From 29b7800f73c9e7bf6ea3d774145eb1be82fc7979 Mon Sep 17 00:00:00 2001 From: alex-senger Date: Wed, 24 Apr 2024 14:29:36 +0200 Subject: [PATCH 001/183] feat: add first parameters --- src/resources/builtins/parameters.ttsl | 260 +++++++++++++++++++++++++ 1 file changed, 260 insertions(+) create mode 100644 src/resources/builtins/parameters.ttsl diff --git a/src/resources/builtins/parameters.ttsl b/src/resources/builtins/parameters.ttsl new file mode 100644 index 00000000..8a8a6324 --- /dev/null +++ b/src/resources/builtins/parameters.ttsl @@ -0,0 +1,260 @@ +package (?) + +// abgelt_st.yaml -------------------------------------------------------- + +/** + * Constant for the Capital Income Tax Rate as defined in §32d (1) EStG. + * Reference: Art. 1 G. v. 14.08.2007 + */ +public const abgeltungssteuersatz: Float { + to 2008-12-31 = 0.0; + from 2009-01-01 = 0.25; +} + +// arbeitsl_geld_2.yaml -------------------------------------------------- + +/** + * Income shares not subject to transfer withdrawal. + * Einkommensanteile, die anrechnungsfrei bleiben. § 30 SGB II. Seit 01.10.2005 + * zudem definiert durch Freibetrag in § 11 SGB II, s. § 67 SGB II. Seit 01.04.2011 + * § 11b (2) SGB II (neugefasst durch B. v. 13.05.2011 BGBl. I S. 850. Artikel 2 + * G. v. 24.03.2011 BGBl. I S. 453). + */ +public const anrechnungsfreieEinkommensanteile: Dict>> { + // Reference: Artikel 1. G. v. 24.12.2003 BGBl. I S. 2954. + from 2005-01-01 = { + 0: { + lower_threshold: -inf, + upper_threshold: 0, + rate: 0, + intercept_at_lower_threshold: 0 + }, + 1: { + lower_threshold: 0, + upper_threshold: 400, + rate: 0.15 + }, + 2: { + upper_threshold: 900, + rate: 0.3 + }, + 3: { + upper_threshold: 1500, + rate: 0.15 + }, + 4: { + upper_threshold: inf, + rate: 0 + } + } + + // Reference: Artikel 1 G. v. 14.08.2005 BGBl. I S. 2407. + from 2005-10-01 = { + 0: { + lower_threshold: -inf, + upper_threshold: 0, + rate: 0, + intercept_at_lower_threshold: 0 + }, + 1: { + lower_threshold: 0, + upper_threshold: 100, + rate: 1.0 + }, + 2: { + upper_threshold: 800, + rate: 0.2 + }, + 3: { + upper_threshold: 1200, + rate: 0.1 + }, + 4: { + upper_threshold: inf, + rate: 0 + } + } + + // Reference: Artikel 1 G. v. 20.12.2011 BGBl. I 2854. + from 2011-04-01 = { + 2: { + upper_threshold: 1000 + } + } + + // Reference: G. v. 20.12.2022 BGBl. I S. 2328. + from 2023-07-01 = { + 0: { + lower_threshold: -inf, + upper_threshold: 0, + rate: 0, + intercept_at_lower_threshold: 0 + }, + 1: { + lower_threshold: 0, + upper_threshold: 100, + rate: 1.0 + }, + 2: { + upper_threshold: 520, + rate: 0.2 + }, + 3: { + upper_threshold: 1000, + rate: 0.3 + }, + 4: { + upper_threshold: 1200, + rate: 0.1 + }, + 5: { + upper_threshold: inf, + rate: 0 + } + } +} + + + +/** + * Abweichende anrechnungsfreie Einkommensanteile falls Kinder im Haushalt + * Obere Einkommensgrenze bei anzurechnendem Einkommen, Intervall 3, Haushalt mit + * Kindern. Gilt statt der Parameter in eink_anr_frei für Leistungsbezieher, die mit + * minderjährigem Kind in BG leben oder die ein minderjähriges Kind haben (zweiteres + * wird aktuell noch nicht im Code beachtet). § 30 SGB II. Seit 01.04.2011 § 11b SGB + * II (neugefasst durch B. v. 13.05.2011 BGBl. I S. 850. Artikel 2 G. v. 24.03.2011 + * BGBl. I S. 453). + */ +public const eink_anr_frei_kinder: Dict>> { + // Reference: Artikel 1 G. v. 14.08.2005 BGBl. I S. 2407. + from 2005-10-01 = { + 3: { + upper_threshold: 1500 + } + } + + // Reference: G. v. 20.12.2022 BGBl. I S. 2328. + from 2023-07-01 = { + 4: { + upper_threshold: 1500 + } + } +} + +public const regelsatz { + +} + +// arbeitsl_geld.yaml ---------------------------------------------------- + +/** + * Income which is not deducted from unemployment benefit. + * § 155 SGB III, vorher § 141 (1) S. 1 + */ +public const arbeitslosenGeldFreibetrag { + from 1999-08-01 = 161; + from 2002-01-01 = 165; +} + +/** + * Fictitious social insurance contribution rate + * § 153 (1) Nr. 1 SGB III. Wird angewendet auf das Bemessungsentgelt. ACHTUNG! Beim + * Elterngeld gibt es eine ähnliche Größe. + */ +public const arbeitslosenGeldSozialVersicherungsPauschale: Float { + from 1984-01-01 = 0.1727; + from 1985-01-01 = 0.1745; + from 1986-01-01 = 0.1775; + from 1987-01-01 = 0.1774; + from 1988-01-01 = 0.1794; + from 1989-01-01 = 0.1795; + from 1990-01-01 = 0.1775; + from 1991-01-01 = 0.179; + from 1992-01-01 = 0.184; + from 1993-01-01 = 0.187; + from 1994-01-01 = 0.1955; + from 1995-01-01 = 0.1915; + from 1996-01-01 = 0.1995; + from 1997-01-01 = 0.2095; + from 1998-01-01 = 0.2105; + from 2000-01-01 = 0.20535; + from 2001-01-01 = 0.2044; + from 2002-01-01 = 0.2065; + from 2003-01-01 = 0.2105; + from 2004-01-01 = 0.2095; + from 2005-01-01 = 0.2074; + from 2006-01-01 = 0.2141; + from 2007-01-01 = 0.2075; + from 2008-01-01 = 0.20475; + from 2009-01-01 = 0.20525; + from 2010-01-01 = 0.20225; + from 2011-01-01 = 0.20625; + + // Reference: Art. 2 G. v. 20.12.2011 BGBl. I S. 2854 + from 2012-01-01 = 0.21; + + // Reference: Art. 1 G. v. 18.12.2018 BGBl. I S. 2651 + from 2019-01-01 = 0.2; +} + +/** + * Replacement Rate Unemployment Benefit, for childless persons. + * §149 Nr. 2 SGB III, vorher § 129 (2) SGB III. Höhe des Arbeitslosengeldes im + * Verhältnis zum letzten Nettoentgelt bei Personen ohne Kinder im Sinne des EStG. + */ +public const satz_ohne_kinder: Float { + // Reference: Art. 1 G. v. 24.03.1997 BGBl. I S. 594 + from 1998-08-01 = 0.6; +} + +/** + * Replacement Rate Unemployment Benefit for persons with children. + * §149 Nr. 1 SGB III, vorher §129 Nr. 1 SGB III. Höhe des Arbeitslosengeldes im + * Verhältnis zum letzten Nettoentgelt bei Personen mit Kindern im Sinne des EStG + */ +public const satz_mit_kindern: Float { + // Reference: Art. 1 G. v. 24.03.1997 BGBl. I S. 594 + from 1998-08-01 = 0.67; +} + +/** + * Working hours limit to receive unemployment benefit + * §138 (3) SGB III, früher auch §102 (2) AFG. Grenze, ab der nicht mehr + * Arbeitslosigkeit unterstellt wird. + */ +public const stundengrenze: Int { + from 1969-07-01 = 20; + // Reference: Art. 1 G. v. 20.12.1985 BGBl I S. 2484 + from 1986-01-01 = 19; + + // Reference: Art. 1 G. v. 20.12.1988 BGBl I S. 2343 + from 1989-01-01 = 18; + + // Reference: Art. 2 G. v. 20.12.2011 BGBl I S. 2854 + from 2012-04-01 = 15; +} + +/** + * Length of ALG 1 eligibility + * Dauer des Anspruchs auf ALG 1 richtet sich nach Alter und wie viele Monate + * eine Person versicherungsplichtig in den letzten 5 Jahren war. + */ +public const anspruchsdauer: Dict { + from 1997-03-24 = { + 0: 12, + 50: 15, + 55: 18, + 58: 24 + }; + + // Reference: § 147 Abs. 2 SGB III + from 1997-03-24 = { + 12: 6, + 18: 8, + 20: 10, + 24: 12, + 30: 15, + 36: 18, + 48: 24 + }; +} From 41ecca18ca16ba9929d9a358dd1efc4d5dc9adf3 Mon Sep 17 00:00:00 2001 From: methr0 Date: Wed, 24 Apr 2024 22:22:56 +0200 Subject: [PATCH 002/183] generate conditional statements and loops --- .../generation/safe-ds-python-generator.ts | 33 +++++++++++++++++++ 1 file changed, 33 insertions(+) diff --git a/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts b/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts index b1da0c3f..2043dbb9 100644 --- a/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts +++ b/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts @@ -66,6 +66,11 @@ import { TslPlaceholder, TslSegment, TslStatement, + isTslConditionalStatement, + isTslLoop, + isTslForLoop, + isTslForeachLoop, + isTslWhileLoop, } from '../generated/ast.js'; import { isInStubFile, isStubFile } from '../helpers/fileExtensions.js'; import { IdManager } from '../helpers/idManager.js'; @@ -606,6 +611,34 @@ export class SafeDsPythonGenerator { return joinTracedToNode(statement)(blockLambdaCode, (stmt) => stmt, { separator: NL, })!; + } else if (isTslConditionalStatement(statement)) { + let elseBlock = new CompositeGeneratorNode + if (statement.elseBlock){ + elseBlock = this.generateBlock((statement.elseBlock), frame, false) + } + return expandTracedToNode(statement)`if ${this.generateExpression((statement.expression), frame)}: + ${this.generateBlock((statement.ifBlock), frame)} + else: ${elseBlock}`; + } else if (isTslLoop(statement)) { + if (isTslWhileLoop(statement)){ + return expandTracedToNode(statement)`while ${this.generateExpression((statement.condition), frame)}: + ${this.generateBlock((statement.block), frame)}`; + } else if (isTslForLoop(statement)){ + let firstParameter, thirdParameter = new CompositeGeneratorNode + if (statement.definitionStatement){ + firstParameter = this.generateStatement((statement.definitionStatement), frame, false) + } + if (statement.iteration){ + thirdParameter = this.generateStatement((statement.iteration), frame, false) + } + return expandTracedToNode(statement)`${firstParameter} + while ${this.generateExpression((statement.condition), frame)}: + ${this.generateBlock((statement.block), frame), thirdParameter + }`; + } else if (isTslForeachLoop(statement)){ + return expandTracedToNode(statement)`for ${statement.element} in ${statement.list}: + ${this.generateBlock((statement.block), frame)}`; + } } /* c8 ignore next 2 */ throw new Error(`Unknown TslStatement: ${statement}`); From 31054d42d27c08781f3678697c1c1cc62b78232b Mon Sep 17 00:00:00 2001 From: methr0 Date: Wed, 24 Apr 2024 22:23:28 +0200 Subject: [PATCH 003/183] tests for conditional statement grammar --- .../bad-with else missing elseblock.tsltest | 6 ++++++ .../bad-without else missing block.tsltest | 5 +++++ .../bad-without else missing condition.tsltest | 5 +++++ .../conditional statements/good-with else false.tsltest | 6 ++++++ .../conditional statements/good-with else true.tsltest | 6 ++++++ .../conditional statements/good-without else.tsltest | 5 +++++ 6 files changed, 33 insertions(+) create mode 100644 packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-with else missing elseblock.tsltest create mode 100644 packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-without else missing block.tsltest create mode 100644 packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-without else missing condition.tsltest create mode 100644 packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-with else false.tsltest create mode 100644 packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-with else true.tsltest create mode 100644 packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-without else.tsltest diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-with else missing elseblock.tsltest b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-with else missing elseblock.tsltest new file mode 100644 index 00000000..5589aebe --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-with else missing elseblock.tsltest @@ -0,0 +1,6 @@ +// $TEST$ syntax_error + +function myFunction(): { + if (true){} + else +} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-without else missing block.tsltest b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-without else missing block.tsltest new file mode 100644 index 00000000..415d8f91 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-without else missing block.tsltest @@ -0,0 +1,5 @@ +// $TEST$ syntax_error + +function myFunction(): { + if (true) +} diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-without else missing condition.tsltest b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-without else missing condition.tsltest new file mode 100644 index 00000000..1dca81c9 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-without else missing condition.tsltest @@ -0,0 +1,5 @@ +// $TEST$ syntax_error + +function myFunction(): { + if (){} +} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-with else false.tsltest b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-with else false.tsltest new file mode 100644 index 00000000..43e54879 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-with else false.tsltest @@ -0,0 +1,6 @@ +// $TEST$ no_syntax_error + +function myFunction(): { + if (false){} + else{} +} diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-with else true.tsltest b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-with else true.tsltest new file mode 100644 index 00000000..3a6bd8ee --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-with else true.tsltest @@ -0,0 +1,6 @@ +// $TEST$ no_syntax_error + +function myFunction(): { + if (true){} + else {} +} diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-without else.tsltest b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-without else.tsltest new file mode 100644 index 00000000..abb59d8a --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-without else.tsltest @@ -0,0 +1,5 @@ +// $TEST$ no_syntax_error + +function myFunction(): { + if (true){} +} From 055490fbcb3535a30c22d4ca6456ad919f2069cd Mon Sep 17 00:00:00 2001 From: alex-senger Date: Sat, 27 Apr 2024 14:28:06 +0200 Subject: [PATCH 004/183] feat: finish Arbeitslosengeld --- src/resources/builtins/parameters.ttsl | 446 +++++++++++++++++++++++-- 1 file changed, 416 insertions(+), 30 deletions(-) diff --git a/src/resources/builtins/parameters.ttsl b/src/resources/builtins/parameters.ttsl index 8a8a6324..8134236a 100644 --- a/src/resources/builtins/parameters.ttsl +++ b/src/resources/builtins/parameters.ttsl @@ -1,4 +1,4 @@ -package (?) +package parameter // abgelt_st.yaml -------------------------------------------------------- @@ -7,7 +7,7 @@ package (?) * Reference: Art. 1 G. v. 14.08.2007 */ public const abgeltungssteuersatz: Float { - to 2008-12-31 = 0.0; + from 1984-01-01 = 0.0; from 2009-01-01 = 0.25; } @@ -20,7 +20,7 @@ public const abgeltungssteuersatz: Float { * § 11b (2) SGB II (neugefasst durch B. v. 13.05.2011 BGBl. I S. 850. Artikel 2 * G. v. 24.03.2011 BGBl. I S. 453). */ -public const anrechnungsfreieEinkommensanteile: Dict>> { +public const arbeitslosengeldAnrechnungsfreieEinkommensanteile: Dict>> { // Reference: Artikel 1. G. v. 24.12.2003 BGBl. I S. 2954. from 2005-01-01 = { 0: { @@ -114,8 +114,6 @@ public const anrechnungsfreieEinkommensanteile: Dict>> { +public const arbeitslosengeldAnrechnungsfreieEinkommensanteileFallsKinder: Dict>> { // Reference: Artikel 1 G. v. 14.08.2005 BGBl. I S. 2407. from 2005-10-01 = { 3: { @@ -141,8 +139,391 @@ public const eink_anr_frei_kinder: Dict>> { } } -public const regelsatz { - +/** + * Regelsatz, seit 2011 Beträge differenzieren sich nach Regelbedarfsstufen + * § 20 V SGB II. Für 2005 bis 2010 siehe Bekanntmachungen zu § 20. Seit 2011 + * wird der Regelbedarf durch das Regelbedarfs-Ermittlungsgesetz (RBEG) ermittelt. + * Neufassung SGB II § 20 (1a) und (2) durch Artikel 6 G. v. 22.12.2016 BGBl. I + * S. + * 3159. + */ +public const arbeitslosenGeldRegelsatz: Int | Dict { + from 2005-01-01 = { + scalar: 338, + reference: "Artikel 1 G. v. 24.12.2003 BGBl. I S. 2954.", + note: "Der tatsächliche Wert unterscheidet sich zwischen Ost und West. Korrekte Werte sind in den alten Bundesländern einschließlich Berlin (Ost) 345 Euro, in den neuen Bundesländern 331 Euro." + }, + + // Reference: B. v. 01.09.2005 BGBl. I S. 2718. + // Betrag unverändert. Der tatsächliche Wert unterscheidet sich zwischen Ost und West. Hier wurde vereinfachend 338 Euro als ungewichteter Mittelwert genommen. Korrekte Werte für die Zeit ab 1. Juli 2005 sind in den alten Bundesländern einschließlich Berlin (Ost) 345 Euro, in den neuen Bundesländern 331 Euro. + from 2005-07-01 = 338 + + // Reference: B. v. 20.07.2006 BGBl. I S. 1702. + from 2006-07-01 = 345 + + // Reference: B. v. 18.06.2007 BGBl. I S. 1139. + from 2007-07-01 = 347 + + // Reference: B. v. 26.06.2008 BGBl. I S. 1102. + from 2008-07-01 = 351 + + // Reference: B. v. 17.06.2009 BGBl. I S. 1342. + from 2009-07-01 = 359 + + // Reference: B. v. 07.06.2010 BGBl. I S. 820. Betrag unverändert. + from 2010-07-01 = 359 + + // Reference: Artikel 1 G. v. 24.03.2011 BGBl. I S. 453. + from 2011-01-01 = { + 1: 364, + 2: 328, + 3: 291, + 4: 287, + 5: 251, + 6: 215, + } + + // Reference: V. v. 20.10.2011 BGBl. I S. 2093. + from 2012-01-01 = { + 1: 374, + 2: 337, + 3: 299, + 4: 287, + 5: 251, + 6: 219, + } + + // Reference: B. v. 18.10.2012 BGBl. I S. 2175. + from 2013-01-01 = { + 1: 382, + 2: 345, + 3: 306, + 4: 289, + 5: 255, + 6: 224, + } + + // Reference: B. v. 16.10.2013 BGBl. I S. 3857. + from 2014-01-01 = { + 1: 391, + 2: 353, + 3: 313, + 4: 296, + 5: 261, + 6: 229, + } + + // Reference: B. v. 15.10.2014 BGBl. I S. 1620. + from 2015-01-01 = { + 1: 399, + 2: 360, + 3: 320, + 4: 302, + 5: 267, + 6: 234, + } + + // Reference: B. v. 22.10.2015 BGBl. I S. 1792. + from 2016-01-01 = { + 1: 404, + 2: 364, + 3: 324, + 4: 306, + 5: 270, + 6: 237, + } + + // Reference: G. v. 22.12.2016 BGBl. I S. 3159. + from 2017-01-01 = { + 1: 409, + 2: 368, + 3: 327, + 4: 311, + 5: 291, + 6: 236, + } + + // Reference: V. v. 08.11.2017 BGBl. I S. 3767. + from 2018-01-01 = { + 1: 416, + 2: 374, + 3: 332, + 4: 316, + 5: 296, + 6: 240, + } + + // Reference: V. v. 19.10.2018 BGBl. I S. 1766. + from 2019-01-01 = { + 1: 424, + 2: 382, + 3: 339, + 4: 322, + 5: 302, + 6: 245, + } + + // Reference: V. v. 18.10.2019 BGBl. I S. 1452. + from 2020-01-01 = { + 1: 432, + 2: 389, + 3: 345, + 4: 328, + 5: 308, + 6: 250 + } + + // Reference: G. v. 09.12.2020 BGBl. I S. 2855. + from 2021-01-01 = { + 1: 446, + 2: 401, + 3: 357, + 4: 373, + 5: 309, + 6: 283 + } + + // Reference: V. v. 13.10.2021 BGBl. I S. 4674. + from 2022-01-01 = { + 1: 449, + 2: 404, + 3: 360, + 4: 376, + 5: 311, + 6: 285 + } + + // Reference: G. v. 20.12.2022 BGBl. I S. 2328. + // Bürgergeld-Gesetz + from 2023-01-01 = { + 1: 502, + 2: 451, + 3: 402, + 4: 420, + 5: 348, + 6: 318 + } +} + +/** + * Anteil am Regelsatz für weitere Personen im Haushalt + * 20 (3) SGB II, eigentliche Wirknorm ist § 20 IV SGB II i.V.m Absatz V + * derselben Norm. 2005 bis 2010. + * 2005-2010 der Regelsatz für weitere Haushaltsmitglieder wurden als Anteil + * des Standardsatzes bestimmt. + */ + public const arbeitslosenGeldAnteilRegelsatz: Dict { + // Reference: Artikel 1 G. v. 24.12.2003 BGBl. I S. 2954. + from 2005-01-01 = { + zwei_erwachsene: 0.9, + weitere_erwachsene: 0.8, + kinder_bis_5: 0.6, + kinder_ab_6_bis_13: 0.6, + kinder_ab_14_bis_24: 0.8 + } + + + // TODO: WAS HEIßT DEVIATION_FROM + // Reference: Artikel 1 G. v. 02.03.2009 BGBl. I S. 416. + from 2009-07-01 = { + zwei_erwachsene: 0.9, + weitere_erwachsene: 0.8, + kinder_bis_5: 0.6, + kinder_ab_6_bis_13: 0.7, + kinder_ab_14_bis_24: 0.8 + } + } + +/** + * Anteil am Regelsatz für weitere Personen im Haushalt + * ``kind_unter_7_oder_mehr`` gibt Mehrbedarf AE bei mind. einem Kind unter 7 Jahren + * oder zwei oder drei Kindern unter 16 Jahre an. ``min_1_kind`` gibt den Mehrbedarf + * an wenn der Anspruch größer ist als der für den ersten Schlüssel. ``max`` gibt + * den Maximalanteil für den Mehrbedarf für Alleinerziehende gemessen am + * maßgebenden Regelbedarf. + * § 21 (3) Nr. 1 SGB II. + * reference_period: Month + */ +public const arbeitslosenGeldMehrbedarfAnteil: Dict { + // Reference: G. v. 24.12.2003 BGBl. I S. 2954. + from 2005-01-01 = { + min_1_kind: 0.12, + kind_unter_7_oder_mehr: 0.36, + max: 0.6 + } +} + +/** + * Maximaler Vermögensgrundfreibetrag + * § 12 (2) Satz 1 Nr. 1 SGB II. Ausnahmeregelung für Personen, + * die vor 1948 geboren wurden. Die Ausnahmeregelung taucht im aktuellen Gesetz nicht + * mehr auf und ist nicht mehr relevant, + * da alle betroffenen Personen zu alt für ALG 2 sind. + */ + def arbeitslosenGeldVermögensGrundfreibetragObergrenze: Dict { + // Reference: Artikel 1 G. v. 23.12.2002 BGBl. I S. 4607. + from 2005-01-01 = { + 1947: 33800, + 1948: 13000, + 1958: 13000, + 1964: 13000 + } + + // Reference: Artikel 1 G. v. 20.07.2006 BGBl. I S. 1706. + from 2006-08-01 = { + 1947: 33800, + 1948: 9750, + 1958: 9750, + 1964: 9750 + } + + // Reference: Artikel 1 G. v. 20.04.2007 BGBl. I S. 554. + from 2008-01-01 = { + 1947: 33800, + 1948: 9750, + 1958: 9900, + 1964: 10050 + } + + // Reference: G. v. 20.12.2022 BGBl. I S. 2328. (Bürgergeld-Gesetz) + from 2023-01-01 = { + 1947: null, + 1948: null, + 1958: null, + 1964: null + } + } + +/** + * Schonvermögen beim Bürgergeld + * Seit der Einführung des Bürgergelds zum 01.01.2023 gilt ein Vermögensfreibetrag + * von 15.000 Euro pro Mitglied der Bedarfsgemeinschaft nach Ablauf der Karenzzeit + * von einem Jahr. Während der Karenzzeit ist ein Vermögen von 40.000 Euro für die + * erste Person einer Bedarfsgemeinschaft und 15.000 Euro für jede weitere erlaubt. + */ + const arbeitslosenGeldSchonvermoegenBuergergeld: Dict { + // Reference: G. v. 20.12.2022 BGBl. I S. 2328. (Bürgergeld-Gesetz) + from 2023-01-01 = { + während_karenzzeit: 40000, + normaler_satz: 15000 + } + } + +/** + * Vermögensfreibetrag für Erstausstattung + * § 12 (2) Satz 1 Nr. 4 SGB II. + */ +const arbeitslosenGeldVermoegensfreibetragAusstattung: Int { + // Reference: Artikel 1 G. v. 24.12.2003 BGBl. I S. 2954. + from 2005-01-01 = 750; + + // Reference: G. v. 20.12.2022 BGBl. I S. 2328. (Bürgergeld-Gesetz) + from 2023-01-01 = null; +} + +/** + * Vermögensgrundfreibetrag je Kind + * § 12 (2) Satz 1 Nr. 1 SGB II. + */ +const arbeitslosenGeldVermoegensfreibetragKind: Int { + // Reference: Artikel 1 G. v. 24.12.2003 BGBl. I S. 2954. + from 2005-01-01 = 4100; + + // Reference: Artikel 1 G. v. 20.07.2006 BGBl. I S. 1706. + from 2006-08-01 = 3100; + + // Reference: G. v. 20.12.2022 BGBl. I S. 2328. (Bürgergeld-Gesetz) + from 2023-01-01 = null; +} + +/** + * Altersgrenzen für Vermögensfreibetrag + * Vermögensfreibetrag ändert sich nach Geburtsjahr + */ +const arbeitslosenGeldVermoegensfreibetragAlter: Dict { + 2005-01-01: { + 1: 1948, + 2: 1958, + 3: 1963 + } + + // Reference: G. v. 20.12.2022 BGBl. I S. 2328. (Bürgergeld-Gesetz) + 2023-01-01: { + 1: null, + 2: null, + 3: null + } +} + +/** + * Abzugsfähige Pauschalen für Werbungskosten und Versicherung + * § 6 (1) Nr. 3 a) ALG II-V. 2005-01.01 bis 2016-07-31. Betrag mit V. v. 26.07 + * .2016 BGBl. I S. 1858 entfallen. Wie entfallen? + * § 3 Alg II-V. Seit 01.01.2008 in § 6 Alg II-V. + */ +const arbeitslosenGeldAbzugfaehigePauschale: Dict { + // Reference: V. v. 20.10.2004 BGBl. I S. 2622 + from 2005-01-01 = { + werbung: 15.33, + versicherung: 30.0 + } + + // Reference: V. v. 21.06.2011 BGBl. I S. 1175. + from 2011-01-01 = { + werbung: 15.33, + versicherung: 30.0 + } +} + +/** + * Obergenze Miete pro Quadratmeter + * Die Miete pro Quadratmeter darf einen angemessenen Betrag nicht übersteigen, um + * für ALG2 berechtigt zu sein. Diese Grenze ist nicht konkret im Gesetz + * festgehalten, sondern wird als Faustregel von den Arbeitsargenturen verwendet. + * § 22 SGB II + * unit: Euro / Quadratmeter + */ +const arbeitslosenGeldMaxMieteProQuadratMeter: Int { + from 1984-01-01 = 10 +} + +/** + * Berechtigte Miet-Wohnfläche für ALG2-Empfänger*innen + * Eine Mietwohnung darf für einen Single 45 Quadratmeter (+15 für jede weitere + * Person) groß sein. + */ +const arbeitslosenGeldBerechtigteWohnflaecheMiete: Dict { + from 1984-01-01 = { + single: 45, + je_weitere_person: 15 + } +} + +/** + * Berechtigte Eigentumsfläche für ALG2-Empfänger*innen + * Vor 2023 gilt, dass Eigentum für zwei Personen im Haushalt 80 Quadratmeter (+20 + * für jede weitere Person) groß sein darf. Ab 2023 ist die erlaubte Größe für + * Eigenheime auf 140 Quadratmeter (für Eigentumswohnungen aus 130 Quadratmeter) + * gestiegen und wird ab 5 Personen im Haushalt um 20 Quadratmeter pro Person + * angehoben. + */ +const arbeitslosenGeldBerechtigteWohnflaecheEigentum: Dict { + from 1984-01-01 = { + 1: 80, + 2: 80, + 3: 100, + 4: 120, + je_weitere_person: 20 + } + + // Reference: Art. 1 Nr.12 Abschnitt 5, G. v. 20.12.2022 BGBl. I S. 2328 + from 2023-01-01 = { + 1: 140, + 2: 140, + 3: 140, + 4: 140, + je_weitere_person: 20 + } } // arbeitsl_geld.yaml ---------------------------------------------------- @@ -151,8 +532,11 @@ public const regelsatz { * Income which is not deducted from unemployment benefit. * § 155 SGB III, vorher § 141 (1) S. 1 */ -public const arbeitslosenGeldFreibetrag { +public const arbeitslosenGeldFreibetrag: Int { + // Art. 1 G. v. 21.07.1999 BGBl. I S. 1648 from 1999-08-01 = 161; + + // Art. 3 G. v. 21.12.2000 BGBl. I S. 1983 from 2002-01-01 = 165; } @@ -202,7 +586,7 @@ public const arbeitslosenGeldSozialVersicherungsPauschale: Float { * §149 Nr. 2 SGB III, vorher § 129 (2) SGB III. Höhe des Arbeitslosengeldes im * Verhältnis zum letzten Nettoentgelt bei Personen ohne Kinder im Sinne des EStG. */ -public const satz_ohne_kinder: Float { +public const arbeitslosenGeldSatzOhneKinder: Float { // Reference: Art. 1 G. v. 24.03.1997 BGBl. I S. 594 from 1998-08-01 = 0.6; } @@ -212,9 +596,9 @@ public const satz_ohne_kinder: Float { * §149 Nr. 1 SGB III, vorher §129 Nr. 1 SGB III. Höhe des Arbeitslosengeldes im * Verhältnis zum letzten Nettoentgelt bei Personen mit Kindern im Sinne des EStG */ -public const satz_mit_kindern: Float { +public const arbeitslosenGeldSatzMitKindern: Float { // Reference: Art. 1 G. v. 24.03.1997 BGBl. I S. 594 - from 1998-08-01 = 0.67; + from 1998-08-01 = 0.67; } /** @@ -222,7 +606,7 @@ public const satz_mit_kindern: Float { * §138 (3) SGB III, früher auch §102 (2) AFG. Grenze, ab der nicht mehr * Arbeitslosigkeit unterstellt wird. */ -public const stundengrenze: Int { +public const arbeitslosenGeldStundengrenze: Int { from 1969-07-01 = 20; // Reference: Art. 1 G. v. 20.12.1985 BGBl I S. 2484 from 1986-01-01 = 19; @@ -239,22 +623,24 @@ public const stundengrenze: Int { * Dauer des Anspruchs auf ALG 1 richtet sich nach Alter und wie viele Monate * eine Person versicherungsplichtig in den letzten 5 Jahren war. */ -public const anspruchsdauer: Dict { - from 1997-03-24 = { - 0: 12, - 50: 15, - 55: 18, - 58: 24 - }; - - // Reference: § 147 Abs. 2 SGB III +public const arbeitslosenGeldAnspruchsdauer: Dict { from 1997-03-24 = { - 12: 6, - 18: 8, - 20: 10, - 24: 12, - 30: 15, - 36: 18, - 48: 24 - }; + nach_alter: { + 0: 12 + 50: 15 + 55: 18 + 58: 24 + }, + nach_versicherungspflichtige_monate: { + 12: 6 + 18: 8 + 20: 10 + 24: 12 + 30: 15 + 36: 18 + 48: 24 + } + } } + +// eink_st_abzuege.yaml -------------------------------------------------- From da19ac6a746cb7e8a55877c3612fa084fdfed971 Mon Sep 17 00:00:00 2001 From: alex-senger Date: Sun, 28 Apr 2024 18:43:30 +0200 Subject: [PATCH 005/183] =?UTF-8?q?feat:=20add=20einkommenssteuer=5Fabz?= =?UTF-8?q?=C3=BCge?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/resources/builtins/parameters.ttsl | 613 +++++++++++++++++++++++++ 1 file changed, 613 insertions(+) diff --git a/src/resources/builtins/parameters.ttsl b/src/resources/builtins/parameters.ttsl index 8134236a..c93d4bda 100644 --- a/src/resources/builtins/parameters.ttsl +++ b/src/resources/builtins/parameters.ttsl @@ -644,3 +644,616 @@ public const arbeitslosenGeldAnspruchsdauer: Dict { } // eink_st_abzuege.yaml -------------------------------------------------- + +/** + * Kinderfreibetrag + * sächliches Existenzminimum des Kindes, seit 2000 auch der Freibetrag für + * Betreuungs-, Erziehungs- und Ausbildungskosten. Wird verdoppelt für gemeinsam + * veranlagte Paare. §32 (6) EStG, seit 2000. + * Pro Jahr + */ +const einkommensSteuerKinderFreibetrag: Dict { + // Reference: Art. 1 G. v. 23.12.1982 BGBl. I S. 1857. + from 1983-01-01 = { + saechlichesExistenzminimum: 110 + } + + // Reference: Art. 1 G. v. 26.06.1985 BGBl. I S. 1153. + from 1986-01-01 = { + saechlichesExistenzminimum: 635 + } + + // Reference: Artikel 1 G. v. 25.07.1988 BGBl. I S. 1093. + from 1990-01-01 = { + saechlichesExistenzminimum: 773 + } + + // Reference: Art. 1 G. v. 25.02.1992 BGBl. I S. 297. + from 1992-01-01 = { + saechlichesExistenzminimum: 1049 + } + + // Reference: Art. 1. G. v. 11.10.1995 BGBl. I S. 1250. + from 1996-01-01 = { + saechlichesExistenzminimum: 1601 + } + + from 1997-01-01 = { + saechlichesExistenzminimum: 1767 + } + + // Reference: Art. 1 G. v. 28.12.1999 BGBl. I. S. 2552. + from 2000-01-01 = { + beitragErziehungAusbildung: 774, + saechlichesExistenzminimum: 1767 + } + + // Reference: Art. 1 G. v. 16.08.2001 BGBl. I S. 2074 + from 2002-01-01 = { + beitragErziehungAusbildung: 1080, + saechlichesExistenzminimum: 1824 + } + + // Reference: Art. 1 G. v. 22.12.2008 BGBl. I S. 2955 + from 2009-01-01 = { + beitragErziehungAusbildung: 1080, // previous + saechlichesExistenzminimum: 1932 + } + + // Reference: Art. 1 G. v. 22.12.2009 BGBl. I S. 3950 + from 2010-01-01 = { + beitragErziehungAusbildung: 1320, + saechlichesExistenzminimum: 2184 + } + + // Reference: Art. 1 G. v. 16.07.2015 BGBl. I S. 1202 + from 2015-01-01 = { + beitragErziehungAusbildung: 1320, // previous + saechlichesExistenzminimum: 2256 + } + + // Reference: Art. 2 G. v. 16.07.2015 BGBl. I S. 1202 + from 2016-01-01 = { + beitragErziehungAusbildung: 1320, // previous + saechlichesExistenzminimum: 2304 + } + + // Reference: Art. 8 G. v. 20.12.2016 BGBl. I. S. 3000 + from 2017-01-01 = { + beitragErziehungAusbildung: 1320, // previous + saechlichesExistenzminimum: 2358 + } + + // Reference: Art. 9 G. v. 20.12.2016 BGBl. I. S. 3000 + from 2018-01-01 = { + beitragErziehungAusbildung: 1320, // previous + saechlichesExistenzminimum: 2394 + } + + // Reference: Art. 1 G. v. 29.11.2018 BGBl. I S. 2210 + from 2019-01-01 = { + beitragErziehungAusbildung: 1320, // previous + saechlichesExistenzminimum: 2490 + } + + // Reference: Art. 3 G. v. 29.11.2018 BGBl. I S. 2210 + from 2020-01-01 = { + beitragErziehungAusbildung: 1320, // previous + saechlichesExistenzminimum: 2586 + } + + // Reference: Art. 1 G. v. 01.12.2020 BGBl. I S. 2616 + from 2021-01-01 = { + saechlichesExistenzminimum: 2730, + beitr_erz_ausb: 1464 + } + + // Reference: Art. 1 G. v. 08.12.2022 BGBl. I S. 2230. + from 2022-01-01 = { + beitragErziehungAusbildung: 2730, // previous + saechlichesExistenzminimum: 2810 + } + + // Reference: Art. 2 G. v. 08.12.2022 BGBl. I S. 2230. + from 2023-01-01 = { + beitragErziehungAusbildung: 2730, // previous + saechlichesExistenzminimum: 3012 + } + + // Reference: Art. 3 G. v. 08.12.2022 BGBl. I S. 2230. + from 2024-01-01 = { + beitragErziehungAusbildung: 2730, // previous + saechlichesExistenzminimum: 3192 + } +} + +/** + * Vorwegabzug der Vorsorgeaufwendungen der Rechtslage vor 2004. + * § 10 (4a) EStG. Früher §10 (3) EStG. Hier steht jeweils der Wert für den + * Steuerpflichtigen. Wird verdoppelt für gemeinsam veranlagte Ehegatten. Der gesamte + * Zeitverlauf wurde bereits 2005 festgelegt. + */ +const vorsorge2004Vorwegabzug: Int { + from 1985-01-01 = 1534 + from 1989-01-01 = 2045 + from 1993-01-01 = 3068 + from 2011-01-01 = 2700 + from 2012-01-01 = 2400 + from 2013-01-01 = 2100 + from 2014-01-01 = 1800 + from 2015-01-01 = 1500 + from 2016-01-01 = 1200 + from 2017-01-01 = 900 + from 2018-01-01 = 600 + from 2019-01-01 = 300 +} + +/** + * Werbungskostenpauschbetrag bei nichtselbstständiger Arbeit. + * § 9a Nr. 1a) EStG + * This is the minimum amount deducted from any employment income. + */ +const werbungskostenpauschbetrag: Int { + from 1975-01-01 = 288 + from 1990-01-01 = 1044 + from 2004-01-01 = 920 + + // Reference: Art. 1 G. v. 01.11.2011 BGBl. I S. 2131. + from 2012-01-01 = 1000 + + // Reference: Art. 2 G. v. 23.05.2022 BGBl. I S. 749 + from 2022-01-01 = 1200 + + // Reference: G. v. 20.12.2022 BGBl. I S. 2294. + from 2023-01-01 = 1230 +} + +/** + * Sonderausgaben-Pauschbetrag + * § 10c EStG + */ +const sonderausgabenpauschbetrag: Int { + from 1984-01-01 = 138 + + // Reference: Art. 1 G. v. 25.07.1988, BGBl. I S. 1093 + from 1988-01-01 = 55 + + // Reference: Art. 1 G. v. 19.12.2000, BGBl. I S. 1790 + from 2002-01-01 = 36 +} + +/** + * Sparerpauschbetrag + * § 20 (9) EStG. Früher § 20 (4) EStG. Wert für Singles. Wird verdoppelt für + * gemeinsam veranlagte. seit 2009. vor 2008 Sparerfreibetrag. + */ +const sparerpauschbetrag: Int { + from 1975-01-01 = 153 + from 1990-01-01 = 307 + from 1993-01-01 = 3068 + from 2000-01-01 = 1534 + + // Reference: Art. 1 G. v. 19.12.2000 BGBl I S. 1790. + from 2002-01-01 = 1550 + from 2004-01-01 = 1370 + from 2007-01-01 = 750 + + // Reference: Art. 1 G. v. 14.08.2007 BGBl. I S. 1912 + from 2009-01-01 = 801 + + // Reference: G. v. 20.12.2022 BGBl. I S. 2294. + from 2023-01-01 = 1000 +} + +/** + * Sparerpauschbetrag + * § 20 (9) EStG. Früher § 20 (4) EStG. Wert für Singles. Wird verdoppelt für + * gemeinsam veranlagte. seit 2009. vor 2008 Sparerfreibetrag. + */ +const sparerWerbungskostenPauschbetrag: Int { + from 1975-01-01 = 51 + from 2009-01-01 = 0 +} + +/** + * Allgemeine Vorsorgepauschale Grundhöchstbetrag, Grundtabelle + * §10 (3) EStG bis 2004. + */ +const vorsorge2004Grundhoechstbetrag: Int { + from 1985-01-01 = 1196 + from 1992-01-01 = 1334 +} + +/** + * Höchstbetrag des Altersentlastungsbetrags + * 24a EStG S. 5. Tabelle legt die Werte bis 2040 fest. Bis 2004 erhalten alle + * Steuerpflichtigen, die im voherigen Kalenderjahr das 64. Lebensjahr vollendet + * haben, maximal den gleichen Altersentlastungsbetrag. Ab 2005 hängt dieser Betrag, + * den diese Steuerpflichtigen erhalten, vom Geburtsjahr ab. + */ +const altersentlastungsbetragMax: Int | Dict { + from 1984-01-01 = 1534 + from 1989-01-01 = 1902 + from 2002-01-01 = 1908 + + // Reference: Artikel 1 G. v. 05.07.2004 BGBl. I S. 1427. + 2005-01-01 = { + 1940: 1900, + 1941: 1824, + 1942: 1748, + 1943: 1672, + 1944: 1596, + 1945: 1520, + 1946: 1444, + 1947: 1368, + 1948: 1292, + 1949: 1216, + 1950: 1140, + 1951: 1064, + 1952: 988, + 1953: 912, + 1954: 836, + 1955: 760, + 1956: 722, + 1957: 684, + 1958: 646, + 1959: 608, + 1960: 570, + 1961: 532, + 1962: 494, + 1963: 456, + 1964: 418, + 1965: 380, + 1966: 342, + 1967: 304, + 1968: 266, + 1969: 228, + 1970: 190, + 1971: 152, + 1972: 114, + 1973: 76, + 1974: 38, + 1975: 0 + } +} + +/** + * Anteil des Altersentlastungsbetrags + * §24a EStG S.5. Tabelle legt alle Werte bis 2040 fest. Bis 2004 wird bei allen + * Steuerpflichtigen, die im voherigen Kalenderjahr das 64. Lebensjahr vollendet + * haben, die gleiche Altersentlastungsquote abgezogen. Ab 2005 hängt diese Quote, + * den diese Steuerpflichtigen erhalten, vom Geburtsjahr ab. + */ +const altersentlastungQuote: Float | Dict { + from 1984-01-01 = 0.4 + + // Reference: Artikel 1 G. v. 05.07.2004 BGBl. I S. 1427. + 2005-01-01 = { + 1940: 0.4, + 1941: 0.384, + 1942: 0.368, + 1943: 0.352, + 1944: 0.336, + 1945: 0.32, + 1946: 0.304, + 1947: 0.288, + 1948: 0.272, + 1949: 0.256, + 1950: 0.24, + 1951: 0.224, + 1952: 0.208, + 1953: 0.192, + 1954: 0.176, + 1955: 0.16, + 1956: 0.152, + 1957: 0.144, + 1958: 0.136, + 1959: 0.128, + 1960: 0.12, + 1961: 0.112, + 1962: 0.104, + 1963: 0.096, + 1964: 0.088, + 1965: 0.08, + 1966: 0.072, + 1967: 0.064, + 1968: 0.056, + 1969: 0.048, + 1970: 0.04, + 1971: 0.032, + 1972: 0.024, + 1973: 0.016, + 1974: 0.008, + 1975: 0 + } +} + +/** + * Altersgrenze für Altersentlastungsbetrag + * Der Altersentlastungsbetrag wird einem Steuerpflichtigen gewährt, der vor dem + * Beginn des Kalenderjahres, in dem er sein Einkommen bezogen hat, das 64. + * Lebensjahr vollendet hatte. + * Reference: § 24a Art. 3 EStG + */ +const altersentlastungsbetragAltersgrenze: Int { + from 1984-01-01 = 64 +} + +/** + * Einführungsfaktor für Altersvorsorge Aufwendung + * In den Jahren 2005-2022 stieg der Anteil der abzugsfähigen Beiträge von 60% in + * 2005 jährlich um 2 Prozentpunkte an bis 94% in 2022 erreicht wurden. Eigentlich + * war geplant, dass der Parameter weiter mit dieser Rate steigt, bis ab 2025 100% + * erreicht sind. Abweichend von diesem Plan, wurden die abzugfähigen Beiträge schon + * 2023 auf 100% gesetzt. + * Reference: § 10 Abs. 1 Nr. 2 Buchst. a und b EStG + */ +const einfuehrungsfaktor: { + from 2005-01-01 = { + 0: {lower_threshold: -inf, rate_linear: 0, intercept_at_lower_threshold: 0.6}, + 1: {lower_threshold: 2005, upper_threshold: 2025, rate_linear: 0.02}, + 2: {upper_threshold: inf, rate_linear: 0} + } + + // Reference: G. v. 20.12.2022 BGBl. I S. 2294. + from 2023-01-01 = { + 0: {lower_threshold: -inf, rate_linear: 0, intercept_at_lower_threshold: 0.6}, + 1: {lower_threshold: 2005, rate_linear: 0.02}, + 2: {lower_threshold: 2022, upper_threshold: 2023, rate_linear: 0.06}, + 3: {upper_threshold: inf, rate_linear: 0} + } +} + +/** + * Entlastungsbetrag für Alleinerziehende + * § 24b (1) EStG. vor 2004 "Haushaltsfreibetrag", § 32 (7) EStG + */ +const alleinerzFreibetrag: Int { + from 1984-01-01 = 2154 + from 1986-01-01 = 2319 + from 1989-01-01 = 2871 + from 2001-01-01 = 2916 + from 2002-01-01 = 2340 + from 2004-01-01 = 1308 + + // Reference: Art. 1 G. v. 16.07.2015 BGBl. I S.1202 + from 2015-01-01 = 1908 + + // Reference: Art. 3 Nr. 2 G. v. 29.12.2020 BGBl. I S.3096 + from 2020-01-01 = 4008 + + // Reference: G. v. 20.12.2022 BGBl. I S. 2294. + from 2023-01-01 = 4260 +} + +/** + * Entlastungsbetrag für Alleinerziehende, Zusatzbetrag + * §24b (2) S. 2 EStG. Alleinerziehenden-Entlastungsbetrag, Zusatzbetrag pro Kind ab + * dem 2. Kind. + */ +const alleinerzFreibetragZusatz: Int { + // Reference: Art. 1 G. vs. 16.07.2015 BGBl. I S.1202 + from 2015-01-01 = 240 +} + +/** + * Kürzung des Vorwegabzugs für Vorsorgeaufwendungen vor 2004. + * §10 (3) S. 2 EStG (vor 2004). Der Vorwegabzug wird pauschal um einen Anteil + * gekürzt bei abhängig Beschäftigten (vereinfacht). + */ +const vorsorge2004KuerzungVorwegabzug: Float { + from 1985-01-01 = 0.0935 + from 1986-01-01 = 0.096 + from 1987-01-01 = 0.0935 + + // Reference: Art. 1 G. v. 25.07.1988 BGBl. I S. 1093 + from 1989-01-01 = 0.12 + + // Reference: Art. 1 G. v. 21.12.1993 BGBl. I S. 2310. + from 1994-01-01 = 0.16 +} + +/** + * Regulärer Maximalbetrag für sonstige Vorsorgeaufwendungen (Kranken-, Pflege, + * AL-V), der für sozialverspfl. Beschäftigte gilt. + * §10 Abs. 4 S.1 EStG + */ +const vorsorgeSonstigeAufwendungenMax: Int { + // Reference: Art. 1 G. v. 05.07.2004 BGBl. I S.1427 + from 2005-01-01 = 1500 + + // Reference: Art. 1 G. v. 23.07.2009 BGBl. I S.1959. + from 2010-01-01 = 1900 +} + +/** + * Maximalbetrag der Altersvorsorgeaufwendungen, 2005er Rechtsstand + * §10 (3) EStG, Anlage 2 SGB VI + */ +const vorsorgeAltersvorsorgeaufwendungenMax: Int { + // Art. 1 G. v. 05.07.2004 BGBl. I S.1427 + from 2005-01-01 = 20000 + + // Ab 2015 knappschaftlicher Höchstbetrag, d.h. knappschaftlicher Beitragssatz * + // knappschaftliche Beitragsbemessungsgrenze + from 2015-01-01 = 22170 + + // .248 * 91800 + from 2016-01-01 = 22766 + + // .247 * 94200 + from 2017-01-01 = 23362 + + // .247 * 96000 + from 2018-01-01 = 23712 + + // .247 * 98400 + from 2019-01-01 = 24305 + + // .247 * 101400 + // Reference: Art. 3 V. v. 17.12.2019 BGBl I S. 2848. + from 2020-01-01 = 25046 + + // .247 * 104400 + // Reference: §3 V. v. 30.11.2020 BGBl. I S. 2612. + from 2021-01-01 = 25787 + + // .247 * 103800 + // Reference: §3 V. v. 30.11.2021, BGBl. I S. 5044. + from 2022-01-01 = 25640 +} + +/** + * Anteil, um den Krankenversicherungsbeiträge gemindert werden bei abhängig + * Beschäftigten. + * §10 (3) a) S.4 EStG + */ +const vorsorgeKrankenMinderung: Float { + // Reference: Art. 1 G. v. 16.07.2009 BGBl. I S. 1959 + from 2009-07-23 = 0.04 +} + +/** + * Behinderten-Pauschbetrag, in Abhängigkeit des Behinderungsgrads. + * § 33b (3) EStG. + */ +const behindertenPauschbetrag: Dict { + // Reference: G. v. 05.08.1974 BGBl. I S. 1769. + from 1975-01-01 = { + 0: 0, + 25: 307, + 35: 429, + 45: 568, + 55: 721, + 65: 890, + 75: 1058, + 85: 1227, + 95: 1411 + } + + // Reference: Art. 1 G. v. 19.12.2000 BGBl. I S. 1790. + from 2002-01-01 = { + 0: 0, + 25: 310, + 35: 430, + 45: 570, + 55: 720, + 65: 890, + 75: 1060, + 85: 1230, + 95: 1420 + } + + // Reference: Art. 1 G. v. 09.12.2020 BGBL. I S. 2770. + from 2021-01-01 = { + 0: 0, + 20: 384, + 30: 620, + 40: 860, + 50: 1140, + 60: 1440, + 70: 1780, + 80: 2120, + 90: 2460, + 100: 2840 + } +} + +/** + * Anteil der Betreuungsaufwendungen, der auf das zu versteuernde Einkommen + * anrechenbar ist + * §10 (1) Nr. 5 EStG + */ +const kinderbetreuungskostenAbzAnteil: Float { + // Reference: Art. 1 G. v. 01.11.2011 BGBl. I S.2131 + from 2012-01-01 = 0.6666666 +} + +/** + * Maximal abziehbare Betreuungsaufwendungen pro Kind + * §10 (1) Nr. 5 EStG + */ +const kinderbetreuungskostenAbzMaximum: Int { + // Reference: Art. 1 G. v. 01.11.2011 BGBl. I S.2131 + from 2012-01-01 = 4000 +} + +/** + * Anteil abgezogene Rentenversicherungsbeiträge + * §10 (3) a) S.4 EStG + */ +const vorsorgepauschaleRentenversicherungsAnteil: Dict> { + 2005-01-01 = { + 0: { + lower_threshold: -inf, + upper_threshold: 2005, + rate_linear: 0, + intercept_at_lower_threshold: 0.2 + }, + 1: { + lower_threshold: 2005, + upper_threshold: 2025, + rate_linear: 0.04, + intercept_at_lower_threshold: 0.2 + }, + 2: { + lower_threshold: 2025, + upper_threshold: inf, + rate_linear: 0, + intercept_at_lower_threshold: 1 + } + } + + 2023-01-01 = { + 0: { + lower_threshold: -inf, + rate_linear: 0, + intercept_at_lower_threshold: 0.2 + }, + 1: { + lower_threshold: 2005, + rate_linear: 0.04 + }, + 2: { + lower_threshold: 2022, + upper_threshold: 2023, + rate_linear: 0.12 + }, + 3: { + lower_threshold: 2023, + upper_threshold: inf, + rate_linear: 0 + } + } +} + +/** + * Mindestanteil für Mindestvorsorgepauschale + * Mindestanteil an Beiträgen zu GKV und GPV, der abgesetzt wird bei + * Mindestvorsorgepauschale + * Reference: 39b (2) Nr.3 EStG + */ +const vorsorgepauschaleMindestanteil: Float { + // Reference: Art. 1 G. v. 16.07.2009 BGBl. I S. 1959 + from 2009-07-23 = 0.12 +} + +/** + * Höchstbetrag Mindestvorsorgepauschale + * Höchsbetrag für Mindestvorsorgepauschale der Beiträge zu GKV und PKV, die von der + * Lohnsteuer abgesetzt werden können. + * Reference: 39b (2) Nr.3 EStG. Depends on Steuerklasse. + */ +const vorsorgepauschaleKvMax: Dict { + // Reference: Art. 1 G. v. 16.07.2009 BGBl. I S. 1959 + from 2009-07-23 = { + steuerklasse_3: 3000, + steuerklasse_nicht3: 1900 + } +} + +// TODO: rounding + +// eink_st.yaml ---------------------------------------------------------- + + From f4b3d77955c02343372d34f8259cb20c642511cb Mon Sep 17 00:00:00 2001 From: alex-senger Date: Sun, 28 Apr 2024 18:50:25 +0200 Subject: [PATCH 006/183] feat: add einkommenssteuer --- src/resources/builtins/parameters.ttsl | 174 +++++++++++++++++++++++++ 1 file changed, 174 insertions(+) diff --git a/src/resources/builtins/parameters.ttsl b/src/resources/builtins/parameters.ttsl index c93d4bda..5daa4cb7 100644 --- a/src/resources/builtins/parameters.ttsl +++ b/src/resources/builtins/parameters.ttsl @@ -1256,4 +1256,178 @@ const vorsorgepauschaleKvMax: Dict { // eink_st.yaml ---------------------------------------------------------- +/** + * Einkommenssteuer Tarif + * §32a EStG + * Der quadratische Anstieg in den mittleren Intervallen wird nach der Formel + * des Progressionsfaktors berechnet. Einzelheiten sind im docstring der Funktion + * add_progressionsfaktor beschrieben. + */ +const eink_st_tarif: Dict> { + + // TODO: klären wie das mit deviation_from aussieht + + + from 2002-01-01 = { + 0: {lower_threshold: -inf, upper_threshold: 7235, rate_linear: 0, rate_quadratic: 0, intercept_at_lower_threshold: 0}, + 1: {upper_threshold: 9251, rate_linear: 0.199}, + 2: {upper_threshold: 55007, rate_linear: 0.23}, + 3: {upper_threshold: inf, rate_linear: 0.485, rate_quadratic: 0} + } + + from 2004-01-01 = { + 0: {lower_threshold: -inf, upper_threshold: 7664, rate_linear: 0, intercept_at_lower_threshold: 0}, + 1: {upper_threshold: 12739, rate_linear: 0.16}, + 2: {upper_threshold: 52151, rate_linear: 0.2405}, + 3: {upper_threshold: inf, rate_linear: 0.45, rate_quadratic: 0} + } + + from 2005-01-01 = { + 0: {lower_threshold: -inf, upper_threshold: 7664, rate_linear: 0, rate_quadratic: 0, intercept_at_lower_threshold: 0}, + 1: {upper_threshold: 12739, rate_linear: 0.15}, + 2: {upper_threshold: 52151, rate_linear: 0.2397}, + 3: {upper_threshold: inf, rate_linear: 0.42, rate_quadratic: 0} + } + + from 2007-01-01 = { + 0: {lower_threshold: -inf, upper_threshold: 7664, rate_linear: 0, rate_quadratic: 0, intercept_at_lower_threshold: 0}, + 1: {upper_threshold: 12739, rate_linear: 0.15}, + 2: {upper_threshold: 52151, rate_linear: 0.2397}, + 3: {upper_threshold: 250000, rate_linear: 0.42, rate_quadratic: 0}, + 4: {upper_threshold: inf, rate_linear: 0.45, rate_quadratic: 0} + } + + from 2009-01-01 = { + deviation_from: previous, + 0: {upper_threshold: 7834}, + 1: {upper_threshold: 13139, rate_linear: 0.14}, + 2: {upper_threshold: 52551}, + 3: {upper_threshold: 250400} + } + + from 2010-01-01 = { + deviation_from: previous, + 0: {upper_threshold: 8004}, + 1: {upper_threshold: 13469}, + 2: {upper_threshold: 52881}, + 3: {upper_threshold: 250730} + } + + from 2013-01-01 = { + deviation_from: previous, + 0: {upper_threshold: 8130} + } + + from 2014-01-01 = { + // Reference: G. v. 20.2.2013, BGBl I S.283 + deviation_from: previous, + 0: {upper_threshold: 8354} + } + + from 2015-07-01 = { + // Reference: G. v. 15.07.2015, BGBl. Nr. 30 2015 + deviation_from: previous, + 0: {upper_threshold: 8472} + } + + from 2016-01-01 = { + // Reference: G. v. 15.07.2015, BGBl. Nr. 30 2015 + deviation_from: previous, + 0: {upper_threshold: 8652}, + 1: {upper_threshold: 13669}, + 2: {upper_threshold: 53665}, + 3: {upper_threshold: 254446} + } + + from 2017-01-01 = { + // Reference: Artikel 8 G. v. 20.12.2016, BGBl I S. 3000 + deviation_from: previous, + 0: {upper_threshold: 8820}, + 1: {upper_threshold: 13769}, + 2: {upper_threshold: 54057}, + 3: {upper_threshold: 256303} + } + + from 2018-01-01 = { + // Reference: Artikel 9 G. v 23.12.2016, BGBL I, S. 3000 + deviation_from: previous, + 0: {upper_threshold: 9000}, + 1: {upper_threshold: 13996}, + 2: {upper_threshold: 54949}, + 3: {upper_threshold: 260532} + } + + from 2019-01-01 = { + deviation_from: previous, + 0: {upper_threshold: 9169}, + 1: {upper_threshold: 14255}, + 2: {upper_threshold: 55961}, + 3: {upper_threshold: 265327} + } + + from 2020-01-01 = { + // Reference: Art. 3 G. v. 29.11.2018 BGBl. I S. 2210 + deviation_from: previous, + 0: {upper_threshold: 9408}, + 1: {upper_threshold: 14532}, + 2: {upper_threshold: 57051}, + 3: {upper_threshold: 270501} + } + + from 2021-01-01 = { + // Reference: Art. 1 G. v. 01.12.2020 BGBl. I S. 2616 + deviation_from: previous, + 0: {upper_threshold: 9744}, + 1: {upper_threshold: 14753}, + 2: {upper_threshold: 57918}, + 3: {upper_threshold: 274613} + } + + from 2022-01-01 = { + // Reference: Art. 1 G. v. 23.05.2022 BGBl. I S. 749 + deviation_from: previous, + 0: {upper_threshold: 10347}, + 1: {upper_threshold: 14926}, + 2: {upper_threshold: 58596}, + 3: {upper_threshold: 277826} + } + + from 2023-01-01 = { + // Reference: Art. 2 G. v. 08.12.2022 BGBl. I S. 2230., + deviation_from: previous, + 0: {upper_threshold: 10909}, + 1: {upper_threshold: 16000}, + 2: {upper_threshold: 62810}, + 3: {upper_threshold: 277826} + } + + from 2024-01-01 = { + // Reference: Art. 3 G. v. 08.12.2022 BGBl. I S. 2230. + deviation_from: previous, + 0: {upper_threshold: 11605}, + 1: {upper_threshold: 17006}, + 2: {upper_threshold: 66761}, + 3: {upper_threshold: 277826} + } +} + +/** + * Ertragsanteil-Funktion für den Anteil an sozialversicherungspflichtigen + * Renteneinkommen, der versteuert werden muss (piecewise linear) + * § 22 EStG + * Diese Funktion ist hier ab 2002 angegeben. Vor 2002 das Steuersystem ist nicht + * implementiert. + */ +const renteErtragsanteil: Dict> { + from 2002-01-01 = { + 0: {lower_threshold: -inf, upper_threshold: 2005, rate_linear: 0, intercept_at_lower_threshold: 0.27}, + 1: {lower_threshold: 2005, upper_threshold: 2021, rate_linear: 0.02, intercept_at_lower_threshold: 0.5}, + 2: {lower_threshold: 2021, upper_threshold: 2041, rate_linear: 0.01, intercept_at_lower_threshold: 0.8}, + 3: {lower_threshold: 2041, upper_threshold: inf, rate_linear: 0.0, intercept_at_lower_threshold: 1} + } +} + +// TODO: rounding + +// elterngeld.yaml ------------------------------------------------------- From 8459c6ed45c80e643363e24b3b980d7168adba51 Mon Sep 17 00:00:00 2001 From: alex-senger Date: Sun, 28 Apr 2024 18:58:32 +0200 Subject: [PATCH 007/183] feat: add elterngeld --- src/resources/builtins/parameters.ttsl | 142 +++++++++++++++++++++++++ 1 file changed, 142 insertions(+) diff --git a/src/resources/builtins/parameters.ttsl b/src/resources/builtins/parameters.ttsl index 5daa4cb7..2a246a2f 100644 --- a/src/resources/builtins/parameters.ttsl +++ b/src/resources/builtins/parameters.ttsl @@ -1431,3 +1431,145 @@ const renteErtragsanteil: Dict> { // elterngeld.yaml ------------------------------------------------------- +/** + * Faktor bei der ElG-Berechung, 2. Stufe + * § 2 (1) BEEG + */ +const elterngeldFaktor: Float { + from 2007-01-01 = 0.67 +} + +/** + * Höchstbetrag des Elterngeldes + * § 2 (1) BEEG + */ +const elterngeldHoechstbetrag: Int { + from 2007-01-01 = 1800 +} + +/** + * Nettoeinkommen an 1. und 2. Stufe + * § 2 (2) BEEG. Maßgeblich ist das durchschnittlich erzielte monatliche Einkommen + * vor der Geburt + */ +const elterngeldNettoeinkommenStufen: Dict { + // Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 + from 2007-01-01 = { + 1: 1000, + 2: 1001 + } + + // Reference: Art. 14 G. v. 09.12.2010 BGBl. I S. 1885 + from 2011-01-01 = { + 1: 1000, + 2: 1201 + } +} + +/** + * Mindestbetrag des Elterngeldes + * § 2 (5) BEEG + */ +const elterngeldMindestbetrag: Int { + // Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 + from 2007-01-01 = 300 +} + +/** + * Korrektur des Prozentsatzes für hohe und niedrige Einkommen + * § 2 (2) BEEG + */ +const elterngeldProzentKorrektur: Float { + // Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 + from 2007-01-01 = 0.001 +} + +/** + * Minimaler Anteil des Elterngelds am vorherigen Nettoeinkommen + * § 2 (2) BEEG + */ +const elterngeldProzentMinimum: Float { + from 2007-01-01 = 0.67 + + // Reference: Art. 14 G. v. 09.12.2010 BGBl. I S. 1885 + from 2011-01-01 = 0.65 +} + +/** + * Einkommensschritte für die Korrektur + * § 2 (2) BEEG + */ +const elterngeldEinkommensSchrittKorrektur: Int { + // Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 + from 2007-01-01 = 2 +} + +/** + * Altersgrenzen für Geschwisterbonus + * Leben im Haushalt zwei Kinder unter 3 Jahren oder mehr als zwei unter 6 Jahren + * wird das Elterngeld um 10% (max. um 75€) erhöht. + * Reference: § 2a BEEG + */ +const elterngeldGeschwisterbonusAltersgrenzenKinder: Dict { + from 2007-01-01 = { + 3: 2, + 6: 3 + } +} + +/** + * Geschwisterbonus als prozentualer Aufschlag + * § 2a (1) BEEG. Früher § 2 (4) BEEG + */ +const elterngeldGeschwisterbonusAufschlag: Float { + // Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 + from 2007-01-01 = 0.1 +} + +/** + * Minimaler Geschwisterbonus als Euro-Betrag + * § 2a (1) BEEG. Früher §2 (4) BEEG + */ +const elterngeldGeschwisterbonusMinimum: Int { + // Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 + from 2007-01-01 = 75 +} + +/** + * Pauschale für jedes weitere Mehrlingskind + * § 2a (4) BEEG, früher §2 (6) BEEG. + * pro Monat + */ +const elterngeldMehrlingbonus: Int { + // Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 + from 2007-01-01 = 300 +} + +/** + * Sozialversicherungspauschale zur Berechnung des Nettoeinkommens + * §2f BEEG. Vor 2012 waren es die eigentlichen Pflichtbeiträge. + */ +const elterngeldSozialversicherungspauschale: Float { + // Reference: Art. 1 G. v. 10.09.2012 BGBl. I S. 1878 + from 2012-09-18 = 0.21 +} + +/** + * Maximale Anzahl an Monaten, in denen ein Paar Elterngeld erhält + * § 4 (3) BEEG + */ +const elterngeldMaxMonatePaar: Int { + // Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 + from 2007-01-01 = 14 +} + +/** + * Maximale Anzahl an Monaten, die jedes Elternteil Elterngeld erhält + * § 4 (3) BEEG + */ +const elterngeldMaxMonateIndividuell: Int { + // Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 + from 2007-01-01 = 12 +} + +// erwerbsm_rente.yaml --------------------------------------------------- From bd9aaa9893ba0e7134308fd303cb359b48ef9b27 Mon Sep 17 00:00:00 2001 From: alex-senger Date: Sun, 28 Apr 2024 19:08:59 +0200 Subject: [PATCH 008/183] feat: add erwerbsm_rente.yaml --- src/resources/builtins/parameters.ttsl | 151 +++++++++++++++++++++++++ 1 file changed, 151 insertions(+) diff --git a/src/resources/builtins/parameters.ttsl b/src/resources/builtins/parameters.ttsl index 2a246a2f..24ccf648 100644 --- a/src/resources/builtins/parameters.ttsl +++ b/src/resources/builtins/parameters.ttsl @@ -1573,3 +1573,154 @@ const elterngeldMaxMonateIndividuell: Int { } // erwerbsm_rente.yaml --------------------------------------------------- + +/** + * Regelaltersgrenze + * Altersgrenze bis zu der man die Erwerbsminderungsrente ohne Abzüge in + * Anspruch nehmen kann. Bis 2012 lag die Regelaltersgrenze bei 63. Ab dann + * schrittweise Anhebung bis 65. + * Reference: § 77 SGB VI Zugangsfaktor + * pro Jahr + */ +const abschlagsfreieAltersgrenze: Dict { + from 2001-01-01 = 63 + from 2012-01-01 = 63.083333 + from 2012-02-01 = 63.166666 + from 2012-03-01 = 63.25 + from 2012-04-01 = 63.333333 + from 2012-05-01 = 63.416666 + from 2012-06-01 = 63.5 + from 2013-01-01 = 63.583333 + from 2014-01-01 = 63.666666 + from 2015-01-01 = 63.75 + from 2016-01-01 = 63.833333 + from 2017-01-01 = 63.916666 + from 2018-01-01 = 64 + from 2019-01-01 = 64.166666 + from 2020-01-01 = 64.333333 + from 2021-01-01 = 64.5 + from 2022-01-01 = 64.666666 + from 2023-01-01 = 64.833333 + from 2024-01-01 = 65 +} + +/** + * Regelaltersgrenze für langjährige Versicherte + * Altersgrenze bis zu der man bestimmte zeitliche Bedingungen + * erfüllt. Bedingungen werden in § 77 Abs. 4 SGB VI definiert. + * Reference: § 77 Abs. 4 SGB VI Zugangsfaktor + * pro Jahr + */ +const regelaltersgrezeLangjaehrigeVersicherte: Dict { + from 2001-01-01 = 63 +} + +/** + * Wartezeitgrenze für abschlagsfreie Erwerbsminderungsrente + * Anzahl an Wartezeitjahren nach § 51 Absatz 3a SGB VI, die für eine abschlagsfreie + * Erwerbsminderungsrente mit 63 nachgewiesen werden müssen. + * Reference: § 264d SGB VI Zugangsfaktor + * pro Jahr + */ +const wartezeitgrenzeLangjaehrigeVersicherteAbschlagsfrei: Dict { + from 2001-01-01 = 35 + from 2024-01-01 = 40 +} + +/** + * Zurechnungszeitgrenze + * Altersgrenze für die Zurechnungszeit der Erwerbsminderungsrente. + * Anhebung von 2020 bis 2027 um 1 Monat pro Kalendarjahr und ab 2028 + * jeweils 2 Monate bis 67 erreicht ist. + * Reference: § 59 SGB VI Zurechnungszeit + * pro Jahr + */ +const zurechnungszeitgrenze: Dict { + from 2001-01-01 = 62.916666 + from 2001-02-01 = 62.833333 + from 2001-03-01 = 62.75 + from 2001-04-01 = 62.666666 + from 2001-05-01 = 62.583333 + from 2001-06-01 = 62.5 + from 2001-07-01 = 62.416666 + from 2001-08-01 = 62.333333 + from 2001-09-01 = 62.25 + from 2001-10-01 = 62.166666 + from 2001-11-01 = 62.083333 + from 2001-12-01 = 62 + from 2002-01-01 = 61.916666 + from 2002-02-01 = 61.833333 + from 2002-03-01 = 61.75 + from 2002-04-01 = 61.666666 + from 2002-05-01 = 61.583333 + from 2002-06-01 = 61.5 + from 2002-07-01 = 61.416666 + from 2002-08-01 = 61.333333 + from 2002-09-01 = 61.25 + from 2002-10-01 = 61.166666 + from 2002-11-01 = 61.083333 + from 2002-12-01 = 61 + from 2003-01-01 = 60.916666 + from 2003-02-01 = 60.833333 + from 2003-03-01 = 60.75 + from 2003-04-01 = 60.666666 + from 2003-05-01 = 60.583333 + from 2003-06-01 = 60.5 + from 2003-07-01 = 60.416666 + from 2003-08-01 = 60.333333 + from 2003-09-01 = 60.25 + from 2003-10-01 = 60.166666 + from 2003-11-01 = 60.083333 + from 2003-12-01 = 60 + from 2014-07-01 = 62 + from 2019-01-01 = 65.666666 + from 2020-01-01 = 65.75 + from 2021-01-01 = 65.833333 + from 2022-01-01 = 65.916666 + from 2023-01-01 = 66 + from 2024-01-01 = 66.083333 + from 2025-01-01 = 66.166666 + from 2026-01-01 = 66.25 + from 2027-01-01 = 66.333333 + from 2028-01-01 = 66.5 + from 2029-01-01 = 66.666666 + from 2030-01-01 = 66.833333 + from 2031-01-01 = 67 +} + +/** + * Kleinster möglicher Zugangsfaktor bei der Erwerbsminderungsrente + * Abzüge wegen frühzeitigem Eintritt in die Erwerbsminderungsrente + * sind bei 10.8% gedeckelt. + * Reference: § 77 SGB VI Zugangsfaktor + */ +const minZugangsfaktor: Dict { + from 2000-01-01 = 0.892 +} + +/** + * Rentenartfaktor für teilweise Erwerbsminderungsrente + * Der Rentenartfaktor ist ein festgelegter Faktor für die + * Rentenberechnung und bestimmt + * das Sicherungsziel der Rentenart im Verhältnis zu einer Altersrente. + * Reference: § 67 SGB VI Rentenartfaktor + */ +const rentenartfaktor: Dict { + from 2001-01-01 = { + teilw: 0.5, + voll: 1.0 + } +} + +/** + * Altersgrenze des belegungsfähigen Gesamtzeitraum + * Als Teil der Grundbewertung wird der belegungsfähige Gesamtzeitraum + * berechnet. Dieser entspricht dem Zeitraum vom 17. + * Lebensjahr bis zum Beginn der Rente + * Reference: SGB VI § 72: Grundbewertung + */ +const altersgrenzeGrundbewertung: Dict { + from 2001-01-01 = 16 +} + +// erziehungsgeld.yaml --------------------------------------------------- From 32021e1d27f410707cba1055c3925f87177a4a80 Mon Sep 17 00:00:00 2001 From: alex-senger Date: Thu, 2 May 2024 10:13:30 +0200 Subject: [PATCH 009/183] feat: add erziehungsgeld parameters --- src/resources/builtins/parameters.ttsl | 98 ++++++++++++++++++++++++++ 1 file changed, 98 insertions(+) diff --git a/src/resources/builtins/parameters.ttsl b/src/resources/builtins/parameters.ttsl index 24ccf648..1dcfd75d 100644 --- a/src/resources/builtins/parameters.ttsl +++ b/src/resources/builtins/parameters.ttsl @@ -1724,3 +1724,101 @@ const altersgrenzeGrundbewertung: Dict { } // erziehungsgeld.yaml --------------------------------------------------- + +/** + * Einkommensgrenze für abzugsfreies Erziehungsgeld + * Reference: Bundesgesetzblatt Jahrgang 2004 Teil I Nr. 6 (p.209) + */ +const erziehungsgeldEinkommensgrenze: Dict>> { + from 2004-02-09 = { + limit: { + alleinerz: { + regelsatz: 23000, + budgetsatz: 19086 + }, + paar: { + regelsatz: 30000, + budgetsatz: 22086 + } + }, + reduced_limit: { + alleinerz: { + regelsatz: 13500, + budgetsatz: 13500 + }, + paar: { + regelsatz: 16500, + budgetsatz: 16500 + } + } + } +} + +/** + * Erhöhung der Einkommensgrenze pro weiterem Kind + * Reference: Bundesgesetzblatt Jahrgang 2004 Teil I Nr. 6 (p.209) + */ +const erziehungsgeldAufschlagEinkommen: Dict { + from 2004-02-09 = 3140 +} + +/** + * Höhe des Erziehungsgeldes abhängig vom beantragtem Satz + * Reference: Bundesgesetzblatt Jahrgang 2004 Teil I Nr. 6 § 5 (p.208) + */ +const erziehungsgeldSatz: Dict { + from 2004-02-09 = { + regelsatz: 300, + budgetsatz: 450 + } +} + +/** + * Faktor zur Berechnung des Abschlag des Erziehungsgeld bei einer + * Überschreitung der Einkommensgrenze ab dem 7 Lebensmonat. + * Der Faktor wird mit dem relevanten Einkommen multipliziert und + * das Produkt entsprechend vom Erziehungsgeld Anspruch abgezogen + * Reference: Bundesgesetzblatt Jahrgang 2004 Teil I Nr. 6 + */ +const erziehungsgeldAbschlagFaktor: Float { + from 2004-02-09 = 0.052 +} + +/** + * Faktor um den das Einkommen pauschal reduziert wird um das das + * relevanten Einkommen zu berechnen + * Reference: Bundesgesetzblatt Jahrgang 2004 Teil I Nr. 6 § 6 (p.209) + */ +const erziehungsgeldPauschalAbzugAufEinkommen: Float { + from 2004-02-09 = 0.76 +} + +/** + * Grenze der wöchentlichen Arbeitsstunden bis zu der Erziehungsgeld ausgezahlt wird + * Reference: Bundesgesetzblatt Jahrgang 2004 Teil I Nr. 6 § 15 (p.211) + */ +const erziehungsgeldArbeitsstundenWoechentlicheGrenze: Int { + from 2004-02-09 = 30 +} + +/** + * Alter des Kindes in Monaten bis zu dem der Regelsatz bezogen werden kann. + * Reference: Bundesgesetzblatt Jahrgang 2004 Teil I Nr. 6 + */ +const erziehungsgeldEndAlterKindRegelsatz: Int { + from 2004-01-01 = 24 +} + +/** + * Alter des Kindes in Monaten bis zu dem der Budgetsatz bezogen werden kann. + * Reference: Bundesgesetzblatt Jahrgang 2004 Teil I Nr. 6 + */ +const erziehungsgeldEndAlterKindBudgetsatz: Int { + from 2004-01-01 = 12 +} + +// TODO: rounding + +// ges_rente.yaml -------------------------------------------------------- + + From 31ea1555ef93ed39023e1a396c3f9a2ea8fdc639 Mon Sep 17 00:00:00 2001 From: methr0 Date: Mon, 6 May 2024 16:22:27 +0200 Subject: [PATCH 010/183] generateFunction with Timespan blocks --- .../generation/safe-ds-python-generator.ts | 68 +++++++++++++++++++ .../src/language/grammar/safe-ds.langium | 24 ++++--- 2 files changed, 84 insertions(+), 8 deletions(-) diff --git a/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts b/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts index 2043dbb9..75663a5c 100644 --- a/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts +++ b/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts @@ -71,6 +71,10 @@ import { isTslForLoop, isTslForeachLoop, isTslWhileLoop, + TslFunction, + TslFunctionBlock, + isTslAggregation, + isTslTimespanStatement, } from '../generated/ast.js'; import { isInStubFile, isStubFile } from '../helpers/fileExtensions.js'; import { IdManager } from '../helpers/idManager.js'; @@ -336,6 +340,11 @@ export class SafeDsPythonGenerator { .map((pipeline) => this.generatePipeline(pipeline, importSet, utilitySet, typeVariableSet, generateOptions), ); + const functions = getModuleMembers(module) + .filter(isTslFunction) + .map((funct) => + this.generateFunction(funct, importSet, utilitySet, typeVariableSet, generateOptions), + ); const imports = this.generateImports(Array.from(importSet.values())); const output = new CompositeGeneratorNode(); output.trace(module); @@ -380,6 +389,16 @@ export class SafeDsPythonGenerator { output.append(joinToNode(pipelines, (pipeline) => pipeline, { separator: SPACING })); output.appendNewLine(); } + if (functions.length > 0) { + output.appendNewLineIf( + imports.length > 0 || typeVariableSet.size > 0 || utilitySet.size > 0 || segments.length > 0, + ); + output.append('# Functions --------------------------------------------------------------------'); + output.appendNewLine(); + output.appendNewLine(); + output.append(joinToNode(functions, (funct) => funct, { separator: SPACING })); + output.appendNewLine(); + } return output; } @@ -418,6 +437,52 @@ export class SafeDsPythonGenerator { .indent({ indentedChildren: [segmentBlock], indentation: PYTHON_INDENT }); } + private generateFunction( + funct: TslFunction, + importSet: Map, + utilitySet: Set, + typeVariableSet: Set, + generateOptions: GenerateOptions, + ): CompositeGeneratorNode { + const infoFrame = new GenerationInfoFrame( + importSet, + utilitySet, + typeVariableSet, + true, + generateOptions.targetPlaceholder, + generateOptions.disableRunnerIntegration, + ); + + return expandTracedToNode(funct)`def ${traceToNode( + funct, + 'name', + )(this.getPythonNameOrDefault(funct))}(${funct.timeunit}, ${funct.groupedBy}, date, ${funct.parameterList}):` + .appendNewLine() + .indent({ indentedChildren: [this.generateFunctionBlock(funct.body, infoFrame)], indentation: PYTHON_INDENT }); + } + + private generateFunctionBlock( + block: TslFunctionBlock, + frame: GenerationInfoFrame, + generateLambda: boolean = false, + ): CompositeGeneratorNode { + const targetPlaceholder = getPlaceholderByName(block, frame.targetPlaceholder); + let statements = getStatements(block).filter((stmt) => this.purityComputer.statementDoesSomething(stmt)); + if (targetPlaceholder) { + statements = this.getStatementsNeededForPartialExecution(targetPlaceholder, statements); + } + if (statements.length === 0) { + return traceToNode(block)('pass'); + } + return joinTracedToNode(block, 'statements')( + statements, + (stmt) => this.generateStatement(stmt, frame, generateLambda), + { + separator: NL, + }, + )!; + } + private generateParameters( parameters: TslParameterList | undefined, frame: GenerationInfoFrame, @@ -611,6 +676,9 @@ export class SafeDsPythonGenerator { return joinTracedToNode(statement)(blockLambdaCode, (stmt) => stmt, { separator: NL, })!; + } else if (isTslTimespanStatement(statement)) { + return expandTracedToNode(statement)`if ${statement.timespan.start} <= date < ${statement.timespan.end}: + ${this.generateFunctionBlock(statement.block, frame)}`; } else if (isTslConditionalStatement(statement)) { let elseBlock = new CompositeGeneratorNode if (statement.elseBlock){ diff --git a/packages/ttsl-lang/src/language/grammar/safe-ds.langium b/packages/ttsl-lang/src/language/grammar/safe-ds.langium index 79698e7a..cc720bdd 100644 --- a/packages/ttsl-lang/src/language/grammar/safe-ds.langium +++ b/packages/ttsl-lang/src/language/grammar/safe-ds.langium @@ -329,16 +329,14 @@ fragment TslFunctionFragment: ; interface TslFunctionBlock extends TslBlock{ - timespans: TslTimespan[] + timespanStatement: TslTimespanStatement[] } TslFunctionBlock returns TslFunctionBlock: {TslFunctionBlock} - '{' ( statements+=TslStatement* - | timespans+=TslTimespan - '{' ( timespans+=TslTimespan statements+=TslStatement + '{' ( timespanStatement+=TslTimespanStatement | statements+=TslStatement)* - '}')* '}' + '}' ; interface TslConstant extends TslModuleMember { @@ -537,6 +535,7 @@ TslStatement returns TslStatement: | TslExpressionStatement | TslConditionalStatement | TslLoop + | TslTimespanStatement ; interface TslAssignment extends TslStatement { @@ -643,13 +642,13 @@ TslExpression returns TslExpression: ; interface TslAggregation extends TslExpression{ - function: @TslFunction - data: @TslData[] + function: TslExpression + data: TslExpression[] groupedBy: TslGroupedBy } TslAggregation returns TslAggregation: - 'aggregate' function=[TslFunction:ID] 'of' data+=[TslData:ID] (',' data+=[TslData:ID])* groupedBy=TslGroupedBy + 'aggregate' function=TslExpression 'of' data+=TslExpression (',' data+=TslExpression)* groupedBy=TslGroupedBy ; interface TslLambda extends TslCallable, TslExpression {} @@ -1057,6 +1056,15 @@ TslTimespan returns TslTimespan: ('from' start=TslDate)? ('to' end=TslDate)? ; +interface TslTimespanStatement extends TslBlock, TslStatement{ + timespan: TslTimespan + block: TslFunctionBlock +} + +TslTimespanStatement returns TslTimespanStatement: + timespan=TslTimespan '{' block=TslFunctionBlock '}' +; + // ----------------------------------------------------------------------------- // Types // ----------------------------------------------------------------------------- From 1750869ac43fee1c8b77e61ce511296be2b2bae1 Mon Sep 17 00:00:00 2001 From: methr0 Date: Mon, 6 May 2024 18:23:42 +0200 Subject: [PATCH 011/183] utility aggregation generation --- .../generation/safe-ds-python-generator.ts | 22 +++++++++++++++++++ .../src/language/grammar/safe-ds.langium | 4 ++-- 2 files changed, 24 insertions(+), 2 deletions(-) diff --git a/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts b/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts index 75663a5c..7e5a8a50 100644 --- a/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts +++ b/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts @@ -178,6 +178,28 @@ const UTILITY_NULL_SAFE_MEMBER_ACCESS: UtilityFunction = { typeVariables: [`${CODEGEN_PREFIX}T`], }; +const UTILITY_AGGREGATION: UtilityFunction = { + name: `${CODEGEN_PREFIX}aggregation`, + code: expandToNode`def ${CODEGEN_PREFIX}aggregation(dataFrame: pd, data: str, id: str, function: str) -> pd | None:` + .appendNewLine() + .indent({ + indentedChildren:['dataFrame = dataFrame.join(dataFrame[id])'], + indentation: PYTHON_INDENT, + }) + .appendNewLine() + .indent({ + indentedChildren:['dataFrame[data] = dataFrame.groupby(id)[data].transform(function)'], + indentation: PYTHON_INDENT, + }) + .appendNewLine() + .indent({ + indentedChildren: ['return dataFrame'], + indentation: PYTHON_INDENT, + }), + imports: [{ importPath: 'gettsim', declarationName: '(compute_taxes_and_transfers, create_synthetic_data, set_up_policy_environment)' }], + typeVariables: [`${CODEGEN_PREFIX}T`], +}; + export class SafeDsPythonGenerator { private readonly builtinAnnotations: SafeDsAnnotations; private readonly nodeMapper: SafeDsNodeMapper; diff --git a/packages/ttsl-lang/src/language/grammar/safe-ds.langium b/packages/ttsl-lang/src/language/grammar/safe-ds.langium index cc720bdd..1b4d241c 100644 --- a/packages/ttsl-lang/src/language/grammar/safe-ds.langium +++ b/packages/ttsl-lang/src/language/grammar/safe-ds.langium @@ -643,12 +643,12 @@ TslExpression returns TslExpression: interface TslAggregation extends TslExpression{ function: TslExpression - data: TslExpression[] + data: TslExpression groupedBy: TslGroupedBy } TslAggregation returns TslAggregation: - 'aggregate' function=TslExpression 'of' data+=TslExpression (',' data+=TslExpression)* groupedBy=TslGroupedBy + 'aggregate' function=TslExpression 'of' data=TslExpression groupedBy=TslGroupedBy ; interface TslLambda extends TslCallable, TslExpression {} From 5f00c7f19fbdcbe4b7da7d03f02953d81cffc374 Mon Sep 17 00:00:00 2001 From: methr0 Date: Mon, 6 May 2024 18:39:48 +0200 Subject: [PATCH 012/183] add Aggregation to generateExpression --- .../src/language/generation/safe-ds-python-generator.ts | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts b/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts index 7e5a8a50..0ce569fa 100644 --- a/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts +++ b/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts @@ -1029,6 +1029,11 @@ export class SafeDsPythonGenerator { this.getInternalReferenceNeededImport(expression, declaration); frame.addImport(referenceImport); return traceToNode(expression)(referenceImport?.alias || this.getPythonNameOrDefault(declaration)); + } else if (isTslAggregation(expression)) { + frame.addUtility(UTILITY_AGGREGATION); + return expandTracedToNode(expression)`${traceToNode( + expression + )(UTILITY_AGGREGATION.name)}(${'dataframe'}, '${expression.data.toString()}', '${expression.groupedBy.id.toString()}', '${expression.function.toString()}')`; } /* c8 ignore next 2 */ throw new Error(`Unknown expression type: ${expression.$type}`); From 3b161aa330ef88cea01c5b7d0769a308bdea85ef Mon Sep 17 00:00:00 2001 From: methr0 Date: Mon, 6 May 2024 18:44:36 +0200 Subject: [PATCH 013/183] aggregate should only have one data instead of a list of data --- docs/language/common/aggregations.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/language/common/aggregations.md b/docs/language/common/aggregations.md index 51b5a4be..f053a1e5 100644 --- a/docs/language/common/aggregations.md +++ b/docs/language/common/aggregations.md @@ -3,7 +3,7 @@ To _aggregate_ [data][data] [grouped by][grouped by] an [ID][id] over a [function][functions] we can use the aggregation expression: ```ttsl -aggregate sum of salery, taxes groupedBy hh_id +aggregate sum of taxes groupedBy hh_id ``` Let's break down the syntax: @@ -11,7 +11,7 @@ Let's break down the syntax: - The keyword `#!ttsl aggregate`. - The [function][functions] to be executed on the grouped values (here `#!ttsl sum`). - The keyword `#!ttsl of`. -- A [List][List] of [data][data] separated by a comma (here `#!ttsl salery, taxes`). +- The [data][data] that is aggregated (here `#!ttsl taxes`). - The [grouped by][grouped by] modifier (here with the id `#!ttsl hh_id`). An aggregation can be executed on one or multiple data values that are all connected to the same given [ID][id]. From 0d3e2a21e181178609e433bb87086fa72f341f03 Mon Sep 17 00:00:00 2001 From: methr0 Date: Tue, 7 May 2024 16:43:50 +0200 Subject: [PATCH 014/183] utility function for creating a constants class --- .../generation/safe-ds-python-generator.ts | 31 +++++++++++++++++++ 1 file changed, 31 insertions(+) diff --git a/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts b/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts index 0ce569fa..b676a1a2 100644 --- a/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts +++ b/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts @@ -3,6 +3,7 @@ import { CompositeGeneratorNode, expandToNode, expandTracedToNode, + IndentNode, joinToNode, joinTracedToNode, NL, @@ -200,6 +201,36 @@ const UTILITY_AGGREGATION: UtilityFunction = { typeVariables: [`${CODEGEN_PREFIX}T`], }; +const UTILITY_CONSTANTS: UtilityFunction = { + name: `${CODEGEN_PREFIX}constants`, + code: expandToNode`class ${CODEGEN_PREFIX}constants():` + .appendNewLine() + .indent(indentingNode => + indentingNode.append( + 'def __init__(self, dictionary: dict):' + ).appendNewLine() + .indent({ + indentedChildren: ['self.dict = dictionary'], + indentation: PYTHON_INDENT + }).appendNewLine() + .append('def getValue(self, date):').appendNewLine() + .indent(indentingNode => + indentingNode.append( + 'for key in self.dict:' + ).appendNewLine() + .indent(indentingNode => + indentingNode.append( + 'if key <= date:' + ).appendNewLine() + .indent({ + indentedChildren: ['result = self.dict[key]'], + indentation: PYTHON_INDENT + })).appendNewLine() + .append('return result'))), + imports: [{ importPath: 'typing', declarationName: 'Any' }], + typeVariables: [`${CODEGEN_PREFIX}T`], +}; + export class SafeDsPythonGenerator { private readonly builtinAnnotations: SafeDsAnnotations; private readonly nodeMapper: SafeDsNodeMapper; From b73226da2cc8deecfb8da3705d71a8eb7d2384a9 Mon Sep 17 00:00:00 2001 From: methr0 Date: Wed, 8 May 2024 17:59:00 +0200 Subject: [PATCH 015/183] generating constants with utilityFunction, changed constructure of constants with different values in langium file --- .../generation/safe-ds-python-generator.ts | 78 ++++++++++++++++++- .../src/language/grammar/safe-ds.langium | 15 +++- 2 files changed, 88 insertions(+), 5 deletions(-) diff --git a/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts b/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts index b676a1a2..f2673dc0 100644 --- a/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts +++ b/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts @@ -76,6 +76,9 @@ import { TslFunctionBlock, isTslAggregation, isTslTimespanStatement, + isTslConstant, + TslConstant, + TslTimespan, } from '../generated/ast.js'; import { isInStubFile, isStubFile } from '../helpers/fileExtensions.js'; import { IdManager } from '../helpers/idManager.js'; @@ -202,8 +205,8 @@ const UTILITY_AGGREGATION: UtilityFunction = { }; const UTILITY_CONSTANTS: UtilityFunction = { - name: `${CODEGEN_PREFIX}constants`, - code: expandToNode`class ${CODEGEN_PREFIX}constants():` + name: `${CODEGEN_PREFIX}ClassConstants`, + code: expandToNode`class ${CODEGEN_PREFIX}ClassConstants():` .appendNewLine() .indent(indentingNode => indentingNode.append( @@ -398,6 +401,11 @@ export class SafeDsPythonGenerator { .map((funct) => this.generateFunction(funct, importSet, utilitySet, typeVariableSet, generateOptions), ); + const constants = getModuleMembers(module) + .filter(isTslConstant) + .map((constant) => + this.generateConstant(constant, importSet, utilitySet, typeVariableSet, generateOptions), + ); const imports = this.generateImports(Array.from(importSet.values())); const output = new CompositeGeneratorNode(); output.trace(module); @@ -452,6 +460,16 @@ export class SafeDsPythonGenerator { output.append(joinToNode(functions, (funct) => funct, { separator: SPACING })); output.appendNewLine(); } + if (constants.length > 0) { + output.appendNewLineIf( + imports.length > 0 || typeVariableSet.size > 0 || utilitySet.size > 0 || segments.length > 0, + ); + output.append('# Constants --------------------------------------------------------------------'); + output.appendNewLine(); + output.appendNewLine(); + output.append(joinToNode(constants, (constant) => constant, { separator: SPACING })); + output.appendNewLine(); + } return output; } @@ -536,6 +554,62 @@ export class SafeDsPythonGenerator { )!; } + private generateConstant( + constant: TslConstant, + importSet: Map, + utilitySet: Set, + typeVariableSet: Set, + generateOptions: GenerateOptions, + ): CompositeGeneratorNode | undefined{ + const infoFrame = new GenerationInfoFrame( + importSet, + utilitySet, + typeVariableSet, + true, + generateOptions.targetPlaceholder, + generateOptions.disableRunnerIntegration, + ); + infoFrame.addUtility(UTILITY_CONSTANTS); + + if(constant.value != null){ + return expandTracedToNode(constant)`${traceToNode( + constant + )(UTILITY_CONSTANTS.name)}({'empty': ${constant.value}})` + } else if (constant.timespanValueEntries != null){ + return expandTracedToNode(constant)`${constant.name}Dict = {${joinTracedToNode(constant, 'timespanValueEntries')( + constant.timespanValueEntries, + (entry) => + expandTracedToNode(entry)`${traceToNode( + entry, + 'timespan', + )(this.generateDateString(entry.timespan, infoFrame))}: ${traceToNode( + entry, + 'value', + )(this.generateExpression(entry.value, infoFrame))}`, + { separator: ', ' }, + )}}`.appendNewLine() + .append(expandTracedToNode(constant)`${traceToNode( + constant + )(UTILITY_CONSTANTS.name)}(${constant.name}Dict)`) + } else{ + return undefined; + } + } + + private generateDateString( + timespan: TslTimespan, + frame: GenerationInfoFrame, + ): CompositeGeneratorNode | undefined { + if(timespan.start != null){ + return expandToNode`s${timespan.start.date.toUTCString()}` // add 's' to mark that it's the start of the timespan + } else if (timespan.end != null){ + return expandToNode`e${timespan.end.date.toUTCString()}` // add 'e' to mark that it's the end of the timespan + } else { + /* c8 ignore next 2 */ + return undefined; + } + } + private generateParameters( parameters: TslParameterList | undefined, frame: GenerationInfoFrame, diff --git a/packages/ttsl-lang/src/language/grammar/safe-ds.langium b/packages/ttsl-lang/src/language/grammar/safe-ds.langium index 1b4d241c..c0b7828f 100644 --- a/packages/ttsl-lang/src/language/grammar/safe-ds.langium +++ b/packages/ttsl-lang/src/language/grammar/safe-ds.langium @@ -340,9 +340,9 @@ TslFunctionBlock returns TslFunctionBlock: ; interface TslConstant extends TslModuleMember { - timespan: TslTimespan + timespanValueEntries?: TslTimespanValueEntry[] ^type: TslType - value: TslExpression + value?: TslExpression } fragment TslConstantFragment: @@ -350,7 +350,7 @@ fragment TslConstantFragment: 'constant' name=ID ':' ^type=TslType - ('{' (timespan=TslTimespan '=' value=TslExpression)*'}' | + ('{' (timespanValueEntries+=TslTimespanValueEntry)* '}' | '=' value=TslExpression) ';'? ; @@ -1065,6 +1065,15 @@ TslTimespanStatement returns TslTimespanStatement: timespan=TslTimespan '{' block=TslFunctionBlock '}' ; +interface TslTimespanValueEntry extends TslObject{ + timespan: TslTimespan + value: TslExpression +} + +TslTimespanValueEntry returns TslTimespanValueEntry: + timespan=TslTimespan '=' value=TslExpression +; + // ----------------------------------------------------------------------------- // Types // ----------------------------------------------------------------------------- From e70d787d27e70777c38a3257749be19722947a4b Mon Sep 17 00:00:00 2001 From: alex-senger Date: Sun, 12 May 2024 15:47:49 +0200 Subject: [PATCH 016/183] feat: add gesetzliche Rente --- src/resources/builtins/parameters.ttsl | 1648 ++++++++++++++++++++++++ 1 file changed, 1648 insertions(+) diff --git a/src/resources/builtins/parameters.ttsl b/src/resources/builtins/parameters.ttsl index 1dcfd75d..feb0df21 100644 --- a/src/resources/builtins/parameters.ttsl +++ b/src/resources/builtins/parameters.ttsl @@ -1821,4 +1821,1652 @@ const erziehungsgeldEndAlterKindBudgetsatz: Int { // ges_rente.yaml -------------------------------------------------------- +/** + * Teil des Nachhaltigkeitsfaktors in der Rentenanpassungsformel, welche das + * Verhältnis von Rentnern zu Beitragszahlern modifiziert + * Reference: §68 Abs. 4 S. 6 SGB VI + */ +const GesetzlicheRenteAlpha: Float { + from 1984-01-01 = 0.0 + from 2002-01-01 = 0.25 +} + +/** + * Teil des Riesterfaktors in der Rentenanpassungsformel + * Reference: §68 Abs. 5 SGB VI + */ +const gesetzlicheRenteAltersVorsorgeAnteil: Float { + from 1993-01-01 = 0.0 + from 2002-01-01 = 0.5 + from 2003-01-01 = 1.0 + from 2004-01-01 = 1.5 + from 2005-01-01 = 2.0 + from 2009-01-01 = 2.5 + from 2010-01-01 = 3.0 + from 2011-01-01 = 3.5 + from 2012-01-01 = 4.0 +} + +/** + * Summe der Beiträge zur Rentenversicherung aller rentenversicherungspflichtig + * Beschäftigten, der geringfügig Beschäftigten und der Bezieher von ALG. + * statistik-rente.de/drv + */ +const gesetzlicheRenteBeitragsvolumen: Dict { + from 1991-01-01 = 108688000 + from 1992-01-01 = 117359000 + from 1993-01-01 = 120559000 + from 1994-01-01 = 132938000 + from 1995-01-01 = 139921000 + from 1996-01-01 = 146160000 + from 1997-01-01 = 153658000 + from 1998-01-01 = 153763000 + from 1999-01-01 = 160506000 + from 2000-01-01 = 163367000 + from 2001-01-01 = 164694000 + from 2002-01-01 = 165481000 + from 2003-01-01 = 169425000 + from 2004-01-01 = 169399000 + from 2005-01-01 = 168954000 + from 2006-01-01 = 180545000 + from 2007-01-01 = 174726000 + from 2008-01-01 = 180028000 + from 2009-01-01 = 181572000 + from 2010-01-01 = 185288000 + from 2011-01-01 = 189850000 + from 2012-01-01 = 193687000 + from 2013-01-01 = 194334000 + from 2014-01-01 = 201647000 + from 2015-01-01 = 207317000 + from 2016-01-01 = 215422000 + from 2017-01-01 = 225244000 + from 2018-01-01 = 236404000 + from 2019-01-01 = 247949000 +} + +/** + * Regelaltersrente/ Standardrente + * Höhe einer abschlagsfreien Rente bei 45 Entgeltpunkten. Ergibt sich aus + * Multiplikation des Rentenwerts mit 45. statistik-rente.de/drv + * Reference: § 154 Abs. 3 Satz 1 Nr. 2 SGB VI + */ +const gesetzlicheRenteEckrente: Float { + from 1995-01-01 = 988.15 + from 1996-01-01 = 992.72 + from 1997-01-01 = 1009.1 + from 1998-01-01 = 1012.47 + from 1999-01-01 = 1026.62 + from 2000-01-01 = 1032.79 + from 2001-01-01 = 1051.99 + from 2002-01-01 = 1072.35 + from 2003-01-01 = 1081.79 + from 2004-01-01 = 1071.79 + from 2005-01-01 = 1063.41 + from 2006-01-01 = 1066.35 + from 2007-01-01 = 1067.8 + from 2008-01-01 = 1077.02 + from 2009-01-01 = 1100.84 + from 2010-01-01 = 1102.67 + from 2011-01-01 = 1109.91 + from 2012-01-01 = 1134.15 + from 2013-01-01 = 1135.71 + from 2014-01-01 = 1154.68 + from 2015-01-01 = 1174.96 + from 2016-01-01 = 1222.09 + from 2017-01-01 = 1242.58 + from 2018-01-01 = 1284.06 +} + +/** + * Durchschnittslohn + * Durchschnittsbruttolohn aller Arbeitnehmer:innen in einem Jahr + */ +const gesetzlicheRenteDurchschnittslohn: Float { + from 2005-01-01 = 28468.23 + from 2006-01-01 = 28673.22 + from 2007-01-01 = 28978.19 + from 2008-01-01 = 29262.71 + from 2009-01-01 = 29774.24 + from 2010-01-01 = 30086.57 + from 2011-01-01 = 30770.62 + from 2012-01-01 = 31452.49 + from 2013-01-01 = 31583.35 + from 2014-01-01 = 32313.66 + from 2015-01-01 = 33047.02 + from 2016-01-01 = 33608.42 +} + +/** + * Beitragspflichtiges Durchschnittsentgelt aller Versicherten + * Durchschnittsentgelt aller Versicherten im Sinne der deutschen Sozialversicherung. + * Dieses wird benötigt zur Berechnung der Entgeltpunkte. + */ +const gesetzlicheRenteBeitragspflichtigesDurchschnittsentgelt: Int { + from 2005-01-01 = 29202 + from 2006-01-01 = 29494 + from 2007-01-01 = 29951 + from 2008-01-01 = 30625 + from 2009-01-01 = 30506 + from 2010-01-01 = 31144 + from 2011-01-01 = 32100 + from 2012-01-01 = 33002 + from 2013-01-01 = 33659 + from 2014-01-01 = 34514 + from 2015-01-01 = 35363 + from 2016-01-01 = 36187 + from 2017-01-01 = 37077 + from 2018-01-01 = 38212 + from 2019-01-01 = 39301 + from 2020-01-01 = 39167 + from 2021-01-01 = 41541 + from 2022-01-01 = 38901 +} + +/** + * Umrechnung der Beitragsbemessungsgrundlagen des Beitrittgebietes + * Für die Berechnung der Entgeltpunkte wird das Einkommen im "Beitrittsgebiet" um + * diesen Faktor erhöht. + * Reference: §256a SGB VI and Anlage 10 SGB VI + */ +const gesetzlicheRenteUmrechnungEntgeltpBeitrittsgebiet: Float { + from 1945-01-01 = 1.0000 + from 1946-01-01 = 1.0000 + from 1947-01-01 = 1.0000 + from 1948-01-01 = 1.0000 + from 1949-01-01 = 1.0000 + from 1950-01-01 = 0.9931 + from 1951-01-01 = 1.0502 + from 1952-01-01 = 1.0617 + from 1953-01-01 = 1.0458 + from 1954-01-01 = 1.0185 + from 1955-01-01 = 1.0656 + from 1956-01-01 = 1.1029 + from 1957-01-01 = 1.1081 + from 1958-01-01 = 1.0992 + from 1959-01-01 = 1.0838 + from 1960-01-01 = 1.1451 + from 1961-01-01 = 1.2374 + from 1962-01-01 = 1.3156 + from 1963-01-01 = 1.3667 + from 1964-01-01 = 1.4568 + from 1965-01-01 = 1.5462 + from 1966-01-01 = 1.6018 + from 1967-01-01 = 1.5927 + from 1968-01-01 = 1.6405 + from 1969-01-01 = 1.7321 + from 1970-01-01 = 1.8875 + from 1971-01-01 = 2.0490 + from 1972-01-01 = 2.1705 + from 1973-01-01 = 2.3637 + from 1974-01-01 = 2.5451 + from 1975-01-01 = 2.6272 + from 1976-01-01 = 2.7344 + from 1977-01-01 = 2.8343 + from 1978-01-01 = 2.8923 + from 1979-01-01 = 2.9734 + from 1980-01-01 = 3.1208 + from 1981-01-01 = 3.1634 + from 1982-01-01 = 3.2147 + from 1983-01-01 = 3.2627 + from 1984-01-01 = 3.2885 + from 1985-01-01 = 3.3129 + from 1986-01-01 = 3.2968 + from 1987-01-01 = 3.2548 + from 1988-01-01 = 3.2381 + from 1989-01-01 = 3.2330 + from 1990-01-01 = 3.0707 + from 1990-06-01 = 2.3473 + from 1991-01-01 = 1.7235 + from 1992-01-01 = 1.4393 + from 1993-01-01 = 1.3197 + from 1994-01-01 = 1.2687 + from 1995-01-01 = 1.2317 + from 1996-01-01 = 1.2209 + from 1997-01-01 = 1.2089 + from 1998-01-01 = 1.2113 + from 1999-01-01 = 1.2054 + from 2000-01-01 = 1.2030 + from 2001-01-01 = 1.2003 + from 2002-01-01 = 1.1972 + from 2003-01-01 = 1.1943 + from 2004-01-01 = 1.1932 + from 2005-01-01 = 1.1827 + from 2006-01-01 = 1.1827 + from 2007-01-01 = 1.1841 + from 2008-01-01 = 1.1857 + from 2009-01-01 = 1.1712 + from 2010-01-01 = 1.1726 + from 2011-01-01 = 1.1740 + from 2012-01-01 = 1.1785 + from 2013-01-01 = 1.1762 + from 2014-01-01 = 1.1665 + from 2015-01-01 = 1.1502 + from 2016-01-01 = 1.1415 + from 2017-01-01 = 1.1374 + from 2018-01-01 = 1.1339 + from 2019-01-01 = 1.0840 + from 2020-01-01 = 1.0700 + from 2021-01-01 = 1.0560 + from 2022-01-01 = 1.0420 + from 2023-01-01 = 1.0280 + from 2024-01-01 = 1.0140 +} + +/** + * Rentenvolumen + * Gesamtvolumen der ausgezahlten Renten + */ +const gesetzlicheRenteGesamtesRentenvolumen: Int { + from 1991-01-01 = 117912000 + from 1992-01-01 = 130901000 + from 1993-01-01 = 141180000 + from 1994-01-01 = 152798000 + from 1995-01-01 = 162625000 + from 1996-01-01 = 168955000 + from 1997-01-01 = 174479000 + from 1998-01-01 = 180323800 + from 1999-01-01 = 184139000 + from 2000-01-01 = 190198000 + from 2001-01-01 = 195776000 + from 2002-01-01 = 202355000 + from 2003-01-01 = 207749000 + from 2004-01-01 = 210522000 + from 2005-01-01 = 211861000 + from 2006-01-01 = 212421000 + from 2007-01-01 = 213649000 + from 2008-01-01 = 216182000 + from 2009-01-01 = 220841000 + from 2010-01-01 = 224352000 + from 2011-01-01 = 225411000 + from 2012-01-01 = 229231000 + from 2013-01-01 = 232297000 + from 2014-01-01 = 238991000 + from 2015-01-01 = 249568000 + from 2016-01-01 = 259345000 + from 2017-01-01 = 286860000 + from 2018-01-01 = 277102000 + from 2019-01-01 = 291359000 +} + +/** + * Rentenwerte alte und neue Bundesländer + * Der aktuelle Rentenwert drückt den Betrag aus, der der monatlichen Rente für + * einen Entgeltpunkt entspricht. + * Reference: statistik-rente.de/drv, § 68 SGB VI + */ +const gesetzlicheRenteRentenwert: Dict { + from 1992-01-01 = { + west: 21.19, + ost: 12.05 + } + + from 1992-07-01 = { + west: 21.80, + ost: 13.59 + } + + from 1993-01-01 = { + west: 21.80, // deviation_from: previous + ost: 14.41 + } + + from 1993-07-01 = { + west: 22.75, + ost: 16.45 + } + + from 1994-01-01 = { + west: 22.75, // deviation_from: previous + ost: 17.05 + } + + from 1994-07-01 = { + west: 23.52, + ost: 17.63 + } + + from 1995-01-01 = { + west: 23.52, // deviation_from: previous + ost: 18.13 + } + + from 1995-07-01 = { + west: 23.64, + ost: 18.58 + } + + from 1996-01-01 = { + west: 23.64, // deviation_from: previous + ost: 19.39 + } + + from 1996-07-01 = { + west: 23.86, + ost: 19.62 + } + + from 1997-07-01 = { + west: 24.26, + ost: 20.71 + } + + from 1998-07-01 = { + west: 24.36, + ost: 20.90 + } + + from 1999-07-01 = { + west: 24.69, + ost: 21.48 + } + + from 2000-07-01 = { + west: 24.84, + ost: 21.61 + } + + from 2001-07-01 = { + west: 25.31, + ost: 22.06 + } + + from 2002-07-01 = { + west: 25.86, + ost: 22.70 + } + + from 2003-07-01 = { + west: 26.13, + ost: 22.97 + } + + from 2007-07-01 = { + west: 26.27, + ost: 23.09 + } + + from 2008-07-01 = { + west: 26.56, + ost: 23.34 + } + + from 2009-07-01 = { + west: 27.2, + ost: 24.13 + } + + from 2011-07-01 = { + west: 27.47, + ost: 24.37 + } + + from 2012-07-01 = { + west: 28.07, + ost: 24.92 + } + + from 2013-07-01 = { + west: 28.14, + ost: 25.74 + } + + from 2014-07-01 = { + west: 28.61, + ost: 26.39 + } + + from 2015-07-01 = { + west: 29.21, + ost: 27.05 + } + + from 2016-07-01 = { + west: 30.45, + ost: 28.66 + } + + from 2017-07-01 = { + west: 31.03, + ost: 29.69 + } + + from 2018-07-01 = { + west: 32.03, + ost: 30.69 + } + + from 2019-07-01 = { + west: 33.05, + ost: 31.89 + } + + from 2020-07-01 = { + west: 34.19, + ost: 33.23 + } + + from 2021-07-01 = { + west: 34.19, // deviation_from: previous + ost: 33.47 + } +} + +/** + * Höchstwert der Entgeltpunkte für Grundrente + * Konstante zur Bestimmung des Höchstwerts der durchschnittlichen Entgeltpunkte und + * des Effekts eines weiteren Monats an Grundrentenzeiten auf Höchstwert. + */ +const gesetzlicheRenteGrundrenteHöchstwert: Dict { + // Reference: § 76g Abs. 4 S. 3, 4 SGB VI + from 2021-01-01 = { + base: 0.0334, + increment: 0.001389, + } +} + +/** + * Zugangsfaktor bei Grundrente + * Der Zugangsfaktor für die Grundrente ist auf 1 begrenzt. + * Reference: § 77 Abs. 2 SGB VI + */ +const gesetzlicheRenteGrundrenteZugangsfaktorMax: Int { + from 2021-01-01 = 1 +} + +/** + * Grundrentenzeiten + * Minimal benötigte Grundrentenzeiten um zur Grundrente berechtigt zu sein und Zahl + * an Grundrentenzeiten ab der zusätzliche Monate an Grundrentenzeiten nicht + * berücksichtigt werden + */ +const gesetzlicheRenteGrundrenteZeiten: Dict { + // Reference: § 76g Abs. 4 S. 5,6 / Abs. 1 S. 1 SGB VI + from 2021-01-01 = { + min: 396, + max: 420, + } +} + +/** + * Einkommensanrechnung Grundrente für Personen ohne verheiratetem Partner + * Werte werden mit dem Rentenwert multipliziert, um Schwellen der + * Einkommensanrechnung des Grundrentenzuschlags zu ermitteln + * Reference: § 97a Abs. 4 S. 2, 4 SGB VI + */ +const gesetzlicheRenteGrundrenteEinkommensanrechnungSingle: Dict> { + // Reference: § 97a Abs. 4 S. 2, 4 SGB VI + from 2021-01-01 = { + 0: { + lower_threshold: -inf, + upper_threshold: 36.56, + rate_linear: 0, + intercept_at_lower_threshold: 0, + }, + 1: { + upper_threshold: 46.78, + rate_linear: 0.6, + }, + 2: { + upper_threshold: inf, + rate_linear: 1, + }, + } +} + +/** + * Einkommensanrechnung Grundrente für Personen mit verheiratetem Partner + * Werte werden mit dem Rentenwert multipliziert, um Schwellen der + * Einkommensanrechnung des Grundrentenzuschlags zu ermitteln + * Reference: § 97a Abs. 4 S. 2, 4 SGB VI + */ +const gesetzlicheRenteGrundrenteEinkommensanrechnungMarried: Dict> { + // Reference: § 97a Abs. 4 S. 2, 4 SGB VI + from 2021-01-01 = { + 0: { + lower_threshold: -inf, + upper_threshold: 57.03, + rate_linear: 0, + intercept_at_lower_threshold: 0, + }, + 1: { + upper_threshold: 67.27, + rate_linear: 0.6, + }, + 2: { + upper_threshold: inf, + rate_linear: 1, + }, + } +} + +/** + * Bonusfaktor aus Grundrente + * Faktor mit dem die durch die Grundrente zusätzlich erhaltenen Entgeltpunkte + * multipliziert werden. + */ +const gesetzlicheRenteGrundrenteFaktorBonus: Float { + // Reference: §§ 76g Abs. 4 S. 3, 4 SGB VI + from 2021-01-01 = 0.875 +} + +/** + * Veränderung des Zugangsfaktors pro Jahr + * Faktor um den sich der Zugangsfaktor für die staatliche Rente erhöht/senkt für + * jedes Jahr, das länger/kürzer gearbeitet wird + * Reference: §77 Abs. 2 Nr. 2 SGB VI + */ +const gesetzlicheRenteZugangsfaktorVeraenderungProJahr: Dict { + // Reference: §77 Abs. 2 Nr. 2 SGB VI + from 2001-01-01 = { + vorzeitiger_renteneintritt: 0.036, + späterer_renteneintritt: 0.06, + } +} + +/** + * Eintrittsalter für Regelaltersrente + * Stückweise lineare Funktion, die die Regelaltersgrenze angibt, bei der das + * Individuum mit seinem vollen Rentenanspruch in Rente gehen kann. Geht die Person + * früher oder später in Rente, ist der Zugangsfaktor und damit der Rentenanspruch + * höher oder niedriger, wenn keine Ausnahmeregelungen erfüllt sind. + * Reference: § 35 Satz 2 SGB VI + */ +const gesetzlicheRenteRegelaltersgrenze: Dict> { + from 1984-01-01 = { + 0: { + lower_threshold: -inf, + upper_threshold: 1946, + rate_linear: 0, + intercept_at_lower_threshold: 65, + }, + 1: { + upper_threshold: 1958, + rate_linear: 0.083333333, + }, + 2: { + upper_threshold: 1964, + rate_linear: 0.16666666, + }, + 3: { + upper_threshold: inf, + rate_linear: 0, + }, + } +} + +/** + * Eintrittsalter für Altersrente für Frauen + * Stückweise lineare Funktion, die die Altersgrenzen angibt, ab denen Frauen + * geboren vor 1952 in Rente gehen konnten. + * Reference: § 237a SGB VI + */ +const gesetzlicheRenteAltersgrenzeFrauen: Dict> { + from 1980-01-01 = { + 0: { + lower_threshold: -inf, + upper_threshold: 1939.916667, + rate_linear: 0, + intercept_at_lower_threshold: 60, + }, + 1: { + upper_threshold: 1944.916666666, + rate_linear: 1, + }, + 2: { + upper_threshold: 1951.916666666, // constant 65 + rate_linear: 0, + }, + 3: { + upper_threshold: 1952, + // since 1952 abolished - regelaltersgrenze applies - jump in theshold by 6 month + rate_linear: 6, + }, + 4: { + upper_threshold: 1958, + rate_linear: 0.083333333, + }, + 5: { + upper_threshold: 1964, + rate_linear: 0.16666666, + }, + 6: { + upper_threshold: inf, + rate_linear: 0, + }, + } +} + +/** + * Altersgrenze für vorzeitigen Bezug der Altersrente für Frauen. + * Frühestmögliches Alter ab dem die Altersrente für Frauen bezogen werden kann + * (mit Abschlägen). + * Reference: § 237a SGB VI + */ +const gesetzlicheRenteAltersgrenzeFrauenVorzeitig: Dict> { + from 1980-01-01 = { + 0: { + lower_threshold: -inf, + upper_threshold: 1952, + rate_linear: 0, + intercept_at_lower_threshold: 60, + }, + 1: { + upper_threshold: 1953, + rate_linear: 7, + }, + 2: { + upper_threshold: inf, // constant 67 + rate_linear: 0, + }, + } +} + +/** + * Kohorte Abschaffung Rente für Frauen + * Kohorte, ab der Rente für Frauen abgeschafft. + * Reference: § 237a SGB VI + */ +const gesetzlicheRenteFirstBirthyearWithoutRenteFrauen: Int { + from 1980-01-01 = 1952 +} + +/** + * Mindestpflichbeitragsjahre ab 40 für Rente für Frauen + ** Mindestpflichbeitragsjahre, nach dem 40. Lebensjahr, + * die für Rente für Frauen berechtigt. + * Wert ist als Jahr zu interpretieren. + * Reference: § 237a SGB VI + */ +const gesetzlicheRenteRenteFrauenPflichtbeitrag: Int { + from 1950-01-01 = 10 +} + +/** + * Altersgrenze für Altersrente wegen Arbeitslosigkeit (abschlagsfrei) + * Frühestmögliches Alter ab dem die Altersrente für Arbeitslose abschlagsfrei + * bezogen werden kann. + * Reference: § 237 SGB VI + */ +const gesetzlicheRenteAltersgrenzeArbeitslosigkeitAbschlagsfrei: Float | Dict> { + from 1980-01-01 = { + 0: { + scalar: 60.0, + }, + } + from 1992-01-01 = { + 0: { + scalar: 60.0, + }, + 1941: { + 1: 60.083333, + 2: 60.083333, + 3: 60.083333, + 4: 60.083333, + 5: 60.166667, + 6: 60.166667, + 7: 60.166667, + 8: 60.166667, + 9: 60.25, + 10: 60.25, + 11: 60.25, + 12: 60.25, + }, + 1942: { + 1: 60.333333, + 2: 60.333333, + 3: 60.333333, + 4: 60.333333, + 5: 60.416667, + 6: 60.416667, + 7: 60.416667, + 8: 60.416667, + 9: 60.5, + 10: 60.5, + 11: 60.5, + 12: 60.5, + }, + 1943: { + 1: 60.583333, + 2: 60.583333, + 3: 60.583333, + 4: 60.583333, + 5: 60.666667, + 6: 60.666667, + 7: 60.666667, + 8: 60.666667, + 9: 60.75, + 10: 60.75, + 11: 60.75, + 12: 60.75, + }, + 1944: { + 1: 60.833333, + 2: 60.833333, + 3: 60.833333, + 4: 60.833333, + 5: 61.916667, + 6: 61.916667, + 7: 61.916667, + 8: 61.916667, + 9: 61.0, + 10: 61, + 11: 61, + 12: 61, + }, + 1945: { + 1: 61.083333, + 2: 61.083333, + 3: 61.166667, + 4: 61.166667, + 5: 61.25, + 6: 61.25, + 7: 61.333333, + 8: 61.333333, + 9: 61.416667, + 10: 61.416667, + 11: 61.5, + 12: 61.5, + }, + 1946: { + 1: 61.583333, + 2: 61.583333, + 3: 61.666667, + 4: 61.666667, + 5: 61.75, + 6: 61.75, + 7: 61.833333, + 8: 61.833333, + 9: 61.916667, + 10: 61.916667, + 11: 62.0, + 12: 62.0, + }, + 1947: { + 1: 62.083333, + 2: 62.083333, + 3: 62.166667, + 4: 62.166667, + 5: 62.25, + 6: 62.25, + 7: 62.333333, + 8: 62.333333, + 9: 62.416667, + 10: 62.416667, + 11: 62.5, + 12: 62.5, + }, + 1948: { + 1: 62.583333, + 2: 62.583333, + 3: 62.666667, + 4: 62.666667, + 5: 62.75, + 6: 62.75, + 7: 62.833333, + 8: 62.833333, + 9: 62.916667, + 10: 62.916667, + 11: 63.0, + 12: 63.0, + }, + 1949: { + 1: 63.083333, + 2: 63.083333, + 3: 63.166667, + 4: 63.166667, + 5: 63.25, + 6: 63.25, + 7: 63.333333, + 8: 63.333333, + 9: 63.416667, + 10: 63.416667, + 11: 63.5, + 12: 63.5, + }, + 1950: { + 1: 63.583333, + 2: 63.583333, + 3: 63.666667, + 4: 63.666667, + 5: 63.75, + 6: 63.75, + 7: 63.833333, + 8: 63.833333, + 9: 63.916667, + 10: 63.916667, + 11: 64.0, + 12: 64.0, + }, + 1951: { + 1: 64.083333, + 2: 64.083333, + 3: 64.166667, + 4: 64.166667, + 5: 64.25, + 6: 64.25, + 7: 64.333333, + 8: 64.333333, + 9: 64.416667, + 10: 64.416667, + 11: 64.5, + 12: 64.5, + }, + 1952: { + 1: 64.583333, + 2: 64.583333, + 3: 64.666667, + 4: 64.666667, + 5: 64.75, + 6: 64.75, + 7: 64.833333, + 8: 64.833333, + 9: 64.916667, + 10: 64.916667, + 11: 65.0, + 12: 65.0, + }, + } + from 1996-07-29 = { + 0: { + scalar: 60.0, + }, + 1937: { + 1: 60.083333, + 2: 60.166667, + 3: 60.25, + 4: 60.333333, + 5: 60.416667, + 6: 60.5, + 7: 60.583333, + 8: 60.666667, + 9: 60.75, + 10: 60.833333, + 11: 60.916667, + 12: 61.0, + }, + 1938: { + 1: 61.083333, + 2: 61.166667, + 3: 61.25, + 4: 61.333333, + 5: 61.416667, + 6: 61.5, + 7: 61.583333, + 8: 61.666667, + 9: 61.75, + 10: 61.833333, + 11: 61.916667, + 12: 62.0, + }, + 1939: { + 1: 62.083333, + 2: 62.166667, + 3: 62.25, + 4: 62.333333, + 5: 62.416667, + 6: 62.5, + 7: 62.583333, + 8: 62.666667, + 9: 62.75, + 10: 62.833333, + 11: 62.916667, + 12: 63.0, + }, + 1940: { + 1: 63.0, + 2: 63.0, + 3: 63.0, + 4: 63.0, + 5: 63.0, + 6: 63.0, + 7: 63.0, + 8: 63.0, + 9: 63.0, + 10: 63.0, + 11: 63.0, + 12: 63.0, + }, + 1941: { + 1: 63.0, + 2: 63.0, + 3: 63.0, + 4: 63.0, + 5: 63.0, + 6: 63.0, + 7: 63.0, + 8: 63.0, + 9: 63.0, + 10: 63.0, + 11: 63.0, + 12: 63.0, + }, + 1942: { + 1: 63.0, + 2: 63.0, + 3: 63.0, + 4: 63.0, + 5: 63.0, + 6: 63.0, + 7: 63.0, + 8: 63.0, + 9: 63.0, + 10: 63.0, + 11: 63.0, + 12: 63.0, + }, + 1943: { + 1: 63.0, + 2: 63.0, + 3: 63.0, + 4: 63.0, + 5: 63.0, + 6: 63.0, + 7: 63.0, + 8: 63.0, + 9: 63.0, + 10: 63.0, + 11: 63.0, + 12: 63.0, + }, + 1944: { + 1: 63.0, + 2: 63.0, + 3: 63.0, + 4: 63.0, + 5: 63.0, + 6: 63.0, + 7: 63.0, + 8: 63.0, + 9: 63.0, + 10: 63.0, + 11: 63.0, + 12: 63.0, + }, + 1945: { + 1: 63.0, + 2: 63.0, + 3: 63.0, + 4: 63.0, + 5: 63.0, + 6: 63.0, + 7: 63.0, + 8: 63.0, + 9: 63.0, + 10: 63.0, + 11: 63.0, + 12: 63.0, + }, + 1946: { + 1: 63.0, + 2: 63.0, + 3: 63.0, + 4: 63.0, + 5: 63.0, + 6: 63.0, + 7: 63.0, + 8: 63.0, + 9: 63.0, + 10: 63.0, + 11: 63.0, + 12: 63.0, + }, + 1947: { + 1: 63.0, + 2: 63.0, + 3: 63.0, + 4: 63.0, + 5: 63.0, + 6: 63.0, + 7: 63.0, + 8: 63.0, + 9: 63.0, + 10: 63.0, + 11: 63.0, + 12: 63.0, + }, + 1948: { + 1: 63.0, + 2: 63.0, + 3: 63.0, + 4: 63.0, + 5: 63.0, + 6: 63.0, + 7: 63.0, + 8: 63.0, + 9: 63.0, + 10: 63.0, + 11: 63.0, + 12: 63.0, + }, + 1949: { + 1: 63.083333, + 2: 63.083333, + 3: 63.166667, + 4: 63.166667, + 5: 63.25, + 6: 63.25, + 7: 63.333333, + 8: 63.333333, + 9: 63.416667, + 10: 63.416667, + 11: 63.5, + 12: 63.5, + }, + 1950: { + 1: 63.583333, + 2: 63.583333, + 3: 63.666667, + 4: 63.666667, + 5: 63.75, + 6: 63.75, + 7: 63.833333, + 8: 63.833333, + 9: 63.916667, + 10: 63.916667, + 11: 64.0, + 12: 64.0, + }, + 1951: { + 1: 64.083333, + 2: 64.083333, + 3: 64.166667, + 4: 64.166667, + 5: 64.25, + 6: 64.25, + 7: 64.333333, + 8: 64.333333, + 9: 64.416667, + 10: 64.416667, + 11: 64.5, + 12: 64.5, + }, + 1952: { + 1: 64.583333, + 2: 64.583333, + 3: 64.666667, + 4: 64.666667, + 5: 64.75, + 6: 64.75, + 7: 64.833333, + 8: 64.833333, + 9: 64.916667, + 10: 64.916667, + 11: 65.0, + 12: 65.0, + }, + /* + Altersgrenze für Altersrente wegen Arbeitslosigkeit mit Vertrauensschutz + (abschlagsfrei). + Increase of full retirement age according to old law (RRG 1992) for individuals + covered under Vertrauensschutz. + Reference: § 237 SGB VI Abs. 4 + */ + vertrauensschutz: { + max_birthyear_old_regime: 1940, + entry_age_old_regime: 60.0, + 1941: { + 1: 60.083333, + 2: 60.083333, + 3: 60.083333, + 4: 60.083333, + 5: 60.166667, + 6: 60.166667, + 7: 60.166667, + 8: 60.166667, + 9: 60.25, + 10: 60.25, + 11: 60.25, + 12: 60.25, + }, + 1942: { + 1: 60.333333, + 2: 60.333333, + 3: 60.333333, + 4: 60.333333, + 5: 60.416667, + 6: 60.416667, + 7: 60.416667, + 8: 60.416667, + 9: 60.5, + 10: 60.5, + 11: 60.5, + 12: 60.5, + }, + 1943: { + 1: 60.583333, + 2: 60.583333, + 3: 60.583333, + 4: 60.583333, + 5: 60.666667, + 6: 60.666667, + 7: 60.666667, + 8: 60.666667, + 9: 60.75, + 10: 60.75, + 11: 60.75, + 12: 60.75, + }, + 1944: { + 1: 60.833333, + 2: 60.833333, + }, + }, + } + + // Reference: Wachstums- und Beschäftigungsförderungsgesetz 1996. BGBl. I S. 1461 1996 + // Increase of full retirement age from 60 to 65 for birth cohort 1937-1941. + from 1996-09-27 = { + max_birthyear_old_regime: 1936, + min_birthyear_new_regime: 1942, + entry_age_old_regime: 60.0, + entry_age_new_regime: 65.0, + 1937: { + 1: 60.083333, + 2: 60.166667, + 3: 60.25, + 4: 60.333333, + 5: 60.416667, + 6: 60.5, + 7: 60.583333, + 8: 60.666667, + 9: 60.75, + 10: 60.833333, + 11: 60.916667, + 12: 61.0, + }, + 1938: { + 1: 61.083333, + 2: 61.166667, + 3: 61.25, + 4: 61.333333, + 5: 61.416667, + 6: 61.5, + 7: 61.583333, + 8: 61.666667, + 9: 61.75, + 10: 61.833333, + 11: 61.916667, + 12: 62.0, + }, + 1939: { + 1: 62.083333, + 2: 62.166667, + 3: 62.25, + 4: 62.333333, + 5: 62.416667, + 6: 62.5, + 7: 62.583333, + 8: 62.666667, + 9: 62.75, + 10: 62.833333, + 11: 62.916667, + 12: 63.0, + }, + 1940: { + 1: 63.083333, + 2: 63.166667, + 3: 63.25, + 4: 63.333333, + 5: 63.416667, + 6: 63.5, + 7: 63.583333, + 8: 63.666667, + 9: 63.75, + 10: 63.833333, + 11: 63.916667, + 12: 64.0, + }, + 1941: { + 1: 64.083333, + 2: 64.166667, + 3: 64.25, + 4: 64.333333, + 5: 64.416667, + 6: 64.5, + 7: 64.583333, + 8: 64.666667, + 9: 64.75, + 10: 64.833333, + 11: 64.916667, + 12: 65.0, + }, + vertrauensschutz: { + /* + Altersgrenze für Altersrente wegen Arbeitslosigkeit mit Vertrauensschutz + (abschlagsfrei). + Increase of full retirement age according to old law (RRG 1992) for individuals + covered under Vertrauensschutz. + Reference: § 237 SGB VI Abs. 4 + */ + max_birthyear_old_regime: 1940, + entry_age_old_regime: 60.0, + 1941: { + 1: 60.083333, + 2: 60.083333, + 3: 60.083333, + 4: 60.083333, + 5: 60.166667, + 6: 60.166667, + 7: 60.166667, + 8: 60.166667, + 9: 60.25, + 10: 60.25, + 11: 60.25, + 12: 60.25, + }, + 1942: { + 1: 60.333333, + 2: 60.333333, + 3: 60.333333, + 4: 60.333333, + 5: 60.416667, + 6: 60.416667, + 7: 60.416667, + 8: 60.416667, + 9: 60.5, + 10: 60.5, + 11: 60.5, + 12: 60.5, + }, + 1943: { + 1: 60.583333, + 2: 60.583333, + 3: 60.583333, + 4: 60.583333, + 5: 60.666667, + 6: 60.666667, + 7: 60.666667, + 8: 60.666667, + 9: 60.75, + 10: 60.75, + 11: 60.75, + 12: 60.75, + }, + 1944: { + 1: 60.833333, + 2: 60.833333, + }, + }, + } +} + +/** + * Altersgrenze für vorzeitige Inanspruchnahme Altersrente wegen Arbeitslosigkeit + * Frühestmögliches Alter ab dem die Altersrente für Arbeitslose + * bezogen werden kann (mit Abschlägen), einschließlich Vertrauensschutz. + * Reference: § 237 SGB VI + */ +const gesetzlicheRenteAltersgrenzeArbeitslosigkeitVorzeitig: Float | Dict>{ + from 1980-01-01 = 60.0 + + // Increase of early retirement age from 60 to 62 for birth cohort 1949-1952. + // Reference: Rentenreformgesetz 1992. BGBl. I S. 2261 1989 § 41 + from 1992-01-01 = { + max_birthyear_old_regime: 1948, + min_birthyear_new_regime: 1953, + entry_age_old_regime: 60.0, + entry_age_new_regime: 62.0, + 1949: { + 1: 60.083333, + 2: 60.083333, + 3: 60.166667, + 4: 60.166667, + 5: 60.25, + 6: 60.25, + 7: 60.333333, + 8: 60.333333, + 9: 60.416667, + 10: 60.416667, + 11: 60.5, + 12: 60.5, + }, + 1950: { + 1: 60.583333, + 2: 60.583333, + 3: 60.666667, + 4: 60.666667, + 5: 60.75, + 6: 60.75, + 7: 60.833333, + 8: 60.833333, + 9: 60.916667, + 10: 60.916667, + 11: 61.0, + 12: 61.0, + }, + 1951: { + 1: 61.083333, + 2: 61.083333, + 3: 61.166667, + 4: 61.166667, + 5: 61.25, + 6: 61.25, + 7: 61.333333, + 8: 61.333333, + 9: 61.416667, + 10: 61.416667, + 11: 61.5, + 12: 61.5, + }, + 1952: { + 1: 61.583333, + 2: 61.583333, + 3: 61.666667, + 4: 61.666667, + 5: 61.75, + 6: 61.75, + 7: 61.833333, + 8: 61.833333, + 9: 61.916667, + 10: 61.916667, + 11: 62.0, + 12: 62.0, + }, + } + + // Increase of early retirement age from 60 to 65 for birth cohort 1937-1941. + // Reference: Wachstums- und Beschäftigungsförderungsgesetz 1996. BGBl. I S. 1461 1996 + from 1996-07-29 = { + max_birthyear_old_regime: 1948, + min_birthyear_new_regime: 1953, + entry_age_old_regime: 60.0, + entry_age_new_regime: 62.0, + 1949: { + 1: 60.083333, + 2: 60.083333, + 3: 60.166667, + 4: 60.166667, + 5: 60.25, + 6: 60.25, + 7: 60.333333, + 8: 60.333333, + 9: 60.416667, + 10: 60.416667, + 11: 60.5, + 12: 60.5, + }, + 1950: { + 1: 60.583333, + 2: 60.583333, + 3: 60.666667, + 4: 60.666667, + 5: 60.75, + 6: 60.75, + 7: 60.833333, + 8: 60.833333, + 9: 60.916667, + 10: 60.916667, + 11: 61.0, + 12: 61.0, + }, + 1951: { + 1: 61.083333, + 2: 61.083333, + 3: 61.166667, + 4: 61.166667, + 5: 61.25, + 6: 61.25, + 7: 61.333333, + 8: 61.333333, + 9: 61.416667, + 10: 61.416667, + 11: 61.5, + 12: 61.5, + }, + 1952: { + 1: 61.583333, + 2: 61.583333, + 3: 61.666667, + 4: 61.666667, + 5: 61.75, + 6: 61.75, + 7: 61.833333, + 8: 61.833333, + 9: 61.916667, + 10: 61.916667, + 11: 62.0, + 12: 62.0, + }, + vertrauensschutz: 60.0, + } + + // Increase of ERA was revoked. + // Reference: Wachstums- und Beschäftigungsförderungsgesetz 1996. BGBl. I S. 1461 1996 + from 1996-09-27 = 60.0, + + from 2004-07-26 = { + max_birthyear_old_regime: 1945, + min_birthyear_new_regime: 1949, + entry_age_old_regime: 60.0, + entry_age_new_regime: 63.0, + 1946: { + 1: 60.083333, + 2: 60.166667, + 3: 60.25, + 4: 60.333333, + 5: 60.416667, + 6: 60.5, + 7: 60.583333, + 8: 60.666667, + 9: 60.75, + 10: 60.833333, + 11: 60.916667, + 12: 61.0, + }, + 1947: { + 1: 61.083333, + 2: 61.166667, + 3: 61.25, + 4: 61.333333, + 5: 61.416667, + 6: 61.5, + 7: 61.583333, + 8: 61.666667, + 9: 61.75, + 10: 61.833333, + 11: 61.916667, + 12: 62.0, + }, + 1948: { + 1: 62.083333, + 2: 62.166667, + 3: 62.25, + 4: 62.333333, + 5: 62.416667, + 6: 62.5, + 7: 62.583333, + 8: 62.666667, + 9: 62.75, + 10: 62.833333, + 11: 62.916667, + 12: 63.0, + }, + vertrauensschutz: 60.0, + } + + // Same statutory retirement ages as before, but abolishment with birth cohort 1952. + // Reference: RV-Nachhaltigkeitsgesetz 2004 and RV-Altersgrenzenanpassungsgesetz 2007. + from 2007-04-30 = { + first_birthyear_without_rente_für_arbeitsl: 1952, + max_birthyear_old_regime: 1945, + min_birthyear_new_regime: 1949, + entry_age_old_regime: 60.0, + entry_age_new_regime: 63.0, + 1946: { + 1: 60.083333, + 2: 60.166667, + 3: 60.25, + 4: 60.333333, + 5: 60.416667, + 6: 60.5, + 7: 60.583333, + 8: 60.666667, + 9: 60.75, + 10: 60.833333, + 11: 60.916667, + 12: 61.0, + }, + 1947: { + 1: 61.083333, + 2: 61.166667, + 3: 61.25, + 4: 61.333333, + 5: 61.416667, + 6: 61.5, + 7: 61.583333, + 8: 61.666667, + 9: 61.75, + 10: 61.833333, + 11: 61.916667, + 12: 62.0, + }, + 1948: { + 1: 62.083333, + 2: 62.166667, + 3: 62.25, + 4: 62.333333, + 5: 62.416667, + 6: 62.5, + 7: 62.583333, + 8: 62.666667, + 9: 62.75, + 10: 62.833333, + 11: 62.916667, + 12: 63.0, + }, + vertrauensschutz: 60.0, + } +} + +/** + * Altersgrenze für vorzeitigen Bezug der Altersrente für langjährig Versicherte + * Frühestmögliches Alter ab dem die Altersrente für langjährig Versicherte + * bezogen werden kann (mit Abschlägen). + * Reference: § 236 SGB VI + */ +const gesetzlicheRenteAltersgrenzeLangjährigVersicherteVorzeitig: Float { + from 1980-01-01 = 63.0 +} + +/** + * Eintrittsalter für langjährig Versicherte - abschlagsfrei + * Stückweise lineare Funktion, die die Regelaltersgrenze angibt, bei der das + * Individuum mit seinem vollen Rentenanspruch in Rente gehen kann. Geht die Person + * früher oder später in Rente, ist der Zugangsfaktor und damit der Rentenanspruch + * höher oder niedriger, wenn keine Ausnahmeregelungen erfüllt sind. + * Reference: § 236 SGB VI + */ +const gesetzlicheRenteAltersgrenzeLangjährigVersicherteAbschlagsfrei: Dict> { + from 1984-01-01 = { + 0: { + lower_threshold: -inf, + upper_threshold: 1936.916666666, + rate_linear: 0, + intercept_at_lower_threshold: 63, + }, + 1: { + upper_threshold: 1938.916666666, + rate_linear: 1, + }, + 2: { + upper_threshold: 1948.916666666, + rate_linear: 0, + }, + 3: { + upper_threshold: 1949.25, + rate_linear: 1, + }, + 4: { + upper_threshold: 1950, // 1950.91667 + rate_linear: 0, + }, + 5: { + upper_threshold: 1958, + rate_linear: 0.083333333, + }, + 6: { + upper_threshold: 1964, + rate_linear: 0.16666666, + }, + 7: { + upper_threshold: inf, + rate_linear: 0, + }, + } +} + +/** + * Kohorte Angleichung Rente langjährig Versicherte + * Kohorte, ab der Altersgrenze für abschlagfreie Rente für langjährig Versicherte an + * Altersgrenze Regelaltersrente angeglichen wurde. + * Reference: § 237 SGB VI + */ +const gesetzlicheRenteAlignmentCohortLangjährigVersicherte: Int { + from 1980-01-01 = 1950 +} + +/** + * Eintrittsalter für besonders langjährig Versicherte - abschlagsfrei (Rente mit 63) + * Stückweise lineare Funktion, die die Regelaltersgrenze angibt, bei der das + * Individuum mit seinem vollen Rentenanspruch in Rente gehen kann. Geht die Person + * früher oder später in Rente, ist der Zugangsfaktor und damit der Rentenanspruch + * höher oder niedriger, wenn keine Ausnahmeregelungen erfüllt sind. + * Ab dem 1.7.2014 wurde die Altersgrenze für Kohorten bis 1952 auf 63 Jahre + * gesenkt (für nachfolgende Kohorten steigt sie um 2 Monate pro Kohorte bis + * 65). Personen, die vor dem 1.7.1951 (codiert als 1951.5) geboren wurden, + * waren zu diesem Zeitpunkt aber schon älter als 63 und hatten ensprechend ein + * höheres verfügbares Renteneintrittsalter. Nur Personen, die ab dem 1.7.1949 + * geboren wurden konnten überhaupt profitieren, da alle anderen schon über 65 + * waren. Für die Zugangsfaktor berechnung werden die tatsächlich verfügbaren + * Renteneintrittsalter benötigt. Daher brauchen wir für die inputs eine + * monatliche Präzision bis Kohorte 1952. + * Reference: § 38 SGB VI + */ +const gesetzlicheRenteAltersgrenzeBesondersLangjährigVersicherte: Dict> { + from 2012-01-01 = { + 0: { + lower_threshold: -inf, + upper_threshold: inf, + rate_linear: 0, + intercept_at_lower_threshold: 65, + }, + }, + from 2014-07-01 = { + 0: { + lower_threshold: -inf, + upper_threshold: 1949.5, + rate_linear: 0, + intercept_at_lower_threshold: 65, + }, + 1: { + upper_threshold: 1951.5, + rate_linear: -1, + }, + 2: { + upper_threshold: 1952, + rate_linear: 0, + }, + 3: { + upper_threshold: 1964, + rate_linear: 0.16666666, + }, + 4: { + upper_threshold: inf, + rate_linear: 0, + } + } +} + +/** + * Kohorte Implementierung Rente für besonders langjährig Versicherte + * Kohorte, ab der Rente für besonders langjährig Versicherte vollständig eingeführt. + * Reference: § 237 SGB VI + */ +const gesetzlicheRenteFirstBirthyearBesondersLangjährigVersicherte: Int { + from 2012-01-01 = 1952 +} + +// TODO: rounding +// TODO: threshholdswartezeiten +// grunds_im_alter.yaml -------------------------------------------------- From 054eab644218903565cc66c201c358b5d9288f43 Mon Sep 17 00:00:00 2001 From: methr0 Date: Mon, 13 May 2024 21:35:32 +0200 Subject: [PATCH 017/183] tests for functions, data and constants --- .../bad-missing name.tsltest} | 2 +- .../bad-missing type.tsltest} | 2 +- .../grammar/declarations/constants/bad-missing value.tsltest | 3 +++ .../good-with type and value.tsltest} | 2 +- .../bad-missing name.tsltest} | 2 +- .../bad-missing type.tsltest} | 2 +- .../good-with type and name.tsltest} | 2 +- .../declarations/functions/bad-missing parameter list.tsltest | 3 +++ .../{bad-static.sdstest => bad-missing parameter type.tsltest} | 2 +- .../functions/bad-unclosed constraint list.sdstest | 3 --- .../declarations/functions/bad-unclosed parameter list.tsltest | 3 +++ .../declarations/functions/bad-unclosed result list.tsltest | 3 +++ ...od-annotation call.sdstest => good-annotation call.tsltest} | 2 +- .../declarations/functions/good-with constraint list.sdstest | 3 --- ...parameter list.sdstest => good-with parameter list.tsltest} | 2 +- .../declarations/functions/good-with result list.tsltest | 3 +++ .../functions/good-with type parameter list.tsltest | 3 +++ 17 files changed, 27 insertions(+), 15 deletions(-) rename packages/ttsl-lang/tests/resources/grammar/declarations/{functions/bad-unclosed type parameter list.sdstest => constants/bad-missing name.tsltest} (54%) rename packages/ttsl-lang/tests/resources/grammar/declarations/{functions/bad-unclosed result list.sdstest => constants/bad-missing type.tsltest} (52%) create mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing value.tsltest rename packages/ttsl-lang/tests/resources/grammar/declarations/{functions/good-with result list.sdstest => constants/good-with type and value.tsltest} (51%) rename packages/ttsl-lang/tests/resources/grammar/declarations/{functions/bad-missing parameter list.sdstest => data/bad-missing name.tsltest} (61%) rename packages/ttsl-lang/tests/resources/grammar/declarations/{functions/bad-unclosed parameter list.sdstest => data/bad-missing type.tsltest} (60%) rename packages/ttsl-lang/tests/resources/grammar/declarations/{functions/good-with parameter list.sdstest => data/good-with type and name.tsltest} (61%) create mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing parameter list.tsltest rename packages/ttsl-lang/tests/resources/grammar/declarations/functions/{bad-static.sdstest => bad-missing parameter type.tsltest} (50%) delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed constraint list.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed parameter list.tsltest create mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed result list.tsltest rename packages/ttsl-lang/tests/resources/grammar/declarations/functions/{good-annotation call.sdstest => good-annotation call.tsltest} (70%) delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with constraint list.sdstest rename packages/ttsl-lang/tests/resources/grammar/declarations/functions/{good-with type parameter list.sdstest => good-with parameter list.tsltest} (55%) create mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with result list.tsltest create mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with type parameter list.tsltest diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed type parameter list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing name.tsltest similarity index 54% rename from packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed type parameter list.sdstest rename to packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing name.tsltest index 9f420446..53e2553c 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed type parameter list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing name.tsltest @@ -1,3 +1,3 @@ // $TEST$ syntax_error -fun myFunction<() +constant : Int = 1; diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed result list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing type.tsltest similarity index 52% rename from packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed result list.sdstest rename to packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing type.tsltest index 7cfa8c4f..e19c771e 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed result list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing type.tsltest @@ -1,3 +1,3 @@ // $TEST$ syntax_error -fun myFunction() -> ( +constant value: = 1 diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing value.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing value.tsltest new file mode 100644 index 00000000..80e9be97 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing value.tsltest @@ -0,0 +1,3 @@ +// $TEST$ syntax_error + +constant value: Int = diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with result list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/constants/good-with type and value.tsltest similarity index 51% rename from packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with result list.sdstest rename to packages/ttsl-lang/tests/resources/grammar/declarations/constants/good-with type and value.tsltest index 8a7ee30b..d85ef74f 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with result list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/constants/good-with type and value.tsltest @@ -1,3 +1,3 @@ // $TEST$ no_syntax_error -fun myFunction() -> () +constant value: Int = 1; diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing parameter list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/data/bad-missing name.tsltest similarity index 61% rename from packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing parameter list.sdstest rename to packages/ttsl-lang/tests/resources/grammar/declarations/data/bad-missing name.tsltest index 15819fa8..cc484719 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing parameter list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/data/bad-missing name.tsltest @@ -1,3 +1,3 @@ // $TEST$ syntax_error -fun myFunction +data : Int; diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed parameter list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/data/bad-missing type.tsltest similarity index 60% rename from packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed parameter list.sdstest rename to packages/ttsl-lang/tests/resources/grammar/declarations/data/bad-missing type.tsltest index 4a691258..fbd5e717 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed parameter list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/data/bad-missing type.tsltest @@ -1,3 +1,3 @@ // $TEST$ syntax_error -fun myFunction( +data Data1: diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with parameter list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/data/good-with type and name.tsltest similarity index 61% rename from packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with parameter list.sdstest rename to packages/ttsl-lang/tests/resources/grammar/declarations/data/good-with type and name.tsltest index 38ac8b66..6d064ba9 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with parameter list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/data/good-with type and name.tsltest @@ -1,3 +1,3 @@ // $TEST$ no_syntax_error -fun myFunction() +data Data1: Int; \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing parameter list.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing parameter list.tsltest new file mode 100644 index 00000000..9a97324f --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing parameter list.tsltest @@ -0,0 +1,3 @@ +// $TEST$ syntax_error + +function myFunction diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-static.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing parameter type.tsltest similarity index 50% rename from packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-static.sdstest rename to packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing parameter type.tsltest index db57e786..6daec909 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-static.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing parameter type.tsltest @@ -1,3 +1,3 @@ // $TEST$ syntax_error -static fun myFunction() +function myFunction(x:) diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed constraint list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed constraint list.sdstest deleted file mode 100644 index fb955879..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed constraint list.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -fun myFunction() where { diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed parameter list.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed parameter list.tsltest new file mode 100644 index 00000000..b76a08f4 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed parameter list.tsltest @@ -0,0 +1,3 @@ +// $TEST$ syntax_error + +function myFunction( diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed result list.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed result list.tsltest new file mode 100644 index 00000000..ebcbdd44 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed result list.tsltest @@ -0,0 +1,3 @@ +// $TEST$ syntax_error + +function myFunction(): ( diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-annotation call.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-annotation call.tsltest similarity index 70% rename from packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-annotation call.sdstest rename to packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-annotation call.tsltest index 1fcd9ca3..f556f0e6 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-annotation call.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-annotation call.tsltest @@ -3,4 +3,4 @@ package test @Annotation -fun myFunction() +function myFunction() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with constraint list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with constraint list.sdstest deleted file mode 100644 index faec38e5..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with constraint list.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -fun myFunction() where {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with type parameter list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with parameter list.tsltest similarity index 55% rename from packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with type parameter list.sdstest rename to packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with parameter list.tsltest index 912dae7a..36b85780 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with type parameter list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with parameter list.tsltest @@ -1,3 +1,3 @@ // $TEST$ no_syntax_error -fun myFunction<>() +function myFunction() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with result list.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with result list.tsltest new file mode 100644 index 00000000..54bc099f --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with result list.tsltest @@ -0,0 +1,3 @@ +// $TEST$ no_syntax_error + +function myFunction() -> () diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with type parameter list.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with type parameter list.tsltest new file mode 100644 index 00000000..d9f348cc --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with type parameter list.tsltest @@ -0,0 +1,3 @@ +// $TEST$ no_syntax_error + +function myFunction(x: Int) From 2c0bcee52808c3b384e17c9d52bad2401282c55d Mon Sep 17 00:00:00 2001 From: methr0 Date: Tue, 14 May 2024 13:14:12 +0200 Subject: [PATCH 018/183] update TimespanStatement generation --- .../generation/safe-ds-python-generator.ts | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts b/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts index f2673dc0..eb47c28f 100644 --- a/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts +++ b/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts @@ -803,8 +803,19 @@ export class SafeDsPythonGenerator { return joinTracedToNode(statement)(blockLambdaCode, (stmt) => stmt, { separator: NL, })!; - } else if (isTslTimespanStatement(statement)) { - return expandTracedToNode(statement)`if ${statement.timespan.start} <= date < ${statement.timespan.end}: + } else if (isTslTimespanStatement(statement)) { + var start = '' + var end = '' + if (statement.timespan.start != null){ + start = statement.timespan.start.date.toUTCString() + ' <=' + } + if (statement.timespan.end != null){ + end = '< ' + statement.timespan.end.date.toUTCString() + } + if (statement.timespan.start == null && statement.timespan.end == null){ + throw new Error(`Timespan has neither a start nor an end value`); + } + return expandTracedToNode(statement)`if ${start} date ${end}: ${this.generateFunctionBlock(statement.block, frame)}`; } else if (isTslConditionalStatement(statement)) { let elseBlock = new CompositeGeneratorNode From 3df119bc03da68c104bbde6dd1973178888f9fba Mon Sep 17 00:00:00 2001 From: methr0 Date: Tue, 14 May 2024 13:42:05 +0200 Subject: [PATCH 019/183] generate Data --- .../generation/safe-ds-python-generator.ts | 37 +++++++++++++++++++ 1 file changed, 37 insertions(+) diff --git a/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts b/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts index eb47c28f..22fc5f42 100644 --- a/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts +++ b/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts @@ -79,6 +79,8 @@ import { isTslConstant, TslConstant, TslTimespan, + isTslData, + TslData, } from '../generated/ast.js'; import { isInStubFile, isStubFile } from '../helpers/fileExtensions.js'; import { IdManager } from '../helpers/idManager.js'; @@ -406,6 +408,11 @@ export class SafeDsPythonGenerator { .map((constant) => this.generateConstant(constant, importSet, utilitySet, typeVariableSet, generateOptions), ); + const data = getModuleMembers(module) + .filter(isTslData) + .map((data) => + this.generateData(data, importSet, utilitySet, typeVariableSet, generateOptions), + ); const imports = this.generateImports(Array.from(importSet.values())); const output = new CompositeGeneratorNode(); output.trace(module); @@ -470,6 +477,16 @@ export class SafeDsPythonGenerator { output.append(joinToNode(constants, (constant) => constant, { separator: SPACING })); output.appendNewLine(); } + if (data.length > 0) { + output.appendNewLineIf( + imports.length > 0 || typeVariableSet.size > 0 || utilitySet.size > 0 || segments.length > 0, + ); + output.append('# Data --------------------------------------------------------------------'); + output.appendNewLine(); + output.appendNewLine(); + output.append(joinToNode(data, (data) => data, { separator: SPACING })); + output.appendNewLine(); + } return output; } @@ -610,6 +627,26 @@ export class SafeDsPythonGenerator { } } + private generateData( + data: TslData, + importSet: Map, + utilitySet: Set, + typeVariableSet: Set, + generateOptions: GenerateOptions, + ): CompositeGeneratorNode{ + const infoFrame = new GenerationInfoFrame( + importSet, + utilitySet, + typeVariableSet, + true, + generateOptions.targetPlaceholder, + generateOptions.disableRunnerIntegration, + ); + infoFrame.addUtility(UTILITY_CONSTANTS); + + return expandToNode`${data.name} = ${data.type}()` + } + private generateParameters( parameters: TslParameterList | undefined, frame: GenerationInfoFrame, From 07f80e2d959639f0e0955a5607b0b369ab994416 Mon Sep 17 00:00:00 2001 From: alex-senger Date: Tue, 14 May 2024 14:39:54 +0200 Subject: [PATCH 020/183] feat: add GrundsicherungImAlter --- src/resources/builtins/parameters.ttsl | 276 +++++++++++++++++++++++++ 1 file changed, 276 insertions(+) diff --git a/src/resources/builtins/parameters.ttsl b/src/resources/builtins/parameters.ttsl index feb0df21..182101fb 100644 --- a/src/resources/builtins/parameters.ttsl +++ b/src/resources/builtins/parameters.ttsl @@ -3470,3 +3470,279 @@ const gesetzlicheRenteFirstBirthyearBesondersLangjährigVersicherte: Int { // TODO: threshholdswartezeiten // grunds_im_alter.yaml -------------------------------------------------- + +--- +vermögensfreibetrag: + name: + de: Schonvermögen für Grundsicherung im Alter + en: Allowed amount of wealth for Grundsicherung im Alter + description: + de: >- + Ab dieser Vermögensschwelle besteht kein Anspruch auf Grundsicherung im Alter / + bei Erwerbsminderung. + en: >- + There is no entitlement to Grundsicherung im Alter / bei Erwerbsminderung if + assets exceed this threshold. + unit: Euro + reference: >- + § 1 Verordnung zur Durchführung des § 90 Abs. 2 Nr. 9 des Zwölften Buches + Sozialgesetzbuch + 1984-01-01: + adult: 0 + child: 0 + 2003-01-01: + adult: 2600 + child: 0 + 2017-04-01: + adult: 5000 + child: 500 +ges_rente_anr_frei: + name: + de: Anrechnungsfreier Anteil der staatlichen Rente (bei mind. 33 Grundrentenzeiten) + en: >- + Public pension share not subject to transfer withdrawal (if at least 33 + Grundrentenzeiten) + description: + de: >- + Anrechnungsfreie Anteile staatliche Rente wenn mindestens 33 Jahre + Grundrentenzeiten erreicht wurden. + en: >- + Public pension shares not subject to transfer withdrawal for subjects whose + Grundrentenzeiten exceeds 33 years. + unit: Share + type: piecewise_linear + 1984-01-01: + reference: No income could be deducted + 0: + lower_threshold: -inf + upper_threshold: inf + rate: 0 + intercept_at_lower_threshold: 0 + 2021-01-01: + reference: § 82a Abs. 1 und 2 SGB XII + 0: + lower_threshold: -inf + upper_threshold: 0 + rate: 0 + intercept_at_lower_threshold: 0 + 1: + lower_threshold: 0 + upper_threshold: 100 + rate: 1 + 2: + upper_threshold: inf + rate: 0.3 +kapitaleink_anr_frei: + name: + de: Freibetrag des Kapitaleinkommens für Grundsicherung + en: Amount of capital income not subject to transfer withdrawal + description: + de: >- + Nur das Kapitaleinkommens, das über diesem Freibetrag liegt, wird auf die + Grundsicherung im Alter angerechnet. The reference is § 82 SGB XII Abs. 2. + en: >- + Only the capital income above the threshold is considered for the calculation of + the Grundsicherung im Alter. + unit: Euro + reference_period: Year + 1984-01-01: + scalar: 0 + note: null + 2016-01-01: + reference: § 43 SGB XII Abs. 2 + scalar: 26 +erwerbseink_anr_frei: + name: + de: Anrechnungsfreier Anteil des Erwerbseinkommens für Grundsicherung + en: Income shares not subject to transfer withdrawal + description: + de: >- + Anteil des Erwerbseinkommens, welcher bei der Berechnung der Grundsicherung nicht + zum Einkommen addiert wird. + en: >- + Share of income, which is not added to the total income when calculating the + Grundsicherung. + unit: Share + reference: § 82 SGB XII Abs. 3 + 1984-01-01: + scalar: 0 + note: Unclear how it was handled before 2005 + 2005-01-01: + scalar: 0.3 +priv_rente_anr_frei: + name: + de: Anrechnungsfreie Anteile der privaten Rente für Grundsicherung + en: Private pension shares not subject to transfer withdrawal + description: + de: >- + Anteil der privaten Rente, welcher bei der Berechnung der Grundsicherung nicht zum + Einkommen addiert wird. + en: >- + Share of privat pension, which is not added to total income when calculating the + Grundsicherung. + unit: Share + type: piecewise_linear + reference: § 82 SGB XII Abs. 4 + 1984-01-01: + reference: Unclear how it was handled before 2005 + 0: + lower_threshold: -inf + upper_threshold: inf + rate: 0 + intercept_at_lower_threshold: 0 + 2005-01-01: + 0: + lower_threshold: -inf + upper_threshold: 0 + rate: 0 + intercept_at_lower_threshold: 0 + 1: + lower_threshold: 0 + upper_threshold: 100 + rate: 1 + 2: + upper_threshold: inf + rate: 0.3 +mehrbedarf_schwerbeh_g: + name: + de: Mehrbedarf bei Schwerbehinderung + en: Additional requirement when severely disabled + description: + de: >- + Dieser Prozentanteil des Regelbedarfs wird Menschen mit Schwerbehindertenausweis + mit Merkzeichen G, die Grundsicherung im Alter oder bei Erwerbsminderung bekommen, + als Mehrbedarf anerkannt. + en: >- + This percentage of the normal requirement is added as an additional requirement + for someone who has a severly disabled ID card which shows the code 'G' and is + entitled to the Grundsicherung. + unit: Percent + reference: § 30 Abs. 1 SGB XII, https://www.buzer.de/gesetz/3415/al0-3758.htm + 2006-12-07: + scalar: 0.17 + +/** + * Schonvermögen für Grundsicherung im Alter + * Ab dieser Vermögensschwelle besteht kein Anspruch auf Grundsicherung im Alter / + * bei Erwerbsminderung. + * Reference: § 1 Verordnung zur Durchführung des § 90 Abs. 2 Nr. 9 des Zwölften Buches + * Sozialgesetzbuch + */ +const grundsicherungImAlterVermoegensfreibetrag: Dict { + from 1984-01-01: { + adult: 0, + child: 0, + }, + from 2003-01-01: { + adult: 2600, + child: 0, + }, + from 2017-04-01: { + adult: 5000, + child: 500, + }, +} + +/** + * Anrechnungsfreier Anteil der staatlichen Rente (bei mind. 33 Grundrentenzeiten) + * Anrechnungsfreie Anteile staatliche Rente wenn mindestens 33 Jahre + * Grundrentenzeiten erreicht wurden. + */ +const grundsicherungImAlterGesetzlicheRenteAnrechnungsfrei: Dict> { + from 1984-01-01: { + 0: { + lower_threshold: -inf, + upper_threshold: inf, + rate: 0, + intercept_at_lower_threshold: 0, + }, + }, + from 2021-01-01: { + 0: { + lower_threshold: -inf, + upper_threshold: 0, + rate: 0, + intercept_at_lower_threshold: 0, + }, + 1: { + lower_threshold: 0, + upper_threshold: 100, + rate: 1, + }, + 2: { + upper_threshold: inf, + rate: 0.3, + }, + }, +} + +/** + * Freibetrag des Kapitaleinkommens für Grundsicherung + * Nur das Kapitaleinkommens, das über diesem Freibetrag liegt, wird auf die + * Grundsicherung im Alter angerechnet. The reference is § 82 SGB XII Abs. 2. + */ +const grundsicherungImAlterKapitaleinkommensfreibetrag: Int { + from 1984-01-01 = 0 + + // Reference: § 43 SGB XII Abs. 2 + from 2016-01-01 = 26 +} + +/** + * Anrechnungsfreier Anteil des Erwerbseinkommens für Grundsicherung + * Anteil des Erwerbseinkommens, welcher bei der Berechnung der Grundsicherung nicht + * zum Einkommen addiert wird. + * Reference: § 82 SGB XII Abs. 3 + */ +const grundsicherungImAlterErwerbseinkommensfreibetrag: Float { + // Unclear how it was handled before 2005 + from 1984-01-01 = 0 + + from 2005-01-01 = 0.3 +} + +/** + * Anrechnungsfreie Anteile der privaten Rente für Grundsicherung + * Anteil der privaten Rente, welcher bei der Berechnung der Grundsicherung nicht zum + * Einkommen addiert wird. + * Reference: § 82 SGB XII Abs. 4 + */ +const grundsicherungImAlterPrivateRenteAnrechnungsfrei: Dict> { + from 1984-01-01: { + // Unclear how it was handled before 2005, + 0: { + lower_threshold: -inf, + upper_threshold: inf, + rate: 0, + intercept_at_lower_threshold: 0, + }, + }, + from 2005-01-01: { + 0: { + lower_threshold: -inf, + upper_threshold: 0, + rate: 0, + intercept_at_lower_threshold: 0, + }, + 1: { + lower_threshold: 0, + upper_threshold: 100, + rate: 1, + }, + 2: { + upper_threshold: inf, + rate: 0.3, + }, + }, +} + +/** + * Mehrbedarf bei Schwerbehinderung + * Dieser Prozentanteil des Regelbedarfs wird Menschen mit Schwerbehindertenausweis + * mit Merkzeichen G, die Grundsicherung im Alter oder bei Erwerbsminderung bekommen, + * als Mehrbedarf anerkannt. + * Reference: § 30 Abs. 1 SGB XII, https://www.buzer.de/gesetz/3415/al0-3758.htm + */ +const grundsicherungImAlterMehrbedarfSchwerbehinderung: Float { + from 2006-12-07 = 0.17 +} From c231ac7ad6b51f5d69e8f5d1002767ba81af63a7 Mon Sep 17 00:00:00 2001 From: methr0 Date: Tue, 14 May 2024 14:44:57 +0200 Subject: [PATCH 021/183] fix build --- .../src/language/grammar/safe-ds.langium | 28 +++++++++++++++---- 1 file changed, 22 insertions(+), 6 deletions(-) diff --git a/packages/ttsl-lang/src/language/grammar/safe-ds.langium b/packages/ttsl-lang/src/language/grammar/safe-ds.langium index 79698e7a..798092b4 100644 --- a/packages/ttsl-lang/src/language/grammar/safe-ds.langium +++ b/packages/ttsl-lang/src/language/grammar/safe-ds.langium @@ -329,19 +329,17 @@ fragment TslFunctionFragment: ; interface TslFunctionBlock extends TslBlock{ - timespans: TslTimespan[] + timespanStatement: TslTimespanStatement[] } TslFunctionBlock returns TslFunctionBlock: {TslFunctionBlock} - '{' ( statements+=TslStatement* - | timespans+=TslTimespan - '{' ( timespans+=TslTimespan statements+=TslStatement + '{' ( timespanStatement+=TslTimespanStatement | statements+=TslStatement)* - '}')* '}' + '}' ; -interface TslConstant extends TslModuleMember { +interface TslConstant extends TslModuleMember, TslDeclaration { timespan: TslTimespan ^type: TslType value: TslExpression @@ -1057,6 +1055,24 @@ TslTimespan returns TslTimespan: ('from' start=TslDate)? ('to' end=TslDate)? ; +interface TslTimespanStatement extends TslBlock, TslStatement{ + timespan: TslTimespan + block: TslFunctionBlock +} + +TslTimespanStatement returns TslTimespanStatement: + timespan=TslTimespan '{' block=TslFunctionBlock '}' +; + +interface TslTimespanValueEntry extends TslObject{ + timespan: TslTimespan + value: TslExpression +} + +TslTimespanValueEntry returns TslTimespanValueEntry: + timespan=TslTimespan '=' value=TslExpression +; + // ----------------------------------------------------------------------------- // Types // ----------------------------------------------------------------------------- From 28879cac82b67951771d6a35a610003d0a178831 Mon Sep 17 00:00:00 2001 From: methr0 Date: Tue, 14 May 2024 14:52:28 +0200 Subject: [PATCH 022/183] fix build --- packages/ttsl-lang/src/language/helpers/nodeProperties.ts | 2 +- packages/ttsl-lang/src/language/index.ts | 2 +- packages/ttsl-lang/src/language/safe-ds-module.ts | 4 ++-- .../src/language/scoping/safe-ds-scope-computation.ts | 2 +- .../src/language/workspace/safe-ds-settings-provider.ts | 4 ++-- 5 files changed, 7 insertions(+), 7 deletions(-) diff --git a/packages/ttsl-lang/src/language/helpers/nodeProperties.ts b/packages/ttsl-lang/src/language/helpers/nodeProperties.ts index 8c48bbc5..7e3554cd 100644 --- a/packages/ttsl-lang/src/language/helpers/nodeProperties.ts +++ b/packages/ttsl-lang/src/language/helpers/nodeProperties.ts @@ -84,7 +84,7 @@ export const hasAnnotationCallOf = ( }; export const isInternal = (node: TslDeclaration | undefined): boolean => { - return isTslSegment(node) && node.visibility === 'internal'; + return isTslSegment(node); }; export namespace Argument { diff --git a/packages/ttsl-lang/src/language/index.ts b/packages/ttsl-lang/src/language/index.ts index c4ad95b2..04bc5702 100644 --- a/packages/ttsl-lang/src/language/index.ts +++ b/packages/ttsl-lang/src/language/index.ts @@ -6,7 +6,7 @@ export { createSafeDsServices } from './safe-ds-module.js'; export { startLanguageServer } from './main.js'; // Language Metadata -export { SafeDsLanguageMetaData } from './generated/module.js'; +export { TSLLanguageMetaData } from './generated/module.js'; // AST export * as ast from './generated/ast.js'; diff --git a/packages/ttsl-lang/src/language/safe-ds-module.ts b/packages/ttsl-lang/src/language/safe-ds-module.ts index c45d65f9..090b6a76 100644 --- a/packages/ttsl-lang/src/language/safe-ds-module.ts +++ b/packages/ttsl-lang/src/language/safe-ds-module.ts @@ -13,7 +13,7 @@ import { SafeDsEnums, SafeDsImpurityReasons } from './builtins/safe-ds-enums.js' import { SafeDsCommentProvider } from './documentation/safe-ds-comment-provider.js'; import { SafeDsDocumentationProvider } from './documentation/safe-ds-documentation-provider.js'; import { SafeDsCallGraphComputer } from './flow/safe-ds-call-graph-computer.js'; -import { SafeDsGeneratedModule, SafeDsGeneratedSharedModule } from './generated/module.js'; +import { TSLGeneratedModule, SafeDsGeneratedSharedModule } from './generated/module.js'; import { SafeDsPythonGenerator } from './generation/safe-ds-python-generator.js'; import { SafeDsValueConverter } from './grammar/safe-ds-value-converter.js'; import { SafeDsNodeMapper } from './helpers/safe-ds-node-mapper.js'; @@ -194,7 +194,7 @@ export const createSafeDsServices = async function ( SafeDs: SafeDsServices; }> { const shared = inject(createDefaultSharedModule(context), SafeDsGeneratedSharedModule, SafeDsSharedModule); - const SafeDs = inject(createDefaultModule({ shared }), SafeDsGeneratedModule, SafeDsModule); + const SafeDs = inject(createDefaultModule({ shared }), TSLGeneratedModule, SafeDsModule); shared.ServiceRegistry.register(SafeDs); registerValidationChecks(SafeDs); diff --git a/packages/ttsl-lang/src/language/scoping/safe-ds-scope-computation.ts b/packages/ttsl-lang/src/language/scoping/safe-ds-scope-computation.ts index 57c60a52..35b86dd2 100644 --- a/packages/ttsl-lang/src/language/scoping/safe-ds-scope-computation.ts +++ b/packages/ttsl-lang/src/language/scoping/safe-ds-scope-computation.ts @@ -30,7 +30,7 @@ import { export class SafeDsScopeComputation extends DefaultScopeComputation { protected override exportNode(node: AstNode, exports: AstNodeDescription[], document: LangiumDocument): void { // Modules, pipelines, and private segments cannot be referenced from other documents - if (isTslModule(node) || isTslPipeline(node) || (isTslSegment(node) && node.visibility === 'private')) { + if (isTslModule(node) || isTslPipeline(node) || (isTslSegment(node))) { return; } diff --git a/packages/ttsl-lang/src/language/workspace/safe-ds-settings-provider.ts b/packages/ttsl-lang/src/language/workspace/safe-ds-settings-provider.ts index 737b15d4..9c3408b7 100644 --- a/packages/ttsl-lang/src/language/workspace/safe-ds-settings-provider.ts +++ b/packages/ttsl-lang/src/language/workspace/safe-ds-settings-provider.ts @@ -1,6 +1,6 @@ import { ConfigurationProvider } from 'langium'; import { SafeDsServices } from '../safe-ds-module.js'; -import { SafeDsLanguageMetaData } from '../generated/module.js'; +import { TSLLanguageMetaData } from '../generated/module.js'; export class SafeDsSettingsProvider { private readonly configurationProvider: ConfigurationProvider; @@ -27,7 +27,7 @@ export class SafeDsSettingsProvider { private async getValidationSettings(): Promise> { return ( - (await this.configurationProvider.getConfiguration(SafeDsLanguageMetaData.languageId, 'validation')) ?? {} + (await this.configurationProvider.getConfiguration(TSLLanguageMetaData.languageId, 'validation')) ?? {} ); } } From d847caf93fce3ac8b64f25166f8feaec4e6af2a1 Mon Sep 17 00:00:00 2001 From: methr0 Date: Wed, 15 May 2024 11:53:18 +0200 Subject: [PATCH 023/183] change comment in test files form `//` to `#` --- docs/development/call-graph-testing.md | 2 +- docs/development/generation-testing.md | 2 +- docs/development/grammar-testing.md | 4 +- .../development/partial-evaluation-testing.md | 6 +- docs/development/scoping-testing.md | 6 +- docs/development/typing-testing.md | 4 +- docs/development/validation-testing.md | 6 +- .../tests/helpers/testChecks.test.ts | 16 +- .../tests/helpers/testComments.test.ts | 6 +- .../ttsl-lang/tests/helpers/testComments.ts | 2 +- .../lsp/safe-ds-inlay-hint-provider.test.ts | 8 +- .../lsp/safe-ds-rename-provider.test.ts | 28 +-- .../call graph/annotation call.sdstest | 2 +- .../argument/block lambda.sdstest | 2 +- .../callable does not get called.sdstest | 2 +- .../argument/expression lambda.sdstest | 2 +- .../argument/function.sdstest | 2 +- .../argument/segment.sdstest | 2 +- .../block lambda call/basic.sdstest | 2 +- .../function call in nested lambda.sdstest | 2 +- .../body/function call.sdstest | 2 +- .../default value/call.sdstest | 2 +- .../default value/callable.sdstest | 2 +- .../default value/previous parameter.sdstest | 2 +- .../block lambda call/null safe.sdstest | 2 +- .../call graph/callable type call.sdstest | 2 +- .../call graph/callable/block lambda.sdstest | 2 +- .../call graph/callable/class.sdstest | 2 +- .../call graph/callable/enum variant.sdstest | 2 +- .../callable/expression lambda.sdstest | 2 +- .../call graph/callable/function.sdstest | 2 +- .../call graph/callable/segment.sdstest | 2 +- .../class call/argument/call.sdstest | 2 +- .../class call/argument/callable.sdstest | 2 +- .../class call/argument/other.sdstest | 2 +- .../call graph/class call/basic.sdstest | 2 +- .../class call/default value/call.sdstest | 2 +- .../class call/default value/callable.sdstest | 2 +- .../default value/previous parameter.sdstest | 2 +- .../call graph/class call/null safe.sdstest | 2 +- .../block lambda passed as argument.sdstest | 2 +- .../closure/block lambda returned.sdstest | 2 +- ...pression lambda passed as argument.sdstest | 2 +- .../expression lambda returned.sdstest | 2 +- ...ault value handling in entry point.sdstest | 2 +- .../enum variant call/argument/call.sdstest | 2 +- .../argument/callable.sdstest | 2 +- .../enum variant call/argument/other.sdstest | 2 +- .../enum variant call/basic.sdstest | 2 +- .../enum variant call/called twice.sdstest | 2 +- .../default value/call.sdstest | 2 +- .../default value/callable.sdstest | 2 +- .../default value/previous parameter.sdstest | 2 +- .../enum variant call/null safe.sdstest | 2 +- .../argument/block lambda.sdstest | 2 +- .../callable does not get called.sdstest | 2 +- .../argument/expression lambda.sdstest | 2 +- .../argument/function.sdstest | 2 +- .../argument/segment.sdstest | 2 +- .../expression lambda call/basic.sdstest | 2 +- .../function call in nested lambda.sdstest | 2 +- .../body/function call.sdstest | 2 +- .../default value/call.sdstest | 2 +- .../default value/callable.sdstest | 2 +- .../default value/previous parameter.sdstest | 2 +- .../expression lambda call/null safe.sdstest | 2 +- .../function call/argument/call.sdstest | 2 +- .../function call/argument/callable.sdstest | 2 +- .../function call/argument/other.sdstest | 2 +- .../call graph/function call/basic.sdstest | 2 +- .../function call/default value/call.sdstest | 2 +- .../default value/callable.sdstest | 2 +- .../default value/previous parameter.sdstest | 2 +- .../function call/instance method.sdstest | 2 +- .../function call/null safe.sdstest | 8 +- .../function call/static method.sdstest | 2 +- .../call graph/recursion/direct.sdstest | 6 +- .../recursion/not recursive.sdstest | 2 +- ...tive via function pointer argument.sdstest | 2 +- .../transitive via lambda argument.sdstest | 2 +- .../call graph/recursion/transitive.sdstest | 6 +- .../argument/block lambda.sdstest | 2 +- .../callable does not get called.sdstest | 2 +- .../argument/expression lambda.sdstest | 2 +- .../segment call/argument/function.sdstest | 2 +- .../segment call/argument/segment.sdstest | 2 +- .../call graph/segment call/basic.sdstest | 2 +- .../function call in nested lambda.sdstest | 2 +- .../segment call/body/function call.sdstest | 2 +- .../segment call/default value/call.sdstest | 2 +- .../default value/callable.sdstest | 2 +- .../default value/previous parameter.sdstest | 2 +- .../call graph/segment call/null safe.sdstest | 2 +- .../call graph/unresolved callable.sdstest | 2 +- .../formatting/modules/empty.sdstest | 4 +- .../input.sdstest | 2 +- .../input.sdstest | 2 +- .../partial/impure dependency/input.sdstest | 2 +- .../partial/pure dependency/input.sdstest | 2 +- .../partial/redundant impurity/input.sdstest | 2 +- .../bad-unclosed argument list.sdstest | 2 +- .../good-empty argument list.sdstest | 2 +- .../good-multiple arguments.sdstest | 2 +- .../good-named argument.sdstest | 2 +- .../good-no argument list.sdstest | 2 +- .../good-positional argument.sdstest | 2 +- .../bad-unclosed constraint list.sdstest | 2 +- .../bad-unclosed parameter list.sdstest | 2 +- .../annotations/good-annotation call.sdstest | 2 +- .../good-no parameter list.sdstest | 2 +- .../good-with constraint list.sdstest | 2 +- .../good-with parameter list.sdstest | 2 +- .../classes/attributes/good-annotated.sdstest | 2 +- .../classes/attributes/good-no type.sdstest | 2 +- .../classes/attributes/good-static.sdstest | 2 +- .../classes/attributes/good-with type.sdstest | 2 +- .../bad-empty parent type list.sdstest | 2 +- .../classes/bad-unclosed body.sdstest | 2 +- .../bad-unclosed constraint list.sdstest | 2 +- .../bad-unclosed parameter list.sdstest | 2 +- .../bad-unclosed type parameter list.sdstest | 2 +- .../classes/good-annotation call.sdstest | 2 +- .../classes/good-empty body.sdstest | 2 +- .../declarations/classes/good-minimal.sdstest | 2 +- .../good-multiple parent types.sdstest | 2 +- .../classes/good-one parent type.sdstest | 2 +- .../classes/good-with constraint list.sdstest | 2 +- .../classes/good-with parameter list.sdstest | 2 +- .../good-with type parameter list.sdstest | 2 +- .../good-annotated instance method.sdstest | 2 +- .../good-annotated static method.sdstest | 2 +- .../methods/good-instance method.sdstest | 2 +- .../methods/good-static method.sdstest | 2 +- .../good-annotated nested class.sdstest | 2 +- .../nested classes/good-nested-class.sdstest | 2 +- .../good-annotated nested enum.sdstest | 2 +- .../nested enums/good-nested enum.sdstest | 2 +- .../constants/bad-missing name.tsltest | 2 +- .../constants/bad-missing type.tsltest | 2 +- .../constants/bad-missing value.tsltest | 2 +- .../good-with type and value.tsltest | 2 +- .../constraints/bad-missing comma.sdstest | 2 +- .../constraints/good-empty.sdstest | 2 +- .../good-greater than constraint.sdstest | 2 +- ...-greater than or equals constraint.sdstest | 2 +- .../good-less than constraint.sdstest | 2 +- ...ood-less than or equals constraint.sdstest | 2 +- .../good-multiple constraints.sdstest | 2 +- .../data/bad-missing name.tsltest | 2 +- .../data/bad-missing type.tsltest | 2 +- .../data/good-with type and name.tsltest | 2 +- .../enums/bad-unclosed body.sdstest | 2 +- .../enums/good-annotation call.sdstest | 2 +- .../enums/good-empty body.sdstest | 2 +- .../declarations/enums/good-no body.sdstest | 2 +- .../enums/good-variants in body.sdstest | 2 +- .../bad-unclosed constraint list.sdstest | 2 +- .../bad-unclosed parameter list.sdstest | 2 +- .../variants/good-annotation call.sdstest | 2 +- .../variants/good-no parameter list.sdstest | 2 +- .../good-with constraint list.sdstest | 2 +- .../variants/good-with parameter list.sdstest | 2 +- .../bad-missing parameter list.tsltest | 2 +- .../bad-missing parameter type.tsltest | 2 +- .../bad-unclosed parameter list.tsltest | 2 +- .../bad-unclosed result list.tsltest | 2 +- .../functions/good-annotation call.tsltest | 2 +- .../good-with parameter list.tsltest | 2 +- .../functions/good-with result list.tsltest | 2 +- .../good-with type parameter list.tsltest | 2 +- .../bad-const before annotation.sdstest | 2 +- .../bad-double const modifier.sdstest | 2 +- .../parameters/bad-missing comma.sdstest | 2 +- .../good-annotated parameter.sdstest | 2 +- ...ood-const typed optional parameter.sdstest | 2 +- ...ood-const typed required parameter.sdstest | 2 +- ...d-const untyped optional parameter.sdstest | 2 +- ...d-const untyped required parameter.sdstest | 2 +- .../parameters/good-empty.sdstest | 2 +- .../good-multiple parameters.sdstest | 2 +- .../good-typed optional parameter.sdstest | 2 +- .../good-typed required parameter.sdstest | 2 +- .../good-untyped optional parameter.sdstest | 2 +- .../good-untyped required parameter.sdstest | 2 +- .../pipelines/bad-missing body.sdstest | 2 +- .../pipelines/bad-unclosed body.sdstest | 2 +- .../pipelines/good-annotation call.sdstest | 2 +- .../pipelines/good-empty body.sdstest | 2 +- .../pipelines/good-statements in body.sdstest | 2 +- .../results/bad-missing comma.sdstest | 2 +- .../results/good-annotated result.sdstest | 2 +- .../declarations/results/good-empty.sdstest | 2 +- .../results/good-multiple results.sdstest | 2 +- ...-one typed result (in parentheses).sdstest | 2 +- ...-one typed result (no parentheses).sdstest | 2 +- ...ne untyped result (no parentheses).sdstest | 2 +- ... untyped result (with parentheses).sdstest | 2 +- .../segments/bad-missing body.sdstest | 2 +- .../bad-missing parameter list.sdstest | 2 +- ... visibilities (internal, internal).sdstest | 2 +- ...o visibilities (internal, private).sdstest | 2 +- ...o visibilities (private, internal).sdstest | 2 +- ...wo visibilities (private, private).sdstest | 2 +- .../segments/bad-unclosed body.sdstest | 2 +- .../bad-unclosed parameter list.sdstest | 2 +- .../segments/bad-unclosed result list.sdstest | 2 +- .../segments/good-annotation call.sdstest | 2 +- .../segments/good-internal segment.sdstest | 2 +- .../segments/good-private segment.sdstest | 2 +- .../segments/good-statements in body.sdstest | 2 +- .../good-with constraint list.sdstest | 2 +- .../good-with parameter list and body.sdstest | 2 +- .../segments/good-with result list.sdstest | 2 +- .../type parameters/bad-missing comma.sdstest | 2 +- .../good-annotated type parameter.sdstest | 2 +- ...travariant optional type parameter.sdstest | 2 +- ...travariant required type parameter.sdstest | 2 +- ... covariant optional type parameter.sdstest | 2 +- ... covariant required type parameter.sdstest | 2 +- ... invariant optional type parameter.sdstest | 2 +- ... invariant required type parameter.sdstest | 2 +- .../type parameters/good-empty.sdstest | 2 +- .../good-multiple type parameters.sdstest | 2 +- ...travariant optional type parameter.sdstest | 2 +- ...travariant required type parameter.sdstest | 2 +- ... covariant optional type parameter.sdstest | 2 +- ... covariant required type parameter.sdstest | 2 +- ... invariant optional type parameter.sdstest | 2 +- ... invariant required type parameter.sdstest | 2 +- ...bad-addition without left operator.sdstest | 2 +- ...ad-addition without right operator.sdstest | 2 +- ...bad-division without left operator.sdstest | 2 +- ...ad-division without right operator.sdstest | 2 +- ...ltiplication without left operator.sdstest | 2 +- ...tiplication without right operator.sdstest | 2 +- .../bad-negation without operator.sdstest | 2 +- ...subtraction without right operator.sdstest | 2 +- .../good-addition.sdstest | 2 +- .../good-complex example.sdstest | 2 +- .../good-division.sdstest | 2 +- .../good-multiplication.sdstest | 2 +- .../good-negation.sdstest | 2 +- .../good-subtraction.sdstest | 2 +- .../block lambdas/bad-unclosed body.sdstest | 2 +- .../bad-unclosed parameter list.sdstest | 2 +- .../block lambdas/good-filled body.sdstest | 2 +- .../good-with parameter list and body.sdstest | 2 +- .../calls/bad-unclosed argument list.sdstest | 2 +- ...xed positional and named arguments.sdstest | 2 +- .../calls/good-named argument.sdstest | 2 +- .../calls/good-no arguments.sdstest | 2 +- .../expressions/calls/good-null safe.sdstest | 2 +- .../calls/good-positional argument.sdstest | 2 +- ...han or equal without left operator.sdstest | 2 +- ...an or equal without right operator.sdstest | 2 +- ...greater than without left operator.sdstest | 2 +- ...reater than without right operator.sdstest | 2 +- ...han or equal without left operator.sdstest | 2 +- ...an or equal without right operator.sdstest | 2 +- ...ad-less than without left operator.sdstest | 2 +- ...d-less than without right operator.sdstest | 2 +- .../good-greater than or equal.sdstest | 2 +- .../good-greater than.sdstest | 2 +- .../good-less than or equal.sdstest | 2 +- .../good-less than.sdstest | 2 +- .../bad-without left operand.sdstest | 2 +- .../bad-without right operand.sdstest | 2 +- .../elvis operators/good-basic.sdstest | 2 +- .../elvis operators/good-chained.sdstest | 2 +- .../bad-equal without left operator.sdstest | 2 +- .../bad-equal without right operator.sdstest | 2 +- ...ad-identical without left operator.sdstest | 2 +- ...d-identical without right operator.sdstest | 2 +- ...ad-not equal without left operator.sdstest | 2 +- ...d-not equal without right operator.sdstest | 2 +- ...ot identical without left operator.sdstest | 2 +- ...t identical without right operator.sdstest | 2 +- .../equality operators/good-equal.sdstest | 2 +- .../equality operators/good-identical.sdstest | 2 +- .../equality operators/good-not equal.sdstest | 2 +- .../good-not identical.sdstest | 2 +- .../bad-missing body.sdstest | 2 +- .../bad-unclosed parameter list.sdstest | 2 +- ...with parameter list and expression.sdstest | 2 +- .../good-complex chained expression.sdstest | 2 +- .../expressions/good-reference.sdstest | 2 +- .../indexed accesses/bad-no index.sdstest | 2 +- .../bad-unclosed square bracket.sdstest | 2 +- .../good-literal index.sdstest | 2 +- .../indexed accesses/good-null safe.sdstest | 2 +- .../good-reference index.sdstest | 2 +- .../lists/bad-unclosed square bracket.sdstest | 2 +- .../good-nested multiple elements.sdstest | 2 +- .../lists/good-nested one element.sdstest | 2 +- .../good-one level multiple elements.sdstest | 2 +- .../lists/good-one level one element.sdstest | 2 +- .../float/bad-no digits before dot.sdstest | 2 +- .../literals/float/good-basic example.sdstest | 2 +- ...ientific notation with lowercase e.sdstest | 2 +- ...ientific notation with uppercase e.sdstest | 2 +- .../expressions/literals/good-false.sdstest | 2 +- .../expressions/literals/good-null.sdstest | 2 +- .../expressions/literals/good-true.sdstest | 2 +- .../literals/int/good-leading zero.sdstest | 2 +- .../literals/int/good-multiple digits.sdstest | 2 +- .../literals/int/good-one digit.sdstest | 2 +- .../bad-single quotes as delimiters.sdstest | 2 +- .../string/bad-unclosed quote.sdstest | 2 +- .../string/good-basic content.sdstest | 2 +- ...sing template expression delimiter.sdstest | 2 +- ...od-curly braces separated by space.sdstest | 2 +- .../literals/string/good-empty.sdstest | 2 +- .../string/good-escaped curly brace.sdstest | 2 +- .../string/good-multiple lines.sdstest | 2 +- .../good-newline escape sequence.sdstest | 2 +- .../string/good-single curly brace.sdstest | 2 +- .../literals/string/good-single quote.sdstest | 2 +- .../good-unicode escape sequence.sdstest | 2 +- ...-conjunction without left operator.sdstest | 2 +- ...conjunction without right operator.sdstest | 2 +- ...-disjunction without left operator.sdstest | 2 +- ...disjunction without right operator.sdstest | 2 +- .../bad-negation without operator.sdstest | 2 +- .../good-complex example.sdstest | 2 +- .../good-conjunction.sdstest | 2 +- .../good-disjunction.sdstest | 2 +- .../logical operations/good-negation.sdstest | 2 +- .../expressions/maps/bad-no colon.sdstest | 2 +- .../expressions/maps/bad-no key.sdstest | 2 +- .../expressions/maps/bad-no value.sdstest | 2 +- .../maps/bad-unclosed curly brace.sdstest | 2 +- .../good-nested multiple elements.sdstest | 2 +- .../maps/good-nested one element.sdstest | 2 +- .../good-one level multiple elements.sdstest | 2 +- .../maps/good-one level one element.sdstest | 2 +- .../member accesses/bad-no receiver.sdstest | 2 +- .../member accesses/good-not nullable.sdstest | 2 +- .../member accesses/good-nullable.sdstest | 2 +- .../bad-unclosed parenthesis.sdstest | 2 +- .../good-nested.sdstest | 2 +- .../good-one level.sdstest | 2 +- ...ate string with invalid expression.sdstest | 2 +- .../bad-unclosed template expression.sdstest | 2 +- .../good-empty template expression.sdstest | 2 +- ...plate string with basic expression.sdstest | 2 +- .../type casts/bad-without expression.sdstest | 2 +- .../type casts/bad-without type.sdstest | 2 +- .../expressions/type casts/good-basic.sdstest | 2 +- .../type casts/good-chained.sdstest | 2 +- .../keywords as names/bad-unescaped _.sdstest | 2 +- .../bad-unescaped and.sdstest | 2 +- .../bad-unescaped annotation.sdstest | 2 +- .../bad-unescaped as.sdstest | 2 +- .../bad-unescaped attr.sdstest | 2 +- .../bad-unescaped class.sdstest | 2 +- .../bad-unescaped const.sdstest | 2 +- .../bad-unescaped enum.sdstest | 2 +- .../bad-unescaped false.sdstest | 2 +- .../bad-unescaped fun.sdstest | 2 +- .../bad-unescaped import.sdstest | 2 +- .../bad-unescaped in.sdstest | 2 +- .../bad-unescaped internal.sdstest | 2 +- .../bad-unescaped literal.sdstest | 2 +- .../bad-unescaped not.sdstest | 2 +- .../bad-unescaped null.sdstest | 2 +- .../bad-unescaped or.sdstest | 2 +- .../bad-unescaped out.sdstest | 2 +- .../bad-unescaped package.sdstest | 2 +- .../bad-unescaped pipeline.sdstest | 2 +- .../bad-unescaped private.sdstest | 2 +- .../bad-unescaped schema.sdstest | 2 +- .../bad-unescaped segment.sdstest | 2 +- .../bad-unescaped static.sdstest | 2 +- .../bad-unescaped sub.sdstest | 2 +- .../bad-unescaped true.sdstest | 2 +- .../bad-unescaped union.sdstest | 2 +- .../bad-unescaped val.sdstest | 2 +- .../bad-unescaped where.sdstest | 2 +- .../bad-unescaped yield.sdstest | 2 +- .../good-escapedKeywords.sdstest | 2 +- .../good-escapedNonKeyword.sdstest | 2 +- ...-annotation call after declaration.sdstest | 2 +- .../bad-annotation call after import.sdstest | 2 +- ...annotation call after package name.sdstest | 2 +- ...ll between package name and import.sdstest | 2 +- .../bad-duplicate package name.sdstest | 2 +- .../bad-import after declaration.sdstest | 2 +- .../bad-import without declarations.sdstest | 2 +- .../bad-import without package.sdstest | 2 +- ...bad-package name after declaration.sdstest | 2 +- .../bad-package name after import.sdstest | 2 +- ...od-annotation call and declaration.sdstest | 2 +- ...on call and import and declaration.sdstest | 2 +- .../good-annotation call and import.sdstest | 2 +- ...l and package name and declaration.sdstest | 2 +- ...ge name and import and declaration.sdstest | 2 +- ...n call and package name and import.sdstest | 2 +- ...d-annotation call and package name.sdstest | 2 +- .../modules/good-annotation call.sdstest | 2 +- ...-annotation calls and declarations.sdstest | 2 +- ...calls and imports and declarations.sdstest | 2 +- .../good-annotation calls and imports.sdstest | 2 +- ... and package name and declarations.sdstest | 2 +- ... name and imports and declarations.sdstest | 2 +- ...calls and package name and imports.sdstest | 2 +- ...-annotation calls and package name.sdstest | 2 +- .../modules/good-annotation calls.sdstest | 2 +- .../grammar/modules/good-declaration.sdstest | 2 +- .../grammar/modules/good-declarations.sdstest | 2 +- .../grammar/modules/good-empty.sdstest | 2 +- .../good-import and declaration.sdstest | 2 +- .../grammar/modules/good-import.sdstest | 2 +- .../good-imports and declarations.sdstest | 2 +- .../grammar/modules/good-imports.sdstest | 2 +- .../good-package name and declaration.sdstest | 2 +- ...good-package name and declarations.sdstest | 2 +- ...ge name and import and declaration.sdstest | 2 +- .../good-package name and import.sdstest | 2 +- ... name and imports and declarations.sdstest | 2 +- .../good-package name and imports.sdstest | 2 +- .../grammar/modules/good-package name.sdstest | 2 +- .../schema/bad-no name (colon).sdstest | 2 +- .../schema/bad-no name (no colon).sdstest | 2 +- .../schema/bad-no type (colon).sdstest | 2 +- .../schema/bad-no type (no colon).sdstest | 2 +- .../schema/bad-switched name and type.sdstest | 2 +- .../schema/bad-unclosed curly brace.sdstest | 2 +- .../schema/good-annotation call.sdstest | 2 +- .../grammar/schema/good-empty schema.sdstest | 2 +- .../grammar/schema/good-one column.sdstest | 2 +- .../grammar/schema/good-two columns.sdstest | 2 +- ...-in block lambda without assignees.sdstest | 2 +- ...in block lambda without expression.sdstest | 2 +- ...-in block lambda without semicolon.sdstest | 2 +- .../bad-in pipeline without assignees.sdstest | 2 +- ...bad-in pipeline without expression.sdstest | 2 +- .../bad-in pipeline without semicolon.sdstest | 2 +- .../bad-in segment without assignees.sdstest | 2 +- .../bad-in segment without expression.sdstest | 2 +- .../bad-in segment without semicolon.sdstest | 2 +- .../assignments/good-in block lambda.sdstest | 2 +- .../assignments/good-in pipeline.sdstest | 2 +- .../assignments/good-in segment.sdstest | 2 +- ...ad-empty statement in block lambda.sdstest | 2 +- .../bad-empty statement in pipeline.sdstest | 2 +- .../bad-empty statement in segment.sdstest | 2 +- .../bad-with else missing elseblock.tsltest | 2 +- .../bad-without else missing block.tsltest | 2 +- ...bad-without else missing condition.tsltest | 2 +- .../good-with else false.tsltest | 2 +- .../good-with else true.tsltest | 2 +- .../good-without else.tsltest | 2 +- ...-in block lambda without semicolon.sdstest | 2 +- .../bad-in pipeline without semicolon.sdstest | 2 +- .../bad-in segment without semicolon.sdstest | 2 +- .../good-in block lambda.sdstest | 2 +- .../good-in pipeline.sdstest | 2 +- .../good-in segment.sdstest | 2 +- ...d-argument list of annotation call.sdstest | 2 +- .../good-argument list of call.sdstest | 2 +- ...list of assignment in block lambda.sdstest | 2 +- .../good-assignee list of assignment.sdstest | 2 +- .../good-column list of schema.sdstest | 2 +- ...good-constraint list of annotation.sdstest | 2 +- .../good-constraint list of class.sdstest | 2 +- ...od-constraint list of enum variant.sdstest | 2 +- .../good-constraint list of function.sdstest | 2 +- .../good-elements of list.sdstest | 2 +- .../good-entries of map.sdstest | 2 +- ...claration list of qualified import.sdstest | 2 +- .../good-literal list of literal type.sdstest | 2 +- .../good-parameter list of annotation.sdstest | 2 +- ...ood-parameter list of block lambda.sdstest | 2 +- ...od-parameter list of callable type.sdstest | 2 +- .../good-parameter list of class.sdstest | 2 +- ...ood-parameter list of enum variant.sdstest | 2 +- ...arameter list of expression lambda.sdstest | 2 +- .../good-parameter list of function.sdstest | 2 +- .../good-parameter list of segment.sdstest | 2 +- .../good-parent type list of class.sdstest | 2 +- .../good-result list of callable type.sdstest | 2 +- .../good-result list of function.sdstest | 2 +- .../good-result list of segment.sdstest | 2 +- ...d-type argument list of named type.sdstest | 2 +- ...d-type argument list of union type.sdstest | 2 +- .../good-type parameter list of class.sdstest | 2 +- ...od-type parameter list of function.sdstest | 2 +- .../callable types/bad-missing arrow.sdstest | 2 +- .../bad-missing parameter list.sdstest | 2 +- .../bad-missing result list.sdstest | 2 +- .../bad-unclosed parameter list.sdstest | 2 +- .../bad-unclosed result list.sdstest | 2 +- ...od-with parameter and result lists.sdstest | 2 +- .../types/literal types/bad-nested.sdstest | 2 +- .../literal types/bad-no literal list.sdstest | 2 +- .../bad-unclosed angle bracket.sdstest | 2 +- .../types/literal types/good-empty.sdstest | 2 +- .../good-with list literal.sdstest | 2 +- .../literal types/good-with literals.sdstest | 2 +- .../good-with map literal.sdstest | 2 +- .../bad-callable type as member.sdstest | 2 +- .../bad-literal type as member.sdstest | 2 +- .../member types/bad-missing member.sdstest | 2 +- .../member types/bad-missing receiver.sdstest | 2 +- .../bad-unclosed angle bracket.sdstest | 2 +- .../bad-union type as member.sdstest | 2 +- .../good-long complex chain.sdstest | 2 +- ...allable) and member (not nullable).sdstest | 2 +- ...r (callable) and member (nullable).sdstest | 2 +- ...literal) and member (not nullable).sdstest | 2 +- ...er (literal) and member (nullable).sdstest | 2 +- ...ullable) and member (not nullable).sdstest | 2 +- ...ot nullable) and member (nullable).sdstest | 2 +- ...ullable) and member (not nullable).sdstest | 2 +- ...d, nullable) and member (nullable).sdstest | 2 +- ... (union) and member (not nullable).sdstest | 2 +- ...iver (union) and member (nullable).sdstest | 2 +- .../bad-unclosed angle bracket.sdstest | 2 +- ...no type arguments and not nullable.sdstest | 2 +- ...ood-no type arguments and nullable.sdstest | 2 +- .../good-type argument and nullable.sdstest | 2 +- ...od-type arguments and not nullable.sdstest | 2 +- .../bad-unclosed angle bracket.sdstest | 2 +- .../types/union types/good-empty.sdstest | 2 +- .../types/union types/good-nested.sdstest | 2 +- .../good-with type arguments.sdstest | 2 +- .../base cases/block lambdas/main.sdstest | 2 +- .../base cases/boolean literals/main.sdstest | 4 +- .../base cases/classes/main.sdstest | 2 +- .../base cases/enum variants/main.sdstest | 2 +- .../expression lambdas/main.sdstest | 2 +- .../base cases/float literals/main.sdstest | 4 +- .../base cases/functions/main.sdstest | 2 +- .../base cases/int literals/main.sdstest | 2 +- .../base cases/null literals/main.sdstest | 2 +- .../base cases/segments/main.sdstest | 2 +- .../main.sdstest | 4 +- .../invalid nodes/main.sdstest | 2 +- .../recursive cases/arguments/main.sdstest | 4 +- .../block lambda results/main.sdstest | 8 +- .../assignees/placeholders/main.sdstest | 8 +- .../assignees/wildcards/main.sdstest | 8 +- .../assignees/yields/main.sdstest | 8 +- .../calls/of block lambdas/closure.sdstest | 2 +- .../calls/of block lambdas/main.sdstest | 2 +- ...ameter value used as default value.sdstest | 2 +- .../calls/of classes/main.sdstest | 2 +- .../calls/of enum variants/main.sdstest | 18 +- .../of expression lambdas/closure.sdstest | 2 +- .../calls/of expression lambdas/main.sdstest | 2 +- ...ameter value used as default value.sdstest | 2 +- .../calls/of functions/main.sdstest | 2 +- .../calls/of segments/main.sdstest | 2 +- ...ameter value used as default value.sdstest | 2 +- .../calls/of unknown parameter/main.sdstest | 2 +- .../calls/on null/main.sdstest | 4 +- .../calls/recursion/main.sdstest | 2 +- .../calls/unresolved/main.sdstest | 4 +- .../indexed access/on lists/main.sdstest | 14 +- .../indexed access/on maps/main.sdstest | 12 +- .../indexed access/on null/main.sdstest | 4 +- .../indexed access/on other/main.sdstest | 4 +- .../infix operations/and/main.sdstest | 16 +- .../and/short circuiting.sdstest | 12 +- .../infix operations/divided by/main.sdstest | 22 +- .../infix operations/elvis/main.sdstest | 12 +- .../elvis/short circuiting.sdstest | 12 +- .../infix operations/equals/main.sdstest | 8 +- .../greater than or equals/main.sdstest | 24 +-- .../greater than/main.sdstest | 24 +-- .../identical to/main.sdstest | 8 +- .../less than or equals/main.sdstest | 24 +-- .../infix operations/less than/main.sdstest | 24 +-- .../infix operations/minus/main.sdstest | 16 +- .../infix operations/not equals/main.sdstest | 8 +- .../not identical to/main.sdstest | 8 +- .../infix operations/or/main.sdstest | 16 +- .../or/short circuiting.sdstest | 12 +- .../infix operations/plus/main.sdstest | 16 +- .../infix operations/times/main.sdstest | 16 +- .../recursive cases/lists/main.sdstest | 4 +- .../recursive cases/maps/main.sdstest | 4 +- .../of call results/main.sdstest | 12 +- .../of enum variant parameters/main.sdstest | 6 +- .../of enum variants/main.sdstest | 4 +- .../member accesses/on null/main.sdstest | 4 +- .../on other receivers/main.sdstest | 2 +- .../member accesses/unresolved/main.sdstest | 4 +- .../recursive cases/parameters/main.sdstest | 6 +- .../parenthesized expressions/main.sdstest | 8 +- .../prefix operations/minus/main.sdstest | 8 +- .../prefix operations/not/main.sdstest | 8 +- .../recursive cases/references/main.sdstest | 4 +- .../recursive cases/results/main.sdstest | 6 +- .../template strings/main.sdstest | 6 +- .../recursive cases/type casts/main.sdstest | 4 +- ...ain no imports or own declarations.sdstest | 10 +- ... with imports and own declarations.sdstest | 14 +- ...with multiple imports of same name.sdstest | 2 +- ...n with qualified import with alias.sdstest | 16 +- .../main with qualified import.sdstest | 14 +- .../main with wildcard import.sdstest | 10 +- .../resource other package.sdstest | 8 +- .../resource safeds package.sdstest | 4 +- .../resource same package.sdstest | 4 +- .../resource without package.sdstest | 4 +- .../on annotation/main.sdstest | 12 +- .../on attribute/main.sdstest | 12 +- .../annotation calls/on class/main.sdstest | 12 +- .../on enum variant/main.sdstest | 12 +- .../annotation calls/on enum/main.sdstest | 12 +- .../annotation calls/on function/main.sdstest | 12 +- .../annotation calls/on module/main.sdstest | 8 +- .../on parameter/main.sdstest | 16 +- .../annotation calls/on pipeline/main.sdstest | 12 +- .../annotation calls/on result/main.sdstest | 12 +- .../annotation calls/on segment/main.sdstest | 12 +- .../on type parameter/main.sdstest | 12 +- .../to parameter/main.sdstest | 12 +- .../main.sdstest | 2 +- .../unresolved/main.sdstest | 4 +- .../to parameter of annotation/main.sdstest | 18 +- .../to parameter of block lambda/main.sdstest | 12 +- .../main.sdstest | 18 +- .../to parameter of class/main.sdstest | 18 +- .../to parameter of enum variant/main.sdstest | 18 +- .../main.sdstest | 12 +- .../to parameter of function/main.sdstest | 18 +- .../to parameter of segment/main.sdstest | 18 +- .../main.sdstest | 2 +- .../of calls/unresolved/main.sdstest | 4 +- .../with nullable receiver/main.sdstest | 18 +- .../to annotations/main.sdstest | 16 +- .../resource first package.sdstest | 4 +- .../resource second package.sdstest | 8 +- .../to global classes/main.sdstest | 16 +- .../resource first package.sdstest | 4 +- .../resource second package.sdstest | 8 +- .../to global enums/main.sdstest | 16 +- .../resource first package.sdstest | 4 +- .../resource second package.sdstest | 8 +- .../to global functions/main.sdstest | 16 +- .../resource first package.sdstest | 4 +- .../resource second package.sdstest | 8 +- .../to nested declaration/main.sdstest | 16 +- .../resource first package.sdstest | 4 +- .../resource second package.sdstest | 8 +- .../to pipelines/main.sdstest | 16 +- .../resource first package.sdstest | 4 +- .../resource second package.sdstest | 8 +- .../to schemas/main.sdstest | 16 +- .../to schemas/resource first package.sdstest | 4 +- .../resource second package.sdstest | 8 +- .../to segments/main.sdstest | 26 +-- .../resource first package.sdstest | 4 +- .../to segments/resource same package.sdstest | 6 +- .../resource second package.sdstest | 12 +- .../unresolved/main.sdstest | 2 +- .../on type parameters/main.sdstest | 10 +- .../to class members/hiding/main.sdstest | 24 +-- .../to class members/inheritance/main.sdstest | 48 ++--- .../instance attributes/main.sdstest | 56 ++--- .../instance methods/main.sdstest | 56 ++--- .../nested classes/main.sdstest | 46 ++--- .../nested enums/main.sdstest | 46 ++--- .../to class members/overriding/main.sdstest | 12 +- .../static attributes/main.sdstest | 44 ++-- .../static methods/main.sdstest | 46 ++--- .../to enum variants/main.sdstest | 16 +- .../main.sdstest | 20 +- .../call with nullable receiver/main.sdstest | 16 +- .../main.sdstest | 8 +- .../to results/of block lambdas/main.sdstest | 8 +- .../main.sdstest | 8 +- .../to results/of callable types/main.sdstest | 8 +- .../main.sdstest | 8 +- .../to results/of functions/main.sdstest | 8 +- .../main.sdstest | 8 +- .../to results/of segments/main.sdstest | 8 +- ...ain no imports or own declarations.sdstest | 10 +- ... with imports and own declarations.sdstest | 14 +- ...with multiple imports of same name.sdstest | 2 +- ...n with qualified import with alias.sdstest | 16 +- .../main with qualified import.sdstest | 14 +- .../main with wildcard import.sdstest | 10 +- .../resource other package.sdstest | 8 +- .../resource safeds package.sdstest | 4 +- .../resource same package.sdstest | 4 +- .../resource without package.sdstest | 4 +- ...ain no imports or own declarations.sdstest | 10 +- ... with imports and own declarations.sdstest | 14 +- ...with multiple imports of same name.sdstest | 2 +- ...n with qualified import with alias.sdstest | 16 +- .../main with qualified import.sdstest | 14 +- .../main with wildcard import.sdstest | 10 +- .../resource other package.sdstest | 8 +- .../resource safeds package.sdstest | 4 +- .../resource same package.sdstest | 4 +- .../resource without package.sdstest | 4 +- .../main.sdstest | 60 +++--- .../main.sdstest | 22 +- .../main.sdstest | 22 +- .../to global classes/main.sdstest | 10 +- .../in same file/to global enums/main.sdstest | 10 +- .../to nested classes/main.sdstest | 14 +- .../in same file/to nested enums/main.sdstest | 14 +- .../main.sdstest | 2 +- .../main.sdstest | 10 +- .../in global classes/main.sdstest | 30 +-- .../in global functions/main.sdstest | 28 +-- .../in methods/main.sdstest | 56 ++--- .../in nested classes/main.sdstest | 62 +++--- .../in annotation/main.sdstest | 12 +- .../main.sdstest | 14 +- .../in global class/main.sdstest | 12 +- .../in global function/main.sdstest | 12 +- .../parameter bounds/in method/main.sdstest | 22 +- .../in nested class/main.sdstest | 22 +- .../parameter bounds/in segment/main.sdstest | 12 +- ...ain no imports or own declarations.sdstest | 10 +- ... with imports and own declarations.sdstest | 14 +- ...with multiple imports of same name.sdstest | 2 +- ...n with qualified import with alias.sdstest | 16 +- .../main with qualified import.sdstest | 12 +- .../main with wildcard import.sdstest | 10 +- .../resource other package.sdstest | 6 +- .../resource safeds package.sdstest | 4 +- .../resource same package.sdstest | 4 +- .../resource without package.sdstest | 4 +- ...ain no imports or own declarations.sdstest | 10 +- ... with imports and own declarations.sdstest | 14 +- ...with multiple imports of same name.sdstest | 2 +- ...n with qualified import with alias.sdstest | 16 +- .../main with qualified import.sdstest | 12 +- .../main with wildcard import.sdstest | 10 +- .../resource other package.sdstest | 6 +- .../resource safeds package.sdstest | 4 +- .../resource same package.sdstest | 4 +- .../resource without package.sdstest | 4 +- ...ain no imports or own declarations.sdstest | 10 +- ... with imports and own declarations.sdstest | 14 +- ...with multiple imports of same name.sdstest | 2 +- ...n with qualified import with alias.sdstest | 16 +- .../main with qualified import.sdstest | 12 +- .../main with wildcard import.sdstest | 10 +- .../resource other package.sdstest | 6 +- .../resource safeds package.sdstest | 4 +- .../resource same package.sdstest | 4 +- .../resource without package.sdstest | 4 +- ...ain no imports or own declarations.sdstest | 10 +- ... with imports and own declarations.sdstest | 14 +- ...with multiple imports of same name.sdstest | 2 +- ...n with qualified import with alias.sdstest | 16 +- .../main with qualified import.sdstest | 12 +- .../main with wildcard import.sdstest | 10 +- .../resource other package.sdstest | 6 +- .../resource safeds package.sdstest | 4 +- .../resource same package.sdstest | 4 +- .../resource without package.sdstest | 4 +- ...ain no imports or own declarations.sdstest | 10 +- ... with imports and own declarations.sdstest | 14 +- ...with multiple imports of same name.sdstest | 2 +- ...n with qualified import with alias.sdstest | 16 +- .../main with qualified import.sdstest | 12 +- .../main with wildcard import.sdstest | 10 +- .../resource other package.sdstest | 6 +- .../resource safeds package.sdstest | 4 +- .../resource same package.sdstest | 4 +- .../resource without package.sdstest | 4 +- ...ain no imports or own declarations.sdstest | 10 +- ... with imports and own declarations.sdstest | 14 +- ...with multiple imports of same name.sdstest | 2 +- ...n with qualified import with alias.sdstest | 16 +- .../main with qualified import.sdstest | 12 +- .../main with wildcard import.sdstest | 10 +- .../to schemas/resource other package.sdstest | 6 +- .../resource safeds package.sdstest | 4 +- .../to schemas/resource same package.sdstest | 4 +- .../resource without package.sdstest | 4 +- ...ain no imports or own declarations.sdstest | 26 +-- ... with imports and own declarations.sdstest | 30 +-- ...with multiple imports of same name.sdstest | 2 +- ...n with qualified import with alias.sdstest | 32 +-- .../main with qualified import.sdstest | 28 +-- .../main with wildcard import.sdstest | 26 +-- .../resource other package.sdstest | 10 +- .../resource safeds package.sdstest | 8 +- .../to segments/resource same package.sdstest | 8 +- .../resource without package.sdstest | 8 +- .../in same file/to annotations/main.sdstest | 8 +- .../from outside/main.sdstest | 2 +- .../of containing block lambda/main.sdstest | 2 +- .../to class members/main.sdstest | 12 +- .../to containing declarations/main.sdstest | 60 +++--- .../to enum variants/main.sdstest | 2 +- .../to global classes/main.sdstest | 8 +- .../in same file/to global enums/main.sdstest | 8 +- .../to global functions/main.sdstest | 8 +- .../in same file/to modules/main.sdstest | 2 +- .../main.sdstest | 64 +++--- .../to parameters/from outside/main.sdstest | 16 +- .../from parameter bound/main.sdstest | 24 +-- .../of containing block lambda/main.sdstest | 44 ++-- .../main.sdstest | 38 ++-- .../of containing segment/main.sdstest | 24 +-- .../in same file/to pipelines/main.sdstest | 8 +- .../to placeholders/from outside/main.sdstest | 6 +- .../of containing block lambda/main.sdstest | 74 +++---- .../of containing pipeline/main.sdstest | 34 ++-- .../of containing segment/main.sdstest | 34 ++-- .../to redeclared module member/main.sdstest | 8 +- .../to results/from outside/main.sdstest | 6 +- .../of containing segment/main.sdstest | 2 +- .../in same file/to schemas/main.sdstest | 8 +- .../in same file/to segments/main.sdstest | 22 +- .../to type parameters/main.sdstest | 2 +- .../references/unresolved/main.sdstest | 2 +- .../main.sdstest | 2 +- .../main.sdstest | 26 +-- .../main.sdstest | 4 +- .../main.sdstest | 4 +- .../type arguments/to unresolved/main.sdstest | 4 +- .../scoping/yields/in pipeline/main.sdstest | 8 +- .../scoping/yields/in segment/main.sdstest | 16 +- .../block lambda results/main.sdstest | 12 +- .../assignees/placeholders/main.sdstest | 12 +- .../typing/assignees/yields/main.sdstest | 12 +- .../declarations/annotations/main.sdstest | 6 +- .../declarations/attributes/main.sdstest | 12 +- .../typing/declarations/classes/main.sdstest | 4 +- .../declarations/enum variants/main.sdstest | 4 +- .../typing/declarations/enums/main.sdstest | 4 +- .../declarations/functions/main.sdstest | 10 +- .../parameters/of annotations/main.sdstest | 6 +- .../that are isolated/main.sdstest | 2 +- .../that are passed as arguments/main.sdstest | 14 +- .../main.sdstest | 8 +- .../that are yielded/main.sdstest | 8 +- .../with manifest types/main.sdstest | 4 +- .../parameters/of callable types/main.sdstest | 6 +- .../parameters/of classes/main.sdstest | 6 +- .../parameters/of enum variants/main.sdstest | 6 +- .../that are isolated/main.sdstest | 2 +- .../that are passed as arguments/main.sdstest | 14 +- .../main.sdstest | 8 +- .../that are yielded/main.sdstest | 8 +- .../with manifest types/main.sdstest | 4 +- .../parameters/of functions/main.sdstest | 6 +- .../parameters/of segments/main.sdstest | 6 +- .../declarations/pipelines/main.sdstest | 2 +- .../typing/declarations/results/main.sdstest | 12 +- .../typing/declarations/segments/main.sdstest | 10 +- .../declarations/type parameters/main.sdstest | 4 +- .../typing/expressions/arguments/main.sdstest | 30 +-- .../that are isolated/main.sdstest | 4 +- .../that are passed as arguments/main.sdstest | 14 +- .../main.sdstest | 12 +- .../that are yielded/main.sdstest | 6 +- .../with manifest types/main.sdstest | 4 +- .../calls/of annotations/main.sdstest | 4 +- .../calls/of block lambdas/main.sdstest | 8 +- .../calls/of callable types/main.sdstest | 8 +- .../expressions/calls/of classes/main.sdstest | 8 +- .../calls/of enum variants/main.sdstest | 40 ++-- .../calls/of expression lambdas/main.sdstest | 4 +- .../calls/of functions/main.sdstest | 8 +- .../calls/of non-callable/main.sdstest | 4 +- .../calls/of nullable receiver/main.sdstest | 8 +- .../calls/of segments/main.sdstest | 8 +- .../clamp to upper bound/main.sdstest | 8 +- .../deep nesting/main.sdstest | 20 +- .../default value of parameter/main.sdstest | 4 +- .../main.sdstest | 8 +- .../differing variance/main.sdstest | 32 +-- .../multiple contravariant/main.sdstest | 24 +-- .../multiple covariant/main.sdstest | 28 +-- .../single contravariant/main.sdstest | 4 +- .../single covariant/main.sdstest | 4 +- .../expressions/calls/unresolved/main.sdstest | 4 +- .../that are isolated/main.sdstest | 4 +- .../that are passed as arguments/main.sdstest | 14 +- .../main.sdstest | 6 +- .../that are yielded/main.sdstest | 6 +- .../with manifest types/main.sdstest | 2 +- .../indexed accesses/on lists/main.sdstest | 48 ++--- .../indexed accesses/on maps/main.sdstest | 48 ++--- .../indexed accesses/on other/main.sdstest | 8 +- .../on unresolved/main.sdstest | 4 +- .../typing/expressions/lists/main.sdstest | 10 +- .../typing/expressions/literals/main.sdstest | 10 +- .../typing/expressions/maps/main.sdstest | 12 +- .../main.sdstest | 48 ++--- .../to enum variants/main.sdstest | 12 +- .../to nested classes/main.sdstest | 4 +- .../to nested enums/main.sdstest | 4 +- .../member accesses/to other/main.sdstest | 30 +-- .../member accesses/unresolved/main.sdstest | 4 +- .../operations/arithmetic/main.sdstest | 120 +++++------ .../operations/comparison/main.sdstest | 16 +- .../elvis/non nullable left operand.sdstest | 24 +-- .../elvis/nullable left operand.sdstest | 12 +- .../operations/equality/main.sdstest | 16 +- .../operations/logical/main.sdstest | 12 +- .../parenthesized expressions/main.sdstest | 20 +- .../references/to global classes/main.sdstest | 2 +- .../references/to global enums/main.sdstest | 2 +- .../references/to other/main.sdstest | 8 +- .../references/unresolved/main.sdstest | 2 +- .../expressions/template strings/main.sdstest | 4 +- .../expressions/type casts/main.sdstest | 6 +- ...op if class has no type parameters.sdstest | 2 +- .../class type and class type/main.sdstest | 22 +- .../with type parameters.sdstest | 68 +++---- .../class type and enum type/main.sdstest | 16 +- .../class type and enum variant/main.sdstest | 16 +- .../class type and literal type/main.sdstest | 30 +-- .../main.sdstest | 24 +-- .../enum type and enum type/main.sdstest | 12 +- .../main.sdstest | 12 +- .../main.sdstest | 24 +-- .../main.sdstest | 18 +- .../main.sdstest | 20 +- .../incompatible types/main.sdstest | 24 +-- .../main.sdstest | 6 +- .../simplification/main.sdstest | 8 +- .../main.sdstest | 14 +- .../unhandled type/main.sdstest | 12 +- .../unknown type/main.sdstest | 4 +- .../class type and class type/main.sdstest | 12 +- .../with type parameters.sdstest | 48 ++--- .../class type and literal type/main.sdstest | 20 +- .../main.sdstest | 10 +- .../enum type and enum type/main.sdstest | 8 +- .../main.sdstest | 8 +- .../main.sdstest | 12 +- .../main.sdstest | 12 +- .../main.sdstest | 10 +- .../incompatible types/main.sdstest | 16 +- .../main.sdstest | 4 +- .../main.sdstest | 10 +- .../main.sdstest | 8 +- .../simplification/main.sdstest | 8 +- .../main.sdstest | 18 +- .../main.sdstest | 20 +- .../unhandled type/main.sdstest | 12 +- .../unknown type/main.sdstest | 4 +- .../main.sdstest | 10 +- .../main.sdstest | 6 +- .../main.sdstest | 84 ++++---- .../main.sdstest | 2 +- .../main.sdstest | 2 +- .../main.sdstest | 4 +- .../typing/simplification/unwrap/main.sdstest | 22 +- .../typing/types/callable types/main.sdstest | 10 +- .../typing/types/literal types/main.sdstest | 6 +- .../typing/types/member types/main.sdstest | 22 +- .../typing/types/named types/main.sdstest | 12 +- .../named types/with type parameters.sdstest | 24 +-- .../typing/types/type arguments/main.sdstest | 12 +- .../typing/types/union types/main.sdstest | 4 +- .../deprecated/assigned result/main.sdstest | 24 +-- .../deprecated/called annotation/main.sdstest | 6 +- .../corresponding parameter/main.sdstest | 12 +- .../main.sdstest | 40 ++-- .../from named type/main.sdstest | 14 +- .../from reference/main.sdstest | 38 ++-- .../experimental/assigned result/main.sdstest | 24 +-- .../called annotation/main.sdstest | 6 +- .../corresponding parameter/main.sdstest | 12 +- .../from named type/main.sdstest | 14 +- .../from reference/main.sdstest | 38 ++-- .../main.sdstest | 40 ++-- .../annotations/pythonCall/main.sdstest | 18 +- .../annotations/pythonModule/error.sdstest | 2 +- .../pythonModule/no annotation.sdstest | 2 +- .../annotations/pythonModule/no error.sdstest | 4 +- .../identical to safe-ds name/main.sdstest | 6 +- .../no annotation.sdstest | 2 +- .../main.sdstest | 14 +- .../annotations/repeatable/main.sdstest | 14 +- .../target/duplicate target/main.sdstest | 30 +-- .../no target annotation.sdstest | 2 +- .../target/wrong target/main.sdstest | 100 ++++----- .../constraint lists/main.sdstest | 2 +- .../literal types/main.sdstest | 2 +- .../maps/main.sdstest | 4 +- .../union types/main.sdstest | 8 +- .../inheritance/must be acyclic/main.sdstest | 16 +- .../class with parent types.sdstest | 20 +- .../class without parent types.sdstest | 2 +- .../class with parent types.sdstest | 20 +- .../class with parent types.sdstest | 12 +- .../class without parent types.sdstest | 2 +- .../main.sdstest | 32 +-- .../type parameters.sdstest | 20 +- .../main.sdstest | 32 +-- .../purity.sdstest | 8 +- .../safeds lang any.sdstest | 2 +- .../type parameters.sdstest | 18 +- .../names/casing/annotations.sdstest | 10 +- .../names/casing/attributes.sdstest | 10 +- .../names/casing/block lambda results.sdstest | 10 +- .../validation/names/casing/classes.sdstest | 10 +- .../names/casing/enum variants.sdstest | 10 +- .../validation/names/casing/enums.sdstest | 10 +- .../validation/names/casing/functions.sdstest | 10 +- .../names/casing/no package name.sdstest | 2 +- .../package name leading underscore.sdstest | 2 +- .../package name lowercase escaped.sdstest | 2 +- .../casing/package name lowercase.sdstest | 2 +- .../casing/package name snake case.sdstest | 2 +- .../casing/package name uppercase.sdstest | 2 +- .../names/casing/parameters.sdstest | 10 +- .../validation/names/casing/pipelines.sdstest | 10 +- .../names/casing/placeholders.sdstest | 10 +- .../validation/names/casing/results.sdstest | 10 +- .../validation/names/casing/schemas.sdstest | 10 +- .../validation/names/casing/segments.sdstest | 10 +- .../names/casing/type parameters.sdstest | 10 +- .../names/codegen prefix/annotations.sdstest | 4 +- .../names/codegen prefix/attributes.sdstest | 4 +- .../block lambda results.sdstest | 4 +- .../names/codegen prefix/classes.sdstest | 4 +- .../codegen prefix/enum variants.sdstest | 4 +- .../names/codegen prefix/enums.sdstest | 4 +- .../names/codegen prefix/functions.sdstest | 4 +- .../codegen prefix/no package name.sdstest | 2 +- .../package name with codegen prefix.sdstest | 2 +- ...ackage name without codegen prefix.sdstest | 2 +- .../names/codegen prefix/parameters.sdstest | 4 +- .../names/codegen prefix/pipelines.sdstest | 4 +- .../names/codegen prefix/placeholders.sdstest | 4 +- .../names/codegen prefix/results.sdstest | 4 +- .../names/codegen prefix/schemas.sdstest | 4 +- .../names/codegen prefix/segments.sdstest | 4 +- .../codegen prefix/type parameters.sdstest | 4 +- .../names/core names/in safeds lang.sdstest | 2 +- .../validation/names/core names/main.sdstest | 4 +- .../duplicates/across files/main.sdstest | 72 +++---- .../across files/other package.sdstest | 18 +- .../duplicates/across files/safeds 1.sdstest | 20 +- .../duplicates/across files/safeds 2.sdstest | 18 +- .../across files/same package.sdstest | 18 +- .../duplicates/in annotation/main.sdstest | 6 +- .../duplicates/in block lambda/main.sdstest | 36 ++-- .../duplicates/in callable type/main.sdstest | 16 +- .../names/duplicates/in class/main.sdstest | 172 ++++++++-------- .../duplicates/in enum variant/main.sdstest | 6 +- .../names/duplicates/in enum/main.sdstest | 6 +- .../in expression lambda/main.sdstest | 6 +- .../names/duplicates/in function/main.sdstest | 30 +-- .../duplicates/in pipeline file/main.sdspipe | 70 +++---- .../names/duplicates/in pipeline/main.sdstest | 6 +- .../names/duplicates/in schema/main.sdstest | 6 +- .../names/duplicates/in segment/main.sdstest | 36 ++-- .../duplicates/in stub file/main.sdsstub | 70 +++---- .../duplicates/in test file/main.sdstest | 70 +++---- .../duplicate parameter/main.sdstest | 112 +++++----- ...rgument list is missing altogether.sdstest | 2 +- .../missing required parameter/main.sdstest | 130 ++++++------ .../main.sdstest | 52 ++--- .../too many arguments/main.sdstest | 130 ++++++------ .../missing argument list/main.sdstest | 20 +- .../main.sdstest | 12 +- .../main.sdstest | 6 +- .../main.sdstest | 6 +- .../main.sdstest | 62 +++--- .../main.sdstest | 34 ++-- .../parameter must be const/main.sdstest | 56 ++--- .../main.sdstest | 32 +-- .../main.sdstest | 72 +++---- .../main.sdstest | 112 +++++----- .../parameters/const modifier/error.sdstest | 6 +- .../const modifier/no error.sdstest | 2 +- .../main.sdstest | 12 +- .../no type.sdstest | 2 +- .../main.sdstest | 96 ++++----- .../placeholders/alias/main.sdstest | 30 +-- .../placeholders/unused/main.sdstest | 24 +-- .../segments/duplicate yield/main.sdstest | 14 +- .../segments/unassigned result/main.sdstest | 10 +- .../segments/unused parameter/main.sdstest | 24 +-- .../declarations/segments/unused/main.sdstest | 12 +- .../main.sdstest | 28 +-- .../insufficient context/main.sdstest | 36 ++-- .../main.sdstest | 18 +- .../main.sdstest | 38 ++-- .../contravariant type parameter.sdstest | 74 +++---- .../covariant type parameter.sdstest | 74 +++---- .../invariant type parameter.sdstest | 74 +++---- .../usage of class type parameters.sdstest | 22 +- .../invariant.sdstest | 2 +- .../variance only on classes/variant.sdstest | 8 +- .../annotation calls.sdstest | 16 +- .../const parameters.sdstest | 12 +- .../normal parameters.sdstest | 8 +- .../calls/recursion/direct.sdstest | 6 +- .../calls/recursion/not recursive.sdstest | 2 +- ...tive via function pointer argument.sdstest | 2 +- .../transitive via lambda argument.sdstest | 2 +- .../calls/recursion/transitive.sdstest | 6 +- .../missing null safety/main.sdstest | 82 ++++---- .../list index out of bounds/main.sdstest | 36 ++-- .../map key does not exist/main.sdstest | 22 +- .../division by zero/main.sdstest | 30 +-- .../assigned to typed parameter.sdstest | 104 +++++----- .../assigned to unresolved parameter.sdstest | 12 +- .../assigned to untyped parameter.sdstest | 104 +++++----- .../lambdas/context/invalid context.sdstest | 12 +- .../main.sdstest | 30 +-- .../references/function pointer/main.sdstest | 50 ++--- .../static class reference/main.sdstest | 30 +-- .../static enum reference/main.sdstest | 18 +- .../references/target/main.sdstest | 6 +- .../missing template expression/main.sdstest | 8 +- .../other/imports/main with issues.sdstest | 12 +- .../other/imports/main without issues.sdstest | 4 +- .../main.sdspipe | 24 +-- .../declarations in stub files/main.sdsstub | 24 +-- ...ng is allowed (no pipeline errors).sdstest | 24 +-- ...ything is allowed (no stub errors).sdstest | 24 +-- .../pipeline file (empty).sdspipe | 2 +- .../pipeline file (only annotations).sdspipe | 2 +- .../pipeline file (only imports).sdspipe | 2 +- ...le (with declarations and package).sdspipe | 4 +- ...(with declarations but no package).sdspipe | 4 +- .../stub file (empty).sdsstub | 2 +- .../stub file (only annotations).sdsstub | 2 +- .../stub file (only imports).sdsstub | 2 +- ...le (with declarations and package).sdsstub | 4 +- ...(with declarations but no package).sdsstub | 4 +- .../pipe elsewhere.sdspipe | 2 +- .../pipe in safeds.sdspipe | 2 +- .../pipe in subpackage of safeds.sdspipe | 2 +- .../stub elsewhere.sdsstub | 2 +- .../stub in safeds.sdsstub | 2 +- .../stub in subpackage of safeds.sdsstub | 2 +- .../test elsewhere.sdstest | 2 +- .../test in safeds.sdstest | 2 +- .../test in subpackage of safeds.sdstest | 2 +- .../assignments/has no effect/main.sdstest | 16 +- .../implicitly ignore result/main.sdstest | 34 ++-- .../assignments/nothing assigned/main.sdstest | 96 ++++----- .../yield forbidden in pipeline/main.sdstest | 6 +- .../has no effect/main.sdstest | 36 ++-- .../types/callable types/context/main.sdstest | 30 +-- .../callable types/context/nested.sdstest | 6 +- .../optional.sdstest | 2 +- .../required.sdstest | 2 +- .../duplicate literals/empty list.sdstest | 2 +- .../duplicate literals/main.sdstest | 8 +- .../must have literals/main.sdstest | 6 +- .../main.sdstest | 2 +- .../main.sdstest | 2 +- .../duplicate type parameter/main.sdstest | 20 +- .../main.sdstest | 12 +- .../too many type arguments/main.sdstest | 12 +- .../types/union types/context/main.sdstest | 28 +-- .../types/union types/context/nested.sdstest | 6 +- .../duplicate types/empty list.sdstest | 2 +- .../union types/duplicate types/main.sdstest | 8 +- .../union types/must have types/main.sdstest | 6 +- .../duplicate impurity reason/main.sdstest | 30 +-- .../no impure annotation.sdstest | 2 +- .../arguments.sdstest | 72 +++---- .../default values.sdstest | 60 +++--- .../invalid parameter name/main.sdstest | 20 +- .../main.sdstest | 22 +- .../no purity annotation.sdstest | 2 +- .../purity/no impurity reasons/main.sdstest | 12 +- .../purity/not specified/main.sdstest | 6 +- .../main.sdstest | 10 +- .../purity/pure and impure/main.sdstest | 8 +- .../main.sdstest | 20 +- .../main.sdstest | 34 ++-- .../style/unnecessary assignment/main.sdstest | 16 +- .../unnecessary body in class/main.sdstest | 6 +- .../unnecessary body in enum/main.sdstest | 4 +- .../info.sdstest | 2 +- .../no info.sdstest | 2 +- .../main.sdstest | 4 +- .../main.sdstest | 4 +- .../main.sdstest | 4 +- .../main.sdstest | 4 +- .../main.sdstest | 4 +- .../unnecessary elvis operator/main.sdstest | 40 ++-- .../unnecessary import alias/main.sdstest | 6 +- .../unnecessary null safety/main.sdstest | 82 ++++---- .../main.sdstest | 4 +- .../main.sdstest | 4 +- .../main.sdstest | 4 +- .../main.sdstest | 4 +- .../main.sdstest | 16 +- .../main.sdstest | 4 +- .../main.sdstest | 4 +- .../style/unnecessary union type/main.sdstest | 6 +- .../types/checking/arguments/main.sdstest | 10 +- .../arguments/with type parameters.sdstest | 40 ++-- .../types/checking/call receiver/main.sdstest | 58 +++--- .../main.sdstest | 4 +- .../checking/default values/main.sdstest | 8 +- .../with type parameters.sdstest | 36 ++-- .../indexed access on list/main.sdstest | 16 +- .../indexed access on map/main.sdstest | 22 +- .../indexed access receiver/main.sdstest | 20 +- .../checking/infix operations/main.sdstest | 192 +++++++++--------- .../types/checking/lists/main.sdstest | 6 +- .../types/checking/maps/main.sdstest | 12 +- .../checking/prefix operations/main.sdstest | 18 +- .../types/checking/type casts/main.sdstest | 4 +- .../main.sdstest | 40 ++-- .../main.sdstest | 26 +-- .../types/checking/yields/main.sdstest | 6 +- ...rgument list is missing altogether.sdstest | 2 +- .../main.sdstest | 22 +- .../missing type argument list/main.sdstest | 16 +- .../missing for attribute/main.sdstest | 4 +- .../missing for parameter/main.sdstest | 32 +-- .../missing for result/main.sdstest | 16 +- 1219 files changed, 5876 insertions(+), 5876 deletions(-) diff --git a/docs/development/call-graph-testing.md b/docs/development/call-graph-testing.md index 5c497fce..000d69ca 100644 --- a/docs/development/call-graph-testing.md +++ b/docs/development/call-graph-testing.md @@ -16,7 +16,7 @@ graph test. 3. Surround calls or callables for which you want to compute a call graph with test markers, e.g. `»f()«`. Add a comment in the preceding line with the following format: ```ts - // $TEST$ ["f", "$blockLambda", "$expressionLambda", "undefined"] + # $TEST$ ["f", "$blockLambda", "$expressionLambda", "undefined"] ``` The comment must contain an array with the names of the callables that are expected to be called. The order must match the actual call order. The names must be: diff --git a/docs/development/generation-testing.md b/docs/development/generation-testing.md index 5bb97e77..bfcc8099 100644 --- a/docs/development/generation-testing.md +++ b/docs/development/generation-testing.md @@ -23,7 +23,7 @@ generation test. placeholder with test markers, e.g. `val »a« = 1;`. You may only mark a single placeholder this way. Add a comment in the preceding line with the following format: ```ts - // $TEST$ run_until + # $TEST$ run_until ``` 5. Add another folder called `generated` inside the folder that you created in step 1. Place folders and Python files inside the `generated` folder to specify the expected output of the program. The relative paths to the Python files diff --git a/docs/development/grammar-testing.md b/docs/development/grammar-testing.md index 99bfe195..19d3b6e5 100644 --- a/docs/development/grammar-testing.md +++ b/docs/development/grammar-testing.md @@ -18,11 +18,11 @@ test. 2. If you want to assert that a file is parsed without a syntax error[^1], add the following comment to the file: ```ts - // $TEST$ no_syntax_error + # $TEST$ no_syntax_error ``` If you instead want to assert that the parser detects a syntax error, add the following comment to the file: ```ts - // $TEST$ syntax_error + # $TEST$ syntax_error ``` !!! warning diff --git a/docs/development/partial-evaluation-testing.md b/docs/development/partial-evaluation-testing.md index aae92008..27871203 100644 --- a/docs/development/partial-evaluation-testing.md +++ b/docs/development/partial-evaluation-testing.md @@ -20,9 +20,9 @@ partial evaluation test. 5. For each pair of test markers, add a test comment with one of the formats listed below. Test comments and test markers are mapped to each other by their position in the file, i.e. the first test comment corresponds to the first test marker, the second test comment corresponds to the second test marker, etc. - * `// $TEST$ constant equivalence_class `: Assert that all nodes with the same `` get partially evaluated + * `# $TEST$ constant equivalence_class `: Assert that all nodes with the same `` get partially evaluated successfully to the same constant expression. - * `// $TEST$ serialization `: Assert that the node gets partially evaluated to a constant expression + * `# $TEST$ serialization `: Assert that the node gets partially evaluated to a constant expression that serializes to ``. - * `// $TEST$ not constant`: Assert that the node cannot be evaluated to a constant expression. + * `# $TEST$ not constant`: Assert that the node cannot be evaluated to a constant expression. 6. Run the tests. The test runner will automatically pick up the new test. diff --git a/docs/development/scoping-testing.md b/docs/development/scoping-testing.md index 854b1fcb..75bbc073 100644 --- a/docs/development/scoping-testing.md +++ b/docs/development/scoping-testing.md @@ -19,17 +19,17 @@ test. 4. Surround **the name** of any declaration that you want to reference with test markers, e.g. `class »C«`. Add a comment in the preceding line with the following format (replace `` with some unique identifier): ```ts - // $TEST$ target + # $TEST$ target ``` 5. Surround references you want to test with test markers, e.g. `»C«()`. If you want to assert that the reference should be resolved, add a comment in the preceding line with the following format (replace `` with the identifier you previously assigned to the referenced declaration): ```ts - // $TEST$ references + # $TEST$ references ``` If you instead want to assert that the reference is unresolved, add the following comment to the preceding line: ```ts - // $TEST$ unresolved + # $TEST$ unresolved ``` 6. Run the tests. The test runner will automatically pick up the new test. diff --git a/docs/development/typing-testing.md b/docs/development/typing-testing.md index 6f5405bb..2c02dcee 100644 --- a/docs/development/typing-testing.md +++ b/docs/development/typing-testing.md @@ -21,7 +21,7 @@ test. 5. For each pair of test markers, add a test comment with one of the formats listed below. Test comments and test markers are mapped to each other by their position in the file, i.e. the first test comment corresponds to the first test marker, the second test comment corresponds to the second test marker, etc. - * `// $TEST$ equivalence_class `: Assert that all nodes with the same `` have the same type. All equivalence + * `# $TEST$ equivalence_class `: Assert that all nodes with the same `` have the same type. All equivalence classes must have at least two entries. - * `// $TEST$ serialization `: Assert that the serialized type of the node is ``. + * `# $TEST$ serialization `: Assert that the serialized type of the node is ``. 6. Run the tests. The test runner will automatically pick up the new test. diff --git a/docs/development/validation-testing.md b/docs/development/validation-testing.md index 7b8b5be3..d1e8629b 100644 --- a/docs/development/validation-testing.md +++ b/docs/development/validation-testing.md @@ -41,19 +41,19 @@ validation test. Here are some examples: ```ts -// $TEST$ error "Incompatible type." +# $TEST$ error "Incompatible type." ``` We expect an error with the exact message `Incompatible type.`. ```ts -// $TEST$ no warning "Name should be lowerCamelCase." +# $TEST$ no warning "Name should be lowerCamelCase." ``` We expect no warning with the exact message `Name should be lowerCamelCase.`. ```ts -// $TEST$ info r".*empty.*" +# $TEST$ info r".*empty.*" ``` We expect an info with a message that matches the regular expression `.*empty.*`. diff --git a/packages/ttsl-lang/tests/helpers/testChecks.test.ts b/packages/ttsl-lang/tests/helpers/testChecks.test.ts index 1d789e94..6dbf9620 100644 --- a/packages/ttsl-lang/tests/helpers/testChecks.test.ts +++ b/packages/ttsl-lang/tests/helpers/testChecks.test.ts @@ -21,7 +21,7 @@ describe('findTestChecks', () => { }, { program: ` -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error `, expected: [ { @@ -32,7 +32,7 @@ describe('findTestChecks', () => { }, { program: ` -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error ${OPEN}${CLOSE} `, expected: [ @@ -48,9 +48,9 @@ ${OPEN}${CLOSE} }, { program: ` -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error ${OPEN}${CLOSE} -// $TEST$ syntax_error +# $TEST$ syntax_error ${OPEN}${CLOSE} `, expected: [ @@ -83,7 +83,7 @@ ${OPEN}${CLOSE} it('should report closing test markers without matching opening test marker', () => { const result = findTestChecks( ` - // $TEST$ no_syntax_error + # $TEST$ no_syntax_error ${OPEN}\n${CLOSE}${CLOSE} `, URI.parse(uri), @@ -98,7 +98,7 @@ ${OPEN}${CLOSE} it('should report opening test markers without matching closing test marker', () => { const result = findTestChecks( ` - // $TEST$ no_syntax_error + # $TEST$ no_syntax_error ${OPEN}\n${OPEN}${OPEN}${CLOSE} `, URI.parse(uri), @@ -113,7 +113,7 @@ ${OPEN}${CLOSE} it('should report if more ranges than comments are found', () => { const result = findTestChecks( ` - // $TEST$ no_syntax_error + # $TEST$ no_syntax_error ${OPEN}\n${CLOSE}${OPEN}\n${CLOSE} `, URI.parse(uri), @@ -137,7 +137,7 @@ ${OPEN}${CLOSE} it('should report if fewer ranges than comments are found if corresponding check is enabled', () => { const result = findTestChecks( ` - // $TEST$ no_syntax_error + # $TEST$ no_syntax_error `, URI.parse(uri), { failIfFewerRangesThanComments: true }, diff --git a/packages/ttsl-lang/tests/helpers/testComments.test.ts b/packages/ttsl-lang/tests/helpers/testComments.test.ts index 467fc4db..ef5d0ddf 100644 --- a/packages/ttsl-lang/tests/helpers/testComments.test.ts +++ b/packages/ttsl-lang/tests/helpers/testComments.test.ts @@ -9,13 +9,13 @@ describe('findTestComments', () => { id: 'empty program', }, { - program: `// $TEST$ no_syntax_error`, + program: `# $TEST$ no_syntax_error`, expected: ['no_syntax_error'], id: 'single comment', }, { - program: `// $TEST$ no_syntax_error - // $TEST$ syntax_error + program: `# $TEST$ no_syntax_error + # $TEST$ syntax_error // another comment`, expected: ['no_syntax_error', 'syntax_error'], id: 'multiple comments', diff --git a/packages/ttsl-lang/tests/helpers/testComments.ts b/packages/ttsl-lang/tests/helpers/testComments.ts index 723518a8..50e54999 100644 --- a/packages/ttsl-lang/tests/helpers/testComments.ts +++ b/packages/ttsl-lang/tests/helpers/testComments.ts @@ -1,7 +1,7 @@ const pattern = /\/\/\s*\$TEST\$(?[^\n]*)/gu; /** - * Finds all test comments (`// $TEST$ ...`) in the given program. + * Finds all test comments (`# $TEST$ ...`) in the given program. * * @param program The program with test comments. * @return The list of test comments. diff --git a/packages/ttsl-lang/tests/language/lsp/safe-ds-inlay-hint-provider.test.ts b/packages/ttsl-lang/tests/language/lsp/safe-ds-inlay-hint-provider.test.ts index f0ac8434..e7ef33b4 100644 --- a/packages/ttsl-lang/tests/language/lsp/safe-ds-inlay-hint-provider.test.ts +++ b/packages/ttsl-lang/tests/language/lsp/safe-ds-inlay-hint-provider.test.ts @@ -18,7 +18,7 @@ describe('SafeDsInlayHintProvider', async () => { fun f(p: Int) pipeline myPipeline { - // $TEST$ before "p = " + # $TEST$ before "p = " f(»«1); } `, @@ -48,7 +48,7 @@ describe('SafeDsInlayHintProvider', async () => { code: ` pipeline myPipeline { () { - // $TEST$ after ": literal<1>" + # $TEST$ after ": literal<1>" yield r»« = 1; }; } @@ -58,7 +58,7 @@ describe('SafeDsInlayHintProvider', async () => { testName: 'placeholder', code: ` pipeline myPipeline { - // $TEST$ after ": literal<1>" + # $TEST$ after ": literal<1>" val x»« = 1; } `, @@ -75,7 +75,7 @@ describe('SafeDsInlayHintProvider', async () => { testName: 'yield', code: ` segment s() -> r: Int { - // $TEST$ after ": literal<1>" + # $TEST$ after ": literal<1>" yield r»« = 1; } `, diff --git a/packages/ttsl-lang/tests/language/lsp/safe-ds-rename-provider.test.ts b/packages/ttsl-lang/tests/language/lsp/safe-ds-rename-provider.test.ts index 27f69ee6..749bd345 100644 --- a/packages/ttsl-lang/tests/language/lsp/safe-ds-rename-provider.test.ts +++ b/packages/ttsl-lang/tests/language/lsp/safe-ds-rename-provider.test.ts @@ -28,14 +28,14 @@ describe('SafeDsRenameProvider', async () => { class MyClass - fun f(p: MyClass) + function f(p: MyClass) `, expectedOutput: ` package test class SomeClass - fun f(p: SomeClass) + function f(p: SomeClass) `, }, ], @@ -61,12 +61,12 @@ describe('SafeDsRenameProvider', async () => { originalContent: ` package test - fun f(p: MyClass) + function f(p: MyClass) `, expectedOutput: ` package test - fun f(p: SomeClass) + function f(p: SomeClass) `, }, ], @@ -94,14 +94,14 @@ describe('SafeDsRenameProvider', async () => { from test import * - fun f(p: MyClass) + function f(p: MyClass) `, expectedOutput: ` package test2 from test import * - fun f(p: SomeClass) + function f(p: SomeClass) `, }, ], @@ -129,14 +129,14 @@ describe('SafeDsRenameProvider', async () => { from test import MyClass - fun f(p: MyClass) + function f(p: MyClass) `, expectedOutput: ` package test2 from test import SomeClass - fun f(p: SomeClass) + function f(p: SomeClass) `, }, ], @@ -164,14 +164,14 @@ describe('SafeDsRenameProvider', async () => { from test import MyClass as MyClass2 - fun f(p: MyClass2) + function f(p: MyClass2) `, expectedOutput: ` package test2 from test import SomeClass as MyClass2 - fun f(p: MyClass2) + function f(p: MyClass2) `, }, ], @@ -199,14 +199,14 @@ describe('SafeDsRenameProvider', async () => { from test import MyClass as MyClass - fun f(p: MyClass) + function f(p: MyClass) `, expectedOutput: ` package test2 from test import SomeClass as MyClass - fun f(p: MyClass) + function f(p: MyClass) `, }, ], @@ -234,14 +234,14 @@ describe('SafeDsRenameProvider', async () => { from test import MyClass as MyClass2 - fun f(p: MyClass) + function f(p: MyClass) `, expectedOutput: ` package test from test import SomeClass as MyClass2 - fun f(p: SomeClass) + function f(p: SomeClass) `, }, ], diff --git a/packages/ttsl-lang/tests/resources/call graph/annotation call.sdstest b/packages/ttsl-lang/tests/resources/call graph/annotation call.sdstest index cd5e95f0..b11f315a 100644 --- a/packages/ttsl-lang/tests/resources/call graph/annotation call.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/annotation call.sdstest @@ -3,6 +3,6 @@ package tests.callGraph.annotationCall annotation MyAnnotation pipeline myPipeline { - // $TEST$ ["undefined"] + # $TEST$ ["undefined"] »MyAnnotation()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/block lambda.sdstest b/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/block lambda.sdstest index 4d4aff34..cd7fd3ed 100644 --- a/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/block lambda.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/block lambda.sdstest @@ -7,7 +7,7 @@ pipeline myPipeline { param1(f); }; - // $TEST$ ["$blockLambda", "$blockLambda", "f"] + # $TEST$ ["$blockLambda", "$blockLambda", "f"] »lambda((param) { param(); })«; diff --git a/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/callable does not get called.sdstest b/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/callable does not get called.sdstest index f792a880..be1b410c 100644 --- a/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/callable does not get called.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/callable does not get called.sdstest @@ -5,6 +5,6 @@ package tests.callGraph.blockLambdaCall.argument.callableDoesNotGetCalled pipeline myPipeline { val lambda = (param: () -> ()) {}; - // $TEST$ ["$blockLambda"] + # $TEST$ ["$blockLambda"] »lambda(f)«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/expression lambda.sdstest b/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/expression lambda.sdstest index b57b5698..7153cbcc 100644 --- a/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/expression lambda.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/expression lambda.sdstest @@ -7,6 +7,6 @@ pipeline myPipeline { param1(f); }; - // $TEST$ ["$blockLambda", "$expressionLambda", "f"] + # $TEST$ ["$blockLambda", "$expressionLambda", "f"] »lambda((param) -> param())«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/function.sdstest b/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/function.sdstest index cd871f01..9dafab06 100644 --- a/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/function.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/function.sdstest @@ -7,6 +7,6 @@ pipeline myPipeline { param(); }; - // $TEST$ ["$blockLambda", "f"] + # $TEST$ ["$blockLambda", "f"] »lambda(f)«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/segment.sdstest b/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/segment.sdstest index 846cf3ec..eefc870a 100644 --- a/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/segment.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/segment.sdstest @@ -7,7 +7,7 @@ pipeline myPipeline { param1(f); }; - // $TEST$ ["$blockLambda", "mySegment", "f"] + # $TEST$ ["$blockLambda", "mySegment", "f"] »lambda(mySegment)«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/block lambda call/basic.sdstest b/packages/ttsl-lang/tests/resources/call graph/block lambda call/basic.sdstest index 748803de..4c8d4123 100644 --- a/packages/ttsl-lang/tests/resources/call graph/block lambda call/basic.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/block lambda call/basic.sdstest @@ -3,6 +3,6 @@ package tests.callGraph.blockLambdaCall.basic pipeline myPipeline { val lambda = () {}; - // $TEST$ ["$blockLambda"] + # $TEST$ ["$blockLambda"] »lambda()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/block lambda call/body/function call in nested lambda.sdstest b/packages/ttsl-lang/tests/resources/call graph/block lambda call/body/function call in nested lambda.sdstest index 8c151f05..472422ac 100644 --- a/packages/ttsl-lang/tests/resources/call graph/block lambda call/body/function call in nested lambda.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/block lambda call/body/function call in nested lambda.sdstest @@ -5,6 +5,6 @@ package tests.callGraph.blockLambdaCall.body.functionCallInNestedLambda pipeline myPipeline { val lambda = () { () -> f(); }; - // $TEST$ ["$blockLambda"] + # $TEST$ ["$blockLambda"] »lambda()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/block lambda call/body/function call.sdstest b/packages/ttsl-lang/tests/resources/call graph/block lambda call/body/function call.sdstest index 0b7b9583..4a6e5039 100644 --- a/packages/ttsl-lang/tests/resources/call graph/block lambda call/body/function call.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/block lambda call/body/function call.sdstest @@ -5,6 +5,6 @@ package tests.callGraph.blockLambdaCall.body.functionCall pipeline myPipeline { val lambda = () { f(); }; - // $TEST$ ["$blockLambda", "f"] + # $TEST$ ["$blockLambda", "f"] »lambda()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/block lambda call/default value/call.sdstest b/packages/ttsl-lang/tests/resources/call graph/block lambda call/default value/call.sdstest index 1db677a7..6bb5d56d 100644 --- a/packages/ttsl-lang/tests/resources/call graph/block lambda call/default value/call.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/block lambda call/default value/call.sdstest @@ -7,6 +7,6 @@ pipeline myPipeline { f: Any = default() ) {}; - // $TEST$ ["$blockLambda", "default"] + # $TEST$ ["$blockLambda", "default"] »lambda()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/block lambda call/default value/callable.sdstest b/packages/ttsl-lang/tests/resources/call graph/block lambda call/default value/callable.sdstest index 6bcb97e8..288a96cd 100644 --- a/packages/ttsl-lang/tests/resources/call graph/block lambda call/default value/callable.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/block lambda call/default value/callable.sdstest @@ -9,6 +9,6 @@ pipeline myPipeline { f(); }; - // $TEST$ ["$blockLambda", "default"] + # $TEST$ ["$blockLambda", "default"] »lambda()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/block lambda call/default value/previous parameter.sdstest b/packages/ttsl-lang/tests/resources/call graph/block lambda call/default value/previous parameter.sdstest index 91200b0c..6856a646 100644 --- a/packages/ttsl-lang/tests/resources/call graph/block lambda call/default value/previous parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/block lambda call/default value/previous parameter.sdstest @@ -8,6 +8,6 @@ pipeline myPipeline { g: Any = f() ) {}; - // $TEST$ ["$blockLambda", "default"] + # $TEST$ ["$blockLambda", "default"] »lambda()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/block lambda call/null safe.sdstest b/packages/ttsl-lang/tests/resources/call graph/block lambda call/null safe.sdstest index 40999c36..ddcb2826 100644 --- a/packages/ttsl-lang/tests/resources/call graph/block lambda call/null safe.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/block lambda call/null safe.sdstest @@ -3,6 +3,6 @@ package tests.callGraph.blockLambdaCall.nullSafe pipeline myPipeline { val lambda = () {}; - // $TEST$ ["$blockLambda"] + # $TEST$ ["$blockLambda"] »lambda?()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/callable type call.sdstest b/packages/ttsl-lang/tests/resources/call graph/callable type call.sdstest index 1ca18602..307c650b 100644 --- a/packages/ttsl-lang/tests/resources/call graph/callable type call.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/callable type call.sdstest @@ -1,6 +1,6 @@ package tests.callGraph.callableTypeCall segment mySegment(param: () -> ()) { - // $TEST$ ["param"] + # $TEST$ ["param"] »param()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/callable/block lambda.sdstest b/packages/ttsl-lang/tests/resources/call graph/callable/block lambda.sdstest index 891b0266..3188873f 100644 --- a/packages/ttsl-lang/tests/resources/call graph/callable/block lambda.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/callable/block lambda.sdstest @@ -4,6 +4,6 @@ package tests.callGraph.callable.blockLambda @Pure fun g() -> r: Any pipeline myPipeline { - // $TEST$ ["$blockLambda", "f", "g"] + # $TEST$ ["$blockLambda", "f", "g"] »(param: Any = f()) { g(); }«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/callable/class.sdstest b/packages/ttsl-lang/tests/resources/call graph/callable/class.sdstest index 68ec2646..2ec64d4e 100644 --- a/packages/ttsl-lang/tests/resources/call graph/callable/class.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/callable/class.sdstest @@ -3,5 +3,5 @@ package tests.callGraph.callable.`class` @Pure fun f() -> r: Any @Pure fun g() -// $TEST$ ["MyClass", "f", "g"] +# $TEST$ ["MyClass", "f", "g"] »class MyClass(param1: Any = f(), param2: () -> () = g)« diff --git a/packages/ttsl-lang/tests/resources/call graph/callable/enum variant.sdstest b/packages/ttsl-lang/tests/resources/call graph/callable/enum variant.sdstest index 8fda813f..fbdd0f18 100644 --- a/packages/ttsl-lang/tests/resources/call graph/callable/enum variant.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/callable/enum variant.sdstest @@ -3,7 +3,7 @@ package tests.callGraph.callable.enumVariant @Pure fun f() -> r: Any @Pure fun g() -// $TEST$ ["MyEnumVariant", "f", "g"] +# $TEST$ ["MyEnumVariant", "f", "g"] enum MyEnum { »MyEnumVariant(param1: Any = f(), param2: () -> () = g)« } diff --git a/packages/ttsl-lang/tests/resources/call graph/callable/expression lambda.sdstest b/packages/ttsl-lang/tests/resources/call graph/callable/expression lambda.sdstest index 1b6af2fd..1a1be867 100644 --- a/packages/ttsl-lang/tests/resources/call graph/callable/expression lambda.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/callable/expression lambda.sdstest @@ -4,6 +4,6 @@ package tests.callGraph.callable.expressionLambda @Pure fun g() -> r: Any pipeline myPipeline { - // $TEST$ ["$expressionLambda", "f", "g"] + # $TEST$ ["$expressionLambda", "f", "g"] »(param: Any = f()) -> g()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/callable/function.sdstest b/packages/ttsl-lang/tests/resources/call graph/callable/function.sdstest index 8d8659fe..756f8b3c 100644 --- a/packages/ttsl-lang/tests/resources/call graph/callable/function.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/callable/function.sdstest @@ -3,5 +3,5 @@ package tests.callGraph.callable.function @Pure fun f() -> r: Any @Pure fun g() -// $TEST$ ["myFunction", "f", "g"] +# $TEST$ ["myFunction", "f", "g"] @Pure »fun myFunction(param1: Any = f(), param2: () -> () = g)« diff --git a/packages/ttsl-lang/tests/resources/call graph/callable/segment.sdstest b/packages/ttsl-lang/tests/resources/call graph/callable/segment.sdstest index 47286ed2..a50d3858 100644 --- a/packages/ttsl-lang/tests/resources/call graph/callable/segment.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/callable/segment.sdstest @@ -3,7 +3,7 @@ package tests.callGraph.callable.`segment` @Pure fun f() -> r: Any @Pure fun g() -> r: Any -// $TEST$ ["mySegment", "f", "g"] +# $TEST$ ["mySegment", "f", "g"] »segment mySegment(param: Any = f()) { g(); }« diff --git a/packages/ttsl-lang/tests/resources/call graph/class call/argument/call.sdstest b/packages/ttsl-lang/tests/resources/call graph/class call/argument/call.sdstest index 90de9e57..4e98f91f 100644 --- a/packages/ttsl-lang/tests/resources/call graph/class call/argument/call.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/class call/argument/call.sdstest @@ -8,6 +8,6 @@ class MyClass( ) pipeline myPipeline { - // $TEST$ ["MyClass"] + # $TEST$ ["MyClass"] »MyClass(Passed())«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/class call/argument/callable.sdstest b/packages/ttsl-lang/tests/resources/call graph/class call/argument/callable.sdstest index 90b51076..f6f13977 100644 --- a/packages/ttsl-lang/tests/resources/call graph/class call/argument/callable.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/class call/argument/callable.sdstest @@ -8,6 +8,6 @@ class MyClass( ) pipeline myPipeline { - // $TEST$ ["MyClass", "Passed"] + # $TEST$ ["MyClass", "Passed"] »MyClass(Passed)«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/class call/argument/other.sdstest b/packages/ttsl-lang/tests/resources/call graph/class call/argument/other.sdstest index 1d4f722f..7aeb0f30 100644 --- a/packages/ttsl-lang/tests/resources/call graph/class call/argument/other.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/class call/argument/other.sdstest @@ -8,6 +8,6 @@ class MyClass( ) pipeline myPipeline { - // $TEST$ ["MyClass"] + # $TEST$ ["MyClass"] »MyClass(1)«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/class call/basic.sdstest b/packages/ttsl-lang/tests/resources/call graph/class call/basic.sdstest index 4f987788..a9172bb0 100644 --- a/packages/ttsl-lang/tests/resources/call graph/class call/basic.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/class call/basic.sdstest @@ -3,6 +3,6 @@ package tests.callGraph.classCall.basic class MyClass() pipeline myPipeline { - // $TEST$ ["MyClass"] + # $TEST$ ["MyClass"] »MyClass()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/class call/default value/call.sdstest b/packages/ttsl-lang/tests/resources/call graph/class call/default value/call.sdstest index 01780506..18fa3df0 100644 --- a/packages/ttsl-lang/tests/resources/call graph/class call/default value/call.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/class call/default value/call.sdstest @@ -8,6 +8,6 @@ class MyClass( ) pipeline myPipeline { - // $TEST$ ["MyClass", "Default"] + # $TEST$ ["MyClass", "Default"] »MyClass()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/class call/default value/callable.sdstest b/packages/ttsl-lang/tests/resources/call graph/class call/default value/callable.sdstest index a32058d8..bc595e51 100644 --- a/packages/ttsl-lang/tests/resources/call graph/class call/default value/callable.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/class call/default value/callable.sdstest @@ -8,6 +8,6 @@ class MyClass( ) pipeline myPipeline { - // $TEST$ ["MyClass", "Default"] + # $TEST$ ["MyClass", "Default"] »MyClass()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/class call/default value/previous parameter.sdstest b/packages/ttsl-lang/tests/resources/call graph/class call/default value/previous parameter.sdstest index 3b944e28..c257691b 100644 --- a/packages/ttsl-lang/tests/resources/call graph/class call/default value/previous parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/class call/default value/previous parameter.sdstest @@ -8,6 +8,6 @@ class MyClass( ) pipeline myPipeline { - // $TEST$ ["MyClass", "default", "default"] + # $TEST$ ["MyClass", "default", "default"] »MyClass()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/class call/null safe.sdstest b/packages/ttsl-lang/tests/resources/call graph/class call/null safe.sdstest index 820cc675..055ea6a8 100644 --- a/packages/ttsl-lang/tests/resources/call graph/class call/null safe.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/class call/null safe.sdstest @@ -3,6 +3,6 @@ package tests.callGraph.classCall.nullSafe class MyClass() pipeline myPipeline { - // $TEST$ ["MyClass"] + # $TEST$ ["MyClass"] »MyClass?()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/closure/block lambda passed as argument.sdstest b/packages/ttsl-lang/tests/resources/call graph/closure/block lambda passed as argument.sdstest index 225fb80e..3acf8952 100644 --- a/packages/ttsl-lang/tests/resources/call graph/closure/block lambda passed as argument.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/closure/block lambda passed as argument.sdstest @@ -13,6 +13,6 @@ segment mySegment2(param2: () -> ()) { } pipeline myPipeline { - // $TEST$ ["mySegment1", "mySegment2", "$blockLambda", "$blockLambda", "f"] + # $TEST$ ["mySegment1", "mySegment2", "$blockLambda", "$blockLambda", "f"] »mySegment1(() { f(); })«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/closure/block lambda returned.sdstest b/packages/ttsl-lang/tests/resources/call graph/closure/block lambda returned.sdstest index 07f2d53a..524871c8 100644 --- a/packages/ttsl-lang/tests/resources/call graph/closure/block lambda returned.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/closure/block lambda returned.sdstest @@ -10,6 +10,6 @@ pipeline myPipeline { }; val closure = lambda(f); - // $TEST$ ["$blockLambda", "f"] + # $TEST$ ["$blockLambda", "f"] »closure()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/closure/expression lambda passed as argument.sdstest b/packages/ttsl-lang/tests/resources/call graph/closure/expression lambda passed as argument.sdstest index 14a793f9..83c018e6 100644 --- a/packages/ttsl-lang/tests/resources/call graph/closure/expression lambda passed as argument.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/closure/expression lambda passed as argument.sdstest @@ -11,6 +11,6 @@ segment mySegment2(param2: () -> ()) { } pipeline myPipeline { - // $TEST$ ["mySegment1", "mySegment2", "$expressionLambda", "$expressionLambda", "f"] + # $TEST$ ["mySegment1", "mySegment2", "$expressionLambda", "$expressionLambda", "f"] »mySegment1(() -> f())«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/closure/expression lambda returned.sdstest b/packages/ttsl-lang/tests/resources/call graph/closure/expression lambda returned.sdstest index d8156494..84e78921 100644 --- a/packages/ttsl-lang/tests/resources/call graph/closure/expression lambda returned.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/closure/expression lambda returned.sdstest @@ -8,6 +8,6 @@ pipeline myPipeline { () -> param(); val closure = lambda(f); - // $TEST$ ["$expressionLambda", "f"] + # $TEST$ ["$expressionLambda", "f"] »closure()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/default value handling in entry point.sdstest b/packages/ttsl-lang/tests/resources/call graph/default value handling in entry point.sdstest index 1aadbec4..883d1b18 100644 --- a/packages/ttsl-lang/tests/resources/call graph/default value handling in entry point.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/default value handling in entry point.sdstest @@ -7,6 +7,6 @@ package tests.callGraph.defaultValueHandlingInEntryPoint @Pure fun default() -> r: Any segment mySegment(param: () -> () = default) { - // $TEST$ ["param"] + # $TEST$ ["param"] »param()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/enum variant call/argument/call.sdstest b/packages/ttsl-lang/tests/resources/call graph/enum variant call/argument/call.sdstest index 11d19c1d..590a4a0c 100644 --- a/packages/ttsl-lang/tests/resources/call graph/enum variant call/argument/call.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/enum variant call/argument/call.sdstest @@ -10,6 +10,6 @@ enum MyEnum { } pipeline myPipeline { - // $TEST$ ["MyVariant"] + # $TEST$ ["MyVariant"] »MyEnum.MyVariant(passed())«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/enum variant call/argument/callable.sdstest b/packages/ttsl-lang/tests/resources/call graph/enum variant call/argument/callable.sdstest index c2846b01..0a656665 100644 --- a/packages/ttsl-lang/tests/resources/call graph/enum variant call/argument/callable.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/enum variant call/argument/callable.sdstest @@ -10,6 +10,6 @@ enum MyEnum { } pipeline myPipeline { - // $TEST$ ["MyVariant", "passed"] + # $TEST$ ["MyVariant", "passed"] »MyEnum.MyVariant(passed)«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/enum variant call/argument/other.sdstest b/packages/ttsl-lang/tests/resources/call graph/enum variant call/argument/other.sdstest index 6b1082e5..b23a5ae4 100644 --- a/packages/ttsl-lang/tests/resources/call graph/enum variant call/argument/other.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/enum variant call/argument/other.sdstest @@ -10,6 +10,6 @@ enum MyEnum { } pipeline myPipeline { - // $TEST$ ["MyVariant"] + # $TEST$ ["MyVariant"] »MyEnum.MyVariant(1)«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/enum variant call/basic.sdstest b/packages/ttsl-lang/tests/resources/call graph/enum variant call/basic.sdstest index 6ccdec78..b2664a6a 100644 --- a/packages/ttsl-lang/tests/resources/call graph/enum variant call/basic.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/enum variant call/basic.sdstest @@ -5,6 +5,6 @@ enum MyEnum { } pipeline myPipeline { - // $TEST$ ["MyVariant"] + # $TEST$ ["MyVariant"] »MyEnum.MyVariant()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/enum variant call/called twice.sdstest b/packages/ttsl-lang/tests/resources/call graph/enum variant call/called twice.sdstest index 8c521fd4..f52a9686 100644 --- a/packages/ttsl-lang/tests/resources/call graph/enum variant call/called twice.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/enum variant call/called twice.sdstest @@ -5,6 +5,6 @@ enum MyEnum { } pipeline myPipeline { - // $TEST$ ["undefined"] + # $TEST$ ["undefined"] »MyEnum.MyVariant()()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/enum variant call/default value/call.sdstest b/packages/ttsl-lang/tests/resources/call graph/enum variant call/default value/call.sdstest index 12e4a7e0..3882471c 100644 --- a/packages/ttsl-lang/tests/resources/call graph/enum variant call/default value/call.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/enum variant call/default value/call.sdstest @@ -10,6 +10,6 @@ enum MyEnum { } pipeline myPipeline { - // $TEST$ ["MyVariant", "default"] + # $TEST$ ["MyVariant", "default"] »MyEnum.MyVariant()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/enum variant call/default value/callable.sdstest b/packages/ttsl-lang/tests/resources/call graph/enum variant call/default value/callable.sdstest index 90aebe9d..333a83bb 100644 --- a/packages/ttsl-lang/tests/resources/call graph/enum variant call/default value/callable.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/enum variant call/default value/callable.sdstest @@ -10,6 +10,6 @@ enum MyEnum { } pipeline myPipeline { - // $TEST$ ["MyVariant", "default"] + # $TEST$ ["MyVariant", "default"] »MyEnum.MyVariant()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/enum variant call/default value/previous parameter.sdstest b/packages/ttsl-lang/tests/resources/call graph/enum variant call/default value/previous parameter.sdstest index 4dde1013..19d0b6d4 100644 --- a/packages/ttsl-lang/tests/resources/call graph/enum variant call/default value/previous parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/enum variant call/default value/previous parameter.sdstest @@ -10,6 +10,6 @@ enum MyEnum { } pipeline myPipeline { - // $TEST$ ["MyVariant", "default", "default"] + # $TEST$ ["MyVariant", "default", "default"] »MyEnum.MyVariant()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/enum variant call/null safe.sdstest b/packages/ttsl-lang/tests/resources/call graph/enum variant call/null safe.sdstest index 57794cb0..4f7ce9f1 100644 --- a/packages/ttsl-lang/tests/resources/call graph/enum variant call/null safe.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/enum variant call/null safe.sdstest @@ -5,6 +5,6 @@ enum MyEnum { } pipeline myPipeline { - // $TEST$ ["MyVariant"] + # $TEST$ ["MyVariant"] »MyEnum.MyVariant?()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/block lambda.sdstest b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/block lambda.sdstest index 76018d4a..b70971c9 100644 --- a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/block lambda.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/block lambda.sdstest @@ -6,7 +6,7 @@ pipeline myPipeline { val lambda = (param1: (param: () -> ()) -> ()) -> param1(f); - // $TEST$ ["$expressionLambda", "$blockLambda", "f"] + # $TEST$ ["$expressionLambda", "$blockLambda", "f"] »lambda((param) { param(); })«; diff --git a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/callable does not get called.sdstest b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/callable does not get called.sdstest index 64aef28f..14f00c1a 100644 --- a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/callable does not get called.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/callable does not get called.sdstest @@ -5,6 +5,6 @@ package tests.callGraph.expressionLambdaCall.argument.callableDoesNotGetCalled pipeline myPipeline { val lambda = (param: () -> ()) -> 1; - // $TEST$ ["$expressionLambda"] + # $TEST$ ["$expressionLambda"] »lambda(f)«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/expression lambda.sdstest b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/expression lambda.sdstest index 0a29cff1..c8db1bda 100644 --- a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/expression lambda.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/expression lambda.sdstest @@ -6,6 +6,6 @@ pipeline myPipeline { val lambda = (param1: (param: () -> ()) -> ()) -> param1(f); - // $TEST$ ["$expressionLambda", "$expressionLambda", "f"] + # $TEST$ ["$expressionLambda", "$expressionLambda", "f"] »lambda((param) -> param())«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/function.sdstest b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/function.sdstest index b98eca57..5cf8bad7 100644 --- a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/function.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/function.sdstest @@ -6,6 +6,6 @@ pipeline myPipeline { val lambda = (param: () -> ()) -> param(); - // $TEST$ ["$expressionLambda", "f"] + # $TEST$ ["$expressionLambda", "f"] »lambda(f)«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/segment.sdstest b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/segment.sdstest index 4346e3b0..11c00507 100644 --- a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/segment.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/segment.sdstest @@ -6,7 +6,7 @@ pipeline myPipeline { val lambda = (param1: (param: () -> ()) -> ()) -> param1(f); - // $TEST$ ["$expressionLambda", "mySegment", "f"] + # $TEST$ ["$expressionLambda", "mySegment", "f"] »lambda(mySegment)«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/basic.sdstest b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/basic.sdstest index a9049d41..38aef9e7 100644 --- a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/basic.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/basic.sdstest @@ -3,6 +3,6 @@ package tests.callGraph.expressionLambdaCall.basic pipeline myPipeline { val lambda = () -> 1; - // $TEST$ ["$expressionLambda"] + # $TEST$ ["$expressionLambda"] »lambda()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/body/function call in nested lambda.sdstest b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/body/function call in nested lambda.sdstest index 53ade196..891b2ddd 100644 --- a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/body/function call in nested lambda.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/body/function call in nested lambda.sdstest @@ -5,6 +5,6 @@ package tests.callGraph.expressionLambdaCall.body.functionCallInNestedLambda pipeline myPipeline { val lambda = () -> () -> f(); - // $TEST$ ["$expressionLambda"] + # $TEST$ ["$expressionLambda"] »lambda()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/body/function call.sdstest b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/body/function call.sdstest index 02efa731..77d1f41f 100644 --- a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/body/function call.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/body/function call.sdstest @@ -5,6 +5,6 @@ package tests.callGraph.expressionLambdaCall.body.functionCall pipeline myPipeline { val lambda = () -> f(); - // $TEST$ ["$expressionLambda", "f"] + # $TEST$ ["$expressionLambda", "f"] »lambda()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/default value/call.sdstest b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/default value/call.sdstest index 4cfffd24..96e6e3fe 100644 --- a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/default value/call.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/default value/call.sdstest @@ -7,6 +7,6 @@ pipeline myPipeline { f: Any = default() ) -> 1; - // $TEST$ ["$expressionLambda", "default"] + # $TEST$ ["$expressionLambda", "default"] »lambda()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/default value/callable.sdstest b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/default value/callable.sdstest index a2172d75..dd5c84a9 100644 --- a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/default value/callable.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/default value/callable.sdstest @@ -7,6 +7,6 @@ pipeline myPipeline { f: () -> () = default ) -> f(); - // $TEST$ ["$expressionLambda", "default"] + # $TEST$ ["$expressionLambda", "default"] »lambda()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/default value/previous parameter.sdstest b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/default value/previous parameter.sdstest index 95f6740c..ffe60681 100644 --- a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/default value/previous parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/default value/previous parameter.sdstest @@ -8,6 +8,6 @@ pipeline myPipeline { g: Any = f() ) -> 1; - // $TEST$ ["$expressionLambda", "default"] + # $TEST$ ["$expressionLambda", "default"] »lambda()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/null safe.sdstest b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/null safe.sdstest index 96354110..cf5b12f7 100644 --- a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/null safe.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/null safe.sdstest @@ -3,6 +3,6 @@ package tests.callGraph.expressionLambdaCall.nullSafe pipeline myPipeline { val lambda = () -> 1; - // $TEST$ ["$expressionLambda"] + # $TEST$ ["$expressionLambda"] »lambda?()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/function call/argument/call.sdstest b/packages/ttsl-lang/tests/resources/call graph/function call/argument/call.sdstest index 2316706e..773b1521 100644 --- a/packages/ttsl-lang/tests/resources/call graph/function call/argument/call.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/function call/argument/call.sdstest @@ -8,6 +8,6 @@ package tests.callGraph.functionCall.argument.call ) pipeline myPipeline { - // $TEST$ ["myFunction"] + # $TEST$ ["myFunction"] »myFunction(passed())«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/function call/argument/callable.sdstest b/packages/ttsl-lang/tests/resources/call graph/function call/argument/callable.sdstest index 11e86680..bd98f406 100644 --- a/packages/ttsl-lang/tests/resources/call graph/function call/argument/callable.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/function call/argument/callable.sdstest @@ -8,6 +8,6 @@ package tests.callGraph.functionCall.argument.callable ) pipeline myPipeline { - // $TEST$ ["myFunction", "passed"] + # $TEST$ ["myFunction", "passed"] »myFunction(passed)«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/function call/argument/other.sdstest b/packages/ttsl-lang/tests/resources/call graph/function call/argument/other.sdstest index adf0c5ed..8ece5918 100644 --- a/packages/ttsl-lang/tests/resources/call graph/function call/argument/other.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/function call/argument/other.sdstest @@ -8,6 +8,6 @@ package tests.callGraph.functionCall.argument.other ) pipeline myPipeline { - // $TEST$ ["myFunction"] + # $TEST$ ["myFunction"] »myFunction(1)«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/function call/basic.sdstest b/packages/ttsl-lang/tests/resources/call graph/function call/basic.sdstest index 7ede6cbc..45398ce3 100644 --- a/packages/ttsl-lang/tests/resources/call graph/function call/basic.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/function call/basic.sdstest @@ -3,6 +3,6 @@ package tests.callGraph.functionCall.basic @Pure fun myFunction() pipeline myPipeline { - // $TEST$ ["myFunction"] + # $TEST$ ["myFunction"] »myFunction()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/function call/default value/call.sdstest b/packages/ttsl-lang/tests/resources/call graph/function call/default value/call.sdstest index e7524ff0..f29f485c 100644 --- a/packages/ttsl-lang/tests/resources/call graph/function call/default value/call.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/function call/default value/call.sdstest @@ -8,6 +8,6 @@ package tests.callGraph.functionCall.defaultValue.call ) pipeline myPipeline { - // $TEST$ ["myFunction", "default"] + # $TEST$ ["myFunction", "default"] »myFunction()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/function call/default value/callable.sdstest b/packages/ttsl-lang/tests/resources/call graph/function call/default value/callable.sdstest index a5152dd4..429ac9f3 100644 --- a/packages/ttsl-lang/tests/resources/call graph/function call/default value/callable.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/function call/default value/callable.sdstest @@ -8,6 +8,6 @@ package tests.callGraph.functionCall.defaultValue.callable ) pipeline myPipeline { - // $TEST$ ["myFunction", "default"] + # $TEST$ ["myFunction", "default"] »myFunction()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/function call/default value/previous parameter.sdstest b/packages/ttsl-lang/tests/resources/call graph/function call/default value/previous parameter.sdstest index 8f7a602c..3677b21d 100644 --- a/packages/ttsl-lang/tests/resources/call graph/function call/default value/previous parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/function call/default value/previous parameter.sdstest @@ -8,6 +8,6 @@ package tests.callGraph.functionCall.defaultValue.previousParameter ) pipeline myPipeline { - // $TEST$ ["myFunction", "default", "default"] + # $TEST$ ["myFunction", "default", "default"] »myFunction()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/function call/instance method.sdstest b/packages/ttsl-lang/tests/resources/call graph/function call/instance method.sdstest index 74ed9f83..c312edcc 100644 --- a/packages/ttsl-lang/tests/resources/call graph/function call/instance method.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/function call/instance method.sdstest @@ -5,6 +5,6 @@ class MyClass { } pipeline myPipeline { - // $TEST$ ["myFunction"] + # $TEST$ ["myFunction"] »MyClass().myFunction()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/function call/null safe.sdstest b/packages/ttsl-lang/tests/resources/call graph/function call/null safe.sdstest index c2d4effb..37b40dbf 100644 --- a/packages/ttsl-lang/tests/resources/call graph/function call/null safe.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/function call/null safe.sdstest @@ -11,15 +11,15 @@ segment mySegment( myClass: MyClass, myClassOrNull: MyClass? ) { - // $TEST$ ["myFunction"] + # $TEST$ ["myFunction"] »myFunction?()«; - // $TEST$ ["myStaticMethod"] + # $TEST$ ["myStaticMethod"] »MyClass.myStaticMethod?()«; - // $TEST$ ["myInstanceMethod"] + # $TEST$ ["myInstanceMethod"] »myClass.myInstanceMethod?()«; - // $TEST$ ["myInstanceMethod"] + # $TEST$ ["myInstanceMethod"] »myClassOrNull?.myInstanceMethod?()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/function call/static method.sdstest b/packages/ttsl-lang/tests/resources/call graph/function call/static method.sdstest index 092b5f9d..eca7819e 100644 --- a/packages/ttsl-lang/tests/resources/call graph/function call/static method.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/function call/static method.sdstest @@ -5,6 +5,6 @@ class MyClass { } pipeline myPipeline { - // $TEST$ ["myFunction"] + # $TEST$ ["myFunction"] »MyClass.myFunction()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/recursion/direct.sdstest b/packages/ttsl-lang/tests/resources/call graph/recursion/direct.sdstest index 7cb6cc27..f871442b 100644 --- a/packages/ttsl-lang/tests/resources/call graph/recursion/direct.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/recursion/direct.sdstest @@ -1,16 +1,16 @@ package tests.callGraph.recursion.direct segment s1() { - // $TEST$ ["s2", "s3", "s2"] + # $TEST$ ["s2", "s3", "s2"] »s2()«; } segment s2() { - // $TEST$ ["s3", "s2", "s3"] + # $TEST$ ["s3", "s2", "s3"] »s3()«; } segment s3() { - // $TEST$ ["s2", "s3", "s2"] + # $TEST$ ["s2", "s3", "s2"] »s2()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/recursion/not recursive.sdstest b/packages/ttsl-lang/tests/resources/call graph/recursion/not recursive.sdstest index 00a9c424..9264d97c 100644 --- a/packages/ttsl-lang/tests/resources/call graph/recursion/not recursive.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/recursion/not recursive.sdstest @@ -6,7 +6,7 @@ package tests.callGraph.recursion.notRecursive */ segment s1() { - // $TEST$ ["s2", "$expressionLambda", "s2", "$blockLambda"] + # $TEST$ ["s2", "$expressionLambda", "s2", "$blockLambda"] »s2(() -> s2())«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/recursion/transitive via function pointer argument.sdstest b/packages/ttsl-lang/tests/resources/call graph/recursion/transitive via function pointer argument.sdstest index 1bb89500..53aff241 100644 --- a/packages/ttsl-lang/tests/resources/call graph/recursion/transitive via function pointer argument.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/recursion/transitive via function pointer argument.sdstest @@ -1,7 +1,7 @@ package tests.callGraph.recursion.transitiveViaFunctionPointerArgument segment s1() { - // $TEST$ ["s2", "s1", "s2"] + # $TEST$ ["s2", "s1", "s2"] »s2(s1)«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/recursion/transitive via lambda argument.sdstest b/packages/ttsl-lang/tests/resources/call graph/recursion/transitive via lambda argument.sdstest index 041103cf..204e3794 100644 --- a/packages/ttsl-lang/tests/resources/call graph/recursion/transitive via lambda argument.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/recursion/transitive via lambda argument.sdstest @@ -1,7 +1,7 @@ package tests.callGraph.recursion.transitiveViaLambdaArgument segment s1() { - // $TEST$ ["s2", "$expressionLambda", "s1", "s2"] + # $TEST$ ["s2", "$expressionLambda", "s1", "s2"] »s2(() -> s1())«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/recursion/transitive.sdstest b/packages/ttsl-lang/tests/resources/call graph/recursion/transitive.sdstest index 4348ff90..d862cc1c 100644 --- a/packages/ttsl-lang/tests/resources/call graph/recursion/transitive.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/recursion/transitive.sdstest @@ -1,16 +1,16 @@ package tests.callGraph.recursion.transitive segment s1() { - // $TEST$ ["s2", "s3", "s1", "s2"] + # $TEST$ ["s2", "s3", "s1", "s2"] »s2()«; } segment s2() { - // $TEST$ ["s3", "s1", "s2", "s3"] + # $TEST$ ["s3", "s1", "s2", "s3"] »s3()«; } segment s3() { - // $TEST$ ["s1", "s2", "s3", "s1"] + # $TEST$ ["s1", "s2", "s3", "s1"] »s1()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/segment call/argument/block lambda.sdstest b/packages/ttsl-lang/tests/resources/call graph/segment call/argument/block lambda.sdstest index 0964a736..9dc2a0fc 100644 --- a/packages/ttsl-lang/tests/resources/call graph/segment call/argument/block lambda.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/segment call/argument/block lambda.sdstest @@ -7,7 +7,7 @@ segment mySegment(param1: (param: () -> ()) -> ()) { } pipeline myPipeline { - // $TEST$ ["mySegment", "$blockLambda", "f"] + # $TEST$ ["mySegment", "$blockLambda", "f"] »mySegment((param) { param(); })«; diff --git a/packages/ttsl-lang/tests/resources/call graph/segment call/argument/callable does not get called.sdstest b/packages/ttsl-lang/tests/resources/call graph/segment call/argument/callable does not get called.sdstest index dc071201..9435509b 100644 --- a/packages/ttsl-lang/tests/resources/call graph/segment call/argument/callable does not get called.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/segment call/argument/callable does not get called.sdstest @@ -5,6 +5,6 @@ package tests.callGraph.segmentCall.argument.callableDoesNotGetCalled segment mySegment(param: () -> ()) {} pipeline myPipeline { - // $TEST$ ["mySegment"] + # $TEST$ ["mySegment"] »mySegment(f)«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/segment call/argument/expression lambda.sdstest b/packages/ttsl-lang/tests/resources/call graph/segment call/argument/expression lambda.sdstest index d98db885..d4c49b46 100644 --- a/packages/ttsl-lang/tests/resources/call graph/segment call/argument/expression lambda.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/segment call/argument/expression lambda.sdstest @@ -7,6 +7,6 @@ segment mySegment(param1: (param: () -> ()) -> ()) { } pipeline myPipeline { - // $TEST$ ["mySegment", "$expressionLambda", "f"] + # $TEST$ ["mySegment", "$expressionLambda", "f"] »mySegment((param) -> param())«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/segment call/argument/function.sdstest b/packages/ttsl-lang/tests/resources/call graph/segment call/argument/function.sdstest index 636eb15c..81dcbfaa 100644 --- a/packages/ttsl-lang/tests/resources/call graph/segment call/argument/function.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/segment call/argument/function.sdstest @@ -7,6 +7,6 @@ segment mySegment(param: () -> ()) { } pipeline myPipeline { - // $TEST$ ["mySegment", "f"] + # $TEST$ ["mySegment", "f"] »mySegment(f)«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/segment call/argument/segment.sdstest b/packages/ttsl-lang/tests/resources/call graph/segment call/argument/segment.sdstest index 7ce228e8..f8573c98 100644 --- a/packages/ttsl-lang/tests/resources/call graph/segment call/argument/segment.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/segment call/argument/segment.sdstest @@ -11,6 +11,6 @@ segment mySegment2(param: () -> ()) { } pipeline myPipeline { - // $TEST$ ["mySegment1", "mySegment2", "f"] + # $TEST$ ["mySegment1", "mySegment2", "f"] »mySegment1(mySegment2)«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/segment call/basic.sdstest b/packages/ttsl-lang/tests/resources/call graph/segment call/basic.sdstest index 6efed0c9..1ffae6e9 100644 --- a/packages/ttsl-lang/tests/resources/call graph/segment call/basic.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/segment call/basic.sdstest @@ -3,6 +3,6 @@ package tests.callGraph.segmentCall.basic segment mySegment() {} pipeline myPipeline { - // $TEST$ ["mySegment"] + # $TEST$ ["mySegment"] »mySegment()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/segment call/body/function call in nested lambda.sdstest b/packages/ttsl-lang/tests/resources/call graph/segment call/body/function call in nested lambda.sdstest index 7b3b98d5..55eefc54 100644 --- a/packages/ttsl-lang/tests/resources/call graph/segment call/body/function call in nested lambda.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/segment call/body/function call in nested lambda.sdstest @@ -7,6 +7,6 @@ segment mySegment() { } pipeline myPipeline { - // $TEST$ ["mySegment"] + # $TEST$ ["mySegment"] »mySegment()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/segment call/body/function call.sdstest b/packages/ttsl-lang/tests/resources/call graph/segment call/body/function call.sdstest index cd2f7a3e..0fdccecd 100644 --- a/packages/ttsl-lang/tests/resources/call graph/segment call/body/function call.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/segment call/body/function call.sdstest @@ -7,6 +7,6 @@ segment mySegment() { } pipeline myPipeline { - // $TEST$ ["mySegment", "f"] + # $TEST$ ["mySegment", "f"] »mySegment()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/segment call/default value/call.sdstest b/packages/ttsl-lang/tests/resources/call graph/segment call/default value/call.sdstest index f6e337bd..016cf227 100644 --- a/packages/ttsl-lang/tests/resources/call graph/segment call/default value/call.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/segment call/default value/call.sdstest @@ -7,6 +7,6 @@ segment mySegment( ) {} pipeline myPipeline { - // $TEST$ ["mySegment", "default"] + # $TEST$ ["mySegment", "default"] »mySegment()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/segment call/default value/callable.sdstest b/packages/ttsl-lang/tests/resources/call graph/segment call/default value/callable.sdstest index 0b4af441..43144eb2 100644 --- a/packages/ttsl-lang/tests/resources/call graph/segment call/default value/callable.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/segment call/default value/callable.sdstest @@ -9,6 +9,6 @@ segment mySegment( } pipeline myPipeline { - // $TEST$ ["mySegment", "default"] + # $TEST$ ["mySegment", "default"] »mySegment()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/segment call/default value/previous parameter.sdstest b/packages/ttsl-lang/tests/resources/call graph/segment call/default value/previous parameter.sdstest index f64ce4c2..bba75d39 100644 --- a/packages/ttsl-lang/tests/resources/call graph/segment call/default value/previous parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/segment call/default value/previous parameter.sdstest @@ -8,6 +8,6 @@ segment mySegment( ) {} pipeline myPipeline { - // $TEST$ ["mySegment", "default"] + # $TEST$ ["mySegment", "default"] »mySegment()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/segment call/null safe.sdstest b/packages/ttsl-lang/tests/resources/call graph/segment call/null safe.sdstest index ae3ea8b2..e2b523a0 100644 --- a/packages/ttsl-lang/tests/resources/call graph/segment call/null safe.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/segment call/null safe.sdstest @@ -3,6 +3,6 @@ package tests.callGraph.segmentCall.nullSafe segment mySegment() {} pipeline myPipeline { - // $TEST$ ["mySegment"] + # $TEST$ ["mySegment"] »mySegment?()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/unresolved callable.sdstest b/packages/ttsl-lang/tests/resources/call graph/unresolved callable.sdstest index d3157370..241575c8 100644 --- a/packages/ttsl-lang/tests/resources/call graph/unresolved callable.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/unresolved callable.sdstest @@ -1,6 +1,6 @@ package tests.callGraph.unresolvedCallable pipeline myPipeline { - // $TEST$ ["undefined"] + # $TEST$ ["undefined"] »unresolved()«; } diff --git a/packages/ttsl-lang/tests/resources/formatting/modules/empty.sdstest b/packages/ttsl-lang/tests/resources/formatting/modules/empty.sdstest index 2acf4e33..d9fa8eb9 100644 --- a/packages/ttsl-lang/tests/resources/formatting/modules/empty.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/modules/empty.sdstest @@ -1,5 +1,5 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error // ----------------------------------------------------------------------------- -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error diff --git a/packages/ttsl-lang/tests/resources/generation/partial/impure dependency file constant/input.sdstest b/packages/ttsl-lang/tests/resources/generation/partial/impure dependency file constant/input.sdstest index b7b0a73f..6e0e456e 100644 --- a/packages/ttsl-lang/tests/resources/generation/partial/impure dependency file constant/input.sdstest +++ b/packages/ttsl-lang/tests/resources/generation/partial/impure dependency file constant/input.sdstest @@ -19,6 +19,6 @@ pipeline testPipeline { val impureFileWrite2B = iFileWriteB(); val impureFileReadAgainB = iFileReadB(); - // $TEST$ run_until + # $TEST$ run_until val »result« = impureFileReadAgain + impureFileReadAgainB; } diff --git a/packages/ttsl-lang/tests/resources/generation/partial/impure dependency file parameter/input.sdstest b/packages/ttsl-lang/tests/resources/generation/partial/impure dependency file parameter/input.sdstest index 37b3816a..6deb24d6 100644 --- a/packages/ttsl-lang/tests/resources/generation/partial/impure dependency file parameter/input.sdstest +++ b/packages/ttsl-lang/tests/resources/generation/partial/impure dependency file parameter/input.sdstest @@ -10,6 +10,6 @@ pipeline testPipeline { val impureFileWrite2 = iFileWrite("c.txt"); val impureFileReadAgain = iFileRead("d.txt"); - // $TEST$ run_until + # $TEST$ run_until val »result« = impureFileReadAgain + 2; } diff --git a/packages/ttsl-lang/tests/resources/generation/partial/impure dependency/input.sdstest b/packages/ttsl-lang/tests/resources/generation/partial/impure dependency/input.sdstest index 8843682b..173818b1 100644 --- a/packages/ttsl-lang/tests/resources/generation/partial/impure dependency/input.sdstest +++ b/packages/ttsl-lang/tests/resources/generation/partial/impure dependency/input.sdstest @@ -32,7 +32,7 @@ pipeline testPipeline { val impureA2 = i1(noPartialEvalInt(pureValueForImpure3)); i1(4); - // $TEST$ run_until + # $TEST$ run_until val »result« = i1(impureA2); i1(4); // Should not be generated - impure cannot affect result after result is already calculated val someImpureValue = i1(4); // Should not be generated - impure cannot affect result after result is already calculated diff --git a/packages/ttsl-lang/tests/resources/generation/partial/pure dependency/input.sdstest b/packages/ttsl-lang/tests/resources/generation/partial/pure dependency/input.sdstest index 64a9cf85..81b14156 100644 --- a/packages/ttsl-lang/tests/resources/generation/partial/pure dependency/input.sdstest +++ b/packages/ttsl-lang/tests/resources/generation/partial/pure dependency/input.sdstest @@ -75,7 +75,7 @@ line"; val listResult = g3(list); val listResult2 = g3(list2); // Should not be generated - // $TEST$ run_until + # $TEST$ run_until val »result« = -o + 1 + value1 + mapResult * listResult / g4(listValue); val lDouble3 = 1.0; // Should not be generated - pure cannot affect result after result is already calculated diff --git a/packages/ttsl-lang/tests/resources/generation/partial/redundant impurity/input.sdstest b/packages/ttsl-lang/tests/resources/generation/partial/redundant impurity/input.sdstest index 16cce682..5ebb4386 100644 --- a/packages/ttsl-lang/tests/resources/generation/partial/redundant impurity/input.sdstest +++ b/packages/ttsl-lang/tests/resources/generation/partial/redundant impurity/input.sdstest @@ -31,7 +31,7 @@ pipeline testPipeline { val impureA2 = i1(noPartialEvalInt(pureValueForImpure3)); // Should not be generated - cannot affect result i1(4); // Should not be generated - impure can not have effects on future statements as they are pure - // $TEST$ run_until + # $TEST$ run_until val »result« = pureValue - 1; i1(4); // Should not be generated - impure cannot affect result after result is already calculated val someImpureValue = i1(4); // Should not be generated - impure cannot affect result after result is already calculated diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/bad-unclosed argument list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/bad-unclosed argument list.sdstest index 8e537c4c..eed8dd65 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/bad-unclosed argument list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/bad-unclosed argument list.sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error @Annotation( diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-empty argument list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-empty argument list.sdstest index af0cf406..7bb2a9ef 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-empty argument list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-empty argument list.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error @Annotation() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-multiple arguments.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-multiple arguments.sdstest index 7c510cf6..366f6954 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-multiple arguments.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-multiple arguments.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error @Annotation(1, a = 2) diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-named argument.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-named argument.sdstest index ba199336..88d181f6 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-named argument.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-named argument.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error @Annotation(b = 2) diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-no argument list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-no argument list.sdstest index b0f0c598..c9aa7ba9 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-no argument list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-no argument list.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error @Annotation diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-positional argument.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-positional argument.sdstest index 319c6983..455f3a32 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-positional argument.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-positional argument.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error @Annotation(1) diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/bad-unclosed constraint list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/bad-unclosed constraint list.sdstest index 4116a938..ab9d5ec5 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/bad-unclosed constraint list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/bad-unclosed constraint list.sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error annotation MyAnnotation where { diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/bad-unclosed parameter list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/bad-unclosed parameter list.sdstest index ec0beccf..92e2e212 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/bad-unclosed parameter list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/bad-unclosed parameter list.sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error annotation MyAnnotation( diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/good-annotation call.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/good-annotation call.sdstest index d867f6cb..d6c6c59d 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/good-annotation call.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/good-annotation call.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error package test diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/good-no parameter list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/good-no parameter list.sdstest index a4a5a34d..58c9da3d 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/good-no parameter list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/good-no parameter list.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error annotation MyAnnotation diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/good-with constraint list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/good-with constraint list.sdstest index 19cb167c..5aca6aaa 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/good-with constraint list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/good-with constraint list.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error annotation MyAnnotation where {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/good-with parameter list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/good-with parameter list.sdstest index 54d35f27..2679d074 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/good-with parameter list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/good-with parameter list.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error annotation MyAnnotation() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/attributes/good-annotated.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/attributes/good-annotated.sdstest index 11ebf0fc..e56dd849 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/attributes/good-annotated.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/attributes/good-annotated.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error class MyClass { @Annotation attr a diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/attributes/good-no type.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/attributes/good-no type.sdstest index 1b683279..a8dc0143 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/attributes/good-no type.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/attributes/good-no type.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error class MyClass { attr a diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/attributes/good-static.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/attributes/good-static.sdstest index c256ad51..27b9a168 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/attributes/good-static.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/attributes/good-static.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error class MyClass { static attr a: Int diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/attributes/good-with type.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/attributes/good-with type.sdstest index 8c5eaa37..14ac1d6c 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/attributes/good-with type.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/attributes/good-with type.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error class MyClass { attr a: Int diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-empty parent type list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-empty parent type list.sdstest index a4bb256c..0e57bbf9 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-empty parent type list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-empty parent type list.sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error class MyClass sub diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-unclosed body.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-unclosed body.sdstest index 87b9a8c4..5d592849 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-unclosed body.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-unclosed body.sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error class MyClass { diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-unclosed constraint list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-unclosed constraint list.sdstest index bb2ac2a4..1e008138 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-unclosed constraint list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-unclosed constraint list.sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error class MyClass where { diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-unclosed parameter list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-unclosed parameter list.sdstest index 63fd5d81..41d1dc8d 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-unclosed parameter list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-unclosed parameter list.sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error class MyClass( diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-unclosed type parameter list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-unclosed type parameter list.sdstest index a86d4586..dc758216 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-unclosed type parameter list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-unclosed type parameter list.sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error class MyClass< diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-annotation call.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-annotation call.sdstest index c86c9b5b..14e7f34e 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-annotation call.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-annotation call.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error package test diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-empty body.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-empty body.sdstest index 4576be59..4c8758cc 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-empty body.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-empty body.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error class MyClass {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-minimal.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-minimal.sdstest index 0b2a1003..4f6aede1 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-minimal.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-minimal.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error class MyClass diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-multiple parent types.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-multiple parent types.sdstest index 0c1a8460..e51d0266 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-multiple parent types.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-multiple parent types.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error class MyClass sub Int, Number diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-one parent type.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-one parent type.sdstest index 1231a1b7..673d2f02 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-one parent type.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-one parent type.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error class MyClass sub Int diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-with constraint list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-with constraint list.sdstest index 982a5c1a..b2b087fb 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-with constraint list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-with constraint list.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error class MyClass where {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-with parameter list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-with parameter list.sdstest index fe748608..cc240191 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-with parameter list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-with parameter list.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error class MyClass() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-with type parameter list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-with type parameter list.sdstest index a06a2893..c9d39652 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-with type parameter list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-with type parameter list.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error class MyClass<> diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/methods/good-annotated instance method.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/methods/good-annotated instance method.sdstest index 72695918..3f8a9b21 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/methods/good-annotated instance method.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/methods/good-annotated instance method.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error class MyClass { @MyAnnotation diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/methods/good-annotated static method.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/methods/good-annotated static method.sdstest index 4eb3f7d5..c424e943 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/methods/good-annotated static method.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/methods/good-annotated static method.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error class MyClass { @MyAnnotation diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/methods/good-instance method.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/methods/good-instance method.sdstest index 0a0ea9b6..972ec9c6 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/methods/good-instance method.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/methods/good-instance method.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error class MyClass { fun myFunction() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/methods/good-static method.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/methods/good-static method.sdstest index cd54cd70..acef5186 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/methods/good-static method.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/methods/good-static method.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error class MyClass { static fun myFunction() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/nested classes/good-annotated nested class.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/nested classes/good-annotated nested class.sdstest index 20f74916..5ed4f8fa 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/nested classes/good-annotated nested class.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/nested classes/good-annotated nested class.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error class MyOuterClass { @MyAnnotation diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/nested classes/good-nested-class.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/nested classes/good-nested-class.sdstest index f090b40b..39bdc50b 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/nested classes/good-nested-class.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/nested classes/good-nested-class.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error class MyOuterClass { class MyClass diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/nested enums/good-annotated nested enum.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/nested enums/good-annotated nested enum.sdstest index 76b8b7a8..748c416d 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/nested enums/good-annotated nested enum.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/nested enums/good-annotated nested enum.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error class MyOuterClass { @MyAnnotation diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/nested enums/good-nested enum.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/nested enums/good-nested enum.sdstest index d86fe01c..f43a21f2 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/nested enums/good-nested enum.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/nested enums/good-nested enum.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error class MyOuterClass { enum MyEnum { diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing name.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing name.tsltest index 53e2553c..cdae50b5 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing name.tsltest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing name.tsltest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error constant : Int = 1; diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing type.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing type.tsltest index e19c771e..fc06cf31 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing type.tsltest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing type.tsltest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error constant value: = 1 diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing value.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing value.tsltest index 80e9be97..b1697d48 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing value.tsltest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing value.tsltest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error constant value: Int = diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/constants/good-with type and value.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/constants/good-with type and value.tsltest index d85ef74f..7ff51d5c 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/constants/good-with type and value.tsltest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/constants/good-with type and value.tsltest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error constant value: Int = 1; diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/bad-missing comma.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/bad-missing comma.sdstest index 9eee0a23..e518970a 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/bad-missing comma.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/bad-missing comma.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error annotation MyAnnotation where { p < 0 diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-empty.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-empty.sdstest index 19cb167c..5aca6aaa 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-empty.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-empty.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error annotation MyAnnotation where {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-greater than constraint.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-greater than constraint.sdstest index 1c940e1d..c48a4e09 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-greater than constraint.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-greater than constraint.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error annotation MyAnnotation where { p > 0 diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-greater than or equals constraint.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-greater than or equals constraint.sdstest index 8bde0690..d0ff248b 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-greater than or equals constraint.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-greater than or equals constraint.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error annotation MyAnnotation where { p >= 0 diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-less than constraint.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-less than constraint.sdstest index 7665e1f6..baced08e 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-less than constraint.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-less than constraint.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error annotation MyAnnotation where { p < 0 diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-less than or equals constraint.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-less than or equals constraint.sdstest index 9c206305..87088e9b 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-less than or equals constraint.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-less than or equals constraint.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error annotation MyAnnotation where { p <= 0 diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-multiple constraints.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-multiple constraints.sdstest index c20fe5b6..bbefb801 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-multiple constraints.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-multiple constraints.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error annotation MyAnnotation where { p < 0, diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/data/bad-missing name.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/data/bad-missing name.tsltest index cc484719..36f7a7de 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/data/bad-missing name.tsltest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/data/bad-missing name.tsltest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error data : Int; diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/data/bad-missing type.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/data/bad-missing type.tsltest index fbd5e717..3c4cc803 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/data/bad-missing type.tsltest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/data/bad-missing type.tsltest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error data Data1: diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/data/good-with type and name.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/data/good-with type and name.tsltest index 6d064ba9..55bfd115 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/data/good-with type and name.tsltest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/data/good-with type and name.tsltest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error data Data1: Int; \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/bad-unclosed body.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/enums/bad-unclosed body.sdstest index f80c9cee..9dee2647 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/bad-unclosed body.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/enums/bad-unclosed body.sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error enum MyEnum { diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/good-annotation call.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/enums/good-annotation call.sdstest index f4e602fe..ff8b7830 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/good-annotation call.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/enums/good-annotation call.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error package test diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/good-empty body.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/enums/good-empty body.sdstest index 44b08ebc..939f2558 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/good-empty body.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/enums/good-empty body.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error enum MyEnum {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/good-no body.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/enums/good-no body.sdstest index a5b34a99..2d131bbe 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/good-no body.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/enums/good-no body.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error enum MyEnum diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/good-variants in body.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/enums/good-variants in body.sdstest index b12562bc..878c155b 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/good-variants in body.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/enums/good-variants in body.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error enum MyEnum { MyEnumVariant diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/bad-unclosed constraint list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/bad-unclosed constraint list.sdstest index 69c43974..fc42d3d0 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/bad-unclosed constraint list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/bad-unclosed constraint list.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error enum MyEnum { MyEnumVariant where { diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/bad-unclosed parameter list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/bad-unclosed parameter list.sdstest index 3dea580f..79539680 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/bad-unclosed parameter list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/bad-unclosed parameter list.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error enum MyEnum { MyEnumVariant( diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/good-annotation call.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/good-annotation call.sdstest index 05a3e6a0..cdd7269e 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/good-annotation call.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/good-annotation call.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error enum MyEnum { @Annotation diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/good-no parameter list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/good-no parameter list.sdstest index b12562bc..878c155b 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/good-no parameter list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/good-no parameter list.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error enum MyEnum { MyEnumVariant diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/good-with constraint list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/good-with constraint list.sdstest index bf2fdb55..c92316cb 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/good-with constraint list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/good-with constraint list.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error enum MyEnum { MyEnumVariant where {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/good-with parameter list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/good-with parameter list.sdstest index 9ff00fb6..98cf2703 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/good-with parameter list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/good-with parameter list.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error enum MyEnum { MyEnumVariant() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing parameter list.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing parameter list.tsltest index 9a97324f..010d8b5b 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing parameter list.tsltest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing parameter list.tsltest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error function myFunction diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing parameter type.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing parameter type.tsltest index 6daec909..53639679 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing parameter type.tsltest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing parameter type.tsltest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error function myFunction(x:) diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed parameter list.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed parameter list.tsltest index b76a08f4..c0bec18c 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed parameter list.tsltest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed parameter list.tsltest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error function myFunction( diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed result list.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed result list.tsltest index ebcbdd44..dca8b55d 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed result list.tsltest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed result list.tsltest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error function myFunction(): ( diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-annotation call.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-annotation call.tsltest index f556f0e6..bf5b5ecc 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-annotation call.tsltest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-annotation call.tsltest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error package test diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with parameter list.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with parameter list.tsltest index 36b85780..d0788d09 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with parameter list.tsltest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with parameter list.tsltest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error function myFunction() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with result list.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with result list.tsltest index 54bc099f..fea48ca4 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with result list.tsltest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with result list.tsltest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error function myFunction() -> () diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with type parameter list.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with type parameter list.tsltest index d9f348cc..e269fb41 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with type parameter list.tsltest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with type parameter list.tsltest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error function myFunction(x: Int) diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/bad-const before annotation.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/bad-const before annotation.sdstest index 1b5fd298..ae8dcb11 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/bad-const before annotation.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/bad-const before annotation.sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error class MyClass(const @Annotation a) diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/bad-double const modifier.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/bad-double const modifier.sdstest index 8b210905..8369d68f 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/bad-double const modifier.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/bad-double const modifier.sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error class MyClass(const const a: String) diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/bad-missing comma.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/bad-missing comma.sdstest index cf90d6e5..ff13b97a 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/bad-missing comma.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/bad-missing comma.sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error class MyClass(a b) diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-annotated parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-annotated parameter.sdstest index c71b43ca..782f752a 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-annotated parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-annotated parameter.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error class MyClass(@Annotation a: Int) diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-const typed optional parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-const typed optional parameter.sdstest index 7a9b687c..270edc1b 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-const typed optional parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-const typed optional parameter.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error class MyClass(const a: Int = 1) diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-const typed required parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-const typed required parameter.sdstest index 7de3e265..dd484ea8 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-const typed required parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-const typed required parameter.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error class MyClass(const a: Int) diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-const untyped optional parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-const untyped optional parameter.sdstest index acda4390..2e956d49 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-const untyped optional parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-const untyped optional parameter.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error class MyClass(const a = 1) diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-const untyped required parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-const untyped required parameter.sdstest index 5bc30a4a..c368ed8b 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-const untyped required parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-const untyped required parameter.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error class MyClass(const a) diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-empty.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-empty.sdstest index fe748608..cc240191 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-empty.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-empty.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error class MyClass() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-multiple parameters.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-multiple parameters.sdstest index 93b84c6e..9c93e8d1 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-multiple parameters.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-multiple parameters.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error class MyClass( @Annotation a1, diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-typed optional parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-typed optional parameter.sdstest index 076ed97d..a4991752 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-typed optional parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-typed optional parameter.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error class MyClass(a: Int = 1) diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-typed required parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-typed required parameter.sdstest index 3785d50c..02daf5df 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-typed required parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-typed required parameter.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error class MyClass(a: Int) diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-untyped optional parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-untyped optional parameter.sdstest index 9a29e763..c0b363c2 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-untyped optional parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-untyped optional parameter.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error class MyClass(a = 1) diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-untyped required parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-untyped required parameter.sdstest index d02baee9..070521f2 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-untyped required parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-untyped required parameter.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error class MyClass(a) diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/bad-missing body.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/bad-missing body.sdstest index 87b1fa7e..5911519b 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/bad-missing body.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/bad-missing body.sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/bad-unclosed body.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/bad-unclosed body.sdstest index 9710c4c7..d4bd8367 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/bad-unclosed body.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/bad-unclosed body.sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/good-annotation call.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/good-annotation call.sdstest index b6c69990..db5223ea 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/good-annotation call.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/good-annotation call.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error package test diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/good-empty body.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/good-empty body.sdstest index e65f1eb9..a38132bd 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/good-empty body.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/good-empty body.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/good-statements in body.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/good-statements in body.sdstest index 53561750..c3b07d95 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/good-statements in body.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/good-statements in body.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { val a = 1; diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/results/bad-missing comma.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/results/bad-missing comma.sdstest index fb9dc5e0..a030d660 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/results/bad-missing comma.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/results/bad-missing comma.sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error segment mySegment() -> (a b) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-annotated result.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-annotated result.sdstest index 00dbc182..aba9d8a2 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-annotated result.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-annotated result.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error segment mySegment() -> (@Annotation a: Int) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-empty.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-empty.sdstest index 8a30512c..aa2077bd 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-empty.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-empty.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error segment mySegment() -> () {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-multiple results.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-multiple results.sdstest index 13bcfdb4..64966909 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-multiple results.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-multiple results.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error segment mySegment() -> ( @Annotation a, diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-one typed result (in parentheses).sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-one typed result (in parentheses).sdstest index 9a380212..7c902be5 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-one typed result (in parentheses).sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-one typed result (in parentheses).sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error segment mySegment() -> (a: Int) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-one typed result (no parentheses).sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-one typed result (no parentheses).sdstest index 13940ca8..2b79a858 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-one typed result (no parentheses).sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-one typed result (no parentheses).sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error segment mySegment() -> a: Int {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-one untyped result (no parentheses).sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-one untyped result (no parentheses).sdstest index f001e7a3..a474b597 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-one untyped result (no parentheses).sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-one untyped result (no parentheses).sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error segment mySegment() -> a {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-one untyped result (with parentheses).sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-one untyped result (with parentheses).sdstest index dfc4ac34..4e60a7fd 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-one untyped result (with parentheses).sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-one untyped result (with parentheses).sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error segment mySegment() -> (a) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-missing body.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-missing body.sdstest index e37a29d5..f3cce832 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-missing body.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-missing body.sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error segment mySegment() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-missing parameter list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-missing parameter list.sdstest index c10c4ad1..b5b15308 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-missing parameter list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-missing parameter list.sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error segment mySegment {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-two visibilities (internal, internal).sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-two visibilities (internal, internal).sdstest index 619f22a7..72d1a52d 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-two visibilities (internal, internal).sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-two visibilities (internal, internal).sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error internal internal segment mySegment() {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-two visibilities (internal, private).sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-two visibilities (internal, private).sdstest index 27047c8d..a3dbe18a 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-two visibilities (internal, private).sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-two visibilities (internal, private).sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error internal private segment mySegment() {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-two visibilities (private, internal).sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-two visibilities (private, internal).sdstest index 797a58dc..9a1893fd 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-two visibilities (private, internal).sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-two visibilities (private, internal).sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error private internal segment mySegment() {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-two visibilities (private, private).sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-two visibilities (private, private).sdstest index 0c0f7303..49896d0b 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-two visibilities (private, private).sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-two visibilities (private, private).sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error private private segment mySegment() {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-unclosed body.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-unclosed body.sdstest index 1ba29b8f..f714f683 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-unclosed body.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-unclosed body.sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error segment mySegment() { diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-unclosed parameter list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-unclosed parameter list.sdstest index 4312edd1..e27d27cf 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-unclosed parameter list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-unclosed parameter list.sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error segment mySegment( {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-unclosed result list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-unclosed result list.sdstest index e1884342..2787dfb0 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-unclosed result list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-unclosed result list.sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error segment mySegment() -> ( {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-annotation call.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-annotation call.sdstest index 9d5ef909..91b6e7c8 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-annotation call.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-annotation call.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error package test diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-internal segment.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-internal segment.sdstest index 974c3aa4..4ddc25eb 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-internal segment.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-internal segment.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error internal segment mySegment() {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-private segment.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-private segment.sdstest index de021652..6fb52adc 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-private segment.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-private segment.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error private segment mySegment() {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-statements in body.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-statements in body.sdstest index 0fcc81aa..310f322f 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-statements in body.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-statements in body.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error private segment mySegment() { val a = 1; diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-with constraint list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-with constraint list.sdstest index 028dd843..02a28d33 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-with constraint list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-with constraint list.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error segment mySegment() where {} {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-with parameter list and body.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-with parameter list and body.sdstest index 538c2b17..a2e0e386 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-with parameter list and body.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-with parameter list and body.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error segment mySegment() {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-with result list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-with result list.sdstest index 8a30512c..aa2077bd 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-with result list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-with result list.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error segment mySegment() -> () {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/bad-missing comma.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/bad-missing comma.sdstest index 58d8c50b..eeb8d9b6 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/bad-missing comma.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/bad-missing comma.sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error fun myFunction() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-annotated type parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-annotated type parameter.sdstest index 40967e52..8d13f22d 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-annotated type parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-annotated type parameter.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error fun myFunction<@Annotation T>() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded contravariant optional type parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded contravariant optional type parameter.sdstest index 243f6366..ba08b315 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded contravariant optional type parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded contravariant optional type parameter.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error fun myFunction() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded contravariant required type parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded contravariant required type parameter.sdstest index 68af9baf..eeda1a68 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded contravariant required type parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded contravariant required type parameter.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error fun myFunction() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded covariant optional type parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded covariant optional type parameter.sdstest index 0e364d12..75d9f998 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded covariant optional type parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded covariant optional type parameter.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error fun myFunction() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded covariant required type parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded covariant required type parameter.sdstest index 613f0926..8a93ac04 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded covariant required type parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded covariant required type parameter.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error fun myFunction() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded invariant optional type parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded invariant optional type parameter.sdstest index 93a5eb3d..fad1831f 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded invariant optional type parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded invariant optional type parameter.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error fun myFunction() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded invariant required type parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded invariant required type parameter.sdstest index e7ce3182..021d2abb 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded invariant required type parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded invariant required type parameter.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error fun myFunction() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-empty.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-empty.sdstest index 912dae7a..f270ef67 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-empty.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-empty.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error fun myFunction<>() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-multiple type parameters.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-multiple type parameters.sdstest index 5ea557ce..e174e0bc 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-multiple type parameters.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-multiple type parameters.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error fun myFunction<@Annotation T, in S, out U>() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded contravariant optional type parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded contravariant optional type parameter.sdstest index 88d30d82..b9402bd1 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded contravariant optional type parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded contravariant optional type parameter.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error fun myFunction() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded contravariant required type parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded contravariant required type parameter.sdstest index 180c50e9..9a47947f 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded contravariant required type parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded contravariant required type parameter.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error fun myFunction() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded covariant optional type parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded covariant optional type parameter.sdstest index 1be49dfd..c5564a67 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded covariant optional type parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded covariant optional type parameter.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error fun myFunction() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded covariant required type parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded covariant required type parameter.sdstest index c7d1c7e6..ee113893 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded covariant required type parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded covariant required type parameter.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error fun myFunction() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded invariant optional type parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded invariant optional type parameter.sdstest index ab7a2938..41ee9fe2 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded invariant optional type parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded invariant optional type parameter.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error fun myFunction() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded invariant required type parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded invariant required type parameter.sdstest index 0bda9471..6321d445 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded invariant required type parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded invariant required type parameter.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error fun myFunction() diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-addition without left operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-addition without left operator.sdstest index 93c549ea..5141e5fc 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-addition without left operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-addition without left operator.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { + 2; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-addition without right operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-addition without right operator.sdstest index 8b6e73af..3cc7076d 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-addition without right operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-addition without right operator.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { 1 +; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-division without left operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-division without left operator.sdstest index 57a90363..a8aed892 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-division without left operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-division without left operator.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { / 2; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-division without right operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-division without right operator.sdstest index 38081c76..b4692bea 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-division without right operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-division without right operator.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { 1 /; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-multiplication without left operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-multiplication without left operator.sdstest index 60a5900f..47180c7a 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-multiplication without left operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-multiplication without left operator.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { * 2; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-multiplication without right operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-multiplication without right operator.sdstest index b62d52f6..bcdf896e 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-multiplication without right operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-multiplication without right operator.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { 1 *; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-negation without operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-negation without operator.sdstest index 854267fb..2bac0372 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-negation without operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-negation without operator.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { -; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-subtraction without right operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-subtraction without right operator.sdstest index 9dd3c100..04ae61da 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-subtraction without right operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-subtraction without right operator.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { 1 -; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-addition.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-addition.sdstest index f273ef1e..c6444527 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-addition.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-addition.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { 1 + 2; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-complex example.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-complex example.sdstest index 313f34cb..792e6a4e 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-complex example.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-complex example.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { (1 + 2) * -3 / (1 - 4) + 5; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-division.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-division.sdstest index ef34e2fd..0eaabe32 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-division.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-division.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { 1 / 2; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-multiplication.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-multiplication.sdstest index e7b1bfb6..e07da1a7 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-multiplication.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-multiplication.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { 1 * 2; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-negation.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-negation.sdstest index 1974fcb1..cfa41017 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-negation.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-negation.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { -1; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-subtraction.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-subtraction.sdstest index 7e5f9271..2b8398ae 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-subtraction.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-subtraction.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { 1 - 2; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/block lambdas/bad-unclosed body.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/block lambdas/bad-unclosed body.sdstest index 53e199fd..50c093b5 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/block lambdas/bad-unclosed body.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/block lambdas/bad-unclosed body.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { () {; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/block lambdas/bad-unclosed parameter list.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/block lambdas/bad-unclosed parameter list.sdstest index dd9e7ec5..85aa8649 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/block lambdas/bad-unclosed parameter list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/block lambdas/bad-unclosed parameter list.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { ( {}; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/block lambdas/good-filled body.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/block lambdas/good-filled body.sdstest index de33ac71..b23ac9f5 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/block lambdas/good-filled body.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/block lambdas/good-filled body.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { () { diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/block lambdas/good-with parameter list and body.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/block lambdas/good-with parameter list and body.sdstest index 8d1b84da..f00c96b8 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/block lambdas/good-with parameter list and body.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/block lambdas/good-with parameter list and body.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { () {}; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/calls/bad-unclosed argument list.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/calls/bad-unclosed argument list.sdstest index 181da152..6ef73b63 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/calls/bad-unclosed argument list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/calls/bad-unclosed argument list.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { f(; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-mixed positional and named arguments.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-mixed positional and named arguments.sdstest index 5d992779..b01975e4 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-mixed positional and named arguments.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-mixed positional and named arguments.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { f(1, b = 2); diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-named argument.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-named argument.sdstest index f0e4ce7b..b0b8ab2a 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-named argument.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-named argument.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { f(b = 2); diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-no arguments.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-no arguments.sdstest index 6cd2261b..46e9af1d 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-no arguments.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-no arguments.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { f(); diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-null safe.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-null safe.sdstest index 48ef60ec..b51b2f75 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-null safe.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-null safe.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { f?(1); diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-positional argument.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-positional argument.sdstest index 67090259..2ccfef92 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-positional argument.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-positional argument.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { f(1); diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than or equal without left operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than or equal without left operator.sdstest index 0f192c49..76dc0faa 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than or equal without left operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than or equal without left operator.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { >= 2; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than or equal without right operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than or equal without right operator.sdstest index 5985c39b..f2410411 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than or equal without right operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than or equal without right operator.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { 1 >=; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than without left operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than without left operator.sdstest index 0a66c978..9cb23a58 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than without left operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than without left operator.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { > 2; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than without right operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than without right operator.sdstest index bb733c94..3d20b341 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than without right operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than without right operator.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { 1 >; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than or equal without left operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than or equal without left operator.sdstest index 7e6d0416..0216f63f 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than or equal without left operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than or equal without left operator.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { <= 2; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than or equal without right operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than or equal without right operator.sdstest index 1beda50d..dc6aef56 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than or equal without right operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than or equal without right operator.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { 1 <=; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than without left operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than without left operator.sdstest index 4fe72792..aea0502d 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than without left operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than without left operator.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { < 2; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than without right operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than without right operator.sdstest index da8a9126..399f0747 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than without right operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than without right operator.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { 1 <; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-greater than or equal.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-greater than or equal.sdstest index b307ff91..f73d8ef6 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-greater than or equal.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-greater than or equal.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { 1 >= 2; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-greater than.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-greater than.sdstest index 72d16eac..c8786939 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-greater than.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-greater than.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { 1 > 2; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-less than or equal.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-less than or equal.sdstest index 27e5caf2..82bfadf9 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-less than or equal.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-less than or equal.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { 1 <= 2; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-less than.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-less than.sdstest index fc782e89..7e1221ad 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-less than.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-less than.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { 1 < 2; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/bad-without left operand.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/bad-without left operand.sdstest index f698fb17..4a8a305f 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/bad-without left operand.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/bad-without left operand.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { ?: Int; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/bad-without right operand.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/bad-without right operand.sdstest index 2c3bf116..431e2c1f 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/bad-without right operand.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/bad-without right operand.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { 1 ?:; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/good-basic.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/good-basic.sdstest index 5aaea6c8..62586bc6 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/good-basic.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/good-basic.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { null ?: 1; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/good-chained.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/good-chained.sdstest index 9b6a1240..e47da3a8 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/good-chained.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/good-chained.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { null ?: null ?: 1; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-equal without left operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-equal without left operator.sdstest index 6f529e44..6e25b432 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-equal without left operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-equal without left operator.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { == 2; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-equal without right operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-equal without right operator.sdstest index 37613704..2b8d2e37 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-equal without right operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-equal without right operator.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { 1 ==; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-identical without left operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-identical without left operator.sdstest index 7c15456a..b5814284 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-identical without left operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-identical without left operator.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { === 2; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-identical without right operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-identical without right operator.sdstest index 333baa79..dc07ea34 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-identical without right operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-identical without right operator.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { 1 ===; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not equal without left operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not equal without left operator.sdstest index c75d3f48..4f6607ea 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not equal without left operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not equal without left operator.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { != 2; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not equal without right operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not equal without right operator.sdstest index 6fbeacce..4a6a30a2 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not equal without right operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not equal without right operator.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { 1 !=; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not identical without left operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not identical without left operator.sdstest index 2e92a031..08f64095 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not identical without left operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not identical without left operator.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { 1 !==; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not identical without right operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not identical without right operator.sdstest index 2e92a031..08f64095 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not identical without right operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not identical without right operator.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { 1 !==; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-equal.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-equal.sdstest index ab608294..b48333c6 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-equal.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-equal.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { 1 == 2; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-identical.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-identical.sdstest index cc17d2bf..2460ab2d 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-identical.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-identical.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { 1 === 2; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-not equal.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-not equal.sdstest index 66b7ffeb..9b301888 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-not equal.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-not equal.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { 1 != 2; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-not identical.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-not identical.sdstest index 1f897170..668def25 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-not identical.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-not identical.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { 1 !== 2; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/expression lambdas/bad-missing body.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/expression lambdas/bad-missing body.sdstest index 0ab44dbd..be08633d 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/expression lambdas/bad-missing body.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/expression lambdas/bad-missing body.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { () ->; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/expression lambdas/bad-unclosed parameter list.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/expression lambdas/bad-unclosed parameter list.sdstest index 9568407b..ad8bcc52 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/expression lambdas/bad-unclosed parameter list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/expression lambdas/bad-unclosed parameter list.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { ( -> 1; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/expression lambdas/good-with parameter list and expression.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/expression lambdas/good-with parameter list and expression.sdstest index 77b37f42..7d231ec5 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/expression lambdas/good-with parameter list and expression.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/expression lambdas/good-with parameter list and expression.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { () -> 1; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/good-complex chained expression.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/good-complex chained expression.sdstest index d9277deb..5137f39d 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/good-complex chained expression.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/good-complex chained expression.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { a.member?.f()[1]; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/good-reference.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/good-reference.sdstest index 36197610..41b34be2 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/good-reference.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/good-reference.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { a; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/bad-no index.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/bad-no index.sdstest index 9dac005b..8fd6193a 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/bad-no index.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/bad-no index.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline test { a[]; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/bad-unclosed square bracket.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/bad-unclosed square bracket.sdstest index 7248c7b5..1183d032 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/bad-unclosed square bracket.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/bad-unclosed square bracket.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline test { a[1; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/good-literal index.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/good-literal index.sdstest index ff4ae34b..7b5c5f18 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/good-literal index.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/good-literal index.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline test { a[1]; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/good-null safe.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/good-null safe.sdstest index 7327f075..5f5457c1 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/good-null safe.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/good-null safe.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline test { a?[1]; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/good-reference index.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/good-reference index.sdstest index 6dafc20c..79011baa 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/good-reference index.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/good-reference index.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline test { a[b]; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/lists/bad-unclosed square bracket.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/lists/bad-unclosed square bracket.sdstest index 2a991668..3f085dd0 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/lists/bad-unclosed square bracket.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/lists/bad-unclosed square bracket.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { [1; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-nested multiple elements.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-nested multiple elements.sdstest index 0676978c..13337e22 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-nested multiple elements.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-nested multiple elements.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { [[1, 2]]; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-nested one element.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-nested one element.sdstest index 9edb2c2f..f0f6b41f 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-nested one element.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-nested one element.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { [[1 + 2]]; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-one level multiple elements.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-one level multiple elements.sdstest index 5327782b..d561d373 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-one level multiple elements.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-one level multiple elements.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { [1, 2]; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-one level one element.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-one level one element.sdstest index 2f0593a4..5f080fa2 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-one level one element.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-one level one element.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { [1 + 2]; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/bad-no digits before dot.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/bad-no digits before dot.sdstest index ae5accd1..12d78534 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/bad-no digits before dot.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/bad-no digits before dot.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { .2; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/good-basic example.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/good-basic example.sdstest index 0a1139ef..a4d12d5c 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/good-basic example.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/good-basic example.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { 1.2; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/good-scientific notation with lowercase e.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/good-scientific notation with lowercase e.sdstest index 487983bc..7d33b940 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/good-scientific notation with lowercase e.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/good-scientific notation with lowercase e.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { 1e10; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/good-scientific notation with uppercase e.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/good-scientific notation with uppercase e.sdstest index 351d43ce..cb8c5a68 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/good-scientific notation with uppercase e.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/good-scientific notation with uppercase e.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { 1E10; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/good-false.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/good-false.sdstest index efe0d586..1f24d666 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/good-false.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/good-false.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { false; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/good-null.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/good-null.sdstest index f5ff60a7..4602febf 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/good-null.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/good-null.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { null; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/good-true.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/good-true.sdstest index 58d43666..2f2df957 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/good-true.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/good-true.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { true; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/int/good-leading zero.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/int/good-leading zero.sdstest index c37f760a..9fac28d6 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/int/good-leading zero.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/int/good-leading zero.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { 01; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/int/good-multiple digits.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/int/good-multiple digits.sdstest index 509aab5b..07ef5028 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/int/good-multiple digits.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/int/good-multiple digits.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { 1234567890; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/int/good-one digit.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/int/good-one digit.sdstest index 9c748058..5b0b6ed2 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/int/good-one digit.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/int/good-one digit.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { 1; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/bad-single quotes as delimiters.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/bad-single quotes as delimiters.sdstest index 8b4551d6..336c8ff3 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/bad-single quotes as delimiters.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/bad-single quotes as delimiters.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { ''; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/bad-unclosed quote.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/bad-unclosed quote.sdstest index 36f8d414..ece95009 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/bad-unclosed quote.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/bad-unclosed quote.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { "; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-basic content.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-basic content.sdstest index 79cefed4..935c134e 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-basic content.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-basic content.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { "myString"; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-closing template expression delimiter.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-closing template expression delimiter.sdstest index 7f7c2dca..fdd181ba 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-closing template expression delimiter.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-closing template expression delimiter.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { "}}"; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-curly braces separated by space.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-curly braces separated by space.sdstest index f12997d1..2bd7258f 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-curly braces separated by space.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-curly braces separated by space.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { "{ {"; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-empty.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-empty.sdstest index dafae1fe..b57f8495 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-empty.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-empty.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { ""; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-escaped curly brace.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-escaped curly brace.sdstest index cd8f0e48..a2ae5bfe 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-escaped curly brace.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-escaped curly brace.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { "\{{"; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-multiple lines.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-multiple lines.sdstest index 64768bc4..f0ff08e9 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-multiple lines.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-multiple lines.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { " diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-newline escape sequence.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-newline escape sequence.sdstest index 7104ee86..01267dfe 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-newline escape sequence.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-newline escape sequence.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { "\n"; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-single curly brace.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-single curly brace.sdstest index f9e7f60d..ad1cffed 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-single curly brace.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-single curly brace.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { "{"; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-single quote.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-single quote.sdstest index ac7a4af3..4e7a5f1c 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-single quote.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-single quote.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { "'"; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-unicode escape sequence.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-unicode escape sequence.sdstest index f808b694..e3bba7e9 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-unicode escape sequence.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-unicode escape sequence.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { "\u000c"; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-conjunction without left operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-conjunction without left operator.sdstest index c8e3415b..3b0e6d42 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-conjunction without left operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-conjunction without left operator.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { and true; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-conjunction without right operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-conjunction without right operator.sdstest index 3da7f5c0..102b9ee0 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-conjunction without right operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-conjunction without right operator.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { false and; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-disjunction without left operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-disjunction without left operator.sdstest index 677b31b4..af9e5465 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-disjunction without left operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-disjunction without left operator.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { or true; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-disjunction without right operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-disjunction without right operator.sdstest index 13971f94..6d8e6cad 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-disjunction without right operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-disjunction without right operator.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { true or; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-negation without operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-negation without operator.sdstest index 854267fb..2bac0372 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-negation without operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-negation without operator.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { -; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-complex example.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-complex example.sdstest index 0a12be46..ff51eea9 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-complex example.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-complex example.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { not true and false or true; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-conjunction.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-conjunction.sdstest index 89fea66f..48c34f03 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-conjunction.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-conjunction.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { false and true; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-disjunction.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-disjunction.sdstest index 271891b9..61e71b46 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-disjunction.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-disjunction.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { true or true; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-negation.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-negation.sdstest index 30790c5d..bbe571f8 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-negation.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-negation.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { not true; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-no colon.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-no colon.sdstest index 62ec6038..73bf3fca 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-no colon.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-no colon.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { {1 "one"}; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-no key.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-no key.sdstest index 74ffc56e..620a6d38 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-no key.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-no key.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { {: "one"}; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-no value.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-no value.sdstest index 3b6dbb19..5075dee0 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-no value.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-no value.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { {1: }; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-unclosed curly brace.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-unclosed curly brace.sdstest index d87b4d94..8a065a19 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-unclosed curly brace.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-unclosed curly brace.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { {1: "one"; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-nested multiple elements.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-nested multiple elements.sdstest index e53c86eb..121d3771 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-nested multiple elements.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-nested multiple elements.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { { diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-nested one element.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-nested one element.sdstest index 81c26373..95eb89b9 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-nested one element.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-nested one element.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { { diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-one level multiple elements.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-one level multiple elements.sdstest index cb179d9b..8d7aaaaf 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-one level multiple elements.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-one level multiple elements.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { {1: "one", 2: "two"}; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-one level one element.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-one level one element.sdstest index 32922ba0..6ef83293 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-one level one element.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-one level one element.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { {1: "one"}; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/member accesses/bad-no receiver.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/member accesses/bad-no receiver.sdstest index f21bdfb4..994417a2 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/member accesses/bad-no receiver.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/member accesses/bad-no receiver.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { .member; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/member accesses/good-not nullable.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/member accesses/good-not nullable.sdstest index 0143e79a..7b18e560 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/member accesses/good-not nullable.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/member accesses/good-not nullable.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { a.member; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/member accesses/good-nullable.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/member accesses/good-nullable.sdstest index 1a9b8c15..1dd1a494 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/member accesses/good-nullable.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/member accesses/good-nullable.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { a?.member; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/parenthesized expressions/bad-unclosed parenthesis.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/parenthesized expressions/bad-unclosed parenthesis.sdstest index 96a1dce5..86154357 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/parenthesized expressions/bad-unclosed parenthesis.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/parenthesized expressions/bad-unclosed parenthesis.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { (1; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/parenthesized expressions/good-nested.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/parenthesized expressions/good-nested.sdstest index 5b210c27..28de2204 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/parenthesized expressions/good-nested.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/parenthesized expressions/good-nested.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { ((1 + 2)); diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/parenthesized expressions/good-one level.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/parenthesized expressions/good-one level.sdstest index 631db9b5..7ee06f7c 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/parenthesized expressions/good-one level.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/parenthesized expressions/good-one level.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { (1 + 2); diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/template strings/bad-template string with invalid expression.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/template strings/bad-template string with invalid expression.sdstest index a34d0a56..0222f44a 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/template strings/bad-template string with invalid expression.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/template strings/bad-template string with invalid expression.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { "{{ ??? }}"; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/template strings/bad-unclosed template expression.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/template strings/bad-unclosed template expression.sdstest index 6c4e7f08..6576503a 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/template strings/bad-unclosed template expression.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/template strings/bad-unclosed template expression.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { "{{"; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/template strings/good-empty template expression.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/template strings/good-empty template expression.sdstest index 064cfd44..89743ed3 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/template strings/good-empty template expression.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/template strings/good-empty template expression.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { "{{ }}"; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/template strings/good-template string with basic expression.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/template strings/good-template string with basic expression.sdstest index fc8d3666..0bf6ffbd 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/template strings/good-template string with basic expression.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/template strings/good-template string with basic expression.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { "{{ 1 }}"; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/type casts/bad-without expression.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/type casts/bad-without expression.sdstest index f7461212..6f82ee37 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/type casts/bad-without expression.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/type casts/bad-without expression.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { as Int; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/type casts/bad-without type.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/type casts/bad-without type.sdstest index 604895a0..99d0a1bd 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/type casts/bad-without type.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/type casts/bad-without type.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { 1 as; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/type casts/good-basic.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/type casts/good-basic.sdstest index 7c845dd8..0fad21e8 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/type casts/good-basic.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/type casts/good-basic.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { 1 as Int; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/type casts/good-chained.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/type casts/good-chained.sdstest index ca2f5a76..983f1971 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/type casts/good-chained.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/type casts/good-chained.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { 1 as Int as String; diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped _.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped _.sdstest index 84288017..85a3f2c5 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped _.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped _.sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error class _ diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped and.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped and.sdstest index 085b54b3..0bb8f547 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped and.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped and.sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error class and diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped annotation.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped annotation.sdstest index 89340ecc..4b597f6a 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped annotation.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped annotation.sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error class annotation diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped as.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped as.sdstest index 89c7cfad..2ba02019 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped as.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped as.sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error class as diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped attr.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped attr.sdstest index 95b2ac0b..d1bff13f 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped attr.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped attr.sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error class attr diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped class.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped class.sdstest index 84293707..9a33eeb2 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped class.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped class.sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error class class diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped const.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped const.sdstest index b310364a..75f62522 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped const.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped const.sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error class const diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped enum.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped enum.sdstest index 5fd6ae41..852b4450 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped enum.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped enum.sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error class enum diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped false.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped false.sdstest index 9a8c9b3f..af850464 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped false.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped false.sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error class false diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped fun.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped fun.sdstest index edea3480..d7816347 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped fun.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped fun.sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error class fun diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped import.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped import.sdstest index e7c5c26c..1ea7be70 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped import.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped import.sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error class import diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped in.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped in.sdstest index fb6e6099..7b8bee0a 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped in.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped in.sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error class in diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped internal.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped internal.sdstest index 68b05ffe..82a4fd6a 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped internal.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped internal.sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error class internal diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped literal.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped literal.sdstest index 8578433b..b7863813 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped literal.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped literal.sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error class literal diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped not.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped not.sdstest index 0a99c29f..52d45e69 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped not.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped not.sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error class not diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped null.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped null.sdstest index 40d2934f..faccc0d9 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped null.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped null.sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error class null diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped or.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped or.sdstest index 2e8b7582..1ae53952 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped or.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped or.sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error class or diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped out.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped out.sdstest index cda025c1..4bf9d63d 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped out.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped out.sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error class out diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped package.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped package.sdstest index 65ef3c09..cf48b7aa 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped package.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped package.sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error class package diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped pipeline.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped pipeline.sdstest index e28d5204..0f352db2 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped pipeline.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped pipeline.sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error class pipeline diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped private.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped private.sdstest index f701b4bc..1c73321a 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped private.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped private.sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error class private diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped schema.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped schema.sdstest index bc788c52..802ef7dd 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped schema.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped schema.sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error class schema diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped segment.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped segment.sdstest index 5327bb38..653c08f8 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped segment.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped segment.sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error class segment diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped static.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped static.sdstest index 4084a2ce..c5594192 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped static.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped static.sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error class static diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped sub.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped sub.sdstest index 0cc3a750..836a88de 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped sub.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped sub.sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error class sub diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped true.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped true.sdstest index 810fbb1b..2b1859fd 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped true.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped true.sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error class true diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped union.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped union.sdstest index 156a14b8..513c1e22 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped union.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped union.sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error class union diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped val.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped val.sdstest index c0d3d780..789d3412 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped val.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped val.sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error class val diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped where.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped where.sdstest index 4a5a8cf7..603c174f 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped where.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped where.sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error class where diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped yield.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped yield.sdstest index 965b87c3..49b64014 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped yield.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped yield.sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error class yield diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/good-escapedKeywords.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/good-escapedKeywords.sdstest index b44cdb5f..bf629b32 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/good-escapedKeywords.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/good-escapedKeywords.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error class `_` class `and` diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/good-escapedNonKeyword.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/good-escapedNonKeyword.sdstest index 2a9df26c..42bd6d11 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/good-escapedNonKeyword.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/good-escapedNonKeyword.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error class `Bla` diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/bad-annotation call after declaration.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/bad-annotation call after declaration.sdstest index 32b6ba5f..60963b7b 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/bad-annotation call after declaration.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/bad-annotation call after declaration.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error class C diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/bad-annotation call after import.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/bad-annotation call after import.sdstest index 69fd2c16..cbbcf31d 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/bad-annotation call after import.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/bad-annotation call after import.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error from myPackage import MyClass diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/bad-annotation call after package name.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/bad-annotation call after package name.sdstest index c0f18f3a..73f0ce27 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/bad-annotation call after package name.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/bad-annotation call after package name.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error package test diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/bad-annotation call between package name and import.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/bad-annotation call between package name and import.sdstest index d0692375..394f34fa 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/bad-annotation call between package name and import.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/bad-annotation call between package name and import.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error package test diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/bad-duplicate package name.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/bad-duplicate package name.sdstest index 6c3bb4d6..5fb58823 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/bad-duplicate package name.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/bad-duplicate package name.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error package test diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/bad-import after declaration.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/bad-import after declaration.sdstest index 37d05a95..081196c6 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/bad-import after declaration.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/bad-import after declaration.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error class C diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/bad-import without declarations.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/bad-import without declarations.sdstest index 8e5e68c4..562cc7b4 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/bad-import without declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/bad-import without declarations.sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error from myPackage import diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/bad-import without package.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/bad-import without package.sdstest index e81a3ffe..d39b8f36 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/bad-import without package.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/bad-import without package.sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error from import MyClass diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/bad-package name after declaration.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/bad-package name after declaration.sdstest index 0050a51d..ed52d4d8 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/bad-package name after declaration.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/bad-package name after declaration.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error class C diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/bad-package name after import.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/bad-package name after import.sdstest index fb1df5eb..a8fd8c07 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/bad-package name after import.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/bad-package name after import.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error from myPackage import someDeclaration diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and declaration.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and declaration.sdstest index 4ad22173..445f2646 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and declaration.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and declaration.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error @Annotation1 diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and import and declaration.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and import and declaration.sdstest index 23513163..a05b3a00 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and import and declaration.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and import and declaration.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error @Annotation1 diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and import.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and import.sdstest index 9412b051..23894a2a 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and import.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and import.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error @Annotation1 diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and package name and declaration.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and package name and declaration.sdstest index bcdd8aca..f08ca10f 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and package name and declaration.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and package name and declaration.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error @Annotation1 diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and package name and import and declaration.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and package name and import and declaration.sdstest index 417eab28..07d2f1f7 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and package name and import and declaration.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and package name and import and declaration.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error @Annotation1 diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and package name and import.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and package name and import.sdstest index 6e382d8d..2ede89b6 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and package name and import.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and package name and import.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error @Annotation1 diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and package name.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and package name.sdstest index bebb420a..a15eb2ed 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and package name.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and package name.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error @Annotation1 diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call.sdstest index d99e5e6a..a3a0576c 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error @Annotation1 diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and declarations.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and declarations.sdstest index 527c03d0..5c8529cb 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and declarations.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error @Annotation1 @Annotation2 diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and imports and declarations.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and imports and declarations.sdstest index 1405718a..af4e0e1a 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and imports and declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and imports and declarations.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error @Annotation1 @Annotation2 diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and imports.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and imports.sdstest index 091c3ceb..bda0cf39 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and imports.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and imports.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error @Annotation1 @Annotation2 diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and package name and declarations.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and package name and declarations.sdstest index 670d85b1..4465b9ff 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and package name and declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and package name and declarations.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error @Annotation1 @Annotation2 diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and package name and imports and declarations.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and package name and imports and declarations.sdstest index cef48d9c..2d8f4c4a 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and package name and imports and declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and package name and imports and declarations.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error @Annotation1 @Annotation2 diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and package name and imports.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and package name and imports.sdstest index c35fd05c..a649152a 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and package name and imports.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and package name and imports.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error @Annotation1 @Annotation2 diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and package name.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and package name.sdstest index 777ab87a..4c61fdf8 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and package name.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and package name.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error @Annotation1 @Annotation2 diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls.sdstest index 2c41fba2..bd0b6e64 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error @Annotation1 @Annotation2 diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-declaration.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-declaration.sdstest index 04c83e5f..69044739 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-declaration.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-declaration.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error class C diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-declarations.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-declarations.sdstest index e64324dd..83efc408 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-declarations.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error class C class D diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-empty.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-empty.sdstest index 665cb888..4fdd9ba3 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-empty.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-empty.sdstest @@ -1 +1 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-import and declaration.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-import and declaration.sdstest index ba1a0a17..53a89afd 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-import and declaration.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-import and declaration.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error from myPackage import MyClass diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-import.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-import.sdstest index 4cd7febc..7dc1b9af 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-import.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-import.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error from myPackage import MyClass diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-imports and declarations.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-imports and declarations.sdstest index c999e0d4..91077664 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-imports and declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-imports and declarations.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error from myPackage import MyClass from myPackage import MyClass as Class diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-imports.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-imports.sdstest index 117cdede..1ee8d640 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-imports.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-imports.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error from myPackage import MyClass from myPackage import MyClass as Class diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and declaration.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and declaration.sdstest index 467c84b6..4a1e020d 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and declaration.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and declaration.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error package myPackage diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and declarations.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and declarations.sdstest index 5d53478e..2afcc045 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and declarations.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error package myPackage diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and import and declaration.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and import and declaration.sdstest index a15f84d0..2a6f32f6 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and import and declaration.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and import and declaration.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error package myPackage diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and import.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and import.sdstest index 1e641a95..bde88774 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and import.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and import.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error package myPackage diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and imports and declarations.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and imports and declarations.sdstest index 32276074..e9745fa0 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and imports and declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and imports and declarations.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error package myPackage diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and imports.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and imports.sdstest index 2e7a19d8..52008f46 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and imports.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and imports.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error package myPackage diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-package name.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-package name.sdstest index 6cf287b7..9cbefbb4 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-package name.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-package name.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error package myPackage diff --git a/packages/ttsl-lang/tests/resources/grammar/schema/bad-no name (colon).sdstest b/packages/ttsl-lang/tests/resources/grammar/schema/bad-no name (colon).sdstest index 7e8ad729..eef2ab86 100644 --- a/packages/ttsl-lang/tests/resources/grammar/schema/bad-no name (colon).sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/schema/bad-no name (colon).sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error schema MySchema { : Int diff --git a/packages/ttsl-lang/tests/resources/grammar/schema/bad-no name (no colon).sdstest b/packages/ttsl-lang/tests/resources/grammar/schema/bad-no name (no colon).sdstest index b9972ace..224f7acd 100644 --- a/packages/ttsl-lang/tests/resources/grammar/schema/bad-no name (no colon).sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/schema/bad-no name (no colon).sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error schema MySchema { Int diff --git a/packages/ttsl-lang/tests/resources/grammar/schema/bad-no type (colon).sdstest b/packages/ttsl-lang/tests/resources/grammar/schema/bad-no type (colon).sdstest index 0da371cb..0f987c5d 100644 --- a/packages/ttsl-lang/tests/resources/grammar/schema/bad-no type (colon).sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/schema/bad-no type (colon).sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error schema MySchema { "column1" : diff --git a/packages/ttsl-lang/tests/resources/grammar/schema/bad-no type (no colon).sdstest b/packages/ttsl-lang/tests/resources/grammar/schema/bad-no type (no colon).sdstest index 8a3589f9..0bd789c4 100644 --- a/packages/ttsl-lang/tests/resources/grammar/schema/bad-no type (no colon).sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/schema/bad-no type (no colon).sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error schema MySchema { "column1" diff --git a/packages/ttsl-lang/tests/resources/grammar/schema/bad-switched name and type.sdstest b/packages/ttsl-lang/tests/resources/grammar/schema/bad-switched name and type.sdstest index 35432749..209d0a1e 100644 --- a/packages/ttsl-lang/tests/resources/grammar/schema/bad-switched name and type.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/schema/bad-switched name and type.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error schema MySchema { Int: "column1" diff --git a/packages/ttsl-lang/tests/resources/grammar/schema/bad-unclosed curly brace.sdstest b/packages/ttsl-lang/tests/resources/grammar/schema/bad-unclosed curly brace.sdstest index 344b89da..deec0956 100644 --- a/packages/ttsl-lang/tests/resources/grammar/schema/bad-unclosed curly brace.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/schema/bad-unclosed curly brace.sdstest @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error schema MySchema { diff --git a/packages/ttsl-lang/tests/resources/grammar/schema/good-annotation call.sdstest b/packages/ttsl-lang/tests/resources/grammar/schema/good-annotation call.sdstest index 6d802b73..58bbc01f 100644 --- a/packages/ttsl-lang/tests/resources/grammar/schema/good-annotation call.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/schema/good-annotation call.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error package test diff --git a/packages/ttsl-lang/tests/resources/grammar/schema/good-empty schema.sdstest b/packages/ttsl-lang/tests/resources/grammar/schema/good-empty schema.sdstest index f1e64b43..6a4dd39b 100644 --- a/packages/ttsl-lang/tests/resources/grammar/schema/good-empty schema.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/schema/good-empty schema.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error schema MySchema {} diff --git a/packages/ttsl-lang/tests/resources/grammar/schema/good-one column.sdstest b/packages/ttsl-lang/tests/resources/grammar/schema/good-one column.sdstest index bea79ca3..ccc30da5 100644 --- a/packages/ttsl-lang/tests/resources/grammar/schema/good-one column.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/schema/good-one column.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error schema MySchema { "column1": Int diff --git a/packages/ttsl-lang/tests/resources/grammar/schema/good-two columns.sdstest b/packages/ttsl-lang/tests/resources/grammar/schema/good-two columns.sdstest index 5cd16453..f79a4356 100644 --- a/packages/ttsl-lang/tests/resources/grammar/schema/good-two columns.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/schema/good-two columns.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error schema MySchema { "column1": Int, diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in block lambda without assignees.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in block lambda without assignees.sdstest index 670cdb28..151973bc 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in block lambda without assignees.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in block lambda without assignees.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { () { diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in block lambda without expression.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in block lambda without expression.sdstest index 6d5ea11a..1d884a80 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in block lambda without expression.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in block lambda without expression.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { () { diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in block lambda without semicolon.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in block lambda without semicolon.sdstest index 910fdb29..ffdb9f57 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in block lambda without semicolon.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in block lambda without semicolon.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { () { diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in pipeline without assignees.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in pipeline without assignees.sdstest index 673d19d5..df2f3d5f 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in pipeline without assignees.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in pipeline without assignees.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { = 0; diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in pipeline without expression.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in pipeline without expression.sdstest index 5bc01e5b..2b5c1a5c 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in pipeline without expression.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in pipeline without expression.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { val a =; diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in pipeline without semicolon.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in pipeline without semicolon.sdstest index 1a5bd5ec..966da2fd 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in pipeline without semicolon.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in pipeline without semicolon.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { val a = 0 diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in segment without assignees.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in segment without assignees.sdstest index 886632c6..6b059be1 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in segment without assignees.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in segment without assignees.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error segment mySegment() { = 0; diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in segment without expression.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in segment without expression.sdstest index 0d7b52fd..ab8cdf57 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in segment without expression.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in segment without expression.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error segment mySegment() { val a =; diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in segment without semicolon.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in segment without semicolon.sdstest index 350dbd7d..06cac9d3 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in segment without semicolon.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in segment without semicolon.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error segment mySegment() { val a = 0 diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/good-in block lambda.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/good-in block lambda.sdstest index 7f4f5a00..190ecc97 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/good-in block lambda.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/good-in block lambda.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { () { diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/good-in pipeline.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/good-in pipeline.sdstest index 547464b3..a73637e4 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/good-in pipeline.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/good-in pipeline.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { val a = 0; diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/good-in segment.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/good-in segment.sdstest index 334f15ef..bdbb994a 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/good-in segment.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/good-in segment.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error segment mySegment() { val a = 0; diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/bad-empty statement in block lambda.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/bad-empty statement in block lambda.sdstest index 47540d3b..0c48d0e3 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/bad-empty statement in block lambda.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/bad-empty statement in block lambda.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { () { diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/bad-empty statement in pipeline.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/bad-empty statement in pipeline.sdstest index b49c045c..333ebefb 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/bad-empty statement in pipeline.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/bad-empty statement in pipeline.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { ; diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/bad-empty statement in segment.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/bad-empty statement in segment.sdstest index ab3a700b..f17e3d06 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/bad-empty statement in segment.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/bad-empty statement in segment.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error segment mySegment() { ; diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-with else missing elseblock.tsltest b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-with else missing elseblock.tsltest index 5589aebe..2726729b 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-with else missing elseblock.tsltest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-with else missing elseblock.tsltest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +// $TEST$ syntax_error function myFunction(): { if (true){} diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-without else missing block.tsltest b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-without else missing block.tsltest index 415d8f91..c85ba297 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-without else missing block.tsltest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-without else missing block.tsltest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error function myFunction(): { if (true) diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-without else missing condition.tsltest b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-without else missing condition.tsltest index 1dca81c9..42ef6b5b 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-without else missing condition.tsltest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-without else missing condition.tsltest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error function myFunction(): { if (){} diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-with else false.tsltest b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-with else false.tsltest index 43e54879..9ed45c37 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-with else false.tsltest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-with else false.tsltest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error function myFunction(): { if (false){} diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-with else true.tsltest b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-with else true.tsltest index 3a6bd8ee..002c6c15 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-with else true.tsltest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-with else true.tsltest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error function myFunction(): { if (true){} diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-without else.tsltest b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-without else.tsltest index abb59d8a..d5956a99 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-without else.tsltest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-without else.tsltest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error function myFunction(): { if (true){} diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/bad-in block lambda without semicolon.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/bad-in block lambda without semicolon.sdstest index 6493c7e3..feb115dc 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/bad-in block lambda without semicolon.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/bad-in block lambda without semicolon.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { () { diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/bad-in pipeline without semicolon.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/bad-in pipeline without semicolon.sdstest index bcf2dbd2..ff65d1ad 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/bad-in pipeline without semicolon.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/bad-in pipeline without semicolon.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error pipeline myPipeline { call() diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/bad-in segment without semicolon.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/bad-in segment without semicolon.sdstest index 8e9345f9..e4b72cb9 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/bad-in segment without semicolon.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/bad-in segment without semicolon.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error segment mySegment() { call() diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/good-in block lambda.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/good-in block lambda.sdstest index 63f8f138..af2844a9 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/good-in block lambda.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/good-in block lambda.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { () { diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/good-in pipeline.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/good-in pipeline.sdstest index a3fb0130..c1c2afd7 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/good-in pipeline.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/good-in pipeline.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { call(); diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/good-in segment.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/good-in segment.sdstest index 57c29420..9ef76b27 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/good-in segment.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/good-in segment.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error segment mySegment() { call(); diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-argument list of annotation call.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-argument list of annotation call.sdstest index f8be6908..7ac2dda3 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-argument list of annotation call.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-argument list of annotation call.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error @A(1, 2, ) diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-argument list of call.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-argument list of call.sdstest index 00d833f0..7ded7e6f 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-argument list of call.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-argument list of call.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline p { f(1, 2, ); diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-assignee list of assignment in block lambda.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-assignee list of assignment in block lambda.sdstest index 397d4183..f06aa4c1 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-assignee list of assignment in block lambda.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-assignee list of assignment in block lambda.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline p { () { diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-assignee list of assignment.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-assignee list of assignment.sdstest index 83e8ff91..1602c872 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-assignee list of assignment.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-assignee list of assignment.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline p { val a, val b, = f(); diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-column list of schema.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-column list of schema.sdstest index f4dd423f..a144f227 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-column list of schema.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-column list of schema.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error schema MySchemaWithTrailingComma { "column1" : Int, diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-constraint list of annotation.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-constraint list of annotation.sdstest index ab23f1ef..57a0170a 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-constraint list of annotation.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-constraint list of annotation.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error annotation A where { p < 0, diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-constraint list of class.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-constraint list of class.sdstest index c3b80dd9..2c361e4d 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-constraint list of class.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-constraint list of class.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error class C where { p < 0, diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-constraint list of enum variant.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-constraint list of enum variant.sdstest index 8330bbf5..ab6384f6 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-constraint list of enum variant.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-constraint list of enum variant.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error enum E { A where { diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-constraint list of function.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-constraint list of function.sdstest index 0520d786..27a7f9a8 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-constraint list of function.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-constraint list of function.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error fun f() where { p < 0, diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-elements of list.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-elements of list.sdstest index be2054ad..b4a98c08 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-elements of list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-elements of list.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { [1, 2, ]; diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-entries of map.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-entries of map.sdstest index 787c00d7..6b62e6a9 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-entries of map.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-entries of map.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline myPipeline { {1: "one", 2: "two", }; diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-imported declaration list of qualified import.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-imported declaration list of qualified import.sdstest index e98849e9..e4735b62 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-imported declaration list of qualified import.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-imported declaration list of qualified import.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error from myPackage import MyClass, MyClass as Class, \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-literal list of literal type.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-literal list of literal type.sdstest index 0253c098..c0cdfc01 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-literal list of literal type.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-literal list of literal type.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error segment s( f: literal diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of annotation.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of annotation.sdstest index da48dfa8..6c4d85e0 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of annotation.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of annotation.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error annotation A( a: Int, diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of block lambda.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of block lambda.sdstest index a1f3e4e3..0f0b93c3 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of block lambda.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of block lambda.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline p { (first, second, ) {}; diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of callable type.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of callable type.sdstest index e1d85571..527b372f 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of callable type.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of callable type.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error segment s( f: (x: Int, y: Int, ) -> () diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of class.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of class.sdstest index 5101eeba..9aa45910 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of class.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of class.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error class C(a: Int, b: Int, ) diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of enum variant.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of enum variant.sdstest index 449e1df0..18aa6ca9 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of enum variant.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of enum variant.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error enum E { A( diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of expression lambda.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of expression lambda.sdstest index b8a58ec3..c04a1d65 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of expression lambda.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of expression lambda.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error pipeline p { (first, second, ) -> 1; diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of function.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of function.sdstest index 067186c8..5cd6104d 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of function.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of function.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error fun f( a: Int, diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of segment.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of segment.sdstest index 47f64488..7eb2519e 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of segment.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of segment.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error segment s( a: Int, diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parent type list of class.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parent type list of class.sdstest index 1bcd73e5..a705e37b 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parent type list of class.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parent type list of class.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error class C sub D, E, diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-result list of callable type.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-result list of callable type.sdstest index e06ea897..e8ff5ec0 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-result list of callable type.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-result list of callable type.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error segment s( f: () -> (x: Int, y: Int, ) diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-result list of function.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-result list of function.sdstest index 6900e96e..fb3da56f 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-result list of function.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-result list of function.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error fun f() -> ( first: Int, diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-result list of segment.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-result list of segment.sdstest index 64c7b4b2..6f1c43cf 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-result list of segment.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-result list of segment.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error segment s() -> ( first: Int, diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-type argument list of named type.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-type argument list of named type.sdstest index c4d43d35..b19dbc70 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-type argument list of named type.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-type argument list of named type.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error segment s( f: Type diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-type argument list of union type.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-type argument list of union type.sdstest index 83b71756..a5915350 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-type argument list of union type.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-type argument list of union type.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error segment s( f: union diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-type parameter list of class.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-type parameter list of class.sdstest index 8c208c01..b2dd3728 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-type parameter list of class.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-type parameter list of class.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error class C diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-type parameter list of function.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-type parameter list of function.sdstest index f139517e..9b28068a 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-type parameter list of function.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-type parameter list of function.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error fun f() diff --git a/packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-missing arrow.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-missing arrow.sdstest index 5674be22..38e12cf3 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-missing arrow.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-missing arrow.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error segment mySegment( f: () () diff --git a/packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-missing parameter list.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-missing parameter list.sdstest index 73927697..ac42849c 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-missing parameter list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-missing parameter list.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error segment mySegment( f: -> () diff --git a/packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-missing result list.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-missing result list.sdstest index 89bb1850..837aa711 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-missing result list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-missing result list.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error segment mySegment( f: () -> diff --git a/packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-unclosed parameter list.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-unclosed parameter list.sdstest index 13278275..b9e2b5af 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-unclosed parameter list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-unclosed parameter list.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error segment mySegment( f: ( -> () diff --git a/packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-unclosed result list.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-unclosed result list.sdstest index 3b2759a8..d49d667a 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-unclosed result list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-unclosed result list.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error segment mySegment( f: () -> ( diff --git a/packages/ttsl-lang/tests/resources/grammar/types/callable types/good-with parameter and result lists.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/callable types/good-with parameter and result lists.sdstest index 2baa7ff0..a5a088c1 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/callable types/good-with parameter and result lists.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/callable types/good-with parameter and result lists.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error segment mySegment( f: () -> () diff --git a/packages/ttsl-lang/tests/resources/grammar/types/literal types/bad-nested.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/literal types/bad-nested.sdstest index ce0e69ae..fae94dc0 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/literal types/bad-nested.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/literal types/bad-nested.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error segment mySegment( x: literal> diff --git a/packages/ttsl-lang/tests/resources/grammar/types/literal types/bad-no literal list.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/literal types/bad-no literal list.sdstest index 7c5a3834..5245213d 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/literal types/bad-no literal list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/literal types/bad-no literal list.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error segment mySegment( x: literal diff --git a/packages/ttsl-lang/tests/resources/grammar/types/literal types/bad-unclosed angle bracket.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/literal types/bad-unclosed angle bracket.sdstest index abf93699..b5dc0d8e 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/literal types/bad-unclosed angle bracket.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/literal types/bad-unclosed angle bracket.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error segment mySegment( x: literal< diff --git a/packages/ttsl-lang/tests/resources/grammar/types/literal types/good-empty.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/literal types/good-empty.sdstest index 66a936d1..794a4c62 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/literal types/good-empty.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/literal types/good-empty.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error segment mySegment( x: literal<> diff --git a/packages/ttsl-lang/tests/resources/grammar/types/literal types/good-with list literal.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/literal types/good-with list literal.sdstest index 02435b25..7c5357c7 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/literal types/good-with list literal.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/literal types/good-with list literal.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error segment mySegment( x: literal<[]> diff --git a/packages/ttsl-lang/tests/resources/grammar/types/literal types/good-with literals.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/literal types/good-with literals.sdstest index 3fbda1b5..54713226 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/literal types/good-with literals.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/literal types/good-with literals.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error segment mySegment( x: literal diff --git a/packages/ttsl-lang/tests/resources/grammar/types/literal types/good-with map literal.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/literal types/good-with map literal.sdstest index d19c3930..60c1b6c0 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/literal types/good-with map literal.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/literal types/good-with map literal.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error segment mySegment( x: literal<{}> diff --git a/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-callable type as member.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-callable type as member.sdstest index 11f5aba3..4eb240e5 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-callable type as member.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-callable type as member.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error segment mySegment( x: OuterClass.() -> () diff --git a/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-literal type as member.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-literal type as member.sdstest index 701706f1..615fe494 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-literal type as member.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-literal type as member.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error segment mySegment( x: OuterClass.literal<> diff --git a/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-missing member.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-missing member.sdstest index 9f4517d3..62eec592 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-missing member.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-missing member.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error segment mySegment( x: OuterClass. diff --git a/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-missing receiver.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-missing receiver.sdstest index 36d39ad5..a123da6d 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-missing receiver.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-missing receiver.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error segment mySegment( x: .InnerClass diff --git a/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-unclosed angle bracket.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-unclosed angle bracket.sdstest index b69e017b..ecf5fb40 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-unclosed angle bracket.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-unclosed angle bracket.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error segment mySegment( x: OuterClass.InnerClass< diff --git a/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-union type as member.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-union type as member.sdstest index bdbd8075..a68de5a4 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-union type as member.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-union type as member.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error segment mySegment( x: OuterClass.union<> diff --git a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-long complex chain.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/member types/good-long complex chain.sdstest index 1a3867f8..d0f73add 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-long complex chain.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/member types/good-long complex chain.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error segment mySegment( x: union<>.MiddleClass?.InnerClass diff --git a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (callable) and member (not nullable).sdstest b/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (callable) and member (not nullable).sdstest index 4867643c..00ed5e6c 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (callable) and member (not nullable).sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (callable) and member (not nullable).sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error segment mySegment( x: () -> ().InnerClass diff --git a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (callable) and member (nullable).sdstest b/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (callable) and member (nullable).sdstest index 5cfef9a1..f2857084 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (callable) and member (nullable).sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (callable) and member (nullable).sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error segment mySegment( x: () -> ().InnerClass? diff --git a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (literal) and member (not nullable).sdstest b/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (literal) and member (not nullable).sdstest index 6be0c881..18d08c95 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (literal) and member (not nullable).sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (literal) and member (not nullable).sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error segment mySegment( x: literal<>.InnerClass diff --git a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (literal) and member (nullable).sdstest b/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (literal) and member (nullable).sdstest index 2c8e93a9..94cb846f 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (literal) and member (nullable).sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (literal) and member (nullable).sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error segment mySegment( x: literal<>.InnerClass? diff --git a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (named, not nullable) and member (not nullable).sdstest b/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (named, not nullable) and member (not nullable).sdstest index 56b6bf48..9317d711 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (named, not nullable) and member (not nullable).sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (named, not nullable) and member (not nullable).sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error segment mySegment( x: OuterClass.InnerClass diff --git a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (named, not nullable) and member (nullable).sdstest b/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (named, not nullable) and member (nullable).sdstest index 118f8783..cb2c5a8f 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (named, not nullable) and member (nullable).sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (named, not nullable) and member (nullable).sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error segment mySegment( x: OuterClass.InnerClass? diff --git a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (named, nullable) and member (not nullable).sdstest b/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (named, nullable) and member (not nullable).sdstest index f74fa6e4..0d9e95f9 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (named, nullable) and member (not nullable).sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (named, nullable) and member (not nullable).sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error segment mySegment( x: OuterClass?.InnerClass diff --git a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (named, nullable) and member (nullable).sdstest b/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (named, nullable) and member (nullable).sdstest index 118f8783..cb2c5a8f 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (named, nullable) and member (nullable).sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (named, nullable) and member (nullable).sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error segment mySegment( x: OuterClass.InnerClass? diff --git a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (union) and member (not nullable).sdstest b/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (union) and member (not nullable).sdstest index 5d1d5321..ae2f4e07 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (union) and member (not nullable).sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (union) and member (not nullable).sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error segment mySegment( x: union<>.InnerClass diff --git a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (union) and member (nullable).sdstest b/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (union) and member (nullable).sdstest index 04ad20cc..776fbab1 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (union) and member (nullable).sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (union) and member (nullable).sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error segment mySegment( x: union<>.InnerClass? diff --git a/packages/ttsl-lang/tests/resources/grammar/types/named types/bad-unclosed angle bracket.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/named types/bad-unclosed angle bracket.sdstest index 77d80695..acb38b49 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/named types/bad-unclosed angle bracket.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/named types/bad-unclosed angle bracket.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error segment mySegment( x: OuterClass< diff --git a/packages/ttsl-lang/tests/resources/grammar/types/named types/good-no type arguments and not nullable.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/named types/good-no type arguments and not nullable.sdstest index 880fb7dd..574b8e8c 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/named types/good-no type arguments and not nullable.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/named types/good-no type arguments and not nullable.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error segment mySegment( x: Int diff --git a/packages/ttsl-lang/tests/resources/grammar/types/named types/good-no type arguments and nullable.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/named types/good-no type arguments and nullable.sdstest index 9da0abc2..e8e044e3 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/named types/good-no type arguments and nullable.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/named types/good-no type arguments and nullable.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error segment mySegment( x: Int? diff --git a/packages/ttsl-lang/tests/resources/grammar/types/named types/good-type argument and nullable.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/named types/good-type argument and nullable.sdstest index 1959e858..dfdcaae9 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/named types/good-type argument and nullable.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/named types/good-type argument and nullable.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error segment mySegment( x: Int? diff --git a/packages/ttsl-lang/tests/resources/grammar/types/named types/good-type arguments and not nullable.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/named types/good-type arguments and not nullable.sdstest index c814980e..5ece5476 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/named types/good-type arguments and not nullable.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/named types/good-type arguments and not nullable.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error segment mySegment( x: Int diff --git a/packages/ttsl-lang/tests/resources/grammar/types/union types/bad-unclosed angle bracket.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/union types/bad-unclosed angle bracket.sdstest index 05a407af..2c052d03 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/union types/bad-unclosed angle bracket.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/union types/bad-unclosed angle bracket.sdstest @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error segment mySegment( x: union< diff --git a/packages/ttsl-lang/tests/resources/grammar/types/union types/good-empty.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/union types/good-empty.sdstest index 0d4de615..2d1fa8ce 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/union types/good-empty.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/union types/good-empty.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error segment mySegment( x: union<> diff --git a/packages/ttsl-lang/tests/resources/grammar/types/union types/good-nested.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/union types/good-nested.sdstest index 9fbe2261..3e9785aa 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/union types/good-nested.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/union types/good-nested.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error segment mySegment( x: union> diff --git a/packages/ttsl-lang/tests/resources/grammar/types/union types/good-with type arguments.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/union types/good-with type arguments.sdstest index 0d9fc775..e1246c7f 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/union types/good-with type arguments.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/union types/good-with type arguments.sdstest @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error segment mySegment( x: union diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/block lambdas/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/block lambdas/main.sdstest index 5e1a56dd..00c6e80d 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/block lambdas/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/block lambdas/main.sdstest @@ -1,6 +1,6 @@ package tests.partialValidation.baseCases.expressionLambdas pipeline test { - // $TEST$ serialization $expressionLambdaClosure + # $TEST$ serialization $expressionLambdaClosure »() -> 1«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/boolean literals/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/boolean literals/main.sdstest index c12e0ca7..e489cc2a 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/boolean literals/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/boolean literals/main.sdstest @@ -1,9 +1,9 @@ package tests.partialValidation.baseCases.booleanLiterals pipeline test { - // $TEST$ serialization false + # $TEST$ serialization false »false«; - // $TEST$ serialization true + # $TEST$ serialization true »true«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/classes/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/classes/main.sdstest index 372271be..b7a98b21 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/classes/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/classes/main.sdstest @@ -1,4 +1,4 @@ package tests.partialValidation.baseCases.classes -// $TEST$ serialization C +# $TEST$ serialization C »class C« diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/enum variants/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/enum variants/main.sdstest index 8c4fcc88..c5844cd6 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/enum variants/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/enum variants/main.sdstest @@ -1,6 +1,6 @@ package tests.partialValidation.baseCases.enumVariants enum MyEnum { - // $TEST$ serialization MyVariant + # $TEST$ serialization MyVariant »MyVariant« } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/expression lambdas/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/expression lambdas/main.sdstest index 686070ce..d0faa1c8 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/expression lambdas/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/expression lambdas/main.sdstest @@ -1,6 +1,6 @@ package tests.partialValidation.baseCases.blockLambdas pipeline test { - // $TEST$ serialization $blockLambdaClosure + # $TEST$ serialization $blockLambdaClosure »() {}«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/float literals/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/float literals/main.sdstest index c5f6dab5..7ed21a44 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/float literals/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/float literals/main.sdstest @@ -1,9 +1,9 @@ package tests.partialValidation.baseCases.floatLiterals pipeline test { - // $TEST$ serialization 1.25 + # $TEST$ serialization 1.25 »1.25«; - // $TEST$ serialization 0.02 + # $TEST$ serialization 0.02 »2e-2«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/functions/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/functions/main.sdstest index 1f0f1b21..f5a02d39 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/functions/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/functions/main.sdstest @@ -1,4 +1,4 @@ package tests.partialValidation.baseCases.functions -// $TEST$ serialization f +# $TEST$ serialization f @Pure »fun f()« diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/int literals/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/int literals/main.sdstest index 6a9e1c38..4693cffb 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/int literals/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/int literals/main.sdstest @@ -1,6 +1,6 @@ package tests.partialValidation.baseCases.intLiterals pipeline test { - // $TEST$ serialization 123 + # $TEST$ serialization 123 »123«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/null literals/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/null literals/main.sdstest index ce8914a9..c0f49eb5 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/null literals/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/null literals/main.sdstest @@ -1,6 +1,6 @@ package tests.partialValidation.baseCases.nullLiterals pipeline test { - // $TEST$ serialization null + # $TEST$ serialization null »null«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/segments/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/segments/main.sdstest index fc5b4734..044fabca 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/segments/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/segments/main.sdstest @@ -1,4 +1,4 @@ package tests.partialValidation.baseCases.segments -// $TEST$ serialization mySegment +# $TEST$ serialization mySegment »segment mySegment() {}« diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/string literals (without interpolation)/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/string literals (without interpolation)/main.sdstest index cfa452d8..cb344f56 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/string literals (without interpolation)/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/string literals (without interpolation)/main.sdstest @@ -1,9 +1,9 @@ package tests.partialValidation.baseCases.stringLiteralsWithoutInterpolation pipeline test { - // $TEST$ serialization "test" + # $TEST$ serialization "test" »"test"«; - // $TEST$ serialization "test\t" + # $TEST$ serialization "test\t" »"test\t"«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/invalid nodes/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/invalid nodes/main.sdstest index 90e69ec8..fcbb8463 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/invalid nodes/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/invalid nodes/main.sdstest @@ -1,4 +1,4 @@ package tests.partialValidation.invalidNodes -// $TEST$ serialization ? +# $TEST$ serialization ? »schema mySchema {}« diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/arguments/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/arguments/main.sdstest index 3513e80a..5dbd87da 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/arguments/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/arguments/main.sdstest @@ -3,9 +3,9 @@ package tests.partialValidation.recursiveCases.arguments @Pure fun f(p: Any?) pipeline test { - // $TEST$ serialization 1 + # $TEST$ serialization 1 f(»p = 1«); - // $TEST$ serialization null + # $TEST$ serialization null f(»p = null«); } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/block lambda results/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/block lambda results/main.sdstest index 8632b110..f4370a32 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/block lambda results/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/block lambda results/main.sdstest @@ -6,12 +6,12 @@ segment mySegment() -> r: Int { pipeline test { () { - // $TEST$ serialization 1 - // $TEST$ serialization ? + # $TEST$ serialization 1 + # $TEST$ serialization ? »yield a«, »yield b« = 1; - // $TEST$ serialization 2 - // $TEST$ serialization ? + # $TEST$ serialization 2 + # $TEST$ serialization ? »yield c«, »yield d« = mySegment(); }; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/placeholders/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/placeholders/main.sdstest index a3df4036..1c8e4ec3 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/placeholders/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/placeholders/main.sdstest @@ -5,11 +5,11 @@ segment mySegment() -> r: Int { } pipeline test { - // $TEST$ serialization 1 - // $TEST$ serialization ? + # $TEST$ serialization 1 + # $TEST$ serialization ? »val a«, »val b« = 1; - // $TEST$ serialization 2 - // $TEST$ serialization ? + # $TEST$ serialization 2 + # $TEST$ serialization ? »val c«, »val d« = mySegment(); } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/wildcards/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/wildcards/main.sdstest index a0876509..bbe19f58 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/wildcards/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/wildcards/main.sdstest @@ -5,11 +5,11 @@ segment mySegment() -> r: Int { } pipeline test { - // $TEST$ serialization 1 - // $TEST$ serialization ? + # $TEST$ serialization 1 + # $TEST$ serialization ? »_«, »_« = 1; - // $TEST$ serialization 2 - // $TEST$ serialization ? + # $TEST$ serialization 2 + # $TEST$ serialization ? »_«, »_« = mySegment(); } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/yields/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/yields/main.sdstest index 8731cd3a..98316b0e 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/yields/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/yields/main.sdstest @@ -5,11 +5,11 @@ segment mySegment() -> r: Int { } segment mySegment2() -> (a: Int, b: Int, c: Int, d: Int) { - // $TEST$ serialization 1 - // $TEST$ serialization ? + # $TEST$ serialization 1 + # $TEST$ serialization ? »yield a«, »yield b« = 1; - // $TEST$ serialization 2 - // $TEST$ serialization ? + # $TEST$ serialization 2 + # $TEST$ serialization ? »yield c«, »yield d« = mySegment(); } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of block lambdas/closure.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of block lambdas/closure.sdstest index ab57993a..7284631f 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of block lambdas/closure.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of block lambdas/closure.sdstest @@ -7,6 +7,6 @@ segment mySegment(p: Int) -> (closure: () -> (r: Int)) { } pipeline test { - // $TEST$ serialization 1 + # $TEST$ serialization 1 »mySegment(1)()«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of block lambdas/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of block lambdas/main.sdstest index 298349dd..cadf3d64 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of block lambdas/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of block lambdas/main.sdstest @@ -6,6 +6,6 @@ pipeline test { yield s = 2; }; - // $TEST$ serialization (r = 1, s = 2) + # $TEST$ serialization (r = 1, s = 2) »blockLambda()«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of block lambdas/previous parameter value used as default value.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of block lambdas/previous parameter value used as default value.sdstest index 3a09c0d5..77fcbfa1 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of block lambdas/previous parameter value used as default value.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of block lambdas/previous parameter value used as default value.sdstest @@ -5,6 +5,6 @@ pipeline test { yield r = p2; }; - // $TEST$ serialization 1 + # $TEST$ serialization 1 »blockLambda(1)«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of classes/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of classes/main.sdstest index fcceeec4..aa7d2186 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of classes/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of classes/main.sdstest @@ -3,6 +3,6 @@ package tests.partialValidation.recursiveCases.calls.ofClasses class C() pipeline test { - // $TEST$ serialization ? + # $TEST$ serialization ? »C()«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of enum variants/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of enum variants/main.sdstest index e972a57d..d7b0851a 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of enum variants/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of enum variants/main.sdstest @@ -6,30 +6,30 @@ enum MyEnum { } pipeline test { - // $TEST$ serialization MyEnumVariantWithoutParameters() + # $TEST$ serialization MyEnumVariantWithoutParameters() »MyEnum.MyEnumVariantWithoutParameters()«; - // $TEST$ serialization MyEnumVariantWithParameters(p = ?, q = 3) + # $TEST$ serialization MyEnumVariantWithParameters(p = ?, q = 3) »MyEnum.MyEnumVariantWithParameters()«; - // $TEST$ serialization MyEnumVariantWithParameters(p = 1, q = 3) + # $TEST$ serialization MyEnumVariantWithParameters(p = 1, q = 3) »MyEnum.MyEnumVariantWithParameters(1)«; - // $TEST$ serialization MyEnumVariantWithParameters(p = 1, q = 2) + # $TEST$ serialization MyEnumVariantWithParameters(p = 1, q = 2) »MyEnum.MyEnumVariantWithParameters(1, 2)«; - // $TEST$ serialization MyEnumVariantWithParameters(p = 1, q = 2) + # $TEST$ serialization MyEnumVariantWithParameters(p = 1, q = 2) »MyEnum.MyEnumVariantWithParameters(q = 2, p = 1)«; - // $TEST$ serialization MyEnumVariantWithParameters(p = 1, q = ?) + # $TEST$ serialization MyEnumVariantWithParameters(p = 1, q = ?) »MyEnum.MyEnumVariantWithParameters(1, f())«; - // $TEST$ serialization MyEnumVariantWithParameters(p = 1, q = ?) + # $TEST$ serialization MyEnumVariantWithParameters(p = 1, q = ?) »MyEnum.MyEnumVariantWithParameters(1, f(), 3)«; - // $TEST$ serialization MyEnumVariantWithParameters(p = 1, q = ?) + # $TEST$ serialization MyEnumVariantWithParameters(p = 1, q = ?) »MyEnum.MyEnumVariantWithParameters(1, f(), r = 3)«; - // $TEST$ serialization ? + # $TEST$ serialization ? »MyEnum.MyEnumVariantWithParameters(q = 2, p = 1)()«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of expression lambdas/closure.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of expression lambdas/closure.sdstest index d21009b1..5b435179 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of expression lambdas/closure.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of expression lambdas/closure.sdstest @@ -5,6 +5,6 @@ segment mySegment(p: Int) -> (closure: () -> (r: Int)) { } pipeline test { - // $TEST$ serialization 1 + # $TEST$ serialization 1 »mySegment(1)()«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of expression lambdas/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of expression lambdas/main.sdstest index dc73fa86..f7ef355a 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of expression lambdas/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of expression lambdas/main.sdstest @@ -3,6 +3,6 @@ package tests.partialValidation.recursiveCases.calls.ofExpressionLambdas pipeline test { val expressionLambda = () -> 1; - // $TEST$ serialization 1 + # $TEST$ serialization 1 »expressionLambda()«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of expression lambdas/previous parameter value used as default value.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of expression lambdas/previous parameter value used as default value.sdstest index 0a679ab7..2cc827ac 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of expression lambdas/previous parameter value used as default value.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of expression lambdas/previous parameter value used as default value.sdstest @@ -3,6 +3,6 @@ package tests.partialValidation.recursiveCases.calls.ofExpressionLambdas.previou pipeline test { val expressionLambda = (p1: Int, p2: Int = p1) -> p2; - // $TEST$ serialization 1 + # $TEST$ serialization 1 »expressionLambda(1)«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of functions/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of functions/main.sdstest index afb1fb27..96b1601c 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of functions/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of functions/main.sdstest @@ -3,6 +3,6 @@ package tests.partialValidation.recursiveCases.calls.ofFunctions @Pure fun f() pipeline test { - // $TEST$ serialization ? + # $TEST$ serialization ? »f()«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of segments/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of segments/main.sdstest index ee852b01..20da8842 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of segments/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of segments/main.sdstest @@ -5,6 +5,6 @@ segment mySegment() -> (r: Int, s: Int) { } pipeline test { - // $TEST$ serialization (r = 1, s = ?) + # $TEST$ serialization (r = 1, s = ?) »mySegment()«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of segments/previous parameter value used as default value.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of segments/previous parameter value used as default value.sdstest index 9963635f..edfa2a51 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of segments/previous parameter value used as default value.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of segments/previous parameter value used as default value.sdstest @@ -5,6 +5,6 @@ segment mySegment(p1: Int, p2: Int = p1) -> r: Int { } pipeline test { - // $TEST$ serialization 1 + # $TEST$ serialization 1 »mySegment(1)«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of unknown parameter/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of unknown parameter/main.sdstest index bc6e981f..2a20f556 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of unknown parameter/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of unknown parameter/main.sdstest @@ -1,6 +1,6 @@ package tests.partialValidation.recursiveCases.calls.ofUnknownParameter segment mySegment(p: () -> ()) { - // $TEST$ serialization ? + # $TEST$ serialization ? »p()«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/on null/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/on null/main.sdstest index d09f45c6..97e7d234 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/on null/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/on null/main.sdstest @@ -1,9 +1,9 @@ package tests.partialValidation.recursiveCases.calls.onNull segment mySegment() { - // $TEST$ serialization ? + # $TEST$ serialization ? »null()«; - // $TEST$ serialization null + # $TEST$ serialization null »null?()«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/recursion/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/recursion/main.sdstest index bd812258..5a362728 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/recursion/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/recursion/main.sdstest @@ -1,6 +1,6 @@ package tests.partialValidation.recursiveCases.calls.recursion segment mySegment() -> r: Int { - // $TEST$ serialization ? + # $TEST$ serialization ? yield r = »mySegment()«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/unresolved/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/unresolved/main.sdstest index 3fd30caf..f46df5d2 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/unresolved/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/unresolved/main.sdstest @@ -5,9 +5,9 @@ enum MyEnum { } pipeline test { - // $TEST$ serialization ? + # $TEST$ serialization ? »unresolved.MyEnumVariant()«; - // $TEST$ serialization ? + # $TEST$ serialization ? »MyEnum.unresolved()«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on lists/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on lists/main.sdstest index eceb9abb..5fe5a058 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on lists/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on lists/main.sdstest @@ -1,24 +1,24 @@ package tests.partialValidation.recursiveCases.indexedAccess.onLists pipeline test { - // $TEST$ serialization 2 + # $TEST$ serialization 2 »[1, 2, 3][1]«; - // $TEST$ serialization 1 + # $TEST$ serialization 1 »[1, 2, unresolved][0]«; - // $TEST$ serialization ? + # $TEST$ serialization ? »[1, 2, unresolved][2]«; - // $TEST$ serialization ? + # $TEST$ serialization ? »[][-1]«; - // $TEST$ serialization ? + # $TEST$ serialization ? »[][1]«; - // $TEST$ serialization ? + # $TEST$ serialization ? »[][""]«; - // $TEST$ serialization ? + # $TEST$ serialization ? »[][unresolved]«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on maps/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on maps/main.sdstest index 9a2e8d60..c6922b8e 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on maps/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on maps/main.sdstest @@ -1,21 +1,21 @@ package tests.partialValidation.recursiveCases.indexedAccess.onMaps pipeline test { - // $TEST$ serialization 1 + # $TEST$ serialization 1 »{"1": 1}["1"]«; - // $TEST$ serialization 2 + # $TEST$ serialization 2 »{"1": 1, "1": 2}["1"]«; // In Python the last matching entry wins, so we need to mimic that behavior - // $TEST$ serialization 2 + # $TEST$ serialization 2 »{"1": 1, "2": 2, "3": unresolved}["2"]«; - // $TEST$ serialization ? + # $TEST$ serialization ? »{"1": 1, "2": 2, "3": unresolved}["3"]«; - // $TEST$ serialization ? + # $TEST$ serialization ? »{}[1]«; - // $TEST$ serialization ? + # $TEST$ serialization ? »{}[unresolved]«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on null/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on null/main.sdstest index e19c2fea..14e1e6b0 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on null/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on null/main.sdstest @@ -1,9 +1,9 @@ package tests.partialValidation.recursiveCases.indexedAccess.onNull pipeline test { - // $TEST$ serialization ? + # $TEST$ serialization ? »null[0]«; - // $TEST$ serialization null + # $TEST$ serialization null »null?[0]«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on other/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on other/main.sdstest index 599dd967..34e178a7 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on other/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on other/main.sdstest @@ -1,9 +1,9 @@ package tests.partialValidation.recursiveCases.indexedAccess.onOther pipeline test { - // $TEST$ serialization ? + # $TEST$ serialization ? »1[1]«; - // $TEST$ serialization ? + # $TEST$ serialization ? »unresolved[1]«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/and/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/and/main.sdstest index f9df8974..da15394a 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/and/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/and/main.sdstest @@ -1,27 +1,27 @@ package tests.partialValidation.recursiveCases.infixOperations.`and` pipeline test { - // $TEST$ serialization false + # $TEST$ serialization false »false and false«; - // $TEST$ serialization false + # $TEST$ serialization false »false and true«; - // $TEST$ serialization false + # $TEST$ serialization false »true and false«; - // $TEST$ serialization true + # $TEST$ serialization true »true and true«; - // $TEST$ serialization ? + # $TEST$ serialization ? »1 and true«; - // $TEST$ serialization ? + # $TEST$ serialization ? »true and 0«; - // $TEST$ serialization ? + # $TEST$ serialization ? »unresolved and true«; - // $TEST$ serialization ? + # $TEST$ serialization ? »true and unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/and/short circuiting.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/and/short circuiting.sdstest index 6a17bac2..21f27bb7 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/and/short circuiting.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/and/short circuiting.sdstest @@ -10,21 +10,21 @@ fun functionWithoutSideEffects() -> result: Boolean fun functionWithSideEffects() -> result: Boolean pipeline test { - // $TEST$ serialization false + # $TEST$ serialization false »false and pureFunction()«; - // $TEST$ serialization false + # $TEST$ serialization false »false and functionWithoutSideEffects()«; - // $TEST$ serialization false + # $TEST$ serialization false »false and functionWithSideEffects()«; - // $TEST$ serialization ? + # $TEST$ serialization ? »true and pureFunction()«; - // $TEST$ serialization ? + # $TEST$ serialization ? »true and functionWithoutSideEffects()«; - // $TEST$ serialization ? + # $TEST$ serialization ? »true and functionWithSideEffects()«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/divided by/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/divided by/main.sdstest index c04021c2..7c6db855 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/divided by/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/divided by/main.sdstest @@ -1,38 +1,38 @@ package tests.partialValidation.recursiveCases.infixOperations.dividedBy pipeline test { - // $TEST$ serialization 0.5 + # $TEST$ serialization 0.5 »0.25 / 0.5«; - // $TEST$ serialization 1.5 + # $TEST$ serialization 1.5 »1.5 / 1«; - // $TEST$ serialization 1.6 + # $TEST$ serialization 1.6 »1 / 0.625«; - // $TEST$ serialization 1 + # $TEST$ serialization 1 »1 / 1«; - // $TEST$ serialization ? + # $TEST$ serialization ? »1 / 0«; - // $TEST$ serialization ? + # $TEST$ serialization ? »1 / 0.0«; - // $TEST$ serialization ? + # $TEST$ serialization ? »1 / -0.0«; - // $TEST$ serialization ? + # $TEST$ serialization ? »true / 1«; - // $TEST$ serialization ? + # $TEST$ serialization ? »1 / true«; - // $TEST$ serialization ? + # $TEST$ serialization ? »unresolved / 1«; - // $TEST$ serialization ? + # $TEST$ serialization ? »1 / unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/elvis/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/elvis/main.sdstest index 1b3d047c..b0eeaf83 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/elvis/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/elvis/main.sdstest @@ -1,21 +1,21 @@ package tests.partialValidation.recursiveCases.infixOperations.elvis pipeline test { - // $TEST$ serialization true + # $TEST$ serialization true »true ?: false«; - // $TEST$ serialization false + # $TEST$ serialization false »null ?: false«; - // $TEST$ serialization $expressionLambdaClosure + # $TEST$ serialization $expressionLambdaClosure »(() -> 1) ?: false«; - // $TEST$ serialization ? + # $TEST$ serialization ? »(() -> 1) ?: unresolved«; - // $TEST$ serialization ? + # $TEST$ serialization ? »unresolved ?: null«; - // $TEST$ serialization ? + # $TEST$ serialization ? »null ?: unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/elvis/short circuiting.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/elvis/short circuiting.sdstest index 174cd208..6f9c0249 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/elvis/short circuiting.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/elvis/short circuiting.sdstest @@ -10,21 +10,21 @@ fun functionWithoutSideEffects() -> result: Boolean fun functionWithSideEffects() -> result: Boolean pipeline test { - // $TEST$ serialization 1 + # $TEST$ serialization 1 »1 ?: pureFunction()«; - // $TEST$ serialization 1 + # $TEST$ serialization 1 »1 ?: functionWithoutSideEffects()«; - // $TEST$ serialization 1 + # $TEST$ serialization 1 »1 ?: functionWithSideEffects()«; - // $TEST$ serialization ? + # $TEST$ serialization ? »null ?: pureFunction()«; - // $TEST$ serialization ? + # $TEST$ serialization ? »null ?: functionWithoutSideEffects()«; - // $TEST$ serialization ? + # $TEST$ serialization ? »null ?: functionWithSideEffects()«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/equals/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/equals/main.sdstest index 177b74c1..340b013b 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/equals/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/equals/main.sdstest @@ -1,15 +1,15 @@ package tests.partialValidation.recursiveCases.infixOperations.equals pipeline test { - // $TEST$ serialization true + # $TEST$ serialization true »true == true«; - // $TEST$ serialization false + # $TEST$ serialization false »false == 1«; - // $TEST$ serialization ? + # $TEST$ serialization ? »1 == unresolved«; - // $TEST$ serialization ? + # $TEST$ serialization ? »unresolved == 1.25«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/greater than or equals/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/greater than or equals/main.sdstest index 5f9e3f6b..94990a59 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/greater than or equals/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/greater than or equals/main.sdstest @@ -1,41 +1,41 @@ package tests.partialValidation.recursiveCases.infixOperations.greaterThanOrEquals pipeline test { - // $TEST$ serialization true + # $TEST$ serialization true »0.5 >= 0.5«; - // $TEST$ serialization true + # $TEST$ serialization true »1.5 >= 0«; - // $TEST$ serialization true + # $TEST$ serialization true »1 >= 0.5«; - // $TEST$ serialization true + # $TEST$ serialization true »1 >= 0«; - // $TEST$ serialization false + # $TEST$ serialization false »0.5 >= 1.5«; - // $TEST$ serialization false + # $TEST$ serialization false »0.5 >= 1«; - // $TEST$ serialization false + # $TEST$ serialization false »0 >= 1.5«; - // $TEST$ serialization false + # $TEST$ serialization false »0 >= 1«; - // $TEST$ serialization ? + # $TEST$ serialization ? »1 >= true«; - // $TEST$ serialization ? + # $TEST$ serialization ? »false >= 0«; - // $TEST$ serialization ? + # $TEST$ serialization ? »unresolved >= false«; - // $TEST$ serialization ? + # $TEST$ serialization ? »true >= unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/greater than/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/greater than/main.sdstest index de60757f..792ad137 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/greater than/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/greater than/main.sdstest @@ -1,41 +1,41 @@ package tests.partialValidation.recursiveCases.infixOperations.greaterThan pipeline test { - // $TEST$ serialization true + # $TEST$ serialization true »1.5 > 0.5«; - // $TEST$ serialization true + # $TEST$ serialization true »1.5 > 0«; - // $TEST$ serialization true + # $TEST$ serialization true »1 > 0.5«; - // $TEST$ serialization true + # $TEST$ serialization true »1 > 0«; - // $TEST$ serialization false + # $TEST$ serialization false »0.5 > 1.5«; - // $TEST$ serialization false + # $TEST$ serialization false »0.5 > 1«; - // $TEST$ serialization false + # $TEST$ serialization false »0 > 1.5«; - // $TEST$ serialization false + # $TEST$ serialization false »0 > 1«; - // $TEST$ serialization ? + # $TEST$ serialization ? »1 > true«; - // $TEST$ serialization ? + # $TEST$ serialization ? »false > 0«; - // $TEST$ serialization ? + # $TEST$ serialization ? »unresolved > false«; - // $TEST$ serialization ? + # $TEST$ serialization ? »true > unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/identical to/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/identical to/main.sdstest index 9f663404..1b781031 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/identical to/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/identical to/main.sdstest @@ -1,15 +1,15 @@ package tests.partialValidation.recursiveCases.infixOperations.identicalTo pipeline test { - // $TEST$ serialization true + # $TEST$ serialization true »true === true«; - // $TEST$ serialization false + # $TEST$ serialization false »false === 1«; - // $TEST$ serialization ? + # $TEST$ serialization ? »1 === unresolved«; - // $TEST$ serialization ? + # $TEST$ serialization ? »unresolved === 1.25«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/less than or equals/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/less than or equals/main.sdstest index 19420212..95465429 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/less than or equals/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/less than or equals/main.sdstest @@ -1,41 +1,41 @@ package tests.partialValidation.recursiveCases.infixOperations.lessThanOrEquals pipeline test { - // $TEST$ serialization true + # $TEST$ serialization true »0.5 <= 0.5«; - // $TEST$ serialization true + # $TEST$ serialization true »0.5 <= 1«; - // $TEST$ serialization true + # $TEST$ serialization true »0 <= 1.5«; - // $TEST$ serialization true + # $TEST$ serialization true »0 <= 1«; - // $TEST$ serialization false + # $TEST$ serialization false »1.5 <= 0.5«; - // $TEST$ serialization false + # $TEST$ serialization false »1.5 <= 0«; - // $TEST$ serialization false + # $TEST$ serialization false »1 <= 0.5«; - // $TEST$ serialization false + # $TEST$ serialization false »1 <= 0«; - // $TEST$ serialization ? + # $TEST$ serialization ? »1 <= true«; - // $TEST$ serialization ? + # $TEST$ serialization ? »false <= 0«; - // $TEST$ serialization ? + # $TEST$ serialization ? »unresolved <= false«; - // $TEST$ serialization ? + # $TEST$ serialization ? »true <= unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/less than/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/less than/main.sdstest index c368f289..b8336325 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/less than/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/less than/main.sdstest @@ -1,41 +1,41 @@ package tests.partialValidation.recursiveCases.infixOperations.lessThan pipeline test { - // $TEST$ serialization true + # $TEST$ serialization true »0.5 < 1.5«; - // $TEST$ serialization true + # $TEST$ serialization true »0.5 < 1«; - // $TEST$ serialization true + # $TEST$ serialization true »0 < 1.5«; - // $TEST$ serialization true + # $TEST$ serialization true »0 < 1«; - // $TEST$ serialization false + # $TEST$ serialization false »1.5 < 0.5«; - // $TEST$ serialization false + # $TEST$ serialization false »1.5 < 0«; - // $TEST$ serialization false + # $TEST$ serialization false »1 < 0.5«; - // $TEST$ serialization false + # $TEST$ serialization false »1 < 1«; - // $TEST$ serialization ? + # $TEST$ serialization ? »1 < true«; - // $TEST$ serialization ? + # $TEST$ serialization ? »false < 0«; - // $TEST$ serialization ? + # $TEST$ serialization ? »unresolved < false«; - // $TEST$ serialization ? + # $TEST$ serialization ? »true < unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/minus/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/minus/main.sdstest index 1ab3020d..f2c0f413 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/minus/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/minus/main.sdstest @@ -1,28 +1,28 @@ package tests.partialValidation.recursiveCases.infixOperations.minus pipeline test { - // $TEST$ serialization 1.25 + # $TEST$ serialization 1.25 »1.5 - 0.25«; - // $TEST$ serialization 0.5 + # $TEST$ serialization 0.5 »1.5 - 1«; - // $TEST$ serialization 0.75 + # $TEST$ serialization 0.75 »1 - 0.25«; - // $TEST$ serialization 0 + # $TEST$ serialization 0 »1 - 1«; - // $TEST$ serialization ? + # $TEST$ serialization ? »true - 1«; - // $TEST$ serialization ? + # $TEST$ serialization ? »1 - true«; - // $TEST$ serialization ? + # $TEST$ serialization ? »unresolved - 1«; - // $TEST$ serialization ? + # $TEST$ serialization ? »1 - unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/not equals/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/not equals/main.sdstest index 539dbf17..7cb3534d 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/not equals/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/not equals/main.sdstest @@ -1,15 +1,15 @@ package tests.partialValidation.recursiveCases.infixOperations.notEquals pipeline test { - // $TEST$ serialization false + # $TEST$ serialization false »true != true«; - // $TEST$ serialization true + # $TEST$ serialization true »false != 1«; - // $TEST$ serialization ? + # $TEST$ serialization ? »1 != unresolved«; - // $TEST$ serialization ? + # $TEST$ serialization ? »unresolved != 1.25«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/not identical to/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/not identical to/main.sdstest index 32e217d9..6ba3ca08 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/not identical to/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/not identical to/main.sdstest @@ -1,15 +1,15 @@ package tests.partialValidation.recursiveCases.infixOperations.notIdenticalTo pipeline test { - // $TEST$ serialization false + # $TEST$ serialization false »true !== true«; - // $TEST$ serialization true + # $TEST$ serialization true »false !== 1«; - // $TEST$ serialization ? + # $TEST$ serialization ? »1 !== unresolved«; - // $TEST$ serialization ? + # $TEST$ serialization ? »unresolved !== 1.25«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/or/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/or/main.sdstest index 5df518f9..6057836b 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/or/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/or/main.sdstest @@ -1,27 +1,27 @@ package tests.partialValidation.recursiveCases.infixOperations.`or` pipeline test { - // $TEST$ serialization false + # $TEST$ serialization false »false or false«; - // $TEST$ serialization true + # $TEST$ serialization true »false or true«; - // $TEST$ serialization true + # $TEST$ serialization true »true or false«; - // $TEST$ serialization true + # $TEST$ serialization true »true or true«; - // $TEST$ serialization ? + # $TEST$ serialization ? »1 or false«; - // $TEST$ serialization ? + # $TEST$ serialization ? »false or 0«; - // $TEST$ serialization ? + # $TEST$ serialization ? »unresolved or false«; - // $TEST$ serialization ? + # $TEST$ serialization ? »false or unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/or/short circuiting.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/or/short circuiting.sdstest index 0fa82fc0..e10600a3 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/or/short circuiting.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/or/short circuiting.sdstest @@ -10,21 +10,21 @@ fun functionWithoutSideEffects() -> result: Boolean fun functionWithSideEffects() -> result: Boolean pipeline test { - // $TEST$ serialization true + # $TEST$ serialization true »true or pureFunction()«; - // $TEST$ serialization true + # $TEST$ serialization true »true or functionWithoutSideEffects()«; - // $TEST$ serialization true + # $TEST$ serialization true »true or functionWithSideEffects()«; - // $TEST$ serialization ? + # $TEST$ serialization ? »false or pureFunction()«; - // $TEST$ serialization ? + # $TEST$ serialization ? »false or functionWithoutSideEffects()«; - // $TEST$ serialization ? + # $TEST$ serialization ? »false or functionWithSideEffects()«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/plus/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/plus/main.sdstest index 0d5b0e7f..4ae3e069 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/plus/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/plus/main.sdstest @@ -1,28 +1,28 @@ package tests.partialValidation.recursiveCases.infixOperations.plus pipeline test { - // $TEST$ serialization 1.75 + # $TEST$ serialization 1.75 »1.5 + 0.25«; - // $TEST$ serialization 2.5 + # $TEST$ serialization 2.5 »1.5 + 1«; - // $TEST$ serialization 1.25 + # $TEST$ serialization 1.25 »1 + 0.25«; - // $TEST$ serialization 2 + # $TEST$ serialization 2 »1 + 1«; - // $TEST$ serialization ? + # $TEST$ serialization ? »true + 1«; - // $TEST$ serialization ? + # $TEST$ serialization ? »1 + true«; - // $TEST$ serialization ? + # $TEST$ serialization ? »unresolved + 1«; - // $TEST$ serialization ? + # $TEST$ serialization ? »1 + unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/times/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/times/main.sdstest index 1bcac13f..77294793 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/times/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/times/main.sdstest @@ -1,28 +1,28 @@ package tests.partialValidation.recursiveCases.infixOperations.times pipeline test { - // $TEST$ serialization 0.75 + # $TEST$ serialization 0.75 »1.5 * 0.5«; - // $TEST$ serialization 1.5 + # $TEST$ serialization 1.5 »1.5 * 1«; - // $TEST$ serialization 0.25 + # $TEST$ serialization 0.25 »1 * 0.25«; - // $TEST$ serialization 1 + # $TEST$ serialization 1 »1 * 1«; - // $TEST$ serialization ? + # $TEST$ serialization ? »true * 1«; - // $TEST$ serialization ? + # $TEST$ serialization ? »1 * true«; - // $TEST$ serialization ? + # $TEST$ serialization ? »unresolved * 1«; - // $TEST$ serialization ? + # $TEST$ serialization ? »1 * unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/lists/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/lists/main.sdstest index eb3bf454..c1b7ea16 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/lists/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/lists/main.sdstest @@ -1,9 +1,9 @@ package tests.partialValidation.recursiveCases.lists pipeline test { - // $TEST$ serialization [] + # $TEST$ serialization [] »[]«; - // $TEST$ serialization [1, 2.5, null, ?] + # $TEST$ serialization [1, 2.5, null, ?] »[1, 2.5, null, unresolved]«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/maps/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/maps/main.sdstest index 25c0ef45..dad0445b 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/maps/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/maps/main.sdstest @@ -1,10 +1,10 @@ package tests.partialValidation.recursiveCases.maps pipeline test { - // $TEST$ serialization {} + # $TEST$ serialization {} »{}«; - // $TEST$ serialization {"a": 1, "b": 2.5, "c": null, "d": ?, ?: true} + # $TEST$ serialization {"a": 1, "b": 2.5, "c": null, "d": ?, ?: true} »{ "a": 1, "b": 2.5, diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/of call results/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/of call results/main.sdstest index 28a065d8..1802b2c4 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/of call results/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/of call results/main.sdstest @@ -11,21 +11,21 @@ pipeline test { yield s = q; }; - // $TEST$ serialization 1 + # $TEST$ serialization 1 »mySegment(1).r«; - // $TEST$ serialization 2 + # $TEST$ serialization 2 »mySegment(1).s«; - // $TEST$ serialization ? + # $TEST$ serialization ? »mySegment(1).unresolved«; - // $TEST$ serialization 1 + # $TEST$ serialization 1 »blockLambda(1).r«; - // $TEST$ serialization 2 + # $TEST$ serialization 2 »blockLambda(1).s«; - // $TEST$ serialization ? + # $TEST$ serialization ? »blockLambda(1).unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/of enum variant parameters/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/of enum variant parameters/main.sdstest index d99bebee..ca4da19d 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/of enum variant parameters/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/of enum variant parameters/main.sdstest @@ -5,12 +5,12 @@ enum MyEnum { } pipeline test { - // $TEST$ serialization 1 + # $TEST$ serialization 1 »MyEnum.MyEnumVariantWithParameters(1).p«; - // $TEST$ serialization 2 + # $TEST$ serialization 2 »MyEnum.MyEnumVariantWithParameters(1).q«; - // $TEST$ serialization ? + # $TEST$ serialization ? »MyEnum.MyEnumVariantWithParameters(1).unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/of enum variants/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/of enum variants/main.sdstest index e95c58d3..efac984c 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/of enum variants/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/of enum variants/main.sdstest @@ -6,9 +6,9 @@ enum MyEnum { } pipeline test { - // $TEST$ serialization MyEnumVariantWithoutParameters + # $TEST$ serialization MyEnumVariantWithoutParameters »MyEnum.MyEnumVariantWithoutParameters«; - // $TEST$ serialization MyEnumVariantWithParameters + # $TEST$ serialization MyEnumVariantWithParameters »MyEnum.MyEnumVariantWithParameters«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/on null/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/on null/main.sdstest index 85aa824e..f4e4bc84 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/on null/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/on null/main.sdstest @@ -1,9 +1,9 @@ package tests.partialValidation.recursiveCases.memberAccesses.onNull pipeline test { - // $TEST$ serialization ? + # $TEST$ serialization ? »null.toString«; - // $TEST$ serialization null + # $TEST$ serialization null »null?.toString«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/on other receivers/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/on other receivers/main.sdstest index 583ff6fc..596704d9 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/on other receivers/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/on other receivers/main.sdstest @@ -3,6 +3,6 @@ package tests.partialValidation.recursiveCases.memberAccesses.onOtherReceivers @Pure fun f() -> result: Int pipeline test { - // $TEST$ serialization ? + # $TEST$ serialization ? »f().result«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/unresolved/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/unresolved/main.sdstest index c5bf09ca..a9dcfe51 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/unresolved/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/unresolved/main.sdstest @@ -5,9 +5,9 @@ enum MyEnum { } pipeline test { - // $TEST$ serialization ? + # $TEST$ serialization ? »unresolved.MyEnumVariant«; - // $TEST$ serialization ? + # $TEST$ serialization ? »MyEnum.unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/parameters/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/parameters/main.sdstest index 0604d585..957a35cd 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/parameters/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/parameters/main.sdstest @@ -11,12 +11,12 @@ pipeline myPipeline { val expressionLambda = (p: Int) -> p; - // $TEST$ serialization 1 + # $TEST$ serialization 1 »mySegment(1)«; - // $TEST$ serialization 1 + # $TEST$ serialization 1 »blockLambda(1)«; - // $TEST$ serialization 1 + # $TEST$ serialization 1 »expressionLambda(1)«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/parenthesized expressions/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/parenthesized expressions/main.sdstest index 81abee4d..9e722e9c 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/parenthesized expressions/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/parenthesized expressions/main.sdstest @@ -1,11 +1,11 @@ package tests.partialValidation.recursiveCases.parenthesizedExpression pipeline test { - // $TEST$ equivalence_class value1 - // $TEST$ equivalence_class value1 + # $TEST$ equivalence_class value1 + # $TEST$ equivalence_class value1 »(»1«)«; - // $TEST$ equivalence_class value2 - // $TEST$ equivalence_class value2 + # $TEST$ equivalence_class value2 + # $TEST$ equivalence_class value2 »(»null«)«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/prefix operations/minus/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/prefix operations/minus/main.sdstest index e9bfcc35..2bbbf1dc 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/prefix operations/minus/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/prefix operations/minus/main.sdstest @@ -1,15 +1,15 @@ package tests.partialValidation.recursiveCases.prefixOperations.minus pipeline test { - // $TEST$ serialization -1.5 + # $TEST$ serialization -1.5 »-1.5«; - // $TEST$ serialization -1 + # $TEST$ serialization -1 »-1«; - // $TEST$ serialization ? + # $TEST$ serialization ? »-true«; - // $TEST$ serialization ? + # $TEST$ serialization ? »-unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/prefix operations/not/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/prefix operations/not/main.sdstest index 84c8e97a..1d7b07df 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/prefix operations/not/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/prefix operations/not/main.sdstest @@ -1,15 +1,15 @@ package tests.partialValidation.recursiveCases.prefixOperations.`not` pipeline test { - // $TEST$ serialization true + # $TEST$ serialization true »not false«; - // $TEST$ serialization false + # $TEST$ serialization false »not true«; - // $TEST$ serialization ? + # $TEST$ serialization ? »not 0«; - // $TEST$ serialization ? + # $TEST$ serialization ? »not unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/references/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/references/main.sdstest index f19cb14c..d775d6c2 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/references/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/references/main.sdstest @@ -3,8 +3,8 @@ package tests.partialEvaluation.recursiveCases.assignees.references pipeline myPipeline { val a = 1; - // $TEST$ serialization 1 + # $TEST$ serialization 1 »a«; - // $TEST$ serialization ? + # $TEST$ serialization ? »unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/results/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/results/main.sdstest index 4b97763c..7dbe1e10 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/results/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/results/main.sdstest @@ -1,8 +1,8 @@ package tests.partialEvaluation.recursiveCases.assignees.results -// $TEST$ serialization ? -// $TEST$ serialization 1 -// $TEST$ serialization 2 +# $TEST$ serialization ? +# $TEST$ serialization 1 +# $TEST$ serialization 2 segment mySegment() -> (»a: Int«, »b: Int«, »c: Int«) { yield b = 1; diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/template strings/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/template strings/main.sdstest index df5ab080..41407460 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/template strings/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/template strings/main.sdstest @@ -1,12 +1,12 @@ package tests.partialValidation.recursiveCases.templateStrings pipeline test { - // $TEST$ serialization "start 1 inner1 true inner2 test end" + # $TEST$ serialization "start 1 inner1 true inner2 test end" »"start {{ 1 }} inner1 {{ true }} inner2 {{ "test" }} end"«; - // $TEST$ serialization "start\\t1 inner1\\ttrue inner2\\ttest end\\t" + # $TEST$ serialization "start\\t1 inner1\\ttrue inner2\\ttest end\\t" »"start\t{{ 1 }} inner1\t{{ true }} inner2\t{{ "test" }} end\t"«; - // $TEST$ serialization ? + # $TEST$ serialization ? »"start {{ call() }} end"«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/type casts/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/type casts/main.sdstest index 5d61c482..ea646121 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/type casts/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/type casts/main.sdstest @@ -1,9 +1,9 @@ package tests.partialValidation.recursiveCases.typeCasts pipeline test { - // $TEST$ serialization true + # $TEST$ serialization true »true as Boolean«; - // $TEST$ serialization 1 + # $TEST$ serialization 1 »1 as Boolean«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main no imports or own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main no imports or own declarations.sdstest index bd7c452c..42adc11b 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main no imports or own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main no imports or own declarations.sdstest @@ -1,17 +1,17 @@ package tests.scoping.annotationCalls.acrossFiles -// $TEST$ references same_MyAnnotation +# $TEST$ references same_MyAnnotation @»MyAnnotation« -// $TEST$ references same_AnnotationInSamePackage +# $TEST$ references same_AnnotationInSamePackage @»AnnotationInSamePackage« -// $TEST$ references safeds_AnnotationInSafeDsPackage +# $TEST$ references safeds_AnnotationInSafeDsPackage @»AnnotationInSafeDsPackage« -// $TEST$ unresolved +# $TEST$ unresolved @»AnnotationInAnotherPackage« -// $TEST$ unresolved +# $TEST$ unresolved @»AnnotationWithoutPackage« pipeline myPipeline {} diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with imports and own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with imports and own declarations.sdstest index 26ce5d2b..afb59e0b 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with imports and own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with imports and own declarations.sdstest @@ -3,24 +3,24 @@ package tests.scoping.annotationCalls.acrossFiles from safeds.scoping.annotationCalls.acrossFiles import MyAnnotation as MyOwnAnnotation from tests.scoping.annotationCalls.acrossFiles.other import AnnotationInAnotherPackage, Annotation2InAnotherPackage -// $TEST$ target own_MyOwnAnnotation +# $TEST$ target own_MyOwnAnnotation annotation »MyOwnAnnotation« -// $TEST$ references own_MyOwnAnnotation +# $TEST$ references own_MyOwnAnnotation @»MyOwnAnnotation« -// $TEST$ references same_AnnotationInSamePackage +# $TEST$ references same_AnnotationInSamePackage @»AnnotationInSamePackage« -// $TEST$ references safeds_AnnotationInSafeDsPackage +# $TEST$ references safeds_AnnotationInSafeDsPackage @»AnnotationInSafeDsPackage« -// $TEST$ references other_AnnotationInAnotherPackage +# $TEST$ references other_AnnotationInAnotherPackage @»AnnotationInAnotherPackage« -// $TEST$ references other_Annotation2InAnotherPackage +# $TEST$ references other_Annotation2InAnotherPackage @»Annotation2InAnotherPackage« -// $TEST$ unresolved +# $TEST$ unresolved @»AnnotationWithoutPackage« pipeline myPipeline {} diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with multiple imports of same name.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with multiple imports of same name.sdstest index 6a480c88..bb4199dc 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with multiple imports of same name.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with multiple imports of same name.sdstest @@ -5,6 +5,6 @@ from tests.scoping.annotationCalls.acrossFiles.other import MyAnnotation from tests.scoping.annotationCalls.acrossFiles import MyAnnotation pipeline myPipeline { - // $TEST$ references safeds_MyAnnotation + # $TEST$ references safeds_MyAnnotation »MyAnnotation«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with qualified import with alias.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with qualified import with alias.sdstest index 1d3e552f..eace4460 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with qualified import with alias.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with qualified import with alias.sdstest @@ -4,28 +4,28 @@ from tests.scoping.annotationCalls.acrossFiles import MyAnnotation as MyAnnotati from safeds.scoping.annotationCalls.acrossFiles import MyAnnotation as MyAnnotationInSafeDsPackage from tests.scoping.annotationCalls.acrossFiles.other import MyAnnotation as MyAnnotationInAnotherPackage -// $TEST$ references same_MyAnnotation +# $TEST$ references same_MyAnnotation @»MyAnnotation« -// $TEST$ references same_AnnotationInSamePackage +# $TEST$ references same_AnnotationInSamePackage @»AnnotationInSamePackage« -// $TEST$ references safeds_AnnotationInSafeDsPackage +# $TEST$ references safeds_AnnotationInSafeDsPackage @»AnnotationInSafeDsPackage« -// $TEST$ unresolved +# $TEST$ unresolved @»AnnotationInAnotherPackage« -// $TEST$ unresolved +# $TEST$ unresolved @»AnnotationWithoutPackage« -// $TEST$ references same_MyAnnotation +# $TEST$ references same_MyAnnotation @»MyAnnotationInSamePackage« -// $TEST$ references safeds_MyAnnotation +# $TEST$ references safeds_MyAnnotation @»MyAnnotationInSafeDsPackage« -// $TEST$ references other_MyAnnotation +# $TEST$ references other_MyAnnotation @»MyAnnotationInAnotherPackage« pipeline myPipeline {} diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with qualified import.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with qualified import.sdstest index d6c494b7..add5f8e7 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with qualified import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with qualified import.sdstest @@ -3,24 +3,24 @@ package tests.scoping.annotationCalls.acrossFiles from safeds.scoping.annotationCalls.acrossFiles import MyAnnotation from tests.scoping.annotationCalls.acrossFiles.other import AnnotationInAnotherPackage, Annotation2InAnotherPackage, NotAnAnnotation -// $TEST$ references safeds_MyAnnotation +# $TEST$ references safeds_MyAnnotation @»MyAnnotation« -// $TEST$ references same_AnnotationInSamePackage +# $TEST$ references same_AnnotationInSamePackage @»AnnotationInSamePackage« -// $TEST$ references safeds_AnnotationInSafeDsPackage +# $TEST$ references safeds_AnnotationInSafeDsPackage @»AnnotationInSafeDsPackage« -// $TEST$ references other_AnnotationInAnotherPackage +# $TEST$ references other_AnnotationInAnotherPackage @»AnnotationInAnotherPackage« -// $TEST$ references other_Annotation2InAnotherPackage +# $TEST$ references other_Annotation2InAnotherPackage @»Annotation2InAnotherPackage« -// $TEST$ unresolved +# $TEST$ unresolved @»NotAnAnnotation« -// $TEST$ unresolved +# $TEST$ unresolved @»AnnotationWithoutPackage« pipeline myPipeline {} diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with wildcard import.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with wildcard import.sdstest index a1e2db9b..8e15e691 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with wildcard import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with wildcard import.sdstest @@ -2,18 +2,18 @@ package tests.scoping.annotationCalls.acrossFiles from safeds.scoping.annotationCalls.acrossFiles import * -// $TEST$ references safeds_MyAnnotation +# $TEST$ references safeds_MyAnnotation @»MyAnnotation« -// $TEST$ references same_AnnotationInSamePackage +# $TEST$ references same_AnnotationInSamePackage @»AnnotationInSamePackage« -// $TEST$ references safeds_AnnotationInSafeDsPackage +# $TEST$ references safeds_AnnotationInSafeDsPackage @»AnnotationInSafeDsPackage« -// $TEST$ unresolved +# $TEST$ unresolved @»AnnotationInAnotherPackage« -// $TEST$ unresolved +# $TEST$ unresolved @»AnnotationWithoutPackage« pipeline myPipeline {} diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/resource other package.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/resource other package.sdstest index ca30cdcb..52b2263d 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/resource other package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/resource other package.sdstest @@ -1,13 +1,13 @@ package tests.scoping.annotationCalls.acrossFiles.other -// $TEST$ target other_MyAnnotation +# $TEST$ target other_MyAnnotation annotation »MyAnnotation« -// $TEST$ target other_AnnotationInAnotherPackage +# $TEST$ target other_AnnotationInAnotherPackage annotation »AnnotationInAnotherPackage« -// $TEST$ target other_Annotation2InAnotherPackage +# $TEST$ target other_Annotation2InAnotherPackage annotation »Annotation2InAnotherPackage« -// $TEST$ target other_NotAnAnnotation +# $TEST$ target other_NotAnAnnotation class »NotAnAnnotation« diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/resource safeds package.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/resource safeds package.sdstest index ec8a3f21..2605ac41 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/resource safeds package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/resource safeds package.sdstest @@ -1,7 +1,7 @@ package safeds.scoping.annotationCalls.acrossFiles -// $TEST$ target safeds_MyAnnotation +# $TEST$ target safeds_MyAnnotation annotation »MyAnnotation« -// $TEST$ target safeds_AnnotationInSafeDsPackage +# $TEST$ target safeds_AnnotationInSafeDsPackage annotation »AnnotationInSafeDsPackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/resource same package.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/resource same package.sdstest index 1bb35a8b..9854b24a 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/resource same package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/resource same package.sdstest @@ -1,7 +1,7 @@ package tests.scoping.annotationCalls.acrossFiles -// $TEST$ target same_MyAnnotation +# $TEST$ target same_MyAnnotation annotation »MyAnnotation« -// $TEST$ target same_AnnotationInSamePackage +# $TEST$ target same_AnnotationInSamePackage annotation »AnnotationInSamePackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/resource without package.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/resource without package.sdstest index 39a33d04..c4c3bc48 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/resource without package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/resource without package.sdstest @@ -1,5 +1,5 @@ -// $TEST$ target without_MyAnnotation +# $TEST$ target without_MyAnnotation annotation »MyAnnotation« -// $TEST$ target without_AnnotationWithoutPackage +# $TEST$ target without_AnnotationWithoutPackage annotation »AnnotationWithoutPackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on annotation/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on annotation/main.sdstest index 80a2dca1..64f9c08c 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on annotation/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on annotation/main.sdstest @@ -1,19 +1,19 @@ package tests.scoping.annotationCalls.onAnnotation -// $TEST$ target before +# $TEST$ target before annotation »Before« -// $TEST$ references before +# $TEST$ references before @»Before« -// $TEST$ references after +# $TEST$ references after @»After« -// $TEST$ unresolved +# $TEST$ unresolved @»NotAnAnnotation« -// $TEST$ unresolved +# $TEST$ unresolved @»Unresolved« annotation MyAnnotation -// $TEST$ target after +# $TEST$ target after annotation »After« class NotAnAnnotation diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on attribute/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on attribute/main.sdstest index 125e7d75..31eda997 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on attribute/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on attribute/main.sdstest @@ -1,21 +1,21 @@ package tests.scoping.annotationCalls.onAttribute -// $TEST$ target before +# $TEST$ target before annotation »Before« class MyClass { - // $TEST$ references before + # $TEST$ references before @»Before« - // $TEST$ references after + # $TEST$ references after @»After« - // $TEST$ unresolved + # $TEST$ unresolved @»NotAnAnnotation« - // $TEST$ unresolved + # $TEST$ unresolved @»Unresolved« attr myAttribute: Int } -// $TEST$ target after +# $TEST$ target after annotation »After« class NotAnAnnotation diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on class/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on class/main.sdstest index ec43aa3c..4e12ad3a 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on class/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on class/main.sdstest @@ -1,19 +1,19 @@ package tests.scoping.annotationCalls.onClass -// $TEST$ target before +# $TEST$ target before annotation »Before« -// $TEST$ references before +# $TEST$ references before @»Before« -// $TEST$ references after +# $TEST$ references after @»After« -// $TEST$ unresolved +# $TEST$ unresolved @»NotAnAnnotation« -// $TEST$ unresolved +# $TEST$ unresolved @»Unresolved« class MyClass -// $TEST$ target after +# $TEST$ target after annotation »After« class NotAnAnnotation diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on enum variant/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on enum variant/main.sdstest index 1253875f..dfcb4aee 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on enum variant/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on enum variant/main.sdstest @@ -1,21 +1,21 @@ package tests.scoping.annotationCalls.onEnumVariant -// $TEST$ target before +# $TEST$ target before annotation »Before« enum MyEnum { - // $TEST$ references before + # $TEST$ references before @»Before« - // $TEST$ references after + # $TEST$ references after @»After« - // $TEST$ unresolved + # $TEST$ unresolved @»NotAnAnnotation« - // $TEST$ unresolved + # $TEST$ unresolved @»Unresolved« MyEnumVariant } -// $TEST$ target after +# $TEST$ target after annotation »After« class NotAnAnnotation diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on enum/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on enum/main.sdstest index 161aaa07..25e03d30 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on enum/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on enum/main.sdstest @@ -1,19 +1,19 @@ package tests.scoping.annotationCalls.onEnum -// $TEST$ target before +# $TEST$ target before annotation »Before« -// $TEST$ references before +# $TEST$ references before @»Before« -// $TEST$ references after +# $TEST$ references after @»After« -// $TEST$ unresolved +# $TEST$ unresolved @»NotAnAnnotation« -// $TEST$ unresolved +# $TEST$ unresolved @»Unresolved« enum MyEnum -// $TEST$ target after +# $TEST$ target after annotation »After« class NotAnAnnotation diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on function/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on function/main.sdstest index 81bdfa2d..34d8a0d0 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on function/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on function/main.sdstest @@ -1,19 +1,19 @@ package tests.scoping.annotationCalls.onFunction -// $TEST$ target before +# $TEST$ target before annotation »Before« -// $TEST$ references before +# $TEST$ references before @»Before« -// $TEST$ references after +# $TEST$ references after @»After« -// $TEST$ unresolved +# $TEST$ unresolved @»NotAnAnnotation« -// $TEST$ unresolved +# $TEST$ unresolved @»Unresolved« fun myFunction() -// $TEST$ target after +# $TEST$ target after annotation »After« class NotAnAnnotation diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on module/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on module/main.sdstest index 54d5f865..6c06279d 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on module/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on module/main.sdstest @@ -1,13 +1,13 @@ -// $TEST$ references annotation +# $TEST$ references annotation @»MyAnnotation« -// $TEST$ unresolved +# $TEST$ unresolved @»NotAnAnnotation« -// $TEST$ unresolved +# $TEST$ unresolved @»Unresolved« package tests.scoping.annotationCalls.onModule -// $TEST$ target annotation +# $TEST$ target annotation annotation »MyAnnotation« class NotAnAnnotation diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on parameter/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on parameter/main.sdstest index 2fbdde2c..e37541c2 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on parameter/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on parameter/main.sdstest @@ -1,16 +1,16 @@ package tests.scoping.annotationCalls.onParameter -// $TEST$ target before +# $TEST$ target before annotation »Before« fun myFunction( - // $TEST$ references before + # $TEST$ references before @»Before« - // $TEST$ references after + # $TEST$ references after @»After« - // $TEST$ unresolved + # $TEST$ unresolved @»NotAnAnnotation« - // $TEST$ unresolved + # $TEST$ unresolved @»Unresolved« myParameter: Int ) @@ -18,14 +18,14 @@ fun myFunction( pipeline myPipeline { val alias = Before; - // $TEST$ unresolved + # $TEST$ unresolved (@»alias« myParameter) {}; - // $TEST$ unresolved + # $TEST$ unresolved (@»alias« myParameter) -> 1; } -// $TEST$ target after +# $TEST$ target after annotation »After« class NotAnAnnotation diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on pipeline/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on pipeline/main.sdstest index c57cae47..50ca055f 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on pipeline/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on pipeline/main.sdstest @@ -1,19 +1,19 @@ package tests.scoping.annotationCalls.onPipeline -// $TEST$ target before +# $TEST$ target before annotation »Before« -// $TEST$ references before +# $TEST$ references before @»Before« -// $TEST$ references after +# $TEST$ references after @»After« -// $TEST$ unresolved +# $TEST$ unresolved @»NotAnAnnotation« -// $TEST$ unresolved +# $TEST$ unresolved @»Unresolved« pipeline myPipeline {} -// $TEST$ target after +# $TEST$ target after annotation »After« class NotAnAnnotation diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on result/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on result/main.sdstest index c34ac239..9aa81f3d 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on result/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on result/main.sdstest @@ -1,21 +1,21 @@ package tests.scoping.annotationCalls.onResult -// $TEST$ target before +# $TEST$ target before annotation »Before« fun myFunction() -> ( - // $TEST$ references before + # $TEST$ references before @»Before« - // $TEST$ references after + # $TEST$ references after @»After« - // $TEST$ unresolved + # $TEST$ unresolved @»NotAnAnnotation« - // $TEST$ unresolved + # $TEST$ unresolved @»Unresolved« myResult: Int ) -// $TEST$ target after +# $TEST$ target after annotation »After« class NotAnAnnotation diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on segment/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on segment/main.sdstest index db7a052a..dc296e02 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on segment/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on segment/main.sdstest @@ -1,19 +1,19 @@ package tests.scoping.annotationCalls.onSegment -// $TEST$ target before +# $TEST$ target before annotation »Before« -// $TEST$ references before +# $TEST$ references before @»Before« -// $TEST$ references after +# $TEST$ references after @»After« -// $TEST$ unresolved +# $TEST$ unresolved @»NotAnAnnotation« -// $TEST$ unresolved +# $TEST$ unresolved @»Unresolved« segment mySegment() {} -// $TEST$ target after +# $TEST$ target after annotation »After« class NotAnAnnotation diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on type parameter/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on type parameter/main.sdstest index fe990af1..6080fcd4 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on type parameter/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on type parameter/main.sdstest @@ -1,21 +1,21 @@ package tests.scoping.annotationCalls.onTypeParameter -// $TEST$ target before +# $TEST$ target before annotation »Before« fun myFunction< - // $TEST$ references before + # $TEST$ references before @»Before« - // $TEST$ references after + # $TEST$ references after @»After« - // $TEST$ unresolved + # $TEST$ unresolved @»NotAnAnnotation« - // $TEST$ unresolved + # $TEST$ unresolved @»Unresolved« MyTypeParameter >() -// $TEST$ target after +# $TEST$ target after annotation »After« class NotAnAnnotation diff --git a/packages/ttsl-lang/tests/resources/scoping/arguments/of annotation calls/to parameter/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/arguments/of annotation calls/to parameter/main.sdstest index f718a1e6..974fcb0d 100644 --- a/packages/ttsl-lang/tests/resources/scoping/arguments/of annotation calls/to parameter/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/arguments/of annotation calls/to parameter/main.sdstest @@ -1,20 +1,20 @@ package tests.scoping.arguments.ofAnnotationCalls.toParameter annotation MyAnnotation( - // $TEST$ target a + # $TEST$ target a »a«: Int, - // $TEST$ target b + # $TEST$ target b »b«: Int = 0, - // $TEST$ target c + # $TEST$ target c »c«: Int ) @MyAnnotation( - // $TEST$ references c + # $TEST$ references c »c« = 0, - // $TEST$ references a + # $TEST$ references a »a« = 0, - // $TEST$ references b + # $TEST$ references b »b« = 0 ) pipeline myPipeline {} diff --git a/packages/ttsl-lang/tests/resources/scoping/arguments/of annotation calls/to something other than parameter/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/arguments/of annotation calls/to something other than parameter/main.sdstest index a0edd6f0..56c9c3e0 100644 --- a/packages/ttsl-lang/tests/resources/scoping/arguments/of annotation calls/to something other than parameter/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/arguments/of annotation calls/to something other than parameter/main.sdstest @@ -3,7 +3,7 @@ package tests.scoping.arguments.ofAnnotationCalls.toSomethingOtherThanParameter annotation MyAnnotation(a: Int) @MyAnnotation( - // $TEST$ unresolved + # $TEST$ unresolved »MyAnnotation« = 0, ) pipeline myPipeline {} diff --git a/packages/ttsl-lang/tests/resources/scoping/arguments/of annotation calls/unresolved/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/arguments/of annotation calls/unresolved/main.sdstest index d391846e..6be88d00 100644 --- a/packages/ttsl-lang/tests/resources/scoping/arguments/of annotation calls/unresolved/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/arguments/of annotation calls/unresolved/main.sdstest @@ -3,11 +3,11 @@ package tests.scoping.arguments.ofAnnotationCalls.unresolved annotation MyAnnotation(a: Int) @MyAnnotation( - // $TEST$ unresolved + # $TEST$ unresolved »unresolved« = 0, ) @Unresolved( - // $TEST$ unresolved + # $TEST$ unresolved »a« = 0 ) pipeline myPipeline {} diff --git a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of annotation/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of annotation/main.sdstest index 97bfa9ed..5ef68672 100644 --- a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of annotation/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of annotation/main.sdstest @@ -1,31 +1,31 @@ package tests.scoping.arguments.ofCalls.toParameterOfAnnotation annotation MyAnnotation( - // $TEST$ target a + # $TEST$ target a »a«: Int, - // $TEST$ target b + # $TEST$ target b »b«: Int = 0, - // $TEST$ target c + # $TEST$ target c »c«: Int ) pipeline myPipeline { MyAnnotation( - // $TEST$ references c + # $TEST$ references c »c« = 0, - // $TEST$ references a + # $TEST$ references a »a« = 0, - // $TEST$ references b + # $TEST$ references b »b« = 0 ); val alias = MyAnnotation; alias( - // $TEST$ references c + # $TEST$ references c »c« = 0, - // $TEST$ references a + # $TEST$ references a »a« = 0, - // $TEST$ references b + # $TEST$ references b »b« = 0 ); } diff --git a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of block lambda/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of block lambda/main.sdstest index 0d1c6bf4..22138415 100644 --- a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of block lambda/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of block lambda/main.sdstest @@ -2,20 +2,20 @@ package tests.scoping.arguments.ofCalls.toParameterOfBlockLambda pipeline myPipeline { val myBlockLambda = ( - // $TEST$ target a + # $TEST$ target a »a«: Int, - // $TEST$ target b + # $TEST$ target b »b«: Int = 0, - // $TEST$ target c + # $TEST$ target c »c«: Int ) {}; myBlockLambda( - // $TEST$ references c + # $TEST$ references c »c« = 0, - // $TEST$ references a + # $TEST$ references a »a« = 0, - // $TEST$ references b + # $TEST$ references b »b« = 0 ); } diff --git a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of callable type/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of callable type/main.sdstest index 68626933..8a9d16d6 100644 --- a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of callable type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of callable type/main.sdstest @@ -1,29 +1,29 @@ package tests.scoping.arguments.ofCalls.toParameterOfCallableType segment mySegment(myCallableType: ( - // $TEST$ target a + # $TEST$ target a »a«: Int, - // $TEST$ target b + # $TEST$ target b »b«: Int = 0, - // $TEST$ target c + # $TEST$ target c »c«: Int ) -> ()) { myCallableType( - // $TEST$ references c + # $TEST$ references c »c« = 0, - // $TEST$ references a + # $TEST$ references a »a« = 0, - // $TEST$ references b + # $TEST$ references b »b« = 0 ); val alias = myCallableType; alias( - // $TEST$ references c + # $TEST$ references c »c« = 0, - // $TEST$ references a + # $TEST$ references a »a« = 0, - // $TEST$ references b + # $TEST$ references b »b« = 0 ); } diff --git a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of class/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of class/main.sdstest index 179e0353..8630ba26 100644 --- a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of class/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of class/main.sdstest @@ -1,31 +1,31 @@ package tests.scoping.arguments.ofCalls.toParameterOfClass class MyClass( - // $TEST$ target a + # $TEST$ target a »a«: Int, - // $TEST$ target b + # $TEST$ target b »b«: Int = 0, - // $TEST$ target c + # $TEST$ target c »c«: Int ) {} pipeline myPipeline { MyClass( - // $TEST$ references c + # $TEST$ references c »c« = 0, - // $TEST$ references a + # $TEST$ references a »a« = 0, - // $TEST$ references b + # $TEST$ references b »b« = 0 ); val alias = MyClass; alias( - // $TEST$ references c + # $TEST$ references c »c« = 0, - // $TEST$ references a + # $TEST$ references a »a« = 0, - // $TEST$ references b + # $TEST$ references b »b« = 0 ); } diff --git a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of enum variant/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of enum variant/main.sdstest index bcc2d952..2c3bdcfd 100644 --- a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of enum variant/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of enum variant/main.sdstest @@ -2,11 +2,11 @@ package tests.scoping.arguments.ofCalls.toParameterOfEnumVariant enum MyEnum { MyEnumVariant( - // $TEST$ target a + # $TEST$ target a »a«: Int, - // $TEST$ target b + # $TEST$ target b »b«: Int = 0, - // $TEST$ target c + # $TEST$ target c »c«: Int ) } @@ -14,21 +14,21 @@ enum MyEnum { pipeline myPipeline { MyEnum.MyEnumVariant( - // $TEST$ references c + # $TEST$ references c »c« = 0, - // $TEST$ references a + # $TEST$ references a »a« = 0, - // $TEST$ references b + # $TEST$ references b »b« = 0 ); val alias = MyEnum.MyEnumVariant; alias( - // $TEST$ references c + # $TEST$ references c »c« = 0, - // $TEST$ references a + # $TEST$ references a »a« = 0, - // $TEST$ references b + # $TEST$ references b »b« = 0 ); } diff --git a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of expression lambda/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of expression lambda/main.sdstest index 79ce806f..ef797025 100644 --- a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of expression lambda/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of expression lambda/main.sdstest @@ -2,20 +2,20 @@ package tests.scoping.arguments.ofCalls.toParameterOfExpressionLambda pipeline myPipeline { val myExpressionLambda = ( - // $TEST$ target a + # $TEST$ target a »a«: Int, - // $TEST$ target b + # $TEST$ target b »b«: Int = 0, - // $TEST$ target c + # $TEST$ target c »c«: Int ) -> 1; myExpressionLambda( - // $TEST$ references c + # $TEST$ references c »c« = 0, - // $TEST$ references a + # $TEST$ references a »a« = 0, - // $TEST$ references b + # $TEST$ references b »b« = 0 ); } diff --git a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of function/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of function/main.sdstest index 73a81bc8..38d51082 100644 --- a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of function/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of function/main.sdstest @@ -1,31 +1,31 @@ package tests.scoping.arguments.ofCalls.toParameterOfFunction fun myFunction( - // $TEST$ target a + # $TEST$ target a »a«: Int, - // $TEST$ target b + # $TEST$ target b »b«: Int = 0, - // $TEST$ target c + # $TEST$ target c »c«: Int ) pipeline myPipeline { myFunction( - // $TEST$ references c + # $TEST$ references c »c« = 0, - // $TEST$ references a + # $TEST$ references a »a« = 0, - // $TEST$ references b + # $TEST$ references b »b« = 0 ); val alias = myFunction; alias( - // $TEST$ references c + # $TEST$ references c »c« = 0, - // $TEST$ references a + # $TEST$ references a »a« = 0, - // $TEST$ references b + # $TEST$ references b »b« = 0 ); } diff --git a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of segment/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of segment/main.sdstest index e4957c07..c9710085 100644 --- a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of segment/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of segment/main.sdstest @@ -1,31 +1,31 @@ package tests.scoping.arguments.ofCalls.toParameterOfSegment segment mySegment( - // $TEST$ target a + # $TEST$ target a »a«: Int, - // $TEST$ target b + # $TEST$ target b »b«: Int = 0, - // $TEST$ target c + # $TEST$ target c »c«: Int ) {} pipeline myPipeline { mySegment( - // $TEST$ references c + # $TEST$ references c »c« = 0, - // $TEST$ references a + # $TEST$ references a »a« = 0, - // $TEST$ references b + # $TEST$ references b »b« = 0 ); val alias = mySegment; alias( - // $TEST$ references c + # $TEST$ references c »c« = 0, - // $TEST$ references a + # $TEST$ references a »a« = 0, - // $TEST$ references b + # $TEST$ references b »b« = 0 ); } diff --git a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to something other than parameter/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to something other than parameter/main.sdstest index 9df97d67..657adb16 100644 --- a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to something other than parameter/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to something other than parameter/main.sdstest @@ -3,6 +3,6 @@ package tests.scoping.arguments.ofCalls.toSomethingOtherThanParameter fun f(a: Int) pipeline myPipeline { - // $TEST$ unresolved + # $TEST$ unresolved f(»f« = 1); } diff --git a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/unresolved/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/unresolved/main.sdstest index 2c229246..29d244a8 100644 --- a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/unresolved/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/unresolved/main.sdstest @@ -3,9 +3,9 @@ package tests.scoping.arguments.ofCalls.unresolved fun f(a: Int) pipeline myPipeline { - // $TEST$ unresolved + # $TEST$ unresolved f(»unresolved« = 1); - // $TEST$ unresolved + # $TEST$ unresolved unresolved(»a« = 1); } diff --git a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/with nullable receiver/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/with nullable receiver/main.sdstest index e3429f92..6f8cfe0f 100644 --- a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/with nullable receiver/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/with nullable receiver/main.sdstest @@ -2,11 +2,11 @@ package tests.scoping.arguments.ofCalls.withNullableReceiver class MyClass { fun myFunction( - // $TEST$ target a + # $TEST$ target a »a«: Int, - // $TEST$ target b + # $TEST$ target b »b«: Int = 0, - // $TEST$ target c + # $TEST$ target c »c«: Int ) } @@ -15,20 +15,20 @@ segment mySegment( myClassOrNull: MyClass? ) { myClassOrNull?.myFunction( - // $TEST$ references c + # $TEST$ references c »c« = 0, - // $TEST$ references a + # $TEST$ references a »a« = 0, - // $TEST$ references b + # $TEST$ references b »b« = 0 ); myClassOrNull?.myFunction?( - // $TEST$ references c + # $TEST$ references c »c« = 0, - // $TEST$ references a + # $TEST$ references a »a« = 0, - // $TEST$ references b + # $TEST$ references b »b« = 0 ); } diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to annotations/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to annotations/main.sdstest index 27dee140..74253ce3 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to annotations/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to annotations/main.sdstest @@ -1,26 +1,26 @@ package tests.scoping.importedDeclarations.toAnnotations -// $TEST$ references own_OwnAnnotation +# $TEST$ references own_OwnAnnotation from tests.scoping.importedDeclarations.toAnnotations import »OwnAnnotation« -// $TEST$ references firstPackage_AnnotationInFirstPackage +# $TEST$ references firstPackage_AnnotationInFirstPackage from tests.scoping.importedDeclarations.toAnnotations.first import »AnnotationInFirstPackage« -// $TEST$ references secondPackage_AnnotationInSecondPackage +# $TEST$ references secondPackage_AnnotationInSecondPackage from tests.scoping.importedDeclarations.toAnnotations.second import »AnnotationInSecondPackage« -// $TEST$ references secondPackage_RedeclaredAnnotationInSameFile -// $TEST$ references secondPackage_RedeclaredAnnotationInOtherFile +# $TEST$ references secondPackage_RedeclaredAnnotationInSameFile +# $TEST$ references secondPackage_RedeclaredAnnotationInOtherFile from tests.scoping.importedDeclarations.toAnnotations.second import »RedeclaredAnnotationInSameFile«, »RedeclaredAnnotationInOtherFile« -// $TEST$ references secondPackage_AnnotationInBothPackages +# $TEST$ references secondPackage_AnnotationInBothPackages from tests.scoping.importedDeclarations.toAnnotations.second import »AnnotationInBothPackages« -// $TEST$ unresolved +# $TEST$ unresolved from tests.scoping.importedDeclarations.toAnnotations.second import »AnnotationInFirstPackage« -// $TEST$ target own_OwnAnnotation +# $TEST$ target own_OwnAnnotation annotation »OwnAnnotation« diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to annotations/resource first package.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to annotations/resource first package.sdstest index 822775f8..6e15db69 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to annotations/resource first package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to annotations/resource first package.sdstest @@ -1,7 +1,7 @@ package tests.scoping.importedDeclarations.toAnnotations.first -// $TEST$ target firstPackage_AnnotationInFirstPackage +# $TEST$ target firstPackage_AnnotationInFirstPackage annotation »AnnotationInFirstPackage« -// $TEST$ target firstPackage_AnnotationInBothPackages +# $TEST$ target firstPackage_AnnotationInBothPackages annotation »AnnotationInBothPackages« diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to annotations/resource second package.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to annotations/resource second package.sdstest index caaaed0f..ea410040 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to annotations/resource second package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to annotations/resource second package.sdstest @@ -1,14 +1,14 @@ package tests.scoping.importedDeclarations.toAnnotations.second -// $TEST$ target secondPackage_AnnotationInSecondPackage +# $TEST$ target secondPackage_AnnotationInSecondPackage annotation »AnnotationInSecondPackage« -// $TEST$ target secondPackage_RedeclaredAnnotationInSameFile +# $TEST$ target secondPackage_RedeclaredAnnotationInSameFile annotation »RedeclaredAnnotationInSameFile« annotation RedeclaredAnnotationInSameFile -// $TEST$ target secondPackage_RedeclaredAnnotationInOtherFile +# $TEST$ target secondPackage_RedeclaredAnnotationInOtherFile annotation »RedeclaredAnnotationInOtherFile« -// $TEST$ target secondPackage_AnnotationInBothPackages +# $TEST$ target secondPackage_AnnotationInBothPackages annotation »AnnotationInBothPackages« diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global classes/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global classes/main.sdstest index b3b7f341..88c480bc 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global classes/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global classes/main.sdstest @@ -1,26 +1,26 @@ package tests.scoping.importedDeclarations.toClasses -// $TEST$ references own_OwnClass +# $TEST$ references own_OwnClass from tests.scoping.importedDeclarations.toClasses import »OwnClass« -// $TEST$ references firstPackage_ClassInFirstPackage +# $TEST$ references firstPackage_ClassInFirstPackage from tests.scoping.importedDeclarations.toClasses.first import »ClassInFirstPackage« -// $TEST$ references secondPackage_ClassInSecondPackage +# $TEST$ references secondPackage_ClassInSecondPackage from tests.scoping.importedDeclarations.toClasses.second import »ClassInSecondPackage« -// $TEST$ references secondPackage_RedeclaredClassInSameFile -// $TEST$ references secondPackage_RedeclaredClassInOtherFile +# $TEST$ references secondPackage_RedeclaredClassInSameFile +# $TEST$ references secondPackage_RedeclaredClassInOtherFile from tests.scoping.importedDeclarations.toClasses.second import »RedeclaredClassInSameFile«, »RedeclaredClassInOtherFile« -// $TEST$ references secondPackage_ClassInBothPackages +# $TEST$ references secondPackage_ClassInBothPackages from tests.scoping.importedDeclarations.toClasses.second import »ClassInBothPackages« -// $TEST$ unresolved +# $TEST$ unresolved from tests.scoping.importedDeclarations.toClasses.second import »ClassInFirstPackage« -// $TEST$ target own_OwnClass +# $TEST$ target own_OwnClass class »OwnClass« diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global classes/resource first package.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global classes/resource first package.sdstest index 9a9ae936..f700aa6b 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global classes/resource first package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global classes/resource first package.sdstest @@ -1,7 +1,7 @@ package tests.scoping.importedDeclarations.toClasses.first -// $TEST$ target firstPackage_ClassInFirstPackage +# $TEST$ target firstPackage_ClassInFirstPackage class »ClassInFirstPackage« -// $TEST$ target firstPackage_ClassInBothPackages +# $TEST$ target firstPackage_ClassInBothPackages class »ClassInBothPackages« diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global classes/resource second package.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global classes/resource second package.sdstest index 654d717e..2ef76761 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global classes/resource second package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global classes/resource second package.sdstest @@ -1,14 +1,14 @@ package tests.scoping.importedDeclarations.toClasses.second -// $TEST$ target secondPackage_ClassInSecondPackage +# $TEST$ target secondPackage_ClassInSecondPackage class »ClassInSecondPackage« -// $TEST$ target secondPackage_RedeclaredClassInSameFile +# $TEST$ target secondPackage_RedeclaredClassInSameFile class »RedeclaredClassInSameFile« class RedeclaredClassInSameFile -// $TEST$ target secondPackage_RedeclaredClassInOtherFile +# $TEST$ target secondPackage_RedeclaredClassInOtherFile class »RedeclaredClassInOtherFile« -// $TEST$ target secondPackage_ClassInBothPackages +# $TEST$ target secondPackage_ClassInBothPackages class »ClassInBothPackages« diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global enums/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global enums/main.sdstest index 66594ba3..74d82c32 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global enums/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global enums/main.sdstest @@ -1,26 +1,26 @@ package tests.scoping.importedDeclarations.toEnums -// $TEST$ references own_OwnEnum +# $TEST$ references own_OwnEnum from tests.scoping.importedDeclarations.toEnums import »OwnEnum« -// $TEST$ references firstPackage_EnumInFirstPackage +# $TEST$ references firstPackage_EnumInFirstPackage from tests.scoping.importedDeclarations.toEnums.first import »EnumInFirstPackage« -// $TEST$ references secondPackage_EnumInSecondPackage +# $TEST$ references secondPackage_EnumInSecondPackage from tests.scoping.importedDeclarations.toEnums.second import »EnumInSecondPackage« -// $TEST$ references secondPackage_RedeclaredEnumInSameFile -// $TEST$ references secondPackage_RedeclaredEnumInOtherFile +# $TEST$ references secondPackage_RedeclaredEnumInSameFile +# $TEST$ references secondPackage_RedeclaredEnumInOtherFile from tests.scoping.importedDeclarations.toEnums.second import »RedeclaredEnumInSameFile«, »RedeclaredEnumInOtherFile« -// $TEST$ references secondPackage_EnumInBothPackages +# $TEST$ references secondPackage_EnumInBothPackages from tests.scoping.importedDeclarations.toEnums.second import »EnumInBothPackages« -// $TEST$ unresolved +# $TEST$ unresolved from tests.scoping.importedDeclarations.toEnums.second import »EnumInFirstPackage« -// $TEST$ target own_OwnEnum +# $TEST$ target own_OwnEnum enum »OwnEnum« diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global enums/resource first package.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global enums/resource first package.sdstest index a563a8f8..15094ae9 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global enums/resource first package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global enums/resource first package.sdstest @@ -1,7 +1,7 @@ package tests.scoping.importedDeclarations.toEnums.first -// $TEST$ target firstPackage_EnumInFirstPackage +# $TEST$ target firstPackage_EnumInFirstPackage enum »EnumInFirstPackage« -// $TEST$ target firstPackage_EnumInBothPackages +# $TEST$ target firstPackage_EnumInBothPackages enum »EnumInBothPackages« diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global enums/resource second package.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global enums/resource second package.sdstest index 670236f5..cc65e7ed 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global enums/resource second package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global enums/resource second package.sdstest @@ -1,14 +1,14 @@ package tests.scoping.importedDeclarations.toEnums.second -// $TEST$ target secondPackage_EnumInSecondPackage +# $TEST$ target secondPackage_EnumInSecondPackage enum »EnumInSecondPackage« -// $TEST$ target secondPackage_RedeclaredEnumInSameFile +# $TEST$ target secondPackage_RedeclaredEnumInSameFile enum »RedeclaredEnumInSameFile« enum RedeclaredEnumInSameFile -// $TEST$ target secondPackage_RedeclaredEnumInOtherFile +# $TEST$ target secondPackage_RedeclaredEnumInOtherFile enum »RedeclaredEnumInOtherFile« -// $TEST$ target secondPackage_EnumInBothPackages +# $TEST$ target secondPackage_EnumInBothPackages enum »EnumInBothPackages« diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global functions/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global functions/main.sdstest index 17f57d81..cc1a7bee 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global functions/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global functions/main.sdstest @@ -1,26 +1,26 @@ package tests.scoping.importedDeclarations.toFunctions -// $TEST$ references own_ownFunction +# $TEST$ references own_ownFunction from tests.scoping.importedDeclarations.toFunctions import »ownFunction« -// $TEST$ references firstPackage_functionInFirstPackage +# $TEST$ references firstPackage_functionInFirstPackage from tests.scoping.importedDeclarations.toFunctions.first import »functionInFirstPackage« -// $TEST$ references secondPackage_functionInSecondPackage +# $TEST$ references secondPackage_functionInSecondPackage from tests.scoping.importedDeclarations.toFunctions.second import »functionInSecondPackage« -// $TEST$ references secondPackage_redeclaredFunctionInSameFile -// $TEST$ references secondPackage_redeclaredFunctionInOtherFile +# $TEST$ references secondPackage_redeclaredFunctionInSameFile +# $TEST$ references secondPackage_redeclaredFunctionInOtherFile from tests.scoping.importedDeclarations.toFunctions.second import »redeclaredFunctionInSameFile«, »redeclaredFunctionInOtherFile« -// $TEST$ references secondPackage_functionInBothPackages +# $TEST$ references secondPackage_functionInBothPackages from tests.scoping.importedDeclarations.toFunctions.second import »functionInBothPackages« -// $TEST$ unresolved +# $TEST$ unresolved from tests.scoping.importedDeclarations.toFunctions.second import »functionInFirstPackage« -// $TEST$ target own_ownFunction +# $TEST$ target own_ownFunction fun »ownFunction«() diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global functions/resource first package.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global functions/resource first package.sdstest index 4fe65ce3..72fbec46 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global functions/resource first package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global functions/resource first package.sdstest @@ -1,7 +1,7 @@ package tests.scoping.importedDeclarations.toFunctions.first -// $TEST$ target firstPackage_functionInFirstPackage +# $TEST$ target firstPackage_functionInFirstPackage fun »functionInFirstPackage«() -// $TEST$ target firstPackage_functionInBothPackages +# $TEST$ target firstPackage_functionInBothPackages fun »functionInBothPackages«() diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global functions/resource second package.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global functions/resource second package.sdstest index 0b857158..dc61d0e2 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global functions/resource second package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global functions/resource second package.sdstest @@ -1,14 +1,14 @@ package tests.scoping.importedDeclarations.toFunctions.second -// $TEST$ target secondPackage_functionInSecondPackage +# $TEST$ target secondPackage_functionInSecondPackage fun »functionInSecondPackage«() -// $TEST$ target secondPackage_redeclaredFunctionInSameFile +# $TEST$ target secondPackage_redeclaredFunctionInSameFile fun »redeclaredFunctionInSameFile«() fun redeclaredFunctionInSameFile() -// $TEST$ target secondPackage_redeclaredFunctionInOtherFile +# $TEST$ target secondPackage_redeclaredFunctionInOtherFile fun »redeclaredFunctionInOtherFile«() -// $TEST$ target secondPackage_functionInBothPackages +# $TEST$ target secondPackage_functionInBothPackages fun »functionInBothPackages«() diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to nested declaration/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to nested declaration/main.sdstest index e0216342..dee44e90 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to nested declaration/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to nested declaration/main.sdstest @@ -1,28 +1,28 @@ package tests.scoping.importedDeclarations.toNestedDeclaration -// $TEST$ unresolved +# $TEST$ unresolved from tests.scoping.importedDeclarations.toNestedDeclaration import »OwnClass« -// $TEST$ unresolved +# $TEST$ unresolved from tests.scoping.importedDeclarations.toNestedDeclaration.first import »ClassInFirstPackage« -// $TEST$ unresolved +# $TEST$ unresolved from tests.scoping.importedDeclarations.toNestedDeclaration.second import »ClassInSecondPackage« -// $TEST$ unresolved -// $TEST$ unresolved +# $TEST$ unresolved +# $TEST$ unresolved from tests.scoping.importedDeclarations.toNestedDeclaration.second import »RedeclaredClassInSameFile«, »RedeclaredClassInOtherFile« -// $TEST$ unresolved +# $TEST$ unresolved from tests.scoping.importedDeclarations.toNestedDeclaration.second import »ClassInBothPackages« -// $TEST$ unresolved +# $TEST$ unresolved from tests.scoping.importedDeclarations.toNestedDeclaration.second import »ClassInFirstPackage« class Outer { - // $TEST$ target own_OwnClass + # $TEST$ target own_OwnClass class »OwnClass« } diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to nested declaration/resource first package.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to nested declaration/resource first package.sdstest index 200bf7e8..295affac 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to nested declaration/resource first package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to nested declaration/resource first package.sdstest @@ -1,9 +1,9 @@ package tests.scoping.importedDeclarations.toNestedDeclaration.first class Outer { - // $TEST$ target firstPackage_ClassInFirstPackage + # $TEST$ target firstPackage_ClassInFirstPackage class »ClassInFirstPackage« - // $TEST$ target firstPackage_ClassInBothPackages + # $TEST$ target firstPackage_ClassInBothPackages class »ClassInBothPackages« } diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to nested declaration/resource second package.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to nested declaration/resource second package.sdstest index a2194dd8..6a341092 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to nested declaration/resource second package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to nested declaration/resource second package.sdstest @@ -1,16 +1,16 @@ package tests.scoping.importedDeclarations.toNestedDeclaration.second class Outer { - // $TEST$ target secondPackage_ClassInSecondPackage + # $TEST$ target secondPackage_ClassInSecondPackage class »ClassInSecondPackage« - // $TEST$ target secondPackage_RedeclaredClassInSameFile + # $TEST$ target secondPackage_RedeclaredClassInSameFile class »RedeclaredClassInSameFile« class RedeclaredClassInSameFile - // $TEST$ target secondPackage_RedeclaredClassInOtherFile + # $TEST$ target secondPackage_RedeclaredClassInOtherFile class »RedeclaredClassInOtherFile« - // $TEST$ target secondPackage_ClassInBothPackages + # $TEST$ target secondPackage_ClassInBothPackages class »ClassInBothPackages« } diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to pipelines/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to pipelines/main.sdstest index 0085c16d..3ecf4ead 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to pipelines/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to pipelines/main.sdstest @@ -1,26 +1,26 @@ package tests.scoping.importedDeclarations.toPipelines -// $TEST$ unresolved +# $TEST$ unresolved from tests.scoping.importedDeclarations.toPipelines import »ownPipeline« -// $TEST$ unresolved +# $TEST$ unresolved from tests.scoping.importedDeclarations.toPipelines.first import »pipelineInFirstPackage« -// $TEST$ unresolved +# $TEST$ unresolved from tests.scoping.importedDeclarations.toPipelines.second import »pipelineInSecondPackage« -// $TEST$ unresolved -// $TEST$ unresolved +# $TEST$ unresolved +# $TEST$ unresolved from tests.scoping.importedDeclarations.toPipelines.second import »redeclaredPipelineInSameFile«, »redeclaredPipelineInOtherFile« -// $TEST$ unresolved +# $TEST$ unresolved from tests.scoping.importedDeclarations.toPipelines.second import »pipelineInBothPackages« -// $TEST$ unresolved +# $TEST$ unresolved from tests.scoping.importedDeclarations.toPipelines.second import »pipelineInFirstPackage« -// $TEST$ target own_ownPipeline +# $TEST$ target own_ownPipeline pipeline »ownPipeline« {} diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to pipelines/resource first package.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to pipelines/resource first package.sdstest index 0606253c..b8be21f4 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to pipelines/resource first package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to pipelines/resource first package.sdstest @@ -1,7 +1,7 @@ package tests.scoping.importedDeclarations.toPipelines.first -// $TEST$ target firstPackage_pipelineInFirstPackage +# $TEST$ target firstPackage_pipelineInFirstPackage pipeline »pipelineInFirstPackage« {} -// $TEST$ target firstPackage_pipelineInBothPackages +# $TEST$ target firstPackage_pipelineInBothPackages pipeline »pipelineInBothPackages« {} diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to pipelines/resource second package.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to pipelines/resource second package.sdstest index 87a9d28b..7ab64fe1 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to pipelines/resource second package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to pipelines/resource second package.sdstest @@ -1,14 +1,14 @@ package tests.scoping.importedDeclarations.toPipelines.second -// $TEST$ target secondPackage_pipelineInSecondPackage +# $TEST$ target secondPackage_pipelineInSecondPackage pipeline »pipelineInSecondPackage« {} -// $TEST$ target secondPackage_redeclaredPipelineInSameFile +# $TEST$ target secondPackage_redeclaredPipelineInSameFile pipeline »redeclaredPipelineInSameFile« {} pipeline redeclaredPipelineInSameFile {} -// $TEST$ target secondPackage_redeclaredPipelineInOtherFile +# $TEST$ target secondPackage_redeclaredPipelineInOtherFile pipeline »redeclaredPipelineInOtherFile« {} -// $TEST$ target secondPackage_pipelineInBothPackages +# $TEST$ target secondPackage_pipelineInBothPackages pipeline »pipelineInBothPackages« {} diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to schemas/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to schemas/main.sdstest index 50e262a5..c84bcafb 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to schemas/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to schemas/main.sdstest @@ -1,25 +1,25 @@ package tests.scoping.importedDeclarations.toSchemas -// $TEST$ references own_OwnSchema +# $TEST$ references own_OwnSchema from tests.scoping.importedDeclarations.toSchemas import »OwnSchema« -// $TEST$ references firstPackage_SchemaInFirstPackage +# $TEST$ references firstPackage_SchemaInFirstPackage from tests.scoping.importedDeclarations.toSchemas.first import »SchemaInFirstPackage« -// $TEST$ references secondPackage_SchemaInSecondPackage +# $TEST$ references secondPackage_SchemaInSecondPackage from tests.scoping.importedDeclarations.toSchemas.second import »SchemaInSecondPackage« -// $TEST$ references secondPackage_RedeclaredSchemaInSameFile -// $TEST$ references secondPackage_RedeclaredSchemaInOtherFile +# $TEST$ references secondPackage_RedeclaredSchemaInSameFile +# $TEST$ references secondPackage_RedeclaredSchemaInOtherFile from tests.scoping.importedDeclarations.toSchemas.second import »RedeclaredSchemaInSameFile«, »RedeclaredSchemaInOtherFile« -// $TEST$ references secondPackage_SchemaInBothPackages +# $TEST$ references secondPackage_SchemaInBothPackages from tests.scoping.importedDeclarations.toSchemas.second import »SchemaInBothPackages« -// $TEST$ unresolved +# $TEST$ unresolved from tests.scoping.importedDeclarations.toSchemas.second import »SchemaInFirstPackage« -// $TEST$ target own_OwnSchema +# $TEST$ target own_OwnSchema schema »OwnSchema« {} diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to schemas/resource first package.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to schemas/resource first package.sdstest index 281edb62..6b1fd295 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to schemas/resource first package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to schemas/resource first package.sdstest @@ -1,7 +1,7 @@ package tests.scoping.importedDeclarations.toSchemas.first -// $TEST$ target firstPackage_SchemaInFirstPackage +# $TEST$ target firstPackage_SchemaInFirstPackage schema »SchemaInFirstPackage« {} -// $TEST$ target firstPackage_SchemaInBothPackages +# $TEST$ target firstPackage_SchemaInBothPackages schema »SchemaInBothPackages« {} diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to schemas/resource second package.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to schemas/resource second package.sdstest index 56f66891..e83803bf 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to schemas/resource second package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to schemas/resource second package.sdstest @@ -1,14 +1,14 @@ package tests.scoping.importedDeclarations.toSchemas.second -// $TEST$ target secondPackage_SchemaInSecondPackage +# $TEST$ target secondPackage_SchemaInSecondPackage schema »SchemaInSecondPackage« {} -// $TEST$ target secondPackage_RedeclaredSchemaInSameFile +# $TEST$ target secondPackage_RedeclaredSchemaInSameFile schema »RedeclaredSchemaInSameFile« {} schema RedeclaredSchemaInSameFile {} -// $TEST$ target secondPackage_RedeclaredSchemaInOtherFile +# $TEST$ target secondPackage_RedeclaredSchemaInOtherFile schema »RedeclaredSchemaInOtherFile« {} -// $TEST$ target secondPackage_SchemaInBothPackages +# $TEST$ target secondPackage_SchemaInBothPackages schema »SchemaInBothPackages« {} diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to segments/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to segments/main.sdstest index caff4fa1..af003613 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to segments/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to segments/main.sdstest @@ -1,42 +1,42 @@ package tests.scoping.importedDeclarations.toSegments -// $TEST$ references own_ownSegment +# $TEST$ references own_ownSegment from tests.scoping.importedDeclarations.toSegments import »ownSegment« -// $TEST$ references same_publicSegmentInSamePackage +# $TEST$ references same_publicSegmentInSamePackage from tests.scoping.importedDeclarations.toSegments import »publicSegmentInSamePackage« -// $TEST$ references same_internalSegmentInSamePackage +# $TEST$ references same_internalSegmentInSamePackage from tests.scoping.importedDeclarations.toSegments import »internalSegmentInSamePackage« -// $TEST$ unresolved +# $TEST$ unresolved from tests.scoping.importedDeclarations.toSegments import »privateSegmentInSamePackage« -// $TEST$ references firstPackage_segmentInFirstPackage +# $TEST$ references firstPackage_segmentInFirstPackage from tests.scoping.importedDeclarations.toSegments.first import »segmentInFirstPackage« -// $TEST$ references secondPackage_publicSegmentInSecondPackage +# $TEST$ references secondPackage_publicSegmentInSecondPackage from tests.scoping.importedDeclarations.toSegments.second import »publicSegmentInSecondPackage« -// $TEST$ unresolved +# $TEST$ unresolved from tests.scoping.importedDeclarations.toSegments.second import »internalSegmentInSecondPackage« -// $TEST$ unresolved +# $TEST$ unresolved from tests.scoping.importedDeclarations.toSegments.second import »privateSegmentInSecondPackage« -// $TEST$ references secondPackage_redeclaredSegmentInSameFile -// $TEST$ references secondPackage_redeclaredSegmentInOtherFile +# $TEST$ references secondPackage_redeclaredSegmentInSameFile +# $TEST$ references secondPackage_redeclaredSegmentInOtherFile from tests.scoping.importedDeclarations.toSegments.second import »redeclaredSegmentInSameFile«, »redeclaredSegmentInOtherFile« -// $TEST$ references secondPackage_segmentInBothPackages +# $TEST$ references secondPackage_segmentInBothPackages from tests.scoping.importedDeclarations.toSegments.second import »segmentInBothPackages« -// $TEST$ unresolved +# $TEST$ unresolved from tests.scoping.importedDeclarations.toSegments.second import »segmentInFirstPackage« -// $TEST$ target own_ownSegment +# $TEST$ target own_ownSegment segment »ownSegment«() {} diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to segments/resource first package.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to segments/resource first package.sdstest index 8ba7afa9..8afd310f 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to segments/resource first package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to segments/resource first package.sdstest @@ -1,7 +1,7 @@ package tests.scoping.importedDeclarations.toSegments.first -// $TEST$ target firstPackage_segmentInFirstPackage +# $TEST$ target firstPackage_segmentInFirstPackage segment »segmentInFirstPackage«() {} -// $TEST$ target firstPackage_segmentInBothPackages +# $TEST$ target firstPackage_segmentInBothPackages segment »segmentInBothPackages«() {} diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to segments/resource same package.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to segments/resource same package.sdstest index 682f954b..3a335555 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to segments/resource same package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to segments/resource same package.sdstest @@ -1,10 +1,10 @@ package tests.scoping.importedDeclarations.toSegments -// $TEST$ target same_publicSegmentInSamePackage +# $TEST$ target same_publicSegmentInSamePackage segment »publicSegmentInSamePackage«() {} -// $TEST$ target same_internalSegmentInSamePackage +# $TEST$ target same_internalSegmentInSamePackage internal segment »internalSegmentInSamePackage«() {} -// $TEST$ target same_privateSegmentInSamePackage +# $TEST$ target same_privateSegmentInSamePackage private segment »privateSegmentInSamePackage«() {} diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to segments/resource second package.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to segments/resource second package.sdstest index b3ee4279..73473ec7 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to segments/resource second package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to segments/resource second package.sdstest @@ -1,20 +1,20 @@ package tests.scoping.importedDeclarations.toSegments.second -// $TEST$ target secondPackage_publicSegmentInSecondPackage +# $TEST$ target secondPackage_publicSegmentInSecondPackage segment »publicSegmentInSecondPackage«() {} -// $TEST$ target secondPackage_internalSegmentInSecondPackage +# $TEST$ target secondPackage_internalSegmentInSecondPackage internal segment »internalSegmentInSecondPackage«() {} -// $TEST$ target secondPackage_privateSegmentInSecondPackage +# $TEST$ target secondPackage_privateSegmentInSecondPackage private segment »privateSegmentInSecondPackage«() {} -// $TEST$ target secondPackage_redeclaredSegmentInSameFile +# $TEST$ target secondPackage_redeclaredSegmentInSameFile segment »redeclaredSegmentInSameFile«() {} segment redeclaredSegmentInSameFile() {} -// $TEST$ target secondPackage_redeclaredSegmentInOtherFile +# $TEST$ target secondPackage_redeclaredSegmentInOtherFile segment »redeclaredSegmentInOtherFile«() {} -// $TEST$ target secondPackage_segmentInBothPackages +# $TEST$ target secondPackage_segmentInBothPackages segment »segmentInBothPackages«() {} diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/unresolved/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/unresolved/main.sdstest index f536308a..7c0095b4 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/unresolved/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/unresolved/main.sdstest @@ -1,4 +1,4 @@ package tests.scoping.importedDeclarations.unresolved -// $TEST$ unresolved +# $TEST$ unresolved from tests.scoping.importedDeclarations.toAnnotations import »unresolved« diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/on type parameters/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/on type parameters/main.sdstest index 4883da99..3fc35f6f 100644 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/on type parameters/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/member accesses/on type parameters/main.sdstest @@ -1,7 +1,7 @@ package tests.scoping.memberAccesses.onTypeParameters class C { - // $TEST$ target attribute + # $TEST$ target attribute attr »a«: Int } @@ -9,9 +9,9 @@ class MyClass( unbounded: Unbounded, upperBound: UpperBound, - // $TEST$ unresolved + # $TEST$ unresolved p1: Any = unbounded.»a«, - // $TEST$ references attribute + # $TEST$ references attribute p2: Any = upperBound.»a«, ) { attr unbounded: Unbounded @@ -19,9 +19,9 @@ class MyClass( } segment mySegment(instance: MyClass) { - // $TEST$ references attribute + # $TEST$ references attribute instance.unbounded.»a«; - // $TEST$ references attribute + # $TEST$ references attribute instance.upperBound.»a«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/hiding/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/hiding/main.sdstest index 8f4afe94..fabcc576 100644 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/hiding/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/hiding/main.sdstest @@ -1,43 +1,43 @@ package tests.scoping.memberAccesses.toClassMembers.hiding class MySuperClass { - // $TEST$ target MySuperClass_myStaticAttribute + # $TEST$ target MySuperClass_myStaticAttribute static attr »myStaticAttribute«: Int - // $TEST$ target MySuperClass_myNestedClass + # $TEST$ target MySuperClass_myNestedClass class »MyNestedClass« - // $TEST$ target MySuperClass_myNestedEnum + # $TEST$ target MySuperClass_myNestedEnum enum »MyNestedEnum« - // $TEST$ target MySuperClass_myStaticMethod + # $TEST$ target MySuperClass_myStaticMethod static fun »myStaticMethod1«() } class MyClass sub MySuperClass { - // $TEST$ target MyClass_myStaticAttribute + # $TEST$ target MyClass_myStaticAttribute static attr »myStaticAttribute«: Int - // $TEST$ target MyClass_myNestedClass + # $TEST$ target MyClass_myNestedClass class »MyNestedClass« - // $TEST$ target MyClass_myNestedEnum + # $TEST$ target MyClass_myNestedEnum enum »MyNestedEnum« - // $TEST$ target MyClass_myStaticMethod + # $TEST$ target MyClass_myStaticMethod static fun »myStaticMethod1«() } pipeline myPipeline { - // $TEST$ references MyClass_myStaticAttribute + # $TEST$ references MyClass_myStaticAttribute MyClass.»myStaticAttribute«; - // $TEST$ references MyClass_myNestedClass + # $TEST$ references MyClass_myNestedClass MyClass.»MyNestedClass«; - // $TEST$ references MyClass_myNestedEnum + # $TEST$ references MyClass_myNestedEnum MyClass.»MyNestedEnum«; - // $TEST$ references MyClass_myStaticMethod + # $TEST$ references MyClass_myStaticMethod MyClass.»myStaticMethod1«(); } diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/inheritance/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/inheritance/main.sdstest index ae51019d..93954673 100644 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/inheritance/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/inheritance/main.sdstest @@ -1,84 +1,84 @@ package tests.scoping.memberAccesses.toClassMembers.inheritance class MySuperClass1 { - // $TEST$ target MySuperClass1_myInstanceAttribute + # $TEST$ target MySuperClass1_myInstanceAttribute attr »myInstanceAttribute1«: Int - // $TEST$ target MySuperClass1_myInstanceMethod + # $TEST$ target MySuperClass1_myInstanceMethod fun »myInstanceMethod1«() - // $TEST$ target MySuperClass1_myStaticAttribute + # $TEST$ target MySuperClass1_myStaticAttribute static attr »myStaticAttribute1«: Int - // $TEST$ target MySuperClass1_myNestedClass + # $TEST$ target MySuperClass1_myNestedClass class »MyNestedClass1« - // $TEST$ target MySuperClass1_myNestedEnum + # $TEST$ target MySuperClass1_myNestedEnum enum »MyNestedEnum1« - // $TEST$ target MySuperClass1_myStaticMethod + # $TEST$ target MySuperClass1_myStaticMethod static fun »myStaticMethod1«() } class MySuperClass2 { - // $TEST$ target MySuperClass2_myInstanceAttribute + # $TEST$ target MySuperClass2_myInstanceAttribute attr »myInstanceAttribute2«: Int - // $TEST$ target MySuperClass2_myInstanceMethod + # $TEST$ target MySuperClass2_myInstanceMethod fun »myInstanceMethod2«() - // $TEST$ target MySuperClass2_myStaticAttribute + # $TEST$ target MySuperClass2_myStaticAttribute static attr »myStaticAttribute2«: Int - // $TEST$ target MySuperClass2_myNestedClass + # $TEST$ target MySuperClass2_myNestedClass class »MyNestedClass2« - // $TEST$ target MySuperClass2_myNestedEnum + # $TEST$ target MySuperClass2_myNestedEnum enum »MyNestedEnum2« - // $TEST$ target MySuperClass2_myStaticMethod + # $TEST$ target MySuperClass2_myStaticMethod static fun »myStaticMethod2«() } class MyClass() sub MySuperClass1, MySuperClass2 pipeline myPipeline { - // $TEST$ references MySuperClass1_myInstanceAttribute + # $TEST$ references MySuperClass1_myInstanceAttribute MyClass().»myInstanceAttribute1«; - // $TEST$ references MySuperClass1_myInstanceMethod + # $TEST$ references MySuperClass1_myInstanceMethod MyClass().»myInstanceMethod1«(); - // $TEST$ references MySuperClass1_myStaticAttribute + # $TEST$ references MySuperClass1_myStaticAttribute MyClass.»myStaticAttribute1«; - // $TEST$ references MySuperClass1_myNestedClass + # $TEST$ references MySuperClass1_myNestedClass MyClass.»MyNestedClass1«; - // $TEST$ references MySuperClass1_myNestedEnum + # $TEST$ references MySuperClass1_myNestedEnum MyClass.»MyNestedEnum1«; - // $TEST$ references MySuperClass1_myStaticMethod + # $TEST$ references MySuperClass1_myStaticMethod MyClass.»myStaticMethod1«(); - // $TEST$ unresolved + # $TEST$ unresolved MyClass().»myInstanceAttribute2«; - // $TEST$ unresolved + # $TEST$ unresolved MyClass().»myInstanceMethod2«(); - // $TEST$ unresolved + # $TEST$ unresolved MyClass.»myStaticAttribute2«; - // $TEST$ unresolved + # $TEST$ unresolved MyClass.»MyNestedClass2«; - // $TEST$ unresolved + # $TEST$ unresolved MyClass.»MyNestedEnum2«; - // $TEST$ unresolved + # $TEST$ unresolved MyClass.»myStaticMethod2«(); } diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/instance attributes/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/instance attributes/main.sdstest index 4a5ddbcb..7920af7b 100644 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/instance attributes/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/instance attributes/main.sdstest @@ -1,48 +1,48 @@ package tests.scoping.memberAccesses.toClassMembers.instanceAttributes class MyClass { - // $TEST$ target myInstanceAttribute + # $TEST$ target myInstanceAttribute attr »myInstanceAttribute«: Int - // $TEST$ target redeclaredAsInstanceAttribute + # $TEST$ target redeclaredAsInstanceAttribute attr »redeclaredAsInstanceAttribute«: Int attr redeclaredAsInstanceAttribute: Int - // $TEST$ target redeclaredAsStaticAttribute + # $TEST$ target redeclaredAsStaticAttribute attr »redeclaredAsStaticAttribute«: Int static attr redeclaredAsStaticAttribute: Int - // $TEST$ target redeclaredAsNestedClass + # $TEST$ target redeclaredAsNestedClass attr »redeclaredAsNestedClass«: Int class redeclaredAsNestedClass - // $TEST$ target redeclaredAsNestedEnum + # $TEST$ target redeclaredAsNestedEnum attr »redeclaredAsNestedEnum«: Int enum redeclaredAsNestedEnum - // $TEST$ target redeclaredAsInstanceMethod + # $TEST$ target redeclaredAsInstanceMethod attr »redeclaredAsInstanceMethod«: Int fun redeclaredAsInstanceMethod() - // $TEST$ target redeclaredAsStaticMethod + # $TEST$ target redeclaredAsStaticMethod attr »redeclaredAsStaticMethod«: Int static fun redeclaredAsStaticMethod() - // $TEST$ target declaredPreviouslyAsStaticAttribute + # $TEST$ target declaredPreviouslyAsStaticAttribute static attr declaredPreviouslyAsStaticAttribute: Int attr »declaredPreviouslyAsStaticAttribute«: Int - // $TEST$ target declaredPreviouslyAsNestedClass + # $TEST$ target declaredPreviouslyAsNestedClass class declaredPreviouslyAsNestedClass attr »declaredPreviouslyAsNestedClass«: Int - // $TEST$ target declaredPreviouslyAsNestedEnum + # $TEST$ target declaredPreviouslyAsNestedEnum class declaredPreviouslyAsNestedEnum attr »declaredPreviouslyAsNestedEnum«: Int - // $TEST$ target declaredPreviouslyAsStaticMethod + # $TEST$ target declaredPreviouslyAsStaticMethod static fun declaredPreviouslyAsStaticMethod() attr »declaredPreviouslyAsStaticMethod«: Int } @@ -52,57 +52,57 @@ class AnotherClass fun nullableMyClass() -> result: MyClass? pipeline myPipeline { - // $TEST$ references myInstanceAttribute + # $TEST$ references myInstanceAttribute val myClass = MyClass(); myClass.»myInstanceAttribute«; - // $TEST$ references redeclaredAsInstanceAttribute + # $TEST$ references redeclaredAsInstanceAttribute MyClass().»redeclaredAsInstanceAttribute«; - // $TEST$ references redeclaredAsStaticAttribute + # $TEST$ references redeclaredAsStaticAttribute MyClass().»redeclaredAsStaticAttribute«; - // $TEST$ references redeclaredAsNestedClass + # $TEST$ references redeclaredAsNestedClass MyClass().»redeclaredAsNestedClass«; - // $TEST$ references redeclaredAsNestedEnum + # $TEST$ references redeclaredAsNestedEnum MyClass().»redeclaredAsNestedEnum«; - // $TEST$ references redeclaredAsInstanceMethod + # $TEST$ references redeclaredAsInstanceMethod MyClass().»redeclaredAsInstanceMethod«; - // $TEST$ references redeclaredAsStaticMethod + # $TEST$ references redeclaredAsStaticMethod MyClass().»redeclaredAsStaticMethod«; - // $TEST$ references declaredPreviouslyAsStaticAttribute + # $TEST$ references declaredPreviouslyAsStaticAttribute MyClass().»declaredPreviouslyAsStaticAttribute«; - // $TEST$ references declaredPreviouslyAsNestedClass + # $TEST$ references declaredPreviouslyAsNestedClass MyClass().»declaredPreviouslyAsNestedClass«; - // $TEST$ references declaredPreviouslyAsNestedEnum + # $TEST$ references declaredPreviouslyAsNestedEnum MyClass().»declaredPreviouslyAsNestedEnum«; - // $TEST$ references declaredPreviouslyAsStaticMethod + # $TEST$ references declaredPreviouslyAsStaticMethod MyClass().»declaredPreviouslyAsStaticMethod«; - // $TEST$ references myInstanceAttribute + # $TEST$ references myInstanceAttribute nullableMyClass().»myInstanceAttribute«; - // $TEST$ references myInstanceAttribute + # $TEST$ references myInstanceAttribute nullableMyClass()?.»myInstanceAttribute«; - // $TEST$ unresolved + # $TEST$ unresolved MyClass.»myInstanceAttribute«; - // $TEST$ unresolved + # $TEST$ unresolved AnotherClass().»myInstanceAttribute«; - // $TEST$ unresolved + # $TEST$ unresolved unresolved.»myInstanceAttribute«; - // $TEST$ unresolved + # $TEST$ unresolved MyClass.»unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/instance methods/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/instance methods/main.sdstest index 109f228e..94ee9c29 100644 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/instance methods/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/instance methods/main.sdstest @@ -1,48 +1,48 @@ package tests.scoping.memberAccesses.toClassMembers.instanceMethods class MyClass { - // $TEST$ target myInstanceMethod + # $TEST$ target myInstanceMethod fun »myInstanceMethod«() - // $TEST$ target redeclaredAsInstanceAttribute + # $TEST$ target redeclaredAsInstanceAttribute fun »redeclaredAsInstanceAttribute«() attr redeclaredAsInstanceAttribute: Int - // $TEST$ target redeclaredAsStaticAttribute + # $TEST$ target redeclaredAsStaticAttribute fun »redeclaredAsStaticAttribute«() static attr redeclaredAsStaticAttribute: Int - // $TEST$ target redeclaredAsNestedClass + # $TEST$ target redeclaredAsNestedClass fun »redeclaredAsNestedClass«() class redeclaredAsNestedClass - // $TEST$ target redeclaredAsNestedEnum + # $TEST$ target redeclaredAsNestedEnum fun »redeclaredAsNestedEnum«() enum redeclaredAsNestedEnum - // $TEST$ target redeclaredAsInstanceMethod + # $TEST$ target redeclaredAsInstanceMethod fun »redeclaredAsInstanceMethod«() fun redeclaredAsInstanceMethod() - // $TEST$ target redeclaredAsStaticMethod + # $TEST$ target redeclaredAsStaticMethod fun »redeclaredAsStaticMethod«() static fun redeclaredAsStaticMethod() - // $TEST$ target declaredPreviouslyAsStaticAttribute + # $TEST$ target declaredPreviouslyAsStaticAttribute static attr declaredPreviouslyAsStaticAttribute: Int fun »declaredPreviouslyAsStaticAttribute«() - // $TEST$ target declaredPreviouslyAsNestedClass + # $TEST$ target declaredPreviouslyAsNestedClass class declaredPreviouslyAsNestedClass fun »declaredPreviouslyAsNestedClass«() - // $TEST$ target declaredPreviouslyAsNestedEnum + # $TEST$ target declaredPreviouslyAsNestedEnum class declaredPreviouslyAsNestedEnum fun »declaredPreviouslyAsNestedEnum«() - // $TEST$ target declaredPreviouslyAsStaticMethod + # $TEST$ target declaredPreviouslyAsStaticMethod static fun declaredPreviouslyAsStaticMethod() fun »declaredPreviouslyAsStaticMethod«() } @@ -52,57 +52,57 @@ class AnotherClass fun nullableMyClass() -> result: MyClass? pipeline myPipeline { - // $TEST$ references myInstanceMethod + # $TEST$ references myInstanceMethod val myClass = MyClass(); myClass.»myInstanceMethod«(); - // $TEST$ references redeclaredAsInstanceAttribute + # $TEST$ references redeclaredAsInstanceAttribute MyClass().»redeclaredAsInstanceAttribute«(); - // $TEST$ references redeclaredAsStaticAttribute + # $TEST$ references redeclaredAsStaticAttribute MyClass().»redeclaredAsStaticAttribute«(); - // $TEST$ references redeclaredAsNestedClass + # $TEST$ references redeclaredAsNestedClass MyClass().»redeclaredAsNestedClass«(); - // $TEST$ references redeclaredAsNestedEnum + # $TEST$ references redeclaredAsNestedEnum MyClass().»redeclaredAsNestedEnum«(); - // $TEST$ references redeclaredAsInstanceMethod + # $TEST$ references redeclaredAsInstanceMethod MyClass().»redeclaredAsInstanceMethod«(); - // $TEST$ references redeclaredAsStaticMethod + # $TEST$ references redeclaredAsStaticMethod MyClass().»redeclaredAsStaticMethod«(); - // $TEST$ references declaredPreviouslyAsStaticAttribute + # $TEST$ references declaredPreviouslyAsStaticAttribute MyClass().»declaredPreviouslyAsStaticAttribute«(); - // $TEST$ references declaredPreviouslyAsNestedClass + # $TEST$ references declaredPreviouslyAsNestedClass MyClass().»declaredPreviouslyAsNestedClass«(); - // $TEST$ references declaredPreviouslyAsNestedEnum + # $TEST$ references declaredPreviouslyAsNestedEnum MyClass().»declaredPreviouslyAsNestedEnum«(); - // $TEST$ references declaredPreviouslyAsStaticMethod + # $TEST$ references declaredPreviouslyAsStaticMethod MyClass().»declaredPreviouslyAsStaticMethod«(); - // $TEST$ references myInstanceMethod + # $TEST$ references myInstanceMethod nullableMyClass().»myInstanceMethod«; - // $TEST$ references myInstanceMethod + # $TEST$ references myInstanceMethod nullableMyClass()?.»myInstanceMethod«(); - // $TEST$ unresolved + # $TEST$ unresolved MyClass.»myInstanceMethod«; - // $TEST$ unresolved + # $TEST$ unresolved AnotherClass().»myInstanceMethod«; - // $TEST$ unresolved + # $TEST$ unresolved unresolved.»myInstanceMethod«; - // $TEST$ unresolved + # $TEST$ unresolved MyClass.»unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/nested classes/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/nested classes/main.sdstest index deba1851..6b955ad9 100644 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/nested classes/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/nested classes/main.sdstest @@ -1,40 +1,40 @@ package tests.scoping.memberAccesses.toClassMembers.nestedClasses class MyClass { - // $TEST$ target myNestedClass + # $TEST$ target myNestedClass class »MyNestedClass« - // $TEST$ target redeclaredAsInstanceAttribute + # $TEST$ target redeclaredAsInstanceAttribute class »RedeclaredAsInstanceAttribute« attr RedeclaredAsInstanceAttribute: Int - // $TEST$ target redeclaredAsStaticAttribute + # $TEST$ target redeclaredAsStaticAttribute class »RedeclaredAsStaticAttribute« static attr RedeclaredAsStaticAttribute: Int - // $TEST$ target redeclaredAsNestedClass + # $TEST$ target redeclaredAsNestedClass class »RedeclaredAsNestedClass« class RedeclaredAsNestedClass - // $TEST$ target redeclaredAsNestedEnum + # $TEST$ target redeclaredAsNestedEnum class »RedeclaredAsNestedEnum« enum RedeclaredAsNestedEnum - // $TEST$ target redeclaredAsInstanceMethod + # $TEST$ target redeclaredAsInstanceMethod class »RedeclaredAsInstanceMethod« fun RedeclaredAsInstanceMethod() - // $TEST$ target redeclaredAsStaticMethod + # $TEST$ target redeclaredAsStaticMethod class »RedeclaredAsStaticMethod« static fun RedeclaredAsStaticMethod() - // $TEST$ target declaredPreviouslyAsInstanceAttribute + # $TEST$ target declaredPreviouslyAsInstanceAttribute attr DeclaredPreviouslyAsInstanceAttribute: Int class »DeclaredPreviouslyAsInstanceAttribute« - // $TEST$ target declaredPreviouslyAsInstanceMethod + # $TEST$ target declaredPreviouslyAsInstanceMethod fun DeclaredPreviouslyAsInstanceMethod() class »DeclaredPreviouslyAsInstanceMethod« } @@ -43,47 +43,47 @@ class MyNestedClass class AnotherClass pipeline myPipeline { - // $TEST$ references myNestedClass + # $TEST$ references myNestedClass MyClass.»MyNestedClass«; - // $TEST$ references redeclaredAsInstanceAttribute + # $TEST$ references redeclaredAsInstanceAttribute MyClass.»RedeclaredAsInstanceAttribute«; - // $TEST$ references redeclaredAsStaticAttribute + # $TEST$ references redeclaredAsStaticAttribute MyClass.»RedeclaredAsStaticAttribute«; - // $TEST$ references redeclaredAsNestedClass + # $TEST$ references redeclaredAsNestedClass MyClass.»RedeclaredAsNestedClass«; - // $TEST$ references redeclaredAsNestedEnum + # $TEST$ references redeclaredAsNestedEnum MyClass.»RedeclaredAsNestedEnum«; - // $TEST$ references redeclaredAsInstanceMethod + # $TEST$ references redeclaredAsInstanceMethod MyClass.»RedeclaredAsInstanceMethod«; - // $TEST$ references redeclaredAsStaticMethod + # $TEST$ references redeclaredAsStaticMethod MyClass.»RedeclaredAsStaticMethod«; - // $TEST$ references declaredPreviouslyAsInstanceAttribute + # $TEST$ references declaredPreviouslyAsInstanceAttribute MyClass.»DeclaredPreviouslyAsInstanceAttribute«; - // $TEST$ references declaredPreviouslyAsInstanceMethod + # $TEST$ references declaredPreviouslyAsInstanceMethod MyClass.»DeclaredPreviouslyAsInstanceMethod«; - // $TEST$ unresolved + # $TEST$ unresolved MyClass().»MyNestedClass«; - // $TEST$ unresolved + # $TEST$ unresolved MyClass.»AnotherClass«; - // $TEST$ unresolved + # $TEST$ unresolved AnotherClass.»MyNestedClass«; - // $TEST$ unresolved + # $TEST$ unresolved unresolved.»MyNestedClass«; - // $TEST$ unresolved + # $TEST$ unresolved MyClass.»unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/nested enums/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/nested enums/main.sdstest index 8829f39c..09b24d12 100644 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/nested enums/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/nested enums/main.sdstest @@ -1,40 +1,40 @@ package tests.scoping.memberAccesses.toClassMembers.nestedEnums class MyClass { - // $TEST$ target myNestedEnum + # $TEST$ target myNestedEnum enum »MyNestedEnum« - // $TEST$ target redeclaredAsInstanceAttribute + # $TEST$ target redeclaredAsInstanceAttribute enum »RedeclaredAsInstanceAttribute« attr RedeclaredAsInstanceAttribute: Int - // $TEST$ target redeclaredAsStaticAttribute + # $TEST$ target redeclaredAsStaticAttribute enum »RedeclaredAsStaticAttribute« static attr RedeclaredAsStaticAttribute: Int - // $TEST$ target redeclaredAsNestedClass + # $TEST$ target redeclaredAsNestedClass enum »RedeclaredAsNestedClass« class RedeclaredAsNestedClass - // $TEST$ target redeclaredAsNestedEnum + # $TEST$ target redeclaredAsNestedEnum enum »RedeclaredAsNestedEnum« enum RedeclaredAsNestedEnum - // $TEST$ target redeclaredAsInstanceMethod + # $TEST$ target redeclaredAsInstanceMethod enum »RedeclaredAsInstanceMethod« fun RedeclaredAsInstanceMethod() - // $TEST$ target redeclaredAsStaticMethod + # $TEST$ target redeclaredAsStaticMethod enum »RedeclaredAsStaticMethod« static fun RedeclaredAsStaticMethod() - // $TEST$ target declaredPreviouslyAsInstanceAttribute + # $TEST$ target declaredPreviouslyAsInstanceAttribute attr DeclaredPreviouslyAsInstanceAttribute: Int enum »DeclaredPreviouslyAsInstanceAttribute« - // $TEST$ target declaredPreviouslyAsInstanceMethod + # $TEST$ target declaredPreviouslyAsInstanceMethod fun DeclaredPreviouslyAsInstanceMethod() enum »DeclaredPreviouslyAsInstanceMethod« } @@ -44,47 +44,47 @@ class AnotherClass enum AnotherEnum pipeline myPipeline { - // $TEST$ references myNestedEnum + # $TEST$ references myNestedEnum MyClass.»MyNestedEnum«; - // $TEST$ references redeclaredAsInstanceAttribute + # $TEST$ references redeclaredAsInstanceAttribute MyClass.»RedeclaredAsInstanceAttribute«; - // $TEST$ references redeclaredAsStaticAttribute + # $TEST$ references redeclaredAsStaticAttribute MyClass.»RedeclaredAsStaticAttribute«; - // $TEST$ references redeclaredAsNestedClass + # $TEST$ references redeclaredAsNestedClass MyClass.»RedeclaredAsNestedClass«; - // $TEST$ references redeclaredAsNestedEnum + # $TEST$ references redeclaredAsNestedEnum MyClass.»RedeclaredAsNestedEnum«; - // $TEST$ references redeclaredAsInstanceMethod + # $TEST$ references redeclaredAsInstanceMethod MyClass.»RedeclaredAsInstanceMethod«; - // $TEST$ references redeclaredAsStaticMethod + # $TEST$ references redeclaredAsStaticMethod MyClass.»RedeclaredAsStaticMethod«; - // $TEST$ references declaredPreviouslyAsInstanceAttribute + # $TEST$ references declaredPreviouslyAsInstanceAttribute MyClass.»DeclaredPreviouslyAsInstanceAttribute«; - // $TEST$ references declaredPreviouslyAsInstanceMethod + # $TEST$ references declaredPreviouslyAsInstanceMethod MyClass.»DeclaredPreviouslyAsInstanceMethod«; - // $TEST$ unresolved + # $TEST$ unresolved MyClass().»MyNestedEnum«; - // $TEST$ unresolved + # $TEST$ unresolved MyClass.»AnotherEnum«; - // $TEST$ unresolved + # $TEST$ unresolved AnotherClass.»MyNestedEnum«; - // $TEST$ unresolved + # $TEST$ unresolved unresolved.»MyNestedEnum«; - // $TEST$ unresolved + # $TEST$ unresolved MyClass.»unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/overriding/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/overriding/main.sdstest index 67073732..eab702f7 100644 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/overriding/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/overriding/main.sdstest @@ -1,25 +1,25 @@ package tests.scoping.memberAccesses.toClassMembers.overriding class MySuperClass { - // $TEST$ target MySuperClass_myInstanceAttribute + # $TEST$ target MySuperClass_myInstanceAttribute attr »myInstanceAttribute«: Int - // $TEST$ target MySuperClass_myInstanceMethod + # $TEST$ target MySuperClass_myInstanceMethod fun »myInstanceMethod1«() } class MyClass() sub MySuperClass { - // $TEST$ target MyClass_myInstanceAttribute + # $TEST$ target MyClass_myInstanceAttribute attr »myInstanceAttribute«: Int - // $TEST$ target MyClass_myInstanceMethod + # $TEST$ target MyClass_myInstanceMethod fun »myInstanceMethod1«() } pipeline myPipeline { - // $TEST$ references MyClass_myInstanceAttribute + # $TEST$ references MyClass_myInstanceAttribute MyClass().»myInstanceAttribute«; - // $TEST$ references MyClass_myInstanceMethod + # $TEST$ references MyClass_myInstanceMethod MyClass().»myInstanceMethod1«(); } diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/static attributes/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/static attributes/main.sdstest index 0c9d77c5..1065e3a4 100644 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/static attributes/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/static attributes/main.sdstest @@ -1,40 +1,40 @@ package tests.scoping.memberAccesses.toClassMembers.staticAttributes class MyClass() { - // $TEST$ target myStaticAttribute + # $TEST$ target myStaticAttribute static attr »myStaticAttribute«: Int - // $TEST$ target redeclaredAsInstanceAttribute + # $TEST$ target redeclaredAsInstanceAttribute static attr »redeclaredAsInstanceAttribute«: Int attr redeclaredAsInstanceAttribute: Int - // $TEST$ target redeclaredAsStaticAttribute + # $TEST$ target redeclaredAsStaticAttribute static attr »redeclaredAsStaticAttribute«: Int static attr redeclaredAsStaticAttribute: Int - // $TEST$ target redeclaredAsNestedClass + # $TEST$ target redeclaredAsNestedClass static attr »redeclaredAsNestedClass«: Int class redeclaredAsNestedClass - // $TEST$ target redeclaredAsNestedEnum + # $TEST$ target redeclaredAsNestedEnum static attr »redeclaredAsNestedEnum«: Int enum redeclaredAsNestedEnum - // $TEST$ target redeclaredAsInstanceMethod + # $TEST$ target redeclaredAsInstanceMethod static attr »redeclaredAsInstanceMethod«: Int fun redeclaredAsInstanceMethod() - // $TEST$ target redeclaredAsStaticMethod + # $TEST$ target redeclaredAsStaticMethod static attr »redeclaredAsStaticMethod«: Int static fun redeclaredAsStaticMethod() - // $TEST$ target declaredPreviouslyAsInstanceAttribute + # $TEST$ target declaredPreviouslyAsInstanceAttribute attr declaredPreviouslyAsInstanceAttribute: Int static attr »declaredPreviouslyAsInstanceAttribute«: Int - // $TEST$ target declaredPreviouslyAsInstanceMethod + # $TEST$ target declaredPreviouslyAsInstanceMethod fun declaredPreviouslyAsInstanceMethod() static attr »declaredPreviouslyAsInstanceMethod«: Int } @@ -42,44 +42,44 @@ class MyClass() { class AnotherClass pipeline myPipeline { - // $TEST$ references myStaticAttribute + # $TEST$ references myStaticAttribute MyClass.»myStaticAttribute«; - // $TEST$ references redeclaredAsInstanceAttribute + # $TEST$ references redeclaredAsInstanceAttribute MyClass.»redeclaredAsInstanceAttribute«; - // $TEST$ references redeclaredAsStaticAttribute + # $TEST$ references redeclaredAsStaticAttribute MyClass.»redeclaredAsStaticAttribute«; - // $TEST$ references redeclaredAsNestedClass + # $TEST$ references redeclaredAsNestedClass MyClass.»redeclaredAsNestedClass«; - // $TEST$ references redeclaredAsNestedEnum + # $TEST$ references redeclaredAsNestedEnum MyClass.»redeclaredAsNestedEnum«; - // $TEST$ references redeclaredAsInstanceMethod + # $TEST$ references redeclaredAsInstanceMethod MyClass.»redeclaredAsInstanceMethod«; - // $TEST$ references redeclaredAsStaticMethod + # $TEST$ references redeclaredAsStaticMethod MyClass.»redeclaredAsStaticMethod«; - // $TEST$ references declaredPreviouslyAsInstanceAttribute + # $TEST$ references declaredPreviouslyAsInstanceAttribute MyClass.»declaredPreviouslyAsInstanceAttribute«; - // $TEST$ references declaredPreviouslyAsInstanceMethod + # $TEST$ references declaredPreviouslyAsInstanceMethod MyClass.»declaredPreviouslyAsInstanceMethod«; - // $TEST$ unresolved + # $TEST$ unresolved MyClass().»myStaticAttribute«; - // $TEST$ unresolved + # $TEST$ unresolved AnotherClass.»myStaticAttribute«; - // $TEST$ unresolved + # $TEST$ unresolved unresolved.»myStaticAttribute«; - // $TEST$ unresolved + # $TEST$ unresolved MyClass.»unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/static methods/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/static methods/main.sdstest index 7467d7dc..0388e103 100644 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/static methods/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/static methods/main.sdstest @@ -1,40 +1,40 @@ package tests.scoping.memberAccesses.toClassMembers.staticMethods class MyClass { - // $TEST$ target myStaticMethod + # $TEST$ target myStaticMethod static fun »myStaticMethod«() - // $TEST$ target redeclaredAsInstanceAttribute + # $TEST$ target redeclaredAsInstanceAttribute static fun »redeclaredAsInstanceAttribute«() attr redeclaredAsInstanceAttribute: Int - // $TEST$ target redeclaredAsStaticAttribute + # $TEST$ target redeclaredAsStaticAttribute static fun »redeclaredAsStaticAttribute«() static attr redeclaredAsStaticAttribute: Int - // $TEST$ target redeclaredAsNestedClass + # $TEST$ target redeclaredAsNestedClass static fun »redeclaredAsNestedClass«() class redeclaredAsNestedClass - // $TEST$ target redeclaredAsNestedEnum + # $TEST$ target redeclaredAsNestedEnum static fun »redeclaredAsNestedEnum«() enum redeclaredAsNestedEnum - // $TEST$ target redeclaredAsInstanceMethod + # $TEST$ target redeclaredAsInstanceMethod static fun »redeclaredAsInstanceMethod«() fun redeclaredAsInstanceMethod() - // $TEST$ target redeclaredAsStaticMethod + # $TEST$ target redeclaredAsStaticMethod static fun »redeclaredAsStaticMethod«() static fun redeclaredAsStaticMethod() - // $TEST$ target declaredPreviouslyAsInstanceAttribute + # $TEST$ target declaredPreviouslyAsInstanceAttribute attr declaredPreviouslyAsInstanceAttribute: Int static fun »declaredPreviouslyAsInstanceAttribute«() - // $TEST$ target declaredPreviouslyAsInstanceMethod + # $TEST$ target declaredPreviouslyAsInstanceMethod fun declaredPreviouslyAsInstanceMethod() static fun »declaredPreviouslyAsInstanceMethod«() } @@ -43,47 +43,47 @@ class AnotherClass fun anotherFunction() pipeline myPipeline { - // $TEST$ references myStaticMethod + # $TEST$ references myStaticMethod MyClass.»myStaticMethod«; - // $TEST$ references redeclaredAsInstanceAttribute + # $TEST$ references redeclaredAsInstanceAttribute MyClass.»redeclaredAsInstanceAttribute«; - // $TEST$ references redeclaredAsStaticAttribute + # $TEST$ references redeclaredAsStaticAttribute MyClass.»redeclaredAsStaticAttribute«; - // $TEST$ references redeclaredAsNestedClass + # $TEST$ references redeclaredAsNestedClass MyClass.»redeclaredAsNestedClass«; - // $TEST$ references redeclaredAsNestedEnum + # $TEST$ references redeclaredAsNestedEnum MyClass.»redeclaredAsNestedEnum«; - // $TEST$ references redeclaredAsInstanceMethod + # $TEST$ references redeclaredAsInstanceMethod MyClass.»redeclaredAsInstanceMethod«; - // $TEST$ references redeclaredAsStaticMethod + # $TEST$ references redeclaredAsStaticMethod MyClass.»redeclaredAsStaticMethod«; - // $TEST$ references declaredPreviouslyAsInstanceAttribute + # $TEST$ references declaredPreviouslyAsInstanceAttribute MyClass.»declaredPreviouslyAsInstanceAttribute«; - // $TEST$ references declaredPreviouslyAsInstanceMethod + # $TEST$ references declaredPreviouslyAsInstanceMethod MyClass.»declaredPreviouslyAsInstanceMethod«; - // $TEST$ unresolved + # $TEST$ unresolved MyClass().»myStaticMethod«; - // $TEST$ unresolved + # $TEST$ unresolved MyClass.»anotherFunction«; - // $TEST$ unresolved + # $TEST$ unresolved AnotherClass.»myStaticMethod«; - // $TEST$ unresolved + # $TEST$ unresolved unresolved.»myStaticMethod«; - // $TEST$ unresolved + # $TEST$ unresolved MyClass.»unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to enum variants/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to enum variants/main.sdstest index 3f913c06..e5956c84 100644 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to enum variants/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/member accesses/to enum variants/main.sdstest @@ -1,10 +1,10 @@ package tests.scoping.memberAccesses.toEnumVariants enum MyEnum { - // $TEST$ target myEnumVariant + # $TEST$ target myEnumVariant »MyEnumVariant« - // $TEST$ target redeclaredEnumVariant + # $TEST$ target redeclaredEnumVariant »RedeclaredEnumVariant« RedeclaredEnumVariant } @@ -12,22 +12,22 @@ enum MyEnum { enum AnotherEnum pipeline myPipeline { - // $TEST$ references myEnumVariant + # $TEST$ references myEnumVariant MyEnum.»MyEnumVariant«; - // $TEST$ references redeclaredEnumVariant + # $TEST$ references redeclaredEnumVariant MyEnum.»RedeclaredEnumVariant«; - // $TEST$ unresolved + # $TEST$ unresolved AnotherEnum().»MyEnumVariant«; - // $TEST$ unresolved + # $TEST$ unresolved AnotherEnum.»MyEnumVariant«; - // $TEST$ unresolved + # $TEST$ unresolved unresolved.»MyEnumVariant«; - // $TEST$ unresolved + # $TEST$ unresolved MyEnum.»unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to parameter of enum variants/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to parameter of enum variants/main.sdstest index 2ba689a1..b7acda8a 100644 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to parameter of enum variants/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/member accesses/to parameter of enum variants/main.sdstest @@ -2,10 +2,10 @@ package tests.scoping.memberAccesses.toParametersOfEnumVariants enum MyEnum { MyEnumVariant( - // $TEST$ target param + # $TEST$ target param »param«: Int, - // $TEST$ target redeclared + # $TEST$ target redeclared »redeclared«: Int, redeclared: Int, ) @@ -18,28 +18,28 @@ enum MyOtherEnum { } pipeline myPipeline { - // $TEST$ references param + # $TEST$ references param MyEnum.MyEnumVariant().»param«; - // $TEST$ references redeclared + # $TEST$ references redeclared MyEnum.MyEnumVariant().»redeclared«; - // $TEST$ unresolved + # $TEST$ unresolved MyOtherEnum.MyEnumVariant.»param«; - // $TEST$ unresolved + # $TEST$ unresolved MyEnum.MyOtherEnumVariant().»param«; - // $TEST$ unresolved + # $TEST$ unresolved MyOtherEnum.MyEnumVariant().»param«; - // $TEST$ unresolved + # $TEST$ unresolved MyEnum.MyEnumVariant().»unresolved«; - // $TEST$ unresolved + # $TEST$ unresolved MyEnum.unresolved().»param«; - // $TEST$ unresolved + # $TEST$ unresolved unresolved.MyEnumVariant().»param«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/call with nullable receiver/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/call with nullable receiver/main.sdstest index 85517938..8b07eec6 100644 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/call with nullable receiver/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/call with nullable receiver/main.sdstest @@ -1,33 +1,33 @@ package tests.scoping.memberAccesses.toResults.callWithNullableReceiver class MyClass { - // $TEST$ target functionWithOneResult_singleResult + # $TEST$ target functionWithOneResult_singleResult fun functionWithOneResult() -> »singleResult«: Int - // $TEST$ target functionWithTwoResults_result1 + # $TEST$ target functionWithTwoResults_result1 fun functionWithTwoResults() -> (»result1«: Int, result2: Int) } segment mySegment( myClassOrNull: MyClass? ) { - // $TEST$ references functionWithOneResult_singleResult + # $TEST$ references functionWithOneResult_singleResult myClassOrNull?.functionWithOneResult().»singleResult«; - // $TEST$ references functionWithTwoResults_result1 + # $TEST$ references functionWithTwoResults_result1 myClassOrNull?.functionWithTwoResults().»result1«; - // $TEST$ references functionWithOneResult_singleResult + # $TEST$ references functionWithOneResult_singleResult myClassOrNull?.functionWithOneResult?().»singleResult«; - // $TEST$ references functionWithTwoResults_result1 + # $TEST$ references functionWithTwoResults_result1 myClassOrNull?.functionWithTwoResults?().»result1«; - // $TEST$ references functionWithOneResult_singleResult + # $TEST$ references functionWithOneResult_singleResult myClassOrNull?.functionWithOneResult?()?.»singleResult«; - // $TEST$ references functionWithTwoResults_result1 + # $TEST$ references functionWithTwoResults_result1 myClassOrNull?.functionWithTwoResults?()?.»result1«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of block lambdas (matching member)/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of block lambdas (matching member)/main.sdstest index b197f34b..2c8dda49 100644 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of block lambdas (matching member)/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of block lambdas (matching member)/main.sdstest @@ -1,12 +1,12 @@ package tests.scoping.memberAccesses.toResults.ofBlockLambdas.matchingMember class MyClass() { - // $TEST$ target MyClass_result + # $TEST$ target MyClass_result attr »result«: Int } enum MyEnum { - // $TEST$ target MyEnum_result + # $TEST$ target MyEnum_result MyEnumVariant(»result«: Int) } @@ -19,9 +19,9 @@ pipeline myPipeline { yield result = MyEnum.MyEnumVariant(0); }; - // $TEST$ references MyClass_result + # $TEST$ references MyClass_result f1().»result«; - // $TEST$ references MyEnum_result + # $TEST$ references MyEnum_result f2().»result«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of block lambdas/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of block lambdas/main.sdstest index 208ee9b3..ffe311a9 100644 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of block lambdas/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of block lambdas/main.sdstest @@ -2,19 +2,19 @@ package tests.scoping.memberAccesses.toResults.ofBlockLambdas pipeline myPipeline { val lambdaWithOneResult = () { - // $TEST$ target lambdaWithOneResult_singleResult + # $TEST$ target lambdaWithOneResult_singleResult yield »singleResult« = 1; }; val lambdaWithTwoResults = () { - // $TEST$ target lambdaWithTwoResults_result1 + # $TEST$ target lambdaWithTwoResults_result1 yield »result1« = 1; yield result1 = 1; yield result2 = 1; }; - // $TEST$ references lambdaWithOneResult_singleResult + # $TEST$ references lambdaWithOneResult_singleResult lambdaWithOneResult().»singleResult«; - // $TEST$ references lambdaWithTwoResults_result1 + # $TEST$ references lambdaWithTwoResults_result1 lambdaWithTwoResults().»result1«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of callable types (matching member)/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of callable types (matching member)/main.sdstest index a7cc1c82..559e905d 100644 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of callable types (matching member)/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of callable types (matching member)/main.sdstest @@ -1,12 +1,12 @@ package tests.scoping.memberAccesses.toResults.ofCallableTypes.matchingMember class MyClass() { - // $TEST$ target MyClass_result + # $TEST$ target MyClass_result attr »result«: Int } enum MyEnum { - // $TEST$ target MyEnum_result + # $TEST$ target MyEnum_result MyEnumVariant(»result«: Int) } @@ -15,9 +15,9 @@ segment mySegment( f2: () -> result: MyEnum.MyEnumVariant, ) { - // $TEST$ references MyClass_result + # $TEST$ references MyClass_result f1().»result«; - // $TEST$ references MyEnum_result + # $TEST$ references MyEnum_result f2().»result«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of callable types/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of callable types/main.sdstest index 1e4d3c66..63220e69 100644 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of callable types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of callable types/main.sdstest @@ -1,15 +1,15 @@ package tests.scoping.memberAccesses.toResults.ofCallableTypes segment mySegment( - // $TEST$ target callableWithOneResult_singleResult + # $TEST$ target callableWithOneResult_singleResult callableWithOneResult: () -> »singleResult«: Int, - // $TEST$ target callableWithTwoResults_result1 + # $TEST$ target callableWithTwoResults_result1 callableWithTwoResults: () -> (»result1«: Int, result2: Int), ) { - // $TEST$ references callableWithOneResult_singleResult + # $TEST$ references callableWithOneResult_singleResult callableWithOneResult().»singleResult«; - // $TEST$ references callableWithTwoResults_result1 + # $TEST$ references callableWithTwoResults_result1 callableWithTwoResults().»result1«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of functions (matching member)/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of functions (matching member)/main.sdstest index 263e0eec..59dad608 100644 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of functions (matching member)/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of functions (matching member)/main.sdstest @@ -1,12 +1,12 @@ package tests.scoping.memberAccesses.toResults.ofFunctions.matchingMember class MyClass() { - // $TEST$ target MyClass_result + # $TEST$ target MyClass_result attr »result«: Int } enum MyEnum { - // $TEST$ target MyEnum_result + # $TEST$ target MyEnum_result MyEnumVariant(»result«: Int) } @@ -14,9 +14,9 @@ fun f1() -> result: MyClass fun f2() -> result: MyEnum.MyEnumVariant pipeline myPipeline { - // $TEST$ references MyClass_result + # $TEST$ references MyClass_result f1().»result«; - // $TEST$ references MyEnum_result + # $TEST$ references MyEnum_result f2().»result«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of functions/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of functions/main.sdstest index eeba6f3f..ec56084d 100644 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of functions/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of functions/main.sdstest @@ -1,15 +1,15 @@ package tests.scoping.memberAccesses.toResults.ofFunctions -// $TEST$ target functionWithOneResult_singleResult +# $TEST$ target functionWithOneResult_singleResult fun functionWithOneResult() -> »singleResult«: Int -// $TEST$ target functionWithTwoResults_result1 +# $TEST$ target functionWithTwoResults_result1 fun functionWithTwoResults() -> (»result1«: Int, result2: Int) pipeline myPipeline { - // $TEST$ references functionWithOneResult_singleResult + # $TEST$ references functionWithOneResult_singleResult functionWithOneResult().»singleResult«; - // $TEST$ references functionWithTwoResults_result1 + # $TEST$ references functionWithTwoResults_result1 functionWithTwoResults().»result1«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of segments (matching member)/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of segments (matching member)/main.sdstest index 79463aae..ac4de705 100644 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of segments (matching member)/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of segments (matching member)/main.sdstest @@ -1,12 +1,12 @@ package tests.scoping.memberAccesses.toResults.ofSegments.matchingMember class MyClass() { - // $TEST$ target MyClass_result + # $TEST$ target MyClass_result attr »result«: Int } enum MyEnum { - // $TEST$ target MyEnum_result + # $TEST$ target MyEnum_result MyEnumVariant(»result«: Int) } @@ -14,9 +14,9 @@ segment s1() -> result: MyClass {} segment s2() -> result: MyEnum.MyEnumVariant {} pipeline myPipeline { - // $TEST$ references MyClass_result + # $TEST$ references MyClass_result s1().»result«; - // $TEST$ references MyEnum_result + # $TEST$ references MyEnum_result s2().»result«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of segments/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of segments/main.sdstest index ca1dbcaa..05dbec12 100644 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of segments/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of segments/main.sdstest @@ -1,15 +1,15 @@ package tests.scoping.memberAccesses.toResults.ofSegments -// $TEST$ target segmentWithOneResult_singleResult +# $TEST$ target segmentWithOneResult_singleResult segment segmentWithOneResult() -> »singleResult«: Int {} -// $TEST$ target segmentWithTwoResults_result1 +# $TEST$ target segmentWithTwoResults_result1 segment segmentWithTwoResults() -> (»result1«: Int, result2: Int) {} pipeline myPipeline { - // $TEST$ references segmentWithOneResult_singleResult + # $TEST$ references segmentWithOneResult_singleResult segmentWithOneResult().»singleResult«; - // $TEST$ references segmentWithTwoResults_result1 + # $TEST$ references segmentWithTwoResults_result1 segmentWithTwoResults().»result1«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main no imports or own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main no imports or own declarations.sdstest index 83bf6e2d..0bb2fb47 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main no imports or own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main no imports or own declarations.sdstest @@ -1,18 +1,18 @@ package tests.scoping.namedTypes.acrossFiles.toGlobalClasses segment mySegment( - // $TEST$ references same_MyClass + # $TEST$ references same_MyClass p1: »MyClass«, - // $TEST$ references same_ClassInSamePackage + # $TEST$ references same_ClassInSamePackage p2: »ClassInSamePackage«, - // $TEST$ references safeds_ClassInSafeDsPackage + # $TEST$ references safeds_ClassInSafeDsPackage p3: »ClassInSafeDsPackage«, - // $TEST$ unresolved + # $TEST$ unresolved p4: »ClassInAnotherPackage«, - // $TEST$ unresolved + # $TEST$ unresolved p5: »ClassWithoutPackage«, ) {} diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with imports and own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with imports and own declarations.sdstest index 86ba33e0..52085076 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with imports and own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with imports and own declarations.sdstest @@ -3,25 +3,25 @@ package tests.scoping.namedTypes.acrossFiles.toGlobalClasses from safeds.scoping.namedTypes.acrossFiles.toGlobalClasses import MyClass as MyOwnClass from tests.scoping.namedTypes.acrossFiles.toGlobalClasses.other import ClassInAnotherPackage, Class2InAnotherPackage -// $TEST$ target own_MyOwnClass +# $TEST$ target own_MyOwnClass class »MyOwnClass« segment mySegment( - // $TEST$ references own_MyOwnClass + # $TEST$ references own_MyOwnClass p1: »MyOwnClass«, - // $TEST$ references same_ClassInSamePackage + # $TEST$ references same_ClassInSamePackage p2: »ClassInSamePackage«, - // $TEST$ references safeds_ClassInSafeDsPackage + # $TEST$ references safeds_ClassInSafeDsPackage p3: »ClassInSafeDsPackage«, - // $TEST$ references other_ClassInAnotherPackage + # $TEST$ references other_ClassInAnotherPackage p4: »ClassInAnotherPackage«, - // $TEST$ references other_Class2InAnotherPackage + # $TEST$ references other_Class2InAnotherPackage p5: »Class2InAnotherPackage«, - // $TEST$ unresolved + # $TEST$ unresolved p6: »ClassWithoutPackage«, ) {} diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with multiple imports of same name.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with multiple imports of same name.sdstest index 2d9adf6d..a1fd1f9e 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with multiple imports of same name.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with multiple imports of same name.sdstest @@ -5,6 +5,6 @@ from tests.scoping.namedTypes.acrossFiles.toGlobalClasses.other import MyClass from tests.scoping.namedTypes.acrossFiles.toGlobalClasses import MyClass segment mySegment( - // $TEST$ references safeds_MyClass + # $TEST$ references safeds_MyClass p: »MyClass«, ) {} diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with qualified import with alias.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with qualified import with alias.sdstest index 476df03c..6f297e29 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with qualified import with alias.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with qualified import with alias.sdstest @@ -5,28 +5,28 @@ from safeds.scoping.namedTypes.acrossFiles.toGlobalClasses import MyClass as MyC from tests.scoping.namedTypes.acrossFiles.toGlobalClasses.other import MyClass as MyClassInAnotherPackage segment mySegment( - // $TEST$ references same_MyClass + # $TEST$ references same_MyClass p1: »MyClass«, - // $TEST$ references same_ClassInSamePackage + # $TEST$ references same_ClassInSamePackage p2: »ClassInSamePackage«, - // $TEST$ references safeds_ClassInSafeDsPackage + # $TEST$ references safeds_ClassInSafeDsPackage p3: »ClassInSafeDsPackage«, - // $TEST$ unresolved + # $TEST$ unresolved p4: »ClassInAnotherPackage«, - // $TEST$ unresolved + # $TEST$ unresolved p5: »ClassWithoutPackage«, - // $TEST$ references same_MyClass + # $TEST$ references same_MyClass p6: »MyClassInSamePackage«, - // $TEST$ references safeds_MyClass + # $TEST$ references safeds_MyClass p7: »MyClassInSafeDsPackage«, - // $TEST$ references other_MyClass + # $TEST$ references other_MyClass p8: »MyClassInAnotherPackage«, ) {} diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with qualified import.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with qualified import.sdstest index c29a526f..92cbabed 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with qualified import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with qualified import.sdstest @@ -4,24 +4,24 @@ from safeds.scoping.namedTypes.acrossFiles.toGlobalClasses import MyClass from tests.scoping.namedTypes.acrossFiles.toGlobalClasses.other import ClassInAnotherPackage, Class2InAnotherPackage, notANamedTypeDeclaration segment mySegment( - // $TEST$ references safeds_MyClass + # $TEST$ references safeds_MyClass p1: »MyClass«, - // $TEST$ references same_ClassInSamePackage + # $TEST$ references same_ClassInSamePackage p2: »ClassInSamePackage«, - // $TEST$ references safeds_ClassInSafeDsPackage + # $TEST$ references safeds_ClassInSafeDsPackage p3: »ClassInSafeDsPackage«, - // $TEST$ references other_ClassInAnotherPackage + # $TEST$ references other_ClassInAnotherPackage p4: »ClassInAnotherPackage«, - // $TEST$ references other_Class2InAnotherPackage + # $TEST$ references other_Class2InAnotherPackage p5: »Class2InAnotherPackage«, - // $TEST$ unresolved + # $TEST$ unresolved p6: »notANamedTypeDeclaration«, - // $TEST$ unresolved + # $TEST$ unresolved p7: »ClassWithoutPackage«, ) {} diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with wildcard import.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with wildcard import.sdstest index c68c481c..161fc17e 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with wildcard import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with wildcard import.sdstest @@ -3,18 +3,18 @@ package tests.scoping.namedTypes.acrossFiles.toGlobalClasses from safeds.scoping.namedTypes.acrossFiles.toGlobalClasses import * segment mySegment( - // $TEST$ references safeds_MyClass + # $TEST$ references safeds_MyClass p1: »MyClass«, - // $TEST$ references same_ClassInSamePackage + # $TEST$ references same_ClassInSamePackage p2: »ClassInSamePackage«, - // $TEST$ references safeds_ClassInSafeDsPackage + # $TEST$ references safeds_ClassInSafeDsPackage p3: »ClassInSafeDsPackage«, - // $TEST$ unresolved + # $TEST$ unresolved p4: »ClassInAnotherPackage«, - // $TEST$ unresolved + # $TEST$ unresolved p5: »ClassWithoutPackage«, ) {} diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/resource other package.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/resource other package.sdstest index 06528eef..ede278c9 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/resource other package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/resource other package.sdstest @@ -1,13 +1,13 @@ package tests.scoping.namedTypes.acrossFiles.toGlobalClasses.other -// $TEST$ target other_MyClass +# $TEST$ target other_MyClass class »MyClass« -// $TEST$ target other_ClassInAnotherPackage +# $TEST$ target other_ClassInAnotherPackage class »ClassInAnotherPackage« -// $TEST$ target other_Class2InAnotherPackage +# $TEST$ target other_Class2InAnotherPackage class »Class2InAnotherPackage« -// $TEST$ target other_notANamedTypeDeclaration +# $TEST$ target other_notANamedTypeDeclaration fun »notANamedTypeDeclaration«() diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/resource safeds package.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/resource safeds package.sdstest index a51a37c2..fe9a62fc 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/resource safeds package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/resource safeds package.sdstest @@ -1,7 +1,7 @@ package safeds.scoping.namedTypes.acrossFiles.toGlobalClasses -// $TEST$ target safeds_MyClass +# $TEST$ target safeds_MyClass class »MyClass« -// $TEST$ target safeds_ClassInSafeDsPackage +# $TEST$ target safeds_ClassInSafeDsPackage class »ClassInSafeDsPackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/resource same package.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/resource same package.sdstest index 742ed65e..eeaf529c 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/resource same package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/resource same package.sdstest @@ -1,7 +1,7 @@ package tests.scoping.namedTypes.acrossFiles.toGlobalClasses -// $TEST$ target same_MyClass +# $TEST$ target same_MyClass class »MyClass« -// $TEST$ target same_ClassInSamePackage +# $TEST$ target same_ClassInSamePackage class »ClassInSamePackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/resource without package.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/resource without package.sdstest index bcd07435..82705a3b 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/resource without package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/resource without package.sdstest @@ -1,5 +1,5 @@ -// $TEST$ target without_MyClass +# $TEST$ target without_MyClass class »MyClass« -// $TEST$ target without_ClassWithoutPackage +# $TEST$ target without_ClassWithoutPackage class »ClassWithoutPackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main no imports or own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main no imports or own declarations.sdstest index 7f0a0cef..e7c60a79 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main no imports or own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main no imports or own declarations.sdstest @@ -1,18 +1,18 @@ package tests.scoping.namedTypes.acrossFiles.toGlobalEnums segment mySegment( - // $TEST$ references same_MyEnum + # $TEST$ references same_MyEnum p1: »MyEnum«, - // $TEST$ references same_EnumInSamePackage + # $TEST$ references same_EnumInSamePackage p2: »EnumInSamePackage«, - // $TEST$ references safeds_EnumInSafeDsPackage + # $TEST$ references safeds_EnumInSafeDsPackage p3: »EnumInSafeDsPackage«, - // $TEST$ unresolved + # $TEST$ unresolved p4: »EnumInAnotherPackage«, - // $TEST$ unresolved + # $TEST$ unresolved p5: »EnumWithoutPackage«, ) {} diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with imports and own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with imports and own declarations.sdstest index e56ba80a..c226dfa2 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with imports and own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with imports and own declarations.sdstest @@ -3,25 +3,25 @@ package tests.scoping.namedTypes.acrossFiles.toGlobalEnums from safeds.scoping.namedTypes.acrossFiles.toGlobalEnums import MyEnum as MyOwnEnum from tests.scoping.namedTypes.acrossFiles.toGlobalEnums.other import EnumInAnotherPackage, Enum2InAnotherPackage -// $TEST$ target own_MyOwnEnum +# $TEST$ target own_MyOwnEnum enum »MyOwnEnum« segment mySegment( - // $TEST$ references own_MyOwnEnum + # $TEST$ references own_MyOwnEnum p1: »MyOwnEnum«, - // $TEST$ references same_EnumInSamePackage + # $TEST$ references same_EnumInSamePackage p2: »EnumInSamePackage«, - // $TEST$ references safeds_EnumInSafeDsPackage + # $TEST$ references safeds_EnumInSafeDsPackage p3: »EnumInSafeDsPackage«, - // $TEST$ references other_EnumInAnotherPackage + # $TEST$ references other_EnumInAnotherPackage p4: »EnumInAnotherPackage«, - // $TEST$ references other_Enum2InAnotherPackage + # $TEST$ references other_Enum2InAnotherPackage p5: »Enum2InAnotherPackage«, - // $TEST$ unresolved + # $TEST$ unresolved p6: »EnumWithoutPackage«, ) {} diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with multiple imports of same name.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with multiple imports of same name.sdstest index b13ad0d2..80a11ede 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with multiple imports of same name.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with multiple imports of same name.sdstest @@ -5,6 +5,6 @@ from tests.scoping.namedTypes.acrossFiles.toGlobalEnums.other import MyEnum from tests.scoping.namedTypes.acrossFiles.toGlobalEnums import MyEnum segment mySegment( - // $TEST$ references safeds_MyEnum + # $TEST$ references safeds_MyEnum p: »MyEnum«, ) {} diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with qualified import with alias.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with qualified import with alias.sdstest index fbd4b754..9de0ca25 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with qualified import with alias.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with qualified import with alias.sdstest @@ -5,29 +5,29 @@ from safeds.scoping.namedTypes.acrossFiles.toGlobalEnums import MyEnum as MyEnum from tests.scoping.namedTypes.acrossFiles.toGlobalEnums.other import MyEnum as MyEnumInAnotherPackage segment mySegment( - // $TEST$ references same_MyEnum + # $TEST$ references same_MyEnum p1: »MyEnum«, - // $TEST$ references same_EnumInSamePackage + # $TEST$ references same_EnumInSamePackage p2: »EnumInSamePackage«, - // $TEST$ references safeds_EnumInSafeDsPackage + # $TEST$ references safeds_EnumInSafeDsPackage p3: »EnumInSafeDsPackage«, - // $TEST$ unresolved + # $TEST$ unresolved p4: »EnumInAnotherPackage«, - // $TEST$ unresolved + # $TEST$ unresolved p5: »EnumWithoutPackage«, - // $TEST$ references same_MyEnum + # $TEST$ references same_MyEnum p6: »MyEnumInSamePackage«, - // $TEST$ references safeds_MyEnum + # $TEST$ references safeds_MyEnum p7: »MyEnumInSafeDsPackage«, - // $TEST$ references other_MyEnum + # $TEST$ references other_MyEnum p8: »MyEnumInAnotherPackage«, ) {} diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with qualified import.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with qualified import.sdstest index 155e02e5..64313d79 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with qualified import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with qualified import.sdstest @@ -4,24 +4,24 @@ from safeds.scoping.namedTypes.acrossFiles.toGlobalEnums import MyEnum from tests.scoping.namedTypes.acrossFiles.toGlobalEnums.other import EnumInAnotherPackage, Enum2InAnotherPackage, notANamedTypeDeclaration segment mySegment( - // $TEST$ references safeds_MyEnum + # $TEST$ references safeds_MyEnum p1: »MyEnum«, - // $TEST$ references same_EnumInSamePackage + # $TEST$ references same_EnumInSamePackage p2: »EnumInSamePackage«, - // $TEST$ references safeds_EnumInSafeDsPackage + # $TEST$ references safeds_EnumInSafeDsPackage p3: »EnumInSafeDsPackage«, - // $TEST$ references other_EnumInAnotherPackage + # $TEST$ references other_EnumInAnotherPackage p4: »EnumInAnotherPackage«, - // $TEST$ references other_Enum2InAnotherPackage + # $TEST$ references other_Enum2InAnotherPackage p5: »Enum2InAnotherPackage«, - // $TEST$ unresolved + # $TEST$ unresolved p6: »notANamedTypeDeclaration«, - // $TEST$ unresolved + # $TEST$ unresolved p7: »EnumWithoutPackage«, ) {} diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with wildcard import.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with wildcard import.sdstest index a3970f20..b1e1c5f1 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with wildcard import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with wildcard import.sdstest @@ -3,18 +3,18 @@ package tests.scoping.namedTypes.acrossFiles.toGlobalEnums from safeds.scoping.namedTypes.acrossFiles.toGlobalEnums import * segment mySegment( - // $TEST$ references safeds_MyEnum + # $TEST$ references safeds_MyEnum p1: »MyEnum«, - // $TEST$ references same_EnumInSamePackage + # $TEST$ references same_EnumInSamePackage p2: »EnumInSamePackage«, - // $TEST$ references safeds_EnumInSafeDsPackage + # $TEST$ references safeds_EnumInSafeDsPackage p3: »EnumInSafeDsPackage«, - // $TEST$ unresolved + # $TEST$ unresolved p4: »EnumInAnotherPackage«, - // $TEST$ unresolved + # $TEST$ unresolved p5: »EnumWithoutPackage«, ) {} diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/resource other package.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/resource other package.sdstest index d5c036c0..63d3323f 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/resource other package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/resource other package.sdstest @@ -1,13 +1,13 @@ package tests.scoping.namedTypes.acrossFiles.toGlobalEnums.other -// $TEST$ target other_MyEnum +# $TEST$ target other_MyEnum enum »MyEnum« -// $TEST$ target other_EnumInAnotherPackage +# $TEST$ target other_EnumInAnotherPackage enum »EnumInAnotherPackage« -// $TEST$ target other_Enum2InAnotherPackage +# $TEST$ target other_Enum2InAnotherPackage enum »Enum2InAnotherPackage« -// $TEST$ target other_notANamedTypeDeclaration +# $TEST$ target other_notANamedTypeDeclaration fun »notANamedTypeDeclaration«() diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/resource safeds package.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/resource safeds package.sdstest index 0c032246..25160a64 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/resource safeds package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/resource safeds package.sdstest @@ -1,7 +1,7 @@ package safeds.scoping.namedTypes.acrossFiles.toGlobalEnums -// $TEST$ target safeds_MyEnum +# $TEST$ target safeds_MyEnum enum »MyEnum« -// $TEST$ target safeds_EnumInSafeDsPackage +# $TEST$ target safeds_EnumInSafeDsPackage enum »EnumInSafeDsPackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/resource same package.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/resource same package.sdstest index c5e7e0f0..952f0a87 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/resource same package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/resource same package.sdstest @@ -1,7 +1,7 @@ package tests.scoping.namedTypes.acrossFiles.toGlobalEnums -// $TEST$ target same_MyEnum +# $TEST$ target same_MyEnum enum »MyEnum« -// $TEST$ target same_EnumInSamePackage +# $TEST$ target same_EnumInSamePackage enum »EnumInSamePackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/resource without package.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/resource without package.sdstest index 7587c7e2..b0052f12 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/resource without package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/resource without package.sdstest @@ -1,5 +1,5 @@ -// $TEST$ target without_MyEnum +# $TEST$ target without_MyEnum enum »MyEnum« -// $TEST$ target without_EnumWithoutPackage +# $TEST$ target without_EnumWithoutPackage enum »EnumWithoutPackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to containing named type declarations/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to containing named type declarations/main.sdstest index 6f334dad..d9b0d992 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to containing named type declarations/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to containing named type declarations/main.sdstest @@ -1,89 +1,89 @@ package tests.scoping.namedTypes.inSameFile.toContainingNamedTypeDeclarations -// $TEST$ target outerClass +# $TEST$ target outerClass class »MyClass«< - // $TEST$ references outerClass + # $TEST$ references outerClass T sub »MyClass« >( - // $TEST$ references outerClass + # $TEST$ references outerClass p: »MyClass« -// $TEST$ references outerClass +# $TEST$ references outerClass ) sub »MyClass« { - // $TEST$ references outerClass + # $TEST$ references outerClass attr a1: »MyClass« - // $TEST$ unresolved + # $TEST$ unresolved attr a2: »MyEnum« fun f< - // $TEST$ references outerClass + # $TEST$ references outerClass T1 sub »MyClass«, - // $TEST$ unresolved + # $TEST$ unresolved T2 sub »MyEnum«, >( - // $TEST$ references outerClass + # $TEST$ references outerClass p1: »MyClass«, - // $TEST$ unresolved + # $TEST$ unresolved p2: »MyEnum« ) -> ( - // $TEST$ references outerClass + # $TEST$ references outerClass r1: »MyClass«, - // $TEST$ unresolved + # $TEST$ unresolved r2: »MyEnum« ) - // $TEST$ target enum + # $TEST$ target enum enum »MyEnum« { - // $TEST$ target variant + # $TEST$ target variant »MyEnumVariant«( - // $TEST$ references outerClass + # $TEST$ references outerClass p1: »MyClass«, - // $TEST$ references enum + # $TEST$ references enum p2: »MyEnum«, - // $TEST$ references variant + # $TEST$ references variant p3: »MyEnumVariant«, ) } - // $TEST$ target innerClass + # $TEST$ target innerClass class »MyClass«( - // $TEST$ references innerClass + # $TEST$ references innerClass p1: »MyClass«, - // $TEST$ unresolved + # $TEST$ unresolved p2: »MyEnum«, - // $TEST$ references innerClass - // $TEST$ unresolved + # $TEST$ references innerClass + # $TEST$ unresolved ) sub »MyClass«, »MyEnum« { - // $TEST$ references innerClass + # $TEST$ references innerClass attr a1: »MyClass« - // $TEST$ unresolved + # $TEST$ unresolved attr a2: »MyEnum« fun f< - // $TEST$ references innerClass + # $TEST$ references innerClass T1 sub »MyClass«, - // $TEST$ unresolved + # $TEST$ unresolved T2 sub »MyEnum«, >( - // $TEST$ references innerClass + # $TEST$ references innerClass p1: »MyClass«, - // $TEST$ unresolved + # $TEST$ unresolved p2: »MyEnum«, ) -> ( - // $TEST$ references innerClass + # $TEST$ references innerClass r1: »MyClass«, - // $TEST$ unresolved + # $TEST$ unresolved r2: »MyEnum«, ) } diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to enum variants in global enums/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to enum variants in global enums/main.sdstest index 47638259..257d200b 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to enum variants in global enums/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to enum variants in global enums/main.sdstest @@ -1,46 +1,46 @@ package tests.scoping.namedTypes.inSameFile.toEnumVariantInGlobalEnums enum BeforeEnum { - // $TEST$ target before + # $TEST$ target before »BeforeVariant« Variant1 - // $TEST$ unresolved + # $TEST$ unresolved Variant2(a: »Variant1«) } class BeforeVariant segment mySegment( - // $TEST$ references before + # $TEST$ references before p1: BeforeEnum.»BeforeVariant«, - // $TEST$ references after + # $TEST$ references after p2: AfterEnum.»AfterVariant«, - // $TEST$ unresolved + # $TEST$ unresolved p3: AfterEnum.»BeforeVariant«, - // $TEST$ unresolved + # $TEST$ unresolved p4: BeforeEnum.»AfterVariant«, - // $TEST$ unresolved + # $TEST$ unresolved p5: BeforeEnum.»Unresolved«, - // $TEST$ unresolved + # $TEST$ unresolved p6: AfterEnum.»Unresolved«, - // $TEST$ unresolved + # $TEST$ unresolved p7: Unresolved.»BeforeVariant«, - // $TEST$ unresolved + # $TEST$ unresolved p8: Unresolved.»AfterVariant«, ) {} class AfterVariant enum AfterEnum { - // $TEST$ target after + # $TEST$ target after »AfterVariant« } diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to enum variants in nested enums/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to enum variants in nested enums/main.sdstest index 26c1e68f..ab8ce73e 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to enum variants in nested enums/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to enum variants in nested enums/main.sdstest @@ -2,12 +2,12 @@ package tests.scoping.namedTypes.inSameFile.toEnumVariantsInNestedEnums class BeforeClass { enum BeforeEnum { - // $TEST$ target before + # $TEST$ target before »BeforeVariant« Variant1 - // $TEST$ unresolved + # $TEST$ unresolved Variant2(a: »Variant1«) } } @@ -17,28 +17,28 @@ enum BeforeEnum { } segment mySegment( - // $TEST$ references before + # $TEST$ references before p1: BeforeClass.BeforeEnum.»BeforeVariant«, - // $TEST$ references after + # $TEST$ references after p2: AfterClass.AfterEnum.»AfterVariant«, - // $TEST$ unresolved + # $TEST$ unresolved p3: AfterClass.AfterEnum.»BeforeVariant«, - // $TEST$ unresolved + # $TEST$ unresolved p4: BeforeClass.BeforeEnum.»AfterVariant«, - // $TEST$ unresolved + # $TEST$ unresolved p5: BeforeClass.BeforeEnum.»Unresolved«, - // $TEST$ unresolved + # $TEST$ unresolved p6: AfterClass.AfterEnum.»Unresolved«, - // $TEST$ unresolved + # $TEST$ unresolved p7: BeforeClass.Unresolved.»BeforeVariant«, - // $TEST$ unresolved + # $TEST$ unresolved p8: AfterClass.Unresolved.»AfterVariant«, ) {} @@ -48,7 +48,7 @@ enum AfterEnum { class AfterClass { enum AfterEnum { - // $TEST$ target after + # $TEST$ target after »AfterVariant« } } diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to global classes/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to global classes/main.sdstest index 412e4c4e..8e1be901 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to global classes/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to global classes/main.sdstest @@ -1,18 +1,18 @@ package tests.scoping.namedTypes.inSameFile.toGlobalClasses -// $TEST$ target before +# $TEST$ target before class »BeforeClass« segment mySegment( - // $TEST$ references before + # $TEST$ references before p1: »BeforeClass«, - // $TEST$ references after + # $TEST$ references after p2: »AfterClass«, - // $TEST$ unresolved + # $TEST$ unresolved p3: »Unresolved«, ) {} -// $TEST$ target after +# $TEST$ target after class »AfterClass« diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to global enums/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to global enums/main.sdstest index dfa877d5..5c15fd09 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to global enums/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to global enums/main.sdstest @@ -1,18 +1,18 @@ package tests.scoping.namedTypes.inSameFile.toGlobalEnums -// $TEST$ target before +# $TEST$ target before enum »BeforeEnum« segment mySegment( - // $TEST$ references before + # $TEST$ references before p1: »BeforeEnum«, - // $TEST$ references after + # $TEST$ references after p2: »AfterEnum«, - // $TEST$ unresolved + # $TEST$ unresolved p3: »Unresolved«, ) {} -// $TEST$ target after +# $TEST$ target after enum »AfterEnum« diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to nested classes/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to nested classes/main.sdstest index 5b92a43c..2a9927dc 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to nested classes/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to nested classes/main.sdstest @@ -1,32 +1,32 @@ package tests.scoping.namedTypes.inSameFile.toNestedClasses class BeforeOuterClass { - // $TEST$ target before + # $TEST$ target before class »BeforeInnerClass« } class BeforeInnerClass segment mySegment( - // $TEST$ references before + # $TEST$ references before p1: BeforeOuterClass.»BeforeInnerClass«, - // $TEST$ references after + # $TEST$ references after p2: AfterOuterClass.»AfterInnerClass«, - // $TEST$ unresolved + # $TEST$ unresolved p3: BeforeOuterClass.»AfterInnerClass«, - // $TEST$ unresolved + # $TEST$ unresolved p4: AfterOuterClass.»BeforeInnerClass«, - // $TEST$ unresolved + # $TEST$ unresolved p5: BeforeOuterClass.»Unresolved«, ) {} class AfterInnerClass class AfterOuterClass { - // $TEST$ target after + # $TEST$ target after class »AfterInnerClass« } diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to nested enums/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to nested enums/main.sdstest index a210c859..ba0e4244 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to nested enums/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to nested enums/main.sdstest @@ -1,32 +1,32 @@ package tests.scoping.namedTypes.inSameFile.toNestedEnums class BeforeClass { - // $TEST$ target before + # $TEST$ target before enum »BeforeEnum« } enum BeforeEnum segment mySegment( - // $TEST$ references before + # $TEST$ references before p1: BeforeClass.»BeforeEnum«, - // $TEST$ references after + # $TEST$ references after p2: AfterClass.»AfterEnum«, - // $TEST$ unresolved + # $TEST$ unresolved p3: BeforeClass.»AfterEnum«, - // $TEST$ unresolved + # $TEST$ unresolved p4: AfterClass.»BeforeEnum«, - // $TEST$ unresolved + # $TEST$ unresolved p5: BeforeClass.»Unresolved«, ) {} enum AfterEnum class AfterClass { - // $TEST$ target after + # $TEST$ target after enum »AfterEnum« } diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to something other than named type declarations/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to something other than named type declarations/main.sdstest index f94e1210..14ecdc30 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to something other than named type declarations/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to something other than named type declarations/main.sdstest @@ -1,6 +1,6 @@ package tests.scoping.namedTypes.inSameFile.toSomethingOtherThanNamedTypeDeclarations -// $TEST$ unresolved +# $TEST$ unresolved segment mySegment(p: »notANamedTypeDeclaration«) {} fun notANamedTypeDeclaration() diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in enum variants in nested enums/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in enum variants in nested enums/main.sdstest index 94290c0c..684ddf4a 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in enum variants in nested enums/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in enum variants in nested enums/main.sdstest @@ -1,21 +1,21 @@ package tests.scoping.namedTypes.inSameFile.toTypeParameter.inEnumVariantsInNestedEnums -// $TEST$ target container +# $TEST$ target container class MyClass<»Container«> { fun myFunction1() enum MyEnum { MyEnumVariant( - // $TEST$ references container + # $TEST$ references container a: »Container«, - // $TEST$ unresolved + # $TEST$ unresolved b: »BeforeEnum«, - // $TEST$ unresolved + # $TEST$ unresolved c: »AfterEnum«, - // $TEST$ unresolved + # $TEST$ unresolved d: »Unresolved«, ) } diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in global classes/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in global classes/main.sdstest index c4dfd05f..ff99c460 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in global classes/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in global classes/main.sdstest @@ -3,50 +3,50 @@ package tests.scoping.namedTypes.inSameFile.toTypeParameter.inGlobalClasses fun myFunction1() class MyClass< - // $TEST$ target own + # $TEST$ target own »Own«, - // $TEST$ references own + # $TEST$ references own T1 sub »Own«, - // $TEST$ unresolved + # $TEST$ unresolved T2 sub »Before«, - // $TEST$ unresolved + # $TEST$ unresolved T3 sub »After«, - // $TEST$ unresolved + # $TEST$ unresolved T4 sub »Unresolved«, - // $TEST$ unresolved + # $TEST$ unresolved T5 sub »Forward«, Forward, >( - // $TEST$ references own + # $TEST$ references own a: »Own«, - // $TEST$ unresolved + # $TEST$ unresolved b: »Before«, - // $TEST$ unresolved + # $TEST$ unresolved c: »After«, - // $TEST$ unresolved + # $TEST$ unresolved d: »Unresolved«, ) -// $TEST$ references own +# $TEST$ references own sub »Own« { - // $TEST$ references own + # $TEST$ references own attr z: »Own« - // $TEST$ unresolved + # $TEST$ unresolved attr y: »Before« - // $TEST$ unresolved + # $TEST$ unresolved attr x: »After« - // $TEST$ unresolved + # $TEST$ unresolved attr w: »Unresolved« } diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in global functions/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in global functions/main.sdstest index b53c3115..c2db8fd3 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in global functions/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in global functions/main.sdstest @@ -3,48 +3,48 @@ package tests.scoping.namedTypes.inSameFile.toTypeParameter.inGlobalFunctions fun myFunction1() fun myFunction2< - // $TEST$ target own + # $TEST$ target own »Own«, - // $TEST$ references own + # $TEST$ references own T1 sub »Own«, - // $TEST$ unresolved + # $TEST$ unresolved T2 sub »Before«, - // $TEST$ unresolved + # $TEST$ unresolved T3 sub »After«, - // $TEST$ unresolved + # $TEST$ unresolved T4 sub »Unresolved«, - // $TEST$ unresolved + # $TEST$ unresolved T5 sub »Forward«, Forward, >( - // $TEST$ references own + # $TEST$ references own a: »Own«, - // $TEST$ unresolved + # $TEST$ unresolved b: »Before«, - // $TEST$ unresolved + # $TEST$ unresolved c: »After«, - // $TEST$ unresolved + # $TEST$ unresolved d: »Unresolved« ) -> ( - // $TEST$ references own + # $TEST$ references own z: »Own«, - // $TEST$ unresolved + # $TEST$ unresolved y: »Before«, - // $TEST$ unresolved + # $TEST$ unresolved x: »After«, - // $TEST$ unresolved + # $TEST$ unresolved w: »Unresolved« ) diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in methods/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in methods/main.sdstest index 47d173c4..1f27c50c 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in methods/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in methods/main.sdstest @@ -2,92 +2,92 @@ package tests.scoping.namedTypes.inSameFile.toTypeParameter.inMethods fun myFunction1() -// $TEST$ target container +# $TEST$ target container class MyClass1<»Container«, Overridden> { fun myFunction2() fun myFunction3< - // $TEST$ target own + # $TEST$ target own »Own«, - // $TEST$ target overridden + # $TEST$ target overridden »Overridden«, - // $TEST$ references own + # $TEST$ references own T1 sub »Own«, - // $TEST$ references overridden + # $TEST$ references overridden T2 sub »Overridden«, - // $TEST$ references container + # $TEST$ references container T3 sub »Container«, - // $TEST$ unresolved + # $TEST$ unresolved T4 sub »BeforeMember«, - // $TEST$ unresolved + # $TEST$ unresolved T5 sub »AfterMember«, - // $TEST$ unresolved + # $TEST$ unresolved T6 sub »BeforeGlobal«, - // $TEST$ unresolved + # $TEST$ unresolved T7 sub »AfterGlobal«, - // $TEST$ unresolved + # $TEST$ unresolved T8 sub »Unresolved«, - // $TEST$ unresolved + # $TEST$ unresolved T9 sub »Forward«, Forward, >( - // $TEST$ references own + # $TEST$ references own a: »Own«, - // $TEST$ references overridden + # $TEST$ references overridden b: »Overridden«, - // $TEST$ references container + # $TEST$ references container c: »Container«, - // $TEST$ unresolved + # $TEST$ unresolved d: »BeforeMember«, - // $TEST$ unresolved + # $TEST$ unresolved e: »AfterMember«, - // $TEST$ unresolved + # $TEST$ unresolved g: »BeforeGlobal«, - // $TEST$ unresolved + # $TEST$ unresolved h: »AfterGlobal«, - // $TEST$ unresolved + # $TEST$ unresolved i: »Unresolved«, ) -> ( - // $TEST$ references own + # $TEST$ references own z: »Own«, - // $TEST$ references overridden + # $TEST$ references overridden y: »Overridden«, - // $TEST$ references container + # $TEST$ references container x: »Container«, - // $TEST$ unresolved + # $TEST$ unresolved w: »BeforeMember«, - // $TEST$ unresolved + # $TEST$ unresolved v: »AfterMember«, - // $TEST$ unresolved + # $TEST$ unresolved u: »BeforeGlobal«, - // $TEST$ unresolved + # $TEST$ unresolved t: »AfterGlobal«, - // $TEST$ unresolved + # $TEST$ unresolved s: »Unresolved«, ) diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in nested classes/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in nested classes/main.sdstest index 16e72565..7f766424 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in nested classes/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in nested classes/main.sdstest @@ -2,97 +2,97 @@ package tests.scoping.namedTypes.inSameFile.toTypeParameter.inNestedClasses fun myFunction1() -// $TEST$ target container +# $TEST$ target container class MyClass1<»Container«, Overridden> { fun myFunction2() class MyClass2< - // $TEST$ target own + # $TEST$ target own »Own«, - // $TEST$ target overridden + # $TEST$ target overridden »Overridden«, - // $TEST$ references own + # $TEST$ references own T1 sub »Own«, - // $TEST$ references overridden + # $TEST$ references overridden T2 sub »Overridden«, - // $TEST$ references container + # $TEST$ references container T3 sub »Container«, - // $TEST$ unresolved + # $TEST$ unresolved T4 sub »BeforeMember«, - // $TEST$ unresolved + # $TEST$ unresolved T5 sub »AfterMember«, - // $TEST$ unresolved + # $TEST$ unresolved T6 sub »BeforeGlobal«, - // $TEST$ unresolved + # $TEST$ unresolved T7 sub »AfterGlobal«, - // $TEST$ unresolved + # $TEST$ unresolved T8 sub »Unresolved«, - // $TEST$ unresolved + # $TEST$ unresolved T9 sub »Forward«, Forward, >( - // $TEST$ references own + # $TEST$ references own a: »Own«, - // $TEST$ references overridden + # $TEST$ references overridden b: »Overridden«, - // $TEST$ references container + # $TEST$ references container c: »Container«, - // $TEST$ unresolved + # $TEST$ unresolved d: »BeforeMember«, - // $TEST$ unresolved + # $TEST$ unresolved e: »AfterMember«, - // $TEST$ unresolved + # $TEST$ unresolved f: »BeforeGlobal«, - // $TEST$ unresolved + # $TEST$ unresolved g: »AfterGlobal«, - // $TEST$ unresolved + # $TEST$ unresolved h: »Unresolved«, ) - // $TEST$ references own - // $TEST$ references overridden - // $TEST$ references container + # $TEST$ references own + # $TEST$ references overridden + # $TEST$ references container sub »Own«, »Overridden«, »Container« { - // $TEST$ references own + # $TEST$ references own attr z: »Own« - // $TEST$ references overridden + # $TEST$ references overridden attr y: »Overridden« - // $TEST$ references container + # $TEST$ references container attr x: »Container« - // $TEST$ unresolved + # $TEST$ unresolved attr w: »BeforeMember« - // $TEST$ unresolved + # $TEST$ unresolved attr v: »AfterMember« - // $TEST$ unresolved + # $TEST$ unresolved attr u: »BeforeGlobal« - // $TEST$ unresolved + # $TEST$ unresolved attr t: »AfterGlobal« - // $TEST$ unresolved + # $TEST$ unresolved attr s: »Unresolved« } diff --git a/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in annotation/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in annotation/main.sdstest index 314584ad..f92ce51b 100644 --- a/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in annotation/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in annotation/main.sdstest @@ -3,22 +3,22 @@ package tests.scoping.parameterBounds.inAnnotation fun myFunction1(before: Int) annotation MyAnnotation( - // $TEST$ target own + # $TEST$ target own »own«: Int ) where { - // $TEST$ references own + # $TEST$ references own »own« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »before« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »after« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »notAParameter« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »unresolved« < 0 } diff --git a/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in enum variant in nested enum/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in enum variant in nested enum/main.sdstest index 16e0811f..9225e907 100644 --- a/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in enum variant in nested enum/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in enum variant in nested enum/main.sdstest @@ -5,25 +5,25 @@ class MyClass(container: Int) { enum MyEnum { MyEnumVariant( - // $TEST$ target own + # $TEST$ target own »own«: Int ) where { - // $TEST$ references own + # $TEST$ references own »own« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »container« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »beforeEnum« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »afterEnum« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »notAParameter« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »unresolved« < 0 } } diff --git a/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in global class/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in global class/main.sdstest index e3ada215..2b4fea6f 100644 --- a/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in global class/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in global class/main.sdstest @@ -3,22 +3,22 @@ package tests.scoping.parameterBounds.inGlobalClass fun myFunction1(before: Int) class MyClass( - // $TEST$ target own + # $TEST$ target own »own«: Int ) where { - // $TEST$ references own + # $TEST$ references own »own« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »before« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »after« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »notAParameter« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »unresolved« < 0 } diff --git a/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in global function/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in global function/main.sdstest index 79641217..86b4434a 100644 --- a/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in global function/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in global function/main.sdstest @@ -3,22 +3,22 @@ package tests.scoping.parameterBounds.inGlobalFunction fun myFunction1(before: Int) fun myFunction2( - // $TEST$ target own + # $TEST$ target own »own«: Int ) where { - // $TEST$ references own + # $TEST$ references own »own« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »before« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »after« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »notAParameter« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »unresolved« < 0 } diff --git a/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in method/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in method/main.sdstest index 3ea3d3bc..77710ef3 100644 --- a/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in method/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in method/main.sdstest @@ -6,37 +6,37 @@ class MyClass1(container: Int, overridden: Int) { fun myFunction2(beforeMember: Int) fun myFunction3( - // $TEST$ target own + # $TEST$ target own »own«: Int, - // $TEST$ target overridden + # $TEST$ target overridden »overridden«: Int, ) where { - // $TEST$ references own + # $TEST$ references own »own« < 0, - // $TEST$ references overridden + # $TEST$ references overridden »overridden« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »container« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »beforeMember« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »afterMember« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »beforeGlobal« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »afterGlobal« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »notAParameter« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »unresolved« < 0 } diff --git a/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in nested class/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in nested class/main.sdstest index 1d4ec748..e9227c88 100644 --- a/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in nested class/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in nested class/main.sdstest @@ -6,37 +6,37 @@ class MyClass1(container: Int, overridden: Int){ fun myFunction2(beforeMember: Int) class MyClass2( - // $TEST$ target own + # $TEST$ target own »own«: Int, - // $TEST$ target overridden + # $TEST$ target overridden »overridden«: Int, ) where { - // $TEST$ references own + # $TEST$ references own »own« < 0, - // $TEST$ references overridden + # $TEST$ references overridden »overridden« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »container« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »beforeMember« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »afterMember« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »beforeGlobal« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »afterGlobal« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »notAParameter« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »unresolved« < 0 } diff --git a/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in segment/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in segment/main.sdstest index d426d269..c6344698 100644 --- a/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in segment/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in segment/main.sdstest @@ -3,22 +3,22 @@ package tests.scoping.parameterBounds.inSegment segment mySegment1(before: Int) {} segment mySegment2( - // $TEST$ target own + # $TEST$ target own »own«: Int ) where { - // $TEST$ references own + # $TEST$ references own »own« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »before« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »after« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »notAParameter« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »unresolved« < 0 } {} diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main no imports or own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main no imports or own declarations.sdstest index 343ec013..2547d874 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main no imports or own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main no imports or own declarations.sdstest @@ -1,18 +1,18 @@ package tests.scoping.references.acrossFiles.toAnnotations pipeline myPipeline { - // $TEST$ references same_MyAnnotation + # $TEST$ references same_MyAnnotation »MyAnnotation«; - // $TEST$ references same_AnnotationInSamePackage + # $TEST$ references same_AnnotationInSamePackage »AnnotationInSamePackage«; - // $TEST$ references safeds_AnnotationInSafeDsPackage + # $TEST$ references safeds_AnnotationInSafeDsPackage »AnnotationInSafeDsPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »AnnotationInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »AnnotationWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with imports and own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with imports and own declarations.sdstest index 795246ef..e6d72433 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with imports and own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with imports and own declarations.sdstest @@ -3,25 +3,25 @@ package tests.scoping.references.acrossFiles.toAnnotations from safeds.scoping.references.acrossFiles.toAnnotations import MyAnnotation as MyOwnAnnotation from tests.scoping.references.acrossFiles.toAnnotations.other import AnnotationInAnotherPackage, Annotation2InAnotherPackage -// $TEST$ target own_MyOwnAnnotation +# $TEST$ target own_MyOwnAnnotation annotation »MyOwnAnnotation« pipeline myPipeline { - // $TEST$ references own_MyOwnAnnotation + # $TEST$ references own_MyOwnAnnotation »MyOwnAnnotation«; - // $TEST$ references same_AnnotationInSamePackage + # $TEST$ references same_AnnotationInSamePackage »AnnotationInSamePackage«; - // $TEST$ references safeds_AnnotationInSafeDsPackage + # $TEST$ references safeds_AnnotationInSafeDsPackage »AnnotationInSafeDsPackage«; - // $TEST$ references other_AnnotationInAnotherPackage + # $TEST$ references other_AnnotationInAnotherPackage »AnnotationInAnotherPackage«; - // $TEST$ references other_Annotation2InAnotherPackage + # $TEST$ references other_Annotation2InAnotherPackage »Annotation2InAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »AnnotationWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with multiple imports of same name.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with multiple imports of same name.sdstest index 9c10eff5..d4bd8629 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with multiple imports of same name.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with multiple imports of same name.sdstest @@ -5,6 +5,6 @@ from tests.scoping.references.acrossFiles.toAnnotations.other import MyAnnotatio from tests.scoping.references.acrossFiles.toAnnotations import MyAnnotation pipeline myPipeline { - // $TEST$ references safeds_MyAnnotation + # $TEST$ references safeds_MyAnnotation »MyAnnotation«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with qualified import with alias.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with qualified import with alias.sdstest index 8e57d387..ac651e59 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with qualified import with alias.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with qualified import with alias.sdstest @@ -5,28 +5,28 @@ from safeds.scoping.references.acrossFiles.toAnnotations import MyAnnotation as from tests.scoping.references.acrossFiles.toAnnotations.other import MyAnnotation as MyAnnotationInAnotherPackage pipeline myPipeline { - // $TEST$ references same_MyAnnotation + # $TEST$ references same_MyAnnotation »MyAnnotation«; - // $TEST$ references same_AnnotationInSamePackage + # $TEST$ references same_AnnotationInSamePackage »AnnotationInSamePackage«; - // $TEST$ references safeds_AnnotationInSafeDsPackage + # $TEST$ references safeds_AnnotationInSafeDsPackage »AnnotationInSafeDsPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »AnnotationInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »AnnotationWithoutPackage«; - // $TEST$ references same_MyAnnotation + # $TEST$ references same_MyAnnotation »MyAnnotationInSamePackage«; - // $TEST$ references safeds_MyAnnotation + # $TEST$ references safeds_MyAnnotation »MyAnnotationInSafeDsPackage«; - // $TEST$ references other_MyAnnotation + # $TEST$ references other_MyAnnotation »MyAnnotationInAnotherPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with qualified import.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with qualified import.sdstest index f2e10fd9..4d6a9b2a 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with qualified import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with qualified import.sdstest @@ -4,21 +4,21 @@ from safeds.scoping.references.acrossFiles.toAnnotations import MyAnnotation from tests.scoping.references.acrossFiles.toAnnotations.other import AnnotationInAnotherPackage, Annotation2InAnotherPackage pipeline myPipeline { - // $TEST$ references safeds_MyAnnotation + # $TEST$ references safeds_MyAnnotation »MyAnnotation«; - // $TEST$ references same_AnnotationInSamePackage + # $TEST$ references same_AnnotationInSamePackage »AnnotationInSamePackage«; - // $TEST$ references safeds_AnnotationInSafeDsPackage + # $TEST$ references safeds_AnnotationInSafeDsPackage »AnnotationInSafeDsPackage«; - // $TEST$ references other_AnnotationInAnotherPackage + # $TEST$ references other_AnnotationInAnotherPackage »AnnotationInAnotherPackage«; - // $TEST$ references other_Annotation2InAnotherPackage + # $TEST$ references other_Annotation2InAnotherPackage »Annotation2InAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »AnnotationWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with wildcard import.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with wildcard import.sdstest index db146974..033fc98d 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with wildcard import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with wildcard import.sdstest @@ -3,18 +3,18 @@ package tests.scoping.references.acrossFiles.toAnnotations from safeds.scoping.references.acrossFiles.toAnnotations import * pipeline myPipeline { - // $TEST$ references safeds_MyAnnotation + # $TEST$ references safeds_MyAnnotation »MyAnnotation«; - // $TEST$ references same_AnnotationInSamePackage + # $TEST$ references same_AnnotationInSamePackage »AnnotationInSamePackage«; - // $TEST$ references safeds_AnnotationInSafeDsPackage + # $TEST$ references safeds_AnnotationInSafeDsPackage »AnnotationInSafeDsPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »AnnotationInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »AnnotationWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/resource other package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/resource other package.sdstest index 88ac9ad5..df6ccb25 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/resource other package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/resource other package.sdstest @@ -1,10 +1,10 @@ package tests.scoping.references.acrossFiles.toAnnotations.other -// $TEST$ target other_MyAnnotation +# $TEST$ target other_MyAnnotation annotation »MyAnnotation« -// $TEST$ target other_AnnotationInAnotherPackage +# $TEST$ target other_AnnotationInAnotherPackage annotation »AnnotationInAnotherPackage« -// $TEST$ target other_Annotation2InAnotherPackage +# $TEST$ target other_Annotation2InAnotherPackage annotation »Annotation2InAnotherPackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/resource safeds package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/resource safeds package.sdstest index 3febd64f..b8bc9f89 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/resource safeds package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/resource safeds package.sdstest @@ -1,7 +1,7 @@ package safeds.scoping.references.acrossFiles.toAnnotations -// $TEST$ target safeds_MyAnnotation +# $TEST$ target safeds_MyAnnotation annotation »MyAnnotation« -// $TEST$ target safeds_AnnotationInSafeDsPackage +# $TEST$ target safeds_AnnotationInSafeDsPackage annotation »AnnotationInSafeDsPackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/resource same package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/resource same package.sdstest index 03f61011..14a44a20 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/resource same package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/resource same package.sdstest @@ -1,7 +1,7 @@ package tests.scoping.references.acrossFiles.toAnnotations -// $TEST$ target same_MyAnnotation +# $TEST$ target same_MyAnnotation annotation »MyAnnotation« -// $TEST$ target same_AnnotationInSamePackage +# $TEST$ target same_AnnotationInSamePackage annotation »AnnotationInSamePackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/resource without package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/resource without package.sdstest index 39a33d04..c4c3bc48 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/resource without package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/resource without package.sdstest @@ -1,5 +1,5 @@ -// $TEST$ target without_MyAnnotation +# $TEST$ target without_MyAnnotation annotation »MyAnnotation« -// $TEST$ target without_AnnotationWithoutPackage +# $TEST$ target without_AnnotationWithoutPackage annotation »AnnotationWithoutPackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main no imports or own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main no imports or own declarations.sdstest index 14832a0e..7c0e3ff8 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main no imports or own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main no imports or own declarations.sdstest @@ -1,18 +1,18 @@ package tests.scoping.references.acrossFiles.toGlobalClasses pipeline myPipeline { - // $TEST$ references same_MyClass + # $TEST$ references same_MyClass »MyClass«; - // $TEST$ references same_ClassInSamePackage + # $TEST$ references same_ClassInSamePackage »ClassInSamePackage«; - // $TEST$ references safeds_ClassInSafeDsPackage + # $TEST$ references safeds_ClassInSafeDsPackage »ClassInSafeDsPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »ClassInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »ClassWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with imports and own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with imports and own declarations.sdstest index 1f05fa8b..1f211248 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with imports and own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with imports and own declarations.sdstest @@ -3,25 +3,25 @@ package tests.scoping.references.acrossFiles.toGlobalClasses from safeds.scoping.references.acrossFiles.toGlobalClasses import MyClass as MyOwnClass from tests.scoping.references.acrossFiles.toGlobalClasses.other import ClassInAnotherPackage, Class2InAnotherPackage -// $TEST$ target own_MyOwnClass +# $TEST$ target own_MyOwnClass class »MyOwnClass« pipeline myPipeline { - // $TEST$ references own_MyOwnClass + # $TEST$ references own_MyOwnClass »MyOwnClass«; - // $TEST$ references same_ClassInSamePackage + # $TEST$ references same_ClassInSamePackage »ClassInSamePackage«; - // $TEST$ references safeds_ClassInSafeDsPackage + # $TEST$ references safeds_ClassInSafeDsPackage »ClassInSafeDsPackage«; - // $TEST$ references other_ClassInAnotherPackage + # $TEST$ references other_ClassInAnotherPackage »ClassInAnotherPackage«; - // $TEST$ references other_Class2InAnotherPackage + # $TEST$ references other_Class2InAnotherPackage »Class2InAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »ClassWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with multiple imports of same name.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with multiple imports of same name.sdstest index 8b624512..a18fe36a 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with multiple imports of same name.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with multiple imports of same name.sdstest @@ -5,6 +5,6 @@ from tests.scoping.references.acrossFiles.toGlobalClasses.other import MyClass from tests.scoping.references.acrossFiles.toGlobalClasses import MyClass pipeline myPipeline { - // $TEST$ references safeds_MyClass + # $TEST$ references safeds_MyClass »MyClass«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with qualified import with alias.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with qualified import with alias.sdstest index 2a7d6d90..02c0a5e4 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with qualified import with alias.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with qualified import with alias.sdstest @@ -5,28 +5,28 @@ from safeds.scoping.references.acrossFiles.toGlobalClasses import MyClass as MyC from tests.scoping.references.acrossFiles.toGlobalClasses.other import MyClass as MyClassInAnotherPackage pipeline myPipeline { - // $TEST$ references same_MyClass + # $TEST$ references same_MyClass »MyClass«; - // $TEST$ references same_ClassInSamePackage + # $TEST$ references same_ClassInSamePackage »ClassInSamePackage«; - // $TEST$ references safeds_ClassInSafeDsPackage + # $TEST$ references safeds_ClassInSafeDsPackage »ClassInSafeDsPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »ClassInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »ClassWithoutPackage«; - // $TEST$ references same_MyClass + # $TEST$ references same_MyClass »MyClassInSamePackage«; - // $TEST$ references safeds_MyClass + # $TEST$ references safeds_MyClass »MyClassInSafeDsPackage«; - // $TEST$ references other_MyClass + # $TEST$ references other_MyClass »MyClassInAnotherPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with qualified import.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with qualified import.sdstest index 10bf0a70..314d80e9 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with qualified import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with qualified import.sdstest @@ -4,21 +4,21 @@ from safeds.scoping.references.acrossFiles.toGlobalClasses import MyClass from tests.scoping.references.acrossFiles.toGlobalClasses.other import ClassInAnotherPackage, Class2InAnotherPackage pipeline myPipeline { - // $TEST$ references safeds_MyClass + # $TEST$ references safeds_MyClass »MyClass«; - // $TEST$ references same_ClassInSamePackage + # $TEST$ references same_ClassInSamePackage »ClassInSamePackage«; - // $TEST$ references safeds_ClassInSafeDsPackage + # $TEST$ references safeds_ClassInSafeDsPackage »ClassInSafeDsPackage«; - // $TEST$ references other_ClassInAnotherPackage + # $TEST$ references other_ClassInAnotherPackage »ClassInAnotherPackage«; - // $TEST$ references other_Class2InAnotherPackage + # $TEST$ references other_Class2InAnotherPackage »Class2InAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »ClassWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with wildcard import.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with wildcard import.sdstest index 2e24c405..2e852a7b 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with wildcard import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with wildcard import.sdstest @@ -3,18 +3,18 @@ package tests.scoping.references.acrossFiles.toGlobalClasses from safeds.scoping.references.acrossFiles.toGlobalClasses import * pipeline myPipeline { - // $TEST$ references safeds_MyClass + # $TEST$ references safeds_MyClass »MyClass«; - // $TEST$ references same_ClassInSamePackage + # $TEST$ references same_ClassInSamePackage »ClassInSamePackage«; - // $TEST$ references safeds_ClassInSafeDsPackage + # $TEST$ references safeds_ClassInSafeDsPackage »ClassInSafeDsPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »ClassInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »ClassWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/resource other package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/resource other package.sdstest index 67c9b8be..92d67f2c 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/resource other package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/resource other package.sdstest @@ -1,10 +1,10 @@ package tests.scoping.references.acrossFiles.toGlobalClasses.other -// $TEST$ target other_MyClass +# $TEST$ target other_MyClass class »MyClass« -// $TEST$ target other_ClassInAnotherPackage +# $TEST$ target other_ClassInAnotherPackage class »ClassInAnotherPackage« -// $TEST$ target other_Class2InAnotherPackage +# $TEST$ target other_Class2InAnotherPackage class »Class2InAnotherPackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/resource safeds package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/resource safeds package.sdstest index f9bbc9a9..3da34893 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/resource safeds package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/resource safeds package.sdstest @@ -1,7 +1,7 @@ package safeds.scoping.references.acrossFiles.toGlobalClasses -// $TEST$ target safeds_MyClass +# $TEST$ target safeds_MyClass class »MyClass« -// $TEST$ target safeds_ClassInSafeDsPackage +# $TEST$ target safeds_ClassInSafeDsPackage class »ClassInSafeDsPackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/resource same package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/resource same package.sdstest index 5f358622..17f76130 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/resource same package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/resource same package.sdstest @@ -1,7 +1,7 @@ package tests.scoping.references.acrossFiles.toGlobalClasses -// $TEST$ target same_MyClass +# $TEST$ target same_MyClass class »MyClass« -// $TEST$ target same_ClassInSamePackage +# $TEST$ target same_ClassInSamePackage class »ClassInSamePackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/resource without package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/resource without package.sdstest index bcd07435..82705a3b 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/resource without package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/resource without package.sdstest @@ -1,5 +1,5 @@ -// $TEST$ target without_MyClass +# $TEST$ target without_MyClass class »MyClass« -// $TEST$ target without_ClassWithoutPackage +# $TEST$ target without_ClassWithoutPackage class »ClassWithoutPackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main no imports or own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main no imports or own declarations.sdstest index 0271f2e5..169c166b 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main no imports or own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main no imports or own declarations.sdstest @@ -1,18 +1,18 @@ package tests.scoping.references.acrossFiles.toGlobalEnums pipeline myPipeline { - // $TEST$ references same_MyEnum + # $TEST$ references same_MyEnum »MyEnum«; - // $TEST$ references same_EnumInSamePackage + # $TEST$ references same_EnumInSamePackage »EnumInSamePackage«; - // $TEST$ references safeds_EnumInSafeDsPackage + # $TEST$ references safeds_EnumInSafeDsPackage »EnumInSafeDsPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »EnumInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »EnumWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with imports and own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with imports and own declarations.sdstest index 5d3127fa..d6e0ee1a 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with imports and own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with imports and own declarations.sdstest @@ -3,25 +3,25 @@ package tests.scoping.references.acrossFiles.toGlobalEnums from safeds.scoping.references.acrossFiles.toGlobalEnums import MyEnum as MyOwnEnum from tests.scoping.references.acrossFiles.toGlobalEnums.other import EnumInAnotherPackage, Enum2InAnotherPackage -// $TEST$ target own_MyOwnEnum +# $TEST$ target own_MyOwnEnum enum »MyOwnEnum« pipeline myPipeline { - // $TEST$ references own_MyOwnEnum + # $TEST$ references own_MyOwnEnum »MyOwnEnum«; - // $TEST$ references same_EnumInSamePackage + # $TEST$ references same_EnumInSamePackage »EnumInSamePackage«; - // $TEST$ references safeds_EnumInSafeDsPackage + # $TEST$ references safeds_EnumInSafeDsPackage »EnumInSafeDsPackage«; - // $TEST$ references other_EnumInAnotherPackage + # $TEST$ references other_EnumInAnotherPackage »EnumInAnotherPackage«; - // $TEST$ references other_Enum2InAnotherPackage + # $TEST$ references other_Enum2InAnotherPackage »Enum2InAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »EnumWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with multiple imports of same name.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with multiple imports of same name.sdstest index 6a8fe5b7..2e53d5b0 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with multiple imports of same name.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with multiple imports of same name.sdstest @@ -5,6 +5,6 @@ from tests.scoping.references.acrossFiles.toGlobalEnums.other import MyEnum from tests.scoping.references.acrossFiles.toGlobalEnums import MyEnum pipeline myPipeline { - // $TEST$ references safeds_MyEnum + # $TEST$ references safeds_MyEnum »MyEnum«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with qualified import with alias.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with qualified import with alias.sdstest index 6139ad2f..e37bb443 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with qualified import with alias.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with qualified import with alias.sdstest @@ -5,29 +5,29 @@ from safeds.scoping.references.acrossFiles.toGlobalEnums import MyEnum as MyEnum from tests.scoping.references.acrossFiles.toGlobalEnums.other import MyEnum as MyEnumInAnotherPackage pipeline myPipeline { - // $TEST$ references same_MyEnum + # $TEST$ references same_MyEnum »MyEnum«; - // $TEST$ references same_EnumInSamePackage + # $TEST$ references same_EnumInSamePackage »EnumInSamePackage«; - // $TEST$ references safeds_EnumInSafeDsPackage + # $TEST$ references safeds_EnumInSafeDsPackage »EnumInSafeDsPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »EnumInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »EnumWithoutPackage«; - // $TEST$ references same_MyEnum + # $TEST$ references same_MyEnum »MyEnumInSamePackage«; - // $TEST$ references safeds_MyEnum + # $TEST$ references safeds_MyEnum »MyEnumInSafeDsPackage«; - // $TEST$ references other_MyEnum + # $TEST$ references other_MyEnum »MyEnumInAnotherPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with qualified import.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with qualified import.sdstest index c844cc99..db403cc5 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with qualified import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with qualified import.sdstest @@ -4,21 +4,21 @@ from safeds.scoping.references.acrossFiles.toGlobalEnums import MyEnum from tests.scoping.references.acrossFiles.toGlobalEnums.other import EnumInAnotherPackage, Enum2InAnotherPackage pipeline myPipeline { - // $TEST$ references safeds_MyEnum + # $TEST$ references safeds_MyEnum »MyEnum«; - // $TEST$ references same_EnumInSamePackage + # $TEST$ references same_EnumInSamePackage »EnumInSamePackage«; - // $TEST$ references safeds_EnumInSafeDsPackage + # $TEST$ references safeds_EnumInSafeDsPackage »EnumInSafeDsPackage«; - // $TEST$ references other_EnumInAnotherPackage + # $TEST$ references other_EnumInAnotherPackage »EnumInAnotherPackage«; - // $TEST$ references other_Enum2InAnotherPackage + # $TEST$ references other_Enum2InAnotherPackage »Enum2InAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »EnumWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with wildcard import.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with wildcard import.sdstest index 391d353e..00201f84 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with wildcard import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with wildcard import.sdstest @@ -3,18 +3,18 @@ package tests.scoping.references.acrossFiles.toGlobalEnums from safeds.scoping.references.acrossFiles.toGlobalEnums import * pipeline myPipeline { - // $TEST$ references safeds_MyEnum + # $TEST$ references safeds_MyEnum »MyEnum«; - // $TEST$ references same_EnumInSamePackage + # $TEST$ references same_EnumInSamePackage »EnumInSamePackage«; - // $TEST$ references safeds_EnumInSafeDsPackage + # $TEST$ references safeds_EnumInSafeDsPackage »EnumInSafeDsPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »EnumInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »EnumWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/resource other package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/resource other package.sdstest index a561a587..5ac5748d 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/resource other package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/resource other package.sdstest @@ -1,10 +1,10 @@ package tests.scoping.references.acrossFiles.toGlobalEnums.other -// $TEST$ target other_MyEnum +# $TEST$ target other_MyEnum enum »MyEnum« -// $TEST$ target other_EnumInAnotherPackage +# $TEST$ target other_EnumInAnotherPackage enum »EnumInAnotherPackage« -// $TEST$ target other_Enum2InAnotherPackage +# $TEST$ target other_Enum2InAnotherPackage enum »Enum2InAnotherPackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/resource safeds package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/resource safeds package.sdstest index 44e595fc..ba6c6b01 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/resource safeds package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/resource safeds package.sdstest @@ -1,7 +1,7 @@ package safeds.scoping.references.acrossFiles.toGlobalEnums -// $TEST$ target safeds_MyEnum +# $TEST$ target safeds_MyEnum enum »MyEnum« -// $TEST$ target safeds_EnumInSafeDsPackage +# $TEST$ target safeds_EnumInSafeDsPackage enum »EnumInSafeDsPackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/resource same package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/resource same package.sdstest index 43c20ebc..7710a15d 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/resource same package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/resource same package.sdstest @@ -1,7 +1,7 @@ package tests.scoping.references.acrossFiles.toGlobalEnums -// $TEST$ target same_MyEnum +# $TEST$ target same_MyEnum enum »MyEnum« -// $TEST$ target same_EnumInSamePackage +# $TEST$ target same_EnumInSamePackage enum »EnumInSamePackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/resource without package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/resource without package.sdstest index 7587c7e2..b0052f12 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/resource without package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/resource without package.sdstest @@ -1,5 +1,5 @@ -// $TEST$ target without_MyEnum +# $TEST$ target without_MyEnum enum »MyEnum« -// $TEST$ target without_EnumWithoutPackage +# $TEST$ target without_EnumWithoutPackage enum »EnumWithoutPackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main no imports or own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main no imports or own declarations.sdstest index aa95d66f..c158cb96 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main no imports or own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main no imports or own declarations.sdstest @@ -1,18 +1,18 @@ package tests.scoping.references.acrossFiles.toGlobalFunctions pipeline myPipeline { - // $TEST$ references same_myFunction + # $TEST$ references same_myFunction »myFunction«; - // $TEST$ references same_functionInSamePackage + # $TEST$ references same_functionInSamePackage »functionInSamePackage«; - // $TEST$ references safeds_functionInSafeDsPackage + # $TEST$ references safeds_functionInSafeDsPackage »functionInSafeDsPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »functionInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »functionWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with imports and own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with imports and own declarations.sdstest index 822b94b9..8d37eb3c 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with imports and own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with imports and own declarations.sdstest @@ -3,25 +3,25 @@ package tests.scoping.references.acrossFiles.toGlobalFunctions from safeds.scoping.references.acrossFiles.toGlobalFunctions import myFunction as myOwnFunction from tests.scoping.references.acrossFiles.toGlobalFunctions.other import functionInAnotherPackage, function2InAnotherPackage -// $TEST$ target own_myOwnFunction +# $TEST$ target own_myOwnFunction fun »myOwnFunction«() pipeline myPipeline { - // $TEST$ references own_myOwnFunction + # $TEST$ references own_myOwnFunction »myOwnFunction«; - // $TEST$ references same_functionInSamePackage + # $TEST$ references same_functionInSamePackage »functionInSamePackage«; - // $TEST$ references safeds_functionInSafeDsPackage + # $TEST$ references safeds_functionInSafeDsPackage »functionInSafeDsPackage«; - // $TEST$ references other_functionInAnotherPackage + # $TEST$ references other_functionInAnotherPackage »functionInAnotherPackage«; - // $TEST$ references other_function2InAnotherPackage + # $TEST$ references other_function2InAnotherPackage »function2InAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »functionWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with multiple imports of same name.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with multiple imports of same name.sdstest index d19d3dff..ddee893c 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with multiple imports of same name.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with multiple imports of same name.sdstest @@ -5,6 +5,6 @@ from tests.scoping.references.acrossFiles.toGlobalFunctions.other import myFunct from tests.scoping.references.acrossFiles.toGlobalFunctions import myFunction pipeline myPipeline { - // $TEST$ references safeds_myFunction + # $TEST$ references safeds_myFunction »myFunction«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with qualified import with alias.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with qualified import with alias.sdstest index fd2a9cb9..cd0eff17 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with qualified import with alias.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with qualified import with alias.sdstest @@ -5,29 +5,29 @@ from safeds.scoping.references.acrossFiles.toGlobalFunctions import myFunction a from tests.scoping.references.acrossFiles.toGlobalFunctions.other import myFunction as myFunctionInAnotherPackage pipeline myPipeline { - // $TEST$ references same_myFunction + # $TEST$ references same_myFunction »myFunction«; - // $TEST$ references same_functionInSamePackage + # $TEST$ references same_functionInSamePackage »functionInSamePackage«; - // $TEST$ references safeds_functionInSafeDsPackage + # $TEST$ references safeds_functionInSafeDsPackage »functionInSafeDsPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »functionInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »functionWithoutPackage«; - // $TEST$ references same_myFunction + # $TEST$ references same_myFunction »myFunctionInSamePackage«; - // $TEST$ references safeds_myFunction + # $TEST$ references safeds_myFunction »myFunctionInSafeDsPackage«; - // $TEST$ references other_myFunction + # $TEST$ references other_myFunction »myFunctionInAnotherPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with qualified import.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with qualified import.sdstest index 056e08fc..6cb0e73d 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with qualified import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with qualified import.sdstest @@ -4,21 +4,21 @@ from safeds.scoping.references.acrossFiles.toGlobalFunctions import myFunction from tests.scoping.references.acrossFiles.toGlobalFunctions.other import functionInAnotherPackage, function2InAnotherPackage pipeline myPipeline { - // $TEST$ references safeds_myFunction + # $TEST$ references safeds_myFunction »myFunction«; - // $TEST$ references same_functionInSamePackage + # $TEST$ references same_functionInSamePackage »functionInSamePackage«; - // $TEST$ references safeds_functionInSafeDsPackage + # $TEST$ references safeds_functionInSafeDsPackage »functionInSafeDsPackage«; - // $TEST$ references other_functionInAnotherPackage + # $TEST$ references other_functionInAnotherPackage »functionInAnotherPackage«; - // $TEST$ references other_function2InAnotherPackage + # $TEST$ references other_function2InAnotherPackage »function2InAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »functionWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with wildcard import.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with wildcard import.sdstest index e152bdc8..0b998b96 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with wildcard import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with wildcard import.sdstest @@ -3,18 +3,18 @@ package tests.scoping.references.acrossFiles.toGlobalFunctions from safeds.scoping.references.acrossFiles.toGlobalFunctions import * pipeline myPipeline { - // $TEST$ references safeds_myFunction + # $TEST$ references safeds_myFunction »myFunction«; - // $TEST$ references same_functionInSamePackage + # $TEST$ references same_functionInSamePackage »functionInSamePackage«; - // $TEST$ references safeds_functionInSafeDsPackage + # $TEST$ references safeds_functionInSafeDsPackage »functionInSafeDsPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »functionInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »functionWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/resource other package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/resource other package.sdstest index 350069f5..7a774965 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/resource other package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/resource other package.sdstest @@ -1,10 +1,10 @@ package tests.scoping.references.acrossFiles.toGlobalFunctions.other -// $TEST$ target other_myFunction +# $TEST$ target other_myFunction fun »myFunction«() -// $TEST$ target other_functionInAnotherPackage +# $TEST$ target other_functionInAnotherPackage fun »functionInAnotherPackage«() -// $TEST$ target other_function2InAnotherPackage +# $TEST$ target other_function2InAnotherPackage fun »function2InAnotherPackage«() diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/resource safeds package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/resource safeds package.sdstest index 42f3f9bd..5591bde0 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/resource safeds package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/resource safeds package.sdstest @@ -1,7 +1,7 @@ package safeds.scoping.references.acrossFiles.toGlobalFunctions -// $TEST$ target safeds_myFunction +# $TEST$ target safeds_myFunction fun »myFunction«() -// $TEST$ target safeds_functionInSafeDsPackage +# $TEST$ target safeds_functionInSafeDsPackage fun »functionInSafeDsPackage«() diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/resource same package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/resource same package.sdstest index 969c2847..eec5e663 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/resource same package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/resource same package.sdstest @@ -1,7 +1,7 @@ package tests.scoping.references.acrossFiles.toGlobalFunctions -// $TEST$ target same_myFunction +# $TEST$ target same_myFunction fun »myFunction«() -// $TEST$ target same_functionInSamePackage +# $TEST$ target same_functionInSamePackage fun »functionInSamePackage«() diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/resource without package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/resource without package.sdstest index fc524811..bbead6af 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/resource without package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/resource without package.sdstest @@ -1,5 +1,5 @@ -// $TEST$ target without_myFunction +# $TEST$ target without_myFunction fun »myFunction«() -// $TEST$ target without_functionWithoutPackage +# $TEST$ target without_functionWithoutPackage fun »functionWithoutPackage«() diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main no imports or own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main no imports or own declarations.sdstest index 2a5d9174..f7fbcf05 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main no imports or own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main no imports or own declarations.sdstest @@ -1,18 +1,18 @@ package tests.scoping.references.acrossFiles.toPipelines segment mySegment() { - // $TEST$ unresolved + # $TEST$ unresolved »myPipeline«; - // $TEST$ unresolved + # $TEST$ unresolved »pipelineInSamePackage«; - // $TEST$ unresolved + # $TEST$ unresolved »pipelineInSafeDsPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »pipelineInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »pipelineWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with imports and own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with imports and own declarations.sdstest index 18d49714..037f300d 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with imports and own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with imports and own declarations.sdstest @@ -3,25 +3,25 @@ package tests.scoping.references.acrossFiles.toPipelines from safeds.scoping.references.acrossFiles.toPipelines import myPipeline as myOwnPipeline from tests.scoping.references.acrossFiles.toPipelines.other import pipelineInAnotherPackage, pipeline2InAnotherPackage -// $TEST$ target own_myOwnPipeline +# $TEST$ target own_myOwnPipeline pipeline »myOwnPipeline« {} segment mySegment() { - // $TEST$ references own_myOwnPipeline + # $TEST$ references own_myOwnPipeline »myOwnPipeline«; - // $TEST$ unresolved + # $TEST$ unresolved »pipelineInSamePackage«; - // $TEST$ unresolved + # $TEST$ unresolved »pipelineInSafeDsPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »pipelineInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »pipeline2InAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »pipelineWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with multiple imports of same name.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with multiple imports of same name.sdstest index 9720b43e..6e29ff58 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with multiple imports of same name.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with multiple imports of same name.sdstest @@ -5,6 +5,6 @@ from tests.scoping.references.acrossFiles.toPipelines.other import myPipeline from tests.scoping.references.acrossFiles.toPipelines import myPipeline segment mySegment() { - // $TEST$ unresolved + # $TEST$ unresolved »myPipeline«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with qualified import with alias.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with qualified import with alias.sdstest index 9f3eb5e3..f85da9f7 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with qualified import with alias.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with qualified import with alias.sdstest @@ -5,29 +5,29 @@ from safeds.scoping.references.acrossFiles.toPipelines import myPipeline as myPi from tests.scoping.references.acrossFiles.toPipelines.other import myPipeline as myPipelineInAnotherPackage segment mySegment() { - // $TEST$ unresolved + # $TEST$ unresolved »myPipeline«; - // $TEST$ unresolved + # $TEST$ unresolved »pipelineInSamePackage«; - // $TEST$ unresolved + # $TEST$ unresolved »pipelineInSafeDsPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »pipelineInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »pipelineWithoutPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »myPipelineInSamePackage«; - // $TEST$ unresolved + # $TEST$ unresolved »myPipelineInSafeDsPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »myPipelineInAnotherPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with qualified import.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with qualified import.sdstest index 5b97bbc9..91dae559 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with qualified import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with qualified import.sdstest @@ -4,21 +4,21 @@ from safeds.scoping.references.acrossFiles.toPipelines import myPipeline from tests.scoping.references.acrossFiles.toPipelines.other import pipelineInAnotherPackage, pipeline2InAnotherPackage segment mySegment() { - // $TEST$ unresolved + # $TEST$ unresolved »myPipeline«; - // $TEST$ unresolved + # $TEST$ unresolved »pipelineInSamePackage«; - // $TEST$ unresolved + # $TEST$ unresolved »pipelineInSafeDsPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »pipelineInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »pipeline2InAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »pipelineWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with wildcard import.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with wildcard import.sdstest index 8747eb06..1483767b 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with wildcard import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with wildcard import.sdstest @@ -3,18 +3,18 @@ package tests.scoping.references.acrossFiles.toPipelines from safeds.scoping.references.acrossFiles.toPipelines import * segment mySegment() { - // $TEST$ unresolved + # $TEST$ unresolved »myPipeline«; - // $TEST$ unresolved + # $TEST$ unresolved »pipelineInSamePackage«; - // $TEST$ unresolved + # $TEST$ unresolved »pipelineInSafeDsPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »pipelineInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »pipelineWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/resource other package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/resource other package.sdstest index 3adecca8..76010a15 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/resource other package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/resource other package.sdstest @@ -1,10 +1,10 @@ package tests.scoping.references.acrossFiles.toPipelines.other -// $TEST$ target other_myPipeline +# $TEST$ target other_myPipeline pipeline »myPipeline« {} -// $TEST$ target other_pipelineInAnotherPackage +# $TEST$ target other_pipelineInAnotherPackage pipeline »pipelineInAnotherPackage« {} -// $TEST$ target other_pipeline2InAnotherPackage +# $TEST$ target other_pipeline2InAnotherPackage pipeline »pipeline2InAnotherPackage« {} diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/resource safeds package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/resource safeds package.sdstest index 9f66ceb0..9369b87c 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/resource safeds package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/resource safeds package.sdstest @@ -1,7 +1,7 @@ package safeds.scoping.references.acrossFiles.toPipelines -// $TEST$ target safeds_myPipeline +# $TEST$ target safeds_myPipeline pipeline »myPipeline« {} -// $TEST$ target safeds_pipelineInSafeDsPackage +# $TEST$ target safeds_pipelineInSafeDsPackage pipeline »pipelineInSafeDsPackage« {} diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/resource same package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/resource same package.sdstest index 34cec8ca..5bf4de88 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/resource same package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/resource same package.sdstest @@ -1,7 +1,7 @@ package tests.scoping.references.acrossFiles.toPipelines -// $TEST$ target same_myPipeline +# $TEST$ target same_myPipeline pipeline »myPipeline« {} -// $TEST$ target same_pipelineInSamePackage +# $TEST$ target same_pipelineInSamePackage pipeline »pipelineInSamePackage« {} diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/resource without package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/resource without package.sdstest index da94d86f..45977c18 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/resource without package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/resource without package.sdstest @@ -1,5 +1,5 @@ -// $TEST$ target without_myPipeline +# $TEST$ target without_myPipeline pipeline »myPipeline« {} -// $TEST$ target without_pipelineWithoutPackage +# $TEST$ target without_pipelineWithoutPackage pipeline »pipelineWithoutPackage« {} diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main no imports or own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main no imports or own declarations.sdstest index 9d84b922..4fddfd95 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main no imports or own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main no imports or own declarations.sdstest @@ -1,18 +1,18 @@ package tests.scoping.references.acrossFiles.toSchemas pipeline myPipeline { - // $TEST$ references same_MySchema + # $TEST$ references same_MySchema »MySchema«; - // $TEST$ references same_SchemaInSamePackage + # $TEST$ references same_SchemaInSamePackage »SchemaInSamePackage«; - // $TEST$ references safeds_SchemaInSafeDsPackage + # $TEST$ references safeds_SchemaInSafeDsPackage »SchemaInSafeDsPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »SchemaInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »SchemaWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with imports and own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with imports and own declarations.sdstest index 3aa40542..43bc5a88 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with imports and own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with imports and own declarations.sdstest @@ -3,25 +3,25 @@ package tests.scoping.references.acrossFiles.toSchemas from safeds.scoping.references.acrossFiles.toSchemas import MySchema as MyOwnSchema from tests.scoping.references.acrossFiles.toSchemas.other import SchemaInAnotherPackage, Schema2InAnotherPackage -// $TEST$ target own_MyOwnSchema +# $TEST$ target own_MyOwnSchema schema »MyOwnSchema« {} pipeline myPipeline { - // $TEST$ references own_MyOwnSchema + # $TEST$ references own_MyOwnSchema »MyOwnSchema«; - // $TEST$ references same_SchemaInSamePackage + # $TEST$ references same_SchemaInSamePackage »SchemaInSamePackage«; - // $TEST$ references safeds_SchemaInSafeDsPackage + # $TEST$ references safeds_SchemaInSafeDsPackage »SchemaInSafeDsPackage«; - // $TEST$ references other_SchemaInAnotherPackage + # $TEST$ references other_SchemaInAnotherPackage »SchemaInAnotherPackage«; - // $TEST$ references other_Schema2InAnotherPackage + # $TEST$ references other_Schema2InAnotherPackage »Schema2InAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »SchemaWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with multiple imports of same name.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with multiple imports of same name.sdstest index 1fb7f3e6..b71d43f7 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with multiple imports of same name.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with multiple imports of same name.sdstest @@ -5,6 +5,6 @@ from tests.scoping.references.acrossFiles.toSchemas.other import MySchema from tests.scoping.references.acrossFiles.toSchemas import MySchema pipeline myPipeline { - // $TEST$ references safeds_MySchema + # $TEST$ references safeds_MySchema »MySchema«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with qualified import with alias.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with qualified import with alias.sdstest index a4d0ffb9..f67c8eda 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with qualified import with alias.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with qualified import with alias.sdstest @@ -5,29 +5,29 @@ from safeds.scoping.references.acrossFiles.toSchemas import MySchema as MySchema from tests.scoping.references.acrossFiles.toSchemas.other import MySchema as MySchemaInAnotherPackage pipeline myPipeline { - // $TEST$ references same_MySchema + # $TEST$ references same_MySchema »MySchema«; - // $TEST$ references same_SchemaInSamePackage + # $TEST$ references same_SchemaInSamePackage »SchemaInSamePackage«; - // $TEST$ references safeds_SchemaInSafeDsPackage + # $TEST$ references safeds_SchemaInSafeDsPackage »SchemaInSafeDsPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »SchemaInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »SchemaWithoutPackage«; - // $TEST$ references same_MySchema + # $TEST$ references same_MySchema »MySchemaInSamePackage«; - // $TEST$ references safeds_MySchema + # $TEST$ references safeds_MySchema »MySchemaInSafeDsPackage«; - // $TEST$ references other_MySchema + # $TEST$ references other_MySchema »MySchemaInAnotherPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with qualified import.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with qualified import.sdstest index 49e62144..294ef945 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with qualified import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with qualified import.sdstest @@ -4,21 +4,21 @@ from safeds.scoping.references.acrossFiles.toSchemas import MySchema from tests.scoping.references.acrossFiles.toSchemas.other import SchemaInAnotherPackage, Schema2InAnotherPackage pipeline myPipeline { - // $TEST$ references safeds_MySchema + # $TEST$ references safeds_MySchema »MySchema«; - // $TEST$ references same_SchemaInSamePackage + # $TEST$ references same_SchemaInSamePackage »SchemaInSamePackage«; - // $TEST$ references safeds_SchemaInSafeDsPackage + # $TEST$ references safeds_SchemaInSafeDsPackage »SchemaInSafeDsPackage«; - // $TEST$ references other_SchemaInAnotherPackage + # $TEST$ references other_SchemaInAnotherPackage »SchemaInAnotherPackage«; - // $TEST$ references other_Schema2InAnotherPackage + # $TEST$ references other_Schema2InAnotherPackage »Schema2InAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »SchemaWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with wildcard import.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with wildcard import.sdstest index c7beb819..6af6cc0b 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with wildcard import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with wildcard import.sdstest @@ -3,18 +3,18 @@ package tests.scoping.references.acrossFiles.toSchemas from safeds.scoping.references.acrossFiles.toSchemas import * pipeline myPipeline { - // $TEST$ references safeds_MySchema + # $TEST$ references safeds_MySchema »MySchema«; - // $TEST$ references same_SchemaInSamePackage + # $TEST$ references same_SchemaInSamePackage »SchemaInSamePackage«; - // $TEST$ references safeds_SchemaInSafeDsPackage + # $TEST$ references safeds_SchemaInSafeDsPackage »SchemaInSafeDsPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »SchemaInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »SchemaWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/resource other package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/resource other package.sdstest index 27b7146e..4fb6033e 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/resource other package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/resource other package.sdstest @@ -1,10 +1,10 @@ package tests.scoping.references.acrossFiles.toSchemas.other -// $TEST$ target other_MySchema +# $TEST$ target other_MySchema schema »MySchema« {} -// $TEST$ target other_SchemaInAnotherPackage +# $TEST$ target other_SchemaInAnotherPackage schema »SchemaInAnotherPackage« {} -// $TEST$ target other_Schema2InAnotherPackage +# $TEST$ target other_Schema2InAnotherPackage schema »Schema2InAnotherPackage« {} diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/resource safeds package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/resource safeds package.sdstest index f8f5a10c..7a023633 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/resource safeds package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/resource safeds package.sdstest @@ -1,7 +1,7 @@ package safeds.scoping.references.acrossFiles.toSchemas -// $TEST$ target safeds_MySchema +# $TEST$ target safeds_MySchema schema »MySchema« {} -// $TEST$ target safeds_SchemaInSafeDsPackage +# $TEST$ target safeds_SchemaInSafeDsPackage schema »SchemaInSafeDsPackage« {} diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/resource same package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/resource same package.sdstest index 2fdfc079..7207677e 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/resource same package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/resource same package.sdstest @@ -1,7 +1,7 @@ package tests.scoping.references.acrossFiles.toSchemas -// $TEST$ target same_MySchema +# $TEST$ target same_MySchema schema »MySchema« {} -// $TEST$ target same_SchemaInSamePackage +# $TEST$ target same_SchemaInSamePackage schema »SchemaInSamePackage« {} diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/resource without package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/resource without package.sdstest index 89cd8480..3412fadb 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/resource without package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/resource without package.sdstest @@ -1,5 +1,5 @@ -// $TEST$ target without_MySchema +# $TEST$ target without_MySchema schema »MySchema« {} -// $TEST$ target without_SchemaWithoutPackage +# $TEST$ target without_SchemaWithoutPackage schema »SchemaWithoutPackage« {} diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main no imports or own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main no imports or own declarations.sdstest index 97e096ed..cc2d2cdd 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main no imports or own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main no imports or own declarations.sdstest @@ -1,46 +1,46 @@ package tests.scoping.references.acrossFiles.toSegments pipeline myPipeline { - // $TEST$ references same_mySegment + # $TEST$ references same_mySegment »mySegment«; - // $TEST$ references same_publicSegmentInSamePackage + # $TEST$ references same_publicSegmentInSamePackage »publicSegmentInSamePackage«; - // $TEST$ references same_internalSegmentInSamePackage + # $TEST$ references same_internalSegmentInSamePackage »internalSegmentInSamePackage«; - // $TEST$ unresolved + # $TEST$ unresolved »privateSegmentInSamePackage«; - // $TEST$ references safeds_publicSegmentInSafeDsPackage + # $TEST$ references safeds_publicSegmentInSafeDsPackage »publicSegmentInSafeDsPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »internalSegmentInSafeDsPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »privateSegmentInSafeDsPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »publicSegmentInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »internalSegmentInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »privateSegmentInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »publicSegmentWithoutPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »internalSegmentWithoutPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »privateSegmentWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with imports and own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with imports and own declarations.sdstest index f179230e..20131d86 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with imports and own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with imports and own declarations.sdstest @@ -5,53 +5,53 @@ from tests.scoping.references.acrossFiles.toSegments.other import publicSegmentI from tests.scoping.references.acrossFiles.toSegments.other import internalSegmentInAnotherPackage from tests.scoping.references.acrossFiles.toSegments.other import privateSegmentInAnotherPackage -// $TEST$ target own_myOwnSegment +# $TEST$ target own_myOwnSegment segment »myOwnSegment«() {} pipeline myPipeline { - // $TEST$ references own_myOwnSegment + # $TEST$ references own_myOwnSegment »myOwnSegment«; - // $TEST$ references same_publicSegmentInSamePackage + # $TEST$ references same_publicSegmentInSamePackage »publicSegmentInSamePackage«; - // $TEST$ references same_internalSegmentInSamePackage + # $TEST$ references same_internalSegmentInSamePackage »internalSegmentInSamePackage«; - // $TEST$ unresolved + # $TEST$ unresolved »privateSegmentInSamePackage«; - // $TEST$ references safeds_publicSegmentInSafeDsPackage + # $TEST$ references safeds_publicSegmentInSafeDsPackage »publicSegmentInSafeDsPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »internalSegmentInSafeDsPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »privateSegmentInSafeDsPackage«; - // $TEST$ references other_publicSegmentInAnotherPackage + # $TEST$ references other_publicSegmentInAnotherPackage »publicSegmentInAnotherPackage«; - // $TEST$ references other_public2SegmentInAnotherPackage + # $TEST$ references other_public2SegmentInAnotherPackage »public2SegmentInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »internalSegmentInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »privateSegmentInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »publicSegmentWithoutPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »internalSegmentWithoutPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »privateSegmentWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with multiple imports of same name.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with multiple imports of same name.sdstest index 3f6a60a0..ebd4460d 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with multiple imports of same name.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with multiple imports of same name.sdstest @@ -5,6 +5,6 @@ from tests.scoping.references.acrossFiles.toSegments.other import mySegment from tests.scoping.references.acrossFiles.toSegments import mySegment pipeline myPipeline { - // $TEST$ references safeds_mySegment + # $TEST$ references safeds_mySegment »mySegment«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with qualified import with alias.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with qualified import with alias.sdstest index a82b6d78..e719bb17 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with qualified import with alias.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with qualified import with alias.sdstest @@ -5,56 +5,56 @@ from safeds.scoping.references.acrossFiles.toSegments import mySegment as mySegm from tests.scoping.references.acrossFiles.toSegments.other import mySegment as mySegmentInAnotherPackage pipeline myPipeline { - // $TEST$ references same_mySegment + # $TEST$ references same_mySegment »mySegment«; - // $TEST$ references same_publicSegmentInSamePackage + # $TEST$ references same_publicSegmentInSamePackage »publicSegmentInSamePackage«; - // $TEST$ references same_internalSegmentInSamePackage + # $TEST$ references same_internalSegmentInSamePackage »internalSegmentInSamePackage«; - // $TEST$ unresolved + # $TEST$ unresolved »privateSegmentInSamePackage«; - // $TEST$ references safeds_publicSegmentInSafeDsPackage + # $TEST$ references safeds_publicSegmentInSafeDsPackage »publicSegmentInSafeDsPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »internalSegmentInSafeDsPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »privateSegmentInSafeDsPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »publicSegmentInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »internalSegmentInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »privateSegmentInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »publicSegmentWithoutPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »internalSegmentWithoutPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »privateSegmentWithoutPackage«; - // $TEST$ references same_mySegment + # $TEST$ references same_mySegment »mySegmentInSamePackage«; - // $TEST$ references safeds_mySegment + # $TEST$ references safeds_mySegment »mySegmentInSafeDsPackage«; - // $TEST$ references other_mySegment + # $TEST$ references other_mySegment »mySegmentInAnotherPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with qualified import.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with qualified import.sdstest index b0a350a4..8c9d7f67 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with qualified import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with qualified import.sdstest @@ -6,49 +6,49 @@ from tests.scoping.references.acrossFiles.toSegments.other import internalSegmen from tests.scoping.references.acrossFiles.toSegments.other import privateSegmentInAnotherPackage pipeline myPipeline { - // $TEST$ references safeds_mySegment + # $TEST$ references safeds_mySegment »mySegment«; - // $TEST$ references same_publicSegmentInSamePackage + # $TEST$ references same_publicSegmentInSamePackage »publicSegmentInSamePackage«; - // $TEST$ references same_internalSegmentInSamePackage + # $TEST$ references same_internalSegmentInSamePackage »internalSegmentInSamePackage«; - // $TEST$ unresolved + # $TEST$ unresolved »privateSegmentInSamePackage«; - // $TEST$ references safeds_publicSegmentInSafeDsPackage + # $TEST$ references safeds_publicSegmentInSafeDsPackage »publicSegmentInSafeDsPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »internalSegmentInSafeDsPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »privateSegmentInSafeDsPackage«; - // $TEST$ references other_publicSegmentInAnotherPackage + # $TEST$ references other_publicSegmentInAnotherPackage »publicSegmentInAnotherPackage«; - // $TEST$ references other_public2SegmentInAnotherPackage + # $TEST$ references other_public2SegmentInAnotherPackage »public2SegmentInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »internalSegmentInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »privateSegmentInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »publicSegmentWithoutPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »internalSegmentWithoutPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »privateSegmentWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with wildcard import.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with wildcard import.sdstest index 86caa307..4bfb2141 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with wildcard import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with wildcard import.sdstest @@ -3,46 +3,46 @@ package tests.scoping.references.acrossFiles.toSegments from safeds.scoping.references.acrossFiles.toSegments import * pipeline myPipeline { - // $TEST$ references safeds_mySegment + # $TEST$ references safeds_mySegment »mySegment«; - // $TEST$ references same_publicSegmentInSamePackage + # $TEST$ references same_publicSegmentInSamePackage »publicSegmentInSamePackage«; - // $TEST$ references same_internalSegmentInSamePackage + # $TEST$ references same_internalSegmentInSamePackage »internalSegmentInSamePackage«; - // $TEST$ unresolved + # $TEST$ unresolved »privateSegmentInSamePackage«; - // $TEST$ references safeds_publicSegmentInSafeDsPackage + # $TEST$ references safeds_publicSegmentInSafeDsPackage »publicSegmentInSafeDsPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »internalSegmentInSafeDsPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »privateSegmentInSafeDsPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »publicSegmentInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »internalSegmentInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »privateSegmentInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »publicSegmentWithoutPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »internalSegmentWithoutPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »privateSegmentWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/resource other package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/resource other package.sdstest index 02cd0f13..c1699e56 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/resource other package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/resource other package.sdstest @@ -1,16 +1,16 @@ package tests.scoping.references.acrossFiles.toSegments.other -// $TEST$ target other_mySegment +# $TEST$ target other_mySegment segment »mySegment«() {} -// $TEST$ target other_publicSegmentInAnotherPackage +# $TEST$ target other_publicSegmentInAnotherPackage segment »publicSegmentInAnotherPackage«() {} -// $TEST$ target other_public2SegmentInAnotherPackage +# $TEST$ target other_public2SegmentInAnotherPackage segment »public2SegmentInAnotherPackage«() {} -// $TEST$ target other_internalSegmentInAnotherPackage +# $TEST$ target other_internalSegmentInAnotherPackage internal segment »internalSegmentInAnotherPackage«() {} -// $TEST$ target other_privateSegmentInAnotherPackage +# $TEST$ target other_privateSegmentInAnotherPackage private segment »privateSegmentInAnotherPackage«() {} diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/resource safeds package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/resource safeds package.sdstest index 2f1e577e..0ebbd989 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/resource safeds package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/resource safeds package.sdstest @@ -1,13 +1,13 @@ package safeds.scoping.references.acrossFiles.toSegments -// $TEST$ target safeds_mySegment +# $TEST$ target safeds_mySegment segment »mySegment«() {} -// $TEST$ target safeds_publicSegmentInSafeDsPackage +# $TEST$ target safeds_publicSegmentInSafeDsPackage segment »publicSegmentInSafeDsPackage«() {} -// $TEST$ target safeds_internalSegmentInSafeDsPackage +# $TEST$ target safeds_internalSegmentInSafeDsPackage internal segment »internalSegmentInSafeDsPackage«() {} -// $TEST$ target safeds_privateSegmentInSafeDsPackage +# $TEST$ target safeds_privateSegmentInSafeDsPackage private segment »privateSegmentInSafeDsPackage«() {} diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/resource same package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/resource same package.sdstest index 9d1f66b4..a3ea3df3 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/resource same package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/resource same package.sdstest @@ -1,13 +1,13 @@ package tests.scoping.references.acrossFiles.toSegments -// $TEST$ target same_mySegment +# $TEST$ target same_mySegment segment »mySegment«() {} -// $TEST$ target same_publicSegmentInSamePackage +# $TEST$ target same_publicSegmentInSamePackage segment »publicSegmentInSamePackage«() {} -// $TEST$ target same_internalSegmentInSamePackage +# $TEST$ target same_internalSegmentInSamePackage internal segment »internalSegmentInSamePackage«() {} -// $TEST$ target same_privateSegmentInSamePackage +# $TEST$ target same_privateSegmentInSamePackage private segment »privateSegmentInSamePackage«() {} diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/resource without package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/resource without package.sdstest index 6c6e2ca6..de228f0d 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/resource without package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/resource without package.sdstest @@ -1,11 +1,11 @@ -// $TEST$ target without_mySegment +# $TEST$ target without_mySegment segment »mySegment«() {} -// $TEST$ target without_publicSegmentWithoutPackage +# $TEST$ target without_publicSegmentWithoutPackage segment »publicSegmentWithoutPackage«() {} -// $TEST$ target without_internalSegmentWithoutPackage +# $TEST$ target without_internalSegmentWithoutPackage internal segment »internalSegmentWithoutPackage«() {} -// $TEST$ target without_privateSegmentWithoutPackage +# $TEST$ target without_privateSegmentWithoutPackage private segment »privateSegmentWithoutPackage«() {} diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to annotations/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to annotations/main.sdstest index 1564119c..dbc3ba36 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to annotations/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to annotations/main.sdstest @@ -1,15 +1,15 @@ package tests.scoping.references.inSameFile.toAnnotations -// $TEST$ target before +# $TEST$ target before annotation »Before« segment mySegment() { - // $TEST$ references before + # $TEST$ references before »Before«; - // $TEST$ references after + # $TEST$ references after »After«; } -// $TEST$ target after +# $TEST$ target after annotation »After« diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to block lambda results/from outside/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to block lambda results/from outside/main.sdstest index 95875b7d..f7656821 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to block lambda results/from outside/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to block lambda results/from outside/main.sdstest @@ -5,6 +5,6 @@ pipeline myPipeline { yield myBlockLambdaResult = 1; }; - // $TEST$ unresolved + # $TEST$ unresolved »myBlockLambdaResult«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to block lambda results/of containing block lambda/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to block lambda results/of containing block lambda/main.sdstest index 4a06f68d..f154af03 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to block lambda results/of containing block lambda/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to block lambda results/of containing block lambda/main.sdstest @@ -3,7 +3,7 @@ package tests.scoping.references.inSameFile.toBlockLambdaResults.ofContainingBlo pipeline myPipeline { () { yield lambdaResult = 1; - // $TEST$ unresolved + # $TEST$ unresolved »lambdaResult«; }; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to class members/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to class members/main.sdstest index 373eceea..90e4f88a 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to class members/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to class members/main.sdstest @@ -13,21 +13,21 @@ class MyClass { } pipeline myPipeline { - // $TEST$ unresolved + # $TEST$ unresolved »staticAttribute«; - // $TEST$ unresolved + # $TEST$ unresolved »instanceAttribute«; - // $TEST$ unresolved + # $TEST$ unresolved »NestedClass«; - // $TEST$ unresolved + # $TEST$ unresolved »NestedEnum«; - // $TEST$ unresolved + # $TEST$ unresolved »staticMethod«; - // $TEST$ unresolved + # $TEST$ unresolved »instanceMethod«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to containing declarations/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to containing declarations/main.sdstest index daee4dd2..86bfd661 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to containing declarations/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to containing declarations/main.sdstest @@ -3,112 +3,112 @@ package tests.scoping.references.inSameFile.toContainingDeclarations @Repeatable annotation MyAnnotation(p: Any?) -// $TEST$ target outerClass +# $TEST$ target outerClass class »MyClass«( @MyAnnotation( - // $TEST$ references outerClass + # $TEST$ references outerClass p = »MyClass«() ) - // $TEST$ references outerClass + # $TEST$ references outerClass p: Any? = »MyClass«() ) { @MyAnnotation( - // $TEST$ references outerClass + # $TEST$ references outerClass p = »MyClass«() ) @MyAnnotation( - // $TEST$ unresolved + # $TEST$ unresolved p = »MyEnum« ) fun f( @MyAnnotation( - // $TEST$ references outerClass + # $TEST$ references outerClass p = »MyClass«() ) - // $TEST$ references outerClass + # $TEST$ references outerClass p1: Any? = »MyClass«(), @MyAnnotation( - // $TEST$ unresolved + # $TEST$ unresolved p = »MyEnum« ) - // $TEST$ unresolved + # $TEST$ unresolved p2: Any? = »MyEnum« ) @MyAnnotation( - // $TEST$ references outerClass + # $TEST$ references outerClass p = »MyClass«() ) @MyAnnotation( - // $TEST$ unresolved + # $TEST$ unresolved p = »MyEnum« ) - // $TEST$ target enum + # $TEST$ target enum enum »MyEnum« { - // $TEST$ target variant + # $TEST$ target variant »MyEnumVariant«( @MyAnnotation( - // $TEST$ references outerClass + # $TEST$ references outerClass p = »MyClass«() ) - // $TEST$ references outerClass + # $TEST$ references outerClass p1: Any? = »MyClass«(), @MyAnnotation( - // $TEST$ references enum + # $TEST$ references enum p = »MyEnum« ) - // $TEST$ references enum + # $TEST$ references enum p2: Any? = »MyEnum«, @MyAnnotation( - // $TEST$ references variant + # $TEST$ references variant p = »MyEnumVariant« ) - // $TEST$ references variant + # $TEST$ references variant p3: Any? = »MyEnumVariant«, ) } @MyAnnotation( - // $TEST$ references outerClass + # $TEST$ references outerClass p = »MyClass«() ) @MyAnnotation( - // $TEST$ unresolved + # $TEST$ unresolved p = »MyEnum« ) - // $TEST$ target innerClass + # $TEST$ target innerClass class »MyClass«( @MyAnnotation( - // $TEST$ references innerClass + # $TEST$ references innerClass p = »MyClass«() ) - // $TEST$ references innerClass + # $TEST$ references innerClass p1: Any? = »MyClass«(), @MyAnnotation( - // $TEST$ unresolved + # $TEST$ unresolved p = »MyEnum« ) - // $TEST$ unresolved + # $TEST$ unresolved p2: Any? = »MyEnum« ) { fun f( @MyAnnotation( - // $TEST$ references innerClass + # $TEST$ references innerClass p = »MyClass«() ) - // $TEST$ references innerClass + # $TEST$ references innerClass p1: Any? = »MyClass«(), @MyAnnotation( - // $TEST$ unresolved + # $TEST$ unresolved p = »MyEnum« ) - // $TEST$ unresolved + # $TEST$ unresolved p2: Any? = »MyEnum« ) } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to enum variants/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to enum variants/main.sdstest index 180d015c..bfe6cdcb 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to enum variants/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to enum variants/main.sdstest @@ -5,6 +5,6 @@ enum MyEnum { } pipeline myPipeline { - // $TEST$ unresolved + # $TEST$ unresolved »MyEnumVariant«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to global classes/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to global classes/main.sdstest index 0085cf6c..8d3fefae 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to global classes/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to global classes/main.sdstest @@ -1,15 +1,15 @@ package tests.scoping.references.inSameFile.toGlobalClasses -// $TEST$ target before +# $TEST$ target before class »Before«() pipeline myPipeline { - // $TEST$ references before + # $TEST$ references before »Before«; - // $TEST$ references after + # $TEST$ references after »After«; } -// $TEST$ target after +# $TEST$ target after class »After«() diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to global enums/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to global enums/main.sdstest index 9ec1275a..a70096c7 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to global enums/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to global enums/main.sdstest @@ -1,15 +1,15 @@ package tests.scoping.references.inSameFile.toGlobalEnums -// $TEST$ target before +# $TEST$ target before enum »Before« pipeline myPipeline { - // $TEST$ references before + # $TEST$ references before »Before«(); - // $TEST$ references after + # $TEST$ references after »After«(); } -// $TEST$ target after +# $TEST$ target after enum »After« diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to global functions/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to global functions/main.sdstest index 7f07163a..eb08a324 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to global functions/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to global functions/main.sdstest @@ -1,15 +1,15 @@ package tests.scoping.references.inSameFile.toGlobalFunctions -// $TEST$ target before +# $TEST$ target before fun »before«() pipeline myPipeline { - // $TEST$ references before + # $TEST$ references before »before«(); - // $TEST$ references after + # $TEST$ references after »after«(); } -// $TEST$ target after +# $TEST$ target after fun »after«() diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to modules/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to modules/main.sdstest index 2904f0e2..da5ea19e 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to modules/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to modules/main.sdstest @@ -1,6 +1,6 @@ package tests pipeline myPipeline { - // $TEST$ unresolved + # $TEST$ unresolved »tests«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/from default value of parameter/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/from default value of parameter/main.sdstest index bdd2e7af..3b48e359 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/from default value of parameter/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/from default value of parameter/main.sdstest @@ -1,84 +1,84 @@ package tests.scoping.references.inSameFile.toParameters.fromDefaultValueOfParameter annotation MyAnnotation( - // $TEST$ target annotation_param - // $TEST$ unresolved + # $TEST$ target annotation_param + # $TEST$ unresolved »p«: String = »q«, - // $TEST$ references annotation_param + # $TEST$ references annotation_param q: String = »p«, - // $TEST$ unresolved + # $TEST$ unresolved r: String = »r«, ) class MyClass( - // $TEST$ target class_param - // $TEST$ unresolved + # $TEST$ target class_param + # $TEST$ unresolved »p«: String = »q«, - // $TEST$ references class_param + # $TEST$ references class_param q: String = »p«, - // $TEST$ unresolved + # $TEST$ unresolved r: String = »r«, ) enum MyEnum { MyEnumVariant( - // $TEST$ target enum_variant_param - // $TEST$ unresolved + # $TEST$ target enum_variant_param + # $TEST$ unresolved »p«: String = »q«, - // $TEST$ references enum_variant_param + # $TEST$ references enum_variant_param q: String = »p«, - // $TEST$ unresolved + # $TEST$ unresolved r: String = »r«, ) } fun myFunction( - // $TEST$ target function_param - // $TEST$ unresolved + # $TEST$ target function_param + # $TEST$ unresolved »p«: String = »q«, - // $TEST$ references function_param + # $TEST$ references function_param q: String = »p«, - // $TEST$ unresolved + # $TEST$ unresolved r: String = »r«, ) segment mySegment1( - // $TEST$ target segment_param - // $TEST$ unresolved + # $TEST$ target segment_param + # $TEST$ unresolved »p«: String = »q«, - // $TEST$ references segment_param + # $TEST$ references segment_param q: String = »p«, - // $TEST$ unresolved + # $TEST$ unresolved r: String = »r«, ) {} segment mySegment2( p: ( - // $TEST$ target callable_type_param - // $TEST$ unresolved + # $TEST$ target callable_type_param + # $TEST$ unresolved »p«: String = »q«, - // $TEST$ references callable_type_param + # $TEST$ references callable_type_param q: String = »p«, - // $TEST$ unresolved + # $TEST$ unresolved r: String = »r«, ) -> () ) { ( - // $TEST$ target block_lambda_param - // $TEST$ unresolved + # $TEST$ target block_lambda_param + # $TEST$ unresolved »p«: String = »q«, - // $TEST$ references block_lambda_param + # $TEST$ references block_lambda_param q: String = »p«, - // $TEST$ unresolved + # $TEST$ unresolved r: String = »r«, ) {}; ( - // $TEST$ target block_function_param - // $TEST$ unresolved + # $TEST$ target block_function_param + # $TEST$ unresolved »p«: String = »q«, - // $TEST$ references block_function_param + # $TEST$ references block_function_param q: String = »p«, - // $TEST$ unresolved + # $TEST$ unresolved r: String = »r«, ) -> 1; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/from outside/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/from outside/main.sdstest index d923ca8e..6af77d45 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/from outside/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/from outside/main.sdstest @@ -18,27 +18,27 @@ segment mySegment2( (myBlockLambdaParameter) {}; (myExpressionLambdaParameter) -> 1; - // $TEST$ unresolved + # $TEST$ unresolved »myAnnotationParameter«; - // $TEST$ unresolved + # $TEST$ unresolved »myClassParameter«; - // $TEST$ unresolved + # $TEST$ unresolved »myEnumVariantParameter«; - // $TEST$ unresolved + # $TEST$ unresolved »myFunctionParameter«; - // $TEST$ unresolved + # $TEST$ unresolved »mySegmentParameter«; - // $TEST$ unresolved + # $TEST$ unresolved »myCallableTypeParameter«; - // $TEST$ unresolved + # $TEST$ unresolved »myBlockLambdaParameter«; - // $TEST$ unresolved + # $TEST$ unresolved »myExpressionLambdaParameter«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/from parameter bound/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/from parameter bound/main.sdstest index dfd795e3..3948dc6e 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/from parameter bound/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/from parameter bound/main.sdstest @@ -1,39 +1,39 @@ package tests.scoping.references.inSameFile.toParameters.fromParameterBound -// $TEST$ target annotation_p +# $TEST$ target annotation_p annotation MyAnnotation(»p«: Int) where { - // $TEST$ references annotation_p + # $TEST$ references annotation_p p < »p«, - // $TEST$ unresolved + # $TEST$ unresolved p > »unresolved«, } -// $TEST$ target class_p +# $TEST$ target class_p class MyClass(»p«: Int) where { - // $TEST$ references class_p + # $TEST$ references class_p p < »p«, - // $TEST$ unresolved + # $TEST$ unresolved p > »unresolved«, } -// $TEST$ target enumVariant_p +# $TEST$ target enumVariant_p enum MyEnum { MyEnumVariant(»p«: Int) where { - // $TEST$ references enumVariant_p + # $TEST$ references enumVariant_p p < »p«, - // $TEST$ unresolved + # $TEST$ unresolved p > »unresolved«, } } -// $TEST$ target function_p +# $TEST$ target function_p fun myFunction(»p«: Int) where { - // $TEST$ references function_p + # $TEST$ references function_p p < »p«, - // $TEST$ unresolved + # $TEST$ unresolved p > »unresolved«, } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/of containing block lambda/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/of containing block lambda/main.sdstest index 5ca399e9..e6ee997b 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/of containing block lambda/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/of containing block lambda/main.sdstest @@ -4,75 +4,75 @@ segment mySegment(myShadowedSegmentParameter: Int) { val myShadowedPlaceholder = 0; ( - // $TEST$ target outer_myOuterBlockLambdaParameter + # $TEST$ target outer_myOuterBlockLambdaParameter »myOuterBlockLambdaParameter«, - // $TEST$ target outer_myShadowedSegmentParameter + # $TEST$ target outer_myShadowedSegmentParameter »myShadowedSegmentParameter«, - // $TEST$ target outer_myShadowedBlockLambdaParameter + # $TEST$ target outer_myShadowedBlockLambdaParameter »myShadowedBlockLambdaParameter«, - // $TEST$ target outer_myShadowedPlaceholder + # $TEST$ target outer_myShadowedPlaceholder »myShadowedPlaceholder«, - // $TEST$ target redeclaredAsParameter + # $TEST$ target redeclaredAsParameter »redeclaredAsParameter«, redeclaredAsParameter, - // $TEST$ target redeclaredAsPlaceholder + # $TEST$ target redeclaredAsPlaceholder »redeclaredAsPlaceholder«, ) { val redeclaredAsPlaceholder = 0; - // $TEST$ references outer_myOuterBlockLambdaParameter + # $TEST$ references outer_myOuterBlockLambdaParameter »myOuterBlockLambdaParameter«; - // $TEST$ references outer_myShadowedSegmentParameter + # $TEST$ references outer_myShadowedSegmentParameter »myShadowedSegmentParameter«; - // $TEST$ references outer_myShadowedBlockLambdaParameter + # $TEST$ references outer_myShadowedBlockLambdaParameter »myShadowedBlockLambdaParameter«; - // $TEST$ references outer_myShadowedPlaceholder + # $TEST$ references outer_myShadowedPlaceholder »myShadowedPlaceholder«; - // $TEST$ references redeclaredAsParameter + # $TEST$ references redeclaredAsParameter »redeclaredAsParameter«; - // $TEST$ references redeclaredAsPlaceholder + # $TEST$ references redeclaredAsPlaceholder »redeclaredAsPlaceholder«; - // $TEST$ unresolved + # $TEST$ unresolved »myInnerBlockLambdaParameter«; ( - // $TEST$ target inner_myInnerBlockLambdaParameter + # $TEST$ target inner_myInnerBlockLambdaParameter »myInnerBlockLambdaParameter«, - // $TEST$ target inner_myShadowedBlockLambdaParameter + # $TEST$ target inner_myShadowedBlockLambdaParameter »myShadowedBlockLambdaParameter« ) { () -> - // $TEST$ references outer_myOuterBlockLambdaParameter + # $TEST$ references outer_myOuterBlockLambdaParameter »myOuterBlockLambdaParameter« + - // $TEST$ references outer_myShadowedSegmentParameter + # $TEST$ references outer_myShadowedSegmentParameter »myShadowedSegmentParameter« + - // $TEST$ references inner_myShadowedBlockLambdaParameter + # $TEST$ references inner_myShadowedBlockLambdaParameter »myShadowedBlockLambdaParameter«; - // $TEST$ references outer_myShadowedPlaceholder + # $TEST$ references outer_myShadowedPlaceholder »myShadowedPlaceholder« + - // $TEST$ references redeclaredAsParameter + # $TEST$ references redeclaredAsParameter »redeclaredAsParameter« + - // $TEST$ references redeclaredAsPlaceholder + # $TEST$ references redeclaredAsPlaceholder »redeclaredAsPlaceholder« + - // $TEST$ references inner_myInnerBlockLambdaParameter + # $TEST$ references inner_myInnerBlockLambdaParameter »myInnerBlockLambdaParameter«; }; diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/of containing expression lambda/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/of containing expression lambda/main.sdstest index 1f5fd6cc..fc2a78fb 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/of containing expression lambda/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/of containing expression lambda/main.sdstest @@ -4,64 +4,64 @@ segment mySegment(myShadowedSegmentParameter: Int) { val myShadowedPlaceholder = 0; ( - // $TEST$ target outer_myOuterExpressionLambdaParameter + # $TEST$ target outer_myOuterExpressionLambdaParameter »myOuterExpressionLambdaParameter«, - // $TEST$ target outer_myShadowedSegmentParameter + # $TEST$ target outer_myShadowedSegmentParameter »myShadowedSegmentParameter«, - // $TEST$ target outer_myShadowedExpressionLambdaParameter + # $TEST$ target outer_myShadowedExpressionLambdaParameter »myShadowedExpressionLambdaParameter«, - // $TEST$ target outer_myShadowedPlaceholder + # $TEST$ target outer_myShadowedPlaceholder »myShadowedPlaceholder«, - // $TEST$ target outer_redeclaredAsParameter + # $TEST$ target outer_redeclaredAsParameter »redeclaredAsParameter«, redeclaredAsParameter ) -> - // $TEST$ references outer_myOuterExpressionLambdaParameter + # $TEST$ references outer_myOuterExpressionLambdaParameter »myOuterExpressionLambdaParameter« + - // $TEST$ references outer_myShadowedSegmentParameter + # $TEST$ references outer_myShadowedSegmentParameter »myShadowedSegmentParameter« + - // $TEST$ references outer_myShadowedPlaceholder + # $TEST$ references outer_myShadowedPlaceholder »myShadowedPlaceholder« + - // $TEST$ references outer_redeclaredAsParameter + # $TEST$ references outer_redeclaredAsParameter »redeclaredAsParameter« + - // $TEST$ unresolved + # $TEST$ unresolved »myInnerExpressionLambdaParameter« + - // $TEST$ references outer_myShadowedExpressionLambdaParameter + # $TEST$ references outer_myShadowedExpressionLambdaParameter »myShadowedExpressionLambdaParameter« + (( - // $TEST$ target inner_myInnerExpressionLambdaParameter + # $TEST$ target inner_myInnerExpressionLambdaParameter »myInnerExpressionLambdaParameter«, - // $TEST$ target inner_myShadowedExpressionLambdaParameter + # $TEST$ target inner_myShadowedExpressionLambdaParameter »myShadowedExpressionLambdaParameter«, ) -> () { - // $TEST$ references outer_myOuterExpressionLambdaParameter + # $TEST$ references outer_myOuterExpressionLambdaParameter »myOuterExpressionLambdaParameter«; - // $TEST$ references outer_myShadowedSegmentParameter + # $TEST$ references outer_myShadowedSegmentParameter »myShadowedSegmentParameter«; - // $TEST$ references outer_myShadowedPlaceholder + # $TEST$ references outer_myShadowedPlaceholder »myShadowedPlaceholder«; - // $TEST$ references outer_redeclaredAsParameter + # $TEST$ references outer_redeclaredAsParameter »redeclaredAsParameter«; - // $TEST$ references inner_myInnerExpressionLambdaParameter + # $TEST$ references inner_myInnerExpressionLambdaParameter »myInnerExpressionLambdaParameter«; - // $TEST$ references inner_myShadowedExpressionLambdaParameter + # $TEST$ references inner_myShadowedExpressionLambdaParameter »myShadowedExpressionLambdaParameter«; } ) diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/of containing segment/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/of containing segment/main.sdstest index 6d0766b7..cfba356d 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/of containing segment/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/of containing segment/main.sdstest @@ -1,45 +1,45 @@ package tests.scoping.references.inSameFile.toParameters.ofContainingExpressionLambda segment mySegment( - // $TEST$ target parameter + # $TEST$ target parameter »myParameter«: Int, - // $TEST$ target redeclaredAsParameter + # $TEST$ target redeclaredAsParameter »redeclaredAsParameter«: Int, redeclaredAsParameter: Int, - // $TEST$ target redeclaredAsPlaceholder + # $TEST$ target redeclaredAsPlaceholder »redeclaredAsPlaceholder«: Int ) { val redeclaredAsPlaceholder = 0; - // $TEST$ references parameter + # $TEST$ references parameter »myParameter«; - // $TEST$ references redeclaredAsParameter + # $TEST$ references redeclaredAsParameter »redeclaredAsParameter«; - // $TEST$ references redeclaredAsPlaceholder + # $TEST$ references redeclaredAsPlaceholder »redeclaredAsPlaceholder«; () { - // $TEST$ references parameter + # $TEST$ references parameter »myParameter«; - // $TEST$ references redeclaredAsParameter + # $TEST$ references redeclaredAsParameter »redeclaredAsParameter«; - // $TEST$ references redeclaredAsPlaceholder + # $TEST$ references redeclaredAsPlaceholder »redeclaredAsPlaceholder«; }; () -> - // $TEST$ references parameter + # $TEST$ references parameter »myParameter« + - // $TEST$ references redeclaredAsParameter + # $TEST$ references redeclaredAsParameter »redeclaredAsParameter« + - // $TEST$ references redeclaredAsPlaceholder + # $TEST$ references redeclaredAsPlaceholder »redeclaredAsPlaceholder«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to pipelines/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to pipelines/main.sdstest index 6a0fe7a3..9ad61ad5 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to pipelines/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to pipelines/main.sdstest @@ -1,15 +1,15 @@ package tests.scoping.references.inSameFile.toPipelines -// $TEST$ target before +# $TEST$ target before pipeline »before« {} segment mySegment() { - // $TEST$ references before + # $TEST$ references before »before«; - // $TEST$ references after + # $TEST$ references after »after«; } -// $TEST$ target after +# $TEST$ target after pipeline »after« {} diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to placeholders/from outside/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to placeholders/from outside/main.sdstest index 6c0aa54d..54858704 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to placeholders/from outside/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to placeholders/from outside/main.sdstest @@ -13,12 +13,12 @@ pipeline myPipeline2 { val blockLambdaPlaceholder = 1; }; - // $TEST$ unresolved + # $TEST$ unresolved »pipelinePlaceholder«; - // $TEST$ unresolved + # $TEST$ unresolved »segmentPlaceholder«; - // $TEST$ unresolved + # $TEST$ unresolved »blockLambdaPlaceholder«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to placeholders/of containing block lambda/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to placeholders/of containing block lambda/main.sdstest index 434bf178..3fe2022c 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to placeholders/of containing block lambda/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to placeholders/of containing block lambda/main.sdstest @@ -4,123 +4,123 @@ segment mySegment(mySegmentParameter: Int) { val mySegmentPlaceholder = 0; (myOuterBlockLambdaParameter) { - // $TEST$ target outer_mySegmentParameter + # $TEST$ target outer_mySegmentParameter val »mySegmentParameter« = 0; - // $TEST$ target outer_mySegmentPlaceholder + # $TEST$ target outer_mySegmentPlaceholder val »mySegmentPlaceholder« = 0; - // $TEST$ target outer_myOuterBlockLambdaPlaceholderBefore + # $TEST$ target outer_myOuterBlockLambdaPlaceholderBefore val »myOuterBlockLambdaPlaceholderBefore« = 0; - // $TEST$ target outer_redeclared + # $TEST$ target outer_redeclared val »redeclared« = 0; val redeclared = 0; - // $TEST$ references outer_mySegmentParameter + # $TEST$ references outer_mySegmentParameter »mySegmentParameter«; - // $TEST$ references outer_mySegmentPlaceholder + # $TEST$ references outer_mySegmentPlaceholder »mySegmentPlaceholder«; - // $TEST$ references outer_myOuterBlockLambdaPlaceholderBefore + # $TEST$ references outer_myOuterBlockLambdaPlaceholderBefore »myOuterBlockLambdaPlaceholderBefore«; - // $TEST$ references outer_redeclared + # $TEST$ references outer_redeclared »redeclared«; - // $TEST$ unresolved + # $TEST$ unresolved »myOuterBlockLambdaPlaceholderAfter«; val blockLambda = () { - // $TEST$ target inner_mySegmentParameter + # $TEST$ target inner_mySegmentParameter val »mySegmentParameter« = 0; - // $TEST$ target inner_mySegmentPlaceholder + # $TEST$ target inner_mySegmentPlaceholder val »mySegmentPlaceholder« = 0; - // $TEST$ target inner_myOuterBlockLambdaParameter + # $TEST$ target inner_myOuterBlockLambdaParameter val »myOuterBlockLambdaParameter« = 0; - // $TEST$ target inner_myOuterBlockLambdaPlaceholderBefore + # $TEST$ target inner_myOuterBlockLambdaPlaceholderBefore val »myOuterBlockLambdaPlaceholderBefore« = 0; - // $TEST$ references inner_mySegmentParameter + # $TEST$ references inner_mySegmentParameter »mySegmentParameter«; - // $TEST$ references inner_mySegmentPlaceholder + # $TEST$ references inner_mySegmentPlaceholder »mySegmentPlaceholder«; - // $TEST$ references inner_myOuterBlockLambdaParameter + # $TEST$ references inner_myOuterBlockLambdaParameter »myOuterBlockLambdaParameter«; - // $TEST$ references inner_myOuterBlockLambdaPlaceholderBefore + # $TEST$ references inner_myOuterBlockLambdaPlaceholderBefore »myOuterBlockLambdaPlaceholderBefore«; - // $TEST$ references outer_redeclared + # $TEST$ references outer_redeclared »redeclared«; - // $TEST$ unresolved + # $TEST$ unresolved »blockLambda«; - // $TEST$ unresolved + # $TEST$ unresolved »myOuterBlockLambdaPlaceholderAfter«; val expressionLambda = () -> - // $TEST$ references inner_mySegmentParameter + # $TEST$ references inner_mySegmentParameter »mySegmentParameter« + - // $TEST$ references inner_mySegmentPlaceholder + # $TEST$ references inner_mySegmentPlaceholder »mySegmentPlaceholder« + - // $TEST$ references inner_myOuterBlockLambdaParameter + # $TEST$ references inner_myOuterBlockLambdaParameter »myOuterBlockLambdaParameter« + - // $TEST$ references inner_myOuterBlockLambdaPlaceholderBefore + # $TEST$ references inner_myOuterBlockLambdaPlaceholderBefore »myOuterBlockLambdaPlaceholderBefore« + - // $TEST$ references outer_redeclared + # $TEST$ references outer_redeclared »redeclared« + - // $TEST$ unresolved + # $TEST$ unresolved »blockLambda« + - // $TEST$ unresolved + # $TEST$ unresolved »expressionLambda« + - // $TEST$ unresolved + # $TEST$ unresolved »myOuterBlockLambdaPlaceholderAfter«; }; () -> () { - // $TEST$ target blockLambdaInExpressionLambda_mySegmentParameter + # $TEST$ target blockLambdaInExpressionLambda_mySegmentParameter val »mySegmentParameter« = 0; - // $TEST$ target blockLambdaInExpressionLambda_mySegmentPlaceholder + # $TEST$ target blockLambdaInExpressionLambda_mySegmentPlaceholder val »mySegmentPlaceholder« = 0; - // $TEST$ target blockLambdaInExpressionLambda_myOuterBlockLambdaParameter + # $TEST$ target blockLambdaInExpressionLambda_myOuterBlockLambdaParameter val »myOuterBlockLambdaParameter« = 0; - // $TEST$ target blockLambdaInExpressionLambda_myOuterBlockLambdaPlaceholderBefore + # $TEST$ target blockLambdaInExpressionLambda_myOuterBlockLambdaPlaceholderBefore val »myOuterBlockLambdaPlaceholderBefore« = 0; - // $TEST$ references blockLambdaInExpressionLambda_mySegmentParameter + # $TEST$ references blockLambdaInExpressionLambda_mySegmentParameter »mySegmentParameter«; - // $TEST$ references blockLambdaInExpressionLambda_mySegmentPlaceholder + # $TEST$ references blockLambdaInExpressionLambda_mySegmentPlaceholder »mySegmentPlaceholder«; - // $TEST$ references blockLambdaInExpressionLambda_myOuterBlockLambdaPlaceholderBefore + # $TEST$ references blockLambdaInExpressionLambda_myOuterBlockLambdaPlaceholderBefore »myOuterBlockLambdaPlaceholderBefore«; - // $TEST$ references outer_redeclared + # $TEST$ references outer_redeclared »redeclared«; - // $TEST$ unresolved + # $TEST$ unresolved »myOuterBlockLambdaPlaceholderAfter«; }; diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to placeholders/of containing pipeline/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to placeholders/of containing pipeline/main.sdstest index 48ceac04..8baecf46 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to placeholders/of containing pipeline/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to placeholders/of containing pipeline/main.sdstest @@ -1,61 +1,61 @@ package tests.scoping.references.inSameFile.toPlaceholders.ofContainingPipeline pipeline myPipeline { - // $TEST$ target before + # $TEST$ target before val »before« = 0; - // $TEST$ target redeclared + # $TEST$ target redeclared val »redeclared« = 0; val redeclared = 0; - // $TEST$ references before + # $TEST$ references before »before«; - // $TEST$ references redeclared + # $TEST$ references redeclared »redeclared«; - // $TEST$ unresolved + # $TEST$ unresolved »after«; val blockLambda = () { - // $TEST$ references before + # $TEST$ references before »before«; - // $TEST$ references redeclared + # $TEST$ references redeclared »redeclared«; - // $TEST$ unresolved + # $TEST$ unresolved »blockLambda«; - // $TEST$ unresolved + # $TEST$ unresolved »after«; () { - // $TEST$ references before + # $TEST$ references before »before«; - // $TEST$ references redeclared + # $TEST$ references redeclared »redeclared«; - // $TEST$ unresolved + # $TEST$ unresolved »blockLambda«; - // $TEST$ unresolved + # $TEST$ unresolved »after«; }; }; val expressionLambda = () -> - // $TEST$ references before + # $TEST$ references before »before« + - // $TEST$ references redeclared + # $TEST$ references redeclared »redeclared« + - // $TEST$ unresolved + # $TEST$ unresolved »expressionLambda« + - // $TEST$ unresolved + # $TEST$ unresolved »after«; val after = 1; diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to placeholders/of containing segment/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to placeholders/of containing segment/main.sdstest index 4105498b..9f9e467c 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to placeholders/of containing segment/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to placeholders/of containing segment/main.sdstest @@ -1,61 +1,61 @@ package tests.scoping.references.inSameFile.toPlaceholders.ofContainingSegment segment mySegment() { - // $TEST$ target before + # $TEST$ target before val »before« = 0; - // $TEST$ target redeclared + # $TEST$ target redeclared val »redeclared« = 0; val redeclared = 0; - // $TEST$ references before + # $TEST$ references before »before«; - // $TEST$ references redeclared + # $TEST$ references redeclared »redeclared«; - // $TEST$ unresolved + # $TEST$ unresolved »after«; val blockLambda = () { - // $TEST$ references before + # $TEST$ references before »before«; - // $TEST$ references redeclared + # $TEST$ references redeclared »redeclared«; - // $TEST$ unresolved + # $TEST$ unresolved »blockLambda«; - // $TEST$ unresolved + # $TEST$ unresolved »after«; () { - // $TEST$ references before + # $TEST$ references before »before«; - // $TEST$ references redeclared + # $TEST$ references redeclared »redeclared«; - // $TEST$ unresolved + # $TEST$ unresolved »blockLambda«; - // $TEST$ unresolved + # $TEST$ unresolved »after«; }; }; val expressionLambda = () -> - // $TEST$ references before + # $TEST$ references before »before« + - // $TEST$ references redeclared + # $TEST$ references redeclared »redeclared« + - // $TEST$ unresolved + # $TEST$ unresolved »expressionLambda« + - // $TEST$ unresolved + # $TEST$ unresolved »after«; val after = 1; diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to redeclared module member/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to redeclared module member/main.sdstest index 55939d2f..5594298f 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to redeclared module member/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to redeclared module member/main.sdstest @@ -1,19 +1,19 @@ package tests.scoping.references.inSameFile.toRedeclaredModuleMember -// $TEST$ target before +# $TEST$ target before class »Before« class Before segment mySegment() { - // $TEST$ references before + # $TEST$ references before »Before«; - // $TEST$ references after + # $TEST$ references after »after«; } -// $TEST$ target after +# $TEST$ target after fun »after«() fun after() diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to results/from outside/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to results/from outside/main.sdstest index 4943e09c..686d9132 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to results/from outside/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to results/from outside/main.sdstest @@ -7,12 +7,12 @@ segment mySegment1() -> (mySegmentResult: String) {} segment mySegment2( p: () -> (myCallableTypeResult: String) ) { - // $TEST$ unresolved + # $TEST$ unresolved »myFunctionResult«; - // $TEST$ unresolved + # $TEST$ unresolved »mySegmentResult«; - // $TEST$ unresolved + # $TEST$ unresolved »myCallableTypeResult«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to results/of containing segment/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to results/of containing segment/main.sdstest index e0727091..7f000da8 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to results/of containing segment/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to results/of containing segment/main.sdstest @@ -1,6 +1,6 @@ package tests.scoping.references.inSameFile.toResults.ofContainingSegment segment mySegment() -> myResult: Int { - // $TEST$ unresolved + # $TEST$ unresolved »myResult«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to schemas/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to schemas/main.sdstest index a3832361..1b2ecb43 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to schemas/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to schemas/main.sdstest @@ -1,15 +1,15 @@ package tests.scoping.references.inSameFile.toSchemas -// $TEST$ target before +# $TEST$ target before schema »Before« {} segment mySegment() { - // $TEST$ references before + # $TEST$ references before »Before«; - // $TEST$ references after + # $TEST$ references after »After«; } -// $TEST$ target after +# $TEST$ target after schema »After« {} diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to segments/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to segments/main.sdstest index 6223ba59..10ce68d0 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to segments/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to segments/main.sdstest @@ -1,32 +1,32 @@ package tests.scoping.references.inSameFile.toSegments -// $TEST$ target privateBefore +# $TEST$ target privateBefore private segment »privateBefore«() {} -// $TEST$ target internalBefore +# $TEST$ target internalBefore internal segment »internalBefore«() {} -// $TEST$ target publicBefore +# $TEST$ target publicBefore segment »publicBefore«() {} pipeline myPipeline { - // $TEST$ references privateBefore + # $TEST$ references privateBefore »privateBefore«(); - // $TEST$ references internalBefore + # $TEST$ references internalBefore »internalBefore«(); - // $TEST$ references publicBefore + # $TEST$ references publicBefore »publicBefore«(); - // $TEST$ references privateAfter + # $TEST$ references privateAfter »privateAfter«(); - // $TEST$ references internalAfter + # $TEST$ references internalAfter »internalAfter«(); } -// $TEST$ target privateAfter +# $TEST$ target privateAfter private segment »privateAfter«() {} -// $TEST$ target internalAfter +# $TEST$ target internalAfter internal segment »internalAfter«() {} -// $TEST$ target publicAfter +# $TEST$ target publicAfter segment »publicAfter«() {} diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to type parameters/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to type parameters/main.sdstest index 8416c939..ce3c2a4a 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to type parameters/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to type parameters/main.sdstest @@ -3,6 +3,6 @@ package tests.scoping.references.inSameFile.toTypeParameters class MyClass() pipeline myPipeline { - // $TEST$ unresolved + # $TEST$ unresolved »T«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/unresolved/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/unresolved/main.sdstest index 6bb2abd3..98e4389d 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/unresolved/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/unresolved/main.sdstest @@ -1,6 +1,6 @@ package tests.scoping.references.unresolved segment mySegment() { - // $TEST$ unresolved + # $TEST$ unresolved »unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/type arguments/to something other than type parameter/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/type arguments/to something other than type parameter/main.sdstest index d0006b66..1b8a3ca3 100644 --- a/packages/ttsl-lang/tests/resources/scoping/type arguments/to something other than type parameter/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/type arguments/to something other than type parameter/main.sdstest @@ -1,6 +1,6 @@ package tests.scoping.typeArguments.toSomethingOtherThanTypeParameter -// $TEST$ unresolved +# $TEST$ unresolved segment mySegment(p: MyClass<»notAtypeParameter« = Int>) {} class MyClass diff --git a/packages/ttsl-lang/tests/resources/scoping/type arguments/to type parameter in containing named type declaration/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/type arguments/to type parameter in containing named type declaration/main.sdstest index fa3253f8..74f47b34 100644 --- a/packages/ttsl-lang/tests/resources/scoping/type arguments/to type parameter in containing named type declaration/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/type arguments/to type parameter in containing named type declaration/main.sdstest @@ -1,45 +1,45 @@ package tests.scoping.typeArguments.toTypeParameterInContainingNamedTypeDeclaration -// $TEST$ target outerClass +# $TEST$ target outerClass class MyClass<»T«>( - // $TEST$ references outerClass + # $TEST$ references outerClass p: MyClass<»T« = Int>, -// $TEST$ references outerClass +# $TEST$ references outerClass ) sub MyClass<»T« = Int> { - // $TEST$ references outerClass + # $TEST$ references outerClass attr a: MyClass<»T« = Int> fun f( - // $TEST$ references outerClass + # $TEST$ references outerClass p: MyClass<»T« = Int>, ) -> ( - // $TEST$ references outerClass + # $TEST$ references outerClass r: MyClass<»T« = Int>, ) enum MyEnum { MyEnumVariant( - // $TEST$ references outerClass + # $TEST$ references outerClass p: MyClass<»T« = Int>, ) } - // $TEST$ target innerClass + # $TEST$ target innerClass class MyClass<»T«>( - // $TEST$ references innerClass + # $TEST$ references innerClass p: MyClass<»T« = Int>, - // $TEST$ references innerClass + # $TEST$ references innerClass ) sub MyClass<»T« = Int> { - // $TEST$ references innerClass + # $TEST$ references innerClass attr a: MyClass<»T« = Int> fun f( - // $TEST$ references innerClass + # $TEST$ references innerClass p: MyClass<»T« = Int>, ) -> ( - // $TEST$ references innerClass + # $TEST$ references innerClass r: MyClass<»T« = Int>, ) } diff --git a/packages/ttsl-lang/tests/resources/scoping/type arguments/to type parameter in global class/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/type arguments/to type parameter in global class/main.sdstest index 5ac02bf5..8142d6d2 100644 --- a/packages/ttsl-lang/tests/resources/scoping/type arguments/to type parameter in global class/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/type arguments/to type parameter in global class/main.sdstest @@ -1,9 +1,9 @@ package tests.scoping.typeArguments.toTypeParameterInGlobalClass -// $TEST$ target t +# $TEST$ target t class MyClass<»T«> segment mySegment( - // $TEST$ references t + # $TEST$ references t p: MyClass<»T« = Int> ) {} diff --git a/packages/ttsl-lang/tests/resources/scoping/type arguments/to type parameter in nested class/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/type arguments/to type parameter in nested class/main.sdstest index 5f02c2b8..1a8674b2 100644 --- a/packages/ttsl-lang/tests/resources/scoping/type arguments/to type parameter in nested class/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/type arguments/to type parameter in nested class/main.sdstest @@ -1,11 +1,11 @@ package tests.scoping.typeArguments.toTypeParameterInNestedClass class MyClass { - // $TEST$ target t + # $TEST$ target t class MyNestedClass<»T«> } segment mySegment( - // $TEST$ references t + # $TEST$ references t p: MyClass.MyNestedClass<»T« = Int> ) {} diff --git a/packages/ttsl-lang/tests/resources/scoping/type arguments/to unresolved/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/type arguments/to unresolved/main.sdstest index 808373e7..b8bf729e 100644 --- a/packages/ttsl-lang/tests/resources/scoping/type arguments/to unresolved/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/type arguments/to unresolved/main.sdstest @@ -1,10 +1,10 @@ package tests.scoping.typeArguments.toUnresolved segment mySegment( - // $TEST$ unresolved + # $TEST$ unresolved p1: MyClass<»unresolved« = Int>, - // $TEST$ unresolved + # $TEST$ unresolved p2: unresolved<»T« = Int>, ) {} diff --git a/packages/ttsl-lang/tests/resources/scoping/yields/in pipeline/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/yields/in pipeline/main.sdstest index c43abe9d..cb5357e1 100644 --- a/packages/ttsl-lang/tests/resources/scoping/yields/in pipeline/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/yields/in pipeline/main.sdstest @@ -3,16 +3,16 @@ package tests.scoping.yields.inPipeline segment mySegment1() -> before: Int {} pipeline myPipeline { - // $TEST$ unresolved + # $TEST$ unresolved yield »before« = 1; - // $TEST$ unresolved + # $TEST$ unresolved yield »after« = 1; - // $TEST$ unresolved + # $TEST$ unresolved yield »NotAResult« = 1; - // $TEST$ unresolved + # $TEST$ unresolved yield »unresolved« = 1; } diff --git a/packages/ttsl-lang/tests/resources/scoping/yields/in segment/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/yields/in segment/main.sdstest index 56b29de9..655a7b32 100644 --- a/packages/ttsl-lang/tests/resources/scoping/yields/in segment/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/yields/in segment/main.sdstest @@ -3,29 +3,29 @@ package tests.scoping.yields.inSegment segment mySegment1() -> before: Int {} segment mySegment() -> ( - // $TEST$ target result + # $TEST$ target result »result«: Int, - // $TEST$ target redeclared + # $TEST$ target redeclared »redeclared«: Int, redeclared: Int, ) { - // $TEST$ references result + # $TEST$ references result yield »result« = 1; - // $TEST$ references redeclared + # $TEST$ references redeclared yield »redeclared« = 1; - // $TEST$ unresolved + # $TEST$ unresolved yield »before« = 1; - // $TEST$ unresolved + # $TEST$ unresolved yield »after« = 1; - // $TEST$ unresolved + # $TEST$ unresolved yield »NotAResult« = 1; - // $TEST$ unresolved + # $TEST$ unresolved yield »unresolved« = 1; } diff --git a/packages/ttsl-lang/tests/resources/typing/assignees/block lambda results/main.sdstest b/packages/ttsl-lang/tests/resources/typing/assignees/block lambda results/main.sdstest index a6f46d81..28fc7cc7 100644 --- a/packages/ttsl-lang/tests/resources/typing/assignees/block lambda results/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/assignees/block lambda results/main.sdstest @@ -4,20 +4,20 @@ fun f() -> (r1: Int, r2: Float, r3: String) segment mySegment() -> (r: Int) { () { - // $TEST$ equivalence_class assignedValue - // $TEST$ equivalence_class assignedValue + # $TEST$ equivalence_class assignedValue + # $TEST$ equivalence_class assignedValue yield »r« = »1«; }; () { - // $TEST$ serialization literal<1> - // $TEST$ serialization $unknown + # $TEST$ serialization literal<1> + # $TEST$ serialization $unknown yield »r«, yield »s« = 1; }; () { - // $TEST$ serialization Int - // $TEST$ serialization String + # $TEST$ serialization Int + # $TEST$ serialization String yield »r«, _, yield »s« = f(); }; } diff --git a/packages/ttsl-lang/tests/resources/typing/assignees/placeholders/main.sdstest b/packages/ttsl-lang/tests/resources/typing/assignees/placeholders/main.sdstest index 144cda8d..16cce0ac 100644 --- a/packages/ttsl-lang/tests/resources/typing/assignees/placeholders/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/assignees/placeholders/main.sdstest @@ -3,19 +3,19 @@ package tests.typing.assignees.placeholders fun f() -> (r1: Int, r2: Float, r3: String) segment mySegment1() -> (r: Int) { - // $TEST$ equivalence_class assignedValue - // $TEST$ equivalence_class assignedValue + # $TEST$ equivalence_class assignedValue + # $TEST$ equivalence_class assignedValue val »r« = »1«; } segment mySegment2() -> (r: Int, s: String) { - // $TEST$ serialization literal<1> - // $TEST$ serialization $unknown + # $TEST$ serialization literal<1> + # $TEST$ serialization $unknown val »r«, val »s« = 1; } segment mySegment3() -> (r: Int, s: String) { - // $TEST$ serialization Int - // $TEST$ serialization String + # $TEST$ serialization Int + # $TEST$ serialization String val »r«, _, val »s« = f(); } diff --git a/packages/ttsl-lang/tests/resources/typing/assignees/yields/main.sdstest b/packages/ttsl-lang/tests/resources/typing/assignees/yields/main.sdstest index b26079cd..9248abac 100644 --- a/packages/ttsl-lang/tests/resources/typing/assignees/yields/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/assignees/yields/main.sdstest @@ -3,19 +3,19 @@ package tests.typing.assignees.yields fun f() -> (r1: Int, r2: Float, r3: String) segment mySegment1() -> (r: Int) { - // $TEST$ equivalence_class assignedValue - // $TEST$ equivalence_class assignedValue + # $TEST$ equivalence_class assignedValue + # $TEST$ equivalence_class assignedValue »yield r«, _ = »1«; // the wildcards prevents the marker from matching the entire assignee list } segment mySegment2() -> (r: Int, s: String) { - // $TEST$ serialization literal<1> - // $TEST$ serialization $unknown + # $TEST$ serialization literal<1> + # $TEST$ serialization $unknown »yield r«, »yield s« = 1; } segment mySegment3() -> (r: Int, s: String) { - // $TEST$ serialization Int - // $TEST$ serialization String + # $TEST$ serialization Int + # $TEST$ serialization String »yield r«, _, »yield s« = f(); } diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/annotations/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/annotations/main.sdstest index d3e2a94a..8963f2a4 100644 --- a/packages/ttsl-lang/tests/resources/typing/declarations/annotations/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/declarations/annotations/main.sdstest @@ -1,10 +1,10 @@ package tests.typing.declarations.annotations -// $TEST$ serialization () -> () +# $TEST$ serialization () -> () annotation »myAnnotation1« -// $TEST$ serialization (p1: Int, p2: String) -> () +# $TEST$ serialization (p1: Int, p2: String) -> () annotation »myAnnotation3«(p1: Int, p2: String) -// $TEST$ serialization (p1: $unknown) -> () +# $TEST$ serialization (p1: $unknown) -> () annotation »myAnnotation5«(p1) diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/attributes/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/attributes/main.sdstest index 7b10c3bc..d765b9a8 100644 --- a/packages/ttsl-lang/tests/resources/typing/declarations/attributes/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/declarations/attributes/main.sdstest @@ -1,17 +1,17 @@ package tests.typing.declarations.attributes class C { - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown attr »a« - // $TEST$ equivalence_class instanceAttribute - // $TEST$ equivalence_class instanceAttribute + # $TEST$ equivalence_class instanceAttribute + # $TEST$ equivalence_class instanceAttribute attr »b«: »Int« - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown static attr »c« - // $TEST$ equivalence_class staticAttribute - // $TEST$ equivalence_class staticAttribute + # $TEST$ equivalence_class staticAttribute + # $TEST$ equivalence_class staticAttribute static attr »d«: »Int« } diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/classes/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/classes/main.sdstest index 17c8bbeb..30332402 100644 --- a/packages/ttsl-lang/tests/resources/typing/declarations/classes/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/declarations/classes/main.sdstest @@ -1,7 +1,7 @@ package tests.typing.declarations.classes -// $TEST$ serialization MyClass1 +# $TEST$ serialization MyClass1 class »MyClass1« -// $TEST$ serialization MyClass2 +# $TEST$ serialization MyClass2 class »MyClass2« diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/enum variants/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/enum variants/main.sdstest index 1cdf36ae..28018ebc 100644 --- a/packages/ttsl-lang/tests/resources/typing/declarations/enum variants/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/declarations/enum variants/main.sdstest @@ -1,9 +1,9 @@ package tests.typing.declarations.enumVariants enum MyEnum { - // $TEST$ serialization MyEnum.MyEnumVariant1 + # $TEST$ serialization MyEnum.MyEnumVariant1 »MyEnumVariant1« - // $TEST$ serialization MyEnum.MyEnumVariant2 + # $TEST$ serialization MyEnum.MyEnumVariant2 »MyEnumVariant2« } diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/enums/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/enums/main.sdstest index e1297fb1..57879457 100644 --- a/packages/ttsl-lang/tests/resources/typing/declarations/enums/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/declarations/enums/main.sdstest @@ -1,7 +1,7 @@ package tests.typing.declarations.enums -// $TEST$ serialization MyEnum1 +# $TEST$ serialization MyEnum1 enum »MyEnum1« -// $TEST$ serialization MyEnum2 +# $TEST$ serialization MyEnum2 enum »MyEnum2« diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/functions/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/functions/main.sdstest index d8e86e84..ae1a9951 100644 --- a/packages/ttsl-lang/tests/resources/typing/declarations/functions/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/declarations/functions/main.sdstest @@ -1,16 +1,16 @@ package tests.typing.declarations.functions -// $TEST$ serialization () -> () +# $TEST$ serialization () -> () fun »myFunction1«() -// $TEST$ serialization () -> (r1: Int, r2: String) +# $TEST$ serialization () -> (r1: Int, r2: String) fun »myFunction2«() -> (r1: Int, r2: String) -// $TEST$ serialization (p1: Int, p2: String) -> () +# $TEST$ serialization (p1: Int, p2: String) -> () fun »myFunction3«(p1: Int, p2: String) -// $TEST$ serialization (p1: Int, p2: String) -> (r1: Int, r2: String) +# $TEST$ serialization (p1: Int, p2: String) -> (r1: Int, r2: String) fun »myFunction4«(p1: Int, p2: String) -> (r1: Int, r2: String) -// $TEST$ serialization (p1: $unknown) -> (r1: $unknown) +# $TEST$ serialization (p1: $unknown) -> (r1: $unknown) fun »myFunction5«(p1) -> (r1) diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of annotations/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of annotations/main.sdstest index 765e82e7..87209cf5 100644 --- a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of annotations/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of annotations/main.sdstest @@ -1,8 +1,8 @@ package tests.typing.declarations.parameters.ofAnnotations -// $TEST$ equivalence_class parameterType -// $TEST$ equivalence_class parameterType +# $TEST$ equivalence_class parameterType +# $TEST$ equivalence_class parameterType annotation MyAnnotation1(»p«: »Int«) -// $TEST$ serialization $unknown +# $TEST$ serialization $unknown annotation MyAnnotation2(»p«) diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/that are isolated/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/that are isolated/main.sdstest index bc78c346..24200463 100644 --- a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/that are isolated/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/that are isolated/main.sdstest @@ -1,6 +1,6 @@ package tests.typing.declarations.parameters.ofBlockLambdas.thatAreIsolated segment mySegment() { - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown (»p«) {}; } diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/that are passed as arguments/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/that are passed as arguments/main.sdstest index 6acee7d5..79e0b0ae 100644 --- a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/that are passed as arguments/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/that are passed as arguments/main.sdstest @@ -1,26 +1,26 @@ package tests.typing.declarations.parameters.ofBlockLambdas.thatArePassedAsArguments -// $TEST$ equivalence_class parameterType1 +# $TEST$ equivalence_class parameterType1 fun higherOrderFunction1(param: (a: »String«) -> ()) fun higherOrderFunction2(param: () -> ()) fun normalFunction(param: Int) segment mySegment() { - // $TEST$ equivalence_class parameterType1 + # $TEST$ equivalence_class parameterType1 higherOrderFunction1((»p«) {}); - // $TEST$ equivalence_class parameterType1 + # $TEST$ equivalence_class parameterType1 higherOrderFunction1(param = (»p«) {}); - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown higherOrderFunction2((»p«) {}); - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown higherOrderFunction2(param = (»p«) {}); - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown normalFunction((»p«) {}); - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown normalFunction(param = (»p«) {}); } diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/that are passed as default values/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/that are passed as default values/main.sdstest index 4cbdf821..31156f05 100644 --- a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/that are passed as default values/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/that are passed as default values/main.sdstest @@ -1,17 +1,17 @@ package tests.typing.declarations.parameters.ofBlockLambdas.thatArePassedAsDefaultValues fun higherOrderFunction1( - // $TEST$ equivalence_class parameterType1 - // $TEST$ equivalence_class parameterType1 + # $TEST$ equivalence_class parameterType1 + # $TEST$ equivalence_class parameterType1 param: (p: »String«) -> () = (»p«) {} ) fun higherOrderFunction2( - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown param: () -> () = (»p«) {} ) fun normalFunction( - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown param: Int = (»p«) {} ) diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/that are yielded/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/that are yielded/main.sdstest index bcb8aca8..ef607296 100644 --- a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/that are yielded/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/that are yielded/main.sdstest @@ -1,17 +1,17 @@ package tests.typing.declarations.parameters.ofBlockLambdas.thatAreYielded segment mySegment() -> ( - // $TEST$ equivalence_class parameterType2 + # $TEST$ equivalence_class parameterType2 r: (p: »String«) -> (), s: () -> (), t: Int, ) { - // $TEST$ equivalence_class parameterType2 + # $TEST$ equivalence_class parameterType2 yield r = (»p«) {}; - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown yield s = (»p«) {}; - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown yield t = (»p«) {}; } diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/with manifest types/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/with manifest types/main.sdstest index 4b0564d6..172f5221 100644 --- a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/with manifest types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/with manifest types/main.sdstest @@ -1,7 +1,7 @@ package tests.typing.declarations.parameters.ofBlockLambdas.withManifestTypes segment mySegment() { - // $TEST$ equivalence_class parameterType3 - // $TEST$ equivalence_class parameterType3 + # $TEST$ equivalence_class parameterType3 + # $TEST$ equivalence_class parameterType3 (»p«: »Int«) {}; } diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of callable types/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of callable types/main.sdstest index 17a6a703..091ec607 100644 --- a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of callable types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of callable types/main.sdstest @@ -1,8 +1,8 @@ package tests.typing.declarations.parameters.ofCallableTypes -// $TEST$ equivalence_class parameterType -// $TEST$ equivalence_class parameterType +# $TEST$ equivalence_class parameterType +# $TEST$ equivalence_class parameterType annotation MyAnnotation1(f: (»p«: »Int«) -> ()) -// $TEST$ serialization $unknown +# $TEST$ serialization $unknown annotation MyAnnotation2(f: (»p«) -> ()) diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of classes/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of classes/main.sdstest index 9185e184..d0587b89 100644 --- a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of classes/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of classes/main.sdstest @@ -1,8 +1,8 @@ package tests.typing.declarations.parameters.ofClasses -// $TEST$ equivalence_class parameterType -// $TEST$ equivalence_class parameterType +# $TEST$ equivalence_class parameterType +# $TEST$ equivalence_class parameterType class MyClass1(»p«: »Int«) -// $TEST$ serialization $unknown +# $TEST$ serialization $unknown class MyClass2(»p«) diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of enum variants/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of enum variants/main.sdstest index 8267ac61..4db3c11c 100644 --- a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of enum variants/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of enum variants/main.sdstest @@ -1,10 +1,10 @@ package tests.typing.declarations.parameters.ofEnumVariants enum MyEnum { - // $TEST$ equivalence_class parameterType - // $TEST$ equivalence_class parameterType + # $TEST$ equivalence_class parameterType + # $TEST$ equivalence_class parameterType MyEnumVariant1(»p«: »Int«) - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown MyEnumVariant2(»p«) } diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/that are isolated/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/that are isolated/main.sdstest index 51f0a097..bd6ee113 100644 --- a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/that are isolated/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/that are isolated/main.sdstest @@ -1,6 +1,6 @@ package tests.typing.declarations.parameters.ofExpressionLambdas.thatAreIsolated segment mySegment() { - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown (»p«) -> 1; } diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/that are passed as arguments/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/that are passed as arguments/main.sdstest index 5244fdaf..b0ac2203 100644 --- a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/that are passed as arguments/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/that are passed as arguments/main.sdstest @@ -1,26 +1,26 @@ package tests.typing.declarations.parameters.ofExpressionLambdas.thatArePassedAsArguments -// $TEST$ equivalence_class parameterType1 +# $TEST$ equivalence_class parameterType1 fun higherOrderFunction1(param: (a: »String«) -> r: String) fun higherOrderFunction2(param: () -> r: String) fun normalFunction(param: Int) segment mySegment() { - // $TEST$ equivalence_class parameterType1 + # $TEST$ equivalence_class parameterType1 higherOrderFunction1((»p«) -> ""); - // $TEST$ equivalence_class parameterType1 + # $TEST$ equivalence_class parameterType1 higherOrderFunction1(param = (»p«) -> ""); - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown higherOrderFunction2((»p«) -> ""); - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown higherOrderFunction2(param = (»p«) -> ""); - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown normalFunction((»p«) -> ""); - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown normalFunction(param = (»p«) -> ""); } diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/that are passed as default values/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/that are passed as default values/main.sdstest index 0476e790..0064d395 100644 --- a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/that are passed as default values/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/that are passed as default values/main.sdstest @@ -1,17 +1,17 @@ package tests.typing.declarations.parameters.ofExpressionLambdas.thatArePassedAsArguments fun higherOrderFunction1( - // $TEST$ equivalence_class parameterType1 - // $TEST$ equivalence_class parameterType1 + # $TEST$ equivalence_class parameterType1 + # $TEST$ equivalence_class parameterType1 param: (p: »String«) -> r: String = (»p«) -> "" ) fun higherOrderFunction2( - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown param: () -> r: String = (»p«) -> "" ) fun normalFunction( - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown param: Int = (»p«) -> "" ) diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/that are yielded/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/that are yielded/main.sdstest index c5da2c33..2a3c9588 100644 --- a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/that are yielded/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/that are yielded/main.sdstest @@ -1,17 +1,17 @@ package tests.typing.declarations.parameters.ofExpressionLambdas.thatAreYielded segment mySegment() -> ( - // $TEST$ equivalence_class parameterType2 + # $TEST$ equivalence_class parameterType2 r: (p: »String«) -> r: String, s: () -> r: String, t: Int, ) { - // $TEST$ equivalence_class parameterType2 + # $TEST$ equivalence_class parameterType2 yield r = (»p«) -> true; - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown yield s = (»p«) -> true; - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown yield t = (»p«) -> true; } diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/with manifest types/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/with manifest types/main.sdstest index 21689517..7b88ab7c 100644 --- a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/with manifest types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/with manifest types/main.sdstest @@ -1,7 +1,7 @@ package tests.typing.declarations.parameters.ofExpressionLambdas.withManifestTypes segment mySegment() { - // $TEST$ equivalence_class parameterType3 - // $TEST$ equivalence_class parameterType3 + # $TEST$ equivalence_class parameterType3 + # $TEST$ equivalence_class parameterType3 (»p«: »Int«) -> 1; } diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of functions/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of functions/main.sdstest index 854f7a2a..9d3eac6d 100644 --- a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of functions/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of functions/main.sdstest @@ -1,8 +1,8 @@ package tests.typing.declarations.parameters.ofFunctions -// $TEST$ equivalence_class parameterType -// $TEST$ equivalence_class parameterType +# $TEST$ equivalence_class parameterType +# $TEST$ equivalence_class parameterType fun myFunction1(»p«: »Int«) -// $TEST$ serialization $unknown +# $TEST$ serialization $unknown fun myFunction2(»p«) diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of segments/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of segments/main.sdstest index 5937cb36..b4aa6612 100644 --- a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of segments/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of segments/main.sdstest @@ -1,8 +1,8 @@ package tests.typing.declarations.parameters.ofSegments -// $TEST$ equivalence_class parameterType -// $TEST$ equivalence_class parameterType +# $TEST$ equivalence_class parameterType +# $TEST$ equivalence_class parameterType segment mySegment1(»p«: »Int«) {} -// $TEST$ serialization $unknown +# $TEST$ serialization $unknown segment mySegment2(»p«) {} diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/pipelines/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/pipelines/main.sdstest index 51dd507d..635d52fd 100644 --- a/packages/ttsl-lang/tests/resources/typing/declarations/pipelines/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/declarations/pipelines/main.sdstest @@ -1,4 +1,4 @@ package tests.typing.declarations.pipelines -// $TEST$ serialization $unknown +# $TEST$ serialization $unknown pipeline »myPipeline« {} diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/results/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/results/main.sdstest index fe03bfa5..5b25d60c 100644 --- a/packages/ttsl-lang/tests/resources/typing/declarations/results/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/declarations/results/main.sdstest @@ -1,14 +1,14 @@ package tests.typing.declarations.results -// $TEST$ equivalence_class functionResult -// $TEST$ equivalence_class functionResult +# $TEST$ equivalence_class functionResult +# $TEST$ equivalence_class functionResult fun myFun() -> (»r«: »String«) segment mySegment( - // $TEST$ equivalence_class callableTypeResult - // $TEST$ equivalence_class callableTypeResult + # $TEST$ equivalence_class callableTypeResult + # $TEST$ equivalence_class callableTypeResult p: () -> (»r«: »String«) -// $TEST$ equivalence_class segmentResult -// $TEST$ equivalence_class segmentResult +# $TEST$ equivalence_class segmentResult +# $TEST$ equivalence_class segmentResult ) -> (»r«: »String«) {} diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/segments/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/segments/main.sdstest index 953e8a87..a07d5928 100644 --- a/packages/ttsl-lang/tests/resources/typing/declarations/segments/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/declarations/segments/main.sdstest @@ -1,16 +1,16 @@ package tests.typing.declarations.segments -// $TEST$ serialization () -> () +# $TEST$ serialization () -> () segment »mySegment1«() {} -// $TEST$ serialization () -> (r1: Int, r2: String) +# $TEST$ serialization () -> (r1: Int, r2: String) segment »mySegment2«() -> (r1: Int, r2: String) {} -// $TEST$ serialization (p1: Int, p2: String) -> () +# $TEST$ serialization (p1: Int, p2: String) -> () segment »mySegment3«(p1: Int, p2: String) {} -// $TEST$ serialization (p1: Int, p2: String) -> (r1: Int, r2: String) +# $TEST$ serialization (p1: Int, p2: String) -> (r1: Int, r2: String) segment »mySegment4«(p1: Int, p2: String) -> (r1: Int, r2: String) {} -// $TEST$ serialization (p1: $unknown) -> (r1: $unknown) +# $TEST$ serialization (p1: $unknown) -> (r1: $unknown) segment »mySegment5«(p1) -> (r1) {} diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/type parameters/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/type parameters/main.sdstest index 52586950..9b62b388 100644 --- a/packages/ttsl-lang/tests/resources/typing/declarations/type parameters/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/declarations/type parameters/main.sdstest @@ -1,5 +1,5 @@ package tests.typing.declarations.typeParameters -// $TEST$ serialization K -// $TEST$ serialization V +# $TEST$ serialization K +# $TEST$ serialization V class MyClass<»K«, »V«> diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/arguments/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/arguments/main.sdstest index 8efa9e45..89899653 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/arguments/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/arguments/main.sdstest @@ -3,37 +3,37 @@ package tests.typing.expressions.arguments fun f(p: Any?) pipeline myPipeline { - // $TEST$ equivalence_class boolean - // $TEST$ equivalence_class boolean - // $TEST$ equivalence_class boolean + # $TEST$ equivalence_class boolean + # $TEST$ equivalence_class boolean + # $TEST$ equivalence_class boolean »true«; f(»true«); f(»p = true«); - // $TEST$ equivalence_class float - // $TEST$ equivalence_class float - // $TEST$ equivalence_class float + # $TEST$ equivalence_class float + # $TEST$ equivalence_class float + # $TEST$ equivalence_class float »1.0«; f(»1.0«); f(»p = 1.0«); - // $TEST$ equivalence_class int - // $TEST$ equivalence_class int - // $TEST$ equivalence_class int + # $TEST$ equivalence_class int + # $TEST$ equivalence_class int + # $TEST$ equivalence_class int »1«; f(»1«); f(»p = 1«); - // $TEST$ equivalence_class null - // $TEST$ equivalence_class null - // $TEST$ equivalence_class null + # $TEST$ equivalence_class null + # $TEST$ equivalence_class null + # $TEST$ equivalence_class null »null«; f(»null«); f(»p = null«); - // $TEST$ equivalence_class string - // $TEST$ equivalence_class string - // $TEST$ equivalence_class string + # $TEST$ equivalence_class string + # $TEST$ equivalence_class string + # $TEST$ equivalence_class string »""«; f(»""«); f(»p = ""«); diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/that are isolated/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/that are isolated/main.sdstest index 157a8127..47f67353 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/that are isolated/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/that are isolated/main.sdstest @@ -3,12 +3,12 @@ package tests.typing.expressions.blockLambdas.thatAreIsolated fun g() -> r: Int segment mySegment() { - // $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: $unknown) + # $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: $unknown) »(p) { yield r, yield s = 1; }«; - // $TEST$ serialization (p: $unknown) -> (r: Int, s: $unknown) + # $TEST$ serialization (p: $unknown) -> (r: Int, s: $unknown) val f = »(p) { yield r, yield s = g(); }«; diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/that are passed as arguments/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/that are passed as arguments/main.sdstest index 4303239a..0382bc4e 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/that are passed as arguments/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/that are passed as arguments/main.sdstest @@ -6,40 +6,40 @@ fun normalFunction(param: Int) fun parameterlessFunction() segment mySegment() { - // $TEST$ serialization (p: String) -> (r: literal<1>, s: literal<"">) + # $TEST$ serialization (p: String) -> (r: literal<1>, s: literal<"">) higherOrderFunction1(»(p) { yield r = 1; yield s = ""; }«); - // $TEST$ serialization (p: String) -> (r: literal<1>, s: $unknown) + # $TEST$ serialization (p: String) -> (r: literal<1>, s: $unknown) higherOrderFunction1(param = »(p) { yield r, yield s = 1; }«); - // $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: literal<"">) + # $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: literal<"">) higherOrderFunction2(»(p) { yield r = 1; yield s = ""; }«); - // $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: $unknown) + # $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: $unknown) higherOrderFunction2(param = »(p) { yield r, yield s = 1; }«); - // $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: literal<"">) + # $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: literal<"">) normalFunction(»(p) { yield r = 1; yield s = ""; }«); - // $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: $unknown) + # $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: $unknown) normalFunction(param = »(p) { yield r, yield s = 1; }«); - // $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: $unknown) + # $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: $unknown) parameterlessFunction(»(p) { yield r, yield s = 1; }«); diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/that are passed as default values/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/that are passed as default values/main.sdstest index d77d639a..19893075 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/that are passed as default values/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/that are passed as default values/main.sdstest @@ -1,36 +1,36 @@ package tests.typing.expressions.blockLambdas.thatArePassedAsDefaultValues fun higherOrderFunction1( - // $TEST$ serialization (p: String) -> (r: literal<1>, s: literal<"">) + # $TEST$ serialization (p: String) -> (r: literal<1>, s: literal<"">) param1: (p: String) -> (r: Int, s: String) = »(p) { yield r = 1; yield s = ""; }«, - // $TEST$ serialization (p: String) -> (r: literal<1>, s: $unknown) + # $TEST$ serialization (p: String) -> (r: literal<1>, s: $unknown) param2: (p: String) -> (r: Int, s: String) = »(p) { yield r, yield s = 1; }«, ) fun higherOrderFunction2( - // $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: literal<"">) + # $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: literal<"">) param1: () -> () = »(p) { yield r = 1; yield s = ""; }«, - // $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: $unknown) + # $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: $unknown) param2: () -> () = »(p) { yield r, yield s = 1; }«, ) fun normalFunction( - // $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: literal<"">) + # $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: literal<"">) param1: Int = »(p) { yield r = 1; yield s = ""; }«, - // $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: $unknown) + # $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: $unknown) param2: Int = »(p) { yield r, yield s = 1; }«, diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/that are yielded/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/that are yielded/main.sdstest index 7eaf2d53..2aee7d41 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/that are yielded/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/that are yielded/main.sdstest @@ -5,19 +5,19 @@ segment mySegment() -> ( s: () -> (), t: Int, ) { - // $TEST$ serialization (p: String) -> (r: literal<1>, s: literal<"">) + # $TEST$ serialization (p: String) -> (r: literal<1>, s: literal<"">) yield r = »(p) { yield r = 1; yield s = ""; }«; - // $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: literal<"">) + # $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: literal<"">) yield s = »(p) { yield r = 1; yield s = ""; }«; - // $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: $unknown) + # $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: $unknown) yield t = »(p) { yield r, yield s = 1; }«; diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/with manifest types/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/with manifest types/main.sdstest index aa34f81a..fff6cd35 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/with manifest types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/with manifest types/main.sdstest @@ -1,13 +1,13 @@ package tests.typing.expressions.blockLambdas.withManifestTypes segment mySegment() { - // $TEST$ serialization (p: Int) -> (r: literal<1>, s: literal<"">) + # $TEST$ serialization (p: Int) -> (r: literal<1>, s: literal<"">) »(p: Int) { yield r = 1; yield s = ""; }«; - // $TEST$ serialization (p: String) -> (r: literal<1>, s: $unknown) + # $TEST$ serialization (p: String) -> (r: literal<1>, s: $unknown) »(p: String) { yield r, yield s = 1; }«; diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of annotations/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/of annotations/main.sdstest index 350c95c8..59f5d871 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of annotations/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/calls/of annotations/main.sdstest @@ -3,9 +3,9 @@ package tests.typing.expressions.calls.ofAnnotations annotation MyAnnotation pipeline myPipeline { - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown »MyAnnotation()«; - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown »MyAnnotation?()«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of block lambdas/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/of block lambdas/main.sdstest index 264025a9..a41b2e0c 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of block lambdas/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/calls/of block lambdas/main.sdstest @@ -1,23 +1,23 @@ package tests.typing.expressions.calls.ofBlockLambdas pipeline myPipeline { - // $TEST$ serialization literal<""> + # $TEST$ serialization literal<""> »(() { yield r = ""; })()«; - // $TEST$ serialization (r: literal<"">, s: literal<1>) + # $TEST$ serialization (r: literal<"">, s: literal<1>) »(() { yield r = ""; yield s = 1; })()«; - // $TEST$ serialization literal<""> + # $TEST$ serialization literal<""> »(() { yield r = ""; })?()«; - // $TEST$ serialization (r: literal<"">, s: literal<1>) + # $TEST$ serialization (r: literal<"">, s: literal<1>) »(() { yield r = ""; yield s = 1; diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of callable types/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/of callable types/main.sdstest index 9e8a2521..9996e9d7 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of callable types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/calls/of callable types/main.sdstest @@ -4,15 +4,15 @@ segment mySegment( p1: () -> r: String, p2: () -> (r: String, s: Int) ) { - // $TEST$ serialization String + # $TEST$ serialization String »p1()«; - // $TEST$ serialization (r: String, s: Int) + # $TEST$ serialization (r: String, s: Int) »p2()«; - // $TEST$ serialization String + # $TEST$ serialization String »p1?()«; - // $TEST$ serialization (r: String, s: Int) + # $TEST$ serialization (r: String, s: Int) »p2?()«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of classes/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/of classes/main.sdstest index 0e9e5bf9..b44955a2 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of classes/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/calls/of classes/main.sdstest @@ -3,15 +3,15 @@ package tests.typing.expressions.calls.ofClasses class C() pipeline myPipeline { - // $TEST$ serialization C + # $TEST$ serialization C »C()«; - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown »C()()«; - // $TEST$ serialization C + # $TEST$ serialization C »C?()«; - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown »C?()?()«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of enum variants/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/of enum variants/main.sdstest index 04387c9b..e5f90a70 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of enum variants/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/calls/of enum variants/main.sdstest @@ -7,76 +7,76 @@ enum MyEnum { } pipeline myPipeline { - // $TEST$ serialization MyEnum.MyEnumVariantWithoutParameterList + # $TEST$ serialization MyEnum.MyEnumVariantWithoutParameterList »MyEnum.MyEnumVariantWithoutParameterList()«; - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown val alias1 = MyEnum.MyEnumVariantWithoutParameterList; »alias1()«; - // $TEST$ serialization MyEnum.MyEnumVariantWithoutParameters + # $TEST$ serialization MyEnum.MyEnumVariantWithoutParameters »MyEnum.MyEnumVariantWithoutParameters()«; - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown val alias2 = MyEnum.MyEnumVariantWithoutParameters; »alias2()«; - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown »MyEnum.MyEnumVariantWithoutParameters()()«; - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown val alias3 = MyEnum.MyEnumVariantWithoutParameters(); »alias3()«; - // $TEST$ serialization MyEnum.MyEnumVariantWithParameters + # $TEST$ serialization MyEnum.MyEnumVariantWithParameters »MyEnum.MyEnumVariantWithParameters(1)«; - // $TEST$ serialization MyEnum.MyEnumVariantWithParameters + # $TEST$ serialization MyEnum.MyEnumVariantWithParameters val alias4 = MyEnum.MyEnumVariantWithParameters; »alias4(1)«; - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown »MyEnum.MyEnumVariantWithParameters(1)()«; - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown val alias5 = MyEnum.MyEnumVariantWithParameters(1); »alias5()«; // Null-safe calls ------------------------------------------------------------------------------------------------- - // $TEST$ serialization MyEnum.MyEnumVariantWithoutParameterList + # $TEST$ serialization MyEnum.MyEnumVariantWithoutParameterList »MyEnum.MyEnumVariantWithoutParameterList?()«; - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown val alias1 = MyEnum.MyEnumVariantWithoutParameterList; »alias1?()«; - // $TEST$ serialization MyEnum.MyEnumVariantWithoutParameters + # $TEST$ serialization MyEnum.MyEnumVariantWithoutParameters »MyEnum.MyEnumVariantWithoutParameters?()«; - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown val alias2 = MyEnum.MyEnumVariantWithoutParameters; »alias2?()«; - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown »MyEnum.MyEnumVariantWithoutParameters?()?()«; - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown val alias3 = MyEnum.MyEnumVariantWithoutParameters?(); »alias3?()«; - // $TEST$ serialization MyEnum.MyEnumVariantWithParameters + # $TEST$ serialization MyEnum.MyEnumVariantWithParameters »MyEnum.MyEnumVariantWithParameters(1)«; - // $TEST$ serialization MyEnum.MyEnumVariantWithParameters + # $TEST$ serialization MyEnum.MyEnumVariantWithParameters val alias4 = MyEnum.MyEnumVariantWithParameters; »alias4?(1)«; - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown »MyEnum.MyEnumVariantWithParameters(1)?()«; - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown val alias5 = MyEnum.MyEnumVariantWithParameters(1); »alias5?()«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of expression lambdas/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/of expression lambdas/main.sdstest index 5c255a9f..4ef52a6c 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of expression lambdas/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/calls/of expression lambdas/main.sdstest @@ -1,9 +1,9 @@ package tests.typing.expressions.calls.ofExpressionLambdas pipeline myPipeline { - // $TEST$ serialization literal<1> + # $TEST$ serialization literal<1> »(() -> 1)()«; - // $TEST$ serialization literal<1> + # $TEST$ serialization literal<1> »(() -> 1)?()«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of functions/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/of functions/main.sdstest index 2df9dfa6..cadcd1b5 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of functions/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/calls/of functions/main.sdstest @@ -4,15 +4,15 @@ fun f1() -> r: String fun f2() -> (r: String, s: Int) pipeline myPipeline { - // $TEST$ serialization String + # $TEST$ serialization String »f1()«; - // $TEST$ serialization (r: String, s: Int) + # $TEST$ serialization (r: String, s: Int) »f2()«; - // $TEST$ serialization String + # $TEST$ serialization String »f1?()«; - // $TEST$ serialization (r: String, s: Int) + # $TEST$ serialization (r: String, s: Int) »f2?()«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of non-callable/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/of non-callable/main.sdstest index 3948cb8f..077a6cd0 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of non-callable/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/calls/of non-callable/main.sdstest @@ -3,9 +3,9 @@ package tests.typing.expressions.calls.ofNonCallables enum MyEnum pipeline myPipeline { - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown »MyEnum()«; - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown »MyEnum?()«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of nullable receiver/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/of nullable receiver/main.sdstest index 358ca43a..b433f33d 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of nullable receiver/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/calls/of nullable receiver/main.sdstest @@ -8,13 +8,13 @@ class MyClass { segment mySegment( myClassOrNull: MyClass? ) { - // $TEST$ serialization Int + # $TEST$ serialization Int »myClassOrNull?.a()«; - // $TEST$ serialization Int + # $TEST$ serialization Int »myClassOrNull?.f()«; - // $TEST$ serialization Int? + # $TEST$ serialization Int? »myClassOrNull?.f?()«; - // $TEST$ serialization Int? + # $TEST$ serialization Int? »myClassOrNull?.f?()«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of segments/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/of segments/main.sdstest index 713685eb..7c293e09 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of segments/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/calls/of segments/main.sdstest @@ -7,15 +7,15 @@ segment s2() -> (r: String, s: Int) { } pipeline myPipeline { - // $TEST$ serialization String + # $TEST$ serialization String »s1()«; - // $TEST$ serialization (r: String, s: Int) + # $TEST$ serialization (r: String, s: Int) »s2()«; - // $TEST$ serialization String + # $TEST$ serialization String »s1?()«; - // $TEST$ serialization (r: String, s: Int) + # $TEST$ serialization (r: String, s: Int) »s2?()«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/clamp to upper bound/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/clamp to upper bound/main.sdstest index 8d16db57..8b02e652 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/clamp to upper bound/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/clamp to upper bound/main.sdstest @@ -5,15 +5,15 @@ class C1(p1: T) @Pure fun f1(p1: T) -> r1: T pipeline myPipeline { - // $TEST$ serialization C1 + # $TEST$ serialization C1 »C1("")«; - // $TEST$ serialization C1 + # $TEST$ serialization C1 »C1()«; - // $TEST$ serialization Int + # $TEST$ serialization Int »f1("")«; - // $TEST$ serialization Int + # $TEST$ serialization Int »f1()«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/deep nesting/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/deep nesting/main.sdstest index 78c0bbae..5a1291b3 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/deep nesting/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/deep nesting/main.sdstest @@ -16,25 +16,25 @@ segment mySegment( a4: Contravariant, a5: Contravariant>, ) { - // $TEST$ serialization C1 + # $TEST$ serialization C1 »C1(a2, a1)«; - // $TEST$ serialization C1 + # $TEST$ serialization C1 »C1(a2, a2)«; - // $TEST$ serialization C1 + # $TEST$ serialization C1 »C1(a2, a3)«; - // $TEST$ serialization C1 + # $TEST$ serialization C1 »C1(a2, a4)«; - // $TEST$ serialization C1 + # $TEST$ serialization C1 »C1(a2, a5)«; - // $TEST$ serialization Int + # $TEST$ serialization Int »f1(a2, a1)«; - // $TEST$ serialization Number + # $TEST$ serialization Number »f1(a2, a2)«; - // $TEST$ serialization Number + # $TEST$ serialization Number »f1(a2, a3)«; - // $TEST$ serialization Number + # $TEST$ serialization Number »f1(a2, a4)«; - // $TEST$ serialization Number + # $TEST$ serialization Number »f1(a2, a5)«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/default value of parameter/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/default value of parameter/main.sdstest index 55ffe280..98e5935e 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/default value of parameter/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/default value of parameter/main.sdstest @@ -5,9 +5,9 @@ class C1(p1: T = 0) @Pure fun f1(p1: T = 0) -> r1: T pipeline myPipeline { - // $TEST$ serialization C1> + # $TEST$ serialization C1> »C1()«; - // $TEST$ serialization literal<0> + # $TEST$ serialization literal<0> »f1()«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/default value of type parameter/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/default value of type parameter/main.sdstest index 52921225..6589d9ae 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/default value of type parameter/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/default value of type parameter/main.sdstest @@ -7,13 +7,13 @@ class C2() @Pure fun f2() -> r1: T pipeline myPipeline { - // $TEST$ serialization C1 + # $TEST$ serialization C1 »C1()«; - // $TEST$ serialization C2 + # $TEST$ serialization C2 »C2()«; - // $TEST$ serialization Nothing + # $TEST$ serialization Nothing »f1()«; - // $TEST$ serialization Int + # $TEST$ serialization Int »f2()«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/differing variance/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/differing variance/main.sdstest index b97517ee..7f9b5e12 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/differing variance/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/differing variance/main.sdstest @@ -19,40 +19,40 @@ segment mySegment( b2: Invariant, b3: Covariant, ) { - // $TEST$ serialization C1 + # $TEST$ serialization C1 »C1(a1, a2)«; - // $TEST$ serialization C1 + # $TEST$ serialization C1 »C1(a1, b2)«; - // $TEST$ serialization C1 + # $TEST$ serialization C1 »C1(b1, a2)«; - // $TEST$ serialization C1 + # $TEST$ serialization C1 »C1(b1, b2)«; - // $TEST$ serialization C2 + # $TEST$ serialization C2 »C2(a1, a3)«; - // $TEST$ serialization C2 + # $TEST$ serialization C2 »C2(a1, b3)«; - // $TEST$ serialization C2 + # $TEST$ serialization C2 »C2(b1, a3)«; - // $TEST$ serialization C2 + # $TEST$ serialization C2 »C2(b1, b3)«; - // $TEST$ serialization Nothing + # $TEST$ serialization Nothing »f1(a1, a2)«; - // $TEST$ serialization Nothing + # $TEST$ serialization Nothing »f1(a1, b2)«; - // $TEST$ serialization Number + # $TEST$ serialization Number »f1(b1, a2)«; - // $TEST$ serialization Number + # $TEST$ serialization Number »f1(b1, b2)«; - // $TEST$ serialization Nothing + # $TEST$ serialization Nothing »f2(a1, a3)«; - // $TEST$ serialization Nothing + # $TEST$ serialization Nothing »f2(a1, b3)«; - // $TEST$ serialization Number + # $TEST$ serialization Number »f2(b1, a3)«; - // $TEST$ serialization Number + # $TEST$ serialization Number »f2(b1, b3)«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/multiple contravariant/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/multiple contravariant/main.sdstest index 1a0e825f..156235a9 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/multiple contravariant/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/multiple contravariant/main.sdstest @@ -16,29 +16,29 @@ segment mySegment( c: (p1: Number) -> () ) { - // $TEST$ serialization C1 + # $TEST$ serialization C1 »C1(a1, c)«; - // $TEST$ serialization C1 + # $TEST$ serialization C1 »C1(a2, c)«; - // $TEST$ serialization C1 + # $TEST$ serialization C1 »C1(a3, c)«; - // $TEST$ serialization C1 + # $TEST$ serialization C1 »C1(a4, c)«; - // $TEST$ serialization C1 + # $TEST$ serialization C1 »C1(a5, c)«; - // $TEST$ serialization C1 + # $TEST$ serialization C1 »C1(a1, (p1) {})«; - // $TEST$ serialization Int + # $TEST$ serialization Int »f1(a1, c)«; - // $TEST$ serialization Number + # $TEST$ serialization Number »f1(a2, c)«; - // $TEST$ serialization Number + # $TEST$ serialization Number »f1(a3, c)«; - // $TEST$ serialization Number + # $TEST$ serialization Number »f1(a4, c)«; - // $TEST$ serialization Nothing + # $TEST$ serialization Nothing »f1(a5, c)«; - // $TEST$ serialization Int + # $TEST$ serialization Int »f1(a1, (p1) {})«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/multiple covariant/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/multiple covariant/main.sdstest index c573e92d..11653b31 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/multiple covariant/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/multiple covariant/main.sdstest @@ -20,33 +20,33 @@ segment mySegment( c: () -> r1: Number ) { - // $TEST$ serialization C1 + # $TEST$ serialization C1 »C1(a1, b1, c)«; - // $TEST$ serialization C1 + # $TEST$ serialization C1 »C1(a2, b1, c)«; - // $TEST$ serialization C1 + # $TEST$ serialization C1 »C1(a3, b1, c)«; - // $TEST$ serialization C1 + # $TEST$ serialization C1 »C1(a1, b2, c)«; - // $TEST$ serialization C1 + # $TEST$ serialization C1 »C1(a1, b3, c)«; - // $TEST$ serialization C1 + # $TEST$ serialization C1 »C1(a1, b1, () -> "")«; - // $TEST$ serialization C1 + # $TEST$ serialization C1 »C1(a1, b1, SomeClass)«; - // $TEST$ serialization Number + # $TEST$ serialization Number »f1(a1, b1, c)«; - // $TEST$ serialization Number + # $TEST$ serialization Number »f1(a2, b1, c)«; - // $TEST$ serialization Any? + # $TEST$ serialization Any? »f1(a3, b1, c)«; - // $TEST$ serialization Number + # $TEST$ serialization Number »f1(a1, b2, c)«; - // $TEST$ serialization Any? + # $TEST$ serialization Any? »f1(a1, b3, c)«; - // $TEST$ serialization Any + # $TEST$ serialization Any »f1(a1, b1, () -> "")«; - // $TEST$ serialization Any + # $TEST$ serialization Any »f1(a1, b1, SomeClass)«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/single contravariant/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/single contravariant/main.sdstest index f6338b6e..e727dc47 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/single contravariant/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/single contravariant/main.sdstest @@ -8,9 +8,9 @@ class C1(p1: Contravariant) segment mySegment( p1: Contravariant, ) { - // $TEST$ serialization C1 + # $TEST$ serialization C1 »C1(p1)«; - // $TEST$ serialization Int + # $TEST$ serialization Int »f1(p1)«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/single covariant/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/single covariant/main.sdstest index 06b195bb..852ee30e 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/single covariant/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/single covariant/main.sdstest @@ -6,9 +6,9 @@ class C1(p1: T) segment mySegment( p1: Int, ) { - // $TEST$ serialization C1 + # $TEST$ serialization C1 »C1(p1)«; - // $TEST$ serialization Int + # $TEST$ serialization Int »f1(p1)«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/unresolved/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/unresolved/main.sdstest index 4ad038be..47edf418 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/unresolved/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/calls/unresolved/main.sdstest @@ -1,9 +1,9 @@ package tests.typing.expressions.calls.ofUnresolved pipeline myPipeline { - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown »unresolved()«; - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown »unresolved?()«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/that are isolated/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/that are isolated/main.sdstest index 1cca1cc2..7858e777 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/that are isolated/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/that are isolated/main.sdstest @@ -3,9 +3,9 @@ package tests.typing.expressions.expressionLambdas.thatAreIsolated fun g() -> r: Int segment mySegment() { - // $TEST$ serialization (p: $unknown) -> (result: Int) + # $TEST$ serialization (p: $unknown) -> (result: Int) »(p) -> g()«; - // $TEST$ serialization (p: $unknown) -> (result: literal<1>) + # $TEST$ serialization (p: $unknown) -> (result: literal<1>) val f = »(p) -> 1«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/that are passed as arguments/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/that are passed as arguments/main.sdstest index 4277aabf..42032365 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/that are passed as arguments/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/that are passed as arguments/main.sdstest @@ -6,24 +6,24 @@ fun normalFunction(param: Int) fun parameterlessFunction() segment mySegment() { - // $TEST$ serialization (p: String) -> (result: literal<1>) + # $TEST$ serialization (p: String) -> (result: literal<1>) higherOrderFunction1(»(p) -> 1«); - // $TEST$ serialization (p: String) -> (result: literal<1>) + # $TEST$ serialization (p: String) -> (result: literal<1>) higherOrderFunction1(param = »(p) -> 1«); - // $TEST$ serialization (p: $unknown) -> (result: literal<1>) + # $TEST$ serialization (p: $unknown) -> (result: literal<1>) higherOrderFunction2(»(p) -> 1«); - // $TEST$ serialization (p: $unknown) -> (result: literal<1>) + # $TEST$ serialization (p: $unknown) -> (result: literal<1>) higherOrderFunction2(param = »(p) -> 1«); - // $TEST$ serialization (p: $unknown) -> (result: literal<1>) + # $TEST$ serialization (p: $unknown) -> (result: literal<1>) normalFunction(»(p) -> 1«); - // $TEST$ serialization (p: $unknown) -> (result: literal<1>) + # $TEST$ serialization (p: $unknown) -> (result: literal<1>) normalFunction(param = »(p) -> 1«); - // $TEST$ serialization (p: $unknown) -> (result: literal<1>) + # $TEST$ serialization (p: $unknown) -> (result: literal<1>) parameterlessFunction(»(p) -> 1«); } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/that are passed as default values/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/that are passed as default values/main.sdstest index 201a0594..c86065a4 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/that are passed as default values/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/that are passed as default values/main.sdstest @@ -1,16 +1,16 @@ package tests.typing.expressions.expressionLambdas.thatArePassedAsDefaultValues fun higherOrderFunction1( - // $TEST$ serialization (p: String) -> (result: literal<1>) + # $TEST$ serialization (p: String) -> (result: literal<1>) param: (p: String) -> (r: Int) = »(p) -> 1« ) fun higherOrderFunction2( - // $TEST$ serialization (p: $unknown) -> (result: literal<1>) + # $TEST$ serialization (p: $unknown) -> (result: literal<1>) param: () -> () = »(p) -> 1« ) fun normalFunction( - // $TEST$ serialization (p: $unknown) -> (result: literal<1>) + # $TEST$ serialization (p: $unknown) -> (result: literal<1>) param: Int = »(p) -> 1« ) diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/that are yielded/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/that are yielded/main.sdstest index c8f26c2a..1d40039f 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/that are yielded/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/that are yielded/main.sdstest @@ -5,12 +5,12 @@ segment mySegment() -> ( s: () -> (), t: Int, ) { - // $TEST$ serialization (p: String) -> (result: literal<1>) + # $TEST$ serialization (p: String) -> (result: literal<1>) yield r = »(p) -> 1«; - // $TEST$ serialization (p: $unknown) -> (result: literal<1>) + # $TEST$ serialization (p: $unknown) -> (result: literal<1>) yield s = »(p) -> 1«; - // $TEST$ serialization (p: $unknown) -> (result: literal<1>) + # $TEST$ serialization (p: $unknown) -> (result: literal<1>) yield t = »(p) -> 1«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/with manifest types/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/with manifest types/main.sdstest index 5ad3d084..4e8331d5 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/with manifest types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/with manifest types/main.sdstest @@ -1,6 +1,6 @@ package tests.typing.expressions.expressionLambdas.withManifestTypes segment mySegment() { - // $TEST$ serialization (p: Int) -> (result: literal<1>) + # $TEST$ serialization (p: Int) -> (result: literal<1>) »(p: Int) -> 1«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on lists/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on lists/main.sdstest index 99e63e19..5e775222 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on lists/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on lists/main.sdstest @@ -3,41 +3,41 @@ package tests.typing.expressions.indexedAccesses.onLists class IntList sub List segment mySegment(param1: List, param2: List?, param3: IntList) { - // $TEST$ serialization Int + # $TEST$ serialization Int »param1[0]«; - // $TEST$ serialization Int + # $TEST$ serialization Int »param1[unresolved]«; - // $TEST$ serialization Int + # $TEST$ serialization Int »param2[0]«; - // $TEST$ serialization Int + # $TEST$ serialization Int »param2[unresolved]«; - // $TEST$ serialization Int + # $TEST$ serialization Int »param3[0]«; - // $TEST$ serialization Int + # $TEST$ serialization Int »param3[unresolved]«; - // $TEST$ serialization Int + # $TEST$ serialization Int »param1?[0]«; - // $TEST$ serialization Int + # $TEST$ serialization Int »param1?[unresolved]«; - // $TEST$ serialization Int? + # $TEST$ serialization Int? »param2?[0]«; - // $TEST$ serialization Int? + # $TEST$ serialization Int? »param2?[unresolved]«; - // $TEST$ serialization Int + # $TEST$ serialization Int »param3?[0]«; - // $TEST$ serialization Int + # $TEST$ serialization Int »param3?[unresolved]«; } @@ -46,40 +46,40 @@ class MyClass, MyNullableList sub List?>( param2: MyList?, param3: MyNullableList, - // $TEST$ serialization Int + # $TEST$ serialization Int p1: Any? = »param1[0]«, - // $TEST$ serialization Int + # $TEST$ serialization Int p2: Any? = »param1[unresolved]«, - // $TEST$ serialization Int + # $TEST$ serialization Int p3: Any? = »param2[0]«, - // $TEST$ serialization Int + # $TEST$ serialization Int p4: Any? = »param2[unresolved]«, - // $TEST$ serialization Int + # $TEST$ serialization Int p5: Any? = »param3[0]«, - // $TEST$ serialization Int + # $TEST$ serialization Int p6: Any? = »param3[unresolved]«, - // $TEST$ serialization Int + # $TEST$ serialization Int p7: Any? = »param1?[0]«, - // $TEST$ serialization Int + # $TEST$ serialization Int p8: Any? = »param1?[unresolved]«, - // $TEST$ serialization Int? + # $TEST$ serialization Int? p9: Any? = »param2?[0]«, - // $TEST$ serialization Int? + # $TEST$ serialization Int? p10: Any? = »param2?[unresolved]«, - // $TEST$ serialization Int? + # $TEST$ serialization Int? p11: Any? = »param3?[0]«, - // $TEST$ serialization Int? + # $TEST$ serialization Int? p12: Any? = »param3?[unresolved]«, ) diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on maps/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on maps/main.sdstest index b55e8e77..b2641234 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on maps/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on maps/main.sdstest @@ -3,41 +3,41 @@ package tests.typing.expressions.indexedAccesses.onMaps class MyMap sub Map segment mySegment(param1: Map, param2: Map?, param3: MyMap) { - // $TEST$ serialization Int + # $TEST$ serialization Int »param1[""]«; - // $TEST$ serialization Int + # $TEST$ serialization Int »param1[unresolved]«; - // $TEST$ serialization Int + # $TEST$ serialization Int »param2[""]«; - // $TEST$ serialization Int + # $TEST$ serialization Int »param2[unresolved]«; - // $TEST$ serialization Int + # $TEST$ serialization Int »param3[""]«; - // $TEST$ serialization Int + # $TEST$ serialization Int »param3[unresolved]«; - // $TEST$ serialization Int + # $TEST$ serialization Int »param1?[""]«; - // $TEST$ serialization Int + # $TEST$ serialization Int »param1?[unresolved]«; - // $TEST$ serialization Int? + # $TEST$ serialization Int? »param2?[""]«; - // $TEST$ serialization Int? + # $TEST$ serialization Int? »param2?[unresolved]«; - // $TEST$ serialization Int + # $TEST$ serialization Int »param3?[""]«; - // $TEST$ serialization Int + # $TEST$ serialization Int »param3?[unresolved]«; } @@ -46,40 +46,40 @@ class MyClass, MyNullableMap sub Map?>( param2: MyMap?, param3: MyNullableMap, - // $TEST$ serialization Int + # $TEST$ serialization Int p1: Any? = »param1[""]«, - // $TEST$ serialization Int + # $TEST$ serialization Int p2: Any? = »param1[unresolved]«, - // $TEST$ serialization Int + # $TEST$ serialization Int p3: Any? = »param2[""]«, - // $TEST$ serialization Int + # $TEST$ serialization Int p4: Any? = »param2[unresolved]«, - // $TEST$ serialization Int + # $TEST$ serialization Int p5: Any? = »param3[""]«, - // $TEST$ serialization Int + # $TEST$ serialization Int p6: Any? = »param3[unresolved]«, - // $TEST$ serialization Int + # $TEST$ serialization Int p7: Any? = »param1?[""]«, - // $TEST$ serialization Int + # $TEST$ serialization Int p8: Any? = »param1?[unresolved]«, - // $TEST$ serialization Int? + # $TEST$ serialization Int? p9: Any? = »param2?[""]«, - // $TEST$ serialization Int? + # $TEST$ serialization Int? p10: Any? = »param2?[unresolved]«, - // $TEST$ serialization Int? + # $TEST$ serialization Int? p11: Any? = »param3?[""]«, - // $TEST$ serialization Int? + # $TEST$ serialization Int? p12: Any? = »param3?[unresolved]«, ) diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on other/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on other/main.sdstest index 12637d99..c8e72cd1 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on other/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on other/main.sdstest @@ -1,16 +1,16 @@ package tests.typing.expressions.indexedAccesses.onOther segment mySegment3(param1: String, param2: String?) { - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown »param1[0]«; - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown »param2[0]«; - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown »param1?[0]«; - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown »param2?[0]«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on unresolved/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on unresolved/main.sdstest index 352d9f4b..079f641c 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on unresolved/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on unresolved/main.sdstest @@ -1,9 +1,9 @@ package tests.typing.expressions.indexedAccesses.onUnresolved segment mySegment() { - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown »unresolved[0]«; - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown »unresolved?[0]«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/lists/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/lists/main.sdstest index 270f8de3..dd3cc8f0 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/lists/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/lists/main.sdstest @@ -5,18 +5,18 @@ package tests.typing.expressions.lists pipeline myPipeline { - // $TEST$ serialization List + # $TEST$ serialization List »[]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[1, 2, 3]«; - // $TEST$ serialization List + # $TEST$ serialization List »[1, float(), 3]«; - // $TEST$ serialization List + # $TEST$ serialization List »[1, string(), 3]«; - // $TEST$ serialization List + # $TEST$ serialization List »[1, string(), null]«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/literals/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/literals/main.sdstest index f17a08ae..ac8bf6e6 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/literals/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/literals/main.sdstest @@ -2,18 +2,18 @@ package tests.typing.expressions.literals pipeline myPipeline { - // $TEST$ serialization literal + # $TEST$ serialization literal val booleanLiteral = »true«; - // $TEST$ serialization literal<1.5> + # $TEST$ serialization literal<1.5> val floatLiteral = »1.5«; - // $TEST$ serialization literal<1> + # $TEST$ serialization literal<1> val intLiteral = »1«; - // $TEST$ serialization Nothing? + # $TEST$ serialization Nothing? val nullLiteral = »null«; - // $TEST$ serialization literal<"myString"> + # $TEST$ serialization literal<"myString"> val stringLiteral = »"myString"«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/maps/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/maps/main.sdstest index 2d055e1f..23572818 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/maps/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/maps/main.sdstest @@ -5,21 +5,21 @@ package tests.typing.expressions.maps pipeline myPipeline { - // $TEST$ serialization Map + # $TEST$ serialization Map »{}«; - // $TEST$ serialization Map> + # $TEST$ serialization Map> »{1: 1, 2: 2, 3: 3}«; - // $TEST$ serialization Map + # $TEST$ serialization Map »{1: 1, float(): float(), 3: 3}«; - // $TEST$ serialization Map + # $TEST$ serialization Map »{1: 1, string(): string(), 3: 3}«; - // $TEST$ serialization Map + # $TEST$ serialization Map »{1: 1, string(): string(), null: null}«; - // $TEST$ serialization Map + # $TEST$ serialization Map »{float(): string(), 1: null}«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/on class with type parameters/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/on class with type parameters/main.sdstest index 219a7319..f1510c95 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/on class with type parameters/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/on class with type parameters/main.sdstest @@ -13,64 +13,64 @@ class D sub C // Accessing own members segment mySegment1(p: C) { - // $TEST$ serialization Int + # $TEST$ serialization Int »p.nonNullableMember«; - // $TEST$ serialization Int? + # $TEST$ serialization Int? »p.nullableMember«; - // $TEST$ serialization () -> (r: Int) + # $TEST$ serialization () -> (r: Int) »p.method«; - // $TEST$ serialization Int + # $TEST$ serialization Int »p?.nonNullableMember«; - // $TEST$ serialization Int? + # $TEST$ serialization Int? »p?.nullableMember«; - // $TEST$ serialization () -> (r: Int) + # $TEST$ serialization () -> (r: Int) »p?.method«; - // $TEST$ serialization Int + # $TEST$ serialization Int »nullableC().nonNullableMember«; - // $TEST$ serialization Int? + # $TEST$ serialization Int? »nullableC().nullableMember«; - // $TEST$ serialization () -> (r: Int) + # $TEST$ serialization () -> (r: Int) »nullableC().method«; - // $TEST$ serialization Int? + # $TEST$ serialization Int? »nullableC()?.nonNullableMember«; - // $TEST$ serialization Int? + # $TEST$ serialization Int? »nullableC()?.nullableMember«; - // $TEST$ serialization union<() -> (r: Int), Nothing?> + # $TEST$ serialization union<() -> (r: Int), Nothing?> »nullableC()?.method«; } // Accessing inherited members segment mySegment2(p: D) { - // $TEST$ serialization Int + # $TEST$ serialization Int »p.nonNullableMember«; - // $TEST$ serialization Int? + # $TEST$ serialization Int? »p.nullableMember«; - // $TEST$ serialization () -> (r: Int) + # $TEST$ serialization () -> (r: Int) »p.method«; - // $TEST$ serialization Int + # $TEST$ serialization Int »p?.nonNullableMember«; - // $TEST$ serialization Int? + # $TEST$ serialization Int? »p?.nullableMember«; - // $TEST$ serialization () -> (r: Int) + # $TEST$ serialization () -> (r: Int) »p?.method«; - // $TEST$ serialization Int + # $TEST$ serialization Int »nullableD().nonNullableMember«; - // $TEST$ serialization Int? + # $TEST$ serialization Int? »nullableD().nullableMember«; - // $TEST$ serialization () -> (r: Int) + # $TEST$ serialization () -> (r: Int) »nullableD().method«; - // $TEST$ serialization Int? + # $TEST$ serialization Int? »nullableD()?.nonNullableMember«; - // $TEST$ serialization Int? + # $TEST$ serialization Int? »nullableD()?.nullableMember«; - // $TEST$ serialization union<() -> (r: Int), Nothing?> + # $TEST$ serialization union<() -> (r: Int), Nothing?> »nullableD()?.method«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/to enum variants/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/to enum variants/main.sdstest index d970d712..41d68be7 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/to enum variants/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/to enum variants/main.sdstest @@ -7,22 +7,22 @@ enum MyEnum { } pipeline myPipeline { - // $TEST$ serialization MyEnum.MyEnumVariantWithoutParameterList + # $TEST$ serialization MyEnum.MyEnumVariantWithoutParameterList »MyEnum.MyEnumVariantWithoutParameterList«; - // $TEST$ serialization MyEnum.MyEnumVariantWithoutParameters + # $TEST$ serialization MyEnum.MyEnumVariantWithoutParameters »MyEnum.MyEnumVariantWithoutParameters«; - // $TEST$ serialization $type + # $TEST$ serialization $type »MyEnum.MyEnumVariantWithParameters«; - // $TEST$ serialization MyEnum.MyEnumVariantWithoutParameterList + # $TEST$ serialization MyEnum.MyEnumVariantWithoutParameterList »MyEnum?.MyEnumVariantWithoutParameterList«; - // $TEST$ serialization MyEnum.MyEnumVariantWithoutParameters + # $TEST$ serialization MyEnum.MyEnumVariantWithoutParameters »MyEnum?.MyEnumVariantWithoutParameters«; - // $TEST$ serialization $type + # $TEST$ serialization $type »MyEnum?.MyEnumVariantWithParameters«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/to nested classes/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/to nested classes/main.sdstest index 9c9ae1ed..dbd6501f 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/to nested classes/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/to nested classes/main.sdstest @@ -5,9 +5,9 @@ class MyClass { } pipeline myPipeline { - // $TEST$ serialization $type + # $TEST$ serialization $type »MyClass.MyNestedClass«; - // $TEST$ serialization $type + # $TEST$ serialization $type »MyClass?.MyNestedClass«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/to nested enums/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/to nested enums/main.sdstest index 66e3c74b..2e4b2a0b 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/to nested enums/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/to nested enums/main.sdstest @@ -5,9 +5,9 @@ class MyClass { } pipeline myPipeline { - // $TEST$ serialization $type + # $TEST$ serialization $type »MyClass.MyNestedEnum«; - // $TEST$ serialization $type + # $TEST$ serialization $type »MyClass?.MyNestedEnum«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/to other/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/to other/main.sdstest index f77c4900..9961d582 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/to other/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/to other/main.sdstest @@ -1,45 +1,45 @@ package tests.typing.expressions.memberAccesses.toOther class C() { - // $TEST$ equivalence_class nonNullableMember + # $TEST$ equivalence_class nonNullableMember attr »nonNullableMember«: Int - // $TEST$ equivalence_class nullableMember + # $TEST$ equivalence_class nullableMember attr »nullableMember«: Any? - // $TEST$ equivalence_class method + # $TEST$ equivalence_class method @Pure fun »method«() -> r: Int } fun nullableC() -> result: C? pipeline myPipeline { - // $TEST$ equivalence_class nonNullableMember + # $TEST$ equivalence_class nonNullableMember »C().nonNullableMember«; - // $TEST$ equivalence_class nullableMember + # $TEST$ equivalence_class nullableMember »C().nullableMember«; - // $TEST$ equivalence_class method + # $TEST$ equivalence_class method »C().method«; - // $TEST$ equivalence_class nonNullableMember + # $TEST$ equivalence_class nonNullableMember »C()?.nonNullableMember«; - // $TEST$ equivalence_class nullableMember + # $TEST$ equivalence_class nullableMember »C()?.nullableMember«; - // $TEST$ equivalence_class method + # $TEST$ equivalence_class method »C()?.method«; - // $TEST$ equivalence_class nonNullableMember + # $TEST$ equivalence_class nonNullableMember »nullableC().nonNullableMember«; - // $TEST$ equivalence_class nullableMember + # $TEST$ equivalence_class nullableMember »nullableC().nullableMember«; - // $TEST$ equivalence_class method + # $TEST$ equivalence_class method »nullableC().method«; - // $TEST$ serialization Int? + # $TEST$ serialization Int? »nullableC()?.nonNullableMember«; - // $TEST$ equivalence_class nullableMember + # $TEST$ equivalence_class nullableMember »nullableC()?.nullableMember«; - // $TEST$ serialization union<() -> (r: Int), Nothing?> + # $TEST$ serialization union<() -> (r: Int), Nothing?> »nullableC()?.method«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/unresolved/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/unresolved/main.sdstest index 9cef6afd..601e131a 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/unresolved/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/unresolved/main.sdstest @@ -3,9 +3,9 @@ package tests.typing.expressions.memberAccesses.unresolved class C pipeline myPipeline { - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown »C.unresolved«; - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown »C?.unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/operations/arithmetic/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/operations/arithmetic/main.sdstest index 57046ac4..984f4461 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/operations/arithmetic/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/operations/arithmetic/main.sdstest @@ -4,140 +4,140 @@ fun anyInt() -> r: Int fun anyFloat() -> r: Float pipeline constantOperands { - // $TEST$ serialization literal<2> + # $TEST$ serialization literal<2> val additionIntInt = »1 + 1«; - // $TEST$ serialization literal<0> + # $TEST$ serialization literal<0> val subtractionIntInt = »1 - 1«; - // $TEST$ serialization literal<1> + # $TEST$ serialization literal<1> val multiplicationIntInt = »1 * 1«; - // $TEST$ serialization literal<1> + # $TEST$ serialization literal<1> val divisionIntInt = »1 / 1«; - // $TEST$ serialization literal<2.5> + # $TEST$ serialization literal<2.5> val additionIntFloat = »1 + 1.5«; - // $TEST$ serialization literal<-0.5> + # $TEST$ serialization literal<-0.5> val subtractionIntFloat = »1 - 1.5«; - // $TEST$ serialization literal<1.5> + # $TEST$ serialization literal<1.5> val multiplicationIntFloat = »1 * 1.5«; - // $TEST$ serialization literal<1.6> + # $TEST$ serialization literal<1.6> val divisionIntFloat = »1 / 0.625«; - // $TEST$ serialization literal<2.5> + # $TEST$ serialization literal<2.5> val additionFloatInt = »1.5 + 1«; - // $TEST$ serialization literal<0.5> + # $TEST$ serialization literal<0.5> val subtractionFloatInt = »1.5 - 1«; - // $TEST$ serialization literal<1.5> + # $TEST$ serialization literal<1.5> val multiplicationFloatInt = »1.5 * 1«; - // $TEST$ serialization literal<1.5> + # $TEST$ serialization literal<1.5> val divisionFloatInt = »1.5 / 1«; - // $TEST$ serialization literal<2.75> + # $TEST$ serialization literal<2.75> val additionFloatFloat = »1.5 + 1.25«; - // $TEST$ serialization literal<0.25> + # $TEST$ serialization literal<0.25> val subtractionFloatFloat = »1.5 - 1.25«; - // $TEST$ serialization literal<1.875> + # $TEST$ serialization literal<1.875> val multiplicationFloatFloat = »1.5 * 1.25«; - // $TEST$ serialization literal<0.6> + # $TEST$ serialization literal<0.6> val divisionFloatFloat = »1.5 / 2.5«; - // $TEST$ serialization literal<-1> + # $TEST$ serialization literal<-1> val negationInt = »-1«; - // $TEST$ serialization literal<-1.5> + # $TEST$ serialization literal<-1.5> val negationFloat = »-1.5«; } pipeline invalidOperands { - // $TEST$ serialization Float + # $TEST$ serialization Float val additionInvalid = »true + true«; - // $TEST$ serialization Float + # $TEST$ serialization Float val subtractionInvalid = »true - true«; - // $TEST$ serialization Float + # $TEST$ serialization Float val multiplicationInvalid = »true * true«; - // $TEST$ serialization Float + # $TEST$ serialization Float val divisionInvalid = »true / true«; - // $TEST$ serialization Float + # $TEST$ serialization Float val negationInvalid = »-true«; } pipeline nonConstantOperands { - // $TEST$ serialization Int + # $TEST$ serialization Int val additionIntInt = »anyInt() + anyInt()«; - // $TEST$ serialization Int + # $TEST$ serialization Int val subtractionIntInt = »anyInt() - anyInt()«; - // $TEST$ serialization Int + # $TEST$ serialization Int val multiplicationIntInt = »anyInt() * anyInt()«; - // $TEST$ serialization Int + # $TEST$ serialization Int val divisionIntInt = »anyInt() / anyInt()«; - // $TEST$ serialization Float + # $TEST$ serialization Float val additionIntFloat = »anyInt() + anyFloat()«; - // $TEST$ serialization Float + # $TEST$ serialization Float val subtractionIntFloat = »anyInt() - anyFloat()«; - // $TEST$ serialization Float + # $TEST$ serialization Float val multiplicationIntFloat = »anyInt() * anyFloat()«; - // $TEST$ serialization Float + # $TEST$ serialization Float val divisionIntFloat = »anyInt() / anyFloat()«; - // $TEST$ serialization Float + # $TEST$ serialization Float val additionFloatInt = »anyFloat() + anyInt()«; - // $TEST$ serialization Float + # $TEST$ serialization Float val subtractionFloatInt = »anyFloat() - anyInt()«; - // $TEST$ serialization Float + # $TEST$ serialization Float val multiplicationFloatInt = »anyFloat() * anyInt()«; - // $TEST$ serialization Float + # $TEST$ serialization Float val divisionFloatInt = »anyFloat() / anyInt()«; - // $TEST$ serialization Float + # $TEST$ serialization Float val additionFloatFloat = »anyFloat() + anyFloat()«; - // $TEST$ serialization Float + # $TEST$ serialization Float val subtractionFloatFloat = »anyFloat() - anyFloat()«; - // $TEST$ serialization Float + # $TEST$ serialization Float val multiplicationFloatFloat = »anyFloat() * anyFloat()«; - // $TEST$ serialization Float + # $TEST$ serialization Float val divisionFloatFloat = »anyFloat() / anyFloat()«; - // $TEST$ serialization Int + # $TEST$ serialization Int val negationInt = »-anyInt()«; - // $TEST$ serialization Float + # $TEST$ serialization Float val negationFloat = »-anyFloat()«; } pipeline mixedOperands { - // $TEST$ serialization Int + # $TEST$ serialization Int val additionIntInt = »10 + anyInt()«; - // $TEST$ serialization Int + # $TEST$ serialization Int val subtractionIntInt = »10 - anyInt()«; - // $TEST$ serialization Int + # $TEST$ serialization Int val multiplicationIntInt = »10 * anyInt()«; - // $TEST$ serialization Int + # $TEST$ serialization Int val divisionIntInt = »10 / anyInt()«; - // $TEST$ serialization Float + # $TEST$ serialization Float val additionIntFloat = »10 + anyFloat()«; - // $TEST$ serialization Float + # $TEST$ serialization Float val subtractionIntFloat = »10 - anyFloat()«; - // $TEST$ serialization Float + # $TEST$ serialization Float val multiplicationIntFloat = »10 * anyFloat()«; - // $TEST$ serialization Float + # $TEST$ serialization Float val divisionIntFloat = »10 / anyFloat()«; - // $TEST$ serialization Float + # $TEST$ serialization Float val additionFloatInt = »1.5 + anyInt()«; - // $TEST$ serialization Float + # $TEST$ serialization Float val subtractionFloatInt = »1.5 - anyInt()«; - // $TEST$ serialization Float + # $TEST$ serialization Float val multiplicationFloatInt = »1.5 * anyInt()«; - // $TEST$ serialization Float + # $TEST$ serialization Float val divisionFloatInt = »1.5 / anyInt()«; - // $TEST$ serialization Float + # $TEST$ serialization Float val additionFloatFloat = »1.5 + anyFloat()«; - // $TEST$ serialization Float + # $TEST$ serialization Float val subtractionFloatFloat = »1.5 - anyFloat()«; - // $TEST$ serialization Float + # $TEST$ serialization Float val multiplicationFloatFloat = »1.5 * anyFloat()«; - // $TEST$ serialization Float + # $TEST$ serialization Float val divisionFloatFloat = »1.5 / anyFloat()«; } @@ -145,10 +145,10 @@ pipeline mixedOperands { class MyClass( p1: T, - // $TEST$ serialization Float + # $TEST$ serialization Float p2: Any? = »p1 + 1«, - // $TEST$ serialization Float + # $TEST$ serialization Float p3: Any? = »1 + p1«, - // $TEST$ serialization Float + # $TEST$ serialization Float p4: Any? = »-p1«, ) diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/operations/comparison/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/operations/comparison/main.sdstest index 1aa39738..e362d0c2 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/operations/comparison/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/operations/comparison/main.sdstest @@ -1,21 +1,21 @@ package tests.typing.operations.comparison pipeline myPipeline { - // $TEST$ serialization literal + # $TEST$ serialization literal val lessThan = »1 < 1«; - // $TEST$ serialization literal + # $TEST$ serialization literal val lessThanOrEquals = »1 <= 1«; - // $TEST$ serialization literal + # $TEST$ serialization literal val greaterThanOrEquals = »1 >= 1«; - // $TEST$ serialization literal + # $TEST$ serialization literal val greaterThan = »1 > 1«; - // $TEST$ serialization Boolean + # $TEST$ serialization Boolean val lessThanInvalid = »true < true«; - // $TEST$ serialization Boolean + # $TEST$ serialization Boolean val lessThanOrEqualsInvalid = »true <= true«; - // $TEST$ serialization Boolean + # $TEST$ serialization Boolean val greaterThanOrEqualsInvalid = »true >= true«; - // $TEST$ serialization Boolean + # $TEST$ serialization Boolean val greaterThanInvalid = »true > true«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/operations/elvis/non nullable left operand.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/operations/elvis/non nullable left operand.sdstest index 0c69a9d1..8e4e33ef 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/operations/elvis/non nullable left operand.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/operations/elvis/non nullable left operand.sdstest @@ -4,29 +4,29 @@ package tests.typing.operations.elvis.nonNullableLeftOperand @Pure fun intOrNull() -> a: Int? pipeline elvisWithNonNullableLeftOperand { - // $TEST$ equivalence_class leftOperand1 + # $TEST$ equivalence_class leftOperand1 »1«; - // $TEST$ equivalence_class leftOperand1 + # $TEST$ equivalence_class leftOperand1 »1 ?: intOrNull()«; - // $TEST$ equivalence_class leftOperand1 + # $TEST$ equivalence_class leftOperand1 »1 ?: 1«; - // $TEST$ equivalence_class leftOperand1 + # $TEST$ equivalence_class leftOperand1 »1 ?: 1.0«; - // $TEST$ equivalence_class leftOperand1 + # $TEST$ equivalence_class leftOperand1 »1 ?: ""«; - // $TEST$ equivalence_class leftOperand1 + # $TEST$ equivalence_class leftOperand1 »1 ?: null«; - // $TEST$ equivalence_class leftOperand2 + # $TEST$ equivalence_class leftOperand2 »int()«; - // $TEST$ equivalence_class leftOperand2 + # $TEST$ equivalence_class leftOperand2 »int() ?: intOrNull()«; - // $TEST$ equivalence_class leftOperand2 + # $TEST$ equivalence_class leftOperand2 »int() ?: 1«; - // $TEST$ equivalence_class leftOperand2 + # $TEST$ equivalence_class leftOperand2 »int() ?: 1.0«; - // $TEST$ equivalence_class leftOperand2 + # $TEST$ equivalence_class leftOperand2 »int() ?: ""«; - // $TEST$ equivalence_class leftOperand2 + # $TEST$ equivalence_class leftOperand2 »int() ?: null«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/operations/elvis/nullable left operand.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/operations/elvis/nullable left operand.sdstest index 099e092e..7b4dbd9a 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/operations/elvis/nullable left operand.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/operations/elvis/nullable left operand.sdstest @@ -4,16 +4,16 @@ package tests.typing.operations.elvis.nullableLeftOperand @Pure fun stringOrNull() -> s: String? pipeline elvisWithNullableLeftOperand { - // $TEST$ serialization Int? + # $TEST$ serialization Int? »intOrNull() ?: intOrNull()«; - // $TEST$ serialization Int? + # $TEST$ serialization Int? »intOrNull() ?: null«; - // $TEST$ serialization Int + # $TEST$ serialization Int »intOrNull() ?: 1«; - // $TEST$ serialization Number + # $TEST$ serialization Number »intOrNull() ?: 1.0«; - // $TEST$ serialization Any + # $TEST$ serialization Any »intOrNull() ?: ""«; - // $TEST$ serialization Any? + # $TEST$ serialization Any? »intOrNull() ?: stringOrNull()«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/operations/equality/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/operations/equality/main.sdstest index 6d7ffa53..e2b6223b 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/operations/equality/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/operations/equality/main.sdstest @@ -1,22 +1,22 @@ package tests.typing.operations.equality pipeline myPipeline { - // $TEST$ serialization literal + # $TEST$ serialization literal val equals = (»1 == 1«); - // $TEST$ serialization literal + # $TEST$ serialization literal val notEquals = (»1 != 1«); - // $TEST$ serialization literal + # $TEST$ serialization literal val identicalTo = (»1 === 1«); - // $TEST$ serialization literal + # $TEST$ serialization literal val notIdenticalTo = (»1 !== 1«); - // $TEST$ serialization Boolean + # $TEST$ serialization Boolean val nonConstantEquals = (»1 == unresolved«); - // $TEST$ serialization Boolean + # $TEST$ serialization Boolean val nonConstantNotEquals = (»1 != unresolved«); - // $TEST$ serialization Boolean + # $TEST$ serialization Boolean val nonConstantIdenticalTo = (»1 === unresolved«); - // $TEST$ serialization Boolean + # $TEST$ serialization Boolean val nonConstantNotIdenticalTo = (»1 !== unresolved«); } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/operations/logical/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/operations/logical/main.sdstest index 2428e6b4..39c328fa 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/operations/logical/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/operations/logical/main.sdstest @@ -1,17 +1,17 @@ package tests.typing.operations.logical pipeline myPipeline { - // $TEST$ serialization literal + # $TEST$ serialization literal val conjunction = »true and true«; - // $TEST$ serialization literal + # $TEST$ serialization literal val disjunction = »true or true«; - // $TEST$ serialization literal + # $TEST$ serialization literal val negation = »not true«; - // $TEST$ serialization Boolean + # $TEST$ serialization Boolean val conjunctionInvalid = »1 and 1«; - // $TEST$ serialization Boolean + # $TEST$ serialization Boolean val disjunctionInvalid = »1.0 or 1.0«; - // $TEST$ serialization Boolean + # $TEST$ serialization Boolean val negationInvalid = »not "true"«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/parenthesized expressions/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/parenthesized expressions/main.sdstest index 7695ced7..8da5a246 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/parenthesized expressions/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/parenthesized expressions/main.sdstest @@ -1,23 +1,23 @@ package tests.typing.expressions.parenthesizedExpressions pipeline myPipeline { - // $TEST$ equivalence_class boolean - // $TEST$ equivalence_class boolean + # $TEST$ equivalence_class boolean + # $TEST$ equivalence_class boolean »(»true«)«; - // $TEST$ equivalence_class float - // $TEST$ equivalence_class float + # $TEST$ equivalence_class float + # $TEST$ equivalence_class float »(»1.0«)«; - // $TEST$ equivalence_class int - // $TEST$ equivalence_class int + # $TEST$ equivalence_class int + # $TEST$ equivalence_class int »(»1«)«; - // $TEST$ equivalence_class null - // $TEST$ equivalence_class null + # $TEST$ equivalence_class null + # $TEST$ equivalence_class null »(»null«)«; - // $TEST$ equivalence_class string - // $TEST$ equivalence_class string + # $TEST$ equivalence_class string + # $TEST$ equivalence_class string »(»""«)«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/references/to global classes/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/references/to global classes/main.sdstest index 1d2be92c..ae1d50c4 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/references/to global classes/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/references/to global classes/main.sdstest @@ -3,6 +3,6 @@ package tests.typing.expressions.references.toGlobalClasses class MyClass pipeline myPipeline { - // $TEST$ serialization $type + # $TEST$ serialization $type »MyClass«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/references/to global enums/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/references/to global enums/main.sdstest index 03b51756..a75c2e08 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/references/to global enums/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/references/to global enums/main.sdstest @@ -3,6 +3,6 @@ package tests.typing.expressions.references.toGlobalEnums enum MyEnum pipeline myPipeline { - // $TEST$ serialization $type + # $TEST$ serialization $type »MyEnum«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/references/to other/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/references/to other/main.sdstest index e284e171..6c197d53 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/references/to other/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/references/to other/main.sdstest @@ -1,13 +1,13 @@ package tests.typing.expressions.references.toOther segment mySegment( - // $TEST$ equivalence_class p1 + # $TEST$ equivalence_class p1 »p1«: Int, - // $TEST$ equivalence_class p2 + # $TEST$ equivalence_class p2 »p2«: String ) { - // $TEST$ equivalence_class p1 + # $TEST$ equivalence_class p1 »p1«; - // $TEST$ equivalence_class p2 + # $TEST$ equivalence_class p2 »p2«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/references/unresolved/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/references/unresolved/main.sdstest index a14b2c6e..355117c4 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/references/unresolved/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/references/unresolved/main.sdstest @@ -1,6 +1,6 @@ package tests.typing.expressions.references.unresolved pipeline myPipeline { - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown »unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/template strings/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/template strings/main.sdstest index bf878f09..98786622 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/template strings/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/template strings/main.sdstest @@ -1,9 +1,9 @@ package tests.typing.expressions.templateStrings pipeline myPipeline { - // $TEST$ serialization literal<"1 + 2 = 3"> + # $TEST$ serialization literal<"1 + 2 = 3"> val valid = »"1 + 2 = {{ 1 + 2 }}"«; - // $TEST$ serialization String + # $TEST$ serialization String val invalid = »"1 + 2 = {{ unresolved }}"«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/type casts/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/type casts/main.sdstest index aee79776..07ee7569 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/type casts/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/type casts/main.sdstest @@ -3,12 +3,12 @@ package tests.typing.expressions.typeCasts @Pure fun f() -> r: Int pipeline myPipeline { - // $TEST$ serialization Boolean + # $TEST$ serialization Boolean »1 as Boolean«; // Partial evaluator can handle expression - // $TEST$ serialization Boolean + # $TEST$ serialization Boolean »r as Boolean«; // Partial evaluator cannot handle expression - // $TEST$ serialization Boolean + # $TEST$ serialization Boolean »unresolved as Boolean«; // Expression has unknown type } diff --git a/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and class type/cannot stop if class has no type parameters.sdstest b/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and class type/cannot stop if class has no type parameters.sdstest index 5743b68c..b59396de 100644 --- a/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and class type/cannot stop if class has no type parameters.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and class type/cannot stop if class has no type parameters.sdstest @@ -9,6 +9,6 @@ segment mySegment( p1: Contravariant>, p2: Contravariant, ) { - // $TEST$ serialization List> + # $TEST$ serialization List> »[p1, p2]«; } diff --git a/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and class type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and class type/main.sdstest index 0282a7a4..21958d20 100644 --- a/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and class type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and class type/main.sdstest @@ -16,27 +16,27 @@ segment mySegment1( e: Contravariant, eOrNull: Contravariant, ) { - // $TEST$ serialization List> + # $TEST$ serialization List> »[c, c]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[c, cOrNull]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[c, d]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[c, dOrNull]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[c, e]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[c, eOrNull]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[cOrNull, cOrNull]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[cOrNull, d]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[cOrNull, dOrNull]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[cOrNull, e]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[cOrNull, eOrNull]«; } diff --git a/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and class type/with type parameters.sdstest b/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and class type/with type parameters.sdstest index f67c8743..1ee940c0 100644 --- a/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and class type/with type parameters.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and class type/with type parameters.sdstest @@ -11,39 +11,39 @@ segment covariant( coFloat: Contravariant, coFloat2: Contravariant>, ) { - // $TEST$ serialization List>> + # $TEST$ serialization List>> »[coNumber, coNumber]«; - // $TEST$ serialization List>> + # $TEST$ serialization List>> »[coNumber, coInt]«; - // $TEST$ serialization List>> + # $TEST$ serialization List>> »[coNumber, coString]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[coNumber, coFloat]«; - // $TEST$ serialization List>> + # $TEST$ serialization List>> »[coNumber, coFloat2]«; - // $TEST$ serialization List>> + # $TEST$ serialization List>> »[coInt, coInt]«; - // $TEST$ serialization List>> + # $TEST$ serialization List>> »[coInt, coString]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[coInt, coFloat]«; - // $TEST$ serialization List>> + # $TEST$ serialization List>> »[coInt, coFloat2]«; - // $TEST$ serialization List>> + # $TEST$ serialization List>> »[coString, coString]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[coString, coFloat]«; - // $TEST$ serialization List>> + # $TEST$ serialization List>> »[coString, coFloat2]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[coFloat, coFloat]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[coFloat, coFloat2]«; - // $TEST$ serialization List>> + # $TEST$ serialization List>> »[coFloat2, coFloat2]«; } @@ -55,7 +55,7 @@ segment contravariant( ) { // Most tests are in the "lowest common supertype" folder. Here we only test that we call the right method. - // $TEST$ serialization List>> + # $TEST$ serialization List>> »[contraFloat, contraInt]«; } @@ -70,39 +70,39 @@ segment invariant( invInt2: Contravariant, invInt3: Contravariant>, ) { - // $TEST$ serialization List>> + # $TEST$ serialization List>> »[invNumber, invNumber]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[invNumber, invInt]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[invNumber, invString]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[invNumber, invInt2]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[invNumber, invInt3]«; - // $TEST$ serialization List>> + # $TEST$ serialization List>> »[invInt, invInt]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[invInt, invString]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[invInt, invInt2]«; - // $TEST$ serialization List>> + # $TEST$ serialization List>> »[invInt, invInt3]«; - // $TEST$ serialization List>> + # $TEST$ serialization List>> »[invString, invString]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[invString, invInt2]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[invString, invInt3]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[invInt2, invInt2]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[invInt2, invInt3]«; - // $TEST$ serialization List>> + # $TEST$ serialization List>> »[invInt3, invInt3]«; } @@ -112,11 +112,11 @@ segment multiple( multipleNumberNumber: Contravariant>, multipleNumberFloat: Contravariant>, ) { - // $TEST$ serialization List>> + # $TEST$ serialization List>> »[multipleNumberNumber, multipleNumberNumber]«; - // $TEST$ serialization List>> + # $TEST$ serialization List>> »[multipleNumberNumber, multipleNumberFloat]«; - // $TEST$ serialization List>> + # $TEST$ serialization List>> »[multipleNumberFloat, multipleNumberFloat]«; } diff --git a/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and enum type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and enum type/main.sdstest index a36b52cc..5c0a1ee2 100644 --- a/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and enum type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and enum type/main.sdstest @@ -14,21 +14,21 @@ segment mySegment( e: Contravariant, eOrNull: Contravariant, ) { - // $TEST$ serialization List> + # $TEST$ serialization List> »[any, e]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[anyOrNull, e]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[any, eOrNull]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[anyOrNull, eOrNull]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[c, e]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[cOrNull, e]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[c, eOrNull]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[cOrNull, eOrNull]«; } diff --git a/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and enum variant/main.sdstest b/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and enum variant/main.sdstest index f7ff7cc1..64a697bb 100644 --- a/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and enum variant/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and enum variant/main.sdstest @@ -16,21 +16,21 @@ segment mySegment( v: Contravariant, vOrNull: Contravariant, ) { - // $TEST$ serialization List> + # $TEST$ serialization List> »[any, v]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[anyOrNull, v]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[any, vOrNull]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[anyOrNull, vOrNull]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[c, v]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[cOrNull, v]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[c, vOrNull]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[cOrNull, vOrNull]«; } diff --git a/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and literal type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and literal type/main.sdstest index c228385c..e17eee28 100644 --- a/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and literal type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and literal type/main.sdstest @@ -19,52 +19,52 @@ segment mySegment( nothing: Contravariant, nothingOrNull: Contravariant, ) { - // $TEST$ serialization List> + # $TEST$ serialization List> »[one, c]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[one, cOrNull]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[oneOrNull, cOrNull]«; - // $TEST$ serialization List>> + # $TEST$ serialization List>> »[one, int]«; - // $TEST$ serialization List>> + # $TEST$ serialization List>> »[one, intOrNull]«; - // $TEST$ serialization List>> + # $TEST$ serialization List>> »[oneOrNull, intOrNull]«; - // $TEST$ serialization List>> + # $TEST$ serialization List>> »[one, number]«; - // $TEST$ serialization List>> + # $TEST$ serialization List>> »[one, numberOrNull]«; - // $TEST$ serialization List>> + # $TEST$ serialization List>> »[oneOrNull, numberOrNull]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[one, string]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[one, stringOrNull]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[oneOrNull, stringOrNull]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[one, nothing]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[one, nothingOrNull]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[oneOrNull, nothingOrNull]«; } diff --git a/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and type parameter type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and type parameter type/main.sdstest index 9586a80c..4abae894 100644 --- a/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and type parameter type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and type parameter type/main.sdstest @@ -22,29 +22,29 @@ class Test< toDOrNullExplicit: Contravariant, toE: Contravariant, - // $TEST$ serialization List> + # $TEST$ serialization List> a1: Any = »[c, toAnyOrNull]«, - // $TEST$ serialization List> + # $TEST$ serialization List> a2: Any = »[c, toAnyOrNullExplicit]«, - // $TEST$ serialization List> + # $TEST$ serialization List> a3: Any = »[c, toC]«, - // $TEST$ serialization List> + # $TEST$ serialization List> a4: Any = »[c, toD]«, - // $TEST$ serialization List> + # $TEST$ serialization List> a5: Any = »[c, toDOrNullExplicit]«, - // $TEST$ serialization List> + # $TEST$ serialization List> a6: Any = »[c, toE]«, - // $TEST$ serialization List> + # $TEST$ serialization List> b1: Any = »[cOrNull, toAnyOrNull]«, - // $TEST$ serialization List> + # $TEST$ serialization List> b2: Any = »[cOrNull, toAnyOrNullExplicit]«, - // $TEST$ serialization List> + # $TEST$ serialization List> b3: Any = »[cOrNull, toC]«, - // $TEST$ serialization List> + # $TEST$ serialization List> b4: Any = »[cOrNull, toD]«, - // $TEST$ serialization List> + # $TEST$ serialization List> b5: Any = »[cOrNull, toDOrNullExplicit]«, - // $TEST$ serialization List> + # $TEST$ serialization List> b6: Any = »[cOrNull, toE]«, ) diff --git a/packages/ttsl-lang/tests/resources/typing/highest common subtype/enum type and enum type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/highest common subtype/enum type and enum type/main.sdstest index c2d540b2..accbcf08 100644 --- a/packages/ttsl-lang/tests/resources/typing/highest common subtype/enum type and enum type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/highest common subtype/enum type and enum type/main.sdstest @@ -11,22 +11,22 @@ segment mySegment( e2: Contravariant, e2OrNull: Contravariant ) { - // $TEST$ serialization List> + # $TEST$ serialization List> »[e1, e1]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[e1, e1OrNull]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[e1OrNull, e1OrNull]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[e1, e2]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[e1, e2OrNull]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[e1OrNull, e2OrNull]«; } diff --git a/packages/ttsl-lang/tests/resources/typing/highest common subtype/enum type and enum variant type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/highest common subtype/enum type and enum variant type/main.sdstest index 459b2b93..1d58e7fe 100644 --- a/packages/ttsl-lang/tests/resources/typing/highest common subtype/enum type and enum variant type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/highest common subtype/enum type and enum variant type/main.sdstest @@ -17,22 +17,22 @@ segment mySegment( v2: Contravariant, v2OrNull: Contravariant, ) { - // $TEST$ serialization List> + # $TEST$ serialization List> »[e1, v1]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[e1, v1OrNull]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[e1OrNull, v1OrNull]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[e1, v2]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[e1, v2OrNull]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[e1OrNull, v2OrNull]«; } diff --git a/packages/ttsl-lang/tests/resources/typing/highest common subtype/enum type and type parameter type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/highest common subtype/enum type and type parameter type/main.sdstest index 852368bf..1a629057 100644 --- a/packages/ttsl-lang/tests/resources/typing/highest common subtype/enum type and type parameter type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/highest common subtype/enum type and type parameter type/main.sdstest @@ -24,29 +24,29 @@ class Test< toVOrNullExplicit: Contravariant, toF: Contravariant, - // $TEST$ serialization List> + # $TEST$ serialization List> a1: Any = »[e, toAnyOrNull]«, - // $TEST$ serialization List> + # $TEST$ serialization List> a2: Any = »[e, toAnyOrNullExplicit]«, - // $TEST$ serialization List> + # $TEST$ serialization List> a3: Any = »[e, toE]«, - // $TEST$ serialization List> + # $TEST$ serialization List> a4: Any = »[e, toV]«, - // $TEST$ serialization List> + # $TEST$ serialization List> a5: Any = »[e, toVOrNullExplicit]«, - // $TEST$ serialization List> + # $TEST$ serialization List> a6: Any = »[e, toF]«, - // $TEST$ serialization List> + # $TEST$ serialization List> b1: Any = »[eOrNull, toAnyOrNull]«, - // $TEST$ serialization List> + # $TEST$ serialization List> b2: Any = »[eOrNull, toAnyOrNullExplicit]«, - // $TEST$ serialization List> + # $TEST$ serialization List> b3: Any = »[eOrNull, toE]«, - // $TEST$ serialization List> + # $TEST$ serialization List> b4: Any = »[eOrNull, toV]«, - // $TEST$ serialization List> + # $TEST$ serialization List> b5: Any = »[eOrNull, toVOrNullExplicit]«, - // $TEST$ serialization List> + # $TEST$ serialization List> b6: Any = »[eOrNull, toF]«, ) diff --git a/packages/ttsl-lang/tests/resources/typing/highest common subtype/enum variant type and enum variant type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/highest common subtype/enum variant type and enum variant type/main.sdstest index 33c9919e..9a62e91b 100644 --- a/packages/ttsl-lang/tests/resources/typing/highest common subtype/enum variant type and enum variant type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/highest common subtype/enum variant type and enum variant type/main.sdstest @@ -18,32 +18,32 @@ segment mySegment( v3: Contravariant, v3OrNull: Contravariant ) { - // $TEST$ serialization List> + # $TEST$ serialization List> »[v1, v1]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[v1, v1OrNull]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[v1OrNull, v1OrNull]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[v1, v2]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[v1, v2OrNull]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[v1OrNull, v2OrNull]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[v1, v3]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[v1, v3OrNull]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[v1OrNull, v3OrNull]«; } diff --git a/packages/ttsl-lang/tests/resources/typing/highest common subtype/enum variant type and type parameter type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/highest common subtype/enum variant type and type parameter type/main.sdstest index 82b1ef21..09b54a37 100644 --- a/packages/ttsl-lang/tests/resources/typing/highest common subtype/enum variant type and type parameter type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/highest common subtype/enum variant type and type parameter type/main.sdstest @@ -21,25 +21,25 @@ class Test< toV1OrNullExplicit: Contravariant, toV2: Contravariant, - // $TEST$ serialization List> + # $TEST$ serialization List> a1: Any = »[v1, toAnyOrNull]«, - // $TEST$ serialization List> + # $TEST$ serialization List> a2: Any = »[v1, toAnyOrNullExplicit]«, - // $TEST$ serialization List> + # $TEST$ serialization List> a3: Any = »[v1, toV1]«, - // $TEST$ serialization List> + # $TEST$ serialization List> a4: Any = »[v1, toV1OrNullExplicit]«, - // $TEST$ serialization List> + # $TEST$ serialization List> a5: Any = »[v1, toV2]«, - // $TEST$ serialization List> + # $TEST$ serialization List> b1: Any = »[v1OrNull, toAnyOrNull]«, - // $TEST$ serialization List> + # $TEST$ serialization List> b2: Any = »[v1OrNull, toAnyOrNullExplicit]«, - // $TEST$ serialization List> + # $TEST$ serialization List> b3: Any = »[v1OrNull, toV1]«, - // $TEST$ serialization List> + # $TEST$ serialization List> b4: Any = »[v1OrNull, toV1OrNullExplicit]«, - // $TEST$ serialization List> + # $TEST$ serialization List> b5: Any = »[v1OrNull, toV2]«, ) diff --git a/packages/ttsl-lang/tests/resources/typing/highest common subtype/incompatible types/main.sdstest b/packages/ttsl-lang/tests/resources/typing/highest common subtype/incompatible types/main.sdstest index 870a0a6f..0c731ad0 100644 --- a/packages/ttsl-lang/tests/resources/typing/highest common subtype/incompatible types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/highest common subtype/incompatible types/main.sdstest @@ -16,24 +16,24 @@ segment mySegment( v: Contravariant, vOrNull: Contravariant ) { - // $TEST$ serialization List> + # $TEST$ serialization List> »[one, e]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[oneOrNull, e]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[one, eOrNull]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[oneOrNull, eOrNull]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[one, v]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[oneOrNull, v]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[one, vOrNull]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[oneOrNull, vOrNull]«; } @@ -44,13 +44,13 @@ class Test( t: Contravariant, tOrNull: Contravariant, - // $TEST$ serialization List> + # $TEST$ serialization List> p1: Any = »[one, t]«, - // $TEST$ serialization List> + # $TEST$ serialization List> p2: Any = »[one, tOrNull]«, - // $TEST$ serialization List> + # $TEST$ serialization List> p3: Any = »[oneOrNull, t]«, - // $TEST$ serialization List> + # $TEST$ serialization List> p4: Any = »[oneOrNull, tOrNull]« ) diff --git a/packages/ttsl-lang/tests/resources/typing/highest common subtype/literal type and literal type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/highest common subtype/literal type and literal type/main.sdstest index 01be3a8c..3e8070c8 100644 --- a/packages/ttsl-lang/tests/resources/typing/highest common subtype/literal type and literal type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/highest common subtype/literal type and literal type/main.sdstest @@ -7,12 +7,12 @@ segment mySegment( p2: Contravariant>, p3: Contravariant>, ) { - // $TEST$ serialization List>> + # $TEST$ serialization List>> »[p1, p1]«; - // $TEST$ serialization List>> + # $TEST$ serialization List>> »[p1, p2]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[p1, p3]«; } diff --git a/packages/ttsl-lang/tests/resources/typing/highest common subtype/simplification/main.sdstest b/packages/ttsl-lang/tests/resources/typing/highest common subtype/simplification/main.sdstest index 8afda84c..a565e0de 100644 --- a/packages/ttsl-lang/tests/resources/typing/highest common subtype/simplification/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/highest common subtype/simplification/main.sdstest @@ -7,15 +7,15 @@ segment mySegment( p2: Contravariant>, p3: Contravariant, literal>>, ) { - // $TEST$ serialization List> + # $TEST$ serialization List> »[p1, p2]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[p1, p3]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[p2, p3]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[p3, p3]«; } diff --git a/packages/ttsl-lang/tests/resources/typing/highest common subtype/type parameter type and type parameter type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/highest common subtype/type parameter type and type parameter type/main.sdstest index 829c20a9..02d37d94 100644 --- a/packages/ttsl-lang/tests/resources/typing/highest common subtype/type parameter type and type parameter type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/highest common subtype/type parameter type and type parameter type/main.sdstest @@ -8,19 +8,19 @@ class Test( t2: Contravariant, t2OrNull: Contravariant, - // $TEST$ serialization List> + # $TEST$ serialization List> a1: Any = »[t1, t1]«, - // $TEST$ serialization List> + # $TEST$ serialization List> a2: Any = »[t1, t1OrNull]«, - // $TEST$ serialization List> + # $TEST$ serialization List> a3: Any = »[t1, t2]«, - // $TEST$ serialization List> + # $TEST$ serialization List> a4: Any = »[t1, t2OrNull]«, - // $TEST$ serialization List> + # $TEST$ serialization List> b1: Any = »[t1OrNull, t1OrNull]«, - // $TEST$ serialization List> + # $TEST$ serialization List> b2: Any = »[t1OrNull, t2]«, - // $TEST$ serialization List> + # $TEST$ serialization List> b3: Any = »[t1OrNull, t2OrNull]«, ) diff --git a/packages/ttsl-lang/tests/resources/typing/highest common subtype/unhandled type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/highest common subtype/unhandled type/main.sdstest index 15f6062d..09a3c2da 100644 --- a/packages/ttsl-lang/tests/resources/typing/highest common subtype/unhandled type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/highest common subtype/unhandled type/main.sdstest @@ -13,21 +13,21 @@ segment mySegment( // Named tuple types and static types are also not handled, but we can't test them here ) { - // $TEST$ serialization List> + # $TEST$ serialization List> »[one, `union`]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[oneOrNull, `union`]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[one, unionOrNull]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[oneOrNull, unionOrNull]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[one, callable]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[oneOrNull, callable]«; } diff --git a/packages/ttsl-lang/tests/resources/typing/highest common subtype/unknown type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/highest common subtype/unknown type/main.sdstest index 2ad0d112..31749d27 100644 --- a/packages/ttsl-lang/tests/resources/typing/highest common subtype/unknown type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/highest common subtype/unknown type/main.sdstest @@ -7,9 +7,9 @@ segment mySegment( nullable: Contravariant>, unknown: Contravariant, ) { - // $TEST$ serialization List> + # $TEST$ serialization List> »[one, unknown]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[nullable, unknown]«; } diff --git a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/class type and class type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/class type and class type/main.sdstest index 56108684..86843c9c 100644 --- a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/class type and class type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/class type and class type/main.sdstest @@ -12,23 +12,23 @@ segment mySegment1( e: E, eOrNull: E?, ) { - // $TEST$ serialization List + # $TEST$ serialization List »[c, c]«; - // $TEST$ serialization List + # $TEST$ serialization List »[c, cOrNull]«; - // $TEST$ serialization List + # $TEST$ serialization List »[c, d]«; - // $TEST$ serialization List + # $TEST$ serialization List »[c, dOrNull]«; - // $TEST$ serialization List + # $TEST$ serialization List »[c, e]«; - // $TEST$ serialization List + # $TEST$ serialization List »[c, eOrNull]«; } diff --git a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/class type and class type/with type parameters.sdstest b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/class type and class type/with type parameters.sdstest index ed059df9..ec54d142 100644 --- a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/class type and class type/with type parameters.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/class type and class type/with type parameters.sdstest @@ -9,28 +9,28 @@ segment covariant( coString: Covariant, coFloat: FloatCovariant, ) { - // $TEST$ serialization List> + # $TEST$ serialization List> »[coNumber, coNumber]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[coNumber, coInt]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[coNumber, coString]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[coNumber, coFloat]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[coInt, coInt]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[coInt, coString]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[coInt, coFloat]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[coString, coString]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[coString, coFloat]«; - // $TEST$ serialization List + # $TEST$ serialization List »[coFloat, coFloat]«; } @@ -42,7 +42,7 @@ segment contravariant( ) { // Most tests are in the "highest common subtype" folder. Here we only test that we call the right method. - // $TEST$ serialization List> + # $TEST$ serialization List> »[contraFloat, contraInt]«; } @@ -55,28 +55,28 @@ segment invariant( invString: Invariant, invFloat: FloatInvariant ) { - // $TEST$ serialization List> + # $TEST$ serialization List> »[invNumber, invNumber]«; - // $TEST$ serialization List + # $TEST$ serialization List »[invNumber, invInt]«; - // $TEST$ serialization List + # $TEST$ serialization List »[invNumber, invString]«; - // $TEST$ serialization List + # $TEST$ serialization List »[invNumber, invFloat]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[invInt, invInt]«; - // $TEST$ serialization List + # $TEST$ serialization List »[invInt, invString]«; - // $TEST$ serialization List + # $TEST$ serialization List »[invInt, invFloat]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[invString, invString]«; - // $TEST$ serialization List + # $TEST$ serialization List »[invString, invFloat]«; - // $TEST$ serialization List + # $TEST$ serialization List »[invFloat, invFloat]«; } @@ -86,11 +86,11 @@ segment multiple( multipleNumberInt: Multiple, multipleNumberFloat: Multiple, ) { - // $TEST$ serialization List> + # $TEST$ serialization List> »[multipleNumberInt, multipleNumberInt]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[multipleNumberInt, multipleNumberFloat]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[multipleNumberFloat, multipleNumberFloat]«; } diff --git a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/class type and literal type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/class type and literal type/main.sdstest index 93b2dfb4..ffa04adf 100644 --- a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/class type and literal type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/class type and literal type/main.sdstest @@ -14,37 +14,37 @@ segment mySegment( nothing: Nothing, nothingOrNull: Nothing?, ) { - // $TEST$ serialization List + # $TEST$ serialization List »[1, c]«; - // $TEST$ serialization List + # $TEST$ serialization List »[1, cOrNull]«; - // $TEST$ serialization List + # $TEST$ serialization List »[1, int]«; - // $TEST$ serialization List + # $TEST$ serialization List »[1, intOrNull]«; - // $TEST$ serialization List + # $TEST$ serialization List »[1, number]«; - // $TEST$ serialization List + # $TEST$ serialization List »[1, numberOrNull]«; - // $TEST$ serialization List + # $TEST$ serialization List »[1, string]«; - // $TEST$ serialization List + # $TEST$ serialization List »[1, stringOrNull]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[1, nothing]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[1, nothingOrNull]«; } diff --git a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/class type and type parameter type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/class type and type parameter type/main.sdstest index 6b68b829..d88dd4ab 100644 --- a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/class type and type parameter type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/class type and type parameter type/main.sdstest @@ -12,14 +12,14 @@ class Test + # $TEST$ serialization List p1: Any = »[c, unbounded]«, - // $TEST$ serialization List + # $TEST$ serialization List p2: Any = »[c, unboundedOrNull]«, - // $TEST$ serialization List + # $TEST$ serialization List p3: Any = »[c, boundedByC]«, - // $TEST$ serialization List + # $TEST$ serialization List p4: Any = »[c, boundedByD]«, - // $TEST$ serialization List + # $TEST$ serialization List p5: Any = »[c, boundedByDOrNull]«, ) diff --git a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum type and enum type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum type and enum type/main.sdstest index a25495d2..95f9a847 100644 --- a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum type and enum type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum type and enum type/main.sdstest @@ -9,16 +9,16 @@ segment mySegment( e2: E2, e2OrNull: E2? ) { - // $TEST$ serialization List + # $TEST$ serialization List »[e1, e1]«; - // $TEST$ serialization List + # $TEST$ serialization List »[e1, e1OrNull]«; - // $TEST$ serialization List + # $TEST$ serialization List »[e1, e2]«; - // $TEST$ serialization List + # $TEST$ serialization List »[e1, e2OrNull]«; } diff --git a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum type and enum variant type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum type and enum variant type/main.sdstest index 0f2a8f8c..3c230209 100644 --- a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum type and enum variant type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum type and enum variant type/main.sdstest @@ -14,16 +14,16 @@ segment mySegment( v2: E2.V2, v2OrNull: E2.V2? ) { - // $TEST$ serialization List + # $TEST$ serialization List »[e1, v1]«; - // $TEST$ serialization List + # $TEST$ serialization List »[e1, v1OrNull]«; - // $TEST$ serialization List + # $TEST$ serialization List »[e1, v2]«; - // $TEST$ serialization List + # $TEST$ serialization List »[e1, v2OrNull]«; } diff --git a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum type and type parameter type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum type and type parameter type/main.sdstest index 14568f31..de50e13c 100644 --- a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum type and type parameter type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum type and type parameter type/main.sdstest @@ -22,16 +22,16 @@ class Test< boundedByOtherEnum: BoundedByOtherEnum, boundedByOtherEnumOrNull: BoundedByOtherEnumOrNull, - // $TEST$ serialization List + # $TEST$ serialization List p1: Any = »[e, unbounded]«, - // $TEST$ serialization List + # $TEST$ serialization List p2: Any = »[e, unboundedOrNull]«, - // $TEST$ serialization List + # $TEST$ serialization List p3: Any = »[e, boundedByEnum]«, - // $TEST$ serialization List + # $TEST$ serialization List p4: Any = »[e, boundedByEnumVariant]«, - // $TEST$ serialization List + # $TEST$ serialization List p5: Any = »[e, boundedByOtherEnum]«, - // $TEST$ serialization List + # $TEST$ serialization List p6: Any = »[e, boundedByOtherEnumOrNull]«, ) diff --git a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum variant type and enum variant type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum variant type and enum variant type/main.sdstest index 1baf1b84..f8b7a80b 100644 --- a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum variant type and enum variant type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum variant type and enum variant type/main.sdstest @@ -16,23 +16,23 @@ segment mySegment( v3: E3.V3, v3OrNull: E3.V3? ) { - // $TEST$ serialization List + # $TEST$ serialization List »[v1, v1]«; - // $TEST$ serialization List + # $TEST$ serialization List »[v1, v1OrNull]«; - // $TEST$ serialization List + # $TEST$ serialization List »[v1, v2]«; - // $TEST$ serialization List + # $TEST$ serialization List »[v1, v2OrNull]«; - // $TEST$ serialization List + # $TEST$ serialization List »[v1, v3]«; - // $TEST$ serialization List + # $TEST$ serialization List »[v1, v3OrNull]«; } diff --git a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum variant type and type parameter type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum variant type and type parameter type/main.sdstest index 45eeb432..ab92e965 100644 --- a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum variant type and type parameter type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum variant type and type parameter type/main.sdstest @@ -19,14 +19,14 @@ class D< boundedByOtherEnumVariant: BoundedByOtherEnumVariant, boundedByOtherEnumVariantOrNull: BoundedByOtherEnumVariantOrNull, - // $TEST$ serialization List + # $TEST$ serialization List p1: Any = »[v, unbounded]«, - // $TEST$ serialization List + # $TEST$ serialization List p2: Any = »[v, unboundedOrNull]«, - // $TEST$ serialization List + # $TEST$ serialization List p3: Any = »[v, boundedByEnumVariant]«, - // $TEST$ serialization List + # $TEST$ serialization List p4: Any = »[v, boundedByOtherEnumVariant]«, - // $TEST$ serialization List + # $TEST$ serialization List p5: Any = »[v, boundedByOtherEnumVariantOrNull]«, ) diff --git a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/incompatible types/main.sdstest b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/incompatible types/main.sdstest index 34d6a492..4354b1e7 100644 --- a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/incompatible types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/incompatible types/main.sdstest @@ -10,30 +10,30 @@ segment mySegment( eOrNull: E?, vOrNull: E.V? ) { - // $TEST$ serialization List + # $TEST$ serialization List »[C(), e]«; - // $TEST$ serialization List + # $TEST$ serialization List »[C(), eOrNull]«; - // $TEST$ serialization List + # $TEST$ serialization List »[C(), E.V]«; - // $TEST$ serialization List + # $TEST$ serialization List »[C(), vOrNull]«; - // $TEST$ serialization List + # $TEST$ serialization List »[1, e]«; - // $TEST$ serialization List + # $TEST$ serialization List »[1, eOrNull]«; - // $TEST$ serialization List + # $TEST$ serialization List »[1, E.V]«; - // $TEST$ serialization List + # $TEST$ serialization List »[1, vOrNull]«; } diff --git a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/literal type and literal type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/literal type and literal type/main.sdstest index e69766be..39548649 100644 --- a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/literal type and literal type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/literal type and literal type/main.sdstest @@ -1,9 +1,9 @@ package tests.typing.lowestCommonSupertype.literalTypeAndLiteralType segment mySegment() { - // $TEST$ serialization List> + # $TEST$ serialization List> »[true, 1]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[true, null]«; } diff --git a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/literal type and type parameter type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/literal type and type parameter type/main.sdstest index 59380141..51554bb3 100644 --- a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/literal type and type parameter type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/literal type and type parameter type/main.sdstest @@ -12,14 +12,14 @@ class Test< boundedByString: BoundedByString, boundedByStringOrNull: BoundedByStringOrNull, - // $TEST$ serialization List + # $TEST$ serialization List p1: Any = »[1, unbounded]«, - // $TEST$ serialization List + # $TEST$ serialization List p2: Any = »[1, unboundedOrNull]«, - // $TEST$ serialization List + # $TEST$ serialization List p3: Any = »[1, boundedByInt]«, - // $TEST$ serialization List + # $TEST$ serialization List p4: Any = »[1, boundedByString]«, - // $TEST$ serialization List + # $TEST$ serialization List p5: Any = »[1, boundedByStringOrNull]«, ) diff --git a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/no types after simplification/main.sdstest b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/no types after simplification/main.sdstest index 9b35a2f7..e0e9aea0 100644 --- a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/no types after simplification/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/no types after simplification/main.sdstest @@ -4,15 +4,15 @@ segment mySegment( p1: literal<>, p2: union<>, ) { - // $TEST$ serialization List + # $TEST$ serialization List »[]«; - // $TEST$ serialization List + # $TEST$ serialization List »[p1]«; - // $TEST$ serialization List + # $TEST$ serialization List »[p2]«; - // $TEST$ serialization List + # $TEST$ serialization List »[p1, p2]«; } diff --git a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/simplification/main.sdstest b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/simplification/main.sdstest index 942901e0..419cfd66 100644 --- a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/simplification/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/simplification/main.sdstest @@ -6,15 +6,15 @@ segment mySegment( p1: union, literal>, p2: literal<> ) { - // $TEST$ serialization List + # $TEST$ serialization List »[p1, p1]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[1, 1.5]«; - // $TEST$ serialization List + # $TEST$ serialization List »[C(), p2]«; - // $TEST$ serialization List + # $TEST$ serialization List »[C(), null]«; } diff --git a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/singular type after simplification/main.sdstest b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/singular type after simplification/main.sdstest index 72381e3e..d83bdf21 100644 --- a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/singular type after simplification/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/singular type after simplification/main.sdstest @@ -10,30 +10,30 @@ enum E { segment mySegment( p1: E ) { - // $TEST$ serialization List<() -> ()> + # $TEST$ serialization List<() -> ()> »[() {}]«; - // $TEST$ serialization List> + # $TEST$ serialization List> »[1]«; - // $TEST$ serialization List<(r1: Int, r2: Int)> + # $TEST$ serialization List<(r1: Int, r2: Int)> »[f()]«; - // $TEST$ serialization List + # $TEST$ serialization List »[C()]«; - // $TEST$ serialization List + # $TEST$ serialization List »[p1]«; - // $TEST$ serialization List + # $TEST$ serialization List »[E.V]«; - // $TEST$ serialization List<$type> + # $TEST$ serialization List<$type> »[C]«; - // $TEST$ serialization List<$unknown> + # $TEST$ serialization List<$unknown> »[unknown]«; } -// $TEST$ serialization List +# $TEST$ serialization List class D(t: T, list: Any = »[t]«) diff --git a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/type parameter type and type parameter type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/type parameter type and type parameter type/main.sdstest index 7a1d97b6..b65344cf 100644 --- a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/type parameter type and type parameter type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/type parameter type and type parameter type/main.sdstest @@ -11,27 +11,27 @@ class Test + # $TEST$ serialization List a1: Any = »[nothingToAnyOrNull, nothingToAnyOrNull]«, - // $TEST$ serialization List + # $TEST$ serialization List a2: Any = »[nothingToAnyOrNull, nothingToD]«, - // $TEST$ serialization List + # $TEST$ serialization List a3: Any = »[nothingToAnyOrNull, nothingToE]«, - // $TEST$ serialization List + # $TEST$ serialization List a4: Any = »[nothingToAnyOrNull, nothingToF]«, - // $TEST$ serialization List + # $TEST$ serialization List b1: Any = »[nothingToD, nothingToD]«, - // $TEST$ serialization List + # $TEST$ serialization List b2: Any = »[nothingToD, nothingToE]«, - // $TEST$ serialization List + # $TEST$ serialization List b3: Any = »[nothingToD, nothingToF]«, - // $TEST$ serialization List + # $TEST$ serialization List c1: Any = »[nothingToE, nothingToE]«, - // $TEST$ serialization List + # $TEST$ serialization List c2: Any = »[nothingToE, nothingToF]«, - // $TEST$ serialization List + # $TEST$ serialization List d1: Any = »[nothingToF, nothingToF]« ) diff --git a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/unhandled type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/unhandled type/main.sdstest index b9e60d1b..636712b7 100644 --- a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/unhandled type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/unhandled type/main.sdstest @@ -4,21 +4,21 @@ class C @Pure fun f() -> (r1: Int, r2: Int) segment mySegment() { - // $TEST$ serialization List + # $TEST$ serialization List »[1, f]«; - // $TEST$ serialization List + # $TEST$ serialization List »[null, f]«; - // $TEST$ serialization List + # $TEST$ serialization List »[1, C]«; - // $TEST$ serialization List + # $TEST$ serialization List »[null, C]«; - // $TEST$ serialization List + # $TEST$ serialization List »[1, f()]«; - // $TEST$ serialization List + # $TEST$ serialization List »[null, f()]«; } diff --git a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/unknown type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/unknown type/main.sdstest index e73d1d98..20ca17f7 100644 --- a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/unknown type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/unknown type/main.sdstest @@ -1,9 +1,9 @@ package tests.typing.lowestCommonSupertype.unknownType segment mySegment() { - // $TEST$ serialization List + # $TEST$ serialization List »[1, unknown]«; - // $TEST$ serialization List + # $TEST$ serialization List »[null, unknown]«; } diff --git a/packages/ttsl-lang/tests/resources/typing/simplification/merge literal types in union types/main.sdstest b/packages/ttsl-lang/tests/resources/typing/simplification/merge literal types in union types/main.sdstest index ddadce8a..94c06954 100644 --- a/packages/ttsl-lang/tests/resources/typing/simplification/merge literal types in union types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/simplification/merge literal types in union types/main.sdstest @@ -1,18 +1,18 @@ package tests.typing.simplification.mergeLiteralTypesInUnionTypes class C( - // $TEST$ serialization literal<1> + # $TEST$ serialization literal<1> p1: »union, literal<1, 1>>«, - // $TEST$ serialization literal<1, 2> + # $TEST$ serialization literal<1, 2> p2: »union, literal<1, 2>>«, - // $TEST$ serialization literal<1, 2, 3> + # $TEST$ serialization literal<1, 2, 3> p3: »union, literal<2, 3>>«, - // $TEST$ serialization literal<1, 2, 3> + # $TEST$ serialization literal<1, 2, 3> p4: »union, literal<2>, literal<3>>«, - // $TEST$ serialization union, String> + # $TEST$ serialization union, String> p5: »union, String, literal<2, 3>>«, ) diff --git a/packages/ttsl-lang/tests/resources/typing/simplification/remove duplicate constants from literal types/main.sdstest b/packages/ttsl-lang/tests/resources/typing/simplification/remove duplicate constants from literal types/main.sdstest index 4aeb7c89..957e2f33 100644 --- a/packages/ttsl-lang/tests/resources/typing/simplification/remove duplicate constants from literal types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/simplification/remove duplicate constants from literal types/main.sdstest @@ -1,12 +1,12 @@ package tests.typing.simplification.removeDuplicateConstantsFromLiteralTypes class C( - // $TEST$ serialization literal<1> + # $TEST$ serialization literal<1> p1: »literal<1, 1>«, - // $TEST$ serialization literal<1, 2> + # $TEST$ serialization literal<1, 2> p2: »literal<1, 2>«, - // $TEST$ serialization literal<1, 1.0> + # $TEST$ serialization literal<1, 1.0> p3: »literal<1, 1.0>«, ) diff --git a/packages/ttsl-lang/tests/resources/typing/simplification/remove unneeded entries from union types/main.sdstest b/packages/ttsl-lang/tests/resources/typing/simplification/remove unneeded entries from union types/main.sdstest index f26435ca..42e4218a 100644 --- a/packages/ttsl-lang/tests/resources/typing/simplification/remove unneeded entries from union types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/simplification/remove unneeded entries from union types/main.sdstest @@ -1,126 +1,126 @@ package tests.typing.simplification.removeUnneededEntriesFromUnionTypes class C( - // $TEST$ serialization Int + # $TEST$ serialization Int p1: »union«, - // $TEST$ serialization union + # $TEST$ serialization union p2: »union«, - // $TEST$ serialization Number + # $TEST$ serialization Number p3: »union«, - // $TEST$ serialization Number + # $TEST$ serialization Number p4: »union«, - // $TEST$ serialization Number? + # $TEST$ serialization Number? p5: »union«, - // $TEST$ serialization Any + # $TEST$ serialization Any p6: »union«, - // $TEST$ serialization Any + # $TEST$ serialization Any p7: »union«, - // $TEST$ serialization Any? + # $TEST$ serialization Any? p8: »union«, - // $TEST$ serialization union + # $TEST$ serialization union p9: »union«, - // $TEST$ serialization union + # $TEST$ serialization union p10: »union«, - // $TEST$ serialization union + # $TEST$ serialization union p11: »union«, - // $TEST$ serialization union + # $TEST$ serialization union p12: »union«, - // $TEST$ serialization Any + # $TEST$ serialization Any p13: »union«, - // $TEST$ serialization Any? + # $TEST$ serialization Any? p14: »union«, - // $TEST$ serialization Any + # $TEST$ serialization Any p15: »union«, - // $TEST$ serialization Any? + # $TEST$ serialization Any? p16: »union«, ) class TestsInvolvingNothing( - // $TEST$ serialization Any + # $TEST$ serialization Any p1: »union«, - // $TEST$ serialization Any? + # $TEST$ serialization Any? p2: »union«, - // $TEST$ serialization literal<1> + # $TEST$ serialization literal<1> p3: »union, Nothing>«, - // $TEST$ serialization literal<1, null> + # $TEST$ serialization literal<1, null> p4: »union, Nothing?>«, - // $TEST$ serialization () -> () + # $TEST$ serialization () -> () p5: »union<() -> (), Nothing>«, - // $TEST$ serialization union<() -> (), Nothing?> + # $TEST$ serialization union<() -> (), Nothing?> p6: »union<() -> (), Nothing?>«, ) class TestsInvolvingTypeParameters( - // $TEST$ serialization Unbounded + # $TEST$ serialization Unbounded a1: »union«, - // $TEST$ serialization Unbounded + # $TEST$ serialization Unbounded a2: »union«, - // $TEST$ serialization Unbounded? + # $TEST$ serialization Unbounded? a3: »union«, - // $TEST$ serialization Unbounded? + # $TEST$ serialization Unbounded? a4: »union«, - // $TEST$ serialization union + # $TEST$ serialization union a5: »union«, - // $TEST$ serialization union + # $TEST$ serialization union a6: »union«, - // $TEST$ serialization Any? + # $TEST$ serialization Any? a7: »union«, - // $TEST$ serialization Any? + # $TEST$ serialization Any? a8: »union«, - // $TEST$ serialization UpperBound + # $TEST$ serialization UpperBound b1: »union«, - // $TEST$ serialization UpperBound + # $TEST$ serialization UpperBound b2: »union«, - // $TEST$ serialization UpperBound? + # $TEST$ serialization UpperBound? b3: »union«, - // $TEST$ serialization UpperBound? + # $TEST$ serialization UpperBound? b4: »union«, - // $TEST$ serialization union + # $TEST$ serialization union b5: »union«, - // $TEST$ serialization union + # $TEST$ serialization union b6: »union«, - // $TEST$ serialization Number + # $TEST$ serialization Number b7: »union«, - // $TEST$ serialization Number + # $TEST$ serialization Number b8: »union«, - // $TEST$ serialization Number? + # $TEST$ serialization Number? b9: »union«, - // $TEST$ serialization Number? + # $TEST$ serialization Number? b10: »union«, - // $TEST$ serialization Any? + # $TEST$ serialization Any? b11: »union«, - // $TEST$ serialization Any? + # $TEST$ serialization Any? b12: »union«, ) diff --git a/packages/ttsl-lang/tests/resources/typing/simplification/replace empty literal types with Nothing/main.sdstest b/packages/ttsl-lang/tests/resources/typing/simplification/replace empty literal types with Nothing/main.sdstest index 01740bae..78accc9e 100644 --- a/packages/ttsl-lang/tests/resources/typing/simplification/replace empty literal types with Nothing/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/simplification/replace empty literal types with Nothing/main.sdstest @@ -1,6 +1,6 @@ package tests.typing.simplification.replaceEmptyLiteralTypesWithNothing class C( - // $TEST$ serialization Nothing + # $TEST$ serialization Nothing p1: »literal<>« ) diff --git a/packages/ttsl-lang/tests/resources/typing/simplification/replace empty union types with Nothing/main.sdstest b/packages/ttsl-lang/tests/resources/typing/simplification/replace empty union types with Nothing/main.sdstest index f556c923..02203b85 100644 --- a/packages/ttsl-lang/tests/resources/typing/simplification/replace empty union types with Nothing/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/simplification/replace empty union types with Nothing/main.sdstest @@ -1,6 +1,6 @@ package tests.typing.simplification.replaceEmptyUnionTypesWithNothing class C( - // $TEST$ serialization Nothing + # $TEST$ serialization Nothing p1: »union<>« ) diff --git a/packages/ttsl-lang/tests/resources/typing/simplification/replace literals types that allow only null with NothingOrNull/main.sdstest b/packages/ttsl-lang/tests/resources/typing/simplification/replace literals types that allow only null with NothingOrNull/main.sdstest index b52fa6af..2c0e822f 100644 --- a/packages/ttsl-lang/tests/resources/typing/simplification/replace literals types that allow only null with NothingOrNull/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/simplification/replace literals types that allow only null with NothingOrNull/main.sdstest @@ -1,9 +1,9 @@ package tests.typing.simplification.replaceLiteralTypesThatAllowOnlyNullWithNothingOrNull class C( - // $TEST$ serialization Nothing? + # $TEST$ serialization Nothing? p1: »literal«, - // $TEST$ serialization Nothing? + # $TEST$ serialization Nothing? p2: »literal« ) diff --git a/packages/ttsl-lang/tests/resources/typing/simplification/unwrap/main.sdstest b/packages/ttsl-lang/tests/resources/typing/simplification/unwrap/main.sdstest index 45ad15cb..24d7c621 100644 --- a/packages/ttsl-lang/tests/resources/typing/simplification/unwrap/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/simplification/unwrap/main.sdstest @@ -1,10 +1,10 @@ package tests.typing.simplification.unwrap segment callableType( - // $TEST$ serialization () -> () + # $TEST$ serialization () -> () f1: »() -> ()«, - // $TEST$ serialization (p: String) -> (r: String) + # $TEST$ serialization (p: String) -> (r: String) f2: »(p: union>) -> (r: union>)« ) {} @@ -13,34 +13,34 @@ segment namedTupleType( f2: () -> (r: String), f3: () -> (r1: union>, r2: union>) ) { - // $TEST$ serialization () + # $TEST$ serialization () »f1()«; - // $TEST$ serialization String + # $TEST$ serialization String »f2()«; - // $TEST$ serialization (r1: String, r2: String) + # $TEST$ serialization (r1: String, r2: String) »f3()«; } segment classType( - // $TEST$ serialization String + # $TEST$ serialization String p1: »String«, - // $TEST$ serialization List + # $TEST$ serialization List p2: »List«, - // $TEST$ serialization List + # $TEST$ serialization List p3: »List>>«, ) {} segment unionType( - // $TEST$ serialization String + # $TEST$ serialization String p1: »union«, - // $TEST$ serialization String + # $TEST$ serialization String p2: »union>«, - // $TEST$ serialization union + # $TEST$ serialization union p3: »union, Boolean>«, ) {} diff --git a/packages/ttsl-lang/tests/resources/typing/types/callable types/main.sdstest b/packages/ttsl-lang/tests/resources/typing/types/callable types/main.sdstest index da9f77e1..a991a982 100644 --- a/packages/ttsl-lang/tests/resources/typing/types/callable types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/types/callable types/main.sdstest @@ -1,16 +1,16 @@ package tests.typing.types.callableTypes -// $TEST$ serialization () -> () +# $TEST$ serialization () -> () fun myFunction1(f: »() -> ()«) -// $TEST$ serialization () -> (r1: Int, r2: String) +# $TEST$ serialization () -> (r1: Int, r2: String) fun myFunction2(f: »() -> (r1: Int, r2: String)«) -// $TEST$ serialization (p1: Int, p2: String) -> () +# $TEST$ serialization (p1: Int, p2: String) -> () fun myFunction3(f: »(p1: Int, p2: String) -> ()«) -// $TEST$ serialization (p1: Int, p2: String) -> (r1: Int, r2: String) +# $TEST$ serialization (p1: Int, p2: String) -> (r1: Int, r2: String) fun myFunction4(f: »(p1: Int, p2: String) -> (r1: Int, r2: String)«) -// $TEST$ serialization (p1: $unknown) -> (r1: $unknown) +# $TEST$ serialization (p1: $unknown) -> (r1: $unknown) fun myFunction5(f: »(p1) -> (r1)«) diff --git a/packages/ttsl-lang/tests/resources/typing/types/literal types/main.sdstest b/packages/ttsl-lang/tests/resources/typing/types/literal types/main.sdstest index 4adb84d6..a0622293 100644 --- a/packages/ttsl-lang/tests/resources/typing/types/literal types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/types/literal types/main.sdstest @@ -1,10 +1,10 @@ package tests.typing.types.literalTypes -// $TEST$ serialization Nothing +# $TEST$ serialization Nothing fun myFunction1(f: »literal<>«) -// $TEST$ serialization literal<1, 2> +# $TEST$ serialization literal<1, 2> fun myFunction2(f: »literal<1, 2>«) -// $TEST$ serialization literal<1, ""> +# $TEST$ serialization literal<1, ""> fun myFunction3(f: »literal<1, "">«) diff --git a/packages/ttsl-lang/tests/resources/typing/types/member types/main.sdstest b/packages/ttsl-lang/tests/resources/typing/types/member types/main.sdstest index e90431a0..c53fc9cc 100644 --- a/packages/ttsl-lang/tests/resources/typing/types/member types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/types/member types/main.sdstest @@ -1,36 +1,36 @@ package tests.typing.types.memberTypes class MyClass { - // $TEST$ equivalence_class myNestedClass + # $TEST$ equivalence_class myNestedClass class »MyNestedClass« - // $TEST$ equivalence_class myNestedEnum + # $TEST$ equivalence_class myNestedEnum enum »MyNestedEnum« } enum MyEnum { - // $TEST$ equivalence_class myEnumVariant + # $TEST$ equivalence_class myEnumVariant »MyEnumVariant« } fun nonNullableMemberTypes( - // $TEST$ equivalence_class myNestedClass + # $TEST$ equivalence_class myNestedClass a: »MyClass.MyNestedClass«, - // $TEST$ equivalence_class myNestedEnum + # $TEST$ equivalence_class myNestedEnum b: »MyClass.MyNestedEnum«, - // $TEST$ equivalence_class myEnumVariant + # $TEST$ equivalence_class myEnumVariant d: »MyEnum.MyEnumVariant«, - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown e: »MyEnum.unresolved«, ) fun nullableMemberTypes( - // $TEST$ serialization MyNestedClass? + # $TEST$ serialization MyNestedClass? a: »MyClass.MyNestedClass?«, - // $TEST$ serialization MyNestedEnum? + # $TEST$ serialization MyNestedEnum? b: »MyClass.MyNestedEnum?«, - // $TEST$ serialization MyEnum.MyEnumVariant? + # $TEST$ serialization MyEnum.MyEnumVariant? d: »MyEnum.MyEnumVariant?«, - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown e: »MyEnum.unresolved?«, ) diff --git a/packages/ttsl-lang/tests/resources/typing/types/named types/main.sdstest b/packages/ttsl-lang/tests/resources/typing/types/named types/main.sdstest index a8863f83..5d0d5b3d 100644 --- a/packages/ttsl-lang/tests/resources/typing/types/named types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/types/named types/main.sdstest @@ -5,19 +5,19 @@ class MyClass enum MyEnum fun nonNullableNamedTypes( - // $TEST$ serialization MyClass + # $TEST$ serialization MyClass a: »MyClass«, - // $TEST$ serialization MyEnum + # $TEST$ serialization MyEnum b: »MyEnum«, - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown c: »unresolved«, ) fun nullableNamedTypes( - // $TEST$ serialization MyClass? + # $TEST$ serialization MyClass? a: »MyClass?«, - // $TEST$ serialization MyEnum? + # $TEST$ serialization MyEnum? b: »MyEnum?«, - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown c: »unresolved?«, ) diff --git a/packages/ttsl-lang/tests/resources/typing/types/named types/with type parameters.sdstest b/packages/ttsl-lang/tests/resources/typing/types/named types/with type parameters.sdstest index 05cd2dd7..a5ef1bc4 100644 --- a/packages/ttsl-lang/tests/resources/typing/types/named types/with type parameters.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/types/named types/with type parameters.sdstest @@ -4,33 +4,33 @@ class MyClass2 class MyClass3 fun nonNullableNamedTypes( - // $TEST$ serialization MyClass2 + # $TEST$ serialization MyClass2 a: »MyClass2«, - // $TEST$ serialization MyClass2<$unknown> + # $TEST$ serialization MyClass2<$unknown> b: »MyClass2«, - // $TEST$ serialization MyClass2<$unknown> + # $TEST$ serialization MyClass2<$unknown> c: »MyClass2«, - // $TEST$ serialization MyClass2 + # $TEST$ serialization MyClass2 d: »MyClass2«, - // $TEST$ serialization MyClass3 + # $TEST$ serialization MyClass3 y: »MyClass3«, - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown z: »unresolved«, ) fun nullableNamedTypes( - // $TEST$ serialization MyClass2? + # $TEST$ serialization MyClass2? a: »MyClass2?«, - // $TEST$ serialization MyClass2<$unknown>? + # $TEST$ serialization MyClass2<$unknown>? b: »MyClass2?«, - // $TEST$ serialization MyClass2<$unknown>? + # $TEST$ serialization MyClass2<$unknown>? c: »MyClass2?«, - // $TEST$ serialization MyClass2? + # $TEST$ serialization MyClass2? d: »MyClass2?«, - // $TEST$ serialization MyClass3? + # $TEST$ serialization MyClass3? y: »MyClass3?«, - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown z: »unresolved?«, ) diff --git a/packages/ttsl-lang/tests/resources/typing/types/type arguments/main.sdstest b/packages/ttsl-lang/tests/resources/typing/types/type arguments/main.sdstest index 0f6b3c21..d0685d09 100644 --- a/packages/ttsl-lang/tests/resources/typing/types/type arguments/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/types/type arguments/main.sdstest @@ -3,18 +3,18 @@ package tests.typing.types.typeArguments class MyClass fun myFunction( - // $TEST$ serialization Int + # $TEST$ serialization Int a: MyClass<»Int«>, - // $TEST$ serialization Int + # $TEST$ serialization Int b: MyClass<»T = Int«>, - // $TEST$ serialization Boolean + # $TEST$ serialization Boolean e: unresolved<»Boolean«>, - // $TEST$ serialization Boolean + # $TEST$ serialization Boolean f: unresolved<»T = Boolean«>, - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown g: MyClass<»unresolved«>, - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown h: MyClass<»T = unresolved«>, ) diff --git a/packages/ttsl-lang/tests/resources/typing/types/union types/main.sdstest b/packages/ttsl-lang/tests/resources/typing/types/union types/main.sdstest index 12ed6e73..4e41c6bc 100644 --- a/packages/ttsl-lang/tests/resources/typing/types/union types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/types/union types/main.sdstest @@ -1,7 +1,7 @@ package tests.typing.types.unionTypes -// $TEST$ serialization Nothing +# $TEST$ serialization Nothing fun myFunction(a: »union<>«) -// $TEST$ serialization union +# $TEST$ serialization union fun myFunction(a: »union«) diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/assigned result/main.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/assigned result/main.sdstest index f4cc1bd1..6ec94a14 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/assigned result/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/assigned result/main.sdstest @@ -6,25 +6,25 @@ fun myFunction() -> ( ) segment mySegment() -> (result1: Int, result2: Int, result3: Int) { - // $TEST$ warning "The assigned result 'deprecatedResult' is deprecated." - // $TEST$ no warning r"The assigned result '\w*' is deprecated\." - // $TEST$ no warning r"The assigned result '\w*' is deprecated\." + # $TEST$ warning "The assigned result 'deprecatedResult' is deprecated." + # $TEST$ no warning r"The assigned result '\w*' is deprecated\." + # $TEST$ no warning r"The assigned result '\w*' is deprecated\." »val a«, »val b«, »val c« = myFunction(); - // $TEST$ warning "The assigned result 'deprecatedResult' is deprecated." - // $TEST$ no warning r"The assigned result '\w*' is deprecated\." - // $TEST$ no warning r"The assigned result '\w*' is deprecated\." + # $TEST$ warning "The assigned result 'deprecatedResult' is deprecated." + # $TEST$ no warning r"The assigned result '\w*' is deprecated\." + # $TEST$ no warning r"The assigned result '\w*' is deprecated\." »yield result1«, »yield result2«, »yield result3« = myFunction(); - // $TEST$ no warning r"The assigned result '\w*' is deprecated\." - // $TEST$ no warning r"The assigned result '\w*' is deprecated\." - // $TEST$ no warning r"The assigned result '\w*' is deprecated\." + # $TEST$ no warning r"The assigned result '\w*' is deprecated\." + # $TEST$ no warning r"The assigned result '\w*' is deprecated\." + # $TEST$ no warning r"The assigned result '\w*' is deprecated\." »_«, »_«, »_« = myFunction(); - // $TEST$ no warning r"The assigned result '\w*' is deprecated\." + # $TEST$ no warning r"The assigned result '\w*' is deprecated\." »val d« = a; - // $TEST$ no warning r"The assigned result '\w*' is deprecated\." + # $TEST$ no warning r"The assigned result '\w*' is deprecated\." »val e« = b; - // $TEST$ no warning r"The assigned result '\w*' is deprecated\." + # $TEST$ no warning r"The assigned result '\w*' is deprecated\." »val f« = 1; } diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/called annotation/main.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/called annotation/main.sdstest index c7ac37d1..b3a60e3e 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/called annotation/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/called annotation/main.sdstest @@ -4,10 +4,10 @@ package tests.validation.builtins.deprecated.calledAnnotation annotation DeprecatedAnnotation annotation ValidAnnotation -// $TEST$ warning "The called annotation 'DeprecatedAnnotation' is deprecated." +# $TEST$ warning "The called annotation 'DeprecatedAnnotation' is deprecated." @»DeprecatedAnnotation« -// $TEST$ no warning r"The called annotation '\w*' is deprecated\." +# $TEST$ no warning r"The called annotation '\w*' is deprecated\." @»ValidAnnotation« -// $TEST$ no warning r"The called annotation '\w*' is deprecated\." +# $TEST$ no warning r"The called annotation '\w*' is deprecated\." @»Unresolved« pipeline myPipeline {} diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/corresponding parameter/main.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/corresponding parameter/main.sdstest index 752ebb63..846680f4 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/corresponding parameter/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/corresponding parameter/main.sdstest @@ -7,20 +7,20 @@ fun f( pipeline myPipeline { f( - // $TEST$ warning "The corresponding parameter 'deprecatedParameter' is deprecated." + # $TEST$ warning "The corresponding parameter 'deprecatedParameter' is deprecated." »deprecatedParameter = 1«, - // $TEST$ no warning r"The corresponding parameter '\w*' is deprecated\." + # $TEST$ no warning r"The corresponding parameter '\w*' is deprecated\." »validParameter = 1«, - // $TEST$ no warning r"The corresponding parameter '\w*' is deprecated\." + # $TEST$ no warning r"The corresponding parameter '\w*' is deprecated\." »unresolved = 1«, ); f( - // $TEST$ warning "The corresponding parameter 'deprecatedParameter' is deprecated." + # $TEST$ warning "The corresponding parameter 'deprecatedParameter' is deprecated." »1«, - // $TEST$ no warning r"The corresponding parameter '\w*' is deprecated\." + # $TEST$ no warning r"The corresponding parameter '\w*' is deprecated\." »1«, - // $TEST$ no warning r"The corresponding parameter '\w*' is deprecated\." + # $TEST$ no warning r"The corresponding parameter '\w*' is deprecated\." »1«, ); } diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/must not be used on required parameters/main.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/must not be used on required parameters/main.sdstest index 201f9c0c..395606fb 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/must not be used on required parameters/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/must not be used on required parameters/main.sdstest @@ -1,48 +1,48 @@ package tests.validation.builtins.deprecated.mustNotBeUsedOnRequiredParameters -// $TEST$ error "A deprecated parameter must be optional." -// $TEST$ no error "A deprecated parameter must be optional." +# $TEST$ error "A deprecated parameter must be optional." +# $TEST$ no error "A deprecated parameter must be optional." annotation MyAnnotation(@Deprecated »a«: Int, @Deprecated »b«: Int = 3) -// $TEST$ error "A deprecated parameter must be optional." -// $TEST$ no error "A deprecated parameter must be optional." +# $TEST$ error "A deprecated parameter must be optional." +# $TEST$ no error "A deprecated parameter must be optional." class MyClass(@Deprecated »a«: Int, @Deprecated »b«: Int = 3) { - // $TEST$ error "A deprecated parameter must be optional." - // $TEST$ no error "A deprecated parameter must be optional." + # $TEST$ error "A deprecated parameter must be optional." + # $TEST$ no error "A deprecated parameter must be optional." class MyClass(@Deprecated »a«: Int, @Deprecated »b«: Int = 3) - // $TEST$ error "A deprecated parameter must be optional." - // $TEST$ no error "A deprecated parameter must be optional." + # $TEST$ error "A deprecated parameter must be optional." + # $TEST$ no error "A deprecated parameter must be optional." fun myFunction(@Deprecated »a«: Int, @Deprecated »b«: Int = 3) } enum MyEnum { - // $TEST$ error "A deprecated parameter must be optional." - // $TEST$ no error "A deprecated parameter must be optional." + # $TEST$ error "A deprecated parameter must be optional." + # $TEST$ no error "A deprecated parameter must be optional." MyEnumVariant(@Deprecated »a«: Int, @Deprecated »b«: Int = 3) } -// $TEST$ error "A deprecated parameter must be optional." -// $TEST$ no error "A deprecated parameter must be optional." +# $TEST$ error "A deprecated parameter must be optional." +# $TEST$ no error "A deprecated parameter must be optional." fun myFunction(@Deprecated »a«: Int, @Deprecated »b«: Int = 3) -// $TEST$ error "A deprecated parameter must be optional." -// $TEST$ no error "A deprecated parameter must be optional." +# $TEST$ error "A deprecated parameter must be optional." +# $TEST$ no error "A deprecated parameter must be optional." segment mySegment1(@Deprecated »a«: Int, @Deprecated »b«: Int = 3) {} -// $TEST$ no error "A deprecated parameter must be optional." -// $TEST$ no error "A deprecated parameter must be optional." +# $TEST$ no error "A deprecated parameter must be optional." +# $TEST$ no error "A deprecated parameter must be optional." segment mySegment2( f: (@Deprecated »a«: Int, @Deprecated »b«: Int = 3) -> () ) { - // $TEST$ no error "A deprecated parameter must be optional." - // $TEST$ no error "A deprecated parameter must be optional." + # $TEST$ no error "A deprecated parameter must be optional." + # $TEST$ no error "A deprecated parameter must be optional." val g = (@Deprecated »a«: Int, @Deprecated »b«: Int = 3) {}; - // $TEST$ no error "A deprecated parameter must be optional." - // $TEST$ no error "A deprecated parameter must be optional." + # $TEST$ no error "A deprecated parameter must be optional." + # $TEST$ no error "A deprecated parameter must be optional." val h = (@Deprecated »a«: Int, @Deprecated »b«: Int = 3) -> 1; } diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/referenced declaration/from named type/main.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/referenced declaration/from named type/main.sdstest index 8de79583..6f2d798d 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/referenced declaration/from named type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/referenced declaration/from named type/main.sdstest @@ -12,21 +12,21 @@ enum ValidEnum { } segment mySegment( - // $TEST$ warning "The referenced declaration 'DeprecatedClass' is deprecated." + # $TEST$ warning "The referenced declaration 'DeprecatedClass' is deprecated." p1: »DeprecatedClass«, - // $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." + # $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." p2: »ValidClass«, - // $TEST$ warning "The referenced declaration 'DeprecatedEnum' is deprecated." + # $TEST$ warning "The referenced declaration 'DeprecatedEnum' is deprecated." p3: »DeprecatedEnum«, - // $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." + # $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." p4: »ValidEnum«, - // $TEST$ warning "The referenced declaration 'DeprecatedEnumVariant' is deprecated." + # $TEST$ warning "The referenced declaration 'DeprecatedEnumVariant' is deprecated." p5: ValidEnum.»DeprecatedEnumVariant«, - // $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." + # $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." p6: ValidEnum.»ValidEnumVariant«, - // $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." + # $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." p7: »Unresolved« ) {} diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/referenced declaration/from reference/main.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/referenced declaration/from reference/main.sdstest index 71a50203..1be35303 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/referenced declaration/from reference/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/referenced declaration/from reference/main.sdstest @@ -41,56 +41,56 @@ segment mySegment( * Deprecation is only relevant for callers */ - // $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." + # $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." »deprecatedParameter«; - // $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." + # $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." »validParameter«; - // $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." + # $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." yield »deprecatedResult« = 1; - // $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." + # $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." yield »validResult« = 1; - // $TEST$ warning "The referenced declaration 'DeprecatedClass' is deprecated." + # $TEST$ warning "The referenced declaration 'DeprecatedClass' is deprecated." »DeprecatedClass«; - // $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." + # $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." »ValidClass«; - // $TEST$ warning "The referenced declaration 'deprecatedAttribute' is deprecated." + # $TEST$ warning "The referenced declaration 'deprecatedAttribute' is deprecated." ValidClass.»deprecatedAttribute«; - // $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." + # $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." ValidClass.»validAttribute«; - // $TEST$ warning "The referenced declaration 'DeprecatedEnum' is deprecated." + # $TEST$ warning "The referenced declaration 'DeprecatedEnum' is deprecated." »DeprecatedEnum«; - // $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." + # $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." »ValidEnum«; - // $TEST$ warning "The referenced declaration 'DeprecatedEnumVariant' is deprecated." + # $TEST$ warning "The referenced declaration 'DeprecatedEnumVariant' is deprecated." ValidEnum.»DeprecatedEnumVariant«; - // $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." + # $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." ValidEnum.»ValidEnumVariant«; - // $TEST$ warning "The referenced declaration 'deprecatedFunction' is deprecated." + # $TEST$ warning "The referenced declaration 'deprecatedFunction' is deprecated." »deprecatedFunction«(); - // $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." + # $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." »validFunction«(); - // $TEST$ warning "The referenced declaration 'deprecatedResult' is deprecated." + # $TEST$ warning "The referenced declaration 'deprecatedResult' is deprecated." validFunction().»deprecatedResult«; - // $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." + # $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." validFunction().»validResult«; - // $TEST$ warning "The referenced declaration 'deprecatedSegment' is deprecated." + # $TEST$ warning "The referenced declaration 'deprecatedSegment' is deprecated." »deprecatedSegment«(); - // $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." + # $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." »validSegment«(); - // $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." + # $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." »unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/assigned result/main.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/assigned result/main.sdstest index 97c2171c..99e1b4c8 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/assigned result/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/assigned result/main.sdstest @@ -6,25 +6,25 @@ fun myFunction() -> ( ) segment mySegment() -> (result1: Int, result2: Int, result3: Int) { - // $TEST$ warning "The assigned result 'experimentalResult' is experimental." - // $TEST$ no warning r"The assigned result '\w*' is experimental\." - // $TEST$ no warning r"The assigned result '\w*' is experimental\." + # $TEST$ warning "The assigned result 'experimentalResult' is experimental." + # $TEST$ no warning r"The assigned result '\w*' is experimental\." + # $TEST$ no warning r"The assigned result '\w*' is experimental\." »val a«, »val b«, »val c« = myFunction(); - // $TEST$ warning "The assigned result 'experimentalResult' is experimental." - // $TEST$ no warning r"The assigned result '\w*' is experimental\." - // $TEST$ no warning r"The assigned result '\w*' is experimental\." + # $TEST$ warning "The assigned result 'experimentalResult' is experimental." + # $TEST$ no warning r"The assigned result '\w*' is experimental\." + # $TEST$ no warning r"The assigned result '\w*' is experimental\." »yield result1«, »yield result2«, »yield result3« = myFunction(); - // $TEST$ no warning r"The assigned result '\w*' is experimental\." - // $TEST$ no warning r"The assigned result '\w*' is experimental\." - // $TEST$ no warning r"The assigned result '\w*' is experimental\." + # $TEST$ no warning r"The assigned result '\w*' is experimental\." + # $TEST$ no warning r"The assigned result '\w*' is experimental\." + # $TEST$ no warning r"The assigned result '\w*' is experimental\." »_«, »_«, »_« = myFunction(); - // $TEST$ no warning r"The assigned result '\w*' is experimental\." + # $TEST$ no warning r"The assigned result '\w*' is experimental\." »val d« = a; - // $TEST$ no warning r"The assigned result '\w*' is experimental\." + # $TEST$ no warning r"The assigned result '\w*' is experimental\." »val e« = b; - // $TEST$ no warning r"The assigned result '\w*' is experimental\." + # $TEST$ no warning r"The assigned result '\w*' is experimental\." »val f« = 1; } diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/called annotation/main.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/called annotation/main.sdstest index 3792aada..7413bb0e 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/called annotation/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/called annotation/main.sdstest @@ -4,10 +4,10 @@ package tests.validation.builtins.experimental.calledAnnotation annotation ExperimentalAnnotation annotation ValidAnnotation -// $TEST$ warning "The called annotation 'ExperimentalAnnotation' is experimental." +# $TEST$ warning "The called annotation 'ExperimentalAnnotation' is experimental." @»ExperimentalAnnotation« -// $TEST$ no warning r"The called annotation '\w*' is experimental\." +# $TEST$ no warning r"The called annotation '\w*' is experimental\." @»ValidAnnotation« -// $TEST$ no warning r"The called annotation '\w*' is experimental\." +# $TEST$ no warning r"The called annotation '\w*' is experimental\." @»Unresolved« pipeline myPipeline {} diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/corresponding parameter/main.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/corresponding parameter/main.sdstest index ba5934cf..623ec92b 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/corresponding parameter/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/corresponding parameter/main.sdstest @@ -7,20 +7,20 @@ fun f( pipeline myPipeline { f( - // $TEST$ warning "The corresponding parameter 'experimentalParameter' is experimental." + # $TEST$ warning "The corresponding parameter 'experimentalParameter' is experimental." »experimentalParameter = 1«, - // $TEST$ no warning r"The corresponding parameter '\w*' is experimental\." + # $TEST$ no warning r"The corresponding parameter '\w*' is experimental\." »validParameter = 1«, - // $TEST$ no warning r"The corresponding parameter '\w*' is experimental\." + # $TEST$ no warning r"The corresponding parameter '\w*' is experimental\." »unresolved = 1«, ); f( - // $TEST$ warning "The corresponding parameter 'experimentalParameter' is experimental." + # $TEST$ warning "The corresponding parameter 'experimentalParameter' is experimental." »1«, - // $TEST$ no warning r"The corresponding parameter '\w*' is experimental\." + # $TEST$ no warning r"The corresponding parameter '\w*' is experimental\." »1«, - // $TEST$ no warning r"The corresponding parameter '\w*' is experimental\." + # $TEST$ no warning r"The corresponding parameter '\w*' is experimental\." »1«, ); } diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/referenced declaration/from named type/main.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/referenced declaration/from named type/main.sdstest index b2be9f45..4e3671ca 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/referenced declaration/from named type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/referenced declaration/from named type/main.sdstest @@ -12,21 +12,21 @@ enum ValidEnum { } segment mySegment( - // $TEST$ warning "The referenced declaration 'ExperimentalClass' is experimental." + # $TEST$ warning "The referenced declaration 'ExperimentalClass' is experimental." p1: »ExperimentalClass«, - // $TEST$ no warning r"The referenced declaration '\w*' is experimental\." + # $TEST$ no warning r"The referenced declaration '\w*' is experimental\." p2: »ValidClass«, - // $TEST$ warning "The referenced declaration 'ExperimentalEnum' is experimental." + # $TEST$ warning "The referenced declaration 'ExperimentalEnum' is experimental." p3: »ExperimentalEnum«, - // $TEST$ no warning r"The referenced declaration '\w*' is experimental\." + # $TEST$ no warning r"The referenced declaration '\w*' is experimental\." p4: »ValidEnum«, - // $TEST$ warning "The referenced declaration 'ExperimentalEnumVariant' is experimental." + # $TEST$ warning "The referenced declaration 'ExperimentalEnumVariant' is experimental." p5: ValidEnum.»ExperimentalEnumVariant«, - // $TEST$ no warning r"The referenced declaration '\w*' is experimental\." + # $TEST$ no warning r"The referenced declaration '\w*' is experimental\." p6: ValidEnum.»ValidEnumVariant«, - // $TEST$ no warning r"The referenced declaration '\w*' is experimental\." + # $TEST$ no warning r"The referenced declaration '\w*' is experimental\." p7: »Unresolved« ) {} diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/referenced declaration/from reference/main.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/referenced declaration/from reference/main.sdstest index 10745a35..e055945c 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/referenced declaration/from reference/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/referenced declaration/from reference/main.sdstest @@ -41,56 +41,56 @@ segment mySegment( * Deprecation is only relevant for callers */ - // $TEST$ no warning r"The referenced declaration '\w*' is experimental\." + # $TEST$ no warning r"The referenced declaration '\w*' is experimental\." »experimentalParameter«; - // $TEST$ no warning r"The referenced declaration '\w*' is experimental\." + # $TEST$ no warning r"The referenced declaration '\w*' is experimental\." »validParameter«; - // $TEST$ no warning r"The referenced declaration '\w*' is experimental\." + # $TEST$ no warning r"The referenced declaration '\w*' is experimental\." yield »experimentalResult« = 1; - // $TEST$ no warning r"The referenced declaration '\w*' is experimental\." + # $TEST$ no warning r"The referenced declaration '\w*' is experimental\." yield »validResult« = 1; - // $TEST$ warning "The referenced declaration 'ExperimentalClass' is experimental." + # $TEST$ warning "The referenced declaration 'ExperimentalClass' is experimental." »ExperimentalClass«; - // $TEST$ no warning r"The referenced declaration '\w*' is experimental\." + # $TEST$ no warning r"The referenced declaration '\w*' is experimental\." »ValidClass«; - // $TEST$ warning "The referenced declaration 'experimentalAttribute' is experimental." + # $TEST$ warning "The referenced declaration 'experimentalAttribute' is experimental." ValidClass.»experimentalAttribute«; - // $TEST$ no warning r"The referenced declaration '\w*' is experimental\." + # $TEST$ no warning r"The referenced declaration '\w*' is experimental\." ValidClass.»validAttribute«; - // $TEST$ warning "The referenced declaration 'ExperimentalEnum' is experimental." + # $TEST$ warning "The referenced declaration 'ExperimentalEnum' is experimental." »ExperimentalEnum«; - // $TEST$ no warning r"The referenced declaration '\w*' is experimental\." + # $TEST$ no warning r"The referenced declaration '\w*' is experimental\." »ValidEnum«; - // $TEST$ warning "The referenced declaration 'ExperimentalEnumVariant' is experimental." + # $TEST$ warning "The referenced declaration 'ExperimentalEnumVariant' is experimental." ValidEnum.»ExperimentalEnumVariant«; - // $TEST$ no warning r"The referenced declaration '\w*' is experimental\." + # $TEST$ no warning r"The referenced declaration '\w*' is experimental\." ValidEnum.»ValidEnumVariant«; - // $TEST$ warning "The referenced declaration 'experimentalFunction' is experimental." + # $TEST$ warning "The referenced declaration 'experimentalFunction' is experimental." »experimentalFunction«(); - // $TEST$ no warning r"The referenced declaration '\w*' is experimental\." + # $TEST$ no warning r"The referenced declaration '\w*' is experimental\." »validFunction«(); - // $TEST$ warning "The referenced declaration 'experimentalResult' is experimental." + # $TEST$ warning "The referenced declaration 'experimentalResult' is experimental." validFunction().»experimentalResult«; - // $TEST$ no warning r"The referenced declaration '\w*' is experimental\." + # $TEST$ no warning r"The referenced declaration '\w*' is experimental\." validFunction().»validResult«; - // $TEST$ warning "The referenced declaration 'experimentalSegment' is experimental." + # $TEST$ warning "The referenced declaration 'experimentalSegment' is experimental." »experimentalSegment«(); - // $TEST$ no warning r"The referenced declaration '\w*' is experimental\." + # $TEST$ no warning r"The referenced declaration '\w*' is experimental\." »validSegment«(); - // $TEST$ no warning r"The referenced declaration '\w*' is experimental\." + # $TEST$ no warning r"The referenced declaration '\w*' is experimental\." »unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/expert/must not be used on required parameters/main.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/expert/must not be used on required parameters/main.sdstest index 9fe2d13d..a543e272 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/expert/must not be used on required parameters/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/expert/must not be used on required parameters/main.sdstest @@ -1,48 +1,48 @@ package tests.validation.builtins.expert.mustNotBeUsedOnRequiredParameters -// $TEST$ error "An expert parameter must be optional." -// $TEST$ no error "An expert parameter must be optional." +# $TEST$ error "An expert parameter must be optional." +# $TEST$ no error "An expert parameter must be optional." annotation MyAnnotation(@Expert »a«: Int, @Expert »b«: Int = 3) -// $TEST$ error "An expert parameter must be optional." -// $TEST$ no error "An expert parameter must be optional." +# $TEST$ error "An expert parameter must be optional." +# $TEST$ no error "An expert parameter must be optional." class MyClass(@Expert »a«: Int, @Expert »b«: Int = 3) { - // $TEST$ error "An expert parameter must be optional." - // $TEST$ no error "An expert parameter must be optional." + # $TEST$ error "An expert parameter must be optional." + # $TEST$ no error "An expert parameter must be optional." class MyClass(@Expert »a«: Int, @Expert »b«: Int = 3) - // $TEST$ error "An expert parameter must be optional." - // $TEST$ no error "An expert parameter must be optional." + # $TEST$ error "An expert parameter must be optional." + # $TEST$ no error "An expert parameter must be optional." fun myFunction(@Expert »a«: Int, @Expert »b«: Int = 3) } enum MyEnum { - // $TEST$ error "An expert parameter must be optional." - // $TEST$ no error "An expert parameter must be optional." + # $TEST$ error "An expert parameter must be optional." + # $TEST$ no error "An expert parameter must be optional." MyEnumVariant(@Expert »a«: Int, @Expert »b«: Int = 3) } -// $TEST$ error "An expert parameter must be optional." -// $TEST$ no error "An expert parameter must be optional." +# $TEST$ error "An expert parameter must be optional." +# $TEST$ no error "An expert parameter must be optional." fun myFunction(@Expert »a«: Int, @Expert »b«: Int = 3) -// $TEST$ error "An expert parameter must be optional." -// $TEST$ no error "An expert parameter must be optional." +# $TEST$ error "An expert parameter must be optional." +# $TEST$ no error "An expert parameter must be optional." segment mySegment1(@Expert »a«: Int, @Expert »b«: Int = 3) {} -// $TEST$ no error "An expert parameter must be optional." -// $TEST$ no error "An expert parameter must be optional." +# $TEST$ no error "An expert parameter must be optional." +# $TEST$ no error "An expert parameter must be optional." segment mySegment2( f: (@Expert »a«: Int, @Expert »b«: Int = 3) -> () ) { - // $TEST$ no error "An expert parameter must be optional." - // $TEST$ no error "An expert parameter must be optional." + # $TEST$ no error "An expert parameter must be optional." + # $TEST$ no error "An expert parameter must be optional." val g = (@Expert »a«: Int, @Expert »b«: Int = 3) {}; - // $TEST$ no error "An expert parameter must be optional." - // $TEST$ no error "An expert parameter must be optional." + # $TEST$ no error "An expert parameter must be optional." + # $TEST$ no error "An expert parameter must be optional." val h = (@Expert »a«: Int, @Expert »b«: Int = 3) -> 1; } diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonCall/main.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonCall/main.sdstest index 80b97dcb..14395788 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonCall/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonCall/main.sdstest @@ -1,39 +1,39 @@ package tests.validation.builtins.pythonCall class MyClass { - // $TEST$ no error r"The template expressions? .* cannot be interpreted." + # $TEST$ no error r"The template expressions? .* cannot be interpreted." @»PythonCall«("myMethod1($param)") fun myMethod1(param: Int) - // $TEST$ no error r"The template expressions? .* cannot be interpreted." + # $TEST$ no error r"The template expressions? .* cannot be interpreted." @»PythonCall«("myMethod2($this)") fun myMethod2(this: Int) - // $TEST$ no error "The template expression '$this' cannot be interpreted." + # $TEST$ no error "The template expression '$this' cannot be interpreted." @»PythonCall«("myMethod3($this)") fun myMethod3() - // $TEST$ error "The template expressions '$param1', '$param2' cannot be interpreted." + # $TEST$ error "The template expressions '$param1', '$param2' cannot be interpreted." @»PythonCall«("myMethod4($param1, $param2)") fun myMethod4() } -// $TEST$ no error r"The template expressions? .* cannot be interpreted." +# $TEST$ no error r"The template expressions? .* cannot be interpreted." @»PythonCall«("myFunction1($param)") fun myFunction1(param: Int) -// $TEST$ no error r"The template expressions? .* cannot be interpreted." +# $TEST$ no error r"The template expressions? .* cannot be interpreted." @»PythonCall«("myFunction2($this)") fun myFunction2(this: Int) -// $TEST$ error "The template expression '$this' cannot be interpreted." +# $TEST$ error "The template expression '$this' cannot be interpreted." @»PythonCall«("myFunction3($this)") fun myFunction3() -// $TEST$ error "The template expressions '$param1', '$param2' cannot be interpreted." +# $TEST$ error "The template expressions '$param1', '$param2' cannot be interpreted." @»PythonCall«("myFunction4($param1, $param2)") fun myFunction4() -// $TEST$ no error "An expert parameter must be optional." +# $TEST$ no error "An expert parameter must be optional." @»PythonCall«("$this") annotation MyAnnotation() diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonModule/error.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonModule/error.sdstest index 97adb358..3e323ec9 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonModule/error.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonModule/error.sdstest @@ -1,4 +1,4 @@ -// $TEST$ info "The Python module is identical to the Safe-DS package, so the annotation call can be removed." +# $TEST$ info "The Python module is identical to the Safe-DS package, so the annotation call can be removed." @»PythonModule«("tests.validation.builtins.annotations.pythonModule") package tests.validation.builtins.annotations.pythonModule diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonModule/no annotation.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonModule/no annotation.sdstest index 057e3d85..4bdb4d13 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonModule/no annotation.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonModule/no annotation.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no info "The Python module is identical to the Safe-DS package, so the annotation call can be removed." +# $TEST$ no info "The Python module is identical to the Safe-DS package, so the annotation call can be removed." package tests.validation.builtins.annotations.pythonModule diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonModule/no error.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonModule/no error.sdstest index fa3f4fe9..0f978ab4 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonModule/no error.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonModule/no error.sdstest @@ -1,6 +1,6 @@ -// $TEST$ no info "The Python module is identical to the Safe-DS package, so the annotation call can be removed." +# $TEST$ no info "The Python module is identical to the Safe-DS package, so the annotation call can be removed." @»PythonModule«("tests.validation.builtins.annotations.pythonModule.other") -// $TEST$ no info "The Python module is identical to the Safe-DS package, so the annotation call can be removed." +# $TEST$ no info "The Python module is identical to the Safe-DS package, so the annotation call can be removed." @»PythonModule«("tests.validation.builtins.annotations.pythonModule") package tests.validation.builtins.annotations.pythonModule diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonName/identical to safe-ds name/main.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonName/identical to safe-ds name/main.sdstest index cae7182c..717a97fb 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonName/identical to safe-ds name/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonName/identical to safe-ds name/main.sdstest @@ -1,11 +1,11 @@ package tests.validation.builtins.annotations.pythonName.identicalToSafeDsName -// $TEST$ info "The Python name is identical to the Safe-DS name, so the annotation call can be removed." +# $TEST$ info "The Python name is identical to the Safe-DS name, so the annotation call can be removed." @»PythonName«("TestClass1") class TestClass1 -// $TEST$ no info "The Python name is identical to the Safe-DS name, so the annotation call can be removed." +# $TEST$ no info "The Python name is identical to the Safe-DS name, so the annotation call can be removed." @»PythonName«("Test_Class_2") -// $TEST$ no info "The Python name is identical to the Safe-DS name, so the annotation call can be removed." +# $TEST$ no info "The Python name is identical to the Safe-DS name, so the annotation call can be removed." @»PythonName«("TestClass2") class TestClass2 diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonName/identical to safe-ds name/no annotation.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonName/identical to safe-ds name/no annotation.sdstest index de231603..17bd1b1d 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonName/identical to safe-ds name/no annotation.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonName/identical to safe-ds name/no annotation.sdstest @@ -1,4 +1,4 @@ package tests.validation.builtins.annotations.pythonName.identicalToSafeDsName -// $TEST$ no info "The Python name is identical to the Safe-DS name, so the annotation call can be removed." +# $TEST$ no info "The Python name is identical to the Safe-DS name, so the annotation call can be removed." class TestClass3 diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonName/mutually exclusive with python call/main.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonName/mutually exclusive with python call/main.sdstest index 23901ea2..f30c3d34 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonName/mutually exclusive with python call/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonName/mutually exclusive with python call/main.sdstest @@ -1,26 +1,26 @@ package tests.validation.builtins.annotations.pythonName.mutuallyExclusiveWithPythonCall @PythonCall("myFunction1()") -// $TEST$ error "A Python name must not be set if a Python call is set." +# $TEST$ error "A Python name must not be set if a Python call is set." @»PythonName«("my_function_1") -// $TEST$ no error "A Python name must not be set if a Python call is set." +# $TEST$ no error "A Python name must not be set if a Python call is set." @»PythonName«("my_function_1") fun myFunction1() -// $TEST$ error "A Python name must not be set if a Python call is set." +# $TEST$ error "A Python name must not be set if a Python call is set." @»PythonName«("my_function_2") -// $TEST$ no error "A Python name must not be set if a Python call is set." +# $TEST$ no error "A Python name must not be set if a Python call is set." @»PythonName«("my_function_2") @PythonCall("myFunction2()") fun myFunction2() -// $TEST$ no error "A Python name must not be set if a Python call is set." +# $TEST$ no error "A Python name must not be set if a Python call is set." @»PythonName«("my_function_3") fun myFunction3() -// $TEST$ no error "A Python name must not be set if a Python call is set." +# $TEST$ no error "A Python name must not be set if a Python call is set." @»PythonName«("my_function_2") -// $TEST$ no error "A Python name must not be set if a Python call is set." +# $TEST$ no error "A Python name must not be set if a Python call is set." @»PythonName«("my_function_2") @PythonCall("myFunction2()") class MyClass() diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/repeatable/main.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/repeatable/main.sdstest index ffbe0d36..10b91850 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/repeatable/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/repeatable/main.sdstest @@ -5,20 +5,20 @@ annotation SingleUse @Repeatable annotation MultiUse -// $TEST$ no error r"The annotation '\w*' is not repeatable\." +# $TEST$ no error r"The annotation '\w*' is not repeatable\." @»SingleUse« -// $TEST$ no error r"The annotation '\w*' is not repeatable\." +# $TEST$ no error r"The annotation '\w*' is not repeatable\." @»MultiUse« -// $TEST$ no error r"The annotation '\w*' is not repeatable\." +# $TEST$ no error r"The annotation '\w*' is not repeatable\." @»MultiUse« -// $TEST$ no error r"The annotation '\w*' is not repeatable\." +# $TEST$ no error r"The annotation '\w*' is not repeatable\." @»UnresolvedAnnotation« -// $TEST$ no error r"The annotation '\w*' is not repeatable\." +# $TEST$ no error r"The annotation '\w*' is not repeatable\." @»UnresolvedAnnotation« class CorrectUse -// $TEST$ no error r"The annotation '\w*' is not repeatable\." +# $TEST$ no error r"The annotation '\w*' is not repeatable\." @»SingleUse« -// $TEST$ error "The annotation 'SingleUse' is not repeatable." +# $TEST$ error "The annotation 'SingleUse' is not repeatable." @»SingleUse« class IncorrectUse diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/target/duplicate target/main.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/target/duplicate target/main.sdstest index 72baa16f..a89a21b1 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/target/duplicate target/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/target/duplicate target/main.sdstest @@ -1,7 +1,7 @@ package tests.validation.builtins.annotations.target.duplicateTarget @Target([ - // $TEST$ no warning "The target 'Annotation' was set already." + # $TEST$ no warning "The target 'Annotation' was set already." »AnnotationTarget.Annotation« ]) @@ -10,33 +10,33 @@ package tests.validation.builtins.annotations.target.duplicateTarget */ @Target([ - // $TEST$ no warning "The target 'Annotation' was set already." + # $TEST$ no warning "The target 'Annotation' was set already." »AnnotationTarget.Annotation«, - // $TEST$ no warning "The target 'Annotation' was set already." + # $TEST$ no warning "The target 'Annotation' was set already." »AnnotationTarget.Annotation«, ]) annotation TestAnnotation1 @Target([ - // $TEST$ no warning "The target 'Annotation' was set already." + # $TEST$ no warning "The target 'Annotation' was set already." »AnnotationTarget.Annotation«, - // $TEST$ warning "The target 'Annotation' was set already." + # $TEST$ warning "The target 'Annotation' was set already." »AnnotationTarget.Annotation«, ]) annotation TestAnnotation2 @Target([ - // $TEST$ no warning "The target 'Class' was set already." + # $TEST$ no warning "The target 'Class' was set already." »AnnotationTarget.Class«, - // $TEST$ warning "The target 'Class' was set already." + # $TEST$ warning "The target 'Class' was set already." »AnnotationTarget.Class«, - // $TEST$ warning "The target 'Class' was set already." + # $TEST$ warning "The target 'Class' was set already." »AnnotationTarget.Class«, - // $TEST$ no warning "The target 'Annotation' was set already." + # $TEST$ no warning "The target 'Annotation' was set already." »AnnotationTarget.Annotation«, - // $TEST$ warning "The target 'Annotation' was set already." + # $TEST$ warning "The target 'Annotation' was set already." »AnnotationTarget.Annotation«, - // $TEST$ warning "The target 'Annotation' was set already." + # $TEST$ warning "The target 'Annotation' was set already." »AnnotationTarget.Annotation«, ]) annotation TestAnnotation3 @@ -46,17 +46,17 @@ annotation TestAnnotation3 */ @Target( - // $TEST$ no warning "The target 'Class' was set already." + # $TEST$ no warning "The target 'Class' was set already." »AnnotationTarget.Class«, - // $TEST$ no warning "The target 'Class' was set already." + # $TEST$ no warning "The target 'Class' was set already." »AnnotationTarget.Class« ) annotation TestAnnotation4 @Target([ - // $TEST$ no warning r"The target '.*' was set already\." + # $TEST$ no warning r"The target '.*' was set already\." »1«, - // $TEST$ no warning r"The target '.*' was set already\." + # $TEST$ no warning r"The target '.*' was set already\." »1«, ]) annotation TestAnnotation5 diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/target/duplicate target/no target annotation.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/target/duplicate target/no target annotation.sdstest index c23ee214..8264ccf4 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/target/duplicate target/no target annotation.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/target/duplicate target/no target annotation.sdstest @@ -1,5 +1,5 @@ package tests.validation.builtins.annotations.target.duplicateTarget -// $TEST$ no warning r"The target '.*' was already set\." +# $TEST$ no warning r"The target '.*' was already set\." annotation TestAnnotation6 diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/target/wrong target/main.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/target/wrong target/main.sdstest index b506ff37..643571a9 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/target/wrong target/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/target/wrong target/main.sdstest @@ -1,12 +1,12 @@ -// $TEST$ error "The annotation 'AnnotationForEnums' cannot be applied to a module." +# $TEST$ error "The annotation 'AnnotationForEnums' cannot be applied to a module." @»AnnotationForEnums« -// $TEST$ no error r"This annotation '.*' cannot be applied to .*" +# $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForModules« -// $TEST$ no error r"This annotation '.*' cannot be applied to .*" +# $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForMultipleTargets« -// $TEST$ no error r"This annotation '.*' cannot be applied to .*" +# $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForAnything« -// $TEST$ no error r"This annotation '.*' cannot be applied to .*" +# $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»Unresolved« package tests.validation.builtins.annotations.target.wrongTarget @@ -54,119 +54,119 @@ annotation AnnotationForAnything /* Test declarations -------------------------------------------------------- */ -// $TEST$ error "The annotation 'AnnotationForAttributes' cannot be applied to an annotation." +# $TEST$ error "The annotation 'AnnotationForAttributes' cannot be applied to an annotation." @»AnnotationForAttributes« -// $TEST$ no error r"This annotation '.*' cannot be applied to .*" +# $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForAnnotations« -// $TEST$ no error r"This annotation '.*' cannot be applied to .*" +# $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForAnything« -// $TEST$ no error r"This annotation '.*' cannot be applied to .*" +# $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»Unresolved« annotation TestAnnotation -// $TEST$ error "The annotation 'AnnotationForModules' cannot be applied to a class." +# $TEST$ error "The annotation 'AnnotationForModules' cannot be applied to a class." @»AnnotationForModules« -// $TEST$ no error r"This annotation '.*' cannot be applied to .*" +# $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForClasses« -// $TEST$ no error r"This annotation '.*' cannot be applied to .*" +# $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForMultipleTargets« -// $TEST$ no error r"This annotation '.*' cannot be applied to .*" +# $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForAnything« -// $TEST$ no error r"This annotation '.*' cannot be applied to .*" +# $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»Unresolved« class TestClass< - // $TEST$ error "The annotation 'AnnotationForPipelines' cannot be applied to a type parameter." + # $TEST$ error "The annotation 'AnnotationForPipelines' cannot be applied to a type parameter." @»AnnotationForPipelines« - // $TEST$ no error r"This annotation '.*' cannot be applied to .*" + # $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForTypeParameters« - // $TEST$ no error r"This annotation '.*' cannot be applied to .*" + # $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForAnything« - // $TEST$ no error r"This annotation '.*' cannot be applied to .*" + # $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»Unresolved« TEST_TYPE_PARAMETER > { - // $TEST$ error "The annotation 'AnnotationForClasses' cannot be applied to an attribute." + # $TEST$ error "The annotation 'AnnotationForClasses' cannot be applied to an attribute." @»AnnotationForClasses« - // $TEST$ no error r"This annotation '.*' cannot be applied to .*" + # $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForAttributes« - // $TEST$ no error r"This annotation '.*' cannot be applied to .*" + # $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForAnything« - // $TEST$ no error r"This annotation '.*' cannot be applied to .*" + # $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»Unresolved« attr testAttribute: Int } -// $TEST$ error "The annotation 'AnnotationForEnumVariants' cannot be applied to an enum." +# $TEST$ error "The annotation 'AnnotationForEnumVariants' cannot be applied to an enum." @»AnnotationForEnumVariants« -// $TEST$ no error r"This annotation '.*' cannot be applied to .*" +# $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForEnums« -// $TEST$ no error r"This annotation '.*' cannot be applied to .*" +# $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForAnything« -// $TEST$ no error r"This annotation '.*' cannot be applied to .*" +# $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»Unresolved« enum TestEnum { - // $TEST$ error "The annotation 'AnnotationForFunctions' cannot be applied to an enum variant." + # $TEST$ error "The annotation 'AnnotationForFunctions' cannot be applied to an enum variant." @»AnnotationForFunctions« - // $TEST$ no error r"This annotation '.*' cannot be applied to .*" + # $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForEnumVariants« - // $TEST$ no error r"This annotation '.*' cannot be applied to .*" + # $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForAnything« - // $TEST$ no error r"This annotation '.*' cannot be applied to .*" + # $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»Unresolved« TestEnumVariant } -// $TEST$ error "The annotation 'AnnotationForParameters' cannot be applied to a function." +# $TEST$ error "The annotation 'AnnotationForParameters' cannot be applied to a function." @»AnnotationForParameters« -// $TEST$ no error r"This annotation '.*' cannot be applied to .*" +# $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForFunctions« -// $TEST$ no error r"This annotation '.*' cannot be applied to .*" +# $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForAnything« -// $TEST$ no error r"This annotation '.*' cannot be applied to .*" +# $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»Unresolved« fun testFunction( - // $TEST$ error "The annotation 'AnnotationForResults' cannot be applied to a parameter." + # $TEST$ error "The annotation 'AnnotationForResults' cannot be applied to a parameter." @»AnnotationForResults« - // $TEST$ no error r"This annotation '.*' cannot be applied to .*" + # $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForParameters« - // $TEST$ no error r"This annotation '.*' cannot be applied to .*" + # $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForAnything« - // $TEST$ no error r"This annotation '.*' cannot be applied to .*" + # $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»Unresolved« testParameter: Int ) -> ( - // $TEST$ error "The annotation 'AnnotationForTypeParameters' cannot be applied to a result." + # $TEST$ error "The annotation 'AnnotationForTypeParameters' cannot be applied to a result." @»AnnotationForTypeParameters« - // $TEST$ no error r"This annotation '.*' cannot be applied to .*" + # $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForResults« - // $TEST$ no error r"This annotation '.*' cannot be applied to .*" + # $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForAnything« - // $TEST$ no error r"This annotation '.*' cannot be applied to .*" + # $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»Unresolved« testResult: Int ) -// $TEST$ error "The annotation 'AnnotationForSegments' cannot be applied to a pipeline." +# $TEST$ error "The annotation 'AnnotationForSegments' cannot be applied to a pipeline." @»AnnotationForSegments« -// $TEST$ no error r"This annotation '.*' cannot be applied to .*" +# $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForPipelines« -// $TEST$ no error r"This annotation '.*' cannot be applied to .*" +# $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForAnything« -// $TEST$ no error r"This annotation '.*' cannot be applied to .*" +# $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»Unresolved« pipeline testPipeline {} -// $TEST$ error "The annotation 'AnnotationForAnnotations' cannot be applied to a segment." +# $TEST$ error "The annotation 'AnnotationForAnnotations' cannot be applied to a segment." @»AnnotationForAnnotations« -// $TEST$ no error r"This annotation '.*' cannot be applied to .*" +# $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForSegments« -// $TEST$ no error r"This annotation '.*' cannot be applied to .*" +# $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForAnything« -// $TEST$ no error r"This annotation '.*' cannot be applied to .*" +# $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»Unresolved« segment testSegment() {} diff --git a/packages/ttsl-lang/tests/resources/validation/experimental language feature/constraint lists/main.sdstest b/packages/ttsl-lang/tests/resources/validation/experimental language feature/constraint lists/main.sdstest index d76b39b0..16e84f21 100644 --- a/packages/ttsl-lang/tests/resources/validation/experimental language feature/constraint lists/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/experimental language feature/constraint lists/main.sdstest @@ -1,4 +1,4 @@ package tests.validation.experimentalLanguageFeature.constraintLists -// $TEST$ warning "Constraint lists & constraints are experimental and may change without prior notice." +# $TEST$ warning "Constraint lists & constraints are experimental and may change without prior notice." fun myFunction() »where« {} diff --git a/packages/ttsl-lang/tests/resources/validation/experimental language feature/literal types/main.sdstest b/packages/ttsl-lang/tests/resources/validation/experimental language feature/literal types/main.sdstest index 369e22d5..0cee689c 100644 --- a/packages/ttsl-lang/tests/resources/validation/experimental language feature/literal types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/experimental language feature/literal types/main.sdstest @@ -1,6 +1,6 @@ package tests.validation.experimentalLanguageFeature.literalTypes fun myFunction( - // $TEST$ warning "Literal types are experimental and may change without prior notice." + # $TEST$ warning "Literal types are experimental and may change without prior notice." p: »literal«<> ) diff --git a/packages/ttsl-lang/tests/resources/validation/experimental language feature/maps/main.sdstest b/packages/ttsl-lang/tests/resources/validation/experimental language feature/maps/main.sdstest index 9addb92a..b45710df 100644 --- a/packages/ttsl-lang/tests/resources/validation/experimental language feature/maps/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/experimental language feature/maps/main.sdstest @@ -1,9 +1,9 @@ package tests.validation.experimentalLanguageFeature.maps pipeline myPipeline { - // $TEST$ warning "Map literals are experimental and may change without prior notice." + # $TEST$ warning "Map literals are experimental and may change without prior notice." »{"a": "b"}«; - // $TEST$ no warning "Map literals are experimental and may change without prior notice." + # $TEST$ no warning "Map literals are experimental and may change without prior notice." {"a": »{}«}; } diff --git a/packages/ttsl-lang/tests/resources/validation/experimental language feature/union types/main.sdstest b/packages/ttsl-lang/tests/resources/validation/experimental language feature/union types/main.sdstest index 2db26e87..64322513 100644 --- a/packages/ttsl-lang/tests/resources/validation/experimental language feature/union types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/experimental language feature/union types/main.sdstest @@ -1,13 +1,13 @@ package tests.validation.experimentalLanguageFeature.unionTypes fun myFunction( - // $TEST$ warning "Union types are experimental and may change without prior notice." + # $TEST$ warning "Union types are experimental and may change without prior notice." p: »union«, - // $TEST$ no warning "Union types are experimental and may change without prior notice." + # $TEST$ no warning "Union types are experimental and may change without prior notice." q: union<»union«, Int>, - // $TEST$ no warning "Union types are experimental and may change without prior notice." - // $TEST$ no warning "Union types are experimental and may change without prior notice." + # $TEST$ no warning "Union types are experimental and may change without prior notice." + # $TEST$ no warning "Union types are experimental and may change without prior notice." r: union<(p: »union«) -> (r: »union«), Int>, ) diff --git a/packages/ttsl-lang/tests/resources/validation/inheritance/must be acyclic/main.sdstest b/packages/ttsl-lang/tests/resources/validation/inheritance/must be acyclic/main.sdstest index 84def22e..ee488f61 100644 --- a/packages/ttsl-lang/tests/resources/validation/inheritance/must be acyclic/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/inheritance/must be acyclic/main.sdstest @@ -1,22 +1,22 @@ package tests.validation.inheritance.mustBeAcyclic -// $TEST$ error "A class must not directly or indirectly be a subtype of itself." +# $TEST$ error "A class must not directly or indirectly be a subtype of itself." class MyClass1 sub »MyClass3« -// $TEST$ error "A class must not directly or indirectly be a subtype of itself." +# $TEST$ error "A class must not directly or indirectly be a subtype of itself." class MyClass2 sub »MyClass1« -// $TEST$ error "A class must not directly or indirectly be a subtype of itself." +# $TEST$ error "A class must not directly or indirectly be a subtype of itself." class MyClass3 sub »MyClass2« class MyClass4 -// $TEST$ no error "A class must not directly or indirectly be a subtype of itself." +# $TEST$ no error "A class must not directly or indirectly be a subtype of itself." class MyClass5 sub »MyClass4« -// $TEST$ no error "A class must not directly or indirectly be a subtype of itself." +# $TEST$ no error "A class must not directly or indirectly be a subtype of itself." class MyClass6 sub »MyClass7« -// $TEST$ no error "A class must not directly or indirectly be a subtype of itself." +# $TEST$ no error "A class must not directly or indirectly be a subtype of itself." class MyClass7 sub Any, »MyClass6« -// $TEST$ no error "A class must not directly or indirectly be a subtype of itself." +# $TEST$ no error "A class must not directly or indirectly be a subtype of itself." class MyClass8 sub »Unresolved« -// $TEST$ no error "A class must not directly or indirectly be a subtype of itself." +# $TEST$ no error "A class must not directly or indirectly be a subtype of itself." class MyClass9 sub »MyClass8« diff --git a/packages/ttsl-lang/tests/resources/validation/inheritance/must inherit only classes/class with parent types.sdstest b/packages/ttsl-lang/tests/resources/validation/inheritance/must inherit only classes/class with parent types.sdstest index fcb6c6c0..71de5ac8 100644 --- a/packages/ttsl-lang/tests/resources/validation/inheritance/must inherit only classes/class with parent types.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/inheritance/must inherit only classes/class with parent types.sdstest @@ -7,28 +7,28 @@ enum MyEnum { MyEnumVariant } -// $TEST$ no error "A class must only inherit classes." -// $TEST$ no error "A class must only inherit classes." -// $TEST$ no error "A class must only inherit classes." -// $TEST$ no error "A class must only inherit classes." -// $TEST$ no error "A class must only inherit classes." +# $TEST$ no error "A class must only inherit classes." +# $TEST$ no error "A class must only inherit classes." +# $TEST$ no error "A class must only inherit classes." +# $TEST$ no error "A class must only inherit classes." +# $TEST$ no error "A class must only inherit classes." class TestClass1 sub »MyClass«, »MyClass.MyNestedClass«, »MyEnum«, »MyEnum.MyEnumVariant«, »Unresolved« -// $TEST$ no error "A class must only inherit classes." +# $TEST$ no error "A class must only inherit classes." class TestClass2 sub »MyClass« -// $TEST$ no error "A class must only inherit classes." +# $TEST$ no error "A class must only inherit classes." class TestClass3 sub »MyClass.MyNestedClass« -// $TEST$ error "A class must only inherit classes." +# $TEST$ error "A class must only inherit classes." class TestClass4 sub »MyEnum« -// $TEST$ error "A class must only inherit classes." +# $TEST$ error "A class must only inherit classes." class TestClass5 sub »MyEnum.MyEnumVariant« -// $TEST$ no error "A class must only inherit classes." +# $TEST$ no error "A class must only inherit classes." class TestClass6 sub »Unresolved« diff --git a/packages/ttsl-lang/tests/resources/validation/inheritance/must inherit only classes/class without parent types.sdstest b/packages/ttsl-lang/tests/resources/validation/inheritance/must inherit only classes/class without parent types.sdstest index eb1fc7ec..306d5a81 100644 --- a/packages/ttsl-lang/tests/resources/validation/inheritance/must inherit only classes/class without parent types.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/inheritance/must inherit only classes/class without parent types.sdstest @@ -1,4 +1,4 @@ package tests.validation.inheritance.mustInheritOnlyClasses -// $TEST$ no error "A class must only inherit classes." +# $TEST$ no error "A class must only inherit classes." class TestClass7 diff --git a/packages/ttsl-lang/tests/resources/validation/inheritance/must not be nullable/class with parent types.sdstest b/packages/ttsl-lang/tests/resources/validation/inheritance/must not be nullable/class with parent types.sdstest index 78a28da2..4574d236 100644 --- a/packages/ttsl-lang/tests/resources/validation/inheritance/must not be nullable/class with parent types.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/inheritance/must not be nullable/class with parent types.sdstest @@ -7,28 +7,28 @@ enum MyEnum { MyEnumVariant } -// $TEST$ no error "The parent type must not be nullable." -// $TEST$ no error "The parent type must not be nullable." -// $TEST$ no error "The parent type must not be nullable." -// $TEST$ no error "The parent type must not be nullable." -// $TEST$ no error "The parent type must not be nullable." +# $TEST$ no error "The parent type must not be nullable." +# $TEST$ no error "The parent type must not be nullable." +# $TEST$ no error "The parent type must not be nullable." +# $TEST$ no error "The parent type must not be nullable." +# $TEST$ no error "The parent type must not be nullable." class TestClass1 sub »MyClass«, »MyClass.MyNestedClass?«, »MyEnum?«, »MyEnum.MyEnumVariant?«, »Unresolved?« -// $TEST$ error "The parent type must not be nullable." +# $TEST$ error "The parent type must not be nullable." class TestClass2 sub »MyClass?« -// $TEST$ error "The parent type must not be nullable." +# $TEST$ error "The parent type must not be nullable." class TestClass3 sub »MyClass.MyNestedClass?« -// $TEST$ no error "The parent type must not be nullable." +# $TEST$ no error "The parent type must not be nullable." class TestClass4 sub »MyEnum?« -// $TEST$ no error "The parent type must not be nullable." +# $TEST$ no error "The parent type must not be nullable." class TestClass5 sub »MyEnum.MyEnumVariant?« -// $TEST$ no error "The parent type must not be nullable." +# $TEST$ no error "The parent type must not be nullable." class TestClass6 sub »Unresolved?« diff --git a/packages/ttsl-lang/tests/resources/validation/inheritance/no multiple inheritance/class with parent types.sdstest b/packages/ttsl-lang/tests/resources/validation/inheritance/no multiple inheritance/class with parent types.sdstest index 60b064db..5d4ed2a2 100644 --- a/packages/ttsl-lang/tests/resources/validation/inheritance/no multiple inheritance/class with parent types.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/inheritance/no multiple inheritance/class with parent types.sdstest @@ -7,12 +7,12 @@ enum MyEnum { MyEnumVariant } -// $TEST$ no error "Multiple inheritance is not supported. Only the first parent type will be considered." -// $TEST$ error "Multiple inheritance is not supported. Only the first parent type will be considered." -// $TEST$ error "Multiple inheritance is not supported. Only the first parent type will be considered." -// $TEST$ error "Multiple inheritance is not supported. Only the first parent type will be considered." -// $TEST$ error "Multiple inheritance is not supported. Only the first parent type will be considered." -// $TEST$ error "Multiple inheritance is not supported. Only the first parent type will be considered." +# $TEST$ no error "Multiple inheritance is not supported. Only the first parent type will be considered." +# $TEST$ error "Multiple inheritance is not supported. Only the first parent type will be considered." +# $TEST$ error "Multiple inheritance is not supported. Only the first parent type will be considered." +# $TEST$ error "Multiple inheritance is not supported. Only the first parent type will be considered." +# $TEST$ error "Multiple inheritance is not supported. Only the first parent type will be considered." +# $TEST$ error "Multiple inheritance is not supported. Only the first parent type will be considered." class TestClass1 sub »MyClass«, »MyClass.MyNestedClass«, »MyEnum«, diff --git a/packages/ttsl-lang/tests/resources/validation/inheritance/no multiple inheritance/class without parent types.sdstest b/packages/ttsl-lang/tests/resources/validation/inheritance/no multiple inheritance/class without parent types.sdstest index 3233e0ff..ac4fdf60 100644 --- a/packages/ttsl-lang/tests/resources/validation/inheritance/no multiple inheritance/class without parent types.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/inheritance/no multiple inheritance/class without parent types.sdstest @@ -1,4 +1,4 @@ package tests.validation.inheritance.noMultipleInheritance -// $TEST$ no error "Multiple inheritance is not supported. Only the first parent type will be considered." +# $TEST$ no error "Multiple inheritance is not supported. Only the first parent type will be considered." class TestClass2 diff --git a/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method must match overridden method/main.sdstest b/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method must match overridden method/main.sdstest index 05d224e1..0de22fd9 100644 --- a/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method must match overridden method/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method must match overridden method/main.sdstest @@ -9,47 +9,47 @@ class MySuperClass1 { } class MyClass1 sub MySuperClass1 { - // $TEST$ no error r"Overriding member does not match the overridden member:.*" + # $TEST$ no error r"Overriding member does not match the overridden member:.*" attr »myInstanceAttribute«: Int - // $TEST$ no error r"Overriding member does not match the overridden member:.*" + # $TEST$ no error r"Overriding member does not match the overridden member:.*" static attr »myStaticAttribute«: Int - // $TEST$ no error r"Overriding member does not match the overridden member:.*" + # $TEST$ no error r"Overriding member does not match the overridden member:.*" attr »myInstanceAttribute«: Any - // $TEST$ no error r"Overriding member does not match the overridden member:.*" + # $TEST$ no error r"Overriding member does not match the overridden member:.*" static attr »myStaticAttribute«: Any - // $TEST$ no error r"Overriding member does not match the overridden member:.*" + # $TEST$ no error r"Overriding member does not match the overridden member:.*" attr »myOwnInstanceAttribute«: Int - // $TEST$ no error r"Overriding member does not match the overridden member:.*" + # $TEST$ no error r"Overriding member does not match the overridden member:.*" static attr »myOwnStaticAttribute«: Int - // $TEST$ no error r"Overriding member does not match the overridden member:.*" + # $TEST$ no error r"Overriding member does not match the overridden member:.*" @Pure fun »myInstanceMethod«(a: Any = 0) -> r: Int - // $TEST$ no error r"Overriding member does not match the overridden member:.*" + # $TEST$ no error r"Overriding member does not match the overridden member:.*" @Pure static fun »myStaticMethod«(a: Any = 0) -> r: Int - // $TEST$ no error r"Overriding member does not match the overridden member:.*" + # $TEST$ no error r"Overriding member does not match the overridden member:.*" @Pure fun »myInstanceMethod«() -> r: Int - // $TEST$ no error r"Overriding member does not match the overridden member:.*" + # $TEST$ no error r"Overriding member does not match the overridden member:.*" @Pure static fun »myStaticMethod«() -> r: Int - // $TEST$ no error r"Overriding member does not match the overridden member:.*" + # $TEST$ no error r"Overriding member does not match the overridden member:.*" @Pure fun »myOwnInstanceMethod«(a: Any = 0) -> r: Int - // $TEST$ no error r"Overriding member does not match the overridden member:.*" + # $TEST$ no error r"Overriding member does not match the overridden member:.*" @Pure static fun »myOwnStaticMethod«(a: Any = 0) -> r: Int } class MyClass2 sub MySuperClass1 { - // $TEST$ error r"Overriding member does not match the overridden member:.*" + # $TEST$ error r"Overriding member does not match the overridden member:.*" attr »myInstanceAttribute«: Any - // $TEST$ no error r"Overriding member does not match the overridden member:.*" + # $TEST$ no error r"Overriding member does not match the overridden member:.*" static attr »myStaticAttribute«: Any - // $TEST$ error r"Overriding member does not match the overridden member:.*" + # $TEST$ error r"Overriding member does not match the overridden member:.*" @Pure fun »myInstanceMethod«(a: Number = 0) -> r: Any - // $TEST$ no error r"Overriding member does not match the overridden member:.*" + # $TEST$ no error r"Overriding member does not match the overridden member:.*" @Pure static fun »myStaticMethod«(a: Number = 0) -> r: Any } diff --git a/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method must match overridden method/type parameters.sdstest b/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method must match overridden method/type parameters.sdstest index 04b5fcea..5d404836 100644 --- a/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method must match overridden method/type parameters.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method must match overridden method/type parameters.sdstest @@ -8,39 +8,39 @@ class MySuperClass { } class MyClass1 sub MySuperClass { - // $TEST$ no error r"Overriding member does not match the overridden member:.*" + # $TEST$ no error r"Overriding member does not match the overridden member:.*" attr »myInstanceAttribute«: Int - // $TEST$ no error r"Overriding member does not match the overridden member:.*" + # $TEST$ no error r"Overriding member does not match the overridden member:.*" @Pure fun »myInstanceMethod1«(a: Any = 0) -> r: Int } class MyClass2 sub MySuperClass { - // $TEST$ no error r"Overriding member does not match the overridden member:.*" + # $TEST$ no error r"Overriding member does not match the overridden member:.*" attr »myInstanceAttribute«: T - // $TEST$ no error r"Overriding member does not match the overridden member:.*" + # $TEST$ no error r"Overriding member does not match the overridden member:.*" @Pure fun »myInstanceMethod1«(a: T = 0) -> r: T } class MyClass3 sub MySuperClass { - // $TEST$ error r"Overriding member does not match the overridden member:.*" + # $TEST$ error r"Overriding member does not match the overridden member:.*" attr »myInstanceAttribute«: Any - // $TEST$ error r"Overriding member does not match the overridden member:.*" + # $TEST$ error r"Overriding member does not match the overridden member:.*" @Pure fun »myInstanceMethod1«(a: Number = 0) -> r: Any } class MyClass4 sub MySuperClass { - // $TEST$ no error r"Overriding member does not match the overridden member:.*" + # $TEST$ no error r"Overriding member does not match the overridden member:.*" @Pure fun »myInstanceMethod2«(a: T) -> r: T - // $TEST$ no error r"Overriding member does not match the overridden member:.*" + # $TEST$ no error r"Overriding member does not match the overridden member:.*" @Pure fun »myInstanceMethod3«(a: T) -> r: T } class MyClass5 sub MySuperClass { - // $TEST$ error r"Overriding member does not match the overridden member:.*" + # $TEST$ error r"Overriding member does not match the overridden member:.*" @Pure fun »myInstanceMethod3«(a: Int) -> r: Int } class MyClass6 sub MySuperClass { - // $TEST$ error r"Overriding member does not match the overridden member:.*" + # $TEST$ error r"Overriding member does not match the overridden member:.*" attr »myInstanceAttribute«: T } diff --git a/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method should differ from overridden method/main.sdstest b/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method should differ from overridden method/main.sdstest index ea87ac37..f91e098d 100644 --- a/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method should differ from overridden method/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method should differ from overridden method/main.sdstest @@ -9,47 +9,47 @@ class MySuperClass1 { } class MyClass1 sub MySuperClass1 { - // $TEST$ info "Overriding member is identical to overridden member and can be removed." + # $TEST$ info "Overriding member is identical to overridden member and can be removed." attr »myInstanceAttribute«: Number - // $TEST$ no info "Overriding member is identical to overridden member and can be removed." + # $TEST$ no info "Overriding member is identical to overridden member and can be removed." static attr »myStaticAttribute«: Number - // $TEST$ no info "Overriding member is identical to overridden member and can be removed." + # $TEST$ no info "Overriding member is identical to overridden member and can be removed." attr »myInstanceAttribute«: Number - // $TEST$ no info "Overriding member is identical to overridden member and can be removed." + # $TEST$ no info "Overriding member is identical to overridden member and can be removed." static attr »myStaticAttribute«: Number - // $TEST$ no info "Overriding member is identical to overridden member and can be removed." + # $TEST$ no info "Overriding member is identical to overridden member and can be removed." attr »myOwnInstanceAttribute«: Number - // $TEST$ no info "Overriding member is identical to overridden member and can be removed." + # $TEST$ no info "Overriding member is identical to overridden member and can be removed." static attr »myOwnStaticAttribute«: Number - // $TEST$ info "Overriding member is identical to overridden member and can be removed." + # $TEST$ info "Overriding member is identical to overridden member and can be removed." @Pure fun »myInstanceMethod«(a: Number = 0) -> r: Number - // $TEST$ no info "Overriding member is identical to overridden member and can be removed." + # $TEST$ no info "Overriding member is identical to overridden member and can be removed." @Pure static fun »myStaticMethod«(a: Number = 0) -> r: Number - // $TEST$ no info "Overriding member is identical to overridden member and can be removed." + # $TEST$ no info "Overriding member is identical to overridden member and can be removed." @Pure fun »myInstanceMethod«() -> r: Number - // $TEST$ no info "Overriding member is identical to overridden member and can be removed." + # $TEST$ no info "Overriding member is identical to overridden member and can be removed." @Pure static fun »myStaticMethod«() -> r: Number - // $TEST$ no info "Overriding member is identical to overridden member and can be removed." + # $TEST$ no info "Overriding member is identical to overridden member and can be removed." @Pure fun »myOwnInstanceMethod«(a: Number = 0) -> r: Number - // $TEST$ no info "Overriding member is identical to overridden member and can be removed." + # $TEST$ no info "Overriding member is identical to overridden member and can be removed." @Pure static fun »myOwnStaticMethod«(a: Number = 0) -> r: Number } class MyClass2 sub MySuperClass1 { - // $TEST$ no info "Overriding member is identical to overridden member and can be removed." + # $TEST$ no info "Overriding member is identical to overridden member and can be removed." attr »myInstanceAttribute«: Int - // $TEST$ no info "Overriding member is identical to overridden member and can be removed." + # $TEST$ no info "Overriding member is identical to overridden member and can be removed." static attr »myStaticAttribute«: Int - // $TEST$ no info "Overriding member is identical to overridden member and can be removed." + # $TEST$ no info "Overriding member is identical to overridden member and can be removed." @Pure fun »myInstanceMethod«(a: Number = 0) -> r: Int - // $TEST$ no info "Overriding member is identical to overridden member and can be removed." + # $TEST$ no info "Overriding member is identical to overridden member and can be removed." @Pure static fun »myStaticMethod«(a: Number = 0) -> r: Int } diff --git a/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method should differ from overridden method/purity.sdstest b/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method should differ from overridden method/purity.sdstest index 8ef0a9e8..6ff91e70 100644 --- a/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method should differ from overridden method/purity.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method should differ from overridden method/purity.sdstest @@ -8,19 +8,19 @@ class MySuperClass2 { } class MyClass3 sub MySuperClass2 { - // $TEST$ no info "Overriding member is identical to overridden member and can be removed." + # $TEST$ no info "Overriding member is identical to overridden member and can be removed." @Pure fun »myInstanceMethod«(a: Number = 0) -> r: Number - // $TEST$ no info "Overriding member is identical to overridden member and can be removed." + # $TEST$ no info "Overriding member is identical to overridden member and can be removed." @Pure static fun »myStaticMethod«(a: Number = 0) -> r: Number } class MyClass4 sub MySuperClass2 { - // $TEST$ no info "Overriding member is identical to overridden member and can be removed." + # $TEST$ no info "Overriding member is identical to overridden member and can be removed." @Impure([]) fun »myInstanceMethod«(a: Number = 0) -> r: Number - // $TEST$ no info "Overriding member is identical to overridden member and can be removed." + # $TEST$ no info "Overriding member is identical to overridden member and can be removed." @Impure([]) static fun »myStaticMethod«(a: Number = 0) -> r: Number } diff --git a/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method should differ from overridden method/safeds lang any.sdstest b/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method should differ from overridden method/safeds lang any.sdstest index 891d2056..56c02bb1 100644 --- a/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method should differ from overridden method/safeds lang any.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method should differ from overridden method/safeds lang any.sdstest @@ -1,6 +1,6 @@ package safeds.lang class Any { - // $TEST$ no info "Overriding member is identical to overridden member and can be removed." + # $TEST$ no info "Overriding member is identical to overridden member and can be removed." fun »toString«() -> s: String } diff --git a/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method should differ from overridden method/type parameters.sdstest b/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method should differ from overridden method/type parameters.sdstest index d6e2216f..46b66ada 100644 --- a/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method should differ from overridden method/type parameters.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method should differ from overridden method/type parameters.sdstest @@ -8,34 +8,34 @@ class MySuperClass { } class MyClass2 sub MySuperClass { - // $TEST$ info "Overriding member is identical to overridden member and can be removed." + # $TEST$ info "Overriding member is identical to overridden member and can be removed." attr »myInstanceAttribute«: T - // $TEST$ info "Overriding member is identical to overridden member and can be removed." + # $TEST$ info "Overriding member is identical to overridden member and can be removed." @Pure fun »myInstanceMethod1«(a: T = 0) -> r: T } class MyClass1 sub MySuperClass { - // $TEST$ info "Overriding member is identical to overridden member and can be removed." + # $TEST$ info "Overriding member is identical to overridden member and can be removed." attr »myInstanceAttribute«: Number - // $TEST$ info "Overriding member is identical to overridden member and can be removed." + # $TEST$ info "Overriding member is identical to overridden member and can be removed." @Pure fun »myInstanceMethod1«(a: Number = 0) -> r: Number } class MyClass3 sub MySuperClass { - // $TEST$ no info "Overriding member is identical to overridden member and can be removed." + # $TEST$ no info "Overriding member is identical to overridden member and can be removed." attr »myInstanceAttribute«: Int - // $TEST$ no info "Overriding member is identical to overridden member and can be removed." + # $TEST$ no info "Overriding member is identical to overridden member and can be removed." @Pure fun »myInstanceMethod1«(a: Number = 0) -> r: Int } class MyClass4 sub MySuperClass { - // $TEST$ no info "Overriding member is identical to overridden member and can be removed." + # $TEST$ no info "Overriding member is identical to overridden member and can be removed." @Pure fun »myInstanceMethod2«(a: T) -> r: T - // $TEST$ info "Overriding member is identical to overridden member and can be removed." + # $TEST$ info "Overriding member is identical to overridden member and can be removed." @Pure fun »myInstanceMethod3«(a: T) -> r: T } class MyClass5 sub MySuperClass { - // $TEST$ no info "Overriding member is identical to overridden member and can be removed." + # $TEST$ no info "Overriding member is identical to overridden member and can be removed." @Pure fun »myInstanceMethod3«(a: Int) -> r: Int } diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/annotations.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/annotations.sdstest index d1b1be50..afac890b 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/annotations.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/annotations.sdstest @@ -1,12 +1,12 @@ package tests.validation.names.casing -// $TEST$ no warning "Names of annotations should be UpperCamelCase." +# $TEST$ no warning "Names of annotations should be UpperCamelCase." annotation »AnnotationUppercase1« -// $TEST$ no warning "Names of annotations should be UpperCamelCase." +# $TEST$ no warning "Names of annotations should be UpperCamelCase." annotation »`AnnotationUppercase2`« -// $TEST$ warning "Names of annotations should be UpperCamelCase." +# $TEST$ warning "Names of annotations should be UpperCamelCase." annotation »annotationLowercase« -// $TEST$ warning "Names of annotations should be UpperCamelCase." +# $TEST$ warning "Names of annotations should be UpperCamelCase." annotation »_annotationUnderscore« -// $TEST$ warning "Names of annotations should be UpperCamelCase." +# $TEST$ warning "Names of annotations should be UpperCamelCase." annotation »Annotation_Snake_Case« diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/attributes.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/attributes.sdstest index 66099ce6..469bd6e8 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/attributes.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/attributes.sdstest @@ -1,14 +1,14 @@ package tests.validation.names.casing class MyClass { - // $TEST$ warning "Names of attributes should be lowerCamelCase." + # $TEST$ warning "Names of attributes should be lowerCamelCase." attr »AttributeUppercase«: Int - // $TEST$ no warning "Names of attributes should be lowerCamelCase." + # $TEST$ no warning "Names of attributes should be lowerCamelCase." attr »attributeLowercase1«: Int - // $TEST$ no warning "Names of attributes should be lowerCamelCase." + # $TEST$ no warning "Names of attributes should be lowerCamelCase." attr »`attributeLowercase2`«: Int - // $TEST$ warning "Names of attributes should be lowerCamelCase." + # $TEST$ warning "Names of attributes should be lowerCamelCase." attr »_attributeUnderscore«: Int - // $TEST$ warning "Names of attributes should be lowerCamelCase." + # $TEST$ warning "Names of attributes should be lowerCamelCase." attr »attribute_snake_case«: Int } diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/block lambda results.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/block lambda results.sdstest index 63ca47c3..0913cb3b 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/block lambda results.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/block lambda results.sdstest @@ -2,15 +2,15 @@ package tests.validation.names.casing pipeline myPipeline1 { () { - // $TEST$ warning "Names of block lambda results should be lowerCamelCase." + # $TEST$ warning "Names of block lambda results should be lowerCamelCase." yield »LambdaResultUppercase« = 1; - // $TEST$ no warning "Names of block lambda results should be lowerCamelCase." + # $TEST$ no warning "Names of block lambda results should be lowerCamelCase." yield »lambdaResultLowercase1« = 1; - // $TEST$ no warning "Names of block lambda results should be lowerCamelCase." + # $TEST$ no warning "Names of block lambda results should be lowerCamelCase." yield »`lambdaResultLowercase2`« = 1; - // $TEST$ warning "Names of block lambda results should be lowerCamelCase." + # $TEST$ warning "Names of block lambda results should be lowerCamelCase." yield »_lambdaResultUnderscore« = 1; - // $TEST$ warning "Names of block lambda results should be lowerCamelCase." + # $TEST$ warning "Names of block lambda results should be lowerCamelCase." yield »lambdaResult_snake_case« = 1; }; } diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/classes.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/classes.sdstest index 8c571f72..b33faf44 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/classes.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/classes.sdstest @@ -1,12 +1,12 @@ package tests.validation.names.casing -// $TEST$ no warning "Names of classes should be UpperCamelCase." +# $TEST$ no warning "Names of classes should be UpperCamelCase." class »ClassUppercase1« -// $TEST$ no warning "Names of classes should be UpperCamelCase." +# $TEST$ no warning "Names of classes should be UpperCamelCase." class »`ClassUppercase2`« -// $TEST$ warning "Names of classes should be UpperCamelCase." +# $TEST$ warning "Names of classes should be UpperCamelCase." class »classLowercase« -// $TEST$ warning "Names of classes should be UpperCamelCase." +# $TEST$ warning "Names of classes should be UpperCamelCase." class »_classUnderscore« -// $TEST$ warning "Names of classes should be UpperCamelCase." +# $TEST$ warning "Names of classes should be UpperCamelCase." class »Class_Snake_Case« diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/enum variants.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/enum variants.sdstest index 11fbe086..4b5f0db9 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/enum variants.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/enum variants.sdstest @@ -1,14 +1,14 @@ package tests.validation.names.casing enum MyEnum { - // $TEST$ no warning "Names of enum variants should be UpperCamelCase." + # $TEST$ no warning "Names of enum variants should be UpperCamelCase." »EnumVariantUppercase1« - // $TEST$ no warning "Names of enum variants should be UpperCamelCase." + # $TEST$ no warning "Names of enum variants should be UpperCamelCase." »`EnumVariantUppercase2`« - // $TEST$ warning "Names of enum variants should be UpperCamelCase." + # $TEST$ warning "Names of enum variants should be UpperCamelCase." »enumVariantLowercase« - // $TEST$ warning "Names of enum variants should be UpperCamelCase." + # $TEST$ warning "Names of enum variants should be UpperCamelCase." »_enumVariantUnderscore« - // $TEST$ warning "Names of enum variants should be UpperCamelCase." + # $TEST$ warning "Names of enum variants should be UpperCamelCase." »Enum_Variant_Snake_Case« } diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/enums.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/enums.sdstest index 90bf4cf0..f55b3ef7 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/enums.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/enums.sdstest @@ -1,12 +1,12 @@ package tests.validation.names.casing -// $TEST$ no warning "Names of enums should be UpperCamelCase." +# $TEST$ no warning "Names of enums should be UpperCamelCase." enum »EnumUppercase1« -// $TEST$ no warning "Names of enums should be UpperCamelCase." +# $TEST$ no warning "Names of enums should be UpperCamelCase." enum »`EnumUppercase2`« -// $TEST$ warning "Names of enums should be UpperCamelCase." +# $TEST$ warning "Names of enums should be UpperCamelCase." enum »enumLowercase« -// $TEST$ warning "Names of enums should be UpperCamelCase." +# $TEST$ warning "Names of enums should be UpperCamelCase." enum »_enumUnderscore« -// $TEST$ warning "Names of enums should be UpperCamelCase." +# $TEST$ warning "Names of enums should be UpperCamelCase." enum »Enum_Snake_Case« diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/functions.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/functions.sdstest index 41d16b3d..8ed50041 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/functions.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/functions.sdstest @@ -1,12 +1,12 @@ package tests.validation.names.casing -// $TEST$ warning "Names of functions should be lowerCamelCase." +# $TEST$ warning "Names of functions should be lowerCamelCase." fun »FunctionUppercase«() -// $TEST$ no warning "Names of functions should be lowerCamelCase." +# $TEST$ no warning "Names of functions should be lowerCamelCase." fun »functionLowercase1«() -// $TEST$ no warning "Names of functions should be lowerCamelCase." +# $TEST$ no warning "Names of functions should be lowerCamelCase." fun »`functionLowercase2`«() -// $TEST$ warning "Names of functions should be lowerCamelCase." +# $TEST$ warning "Names of functions should be lowerCamelCase." fun »_functionUnderscore«() -// $TEST$ warning "Names of functions should be lowerCamelCase." +# $TEST$ warning "Names of functions should be lowerCamelCase." fun »function_snake_case«() diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/no package name.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/no package name.sdstest index b31d16d3..3948a368 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/no package name.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/no package name.sdstest @@ -1 +1 @@ -// $TEST$ no warning "All segments of the qualified name of a package should be lowerCamelCase." +# $TEST$ no warning "All segments of the qualified name of a package should be lowerCamelCase." diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/package name leading underscore.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/package name leading underscore.sdstest index 252c47d9..c2ae50bb 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/package name leading underscore.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/package name leading underscore.sdstest @@ -1,2 +1,2 @@ -// $TEST$ warning "All segments of the qualified name of a package should be lowerCamelCase." +# $TEST$ warning "All segments of the qualified name of a package should be lowerCamelCase." package »tests.validation.declarations._underscore« diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/package name lowercase escaped.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/package name lowercase escaped.sdstest index c5bf8580..2aff365f 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/package name lowercase escaped.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/package name lowercase escaped.sdstest @@ -1,2 +1,2 @@ -// $TEST$ no warning "All segments of the qualified name of a package should be lowerCamelCase." +# $TEST$ no warning "All segments of the qualified name of a package should be lowerCamelCase." package »tests.validation.declarations.`lowercase1`« diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/package name lowercase.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/package name lowercase.sdstest index 44069623..ad036921 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/package name lowercase.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/package name lowercase.sdstest @@ -1,2 +1,2 @@ -// $TEST$ no warning "All segments of the qualified name of a package should be lowerCamelCase." +# $TEST$ no warning "All segments of the qualified name of a package should be lowerCamelCase." package »tests.validation.declarations.lowercase1« diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/package name snake case.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/package name snake case.sdstest index 41197e77..efe68e9d 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/package name snake case.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/package name snake case.sdstest @@ -1,2 +1,2 @@ -// $TEST$ warning "All segments of the qualified name of a package should be lowerCamelCase." +# $TEST$ warning "All segments of the qualified name of a package should be lowerCamelCase." package »tests.validation.declarations.snake_case« diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/package name uppercase.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/package name uppercase.sdstest index 07272cee..3ef878ac 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/package name uppercase.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/package name uppercase.sdstest @@ -1,2 +1,2 @@ -// $TEST$ warning "All segments of the qualified name of a package should be lowerCamelCase." +# $TEST$ warning "All segments of the qualified name of a package should be lowerCamelCase." package »tests.validation.declarations.Uppercase« diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/parameters.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/parameters.sdstest index 59b57573..15f15a52 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/parameters.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/parameters.sdstest @@ -1,14 +1,14 @@ package tests.validation.names.casing fun myFunction1( - // $TEST$ warning "Names of parameters should be lowerCamelCase." + # $TEST$ warning "Names of parameters should be lowerCamelCase." »ParameterUppercase«: Int, - // $TEST$ no warning "Names of parameters should be lowerCamelCase." + # $TEST$ no warning "Names of parameters should be lowerCamelCase." »parameterLowercase1«: Int, - // $TEST$ no warning "Names of parameters should be lowerCamelCase." + # $TEST$ no warning "Names of parameters should be lowerCamelCase." »`parameterLowercase2`«: Int, - // $TEST$ warning "Names of parameters should be lowerCamelCase." + # $TEST$ warning "Names of parameters should be lowerCamelCase." »_parameterUnderscore«: Int, - // $TEST$ warning "Names of parameters should be lowerCamelCase." + # $TEST$ warning "Names of parameters should be lowerCamelCase." »parameter_snake_case«: Int ) diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/pipelines.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/pipelines.sdstest index c9a46ef9..5b31adeb 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/pipelines.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/pipelines.sdstest @@ -1,12 +1,12 @@ package tests.validation.names.casing -// $TEST$ warning "Names of pipelines should be lowerCamelCase." +# $TEST$ warning "Names of pipelines should be lowerCamelCase." pipeline »PipelineUppercase« {} -// $TEST$ no warning "Names of pipelines should be lowerCamelCase." +# $TEST$ no warning "Names of pipelines should be lowerCamelCase." pipeline »pipelineLowercase1« {} -// $TEST$ no warning "Names of pipelines should be lowerCamelCase." +# $TEST$ no warning "Names of pipelines should be lowerCamelCase." pipeline »`pipelineLowercase2`« {} -// $TEST$ warning "Names of pipelines should be lowerCamelCase." +# $TEST$ warning "Names of pipelines should be lowerCamelCase." pipeline »_pipelineUnderscore« {} -// $TEST$ warning "Names of pipelines should be lowerCamelCase." +# $TEST$ warning "Names of pipelines should be lowerCamelCase." pipeline »pipeline_snake_case« {} diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/placeholders.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/placeholders.sdstest index 1cb0658b..d3abe702 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/placeholders.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/placeholders.sdstest @@ -1,14 +1,14 @@ package tests.validation.names.casing pipeline myPipeline2 { - // $TEST$ warning "Names of placeholders should be lowerCamelCase." + # $TEST$ warning "Names of placeholders should be lowerCamelCase." val »PlaceholderUppercase« = 1; - // $TEST$ no warning "Names of placeholders should be lowerCamelCase." + # $TEST$ no warning "Names of placeholders should be lowerCamelCase." val »placeholderLowercase1« = 1; - // $TEST$ no warning "Names of placeholders should be lowerCamelCase." + # $TEST$ no warning "Names of placeholders should be lowerCamelCase." val »`placeholderLowercase2`« = 1; - // $TEST$ warning "Names of placeholders should be lowerCamelCase." + # $TEST$ warning "Names of placeholders should be lowerCamelCase." val »_placeholderUnderscore« = 1; - // $TEST$ warning "Names of placeholders should be lowerCamelCase." + # $TEST$ warning "Names of placeholders should be lowerCamelCase." val »placeholder_snake_case« = 1; } diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/results.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/results.sdstest index f0d2a048..5299c82e 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/results.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/results.sdstest @@ -1,14 +1,14 @@ package tests.validation.names.casing fun myFunction2() -> ( - // $TEST$ warning "Names of results should be lowerCamelCase." + # $TEST$ warning "Names of results should be lowerCamelCase." »ResultUppercase«: Int, - // $TEST$ no warning "Names of results should be lowerCamelCase." + # $TEST$ no warning "Names of results should be lowerCamelCase." »resultLowercase1«: Int, - // $TEST$ no warning "Names of results should be lowerCamelCase." + # $TEST$ no warning "Names of results should be lowerCamelCase." »`resultLowercase2`«: Int, - // $TEST$ warning "Names of results should be lowerCamelCase." + # $TEST$ warning "Names of results should be lowerCamelCase." »_resultUnderscore«: Int, - // $TEST$ warning "Names of results should be lowerCamelCase." + # $TEST$ warning "Names of results should be lowerCamelCase." »result_snake_case«: Int ) diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/schemas.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/schemas.sdstest index a456b764..b53308ca 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/schemas.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/schemas.sdstest @@ -1,12 +1,12 @@ package tests.validation.names.casing -// $TEST$ no warning "Names of schemas should be UpperCamelCase." +# $TEST$ no warning "Names of schemas should be UpperCamelCase." schema »SchemaUppercase1« {} -// $TEST$ no warning "Names of schemas should be UpperCamelCase." +# $TEST$ no warning "Names of schemas should be UpperCamelCase." schema »`SchemaUppercase2`« {} -// $TEST$ warning "Names of schemas should be UpperCamelCase." +# $TEST$ warning "Names of schemas should be UpperCamelCase." schema »schemaLowercase« {} -// $TEST$ warning "Names of schemas should be UpperCamelCase." +# $TEST$ warning "Names of schemas should be UpperCamelCase." schema »_schemaUnderscore« {} -// $TEST$ warning "Names of schemas should be UpperCamelCase." +# $TEST$ warning "Names of schemas should be UpperCamelCase." schema »Schema_Snake_Case« {} diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/segments.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/segments.sdstest index b06585eb..38d40953 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/segments.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/segments.sdstest @@ -1,12 +1,12 @@ package tests.validation.names.casing -// $TEST$ warning "Names of segments should be lowerCamelCase." +# $TEST$ warning "Names of segments should be lowerCamelCase." segment »SegmentUppercase«() {} -// $TEST$ no warning "Names of segments should be lowerCamelCase." +# $TEST$ no warning "Names of segments should be lowerCamelCase." segment »segmentLowercase1«() {} -// $TEST$ no warning "Names of segments should be lowerCamelCase." +# $TEST$ no warning "Names of segments should be lowerCamelCase." segment »`segmentLowercase2`«() {} -// $TEST$ warning "Names of segments should be lowerCamelCase." +# $TEST$ warning "Names of segments should be lowerCamelCase." segment »_segmentUnderscore«() {} -// $TEST$ warning "Names of segments should be lowerCamelCase." +# $TEST$ warning "Names of segments should be lowerCamelCase." segment »segment_snake_case«() {} diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/type parameters.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/type parameters.sdstest index 267bec76..9e2bf7eb 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/type parameters.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/type parameters.sdstest @@ -1,14 +1,14 @@ package tests.validation.names.casing fun myFunction3< - // $TEST$ no warning "Names of type parameters should be UpperCamelCase." + # $TEST$ no warning "Names of type parameters should be UpperCamelCase." »TypeParameterUppercase1«, - // $TEST$ no warning "Names of type parameters should be UpperCamelCase." + # $TEST$ no warning "Names of type parameters should be UpperCamelCase." »`TypeParameterUppercase2`«, - // $TEST$ warning "Names of type parameters should be UpperCamelCase." + # $TEST$ warning "Names of type parameters should be UpperCamelCase." »typeParameterLowercase«, - // $TEST$ warning "Names of type parameters should be UpperCamelCase." + # $TEST$ warning "Names of type parameters should be UpperCamelCase." »_typeParameterUnderscore«, - // $TEST$ warning "Names of type parameters should be UpperCamelCase." + # $TEST$ warning "Names of type parameters should be UpperCamelCase." »Type_Parameter_Snake_Case« >() diff --git a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/annotations.sdstest b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/annotations.sdstest index 2f1ed513..de2b2d78 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/annotations.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/annotations.sdstest @@ -1,7 +1,7 @@ package tests.validation.names.blockLambdaPrefix -// $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." +# $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." annotation »__gen_0« -// $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." +# $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." annotation »_gen_1« diff --git a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/attributes.sdstest b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/attributes.sdstest index 410cd100..0dcf4433 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/attributes.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/attributes.sdstest @@ -1,9 +1,9 @@ package tests.validation.names.blockLambdaPrefix class MyClass { - // $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." + # $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." attr »__gen_0«: Int - // $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." + # $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." attr »_gen_1«: Int } diff --git a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/block lambda results.sdstest b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/block lambda results.sdstest index dcb4646b..1f092d73 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/block lambda results.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/block lambda results.sdstest @@ -2,10 +2,10 @@ package tests.validation.names.blockLambdaPrefix pipeline myPipeline2 { () { - // $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." + # $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." yield »__gen_0« = 1; - // $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." + # $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." yield »_gen_1« = 1; }; } diff --git a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/classes.sdstest b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/classes.sdstest index d7e77027..0eb9ea1f 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/classes.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/classes.sdstest @@ -1,7 +1,7 @@ package tests.validation.names.blockLambdaPrefix -// $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." +# $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." class »__gen_0« -// $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." +# $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." class »_gen_1« diff --git a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/enum variants.sdstest b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/enum variants.sdstest index d69569bd..7c352b41 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/enum variants.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/enum variants.sdstest @@ -1,9 +1,9 @@ package tests.validation.names.blockLambdaPrefix enum MyEnum { - // $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." + # $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." »__gen_0« - // $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." + # $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." »_gen_1« } diff --git a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/enums.sdstest b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/enums.sdstest index c549ec75..4d1d05e4 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/enums.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/enums.sdstest @@ -1,7 +1,7 @@ package tests.validation.names.blockLambdaPrefix -// $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." +# $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." enum »__gen_0« -// $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." +# $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." enum »_gen_1« diff --git a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/functions.sdstest b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/functions.sdstest index bdd235e7..e263101b 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/functions.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/functions.sdstest @@ -1,7 +1,7 @@ package tests.validation.names.blockLambdaPrefix -// $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." +# $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." fun »__gen_0«() -// $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." +# $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." fun »_gen_1«() diff --git a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/no package name.sdstest b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/no package name.sdstest index 961d17e5..1078f95c 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/no package name.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/no package name.sdstest @@ -1 +1 @@ -// $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." +# $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." diff --git a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/package name with codegen prefix.sdstest b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/package name with codegen prefix.sdstest index 72430e42..6d083e3f 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/package name with codegen prefix.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/package name with codegen prefix.sdstest @@ -1,2 +1,2 @@ -// $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." +# $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." package »__gen_0« diff --git a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/package name without codegen prefix.sdstest b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/package name without codegen prefix.sdstest index 56bc1da4..74a1d36e 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/package name without codegen prefix.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/package name without codegen prefix.sdstest @@ -1,2 +1,2 @@ -// $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." +# $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." package »_gen_1« diff --git a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/parameters.sdstest b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/parameters.sdstest index 6fc81e57..f1c36bd1 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/parameters.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/parameters.sdstest @@ -1,9 +1,9 @@ package tests.validation.names.blockLambdaPrefix fun myFunction1( - // $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." + # $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." »__gen_0«: Int, - // $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." + # $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." »_gen_1«: Int, ) diff --git a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/pipelines.sdstest b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/pipelines.sdstest index e5da70f5..cc0724f1 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/pipelines.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/pipelines.sdstest @@ -1,7 +1,7 @@ package tests.validation.names.blockLambdaPrefix -// $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." +# $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." pipeline »__gen_0« {} -// $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." +# $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." pipeline »_gen_1« {} diff --git a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/placeholders.sdstest b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/placeholders.sdstest index 7bb4abb1..7933fd4b 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/placeholders.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/placeholders.sdstest @@ -1,9 +1,9 @@ package tests.validation.names.blockLambdaPrefix pipeline myPipeline1 { - // $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." + # $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." val »__gen_0« = 1; - // $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." + # $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." val »_gen_1« = 1; } diff --git a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/results.sdstest b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/results.sdstest index 654e3798..23be1a97 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/results.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/results.sdstest @@ -1,9 +1,9 @@ package tests.validation.names.blockLambdaPrefix fun myFunction2() -> ( - // $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." + # $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." »__gen_0«: Int, - // $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." + # $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." »_gen_1«: Int, ) diff --git a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/schemas.sdstest b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/schemas.sdstest index 7ec0a8ad..17445874 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/schemas.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/schemas.sdstest @@ -1,7 +1,7 @@ package tests.validation.names.blockLambdaPrefix -// $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." +# $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." schema »__gen_0« {} -// $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." +# $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." schema »_gen_1« {} diff --git a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/segments.sdstest b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/segments.sdstest index fe7c64e4..42dae59c 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/segments.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/segments.sdstest @@ -1,7 +1,7 @@ package tests.validation.names.blockLambdaPrefix -// $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." +# $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." segment »__gen_0«() {} -// $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." +# $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." segment »_gen_1«() {} diff --git a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/type parameters.sdstest b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/type parameters.sdstest index 71f70028..17ffc0ee 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/type parameters.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/type parameters.sdstest @@ -1,9 +1,9 @@ package tests.validation.names.blockLambdaPrefix fun myFunction3< - // $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." + # $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." »__gen_0«, - // $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." + # $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." »_gen_1«, >() diff --git a/packages/ttsl-lang/tests/resources/validation/names/core names/in safeds lang.sdstest b/packages/ttsl-lang/tests/resources/validation/names/core names/in safeds lang.sdstest index e3a02f0a..313fe0f9 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/core names/in safeds lang.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/core names/in safeds lang.sdstest @@ -1,4 +1,4 @@ package safeds.lang -// $TEST$ no error "Names of core declarations must not be used for own declarations." +# $TEST$ no error "Names of core declarations must not be used for own declarations." annotation »Number« diff --git a/packages/ttsl-lang/tests/resources/validation/names/core names/main.sdstest b/packages/ttsl-lang/tests/resources/validation/names/core names/main.sdstest index 78ccb7d0..03e5f4d2 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/core names/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/core names/main.sdstest @@ -1,7 +1,7 @@ package tests.validation.names.coreNames -// $TEST$ error "Names of core declarations must not be used for own declarations." +# $TEST$ error "Names of core declarations must not be used for own declarations." annotation »Any« -// $TEST$ no error "Names of core declarations must not be used for own declarations." +# $TEST$ no error "Names of core declarations must not be used for own declarations." annotation »Any1« diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/main.sdstest b/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/main.sdstest index 433eb345..b95de097 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/main.sdstest @@ -1,78 +1,78 @@ package tests.validation.names.acrossFiles -// $TEST$ error "Multiple declarations in this package have the name 'DuplicateAnnotation'." +# $TEST$ error "Multiple declarations in this package have the name 'DuplicateAnnotation'." annotation »DuplicateAnnotation« -// $TEST$ error "Multiple declarations in this package have the name 'DuplicateClass'." +# $TEST$ error "Multiple declarations in this package have the name 'DuplicateClass'." class »DuplicateClass« -// $TEST$ error "Multiple declarations in this package have the name 'DuplicateEnum'." +# $TEST$ error "Multiple declarations in this package have the name 'DuplicateEnum'." enum »DuplicateEnum« -// $TEST$ error "Multiple declarations in this package have the name 'duplicateFunction'." +# $TEST$ error "Multiple declarations in this package have the name 'duplicateFunction'." fun »duplicateFunction«() -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." pipeline »duplicatePipeline« {} -// $TEST$ error "Multiple declarations in this package have the name 'DuplicateSchema'." +# $TEST$ error "Multiple declarations in this package have the name 'DuplicateSchema'." schema »DuplicateSchema« {} -// $TEST$ error "Multiple declarations in this package have the name 'duplicatePublicSegment'." +# $TEST$ error "Multiple declarations in this package have the name 'duplicatePublicSegment'." segment »duplicatePublicSegment«() {} -// $TEST$ error "Multiple declarations in this package have the name 'duplicateInternalSegment'." +# $TEST$ error "Multiple declarations in this package have the name 'duplicateInternalSegment'." internal segment »duplicateInternalSegment«() {} -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." private segment »duplicatePrivateSegment«() {} -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." annotation »UniqueAnnotation« -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." class »UniqueClass« -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." enum »UniqueEnum« -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." fun »uniqueFunction«() -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." pipeline »uniquePipeline« {} -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." schema »UniqueSchema« {} -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." segment »uniquePublicSegment«() {} -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." internal segment »uniqueInternalSegment«() {} -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." private segment »uniquePrivateSegment«() {} -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." annotation »MyAnnotation« -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." annotation »MyAnnotation« -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." class »MyClass« -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." class »MyClass« -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." enum »MyEnum« -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." enum »MyEnum« -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." fun »myFunction«() -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." fun »myFunction«() -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." pipeline »myPipeline« {} -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." pipeline »myPipeline« {} -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." schema »MySchema« {} -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." schema »MySchema« {} -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." segment »myPublicSegment«() {} -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." segment »myPublicSegment«() {} -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." internal segment »myInternalSegment«() {} -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." internal segment »myInternalSegment«() {} -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." private segment »myPrivateSegment«() {} -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." private segment »myPrivateSegment«() {} diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/other package.sdstest b/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/other package.sdstest index 84389abf..b61ab2b3 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/other package.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/other package.sdstest @@ -1,20 +1,20 @@ package tests.validation.names.acrossFiles.other -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." annotation »UniqueAnnotation« -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." class »UniqueClass« -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." enum »UniqueEnum« -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." fun »uniqueFunction«() -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." pipeline »uniquePipeline« {} -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." schema »UniqueSchema« {} -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." segment »uniquePublicSegment«() {} -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." internal segment »uniqueInternalSegment«() {} -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." private segment »uniquePrivateSegment«() {} diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/safeds 1.sdstest b/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/safeds 1.sdstest index 605fa9d5..92ca0c67 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/safeds 1.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/safeds 1.sdstest @@ -4,24 +4,24 @@ package safeds.lang * Declarations that only occur a second time in builtin files should be excluded, so we don't get errors while editing them. */ -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." class »Any« -// $TEST$ error "Multiple builtin declarations have the name 'DuplicateAnnotation'." +# $TEST$ error "Multiple builtin declarations have the name 'DuplicateAnnotation'." annotation »DuplicateAnnotation« -// $TEST$ error "Multiple builtin declarations have the name 'DuplicateClass'." +# $TEST$ error "Multiple builtin declarations have the name 'DuplicateClass'." class »DuplicateClass« -// $TEST$ error "Multiple builtin declarations have the name 'DuplicateEnum'." +# $TEST$ error "Multiple builtin declarations have the name 'DuplicateEnum'." enum »DuplicateEnum« -// $TEST$ error "Multiple builtin declarations have the name 'duplicateFunction'." +# $TEST$ error "Multiple builtin declarations have the name 'duplicateFunction'." fun »duplicateFunction«() -// $TEST$ no error r"Multiple builtin declarations have the name '\w*'\." +# $TEST$ no error r"Multiple builtin declarations have the name '\w*'\." pipeline »duplicatePipeline« {} -// $TEST$ error "Multiple builtin declarations have the name 'DuplicateSchema'." +# $TEST$ error "Multiple builtin declarations have the name 'DuplicateSchema'." schema »DuplicateSchema« {} -// $TEST$ error "Multiple builtin declarations have the name 'duplicatePublicSegment'." +# $TEST$ error "Multiple builtin declarations have the name 'duplicatePublicSegment'." segment »duplicatePublicSegment«() {} -// $TEST$ error "Multiple builtin declarations have the name 'duplicateInternalSegment'." +# $TEST$ error "Multiple builtin declarations have the name 'duplicateInternalSegment'." internal segment »duplicateInternalSegment«() {} -// $TEST$ no error r"Multiple builtin declarations have the name '\w*'\." +# $TEST$ no error r"Multiple builtin declarations have the name '\w*'\." private segment »duplicatePrivateSegment«() {} diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/safeds 2.sdstest b/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/safeds 2.sdstest index c0f4a34d..4c4763d8 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/safeds 2.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/safeds 2.sdstest @@ -1,20 +1,20 @@ package safeds.lang.other -// $TEST$ error "Multiple builtin declarations have the name 'DuplicateAnnotation'." +# $TEST$ error "Multiple builtin declarations have the name 'DuplicateAnnotation'." annotation »DuplicateAnnotation« -// $TEST$ error "Multiple builtin declarations have the name 'DuplicateClass'." +# $TEST$ error "Multiple builtin declarations have the name 'DuplicateClass'." class »DuplicateClass« -// $TEST$ error "Multiple builtin declarations have the name 'DuplicateEnum'." +# $TEST$ error "Multiple builtin declarations have the name 'DuplicateEnum'." enum »DuplicateEnum« -// $TEST$ error "Multiple builtin declarations have the name 'duplicateFunction'." +# $TEST$ error "Multiple builtin declarations have the name 'duplicateFunction'." fun »duplicateFunction«() -// $TEST$ no error r"Multiple builtin declarations have the name '\w*'\." +# $TEST$ no error r"Multiple builtin declarations have the name '\w*'\." pipeline »duplicatePipeline« {} -// $TEST$ error "Multiple builtin declarations have the name 'DuplicateSchema'." +# $TEST$ error "Multiple builtin declarations have the name 'DuplicateSchema'." schema »DuplicateSchema« {} -// $TEST$ error "Multiple builtin declarations have the name 'duplicatePublicSegment'." +# $TEST$ error "Multiple builtin declarations have the name 'duplicatePublicSegment'." segment »duplicatePublicSegment«() {} -// $TEST$ error "Multiple builtin declarations have the name 'duplicateInternalSegment'." +# $TEST$ error "Multiple builtin declarations have the name 'duplicateInternalSegment'." internal segment »duplicateInternalSegment«() {} -// $TEST$ no error r"Multiple builtin declarations have the name '\w*'\." +# $TEST$ no error r"Multiple builtin declarations have the name '\w*'\." private segment »duplicatePrivateSegment«() {} diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/same package.sdstest b/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/same package.sdstest index ea17382a..a3686834 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/same package.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/same package.sdstest @@ -1,20 +1,20 @@ package tests.validation.names.acrossFiles -// $TEST$ error "Multiple declarations in this package have the name 'DuplicateAnnotation'." +# $TEST$ error "Multiple declarations in this package have the name 'DuplicateAnnotation'." annotation »DuplicateAnnotation« -// $TEST$ error "Multiple declarations in this package have the name 'DuplicateClass'." +# $TEST$ error "Multiple declarations in this package have the name 'DuplicateClass'." class »DuplicateClass« -// $TEST$ error "Multiple declarations in this package have the name 'DuplicateEnum'." +# $TEST$ error "Multiple declarations in this package have the name 'DuplicateEnum'." enum »DuplicateEnum« -// $TEST$ error "Multiple declarations in this package have the name 'duplicateFunction'." +# $TEST$ error "Multiple declarations in this package have the name 'duplicateFunction'." fun »duplicateFunction«() -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." pipeline »duplicatePipeline« {} -// $TEST$ error "Multiple declarations in this package have the name 'DuplicateSchema'." +# $TEST$ error "Multiple declarations in this package have the name 'DuplicateSchema'." schema »DuplicateSchema« {} -// $TEST$ error "Multiple declarations in this package have the name 'duplicatePublicSegment'." +# $TEST$ error "Multiple declarations in this package have the name 'duplicatePublicSegment'." segment »duplicatePublicSegment«() {} -// $TEST$ error "Multiple declarations in this package have the name 'duplicateInternalSegment'." +# $TEST$ error "Multiple declarations in this package have the name 'duplicateInternalSegment'." internal segment »duplicateInternalSegment«() {} -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." private segment »duplicatePrivateSegment«() {} diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in annotation/main.sdstest b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in annotation/main.sdstest index 425a5f85..86e23675 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in annotation/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in annotation/main.sdstest @@ -1,10 +1,10 @@ package tests.validation.names.duplicates.inAnnotation annotation A( - // $TEST$ no error r"A parameter with name '\w*' exists already\." + # $TEST$ no error r"A parameter with name '\w*' exists already\." »duplicateParameter«: Int, - // $TEST$ error "A parameter with name 'duplicateParameter' exists already." + # $TEST$ error "A parameter with name 'duplicateParameter' exists already." »duplicateParameter«: Int, - // $TEST$ no error r"A parameter with name '\w*' exists already\." + # $TEST$ no error r"A parameter with name '\w*' exists already\." »uniqueParameter«: Int ) diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in block lambda/main.sdstest b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in block lambda/main.sdstest index 5a2cbd98..df52dd99 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in block lambda/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in block lambda/main.sdstest @@ -2,50 +2,50 @@ package tests.validation.names.duplicates.inBlockLambda pipeline p { ( - // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." »duplicateParameter«, - // $TEST$ error "A parameter or placeholder with name 'duplicateParameter' exists already." + # $TEST$ error "A parameter or placeholder with name 'duplicateParameter' exists already." »duplicateParameter«, - // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." »uniqueParameter«, - // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." »parameterAndPlaceholder«, - // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." »parameterAndResult« ) { - // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." val »duplicatePlaceholder« = 1; - // $TEST$ error "A parameter or placeholder with name 'duplicatePlaceholder' exists already." + # $TEST$ error "A parameter or placeholder with name 'duplicatePlaceholder' exists already." val »duplicatePlaceholder« = 1; - // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." val »uniquePlaceholder« = 1; - // $TEST$ error "A parameter or placeholder with name 'parameterAndPlaceholder' exists already." + # $TEST$ error "A parameter or placeholder with name 'parameterAndPlaceholder' exists already." val »parameterAndPlaceholder« = 1; - // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." val »placeholderAndResult« = 1; - // $TEST$ no error r"A result with name '\w*' exists already\." + # $TEST$ no error r"A result with name '\w*' exists already\." yield »duplicateResult« = 0; - // $TEST$ error "A result with name 'duplicateResult' exists already." + # $TEST$ error "A result with name 'duplicateResult' exists already." yield »duplicateResult« = 0; - // $TEST$ no error r"A result with name '\w*' exists already\." + # $TEST$ no error r"A result with name '\w*' exists already\." yield »uniqueResult« = 0; - // $TEST$ no error r"A result with name '\w*' exists already\." + # $TEST$ no error r"A result with name '\w*' exists already\." yield »parameterAndResult« = 0; //$TEST$ no error r"A result with name '\w*' exists already\." yield »placeholderAndResult« = 0; //$TEST$ no error r"A result with name '\w*' exists already\." yield »resultAndPlaceholder« = 0; - // $TEST$ no error "A parameter or placeholder with name '\w*' exists already\." + # $TEST$ no error "A parameter or placeholder with name '\w*' exists already\." val »resultAndPlaceholder« = 1; () { - // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." val »duplicatePlaceholder« = 1; - // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." val »parameterAndPlaceholder« = 1; - // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." val »placeholderAndResult« = 1; }; }; diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in callable type/main.sdstest b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in callable type/main.sdstest index 9320563e..2076ff96 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in callable type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in callable type/main.sdstest @@ -2,22 +2,22 @@ package tests.validation.names.duplicates.inCallableType segment s( f: ( - // $TEST$ no error r"A parameter with name '\w*' exists already\." + # $TEST$ no error r"A parameter with name '\w*' exists already\." »duplicateParameter«: Int, - // $TEST$ error "A parameter with name 'duplicateParameter' exists already." + # $TEST$ error "A parameter with name 'duplicateParameter' exists already." »duplicateParameter«: Int, - // $TEST$ no error r"A parameter with name '\w*' exists already\." + # $TEST$ no error r"A parameter with name '\w*' exists already\." »uniqueParameter«: Int, - // $TEST$ no error r"A parameter with name '\w*' exists already\." + # $TEST$ no error r"A parameter with name '\w*' exists already\." »parameterAndResult«: Int ) -> ( - // $TEST$ no error r"A result with name '\w*' exists already\." + # $TEST$ no error r"A result with name '\w*' exists already\." »duplicateResult«: Int, - // $TEST$ error "A result with name 'duplicateResult' exists already." + # $TEST$ error "A result with name 'duplicateResult' exists already." »duplicateResult«: Int, - // $TEST$ no error r"A result with name '\w*' exists already\." + # $TEST$ no error r"A result with name '\w*' exists already\." »uniqueResult«: Int, - // $TEST$ no error r"A result with name '\w*' exists already\." + # $TEST$ no error r"A result with name '\w*' exists already\." »parameterAndResult«: Int ) ) {} diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in class/main.sdstest b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in class/main.sdstest index 650707e0..5c05d96c 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in class/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in class/main.sdstest @@ -1,241 +1,241 @@ package tests.validation.names.duplicates.inClass class MyClass1< - // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »DuplicateTypeParameter«, - // $TEST$ error "A type parameter or parameter with name 'DuplicateTypeParameter' exists already." + # $TEST$ error "A type parameter or parameter with name 'DuplicateTypeParameter' exists already." »DuplicateTypeParameter«, - // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »UniqueTypeParameter«, - // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »TypeParameterAndParameter«, - // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »TypeParameterAndMember«, >( - // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »duplicateParameter«: Int, - // $TEST$ error "A type parameter or parameter with name 'duplicateParameter' exists already." + # $TEST$ error "A type parameter or parameter with name 'duplicateParameter' exists already." »duplicateParameter«: Int, - // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »uniqueParameter«: Int, - // $TEST$ error "A type parameter or parameter with name 'TypeParameterAndParameter' exists already." + # $TEST$ error "A type parameter or parameter with name 'TypeParameterAndParameter' exists already." »TypeParameterAndParameter«: Int, - // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »parameterAndMember«: Int, ) { - // $TEST$ no error r"An instance member with name '\w*' exists already\." + # $TEST$ no error r"An instance member with name '\w*' exists already\." attr »duplicateInstanceAttribute«: Int - // $TEST$ error "An instance member with name 'duplicateInstanceAttribute' exists already." + # $TEST$ error "An instance member with name 'duplicateInstanceAttribute' exists already." attr »duplicateInstanceAttribute«: Int - // $TEST$ no error r"An instance member with name '\w*' exists already\." + # $TEST$ no error r"An instance member with name '\w*' exists already\." attr »uniqueInstanceAttribute«: Int - // $TEST$ no error r"A static member with name '\w*' exists already\." + # $TEST$ no error r"A static member with name '\w*' exists already\." static attr »duplicateStaticAttribute«: Int - // $TEST$ error "A static member with name 'duplicateStaticAttribute' exists already." + # $TEST$ error "A static member with name 'duplicateStaticAttribute' exists already." static attr »duplicateStaticAttribute«: Int - // $TEST$ no error r"A static member with name '\w*' exists already\." + # $TEST$ no error r"A static member with name '\w*' exists already\." static attr »uniqueStaticAttribute«: Int - // $TEST$ no error r"A static member with name '\w*' exists already\." + # $TEST$ no error r"A static member with name '\w*' exists already\." class »DuplicateClass« - // $TEST$ error "A static member with name 'DuplicateClass' exists already." + # $TEST$ error "A static member with name 'DuplicateClass' exists already." class »DuplicateClass« - // $TEST$ no error r"A static member with name '\w*' exists already\." + # $TEST$ no error r"A static member with name '\w*' exists already\." class »UniqueClass« - // $TEST$ no error r"A static member with name '\w*' exists already\." + # $TEST$ no error r"A static member with name '\w*' exists already\." enum »DuplicateEnum« - // $TEST$ error "A static member with name 'DuplicateEnum' exists already." + # $TEST$ error "A static member with name 'DuplicateEnum' exists already." enum »DuplicateEnum« - // $TEST$ no error r"A static member with name '\w*' exists already\." + # $TEST$ no error r"A static member with name '\w*' exists already\." enum »UniqueEnum« - // $TEST$ no error r"An instance member with name '\w*' exists already\." + # $TEST$ no error r"An instance member with name '\w*' exists already\." fun »duplicateInstanceMethod«() - // $TEST$ error "An instance member with name 'duplicateInstanceMethod' exists already." + # $TEST$ error "An instance member with name 'duplicateInstanceMethod' exists already." fun »duplicateInstanceMethod«() - // $TEST$ no error r"An instance member with name '\w*' exists already\." + # $TEST$ no error r"An instance member with name '\w*' exists already\." fun »uniqueInstanceMethod«() - // $TEST$ no error r"A static member with name '\w*' exists already\." + # $TEST$ no error r"A static member with name '\w*' exists already\." static fun »duplicateStaticMethod«() - // $TEST$ error "A static member with name 'duplicateStaticMethod' exists already." + # $TEST$ error "A static member with name 'duplicateStaticMethod' exists already." static fun »duplicateStaticMethod«() - // $TEST$ no error r"A static member with name '\w*' exists already\." + # $TEST$ no error r"A static member with name '\w*' exists already\." static fun »uniqueStaticMethod«() - // $TEST$ no error r"An instance member with name '\w*' exists already\." + # $TEST$ no error r"An instance member with name '\w*' exists already\." attr »duplicateInstanceMember«: Int - // $TEST$ error "An instance member with name 'duplicateInstanceMember' exists already." + # $TEST$ error "An instance member with name 'duplicateInstanceMember' exists already." fun »duplicateInstanceMember«() - // $TEST$ no error r"A static member with name '\w*' exists already\." + # $TEST$ no error r"A static member with name '\w*' exists already\." static attr »duplicateStaticMember«: Int - // $TEST$ error "A static member with name 'duplicateStaticMember' exists already." + # $TEST$ error "A static member with name 'duplicateStaticMember' exists already." class »duplicateStaticMember« - // $TEST$ error "A static member with name 'duplicateStaticMember' exists already." + # $TEST$ error "A static member with name 'duplicateStaticMember' exists already." enum »duplicateStaticMember« - // $TEST$ error "A static member with name 'duplicateStaticMember' exists already." + # $TEST$ error "A static member with name 'duplicateStaticMember' exists already." static fun »duplicateStaticMember«() } class MyClass2< - // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »TypeParameterAndMember«, > { - // $TEST$ no error r"A.*member with name '\w*' exists already\." + # $TEST$ no error r"A.*member with name '\w*' exists already\." attr »TypeParameterAndMember«: Int - // $TEST$ no error r"A.*member with name '\w*' exists already\." + # $TEST$ no error r"A.*member with name '\w*' exists already\." attr »instanceAndStaticMember«: Int - // $TEST$ no error "r"A.*member with name '\w*' exists already\." + # $TEST$ no error "r"A.*member with name '\w*' exists already\." static attr »instanceAndStaticMember«: Int - // $TEST$ no error "r"A.*member with name '\w*' exists already\." + # $TEST$ no error "r"A.*member with name '\w*' exists already\." static attr »staticAndInstanceMember«: Int - // $TEST$ no error r"A.*member with name '\w*' exists already\." + # $TEST$ no error r"A.*member with name '\w*' exists already\." attr »staticAndInstanceMember«: Int } class MyClass3< - // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »TypeParameterAndMember«, > { - // $TEST$ no error r"A.*member with name '\w*' exists already\." + # $TEST$ no error r"A.*member with name '\w*' exists already\." static attr »TypeParameterAndMember«: Int - // $TEST$ no error r"A.*member with name '\w*' exists already\." + # $TEST$ no error r"A.*member with name '\w*' exists already\." attr »instanceAndStaticMember«: Int - // $TEST$ no error "r"A.*member with name '\w*' exists already\." + # $TEST$ no error "r"A.*member with name '\w*' exists already\." class »instanceAndStaticMember« - // $TEST$ no error "r"A.*member with name '\w*' exists already\." + # $TEST$ no error "r"A.*member with name '\w*' exists already\." class »staticAndInstanceMember« - // $TEST$ no error r"A.*member with name '\w*' exists already\." + # $TEST$ no error r"A.*member with name '\w*' exists already\." attr »staticAndInstanceMember«: Int } class MyClass4< - // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »TypeParameterAndMember«, > { - // $TEST$ no error r"A.*member with name '\w*' exists already\." + # $TEST$ no error r"A.*member with name '\w*' exists already\." class »TypeParameterAndMember« - // $TEST$ no error r"A.*member with name '\w*' exists already\." + # $TEST$ no error r"A.*member with name '\w*' exists already\." attr »instanceAndStaticMember«: Int - // $TEST$ no error "r"A.*member with name '\w*' exists already\." + # $TEST$ no error "r"A.*member with name '\w*' exists already\." enum »instanceAndStaticMember« - // $TEST$ no error "r"A.*member with name '\w*' exists already\." + # $TEST$ no error "r"A.*member with name '\w*' exists already\." enum »staticAndInstanceMember« - // $TEST$ no error r"A.*member with name '\w*' exists already\." + # $TEST$ no error r"A.*member with name '\w*' exists already\." attr »staticAndInstanceMember«: Int } class MyClass5< - // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »TypeParameterAndMember«, > { - // $TEST$ no error r"A.*member with name '\w*' exists already\." + # $TEST$ no error r"A.*member with name '\w*' exists already\." enum »TypeParameterAndMember« - // $TEST$ no error r"A.*member with name '\w*' exists already\." + # $TEST$ no error r"A.*member with name '\w*' exists already\." attr »instanceAndStaticMember«: Int - // $TEST$ no error "r"A.*member with name '\w*' exists already\." + # $TEST$ no error "r"A.*member with name '\w*' exists already\." static fun »instanceAndStaticMember«() - // $TEST$ no error "r"A.*member with name '\w*' exists already\." + # $TEST$ no error "r"A.*member with name '\w*' exists already\." static fun »staticAndInstanceMember«() - // $TEST$ no error r"A.*member with name '\w*' exists already\." + # $TEST$ no error r"A.*member with name '\w*' exists already\." attr »staticAndInstanceMember«: Int } class MyClass6< - // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »TypeParameterAndMember«, > { - // $TEST$ no error r"A.*member with name '\w*' exists already\." + # $TEST$ no error r"A.*member with name '\w*' exists already\." fun »TypeParameterAndMember«() - // $TEST$ no error r"A.*member with name '\w*' exists already\." + # $TEST$ no error r"A.*member with name '\w*' exists already\." fun »instanceAndStaticMember«() - // $TEST$ no error "r"A.*member with name '\w*' exists already\." + # $TEST$ no error "r"A.*member with name '\w*' exists already\." static attr »instanceAndStaticMember«: Int - // $TEST$ no error "r"A.*member with name '\w*' exists already\." + # $TEST$ no error "r"A.*member with name '\w*' exists already\." static attr »staticAndInstanceMember«: Int - // $TEST$ no error r"A.*member with name '\w*' exists already\." + # $TEST$ no error r"A.*member with name '\w*' exists already\." fun »staticAndInstanceMember«() } class MyClass7< - // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »TypeParameterAndMember«, > { - // $TEST$ no error r"A.*member with name '\w*' exists already\." + # $TEST$ no error r"A.*member with name '\w*' exists already\." fun »TypeParameterAndMember«() - // $TEST$ no error r"A.*member with name '\w*' exists already\." + # $TEST$ no error r"A.*member with name '\w*' exists already\." fun »instanceAndStaticMember«() - // $TEST$ no error "r"A.*member with name '\w*' exists already\." + # $TEST$ no error "r"A.*member with name '\w*' exists already\." class »instanceAndStaticMember« - // $TEST$ no error "r"A.*member with name '\w*' exists already\." + # $TEST$ no error "r"A.*member with name '\w*' exists already\." class »staticAndInstanceMember« - // $TEST$ no error r"A.*member with name '\w*' exists already\." + # $TEST$ no error r"A.*member with name '\w*' exists already\." fun »staticAndInstanceMember«() } class MyClass8( - // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »parameterAndMember«: Int, ) { - // $TEST$ no error r"A.*member with name '\w*' exists already\." + # $TEST$ no error r"A.*member with name '\w*' exists already\." attr »parameterAndMember«: Int - // $TEST$ no error r"A.*member with name '\w*' exists already\." + # $TEST$ no error r"A.*member with name '\w*' exists already\." fun »instanceAndStaticMember«() - // $TEST$ no error "r"A.*member with name '\w*' exists already\." + # $TEST$ no error "r"A.*member with name '\w*' exists already\." enum »instanceAndStaticMember« - // $TEST$ no error "r"A.*member with name '\w*' exists already\." + # $TEST$ no error "r"A.*member with name '\w*' exists already\." enum »staticAndInstanceMember« - // $TEST$ no error r"A.*member with name '\w*' exists already\." + # $TEST$ no error r"A.*member with name '\w*' exists already\." fun »staticAndInstanceMember«() } class MyClass9( - // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »parameterAndMember«: Int, ) { - // $TEST$ no error r"A.*member with name '\w*' exists already\." + # $TEST$ no error r"A.*member with name '\w*' exists already\." class »parameterAndMember« - // $TEST$ no error r"A.*member with name '\w*' exists already\." + # $TEST$ no error r"A.*member with name '\w*' exists already\." fun »instanceAndStaticMember«() - // $TEST$ no error "r"A.*member with name '\w*' exists already\." + # $TEST$ no error "r"A.*member with name '\w*' exists already\." static fun »instanceAndStaticMember«() - // $TEST$ no error "r"A.*member with name '\w*' exists already\." + # $TEST$ no error "r"A.*member with name '\w*' exists already\." static fun »staticAndInstanceMember«() - // $TEST$ no error r"A.*member with name '\w*' exists already\." + # $TEST$ no error r"A.*member with name '\w*' exists already\." fun »staticAndInstanceMember«() } class MyClass10( - // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »parameterAndMember«: Int, ) { - // $TEST$ no error r"A.*member with name '\w*' exists already\." + # $TEST$ no error r"A.*member with name '\w*' exists already\." enum »parameterAndMember« } class MyClass11( - // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »parameterAndMember«: Int, ) { - // $TEST$ no error r"A.*member with name '\w*' exists already\." + # $TEST$ no error r"A.*member with name '\w*' exists already\." fun »parameterAndMember«() } diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in enum variant/main.sdstest b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in enum variant/main.sdstest index e9f30a7c..3149a17a 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in enum variant/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in enum variant/main.sdstest @@ -2,11 +2,11 @@ package tests.validation.names.duplicates.inEnumVariant enum MyEnum { MyEnumVariant( - // $TEST$ no error r"A parameter with name '\w*' exists already\." + # $TEST$ no error r"A parameter with name '\w*' exists already\." »duplicateParameter«: Int, - // $TEST$ error "A parameter with name 'duplicateParameter' exists already." + # $TEST$ error "A parameter with name 'duplicateParameter' exists already." »duplicateParameter«: Int, - // $TEST$ no error r"A parameter with name '\w*' exists already\." + # $TEST$ no error r"A parameter with name '\w*' exists already\." »uniqueParameter«: Int, ) } diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in enum/main.sdstest b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in enum/main.sdstest index 08903cba..d868bab6 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in enum/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in enum/main.sdstest @@ -1,10 +1,10 @@ package tests.validation.names.duplicates.inEnum enum MyEnum { - // $TEST$ no error r"A variant with name '\w*' exists already\." + # $TEST$ no error r"A variant with name '\w*' exists already\." »MyVariant1« - // $TEST$ error "A variant with name 'MyVariant1' exists already." + # $TEST$ error "A variant with name 'MyVariant1' exists already." »MyVariant1« - // $TEST$ no error r"A variant with name '\w*' exists already\." + # $TEST$ no error r"A variant with name '\w*' exists already\." »MyVariant2« } diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in expression lambda/main.sdstest b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in expression lambda/main.sdstest index 71f4bb00..88a373fd 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in expression lambda/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in expression lambda/main.sdstest @@ -2,11 +2,11 @@ package tests.validation.names.duplicates.inExpressionLambda pipeline p { ( - // $TEST$ no error r"A parameter with name '\w*' exists already\." + # $TEST$ no error r"A parameter with name '\w*' exists already\." »duplicateParameter«, - // $TEST$ error "A parameter with name 'duplicateParameter' exists already." + # $TEST$ error "A parameter with name 'duplicateParameter' exists already." »duplicateParameter«, - // $TEST$ no error r"A parameter with name '\w*' exists already\." + # $TEST$ no error r"A parameter with name '\w*' exists already\." »uniqueParameter«, ) -> 1; } diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in function/main.sdstest b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in function/main.sdstest index 802d3412..6f75534b 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in function/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in function/main.sdstest @@ -1,36 +1,36 @@ package tests.validation.names.duplicates.inFunction fun myFunction< - // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »DuplicateTypeParameter«, - // $TEST$ error "A type parameter or parameter with name 'DuplicateTypeParameter' exists already." + # $TEST$ error "A type parameter or parameter with name 'DuplicateTypeParameter' exists already." »DuplicateTypeParameter«, - // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »UniqueTypeParameter«, - // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »TypeParameterAndParameter«, - // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »TypeParameterAndResult«, >( - // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »duplicateParameter«: Int, - // $TEST$ error "A type parameter or parameter with name 'duplicateParameter' exists already." + # $TEST$ error "A type parameter or parameter with name 'duplicateParameter' exists already." »duplicateParameter«: Int, - // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »uniqueParameter«: Int, - // $TEST$ error "A type parameter or parameter with name 'TypeParameterAndParameter' exists already." + # $TEST$ error "A type parameter or parameter with name 'TypeParameterAndParameter' exists already." »TypeParameterAndParameter«: Int, - // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »parameterAndResult«: Int, ) -> ( - // $TEST$ no error r"A result with name '\w*' exists already\." + # $TEST$ no error r"A result with name '\w*' exists already\." »duplicateResult« : Int, - // $TEST$ error "A result with name 'duplicateResult' exists already." + # $TEST$ error "A result with name 'duplicateResult' exists already." »duplicateResult« : Int, - // $TEST$ no error r"A result with name '\w*' exists already\." + # $TEST$ no error r"A result with name '\w*' exists already\." »uniqueResult« : Int, - // $TEST$ no error r"A result with name '\w*' exists already\." + # $TEST$ no error r"A result with name '\w*' exists already\." »parameterAndResult« : Int, - // $TEST$ no error r"A result with name '\w*' exists already\." + # $TEST$ no error r"A result with name '\w*' exists already\." »TypeParameterAndResult« : Int, ) diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in pipeline file/main.sdspipe b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in pipeline file/main.sdspipe index 92c59bf4..c0c48adc 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in pipeline file/main.sdspipe +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in pipeline file/main.sdspipe @@ -1,85 +1,85 @@ package tests.validation.names.inPipelineFile -// $TEST$ no error r"A declaration with name '\w*' was imported already\." +# $TEST$ no error r"A declaration with name '\w*' was imported already\." from tests.validation.names.inPipelineFile.other import »UniqueImport« -// $TEST$ no error r"A declaration with name '\w*' was imported already\." +# $TEST$ no error r"A declaration with name '\w*' was imported already\." from tests.validation.names.inPipelineFile.other import »DuplicateImport« -// $TEST$ error "A declaration with name 'DuplicateImport' was imported already." +# $TEST$ error "A declaration with name 'DuplicateImport' was imported already." from tests.validation.names.inPipelineFile.other import »DuplicateImport« -// $TEST$ no error r"A declaration with name '\w*' was imported already\." -// $TEST$ error "A declaration with name 'DuplicateAliasedImport' was imported already." +# $TEST$ no error r"A declaration with name '\w*' was imported already\." +# $TEST$ error "A declaration with name 'DuplicateAliasedImport' was imported already." from tests.validation.names.inPipelineFile.other import »DuplicateAliasedImport«, DuplicateImport as »DuplicateAliasedImport« -// $TEST$ no error r"A declaration with name '\w*' was imported already\." +# $TEST$ no error r"A declaration with name '\w*' was imported already\." from tests.validation.names.inPipelineFile.other import »Unresolved« -// $TEST$ no error r"A declaration with name '\w*' was imported already\." +# $TEST$ no error r"A declaration with name '\w*' was imported already\." from tests.validation.names.inPipelineFile.other import »Unresolved« -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." annotation »UniqueAnnotation« -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." annotation »DuplicateAnnotation« -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." annotation »DuplicateAnnotation« -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." class »UniqueClass« -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." class »DuplicateClass« -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." class »DuplicateClass« -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." enum »UniqueEnum« -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." enum »DuplicateEnum« -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." enum »DuplicateEnum« -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." fun »uniqueFunction«() -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." fun »duplicateFunction«() -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." fun »duplicateFunction«() -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." schema »UniqueSchema« {} -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." schema »DuplicateSchema« {} -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." schema »DuplicateSchema« {} -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." pipeline »uniquePipeline« {} -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." pipeline »duplicatePipeline« {} -// $TEST$ error "A declaration with name 'duplicatePipeline' exists already in this file." +# $TEST$ error "A declaration with name 'duplicatePipeline' exists already in this file." pipeline »duplicatePipeline« {} -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." segment »uniqueSegment«() {} -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." segment »duplicateSegment«() {} -// $TEST$ error "A declaration with name 'duplicateSegment' exists already in this file." +# $TEST$ error "A declaration with name 'duplicateSegment' exists already in this file." segment »duplicateSegment«() {} -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." annotation »DuplicateDeclaration« -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." class »DuplicateDeclaration« -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." enum »DuplicateDeclaration« -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." fun »DuplicateDeclaration«() -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." schema »DuplicateDeclaration« {} -// $TEST$ error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ error r"A declaration with name '\w*' exists already in this file\." pipeline »DuplicateDeclaration« {} -// $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." +# $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." segment »DuplicateDeclaration«() {} diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in pipeline/main.sdstest b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in pipeline/main.sdstest index f53765c2..577f8d9c 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in pipeline/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in pipeline/main.sdstest @@ -1,10 +1,10 @@ package tests.validation.names.duplicates.inPipeline pipeline p { - // $TEST$ no error r"A placeholder with name '\w*' exists already\." + # $TEST$ no error r"A placeholder with name '\w*' exists already\." val »duplicatePlaceholder« = 1; - // $TEST$ error "A placeholder with name 'duplicatePlaceholder' exists already." + # $TEST$ error "A placeholder with name 'duplicatePlaceholder' exists already." val »duplicatePlaceholder« = 1; - // $TEST$ no error r"A placeholder with name '\w*' exists already\." + # $TEST$ no error r"A placeholder with name '\w*' exists already\." val »uniquePlaceholder« = 1; } diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in schema/main.sdstest b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in schema/main.sdstest index 735d2be7..eab9185b 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in schema/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in schema/main.sdstest @@ -1,10 +1,10 @@ package tests.validation.names.duplicates.inSchema schema S { - // $TEST$ no error r"A column with name '\w*' exists already\." + # $TEST$ no error r"A column with name '\w*' exists already\." »"duplicateColumn"«: Int, - // $TEST$ error "A column with name 'duplicateColumn' exists already." + # $TEST$ error "A column with name 'duplicateColumn' exists already." »"duplicateColumn"«: Int, - // $TEST$ no error r"A column with name '\w*' exists already\." + # $TEST$ no error r"A column with name '\w*' exists already\." »"uniqueColumn"«: Int, } diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in segment/main.sdstest b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in segment/main.sdstest index a46b224c..e8e2c548 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in segment/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in segment/main.sdstest @@ -1,45 +1,45 @@ package tests.validation.names.duplicates.inSegment segment mySegment( - // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." »duplicateParameter«: Int, - // $TEST$ error "A parameter or placeholder with name 'duplicateParameter' exists already." + # $TEST$ error "A parameter or placeholder with name 'duplicateParameter' exists already." »duplicateParameter«: Int, - // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." »uniqueParameter«: Int, - // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." »parameterAndPlaceholder«: Int, - // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." »parameterAndResult«: Int, ) -> ( - // $TEST$ no error r"A result with name '\w*' exists already\." + # $TEST$ no error r"A result with name '\w*' exists already\." »duplicateResult« : Int, - // $TEST$ error "A result with name 'duplicateResult' exists already." + # $TEST$ error "A result with name 'duplicateResult' exists already." »duplicateResult« : Int, - // $TEST$ no error r"A result with name '\w*' exists already\." + # $TEST$ no error r"A result with name '\w*' exists already\." »uniqueResult« : Int, - // $TEST$ no error r"A result with name '\w*' exists already\." + # $TEST$ no error r"A result with name '\w*' exists already\." »parameterAndResult« : Int, - // $TEST$ no error r"A result with name '\w*' exists already\." + # $TEST$ no error r"A result with name '\w*' exists already\." »placeholderAndResult« : Int, ) { - // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." val »duplicatePlaceholder« = 1; - // $TEST$ error "A parameter or placeholder with name 'duplicatePlaceholder' exists already." + # $TEST$ error "A parameter or placeholder with name 'duplicatePlaceholder' exists already." val »duplicatePlaceholder« = 1; - // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." val »uniquePlaceholder« = 1; - // $TEST$ error "A parameter or placeholder with name 'parameterAndPlaceholder' exists already." + # $TEST$ error "A parameter or placeholder with name 'parameterAndPlaceholder' exists already." val »parameterAndPlaceholder« = 1; - // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." val »placeholderAndResult« = 1; () { - // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." val »duplicatePlaceholder« = 1; - // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." val »parameterAndPlaceholder« = 1; - // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." val »placeholderAndResult« = 1; }; } diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in stub file/main.sdsstub b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in stub file/main.sdsstub index 867baa1f..e9a7c6ad 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in stub file/main.sdsstub +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in stub file/main.sdsstub @@ -1,85 +1,85 @@ package tests.validation.names.inStubFile -// $TEST$ no error r"A declaration with name '\w*' was imported already\." +# $TEST$ no error r"A declaration with name '\w*' was imported already\." from tests.validation.names.inStubFile.other import »UniqueImport« -// $TEST$ no error r"A declaration with name '\w*' was imported already\." +# $TEST$ no error r"A declaration with name '\w*' was imported already\." from tests.validation.names.inStubFile.other import »DuplicateImport« -// $TEST$ error "A declaration with name 'DuplicateImport' was imported already." +# $TEST$ error "A declaration with name 'DuplicateImport' was imported already." from tests.validation.names.inStubFile.other import »DuplicateImport« -// $TEST$ no error r"A declaration with name '\w*' was imported already\." -// $TEST$ error "A declaration with name 'DuplicateAliasedImport' was imported already." +# $TEST$ no error r"A declaration with name '\w*' was imported already\." +# $TEST$ error "A declaration with name 'DuplicateAliasedImport' was imported already." from tests.validation.names.inStubFile.other import »DuplicateAliasedImport«, DuplicateImport as »DuplicateAliasedImport« -// $TEST$ no error r"A declaration with name '\w*' was imported already\." +# $TEST$ no error r"A declaration with name '\w*' was imported already\." from tests.validation.names.inStubFile.other import »Unresolved« -// $TEST$ no error r"A declaration with name '\w*' was imported already\." +# $TEST$ no error r"A declaration with name '\w*' was imported already\." from tests.validation.names.inStubFile.other import »Unresolved« -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." pipeline »uniqueTest« {} -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." pipeline »duplicateTest« {} -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." pipeline »duplicateTest« {} -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." segment »uniqueSegment«() {} -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." segment »duplicateSegment«() {} -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." segment »duplicateSegment«() {} -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." annotation »UniqueAnnotation« -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." annotation »DuplicateAnnotation« -// $TEST$ error "A declaration with name 'DuplicateAnnotation' exists already in this file." +# $TEST$ error "A declaration with name 'DuplicateAnnotation' exists already in this file." annotation »DuplicateAnnotation« -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." class »UniqueClass« -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." class »DuplicateClass« -// $TEST$ error "A declaration with name 'DuplicateClass' exists already in this file." +# $TEST$ error "A declaration with name 'DuplicateClass' exists already in this file." class »DuplicateClass« -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." enum »UniqueEnum« -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." enum »DuplicateEnum« -// $TEST$ error "A declaration with name 'DuplicateEnum' exists already in this file." +# $TEST$ error "A declaration with name 'DuplicateEnum' exists already in this file." enum »DuplicateEnum« -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." fun »uniqueFunction«() -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." fun »duplicateFunction«() -// $TEST$ error "A declaration with name 'duplicateFunction' exists already in this file." +# $TEST$ error "A declaration with name 'duplicateFunction' exists already in this file." fun »duplicateFunction«() -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." schema »UniqueSchema« {} -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." schema »DuplicateSchema« {} -// $TEST$ error "A declaration with name 'DuplicateSchema' exists already in this file." +# $TEST$ error "A declaration with name 'DuplicateSchema' exists already in this file." schema »DuplicateSchema« {} -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." pipeline »DuplicateDeclaration« {} -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." segment »DuplicateDeclaration«() {} -// $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." +# $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." annotation »DuplicateDeclaration« -// $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." +# $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." class »DuplicateDeclaration« -// $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." +# $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." enum »DuplicateDeclaration« -// $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." +# $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." fun »DuplicateDeclaration«() -// $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." +# $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." schema »DuplicateDeclaration« {} diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in test file/main.sdstest b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in test file/main.sdstest index acd73161..b6641e25 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in test file/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in test file/main.sdstest @@ -1,84 +1,84 @@ package tests.validation.names.inTestFile -// $TEST$ no error r"A declaration with name '\w*' was imported already\." +# $TEST$ no error r"A declaration with name '\w*' was imported already\." from tests.validation.names.inTestFile.other import »UniqueImport« -// $TEST$ no error r"A declaration with name '\w*' was imported already\." +# $TEST$ no error r"A declaration with name '\w*' was imported already\." from tests.validation.names.inTestFile.other import »DuplicateImport« -// $TEST$ error "A declaration with name 'DuplicateImport' was imported already." +# $TEST$ error "A declaration with name 'DuplicateImport' was imported already." from tests.validation.names.inTestFile.other import »DuplicateImport« -// $TEST$ no error r"A declaration with name '\w*' was imported already\." -// $TEST$ error "A declaration with name 'DuplicateAliasedImport' was imported already." +# $TEST$ no error r"A declaration with name '\w*' was imported already\." +# $TEST$ error "A declaration with name 'DuplicateAliasedImport' was imported already." from tests.validation.names.inTestFile.other import »DuplicateAliasedImport«, DuplicateImport as »DuplicateAliasedImport« -// $TEST$ no error r"A declaration with name '\w*' was imported already\." +# $TEST$ no error r"A declaration with name '\w*' was imported already\." from tests.validation.names.inTestFile.other import »Unresolved« -// $TEST$ no error r"A declaration with name '\w*' was imported already\." +# $TEST$ no error r"A declaration with name '\w*' was imported already\." from tests.validation.names.inTestFile.other import »Unresolved« -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." annotation »UniqueAnnotation« -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." annotation »DuplicateAnnotation« -// $TEST$ error "A declaration with name 'DuplicateAnnotation' exists already in this file." +# $TEST$ error "A declaration with name 'DuplicateAnnotation' exists already in this file." annotation »DuplicateAnnotation« -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." class »UniqueClass« -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." class »DuplicateClass« -// $TEST$ error "A declaration with name 'DuplicateClass' exists already in this file." +# $TEST$ error "A declaration with name 'DuplicateClass' exists already in this file." class »DuplicateClass« -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." enum »UniqueEnum« -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." enum »DuplicateEnum« -// $TEST$ error "A declaration with name 'DuplicateEnum' exists already in this file." +# $TEST$ error "A declaration with name 'DuplicateEnum' exists already in this file." enum »DuplicateEnum« -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." fun »uniqueFunction«() -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." fun »duplicateFunction«() -// $TEST$ error "A declaration with name 'duplicateFunction' exists already in this file." +# $TEST$ error "A declaration with name 'duplicateFunction' exists already in this file." fun »duplicateFunction«() -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." pipeline »uniquePipeline« {} -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." pipeline »duplicatePipeline« {} -// $TEST$ error "A declaration with name 'duplicatePipeline' exists already in this file." +# $TEST$ error "A declaration with name 'duplicatePipeline' exists already in this file." pipeline »duplicatePipeline« {} -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." schema »UniqueSchema« {} -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." schema »DuplicateSchema« {} -// $TEST$ error "A declaration with name 'DuplicateSchema' exists already in this file." +# $TEST$ error "A declaration with name 'DuplicateSchema' exists already in this file." schema »DuplicateSchema« {} -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." segment »uniqueSegment«() {} -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." segment »duplicateSegment«() {} -// $TEST$ error "A declaration with name 'duplicateSegment' exists already in this file." +# $TEST$ error "A declaration with name 'duplicateSegment' exists already in this file." segment »duplicateSegment«() {} -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." annotation »DuplicateDeclaration« -// $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." +# $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." class »DuplicateDeclaration« -// $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." +# $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." enum »DuplicateDeclaration« -// $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." +# $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." fun »DuplicateDeclaration«() -// $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." +# $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." pipeline »DuplicateDeclaration« {} -// $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." +# $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." segment »DuplicateDeclaration«() {} -// $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." +# $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." schema »DuplicateDeclaration« {} diff --git a/packages/ttsl-lang/tests/resources/validation/other/argument lists/duplicate parameter/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/argument lists/duplicate parameter/main.sdstest index 244b3d03..34610ab4 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/argument lists/duplicate parameter/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/argument lists/duplicate parameter/main.sdstest @@ -17,21 +17,21 @@ pipeline myPipeline {} @MyAnnotation( - // $TEST$ no error "The parameter 'a' is already set." + # $TEST$ no error "The parameter 'a' is already set." »1«, - // $TEST$ error "The parameter 'a' is already set." + # $TEST$ error "The parameter 'a' is already set." »a = 1« ) @MyAnnotation( - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »b = 1«, - // $TEST$ error "The parameter 'b' is already set." + # $TEST$ error "The parameter 'b' is already set." »b = 1« ) @MyAnnotation( - // $TEST$ no error "The parameter 'a' is already set." + # $TEST$ no error "The parameter 'a' is already set." »a = 1«, - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »b = 1« ) segment test( @@ -45,101 +45,101 @@ segment test( val myAnnotationAlias = MyAnnotation; MyAnnotation( - // $TEST$ no error "The parameter 'a' is already set." + # $TEST$ no error "The parameter 'a' is already set." »1«, - // $TEST$ no error "The parameter 'a' is already set." + # $TEST$ no error "The parameter 'a' is already set." »a = 1« ); myAnnotationAlias( - // $TEST$ no error "The parameter 'b' is already set." + # $TEST$ no error "The parameter 'b' is already set." »b = 1«, - // $TEST$ no error "The parameter 'b' is already set." + # $TEST$ no error "The parameter 'b' is already set." »b = 1« ); MyAnnotation( - // $TEST$ no error "The parameter 'a' is already set." + # $TEST$ no error "The parameter 'a' is already set." »a = 1«, - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »b = 1« ); MyClass( - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »1«, - // $TEST$ error "The parameter 'a' is already set." + # $TEST$ error "The parameter 'a' is already set." »a = 1« ); MyClass( - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »b = 1«, - // $TEST$ error "The parameter 'b' is already set." + # $TEST$ error "The parameter 'b' is already set." »b = 1« ); MyClass( - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »a = 1«, - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »b = 1« ); MyEnum.MyEnumVariant( - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »1«, - // $TEST$ error "The parameter 'a' is already set." + # $TEST$ error "The parameter 'a' is already set." »a = 1« ); MyEnum.MyEnumVariant( - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »b = 1«, - // $TEST$ error "The parameter 'b' is already set." + # $TEST$ error "The parameter 'b' is already set." »b = 1« ); MyEnum.MyEnumVariant( - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »a = 1«, - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »b = 1« ); myFunction( - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »1«, - // $TEST$ error "The parameter 'a' is already set." + # $TEST$ error "The parameter 'a' is already set." »a = 1« ); myFunction( - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »b = 1«, - // $TEST$ error "The parameter 'b' is already set." + # $TEST$ error "The parameter 'b' is already set." »b = 1« ); myFunction( - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »a = 1«, - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »b = 1« ); myCallableType( - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »1«, - // $TEST$ error "The parameter 'a' is already set." + # $TEST$ error "The parameter 'a' is already set." »a = 1« ); myCallableType( - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »b = 1«, - // $TEST$ error "The parameter 'b' is already set." + # $TEST$ error "The parameter 'b' is already set." »b = 1« ); myCallableType( - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »a = 1«, - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »b = 1« ); @@ -147,21 +147,21 @@ segment test( val myBlockLambda = (a, b) {}; ((a, b) {})( - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »1«, - // $TEST$ error "The parameter 'a' is already set." + # $TEST$ error "The parameter 'a' is already set." »a = 1« ); myBlockLambda( - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »b = 1«, - // $TEST$ error "The parameter 'b' is already set." + # $TEST$ error "The parameter 'b' is already set." »b = 1« ); ((a, b) {})( - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »a = 1«, - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »b = 1« ); @@ -169,47 +169,47 @@ segment test( val myExpressionLambda = (a, b) -> 1; ((a, b) -> 1)( - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »1«, - // $TEST$ error "The parameter 'a' is already set." + # $TEST$ error "The parameter 'a' is already set." »a = 1« ); myExpressionLambda( - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »b = 1«, - // $TEST$ error "The parameter 'b' is already set." + # $TEST$ error "The parameter 'b' is already set." »b = 1« ); ((a, b) -> 1)( - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »a = 1«, - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »b = 1« ); myPipeline( - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »1«, - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »1« ); myPipeline( - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »a = 1«, - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »a = 1« ); unresolved( - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »1«, - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »1« ); unresolved( - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »a = 1«, - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »a = 1« ); } diff --git a/packages/ttsl-lang/tests/resources/validation/other/argument lists/missing required parameter/dont show this error if the argument list is missing altogether.sdstest b/packages/ttsl-lang/tests/resources/validation/other/argument lists/missing required parameter/dont show this error if the argument list is missing altogether.sdstest index 46a3935a..9f6741d3 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/argument lists/missing required parameter/dont show this error if the argument list is missing altogether.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/argument lists/missing required parameter/dont show this error if the argument list is missing altogether.sdstest @@ -1,6 +1,6 @@ package tests.validation.other.argumentLists.missingRequiredParameter -// $TEST$ no error r"The parameters? .* must be set here\." +# $TEST$ no error r"The parameters? .* must be set here\." @MyAnnotation segment mySegment3( diff --git a/packages/ttsl-lang/tests/resources/validation/other/argument lists/missing required parameter/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/argument lists/missing required parameter/main.sdstest index 167d6fea..bbc6105f 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/argument lists/missing required parameter/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/argument lists/missing required parameter/main.sdstest @@ -16,19 +16,19 @@ segment mySegment1(a: Int, b: Int, c: Int = 0) {} pipeline myPipeline {} -// $TEST$ error "The parameters 'a', 'b' must be set here." +# $TEST$ error "The parameters 'a', 'b' must be set here." @MyAnnotation»()« -// $TEST$ error "The parameter 'b' must be set here." +# $TEST$ error "The parameter 'b' must be set here." @MyAnnotation»(1)« -// $TEST$ no error r"The parameters? .* must be set here\." +# $TEST$ no error r"The parameters? .* must be set here\." @MyAnnotation»(1, 2)« -// $TEST$ no error r"The parameters? .* must be set here\." +# $TEST$ no error r"The parameters? .* must be set here\." @MyAnnotation»(1, 2, 3)« -// $TEST$ no error r"The parameters? .* must be set here\." +# $TEST$ no error r"The parameters? .* must be set here\." @MyAnnotation»(1, 2, 3, 4)« -// $TEST$ error "The parameter 'b' must be set here." +# $TEST$ error "The parameter 'b' must be set here." @MyAnnotation»(1, c = 2)« -// $TEST$ no error r"The parameters? .* must be set here\." +# $TEST$ no error r"The parameters? .* must be set here\." @MyAnnotation»(b = 1, a = 2)« segment mySegment2( myCallableType: (a: Int, b: Int, c: Int = 0) -> () @@ -40,136 +40,136 @@ segment mySegment2( * We can never call an annotation directly and should avoid showing additional errors. */ - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." MyAnnotation»()«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." MyAnnotation»(1)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." MyAnnotation»(1, 2)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." MyAnnotation»(1, 2, 3)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." MyAnnotation»(1, 2, 3, 4)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." MyAnnotation»(1, c = 2)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." MyAnnotation»(b = 1, a = 2)«; - // $TEST$ error "The parameters 'a', 'b' must be set here." + # $TEST$ error "The parameters 'a', 'b' must be set here." MyClass»()«; - // $TEST$ error "The parameter 'b' must be set here." + # $TEST$ error "The parameter 'b' must be set here." MyClass»(1)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." MyClass»(1, 2)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." MyClass»(1, 2, 3)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." MyClass»(1, 2, 3, 4)«; - // $TEST$ error "The parameter 'b' must be set here." + # $TEST$ error "The parameter 'b' must be set here." MyClass»(1, c = 2)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." MyClass»(b = 1, a = 2)«; - // $TEST$ error "The parameters 'a', 'b' must be set here." + # $TEST$ error "The parameters 'a', 'b' must be set here." MyEnum.MyEnumVariant»()«; - // $TEST$ error "The parameter 'b' must be set here." + # $TEST$ error "The parameter 'b' must be set here." MyEnum.MyEnumVariant»(1)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." MyEnum.MyEnumVariant»(1, 2)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." MyEnum.MyEnumVariant»(1, 2, 3)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." MyEnum.MyEnumVariant»(1, 2, 3, 4)«; - // $TEST$ error "The parameter 'b' must be set here." + # $TEST$ error "The parameter 'b' must be set here." MyEnum.MyEnumVariant»(1, c = 2)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." MyEnum.MyEnumVariant»(b = 1, a = 2)«; - // $TEST$ error "The parameters 'a', 'b' must be set here." + # $TEST$ error "The parameters 'a', 'b' must be set here." myFunction»()«; - // $TEST$ error "The parameter 'b' must be set here." + # $TEST$ error "The parameter 'b' must be set here." myFunction»(1)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." myFunction»(1, 2)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." myFunction»(1, 2, 3)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." myFunction»(1, 2, 3, 4)«; - // $TEST$ error "The parameter 'b' must be set here." + # $TEST$ error "The parameter 'b' must be set here." myFunction»(1, c = 2)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." myFunction»(b = 1, a = 2)«; - // $TEST$ error "The parameters 'a', 'b' must be set here." + # $TEST$ error "The parameters 'a', 'b' must be set here." mySegment1»()«; - // $TEST$ error "The parameter 'b' must be set here." + # $TEST$ error "The parameter 'b' must be set here." mySegment1»(1)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." mySegment1»(1, 2)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." mySegment1»(1, 2, 3)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." mySegment1»(1, 2, 3, 4)«; - // $TEST$ error "The parameter 'b' must be set here." + # $TEST$ error "The parameter 'b' must be set here." mySegment1»(1, c = 2)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." mySegment1»(b = 1, a = 2)«; - // $TEST$ error "The parameters 'a', 'b' must be set here." + # $TEST$ error "The parameters 'a', 'b' must be set here." myCallableType»()«; - // $TEST$ error "The parameter 'b' must be set here." + # $TEST$ error "The parameter 'b' must be set here." myCallableType»(1)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." myCallableType»(1, 2)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." myCallableType»(1, 2, 3)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." myCallableType»(1, 2, 3, 4)«; - // $TEST$ error "The parameter 'b' must be set here." + # $TEST$ error "The parameter 'b' must be set here." myCallableType»(1, c = 2)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." myCallableType»(b = 1, a = 2)«; - // $TEST$ error "The parameters 'a', 'b' must be set here." + # $TEST$ error "The parameters 'a', 'b' must be set here." myBlockLambda»()«; - // $TEST$ error "The parameter 'b' must be set here." + # $TEST$ error "The parameter 'b' must be set here." myBlockLambda»(1)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." myBlockLambda»(1, 2)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." myBlockLambda»(1, 2, 3)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." myBlockLambda»(1, 2, 3, 4)«; - // $TEST$ error "The parameter 'b' must be set here." + # $TEST$ error "The parameter 'b' must be set here." myBlockLambda»(1, c = 2)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." myBlockLambda»(b = 1, a = 2)«; - // $TEST$ error "The parameters 'a', 'b' must be set here." + # $TEST$ error "The parameters 'a', 'b' must be set here." myExpressionLambda»()«; - // $TEST$ error "The parameter 'b' must be set here." + # $TEST$ error "The parameter 'b' must be set here." myExpressionLambda»(1)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." myExpressionLambda»(1, 2)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." myExpressionLambda»(1, 2, 3)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." myExpressionLambda»(1, 2, 3, 4)«; - // $TEST$ error "The parameter 'b' must be set here." + # $TEST$ error "The parameter 'b' must be set here." myExpressionLambda»(1, c = 2)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." myExpressionLambda»(b = 1, a = 2)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." myPipeline»()«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." unresolved»()«; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/argument lists/must not have positional argument after named argument/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/argument lists/must not have positional argument after named argument/main.sdstest index 62634ca3..ea2fe81f 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/argument lists/must not have positional argument after named argument/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/argument lists/must not have positional argument after named argument/main.sdstest @@ -2,62 +2,62 @@ package tests.validation.other.argumentLists.mustNotHavePositionalArgumentAfterN annotation MyAnnotation(a: Int, b: Int = 0, c: Int = 0, d: Int = 0) -// $TEST$ no error "After the first named argument all arguments must be named." -// $TEST$ no error "After the first named argument all arguments must be named." -// $TEST$ error "After the first named argument all arguments must be named." -// $TEST$ no error "After the first named argument all arguments must be named." -// $TEST$ error "After the first named argument all arguments must be named." +# $TEST$ no error "After the first named argument all arguments must be named." +# $TEST$ no error "After the first named argument all arguments must be named." +# $TEST$ error "After the first named argument all arguments must be named." +# $TEST$ no error "After the first named argument all arguments must be named." +# $TEST$ error "After the first named argument all arguments must be named." @MyAnnotation(»0«, »a = 1«, »2«, »b = 3«, »4«) class MyClass1 -// $TEST$ no error "After the first named argument all arguments must be named." +# $TEST$ no error "After the first named argument all arguments must be named." @MyAnnotation(»0«) class MyClass2 -// $TEST$ no error "After the first named argument all arguments must be named." +# $TEST$ no error "After the first named argument all arguments must be named." @MyAnnotation(»a = 0«) class MyClass3 -// $TEST$ no error "After the first named argument all arguments must be named." -// $TEST$ no error "After the first named argument all arguments must be named." -// $TEST$ error "After the first named argument all arguments must be named." -// $TEST$ no error "After the first named argument all arguments must be named." +# $TEST$ no error "After the first named argument all arguments must be named." +# $TEST$ no error "After the first named argument all arguments must be named." +# $TEST$ error "After the first named argument all arguments must be named." +# $TEST$ no error "After the first named argument all arguments must be named." @UnresolvedAnnotation(»0«, »a = 1«, »2«, »b = 3«) class MyClass4 -// $TEST$ no error "After the first named argument all arguments must be named." +# $TEST$ no error "After the first named argument all arguments must be named." @UnresolvedAnnotation(»0«) class MyClass5 -// $TEST$ no error "After the first named argument all arguments must be named." +# $TEST$ no error "After the first named argument all arguments must be named." @UnresolvedAnnotation(»a = 0«) class MyClass3 fun f(a: Int, b: Int = 0, c: Int = 0, d: Int = 0) pipeline myPipeline { - // $TEST$ no error "After the first named argument all arguments must be named." - // $TEST$ no error "After the first named argument all arguments must be named." - // $TEST$ error "After the first named argument all arguments must be named." - // $TEST$ no error "After the first named argument all arguments must be named." - // $TEST$ error "After the first named argument all arguments must be named." + # $TEST$ no error "After the first named argument all arguments must be named." + # $TEST$ no error "After the first named argument all arguments must be named." + # $TEST$ error "After the first named argument all arguments must be named." + # $TEST$ no error "After the first named argument all arguments must be named." + # $TEST$ error "After the first named argument all arguments must be named." f(»0«, »a = 1«, »2«, »b = 3«, »4«); - // $TEST$ no error "After the first named argument all arguments must be named." + # $TEST$ no error "After the first named argument all arguments must be named." f(»0«); - // $TEST$ no error "After the first named argument all arguments must be named." + # $TEST$ no error "After the first named argument all arguments must be named." f(»a = 0«); - // $TEST$ no error "After the first named argument all arguments must be named." - // $TEST$ no error "After the first named argument all arguments must be named." - // $TEST$ error "After the first named argument all arguments must be named." - // $TEST$ no error "After the first named argument all arguments must be named." + # $TEST$ no error "After the first named argument all arguments must be named." + # $TEST$ no error "After the first named argument all arguments must be named." + # $TEST$ error "After the first named argument all arguments must be named." + # $TEST$ no error "After the first named argument all arguments must be named." unresolvedCallable(»0«, »a = 1«, »2«, »b = 3«); - // $TEST$ no error "After the first named argument all arguments must be named." + # $TEST$ no error "After the first named argument all arguments must be named." unresolvedCallable(»0«); - // $TEST$ no error "After the first named argument all arguments must be named." + # $TEST$ no error "After the first named argument all arguments must be named." unresolvedCallable(»a = 0«); } diff --git a/packages/ttsl-lang/tests/resources/validation/other/argument lists/too many arguments/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/argument lists/too many arguments/main.sdstest index 3934b8a0..9f014d51 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/argument lists/too many arguments/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/argument lists/too many arguments/main.sdstest @@ -22,19 +22,19 @@ segment mySegment2(a: Int, b: Int = 0) {} pipeline myPipeline {} -// $TEST$ no error r"Expected .* arguments? but got \d*\." +# $TEST$ no error r"Expected .* arguments? but got \d*\." @MyAnnotation1»(1)« -// $TEST$ no error r"Expected .* arguments? but got \d*\." +# $TEST$ no error r"Expected .* arguments? but got \d*\." @MyAnnotation1»(1, 2)« -// $TEST$ error "Expected exactly 2 arguments but got 3." +# $TEST$ error "Expected exactly 2 arguments but got 3." @MyAnnotation1»(1, 2, 3)« -// $TEST$ no error r"Expected .* arguments? but got \d*\." +# $TEST$ no error r"Expected .* arguments? but got \d*\." @MyAnnotation2»()« -// $TEST$ no error r"Expected .* arguments? but got \d*\." +# $TEST$ no error r"Expected .* arguments? but got \d*\." @MyAnnotation2»(1)« -// $TEST$ no error r"Expected .* arguments? but got \d*\." +# $TEST$ no error r"Expected .* arguments? but got \d*\." @MyAnnotation2»(1, 2)« -// $TEST$ error "Expected between 1 and 2 arguments but got 3." +# $TEST$ error "Expected between 1 and 2 arguments but got 3." @MyAnnotation2»(1, 2, 3)« segment mySegment3( myCallableType1: (a: Int, b: Int) -> (), @@ -51,136 +51,136 @@ segment mySegment3( * We can never call an annotation directly and should avoid showing additional errors. */ - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." MyAnnotation1»(1)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." MyAnnotation1»(1, 2)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." MyAnnotation1»(1, 2, 3)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." MyAnnotation2»()«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." MyAnnotation2»(1)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." MyAnnotation2»(1, 2)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." MyAnnotation2»(1, 2, 3)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." MyClass1»(1)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." MyClass1»(1, 2)«; - // $TEST$ error "Expected exactly 2 arguments but got 3." + # $TEST$ error "Expected exactly 2 arguments but got 3." MyClass1»(1, 2, 3)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." MyClass2»()«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." MyClass2»(1)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." MyClass2»(1, 2)«; - // $TEST$ error "Expected between 1 and 2 arguments but got 3." + # $TEST$ error "Expected between 1 and 2 arguments but got 3." MyClass2»(1, 2, 3)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." MyEnum.MyEnumVariant1»(1)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." MyEnum.MyEnumVariant1»(1, 2)«; - // $TEST$ error "Expected exactly 2 arguments but got 3." + # $TEST$ error "Expected exactly 2 arguments but got 3." MyEnum.MyEnumVariant1»(1, 2, 3)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." MyEnum.MyEnumVariant2»()«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." MyEnum.MyEnumVariant2»(1)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." MyEnum.MyEnumVariant2»(1, 2)«; - // $TEST$ error "Expected between 1 and 2 arguments but got 3." + # $TEST$ error "Expected between 1 and 2 arguments but got 3." MyEnum.MyEnumVariant2»(1, 2, 3)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." myFunction1»(1)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." myFunction1»(1, 2)«; - // $TEST$ error "Expected exactly 2 arguments but got 3." + # $TEST$ error "Expected exactly 2 arguments but got 3." myFunction1»(1, 2, 3)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." myFunction2»()«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." myFunction2»(1)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." myFunction2»(1, 2)«; - // $TEST$ error "Expected between 1 and 2 arguments but got 3." + # $TEST$ error "Expected between 1 and 2 arguments but got 3." myFunction2»(1, 2, 3)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." mySegment1»(1)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." mySegment1»(1, 2)«; - // $TEST$ error "Expected exactly 2 arguments but got 3." + # $TEST$ error "Expected exactly 2 arguments but got 3." mySegment1»(1, 2, 3)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." mySegment2»()«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." mySegment2»(1)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." mySegment2»(1, 2)«; - // $TEST$ error "Expected between 1 and 2 arguments but got 3." + # $TEST$ error "Expected between 1 and 2 arguments but got 3." mySegment2»(1, 2, 3)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." myCallableType1»(1)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." myCallableType1»(1, 2)«; - // $TEST$ error "Expected exactly 2 arguments but got 3." + # $TEST$ error "Expected exactly 2 arguments but got 3." myCallableType1»(1, 2, 3)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." myCallableType2»()«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." myCallableType2»(1)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." myCallableType2»(1, 2)«; - // $TEST$ error "Expected between 1 and 2 arguments but got 3." + # $TEST$ error "Expected between 1 and 2 arguments but got 3." myCallableType2»(1, 2, 3)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." myBlockLambda1»(1)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." myBlockLambda1»(1, 2)«; - // $TEST$ error "Expected exactly 2 arguments but got 3." + # $TEST$ error "Expected exactly 2 arguments but got 3." myBlockLambda1»(1, 2, 3)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." myBlockLambda2»()«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." myBlockLambda2»(1)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." myBlockLambda2»(1, 2)«; - // $TEST$ error "Expected between 1 and 2 arguments but got 3." + # $TEST$ error "Expected between 1 and 2 arguments but got 3." myBlockLambda2»(1, 2, 3)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." myExpressionLambda1»(1)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." myExpressionLambda1»(1, 2)«; - // $TEST$ error "Expected exactly 2 arguments but got 3." + # $TEST$ error "Expected exactly 2 arguments but got 3." myExpressionLambda1»(1, 2, 3)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." myExpressionLambda2»()«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." myExpressionLambda2»(1)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." myExpressionLambda2»(1, 2)«; - // $TEST$ error "Expected between 1 and 2 arguments but got 3." + # $TEST$ error "Expected between 1 and 2 arguments but got 3." myExpressionLambda2»(1, 2, 3)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." myPipeline»(1)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." unresolved»(1)«; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/annotation calls/missing argument list/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/annotation calls/missing argument list/main.sdstest index 02d258d8..b8909fa2 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/annotation calls/missing argument list/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/annotation calls/missing argument list/main.sdstest @@ -12,24 +12,24 @@ annotation AnnotationWithoutRequiredParameters(a: Int = 0) @Repeatable annotation AnnotationWithRequiredParameters(a: Int) -// $TEST$ no error r"The annotation '\w*' has required parameters, so an argument list must be added\." +# $TEST$ no error r"The annotation '\w*' has required parameters, so an argument list must be added\." @»AnnotationWithoutParameterList« -// $TEST$ no error r"The annotation '\w*' has required parameters, so an argument list must be added\." +# $TEST$ no error r"The annotation '\w*' has required parameters, so an argument list must be added\." @»AnnotationWithoutParameterList()« -// $TEST$ no error r"The annotation '\w*' has required parameters, so an argument list must be added\." +# $TEST$ no error r"The annotation '\w*' has required parameters, so an argument list must be added\." @»AnnotationWithEmptyParameterList« -// $TEST$ no error r"The annotation '\w*' has required parameters, so an argument list must be added\." +# $TEST$ no error r"The annotation '\w*' has required parameters, so an argument list must be added\." @»AnnotationWithEmptyParameterList()« -// $TEST$ no error r"The annotation '\w*' has required parameters, so an argument list must be added\." +# $TEST$ no error r"The annotation '\w*' has required parameters, so an argument list must be added\." @»AnnotationWithoutRequiredParameters« -// $TEST$ no error r"The annotation '\w*' has required parameters, so an argument list must be added\." +# $TEST$ no error r"The annotation '\w*' has required parameters, so an argument list must be added\." @»AnnotationWithoutRequiredParameters()« -// $TEST$ error "The annotation 'AnnotationWithRequiredParameters' has required parameters, so an argument list must be added." +# $TEST$ error "The annotation 'AnnotationWithRequiredParameters' has required parameters, so an argument list must be added." @»AnnotationWithRequiredParameters« -// $TEST$ no error r"The annotation '\w*' has required parameters, so an argument list must be added\." +# $TEST$ no error r"The annotation '\w*' has required parameters, so an argument list must be added\." @»AnnotationWithRequiredParameters()« -// $TEST$ no error r"The annotation '\w*' has required parameters, so an argument list must be added\." +# $TEST$ no error r"The annotation '\w*' has required parameters, so an argument list must be added\." @»UnresolvedAnnotation« -// $TEST$ no error r"The annotation '\w*' has required parameters, so an argument list must be added\." +# $TEST$ no error r"The annotation '\w*' has required parameters, so an argument list must be added\." @»UnresolvedAnnotation()« class MyClass diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/annotation calls/must not be used on lambda parameters/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/annotation calls/must not be used on lambda parameters/main.sdstest index a589ae4b..1ff4c1f3 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/annotation calls/must not be used on lambda parameters/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/annotation calls/must not be used on lambda parameters/main.sdstest @@ -4,13 +4,13 @@ annotation MyAnnotation pipeline myPipeline { - // $TEST$ error "Lambda parameters must not be annotated." - // $TEST$ error "Lambda parameters must not be annotated." - // $TEST$ error "Lambda parameters must not be annotated." + # $TEST$ error "Lambda parameters must not be annotated." + # $TEST$ error "Lambda parameters must not be annotated." + # $TEST$ error "Lambda parameters must not be annotated." val f = (»@MyAnnotation« »@MyAnnotation« a: Int, »@MyAnnotation« b: Int = 3) {}; - // $TEST$ error "Lambda parameters must not be annotated." - // $TEST$ error "Lambda parameters must not be annotated." - // $TEST$ error "Lambda parameters must not be annotated." + # $TEST$ error "Lambda parameters must not be annotated." + # $TEST$ error "Lambda parameters must not be annotated." + # $TEST$ error "Lambda parameters must not be annotated." val g = (»@MyAnnotation« »@MyAnnotation« a: Int, »@MyAnnotation« b: Int = 3) -> 1; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/annotation calls/must not be used on parameters of callable types/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/annotation calls/must not be used on parameters of callable types/main.sdstest index 03d930b8..1e6911c6 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/annotation calls/must not be used on parameters of callable types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/annotation calls/must not be used on parameters of callable types/main.sdstest @@ -2,9 +2,9 @@ package tests.validation.other.declarations.annotationCalls.mustNotBeUsedOnParam annotation MyAnnotation -// $TEST$ error "Parameters of callable types must not be annotated." -// $TEST$ error "Parameters of callable types must not be annotated." -// $TEST$ error "Parameters of callable types must not be annotated." +# $TEST$ error "Parameters of callable types must not be annotated." +# $TEST$ error "Parameters of callable types must not be annotated." +# $TEST$ error "Parameters of callable types must not be annotated." segment mySegment( f: (»@MyAnnotation« »@MyAnnotation« a: Int, »@MyAnnotation« b: Int = 3) -> () ) {} diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/annotation calls/must not be used on results of callable types/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/annotation calls/must not be used on results of callable types/main.sdstest index 33657cbf..b1376d9b 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/annotation calls/must not be used on results of callable types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/annotation calls/must not be used on results of callable types/main.sdstest @@ -2,9 +2,9 @@ package tests.validation.other.declarations.annotationCalls.mustNotBeUsedOnResul annotation MyAnnotation -// $TEST$ error "Results of callable types must not be annotated." -// $TEST$ error "Results of callable types must not be annotated." -// $TEST$ error "Results of callable types must not be annotated." +# $TEST$ error "Results of callable types must not be annotated." +# $TEST$ error "Results of callable types must not be annotated." +# $TEST$ error "Results of callable types must not be annotated." segment mySegment( f: () -> (»@MyAnnotation« »@MyAnnotation« a: Int, »@MyAnnotation« b: Int) ) {} diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/arguments must match parameter bounds/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/arguments must match parameter bounds/main.sdstest index 7146498a..da597b5a 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/arguments must match parameter bounds/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/arguments must match parameter bounds/main.sdstest @@ -28,62 +28,62 @@ package tests.validation.other.declarations.parameterBounds.argumentsMustMatchPa } segment mySegment(p: Int) { - // $TEST$ error "The value of 'notConst' must be greater than 0 but was 0." + # $TEST$ error "The value of 'notConst' must be greater than 0 but was 0." f1(»0«); - // $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." f1(»""«); - // $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." f1(»p«); - // $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." f1(»unresolved«); - // $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." f1(unresolved = »1«); - // $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." f2(»1«); - // $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." f2(»""«); - // $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." f2(»p«); - // $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." f2(»unresolved«); - // $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." f2(unresolved = »1«); - // $TEST$ error "The value of 'bothBounds' must be greater than 0 but was 0." + # $TEST$ error "The value of 'bothBounds' must be greater than 0 but was 0." f3(»0«); - // $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." f3(»5«); - // $TEST$ error "The value of 'bothBounds' must be less than 10 but was 10." + # $TEST$ error "The value of 'bothBounds' must be less than 10 but was 10." f3(»10«); - // $TEST$ error "The value of 'lowerBound' must be greater than or equal to 0 but was -1." - // $TEST$ error "The value of 'indirectLowerBound' must be greater than or equal to -1 but was -2." + # $TEST$ error "The value of 'lowerBound' must be greater than or equal to 0 but was -1." + # $TEST$ error "The value of 'indirectLowerBound' must be greater than or equal to -1 but was -2." f4(»-1«, »-2«); - // $TEST$ error "The value of 'lowerBound' must be greater than or equal to 0 but was -1." - // $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ error "The value of 'lowerBound' must be greater than or equal to 0 but was -1." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." f4(»-1«, »-1«); - // $TEST$ no error r"The value of '.*' must be .* but was .*\." - // $TEST$ error "The value of 'indirectLowerBound' must be greater than or equal to 0 but was -1." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ error "The value of 'indirectLowerBound' must be greater than or equal to 0 but was -1." f4(»0«, »-1«); - // $TEST$ no error r"The value of '.*' must be .* but was .*\." - // $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." f4(»0«, »0«); - // $TEST$ error "The value of 'upperBound' must be less than or equal to 0 but was 1." - // $TEST$ error "The value of 'indirectUpperBound' must be less than or equal to 1 but was 2." + # $TEST$ error "The value of 'upperBound' must be less than or equal to 0 but was 1." + # $TEST$ error "The value of 'indirectUpperBound' must be less than or equal to 1 but was 2." f5(»1«, »2«); - // $TEST$ error "The value of 'upperBound' must be less than or equal to 0 but was 1." - // $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ error "The value of 'upperBound' must be less than or equal to 0 but was 1." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." f5(»1«, »1«); - // $TEST$ no error r"The value of '.*' must be .* but was .*\." - // $TEST$ error "The value of 'indirectUpperBound' must be less than or equal to 0 but was 1." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ error "The value of 'indirectUpperBound' must be less than or equal to 0 but was 1." f5(»0«, »1«); - // $TEST$ no error r"The value of '.*' must be .* but was .*\." - // $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." f5(»0«, »0«); - // $TEST$ error "The value of 'indirectUpperBound' must be less than or equal to -1 but was 0." + # $TEST$ error "The value of 'indirectUpperBound' must be less than or equal to -1 but was 0." f5(indirectUpperBound = »0«); - // $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." f5(indirectUpperBound = »-1«); } diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/default values must match parameter bounds/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/default values must match parameter bounds/main.sdstest index 54de5438..f40bb5ac 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/default values must match parameter bounds/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/default values must match parameter bounds/main.sdstest @@ -1,13 +1,13 @@ package tests.validation.other.declarations.parameterBounds.defaultValuesMustMatchParameterBounds @Pure fun f1( - // $TEST$ error "The value of 'notConst1' must be greater than 0 but was 0." + # $TEST$ error "The value of 'notConst1' must be greater than 0 but was 0." notConst1: Int = »0«, - // $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." notConst2: Int = »""«, - // $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." notConst3: Int = »p«, - // $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." notConst4: Int = »unresolved«, ) where { notConst1 > 0, @@ -17,22 +17,22 @@ package tests.validation.other.declarations.parameterBounds.defaultValuesMustMat } @Pure fun f2( - // $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." const unbounded1: Int = »1«, - // $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." const unbounded2: Int = »""«, - // $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." const unbounded3: Int = »p«, - // $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." const unbounded4: Int = »unresolved«, ) @Pure fun f3( - // $TEST$ error "The value of 'bothBounds1' must be greater than 0 but was 0." + # $TEST$ error "The value of 'bothBounds1' must be greater than 0 but was 0." const bothBounds1: Int = »0«, - // $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." const bothBounds2: Int= »5«, - // $TEST$ error "The value of 'bothBounds3' must be less than 10 but was 10." + # $TEST$ error "The value of 'bothBounds3' must be less than 10 but was 10." const bothBounds3: Int = »10«, ) where { bothBounds1 > 0, @@ -46,11 +46,11 @@ package tests.validation.other.declarations.parameterBounds.defaultValuesMustMat } @Pure fun f4( - // $TEST$ error "The value of 'lowerBound1' must be greater than or equal to 0 but was -1." + # $TEST$ error "The value of 'lowerBound1' must be greater than or equal to 0 but was -1." const lowerBound1: Int = »-1«, - // $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." const lowerBound2: Int = »0«, - // $TEST$ error "Cannot verify whether the parameter bounds are always met." + # $TEST$ error "Cannot verify whether the parameter bounds are always met." const indirectLowerBound: Int = »0«, ) where { lowerBound1 >= 0, @@ -59,11 +59,11 @@ package tests.validation.other.declarations.parameterBounds.defaultValuesMustMat } @Pure fun f5( - // $TEST$ error "The value of 'upperBound1' must be less than or equal to 0 but was 1." + # $TEST$ error "The value of 'upperBound1' must be less than or equal to 0 but was 1." const upperBound1: Int = »1«, - // $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." const upperBound2: Int = »0«, - // $TEST$ error "Cannot verify whether the parameter bounds are always met." + # $TEST$ error "Cannot verify whether the parameter bounds are always met." const indirectUpperBound: Int = »0«, ) where { upperBound1 <= 0, diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/parameter must be const/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/parameter must be const/main.sdstest index 3c494101..bad49358 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/parameter must be const/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/parameter must be const/main.sdstest @@ -9,68 +9,68 @@ package tests.validation.other.declarations.parameterBounds.parameterMustBeConst const b2: Float, const b3: String ) where { - // $TEST$ error "Only constant parameters can have bounds." + # $TEST$ error "Only constant parameters can have bounds." »a1« < 0, - // $TEST$ error "Only constant parameters can have bounds." + # $TEST$ error "Only constant parameters can have bounds." »a1« <= 0, - // $TEST$ error "Only constant parameters can have bounds." + # $TEST$ error "Only constant parameters can have bounds." »a1« >= 0, - // $TEST$ error "Only constant parameters can have bounds." + # $TEST$ error "Only constant parameters can have bounds." »a1« > 0, - // $TEST$ error "Only constant parameters can have bounds." + # $TEST$ error "Only constant parameters can have bounds." »a2« < 0, - // $TEST$ error "Only constant parameters can have bounds." + # $TEST$ error "Only constant parameters can have bounds." »a2« <= 0, - // $TEST$ error "Only constant parameters can have bounds." + # $TEST$ error "Only constant parameters can have bounds." »a2« >= 0, - // $TEST$ error "Only constant parameters can have bounds." + # $TEST$ error "Only constant parameters can have bounds." »a2« > 0, - // $TEST$ no error "Only constant parameters can have bounds." + # $TEST$ no error "Only constant parameters can have bounds." »a3« < 0, - // $TEST$ no error "Only constant parameters can have bounds." + # $TEST$ no error "Only constant parameters can have bounds." »a3« <= 0, - // $TEST$ no error "Only constant parameters can have bounds." + # $TEST$ no error "Only constant parameters can have bounds." »a3« >= 0, - // $TEST$ no error "Only constant parameters can have bounds." + # $TEST$ no error "Only constant parameters can have bounds." »a3« > 0, - // $TEST$ no error "Only constant parameters can have bounds." + # $TEST$ no error "Only constant parameters can have bounds." »b1« < 0, - // $TEST$ no error "Only constant parameters can have bounds." + # $TEST$ no error "Only constant parameters can have bounds." »b1« <= 0, - // $TEST$ no error "Only constant parameters can have bounds." + # $TEST$ no error "Only constant parameters can have bounds." »b1« >= 0, - // $TEST$ no error "Only constant parameters can have bounds." + # $TEST$ no error "Only constant parameters can have bounds." »b1« > 0, - // $TEST$ no error "Only constant parameters can have bounds." + # $TEST$ no error "Only constant parameters can have bounds." »b2« < 0, - // $TEST$ no error "Only constant parameters can have bounds." + # $TEST$ no error "Only constant parameters can have bounds." »b2« <= 0, - // $TEST$ no error "Only constant parameters can have bounds." + # $TEST$ no error "Only constant parameters can have bounds." »b2« >= 0, - // $TEST$ no error "Only constant parameters can have bounds." + # $TEST$ no error "Only constant parameters can have bounds." »b2« > 0, - // $TEST$ no error "Only constant parameters can have bounds." + # $TEST$ no error "Only constant parameters can have bounds." »b3« < 0, - // $TEST$ no error "Only constant parameters can have bounds." + # $TEST$ no error "Only constant parameters can have bounds." »b3« <= 0, - // $TEST$ no error "Only constant parameters can have bounds." + # $TEST$ no error "Only constant parameters can have bounds." »b3« >= 0, - // $TEST$ no error "Only constant parameters can have bounds." + # $TEST$ no error "Only constant parameters can have bounds." »b3« > 0, - // $TEST$ no error "Only constant parameters can have bounds." + # $TEST$ no error "Only constant parameters can have bounds." »unresolved« < 0, - // $TEST$ no error "Only constant parameters can have bounds." + # $TEST$ no error "Only constant parameters can have bounds." »unresolved« <= 0, - // $TEST$ no error "Only constant parameters can have bounds." + # $TEST$ no error "Only constant parameters can have bounds." »unresolved« >= 0, - // $TEST$ no error "Only constant parameters can have bounds." + # $TEST$ no error "Only constant parameters can have bounds." »unresolved« > 0, } diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/parameter must be float or int/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/parameter must be float or int/main.sdstest index d3634119..2f370cd9 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/parameter must be float or int/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/parameter must be float or int/main.sdstest @@ -5,40 +5,40 @@ package tests.validation.other.declarations.parameterBounds.parameterMustBeFloat p2: Float, p3: String ) where { - // $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." + # $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." »p1« < 0, - // $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." + # $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." »p1« <= 0, - // $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." + # $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." »p1« >= 0, - // $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." + # $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." »p1« > 0, - // $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." + # $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." »p2« < 0, - // $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." + # $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." »p2« <= 0, - // $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." + # $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." »p2« >= 0, - // $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." + # $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." »p2« > 0, - // $TEST$ error "Only 'Float' and 'Int' parameters can have bounds." + # $TEST$ error "Only 'Float' and 'Int' parameters can have bounds." »p3« < 0, - // $TEST$ error "Only 'Float' and 'Int' parameters can have bounds." + # $TEST$ error "Only 'Float' and 'Int' parameters can have bounds." »p3« <= 0, - // $TEST$ error "Only 'Float' and 'Int' parameters can have bounds." + # $TEST$ error "Only 'Float' and 'Int' parameters can have bounds." »p3« >= 0, - // $TEST$ error "Only 'Float' and 'Int' parameters can have bounds." + # $TEST$ error "Only 'Float' and 'Int' parameters can have bounds." »p3« > 0, - // $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." + # $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." »unresolved« < 0, - // $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." + # $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." »unresolved« <= 0, - // $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." + # $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." »unresolved« >= 0, - // $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." + # $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." »unresolved« > 0, } diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/right operand must evaluate to float constant or int constant/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/right operand must evaluate to float constant or int constant/main.sdstest index 3121d3d8..3965dd39 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/right operand must evaluate to float constant or int constant/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/right operand must evaluate to float constant or int constant/main.sdstest @@ -9,86 +9,86 @@ package tests.validation.other.declarations.parameterBounds.rightOperandMustEval const b2: Float, const b3: String, ) where { - // $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." b1 < »0«, - // $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." b1 <= »0«, - // $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." b1 >= »0«, - // $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." b1 > »0«, - // $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." b1 < »0.5«, - // $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." b1 <= »0.5«, - // $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." b1 >= »0.5«, - // $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." b1 > »0.5«, - // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 < »""«, - // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 <= »""«, - // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 >= »""«, - // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 > »""«, - // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 < »a1«, - // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 <= »a1«, - // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 >= »a1«, - // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 > »a1«, - // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 < »a2«, - // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 <= »a2«, - // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 >= »a2«, - // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 > »a2«, - // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 < »a3«, - // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 <= »a3«, - // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 >= »a3«, - // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 > »a3«, - // $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." b1 < »b1«, - // $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." b1 <= »b1«, - // $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." b1 >= »b1«, - // $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." b1 > »b1«, - // $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." b1 < »b2«, - // $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." b1 <= »b2«, - // $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." b1 >= »b2«, - // $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." b1 > »b2«, - // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 < »b3«, - // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 <= »b3«, - // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 >= »b3«, - // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 > »b3«, } diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter lists/must not have required after optional/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter lists/must not have required after optional/main.sdstest index 41c66761..ea9679a7 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter lists/must not have required after optional/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter lists/must not have required after optional/main.sdstest @@ -1,118 +1,118 @@ package tests.validation.other.declarations.parameterLists.mustNotHaveRequiredAfterOptional -// $TEST$ no error "After the first optional parameter all parameters must be optional." -// $TEST$ no error "After the first optional parameter all parameters must be optional." -// $TEST$ error "After the first optional parameter all parameters must be optional." -// $TEST$ no error "After the first optional parameter all parameters must be optional." +# $TEST$ no error "After the first optional parameter all parameters must be optional." +# $TEST$ no error "After the first optional parameter all parameters must be optional." +# $TEST$ error "After the first optional parameter all parameters must be optional." +# $TEST$ no error "After the first optional parameter all parameters must be optional." annotation MyAnnotation1(»a«: Int, »b«: Int = 1, »c«: Int, »d«: Int = 2) -// $TEST$ no error "After the first optional parameter all parameters must be optional." -// $TEST$ no error "After the first optional parameter all parameters must be optional." +# $TEST$ no error "After the first optional parameter all parameters must be optional." +# $TEST$ no error "After the first optional parameter all parameters must be optional." annotation MyAnnotation2(»a«: Int, »b«: Int = 1) -// $TEST$ no error "After the first optional parameter all parameters must be optional." +# $TEST$ no error "After the first optional parameter all parameters must be optional." annotation MyAnnotation3(»a«: Int) -// $TEST$ no error "After the first optional parameter all parameters must be optional." -// $TEST$ no error "After the first optional parameter all parameters must be optional." -// $TEST$ error "After the first optional parameter all parameters must be optional." -// $TEST$ no error "After the first optional parameter all parameters must be optional." +# $TEST$ no error "After the first optional parameter all parameters must be optional." +# $TEST$ no error "After the first optional parameter all parameters must be optional." +# $TEST$ error "After the first optional parameter all parameters must be optional." +# $TEST$ no error "After the first optional parameter all parameters must be optional." class MyClass1(»a«: Int, »b«: Int = 1, »c«: Int, »d«: Int = 2) -// $TEST$ no error "After the first optional parameter all parameters must be optional." -// $TEST$ no error "After the first optional parameter all parameters must be optional." +# $TEST$ no error "After the first optional parameter all parameters must be optional." +# $TEST$ no error "After the first optional parameter all parameters must be optional." class MyClass2(»a«: Int, »b«: Int = 1) -// $TEST$ no error "After the first optional parameter all parameters must be optional." +# $TEST$ no error "After the first optional parameter all parameters must be optional." class MyClass3(»a«: Int) enum MyEnum { - // $TEST$ no error "After the first optional parameter all parameters must be optional." - // $TEST$ no error "After the first optional parameter all parameters must be optional." - // $TEST$ error "After the first optional parameter all parameters must be optional." - // $TEST$ no error "After the first optional parameter all parameters must be optional." + # $TEST$ no error "After the first optional parameter all parameters must be optional." + # $TEST$ no error "After the first optional parameter all parameters must be optional." + # $TEST$ error "After the first optional parameter all parameters must be optional." + # $TEST$ no error "After the first optional parameter all parameters must be optional." MyEnumVariant1(»a«: Int, »b«: Int = 1, »c«: Int, »d«: Int = 2) - // $TEST$ no error "After the first optional parameter all parameters must be optional." - // $TEST$ no error "After the first optional parameter all parameters must be optional." + # $TEST$ no error "After the first optional parameter all parameters must be optional." + # $TEST$ no error "After the first optional parameter all parameters must be optional." MyEnumVariant2(»a«: Int, »b«: Int = 1) - // $TEST$ no error "After the first optional parameter all parameters must be optional." + # $TEST$ no error "After the first optional parameter all parameters must be optional." MyEnumVariant3(»a«: Int) } -// $TEST$ no error "After the first optional parameter all parameters must be optional." -// $TEST$ no error "After the first optional parameter all parameters must be optional." -// $TEST$ error "After the first optional parameter all parameters must be optional." -// $TEST$ no error "After the first optional parameter all parameters must be optional." +# $TEST$ no error "After the first optional parameter all parameters must be optional." +# $TEST$ no error "After the first optional parameter all parameters must be optional." +# $TEST$ error "After the first optional parameter all parameters must be optional." +# $TEST$ no error "After the first optional parameter all parameters must be optional." fun myFunction1(»a«: Int, »b«: Int = 1, »c«: Int, »d«: Int = 2) -// $TEST$ no error "After the first optional parameter all parameters must be optional." -// $TEST$ no error "After the first optional parameter all parameters must be optional." +# $TEST$ no error "After the first optional parameter all parameters must be optional." +# $TEST$ no error "After the first optional parameter all parameters must be optional." fun myFunction2(»a«: Int, »b«: Int = 1) -// $TEST$ no error "After the first optional parameter all parameters must be optional." +# $TEST$ no error "After the first optional parameter all parameters must be optional." fun myFunction3(»a«: Int) -// $TEST$ no error "After the first optional parameter all parameters must be optional." -// $TEST$ no error "After the first optional parameter all parameters must be optional." -// $TEST$ error "After the first optional parameter all parameters must be optional." -// $TEST$ no error "After the first optional parameter all parameters must be optional." +# $TEST$ no error "After the first optional parameter all parameters must be optional." +# $TEST$ no error "After the first optional parameter all parameters must be optional." +# $TEST$ error "After the first optional parameter all parameters must be optional." +# $TEST$ no error "After the first optional parameter all parameters must be optional." segment mySegment1(»a«: Int, »b«: Int = 1, »c«: Int, »d«: Int = 2) {} -// $TEST$ no error "After the first optional parameter all parameters must be optional." -// $TEST$ no error "After the first optional parameter all parameters must be optional." +# $TEST$ no error "After the first optional parameter all parameters must be optional." +# $TEST$ no error "After the first optional parameter all parameters must be optional." segment mySegment2(»a«: Int, »b«: Int = 1) {} -// $TEST$ no error "After the first optional parameter all parameters must be optional." +# $TEST$ no error "After the first optional parameter all parameters must be optional." segment mySegment3(»a«: Int) {} pipeline myPipeline { - // $TEST$ no error "After the first optional parameter all parameters must be optional." - // $TEST$ no error "After the first optional parameter all parameters must be optional." - // $TEST$ error "After the first optional parameter all parameters must be optional." - // $TEST$ no error "After the first optional parameter all parameters must be optional." + # $TEST$ no error "After the first optional parameter all parameters must be optional." + # $TEST$ no error "After the first optional parameter all parameters must be optional." + # $TEST$ error "After the first optional parameter all parameters must be optional." + # $TEST$ no error "After the first optional parameter all parameters must be optional." (»a«: Int, »b«: Int = 1, »c«: Int, »d«: Int = 2) {}; - // $TEST$ no error "After the first optional parameter all parameters must be optional." - // $TEST$ no error "After the first optional parameter all parameters must be optional." + # $TEST$ no error "After the first optional parameter all parameters must be optional." + # $TEST$ no error "After the first optional parameter all parameters must be optional." (»a«: Int, »b«: Int = 1) {}; - // $TEST$ no error "After the first optional parameter all parameters must be optional." + # $TEST$ no error "After the first optional parameter all parameters must be optional." (»a«: Int) {}; - // $TEST$ no error "After the first optional parameter all parameters must be optional." - // $TEST$ no error "After the first optional parameter all parameters must be optional." - // $TEST$ error "After the first optional parameter all parameters must be optional." - // $TEST$ no error "After the first optional parameter all parameters must be optional." + # $TEST$ no error "After the first optional parameter all parameters must be optional." + # $TEST$ no error "After the first optional parameter all parameters must be optional." + # $TEST$ error "After the first optional parameter all parameters must be optional." + # $TEST$ no error "After the first optional parameter all parameters must be optional." (»a«: Int, »b«: Int = 1, »c«: Int, »d«: Int = 2) -> 1; - // $TEST$ no error "After the first optional parameter all parameters must be optional." - // $TEST$ no error "After the first optional parameter all parameters must be optional." + # $TEST$ no error "After the first optional parameter all parameters must be optional." + # $TEST$ no error "After the first optional parameter all parameters must be optional." (»a«: Int, »b«: Int = 1) -> 1; - // $TEST$ no error "After the first optional parameter all parameters must be optional." + # $TEST$ no error "After the first optional parameter all parameters must be optional." (»a«: Int) -> 1; } fun myFunction4( - // $TEST$ no error "After the first optional parameter all parameters must be optional." - // $TEST$ no error "After the first optional parameter all parameters must be optional." - // $TEST$ error "After the first optional parameter all parameters must be optional." - // $TEST$ no error "After the first optional parameter all parameters must be optional." + # $TEST$ no error "After the first optional parameter all parameters must be optional." + # $TEST$ no error "After the first optional parameter all parameters must be optional." + # $TEST$ error "After the first optional parameter all parameters must be optional." + # $TEST$ no error "After the first optional parameter all parameters must be optional." p1: (»a«: Int, »b«: Int = 1, »c«: Int, »d«: Int = 2) -> (), - // $TEST$ no error "After the first optional parameter all parameters must be optional." - // $TEST$ no error "After the first optional parameter all parameters must be optional." + # $TEST$ no error "After the first optional parameter all parameters must be optional." + # $TEST$ no error "After the first optional parameter all parameters must be optional." p2: (»a«: Int, »b«: Int = 1) -> (), - // $TEST$ no error "After the first optional parameter all parameters must be optional." + # $TEST$ no error "After the first optional parameter all parameters must be optional." p3: (»a«: Int) -> (), ) diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/const modifier/error.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/const modifier/error.sdstest index 891b8653..c12b62b9 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/const modifier/error.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/const modifier/error.sdstest @@ -2,19 +2,19 @@ package tests.validation.other.declarations.parameters.illegalConstModifier fun f( g: ( - // $TEST$ error "The const modifier is not applicable to parameters of callable types." + # $TEST$ error "The const modifier is not applicable to parameters of callable types." »const« p1: Int ) -> () ) pipeline myPipeline { ( - // $TEST$ error "The const modifier is not applicable to parameters of lambdas." + # $TEST$ error "The const modifier is not applicable to parameters of lambdas." »const« p1: Int ) {}; ( - // $TEST$ error "The const modifier is not applicable to parameters of lambdas." + # $TEST$ error "The const modifier is not applicable to parameters of lambdas." »const« p1: Int ) -> 1; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/const modifier/no error.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/const modifier/no error.sdstest index 1f0601ea..bade60e5 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/const modifier/no error.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/const modifier/no error.sdstest @@ -1,6 +1,6 @@ package tests.validation.other.declarations.parameters.illegalConstModifier -// $TEST$ no error "The const modifier is not applicable to parameters of callable types." +# $TEST$ no error "The const modifier is not applicable to parameters of callable types." fun f( g: (p2: Int) -> () diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/const must only be used for specific types/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/const must only be used for specific types/main.sdstest index 7e1c3865..7aa07f4e 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/const must only be used for specific types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/const must only be used for specific types/main.sdstest @@ -1,24 +1,24 @@ package tests.validation.other.declarations.parameters.constMustOnlyBeUsedForSpecificTypes annotation MyAnnotation( - // $TEST$ error "An annotation parameter cannot have type 'Any'." + # $TEST$ error "An annotation parameter cannot have type 'Any'." anyParam: »Any«, - // $TEST$ no error r"An annotation parameter cannot have type '.*'\." + # $TEST$ no error r"An annotation parameter cannot have type '.*'\." intParam: »Int«, ) @Pure fun functionWithConstantParameters( - // $TEST$ error "A constant parameter cannot have type 'Any'." + # $TEST$ error "A constant parameter cannot have type 'Any'." const anyParam: »Any«, - // $TEST$ no error r"A constant parameter cannot have type '.*'\." + # $TEST$ no error r"A constant parameter cannot have type '.*'\." const intParam: »Int«, ) @Pure fun functionWithNormalParameters( - // $TEST$ no error r"A constant parameter cannot have type '.*'\." + # $TEST$ no error r"A constant parameter cannot have type '.*'\." anyParam: »Any«, - // $TEST$ no error r"A constant parameter cannot have type '.*'\." + # $TEST$ no error r"A constant parameter cannot have type '.*'\." intParam: »Int«, ) diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/const must only be used for specific types/no type.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/const must only be used for specific types/no type.sdstest index 9e604098..17033d15 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/const must only be used for specific types/no type.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/const must only be used for specific types/no type.sdstest @@ -1,6 +1,6 @@ package tests.validation.other.declarations.parameters.constMustOnlyBeUsedForSpecificTypes -// $TEST$ no error r"A.* parameter cannot have type '.*'\." +# $TEST$ no error r"A.* parameter cannot have type '.*'\." annotation AnnotationMissingType(p) diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/default value must be constant if parameter is constant/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/default value must be constant if parameter is constant/main.sdstest index 6307cf81..9fc58284 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/default value must be constant if parameter is constant/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/default value must be constant if parameter is constant/main.sdstest @@ -4,132 +4,132 @@ package tests.validation.other.parameters.defaultValueMustBeConstantIfParameterI fun f() -> value: Int annotation MyAnnotation( - // $TEST$ no error "Default values of annotation parameters must be constant." + # $TEST$ no error "Default values of annotation parameters must be constant." param1: Int = »1«, - // $TEST$ no error "Default values of annotation parameters must be constant." + # $TEST$ no error "Default values of annotation parameters must be constant." param2: Int = »-2«, - // $TEST$ error "Default values of annotation parameters must be constant." + # $TEST$ error "Default values of annotation parameters must be constant." param3: Int = »f()«, - // $TEST$ no error "Default values of annotation parameters must be constant." + # $TEST$ no error "Default values of annotation parameters must be constant." const param4: Int = »1«, - // $TEST$ no error "Default values of annotation parameters must be constant." + # $TEST$ no error "Default values of annotation parameters must be constant." const param5: Int = »-2«, - // $TEST$ error "Default values of annotation parameters must be constant." + # $TEST$ error "Default values of annotation parameters must be constant." const param6: Int = »f()« ) class MyClass( - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." param1: Int = »1«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." param2: Int = »-2«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." param3: Int = »f()«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." const param4: Int = »1«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." const param5: Int = »-2«, - // $TEST$ error "Default values of constant parameters must be constant." + # $TEST$ error "Default values of constant parameters must be constant." const param6: Int = »f()« ) enum MyEnum { MyEnumVariant( - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." param1: Int = »1«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." param2: Int = »-2«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." param3: Int = »f()«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." const param4: Int = »1«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." const param5: Int = »-2«, - // $TEST$ error "Default values of constant parameters must be constant." + # $TEST$ error "Default values of constant parameters must be constant." const param6: Int = »f()« ) } @Pure fun myFunction( - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." param1: Int = »1«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." param2: Int = »-2«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." param3: Int = »f()«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." const param4: Int = »1«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." const param5: Int = »-2«, - // $TEST$ error "Default values of constant parameters must be constant." + # $TEST$ error "Default values of constant parameters must be constant." const param6: Int = »f()« ) segment mySegment( callableType: ( - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." param1: Int = »1«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." param2: Int = »-2«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." param3: Int = »f()«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." const param4: Int = »1«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." const param5: Int = »-2«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." const param6: Int = »f()«, ) -> (), - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." param1: Int = »1«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." param2: Int = »-2«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." param3: Int = »f()«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." const param4: Int = »1«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." const param5: Int = »-2«, - // $TEST$ error "Default values of constant parameters must be constant." + # $TEST$ error "Default values of constant parameters must be constant." const param6: Int = »f()«, ) { ( - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." param1: Int = »1«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." param2: Int = »-2«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." param3: Int = »f()«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." const param4: Int = »1«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." const param5: Int = »-2«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." const param6: Int = »f()«, ) {}; ( - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." param1: Int = »1«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." param2: Int = »-2«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." param3: Int = »f()«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." const param4: Int = »1«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." const param5: Int = »-2«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." const param6: Int = »f()«, ) -> 1; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/placeholders/alias/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/placeholders/alias/main.sdstest index fe1b0230..a422fdf1 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/placeholders/alias/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/placeholders/alias/main.sdstest @@ -21,32 +21,32 @@ schema MySchema {} segment mySegment1() {} segment mySegment2(myParameter: Int) { - // $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." + # $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." val »myPlaceholder« = 1; - // $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." + # $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." val »a« = MyAnnotation; - // $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." + # $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." val »b« = MyClass.myAttribute; - // $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." + # $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." val »c« = MyClass; - // $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." + # $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." val »d« = MyEnum; - // $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." + # $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." val »e« = MyEnum.MyEnumVariant; - // $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." + # $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." val »f« = myFunction; - // $TEST$ error "Aliases are not allowed to provide a cleaner graphical view." - // $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." + # $TEST$ error "Aliases are not allowed to provide a cleaner graphical view." + # $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." val »g1«, val »g2« = myParameter; - // $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." + # $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." val »h« = myPipeline; - // $TEST$ error "Aliases are not allowed to provide a cleaner graphical view." - // $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." + # $TEST$ error "Aliases are not allowed to provide a cleaner graphical view." + # $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." val »i1«, val »i2« = myPlaceholder; - // $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." + # $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." val »j« = MySchema; - // $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." + # $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." val »k« = mySegment1; - // $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." + # $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." val »l« = unresolved; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/placeholders/unused/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/placeholders/unused/main.sdstest index 1527cb7a..1c8304b0 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/placeholders/unused/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/placeholders/unused/main.sdstest @@ -3,42 +3,42 @@ package tests.validation.other.declarations.placeholders.unused fun f() -> (r1: Int, r2: Int) segment mySegment() { - // $TEST$ warning "This placeholder is unused and can be removed." + # $TEST$ warning "This placeholder is unused and can be removed." val »unused« = 1; - // $TEST$ no warning "This placeholder is unused and can be removed." + # $TEST$ no warning "This placeholder is unused and can be removed." val »used« = 1; used; - // $TEST$ no warning "This placeholder is unused and can be removed." - // $TEST$ no warning "This placeholder is unused and can be removed." + # $TEST$ no warning "This placeholder is unused and can be removed." + # $TEST$ no warning "This placeholder is unused and can be removed." val »last1«, val »last2« = f(); } pipeline myPipeline1 { - // $TEST$ warning "This placeholder is unused and can be removed." + # $TEST$ warning "This placeholder is unused and can be removed." val »unused« = 1; - // $TEST$ no warning "This placeholder is unused and can be removed." + # $TEST$ no warning "This placeholder is unused and can be removed." val »used« = 1; used; - // $TEST$ no warning "This placeholder is unused and can be removed." - // $TEST$ no warning "This placeholder is unused and can be removed." + # $TEST$ no warning "This placeholder is unused and can be removed." + # $TEST$ no warning "This placeholder is unused and can be removed." val »last1«, val »last2« = f(); } pipeline myPipeline2 { () { - // $TEST$ warning "This placeholder is unused and can be removed." + # $TEST$ warning "This placeholder is unused and can be removed." val »unused« = 1; - // $TEST$ no warning "This placeholder is unused and can be removed." + # $TEST$ no warning "This placeholder is unused and can be removed." val »used« = 1; used; - // $TEST$ no warning "This placeholder is unused and can be removed." - // $TEST$ no warning "This placeholder is unused and can be removed." + # $TEST$ no warning "This placeholder is unused and can be removed." + # $TEST$ no warning "This placeholder is unused and can be removed." val »last1«, val »last2« = f(); }; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/segments/duplicate yield/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/segments/duplicate yield/main.sdstest index f6677b70..358a0988 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/segments/duplicate yield/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/segments/duplicate yield/main.sdstest @@ -1,20 +1,20 @@ package tests.validation.other.declarations.segments.duplicateYield segment mySegment() -> (a: Int, b: Int, c: Int) { - // $TEST$ no error r"The result '\w*' has been assigned already\." + # $TEST$ no error r"The result '\w*' has been assigned already\." yield »a« = 1; - // $TEST$ no error r"The result '\w*' has been assigned already\." + # $TEST$ no error r"The result '\w*' has been assigned already\." yield »b« = 1; - // $TEST$ error "The result 'b' has been assigned already." + # $TEST$ error "The result 'b' has been assigned already." yield »b« = 1; - // $TEST$ no error r"The result '\w*' has been assigned already\." - // $TEST$ error "The result 'c' has been assigned already." + # $TEST$ no error r"The result '\w*' has been assigned already\." + # $TEST$ error "The result 'c' has been assigned already." yield »c«, yield »c« = 1; - // $TEST$ no error r"The result '\w*' has been assigned already\." + # $TEST$ no error r"The result '\w*' has been assigned already\." yield »unresolved« = 1; - // $TEST$ no error r"The result '\w*' has been assigned already\." + # $TEST$ no error r"The result '\w*' has been assigned already\." yield »unresolved« = 1; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/segments/unassigned result/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/segments/unassigned result/main.sdstest index f4ef6680..4b85ce12 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/segments/unassigned result/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/segments/unassigned result/main.sdstest @@ -1,10 +1,10 @@ package tests.validation.other.declarations.segments.unassignedResult -// $TEST$ no error "Nothing is assigned to this result." -// $TEST$ no error "Nothing is assigned to this result." -// $TEST$ no error "Nothing is assigned to this result." -// $TEST$ no error "Nothing is assigned to this result." -// $TEST$ error "Nothing is assigned to this result." +# $TEST$ no error "Nothing is assigned to this result." +# $TEST$ no error "Nothing is assigned to this result." +# $TEST$ no error "Nothing is assigned to this result." +# $TEST$ no error "Nothing is assigned to this result." +# $TEST$ error "Nothing is assigned to this result." segment mySegment() -> (»a«: Int, »b«: Int, »c«: Int, »d«: Int, »e«: Int) { yield b = 1; yield a = 1; diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/segments/unused parameter/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/segments/unused parameter/main.sdstest index aa0cdfdb..5a35cb31 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/segments/unused parameter/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/segments/unused parameter/main.sdstest @@ -1,11 +1,11 @@ package tests.validation.other.declarations.segments.unusedParameters segment mySegment( - // $TEST$ warning "This parameter is unused and can be removed." + # $TEST$ warning "This parameter is unused and can be removed." »unused«: Int, - // $TEST$ warning "This parameter is unused and can be removed." + # $TEST$ warning "This parameter is unused and can be removed." »onlyHasBound«: Int, - // $TEST$ no warning "This parameter is unused and can be removed." + # $TEST$ no warning "This parameter is unused and can be removed." »used«: Int ) where { onlyHasBound < 0 @@ -17,37 +17,37 @@ segment mySegment( */ ( - // $TEST$ no warning "This parameter is unused and can be removed." + # $TEST$ no warning "This parameter is unused and can be removed." »unused«: Int, - // $TEST$ no warning "This parameter is unused and can be removed." + # $TEST$ no warning "This parameter is unused and can be removed." »used«: Int ) { used; }; ( - // $TEST$ no warning "This parameter is unused and can be removed." + # $TEST$ no warning "This parameter is unused and can be removed." »unused«: Int, - // $TEST$ no warning "This parameter is unused and can be removed." + # $TEST$ no warning "This parameter is unused and can be removed." »used«: Int ) -> used; } -// $TEST$ no warning "This parameter is unused and can be removed." +# $TEST$ no warning "This parameter is unused and can be removed." annotation MyAnnotation(»unused«: Int) -// $TEST$ no warning "This parameter is unused and can be removed." +# $TEST$ no warning "This parameter is unused and can be removed." class MyClass(»unused«: Int) enum MyEnum { - // $TEST$ no warning "This parameter is unused and can be removed." + # $TEST$ no warning "This parameter is unused and can be removed." MyEnumVariant(»unused«: Int) } fun myFunction( - // $TEST$ no warning "This parameter is unused and can be removed." + # $TEST$ no warning "This parameter is unused and can be removed." »unused«: Int, - // $TEST$ no warning "This parameter is unused and can be removed." + # $TEST$ no warning "This parameter is unused and can be removed." myCallableType: (»unused«: Int) -> (), ) diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/segments/unused/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/segments/unused/main.sdstest index 4cf658e6..2bffbe16 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/segments/unused/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/segments/unused/main.sdstest @@ -1,21 +1,21 @@ package tests.validation.other.declarations.segments.unused -// $TEST$ warning "This segment is unused and can be removed." +# $TEST$ warning "This segment is unused and can be removed." private segment »myUnusedPrivateSegment«() {} -// $TEST$ no warning "This segment is unused and can be removed." +# $TEST$ no warning "This segment is unused and can be removed." private segment »myUsedPrivateSegment«() {} -// $TEST$ warning "This segment is unused and can be removed." +# $TEST$ warning "This segment is unused and can be removed." internal segment »myUnusedInternalSegment«() {} -// $TEST$ no warning "This segment is unused and can be removed." +# $TEST$ no warning "This segment is unused and can be removed." internal segment »myUsedInternalSegment«() {} -// $TEST$ no warning "This segment is unused and can be removed." +# $TEST$ no warning "This segment is unused and can be removed." segment »myUnusedPublicSegment«() {} -// $TEST$ no warning "This segment is unused and can be removed." +# $TEST$ no warning "This segment is unused and can be removed." segment »myUsedPublicSegment«() {} pipeline myPipeline1 { diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameter lists/must not have required after optional/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameter lists/must not have required after optional/main.sdstest index f759ad68..72fc5850 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameter lists/must not have required after optional/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameter lists/must not have required after optional/main.sdstest @@ -1,28 +1,28 @@ package tests.validation.other.declarations.typeParameterLists.mustNotHaveRequiredAfterOptional -// $TEST$ no error "After the first optional type parameter all type parameters must be optional." -// $TEST$ no error "After the first optional type parameter all type parameters must be optional." -// $TEST$ error "After the first optional type parameter all type parameters must be optional." -// $TEST$ no error "After the first optional type parameter all type parameters must be optional." +# $TEST$ no error "After the first optional type parameter all type parameters must be optional." +# $TEST$ no error "After the first optional type parameter all type parameters must be optional." +# $TEST$ error "After the first optional type parameter all type parameters must be optional." +# $TEST$ no error "After the first optional type parameter all type parameters must be optional." class MyClass1<»A«, »B« = Int, »C«, »D« = String> -// $TEST$ no error "After the first optional type parameter all type parameters must be optional." -// $TEST$ no error "After the first optional type parameter all type parameters must be optional." +# $TEST$ no error "After the first optional type parameter all type parameters must be optional." +# $TEST$ no error "After the first optional type parameter all type parameters must be optional." class MyClass2<»A«, »B« = Int> -// $TEST$ no error "After the first optional type parameter all type parameters must be optional." +# $TEST$ no error "After the first optional type parameter all type parameters must be optional." class MyClass3<»A«> -// $TEST$ no error "After the first optional type parameter all type parameters must be optional." -// $TEST$ no error "After the first optional type parameter all type parameters must be optional." -// $TEST$ error "After the first optional type parameter all type parameters must be optional." -// $TEST$ no error "After the first optional type parameter all type parameters must be optional." +# $TEST$ no error "After the first optional type parameter all type parameters must be optional." +# $TEST$ no error "After the first optional type parameter all type parameters must be optional." +# $TEST$ error "After the first optional type parameter all type parameters must be optional." +# $TEST$ no error "After the first optional type parameter all type parameters must be optional." fun myFunction1<»A«, »B« = Int, »C«, »D« = String>() -// $TEST$ no error "After the first optional type parameter all type parameters must be optional." -// $TEST$ no error "After the first optional type parameter all type parameters must be optional." +# $TEST$ no error "After the first optional type parameter all type parameters must be optional." +# $TEST$ no error "After the first optional type parameter all type parameters must be optional." fun myFunction2<»A«, »B« = Int>() -// $TEST$ no error "After the first optional type parameter all type parameters must be optional." +# $TEST$ no error "After the first optional type parameter all type parameters must be optional." fun myFunction3<»A«>() diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/insufficient context/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/insufficient context/main.sdstest index be989fcd..d41dacbc 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/insufficient context/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/insufficient context/main.sdstest @@ -1,41 +1,41 @@ package tests.validation.other.declarations.typeParameters.insufficientContext -// $TEST$ no error "Insufficient context to infer this type parameter." +# $TEST$ no error "Insufficient context to infer this type parameter." class MyClass1<»T«> -// $TEST$ error "Insufficient context to infer this type parameter." +# $TEST$ error "Insufficient context to infer this type parameter." class MyClass2<»T« sub Int>() -// $TEST$ error "Insufficient context to infer this type parameter." +# $TEST$ error "Insufficient context to infer this type parameter." class MyClass3<»T«>() { attr myAttr: T } -// $TEST$ no error "Insufficient context to infer this type parameter." +# $TEST$ no error "Insufficient context to infer this type parameter." class MyClass4<»T« sub Int>(param: T) -// $TEST$ no error "Insufficient context to infer this type parameter." +# $TEST$ no error "Insufficient context to infer this type parameter." class MyClass5<»T«>(param: MyClass4?) -// $TEST$ no error "Insufficient context to infer this type parameter." +# $TEST$ no error "Insufficient context to infer this type parameter." class MyClass6<»T«>(param: () -> (r: T)) -// $TEST$ error "Insufficient context to infer this type parameter." +# $TEST$ error "Insufficient context to infer this type parameter." class MyClass7<»T«>(param: (p: T) -> ()) -// $TEST$ error "Insufficient context to infer this type parameter." +# $TEST$ error "Insufficient context to infer this type parameter." class MyClass8<»T«>(param: () -> (r: (p: T) -> ())) -// $TEST$ error "Insufficient context to infer this type parameter." +# $TEST$ error "Insufficient context to infer this type parameter." class MyClass9<»T«>(param: union) -// $TEST$ error "Insufficient context to infer this type parameter." +# $TEST$ error "Insufficient context to infer this type parameter." class MyClass10<»T«>(param: union) -// $TEST$ error "Insufficient context to infer this type parameter." +# $TEST$ error "Insufficient context to infer this type parameter." fun myFunction1<»T« sub Int>() -// $TEST$ no error "Insufficient context to infer this type parameter." +# $TEST$ no error "Insufficient context to infer this type parameter." fun myFunction2<»T«>(param: T) -// $TEST$ no error "Insufficient context to infer this type parameter." +# $TEST$ no error "Insufficient context to infer this type parameter." fun myFunction3<»T«>(param: MyClass4?) -// $TEST$ no error "Insufficient context to infer this type parameter." +# $TEST$ no error "Insufficient context to infer this type parameter." fun myFunction4<»T«>(param: () -> (r: T)) -// $TEST$ error "Insufficient context to infer this type parameter." +# $TEST$ error "Insufficient context to infer this type parameter." fun myFunction5<»T«>(param: (p: T) -> ()) -// $TEST$ error "Insufficient context to infer this type parameter." +# $TEST$ error "Insufficient context to infer this type parameter." fun myFunction6<»T«>(param: () -> (r: (p: T) -> ())) -// $TEST$ error "Insufficient context to infer this type parameter." +# $TEST$ error "Insufficient context to infer this type parameter." fun myFunction7<»T«>(param: union) -// $TEST$ error "Insufficient context to infer this type parameter." +# $TEST$ error "Insufficient context to infer this type parameter." fun myFunction8<»T«>(param: union) diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/upper bound must be named type/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/upper bound must be named type/main.sdstest index 5eeba74b..c75c00df 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/upper bound must be named type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/upper bound must be named type/main.sdstest @@ -5,27 +5,27 @@ enum E { V } -// $TEST$ error "The upper bound of a type parameter must be a named type." +# $TEST$ error "The upper bound of a type parameter must be a named type." class MyClass1 ()«> -// $TEST$ error "The upper bound of a type parameter must be a named type." +# $TEST$ error "The upper bound of a type parameter must be a named type." class MyClass2«> -// $TEST$ no error "The upper bound of a type parameter must be a named type." +# $TEST$ no error "The upper bound of a type parameter must be a named type." class MyClass3 -// $TEST$ no error "The upper bound of a type parameter must be a named type." +# $TEST$ no error "The upper bound of a type parameter must be a named type." class MyClass4 -// $TEST$ no error "The upper bound of a type parameter must be a named type." +# $TEST$ no error "The upper bound of a type parameter must be a named type." class MyClass5 -// $TEST$ no error "The upper bound of a type parameter must be a named type." -// $TEST$ no error "The upper bound of a type parameter must be a named type." +# $TEST$ no error "The upper bound of a type parameter must be a named type." +# $TEST$ no error "The upper bound of a type parameter must be a named type." class MyClass6 -// $TEST$ error "The upper bound of a type parameter must be a named type." +# $TEST$ error "The upper bound of a type parameter must be a named type." class MyClass7«> -// $TEST$ no error "The upper bound of a type parameter must be a named type." +# $TEST$ no error "The upper bound of a type parameter must be a named type." class MyClass8 diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of class type parameters/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of class type parameters/main.sdstest index 6a5b11d7..929598df 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of class type parameters/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of class type parameters/main.sdstest @@ -1,44 +1,44 @@ package tests.validation.other.declarations.typeParameters.usageOfClassTypeParameters -// $TEST$ no error "This type parameter of a containing class cannot be used here." -// $TEST$ no error "This type parameter of a containing class cannot be used here." +# $TEST$ no error "This type parameter of a containing class cannot be used here." +# $TEST$ no error "This type parameter of a containing class cannot be used here." class MyClass(p: »T«) sub »T« { - // $TEST$ no error "This type parameter of a containing class cannot be used here." + # $TEST$ no error "This type parameter of a containing class cannot be used here." attr a: »T« - // $TEST$ error "This type parameter of a containing class cannot be used here." + # $TEST$ error "This type parameter of a containing class cannot be used here." static attr a: »T« - // $TEST$ no error "This type parameter of a containing class cannot be used here." - // $TEST$ no error "This type parameter of a containing class cannot be used here." - // $TEST$ no error "This type parameter of a containing class cannot be used here." - // $TEST$ no error "This type parameter of a containing class cannot be used here." + # $TEST$ no error "This type parameter of a containing class cannot be used here." + # $TEST$ no error "This type parameter of a containing class cannot be used here." + # $TEST$ no error "This type parameter of a containing class cannot be used here." + # $TEST$ no error "This type parameter of a containing class cannot be used here." fun f(p1: »T«, p2: »S«) -> (r1: »T«, r2: »S«) - // $TEST$ error "This type parameter of a containing class cannot be used here." - // $TEST$ no error "This type parameter of a containing class cannot be used here." - // $TEST$ error "This type parameter of a containing class cannot be used here." - // $TEST$ no error "This type parameter of a containing class cannot be used here." + # $TEST$ error "This type parameter of a containing class cannot be used here." + # $TEST$ no error "This type parameter of a containing class cannot be used here." + # $TEST$ error "This type parameter of a containing class cannot be used here." + # $TEST$ no error "This type parameter of a containing class cannot be used here." static fun f(p1: »T«, p2: »S«) -> (r1: »T«, r2: »S«) - // $TEST$ error "This type parameter of a containing class cannot be used here." - // $TEST$ no error "This type parameter of a containing class cannot be used here." + # $TEST$ error "This type parameter of a containing class cannot be used here." + # $TEST$ no error "This type parameter of a containing class cannot be used here." class MyInnerClass(p1: »T«, p2: »S«) { - // $TEST$ error "This type parameter of a containing class cannot be used here." + # $TEST$ error "This type parameter of a containing class cannot be used here." attr a: »T« - // $TEST$ error "This type parameter of a containing class cannot be used here." + # $TEST$ error "This type parameter of a containing class cannot be used here." static attr a: »T« - // $TEST$ error "This type parameter of a containing class cannot be used here." + # $TEST$ error "This type parameter of a containing class cannot be used here." fun f(p: »T«) - // $TEST$ error "This type parameter of a containing class cannot be used here." + # $TEST$ error "This type parameter of a containing class cannot be used here." static fun f(p: »T«) } enum MyInnerEnum { - // $TEST$ error "This type parameter of a containing class cannot be used here." + # $TEST$ error "This type parameter of a containing class cannot be used here." MyEnumVariant(p1: »T«) } } diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of variant type parameter/contravariant type parameter.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of variant type parameter/contravariant type parameter.sdstest index f75cda4f..daa47e14 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of variant type parameter/contravariant type parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of variant type parameter/contravariant type parameter.sdstest @@ -1,78 +1,78 @@ package tests.validation.other.declarations.typeParameters.usageOfVariantTypeParameters -// $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." +# $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." class MyClass1(p1: »Contravariant«) -// $TEST$ error "A contravariant type parameter cannot be used in covariant position." -// $TEST$ error "A contravariant type parameter cannot be used in invariant position." -// $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." +# $TEST$ error "A contravariant type parameter cannot be used in covariant position." +# $TEST$ error "A contravariant type parameter cannot be used in invariant position." +# $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." sub Producer<»Contravariant«>, Middleware<»Contravariant«>, Consumer<»Contravariant«> { - // $TEST$ error "A contravariant type parameter cannot be used in covariant position." + # $TEST$ error "A contravariant type parameter cannot be used in covariant position." attr a1: »Contravariant« - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." - // $TEST$ error "A contravariant type parameter cannot be used in covariant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ error "A contravariant type parameter cannot be used in covariant position." attr a2: (a1: »Contravariant«) -> (r1: »Contravariant«) - // $TEST$ error "A contravariant type parameter cannot be used in covariant position." + # $TEST$ error "A contravariant type parameter cannot be used in covariant position." attr a3: Producer<»Contravariant«> - // $TEST$ error "A contravariant type parameter cannot be used in invariant position." + # $TEST$ error "A contravariant type parameter cannot be used in invariant position." attr a4: Middleware<»Contravariant«> - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." attr a5: Consumer<»Contravariant«> - // $TEST$ error "A contravariant type parameter cannot be used in covariant position." + # $TEST$ error "A contravariant type parameter cannot be used in covariant position." attr a6: Producer> - // $TEST$ error "A contravariant type parameter cannot be used in invariant position." + # $TEST$ error "A contravariant type parameter cannot be used in invariant position." attr a7: Middleware> - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." attr a8: Consumer> fun f( - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." p1: »Contravariant«, - // $TEST$ error "A contravariant type parameter cannot be used in covariant position." - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ error "A contravariant type parameter cannot be used in covariant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." p2: (a1: »Contravariant«) -> (r1: »Contravariant«), - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." p3: Producer<»Contravariant«>, - // $TEST$ error "A contravariant type parameter cannot be used in invariant position." + # $TEST$ error "A contravariant type parameter cannot be used in invariant position." p4: Middleware<»Contravariant«>, - // $TEST$ error "A contravariant type parameter cannot be used in covariant position." + # $TEST$ error "A contravariant type parameter cannot be used in covariant position." p5: Consumer<»Contravariant«>, ) -> ( - // $TEST$ error "A contravariant type parameter cannot be used in covariant position." + # $TEST$ error "A contravariant type parameter cannot be used in covariant position." r1: »Contravariant«, - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." - // $TEST$ error "A contravariant type parameter cannot be used in covariant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ error "A contravariant type parameter cannot be used in covariant position." r2: (a1: »Contravariant«) -> (r1: »Contravariant«), - // $TEST$ error "A contravariant type parameter cannot be used in covariant position." + # $TEST$ error "A contravariant type parameter cannot be used in covariant position." r3: Producer<»Contravariant«>, - // $TEST$ error "A contravariant type parameter cannot be used in invariant position." + # $TEST$ error "A contravariant type parameter cannot be used in invariant position." r4: Middleware<»Contravariant«>, - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." r5: Consumer<»Contravariant«>, ) } fun f1( - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." p1: »Contravariant«, - // $TEST$ error "A contravariant type parameter cannot be used in covariant position." - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ error "A contravariant type parameter cannot be used in covariant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." p2: (a1: »Contravariant«) -> (r1: »Contravariant«), - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." p3: Producer<»Contravariant«>, - // $TEST$ error "A contravariant type parameter cannot be used in invariant position." + # $TEST$ error "A contravariant type parameter cannot be used in invariant position." p4: Middleware<»Contravariant«>, - // $TEST$ error "A contravariant type parameter cannot be used in covariant position." + # $TEST$ error "A contravariant type parameter cannot be used in covariant position." p5: Consumer<»Contravariant«>, ) -> ( - // $TEST$ error "A contravariant type parameter cannot be used in covariant position." + # $TEST$ error "A contravariant type parameter cannot be used in covariant position." r1: »Contravariant«, - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." - // $TEST$ error "A contravariant type parameter cannot be used in covariant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ error "A contravariant type parameter cannot be used in covariant position." r2: (a1: »Contravariant«) -> (r1: »Contravariant«), - // $TEST$ error "A contravariant type parameter cannot be used in covariant position." + # $TEST$ error "A contravariant type parameter cannot be used in covariant position." r3: Producer<»Contravariant«>, - // $TEST$ error "A contravariant type parameter cannot be used in invariant position." + # $TEST$ error "A contravariant type parameter cannot be used in invariant position." r4: Middleware<»Contravariant«>, - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." r5: Consumer<»Contravariant«>, ) diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of variant type parameter/covariant type parameter.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of variant type parameter/covariant type parameter.sdstest index a8c2a196..0521acf5 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of variant type parameter/covariant type parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of variant type parameter/covariant type parameter.sdstest @@ -1,78 +1,78 @@ package tests.validation.other.declarations.typeParameters.usageOfVariantTypeParameters -// $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." +# $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." class MyClass2(p1: »Covariant«) -// $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." -// $TEST$ error "A covariant type parameter cannot be used in invariant position." -// $TEST$ error "A covariant type parameter cannot be used in contravariant position." +# $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." +# $TEST$ error "A covariant type parameter cannot be used in invariant position." +# $TEST$ error "A covariant type parameter cannot be used in contravariant position." sub Producer<»Covariant«>, Middleware<»Covariant«>, Consumer<»Covariant«> { - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." attr a1: »Covariant« - // $TEST$ error "A covariant type parameter cannot be used in contravariant position." - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ error "A covariant type parameter cannot be used in contravariant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." attr a2: (a1: »Covariant«) -> (r1: »Covariant«) - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." attr a3: Producer<»Covariant«> - // $TEST$ error "A covariant type parameter cannot be used in invariant position." + # $TEST$ error "A covariant type parameter cannot be used in invariant position." attr a4: Middleware<»Covariant«> - // $TEST$ error "A covariant type parameter cannot be used in contravariant position." + # $TEST$ error "A covariant type parameter cannot be used in contravariant position." attr a5: Consumer<»Covariant«> - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." attr a6: Producer> - // $TEST$ error "A covariant type parameter cannot be used in invariant position." + # $TEST$ error "A covariant type parameter cannot be used in invariant position." attr a7: Middleware> - // $TEST$ error "A covariant type parameter cannot be used in contravariant position." + # $TEST$ error "A covariant type parameter cannot be used in contravariant position." attr a8: Consumer> fun f( - // $TEST$ error "A covariant type parameter cannot be used in contravariant position." + # $TEST$ error "A covariant type parameter cannot be used in contravariant position." p1: »Covariant«, - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." - // $TEST$ error "A covariant type parameter cannot be used in contravariant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ error "A covariant type parameter cannot be used in contravariant position." p2: (a1: »Covariant«) -> (r1: »Covariant«), - // $TEST$ error "A covariant type parameter cannot be used in contravariant position." + # $TEST$ error "A covariant type parameter cannot be used in contravariant position." p3: Producer<»Covariant«>, - // $TEST$ error "A covariant type parameter cannot be used in invariant position." + # $TEST$ error "A covariant type parameter cannot be used in invariant position." p4: Middleware<»Covariant«>, - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." p5: Consumer<»Covariant«>, ) -> ( - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." r1: »Covariant«, - // $TEST$ error "A covariant type parameter cannot be used in contravariant position." - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ error "A covariant type parameter cannot be used in contravariant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." r2: (a1: »Covariant«) -> (r1: »Covariant«), - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." r3: Producer<»Covariant«>, - // $TEST$ error "A covariant type parameter cannot be used in invariant position." + # $TEST$ error "A covariant type parameter cannot be used in invariant position." r4: Middleware<»Covariant«>, - // $TEST$ error "A covariant type parameter cannot be used in contravariant position." + # $TEST$ error "A covariant type parameter cannot be used in contravariant position." r5: Consumer<»Covariant«>, ) } fun f2( - // $TEST$ error "A covariant type parameter cannot be used in contravariant position." + # $TEST$ error "A covariant type parameter cannot be used in contravariant position." p1: »Covariant«, - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." - // $TEST$ error "A covariant type parameter cannot be used in contravariant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ error "A covariant type parameter cannot be used in contravariant position." p2: (a1: »Covariant«) -> (r1: »Covariant«), - // $TEST$ error "A covariant type parameter cannot be used in contravariant position." + # $TEST$ error "A covariant type parameter cannot be used in contravariant position." p3: Producer<»Covariant«>, - // $TEST$ error "A covariant type parameter cannot be used in invariant position." + # $TEST$ error "A covariant type parameter cannot be used in invariant position." p4: Middleware<»Covariant«>, - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." p5: Consumer<»Covariant«>, ) -> ( - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." r1: »Covariant«, - // $TEST$ error "A covariant type parameter cannot be used in contravariant position." - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ error "A covariant type parameter cannot be used in contravariant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." r2: (a1: »Covariant«) -> (r1: »Covariant«), - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." r3: Producer<»Covariant«>, - // $TEST$ error "A covariant type parameter cannot be used in invariant position." + # $TEST$ error "A covariant type parameter cannot be used in invariant position." r4: Middleware<»Covariant«>, - // $TEST$ error "A covariant type parameter cannot be used in contravariant position." + # $TEST$ error "A covariant type parameter cannot be used in contravariant position." r5: Consumer<»Covariant«>, ) diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of variant type parameter/invariant type parameter.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of variant type parameter/invariant type parameter.sdstest index b9651f3d..7dd84bb5 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of variant type parameter/invariant type parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of variant type parameter/invariant type parameter.sdstest @@ -1,78 +1,78 @@ package tests.validation.other.declarations.typeParameters.usageOfVariantTypeParameters -// $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." +# $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." class MyClass3(p1: »Invariant«) -// $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." -// $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." -// $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." +# $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." +# $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." +# $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." sub Producer<»Invariant«>, Middleware<»Invariant«>, Consumer<»Invariant«> { - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." attr a1: »Invariant« - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." attr a2: (a1: »Invariant«) -> (r1: »Invariant«) - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." attr a3: Producer<»Invariant«> - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." attr a4: Middleware<»Invariant«> - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." attr a5: Consumer<»Invariant«> - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." attr a6: Producer> - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." attr a7: Middleware> - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." attr a8: Consumer> fun f( - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." p1: »Invariant«, - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." p2: (a1: »Invariant«) -> (r1: »Invariant«), - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." p3: Producer<»Invariant«>, - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." p4: Middleware<»Invariant«>, - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." p5: Consumer<»Invariant«>, ) -> ( - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." r1: »Invariant«, - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." r2: (a1: »Invariant«) -> (r1: »Invariant«), - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." r3: Producer<»Invariant«>, - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." r4: Middleware<»Invariant«>, - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." r5: Consumer<»Invariant«>, ) } fun f3( - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." p1: »Invariant«, - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." p2: (a1: »Invariant«) -> (r1: »Invariant«), - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." p3: Producer<»Invariant«>, - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." p4: Middleware<»Invariant«>, - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." p5: Consumer<»Invariant«>, ) -> ( - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." r1: »Invariant«, - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." r2: (a1: »Invariant«) -> (r1: »Invariant«), - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." r3: Producer<»Invariant«>, - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." r4: Middleware<»Invariant«>, - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." r5: Consumer<»Invariant«>, ) diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of variant type parameter/usage of class type parameters.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of variant type parameter/usage of class type parameters.sdstest index faf8e0a2..0b43162a 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of variant type parameter/usage of class type parameters.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of variant type parameter/usage of class type parameters.sdstest @@ -3,32 +3,32 @@ package tests.validation.other.declarations.typeParameters.usageOfVariantTypePar // We already show other errors in those cases. class MyClass4() { - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." static attr a: »Contra« - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." static fun f(p1: »Co«) -> (r1: »Contra«) - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." class MyInnerClass(p1: »Co«) { - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." attr a: »Contra« - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." static attr a: »Contra« - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." fun f(p1: »Co«) -> (r1: »Contra«) - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." static fun f(p1: »Co«) -> (r1: »Contra«) } enum MyInnerEnum { - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." MyEnumVariant(p1: »Co«) } } diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/variance only on classes/invariant.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/variance only on classes/invariant.sdstest index e4a1859a..59ecc452 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/variance only on classes/invariant.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/variance only on classes/invariant.sdstest @@ -1,6 +1,6 @@ package tests.validation.other.declarations.typeParameters.varianceOnlyOnClasses -// $TEST$ no error "Only type parameters of classes can be variant." +# $TEST$ no error "Only type parameters of classes can be variant." class C1 diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/variance only on classes/variant.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/variance only on classes/variant.sdstest index a9ce52db..daef18d3 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/variance only on classes/variant.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/variance only on classes/variant.sdstest @@ -1,11 +1,11 @@ package tests.validation.other.declarations.typeParameters.varianceOnlyOnClasses -// $TEST$ no error "Only type parameters of classes can be variant." +# $TEST$ no error "Only type parameters of classes can be variant." class C2<»in« T> -// $TEST$ no error "Only type parameters of classes can be variant." +# $TEST$ no error "Only type parameters of classes can be variant." class C3<»out« T> -// $TEST$ error "Only type parameters of classes can be variant." +# $TEST$ error "Only type parameters of classes can be variant." fun f2<»in« T>() -// $TEST$ error "Only type parameters of classes can be variant." +# $TEST$ error "Only type parameters of classes can be variant." fun f3<»out« T>() diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/arguments/must be constant if parameter is constant/annotation calls.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/arguments/must be constant if parameter is constant/annotation calls.sdstest index 98ef0ddb..b68ff36d 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/arguments/must be constant if parameter is constant/annotation calls.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/arguments/must be constant if parameter is constant/annotation calls.sdstest @@ -6,22 +6,22 @@ annotation MyAnnotation1(value: Int) @Repeatable annotation MyAnnotation2(constantParam: MyEnum) -// $TEST$ no error "Values assigned to annotation parameters must be constant." +# $TEST$ no error "Values assigned to annotation parameters must be constant." @MyAnnotation1(»1«) -// $TEST$ no error "Values assigned to annotation parameters must be constant." +# $TEST$ no error "Values assigned to annotation parameters must be constant." @MyAnnotation1(»-2«) -// $TEST$ error "Values assigned to annotation parameters must be constant." +# $TEST$ error "Values assigned to annotation parameters must be constant." @MyAnnotation1(»[1, 2][0]«) -// $TEST$ error "Values assigned to annotation parameters must be constant." +# $TEST$ error "Values assigned to annotation parameters must be constant." @MyAnnotation1(»intFunction()«) -// $TEST$ error "Values assigned to annotation parameters must be constant." +# $TEST$ error "Values assigned to annotation parameters must be constant." @MyAnnotation1(value = »intFunction()«) -// $TEST$ no error "Values assigned to annotation parameters must be constant." +# $TEST$ no error "Values assigned to annotation parameters must be constant." @MyAnnotation2(»MyEnum.MyConstantVariant(1)«) -// $TEST$ error "Values assigned to annotation parameters must be constant." +# $TEST$ error "Values assigned to annotation parameters must be constant." @Unresolved(»intFunction()«) -// $TEST$ error "Values assigned to annotation parameters must be constant." +# $TEST$ error "Values assigned to annotation parameters must be constant." @MyAnnotation1(unresolved = »intFunction()«) pipeline testPipeline {} diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/arguments/must be constant if parameter is constant/const parameters.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/arguments/must be constant if parameter is constant/const parameters.sdstest index a3608cd7..d12779b7 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/arguments/must be constant if parameter is constant/const parameters.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/arguments/must be constant if parameter is constant/const parameters.sdstest @@ -11,17 +11,17 @@ fun anotherFunctionWithConstantParameter( ) pipeline testPipeline { - // $TEST$ no error "Values assigned to constant parameters must be constant." + # $TEST$ no error "Values assigned to constant parameters must be constant." myFunctionWithConstantParameter(»1«); - // $TEST$ no error "Values assigned to constant parameters must be constant." + # $TEST$ no error "Values assigned to constant parameters must be constant." myFunctionWithConstantParameter(»-2«); - // $TEST$ error "Values assigned to constant parameters must be constant." + # $TEST$ error "Values assigned to constant parameters must be constant." myFunctionWithConstantParameter(»[1, 2][0]«); - // $TEST$ error "Values assigned to constant parameters must be constant." + # $TEST$ error "Values assigned to constant parameters must be constant." myFunctionWithConstantParameter(»intFunction()«); - // $TEST$ error "Values assigned to constant parameters must be constant." + # $TEST$ error "Values assigned to constant parameters must be constant." myFunctionWithConstantParameter(constantParam = »intFunction()«); - // $TEST$ no error "Values assigned to constant parameters must be constant." + # $TEST$ no error "Values assigned to constant parameters must be constant." anotherFunctionWithConstantParameter(»MyEnum.MyConstantVariant(1)«); } diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/arguments/must be constant if parameter is constant/normal parameters.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/arguments/must be constant if parameter is constant/normal parameters.sdstest index 5cc70771..86ac41b8 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/arguments/must be constant if parameter is constant/normal parameters.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/arguments/must be constant if parameter is constant/normal parameters.sdstest @@ -6,13 +6,13 @@ fun myFunctionWithNormalParameter( ) pipeline testPipeline { - // $TEST$ no error "Values assigned to constant parameters must be constant." + # $TEST$ no error "Values assigned to constant parameters must be constant." myFunctionWithNormalParameter(»intFunction()«); - // $TEST$ no error "Values assigned to constant parameters must be constant." + # $TEST$ no error "Values assigned to constant parameters must be constant." myFunctionWithNormalParameter(param = »intFunction()«); - // $TEST$ no error "Values assigned to constant parameters must be constant." + # $TEST$ no error "Values assigned to constant parameters must be constant." unresolved(»intFunction()«); - // $TEST$ no error "Values assigned to constant parameters must be constant." + # $TEST$ no error "Values assigned to constant parameters must be constant." myFunctionWithNormalParameter(unresolved = »intFunction()«); } diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/direct.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/direct.sdstest index 5cd39024..661a6546 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/direct.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/direct.sdstest @@ -1,16 +1,16 @@ package tests.validation.other.expression.calls.recurcion.direct segment s1() { - // $TEST$ error "Call leads to infinite recursion." + # $TEST$ error "Call leads to infinite recursion." »s2()«; } segment s2() { - // $TEST$ error "Call leads to infinite recursion." + # $TEST$ error "Call leads to infinite recursion." »s3()«; } segment s3() { - // $TEST$ error "Call leads to infinite recursion." + # $TEST$ error "Call leads to infinite recursion." »s2()«; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/not recursive.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/not recursive.sdstest index 56cca762..e4d3265b 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/not recursive.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/not recursive.sdstest @@ -6,7 +6,7 @@ package tests.validation.other.expression.calls.recurcion.notRecursive */ segment s1() { - // $TEST$ no error "Call leads to infinite recursion." + # $TEST$ no error "Call leads to infinite recursion." »s2(() -> s2())«; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/transitive via function pointer argument.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/transitive via function pointer argument.sdstest index 7b987816..8365b787 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/transitive via function pointer argument.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/transitive via function pointer argument.sdstest @@ -1,7 +1,7 @@ package tests.validation.other.expression.calls.recurcion.transitiveViaFunctionPointerArgument segment s1() { - // $TEST$ error "Call leads to infinite recursion." + # $TEST$ error "Call leads to infinite recursion." »s2(s1)«; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/transitive via lambda argument.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/transitive via lambda argument.sdstest index 04cda9eb..6118843f 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/transitive via lambda argument.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/transitive via lambda argument.sdstest @@ -1,7 +1,7 @@ package tests.validation.other.expression.calls.recurcion.transitiveViaLambdaArgument segment s1() { - // $TEST$ error "Call leads to infinite recursion." + # $TEST$ error "Call leads to infinite recursion." »s2(() -> s1())«; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/transitive.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/transitive.sdstest index aac91299..f27abb27 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/transitive.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/transitive.sdstest @@ -1,16 +1,16 @@ package tests.validation.other.expression.calls.recurcion.transitive segment s1() { - // $TEST$ error "Call leads to infinite recursion." + # $TEST$ error "Call leads to infinite recursion." »s2()«; } segment s2() { - // $TEST$ error "Call leads to infinite recursion." + # $TEST$ error "Call leads to infinite recursion." »s3()«; } segment s3() { - // $TEST$ error "Call leads to infinite recursion." + # $TEST$ error "Call leads to infinite recursion." »s1()«; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/chained expression/missing null safety/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/chained expression/missing null safety/main.sdstest index 8f3b9ca3..8b9d4324 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/chained expression/missing null safety/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/chained expression/missing null safety/main.sdstest @@ -13,41 +13,41 @@ segment call( val myFunction = myClass.f; val myFunctionOrNull = myClassOrNull?.f; - // $TEST$ no error "The receiver can be null so a null-safe call must be used." + # $TEST$ no error "The receiver can be null so a null-safe call must be used." »(() {})()«; - // $TEST$ no error "The receiver can be null so a null-safe call must be used." + # $TEST$ no error "The receiver can be null so a null-safe call must be used." »1()«; - // $TEST$ no error "The receiver can be null so a null-safe call must be used." + # $TEST$ no error "The receiver can be null so a null-safe call must be used." »null()«; - // $TEST$ no error "The receiver can be null so a null-safe call must be used." + # $TEST$ no error "The receiver can be null so a null-safe call must be used." »myFunction()«; - // $TEST$ error "The receiver can be null so a null-safe call must be used." + # $TEST$ error "The receiver can be null so a null-safe call must be used." »myFunctionOrNull()«; - // $TEST$ no error "The receiver can be null so a null-safe call must be used." + # $TEST$ no error "The receiver can be null so a null-safe call must be used." »unresolved()«; - // $TEST$ no error "The receiver can be null so a null-safe call must be used." + # $TEST$ no error "The receiver can be null so a null-safe call must be used." »(() {})?()«; - // $TEST$ no error "The receiver can be null so a null-safe call must be used." + # $TEST$ no error "The receiver can be null so a null-safe call must be used." »1?()«; - // $TEST$ no error "The receiver can be null so a null-safe call must be used." + # $TEST$ no error "The receiver can be null so a null-safe call must be used." »null?()«; - // $TEST$ no error "The receiver can be null so a null-safe call must be used." + # $TEST$ no error "The receiver can be null so a null-safe call must be used." »myFunction?()«; - // $TEST$ no error "The receiver can be null so a null-safe call must be used." + # $TEST$ no error "The receiver can be null so a null-safe call must be used." »myFunctionOrNull?()«; - // $TEST$ no error "The receiver can be null so a null-safe call must be used." + # $TEST$ no error "The receiver can be null so a null-safe call must be used." »unresolved?()«; } @@ -58,38 +58,38 @@ segment indexedAccess( val myList = myClass.l; val myListOrNull = myClassOrNull?.l; - // $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." + # $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." »[1][0]«; - // $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." + # $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." »1[0]«; - // $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." + # $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." »null[0]«; - // $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." + # $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." »myList[0]«; - // $TEST$ error "The receiver can be null so a null-safe indexed access must be used." + # $TEST$ error "The receiver can be null so a null-safe indexed access must be used." »myListOrNull[0]«; - // $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." + # $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." »unresolved[0]«; - // $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." + # $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." »1?[0]«; - // $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." + # $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." »null?[0]«; - // $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." + # $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." »myList?[0]«; - // $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." + # $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." »myListOrNull?[0]«; - // $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." + # $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." »unresolved?[0]«; } @@ -97,14 +97,14 @@ class IndexedAccess?, NonNullable sub List>( nullable: Nullable, nonNullable: NonNullable, - // $TEST$ error "The receiver can be null so a null-safe indexed access must be used." + # $TEST$ error "The receiver can be null so a null-safe indexed access must be used." p1: Any? = »nullable[0]«, - // $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." + # $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." p2: Any? = »nonNullable[0]«, - // $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." + # $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." p3: Any? = »nullable?[0]«, - // $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." + # $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." p4: Any? = »nonNullable?[0]«, ) @@ -112,35 +112,35 @@ segment memberAccess( myClass: MyClass, myClassOrNull: MyClass?, ) { - // $TEST$ no error "The receiver can be null so a null-safe member access must be used." + # $TEST$ no error "The receiver can be null so a null-safe member access must be used." »1.a«; - // $TEST$ error "The receiver can be null so a null-safe member access must be used." + # $TEST$ error "The receiver can be null so a null-safe member access must be used." »null.a«; - // $TEST$ no error "The receiver can be null so a null-safe member access must be used." + # $TEST$ no error "The receiver can be null so a null-safe member access must be used." »myClass.a«; - // $TEST$ error "The receiver can be null so a null-safe member access must be used." + # $TEST$ error "The receiver can be null so a null-safe member access must be used." »myClassOrNull.a«; - // $TEST$ no error "The receiver can be null so a null-safe member access must be used." + # $TEST$ no error "The receiver can be null so a null-safe member access must be used." »unresolved.a«; - // $TEST$ no error "The receiver can be null so a null-safe member access must be used." + # $TEST$ no error "The receiver can be null so a null-safe member access must be used." »1?.a«; - // $TEST$ no error "The receiver can be null so a null-safe member access must be used." + # $TEST$ no error "The receiver can be null so a null-safe member access must be used." »null?.a«; - // $TEST$ no error "The receiver can be null so a null-safe member access must be used." + # $TEST$ no error "The receiver can be null so a null-safe member access must be used." »myClass?.a«; - // $TEST$ no error "The receiver can be null so a null-safe member access must be used." + # $TEST$ no error "The receiver can be null so a null-safe member access must be used." »myClassOrNull?.a«; - // $TEST$ no error "The receiver can be null so a null-safe member access must be used." + # $TEST$ no error "The receiver can be null so a null-safe member access must be used." »unresolved?.a«; } @@ -148,13 +148,13 @@ class MemberAccess( nullable: Nullable, nonNullable: NonNullable, - // $TEST$ error "The receiver can be null so a null-safe member access must be used." + # $TEST$ error "The receiver can be null so a null-safe member access must be used." p1: Any? = »nullable.a«, - // $TEST$ no error "The receiver can be null so a null-safe member access must be used." + # $TEST$ no error "The receiver can be null so a null-safe member access must be used." p2: Any? = »nonNullable.a«, - // $TEST$ no error "The receiver can be null so a null-safe member access must be used." + # $TEST$ no error "The receiver can be null so a null-safe member access must be used." p3: Any? = »nullable?.a«, - // $TEST$ no error "The receiver can be null so a null-safe member access must be used." + # $TEST$ no error "The receiver can be null so a null-safe member access must be used." p4: Any? = »nonNullable?.a«, ) diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/indexed access/list index out of bounds/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/indexed access/list index out of bounds/main.sdstest index a22e3b64..dc78adfd 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/indexed access/list index out of bounds/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/indexed access/list index out of bounds/main.sdstest @@ -10,44 +10,44 @@ segment mySegment( ) { val placeholderList = [1]; - // $TEST$ error "List index '-1' is out of bounds." + # $TEST$ error "List index '-1' is out of bounds." myFunction()[»-1«]; - // $TEST$ no error r"List index '.*' is out of bounds\." + # $TEST$ no error r"List index '.*' is out of bounds\." myFunction()[»0«]; - // $TEST$ no error r"List index '.*' is out of bounds\." + # $TEST$ no error r"List index '.*' is out of bounds\." myFunction()[»1«]; - // $TEST$ no error r"List index '.*' is out of bounds\." + # $TEST$ no error r"List index '.*' is out of bounds\." myFunction()[»parameterIndex«]; - // $TEST$ error "List index '-1' is out of bounds." + # $TEST$ error "List index '-1' is out of bounds." parameterList[»-1«]; - // $TEST$ no error r"List index '.*' is out of bounds\." + # $TEST$ no error r"List index '.*' is out of bounds\." parameterList[»0«]; - // $TEST$ no error r"List index '.*' is out of bounds\." + # $TEST$ no error r"List index '.*' is out of bounds\." parameterList[»1«]; - // $TEST$ no error r"List index '.*' is out of bounds\." + # $TEST$ no error r"List index '.*' is out of bounds\." parameterList[»parameterIndex«]; - // $TEST$ error "List index '-1' is out of bounds." + # $TEST$ error "List index '-1' is out of bounds." nullableList[»-1«]; - // $TEST$ no error r"List index '.*' is out of bounds\." + # $TEST$ no error r"List index '.*' is out of bounds\." nullableList[»0«]; - // $TEST$ no error r"List index '.*' is out of bounds\." + # $TEST$ no error r"List index '.*' is out of bounds\." nullableList[»1«]; - // $TEST$ no error r"List index '.*' is out of bounds\." + # $TEST$ no error r"List index '.*' is out of bounds\." nullableList[»parameterIndex«]; - // $TEST$ error "List index '-1' is out of bounds." + # $TEST$ error "List index '-1' is out of bounds." placeholderList[»-1«]; - // $TEST$ no error r"List index '.*' is out of bounds\." + # $TEST$ no error r"List index '.*' is out of bounds\." placeholderList[»0«]; - // $TEST$ error "List index '1' is out of bounds." + # $TEST$ error "List index '1' is out of bounds." placeholderList[»1«]; - // $TEST$ no error r"List index '.*' is out of bounds\." + # $TEST$ no error r"List index '.*' is out of bounds\." placeholderList[»parameterIndex«]; - // $TEST$ no error r"List index '.*' is out of bounds\." + # $TEST$ no error r"List index '.*' is out of bounds\." unresolved[»-1«]; - // $TEST$ no error r"List index '.*' is out of bounds\." + # $TEST$ no error r"List index '.*' is out of bounds\." placeholderList[»unresolved«]; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/indexed access/map key does not exist/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/indexed access/map key does not exist/main.sdstest index b2978f1e..c266fd76 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/indexed access/map key does not exist/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/indexed access/map key does not exist/main.sdstest @@ -6,29 +6,29 @@ fun myFunction() -> resultMap: Map segment mySegment(parameterMap: Map, parameterKey: String) { val placeholderMap = {"key": 1}; - // $TEST$ no error r"Map key '.*' does not exist\." + # $TEST$ no error r"Map key '.*' does not exist\." myFunction()[»"unknown"«]; - // $TEST$ no error r"Map key '.*' does not exist\." + # $TEST$ no error r"Map key '.*' does not exist\." myFunction()[»"key"«]; - // $TEST$ no error r"Map key '.*' does not exist\." + # $TEST$ no error r"Map key '.*' does not exist\." myFunction()[»parameterKey«]; - // $TEST$ no error r"Map key '.*' does not exist\." + # $TEST$ no error r"Map key '.*' does not exist\." parameterMap[»"unknown"«]; - // $TEST$ no error r"Map key '.*' does not exist\." + # $TEST$ no error r"Map key '.*' does not exist\." parameterMap[»"key"«]; - // $TEST$ no error r"Map key '.*' does not exist\." + # $TEST$ no error r"Map key '.*' does not exist\." parameterMap[»parameterKey«]; - // $TEST$ error "Map key '"unknown"' does not exist." + # $TEST$ error "Map key '"unknown"' does not exist." placeholderMap[»"unknown"«]; - // $TEST$ no error r"Map key '.*' does not exist\." + # $TEST$ no error r"Map key '.*' does not exist\." placeholderMap[»"key"«]; - // $TEST$ no error r"Map key '.*' does not exist\." + # $TEST$ no error r"Map key '.*' does not exist\." placeholderMap[»parameterKey«]; - // $TEST$ no error r"Map key '.*' does not exist\." + # $TEST$ no error r"Map key '.*' does not exist\." unresolved[»"unknown"«]; - // $TEST$ no error r"Map key '.*' does not exist\." + # $TEST$ no error r"Map key '.*' does not exist\." placeholderMap[»unresolved«]; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/infix operations/division by zero/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/infix operations/division by zero/main.sdstest index 365a2c93..9108d7a9 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/infix operations/division by zero/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/infix operations/division by zero/main.sdstest @@ -1,38 +1,38 @@ package tests.validation.other.expressions.infixOperations.divisionByZero pipeline test { - // $TEST$ error "Division by zero." + # $TEST$ error "Division by zero." »1.0 / 0.0«; - // $TEST$ error "Division by zero." + # $TEST$ error "Division by zero." »1.0 / -0.0«; - // $TEST$ no error "Division by zero." + # $TEST$ no error "Division by zero." »1.0 / 1.0«; - // $TEST$ error "Division by zero." + # $TEST$ error "Division by zero." »1.0 / 0«; - // $TEST$ no error "Division by zero." + # $TEST$ no error "Division by zero." »1.0 / 1«; - // $TEST$ error "Division by zero." + # $TEST$ error "Division by zero." »1 / 0.0«; - // $TEST$ error "Division by zero." + # $TEST$ error "Division by zero." »1 / -0.0«; - // $TEST$ no error "Division by zero." + # $TEST$ no error "Division by zero." »1 / 1.0«; - // $TEST$ error "Division by zero." + # $TEST$ error "Division by zero." »1 / 0«; - // $TEST$ no error "Division by zero." + # $TEST$ no error "Division by zero." »1 / 1«; - // $TEST$ no error "Division by zero." + # $TEST$ no error "Division by zero." »null / 0.0«; - // $TEST$ no error "Division by zero." + # $TEST$ no error "Division by zero." »null / -0.0«; - // $TEST$ no error "Division by zero." + # $TEST$ no error "Division by zero." »null / 1.0«; - // $TEST$ no error "Division by zero." + # $TEST$ no error "Division by zero." »null / 0«; - // $TEST$ no error "Division by zero." + # $TEST$ no error "Division by zero." »null / 1«; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/lambdas/context/assigned to typed parameter.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/lambdas/context/assigned to typed parameter.sdstest index 5bdb35bc..bdb60e5e 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/lambdas/context/assigned to typed parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/lambdas/context/assigned to typed parameter.sdstest @@ -6,59 +6,59 @@ package tests.validation.other.expressions.lambdas.assignedToTypedParameter @Repeatable annotation MyAnnotation( - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." f: () -> () = »() {}«, - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." g: () -> r: Int = »() -> 1« ) class MyClass( - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." f: () -> () = »() {}«, - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." g: () -> r: Int = ((»() -> 1«)) ) enum MyEnum { MyEnumVariant( - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." f: () -> () = »() {}«, - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." g: () -> r: Int = ((»() -> 1«)) ) } fun myFunction( - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." f: () -> () = »() {}«, - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." g: () -> r: Int = ((»() -> 1«)) ) segment mySegment1( - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." f: () -> () = »() {}«, - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." g: () -> r: Int = ((»() -> 1«)) ) {} segment mySegment2( - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." f: (p: () -> () = »() {}«) -> (), - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." g: (p: () -> (r: Int) = ((»() -> 1«))) -> (), ) { ( - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." f: () -> () = »() {}«, - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." g: () -> r: Int = ((»() -> 1«)) ) {}; ( - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." f: () -> () = »() {}«, - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." g: () -> r: Int = ((»() -> 1«)) ) -> 1; } @@ -68,15 +68,15 @@ segment mySegment2( */ @MyAnnotation( - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." »() {}«, - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." ((»() -> 1«)) ) @MyAnnotation( - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." f = »() {}«, - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." g = ((»() -> 1«)) ) segment lambdasPassedAsArguments( @@ -86,106 +86,106 @@ segment lambdasPassedAsArguments( val expressionLambda = (p: () -> (), q: () -> (r: Int)) -> 1; MyAnnotation( - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." »() {}«, - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." ((»() -> 1«)) ); MyAnnotation( - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." f = »() {}«, - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." g = ((»() -> 1«)) ); MyClass( - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." »() {}«, - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." ((»() -> 1«)) ); MyClass( - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." f = »() {}«, - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." g = ((»() -> 1«)) ); MyEnum.MyEnumVariant( - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." »() {}«, - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." ((»() -> 1«)) ); MyEnum.MyEnumVariant( - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." f = »() {}«, - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." g = ((»() -> 1«)) ); myFunction( - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." »() {}«, - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." ((»() -> 1«)) ); myFunction( - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." f = »() {}«, - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." g = ((»() -> 1«)) ); mySegment1( - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." »() {}«, - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." ((»() -> 1«)) ); mySegment1( - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." f = »() {}«, - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." g = ((»() -> 1«)) ); callableType( - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." »() {}«, - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." ((»() -> 1«)) ); callableType( - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." p = »() {}«, - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." q = ((»() -> 1«)) ); blockLambda( - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." »() {}«, - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." ((»() -> 1«)) ); blockLambda( - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." p = »() {}«, - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." q = ((»() -> 1«)) ); expressionLambda( - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." »() {}«, - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." ((»() -> 1«)) ); expressionLambda( - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." p = »() {}«, - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." q = ((»() -> 1«)) ); } diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/lambdas/context/assigned to unresolved parameter.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/lambdas/context/assigned to unresolved parameter.sdstest index 1f6db20d..9ef52e47 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/lambdas/context/assigned to unresolved parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/lambdas/context/assigned to unresolved parameter.sdstest @@ -3,18 +3,18 @@ package tests.validation.other.expressions.lambdas.context.assignedToUnresolvedP fun myFunction() pipeline unresolvedParameter { - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." myFunction(»() {}«); - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." myFunction(»() -> 1«); - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." myFunction(unresolved = »() {}«); - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." myFunction(unresolved = »() -> 1«); - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." unresolved(»() {}«); - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." unresolved(»() -> 1«); } diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/lambdas/context/assigned to untyped parameter.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/lambdas/context/assigned to untyped parameter.sdstest index 4a9b77d5..0e2b3cde 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/lambdas/context/assigned to untyped parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/lambdas/context/assigned to untyped parameter.sdstest @@ -6,59 +6,59 @@ package tests.validation.other.expressions.lambdas.context.assignedToUntypedPara @Repeatable annotation MyAnnotation( - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." f = (»() {}«), - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." g = »() -> 1« ) class MyClass( - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." f = (»() {}«), - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." g = »() -> 1« ) enum MyEnum { MyEnumVariant( - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." f = (»() {}«), - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." g = »() -> 1« ) } fun myFunction( - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." f = (»() {}«), - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." g = »() -> 1« ) segment mySegment1( - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." f = (»() {}«), - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." g = »() -> 1« ) {} segment mySegment2( - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." f: (p = (»() {}«)) -> (), - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." g: (p = »() -> 1«) -> (), ) { ( - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." f = (»() {}«), - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." g = »() -> 1« ) {}; ( - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." f = (»() {}«), - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." g = »() -> 1« ) -> 1; } @@ -68,15 +68,15 @@ segment mySegment2( */ @MyAnnotation( - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." (»() {}«), - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." »() -> 1« ) @MyAnnotation( - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." f = (»() {}«), - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." g = »() -> 1« ) segment lambdasPassedAsArguments( @@ -86,106 +86,106 @@ segment lambdasPassedAsArguments( val expressionLambda = (p, q) -> 1; MyAnnotation( - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." (»() {}«), - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." »() -> 1« ); MyAnnotation( - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." f = (»() {}«), - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." g = »() -> 1« ); MyClass( - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." (»() {}«), - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." »() -> 1« ); MyClass( - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." f = (»() {}«), - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." g = »() -> 1« ); MyEnum.MyEnumVariant( - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." (»() {}«), - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." »() -> 1« ); MyEnum.MyEnumVariant( - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." f = (»() {}«), - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." g = »() -> 1« ); myFunction( - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." (»() {}«), - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." »() -> 1« ); myFunction( - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." f = (»() {}«), - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." g = »() -> 1« ); mySegment1( - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." (»() {}«), - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." »() -> 1« ); mySegment1( - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." f = (»() {}«), - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." g = »() -> 1« ); callableType( - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." (»() {}«), - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." »() -> 1« ); callableType( - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." p = (»() {}«), - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." q = »() -> 1« ); blockLambda( - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." (»() {}«), - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." »() -> 1« ); blockLambda( - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." p = (»() {}«), - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." q = »() -> 1« ); expressionLambda( - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." (»() {}«), - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." »() -> 1« ); expressionLambda( - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." p = (»() {}«), - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." q = »() -> 1« ); } diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/lambdas/context/invalid context.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/lambdas/context/invalid context.sdstest index 192f8fea..53a576ef 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/lambdas/context/invalid context.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/lambdas/context/invalid context.sdstest @@ -1,16 +1,16 @@ package tests.validation.other.expressions.lambdas.context.invalidContext pipeline invalidContext { - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." »() {}«; - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." »() -> 1«; - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." (»() {}«)(); - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." (»() -> 1«)(); - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." val a = »() {}«; - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." val b = »() -> 1«; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/member accesses/enum variant must be instantiated/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/member accesses/enum variant must be instantiated/main.sdstest index 48e97648..f6c890f5 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/member accesses/enum variant must be instantiated/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/member accesses/enum variant must be instantiated/main.sdstest @@ -8,43 +8,43 @@ enum MyEnum { } pipeline test { - // $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." + # $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." MyEnum.»EnumVariantWithoutParameterList«; - // $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." + # $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." MyEnum.»EnumVariantWithoutParameterList«(); - // $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." + # $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." val alias1 = MyEnum.EnumVariantWithoutParameterList; »alias1«; - // $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." + # $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." MyEnum.»EnumVariantWithEmptyParameterList«; - // $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." + # $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." MyEnum.»EnumVariantWithEmptyParameterList«(); - // $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." + # $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." val alias2 = MyEnum.EnumVariantWithEmptyParameterList; »alias2«; - // $TEST$ error "The enum variant 'EnumVariantWithoutRequiredParameters' has parameters, so an argument list must be added." + # $TEST$ error "The enum variant 'EnumVariantWithoutRequiredParameters' has parameters, so an argument list must be added." MyEnum.»EnumVariantWithoutRequiredParameters«; - // $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." + # $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." MyEnum.»EnumVariantWithoutRequiredParameters«(); - // $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." + # $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." val alias3 = MyEnum.EnumVariantWithoutRequiredParameters; »alias3«; - // $TEST$ error "The enum variant 'EnumVariantWithRequiredParameters' has parameters, so an argument list must be added." + # $TEST$ error "The enum variant 'EnumVariantWithRequiredParameters' has parameters, so an argument list must be added." MyEnum.»EnumVariantWithRequiredParameters«; - // $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." + # $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." MyEnum.»EnumVariantWithRequiredParameters«(); - // $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." + # $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." val alias4 = MyEnum.EnumVariantWithRequiredParameters; »alias4«; - // $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." + # $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." MyEnum.»Unresolved«; - // $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." + # $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." MyEnum.»Unresolved«(); - // $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." + # $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." val alias5 = MyEnum.Unresolved; »alias5«; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/references/function pointer/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/references/function pointer/main.sdstest index e5a957ba..b2cf5d7f 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/references/function pointer/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/references/function pointer/main.sdstest @@ -11,58 +11,58 @@ fun myFunction2(p: Any) segment mySegment1() {} segment mySegment2() { - // $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + # $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." MyClass().»myInstanceMethod«; - // $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + # $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." MyClass().»myInstanceMethod«.a; - // $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + # $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." MyClass().»myInstanceMethod«.a(); - // $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + # $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." myFunction2(MyClass().»myInstanceMethod«); - // $TEST$ no error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + # $TEST$ no error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." MyClass().»myInstanceMethod«(); - // $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + # $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." MyClass.»myStaticMethod«; - // $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + # $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." MyClass.»myStaticMethod«.a; - // $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + # $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." MyClass.»myStaticMethod«.a(); - // $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + # $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." myFunction2(MyClass.»myStaticMethod«); - // $TEST$ no error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + # $TEST$ no error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." MyClass.»myStaticMethod«(); - // $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + # $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." »myFunction1«; - // $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + # $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." »myFunction1«.a; - // $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + # $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." »myFunction1«.a(); - // $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + # $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." myFunction2(»myFunction1«); - // $TEST$ no error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + # $TEST$ no error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." »myFunction1«(); - // $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + # $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." »mySegment1«; - // $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + # $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." »mySegment1«.a; - // $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + # $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." »mySegment1«.a(); - // $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + # $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." myFunction2(»mySegment1«); - // $TEST$ no error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + # $TEST$ no error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." »mySegment1«(); - // $TEST$ no error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + # $TEST$ no error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." »unresolved«; - // $TEST$ no error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + # $TEST$ no error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." »unresolved«.a; - // $TEST$ no error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + # $TEST$ no error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." »unresolved«.a(); - // $TEST$ no error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + # $TEST$ no error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." myFunction2(»unresolved«); - // $TEST$ no error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + # $TEST$ no error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." »unresolved«(); } diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/references/static class reference/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/references/static class reference/main.sdstest index 729e2e53..547e928b 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/references/static class reference/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/references/static class reference/main.sdstest @@ -15,30 +15,30 @@ class ClassWithStaticMembers { } pipeline test { - // $TEST$ no error "A class must not be statically referenced." + # $TEST$ no error "A class must not be statically referenced." »Unresolved«; - // $TEST$ error "A class must not be statically referenced." + # $TEST$ error "A class must not be statically referenced." »ClassWithConstructor«; - // $TEST$ error "A class must not be statically referenced." + # $TEST$ error "A class must not be statically referenced." »ClassWithoutConstructor«; - // $TEST$ no error "A class must not be statically referenced." + # $TEST$ no error "A class must not be statically referenced." »ClassWithoutConstructor«(); - // $TEST$ no error "A class must not be statically referenced." + # $TEST$ no error "A class must not be statically referenced." »ClassWithConstructor«(); - // $TEST$ no error "A class must not be statically referenced." + # $TEST$ no error "A class must not be statically referenced." »ClassWithStaticMembers«.myAttribute; - // $TEST$ no error "A class must not be statically referenced." + # $TEST$ no error "A class must not be statically referenced." »ClassWithStaticMembers«.unresolved; - // $TEST$ no error "A class must not be statically referenced." - // $TEST$ error "A class must not be statically referenced." + # $TEST$ no error "A class must not be statically referenced." + # $TEST$ error "A class must not be statically referenced." »ClassWithStaticMembers«.»InnerClassWithConstructor«; - // $TEST$ no error "A class must not be statically referenced." - // $TEST$ error "A class must not be statically referenced." + # $TEST$ no error "A class must not be statically referenced." + # $TEST$ error "A class must not be statically referenced." »ClassWithStaticMembers«.»InnerClassWithoutConstructor«; - // $TEST$ no error "A class must not be statically referenced." - // $TEST$ no error "A class must not be statically referenced." + # $TEST$ no error "A class must not be statically referenced." + # $TEST$ no error "A class must not be statically referenced." »ClassWithStaticMembers«.»InnerClassWithConstructor«(); - // $TEST$ no error "A class must not be statically referenced." - // $TEST$ no error "A class must not be statically referenced." + # $TEST$ no error "A class must not be statically referenced." + # $TEST$ no error "A class must not be statically referenced." »ClassWithStaticMembers«.»InnerClassWithConstructor«.myAttribute; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/references/static enum reference/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/references/static enum reference/main.sdstest index 60fc554a..9b9a3ed5 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/references/static enum reference/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/references/static enum reference/main.sdstest @@ -17,22 +17,22 @@ class ClassWithEnum { } pipeline test { - // $TEST$ no error "An enum must not be statically referenced." + # $TEST$ no error "An enum must not be statically referenced." »Unresolved«; - // $TEST$ error "An enum must not be statically referenced." + # $TEST$ error "An enum must not be statically referenced." »Enum«; - // $TEST$ no error "An enum must not be statically referenced." + # $TEST$ no error "An enum must not be statically referenced." »Enum«(); - // $TEST$ no error "An enum must not be statically referenced." + # $TEST$ no error "An enum must not be statically referenced." »Enum«.Variant; - // $TEST$ no error "An enum must not be statically referenced." + # $TEST$ no error "An enum must not be statically referenced." »Enum«.unresolved; - // $TEST$ error "An enum must not be statically referenced." + # $TEST$ error "An enum must not be statically referenced." ClassWithEnum.»Enum«; - // $TEST$ no error "An enum must not be statically referenced." + # $TEST$ no error "An enum must not be statically referenced." ClassWithEnum.»Enum«.Variant; - // $TEST$ error "An enum must not be statically referenced." + # $TEST$ error "An enum must not be statically referenced." ClassWithEnum.ClassWithEnum.»Enum«; - // $TEST$ no error "An enum must not be statically referenced." + # $TEST$ no error "An enum must not be statically referenced." ClassWithEnum.ClassWithEnum.»Enum«.Variant; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/references/target/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/references/target/main.sdstest index 1d2b7fac..e8f144f8 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/references/target/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/references/target/main.sdstest @@ -7,12 +7,12 @@ pipeline myPipeline {} schema MySchema {} segment mySegment() { - // $TEST$ error "An annotation must not be the target of a reference." + # $TEST$ error "An annotation must not be the target of a reference." »MyAnnotation«; - // $TEST$ error "A pipeline must not be the target of a reference." + # $TEST$ error "A pipeline must not be the target of a reference." »myPipeline«; - // $TEST$ error "A schema must not be the target of a reference." + # $TEST$ error "A schema must not be the target of a reference." »MySchema«; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/template strings/missing template expression/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/template strings/missing template expression/main.sdstest index 4e394d56..ddda7c84 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/template strings/missing template expression/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/template strings/missing template expression/main.sdstest @@ -1,11 +1,11 @@ package tests.validation.other.expressions.templateStrings.missingTemplateExpression pipeline test { - // $TEST$ error "There must be an expression between two string parts." - // $TEST$ error "There must be an expression between two string parts." + # $TEST$ error "There must be an expression between two string parts." + # $TEST$ error "There must be an expression between two string parts." "start {{ »}} inner {{« »}} end"«; - // $TEST$ no error "There must be an expression between two string parts." - // $TEST$ no error "There must be an expression between two string parts." + # $TEST$ no error "There must be an expression between two string parts." + # $TEST$ no error "There must be an expression between two string parts." "start {{ 1 »}} inner {{« 1 »}} end"«; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/imports/main with issues.sdstest b/packages/ttsl-lang/tests/resources/validation/other/imports/main with issues.sdstest index 85cdcf69..b3413319 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/imports/main with issues.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/imports/main with issues.sdstest @@ -1,15 +1,15 @@ package tests.other.imports -// $TEST$ error "The package 'tests.other.imports.missing' does not exist." +# $TEST$ error "The package 'tests.other.imports.missing' does not exist." from »tests.other.imports.missing« import * -// $TEST$ error "The package 'tests.other.imports.missing' does not exist." +# $TEST$ error "The package 'tests.other.imports.missing' does not exist." from »tests.other.imports.missing« import C -// $TEST$ error "The package 'tests.other.imports.missing' does not exist." +# $TEST$ error "The package 'tests.other.imports.missing' does not exist." from »tests.other.imports.missing« import C as D -// $TEST$ warning "The package 'tests.other.imports.empty' is empty." +# $TEST$ warning "The package 'tests.other.imports.empty' is empty." from »tests.other.imports.empty« import * -// $TEST$ warning "The package 'tests.other.imports.empty' is empty." +# $TEST$ warning "The package 'tests.other.imports.empty' is empty." from »tests.other.imports.empty« import C -// $TEST$ warning "The package 'tests.other.imports.empty' is empty." +# $TEST$ warning "The package 'tests.other.imports.empty' is empty." from »tests.other.imports.empty« import C as D diff --git a/packages/ttsl-lang/tests/resources/validation/other/imports/main without issues.sdstest b/packages/ttsl-lang/tests/resources/validation/other/imports/main without issues.sdstest index 193d07a8..5e0b52df 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/imports/main without issues.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/imports/main without issues.sdstest @@ -1,7 +1,7 @@ package tests.other.imports -// $TEST$ no error r"The package '\.*' does not exist\." -// $TEST$ no warning r"The package '\.*' is empty\." +# $TEST$ no error r"The package '\.*' does not exist\." +# $TEST$ no warning r"The package '\.*' is empty\." from tests.other.imports.nonEmpty import * from tests.other.imports.nonEmpty import C diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/declarations in pipeline files/main.sdspipe b/packages/ttsl-lang/tests/resources/validation/other/modules/declarations in pipeline files/main.sdspipe index 522c1778..c4a9678c 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/declarations in pipeline files/main.sdspipe +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/declarations in pipeline files/main.sdspipe @@ -1,33 +1,33 @@ package tests.validation.other.modules.declarationsInPipelineFiles -// $TEST$ error "A pipeline file must only declare pipelines and segments." +# $TEST$ error "A pipeline file must only declare pipelines and segments." annotation »MyAnnotation« -// $TEST$ error "A pipeline file must only declare pipelines and segments." +# $TEST$ error "A pipeline file must only declare pipelines and segments." class »MyClass« { - // $TEST$ no error "A pipeline file must only declare pipelines and segments." + # $TEST$ no error "A pipeline file must only declare pipelines and segments." attr »a«: Int - // $TEST$ no error "A pipeline file must only declare pipelines and segments." + # $TEST$ no error "A pipeline file must only declare pipelines and segments." class »MyNestedClass« - // $TEST$ no error "A pipeline file must only declare pipelines and segments." + # $TEST$ no error "A pipeline file must only declare pipelines and segments." enum »MyEnum« - // $TEST$ no error "A pipeline file must only declare pipelines and segments." + # $TEST$ no error "A pipeline file must only declare pipelines and segments." fun »myFunction«() } -// $TEST$ error "A pipeline file must only declare pipelines and segments." +# $TEST$ error "A pipeline file must only declare pipelines and segments." enum »MyEnum« { - // $TEST$ no error "A pipeline file must only declare pipelines and segments." + # $TEST$ no error "A pipeline file must only declare pipelines and segments." »MyEnumInstance« } -// $TEST$ error "A pipeline file must only declare pipelines and segments." +# $TEST$ error "A pipeline file must only declare pipelines and segments." fun »myFunction«() -// $TEST$ error "A pipeline file must only declare pipelines and segments." +# $TEST$ error "A pipeline file must only declare pipelines and segments." schema »MySchema« {} -// $TEST$ no error "A pipeline file must only declare pipelines and segments." +# $TEST$ no error "A pipeline file must only declare pipelines and segments." pipeline »myPipeline« {} -// $TEST$ no error "A pipeline file must only declare pipelines and segments." +# $TEST$ no error "A pipeline file must only declare pipelines and segments." segment »mySegment«() {} diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/declarations in stub files/main.sdsstub b/packages/ttsl-lang/tests/resources/validation/other/modules/declarations in stub files/main.sdsstub index 29a5e436..dc1967cc 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/declarations in stub files/main.sdsstub +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/declarations in stub files/main.sdsstub @@ -1,33 +1,33 @@ package tests.validation.other.modules.declarationsInStubFiles -// $TEST$ error "A stub file must not declare pipelines or segments." +# $TEST$ error "A stub file must not declare pipelines or segments." pipeline »myPipeline« {} -// $TEST$ error "A stub file must not declare pipelines or segments." +# $TEST$ error "A stub file must not declare pipelines or segments." segment »mySegment«() {} -// $TEST$ no error "A stub file must not declare pipelines or segments." +# $TEST$ no error "A stub file must not declare pipelines or segments." annotation »MyAnnotation« -// $TEST$ no error "A stub file must not declare pipelines or segments." +# $TEST$ no error "A stub file must not declare pipelines or segments." class »MyClass« { - // $TEST$ no error "A stub file must not declare pipelines or segments." + # $TEST$ no error "A stub file must not declare pipelines or segments." attr »a«: Int - // $TEST$ no error "A stub file must not declare pipelines or segments." + # $TEST$ no error "A stub file must not declare pipelines or segments." class »MyNestedClass« - // $TEST$ no error "A stub file must not declare pipelines or segments." + # $TEST$ no error "A stub file must not declare pipelines or segments." enum »MyEnum« - // $TEST$ no error "A stub file must not declare pipelines or segments." + # $TEST$ no error "A stub file must not declare pipelines or segments." fun »myFunction«() } -// $TEST$ no error "A stub file must not declare pipelines or segments." +# $TEST$ no error "A stub file must not declare pipelines or segments." enum »MyEnum« { - // $TEST$ no error "A stub file must not declare pipelines or segments." + # $TEST$ no error "A stub file must not declare pipelines or segments." »MyEnumInstance« } -// $TEST$ no error "A stub file must not declare pipelines or segments." +# $TEST$ no error "A stub file must not declare pipelines or segments." fun »myFunction«() -// $TEST$ no error "A stub file must not declare pipelines or segments." +# $TEST$ no error "A stub file must not declare pipelines or segments." schema »MySchema« {} diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/declarations in test files/everything is allowed (no pipeline errors).sdstest b/packages/ttsl-lang/tests/resources/validation/other/modules/declarations in test files/everything is allowed (no pipeline errors).sdstest index d5fe1da7..5524fd2f 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/declarations in test files/everything is allowed (no pipeline errors).sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/declarations in test files/everything is allowed (no pipeline errors).sdstest @@ -1,33 +1,33 @@ package tests.validation.other.modules.declarationsInTestFiles -// $TEST$ no error "A pipeline file must only declare pipelines and segments." +# $TEST$ no error "A pipeline file must only declare pipelines and segments." annotation »MyAnnotation« -// $TEST$ no error "A pipeline file must only declare pipelines and segments." +# $TEST$ no error "A pipeline file must only declare pipelines and segments." class »MyClass« { - // $TEST$ no error "A pipeline file must only declare pipelines and segments." + # $TEST$ no error "A pipeline file must only declare pipelines and segments." attr »a«: Int - // $TEST$ no error "A pipeline file must only declare pipelines and segments." + # $TEST$ no error "A pipeline file must only declare pipelines and segments." class »MyNestedClass« - // $TEST$ no error "A pipeline file must only declare pipelines and segments." + # $TEST$ no error "A pipeline file must only declare pipelines and segments." enum »MyEnum« - // $TEST$ no error "A pipeline file must only declare pipelines and segments." + # $TEST$ no error "A pipeline file must only declare pipelines and segments." fun »myFunction«() } -// $TEST$ no error "A pipeline file must only declare pipelines and segments." +# $TEST$ no error "A pipeline file must only declare pipelines and segments." enum »MyEnum« { - // $TEST$ no error "A pipeline file must only declare pipelines and segments." + # $TEST$ no error "A pipeline file must only declare pipelines and segments." »MyEnumInstance« } -// $TEST$ no error "A pipeline file must only declare pipelines and segments." +# $TEST$ no error "A pipeline file must only declare pipelines and segments." fun »myFunction«() -// $TEST$ no error "A pipeline file must only declare pipelines and segments." +# $TEST$ no error "A pipeline file must only declare pipelines and segments." schema »MySchema« {} -// $TEST$ no error "A pipeline file must only declare pipelines and segments." +# $TEST$ no error "A pipeline file must only declare pipelines and segments." pipeline »myPipeline« {} -// $TEST$ no error "A pipeline file must only declare pipelines and segments." +# $TEST$ no error "A pipeline file must only declare pipelines and segments." segment »mySegment«() {} diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/declarations in test files/everything is allowed (no stub errors).sdstest b/packages/ttsl-lang/tests/resources/validation/other/modules/declarations in test files/everything is allowed (no stub errors).sdstest index cae23b56..70fa2ca0 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/declarations in test files/everything is allowed (no stub errors).sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/declarations in test files/everything is allowed (no stub errors).sdstest @@ -1,33 +1,33 @@ package tests.validation.other.modules.declarationsInTestFiles -// $TEST$ no error "A stub file must not declare pipelines or segments." +# $TEST$ no error "A stub file must not declare pipelines or segments." pipeline »myPipeline« {} -// $TEST$ no error "A stub file must not declare pipelines or segments." +# $TEST$ no error "A stub file must not declare pipelines or segments." segment »mySegment«() {} -// $TEST$ no error "A stub file must not declare pipelines or segments." +# $TEST$ no error "A stub file must not declare pipelines or segments." annotation »MyAnnotation« -// $TEST$ no error "A stub file must not declare pipelines or segments." +# $TEST$ no error "A stub file must not declare pipelines or segments." class »MyClass« { - // $TEST$ no error "A stub file must not declare pipelines or segments." + # $TEST$ no error "A stub file must not declare pipelines or segments." attr »a«: Int - // $TEST$ no error "A stub file must not declare pipelines or segments." + # $TEST$ no error "A stub file must not declare pipelines or segments." class »MyNestedClass« - // $TEST$ no error "A stub file must not declare pipelines or segments." + # $TEST$ no error "A stub file must not declare pipelines or segments." enum »MyEnum« - // $TEST$ no error "A stub file must not declare pipelines or segments." + # $TEST$ no error "A stub file must not declare pipelines or segments." fun »myFunction«() } -// $TEST$ no error "A stub file must not declare pipelines or segments." +# $TEST$ no error "A stub file must not declare pipelines or segments." enum »MyEnum« { - // $TEST$ no error "A stub file must not declare pipelines or segments." + # $TEST$ no error "A stub file must not declare pipelines or segments." »MyEnumInstance« } -// $TEST$ no error "A stub file must not declare pipelines or segments." +# $TEST$ no error "A stub file must not declare pipelines or segments." fun »myFunction«() -// $TEST$ no error "A stub file must not declare pipelines or segments." +# $TEST$ no error "A stub file must not declare pipelines or segments." schema »MySchema« {} diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (empty).sdspipe b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (empty).sdspipe index 27af28cb..1efef064 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (empty).sdspipe +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (empty).sdspipe @@ -1 +1 @@ -// $TEST$ no error "A module with declarations must state its package." +# $TEST$ no error "A module with declarations must state its package." diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (only annotations).sdspipe b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (only annotations).sdspipe index d78842d9..7583c76e 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (only annotations).sdspipe +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (only annotations).sdspipe @@ -1,3 +1,3 @@ -// $TEST$ no error "A module with declarations must state its package." +# $TEST$ no error "A module with declarations must state its package." @AnnotationCall diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (only imports).sdspipe b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (only imports).sdspipe index d27d113d..15f5d970 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (only imports).sdspipe +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (only imports).sdspipe @@ -1,3 +1,3 @@ -// $TEST$ no error "A module with declarations must state its package." +# $TEST$ no error "A module with declarations must state its package." from myPackage import MyClass diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (with declarations and package).sdspipe b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (with declarations and package).sdspipe index 6f4bf0ff..fd8c0c92 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (with declarations and package).sdspipe +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (with declarations and package).sdspipe @@ -1,7 +1,7 @@ package tests.validation.other.modules.mustStatePackage -// $TEST$ no error "A module with declarations must state its package." +# $TEST$ no error "A module with declarations must state its package." segment »s«() {} -// $TEST$ no error "A module with declarations must state its package." +# $TEST$ no error "A module with declarations must state its package." segment »t«() {} diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (with declarations but no package).sdspipe b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (with declarations but no package).sdspipe index a55723f4..192ad2b2 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (with declarations but no package).sdspipe +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (with declarations but no package).sdspipe @@ -1,5 +1,5 @@ -// $TEST$ error "A module with declarations must state its package." +# $TEST$ error "A module with declarations must state its package." segment »s«() {} -// $TEST$ no error "A module with declarations must state its package." +# $TEST$ no error "A module with declarations must state its package." segment »t«() {} diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (empty).sdsstub b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (empty).sdsstub index 27af28cb..1efef064 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (empty).sdsstub +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (empty).sdsstub @@ -1 +1 @@ -// $TEST$ no error "A module with declarations must state its package." +# $TEST$ no error "A module with declarations must state its package." diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (only annotations).sdsstub b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (only annotations).sdsstub index d78842d9..7583c76e 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (only annotations).sdsstub +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (only annotations).sdsstub @@ -1,3 +1,3 @@ -// $TEST$ no error "A module with declarations must state its package." +# $TEST$ no error "A module with declarations must state its package." @AnnotationCall diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (only imports).sdsstub b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (only imports).sdsstub index d27d113d..15f5d970 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (only imports).sdsstub +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (only imports).sdsstub @@ -1,3 +1,3 @@ -// $TEST$ no error "A module with declarations must state its package." +# $TEST$ no error "A module with declarations must state its package." from myPackage import MyClass diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (with declarations and package).sdsstub b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (with declarations and package).sdsstub index 0a9fbaa5..80ece2d4 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (with declarations and package).sdsstub +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (with declarations and package).sdsstub @@ -1,7 +1,7 @@ package tests.validation.other.modules.mustStatePackage -// $TEST$ no error "A module with declarations must state its package." +# $TEST$ no error "A module with declarations must state its package." class »C« -// $TEST$ no error "A module with declarations must state its package." +# $TEST$ no error "A module with declarations must state its package." class »D« diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (with declarations but no package).sdsstub b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (with declarations but no package).sdsstub index ca0e6e42..1064b7c2 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (with declarations but no package).sdsstub +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (with declarations but no package).sdsstub @@ -1,5 +1,5 @@ -// $TEST$ error "A module with declarations must state its package." +# $TEST$ error "A module with declarations must state its package." class »C« -// $TEST$ no error "A module with declarations must state its package." +# $TEST$ no error "A module with declarations must state its package." class »D« diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/pipe elsewhere.sdspipe b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/pipe elsewhere.sdspipe index f193b218..edad3c9d 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/pipe elsewhere.sdspipe +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/pipe elsewhere.sdspipe @@ -1,3 +1,3 @@ -// $TEST$ no error "A pipeline file must not be in a 'safeds' package." +# $TEST$ no error "A pipeline file must not be in a 'safeds' package." package »tests.validation.other.modules.pipelineFilesMustNotBeInSafedsPackage« diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/pipe in safeds.sdspipe b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/pipe in safeds.sdspipe index 01bbbb02..77a115e4 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/pipe in safeds.sdspipe +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/pipe in safeds.sdspipe @@ -1,3 +1,3 @@ -// $TEST$ error "A pipeline file must not be in a 'safeds' package." +# $TEST$ error "A pipeline file must not be in a 'safeds' package." package »safeds« diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/pipe in subpackage of safeds.sdspipe b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/pipe in subpackage of safeds.sdspipe index 84d64908..55feddd3 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/pipe in subpackage of safeds.sdspipe +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/pipe in subpackage of safeds.sdspipe @@ -1,3 +1,3 @@ -// $TEST$ error "A pipeline file must not be in a 'safeds' package." +# $TEST$ error "A pipeline file must not be in a 'safeds' package." package »safeds.validation.other.modules.pipelineFilesMustNotBeInSafedsPackage« diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/stub elsewhere.sdsstub b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/stub elsewhere.sdsstub index f193b218..edad3c9d 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/stub elsewhere.sdsstub +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/stub elsewhere.sdsstub @@ -1,3 +1,3 @@ -// $TEST$ no error "A pipeline file must not be in a 'safeds' package." +# $TEST$ no error "A pipeline file must not be in a 'safeds' package." package »tests.validation.other.modules.pipelineFilesMustNotBeInSafedsPackage« diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/stub in safeds.sdsstub b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/stub in safeds.sdsstub index 07eecbb3..91ef8016 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/stub in safeds.sdsstub +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/stub in safeds.sdsstub @@ -1,3 +1,3 @@ -// $TEST$ no error "A pipeline file must not be in a 'safeds' package." +# $TEST$ no error "A pipeline file must not be in a 'safeds' package." package »safeds« diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/stub in subpackage of safeds.sdsstub b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/stub in subpackage of safeds.sdsstub index 0724b7d8..c263943e 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/stub in subpackage of safeds.sdsstub +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/stub in subpackage of safeds.sdsstub @@ -1,3 +1,3 @@ -// $TEST$ no error "A pipeline file must not be in a 'safeds' package." +# $TEST$ no error "A pipeline file must not be in a 'safeds' package." package »safeds.validation.other.modules.pipelineFilesMustNotBeInSafedsPackage« diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/test elsewhere.sdstest b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/test elsewhere.sdstest index f193b218..edad3c9d 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/test elsewhere.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/test elsewhere.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no error "A pipeline file must not be in a 'safeds' package." +# $TEST$ no error "A pipeline file must not be in a 'safeds' package." package »tests.validation.other.modules.pipelineFilesMustNotBeInSafedsPackage« diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/test in safeds.sdstest b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/test in safeds.sdstest index 07eecbb3..91ef8016 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/test in safeds.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/test in safeds.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no error "A pipeline file must not be in a 'safeds' package." +# $TEST$ no error "A pipeline file must not be in a 'safeds' package." package »safeds« diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/test in subpackage of safeds.sdstest b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/test in subpackage of safeds.sdstest index 0724b7d8..c263943e 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/test in subpackage of safeds.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/test in subpackage of safeds.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no error "A pipeline file must not be in a 'safeds' package." +# $TEST$ no error "A pipeline file must not be in a 'safeds' package." package »safeds.validation.other.modules.pipelineFilesMustNotBeInSafedsPackage« diff --git a/packages/ttsl-lang/tests/resources/validation/other/statements/assignments/has no effect/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/statements/assignments/has no effect/main.sdstest index 10702000..b6aa8c0f 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/statements/assignments/has no effect/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/statements/assignments/has no effect/main.sdstest @@ -1,29 +1,29 @@ package tests.validation.other.statements.assignments.hasNoEffect segment mySegment() -> a: Int { - // $TEST$ warning "This statement does nothing." + # $TEST$ warning "This statement does nothing." »_ = 1 + 2;« - // $TEST$ no warning "This statement does nothing." + # $TEST$ no warning "This statement does nothing." »val a = 1;« - // $TEST$ no warning "This statement does nothing." + # $TEST$ no warning "This statement does nothing." »yield a = 1;« () { - // $TEST$ warning "This statement does nothing." + # $TEST$ warning "This statement does nothing." »_ = 1 + 2;« - // $TEST$ no warning "This statement does nothing." + # $TEST$ no warning "This statement does nothing." »val a = 1;« - // $TEST$ no warning "This statement does nothing." + # $TEST$ no warning "This statement does nothing." »yield a = 1;« }; } segment mySegment2(f: () -> (r: Int)) { - // $TEST$ no warning "This statement does nothing." + # $TEST$ no warning "This statement does nothing." »_ = f();« - // $TEST$ no warning "This statement does nothing." + # $TEST$ no warning "This statement does nothing." »_ = unresolved();« } diff --git a/packages/ttsl-lang/tests/resources/validation/other/statements/assignments/implicitly ignore result/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/statements/assignments/implicitly ignore result/main.sdstest index 1747c2f1..9b325710 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/statements/assignments/implicitly ignore result/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/statements/assignments/implicitly ignore result/main.sdstest @@ -12,41 +12,41 @@ enum MyEnum { } pipeline myPipeline { - // $TEST$ warning "The assignment implicitly ignores the result 'second'." + # $TEST$ warning "The assignment implicitly ignores the result 'second'." »_ = twoResults();« - // $TEST$ warning "The assignment implicitly ignores the results 'second', 'third'." + # $TEST$ warning "The assignment implicitly ignores the results 'second', 'third'." »_ = threeResults();« - // $TEST$ no warning r"The assignment implicitly ignores the result\.*" + # $TEST$ no warning r"The assignment implicitly ignores the result\.*" »_ = oneResult();« - // $TEST$ no warning r"The assignment implicitly ignores the result\.*" + # $TEST$ no warning r"The assignment implicitly ignores the result\.*" »_, _ = twoResults();« - // $TEST$ no warning r"The assignment implicitly ignores the result\.*" + # $TEST$ no warning r"The assignment implicitly ignores the result\.*" »_, _, _ = threeResults();« - // $TEST$ no warning r"The assignment implicitly ignores the result\.*" + # $TEST$ no warning r"The assignment implicitly ignores the result\.*" »_ = MyClass();« - // $TEST$ no warning r"The assignment implicitly ignores the result\.*" + # $TEST$ no warning r"The assignment implicitly ignores the result\.*" »_ = MyEnum.MyEnumVariant();« - // $TEST$ no warning r"The assignment implicitly ignores the result\.*" + # $TEST$ no warning r"The assignment implicitly ignores the result\.*" »_ = 1;« - // $TEST$ no warning r"The assignment implicitly ignores the result\.*" + # $TEST$ no warning r"The assignment implicitly ignores the result\.*" »_ = noResults();« - // $TEST$ no warning r"The assignment implicitly ignores the result\.*" + # $TEST$ no warning r"The assignment implicitly ignores the result\.*" »_, _ = oneResult();« - // $TEST$ no warning r"The assignment implicitly ignores the result\.*" + # $TEST$ no warning r"The assignment implicitly ignores the result\.*" »_, _, _ = twoResults();« - // $TEST$ no warning r"The assignment implicitly ignores the result\.*" + # $TEST$ no warning r"The assignment implicitly ignores the result\.*" »_, _, _, _ = threeResults();« - // $TEST$ no warning r"The assignment implicitly ignores the result\.*" + # $TEST$ no warning r"The assignment implicitly ignores the result\.*" »_, _ = MyClass();« - // $TEST$ no warning r"The assignment implicitly ignores the result\.*" + # $TEST$ no warning r"The assignment implicitly ignores the result\.*" »_, _ = MyEnum.MyEnumVariant();« - // $TEST$ no warning r"The assignment implicitly ignores the result\.*" + # $TEST$ no warning r"The assignment implicitly ignores the result\.*" »_, _ = 1;« - // $TEST$ no warning r"The assignment implicitly ignores the result\.*" + # $TEST$ no warning r"The assignment implicitly ignores the result\.*" »_ = unresolved;« - // $TEST$ no warning r"The assignment implicitly ignores the result\.*" + # $TEST$ no warning r"The assignment implicitly ignores the result\.*" »_ = unresolved();« } diff --git a/packages/ttsl-lang/tests/resources/validation/other/statements/assignments/nothing assigned/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/statements/assignments/nothing assigned/main.sdstest index c0c6a2be..3c04d43a 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/statements/assignments/nothing assigned/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/statements/assignments/nothing assigned/main.sdstest @@ -26,78 +26,78 @@ segment mySegment() -> ( r13: Any?, r14: Any?, ) { - // $TEST$ error "No value is assigned to this assignee." + # $TEST$ error "No value is assigned to this assignee." »_« = noResults(); - // $TEST$ no error "No value is assigned to this assignee." - // $TEST$ error "No value is assigned to this assignee." + # $TEST$ no error "No value is assigned to this assignee." + # $TEST$ error "No value is assigned to this assignee." »_«, »_« = oneResult(); - // $TEST$ no error "No value is assigned to this assignee." - // $TEST$ no error "No value is assigned to this assignee." - // $TEST$ error "No value is assigned to this assignee." + # $TEST$ no error "No value is assigned to this assignee." + # $TEST$ no error "No value is assigned to this assignee." + # $TEST$ error "No value is assigned to this assignee." »_«, »_«, »_« = twoResults(); - // $TEST$ no error "No value is assigned to this assignee." - // $TEST$ error "No value is assigned to this assignee." + # $TEST$ no error "No value is assigned to this assignee." + # $TEST$ error "No value is assigned to this assignee." »_«, »_« = MyClass(); - // $TEST$ no error "No value is assigned to this assignee." - // $TEST$ error "No value is assigned to this assignee." + # $TEST$ no error "No value is assigned to this assignee." + # $TEST$ error "No value is assigned to this assignee." »_«, »_« = MyEnum.MyEnumVariant(); - // $TEST$ no error "No value is assigned to this assignee." - // $TEST$ error "No value is assigned to this assignee." + # $TEST$ no error "No value is assigned to this assignee." + # $TEST$ error "No value is assigned to this assignee." »_«, »_« = 1; - // $TEST$ no error "No value is assigned to this assignee." - // $TEST$ error "No value is assigned to this assignee." + # $TEST$ no error "No value is assigned to this assignee." + # $TEST$ error "No value is assigned to this assignee." »_«, »_« = unresolved; - // $TEST$ error "No value is assigned to this assignee." - // $TEST$ error "No value is assigned to this assignee." + # $TEST$ error "No value is assigned to this assignee." + # $TEST$ error "No value is assigned to this assignee." »_«, »_« = unresolved(); - // $TEST$ error "No value is assigned to this assignee." + # $TEST$ error "No value is assigned to this assignee." »val a« = noResults(); - // $TEST$ no error "No value is assigned to this assignee." - // $TEST$ error "No value is assigned to this assignee." + # $TEST$ no error "No value is assigned to this assignee." + # $TEST$ error "No value is assigned to this assignee." »val b«, »val c« = oneResult(); - // $TEST$ no error "No value is assigned to this assignee." - // $TEST$ no error "No value is assigned to this assignee." - // $TEST$ error "No value is assigned to this assignee." + # $TEST$ no error "No value is assigned to this assignee." + # $TEST$ no error "No value is assigned to this assignee." + # $TEST$ error "No value is assigned to this assignee." »val d«, »val e«, »val f« = twoResults(); - // $TEST$ no error "No value is assigned to this assignee." - // $TEST$ error "No value is assigned to this assignee." + # $TEST$ no error "No value is assigned to this assignee." + # $TEST$ error "No value is assigned to this assignee." »val g«, »val h« = MyClass(); - // $TEST$ no error "No value is assigned to this assignee." - // $TEST$ error "No value is assigned to this assignee." + # $TEST$ no error "No value is assigned to this assignee." + # $TEST$ error "No value is assigned to this assignee." »val i«, »val j« = MyEnum.MyEnumVariant(); - // $TEST$ no error "No value is assigned to this assignee." - // $TEST$ error "No value is assigned to this assignee." + # $TEST$ no error "No value is assigned to this assignee." + # $TEST$ error "No value is assigned to this assignee." »val k«, »val l« = 1; - // $TEST$ no error "No value is assigned to this assignee." - // $TEST$ error "No value is assigned to this assignee." + # $TEST$ no error "No value is assigned to this assignee." + # $TEST$ error "No value is assigned to this assignee." »val m«, »val n« = unresolved; - // $TEST$ error "No value is assigned to this assignee." - // $TEST$ error "No value is assigned to this assignee." + # $TEST$ error "No value is assigned to this assignee." + # $TEST$ error "No value is assigned to this assignee." »val o«, »val p« = unresolved(); - // $TEST$ error "No value is assigned to this assignee." + # $TEST$ error "No value is assigned to this assignee." »yield r1« = noResults(); - // $TEST$ no error "No value is assigned to this assignee." - // $TEST$ error "No value is assigned to this assignee." + # $TEST$ no error "No value is assigned to this assignee." + # $TEST$ error "No value is assigned to this assignee." »yield r2«, »yield r3« = oneResult(); - // $TEST$ no error "No value is assigned to this assignee." - // $TEST$ no error "No value is assigned to this assignee." - // $TEST$ error "No value is assigned to this assignee." + # $TEST$ no error "No value is assigned to this assignee." + # $TEST$ no error "No value is assigned to this assignee." + # $TEST$ error "No value is assigned to this assignee." »yield r4«, »yield r5«, »yield r6« = twoResults(); - // $TEST$ no error "No value is assigned to this assignee." - // $TEST$ error "No value is assigned to this assignee." + # $TEST$ no error "No value is assigned to this assignee." + # $TEST$ error "No value is assigned to this assignee." »yield r7«, »yield r8« = MyClass(); - // $TEST$ no error "No value is assigned to this assignee." - // $TEST$ error "No value is assigned to this assignee." + # $TEST$ no error "No value is assigned to this assignee." + # $TEST$ error "No value is assigned to this assignee." »yield r9«, »yield r10« = MyEnum.MyEnumVariant(); - // $TEST$ no error "No value is assigned to this assignee." - // $TEST$ error "No value is assigned to this assignee." + # $TEST$ no error "No value is assigned to this assignee." + # $TEST$ error "No value is assigned to this assignee." »yield r11«, »yield r12« = 1; - // $TEST$ no error "No value is assigned to this assignee." - // $TEST$ error "No value is assigned to this assignee." + # $TEST$ no error "No value is assigned to this assignee." + # $TEST$ error "No value is assigned to this assignee." »yield r13«, »yield r14« = unresolved; - // $TEST$ error "No value is assigned to this assignee." - // $TEST$ error "No value is assigned to this assignee." + # $TEST$ error "No value is assigned to this assignee." + # $TEST$ error "No value is assigned to this assignee." »yield r15«, »yield r16« = unresolved(); } diff --git a/packages/ttsl-lang/tests/resources/validation/other/statements/assignments/yield forbidden in pipeline/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/statements/assignments/yield forbidden in pipeline/main.sdstest index 95bc46e8..d865f0be 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/statements/assignments/yield forbidden in pipeline/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/statements/assignments/yield forbidden in pipeline/main.sdstest @@ -1,16 +1,16 @@ package tests.validation.other.statements.assignments.yieldForbiddenInPipeline segment s() { - // $TEST$ no error "Yield must not be used in a pipeline." + # $TEST$ no error "Yield must not be used in a pipeline." »yield a« = 1; } pipeline p { - // $TEST$ error "Yield must not be used in a pipeline." + # $TEST$ error "Yield must not be used in a pipeline." »yield a« = 1; () { - // $TEST$ no error "Yield must not be used in a pipeline." + # $TEST$ no error "Yield must not be used in a pipeline." »yield a« = 1; }; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/statements/expression statements/has no effect/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/statements/expression statements/has no effect/main.sdstest index 5dcf20fe..c72c2b3d 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/statements/expression statements/has no effect/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/statements/expression statements/has no effect/main.sdstest @@ -30,62 +30,62 @@ segment recursiveB() { } segment mySegment() { - // $TEST$ warning "This statement does nothing." + # $TEST$ warning "This statement does nothing." »1 + 2;« - // $TEST$ warning "This statement does nothing." + # $TEST$ warning "This statement does nothing." »pureFunction();« - // $TEST$ warning "This statement does nothing." + # $TEST$ warning "This statement does nothing." »MyClass().pureFunction();« - // $TEST$ no warning "This statement does nothing." + # $TEST$ no warning "This statement does nothing." »impureFunction();« - // $TEST$ no warning "This statement does nothing." + # $TEST$ no warning "This statement does nothing." »MyClass().impureFunction();« () { - // $TEST$ warning "This statement does nothing." + # $TEST$ warning "This statement does nothing." »1 + 2;« - // $TEST$ warning "This statement does nothing." + # $TEST$ warning "This statement does nothing." »pureFunction();« - // $TEST$ warning "This statement does nothing." + # $TEST$ warning "This statement does nothing." »MyClass().pureFunction();« - // $TEST$ no warning "This statement does nothing." + # $TEST$ no warning "This statement does nothing." »impureFunction();« - // $TEST$ no warning "This statement does nothing." + # $TEST$ no warning "This statement does nothing." »MyClass().impureFunction();« }; - // $TEST$ warning "This statement does nothing." + # $TEST$ warning "This statement does nothing." »pureSegment();« - // $TEST$ no warning "This statement does nothing." + # $TEST$ no warning "This statement does nothing." »impureSegment();« - // $TEST$ warning "This statement does nothing." + # $TEST$ warning "This statement does nothing." »(() { pureFunction(); MyClass().pureFunction(); })();« - // $TEST$ no warning "This statement does nothing." + # $TEST$ no warning "This statement does nothing." »(() { impureFunction(); })();« - // $TEST$ no warning "This statement does nothing." + # $TEST$ no warning "This statement does nothing." »(() { MyClass().impureFunction(); })();« - // $TEST$ no warning "This statement does nothing." + # $TEST$ no warning "This statement does nothing." »recursiveA();« } segment mySegment2(f: () -> (r: Int)) { - // $TEST$ no warning "This statement does nothing." + # $TEST$ no warning "This statement does nothing." »f();« - // $TEST$ no warning "This statement does nothing." + # $TEST$ no warning "This statement does nothing." »unresolved();« } diff --git a/packages/ttsl-lang/tests/resources/validation/other/types/callable types/context/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/types/callable types/context/main.sdstest index b166586e..9f2b929c 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/types/callable types/context/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/types/callable types/context/main.sdstest @@ -1,68 +1,68 @@ package tests.validation.other.types.callableTypes.context annotation MyAnnotation( - // $TEST$ no error "Callable types must only be used for parameters." + # $TEST$ no error "Callable types must only be used for parameters." p: »() -> ()«, ) class MyClass( - // $TEST$ no error "Callable types must only be used for parameters." + # $TEST$ no error "Callable types must only be used for parameters." p: »() -> ()«, ) { - // $TEST$ error "Callable types must only be used for parameters." + # $TEST$ error "Callable types must only be used for parameters." attr a: »() -> ()« } enum MyEnum { MyEnumVariant( - // $TEST$ no error "Callable types must only be used for parameters." + # $TEST$ no error "Callable types must only be used for parameters." p: »() -> ()«, ) } fun myFunction( - // $TEST$ no error "Callable types must only be used for parameters." + # $TEST$ no error "Callable types must only be used for parameters." p: »() -> ()«, ) -> ( - // $TEST$ error "Callable types must only be used for parameters." + # $TEST$ error "Callable types must only be used for parameters." r: »() -> ()«, ) segment mySegment1( - // $TEST$ no error "Callable types must only be used for parameters." + # $TEST$ no error "Callable types must only be used for parameters." p: »() -> ()«, ) -> ( - // $TEST$ error "Callable types must only be used for parameters." + # $TEST$ error "Callable types must only be used for parameters." r: »() -> ()«, ) {} segment mySegment2( - // $TEST$ no error "Callable types must only be used for parameters." - // $TEST$ error "Callable types must only be used for parameters." + # $TEST$ no error "Callable types must only be used for parameters." + # $TEST$ error "Callable types must only be used for parameters." c: (p: »() -> ()«) -> (r: »() -> ()«), ) { - // $TEST$ no error "Callable types must only be used for parameters." + # $TEST$ no error "Callable types must only be used for parameters." ( p: »() -> ()«, ) {}; - // $TEST$ no error "Callable types must only be used for parameters." + # $TEST$ no error "Callable types must only be used for parameters." ( p: »() -> ()«, ) -> 1; } segment mySegment3( - // $TEST$ error "Callable types must only be used for parameters." + # $TEST$ error "Callable types must only be used for parameters." p1: MyClass<»() -> ()«>, ) {} segment mySegment4( - // $TEST$ error "Callable types must only be used for parameters." + # $TEST$ error "Callable types must only be used for parameters." p1: »() -> ()«.MyClass ) {} segment mySegment5( - // $TEST$ error "Callable types must only be used for parameters." + # $TEST$ error "Callable types must only be used for parameters." p1: union<»() -> ()«> ) {} diff --git a/packages/ttsl-lang/tests/resources/validation/other/types/callable types/context/nested.sdstest b/packages/ttsl-lang/tests/resources/validation/other/types/callable types/context/nested.sdstest index 3389e2ac..6add3efd 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/types/callable types/context/nested.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/types/callable types/context/nested.sdstest @@ -5,12 +5,12 @@ package tests.validation.other.types.callableTypes.context */ class MyClass1 { - // $TEST$ no error "Callable types must only be used for parameters." + # $TEST$ no error "Callable types must only be used for parameters." attr a: () -> (r: »() -> ()«) } class MyClass2 { - // $TEST$ no error "Callable types must only be used for parameters." - // $TEST$ no error "Callable types must only be used for parameters." + # $TEST$ no error "Callable types must only be used for parameters." + # $TEST$ no error "Callable types must only be used for parameters." attr a: () -> (r: (p: »() -> ()«) -> (r: »() -> ()«)) } diff --git a/packages/ttsl-lang/tests/resources/validation/other/types/callable types/must not have optional parameters/optional.sdstest b/packages/ttsl-lang/tests/resources/validation/other/types/callable types/must not have optional parameters/optional.sdstest index b7e13798..8ce5ad98 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/types/callable types/must not have optional parameters/optional.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/types/callable types/must not have optional parameters/optional.sdstest @@ -2,7 +2,7 @@ package tests.validation.other.types.callableTypes.mustNotHaveOptionalParameters fun f( g: ( - // $TEST$ error "A callable type must not have optional parameters." + # $TEST$ error "A callable type must not have optional parameters." p: Int = »1«, ) -> () ) diff --git a/packages/ttsl-lang/tests/resources/validation/other/types/callable types/must not have optional parameters/required.sdstest b/packages/ttsl-lang/tests/resources/validation/other/types/callable types/must not have optional parameters/required.sdstest index a70ae8c0..68c4f378 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/types/callable types/must not have optional parameters/required.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/types/callable types/must not have optional parameters/required.sdstest @@ -2,7 +2,7 @@ package tests.validation.other.types.callableTypes.mustNotHaveOptionalParameters fun f( g: ( - // $TEST$ no error "A callable type must not have optional parameters." + # $TEST$ no error "A callable type must not have optional parameters." p: Int, ) -> () ) diff --git a/packages/ttsl-lang/tests/resources/validation/other/types/literal types/duplicate literals/empty list.sdstest b/packages/ttsl-lang/tests/resources/validation/other/types/literal types/duplicate literals/empty list.sdstest index ad8a0237..ca1f7cdc 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/types/literal types/duplicate literals/empty list.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/types/literal types/duplicate literals/empty list.sdstest @@ -1,6 +1,6 @@ package tests.validation.other.types.literalTypes.duplicateLiterals -// $TEST$ no warning r"The literal .* was already listed." +# $TEST$ no warning r"The literal .* was already listed." segment mySegment1( p: literal<> diff --git a/packages/ttsl-lang/tests/resources/validation/other/types/literal types/duplicate literals/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/types/literal types/duplicate literals/main.sdstest index 7ecff256..31457305 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/types/literal types/duplicate literals/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/types/literal types/duplicate literals/main.sdstest @@ -1,14 +1,14 @@ package tests.validation.other.types.literalTypes.duplicateLiterals segment mySegment( - // $TEST$ no warning r"The literal .* was already listed." + # $TEST$ no warning r"The literal .* was already listed." p: literal<»1«>, q: literal< - // $TEST$ no warning r"The literal .* was already listed." + # $TEST$ no warning r"The literal .* was already listed." »1«, - // $TEST$ no warning r"The literal .* was already listed." + # $TEST$ no warning r"The literal .* was already listed." »2«, - // $TEST$ warning r"The literal 1 was already listed." + # $TEST$ warning r"The literal 1 was already listed." »1«, >, ) {} diff --git a/packages/ttsl-lang/tests/resources/validation/other/types/literal types/must have literals/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/types/literal types/must have literals/main.sdstest index e93a113f..89d7492e 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/types/literal types/must have literals/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/types/literal types/must have literals/main.sdstest @@ -1,16 +1,16 @@ package tests.validation.other.types.literalTypes.mustHaveLiterals -// $TEST$ error "A literal type must have at least one literal." +# $TEST$ error "A literal type must have at least one literal." segment mySegment1( p: literal»<>« ) {} -// $TEST$ no error "A literal type must have at least one literal." +# $TEST$ no error "A literal type must have at least one literal." segment mySegment2( p: literal»<1>« ) {} -// $TEST$ no error "A literal type must have at least one literal." +# $TEST$ no error "A literal type must have at least one literal." segment mySegment3( p: literal»<1, "">« ) {} diff --git a/packages/ttsl-lang/tests/resources/validation/other/types/literal types/must not contain list literals/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/types/literal types/must not contain list literals/main.sdstest index d0e6cae7..356e8edd 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/types/literal types/must not contain list literals/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/types/literal types/must not contain list literals/main.sdstest @@ -1,6 +1,6 @@ package tests.validation.other.types.literalTypes.mustNotContanListLiterals -// $TEST$ error "Literal types must not contain list literals." +# $TEST$ error "Literal types must not contain list literals." segment mySegment( x: literal<»[]«> ) {} diff --git a/packages/ttsl-lang/tests/resources/validation/other/types/literal types/must not contain map literals/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/types/literal types/must not contain map literals/main.sdstest index 08bdf73f..e4acfaa9 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/types/literal types/must not contain map literals/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/types/literal types/must not contain map literals/main.sdstest @@ -1,6 +1,6 @@ package tests.validation.other.types.literalsTypes.mustNotContainMapLiterals -// $TEST$ error "Literal types must not contain map literals." +# $TEST$ error "Literal types must not contain map literals." segment mySegment( x: literal<»{}«> ) {} diff --git a/packages/ttsl-lang/tests/resources/validation/other/types/type argument lists/duplicate type parameter/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/types/type argument lists/duplicate type parameter/main.sdstest index 0cbf53fe..2bae294e 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/types/type argument lists/duplicate type parameter/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/types/type argument lists/duplicate type parameter/main.sdstest @@ -4,33 +4,33 @@ class MyClass fun myFunction( f: MyClass< - // $TEST$ no error r"The type parameter '\w+' is already set\." + # $TEST$ no error r"The type parameter '\w+' is already set\." »Int«, - // $TEST$ error "The type parameter 'A' is already set." + # $TEST$ error "The type parameter 'A' is already set." »A = Int« >, g: MyClass< - // $TEST$ no error r"The type parameter '\w+' is already set\." + # $TEST$ no error r"The type parameter '\w+' is already set\." »B = Int«, - // $TEST$ error "The type parameter 'B' is already set." + # $TEST$ error "The type parameter 'B' is already set." »B = Int« >, h: MyClass< - // $TEST$ no error r"The type parameter '\w+' is already set\." + # $TEST$ no error r"The type parameter '\w+' is already set\." »A = Int«, - // $TEST$ no error r"The type parameter '\w+' is already set\." + # $TEST$ no error r"The type parameter '\w+' is already set\." »B = Int« >, i: MyClass< - // $TEST$ no error r"The type parameter '\w+' is already set\." + # $TEST$ no error r"The type parameter '\w+' is already set\." »Int«, - // $TEST$ no error r"The type parameter '\w+' is already set\." + # $TEST$ no error r"The type parameter '\w+' is already set\." »Int« >, j: MyClass< - // $TEST$ no error r"The type parameter '\w+' is already set\." + # $TEST$ no error r"The type parameter '\w+' is already set\." »Unresolved = Int«, - // $TEST$ no error r"The type parameter '\w+' is already set\." + # $TEST$ no error r"The type parameter '\w+' is already set\." »Unresolved = Int« > ) diff --git a/packages/ttsl-lang/tests/resources/validation/other/types/type argument lists/must not have positional type argument after named type argument/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/types/type argument lists/must not have positional type argument after named type argument/main.sdstest index c6237952..eb18a08a 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/types/type argument lists/must not have positional type argument after named type argument/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/types/type argument lists/must not have positional type argument after named type argument/main.sdstest @@ -1,19 +1,19 @@ package tests.validation.other.types.typeArgumentLists.mustNotHavePositionalTypeArgumentAfterNamedTypeArgument -// $TEST$ no error "After the first named type argument all type arguments must be named." -// $TEST$ no error "After the first named type argument all type arguments must be named." -// $TEST$ error "After the first named type argument all type arguments must be named." -// $TEST$ no error "After the first named type argument all type arguments must be named." +# $TEST$ no error "After the first named type argument all type arguments must be named." +# $TEST$ no error "After the first named type argument all type arguments must be named." +# $TEST$ error "After the first named type argument all type arguments must be named." +# $TEST$ no error "After the first named type argument all type arguments must be named." segment mySegment1( f: MyClass<»Int«, »A = Int«, »Int«, »B = Int«> ) {} -// $TEST$ no error "After the first named type argument all type arguments must be named." +# $TEST$ no error "After the first named type argument all type arguments must be named." segment mySegment2( f: MyClass<»Int«> ) {} -// $TEST$ no error "After the first named type argument all type arguments must be named." +# $TEST$ no error "After the first named type argument all type arguments must be named." segment mySegment2( f: MyClass<»A = Int«> ) {} diff --git a/packages/ttsl-lang/tests/resources/validation/other/types/type argument lists/too many type arguments/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/types/type argument lists/too many type arguments/main.sdstest index 564e9add..f7f7fc7b 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/types/type argument lists/too many type arguments/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/types/type argument lists/too many type arguments/main.sdstest @@ -5,16 +5,16 @@ class MyClass2 class MyClass3 fun myFunction( - // $TEST$ no error r"Expected .* type arguments? but got \d*\." + # $TEST$ no error r"Expected .* type arguments? but got \d*\." a: MyClass1»<>«, - // $TEST$ no error r"Expected .* type arguments? but got \d*\." + # $TEST$ no error r"Expected .* type arguments? but got \d*\." b: MyClass1»«, - // $TEST$ error "Expected exactly 1 type argument but got 2." + # $TEST$ error "Expected exactly 1 type argument but got 2." c: MyClass1»«, - // $TEST$ error "Expected exactly 2 type arguments but got 3." + # $TEST$ error "Expected exactly 2 type arguments but got 3." d: MyClass2»«, - // $TEST$ error "Expected between 1 and 2 type arguments but got 3." + # $TEST$ error "Expected between 1 and 2 type arguments but got 3." f: MyClass3»«, - // $TEST$ no error r"Expected .* type arguments? but got \d*\." + # $TEST$ no error r"Expected .* type arguments? but got \d*\." g: Unresolved»« ) diff --git a/packages/ttsl-lang/tests/resources/validation/other/types/union types/context/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/types/union types/context/main.sdstest index 1060fd99..a0585788 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/types/union types/context/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/types/union types/context/main.sdstest @@ -1,63 +1,63 @@ package tests.validation.other.types.unionTypes.context annotation MyAnnotation( - // $TEST$ no error "Union types must only be used for parameters of annotations, classes, and functions." + # $TEST$ no error "Union types must only be used for parameters of annotations, classes, and functions." p: »union«, ) class MyClass( - // $TEST$ no error "Union types must only be used for parameters of annotations, classes, and functions." + # $TEST$ no error "Union types must only be used for parameters of annotations, classes, and functions." p: »union«, ) { - // $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." + # $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." attr a: »union« } enum MyEnum { MyEnumVariant( - // $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." + # $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." p: »union«, ) } fun myFunction( - // $TEST$ no error "Union types must only be used for parameters of annotations, classes, and functions." + # $TEST$ no error "Union types must only be used for parameters of annotations, classes, and functions." p: »union«, ) -> ( - // $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." + # $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." r: »union«, ) segment mySegment1( - // $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." + # $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." p: »union«, ) -> ( - // $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." + # $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." r: »union«, ) {} segment mySegment2( - // $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." - // $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." + # $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." + # $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." c: (p: »union«) -> (r: »union«), ) { - // $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." + # $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." ( p: »union«, ) {}; - // $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." + # $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." ( p: »union«, ) -> 1; } segment mySegment3( - // $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." + # $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." p1: MyClass<»union«>, ) {} segment mySegment4( - // $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." + # $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." p1: »union«.MyClass ) {} diff --git a/packages/ttsl-lang/tests/resources/validation/other/types/union types/context/nested.sdstest b/packages/ttsl-lang/tests/resources/validation/other/types/union types/context/nested.sdstest index 3c0707f3..5bc12c76 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/types/union types/context/nested.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/types/union types/context/nested.sdstest @@ -5,12 +5,12 @@ package tests.validation.other.types.unionTypes.context */ class MyClass1 { - // $TEST$ no error "Union types must only be used for parameters of annotations, classes, and functions." + # $TEST$ no error "Union types must only be used for parameters of annotations, classes, and functions." attr a: union«> } class MyClass2 { - // $TEST$ no error "Union types must only be used for parameters of annotations, classes, and functions." - // $TEST$ no error "Union types must only be used for parameters of annotations, classes, and functions." + # $TEST$ no error "Union types must only be used for parameters of annotations, classes, and functions." + # $TEST$ no error "Union types must only be used for parameters of annotations, classes, and functions." attr a: union«) -> (r: »union«)> } diff --git a/packages/ttsl-lang/tests/resources/validation/other/types/union types/duplicate types/empty list.sdstest b/packages/ttsl-lang/tests/resources/validation/other/types/union types/duplicate types/empty list.sdstest index cd81b4d1..26ee335b 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/types/union types/duplicate types/empty list.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/types/union types/duplicate types/empty list.sdstest @@ -1,6 +1,6 @@ package tests.validation.other.types.unionTypes.duplicateTypes -// $TEST$ no warning r"The type .* was already listed." +# $TEST$ no warning r"The type .* was already listed." fun myFunction1( p: union<> diff --git a/packages/ttsl-lang/tests/resources/validation/other/types/union types/duplicate types/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/types/union types/duplicate types/main.sdstest index bc3931b9..64dd8e67 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/types/union types/duplicate types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/types/union types/duplicate types/main.sdstest @@ -1,14 +1,14 @@ package tests.validation.other.types.unionTypes.duplicateTypes fun myFunction2( - // $TEST$ no warning r"The type .* was already listed." + # $TEST$ no warning r"The type .* was already listed." p: union<»Int«>, q: union< - // $TEST$ no warning r"The type .* was already listed." + # $TEST$ no warning r"The type .* was already listed." »Int«, - // $TEST$ no warning r"The type .* was already listed." + # $TEST$ no warning r"The type .* was already listed." »String«, - // $TEST$ warning r"The type 'Int' was already listed." + # $TEST$ warning r"The type 'Int' was already listed." »Int«, >, ) diff --git a/packages/ttsl-lang/tests/resources/validation/other/types/union types/must have types/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/types/union types/must have types/main.sdstest index b4779c26..3268a912 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/types/union types/must have types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/types/union types/must have types/main.sdstest @@ -1,16 +1,16 @@ package tests.validation.other.types.unionTypes.mustHaveTypes -// $TEST$ error "A union type must have at least one type." +# $TEST$ error "A union type must have at least one type." fun myFunction1( p: union»<>« ) -// $TEST$ no error "A union type must have at least one type." +# $TEST$ no error "A union type must have at least one type." fun myFunction2( p: union»« ) -// $TEST$ no error "A union type must have at least one type." +# $TEST$ no error "A union type must have at least one type." fun myFunction3( p: union»« ) diff --git a/packages/ttsl-lang/tests/resources/validation/purity/duplicate impurity reason/main.sdstest b/packages/ttsl-lang/tests/resources/validation/purity/duplicate impurity reason/main.sdstest index 6a90b3b0..d7c09504 100644 --- a/packages/ttsl-lang/tests/resources/validation/purity/duplicate impurity reason/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/purity/duplicate impurity reason/main.sdstest @@ -1,7 +1,7 @@ package tests.validation.purity.duplicateImpurityReason @Impure([ - // $TEST$ no warning r"The impurity reason '.*' was set already\." + # $TEST$ no warning r"The impurity reason '.*' was set already\." »ImpurityReason.FileReadFromConstantPath("text.txt")« ]) @@ -10,33 +10,33 @@ package tests.validation.purity.duplicateImpurityReason */ @Impure([ - // $TEST$ no warning r"The impurity reason '.*' was set already\." + # $TEST$ no warning r"The impurity reason '.*' was set already\." »ImpurityReason.FileReadFromConstantPath("text.txt")«, - // $TEST$ no warning r"The impurity reason '.*' was set already\." + # $TEST$ no warning r"The impurity reason '.*' was set already\." »ImpurityReason.FileReadFromConstantPath("text.txt")«, ]) fun testFunction1() @Impure([ - // $TEST$ no warning r"The impurity reason '.*' was set already\." + # $TEST$ no warning r"The impurity reason '.*' was set already\." »ImpurityReason.FileReadFromConstantPath("text.txt")«, - // $TEST$ warning "The impurity reason 'FileReadFromConstantPath(path = "text.txt")' was set already." + # $TEST$ warning "The impurity reason 'FileReadFromConstantPath(path = "text.txt")' was set already." »ImpurityReason.FileReadFromConstantPath("text.txt")«, ]) fun testFunction2() @Impure([ - // $TEST$ no warning r"The impurity reason '.*' was set already\." + # $TEST$ no warning r"The impurity reason '.*' was set already\." »ImpurityReason.FileWriteToConstantPath("text.txt")«, - // $TEST$ warning "The impurity reason 'FileWriteToConstantPath(path = "text.txt")' was set already." + # $TEST$ warning "The impurity reason 'FileWriteToConstantPath(path = "text.txt")' was set already." »ImpurityReason.FileWriteToConstantPath("text.txt")«, - // $TEST$ warning "The impurity reason 'FileWriteToConstantPath(path = "text.txt")' was set already." + # $TEST$ warning "The impurity reason 'FileWriteToConstantPath(path = "text.txt")' was set already." »ImpurityReason.FileWriteToConstantPath("text.txt")«, - // $TEST$ no warning r"The impurity reason '.*' was set already\." + # $TEST$ no warning r"The impurity reason '.*' was set already\." »ImpurityReason.FileReadFromConstantPath("text.txt")«, - // $TEST$ warning "The impurity reason 'FileReadFromConstantPath(path = "text.txt")' was set already." + # $TEST$ warning "The impurity reason 'FileReadFromConstantPath(path = "text.txt")' was set already." »ImpurityReason.FileReadFromConstantPath("text.txt")«, - // $TEST$ warning "The impurity reason 'FileReadFromConstantPath(path = "text.txt")' was set already." + # $TEST$ warning "The impurity reason 'FileReadFromConstantPath(path = "text.txt")' was set already." »ImpurityReason.FileReadFromConstantPath("text.txt")«, ]) fun testFunction3() @@ -46,17 +46,17 @@ fun testFunction3() */ @Impure( - // $TEST$ no warning r"The impurity reason '.*' was set already\." + # $TEST$ no warning r"The impurity reason '.*' was set already\." »ImpurityReason.FileWriteToConstantPath("text.txt")«, - // $TEST$ no warning r"The impurity reason '.*' was set already\." + # $TEST$ no warning r"The impurity reason '.*' was set already\." »ImpurityReason.FileWriteToConstantPath("text.txt")« ) fun testFunction4() @Impure([ - // $TEST$ no warning r"The impurity reason '.*' was set already\." + # $TEST$ no warning r"The impurity reason '.*' was set already\." »1«, - // $TEST$ no warning r"The impurity reason '.*' was set already\." + # $TEST$ no warning r"The impurity reason '.*' was set already\." »1«, ]) fun testFunction5() diff --git a/packages/ttsl-lang/tests/resources/validation/purity/duplicate impurity reason/no impure annotation.sdstest b/packages/ttsl-lang/tests/resources/validation/purity/duplicate impurity reason/no impure annotation.sdstest index 524b60ec..d48711b8 100644 --- a/packages/ttsl-lang/tests/resources/validation/purity/duplicate impurity reason/no impure annotation.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/purity/duplicate impurity reason/no impure annotation.sdstest @@ -1,5 +1,5 @@ package tests.validation.purity.duplicateImpurityReason -// $TEST$ no warning r"The impurity reason '.*' was set already\." +# $TEST$ no warning r"The impurity reason '.*' was set already\." fun testFunction6() diff --git a/packages/ttsl-lang/tests/resources/validation/purity/impure callable passed to pure parameter/arguments.sdstest b/packages/ttsl-lang/tests/resources/validation/purity/impure callable passed to pure parameter/arguments.sdstest index 1be44b86..3884c096 100644 --- a/packages/ttsl-lang/tests/resources/validation/purity/impure callable passed to pure parameter/arguments.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/purity/impure callable passed to pure parameter/arguments.sdstest @@ -53,68 +53,68 @@ segment mySegment2( other: Int = 1, ) -> 1; - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." MyAnnotation(»pureFunction«, »pureFunction«); - // $TEST$ error "Cannot pass an impure callable to a pure parameter." - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." MyAnnotation(»impureFunction«, »impureFunction«); - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." MyClass(»pureFunction«, »pureFunction«); - // $TEST$ error "Cannot pass an impure callable to a pure parameter." - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." MyClass(»impureFunction«, »impureFunction«); - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." MyEnum.MyEnumVariant(»pureFunction«, »pureFunction«); - // $TEST$ error "Cannot pass an impure callable to a pure parameter." - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." MyEnum.MyEnumVariant(»impureFunction«, »impureFunction«); - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." myFunction(»pureFunction«, »pureFunction«, »pureFunction«); - // $TEST$ error "Cannot pass an impure callable to a pure parameter." - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." myFunction(»impureFunction«, »impureFunction«, »impureFunction«); - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." mySegment1(»pureFunction«, »pureFunction«); - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." mySegment1(»impureFunction«, »impureFunction«); - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." myCallableType(»pureFunction«, »pureFunction«); - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." myCallableType(»impureFunction«, »impureFunction«); - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." myBlockLambda(»pureFunction«, »pureFunction«); - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." myBlockLambda(»impureFunction«, »impureFunction«); - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." myExpressionLambda(»pureFunction«, »pureFunction«); - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." myExpressionLambda(»impureFunction«, »impureFunction«); } // Argument does not have callable type pipeline myPipeline { - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." MyClass(»1«, »1«); } diff --git a/packages/ttsl-lang/tests/resources/validation/purity/impure callable passed to pure parameter/default values.sdstest b/packages/ttsl-lang/tests/resources/validation/purity/impure callable passed to pure parameter/default values.sdstest index d6bfa9ac..cbaa7af5 100644 --- a/packages/ttsl-lang/tests/resources/validation/purity/impure callable passed to pure parameter/default values.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/purity/impure callable passed to pure parameter/default values.sdstest @@ -7,41 +7,41 @@ fun pureFunction() fun impureFunction() annotation MyAnnotation( - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." f: () -> () = »pureFunction«, - // $TEST$ error "Cannot pass an impure callable to a pure parameter." + # $TEST$ error "Cannot pass an impure callable to a pure parameter." g: () -> () = »impureFunction«, - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." other: Int = »impureFunction«, ) class MyClass1( - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." f: () -> () = »pureFunction«, - // $TEST$ error "Cannot pass an impure callable to a pure parameter." + # $TEST$ error "Cannot pass an impure callable to a pure parameter." g: () -> () = »impureFunction«, - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." other: Int = »impureFunction«, ) enum MyEnum { MyEnumVariant( - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." f: () -> () = »pureFunction«, - // $TEST$ error "Cannot pass an impure callable to a pure parameter." + # $TEST$ error "Cannot pass an impure callable to a pure parameter." g: () -> () = »impureFunction«, - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." other: Int = »impureFunction«, ) } @Pure fun myFunction1( - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." f: () -> () = »pureFunction«, - // $TEST$ error "Cannot pass an impure callable to a pure parameter." + # $TEST$ error "Cannot pass an impure callable to a pure parameter." g: () -> () = »impureFunction«, - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." other: Int = »impureFunction«, ) @@ -50,60 +50,60 @@ fun myFunction1( ImpurityReason.PotentiallyImpureParameterCall("g1"), ]) fun myFunction2( - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." f1: () -> () = »pureFunction«, - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." g1: () -> () = »impureFunction«, - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." f2: () -> () = »pureFunction«, - // $TEST$ error "Cannot pass an impure callable to a pure parameter." + # $TEST$ error "Cannot pass an impure callable to a pure parameter." g2: () -> () = »impureFunction«, - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." other: Int = »impureFunction«, ) segment mySegment1( myCallableType: ( - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." f: () -> () = »pureFunction«, - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." g: () -> () = »impureFunction«, - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." other: Int = »impureFunction«, ) -> () ) {} segment mySegment2( - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." f: () -> () = »pureFunction«, - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." g: () -> () = »impureFunction«, - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." other: Int = »impureFunction«, ) {} pipeline myPipeline { ( - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." f: () -> () = »pureFunction«, - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." g: () -> () = »impureFunction«, - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." other: Int = »impureFunction«, ) {}; ( - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." f: () -> () = »pureFunction«, - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." g: () -> () = »impureFunction«, - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." other: Int = »impureFunction«, ) -> 1; } // Default value does not have callable type class MyClass2( - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." f: () -> () = »1«, ) diff --git a/packages/ttsl-lang/tests/resources/validation/purity/invalid parameter name/main.sdstest b/packages/ttsl-lang/tests/resources/validation/purity/invalid parameter name/main.sdstest index d7dc2b74..b36d59b9 100644 --- a/packages/ttsl-lang/tests/resources/validation/purity/invalid parameter name/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/purity/invalid parameter name/main.sdstest @@ -1,26 +1,26 @@ package tests.validation.purity.parameterNamesMustBeValid @Impure([ - // $TEST$ no error r"The parameter '.*' does not exist\." + # $TEST$ no error r"The parameter '.*' does not exist\." ImpurityReason.FileReadFromConstantPath(»"text.txt"«), - // $TEST$ no error "The parameter 'p' does not exist." + # $TEST$ no error "The parameter 'p' does not exist." ImpurityReason.FileReadFromParameterizedPath(»"p"«), - // $TEST$ error "The parameter 'q' does not exist." + # $TEST$ error "The parameter 'q' does not exist." ImpurityReason.FileReadFromParameterizedPath(»"q"«), - // $TEST$ no error r"The parameter '.*' does not exist\." + # $TEST$ no error r"The parameter '.*' does not exist\." ImpurityReason.FileWriteToConstantPath(»"text.txt"«), - // $TEST$ no error "The parameter 'p' does not exist." + # $TEST$ no error "The parameter 'p' does not exist." ImpurityReason.FileWriteToParameterizedPath(»"p"«), - // $TEST$ error "The parameter 'q' does not exist." + # $TEST$ error "The parameter 'q' does not exist." ImpurityReason.FileWriteToParameterizedPath(»"q"«), - // $TEST$ no error "The parameter 'p' does not exist." + # $TEST$ no error "The parameter 'p' does not exist." ImpurityReason.PotentiallyImpureParameterCall(»"p"«), - // $TEST$ error "The parameter 'q' does not exist." + # $TEST$ error "The parameter 'q' does not exist." ImpurityReason.PotentiallyImpureParameterCall(»"q"«), - // $TEST$ no error r"The parameter '.*' does not exist\." + # $TEST$ no error r"The parameter '.*' does not exist\." ImpurityReason.PotentiallyImpureParameterCall(»1«), - // $TEST$ no error "The parameter 'q' does not exist." + # $TEST$ no error "The parameter 'q' does not exist." AnotherEnum.SomeVariant(»"q"«) ]) fun f(p: Int) diff --git a/packages/ttsl-lang/tests/resources/validation/purity/must be subset of impurity reasons of overridden method/main.sdstest b/packages/ttsl-lang/tests/resources/validation/purity/must be subset of impurity reasons of overridden method/main.sdstest index 9267adaf..3b4562a9 100644 --- a/packages/ttsl-lang/tests/resources/validation/purity/must be subset of impurity reasons of overridden method/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/purity/must be subset of impurity reasons of overridden method/main.sdstest @@ -1,15 +1,15 @@ package tests.validation.purity.mustBeSubsetOfImpurityReasonsOfOverriddenMethod class Superclass { - // $TEST$ no error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." + # $TEST$ no error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." @Pure fun »pureFunction«() - // $TEST$ no error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." + # $TEST$ no error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." @Impure([]) fun »impureFunctionWithoutReason«() - // $TEST$ no error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." + # $TEST$ no error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." @Impure([ImpurityReason.Other]) fun »impureFunctionWithReasons«() } @@ -19,40 +19,40 @@ class IdenticalSubclass sub Superclass { * We already show another error if the `@Impure` annotation is called multiple times. */ - // $TEST$ no error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." + # $TEST$ no error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." @Pure @Impure([ImpurityReason.Other]) fun »pureFunction«() - // $TEST$ no error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." + # $TEST$ no error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." @Impure([]) fun »impureFunctionWithoutReason«() - // $TEST$ no error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." + # $TEST$ no error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." @Impure([ImpurityReason.Other]) fun »impureFunctionWithReasons«() } class SubsetSubclass sub Superclass { - // $TEST$ no error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." + # $TEST$ no error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." @Pure fun »impureFunctionWithoutReason«() - // $TEST$ no error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." + # $TEST$ no error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." @Impure([]) fun »impureFunctionWithReasons«() } class IllegalSubclass sub Superclass { - // $TEST$ error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." + # $TEST$ error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." @Impure([ImpurityReason.Other]) fun »pureFunction«() - // $TEST$ error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." + # $TEST$ error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." @Impure([ImpurityReason.Other]) fun »impureFunctionWithoutReason«() - // $TEST$ error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." + # $TEST$ error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." @Impure([ImpurityReason.FileReadFromConstantPath("")]) fun impureFunctionWithReasons() } diff --git a/packages/ttsl-lang/tests/resources/validation/purity/must be subset of impurity reasons of overridden method/no purity annotation.sdstest b/packages/ttsl-lang/tests/resources/validation/purity/must be subset of impurity reasons of overridden method/no purity annotation.sdstest index 8af99d5c..a72973c7 100644 --- a/packages/ttsl-lang/tests/resources/validation/purity/must be subset of impurity reasons of overridden method/no purity annotation.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/purity/must be subset of impurity reasons of overridden method/no purity annotation.sdstest @@ -1,6 +1,6 @@ package tests.validation.purity.mustBeSubsetOfImpurityReasonsOfOverriddenMethod -// $TEST$ no error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." +# $TEST$ no error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." class A { fun functionWithUnspecifiedPurity() diff --git a/packages/ttsl-lang/tests/resources/validation/purity/no impurity reasons/main.sdstest b/packages/ttsl-lang/tests/resources/validation/purity/no impurity reasons/main.sdstest index 707de1cf..0cc3820e 100644 --- a/packages/ttsl-lang/tests/resources/validation/purity/no impurity reasons/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/purity/no impurity reasons/main.sdstest @@ -1,21 +1,21 @@ package tests.validation.purity.noImpurityReasons -// $TEST$ error "At least one impurity reason must be specified." +# $TEST$ error "At least one impurity reason must be specified." @»Impure« fun f1() -// $TEST$ error "At least one impurity reason must be specified." +# $TEST$ error "At least one impurity reason must be specified." @»Impure«() fun f2() -// $TEST$ error "At least one impurity reason must be specified." +# $TEST$ error "At least one impurity reason must be specified." @»Impure«([]) -// $TEST$ no error "At least one impurity reason must be specified." +# $TEST$ no error "At least one impurity reason must be specified." @»Impure«([]) fun f3() -// $TEST$ no error "At least one impurity reason must be specified." +# $TEST$ no error "At least one impurity reason must be specified." @»Impure«([ImpurityReason.Other]) -// $TEST$ no error "At least one impurity reason must be specified." +# $TEST$ no error "At least one impurity reason must be specified." @»Impure«([ImpurityReason.Other]) fun f4() diff --git a/packages/ttsl-lang/tests/resources/validation/purity/not specified/main.sdstest b/packages/ttsl-lang/tests/resources/validation/purity/not specified/main.sdstest index 5486cb11..ef447f26 100644 --- a/packages/ttsl-lang/tests/resources/validation/purity/not specified/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/purity/not specified/main.sdstest @@ -1,12 +1,12 @@ package tests.validation.purity.notSpecified -// $TEST$ error r"The purity of a function must be specified. Call the annotation '@Pure' or '@Impure'." +# $TEST$ error r"The purity of a function must be specified. Call the annotation '@Pure' or '@Impure'." fun »functionWithUnknownPurity«() -// $TEST$ no error r"The purity of a function must be specified. Call the annotation '@Pure' or '@Impure'." +# $TEST$ no error r"The purity of a function must be specified. Call the annotation '@Pure' or '@Impure'." @Impure([]) fun »impureFunction«() -// $TEST$ no error r"The purity of a function must be specified. Call the annotation '@Pure' or '@Impure'." +# $TEST$ no error r"The purity of a function must be specified. Call the annotation '@Pure' or '@Impure'." @Pure fun »pureFunction«() diff --git a/packages/ttsl-lang/tests/resources/validation/purity/potentially impure parameter must have callable type/main.sdstest b/packages/ttsl-lang/tests/resources/validation/purity/potentially impure parameter must have callable type/main.sdstest index 67f51a2b..4044f91b 100644 --- a/packages/ttsl-lang/tests/resources/validation/purity/potentially impure parameter must have callable type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/purity/potentially impure parameter must have callable type/main.sdstest @@ -1,15 +1,15 @@ package tests.validation.purity.potentiallyImpureParameterMustHaveCallableType @Impure([ - // $TEST$ error "The parameter 'a' must have a callable type." + # $TEST$ error "The parameter 'a' must have a callable type." ImpurityReason.PotentiallyImpureParameterCall(»"a"«), - // $TEST$ error "The parameter 'b' must have a callable type." + # $TEST$ error "The parameter 'b' must have a callable type." ImpurityReason.PotentiallyImpureParameterCall(»"b"«), - // $TEST$ no error r"The parameter '.*' must have a callable type\." + # $TEST$ no error r"The parameter '.*' must have a callable type\." ImpurityReason.PotentiallyImpureParameterCall(»"c"«), - // $TEST$ no error r"The parameter '.*' must have a callable type\." + # $TEST$ no error r"The parameter '.*' must have a callable type\." ImpurityReason.PotentiallyImpureParameterCall(»"d"«), - // $TEST$ no error r"The parameter '.*' must have a callable type\." + # $TEST$ no error r"The parameter '.*' must have a callable type\." ImpurityReason.PotentiallyImpureParameterCall(»"e"«), ]) fun myFunction( diff --git a/packages/ttsl-lang/tests/resources/validation/purity/pure and impure/main.sdstest b/packages/ttsl-lang/tests/resources/validation/purity/pure and impure/main.sdstest index 308c281c..fb3fd30b 100644 --- a/packages/ttsl-lang/tests/resources/validation/purity/pure and impure/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/purity/pure and impure/main.sdstest @@ -1,17 +1,17 @@ package tests.validation.purity.pureAndImpure -// $TEST$ no error "'@Impure' and '@Pure' are mutually exclusive." +# $TEST$ no error "'@Impure' and '@Pure' are mutually exclusive." fun »neither«() -// $TEST$ no error "'@Impure' and '@Pure' are mutually exclusive." +# $TEST$ no error "'@Impure' and '@Pure' are mutually exclusive." @Impure fun »impure«() -// $TEST$ no error "'@Impure' and '@Pure' are mutually exclusive." +# $TEST$ no error "'@Impure' and '@Pure' are mutually exclusive." @Pure fun »pure«() -// $TEST$ error "'@Impure' and '@Pure' are mutually exclusive." +# $TEST$ error "'@Impure' and '@Pure' are mutually exclusive." @Impure @Pure fun »both«() diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary argument list in annotation call/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary argument list in annotation call/main.sdstest index 9889671f..69696532 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary argument list in annotation call/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary argument list in annotation call/main.sdstest @@ -12,24 +12,24 @@ annotation AnnotationWithoutRequiredParameters(a: Int = 0) @Repeatable annotation AnnotationWithRequiredParameters(a: Int) -// $TEST$ info "This argument list can be removed." +# $TEST$ info "This argument list can be removed." @AnnotationWithoutParameterList»()« -// $TEST$ no info "This argument list can be removed." +# $TEST$ no info "This argument list can be removed." @AnnotationWithoutParameterList»(1)« -// $TEST$ info "This argument list can be removed." +# $TEST$ info "This argument list can be removed." @AnnotationWithEmptyParameterList»()« -// $TEST$ no info "This argument list can be removed." +# $TEST$ no info "This argument list can be removed." @AnnotationWithEmptyParameterList»(1)« -// $TEST$ info "This argument list can be removed." +# $TEST$ info "This argument list can be removed." @AnnotationWithoutRequiredParameters»()« -// $TEST$ no info "This argument list can be removed." +# $TEST$ no info "This argument list can be removed." @AnnotationWithoutRequiredParameters»(1)« -// $TEST$ no info "This argument list can be removed." +# $TEST$ no info "This argument list can be removed." @AnnotationWithRequiredParameters»()« -// $TEST$ no info "This argument list can be removed." +# $TEST$ no info "This argument list can be removed." @AnnotationWithRequiredParameters»(1)« -// $TEST$ no info "This argument list can be removed." +# $TEST$ no info "This argument list can be removed." @Unresolved»()« -// $TEST$ no info "This argument list can be removed." +# $TEST$ no info "This argument list can be removed." @Unresolved»(1)« class MyClass diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary argument list in call/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary argument list in call/main.sdstest index c4abf085..193f4ca2 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary argument list in call/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary argument list in call/main.sdstest @@ -21,45 +21,45 @@ segment mySegment2( val blockLambda = () {}; val expressionLambda = () -> 0; - // $TEST$ no info "This argument list can be removed." + # $TEST$ no info "This argument list can be removed." MyAnnotation»()«; - // $TEST$ no info "This argument list can be removed." + # $TEST$ no info "This argument list can be removed." MyClass»()«; - // $TEST$ info "This argument list can be removed." + # $TEST$ info "This argument list can be removed." MyEnum.EnumVariantWithoutParameterList»()«; - // $TEST$ no info "This argument list can be removed." + # $TEST$ no info "This argument list can be removed." MyEnum.EnumVariantWithoutParameterList»(1)«; - // $TEST$ info "This argument list can be removed." + # $TEST$ info "This argument list can be removed." MyEnum.EnumVariantWithEmptyParameterList»()«; - // $TEST$ no info "This argument list can be removed." + # $TEST$ no info "This argument list can be removed." MyEnum.EnumVariantWithEmptyParameterList»(1)«; - // $TEST$ no info "This argument list can be removed." + # $TEST$ no info "This argument list can be removed." MyEnum.EnumVariantWithoutRequiredParameters»()«; - // $TEST$ no info "This argument list can be removed." + # $TEST$ no info "This argument list can be removed." MyEnum.EnumVariantWithoutRequiredParameters»(1)«; - // $TEST$ no info "This argument list can be removed." + # $TEST$ no info "This argument list can be removed." MyEnum.EnumVariantWithRequiredParameters»()«; - // $TEST$ no info "This argument list can be removed." + # $TEST$ no info "This argument list can be removed." MyEnum.EnumVariantWithRequiredParameters»(1)«; - // $TEST$ no info "This argument list can be removed." + # $TEST$ no info "This argument list can be removed." MyEnum.Unresolved»()«; - // $TEST$ no info "This argument list can be removed." + # $TEST$ no info "This argument list can be removed." MyEnum.Unresolved»(1)«; - // $TEST$ no info "This argument list can be removed." + # $TEST$ no info "This argument list can be removed." myFunction»()«; - // $TEST$ no info "This argument list can be removed." + # $TEST$ no info "This argument list can be removed." mySegment1»()«; - // $TEST$ no info "This argument list can be removed." + # $TEST$ no info "This argument list can be removed." callableType»()«; - // $TEST$ no info "This argument list can be removed." + # $TEST$ no info "This argument list can be removed." blockLambda»()«; - // $TEST$ no info "This argument list can be removed." + # $TEST$ no info "This argument list can be removed." expressionLambda»()«; } diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary assignment/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary assignment/main.sdstest index 59097760..eed80fa7 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary assignment/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary assignment/main.sdstest @@ -7,25 +7,25 @@ class MyClass { } segment mySegment() -> a: Int { - // $TEST$ info "This assignment can be replaced by an expression statement." + # $TEST$ info "This assignment can be replaced by an expression statement." »_, _ = f();« - // $TEST$ info "This assignment can be replaced by an expression statement." + # $TEST$ info "This assignment can be replaced by an expression statement." »_, _ = MyClass().f();« - // $TEST$ no info "This assignment can be replaced by an expression statement." + # $TEST$ no info "This assignment can be replaced by an expression statement." »val a = 1;« - // $TEST$ no info "This assignment can be replaced by an expression statement." + # $TEST$ no info "This assignment can be replaced by an expression statement." »yield a = 1;« () { - // $TEST$ info "This assignment can be replaced by an expression statement." + # $TEST$ info "This assignment can be replaced by an expression statement." »_, _ = f();« - // $TEST$ info "This assignment can be replaced by an expression statement." + # $TEST$ info "This assignment can be replaced by an expression statement." »_, _ = MyClass().f();« - // $TEST$ no info "This assignment can be replaced by an expression statement." + # $TEST$ no info "This assignment can be replaced by an expression statement." »val a = 1;« - // $TEST$ no info "This assignment can be replaced by an expression statement." + # $TEST$ no info "This assignment can be replaced by an expression statement." »yield a = 1;« }; } diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary body in class/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary body in class/main.sdstest index 24001d56..16a3aefe 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary body in class/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary body in class/main.sdstest @@ -1,14 +1,14 @@ package tests.validation.style.unnecessaryBodyInClass -// $TEST$ info "This body can be removed." +# $TEST$ info "This body can be removed." class MyClass1 »{}« -// $TEST$ no info "This body can be removed." +# $TEST$ no info "This body can be removed." class MyClass2 »{ fun f() }« -// $TEST$ no info "This body can be removed." +# $TEST$ no info "This body can be removed." class MyClass3 »{ attr a: Int }« diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary body in enum/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary body in enum/main.sdstest index 91b9bf82..6bae5c77 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary body in enum/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary body in enum/main.sdstest @@ -1,9 +1,9 @@ package tests.validation.style.unnecessaryBodyInEnum -// $TEST$ info "This body can be removed." +# $TEST$ info "This body can be removed." enum MyEnum1 »{}« -// $TEST$ no info "This body can be removed." +# $TEST$ no info "This body can be removed." enum MyEnum2 »{ Instance }« diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary const modifier on annotation parameter/info.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary const modifier on annotation parameter/info.sdstest index c23d3171..89a5c24c 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary const modifier on annotation parameter/info.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary const modifier on annotation parameter/info.sdstest @@ -1,6 +1,6 @@ package tests.validation.style.unnecessaryConstModifierOnAnnotationParameters annotation MyAnnotation( - // $TEST$ info "Annotation parameters are always const, so this modifier can be removed." + # $TEST$ info "Annotation parameters are always const, so this modifier can be removed." »const« p1: Int ) diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary const modifier on annotation parameter/no info.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary const modifier on annotation parameter/no info.sdstest index d9d5f58f..68c01ed3 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary const modifier on annotation parameter/no info.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary const modifier on annotation parameter/no info.sdstest @@ -1,6 +1,6 @@ package tests.validation.style.unnecessaryConstModifierOnAnnotationParameters annotation MyAnnotation( - // $TEST$ no info "Annotation parameters are always const, so this modifier can be removed." + # $TEST$ no info "Annotation parameters are always const, so this modifier can be removed." p2: Int, ) diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in annotation/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in annotation/main.sdstest index 18384871..b8f39688 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in annotation/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in annotation/main.sdstest @@ -1,9 +1,9 @@ package tests.validation.style.unnecessaryConstraintListInAnnotation -// $TEST$ info "This constraint list can be removed." +# $TEST$ info "This constraint list can be removed." annotation MyAnnotation1 »where {}« -// $TEST$ no info "This constraint list can be removed." +# $TEST$ no info "This constraint list can be removed." annotation MyAnnotation2(p: Int) »where { p < 0 }« diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in class/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in class/main.sdstest index 1819c189..5ab9591e 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in class/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in class/main.sdstest @@ -1,9 +1,9 @@ package tests.validation.style.unnecessaryConstraintListInClass -// $TEST$ info "This constraint list can be removed." +# $TEST$ info "This constraint list can be removed." class MyClass1 »where {}« -// $TEST$ no info "This constraint list can be removed." +# $TEST$ no info "This constraint list can be removed." class MyClass2(p: Int) »where { p < 0 }« diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in enum variant/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in enum variant/main.sdstest index e2e51aea..1bc212ef 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in enum variant/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in enum variant/main.sdstest @@ -1,10 +1,10 @@ package tests.validation.style.unnecessaryConstraintInEnumVariant enum MyEnum { - // $TEST$ info "This constraint list can be removed." + # $TEST$ info "This constraint list can be removed." MyVariant1 »where {}« - // $TEST$ no info "This constraint list can be removed." + # $TEST$ no info "This constraint list can be removed." MyVariant2(p: Int) »where { p < 0 }« diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in function/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in function/main.sdstest index e104e176..eeadb021 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in function/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in function/main.sdstest @@ -1,9 +1,9 @@ package tests.validation.style.unnecessaryConstraintListInFunction -// $TEST$ info "This constraint list can be removed." +# $TEST$ info "This constraint list can be removed." fun myFunction1() »where {}« -// $TEST$ no info "This constraint list can be removed." +# $TEST$ no info "This constraint list can be removed." fun myFunction2(p: Int) »where { p < 0 }« diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in segment/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in segment/main.sdstest index 45e9ca48..893e2c85 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in segment/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in segment/main.sdstest @@ -1,9 +1,9 @@ package tests.validation.style.unnecessaryConstraintListInSegment -// $TEST$ info "This constraint list can be removed." +# $TEST$ info "This constraint list can be removed." segment mySegment1() »where {}« {} -// $TEST$ no info "This constraint list can be removed." +# $TEST$ no info "This constraint list can be removed." segment mySegment2(p: Int) »where { p < 0 }« {} diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary elvis operator/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary elvis operator/main.sdstest index 3ba83ddc..cffd46a5 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary elvis operator/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary elvis operator/main.sdstest @@ -4,40 +4,40 @@ package validation.style.unnecessaryElvisOperator pipeline test { - // $TEST$ info "The left operand is never null, so the elvis operator is unnecessary (keep the left operand)." + # $TEST$ info "The left operand is never null, so the elvis operator is unnecessary (keep the left operand)." »1 ?: 2«; - // $TEST$ info "The left operand is never null, so the elvis operator is unnecessary (keep the left operand)." + # $TEST$ info "The left operand is never null, so the elvis operator is unnecessary (keep the left operand)." »1 ?: null«; - // $TEST$ no info "The left operand is never null, so the elvis operator is unnecessary (keep the left operand)." + # $TEST$ no info "The left operand is never null, so the elvis operator is unnecessary (keep the left operand)." »null ?: 2«; - // $TEST$ no info "The left operand is never null, so the elvis operator is unnecessary (keep the left operand)." + # $TEST$ no info "The left operand is never null, so the elvis operator is unnecessary (keep the left operand)." »null ?: null«; - // $TEST$ no info "The right operand is always null, so the elvis operator is unnecessary (keep the left operand)." + # $TEST$ no info "The right operand is always null, so the elvis operator is unnecessary (keep the left operand)." »1 ?: 2«; - // $TEST$ info "The right operand is always null, so the elvis operator is unnecessary (keep the left operand)." + # $TEST$ info "The right operand is always null, so the elvis operator is unnecessary (keep the left operand)." »f() ?: null«; - // $TEST$ no info "The right operand is always null, so the elvis operator is unnecessary (keep the left operand)." + # $TEST$ no info "The right operand is always null, so the elvis operator is unnecessary (keep the left operand)." »null ?: 2«; - // $TEST$ no info "The right operand is always null, so the elvis operator is unnecessary (keep the left operand)." + # $TEST$ no info "The right operand is always null, so the elvis operator is unnecessary (keep the left operand)." »null ?: null«; - // $TEST$ no info "The left operand is always null, so the elvis operator is unnecessary (keep the right operand)." + # $TEST$ no info "The left operand is always null, so the elvis operator is unnecessary (keep the right operand)." »1 ?: 2«; - // $TEST$ no info "The left operand is always null, so the elvis operator is unnecessary (keep the right operand)." + # $TEST$ no info "The left operand is always null, so the elvis operator is unnecessary (keep the right operand)." »1 ?: null«; - // $TEST$ info "The left operand is always null, so the elvis operator is unnecessary (keep the right operand)." + # $TEST$ info "The left operand is always null, so the elvis operator is unnecessary (keep the right operand)." »null ?: 2«; - // $TEST$ no info "The left operand is always null, so the elvis operator is unnecessary (keep the right operand)." + # $TEST$ no info "The left operand is always null, so the elvis operator is unnecessary (keep the right operand)." »null ?: null«; - // $TEST$ no info "Both operands are always null, so the elvis operator is unnecessary (replace it with null)." + # $TEST$ no info "Both operands are always null, so the elvis operator is unnecessary (replace it with null)." »1 ?: 2«; - // $TEST$ no info "Both operands are always null, so the elvis operator is unnecessary (replace it with null)." + # $TEST$ no info "Both operands are always null, so the elvis operator is unnecessary (replace it with null)." »1 ?: null«; - // $TEST$ no info "Both operands are always null, so the elvis operator is unnecessary (replace it with null)." + # $TEST$ no info "Both operands are always null, so the elvis operator is unnecessary (replace it with null)." »null ?: 2«; - // $TEST$ info "Both operands are always null, so the elvis operator is unnecessary (replace it with null)." + # $TEST$ info "Both operands are always null, so the elvis operator is unnecessary (replace it with null)." »null ?: null«; } @@ -45,12 +45,12 @@ class TestsForTypeParameters( nullable: Nullable, nonNullable: NonNullable, - // $TEST$ no info "The left operand is never null, so the elvis operator is unnecessary (keep the left operand)." + # $TEST$ no info "The left operand is never null, so the elvis operator is unnecessary (keep the left operand)." p1: Any? = »nullable ?: 2«, - // $TEST$ no info "The left operand is never null, so the elvis operator is unnecessary (keep the left operand)." + # $TEST$ no info "The left operand is never null, so the elvis operator is unnecessary (keep the left operand)." p2: Any? = »nullable ?: null«, - // $TEST$ info "The left operand is never null, so the elvis operator is unnecessary (keep the left operand)." + # $TEST$ info "The left operand is never null, so the elvis operator is unnecessary (keep the left operand)." p3: Any? = »nonNullable ?: 2«, - // $TEST$ info "The left operand is never null, so the elvis operator is unnecessary (keep the left operand)." + # $TEST$ info "The left operand is never null, so the elvis operator is unnecessary (keep the left operand)." p4: Any? = »nonNullable ?: null«, ) diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary import alias/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary import alias/main.sdstest index 4e8c2468..34d52b89 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary import alias/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary import alias/main.sdstest @@ -1,7 +1,7 @@ package tests.validation.style.unnecessaryImportAlias -// $TEST$ no info "This alias can be removed." +# $TEST$ no info "This alias can be removed." from tests.validation.style.unnecessaryImportAlias.other import C »as D« -// $TEST$ info "This alias can be removed." -// $TEST$ info "This alias can be removed." +# $TEST$ info "This alias can be removed." +# $TEST$ info "This alias can be removed." from tests.validation.style.unnecessaryImportAlias.other import C »as C«, C »as C« diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary null safety/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary null safety/main.sdstest index a2bf48ff..273bced1 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary null safety/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary null safety/main.sdstest @@ -13,41 +13,41 @@ segment call( val myFunction = myClass.f; val myFunctionOrNull = myClassOrNull?.f; - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »(() {})()«; - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »1()«; - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »null()«; - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »myFunction()«; - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »myFunctionOrNull()«; - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »unresolved()«; - // $TEST$ info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ info "The receiver is never null, so null-safety is unnecessary." »(() {})?()«; - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »1?()«; - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »null?()«; - // $TEST$ info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ info "The receiver is never null, so null-safety is unnecessary." »myFunction?()«; - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »myFunctionOrNull?()«; - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »unresolved?()«; } @@ -58,38 +58,38 @@ segment indexedAccess( val myList = myClass.l; val myListOrNull = myClassOrNull?.l; - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »[1][0]«; - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »1[0]«; - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »null[0]«; - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »myList[0]«; - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »myListOrNull[0]«; - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »unresolved[0]«; - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »1?[0]«; - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »null?[0]«; - // $TEST$ info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ info "The receiver is never null, so null-safety is unnecessary." »myList?[0]«; - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »myListOrNull?[0]«; - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »unresolved?[0]«; } @@ -97,14 +97,14 @@ class IndexedAccess?, NonNullable sub List>( nullable: Nullable, nonNullable: NonNullable, - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." p1: Any? = »nullable[0]«, - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." p2: Any? = »nonNullable[0]«, - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." p3: Any? = »nullable?[0]«, - // $TEST$ info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ info "The receiver is never null, so null-safety is unnecessary." p4: Any? = »nonNullable?[0]«, ) @@ -112,35 +112,35 @@ segment memberAccess( myClass: MyClass, myClassOrNull: MyClass?, ) { - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »1.a«; - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »null.a«; - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »myClass.a«; - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »myClassOrNull.a«; - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »unresolved.a«; - // $TEST$ info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ info "The receiver is never null, so null-safety is unnecessary." »1?.a«; - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »null?.a«; - // $TEST$ info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ info "The receiver is never null, so null-safety is unnecessary." »myClass?.a«; - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »myClassOrNull?.a«; - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »unresolved?.a«; } @@ -148,13 +148,13 @@ class MemberAccess( nullable: Nullable, nonNullable: NonNullable, - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." p1: Any? = »nullable.a«, - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." p2: Any? = »nonNullable.a«, - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." p3: Any? = »nullable?.a«, - // $TEST$ info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ info "The receiver is never null, so null-safety is unnecessary." p4: Any? = »nonNullable?.a«, ) diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary parameter list in annotation/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary parameter list in annotation/main.sdstest index 9cdeefb3..85e0854d 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary parameter list in annotation/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary parameter list in annotation/main.sdstest @@ -1,7 +1,7 @@ package tests.validation.style.unnecessaryParameterListInAnnotation -// $TEST$ info "This parameter list can be removed." +# $TEST$ info "This parameter list can be removed." annotation MyAnnotation1»()« -// $TEST$ no info "This parameter list can be removed." +# $TEST$ no info "This parameter list can be removed." annotation MyAnnotation2»(a: Int)« diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary parameter list in enum variant/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary parameter list in enum variant/main.sdstest index 90c689b0..2caf017f 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary parameter list in enum variant/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary parameter list in enum variant/main.sdstest @@ -1,7 +1,7 @@ package tests.validation.style.unnecessaryParameterListInEnumVariant -// $TEST$ info "This parameter list can be removed." +# $TEST$ info "This parameter list can be removed." annotation MyAnnotation1»()« -// $TEST$ no info "This parameter list can be removed." +# $TEST$ no info "This parameter list can be removed." annotation MyAnnotation2»(a: Int)« diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary result list in function/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary result list in function/main.sdstest index edb55960..6e116a0c 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary result list in function/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary result list in function/main.sdstest @@ -1,7 +1,7 @@ package tests.validation.style.unnecessaryResultListInFunction -// $TEST$ info "This result list can be removed." +# $TEST$ info "This result list can be removed." fun myFun1() »-> ()« -// $TEST$ no info "This result list can be removed." +# $TEST$ no info "This result list can be removed." fun myFun2() »-> (r: Int)« diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary result list in segment/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary result list in segment/main.sdstest index baea207e..ec71f7e6 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary result list in segment/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary result list in segment/main.sdstest @@ -1,7 +1,7 @@ package tests.validation.style.unnecessaryResultListInSegment -// $TEST$ info "This result list can be removed." +# $TEST$ info "This result list can be removed." segment mySegment1() »-> ()« {} -// $TEST$ no info "This result list can be removed." +# $TEST$ no info "This result list can be removed." segment mySegment2() »-> (r: Int)« {} diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary type argument list/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary type argument list/main.sdstest index ecc14ba0..0105e424 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary type argument list/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary type argument list/main.sdstest @@ -5,21 +5,21 @@ class ClassWithEmptyTypeParameterList<> class ClassWithTypeParameters fun myFunction( - // $TEST$ info "This type argument list can be removed." + # $TEST$ info "This type argument list can be removed." a1: ClassWithoutTypeParameterList»<>«, - // $TEST$ no info "This type argument list can be removed." + # $TEST$ no info "This type argument list can be removed." a2: ClassWithoutTypeParameterList»«, - // $TEST$ info "This type argument list can be removed." + # $TEST$ info "This type argument list can be removed." a3: ClassWithEmptyTypeParameterList»<>«, - // $TEST$ no info "This type argument list can be removed." + # $TEST$ no info "This type argument list can be removed." a4: ClassWithEmptyTypeParameterList»«, - // $TEST$ no info "This type argument list can be removed." + # $TEST$ no info "This type argument list can be removed." a5: ClassWithTypeParameters»<>«, - // $TEST$ no info "This type argument list can be removed." + # $TEST$ no info "This type argument list can be removed." a6: ClassWithTypeParameters»«, - // $TEST$ no info "This type argument list can be removed." + # $TEST$ no info "This type argument list can be removed." d1: Unresolved»<>«, - // $TEST$ no info "This type argument list can be removed." + # $TEST$ no info "This type argument list can be removed." d2: Unresolved»«, ) diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary type parameter list in class/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary type parameter list in class/main.sdstest index 8d3f68db..ebe8411f 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary type parameter list in class/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary type parameter list in class/main.sdstest @@ -1,7 +1,7 @@ package tests.validation.style.unnecessaryTypeParameterListInClass -// $TEST$ info "This type parameter list can be removed." +# $TEST$ info "This type parameter list can be removed." class MyClass1»<>« -// $TEST$ no info "This type parameter list can be removed." +# $TEST$ no info "This type parameter list can be removed." class MyClass2»« diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary type parameter list in function/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary type parameter list in function/main.sdstest index 8c67cca9..eeed1e9f 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary type parameter list in function/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary type parameter list in function/main.sdstest @@ -1,7 +1,7 @@ package tests.validation.style.unnecessaryTypeParameterListInFunction -// $TEST$ info "This type parameter list can be removed." +# $TEST$ info "This type parameter list can be removed." fun myFunction1»<>«() -// $TEST$ no info "This type parameter list can be removed." +# $TEST$ no info "This type parameter list can be removed." fun myFunction2»«() diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary union type/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary union type/main.sdstest index 451142b8..f078b0ed 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary union type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary union type/main.sdstest @@ -1,16 +1,16 @@ package tests.validation.style.unnecessaryUnionType -// $TEST$ no info "This can be replaced by the singular type argument of the union type." +# $TEST$ no info "This can be replaced by the singular type argument of the union type." segment mySegment1( p: »union<>« ) {} -// $TEST$ info "This can be replaced by the singular type argument of the union type." +# $TEST$ info "This can be replaced by the singular type argument of the union type." segment mySegment2( p: »union« ) {} -// $TEST$ no info "This can be replaced by the singular type argument of the union type." +# $TEST$ no info "This can be replaced by the singular type argument of the union type." segment mySegment3( p: »union« ) {} diff --git a/packages/ttsl-lang/tests/resources/validation/types/checking/arguments/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/checking/arguments/main.sdstest index 95aa5c2f..9e86a4a4 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/checking/arguments/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/checking/arguments/main.sdstest @@ -3,18 +3,18 @@ package tests.validation.types.checking.arguments fun f(p: Int) segment mySegment() { - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." f(»1«); - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." f(p = »1«); - // $TEST$ error "Expected type 'Int' but got 'literal<"">'." + # $TEST$ error "Expected type 'Int' but got 'literal<"">'." f(»""«); - // $TEST$ error "Expected type 'Int' but got 'literal<"">'." + # $TEST$ error "Expected type 'Int' but got 'literal<"">'." f(p = »""«); - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." f(unresolved = »1«); } diff --git a/packages/ttsl-lang/tests/resources/validation/types/checking/arguments/with type parameters.sdstest b/packages/ttsl-lang/tests/resources/validation/types/checking/arguments/with type parameters.sdstest index c1bb33da..379f84fa 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/checking/arguments/with type parameters.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/checking/arguments/with type parameters.sdstest @@ -26,50 +26,50 @@ segment mySegment( number: Number, contravariantInt: Contravariant, ) { - // $TEST$ no error r"Expected type .* but got .*\." - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." C1(»1«, »2«); - // $TEST$ no error r"Expected type .* but got .*\." - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." C1(»1«, »int«); - // $TEST$ no error r"Expected type .* but got .*\." - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." C2(»1«, »2«); - // $TEST$ no error r"Expected type .* but got .*\." - // $TEST$ error "Expected type 'Number' but got 'literal<"">'." + # $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ error "Expected type 'Number' but got 'literal<"">'." C2(»1«, »""«); - // $TEST$ no error r"Expected type .* but got .*\." - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." C3(»1«, »contravariantInt«); - // $TEST$ no error r"Expected type .* but got .*\." - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." C3(»int«, »contravariantInt«); - // $TEST$ no error r"Expected type .* but got .*\." - // $TEST$ error "Expected type 'Contravariant' but got 'Contravariant'." + # $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ error "Expected type 'Contravariant' but got 'Contravariant'." C3(»number«, »contravariantInt«); - // $TEST$ no error r"Expected type .* but got .*\." - // $TEST$ error "Expected type 'Contravariant>' but got 'Contravariant'." + # $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ error "Expected type 'Contravariant>' but got 'Contravariant'." C3(»""«, »contravariantInt«); - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." f(»(p) -> p«); - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." f(»(p) -> 1«); - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." f(»(p: Int) -> p«); - // $TEST$ error "Expected type '(p: Int) -> (r: Int)' but got '(p: Int) -> (result: literal<"">)'." + # $TEST$ error "Expected type '(p: Int) -> (r: Int)' but got '(p: Int) -> (result: literal<"">)'." f(»(p: Int) -> ""«); } diff --git a/packages/ttsl-lang/tests/resources/validation/types/checking/call receiver/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/checking/call receiver/main.sdstest index 979cf38d..aad2ea50 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/checking/call receiver/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/checking/call receiver/main.sdstest @@ -32,66 +32,66 @@ segment mySegment2( val blockLambda = () {}; val expressionLambda = () -> 1; - // $TEST$ no error "This expression is not callable." + # $TEST$ no error "This expression is not callable." »MyAnnotation«(); - // $TEST$ error "This expression is not callable." + # $TEST$ error "This expression is not callable." val myAnnotationAlias = MyAnnotation; »myAnnotationAlias«(); - // $TEST$ no error "This expression is not callable." + # $TEST$ no error "This expression is not callable." »MyClass«(); - // $TEST$ error "This expression is not callable." + # $TEST$ error "This expression is not callable." »MyClass.myAttribute«(); - // $TEST$ no error "This expression is not callable." + # $TEST$ no error "This expression is not callable." »MyClass.MyClass«(); - // $TEST$ error "This expression is not callable." + # $TEST$ error "This expression is not callable." »MyClass.MyEnum«(); - // $TEST$ no error "This expression is not callable." + # $TEST$ no error "This expression is not callable." »MyClass.myFunction«(); - // $TEST$ error "This expression is not callable." + # $TEST$ error "This expression is not callable." »MyEnum«(); - // $TEST$ no error "This expression is not callable." + # $TEST$ no error "This expression is not callable." »MyEnum.MySimpleEnumVariant«(); - // $TEST$ no error "This expression is not callable." + # $TEST$ no error "This expression is not callable." »MyEnum.MyComplexEnumVariant«(); - // $TEST$ no error "This expression is not callable." + # $TEST$ no error "This expression is not callable." »myFunction«(); - // $TEST$ no error "This expression is not callable." + # $TEST$ no error "This expression is not callable." »myPipeline«(); - // $TEST$ error "This expression is not callable." + # $TEST$ error "This expression is not callable." val myPipelineAlias = MyPipeline; »myPipelineAlias«(); - // $TEST$ no error "This expression is not callable." + # $TEST$ no error "This expression is not callable." »MySchema«(); - // $TEST$ error "This expression is not callable." + # $TEST$ error "This expression is not callable." val mySchemaAlias = MySchema; »mySchemaAlias«(); - // $TEST$ no error "This expression is not callable." + # $TEST$ no error "This expression is not callable." »mySegment1«(); - // $TEST$ error "This expression is not callable." + # $TEST$ error "This expression is not callable." »int«(); - // $TEST$ no error "This expression is not callable." + # $TEST$ no error "This expression is not callable." »callable«(); - // $TEST$ error "This expression is not callable." + # $TEST$ error "This expression is not callable." »intLiteral«(); - // $TEST$ no error "This expression is not callable." + # $TEST$ no error "This expression is not callable." »blockLambda«(); - // $TEST$ no error "This expression is not callable." + # $TEST$ no error "This expression is not callable." »expressionLambda«(); - // $TEST$ no error "This expression is not callable." + # $TEST$ no error "This expression is not callable." »(blockLambda)«(); - // $TEST$ no error "This expression is not callable." + # $TEST$ no error "This expression is not callable." »(expressionLambda)«(); - // $TEST$ error "This expression is not callable." + # $TEST$ error "This expression is not callable." »intOrNull«(); - // $TEST$ no error "This expression is not callable." + # $TEST$ no error "This expression is not callable." »callableOrNull«(); /* @@ -100,14 +100,14 @@ segment mySegment2( * distance to the linking error might be too large. */ - // $TEST$ no error "This expression is not callable." + # $TEST$ no error "This expression is not callable." »unknownGlobal«(); - // $TEST$ no error "This expression is not callable." + # $TEST$ no error "This expression is not callable." »MyClass.unknownMember«(); - // $TEST$ error "This expression is not callable." + # $TEST$ error "This expression is not callable." val alias1 = unknownGlobal; »alias1«(); - // $TEST$ error "This expression is not callable." + # $TEST$ error "This expression is not callable." val alias2 = MyClass.unknownMember; »alias2«(); } diff --git a/packages/ttsl-lang/tests/resources/validation/types/checking/called class must have constructor/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/checking/called class must have constructor/main.sdstest index d42292eb..2f468fc9 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/checking/called class must have constructor/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/checking/called class must have constructor/main.sdstest @@ -6,9 +6,9 @@ class B() pipeline test { - // $TEST$ error "Cannot instantiate a class that has no constructor." + # $TEST$ error "Cannot instantiate a class that has no constructor." val a = »A«(); - // $TEST$ no error "Cannot instantiate a class that has no constructor." + # $TEST$ no error "Cannot instantiate a class that has no constructor." val b = »B«(); } diff --git a/packages/ttsl-lang/tests/resources/validation/types/checking/default values/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/checking/default values/main.sdstest index 8dd59f9b..e246e86f 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/checking/default values/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/checking/default values/main.sdstest @@ -1,19 +1,19 @@ package tests.validation.types.checking.defaultValues fun myFun( - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." param1: Int = »1«, - // $TEST$ error "Expected type 'Int' but got 'literal<"">'." + # $TEST$ error "Expected type 'Int' but got 'literal<"">'." param2: Int = »""«, ) fun myOtherFun(callback: (a: Int) -> ()) segment mySegment() { - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." myOtherFun((a = »1«) {}); - // $TEST$ error "Expected type 'Int' but got 'literal<"">'." + # $TEST$ error "Expected type 'Int' but got 'literal<"">'." myOtherFun((a = »""«) {}); } diff --git a/packages/ttsl-lang/tests/resources/validation/types/checking/default values/with type parameters.sdstest b/packages/ttsl-lang/tests/resources/validation/types/checking/default values/with type parameters.sdstest index 93259f6e..d37b3aeb 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/checking/default values/with type parameters.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/checking/default values/with type parameters.sdstest @@ -1,45 +1,45 @@ package tests.validation.types.checking.defaultValues class SomeClass( - // $TEST$ error "Expected type 'T1' but got 'literal'." + # $TEST$ error "Expected type 'T1' but got 'literal'." a1: T1 = »true«, - // $TEST$ error "Expected type 'T1' but got 'literal<1>'." + # $TEST$ error "Expected type 'T1' but got 'literal<1>'." a2: T1 = »1«, - // $TEST$ error "Expected type 'T2' but got 'literal<"">'." + # $TEST$ error "Expected type 'T2' but got 'literal<"">'." a3: T2 = »""«, - // $TEST$ error "Expected type 'T3' but got 'literal<1>'." + # $TEST$ error "Expected type 'T3' but got 'literal<1>'." a4: T3 = »1«, - // $TEST$ error "Expected type 'T3' but got 'literal<"">'." + # $TEST$ error "Expected type 'T3' but got 'literal<"">'." a5: T3 = »""«, - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." b1: T1 = »a1«, - // $TEST$ error "Expected type 'T2' but got 'T1'." + # $TEST$ error "Expected type 'T2' but got 'T1'." b2: T2 = »a1«, - // $TEST$ error "Expected type 'T1' but got 'T2'." + # $TEST$ error "Expected type 'T1' but got 'T2'." b3: T1 = »a3«, - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." b4: T2 = »a4«, ) @Pure fun someFunction( - // $TEST$ error "Expected type 'T1' but got 'literal'." + # $TEST$ error "Expected type 'T1' but got 'literal'." a1: T1 = »true«, - // $TEST$ error "Expected type 'T1' but got 'literal<1>'." + # $TEST$ error "Expected type 'T1' but got 'literal<1>'." a2: T1 = »1«, - // $TEST$ error "Expected type 'T2' but got 'literal<"">'." + # $TEST$ error "Expected type 'T2' but got 'literal<"">'." a3: T2 = »""«, - // $TEST$ error "Expected type 'T3' but got 'literal<1>'." + # $TEST$ error "Expected type 'T3' but got 'literal<1>'." a4: T3 = »1«, - // $TEST$ error "Expected type 'T3' but got 'literal<"">'." + # $TEST$ error "Expected type 'T3' but got 'literal<"">'." a5: T3 = »""«, - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." b1: T1 = »a1«, - // $TEST$ error "Expected type 'T2' but got 'T1'." + # $TEST$ error "Expected type 'T2' but got 'T1'." b2: T2 = »a1«, - // $TEST$ error "Expected type 'T1' but got 'T2'." + # $TEST$ error "Expected type 'T1' but got 'T2'." b3: T1 = »a3«, - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." b4: T2 = »a4«, ) diff --git a/packages/ttsl-lang/tests/resources/validation/types/checking/indexed access on list/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/checking/indexed access on list/main.sdstest index dd10f865..dbf4d841 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/checking/indexed access on list/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/checking/indexed access on list/main.sdstest @@ -4,25 +4,25 @@ package tests.validation.types.checking.indexedAccessOnList @Pure fun index() -> index: Int pipeline myPipeline { - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." [0][»0«]; - // $TEST$ error "Expected type 'Int' but got 'literal<"">'." + # $TEST$ error "Expected type 'Int' but got 'literal<"">'." [0][»""«]; - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." [0][»index()«]; - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." list()[»0«]; - // $TEST$ error "Expected type 'Int' but got 'literal<"">'." + # $TEST$ error "Expected type 'Int' but got 'literal<"">'." list()[»""«]; - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." list()[»index()«]; - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." unresolved[»""«]; } @@ -30,6 +30,6 @@ pipeline myPipeline { class MyClass( p1: T, - // $TEST$ error "Expected type 'Int' but got 'T'." + # $TEST$ error "Expected type 'Int' but got 'T'." a: Any? = [0][»p1«], ) diff --git a/packages/ttsl-lang/tests/resources/validation/types/checking/indexed access on map/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/checking/indexed access on map/main.sdstest index c47863f9..11651e6b 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/checking/indexed access on map/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/checking/indexed access on map/main.sdstest @@ -4,25 +4,25 @@ package tests.validation.types.checking.indexedAccessOnMap @Pure fun key() -> key: String pipeline myPipeline { - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." {"": ""}[»""«]; - // $TEST$ error "Expected type 'String' but got 'literal<1>'." + # $TEST$ error "Expected type 'String' but got 'literal<1>'." {"": ""}[»1«]; - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." {"": ""}[»key()«]; - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." map()[»""«]; - // $TEST$ error "Expected type 'String' but got 'literal<1>'." + # $TEST$ error "Expected type 'String' but got 'literal<1>'." map()[»1«]; - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." map()[»key()«]; - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." unresolved[»""«]; } @@ -31,13 +31,13 @@ class MyMap sub Map segment mySegment( myMap: MyMap, ) { - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." myMap[»""«]; - // $TEST$ error "Expected type 'String' but got 'literal<1>'." + # $TEST$ error "Expected type 'String' but got 'literal<1>'." myMap[»1«]; - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." myMap[»key()«]; } @@ -45,6 +45,6 @@ segment mySegment( class MyClass( p1: T, - // $TEST$ error "Expected type 'String' but got 'T'." + # $TEST$ error "Expected type 'String' but got 'T'." a: Any? = {"": ""}[»p1«], ) diff --git a/packages/ttsl-lang/tests/resources/validation/types/checking/indexed access receiver/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/checking/indexed access receiver/main.sdstest index 7486419b..761a23ab 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/checking/indexed access receiver/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/checking/indexed access receiver/main.sdstest @@ -11,25 +11,25 @@ segment mySegment( myList: MyList, myMap: MyMap, ) { - // $TEST$ no error r"Expected type 'List' or 'Map' but got .*\." + # $TEST$ no error r"Expected type 'List' or 'Map' but got .*\." »[1]«[0]; - // $TEST$ no error r"Expected type 'List' or 'Map' but got .*\." + # $TEST$ no error r"Expected type 'List' or 'Map' but got .*\." »{0: 1}«[0]; - // $TEST$ error "Expected type 'List' or 'Map' but got 'literal<1>'." + # $TEST$ error "Expected type 'List' or 'Map' but got 'literal<1>'." »1«[0]; - // $TEST$ no error r"Expected type 'List' or 'Map' but got .*\." + # $TEST$ no error r"Expected type 'List' or 'Map' but got .*\." »listOrNull«[0]; - // $TEST$ no error r"Expected type 'List' or 'Map' but got .*\." + # $TEST$ no error r"Expected type 'List' or 'Map' but got .*\." »mapOrNull«[""]; - // $TEST$ error "Expected type 'List' or 'Map' but got 'Int?'." + # $TEST$ error "Expected type 'List' or 'Map' but got 'Int?'." »intOrNull«[0]; - // $TEST$ no error r"Expected type 'List' or 'Map' but got .*\." + # $TEST$ no error r"Expected type 'List' or 'Map' but got .*\." »myList«[0]; - // $TEST$ no error r"Expected type 'List' or 'Map' but got .*\." + # $TEST$ no error r"Expected type 'List' or 'Map' but got .*\." »myMap«[""]; - // $TEST$ error "Expected type 'List' or 'Map' but got '$unknown'." + # $TEST$ error "Expected type 'List' or 'Map' but got '$unknown'." »unresolved«[0]; } @@ -37,6 +37,6 @@ segment mySegment( class MyClass( p1: T, - // $TEST$ error "Expected type 'List' or 'Map' but got 'T'." + # $TEST$ error "Expected type 'List' or 'Map' but got 'T'." p2: Any? = »p1«[0], ) diff --git a/packages/ttsl-lang/tests/resources/validation/types/checking/infix operations/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/checking/infix operations/main.sdstest index ecb4643d..943cff73 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/checking/infix operations/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/checking/infix operations/main.sdstest @@ -2,130 +2,130 @@ package tests.validation.types.checking.infixOperations pipeline myPipeline { - // $TEST$ no error r"Expected type 'Boolean' but got .*\." - // $TEST$ no error r"Expected type 'Boolean' but got .*\." + # $TEST$ no error r"Expected type 'Boolean' but got .*\." + # $TEST$ no error r"Expected type 'Boolean' but got .*\." »true« or »true« ; - // $TEST$ error "Expected type 'Boolean' but got 'literal<0>'." - // $TEST$ error "Expected type 'Boolean' but got 'literal<0>'." + # $TEST$ error "Expected type 'Boolean' but got 'literal<0>'." + # $TEST$ error "Expected type 'Boolean' but got 'literal<0>'." »0« or »0«; - // $TEST$ error "Expected type 'Boolean' but got '$unknown'." - // $TEST$ error "Expected type 'Boolean' but got '$unknown'." + # $TEST$ error "Expected type 'Boolean' but got '$unknown'." + # $TEST$ error "Expected type 'Boolean' but got '$unknown'." »unresolved« or »unresolved«; - // $TEST$ no error r"Expected type 'Boolean' but got .*\." - // $TEST$ no error r"Expected type 'Boolean' but got .*\." + # $TEST$ no error r"Expected type 'Boolean' but got .*\." + # $TEST$ no error r"Expected type 'Boolean' but got .*\." »true« and »true«; - // $TEST$ error "Expected type 'Boolean' but got 'literal<0>'." - // $TEST$ error "Expected type 'Boolean' but got 'literal<0>'." + # $TEST$ error "Expected type 'Boolean' but got 'literal<0>'." + # $TEST$ error "Expected type 'Boolean' but got 'literal<0>'." »0« and »0«; - // $TEST$ error "Expected type 'Boolean' but got '$unknown'." - // $TEST$ error "Expected type 'Boolean' but got '$unknown'." + # $TEST$ error "Expected type 'Boolean' but got '$unknown'." + # $TEST$ error "Expected type 'Boolean' but got '$unknown'." »unresolved« and »unresolved«; - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." »0.0« + »0.0«; - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." »0« + »0«; - // $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." - // $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." »""« + »""«; - // $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." - // $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." + # $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." + # $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." »unresolved« + »unresolved«; - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." »0.0« - »0.0«; - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." »0« - »0«; - // $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." - // $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." »""« - »""«; - // $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." - // $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." + # $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." + # $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." »unresolved« - »unresolved«; - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." »0.0« * »0.0«; - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." »0« * »0«; - // $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." - // $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." »""« * »""«; - // $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." - // $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." + # $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." + # $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." »unresolved« * »unresolved«; - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." »0.0« / »0.0«; - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." »0« / »0«; - // $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." - // $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." »""« / »""«; - // $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." - // $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." + # $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." + # $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." »unresolved« / »unresolved«; - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." »0.0« < »0.0«; - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." »0« < »0«; - // $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." - // $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." »""« < »""«; - // $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." - // $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." + # $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." + # $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." »unresolved« < »unresolved«; - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." »0.0« <= »0.0«; - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." »0« <= »0«; - // $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." - // $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." »""« <= »""«; - // $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." - // $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." + # $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." + # $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." »unresolved« <= »unresolved«; - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." »0.0« >= »0.0«; - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." »0« >= »0«; - // $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." - // $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." »""« >= »""«; - // $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." - // $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." + # $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." + # $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." »unresolved« >= »unresolved«; - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." »0.0« > »0.0«; - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." »0« > »0«; - // $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." - // $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." »""« > »""«; - // $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." - // $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." + # $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." + # $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." »unresolved« > »unresolved«; } @@ -133,36 +133,36 @@ pipeline myPipeline { class MyClass( p1: T, - // $TEST$ error "Expected type 'Boolean' but got 'T'." - // $TEST$ error "Expected type 'Boolean' but got 'T'." + # $TEST$ error "Expected type 'Boolean' but got 'T'." + # $TEST$ error "Expected type 'Boolean' but got 'T'." a1: Any? = »p1« or »p1«, - // $TEST$ error "Expected type 'Boolean' but got 'T'." - // $TEST$ error "Expected type 'Boolean' but got 'T'." + # $TEST$ error "Expected type 'Boolean' but got 'T'." + # $TEST$ error "Expected type 'Boolean' but got 'T'." a2: Any? = »p1« and »p1«, - // $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." - // $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." b1: Any? = »p1« + »p1«, - // $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." - // $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." b2: Any? = »p1« - »p1«, - // $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." - // $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." b3: Any? = »p1« * »p1«, - // $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." - // $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." b4: Any? = »p1« / »p1«, - // $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." - // $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." c1: Any? = »p1« < »p1«, - // $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." - // $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." c2: Any? = »p1« <= »p1«, - // $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." - // $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." c3: Any? = »p1« >= »p1«, - // $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." - // $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." c4: Any? = »p1« > »p1«, ) diff --git a/packages/ttsl-lang/tests/resources/validation/types/checking/lists/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/checking/lists/main.sdstest index aa7a127a..d5a8dea5 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/checking/lists/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/checking/lists/main.sdstest @@ -6,11 +6,11 @@ fun twoResults() -> (r1: Int, r2: Int) segment mySegment() { [ - // $TEST$ error "Cannot add a value of type '()' to a list." + # $TEST$ error "Cannot add a value of type '()' to a list." »noResults()«, - // $TEST$ no error r"Cannot add a value of type '.*' to a list\." + # $TEST$ no error r"Cannot add a value of type '.*' to a list\." »oneResult()«, - // $TEST$ error "Cannot add a value of type '(r1: Int, r2: Int)' to a list." + # $TEST$ error "Cannot add a value of type '(r1: Int, r2: Int)' to a list." »twoResults()« ]; } diff --git a/packages/ttsl-lang/tests/resources/validation/types/checking/maps/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/checking/maps/main.sdstest index 5ad3501f..b2786291 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/checking/maps/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/checking/maps/main.sdstest @@ -6,14 +6,14 @@ fun twoResults() -> (r1: Int, r2: Int) segment mySegment() { { - // $TEST$ error "Cannot use a value of type '()' as a map key." - // $TEST$ error "Cannot use a value of type '()' as a map value." + # $TEST$ error "Cannot use a value of type '()' as a map key." + # $TEST$ error "Cannot use a value of type '()' as a map value." »noResults()«: »noResults()«, - // $TEST$ no error r"Cannot use a value of type '.*' as a map key\." - // $TEST$ no error r"Cannot use a value of type '.*' as a map value\." + # $TEST$ no error r"Cannot use a value of type '.*' as a map key\." + # $TEST$ no error r"Cannot use a value of type '.*' as a map value\." »oneResult()«: »oneResult()«, - // $TEST$ error "Cannot use a value of type '(r1: Int, r2: Int)' as a map key." - // $TEST$ error "Cannot use a value of type '(r1: Int, r2: Int)' as a map value." + # $TEST$ error "Cannot use a value of type '(r1: Int, r2: Int)' as a map key." + # $TEST$ error "Cannot use a value of type '(r1: Int, r2: Int)' as a map value." »twoResults()«: »twoResults()« }; } diff --git a/packages/ttsl-lang/tests/resources/validation/types/checking/prefix operations/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/checking/prefix operations/main.sdstest index 5a1c9fcc..96583b8e 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/checking/prefix operations/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/checking/prefix operations/main.sdstest @@ -2,20 +2,20 @@ package tests.validation.types.checking.prefixOperations segment mySegment() { - // $TEST$ no error r"Expected type 'Boolean' but got .*\." + # $TEST$ no error r"Expected type 'Boolean' but got .*\." not »true«; - // $TEST$ error "Expected type 'Boolean' but got 'literal<0>'." + # $TEST$ error "Expected type 'Boolean' but got 'literal<0>'." not »0«; - // $TEST$ error "Expected type 'Boolean' but got '$unknown'." + # $TEST$ error "Expected type 'Boolean' but got '$unknown'." not »unresolved«; - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." -»0.0«; - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." -»0«; - // $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." -»""«; - // $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." + # $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." -»unresolved«; } @@ -23,9 +23,9 @@ segment mySegment() { class MyClass( p1: T, - // $TEST$ error "Expected type 'Boolean' but got 'T'." + # $TEST$ error "Expected type 'Boolean' but got 'T'." a: Any? = not »p1«, - // $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." b: Any? = -»p1«, ) diff --git a/packages/ttsl-lang/tests/resources/validation/types/checking/type casts/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/checking/type casts/main.sdstest index 10308aa4..950846d7 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/checking/type casts/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/checking/type casts/main.sdstest @@ -1,9 +1,9 @@ package tests.validation.types.checking.typeCasts pipeline test { - // $TEST$ no error "Type casts can only be applied to expressions of unknown type." + # $TEST$ no error "Type casts can only be applied to expressions of unknown type." »unresolved« as Int; - // $TEST$ error "Type casts can only be applied to expressions of unknown type." + # $TEST$ error "Type casts can only be applied to expressions of unknown type." »1« as Int; } diff --git a/packages/ttsl-lang/tests/resources/validation/types/checking/type parameter bounds for default values/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/checking/type parameter bounds for default values/main.sdstest index 08129ba3..eafdceea 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/checking/type parameter bounds for default values/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/checking/type parameter bounds for default values/main.sdstest @@ -2,60 +2,60 @@ package tests.validation.types.checking.typeParameterBoundsForDefaultValues class C1< T1 sub Any, - // $TEST$ error "Expected type 'Number' but got 'T1'." + # $TEST$ error "Expected type 'Number' but got 'T1'." T2 sub Number = »T1«, - // $TEST$ error "Expected type 'Number' but got 'Any'." + # $TEST$ error "Expected type 'Number' but got 'Any'." T3 sub Number = »Any«, - // $TEST$ error "Expected type 'T1' but got 'Any'." + # $TEST$ error "Expected type 'T1' but got 'Any'." T4 sub T1 = »Any«, > class C2< T1 sub Number, - // $TEST$ no error r"Expected type '.*' but got '.*'\." + # $TEST$ no error r"Expected type '.*' but got '.*'\." T2 sub Number = »T1«, - // $TEST$ no error r"Expected type '.*' but got '.*'\." + # $TEST$ no error r"Expected type '.*' but got '.*'\." T3 sub Number = »Number«, - // $TEST$ no error r"Expected type '.*' but got '.*'\." + # $TEST$ no error r"Expected type '.*' but got '.*'\." T4 sub T1 = »T1«, - // $TEST$ error "Expected type 'T1' but got 'T2'." + # $TEST$ error "Expected type 'T1' but got 'T2'." T5 sub T1 = »T2«, > class C3< T1 sub Int, - // $TEST$ no error r"Expected type '.*' but got '.*'\." + # $TEST$ no error r"Expected type '.*' but got '.*'\." T2 sub Number = »T1«, - // $TEST$ no error r"Expected type '.*' but got '.*'\." + # $TEST$ no error r"Expected type '.*' but got '.*'\." T3 sub Number = »Int«, - // $TEST$ no error r"Expected type '.*' but got '.*'\." + # $TEST$ no error r"Expected type '.*' but got '.*'\." T4 sub T1 = »Nothing«, > @Pure fun f1< T1 sub Any, - // $TEST$ error "Expected type 'Number' but got 'T1'." + # $TEST$ error "Expected type 'Number' but got 'T1'." T2 sub Number = »T1«, - // $TEST$ error "Expected type 'Number' but got 'Any'." + # $TEST$ error "Expected type 'Number' but got 'Any'." T3 sub Number = »Any«, - // $TEST$ error "Expected type 'T1' but got 'Any'." + # $TEST$ error "Expected type 'T1' but got 'Any'." T4 sub T1 = »Any«, >() @Pure fun f2< T1 sub Number, - // $TEST$ no error r"Expected type '.*' but got '.*'\." + # $TEST$ no error r"Expected type '.*' but got '.*'\." T2 sub Number = »T1«, - // $TEST$ no error r"Expected type '.*' but got '.*'\." + # $TEST$ no error r"Expected type '.*' but got '.*'\." T3 sub Number = »Number«, - // $TEST$ no error r"Expected type '.*' but got '.*'\." + # $TEST$ no error r"Expected type '.*' but got '.*'\." T4 sub T1 = »T1«, - // $TEST$ error "Expected type 'T1' but got 'T2'." + # $TEST$ error "Expected type 'T1' but got 'T2'." T5 sub T1 = »T2«, >() @Pure fun f3< T1 sub Int, - // $TEST$ no error r"Expected type '.*' but got '.*'\." + # $TEST$ no error r"Expected type '.*' but got '.*'\." T2 sub Number = »T1«, - // $TEST$ no error r"Expected type '.*' but got '.*'\." + # $TEST$ no error r"Expected type '.*' but got '.*'\." T3 sub Number = »Int«, - // $TEST$ no error r"Expected type '.*' but got '.*'\." + # $TEST$ no error r"Expected type '.*' but got '.*'\." T4 sub T1 = »Nothing«, >() diff --git a/packages/ttsl-lang/tests/resources/validation/types/checking/type parameter bounds for named types/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/checking/type parameter bounds for named types/main.sdstest index 6b929029..3fe0f1dc 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/checking/type parameter bounds for named types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/checking/type parameter bounds for named types/main.sdstest @@ -5,29 +5,29 @@ class C2 class C3 @Pure fun f( - // $TEST$ no error r"Expected type '.*' but got '.*'\." + # $TEST$ no error r"Expected type '.*' but got '.*'\." a1: C1<»Any?«>, - // $TEST$ no error r"Expected type '.*' but got '.*'\." + # $TEST$ no error r"Expected type '.*' but got '.*'\." a2: C1, - // $TEST$ no error r"Expected type '.*' but got '.*'\." + # $TEST$ no error r"Expected type '.*' but got '.*'\." a3: C1, - // $TEST$ no error r"Expected type '.*' but got '.*'\." + # $TEST$ no error r"Expected type '.*' but got '.*'\." a4: C1<»T«>, - // $TEST$ no error r"Expected type '.*' but got '.*'\." + # $TEST$ no error r"Expected type '.*' but got '.*'\." b1: C2<»Number«>, - // $TEST$ error "Expected type 'Number' but got 'String'." + # $TEST$ error "Expected type 'Number' but got 'String'." b2: C2<»String«>, - // $TEST$ error "Expected type 'Number' but got 'T'." + # $TEST$ error "Expected type 'Number' but got 'T'." b3: C2<»T«>, - // $TEST$ no error r"Expected type '.*' but got '.*'\." - // $TEST$ no error r"Expected type '.*' but got '.*'\." + # $TEST$ no error r"Expected type '.*' but got '.*'\." + # $TEST$ no error r"Expected type '.*' but got '.*'\." c1: C3<»Number«, »Number«>, - // $TEST$ no error r"Expected type '.*' but got '.*'\." - // $TEST$ no error r"Expected type '.*' but got '.*'\." + # $TEST$ no error r"Expected type '.*' but got '.*'\." + # $TEST$ no error r"Expected type '.*' but got '.*'\." c2: C3<»Number«, »Int«>, - // $TEST$ no error r"Expected type '.*' but got '.*'\." - // $TEST$ error "Expected type 'Int' but got 'Number'." + # $TEST$ no error r"Expected type '.*' but got '.*'\." + # $TEST$ error "Expected type 'Int' but got 'Number'." c3: C3<»Int«, »Number«>, ) diff --git a/packages/ttsl-lang/tests/resources/validation/types/checking/yields/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/checking/yields/main.sdstest index 79a363df..3cdf080c 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/checking/yields/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/checking/yields/main.sdstest @@ -1,16 +1,16 @@ package tests.validation.types.checking.yields segment mySegment1() -> result: Int { - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." yield »result« = 1; } segment mySegment2() -> result: Int { - // $TEST$ error "Expected type 'Int' but got 'literal<"">'." + # $TEST$ error "Expected type 'Int' but got 'literal<"">'." yield »result« = ""; } segment mySegment3() { - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." yield »unresolved« = 1; } diff --git a/packages/ttsl-lang/tests/resources/validation/types/named types/missing required type parameter/dont show this error if the type argument list is missing altogether.sdstest b/packages/ttsl-lang/tests/resources/validation/types/named types/missing required type parameter/dont show this error if the type argument list is missing altogether.sdstest index 1ee6c48c..c80089de 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/named types/missing required type parameter/dont show this error if the type argument list is missing altogether.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/named types/missing required type parameter/dont show this error if the type argument list is missing altogether.sdstest @@ -1,6 +1,6 @@ package tests.validation.other.namedTypes.missingRequiredTypeParameter -// $TEST$ no error r"The type parameters? .* must be set here\." +# $TEST$ no error r"The type parameters? .* must be set here\." class MyClass diff --git a/packages/ttsl-lang/tests/resources/validation/types/named types/missing required type parameter/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/named types/missing required type parameter/main.sdstest index 52049aea..f2720e73 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/named types/missing required type parameter/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/named types/missing required type parameter/main.sdstest @@ -5,28 +5,28 @@ class MyClassWithoutTypeParameter class MyClassWithTypeParameters fun myFunction1( - // $TEST$ no error r"The type parameters? .* must be set here\." + # $TEST$ no error r"The type parameters? .* must be set here\." a1: MyClassWithoutTypeParameter»<>«, - // $TEST$ no error r"The type parameters? .* must be set here\." + # $TEST$ no error r"The type parameters? .* must be set here\." a2: MyClassWithoutTypeParameter»«, - // $TEST$ no error r"The type parameters? .* must be set here\." + # $TEST$ no error r"The type parameters? .* must be set here\." a3: MyClassWithoutTypeParameter»«, - // $TEST$ error "The type parameters 'T1', 'T2' must be set here." + # $TEST$ error "The type parameters 'T1', 'T2' must be set here." b1: MyClassWithTypeParameters»<>«, - // $TEST$ error "The type parameter 'T2' must be set here." + # $TEST$ error "The type parameter 'T2' must be set here." b2: MyClassWithTypeParameters»«, - // $TEST$ error "The type parameter 'T1' must be set here." + # $TEST$ error "The type parameter 'T1' must be set here." b3: MyClassWithTypeParameters»«, - // $TEST$ no error r"The type parameters? .* must be set here\." + # $TEST$ no error r"The type parameters? .* must be set here\." b4: MyClassWithTypeParameters»«, - // $TEST$ no error r"The type parameters? .* must be set here\." + # $TEST$ no error r"The type parameters? .* must be set here\." b5: MyClassWithTypeParameters»«, - // $TEST$ no error r"The type parameters? .* must be set here\." + # $TEST$ no error r"The type parameters? .* must be set here\." d1: Unresolved»<>«, - // $TEST$ no error r"The type parameters? .* must be set here\." + # $TEST$ no error r"The type parameters? .* must be set here\." d2: Unresolved»«, - // $TEST$ no error r"The type parameters? .* must be set here\." + # $TEST$ no error r"The type parameters? .* must be set here\." d3: Unresolved»«, ) diff --git a/packages/ttsl-lang/tests/resources/validation/types/named types/missing type argument list/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/named types/missing type argument list/main.sdstest index e7793cda..1b6302da 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/named types/missing type argument list/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/named types/missing type argument list/main.sdstest @@ -5,23 +5,23 @@ class MyClassWithRequiredTypeParameters class MyClassWithOptionalTypeParameters fun myFunction( - // $TEST$ no error r"The type '\w*' has required type parameters, so a type argument list must be added\." + # $TEST$ no error r"The type '\w*' has required type parameters, so a type argument list must be added\." a1: »MyClassWithoutTypeParameters«, - // $TEST$ no error r"The type '\w*' has required type parameters, so a type argument list must be added\." + # $TEST$ no error r"The type '\w*' has required type parameters, so a type argument list must be added\." a2: »MyClassWithoutTypeParameters«<>, - // $TEST$ error "The type 'MyClassWithRequiredTypeParameters' has required type parameters, so a type argument list must be added." + # $TEST$ error "The type 'MyClassWithRequiredTypeParameters' has required type parameters, so a type argument list must be added." b1: »MyClassWithRequiredTypeParameters«, - // $TEST$ no error r"The type '\w*' has required type parameters, so a type argument list must be added\." + # $TEST$ no error r"The type '\w*' has required type parameters, so a type argument list must be added\." b2: »MyClassWithRequiredTypeParameters«<>, - // $TEST$ no error r"The type '\w*' has required type parameters, so a type argument list must be added\." + # $TEST$ no error r"The type '\w*' has required type parameters, so a type argument list must be added\." c1: »MyClassWithOptionalTypeParameters«, - // $TEST$ no error r"The type '\w*' has required type parameters, so a type argument list must be added\." + # $TEST$ no error r"The type '\w*' has required type parameters, so a type argument list must be added\." c2: »MyClassWithOptionalTypeParameters«<>, - // $TEST$ no error r"The type '\w*' has required type parameters, so a type argument list must be added\." + # $TEST$ no error r"The type '\w*' has required type parameters, so a type argument list must be added\." d1: »UnresolvedClass«, - // $TEST$ no error r"The type '\w*' has required type parameters, so a type argument list must be added\." + # $TEST$ no error r"The type '\w*' has required type parameters, so a type argument list must be added\." d2: »UnresolvedClass«<>, ) diff --git a/packages/ttsl-lang/tests/resources/validation/types/type hints/missing for attribute/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/type hints/missing for attribute/main.sdstest index 06b9c856..b8d46c41 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/type hints/missing for attribute/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/type hints/missing for attribute/main.sdstest @@ -1,9 +1,9 @@ package tests.validation.types.typeHints.missingForAttribute class MyClass { - // $TEST$ error "An attribute must have a type hint." + # $TEST$ error "An attribute must have a type hint." attr »myAttribute1« - // $TEST$ no error "An attribute must have a type hint." + # $TEST$ no error "An attribute must have a type hint." attr »myAttribute2«: Int } diff --git a/packages/ttsl-lang/tests/resources/validation/types/type hints/missing for parameter/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/type hints/missing for parameter/main.sdstest index f7250652..1f99516f 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/type hints/missing for parameter/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/type hints/missing for parameter/main.sdstest @@ -1,39 +1,39 @@ package tests.validation.types.typeHints.missingForParameter -// $TEST$ error "A parameter must have a type hint." -// $TEST$ no error "A parameter must have a type hint." +# $TEST$ error "A parameter must have a type hint." +# $TEST$ no error "A parameter must have a type hint." annotation MyAnnotation(»a«, »b«: Int) -// $TEST$ error "A parameter must have a type hint." -// $TEST$ no error "A parameter must have a type hint." +# $TEST$ error "A parameter must have a type hint." +# $TEST$ no error "A parameter must have a type hint." class MyClass(»a«, »b«: Int) { - // $TEST$ error "A parameter must have a type hint." - // $TEST$ no error "A parameter must have a type hint." + # $TEST$ error "A parameter must have a type hint." + # $TEST$ no error "A parameter must have a type hint." class MyClass(»a«, »b«: Int) {} - // $TEST$ error "A parameter must have a type hint." - // $TEST$ no error "A parameter must have a type hint." + # $TEST$ error "A parameter must have a type hint." + # $TEST$ no error "A parameter must have a type hint." fun myFunction(»a«, »b«: Int) } -// $TEST$ error "A parameter must have a type hint." -// $TEST$ no error "A parameter must have a type hint." +# $TEST$ error "A parameter must have a type hint." +# $TEST$ no error "A parameter must have a type hint." fun myFunction(»a«, »b«: Int) pipeline myPipeline { - // $TEST$ no error "A parameter must have a type hint." + # $TEST$ no error "A parameter must have a type hint." (»a«) -> a; - // $TEST$ no error "A parameter must have a type hint." + # $TEST$ no error "A parameter must have a type hint." (»a«) {}; } -// $TEST$ error "A parameter must have a type hint." -// $TEST$ no error "A parameter must have a type hint." +# $TEST$ error "A parameter must have a type hint." +# $TEST$ no error "A parameter must have a type hint." segment mySegment1(»a«, »b«: Int) {} -// $TEST$ error "A parameter must have a type hint." -// $TEST$ no error "A parameter must have a type hint." +# $TEST$ error "A parameter must have a type hint." +# $TEST$ no error "A parameter must have a type hint." segment mySegment2( f: (»a«, »b«: Int) -> () ) {} diff --git a/packages/ttsl-lang/tests/resources/validation/types/type hints/missing for result/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/type hints/missing for result/main.sdstest index 29e4df16..3382cbf0 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/type hints/missing for result/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/type hints/missing for result/main.sdstest @@ -1,21 +1,21 @@ package tests.validation.types.typeHints.missingForResult class MyClass { - // $TEST$ error "A result must have a type hint." - // $TEST$ no error "A result must have a type hint." + # $TEST$ error "A result must have a type hint." + # $TEST$ no error "A result must have a type hint." fun myFunction() -> (»a«, »b«: Int) } -// $TEST$ error "A result must have a type hint." -// $TEST$ no error "A result must have a type hint." +# $TEST$ error "A result must have a type hint." +# $TEST$ no error "A result must have a type hint." fun myFunction() -> (»a«, »b«: Int) -// $TEST$ error "A result must have a type hint." -// $TEST$ no error "A result must have a type hint." +# $TEST$ error "A result must have a type hint." +# $TEST$ no error "A result must have a type hint." segment mySegment1() -> (»a«, »b«: Int) {} -// $TEST$ error "A result must have a type hint." -// $TEST$ no error "A result must have a type hint." +# $TEST$ error "A result must have a type hint." +# $TEST$ no error "A result must have a type hint." segment mySegment2( f: () -> (»a«, »b«: Int) ) {} From 859c115a10ba2a49fe6bed7dbe263dba18a001f7 Mon Sep 17 00:00:00 2001 From: methr0 Date: Wed, 15 May 2024 12:29:55 +0200 Subject: [PATCH 024/183] reverse former commit (comments back to // --- docs/development/call-graph-testing.md | 2 +- docs/development/generation-testing.md | 2 +- docs/development/grammar-testing.md | 4 +- .../development/partial-evaluation-testing.md | 6 +- docs/development/scoping-testing.md | 6 +- docs/development/typing-testing.md | 4 +- docs/development/validation-testing.md | 6 +- .../tests/helpers/testChecks.test.ts | 16 +- .../tests/helpers/testComments.test.ts | 6 +- .../ttsl-lang/tests/helpers/testComments.ts | 2 +- .../lsp/safe-ds-inlay-hint-provider.test.ts | 8 +- .../call graph/annotation call.sdstest | 2 +- .../argument/block lambda.sdstest | 2 +- .../callable does not get called.sdstest | 2 +- .../argument/expression lambda.sdstest | 2 +- .../argument/function.sdstest | 2 +- .../argument/segment.sdstest | 2 +- .../block lambda call/basic.sdstest | 2 +- .../function call in nested lambda.sdstest | 2 +- .../body/function call.sdstest | 2 +- .../default value/call.sdstest | 2 +- .../default value/callable.sdstest | 2 +- .../default value/previous parameter.sdstest | 2 +- .../block lambda call/null safe.sdstest | 2 +- .../call graph/callable type call.sdstest | 2 +- .../call graph/callable/block lambda.sdstest | 2 +- .../call graph/callable/class.sdstest | 2 +- .../call graph/callable/enum variant.sdstest | 2 +- .../callable/expression lambda.sdstest | 2 +- .../call graph/callable/function.sdstest | 2 +- .../call graph/callable/segment.sdstest | 2 +- .../class call/argument/call.sdstest | 2 +- .../class call/argument/callable.sdstest | 2 +- .../class call/argument/other.sdstest | 2 +- .../call graph/class call/basic.sdstest | 2 +- .../class call/default value/call.sdstest | 2 +- .../class call/default value/callable.sdstest | 2 +- .../default value/previous parameter.sdstest | 2 +- .../call graph/class call/null safe.sdstest | 2 +- .../block lambda passed as argument.sdstest | 2 +- .../closure/block lambda returned.sdstest | 2 +- ...pression lambda passed as argument.sdstest | 2 +- .../expression lambda returned.sdstest | 2 +- ...ault value handling in entry point.sdstest | 2 +- .../enum variant call/argument/call.sdstest | 2 +- .../argument/callable.sdstest | 2 +- .../enum variant call/argument/other.sdstest | 2 +- .../enum variant call/basic.sdstest | 2 +- .../enum variant call/called twice.sdstest | 2 +- .../default value/call.sdstest | 2 +- .../default value/callable.sdstest | 2 +- .../default value/previous parameter.sdstest | 2 +- .../enum variant call/null safe.sdstest | 2 +- .../argument/block lambda.sdstest | 2 +- .../callable does not get called.sdstest | 2 +- .../argument/expression lambda.sdstest | 2 +- .../argument/function.sdstest | 2 +- .../argument/segment.sdstest | 2 +- .../expression lambda call/basic.sdstest | 2 +- .../function call in nested lambda.sdstest | 2 +- .../body/function call.sdstest | 2 +- .../default value/call.sdstest | 2 +- .../default value/callable.sdstest | 2 +- .../default value/previous parameter.sdstest | 2 +- .../expression lambda call/null safe.sdstest | 2 +- .../function call/argument/call.sdstest | 2 +- .../function call/argument/callable.sdstest | 2 +- .../function call/argument/other.sdstest | 2 +- .../call graph/function call/basic.sdstest | 2 +- .../function call/default value/call.sdstest | 2 +- .../default value/callable.sdstest | 2 +- .../default value/previous parameter.sdstest | 2 +- .../function call/instance method.sdstest | 2 +- .../function call/null safe.sdstest | 8 +- .../function call/static method.sdstest | 2 +- .../call graph/recursion/direct.sdstest | 6 +- .../recursion/not recursive.sdstest | 2 +- ...tive via function pointer argument.sdstest | 2 +- .../transitive via lambda argument.sdstest | 2 +- .../call graph/recursion/transitive.sdstest | 6 +- .../argument/block lambda.sdstest | 2 +- .../callable does not get called.sdstest | 2 +- .../argument/expression lambda.sdstest | 2 +- .../segment call/argument/function.sdstest | 2 +- .../segment call/argument/segment.sdstest | 2 +- .../call graph/segment call/basic.sdstest | 2 +- .../function call in nested lambda.sdstest | 2 +- .../segment call/body/function call.sdstest | 2 +- .../segment call/default value/call.sdstest | 2 +- .../default value/callable.sdstest | 2 +- .../default value/previous parameter.sdstest | 2 +- .../call graph/segment call/null safe.sdstest | 2 +- .../call graph/unresolved callable.sdstest | 2 +- .../formatting/modules/empty.sdstest | 4 +- .../input.sdstest | 2 +- .../input.sdstest | 2 +- .../partial/impure dependency/input.sdstest | 2 +- .../partial/pure dependency/input.sdstest | 2 +- .../partial/redundant impurity/input.sdstest | 2 +- .../bad-unclosed argument list.sdstest | 2 +- .../good-empty argument list.sdstest | 2 +- .../good-multiple arguments.sdstest | 2 +- .../good-named argument.sdstest | 2 +- .../good-no argument list.sdstest | 2 +- .../good-positional argument.sdstest | 2 +- .../bad-unclosed constraint list.sdstest | 2 +- .../bad-unclosed parameter list.sdstest | 2 +- .../annotations/good-annotation call.sdstest | 2 +- .../good-no parameter list.sdstest | 2 +- .../good-with constraint list.sdstest | 2 +- .../good-with parameter list.sdstest | 2 +- .../classes/attributes/good-annotated.sdstest | 2 +- .../classes/attributes/good-no type.sdstest | 2 +- .../classes/attributes/good-static.sdstest | 2 +- .../classes/attributes/good-with type.sdstest | 2 +- .../bad-empty parent type list.sdstest | 2 +- .../classes/bad-unclosed body.sdstest | 2 +- .../bad-unclosed constraint list.sdstest | 2 +- .../bad-unclosed parameter list.sdstest | 2 +- .../bad-unclosed type parameter list.sdstest | 2 +- .../classes/good-annotation call.sdstest | 2 +- .../classes/good-empty body.sdstest | 2 +- .../declarations/classes/good-minimal.sdstest | 2 +- .../good-multiple parent types.sdstest | 2 +- .../classes/good-one parent type.sdstest | 2 +- .../classes/good-with constraint list.sdstest | 2 +- .../classes/good-with parameter list.sdstest | 2 +- .../good-with type parameter list.sdstest | 2 +- .../good-annotated instance method.sdstest | 2 +- .../good-annotated static method.sdstest | 2 +- .../methods/good-instance method.sdstest | 2 +- .../methods/good-static method.sdstest | 2 +- .../good-annotated nested class.sdstest | 2 +- .../nested classes/good-nested-class.sdstest | 2 +- .../good-annotated nested enum.sdstest | 2 +- .../nested enums/good-nested enum.sdstest | 2 +- .../constants/bad-missing name.tsltest | 2 +- .../constants/bad-missing type.tsltest | 2 +- .../constants/bad-missing value.tsltest | 2 +- .../good-with type and value.tsltest | 2 +- .../constraints/bad-missing comma.sdstest | 2 +- .../constraints/good-empty.sdstest | 2 +- .../good-greater than constraint.sdstest | 2 +- ...-greater than or equals constraint.sdstest | 2 +- .../good-less than constraint.sdstest | 2 +- ...ood-less than or equals constraint.sdstest | 2 +- .../good-multiple constraints.sdstest | 2 +- .../data/bad-missing name.tsltest | 2 +- .../data/bad-missing type.tsltest | 2 +- .../data/good-with type and name.tsltest | 2 +- .../enums/bad-unclosed body.sdstest | 2 +- .../enums/good-annotation call.sdstest | 2 +- .../enums/good-empty body.sdstest | 2 +- .../declarations/enums/good-no body.sdstest | 2 +- .../enums/good-variants in body.sdstest | 2 +- .../bad-unclosed constraint list.sdstest | 2 +- .../bad-unclosed parameter list.sdstest | 2 +- .../variants/good-annotation call.sdstest | 2 +- .../variants/good-no parameter list.sdstest | 2 +- .../good-with constraint list.sdstest | 2 +- .../variants/good-with parameter list.sdstest | 2 +- .../bad-missing parameter list.tsltest | 2 +- .../bad-missing parameter type.tsltest | 2 +- .../bad-unclosed parameter list.tsltest | 2 +- .../bad-unclosed result list.tsltest | 2 +- .../functions/good-annotation call.tsltest | 2 +- .../good-with parameter list.tsltest | 2 +- .../functions/good-with result list.tsltest | 2 +- .../good-with type parameter list.tsltest | 2 +- .../bad-const before annotation.sdstest | 2 +- .../bad-double const modifier.sdstest | 2 +- .../parameters/bad-missing comma.sdstest | 2 +- .../good-annotated parameter.sdstest | 2 +- ...ood-const typed optional parameter.sdstest | 2 +- ...ood-const typed required parameter.sdstest | 2 +- ...d-const untyped optional parameter.sdstest | 2 +- ...d-const untyped required parameter.sdstest | 2 +- .../parameters/good-empty.sdstest | 2 +- .../good-multiple parameters.sdstest | 2 +- .../good-typed optional parameter.sdstest | 2 +- .../good-typed required parameter.sdstest | 2 +- .../good-untyped optional parameter.sdstest | 2 +- .../good-untyped required parameter.sdstest | 2 +- .../pipelines/bad-missing body.sdstest | 2 +- .../pipelines/bad-unclosed body.sdstest | 2 +- .../pipelines/good-annotation call.sdstest | 2 +- .../pipelines/good-empty body.sdstest | 2 +- .../pipelines/good-statements in body.sdstest | 2 +- .../results/bad-missing comma.sdstest | 2 +- .../results/good-annotated result.sdstest | 2 +- .../declarations/results/good-empty.sdstest | 2 +- .../results/good-multiple results.sdstest | 2 +- ...-one typed result (in parentheses).sdstest | 2 +- ...-one typed result (no parentheses).sdstest | 2 +- ...ne untyped result (no parentheses).sdstest | 2 +- ... untyped result (with parentheses).sdstest | 2 +- .../segments/bad-missing body.sdstest | 2 +- .../bad-missing parameter list.sdstest | 2 +- ... visibilities (internal, internal).sdstest | 2 +- ...o visibilities (internal, private).sdstest | 2 +- ...o visibilities (private, internal).sdstest | 2 +- ...wo visibilities (private, private).sdstest | 2 +- .../segments/bad-unclosed body.sdstest | 2 +- .../bad-unclosed parameter list.sdstest | 2 +- .../segments/bad-unclosed result list.sdstest | 2 +- .../segments/good-annotation call.sdstest | 2 +- .../segments/good-internal segment.sdstest | 2 +- .../segments/good-private segment.sdstest | 2 +- .../segments/good-statements in body.sdstest | 2 +- .../good-with constraint list.sdstest | 2 +- .../good-with parameter list and body.sdstest | 2 +- .../segments/good-with result list.sdstest | 2 +- .../type parameters/bad-missing comma.sdstest | 2 +- .../good-annotated type parameter.sdstest | 2 +- ...travariant optional type parameter.sdstest | 2 +- ...travariant required type parameter.sdstest | 2 +- ... covariant optional type parameter.sdstest | 2 +- ... covariant required type parameter.sdstest | 2 +- ... invariant optional type parameter.sdstest | 2 +- ... invariant required type parameter.sdstest | 2 +- .../type parameters/good-empty.sdstest | 2 +- .../good-multiple type parameters.sdstest | 2 +- ...travariant optional type parameter.sdstest | 2 +- ...travariant required type parameter.sdstest | 2 +- ... covariant optional type parameter.sdstest | 2 +- ... covariant required type parameter.sdstest | 2 +- ... invariant optional type parameter.sdstest | 2 +- ... invariant required type parameter.sdstest | 2 +- ...bad-addition without left operator.sdstest | 2 +- ...ad-addition without right operator.sdstest | 2 +- ...bad-division without left operator.sdstest | 2 +- ...ad-division without right operator.sdstest | 2 +- ...ltiplication without left operator.sdstest | 2 +- ...tiplication without right operator.sdstest | 2 +- .../bad-negation without operator.sdstest | 2 +- ...subtraction without right operator.sdstest | 2 +- .../good-addition.sdstest | 2 +- .../good-complex example.sdstest | 2 +- .../good-division.sdstest | 2 +- .../good-multiplication.sdstest | 2 +- .../good-negation.sdstest | 2 +- .../good-subtraction.sdstest | 2 +- .../block lambdas/bad-unclosed body.sdstest | 2 +- .../bad-unclosed parameter list.sdstest | 2 +- .../block lambdas/good-filled body.sdstest | 2 +- .../good-with parameter list and body.sdstest | 2 +- .../calls/bad-unclosed argument list.sdstest | 2 +- ...xed positional and named arguments.sdstest | 2 +- .../calls/good-named argument.sdstest | 2 +- .../calls/good-no arguments.sdstest | 2 +- .../expressions/calls/good-null safe.sdstest | 2 +- .../calls/good-positional argument.sdstest | 2 +- ...han or equal without left operator.sdstest | 2 +- ...an or equal without right operator.sdstest | 2 +- ...greater than without left operator.sdstest | 2 +- ...reater than without right operator.sdstest | 2 +- ...han or equal without left operator.sdstest | 2 +- ...an or equal without right operator.sdstest | 2 +- ...ad-less than without left operator.sdstest | 2 +- ...d-less than without right operator.sdstest | 2 +- .../good-greater than or equal.sdstest | 2 +- .../good-greater than.sdstest | 2 +- .../good-less than or equal.sdstest | 2 +- .../good-less than.sdstest | 2 +- .../bad-without left operand.sdstest | 2 +- .../bad-without right operand.sdstest | 2 +- .../elvis operators/good-basic.sdstest | 2 +- .../elvis operators/good-chained.sdstest | 2 +- .../bad-equal without left operator.sdstest | 2 +- .../bad-equal without right operator.sdstest | 2 +- ...ad-identical without left operator.sdstest | 2 +- ...d-identical without right operator.sdstest | 2 +- ...ad-not equal without left operator.sdstest | 2 +- ...d-not equal without right operator.sdstest | 2 +- ...ot identical without left operator.sdstest | 2 +- ...t identical without right operator.sdstest | 2 +- .../equality operators/good-equal.sdstest | 2 +- .../equality operators/good-identical.sdstest | 2 +- .../equality operators/good-not equal.sdstest | 2 +- .../good-not identical.sdstest | 2 +- .../bad-missing body.sdstest | 2 +- .../bad-unclosed parameter list.sdstest | 2 +- ...with parameter list and expression.sdstest | 2 +- .../good-complex chained expression.sdstest | 2 +- .../expressions/good-reference.sdstest | 2 +- .../indexed accesses/bad-no index.sdstest | 2 +- .../bad-unclosed square bracket.sdstest | 2 +- .../good-literal index.sdstest | 2 +- .../indexed accesses/good-null safe.sdstest | 2 +- .../good-reference index.sdstest | 2 +- .../lists/bad-unclosed square bracket.sdstest | 2 +- .../good-nested multiple elements.sdstest | 2 +- .../lists/good-nested one element.sdstest | 2 +- .../good-one level multiple elements.sdstest | 2 +- .../lists/good-one level one element.sdstest | 2 +- .../float/bad-no digits before dot.sdstest | 2 +- .../literals/float/good-basic example.sdstest | 2 +- ...ientific notation with lowercase e.sdstest | 2 +- ...ientific notation with uppercase e.sdstest | 2 +- .../expressions/literals/good-false.sdstest | 2 +- .../expressions/literals/good-null.sdstest | 2 +- .../expressions/literals/good-true.sdstest | 2 +- .../literals/int/good-leading zero.sdstest | 2 +- .../literals/int/good-multiple digits.sdstest | 2 +- .../literals/int/good-one digit.sdstest | 2 +- .../bad-single quotes as delimiters.sdstest | 2 +- .../string/bad-unclosed quote.sdstest | 2 +- .../string/good-basic content.sdstest | 2 +- ...sing template expression delimiter.sdstest | 2 +- ...od-curly braces separated by space.sdstest | 2 +- .../literals/string/good-empty.sdstest | 2 +- .../string/good-escaped curly brace.sdstest | 2 +- .../string/good-multiple lines.sdstest | 2 +- .../good-newline escape sequence.sdstest | 2 +- .../string/good-single curly brace.sdstest | 2 +- .../literals/string/good-single quote.sdstest | 2 +- .../good-unicode escape sequence.sdstest | 2 +- ...-conjunction without left operator.sdstest | 2 +- ...conjunction without right operator.sdstest | 2 +- ...-disjunction without left operator.sdstest | 2 +- ...disjunction without right operator.sdstest | 2 +- .../bad-negation without operator.sdstest | 2 +- .../good-complex example.sdstest | 2 +- .../good-conjunction.sdstest | 2 +- .../good-disjunction.sdstest | 2 +- .../logical operations/good-negation.sdstest | 2 +- .../expressions/maps/bad-no colon.sdstest | 2 +- .../expressions/maps/bad-no key.sdstest | 2 +- .../expressions/maps/bad-no value.sdstest | 2 +- .../maps/bad-unclosed curly brace.sdstest | 2 +- .../good-nested multiple elements.sdstest | 2 +- .../maps/good-nested one element.sdstest | 2 +- .../good-one level multiple elements.sdstest | 2 +- .../maps/good-one level one element.sdstest | 2 +- .../member accesses/bad-no receiver.sdstest | 2 +- .../member accesses/good-not nullable.sdstest | 2 +- .../member accesses/good-nullable.sdstest | 2 +- .../bad-unclosed parenthesis.sdstest | 2 +- .../good-nested.sdstest | 2 +- .../good-one level.sdstest | 2 +- ...ate string with invalid expression.sdstest | 2 +- .../bad-unclosed template expression.sdstest | 2 +- .../good-empty template expression.sdstest | 2 +- ...plate string with basic expression.sdstest | 2 +- .../type casts/bad-without expression.sdstest | 2 +- .../type casts/bad-without type.sdstest | 2 +- .../expressions/type casts/good-basic.sdstest | 2 +- .../type casts/good-chained.sdstest | 2 +- .../keywords as names/bad-unescaped _.sdstest | 2 +- .../bad-unescaped and.sdstest | 2 +- .../bad-unescaped annotation.sdstest | 2 +- .../bad-unescaped as.sdstest | 2 +- .../bad-unescaped attr.sdstest | 2 +- .../bad-unescaped class.sdstest | 2 +- .../bad-unescaped const.sdstest | 2 +- .../bad-unescaped enum.sdstest | 2 +- .../bad-unescaped false.sdstest | 2 +- .../bad-unescaped fun.sdstest | 2 +- .../bad-unescaped import.sdstest | 2 +- .../bad-unescaped in.sdstest | 2 +- .../bad-unescaped internal.sdstest | 2 +- .../bad-unescaped literal.sdstest | 2 +- .../bad-unescaped not.sdstest | 2 +- .../bad-unescaped null.sdstest | 2 +- .../bad-unescaped or.sdstest | 2 +- .../bad-unescaped out.sdstest | 2 +- .../bad-unescaped package.sdstest | 2 +- .../bad-unescaped pipeline.sdstest | 2 +- .../bad-unescaped private.sdstest | 2 +- .../bad-unescaped schema.sdstest | 2 +- .../bad-unescaped segment.sdstest | 2 +- .../bad-unescaped static.sdstest | 2 +- .../bad-unescaped sub.sdstest | 2 +- .../bad-unescaped true.sdstest | 2 +- .../bad-unescaped union.sdstest | 2 +- .../bad-unescaped val.sdstest | 2 +- .../bad-unescaped where.sdstest | 2 +- .../bad-unescaped yield.sdstest | 2 +- .../good-escapedKeywords.sdstest | 2 +- .../good-escapedNonKeyword.sdstest | 2 +- ...-annotation call after declaration.sdstest | 2 +- .../bad-annotation call after import.sdstest | 2 +- ...annotation call after package name.sdstest | 2 +- ...ll between package name and import.sdstest | 2 +- .../bad-duplicate package name.sdstest | 2 +- .../bad-import after declaration.sdstest | 2 +- .../bad-import without declarations.sdstest | 2 +- .../bad-import without package.sdstest | 2 +- ...bad-package name after declaration.sdstest | 2 +- .../bad-package name after import.sdstest | 2 +- ...od-annotation call and declaration.sdstest | 2 +- ...on call and import and declaration.sdstest | 2 +- .../good-annotation call and import.sdstest | 2 +- ...l and package name and declaration.sdstest | 2 +- ...ge name and import and declaration.sdstest | 2 +- ...n call and package name and import.sdstest | 2 +- ...d-annotation call and package name.sdstest | 2 +- .../modules/good-annotation call.sdstest | 2 +- ...-annotation calls and declarations.sdstest | 2 +- ...calls and imports and declarations.sdstest | 2 +- .../good-annotation calls and imports.sdstest | 2 +- ... and package name and declarations.sdstest | 2 +- ... name and imports and declarations.sdstest | 2 +- ...calls and package name and imports.sdstest | 2 +- ...-annotation calls and package name.sdstest | 2 +- .../modules/good-annotation calls.sdstest | 2 +- .../grammar/modules/good-declaration.sdstest | 2 +- .../grammar/modules/good-declarations.sdstest | 2 +- .../grammar/modules/good-empty.sdstest | 2 +- .../good-import and declaration.sdstest | 2 +- .../grammar/modules/good-import.sdstest | 2 +- .../good-imports and declarations.sdstest | 2 +- .../grammar/modules/good-imports.sdstest | 2 +- .../good-package name and declaration.sdstest | 2 +- ...good-package name and declarations.sdstest | 2 +- ...ge name and import and declaration.sdstest | 2 +- .../good-package name and import.sdstest | 2 +- ... name and imports and declarations.sdstest | 2 +- .../good-package name and imports.sdstest | 2 +- .../grammar/modules/good-package name.sdstest | 2 +- .../schema/bad-no name (colon).sdstest | 2 +- .../schema/bad-no name (no colon).sdstest | 2 +- .../schema/bad-no type (colon).sdstest | 2 +- .../schema/bad-no type (no colon).sdstest | 2 +- .../schema/bad-switched name and type.sdstest | 2 +- .../schema/bad-unclosed curly brace.sdstest | 2 +- .../schema/good-annotation call.sdstest | 2 +- .../grammar/schema/good-empty schema.sdstest | 2 +- .../grammar/schema/good-one column.sdstest | 2 +- .../grammar/schema/good-two columns.sdstest | 2 +- ...-in block lambda without assignees.sdstest | 2 +- ...in block lambda without expression.sdstest | 2 +- ...-in block lambda without semicolon.sdstest | 2 +- .../bad-in pipeline without assignees.sdstest | 2 +- ...bad-in pipeline without expression.sdstest | 2 +- .../bad-in pipeline without semicolon.sdstest | 2 +- .../bad-in segment without assignees.sdstest | 2 +- .../bad-in segment without expression.sdstest | 2 +- .../bad-in segment without semicolon.sdstest | 2 +- .../assignments/good-in block lambda.sdstest | 2 +- .../assignments/good-in pipeline.sdstest | 2 +- .../assignments/good-in segment.sdstest | 2 +- ...ad-empty statement in block lambda.sdstest | 2 +- .../bad-empty statement in pipeline.sdstest | 2 +- .../bad-empty statement in segment.sdstest | 2 +- .../bad-without else missing block.tsltest | 2 +- ...bad-without else missing condition.tsltest | 2 +- .../good-with else false.tsltest | 2 +- .../good-with else true.tsltest | 2 +- .../good-without else.tsltest | 2 +- ...-in block lambda without semicolon.sdstest | 2 +- .../bad-in pipeline without semicolon.sdstest | 2 +- .../bad-in segment without semicolon.sdstest | 2 +- .../good-in block lambda.sdstest | 2 +- .../good-in pipeline.sdstest | 2 +- .../good-in segment.sdstest | 2 +- ...d-argument list of annotation call.sdstest | 2 +- .../good-argument list of call.sdstest | 2 +- ...list of assignment in block lambda.sdstest | 2 +- .../good-assignee list of assignment.sdstest | 2 +- .../good-column list of schema.sdstest | 2 +- ...good-constraint list of annotation.sdstest | 2 +- .../good-constraint list of class.sdstest | 2 +- ...od-constraint list of enum variant.sdstest | 2 +- .../good-constraint list of function.sdstest | 2 +- .../good-elements of list.sdstest | 2 +- .../good-entries of map.sdstest | 2 +- ...claration list of qualified import.sdstest | 2 +- .../good-literal list of literal type.sdstest | 2 +- .../good-parameter list of annotation.sdstest | 2 +- ...ood-parameter list of block lambda.sdstest | 2 +- ...od-parameter list of callable type.sdstest | 2 +- .../good-parameter list of class.sdstest | 2 +- ...ood-parameter list of enum variant.sdstest | 2 +- ...arameter list of expression lambda.sdstest | 2 +- .../good-parameter list of function.sdstest | 2 +- .../good-parameter list of segment.sdstest | 2 +- .../good-parent type list of class.sdstest | 2 +- .../good-result list of callable type.sdstest | 2 +- .../good-result list of function.sdstest | 2 +- .../good-result list of segment.sdstest | 2 +- ...d-type argument list of named type.sdstest | 2 +- ...d-type argument list of union type.sdstest | 2 +- .../good-type parameter list of class.sdstest | 2 +- ...od-type parameter list of function.sdstest | 2 +- .../callable types/bad-missing arrow.sdstest | 2 +- .../bad-missing parameter list.sdstest | 2 +- .../bad-missing result list.sdstest | 2 +- .../bad-unclosed parameter list.sdstest | 2 +- .../bad-unclosed result list.sdstest | 2 +- ...od-with parameter and result lists.sdstest | 2 +- .../types/literal types/bad-nested.sdstest | 2 +- .../literal types/bad-no literal list.sdstest | 2 +- .../bad-unclosed angle bracket.sdstest | 2 +- .../types/literal types/good-empty.sdstest | 2 +- .../good-with list literal.sdstest | 2 +- .../literal types/good-with literals.sdstest | 2 +- .../good-with map literal.sdstest | 2 +- .../bad-callable type as member.sdstest | 2 +- .../bad-literal type as member.sdstest | 2 +- .../member types/bad-missing member.sdstest | 2 +- .../member types/bad-missing receiver.sdstest | 2 +- .../bad-unclosed angle bracket.sdstest | 2 +- .../bad-union type as member.sdstest | 2 +- .../good-long complex chain.sdstest | 2 +- ...allable) and member (not nullable).sdstest | 2 +- ...r (callable) and member (nullable).sdstest | 2 +- ...literal) and member (not nullable).sdstest | 2 +- ...er (literal) and member (nullable).sdstest | 2 +- ...ullable) and member (not nullable).sdstest | 2 +- ...ot nullable) and member (nullable).sdstest | 2 +- ...ullable) and member (not nullable).sdstest | 2 +- ...d, nullable) and member (nullable).sdstest | 2 +- ... (union) and member (not nullable).sdstest | 2 +- ...iver (union) and member (nullable).sdstest | 2 +- .../bad-unclosed angle bracket.sdstest | 2 +- ...no type arguments and not nullable.sdstest | 2 +- ...ood-no type arguments and nullable.sdstest | 2 +- .../good-type argument and nullable.sdstest | 2 +- ...od-type arguments and not nullable.sdstest | 2 +- .../bad-unclosed angle bracket.sdstest | 2 +- .../types/union types/good-empty.sdstest | 2 +- .../types/union types/good-nested.sdstest | 2 +- .../good-with type arguments.sdstest | 2 +- .../base cases/block lambdas/main.sdstest | 2 +- .../base cases/boolean literals/main.sdstest | 4 +- .../base cases/classes/main.sdstest | 2 +- .../base cases/enum variants/main.sdstest | 2 +- .../expression lambdas/main.sdstest | 2 +- .../base cases/float literals/main.sdstest | 4 +- .../base cases/functions/main.sdstest | 2 +- .../base cases/int literals/main.sdstest | 2 +- .../base cases/null literals/main.sdstest | 2 +- .../base cases/segments/main.sdstest | 2 +- .../main.sdstest | 4 +- .../invalid nodes/main.sdstest | 2 +- .../recursive cases/arguments/main.sdstest | 4 +- .../block lambda results/main.sdstest | 8 +- .../assignees/placeholders/main.sdstest | 8 +- .../assignees/wildcards/main.sdstest | 8 +- .../assignees/yields/main.sdstest | 8 +- .../calls/of block lambdas/closure.sdstest | 2 +- .../calls/of block lambdas/main.sdstest | 2 +- ...ameter value used as default value.sdstest | 2 +- .../calls/of classes/main.sdstest | 2 +- .../calls/of enum variants/main.sdstest | 18 +- .../of expression lambdas/closure.sdstest | 2 +- .../calls/of expression lambdas/main.sdstest | 2 +- ...ameter value used as default value.sdstest | 2 +- .../calls/of functions/main.sdstest | 2 +- .../calls/of segments/main.sdstest | 2 +- ...ameter value used as default value.sdstest | 2 +- .../calls/of unknown parameter/main.sdstest | 2 +- .../calls/on null/main.sdstest | 4 +- .../calls/recursion/main.sdstest | 2 +- .../calls/unresolved/main.sdstest | 4 +- .../indexed access/on lists/main.sdstest | 14 +- .../indexed access/on maps/main.sdstest | 12 +- .../indexed access/on null/main.sdstest | 4 +- .../indexed access/on other/main.sdstest | 4 +- .../infix operations/and/main.sdstest | 16 +- .../and/short circuiting.sdstest | 12 +- .../infix operations/divided by/main.sdstest | 22 +- .../infix operations/elvis/main.sdstest | 12 +- .../elvis/short circuiting.sdstest | 12 +- .../infix operations/equals/main.sdstest | 8 +- .../greater than or equals/main.sdstest | 24 +-- .../greater than/main.sdstest | 24 +-- .../identical to/main.sdstest | 8 +- .../less than or equals/main.sdstest | 24 +-- .../infix operations/less than/main.sdstest | 24 +-- .../infix operations/minus/main.sdstest | 16 +- .../infix operations/not equals/main.sdstest | 8 +- .../not identical to/main.sdstest | 8 +- .../infix operations/or/main.sdstest | 16 +- .../or/short circuiting.sdstest | 12 +- .../infix operations/plus/main.sdstest | 16 +- .../infix operations/times/main.sdstest | 16 +- .../recursive cases/lists/main.sdstest | 4 +- .../recursive cases/maps/main.sdstest | 4 +- .../of call results/main.sdstest | 12 +- .../of enum variant parameters/main.sdstest | 6 +- .../of enum variants/main.sdstest | 4 +- .../member accesses/on null/main.sdstest | 4 +- .../on other receivers/main.sdstest | 2 +- .../member accesses/unresolved/main.sdstest | 4 +- .../recursive cases/parameters/main.sdstest | 6 +- .../parenthesized expressions/main.sdstest | 8 +- .../prefix operations/minus/main.sdstest | 8 +- .../prefix operations/not/main.sdstest | 8 +- .../recursive cases/references/main.sdstest | 4 +- .../recursive cases/results/main.sdstest | 6 +- .../template strings/main.sdstest | 6 +- .../recursive cases/type casts/main.sdstest | 4 +- ...ain no imports or own declarations.sdstest | 10 +- ... with imports and own declarations.sdstest | 14 +- ...with multiple imports of same name.sdstest | 2 +- ...n with qualified import with alias.sdstest | 16 +- .../main with qualified import.sdstest | 14 +- .../main with wildcard import.sdstest | 10 +- .../resource other package.sdstest | 8 +- .../resource safeds package.sdstest | 4 +- .../resource same package.sdstest | 4 +- .../resource without package.sdstest | 4 +- .../on annotation/main.sdstest | 12 +- .../on attribute/main.sdstest | 12 +- .../annotation calls/on class/main.sdstest | 12 +- .../on enum variant/main.sdstest | 12 +- .../annotation calls/on enum/main.sdstest | 12 +- .../annotation calls/on function/main.sdstest | 12 +- .../annotation calls/on module/main.sdstest | 8 +- .../on parameter/main.sdstest | 16 +- .../annotation calls/on pipeline/main.sdstest | 12 +- .../annotation calls/on result/main.sdstest | 12 +- .../annotation calls/on segment/main.sdstest | 12 +- .../on type parameter/main.sdstest | 12 +- .../to parameter/main.sdstest | 12 +- .../main.sdstest | 2 +- .../unresolved/main.sdstest | 4 +- .../to parameter of annotation/main.sdstest | 18 +- .../to parameter of block lambda/main.sdstest | 12 +- .../main.sdstest | 18 +- .../to parameter of class/main.sdstest | 18 +- .../to parameter of enum variant/main.sdstest | 18 +- .../main.sdstest | 12 +- .../to parameter of function/main.sdstest | 18 +- .../to parameter of segment/main.sdstest | 18 +- .../main.sdstest | 2 +- .../of calls/unresolved/main.sdstest | 4 +- .../with nullable receiver/main.sdstest | 18 +- .../to annotations/main.sdstest | 16 +- .../resource first package.sdstest | 4 +- .../resource second package.sdstest | 8 +- .../to global classes/main.sdstest | 16 +- .../resource first package.sdstest | 4 +- .../resource second package.sdstest | 8 +- .../to global enums/main.sdstest | 16 +- .../resource first package.sdstest | 4 +- .../resource second package.sdstest | 8 +- .../to global functions/main.sdstest | 16 +- .../resource first package.sdstest | 4 +- .../resource second package.sdstest | 8 +- .../to nested declaration/main.sdstest | 16 +- .../resource first package.sdstest | 4 +- .../resource second package.sdstest | 8 +- .../to pipelines/main.sdstest | 16 +- .../resource first package.sdstest | 4 +- .../resource second package.sdstest | 8 +- .../to schemas/main.sdstest | 16 +- .../to schemas/resource first package.sdstest | 4 +- .../resource second package.sdstest | 8 +- .../to segments/main.sdstest | 26 +-- .../resource first package.sdstest | 4 +- .../to segments/resource same package.sdstest | 6 +- .../resource second package.sdstest | 12 +- .../unresolved/main.sdstest | 2 +- .../on type parameters/main.sdstest | 10 +- .../to class members/hiding/main.sdstest | 24 +-- .../to class members/inheritance/main.sdstest | 48 ++--- .../instance attributes/main.sdstest | 56 ++--- .../instance methods/main.sdstest | 56 ++--- .../nested classes/main.sdstest | 46 ++--- .../nested enums/main.sdstest | 46 ++--- .../to class members/overriding/main.sdstest | 12 +- .../static attributes/main.sdstest | 44 ++-- .../static methods/main.sdstest | 46 ++--- .../to enum variants/main.sdstest | 16 +- .../main.sdstest | 20 +- .../call with nullable receiver/main.sdstest | 16 +- .../main.sdstest | 8 +- .../to results/of block lambdas/main.sdstest | 8 +- .../main.sdstest | 8 +- .../to results/of callable types/main.sdstest | 8 +- .../main.sdstest | 8 +- .../to results/of functions/main.sdstest | 8 +- .../main.sdstest | 8 +- .../to results/of segments/main.sdstest | 8 +- ...ain no imports or own declarations.sdstest | 10 +- ... with imports and own declarations.sdstest | 14 +- ...with multiple imports of same name.sdstest | 2 +- ...n with qualified import with alias.sdstest | 16 +- .../main with qualified import.sdstest | 14 +- .../main with wildcard import.sdstest | 10 +- .../resource other package.sdstest | 8 +- .../resource safeds package.sdstest | 4 +- .../resource same package.sdstest | 4 +- .../resource without package.sdstest | 4 +- ...ain no imports or own declarations.sdstest | 10 +- ... with imports and own declarations.sdstest | 14 +- ...with multiple imports of same name.sdstest | 2 +- ...n with qualified import with alias.sdstest | 16 +- .../main with qualified import.sdstest | 14 +- .../main with wildcard import.sdstest | 10 +- .../resource other package.sdstest | 8 +- .../resource safeds package.sdstest | 4 +- .../resource same package.sdstest | 4 +- .../resource without package.sdstest | 4 +- .../main.sdstest | 60 +++--- .../main.sdstest | 22 +- .../main.sdstest | 22 +- .../to global classes/main.sdstest | 10 +- .../in same file/to global enums/main.sdstest | 10 +- .../to nested classes/main.sdstest | 14 +- .../in same file/to nested enums/main.sdstest | 14 +- .../main.sdstest | 2 +- .../main.sdstest | 10 +- .../in global classes/main.sdstest | 30 +-- .../in global functions/main.sdstest | 28 +-- .../in methods/main.sdstest | 56 ++--- .../in nested classes/main.sdstest | 62 +++--- .../in annotation/main.sdstest | 12 +- .../main.sdstest | 14 +- .../in global class/main.sdstest | 12 +- .../in global function/main.sdstest | 12 +- .../parameter bounds/in method/main.sdstest | 22 +- .../in nested class/main.sdstest | 22 +- .../parameter bounds/in segment/main.sdstest | 12 +- ...ain no imports or own declarations.sdstest | 10 +- ... with imports and own declarations.sdstest | 14 +- ...with multiple imports of same name.sdstest | 2 +- ...n with qualified import with alias.sdstest | 16 +- .../main with qualified import.sdstest | 12 +- .../main with wildcard import.sdstest | 10 +- .../resource other package.sdstest | 6 +- .../resource safeds package.sdstest | 4 +- .../resource same package.sdstest | 4 +- .../resource without package.sdstest | 4 +- ...ain no imports or own declarations.sdstest | 10 +- ... with imports and own declarations.sdstest | 14 +- ...with multiple imports of same name.sdstest | 2 +- ...n with qualified import with alias.sdstest | 16 +- .../main with qualified import.sdstest | 12 +- .../main with wildcard import.sdstest | 10 +- .../resource other package.sdstest | 6 +- .../resource safeds package.sdstest | 4 +- .../resource same package.sdstest | 4 +- .../resource without package.sdstest | 4 +- ...ain no imports or own declarations.sdstest | 10 +- ... with imports and own declarations.sdstest | 14 +- ...with multiple imports of same name.sdstest | 2 +- ...n with qualified import with alias.sdstest | 16 +- .../main with qualified import.sdstest | 12 +- .../main with wildcard import.sdstest | 10 +- .../resource other package.sdstest | 6 +- .../resource safeds package.sdstest | 4 +- .../resource same package.sdstest | 4 +- .../resource without package.sdstest | 4 +- ...ain no imports or own declarations.sdstest | 10 +- ... with imports and own declarations.sdstest | 14 +- ...with multiple imports of same name.sdstest | 2 +- ...n with qualified import with alias.sdstest | 16 +- .../main with qualified import.sdstest | 12 +- .../main with wildcard import.sdstest | 10 +- .../resource other package.sdstest | 6 +- .../resource safeds package.sdstest | 4 +- .../resource same package.sdstest | 4 +- .../resource without package.sdstest | 4 +- ...ain no imports or own declarations.sdstest | 10 +- ... with imports and own declarations.sdstest | 14 +- ...with multiple imports of same name.sdstest | 2 +- ...n with qualified import with alias.sdstest | 16 +- .../main with qualified import.sdstest | 12 +- .../main with wildcard import.sdstest | 10 +- .../resource other package.sdstest | 6 +- .../resource safeds package.sdstest | 4 +- .../resource same package.sdstest | 4 +- .../resource without package.sdstest | 4 +- ...ain no imports or own declarations.sdstest | 10 +- ... with imports and own declarations.sdstest | 14 +- ...with multiple imports of same name.sdstest | 2 +- ...n with qualified import with alias.sdstest | 16 +- .../main with qualified import.sdstest | 12 +- .../main with wildcard import.sdstest | 10 +- .../to schemas/resource other package.sdstest | 6 +- .../resource safeds package.sdstest | 4 +- .../to schemas/resource same package.sdstest | 4 +- .../resource without package.sdstest | 4 +- ...ain no imports or own declarations.sdstest | 26 +-- ... with imports and own declarations.sdstest | 30 +-- ...with multiple imports of same name.sdstest | 2 +- ...n with qualified import with alias.sdstest | 32 +-- .../main with qualified import.sdstest | 28 +-- .../main with wildcard import.sdstest | 26 +-- .../resource other package.sdstest | 10 +- .../resource safeds package.sdstest | 8 +- .../to segments/resource same package.sdstest | 8 +- .../resource without package.sdstest | 8 +- .../in same file/to annotations/main.sdstest | 8 +- .../from outside/main.sdstest | 2 +- .../of containing block lambda/main.sdstest | 2 +- .../to class members/main.sdstest | 12 +- .../to containing declarations/main.sdstest | 60 +++--- .../to enum variants/main.sdstest | 2 +- .../to global classes/main.sdstest | 8 +- .../in same file/to global enums/main.sdstest | 8 +- .../to global functions/main.sdstest | 8 +- .../in same file/to modules/main.sdstest | 2 +- .../main.sdstest | 64 +++--- .../to parameters/from outside/main.sdstest | 16 +- .../from parameter bound/main.sdstest | 24 +-- .../of containing block lambda/main.sdstest | 44 ++-- .../main.sdstest | 38 ++-- .../of containing segment/main.sdstest | 24 +-- .../in same file/to pipelines/main.sdstest | 8 +- .../to placeholders/from outside/main.sdstest | 6 +- .../of containing block lambda/main.sdstest | 74 +++---- .../of containing pipeline/main.sdstest | 34 ++-- .../of containing segment/main.sdstest | 34 ++-- .../to redeclared module member/main.sdstest | 8 +- .../to results/from outside/main.sdstest | 6 +- .../of containing segment/main.sdstest | 2 +- .../in same file/to schemas/main.sdstest | 8 +- .../in same file/to segments/main.sdstest | 22 +- .../to type parameters/main.sdstest | 2 +- .../references/unresolved/main.sdstest | 2 +- .../main.sdstest | 2 +- .../main.sdstest | 26 +-- .../main.sdstest | 4 +- .../main.sdstest | 4 +- .../type arguments/to unresolved/main.sdstest | 4 +- .../scoping/yields/in pipeline/main.sdstest | 8 +- .../scoping/yields/in segment/main.sdstest | 16 +- .../block lambda results/main.sdstest | 12 +- .../assignees/placeholders/main.sdstest | 12 +- .../typing/assignees/yields/main.sdstest | 12 +- .../declarations/annotations/main.sdstest | 6 +- .../declarations/attributes/main.sdstest | 12 +- .../typing/declarations/classes/main.sdstest | 4 +- .../declarations/enum variants/main.sdstest | 4 +- .../typing/declarations/enums/main.sdstest | 4 +- .../declarations/functions/main.sdstest | 10 +- .../parameters/of annotations/main.sdstest | 6 +- .../that are isolated/main.sdstest | 2 +- .../that are passed as arguments/main.sdstest | 14 +- .../main.sdstest | 8 +- .../that are yielded/main.sdstest | 8 +- .../with manifest types/main.sdstest | 4 +- .../parameters/of callable types/main.sdstest | 6 +- .../parameters/of classes/main.sdstest | 6 +- .../parameters/of enum variants/main.sdstest | 6 +- .../that are isolated/main.sdstest | 2 +- .../that are passed as arguments/main.sdstest | 14 +- .../main.sdstest | 8 +- .../that are yielded/main.sdstest | 8 +- .../with manifest types/main.sdstest | 4 +- .../parameters/of functions/main.sdstest | 6 +- .../parameters/of segments/main.sdstest | 6 +- .../declarations/pipelines/main.sdstest | 2 +- .../typing/declarations/results/main.sdstest | 12 +- .../typing/declarations/segments/main.sdstest | 10 +- .../declarations/type parameters/main.sdstest | 4 +- .../typing/expressions/arguments/main.sdstest | 30 +-- .../that are isolated/main.sdstest | 4 +- .../that are passed as arguments/main.sdstest | 14 +- .../main.sdstest | 12 +- .../that are yielded/main.sdstest | 6 +- .../with manifest types/main.sdstest | 4 +- .../calls/of annotations/main.sdstest | 4 +- .../calls/of block lambdas/main.sdstest | 8 +- .../calls/of callable types/main.sdstest | 8 +- .../expressions/calls/of classes/main.sdstest | 8 +- .../calls/of enum variants/main.sdstest | 40 ++-- .../calls/of expression lambdas/main.sdstest | 4 +- .../calls/of functions/main.sdstest | 8 +- .../calls/of non-callable/main.sdstest | 4 +- .../calls/of nullable receiver/main.sdstest | 8 +- .../calls/of segments/main.sdstest | 8 +- .../clamp to upper bound/main.sdstest | 8 +- .../deep nesting/main.sdstest | 20 +- .../default value of parameter/main.sdstest | 4 +- .../main.sdstest | 8 +- .../differing variance/main.sdstest | 32 +-- .../multiple contravariant/main.sdstest | 24 +-- .../multiple covariant/main.sdstest | 28 +-- .../single contravariant/main.sdstest | 4 +- .../single covariant/main.sdstest | 4 +- .../expressions/calls/unresolved/main.sdstest | 4 +- .../that are isolated/main.sdstest | 4 +- .../that are passed as arguments/main.sdstest | 14 +- .../main.sdstest | 6 +- .../that are yielded/main.sdstest | 6 +- .../with manifest types/main.sdstest | 2 +- .../indexed accesses/on lists/main.sdstest | 48 ++--- .../indexed accesses/on maps/main.sdstest | 48 ++--- .../indexed accesses/on other/main.sdstest | 8 +- .../on unresolved/main.sdstest | 4 +- .../typing/expressions/lists/main.sdstest | 10 +- .../typing/expressions/literals/main.sdstest | 10 +- .../typing/expressions/maps/main.sdstest | 12 +- .../main.sdstest | 48 ++--- .../to enum variants/main.sdstest | 12 +- .../to nested classes/main.sdstest | 4 +- .../to nested enums/main.sdstest | 4 +- .../member accesses/to other/main.sdstest | 30 +-- .../member accesses/unresolved/main.sdstest | 4 +- .../operations/arithmetic/main.sdstest | 120 +++++------ .../operations/comparison/main.sdstest | 16 +- .../elvis/non nullable left operand.sdstest | 24 +-- .../elvis/nullable left operand.sdstest | 12 +- .../operations/equality/main.sdstest | 16 +- .../operations/logical/main.sdstest | 12 +- .../parenthesized expressions/main.sdstest | 20 +- .../references/to global classes/main.sdstest | 2 +- .../references/to global enums/main.sdstest | 2 +- .../references/to other/main.sdstest | 8 +- .../references/unresolved/main.sdstest | 2 +- .../expressions/template strings/main.sdstest | 4 +- .../expressions/type casts/main.sdstest | 6 +- ...op if class has no type parameters.sdstest | 2 +- .../class type and class type/main.sdstest | 22 +- .../with type parameters.sdstest | 68 +++---- .../class type and enum type/main.sdstest | 16 +- .../class type and enum variant/main.sdstest | 16 +- .../class type and literal type/main.sdstest | 30 +-- .../main.sdstest | 24 +-- .../enum type and enum type/main.sdstest | 12 +- .../main.sdstest | 12 +- .../main.sdstest | 24 +-- .../main.sdstest | 18 +- .../main.sdstest | 20 +- .../incompatible types/main.sdstest | 24 +-- .../main.sdstest | 6 +- .../simplification/main.sdstest | 8 +- .../main.sdstest | 14 +- .../unhandled type/main.sdstest | 12 +- .../unknown type/main.sdstest | 4 +- .../class type and class type/main.sdstest | 12 +- .../with type parameters.sdstest | 48 ++--- .../class type and literal type/main.sdstest | 20 +- .../main.sdstest | 10 +- .../enum type and enum type/main.sdstest | 8 +- .../main.sdstest | 8 +- .../main.sdstest | 12 +- .../main.sdstest | 12 +- .../main.sdstest | 10 +- .../incompatible types/main.sdstest | 16 +- .../main.sdstest | 4 +- .../main.sdstest | 10 +- .../main.sdstest | 8 +- .../simplification/main.sdstest | 8 +- .../main.sdstest | 18 +- .../main.sdstest | 20 +- .../unhandled type/main.sdstest | 12 +- .../unknown type/main.sdstest | 4 +- .../main.sdstest | 10 +- .../main.sdstest | 6 +- .../main.sdstest | 84 ++++---- .../main.sdstest | 2 +- .../main.sdstest | 2 +- .../main.sdstest | 4 +- .../typing/simplification/unwrap/main.sdstest | 22 +- .../typing/types/callable types/main.sdstest | 10 +- .../typing/types/literal types/main.sdstest | 6 +- .../typing/types/member types/main.sdstest | 22 +- .../typing/types/named types/main.sdstest | 12 +- .../named types/with type parameters.sdstest | 24 +-- .../typing/types/type arguments/main.sdstest | 12 +- .../typing/types/union types/main.sdstest | 4 +- .../deprecated/assigned result/main.sdstest | 24 +-- .../deprecated/called annotation/main.sdstest | 6 +- .../corresponding parameter/main.sdstest | 12 +- .../main.sdstest | 40 ++-- .../from named type/main.sdstest | 14 +- .../from reference/main.sdstest | 38 ++-- .../experimental/assigned result/main.sdstest | 24 +-- .../called annotation/main.sdstest | 6 +- .../corresponding parameter/main.sdstest | 12 +- .../from named type/main.sdstest | 14 +- .../from reference/main.sdstest | 38 ++-- .../main.sdstest | 40 ++-- .../annotations/pythonCall/main.sdstest | 18 +- .../annotations/pythonModule/error.sdstest | 2 +- .../pythonModule/no annotation.sdstest | 2 +- .../annotations/pythonModule/no error.sdstest | 4 +- .../identical to safe-ds name/main.sdstest | 6 +- .../no annotation.sdstest | 2 +- .../main.sdstest | 14 +- .../annotations/repeatable/main.sdstest | 14 +- .../target/duplicate target/main.sdstest | 30 +-- .../no target annotation.sdstest | 2 +- .../target/wrong target/main.sdstest | 100 ++++----- .../constraint lists/main.sdstest | 2 +- .../literal types/main.sdstest | 2 +- .../maps/main.sdstest | 4 +- .../union types/main.sdstest | 8 +- .../inheritance/must be acyclic/main.sdstest | 16 +- .../class with parent types.sdstest | 20 +- .../class without parent types.sdstest | 2 +- .../class with parent types.sdstest | 20 +- .../class with parent types.sdstest | 12 +- .../class without parent types.sdstest | 2 +- .../main.sdstest | 32 +-- .../type parameters.sdstest | 20 +- .../main.sdstest | 32 +-- .../purity.sdstest | 8 +- .../safeds lang any.sdstest | 2 +- .../type parameters.sdstest | 18 +- .../names/casing/annotations.sdstest | 10 +- .../names/casing/attributes.sdstest | 10 +- .../names/casing/block lambda results.sdstest | 10 +- .../validation/names/casing/classes.sdstest | 10 +- .../names/casing/enum variants.sdstest | 10 +- .../validation/names/casing/enums.sdstest | 10 +- .../validation/names/casing/functions.sdstest | 10 +- .../names/casing/no package name.sdstest | 2 +- .../package name leading underscore.sdstest | 2 +- .../package name lowercase escaped.sdstest | 2 +- .../casing/package name lowercase.sdstest | 2 +- .../casing/package name snake case.sdstest | 2 +- .../casing/package name uppercase.sdstest | 2 +- .../names/casing/parameters.sdstest | 10 +- .../validation/names/casing/pipelines.sdstest | 10 +- .../names/casing/placeholders.sdstest | 10 +- .../validation/names/casing/results.sdstest | 10 +- .../validation/names/casing/schemas.sdstest | 10 +- .../validation/names/casing/segments.sdstest | 10 +- .../names/casing/type parameters.sdstest | 10 +- .../names/codegen prefix/annotations.sdstest | 4 +- .../names/codegen prefix/attributes.sdstest | 4 +- .../block lambda results.sdstest | 4 +- .../names/codegen prefix/classes.sdstest | 4 +- .../codegen prefix/enum variants.sdstest | 4 +- .../names/codegen prefix/enums.sdstest | 4 +- .../names/codegen prefix/functions.sdstest | 4 +- .../codegen prefix/no package name.sdstest | 2 +- .../package name with codegen prefix.sdstest | 2 +- ...ackage name without codegen prefix.sdstest | 2 +- .../names/codegen prefix/parameters.sdstest | 4 +- .../names/codegen prefix/pipelines.sdstest | 4 +- .../names/codegen prefix/placeholders.sdstest | 4 +- .../names/codegen prefix/results.sdstest | 4 +- .../names/codegen prefix/schemas.sdstest | 4 +- .../names/codegen prefix/segments.sdstest | 4 +- .../codegen prefix/type parameters.sdstest | 4 +- .../names/core names/in safeds lang.sdstest | 2 +- .../validation/names/core names/main.sdstest | 4 +- .../duplicates/across files/main.sdstest | 72 +++---- .../across files/other package.sdstest | 18 +- .../duplicates/across files/safeds 1.sdstest | 20 +- .../duplicates/across files/safeds 2.sdstest | 18 +- .../across files/same package.sdstest | 18 +- .../duplicates/in annotation/main.sdstest | 6 +- .../duplicates/in block lambda/main.sdstest | 36 ++-- .../duplicates/in callable type/main.sdstest | 16 +- .../names/duplicates/in class/main.sdstest | 172 ++++++++-------- .../duplicates/in enum variant/main.sdstest | 6 +- .../names/duplicates/in enum/main.sdstest | 6 +- .../in expression lambda/main.sdstest | 6 +- .../names/duplicates/in function/main.sdstest | 30 +-- .../duplicates/in pipeline file/main.sdspipe | 70 +++---- .../names/duplicates/in pipeline/main.sdstest | 6 +- .../names/duplicates/in schema/main.sdstest | 6 +- .../names/duplicates/in segment/main.sdstest | 36 ++-- .../duplicates/in stub file/main.sdsstub | 70 +++---- .../duplicates/in test file/main.sdstest | 70 +++---- .../duplicate parameter/main.sdstest | 112 +++++----- ...rgument list is missing altogether.sdstest | 2 +- .../missing required parameter/main.sdstest | 130 ++++++------ .../main.sdstest | 52 ++--- .../too many arguments/main.sdstest | 130 ++++++------ .../missing argument list/main.sdstest | 20 +- .../main.sdstest | 12 +- .../main.sdstest | 6 +- .../main.sdstest | 6 +- .../main.sdstest | 62 +++--- .../main.sdstest | 34 ++-- .../parameter must be const/main.sdstest | 56 ++--- .../main.sdstest | 32 +-- .../main.sdstest | 72 +++---- .../main.sdstest | 112 +++++----- .../parameters/const modifier/error.sdstest | 6 +- .../const modifier/no error.sdstest | 2 +- .../main.sdstest | 12 +- .../no type.sdstest | 2 +- .../main.sdstest | 96 ++++----- .../placeholders/alias/main.sdstest | 30 +-- .../placeholders/unused/main.sdstest | 24 +-- .../segments/duplicate yield/main.sdstest | 14 +- .../segments/unassigned result/main.sdstest | 10 +- .../segments/unused parameter/main.sdstest | 24 +-- .../declarations/segments/unused/main.sdstest | 12 +- .../main.sdstest | 28 +-- .../insufficient context/main.sdstest | 36 ++-- .../main.sdstest | 18 +- .../main.sdstest | 38 ++-- .../contravariant type parameter.sdstest | 74 +++---- .../covariant type parameter.sdstest | 74 +++---- .../invariant type parameter.sdstest | 74 +++---- .../usage of class type parameters.sdstest | 22 +- .../invariant.sdstest | 2 +- .../variance only on classes/variant.sdstest | 8 +- .../annotation calls.sdstest | 16 +- .../const parameters.sdstest | 12 +- .../normal parameters.sdstest | 8 +- .../calls/recursion/direct.sdstest | 6 +- .../calls/recursion/not recursive.sdstest | 2 +- ...tive via function pointer argument.sdstest | 2 +- .../transitive via lambda argument.sdstest | 2 +- .../calls/recursion/transitive.sdstest | 6 +- .../missing null safety/main.sdstest | 82 ++++---- .../list index out of bounds/main.sdstest | 36 ++-- .../map key does not exist/main.sdstest | 22 +- .../division by zero/main.sdstest | 30 +-- .../assigned to typed parameter.sdstest | 104 +++++----- .../assigned to unresolved parameter.sdstest | 12 +- .../assigned to untyped parameter.sdstest | 104 +++++----- .../lambdas/context/invalid context.sdstest | 12 +- .../main.sdstest | 30 +-- .../references/function pointer/main.sdstest | 50 ++--- .../static class reference/main.sdstest | 30 +-- .../static enum reference/main.sdstest | 18 +- .../references/target/main.sdstest | 6 +- .../missing template expression/main.sdstest | 8 +- .../other/imports/main with issues.sdstest | 12 +- .../other/imports/main without issues.sdstest | 4 +- .../main.sdspipe | 24 +-- .../declarations in stub files/main.sdsstub | 24 +-- ...ng is allowed (no pipeline errors).sdstest | 24 +-- ...ything is allowed (no stub errors).sdstest | 24 +-- .../pipeline file (empty).sdspipe | 2 +- .../pipeline file (only annotations).sdspipe | 2 +- .../pipeline file (only imports).sdspipe | 2 +- ...le (with declarations and package).sdspipe | 4 +- ...(with declarations but no package).sdspipe | 4 +- .../stub file (empty).sdsstub | 2 +- .../stub file (only annotations).sdsstub | 2 +- .../stub file (only imports).sdsstub | 2 +- ...le (with declarations and package).sdsstub | 4 +- ...(with declarations but no package).sdsstub | 4 +- .../pipe elsewhere.sdspipe | 2 +- .../pipe in safeds.sdspipe | 2 +- .../pipe in subpackage of safeds.sdspipe | 2 +- .../stub elsewhere.sdsstub | 2 +- .../stub in safeds.sdsstub | 2 +- .../stub in subpackage of safeds.sdsstub | 2 +- .../test elsewhere.sdstest | 2 +- .../test in safeds.sdstest | 2 +- .../test in subpackage of safeds.sdstest | 2 +- .../assignments/has no effect/main.sdstest | 16 +- .../implicitly ignore result/main.sdstest | 34 ++-- .../assignments/nothing assigned/main.sdstest | 96 ++++----- .../yield forbidden in pipeline/main.sdstest | 6 +- .../has no effect/main.sdstest | 36 ++-- .../types/callable types/context/main.sdstest | 30 +-- .../callable types/context/nested.sdstest | 6 +- .../optional.sdstest | 2 +- .../required.sdstest | 2 +- .../duplicate literals/empty list.sdstest | 2 +- .../duplicate literals/main.sdstest | 8 +- .../must have literals/main.sdstest | 6 +- .../main.sdstest | 2 +- .../main.sdstest | 2 +- .../duplicate type parameter/main.sdstest | 20 +- .../main.sdstest | 12 +- .../too many type arguments/main.sdstest | 12 +- .../types/union types/context/main.sdstest | 28 +-- .../types/union types/context/nested.sdstest | 6 +- .../duplicate types/empty list.sdstest | 2 +- .../union types/duplicate types/main.sdstest | 8 +- .../union types/must have types/main.sdstest | 6 +- .../duplicate impurity reason/main.sdstest | 30 +-- .../no impure annotation.sdstest | 2 +- .../arguments.sdstest | 72 +++---- .../default values.sdstest | 60 +++--- .../invalid parameter name/main.sdstest | 20 +- .../main.sdstest | 22 +- .../no purity annotation.sdstest | 2 +- .../purity/no impurity reasons/main.sdstest | 12 +- .../purity/not specified/main.sdstest | 6 +- .../main.sdstest | 10 +- .../purity/pure and impure/main.sdstest | 8 +- .../main.sdstest | 20 +- .../main.sdstest | 34 ++-- .../style/unnecessary assignment/main.sdstest | 16 +- .../unnecessary body in class/main.sdstest | 6 +- .../unnecessary body in enum/main.sdstest | 4 +- .../info.sdstest | 2 +- .../no info.sdstest | 2 +- .../main.sdstest | 4 +- .../main.sdstest | 4 +- .../main.sdstest | 4 +- .../main.sdstest | 4 +- .../main.sdstest | 4 +- .../unnecessary elvis operator/main.sdstest | 40 ++-- .../unnecessary import alias/main.sdstest | 6 +- .../unnecessary null safety/main.sdstest | 82 ++++---- .../main.sdstest | 4 +- .../main.sdstest | 4 +- .../main.sdstest | 4 +- .../main.sdstest | 4 +- .../main.sdstest | 16 +- .../main.sdstest | 4 +- .../main.sdstest | 4 +- .../style/unnecessary union type/main.sdstest | 6 +- .../types/checking/arguments/main.sdstest | 10 +- .../arguments/with type parameters.sdstest | 40 ++-- .../types/checking/call receiver/main.sdstest | 58 +++--- .../main.sdstest | 4 +- .../checking/default values/main.sdstest | 8 +- .../with type parameters.sdstest | 36 ++-- .../indexed access on list/main.sdstest | 16 +- .../indexed access on map/main.sdstest | 22 +- .../indexed access receiver/main.sdstest | 20 +- .../checking/infix operations/main.sdstest | 192 +++++++++--------- .../types/checking/lists/main.sdstest | 6 +- .../types/checking/maps/main.sdstest | 12 +- .../checking/prefix operations/main.sdstest | 18 +- .../types/checking/type casts/main.sdstest | 4 +- .../main.sdstest | 40 ++-- .../main.sdstest | 26 +-- .../types/checking/yields/main.sdstest | 6 +- ...rgument list is missing altogether.sdstest | 2 +- .../main.sdstest | 22 +- .../missing type argument list/main.sdstest | 16 +- .../missing for attribute/main.sdstest | 4 +- .../missing for parameter/main.sdstest | 32 +-- .../missing for result/main.sdstest | 16 +- 1217 files changed, 5861 insertions(+), 5861 deletions(-) diff --git a/docs/development/call-graph-testing.md b/docs/development/call-graph-testing.md index 000d69ca..5c497fce 100644 --- a/docs/development/call-graph-testing.md +++ b/docs/development/call-graph-testing.md @@ -16,7 +16,7 @@ graph test. 3. Surround calls or callables for which you want to compute a call graph with test markers, e.g. `»f()«`. Add a comment in the preceding line with the following format: ```ts - # $TEST$ ["f", "$blockLambda", "$expressionLambda", "undefined"] + // $TEST$ ["f", "$blockLambda", "$expressionLambda", "undefined"] ``` The comment must contain an array with the names of the callables that are expected to be called. The order must match the actual call order. The names must be: diff --git a/docs/development/generation-testing.md b/docs/development/generation-testing.md index bfcc8099..5bb97e77 100644 --- a/docs/development/generation-testing.md +++ b/docs/development/generation-testing.md @@ -23,7 +23,7 @@ generation test. placeholder with test markers, e.g. `val »a« = 1;`. You may only mark a single placeholder this way. Add a comment in the preceding line with the following format: ```ts - # $TEST$ run_until + // $TEST$ run_until ``` 5. Add another folder called `generated` inside the folder that you created in step 1. Place folders and Python files inside the `generated` folder to specify the expected output of the program. The relative paths to the Python files diff --git a/docs/development/grammar-testing.md b/docs/development/grammar-testing.md index 19d3b6e5..99bfe195 100644 --- a/docs/development/grammar-testing.md +++ b/docs/development/grammar-testing.md @@ -18,11 +18,11 @@ test. 2. If you want to assert that a file is parsed without a syntax error[^1], add the following comment to the file: ```ts - # $TEST$ no_syntax_error + // $TEST$ no_syntax_error ``` If you instead want to assert that the parser detects a syntax error, add the following comment to the file: ```ts - # $TEST$ syntax_error + // $TEST$ syntax_error ``` !!! warning diff --git a/docs/development/partial-evaluation-testing.md b/docs/development/partial-evaluation-testing.md index 27871203..aae92008 100644 --- a/docs/development/partial-evaluation-testing.md +++ b/docs/development/partial-evaluation-testing.md @@ -20,9 +20,9 @@ partial evaluation test. 5. For each pair of test markers, add a test comment with one of the formats listed below. Test comments and test markers are mapped to each other by their position in the file, i.e. the first test comment corresponds to the first test marker, the second test comment corresponds to the second test marker, etc. - * `# $TEST$ constant equivalence_class `: Assert that all nodes with the same `` get partially evaluated + * `// $TEST$ constant equivalence_class `: Assert that all nodes with the same `` get partially evaluated successfully to the same constant expression. - * `# $TEST$ serialization `: Assert that the node gets partially evaluated to a constant expression + * `// $TEST$ serialization `: Assert that the node gets partially evaluated to a constant expression that serializes to ``. - * `# $TEST$ not constant`: Assert that the node cannot be evaluated to a constant expression. + * `// $TEST$ not constant`: Assert that the node cannot be evaluated to a constant expression. 6. Run the tests. The test runner will automatically pick up the new test. diff --git a/docs/development/scoping-testing.md b/docs/development/scoping-testing.md index 75bbc073..854b1fcb 100644 --- a/docs/development/scoping-testing.md +++ b/docs/development/scoping-testing.md @@ -19,17 +19,17 @@ test. 4. Surround **the name** of any declaration that you want to reference with test markers, e.g. `class »C«`. Add a comment in the preceding line with the following format (replace `` with some unique identifier): ```ts - # $TEST$ target + // $TEST$ target ``` 5. Surround references you want to test with test markers, e.g. `»C«()`. If you want to assert that the reference should be resolved, add a comment in the preceding line with the following format (replace `` with the identifier you previously assigned to the referenced declaration): ```ts - # $TEST$ references + // $TEST$ references ``` If you instead want to assert that the reference is unresolved, add the following comment to the preceding line: ```ts - # $TEST$ unresolved + // $TEST$ unresolved ``` 6. Run the tests. The test runner will automatically pick up the new test. diff --git a/docs/development/typing-testing.md b/docs/development/typing-testing.md index 2c02dcee..6f5405bb 100644 --- a/docs/development/typing-testing.md +++ b/docs/development/typing-testing.md @@ -21,7 +21,7 @@ test. 5. For each pair of test markers, add a test comment with one of the formats listed below. Test comments and test markers are mapped to each other by their position in the file, i.e. the first test comment corresponds to the first test marker, the second test comment corresponds to the second test marker, etc. - * `# $TEST$ equivalence_class `: Assert that all nodes with the same `` have the same type. All equivalence + * `// $TEST$ equivalence_class `: Assert that all nodes with the same `` have the same type. All equivalence classes must have at least two entries. - * `# $TEST$ serialization `: Assert that the serialized type of the node is ``. + * `// $TEST$ serialization `: Assert that the serialized type of the node is ``. 6. Run the tests. The test runner will automatically pick up the new test. diff --git a/docs/development/validation-testing.md b/docs/development/validation-testing.md index d1e8629b..7b8b5be3 100644 --- a/docs/development/validation-testing.md +++ b/docs/development/validation-testing.md @@ -41,19 +41,19 @@ validation test. Here are some examples: ```ts -# $TEST$ error "Incompatible type." +// $TEST$ error "Incompatible type." ``` We expect an error with the exact message `Incompatible type.`. ```ts -# $TEST$ no warning "Name should be lowerCamelCase." +// $TEST$ no warning "Name should be lowerCamelCase." ``` We expect no warning with the exact message `Name should be lowerCamelCase.`. ```ts -# $TEST$ info r".*empty.*" +// $TEST$ info r".*empty.*" ``` We expect an info with a message that matches the regular expression `.*empty.*`. diff --git a/packages/ttsl-lang/tests/helpers/testChecks.test.ts b/packages/ttsl-lang/tests/helpers/testChecks.test.ts index 6dbf9620..1d789e94 100644 --- a/packages/ttsl-lang/tests/helpers/testChecks.test.ts +++ b/packages/ttsl-lang/tests/helpers/testChecks.test.ts @@ -21,7 +21,7 @@ describe('findTestChecks', () => { }, { program: ` -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error `, expected: [ { @@ -32,7 +32,7 @@ describe('findTestChecks', () => { }, { program: ` -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error ${OPEN}${CLOSE} `, expected: [ @@ -48,9 +48,9 @@ ${OPEN}${CLOSE} }, { program: ` -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error ${OPEN}${CLOSE} -# $TEST$ syntax_error +// $TEST$ syntax_error ${OPEN}${CLOSE} `, expected: [ @@ -83,7 +83,7 @@ ${OPEN}${CLOSE} it('should report closing test markers without matching opening test marker', () => { const result = findTestChecks( ` - # $TEST$ no_syntax_error + // $TEST$ no_syntax_error ${OPEN}\n${CLOSE}${CLOSE} `, URI.parse(uri), @@ -98,7 +98,7 @@ ${OPEN}${CLOSE} it('should report opening test markers without matching closing test marker', () => { const result = findTestChecks( ` - # $TEST$ no_syntax_error + // $TEST$ no_syntax_error ${OPEN}\n${OPEN}${OPEN}${CLOSE} `, URI.parse(uri), @@ -113,7 +113,7 @@ ${OPEN}${CLOSE} it('should report if more ranges than comments are found', () => { const result = findTestChecks( ` - # $TEST$ no_syntax_error + // $TEST$ no_syntax_error ${OPEN}\n${CLOSE}${OPEN}\n${CLOSE} `, URI.parse(uri), @@ -137,7 +137,7 @@ ${OPEN}${CLOSE} it('should report if fewer ranges than comments are found if corresponding check is enabled', () => { const result = findTestChecks( ` - # $TEST$ no_syntax_error + // $TEST$ no_syntax_error `, URI.parse(uri), { failIfFewerRangesThanComments: true }, diff --git a/packages/ttsl-lang/tests/helpers/testComments.test.ts b/packages/ttsl-lang/tests/helpers/testComments.test.ts index ef5d0ddf..467fc4db 100644 --- a/packages/ttsl-lang/tests/helpers/testComments.test.ts +++ b/packages/ttsl-lang/tests/helpers/testComments.test.ts @@ -9,13 +9,13 @@ describe('findTestComments', () => { id: 'empty program', }, { - program: `# $TEST$ no_syntax_error`, + program: `// $TEST$ no_syntax_error`, expected: ['no_syntax_error'], id: 'single comment', }, { - program: `# $TEST$ no_syntax_error - # $TEST$ syntax_error + program: `// $TEST$ no_syntax_error + // $TEST$ syntax_error // another comment`, expected: ['no_syntax_error', 'syntax_error'], id: 'multiple comments', diff --git a/packages/ttsl-lang/tests/helpers/testComments.ts b/packages/ttsl-lang/tests/helpers/testComments.ts index 50e54999..723518a8 100644 --- a/packages/ttsl-lang/tests/helpers/testComments.ts +++ b/packages/ttsl-lang/tests/helpers/testComments.ts @@ -1,7 +1,7 @@ const pattern = /\/\/\s*\$TEST\$(?[^\n]*)/gu; /** - * Finds all test comments (`# $TEST$ ...`) in the given program. + * Finds all test comments (`// $TEST$ ...`) in the given program. * * @param program The program with test comments. * @return The list of test comments. diff --git a/packages/ttsl-lang/tests/language/lsp/safe-ds-inlay-hint-provider.test.ts b/packages/ttsl-lang/tests/language/lsp/safe-ds-inlay-hint-provider.test.ts index e7ef33b4..f0ac8434 100644 --- a/packages/ttsl-lang/tests/language/lsp/safe-ds-inlay-hint-provider.test.ts +++ b/packages/ttsl-lang/tests/language/lsp/safe-ds-inlay-hint-provider.test.ts @@ -18,7 +18,7 @@ describe('SafeDsInlayHintProvider', async () => { fun f(p: Int) pipeline myPipeline { - # $TEST$ before "p = " + // $TEST$ before "p = " f(»«1); } `, @@ -48,7 +48,7 @@ describe('SafeDsInlayHintProvider', async () => { code: ` pipeline myPipeline { () { - # $TEST$ after ": literal<1>" + // $TEST$ after ": literal<1>" yield r»« = 1; }; } @@ -58,7 +58,7 @@ describe('SafeDsInlayHintProvider', async () => { testName: 'placeholder', code: ` pipeline myPipeline { - # $TEST$ after ": literal<1>" + // $TEST$ after ": literal<1>" val x»« = 1; } `, @@ -75,7 +75,7 @@ describe('SafeDsInlayHintProvider', async () => { testName: 'yield', code: ` segment s() -> r: Int { - # $TEST$ after ": literal<1>" + // $TEST$ after ": literal<1>" yield r»« = 1; } `, diff --git a/packages/ttsl-lang/tests/resources/call graph/annotation call.sdstest b/packages/ttsl-lang/tests/resources/call graph/annotation call.sdstest index b11f315a..cd5e95f0 100644 --- a/packages/ttsl-lang/tests/resources/call graph/annotation call.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/annotation call.sdstest @@ -3,6 +3,6 @@ package tests.callGraph.annotationCall annotation MyAnnotation pipeline myPipeline { - # $TEST$ ["undefined"] + // $TEST$ ["undefined"] »MyAnnotation()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/block lambda.sdstest b/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/block lambda.sdstest index cd7fd3ed..4d4aff34 100644 --- a/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/block lambda.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/block lambda.sdstest @@ -7,7 +7,7 @@ pipeline myPipeline { param1(f); }; - # $TEST$ ["$blockLambda", "$blockLambda", "f"] + // $TEST$ ["$blockLambda", "$blockLambda", "f"] »lambda((param) { param(); })«; diff --git a/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/callable does not get called.sdstest b/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/callable does not get called.sdstest index be1b410c..f792a880 100644 --- a/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/callable does not get called.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/callable does not get called.sdstest @@ -5,6 +5,6 @@ package tests.callGraph.blockLambdaCall.argument.callableDoesNotGetCalled pipeline myPipeline { val lambda = (param: () -> ()) {}; - # $TEST$ ["$blockLambda"] + // $TEST$ ["$blockLambda"] »lambda(f)«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/expression lambda.sdstest b/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/expression lambda.sdstest index 7153cbcc..b57b5698 100644 --- a/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/expression lambda.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/expression lambda.sdstest @@ -7,6 +7,6 @@ pipeline myPipeline { param1(f); }; - # $TEST$ ["$blockLambda", "$expressionLambda", "f"] + // $TEST$ ["$blockLambda", "$expressionLambda", "f"] »lambda((param) -> param())«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/function.sdstest b/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/function.sdstest index 9dafab06..cd871f01 100644 --- a/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/function.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/function.sdstest @@ -7,6 +7,6 @@ pipeline myPipeline { param(); }; - # $TEST$ ["$blockLambda", "f"] + // $TEST$ ["$blockLambda", "f"] »lambda(f)«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/segment.sdstest b/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/segment.sdstest index eefc870a..846cf3ec 100644 --- a/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/segment.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/segment.sdstest @@ -7,7 +7,7 @@ pipeline myPipeline { param1(f); }; - # $TEST$ ["$blockLambda", "mySegment", "f"] + // $TEST$ ["$blockLambda", "mySegment", "f"] »lambda(mySegment)«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/block lambda call/basic.sdstest b/packages/ttsl-lang/tests/resources/call graph/block lambda call/basic.sdstest index 4c8d4123..748803de 100644 --- a/packages/ttsl-lang/tests/resources/call graph/block lambda call/basic.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/block lambda call/basic.sdstest @@ -3,6 +3,6 @@ package tests.callGraph.blockLambdaCall.basic pipeline myPipeline { val lambda = () {}; - # $TEST$ ["$blockLambda"] + // $TEST$ ["$blockLambda"] »lambda()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/block lambda call/body/function call in nested lambda.sdstest b/packages/ttsl-lang/tests/resources/call graph/block lambda call/body/function call in nested lambda.sdstest index 472422ac..8c151f05 100644 --- a/packages/ttsl-lang/tests/resources/call graph/block lambda call/body/function call in nested lambda.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/block lambda call/body/function call in nested lambda.sdstest @@ -5,6 +5,6 @@ package tests.callGraph.blockLambdaCall.body.functionCallInNestedLambda pipeline myPipeline { val lambda = () { () -> f(); }; - # $TEST$ ["$blockLambda"] + // $TEST$ ["$blockLambda"] »lambda()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/block lambda call/body/function call.sdstest b/packages/ttsl-lang/tests/resources/call graph/block lambda call/body/function call.sdstest index 4a6e5039..0b7b9583 100644 --- a/packages/ttsl-lang/tests/resources/call graph/block lambda call/body/function call.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/block lambda call/body/function call.sdstest @@ -5,6 +5,6 @@ package tests.callGraph.blockLambdaCall.body.functionCall pipeline myPipeline { val lambda = () { f(); }; - # $TEST$ ["$blockLambda", "f"] + // $TEST$ ["$blockLambda", "f"] »lambda()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/block lambda call/default value/call.sdstest b/packages/ttsl-lang/tests/resources/call graph/block lambda call/default value/call.sdstest index 6bb5d56d..1db677a7 100644 --- a/packages/ttsl-lang/tests/resources/call graph/block lambda call/default value/call.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/block lambda call/default value/call.sdstest @@ -7,6 +7,6 @@ pipeline myPipeline { f: Any = default() ) {}; - # $TEST$ ["$blockLambda", "default"] + // $TEST$ ["$blockLambda", "default"] »lambda()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/block lambda call/default value/callable.sdstest b/packages/ttsl-lang/tests/resources/call graph/block lambda call/default value/callable.sdstest index 288a96cd..6bcb97e8 100644 --- a/packages/ttsl-lang/tests/resources/call graph/block lambda call/default value/callable.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/block lambda call/default value/callable.sdstest @@ -9,6 +9,6 @@ pipeline myPipeline { f(); }; - # $TEST$ ["$blockLambda", "default"] + // $TEST$ ["$blockLambda", "default"] »lambda()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/block lambda call/default value/previous parameter.sdstest b/packages/ttsl-lang/tests/resources/call graph/block lambda call/default value/previous parameter.sdstest index 6856a646..91200b0c 100644 --- a/packages/ttsl-lang/tests/resources/call graph/block lambda call/default value/previous parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/block lambda call/default value/previous parameter.sdstest @@ -8,6 +8,6 @@ pipeline myPipeline { g: Any = f() ) {}; - # $TEST$ ["$blockLambda", "default"] + // $TEST$ ["$blockLambda", "default"] »lambda()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/block lambda call/null safe.sdstest b/packages/ttsl-lang/tests/resources/call graph/block lambda call/null safe.sdstest index ddcb2826..40999c36 100644 --- a/packages/ttsl-lang/tests/resources/call graph/block lambda call/null safe.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/block lambda call/null safe.sdstest @@ -3,6 +3,6 @@ package tests.callGraph.blockLambdaCall.nullSafe pipeline myPipeline { val lambda = () {}; - # $TEST$ ["$blockLambda"] + // $TEST$ ["$blockLambda"] »lambda?()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/callable type call.sdstest b/packages/ttsl-lang/tests/resources/call graph/callable type call.sdstest index 307c650b..1ca18602 100644 --- a/packages/ttsl-lang/tests/resources/call graph/callable type call.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/callable type call.sdstest @@ -1,6 +1,6 @@ package tests.callGraph.callableTypeCall segment mySegment(param: () -> ()) { - # $TEST$ ["param"] + // $TEST$ ["param"] »param()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/callable/block lambda.sdstest b/packages/ttsl-lang/tests/resources/call graph/callable/block lambda.sdstest index 3188873f..891b0266 100644 --- a/packages/ttsl-lang/tests/resources/call graph/callable/block lambda.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/callable/block lambda.sdstest @@ -4,6 +4,6 @@ package tests.callGraph.callable.blockLambda @Pure fun g() -> r: Any pipeline myPipeline { - # $TEST$ ["$blockLambda", "f", "g"] + // $TEST$ ["$blockLambda", "f", "g"] »(param: Any = f()) { g(); }«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/callable/class.sdstest b/packages/ttsl-lang/tests/resources/call graph/callable/class.sdstest index 2ec64d4e..68ec2646 100644 --- a/packages/ttsl-lang/tests/resources/call graph/callable/class.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/callable/class.sdstest @@ -3,5 +3,5 @@ package tests.callGraph.callable.`class` @Pure fun f() -> r: Any @Pure fun g() -# $TEST$ ["MyClass", "f", "g"] +// $TEST$ ["MyClass", "f", "g"] »class MyClass(param1: Any = f(), param2: () -> () = g)« diff --git a/packages/ttsl-lang/tests/resources/call graph/callable/enum variant.sdstest b/packages/ttsl-lang/tests/resources/call graph/callable/enum variant.sdstest index fbdd0f18..8fda813f 100644 --- a/packages/ttsl-lang/tests/resources/call graph/callable/enum variant.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/callable/enum variant.sdstest @@ -3,7 +3,7 @@ package tests.callGraph.callable.enumVariant @Pure fun f() -> r: Any @Pure fun g() -# $TEST$ ["MyEnumVariant", "f", "g"] +// $TEST$ ["MyEnumVariant", "f", "g"] enum MyEnum { »MyEnumVariant(param1: Any = f(), param2: () -> () = g)« } diff --git a/packages/ttsl-lang/tests/resources/call graph/callable/expression lambda.sdstest b/packages/ttsl-lang/tests/resources/call graph/callable/expression lambda.sdstest index 1a1be867..1b6af2fd 100644 --- a/packages/ttsl-lang/tests/resources/call graph/callable/expression lambda.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/callable/expression lambda.sdstest @@ -4,6 +4,6 @@ package tests.callGraph.callable.expressionLambda @Pure fun g() -> r: Any pipeline myPipeline { - # $TEST$ ["$expressionLambda", "f", "g"] + // $TEST$ ["$expressionLambda", "f", "g"] »(param: Any = f()) -> g()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/callable/function.sdstest b/packages/ttsl-lang/tests/resources/call graph/callable/function.sdstest index 756f8b3c..8d8659fe 100644 --- a/packages/ttsl-lang/tests/resources/call graph/callable/function.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/callable/function.sdstest @@ -3,5 +3,5 @@ package tests.callGraph.callable.function @Pure fun f() -> r: Any @Pure fun g() -# $TEST$ ["myFunction", "f", "g"] +// $TEST$ ["myFunction", "f", "g"] @Pure »fun myFunction(param1: Any = f(), param2: () -> () = g)« diff --git a/packages/ttsl-lang/tests/resources/call graph/callable/segment.sdstest b/packages/ttsl-lang/tests/resources/call graph/callable/segment.sdstest index a50d3858..47286ed2 100644 --- a/packages/ttsl-lang/tests/resources/call graph/callable/segment.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/callable/segment.sdstest @@ -3,7 +3,7 @@ package tests.callGraph.callable.`segment` @Pure fun f() -> r: Any @Pure fun g() -> r: Any -# $TEST$ ["mySegment", "f", "g"] +// $TEST$ ["mySegment", "f", "g"] »segment mySegment(param: Any = f()) { g(); }« diff --git a/packages/ttsl-lang/tests/resources/call graph/class call/argument/call.sdstest b/packages/ttsl-lang/tests/resources/call graph/class call/argument/call.sdstest index 4e98f91f..90de9e57 100644 --- a/packages/ttsl-lang/tests/resources/call graph/class call/argument/call.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/class call/argument/call.sdstest @@ -8,6 +8,6 @@ class MyClass( ) pipeline myPipeline { - # $TEST$ ["MyClass"] + // $TEST$ ["MyClass"] »MyClass(Passed())«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/class call/argument/callable.sdstest b/packages/ttsl-lang/tests/resources/call graph/class call/argument/callable.sdstest index f6f13977..90b51076 100644 --- a/packages/ttsl-lang/tests/resources/call graph/class call/argument/callable.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/class call/argument/callable.sdstest @@ -8,6 +8,6 @@ class MyClass( ) pipeline myPipeline { - # $TEST$ ["MyClass", "Passed"] + // $TEST$ ["MyClass", "Passed"] »MyClass(Passed)«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/class call/argument/other.sdstest b/packages/ttsl-lang/tests/resources/call graph/class call/argument/other.sdstest index 7aeb0f30..1d4f722f 100644 --- a/packages/ttsl-lang/tests/resources/call graph/class call/argument/other.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/class call/argument/other.sdstest @@ -8,6 +8,6 @@ class MyClass( ) pipeline myPipeline { - # $TEST$ ["MyClass"] + // $TEST$ ["MyClass"] »MyClass(1)«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/class call/basic.sdstest b/packages/ttsl-lang/tests/resources/call graph/class call/basic.sdstest index a9172bb0..4f987788 100644 --- a/packages/ttsl-lang/tests/resources/call graph/class call/basic.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/class call/basic.sdstest @@ -3,6 +3,6 @@ package tests.callGraph.classCall.basic class MyClass() pipeline myPipeline { - # $TEST$ ["MyClass"] + // $TEST$ ["MyClass"] »MyClass()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/class call/default value/call.sdstest b/packages/ttsl-lang/tests/resources/call graph/class call/default value/call.sdstest index 18fa3df0..01780506 100644 --- a/packages/ttsl-lang/tests/resources/call graph/class call/default value/call.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/class call/default value/call.sdstest @@ -8,6 +8,6 @@ class MyClass( ) pipeline myPipeline { - # $TEST$ ["MyClass", "Default"] + // $TEST$ ["MyClass", "Default"] »MyClass()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/class call/default value/callable.sdstest b/packages/ttsl-lang/tests/resources/call graph/class call/default value/callable.sdstest index bc595e51..a32058d8 100644 --- a/packages/ttsl-lang/tests/resources/call graph/class call/default value/callable.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/class call/default value/callable.sdstest @@ -8,6 +8,6 @@ class MyClass( ) pipeline myPipeline { - # $TEST$ ["MyClass", "Default"] + // $TEST$ ["MyClass", "Default"] »MyClass()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/class call/default value/previous parameter.sdstest b/packages/ttsl-lang/tests/resources/call graph/class call/default value/previous parameter.sdstest index c257691b..3b944e28 100644 --- a/packages/ttsl-lang/tests/resources/call graph/class call/default value/previous parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/class call/default value/previous parameter.sdstest @@ -8,6 +8,6 @@ class MyClass( ) pipeline myPipeline { - # $TEST$ ["MyClass", "default", "default"] + // $TEST$ ["MyClass", "default", "default"] »MyClass()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/class call/null safe.sdstest b/packages/ttsl-lang/tests/resources/call graph/class call/null safe.sdstest index 055ea6a8..820cc675 100644 --- a/packages/ttsl-lang/tests/resources/call graph/class call/null safe.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/class call/null safe.sdstest @@ -3,6 +3,6 @@ package tests.callGraph.classCall.nullSafe class MyClass() pipeline myPipeline { - # $TEST$ ["MyClass"] + // $TEST$ ["MyClass"] »MyClass?()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/closure/block lambda passed as argument.sdstest b/packages/ttsl-lang/tests/resources/call graph/closure/block lambda passed as argument.sdstest index 3acf8952..225fb80e 100644 --- a/packages/ttsl-lang/tests/resources/call graph/closure/block lambda passed as argument.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/closure/block lambda passed as argument.sdstest @@ -13,6 +13,6 @@ segment mySegment2(param2: () -> ()) { } pipeline myPipeline { - # $TEST$ ["mySegment1", "mySegment2", "$blockLambda", "$blockLambda", "f"] + // $TEST$ ["mySegment1", "mySegment2", "$blockLambda", "$blockLambda", "f"] »mySegment1(() { f(); })«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/closure/block lambda returned.sdstest b/packages/ttsl-lang/tests/resources/call graph/closure/block lambda returned.sdstest index 524871c8..07f2d53a 100644 --- a/packages/ttsl-lang/tests/resources/call graph/closure/block lambda returned.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/closure/block lambda returned.sdstest @@ -10,6 +10,6 @@ pipeline myPipeline { }; val closure = lambda(f); - # $TEST$ ["$blockLambda", "f"] + // $TEST$ ["$blockLambda", "f"] »closure()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/closure/expression lambda passed as argument.sdstest b/packages/ttsl-lang/tests/resources/call graph/closure/expression lambda passed as argument.sdstest index 83c018e6..14a793f9 100644 --- a/packages/ttsl-lang/tests/resources/call graph/closure/expression lambda passed as argument.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/closure/expression lambda passed as argument.sdstest @@ -11,6 +11,6 @@ segment mySegment2(param2: () -> ()) { } pipeline myPipeline { - # $TEST$ ["mySegment1", "mySegment2", "$expressionLambda", "$expressionLambda", "f"] + // $TEST$ ["mySegment1", "mySegment2", "$expressionLambda", "$expressionLambda", "f"] »mySegment1(() -> f())«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/closure/expression lambda returned.sdstest b/packages/ttsl-lang/tests/resources/call graph/closure/expression lambda returned.sdstest index 84e78921..d8156494 100644 --- a/packages/ttsl-lang/tests/resources/call graph/closure/expression lambda returned.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/closure/expression lambda returned.sdstest @@ -8,6 +8,6 @@ pipeline myPipeline { () -> param(); val closure = lambda(f); - # $TEST$ ["$expressionLambda", "f"] + // $TEST$ ["$expressionLambda", "f"] »closure()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/default value handling in entry point.sdstest b/packages/ttsl-lang/tests/resources/call graph/default value handling in entry point.sdstest index 883d1b18..1aadbec4 100644 --- a/packages/ttsl-lang/tests/resources/call graph/default value handling in entry point.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/default value handling in entry point.sdstest @@ -7,6 +7,6 @@ package tests.callGraph.defaultValueHandlingInEntryPoint @Pure fun default() -> r: Any segment mySegment(param: () -> () = default) { - # $TEST$ ["param"] + // $TEST$ ["param"] »param()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/enum variant call/argument/call.sdstest b/packages/ttsl-lang/tests/resources/call graph/enum variant call/argument/call.sdstest index 590a4a0c..11d19c1d 100644 --- a/packages/ttsl-lang/tests/resources/call graph/enum variant call/argument/call.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/enum variant call/argument/call.sdstest @@ -10,6 +10,6 @@ enum MyEnum { } pipeline myPipeline { - # $TEST$ ["MyVariant"] + // $TEST$ ["MyVariant"] »MyEnum.MyVariant(passed())«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/enum variant call/argument/callable.sdstest b/packages/ttsl-lang/tests/resources/call graph/enum variant call/argument/callable.sdstest index 0a656665..c2846b01 100644 --- a/packages/ttsl-lang/tests/resources/call graph/enum variant call/argument/callable.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/enum variant call/argument/callable.sdstest @@ -10,6 +10,6 @@ enum MyEnum { } pipeline myPipeline { - # $TEST$ ["MyVariant", "passed"] + // $TEST$ ["MyVariant", "passed"] »MyEnum.MyVariant(passed)«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/enum variant call/argument/other.sdstest b/packages/ttsl-lang/tests/resources/call graph/enum variant call/argument/other.sdstest index b23a5ae4..6b1082e5 100644 --- a/packages/ttsl-lang/tests/resources/call graph/enum variant call/argument/other.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/enum variant call/argument/other.sdstest @@ -10,6 +10,6 @@ enum MyEnum { } pipeline myPipeline { - # $TEST$ ["MyVariant"] + // $TEST$ ["MyVariant"] »MyEnum.MyVariant(1)«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/enum variant call/basic.sdstest b/packages/ttsl-lang/tests/resources/call graph/enum variant call/basic.sdstest index b2664a6a..6ccdec78 100644 --- a/packages/ttsl-lang/tests/resources/call graph/enum variant call/basic.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/enum variant call/basic.sdstest @@ -5,6 +5,6 @@ enum MyEnum { } pipeline myPipeline { - # $TEST$ ["MyVariant"] + // $TEST$ ["MyVariant"] »MyEnum.MyVariant()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/enum variant call/called twice.sdstest b/packages/ttsl-lang/tests/resources/call graph/enum variant call/called twice.sdstest index f52a9686..8c521fd4 100644 --- a/packages/ttsl-lang/tests/resources/call graph/enum variant call/called twice.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/enum variant call/called twice.sdstest @@ -5,6 +5,6 @@ enum MyEnum { } pipeline myPipeline { - # $TEST$ ["undefined"] + // $TEST$ ["undefined"] »MyEnum.MyVariant()()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/enum variant call/default value/call.sdstest b/packages/ttsl-lang/tests/resources/call graph/enum variant call/default value/call.sdstest index 3882471c..12e4a7e0 100644 --- a/packages/ttsl-lang/tests/resources/call graph/enum variant call/default value/call.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/enum variant call/default value/call.sdstest @@ -10,6 +10,6 @@ enum MyEnum { } pipeline myPipeline { - # $TEST$ ["MyVariant", "default"] + // $TEST$ ["MyVariant", "default"] »MyEnum.MyVariant()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/enum variant call/default value/callable.sdstest b/packages/ttsl-lang/tests/resources/call graph/enum variant call/default value/callable.sdstest index 333a83bb..90aebe9d 100644 --- a/packages/ttsl-lang/tests/resources/call graph/enum variant call/default value/callable.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/enum variant call/default value/callable.sdstest @@ -10,6 +10,6 @@ enum MyEnum { } pipeline myPipeline { - # $TEST$ ["MyVariant", "default"] + // $TEST$ ["MyVariant", "default"] »MyEnum.MyVariant()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/enum variant call/default value/previous parameter.sdstest b/packages/ttsl-lang/tests/resources/call graph/enum variant call/default value/previous parameter.sdstest index 19d0b6d4..4dde1013 100644 --- a/packages/ttsl-lang/tests/resources/call graph/enum variant call/default value/previous parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/enum variant call/default value/previous parameter.sdstest @@ -10,6 +10,6 @@ enum MyEnum { } pipeline myPipeline { - # $TEST$ ["MyVariant", "default", "default"] + // $TEST$ ["MyVariant", "default", "default"] »MyEnum.MyVariant()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/enum variant call/null safe.sdstest b/packages/ttsl-lang/tests/resources/call graph/enum variant call/null safe.sdstest index 4f7ce9f1..57794cb0 100644 --- a/packages/ttsl-lang/tests/resources/call graph/enum variant call/null safe.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/enum variant call/null safe.sdstest @@ -5,6 +5,6 @@ enum MyEnum { } pipeline myPipeline { - # $TEST$ ["MyVariant"] + // $TEST$ ["MyVariant"] »MyEnum.MyVariant?()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/block lambda.sdstest b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/block lambda.sdstest index b70971c9..76018d4a 100644 --- a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/block lambda.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/block lambda.sdstest @@ -6,7 +6,7 @@ pipeline myPipeline { val lambda = (param1: (param: () -> ()) -> ()) -> param1(f); - # $TEST$ ["$expressionLambda", "$blockLambda", "f"] + // $TEST$ ["$expressionLambda", "$blockLambda", "f"] »lambda((param) { param(); })«; diff --git a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/callable does not get called.sdstest b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/callable does not get called.sdstest index 14f00c1a..64aef28f 100644 --- a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/callable does not get called.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/callable does not get called.sdstest @@ -5,6 +5,6 @@ package tests.callGraph.expressionLambdaCall.argument.callableDoesNotGetCalled pipeline myPipeline { val lambda = (param: () -> ()) -> 1; - # $TEST$ ["$expressionLambda"] + // $TEST$ ["$expressionLambda"] »lambda(f)«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/expression lambda.sdstest b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/expression lambda.sdstest index c8db1bda..0a29cff1 100644 --- a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/expression lambda.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/expression lambda.sdstest @@ -6,6 +6,6 @@ pipeline myPipeline { val lambda = (param1: (param: () -> ()) -> ()) -> param1(f); - # $TEST$ ["$expressionLambda", "$expressionLambda", "f"] + // $TEST$ ["$expressionLambda", "$expressionLambda", "f"] »lambda((param) -> param())«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/function.sdstest b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/function.sdstest index 5cf8bad7..b98eca57 100644 --- a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/function.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/function.sdstest @@ -6,6 +6,6 @@ pipeline myPipeline { val lambda = (param: () -> ()) -> param(); - # $TEST$ ["$expressionLambda", "f"] + // $TEST$ ["$expressionLambda", "f"] »lambda(f)«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/segment.sdstest b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/segment.sdstest index 11c00507..4346e3b0 100644 --- a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/segment.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/segment.sdstest @@ -6,7 +6,7 @@ pipeline myPipeline { val lambda = (param1: (param: () -> ()) -> ()) -> param1(f); - # $TEST$ ["$expressionLambda", "mySegment", "f"] + // $TEST$ ["$expressionLambda", "mySegment", "f"] »lambda(mySegment)«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/basic.sdstest b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/basic.sdstest index 38aef9e7..a9049d41 100644 --- a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/basic.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/basic.sdstest @@ -3,6 +3,6 @@ package tests.callGraph.expressionLambdaCall.basic pipeline myPipeline { val lambda = () -> 1; - # $TEST$ ["$expressionLambda"] + // $TEST$ ["$expressionLambda"] »lambda()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/body/function call in nested lambda.sdstest b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/body/function call in nested lambda.sdstest index 891b2ddd..53ade196 100644 --- a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/body/function call in nested lambda.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/body/function call in nested lambda.sdstest @@ -5,6 +5,6 @@ package tests.callGraph.expressionLambdaCall.body.functionCallInNestedLambda pipeline myPipeline { val lambda = () -> () -> f(); - # $TEST$ ["$expressionLambda"] + // $TEST$ ["$expressionLambda"] »lambda()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/body/function call.sdstest b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/body/function call.sdstest index 77d1f41f..02efa731 100644 --- a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/body/function call.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/body/function call.sdstest @@ -5,6 +5,6 @@ package tests.callGraph.expressionLambdaCall.body.functionCall pipeline myPipeline { val lambda = () -> f(); - # $TEST$ ["$expressionLambda", "f"] + // $TEST$ ["$expressionLambda", "f"] »lambda()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/default value/call.sdstest b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/default value/call.sdstest index 96e6e3fe..4cfffd24 100644 --- a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/default value/call.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/default value/call.sdstest @@ -7,6 +7,6 @@ pipeline myPipeline { f: Any = default() ) -> 1; - # $TEST$ ["$expressionLambda", "default"] + // $TEST$ ["$expressionLambda", "default"] »lambda()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/default value/callable.sdstest b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/default value/callable.sdstest index dd5c84a9..a2172d75 100644 --- a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/default value/callable.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/default value/callable.sdstest @@ -7,6 +7,6 @@ pipeline myPipeline { f: () -> () = default ) -> f(); - # $TEST$ ["$expressionLambda", "default"] + // $TEST$ ["$expressionLambda", "default"] »lambda()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/default value/previous parameter.sdstest b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/default value/previous parameter.sdstest index ffe60681..95f6740c 100644 --- a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/default value/previous parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/default value/previous parameter.sdstest @@ -8,6 +8,6 @@ pipeline myPipeline { g: Any = f() ) -> 1; - # $TEST$ ["$expressionLambda", "default"] + // $TEST$ ["$expressionLambda", "default"] »lambda()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/null safe.sdstest b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/null safe.sdstest index cf5b12f7..96354110 100644 --- a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/null safe.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/null safe.sdstest @@ -3,6 +3,6 @@ package tests.callGraph.expressionLambdaCall.nullSafe pipeline myPipeline { val lambda = () -> 1; - # $TEST$ ["$expressionLambda"] + // $TEST$ ["$expressionLambda"] »lambda?()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/function call/argument/call.sdstest b/packages/ttsl-lang/tests/resources/call graph/function call/argument/call.sdstest index 773b1521..2316706e 100644 --- a/packages/ttsl-lang/tests/resources/call graph/function call/argument/call.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/function call/argument/call.sdstest @@ -8,6 +8,6 @@ package tests.callGraph.functionCall.argument.call ) pipeline myPipeline { - # $TEST$ ["myFunction"] + // $TEST$ ["myFunction"] »myFunction(passed())«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/function call/argument/callable.sdstest b/packages/ttsl-lang/tests/resources/call graph/function call/argument/callable.sdstest index bd98f406..11e86680 100644 --- a/packages/ttsl-lang/tests/resources/call graph/function call/argument/callable.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/function call/argument/callable.sdstest @@ -8,6 +8,6 @@ package tests.callGraph.functionCall.argument.callable ) pipeline myPipeline { - # $TEST$ ["myFunction", "passed"] + // $TEST$ ["myFunction", "passed"] »myFunction(passed)«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/function call/argument/other.sdstest b/packages/ttsl-lang/tests/resources/call graph/function call/argument/other.sdstest index 8ece5918..adf0c5ed 100644 --- a/packages/ttsl-lang/tests/resources/call graph/function call/argument/other.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/function call/argument/other.sdstest @@ -8,6 +8,6 @@ package tests.callGraph.functionCall.argument.other ) pipeline myPipeline { - # $TEST$ ["myFunction"] + // $TEST$ ["myFunction"] »myFunction(1)«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/function call/basic.sdstest b/packages/ttsl-lang/tests/resources/call graph/function call/basic.sdstest index 45398ce3..7ede6cbc 100644 --- a/packages/ttsl-lang/tests/resources/call graph/function call/basic.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/function call/basic.sdstest @@ -3,6 +3,6 @@ package tests.callGraph.functionCall.basic @Pure fun myFunction() pipeline myPipeline { - # $TEST$ ["myFunction"] + // $TEST$ ["myFunction"] »myFunction()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/function call/default value/call.sdstest b/packages/ttsl-lang/tests/resources/call graph/function call/default value/call.sdstest index f29f485c..e7524ff0 100644 --- a/packages/ttsl-lang/tests/resources/call graph/function call/default value/call.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/function call/default value/call.sdstest @@ -8,6 +8,6 @@ package tests.callGraph.functionCall.defaultValue.call ) pipeline myPipeline { - # $TEST$ ["myFunction", "default"] + // $TEST$ ["myFunction", "default"] »myFunction()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/function call/default value/callable.sdstest b/packages/ttsl-lang/tests/resources/call graph/function call/default value/callable.sdstest index 429ac9f3..a5152dd4 100644 --- a/packages/ttsl-lang/tests/resources/call graph/function call/default value/callable.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/function call/default value/callable.sdstest @@ -8,6 +8,6 @@ package tests.callGraph.functionCall.defaultValue.callable ) pipeline myPipeline { - # $TEST$ ["myFunction", "default"] + // $TEST$ ["myFunction", "default"] »myFunction()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/function call/default value/previous parameter.sdstest b/packages/ttsl-lang/tests/resources/call graph/function call/default value/previous parameter.sdstest index 3677b21d..8f7a602c 100644 --- a/packages/ttsl-lang/tests/resources/call graph/function call/default value/previous parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/function call/default value/previous parameter.sdstest @@ -8,6 +8,6 @@ package tests.callGraph.functionCall.defaultValue.previousParameter ) pipeline myPipeline { - # $TEST$ ["myFunction", "default", "default"] + // $TEST$ ["myFunction", "default", "default"] »myFunction()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/function call/instance method.sdstest b/packages/ttsl-lang/tests/resources/call graph/function call/instance method.sdstest index c312edcc..74ed9f83 100644 --- a/packages/ttsl-lang/tests/resources/call graph/function call/instance method.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/function call/instance method.sdstest @@ -5,6 +5,6 @@ class MyClass { } pipeline myPipeline { - # $TEST$ ["myFunction"] + // $TEST$ ["myFunction"] »MyClass().myFunction()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/function call/null safe.sdstest b/packages/ttsl-lang/tests/resources/call graph/function call/null safe.sdstest index 37b40dbf..c2d4effb 100644 --- a/packages/ttsl-lang/tests/resources/call graph/function call/null safe.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/function call/null safe.sdstest @@ -11,15 +11,15 @@ segment mySegment( myClass: MyClass, myClassOrNull: MyClass? ) { - # $TEST$ ["myFunction"] + // $TEST$ ["myFunction"] »myFunction?()«; - # $TEST$ ["myStaticMethod"] + // $TEST$ ["myStaticMethod"] »MyClass.myStaticMethod?()«; - # $TEST$ ["myInstanceMethod"] + // $TEST$ ["myInstanceMethod"] »myClass.myInstanceMethod?()«; - # $TEST$ ["myInstanceMethod"] + // $TEST$ ["myInstanceMethod"] »myClassOrNull?.myInstanceMethod?()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/function call/static method.sdstest b/packages/ttsl-lang/tests/resources/call graph/function call/static method.sdstest index eca7819e..092b5f9d 100644 --- a/packages/ttsl-lang/tests/resources/call graph/function call/static method.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/function call/static method.sdstest @@ -5,6 +5,6 @@ class MyClass { } pipeline myPipeline { - # $TEST$ ["myFunction"] + // $TEST$ ["myFunction"] »MyClass.myFunction()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/recursion/direct.sdstest b/packages/ttsl-lang/tests/resources/call graph/recursion/direct.sdstest index f871442b..7cb6cc27 100644 --- a/packages/ttsl-lang/tests/resources/call graph/recursion/direct.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/recursion/direct.sdstest @@ -1,16 +1,16 @@ package tests.callGraph.recursion.direct segment s1() { - # $TEST$ ["s2", "s3", "s2"] + // $TEST$ ["s2", "s3", "s2"] »s2()«; } segment s2() { - # $TEST$ ["s3", "s2", "s3"] + // $TEST$ ["s3", "s2", "s3"] »s3()«; } segment s3() { - # $TEST$ ["s2", "s3", "s2"] + // $TEST$ ["s2", "s3", "s2"] »s2()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/recursion/not recursive.sdstest b/packages/ttsl-lang/tests/resources/call graph/recursion/not recursive.sdstest index 9264d97c..00a9c424 100644 --- a/packages/ttsl-lang/tests/resources/call graph/recursion/not recursive.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/recursion/not recursive.sdstest @@ -6,7 +6,7 @@ package tests.callGraph.recursion.notRecursive */ segment s1() { - # $TEST$ ["s2", "$expressionLambda", "s2", "$blockLambda"] + // $TEST$ ["s2", "$expressionLambda", "s2", "$blockLambda"] »s2(() -> s2())«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/recursion/transitive via function pointer argument.sdstest b/packages/ttsl-lang/tests/resources/call graph/recursion/transitive via function pointer argument.sdstest index 53aff241..1bb89500 100644 --- a/packages/ttsl-lang/tests/resources/call graph/recursion/transitive via function pointer argument.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/recursion/transitive via function pointer argument.sdstest @@ -1,7 +1,7 @@ package tests.callGraph.recursion.transitiveViaFunctionPointerArgument segment s1() { - # $TEST$ ["s2", "s1", "s2"] + // $TEST$ ["s2", "s1", "s2"] »s2(s1)«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/recursion/transitive via lambda argument.sdstest b/packages/ttsl-lang/tests/resources/call graph/recursion/transitive via lambda argument.sdstest index 204e3794..041103cf 100644 --- a/packages/ttsl-lang/tests/resources/call graph/recursion/transitive via lambda argument.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/recursion/transitive via lambda argument.sdstest @@ -1,7 +1,7 @@ package tests.callGraph.recursion.transitiveViaLambdaArgument segment s1() { - # $TEST$ ["s2", "$expressionLambda", "s1", "s2"] + // $TEST$ ["s2", "$expressionLambda", "s1", "s2"] »s2(() -> s1())«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/recursion/transitive.sdstest b/packages/ttsl-lang/tests/resources/call graph/recursion/transitive.sdstest index d862cc1c..4348ff90 100644 --- a/packages/ttsl-lang/tests/resources/call graph/recursion/transitive.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/recursion/transitive.sdstest @@ -1,16 +1,16 @@ package tests.callGraph.recursion.transitive segment s1() { - # $TEST$ ["s2", "s3", "s1", "s2"] + // $TEST$ ["s2", "s3", "s1", "s2"] »s2()«; } segment s2() { - # $TEST$ ["s3", "s1", "s2", "s3"] + // $TEST$ ["s3", "s1", "s2", "s3"] »s3()«; } segment s3() { - # $TEST$ ["s1", "s2", "s3", "s1"] + // $TEST$ ["s1", "s2", "s3", "s1"] »s1()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/segment call/argument/block lambda.sdstest b/packages/ttsl-lang/tests/resources/call graph/segment call/argument/block lambda.sdstest index 9dc2a0fc..0964a736 100644 --- a/packages/ttsl-lang/tests/resources/call graph/segment call/argument/block lambda.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/segment call/argument/block lambda.sdstest @@ -7,7 +7,7 @@ segment mySegment(param1: (param: () -> ()) -> ()) { } pipeline myPipeline { - # $TEST$ ["mySegment", "$blockLambda", "f"] + // $TEST$ ["mySegment", "$blockLambda", "f"] »mySegment((param) { param(); })«; diff --git a/packages/ttsl-lang/tests/resources/call graph/segment call/argument/callable does not get called.sdstest b/packages/ttsl-lang/tests/resources/call graph/segment call/argument/callable does not get called.sdstest index 9435509b..dc071201 100644 --- a/packages/ttsl-lang/tests/resources/call graph/segment call/argument/callable does not get called.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/segment call/argument/callable does not get called.sdstest @@ -5,6 +5,6 @@ package tests.callGraph.segmentCall.argument.callableDoesNotGetCalled segment mySegment(param: () -> ()) {} pipeline myPipeline { - # $TEST$ ["mySegment"] + // $TEST$ ["mySegment"] »mySegment(f)«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/segment call/argument/expression lambda.sdstest b/packages/ttsl-lang/tests/resources/call graph/segment call/argument/expression lambda.sdstest index d4c49b46..d98db885 100644 --- a/packages/ttsl-lang/tests/resources/call graph/segment call/argument/expression lambda.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/segment call/argument/expression lambda.sdstest @@ -7,6 +7,6 @@ segment mySegment(param1: (param: () -> ()) -> ()) { } pipeline myPipeline { - # $TEST$ ["mySegment", "$expressionLambda", "f"] + // $TEST$ ["mySegment", "$expressionLambda", "f"] »mySegment((param) -> param())«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/segment call/argument/function.sdstest b/packages/ttsl-lang/tests/resources/call graph/segment call/argument/function.sdstest index 81dcbfaa..636eb15c 100644 --- a/packages/ttsl-lang/tests/resources/call graph/segment call/argument/function.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/segment call/argument/function.sdstest @@ -7,6 +7,6 @@ segment mySegment(param: () -> ()) { } pipeline myPipeline { - # $TEST$ ["mySegment", "f"] + // $TEST$ ["mySegment", "f"] »mySegment(f)«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/segment call/argument/segment.sdstest b/packages/ttsl-lang/tests/resources/call graph/segment call/argument/segment.sdstest index f8573c98..7ce228e8 100644 --- a/packages/ttsl-lang/tests/resources/call graph/segment call/argument/segment.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/segment call/argument/segment.sdstest @@ -11,6 +11,6 @@ segment mySegment2(param: () -> ()) { } pipeline myPipeline { - # $TEST$ ["mySegment1", "mySegment2", "f"] + // $TEST$ ["mySegment1", "mySegment2", "f"] »mySegment1(mySegment2)«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/segment call/basic.sdstest b/packages/ttsl-lang/tests/resources/call graph/segment call/basic.sdstest index 1ffae6e9..6efed0c9 100644 --- a/packages/ttsl-lang/tests/resources/call graph/segment call/basic.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/segment call/basic.sdstest @@ -3,6 +3,6 @@ package tests.callGraph.segmentCall.basic segment mySegment() {} pipeline myPipeline { - # $TEST$ ["mySegment"] + // $TEST$ ["mySegment"] »mySegment()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/segment call/body/function call in nested lambda.sdstest b/packages/ttsl-lang/tests/resources/call graph/segment call/body/function call in nested lambda.sdstest index 55eefc54..7b3b98d5 100644 --- a/packages/ttsl-lang/tests/resources/call graph/segment call/body/function call in nested lambda.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/segment call/body/function call in nested lambda.sdstest @@ -7,6 +7,6 @@ segment mySegment() { } pipeline myPipeline { - # $TEST$ ["mySegment"] + // $TEST$ ["mySegment"] »mySegment()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/segment call/body/function call.sdstest b/packages/ttsl-lang/tests/resources/call graph/segment call/body/function call.sdstest index 0fdccecd..cd2f7a3e 100644 --- a/packages/ttsl-lang/tests/resources/call graph/segment call/body/function call.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/segment call/body/function call.sdstest @@ -7,6 +7,6 @@ segment mySegment() { } pipeline myPipeline { - # $TEST$ ["mySegment", "f"] + // $TEST$ ["mySegment", "f"] »mySegment()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/segment call/default value/call.sdstest b/packages/ttsl-lang/tests/resources/call graph/segment call/default value/call.sdstest index 016cf227..f6e337bd 100644 --- a/packages/ttsl-lang/tests/resources/call graph/segment call/default value/call.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/segment call/default value/call.sdstest @@ -7,6 +7,6 @@ segment mySegment( ) {} pipeline myPipeline { - # $TEST$ ["mySegment", "default"] + // $TEST$ ["mySegment", "default"] »mySegment()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/segment call/default value/callable.sdstest b/packages/ttsl-lang/tests/resources/call graph/segment call/default value/callable.sdstest index 43144eb2..0b4af441 100644 --- a/packages/ttsl-lang/tests/resources/call graph/segment call/default value/callable.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/segment call/default value/callable.sdstest @@ -9,6 +9,6 @@ segment mySegment( } pipeline myPipeline { - # $TEST$ ["mySegment", "default"] + // $TEST$ ["mySegment", "default"] »mySegment()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/segment call/default value/previous parameter.sdstest b/packages/ttsl-lang/tests/resources/call graph/segment call/default value/previous parameter.sdstest index bba75d39..f64ce4c2 100644 --- a/packages/ttsl-lang/tests/resources/call graph/segment call/default value/previous parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/segment call/default value/previous parameter.sdstest @@ -8,6 +8,6 @@ segment mySegment( ) {} pipeline myPipeline { - # $TEST$ ["mySegment", "default"] + // $TEST$ ["mySegment", "default"] »mySegment()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/segment call/null safe.sdstest b/packages/ttsl-lang/tests/resources/call graph/segment call/null safe.sdstest index e2b523a0..ae3ea8b2 100644 --- a/packages/ttsl-lang/tests/resources/call graph/segment call/null safe.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/segment call/null safe.sdstest @@ -3,6 +3,6 @@ package tests.callGraph.segmentCall.nullSafe segment mySegment() {} pipeline myPipeline { - # $TEST$ ["mySegment"] + // $TEST$ ["mySegment"] »mySegment?()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/unresolved callable.sdstest b/packages/ttsl-lang/tests/resources/call graph/unresolved callable.sdstest index 241575c8..d3157370 100644 --- a/packages/ttsl-lang/tests/resources/call graph/unresolved callable.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/unresolved callable.sdstest @@ -1,6 +1,6 @@ package tests.callGraph.unresolvedCallable pipeline myPipeline { - # $TEST$ ["undefined"] + // $TEST$ ["undefined"] »unresolved()«; } diff --git a/packages/ttsl-lang/tests/resources/formatting/modules/empty.sdstest b/packages/ttsl-lang/tests/resources/formatting/modules/empty.sdstest index d9fa8eb9..2acf4e33 100644 --- a/packages/ttsl-lang/tests/resources/formatting/modules/empty.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/modules/empty.sdstest @@ -1,5 +1,5 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error // ----------------------------------------------------------------------------- -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error diff --git a/packages/ttsl-lang/tests/resources/generation/partial/impure dependency file constant/input.sdstest b/packages/ttsl-lang/tests/resources/generation/partial/impure dependency file constant/input.sdstest index 6e0e456e..b7b0a73f 100644 --- a/packages/ttsl-lang/tests/resources/generation/partial/impure dependency file constant/input.sdstest +++ b/packages/ttsl-lang/tests/resources/generation/partial/impure dependency file constant/input.sdstest @@ -19,6 +19,6 @@ pipeline testPipeline { val impureFileWrite2B = iFileWriteB(); val impureFileReadAgainB = iFileReadB(); - # $TEST$ run_until + // $TEST$ run_until val »result« = impureFileReadAgain + impureFileReadAgainB; } diff --git a/packages/ttsl-lang/tests/resources/generation/partial/impure dependency file parameter/input.sdstest b/packages/ttsl-lang/tests/resources/generation/partial/impure dependency file parameter/input.sdstest index 6deb24d6..37b3816a 100644 --- a/packages/ttsl-lang/tests/resources/generation/partial/impure dependency file parameter/input.sdstest +++ b/packages/ttsl-lang/tests/resources/generation/partial/impure dependency file parameter/input.sdstest @@ -10,6 +10,6 @@ pipeline testPipeline { val impureFileWrite2 = iFileWrite("c.txt"); val impureFileReadAgain = iFileRead("d.txt"); - # $TEST$ run_until + // $TEST$ run_until val »result« = impureFileReadAgain + 2; } diff --git a/packages/ttsl-lang/tests/resources/generation/partial/impure dependency/input.sdstest b/packages/ttsl-lang/tests/resources/generation/partial/impure dependency/input.sdstest index 173818b1..8843682b 100644 --- a/packages/ttsl-lang/tests/resources/generation/partial/impure dependency/input.sdstest +++ b/packages/ttsl-lang/tests/resources/generation/partial/impure dependency/input.sdstest @@ -32,7 +32,7 @@ pipeline testPipeline { val impureA2 = i1(noPartialEvalInt(pureValueForImpure3)); i1(4); - # $TEST$ run_until + // $TEST$ run_until val »result« = i1(impureA2); i1(4); // Should not be generated - impure cannot affect result after result is already calculated val someImpureValue = i1(4); // Should not be generated - impure cannot affect result after result is already calculated diff --git a/packages/ttsl-lang/tests/resources/generation/partial/pure dependency/input.sdstest b/packages/ttsl-lang/tests/resources/generation/partial/pure dependency/input.sdstest index 81b14156..64a9cf85 100644 --- a/packages/ttsl-lang/tests/resources/generation/partial/pure dependency/input.sdstest +++ b/packages/ttsl-lang/tests/resources/generation/partial/pure dependency/input.sdstest @@ -75,7 +75,7 @@ line"; val listResult = g3(list); val listResult2 = g3(list2); // Should not be generated - # $TEST$ run_until + // $TEST$ run_until val »result« = -o + 1 + value1 + mapResult * listResult / g4(listValue); val lDouble3 = 1.0; // Should not be generated - pure cannot affect result after result is already calculated diff --git a/packages/ttsl-lang/tests/resources/generation/partial/redundant impurity/input.sdstest b/packages/ttsl-lang/tests/resources/generation/partial/redundant impurity/input.sdstest index 5ebb4386..16cce682 100644 --- a/packages/ttsl-lang/tests/resources/generation/partial/redundant impurity/input.sdstest +++ b/packages/ttsl-lang/tests/resources/generation/partial/redundant impurity/input.sdstest @@ -31,7 +31,7 @@ pipeline testPipeline { val impureA2 = i1(noPartialEvalInt(pureValueForImpure3)); // Should not be generated - cannot affect result i1(4); // Should not be generated - impure can not have effects on future statements as they are pure - # $TEST$ run_until + // $TEST$ run_until val »result« = pureValue - 1; i1(4); // Should not be generated - impure cannot affect result after result is already calculated val someImpureValue = i1(4); // Should not be generated - impure cannot affect result after result is already calculated diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/bad-unclosed argument list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/bad-unclosed argument list.sdstest index eed8dd65..8e537c4c 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/bad-unclosed argument list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/bad-unclosed argument list.sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error @Annotation( diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-empty argument list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-empty argument list.sdstest index 7bb2a9ef..af0cf406 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-empty argument list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-empty argument list.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error @Annotation() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-multiple arguments.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-multiple arguments.sdstest index 366f6954..7c510cf6 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-multiple arguments.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-multiple arguments.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error @Annotation(1, a = 2) diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-named argument.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-named argument.sdstest index 88d181f6..ba199336 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-named argument.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-named argument.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error @Annotation(b = 2) diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-no argument list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-no argument list.sdstest index c9aa7ba9..b0f0c598 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-no argument list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-no argument list.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error @Annotation diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-positional argument.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-positional argument.sdstest index 455f3a32..319c6983 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-positional argument.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-positional argument.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error @Annotation(1) diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/bad-unclosed constraint list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/bad-unclosed constraint list.sdstest index ab9d5ec5..4116a938 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/bad-unclosed constraint list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/bad-unclosed constraint list.sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error annotation MyAnnotation where { diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/bad-unclosed parameter list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/bad-unclosed parameter list.sdstest index 92e2e212..ec0beccf 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/bad-unclosed parameter list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/bad-unclosed parameter list.sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error annotation MyAnnotation( diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/good-annotation call.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/good-annotation call.sdstest index d6c6c59d..d867f6cb 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/good-annotation call.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/good-annotation call.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error package test diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/good-no parameter list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/good-no parameter list.sdstest index 58c9da3d..a4a5a34d 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/good-no parameter list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/good-no parameter list.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error annotation MyAnnotation diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/good-with constraint list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/good-with constraint list.sdstest index 5aca6aaa..19cb167c 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/good-with constraint list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/good-with constraint list.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error annotation MyAnnotation where {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/good-with parameter list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/good-with parameter list.sdstest index 2679d074..54d35f27 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/good-with parameter list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/good-with parameter list.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error annotation MyAnnotation() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/attributes/good-annotated.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/attributes/good-annotated.sdstest index e56dd849..11ebf0fc 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/attributes/good-annotated.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/attributes/good-annotated.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error class MyClass { @Annotation attr a diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/attributes/good-no type.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/attributes/good-no type.sdstest index a8dc0143..1b683279 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/attributes/good-no type.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/attributes/good-no type.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error class MyClass { attr a diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/attributes/good-static.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/attributes/good-static.sdstest index 27b9a168..c256ad51 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/attributes/good-static.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/attributes/good-static.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error class MyClass { static attr a: Int diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/attributes/good-with type.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/attributes/good-with type.sdstest index 14ac1d6c..8c5eaa37 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/attributes/good-with type.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/attributes/good-with type.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error class MyClass { attr a: Int diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-empty parent type list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-empty parent type list.sdstest index 0e57bbf9..a4bb256c 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-empty parent type list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-empty parent type list.sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error class MyClass sub diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-unclosed body.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-unclosed body.sdstest index 5d592849..87b9a8c4 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-unclosed body.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-unclosed body.sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error class MyClass { diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-unclosed constraint list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-unclosed constraint list.sdstest index 1e008138..bb2ac2a4 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-unclosed constraint list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-unclosed constraint list.sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error class MyClass where { diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-unclosed parameter list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-unclosed parameter list.sdstest index 41d1dc8d..63fd5d81 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-unclosed parameter list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-unclosed parameter list.sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error class MyClass( diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-unclosed type parameter list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-unclosed type parameter list.sdstest index dc758216..a86d4586 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-unclosed type parameter list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-unclosed type parameter list.sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error class MyClass< diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-annotation call.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-annotation call.sdstest index 14e7f34e..c86c9b5b 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-annotation call.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-annotation call.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error package test diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-empty body.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-empty body.sdstest index 4c8758cc..4576be59 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-empty body.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-empty body.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error class MyClass {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-minimal.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-minimal.sdstest index 4f6aede1..0b2a1003 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-minimal.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-minimal.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error class MyClass diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-multiple parent types.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-multiple parent types.sdstest index e51d0266..0c1a8460 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-multiple parent types.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-multiple parent types.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error class MyClass sub Int, Number diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-one parent type.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-one parent type.sdstest index 673d2f02..1231a1b7 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-one parent type.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-one parent type.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error class MyClass sub Int diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-with constraint list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-with constraint list.sdstest index b2b087fb..982a5c1a 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-with constraint list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-with constraint list.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error class MyClass where {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-with parameter list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-with parameter list.sdstest index cc240191..fe748608 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-with parameter list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-with parameter list.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error class MyClass() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-with type parameter list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-with type parameter list.sdstest index c9d39652..a06a2893 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-with type parameter list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-with type parameter list.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error class MyClass<> diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/methods/good-annotated instance method.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/methods/good-annotated instance method.sdstest index 3f8a9b21..72695918 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/methods/good-annotated instance method.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/methods/good-annotated instance method.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error class MyClass { @MyAnnotation diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/methods/good-annotated static method.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/methods/good-annotated static method.sdstest index c424e943..4eb3f7d5 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/methods/good-annotated static method.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/methods/good-annotated static method.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error class MyClass { @MyAnnotation diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/methods/good-instance method.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/methods/good-instance method.sdstest index 972ec9c6..0a0ea9b6 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/methods/good-instance method.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/methods/good-instance method.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error class MyClass { fun myFunction() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/methods/good-static method.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/methods/good-static method.sdstest index acef5186..cd54cd70 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/methods/good-static method.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/methods/good-static method.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error class MyClass { static fun myFunction() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/nested classes/good-annotated nested class.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/nested classes/good-annotated nested class.sdstest index 5ed4f8fa..20f74916 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/nested classes/good-annotated nested class.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/nested classes/good-annotated nested class.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error class MyOuterClass { @MyAnnotation diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/nested classes/good-nested-class.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/nested classes/good-nested-class.sdstest index 39bdc50b..f090b40b 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/nested classes/good-nested-class.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/nested classes/good-nested-class.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error class MyOuterClass { class MyClass diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/nested enums/good-annotated nested enum.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/nested enums/good-annotated nested enum.sdstest index 748c416d..76b8b7a8 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/nested enums/good-annotated nested enum.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/nested enums/good-annotated nested enum.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error class MyOuterClass { @MyAnnotation diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/nested enums/good-nested enum.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/nested enums/good-nested enum.sdstest index f43a21f2..d86fe01c 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/nested enums/good-nested enum.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/nested enums/good-nested enum.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error class MyOuterClass { enum MyEnum { diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing name.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing name.tsltest index cdae50b5..53e2553c 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing name.tsltest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing name.tsltest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error constant : Int = 1; diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing type.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing type.tsltest index fc06cf31..e19c771e 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing type.tsltest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing type.tsltest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error constant value: = 1 diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing value.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing value.tsltest index b1697d48..80e9be97 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing value.tsltest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing value.tsltest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error constant value: Int = diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/constants/good-with type and value.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/constants/good-with type and value.tsltest index 7ff51d5c..d85ef74f 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/constants/good-with type and value.tsltest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/constants/good-with type and value.tsltest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error constant value: Int = 1; diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/bad-missing comma.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/bad-missing comma.sdstest index e518970a..9eee0a23 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/bad-missing comma.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/bad-missing comma.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error annotation MyAnnotation where { p < 0 diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-empty.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-empty.sdstest index 5aca6aaa..19cb167c 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-empty.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-empty.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error annotation MyAnnotation where {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-greater than constraint.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-greater than constraint.sdstest index c48a4e09..1c940e1d 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-greater than constraint.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-greater than constraint.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error annotation MyAnnotation where { p > 0 diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-greater than or equals constraint.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-greater than or equals constraint.sdstest index d0ff248b..8bde0690 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-greater than or equals constraint.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-greater than or equals constraint.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error annotation MyAnnotation where { p >= 0 diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-less than constraint.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-less than constraint.sdstest index baced08e..7665e1f6 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-less than constraint.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-less than constraint.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error annotation MyAnnotation where { p < 0 diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-less than or equals constraint.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-less than or equals constraint.sdstest index 87088e9b..9c206305 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-less than or equals constraint.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-less than or equals constraint.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error annotation MyAnnotation where { p <= 0 diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-multiple constraints.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-multiple constraints.sdstest index bbefb801..c20fe5b6 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-multiple constraints.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-multiple constraints.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error annotation MyAnnotation where { p < 0, diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/data/bad-missing name.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/data/bad-missing name.tsltest index 36f7a7de..cc484719 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/data/bad-missing name.tsltest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/data/bad-missing name.tsltest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error data : Int; diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/data/bad-missing type.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/data/bad-missing type.tsltest index 3c4cc803..fbd5e717 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/data/bad-missing type.tsltest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/data/bad-missing type.tsltest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error data Data1: diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/data/good-with type and name.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/data/good-with type and name.tsltest index 55bfd115..6d064ba9 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/data/good-with type and name.tsltest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/data/good-with type and name.tsltest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error data Data1: Int; \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/bad-unclosed body.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/enums/bad-unclosed body.sdstest index 9dee2647..f80c9cee 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/bad-unclosed body.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/enums/bad-unclosed body.sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error enum MyEnum { diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/good-annotation call.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/enums/good-annotation call.sdstest index ff8b7830..f4e602fe 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/good-annotation call.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/enums/good-annotation call.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error package test diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/good-empty body.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/enums/good-empty body.sdstest index 939f2558..44b08ebc 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/good-empty body.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/enums/good-empty body.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error enum MyEnum {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/good-no body.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/enums/good-no body.sdstest index 2d131bbe..a5b34a99 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/good-no body.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/enums/good-no body.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error enum MyEnum diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/good-variants in body.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/enums/good-variants in body.sdstest index 878c155b..b12562bc 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/good-variants in body.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/enums/good-variants in body.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error enum MyEnum { MyEnumVariant diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/bad-unclosed constraint list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/bad-unclosed constraint list.sdstest index fc42d3d0..69c43974 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/bad-unclosed constraint list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/bad-unclosed constraint list.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error enum MyEnum { MyEnumVariant where { diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/bad-unclosed parameter list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/bad-unclosed parameter list.sdstest index 79539680..3dea580f 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/bad-unclosed parameter list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/bad-unclosed parameter list.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error enum MyEnum { MyEnumVariant( diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/good-annotation call.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/good-annotation call.sdstest index cdd7269e..05a3e6a0 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/good-annotation call.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/good-annotation call.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error enum MyEnum { @Annotation diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/good-no parameter list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/good-no parameter list.sdstest index 878c155b..b12562bc 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/good-no parameter list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/good-no parameter list.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error enum MyEnum { MyEnumVariant diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/good-with constraint list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/good-with constraint list.sdstest index c92316cb..bf2fdb55 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/good-with constraint list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/good-with constraint list.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error enum MyEnum { MyEnumVariant where {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/good-with parameter list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/good-with parameter list.sdstest index 98cf2703..9ff00fb6 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/good-with parameter list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/good-with parameter list.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error enum MyEnum { MyEnumVariant() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing parameter list.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing parameter list.tsltest index 010d8b5b..9a97324f 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing parameter list.tsltest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing parameter list.tsltest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error function myFunction diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing parameter type.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing parameter type.tsltest index 53639679..6daec909 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing parameter type.tsltest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing parameter type.tsltest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error function myFunction(x:) diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed parameter list.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed parameter list.tsltest index c0bec18c..b76a08f4 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed parameter list.tsltest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed parameter list.tsltest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error function myFunction( diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed result list.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed result list.tsltest index dca8b55d..ebcbdd44 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed result list.tsltest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed result list.tsltest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error function myFunction(): ( diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-annotation call.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-annotation call.tsltest index bf5b5ecc..f556f0e6 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-annotation call.tsltest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-annotation call.tsltest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error package test diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with parameter list.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with parameter list.tsltest index d0788d09..36b85780 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with parameter list.tsltest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with parameter list.tsltest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error function myFunction() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with result list.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with result list.tsltest index fea48ca4..54bc099f 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with result list.tsltest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with result list.tsltest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error function myFunction() -> () diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with type parameter list.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with type parameter list.tsltest index e269fb41..d9f348cc 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with type parameter list.tsltest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with type parameter list.tsltest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error function myFunction(x: Int) diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/bad-const before annotation.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/bad-const before annotation.sdstest index ae8dcb11..1b5fd298 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/bad-const before annotation.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/bad-const before annotation.sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error class MyClass(const @Annotation a) diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/bad-double const modifier.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/bad-double const modifier.sdstest index 8369d68f..8b210905 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/bad-double const modifier.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/bad-double const modifier.sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error class MyClass(const const a: String) diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/bad-missing comma.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/bad-missing comma.sdstest index ff13b97a..cf90d6e5 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/bad-missing comma.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/bad-missing comma.sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error class MyClass(a b) diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-annotated parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-annotated parameter.sdstest index 782f752a..c71b43ca 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-annotated parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-annotated parameter.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error class MyClass(@Annotation a: Int) diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-const typed optional parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-const typed optional parameter.sdstest index 270edc1b..7a9b687c 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-const typed optional parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-const typed optional parameter.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error class MyClass(const a: Int = 1) diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-const typed required parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-const typed required parameter.sdstest index dd484ea8..7de3e265 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-const typed required parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-const typed required parameter.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error class MyClass(const a: Int) diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-const untyped optional parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-const untyped optional parameter.sdstest index 2e956d49..acda4390 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-const untyped optional parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-const untyped optional parameter.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error class MyClass(const a = 1) diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-const untyped required parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-const untyped required parameter.sdstest index c368ed8b..5bc30a4a 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-const untyped required parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-const untyped required parameter.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error class MyClass(const a) diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-empty.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-empty.sdstest index cc240191..fe748608 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-empty.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-empty.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error class MyClass() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-multiple parameters.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-multiple parameters.sdstest index 9c93e8d1..93b84c6e 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-multiple parameters.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-multiple parameters.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error class MyClass( @Annotation a1, diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-typed optional parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-typed optional parameter.sdstest index a4991752..076ed97d 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-typed optional parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-typed optional parameter.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error class MyClass(a: Int = 1) diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-typed required parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-typed required parameter.sdstest index 02daf5df..3785d50c 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-typed required parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-typed required parameter.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error class MyClass(a: Int) diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-untyped optional parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-untyped optional parameter.sdstest index c0b363c2..9a29e763 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-untyped optional parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-untyped optional parameter.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error class MyClass(a = 1) diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-untyped required parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-untyped required parameter.sdstest index 070521f2..d02baee9 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-untyped required parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-untyped required parameter.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error class MyClass(a) diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/bad-missing body.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/bad-missing body.sdstest index 5911519b..87b1fa7e 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/bad-missing body.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/bad-missing body.sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/bad-unclosed body.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/bad-unclosed body.sdstest index d4bd8367..9710c4c7 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/bad-unclosed body.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/bad-unclosed body.sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/good-annotation call.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/good-annotation call.sdstest index db5223ea..b6c69990 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/good-annotation call.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/good-annotation call.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error package test diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/good-empty body.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/good-empty body.sdstest index a38132bd..e65f1eb9 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/good-empty body.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/good-empty body.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/good-statements in body.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/good-statements in body.sdstest index c3b07d95..53561750 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/good-statements in body.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/good-statements in body.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { val a = 1; diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/results/bad-missing comma.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/results/bad-missing comma.sdstest index a030d660..fb9dc5e0 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/results/bad-missing comma.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/results/bad-missing comma.sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error segment mySegment() -> (a b) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-annotated result.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-annotated result.sdstest index aba9d8a2..00dbc182 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-annotated result.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-annotated result.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error segment mySegment() -> (@Annotation a: Int) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-empty.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-empty.sdstest index aa2077bd..8a30512c 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-empty.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-empty.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error segment mySegment() -> () {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-multiple results.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-multiple results.sdstest index 64966909..13bcfdb4 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-multiple results.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-multiple results.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error segment mySegment() -> ( @Annotation a, diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-one typed result (in parentheses).sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-one typed result (in parentheses).sdstest index 7c902be5..9a380212 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-one typed result (in parentheses).sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-one typed result (in parentheses).sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error segment mySegment() -> (a: Int) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-one typed result (no parentheses).sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-one typed result (no parentheses).sdstest index 2b79a858..13940ca8 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-one typed result (no parentheses).sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-one typed result (no parentheses).sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error segment mySegment() -> a: Int {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-one untyped result (no parentheses).sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-one untyped result (no parentheses).sdstest index a474b597..f001e7a3 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-one untyped result (no parentheses).sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-one untyped result (no parentheses).sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error segment mySegment() -> a {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-one untyped result (with parentheses).sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-one untyped result (with parentheses).sdstest index 4e60a7fd..dfc4ac34 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-one untyped result (with parentheses).sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-one untyped result (with parentheses).sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error segment mySegment() -> (a) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-missing body.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-missing body.sdstest index f3cce832..e37a29d5 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-missing body.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-missing body.sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error segment mySegment() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-missing parameter list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-missing parameter list.sdstest index b5b15308..c10c4ad1 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-missing parameter list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-missing parameter list.sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error segment mySegment {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-two visibilities (internal, internal).sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-two visibilities (internal, internal).sdstest index 72d1a52d..619f22a7 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-two visibilities (internal, internal).sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-two visibilities (internal, internal).sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error internal internal segment mySegment() {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-two visibilities (internal, private).sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-two visibilities (internal, private).sdstest index a3dbe18a..27047c8d 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-two visibilities (internal, private).sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-two visibilities (internal, private).sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error internal private segment mySegment() {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-two visibilities (private, internal).sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-two visibilities (private, internal).sdstest index 9a1893fd..797a58dc 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-two visibilities (private, internal).sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-two visibilities (private, internal).sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error private internal segment mySegment() {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-two visibilities (private, private).sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-two visibilities (private, private).sdstest index 49896d0b..0c0f7303 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-two visibilities (private, private).sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-two visibilities (private, private).sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error private private segment mySegment() {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-unclosed body.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-unclosed body.sdstest index f714f683..1ba29b8f 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-unclosed body.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-unclosed body.sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error segment mySegment() { diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-unclosed parameter list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-unclosed parameter list.sdstest index e27d27cf..4312edd1 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-unclosed parameter list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-unclosed parameter list.sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error segment mySegment( {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-unclosed result list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-unclosed result list.sdstest index 2787dfb0..e1884342 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-unclosed result list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-unclosed result list.sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error segment mySegment() -> ( {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-annotation call.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-annotation call.sdstest index 91b6e7c8..9d5ef909 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-annotation call.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-annotation call.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error package test diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-internal segment.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-internal segment.sdstest index 4ddc25eb..974c3aa4 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-internal segment.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-internal segment.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error internal segment mySegment() {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-private segment.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-private segment.sdstest index 6fb52adc..de021652 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-private segment.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-private segment.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error private segment mySegment() {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-statements in body.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-statements in body.sdstest index 310f322f..0fcc81aa 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-statements in body.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-statements in body.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error private segment mySegment() { val a = 1; diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-with constraint list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-with constraint list.sdstest index 02a28d33..028dd843 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-with constraint list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-with constraint list.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error segment mySegment() where {} {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-with parameter list and body.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-with parameter list and body.sdstest index a2e0e386..538c2b17 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-with parameter list and body.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-with parameter list and body.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error segment mySegment() {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-with result list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-with result list.sdstest index aa2077bd..8a30512c 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-with result list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-with result list.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error segment mySegment() -> () {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/bad-missing comma.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/bad-missing comma.sdstest index eeb8d9b6..58d8c50b 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/bad-missing comma.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/bad-missing comma.sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error fun myFunction() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-annotated type parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-annotated type parameter.sdstest index 8d13f22d..40967e52 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-annotated type parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-annotated type parameter.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error fun myFunction<@Annotation T>() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded contravariant optional type parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded contravariant optional type parameter.sdstest index ba08b315..243f6366 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded contravariant optional type parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded contravariant optional type parameter.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error fun myFunction() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded contravariant required type parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded contravariant required type parameter.sdstest index eeda1a68..68af9baf 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded contravariant required type parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded contravariant required type parameter.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error fun myFunction() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded covariant optional type parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded covariant optional type parameter.sdstest index 75d9f998..0e364d12 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded covariant optional type parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded covariant optional type parameter.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error fun myFunction() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded covariant required type parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded covariant required type parameter.sdstest index 8a93ac04..613f0926 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded covariant required type parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded covariant required type parameter.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error fun myFunction() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded invariant optional type parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded invariant optional type parameter.sdstest index fad1831f..93a5eb3d 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded invariant optional type parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded invariant optional type parameter.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error fun myFunction() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded invariant required type parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded invariant required type parameter.sdstest index 021d2abb..e7ce3182 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded invariant required type parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded invariant required type parameter.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error fun myFunction() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-empty.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-empty.sdstest index f270ef67..912dae7a 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-empty.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-empty.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error fun myFunction<>() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-multiple type parameters.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-multiple type parameters.sdstest index e174e0bc..5ea557ce 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-multiple type parameters.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-multiple type parameters.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error fun myFunction<@Annotation T, in S, out U>() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded contravariant optional type parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded contravariant optional type parameter.sdstest index b9402bd1..88d30d82 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded contravariant optional type parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded contravariant optional type parameter.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error fun myFunction() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded contravariant required type parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded contravariant required type parameter.sdstest index 9a47947f..180c50e9 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded contravariant required type parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded contravariant required type parameter.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error fun myFunction() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded covariant optional type parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded covariant optional type parameter.sdstest index c5564a67..1be49dfd 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded covariant optional type parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded covariant optional type parameter.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error fun myFunction() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded covariant required type parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded covariant required type parameter.sdstest index ee113893..c7d1c7e6 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded covariant required type parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded covariant required type parameter.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error fun myFunction() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded invariant optional type parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded invariant optional type parameter.sdstest index 41ee9fe2..ab7a2938 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded invariant optional type parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded invariant optional type parameter.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error fun myFunction() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded invariant required type parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded invariant required type parameter.sdstest index 6321d445..0bda9471 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded invariant required type parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded invariant required type parameter.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error fun myFunction() diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-addition without left operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-addition without left operator.sdstest index 5141e5fc..93c549ea 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-addition without left operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-addition without left operator.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { + 2; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-addition without right operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-addition without right operator.sdstest index 3cc7076d..8b6e73af 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-addition without right operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-addition without right operator.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { 1 +; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-division without left operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-division without left operator.sdstest index a8aed892..57a90363 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-division without left operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-division without left operator.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { / 2; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-division without right operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-division without right operator.sdstest index b4692bea..38081c76 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-division without right operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-division without right operator.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { 1 /; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-multiplication without left operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-multiplication without left operator.sdstest index 47180c7a..60a5900f 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-multiplication without left operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-multiplication without left operator.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { * 2; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-multiplication without right operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-multiplication without right operator.sdstest index bcdf896e..b62d52f6 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-multiplication without right operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-multiplication without right operator.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { 1 *; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-negation without operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-negation without operator.sdstest index 2bac0372..854267fb 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-negation without operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-negation without operator.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { -; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-subtraction without right operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-subtraction without right operator.sdstest index 04ae61da..9dd3c100 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-subtraction without right operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-subtraction without right operator.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { 1 -; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-addition.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-addition.sdstest index c6444527..f273ef1e 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-addition.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-addition.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { 1 + 2; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-complex example.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-complex example.sdstest index 792e6a4e..313f34cb 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-complex example.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-complex example.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { (1 + 2) * -3 / (1 - 4) + 5; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-division.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-division.sdstest index 0eaabe32..ef34e2fd 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-division.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-division.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { 1 / 2; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-multiplication.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-multiplication.sdstest index e07da1a7..e7b1bfb6 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-multiplication.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-multiplication.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { 1 * 2; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-negation.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-negation.sdstest index cfa41017..1974fcb1 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-negation.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-negation.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { -1; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-subtraction.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-subtraction.sdstest index 2b8398ae..7e5f9271 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-subtraction.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-subtraction.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { 1 - 2; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/block lambdas/bad-unclosed body.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/block lambdas/bad-unclosed body.sdstest index 50c093b5..53e199fd 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/block lambdas/bad-unclosed body.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/block lambdas/bad-unclosed body.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { () {; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/block lambdas/bad-unclosed parameter list.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/block lambdas/bad-unclosed parameter list.sdstest index 85aa8649..dd9e7ec5 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/block lambdas/bad-unclosed parameter list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/block lambdas/bad-unclosed parameter list.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { ( {}; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/block lambdas/good-filled body.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/block lambdas/good-filled body.sdstest index b23ac9f5..de33ac71 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/block lambdas/good-filled body.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/block lambdas/good-filled body.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { () { diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/block lambdas/good-with parameter list and body.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/block lambdas/good-with parameter list and body.sdstest index f00c96b8..8d1b84da 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/block lambdas/good-with parameter list and body.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/block lambdas/good-with parameter list and body.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { () {}; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/calls/bad-unclosed argument list.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/calls/bad-unclosed argument list.sdstest index 6ef73b63..181da152 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/calls/bad-unclosed argument list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/calls/bad-unclosed argument list.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { f(; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-mixed positional and named arguments.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-mixed positional and named arguments.sdstest index b01975e4..5d992779 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-mixed positional and named arguments.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-mixed positional and named arguments.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { f(1, b = 2); diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-named argument.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-named argument.sdstest index b0b8ab2a..f0e4ce7b 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-named argument.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-named argument.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { f(b = 2); diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-no arguments.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-no arguments.sdstest index 46e9af1d..6cd2261b 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-no arguments.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-no arguments.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { f(); diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-null safe.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-null safe.sdstest index b51b2f75..48ef60ec 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-null safe.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-null safe.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { f?(1); diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-positional argument.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-positional argument.sdstest index 2ccfef92..67090259 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-positional argument.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-positional argument.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { f(1); diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than or equal without left operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than or equal without left operator.sdstest index 76dc0faa..0f192c49 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than or equal without left operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than or equal without left operator.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { >= 2; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than or equal without right operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than or equal without right operator.sdstest index f2410411..5985c39b 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than or equal without right operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than or equal without right operator.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { 1 >=; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than without left operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than without left operator.sdstest index 9cb23a58..0a66c978 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than without left operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than without left operator.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { > 2; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than without right operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than without right operator.sdstest index 3d20b341..bb733c94 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than without right operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than without right operator.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { 1 >; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than or equal without left operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than or equal without left operator.sdstest index 0216f63f..7e6d0416 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than or equal without left operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than or equal without left operator.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { <= 2; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than or equal without right operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than or equal without right operator.sdstest index dc6aef56..1beda50d 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than or equal without right operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than or equal without right operator.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { 1 <=; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than without left operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than without left operator.sdstest index aea0502d..4fe72792 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than without left operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than without left operator.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { < 2; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than without right operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than without right operator.sdstest index 399f0747..da8a9126 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than without right operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than without right operator.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { 1 <; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-greater than or equal.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-greater than or equal.sdstest index f73d8ef6..b307ff91 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-greater than or equal.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-greater than or equal.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { 1 >= 2; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-greater than.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-greater than.sdstest index c8786939..72d16eac 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-greater than.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-greater than.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { 1 > 2; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-less than or equal.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-less than or equal.sdstest index 82bfadf9..27e5caf2 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-less than or equal.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-less than or equal.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { 1 <= 2; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-less than.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-less than.sdstest index 7e1221ad..fc782e89 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-less than.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-less than.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { 1 < 2; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/bad-without left operand.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/bad-without left operand.sdstest index 4a8a305f..f698fb17 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/bad-without left operand.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/bad-without left operand.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { ?: Int; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/bad-without right operand.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/bad-without right operand.sdstest index 431e2c1f..2c3bf116 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/bad-without right operand.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/bad-without right operand.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { 1 ?:; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/good-basic.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/good-basic.sdstest index 62586bc6..5aaea6c8 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/good-basic.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/good-basic.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { null ?: 1; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/good-chained.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/good-chained.sdstest index e47da3a8..9b6a1240 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/good-chained.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/good-chained.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { null ?: null ?: 1; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-equal without left operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-equal without left operator.sdstest index 6e25b432..6f529e44 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-equal without left operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-equal without left operator.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { == 2; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-equal without right operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-equal without right operator.sdstest index 2b8d2e37..37613704 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-equal without right operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-equal without right operator.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { 1 ==; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-identical without left operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-identical without left operator.sdstest index b5814284..7c15456a 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-identical without left operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-identical without left operator.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { === 2; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-identical without right operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-identical without right operator.sdstest index dc07ea34..333baa79 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-identical without right operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-identical without right operator.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { 1 ===; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not equal without left operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not equal without left operator.sdstest index 4f6607ea..c75d3f48 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not equal without left operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not equal without left operator.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { != 2; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not equal without right operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not equal without right operator.sdstest index 4a6a30a2..6fbeacce 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not equal without right operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not equal without right operator.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { 1 !=; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not identical without left operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not identical without left operator.sdstest index 08f64095..2e92a031 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not identical without left operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not identical without left operator.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { 1 !==; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not identical without right operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not identical without right operator.sdstest index 08f64095..2e92a031 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not identical without right operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not identical without right operator.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { 1 !==; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-equal.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-equal.sdstest index b48333c6..ab608294 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-equal.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-equal.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { 1 == 2; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-identical.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-identical.sdstest index 2460ab2d..cc17d2bf 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-identical.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-identical.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { 1 === 2; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-not equal.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-not equal.sdstest index 9b301888..66b7ffeb 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-not equal.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-not equal.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { 1 != 2; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-not identical.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-not identical.sdstest index 668def25..1f897170 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-not identical.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-not identical.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { 1 !== 2; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/expression lambdas/bad-missing body.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/expression lambdas/bad-missing body.sdstest index be08633d..0ab44dbd 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/expression lambdas/bad-missing body.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/expression lambdas/bad-missing body.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { () ->; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/expression lambdas/bad-unclosed parameter list.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/expression lambdas/bad-unclosed parameter list.sdstest index ad8bcc52..9568407b 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/expression lambdas/bad-unclosed parameter list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/expression lambdas/bad-unclosed parameter list.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { ( -> 1; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/expression lambdas/good-with parameter list and expression.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/expression lambdas/good-with parameter list and expression.sdstest index 7d231ec5..77b37f42 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/expression lambdas/good-with parameter list and expression.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/expression lambdas/good-with parameter list and expression.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { () -> 1; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/good-complex chained expression.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/good-complex chained expression.sdstest index 5137f39d..d9277deb 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/good-complex chained expression.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/good-complex chained expression.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { a.member?.f()[1]; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/good-reference.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/good-reference.sdstest index 41b34be2..36197610 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/good-reference.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/good-reference.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { a; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/bad-no index.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/bad-no index.sdstest index 8fd6193a..9dac005b 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/bad-no index.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/bad-no index.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline test { a[]; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/bad-unclosed square bracket.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/bad-unclosed square bracket.sdstest index 1183d032..7248c7b5 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/bad-unclosed square bracket.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/bad-unclosed square bracket.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline test { a[1; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/good-literal index.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/good-literal index.sdstest index 7b5c5f18..ff4ae34b 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/good-literal index.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/good-literal index.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline test { a[1]; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/good-null safe.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/good-null safe.sdstest index 5f5457c1..7327f075 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/good-null safe.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/good-null safe.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline test { a?[1]; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/good-reference index.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/good-reference index.sdstest index 79011baa..6dafc20c 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/good-reference index.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/good-reference index.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline test { a[b]; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/lists/bad-unclosed square bracket.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/lists/bad-unclosed square bracket.sdstest index 3f085dd0..2a991668 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/lists/bad-unclosed square bracket.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/lists/bad-unclosed square bracket.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { [1; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-nested multiple elements.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-nested multiple elements.sdstest index 13337e22..0676978c 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-nested multiple elements.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-nested multiple elements.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { [[1, 2]]; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-nested one element.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-nested one element.sdstest index f0f6b41f..9edb2c2f 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-nested one element.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-nested one element.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { [[1 + 2]]; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-one level multiple elements.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-one level multiple elements.sdstest index d561d373..5327782b 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-one level multiple elements.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-one level multiple elements.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { [1, 2]; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-one level one element.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-one level one element.sdstest index 5f080fa2..2f0593a4 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-one level one element.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-one level one element.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { [1 + 2]; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/bad-no digits before dot.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/bad-no digits before dot.sdstest index 12d78534..ae5accd1 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/bad-no digits before dot.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/bad-no digits before dot.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { .2; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/good-basic example.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/good-basic example.sdstest index a4d12d5c..0a1139ef 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/good-basic example.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/good-basic example.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { 1.2; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/good-scientific notation with lowercase e.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/good-scientific notation with lowercase e.sdstest index 7d33b940..487983bc 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/good-scientific notation with lowercase e.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/good-scientific notation with lowercase e.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { 1e10; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/good-scientific notation with uppercase e.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/good-scientific notation with uppercase e.sdstest index cb8c5a68..351d43ce 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/good-scientific notation with uppercase e.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/good-scientific notation with uppercase e.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { 1E10; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/good-false.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/good-false.sdstest index 1f24d666..efe0d586 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/good-false.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/good-false.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { false; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/good-null.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/good-null.sdstest index 4602febf..f5ff60a7 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/good-null.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/good-null.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { null; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/good-true.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/good-true.sdstest index 2f2df957..58d43666 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/good-true.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/good-true.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { true; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/int/good-leading zero.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/int/good-leading zero.sdstest index 9fac28d6..c37f760a 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/int/good-leading zero.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/int/good-leading zero.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { 01; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/int/good-multiple digits.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/int/good-multiple digits.sdstest index 07ef5028..509aab5b 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/int/good-multiple digits.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/int/good-multiple digits.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { 1234567890; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/int/good-one digit.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/int/good-one digit.sdstest index 5b0b6ed2..9c748058 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/int/good-one digit.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/int/good-one digit.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { 1; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/bad-single quotes as delimiters.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/bad-single quotes as delimiters.sdstest index 336c8ff3..8b4551d6 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/bad-single quotes as delimiters.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/bad-single quotes as delimiters.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { ''; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/bad-unclosed quote.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/bad-unclosed quote.sdstest index ece95009..36f8d414 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/bad-unclosed quote.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/bad-unclosed quote.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { "; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-basic content.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-basic content.sdstest index 935c134e..79cefed4 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-basic content.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-basic content.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { "myString"; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-closing template expression delimiter.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-closing template expression delimiter.sdstest index fdd181ba..7f7c2dca 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-closing template expression delimiter.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-closing template expression delimiter.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { "}}"; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-curly braces separated by space.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-curly braces separated by space.sdstest index 2bd7258f..f12997d1 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-curly braces separated by space.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-curly braces separated by space.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { "{ {"; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-empty.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-empty.sdstest index b57f8495..dafae1fe 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-empty.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-empty.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { ""; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-escaped curly brace.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-escaped curly brace.sdstest index a2ae5bfe..cd8f0e48 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-escaped curly brace.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-escaped curly brace.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { "\{{"; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-multiple lines.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-multiple lines.sdstest index f0ff08e9..64768bc4 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-multiple lines.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-multiple lines.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { " diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-newline escape sequence.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-newline escape sequence.sdstest index 01267dfe..7104ee86 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-newline escape sequence.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-newline escape sequence.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { "\n"; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-single curly brace.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-single curly brace.sdstest index ad1cffed..f9e7f60d 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-single curly brace.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-single curly brace.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { "{"; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-single quote.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-single quote.sdstest index 4e7a5f1c..ac7a4af3 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-single quote.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-single quote.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { "'"; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-unicode escape sequence.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-unicode escape sequence.sdstest index e3bba7e9..f808b694 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-unicode escape sequence.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-unicode escape sequence.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { "\u000c"; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-conjunction without left operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-conjunction without left operator.sdstest index 3b0e6d42..c8e3415b 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-conjunction without left operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-conjunction without left operator.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { and true; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-conjunction without right operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-conjunction without right operator.sdstest index 102b9ee0..3da7f5c0 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-conjunction without right operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-conjunction without right operator.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { false and; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-disjunction without left operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-disjunction without left operator.sdstest index af9e5465..677b31b4 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-disjunction without left operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-disjunction without left operator.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { or true; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-disjunction without right operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-disjunction without right operator.sdstest index 6d8e6cad..13971f94 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-disjunction without right operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-disjunction without right operator.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { true or; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-negation without operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-negation without operator.sdstest index 2bac0372..854267fb 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-negation without operator.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-negation without operator.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { -; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-complex example.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-complex example.sdstest index ff51eea9..0a12be46 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-complex example.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-complex example.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { not true and false or true; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-conjunction.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-conjunction.sdstest index 48c34f03..89fea66f 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-conjunction.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-conjunction.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { false and true; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-disjunction.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-disjunction.sdstest index 61e71b46..271891b9 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-disjunction.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-disjunction.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { true or true; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-negation.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-negation.sdstest index bbe571f8..30790c5d 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-negation.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-negation.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { not true; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-no colon.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-no colon.sdstest index 73bf3fca..62ec6038 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-no colon.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-no colon.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { {1 "one"}; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-no key.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-no key.sdstest index 620a6d38..74ffc56e 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-no key.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-no key.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { {: "one"}; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-no value.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-no value.sdstest index 5075dee0..3b6dbb19 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-no value.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-no value.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { {1: }; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-unclosed curly brace.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-unclosed curly brace.sdstest index 8a065a19..d87b4d94 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-unclosed curly brace.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-unclosed curly brace.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { {1: "one"; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-nested multiple elements.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-nested multiple elements.sdstest index 121d3771..e53c86eb 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-nested multiple elements.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-nested multiple elements.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { { diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-nested one element.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-nested one element.sdstest index 95eb89b9..81c26373 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-nested one element.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-nested one element.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { { diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-one level multiple elements.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-one level multiple elements.sdstest index 8d7aaaaf..cb179d9b 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-one level multiple elements.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-one level multiple elements.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { {1: "one", 2: "two"}; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-one level one element.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-one level one element.sdstest index 6ef83293..32922ba0 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-one level one element.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-one level one element.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { {1: "one"}; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/member accesses/bad-no receiver.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/member accesses/bad-no receiver.sdstest index 994417a2..f21bdfb4 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/member accesses/bad-no receiver.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/member accesses/bad-no receiver.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { .member; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/member accesses/good-not nullable.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/member accesses/good-not nullable.sdstest index 7b18e560..0143e79a 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/member accesses/good-not nullable.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/member accesses/good-not nullable.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { a.member; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/member accesses/good-nullable.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/member accesses/good-nullable.sdstest index 1dd1a494..1a9b8c15 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/member accesses/good-nullable.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/member accesses/good-nullable.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { a?.member; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/parenthesized expressions/bad-unclosed parenthesis.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/parenthesized expressions/bad-unclosed parenthesis.sdstest index 86154357..96a1dce5 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/parenthesized expressions/bad-unclosed parenthesis.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/parenthesized expressions/bad-unclosed parenthesis.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { (1; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/parenthesized expressions/good-nested.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/parenthesized expressions/good-nested.sdstest index 28de2204..5b210c27 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/parenthesized expressions/good-nested.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/parenthesized expressions/good-nested.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { ((1 + 2)); diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/parenthesized expressions/good-one level.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/parenthesized expressions/good-one level.sdstest index 7ee06f7c..631db9b5 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/parenthesized expressions/good-one level.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/parenthesized expressions/good-one level.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { (1 + 2); diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/template strings/bad-template string with invalid expression.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/template strings/bad-template string with invalid expression.sdstest index 0222f44a..a34d0a56 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/template strings/bad-template string with invalid expression.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/template strings/bad-template string with invalid expression.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { "{{ ??? }}"; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/template strings/bad-unclosed template expression.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/template strings/bad-unclosed template expression.sdstest index 6576503a..6c4e7f08 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/template strings/bad-unclosed template expression.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/template strings/bad-unclosed template expression.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { "{{"; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/template strings/good-empty template expression.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/template strings/good-empty template expression.sdstest index 89743ed3..064cfd44 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/template strings/good-empty template expression.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/template strings/good-empty template expression.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { "{{ }}"; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/template strings/good-template string with basic expression.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/template strings/good-template string with basic expression.sdstest index 0bf6ffbd..fc8d3666 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/template strings/good-template string with basic expression.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/template strings/good-template string with basic expression.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { "{{ 1 }}"; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/type casts/bad-without expression.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/type casts/bad-without expression.sdstest index 6f82ee37..f7461212 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/type casts/bad-without expression.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/type casts/bad-without expression.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { as Int; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/type casts/bad-without type.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/type casts/bad-without type.sdstest index 99d0a1bd..604895a0 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/type casts/bad-without type.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/type casts/bad-without type.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { 1 as; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/type casts/good-basic.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/type casts/good-basic.sdstest index 0fad21e8..7c845dd8 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/type casts/good-basic.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/type casts/good-basic.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { 1 as Int; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/type casts/good-chained.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/type casts/good-chained.sdstest index 983f1971..ca2f5a76 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/type casts/good-chained.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/type casts/good-chained.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { 1 as Int as String; diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped _.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped _.sdstest index 85a3f2c5..84288017 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped _.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped _.sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error class _ diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped and.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped and.sdstest index 0bb8f547..085b54b3 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped and.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped and.sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error class and diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped annotation.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped annotation.sdstest index 4b597f6a..89340ecc 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped annotation.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped annotation.sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error class annotation diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped as.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped as.sdstest index 2ba02019..89c7cfad 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped as.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped as.sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error class as diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped attr.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped attr.sdstest index d1bff13f..95b2ac0b 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped attr.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped attr.sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error class attr diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped class.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped class.sdstest index 9a33eeb2..84293707 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped class.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped class.sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error class class diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped const.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped const.sdstest index 75f62522..b310364a 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped const.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped const.sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error class const diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped enum.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped enum.sdstest index 852b4450..5fd6ae41 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped enum.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped enum.sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error class enum diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped false.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped false.sdstest index af850464..9a8c9b3f 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped false.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped false.sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error class false diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped fun.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped fun.sdstest index d7816347..edea3480 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped fun.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped fun.sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error class fun diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped import.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped import.sdstest index 1ea7be70..e7c5c26c 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped import.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped import.sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error class import diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped in.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped in.sdstest index 7b8bee0a..fb6e6099 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped in.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped in.sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error class in diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped internal.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped internal.sdstest index 82a4fd6a..68b05ffe 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped internal.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped internal.sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error class internal diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped literal.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped literal.sdstest index b7863813..8578433b 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped literal.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped literal.sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error class literal diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped not.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped not.sdstest index 52d45e69..0a99c29f 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped not.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped not.sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error class not diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped null.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped null.sdstest index faccc0d9..40d2934f 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped null.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped null.sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error class null diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped or.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped or.sdstest index 1ae53952..2e8b7582 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped or.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped or.sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error class or diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped out.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped out.sdstest index 4bf9d63d..cda025c1 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped out.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped out.sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error class out diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped package.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped package.sdstest index cf48b7aa..65ef3c09 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped package.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped package.sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error class package diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped pipeline.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped pipeline.sdstest index 0f352db2..e28d5204 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped pipeline.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped pipeline.sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error class pipeline diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped private.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped private.sdstest index 1c73321a..f701b4bc 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped private.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped private.sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error class private diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped schema.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped schema.sdstest index 802ef7dd..bc788c52 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped schema.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped schema.sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error class schema diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped segment.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped segment.sdstest index 653c08f8..5327bb38 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped segment.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped segment.sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error class segment diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped static.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped static.sdstest index c5594192..4084a2ce 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped static.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped static.sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error class static diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped sub.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped sub.sdstest index 836a88de..0cc3a750 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped sub.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped sub.sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error class sub diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped true.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped true.sdstest index 2b1859fd..810fbb1b 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped true.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped true.sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error class true diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped union.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped union.sdstest index 513c1e22..156a14b8 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped union.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped union.sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error class union diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped val.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped val.sdstest index 789d3412..c0d3d780 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped val.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped val.sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error class val diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped where.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped where.sdstest index 603c174f..4a5a8cf7 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped where.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped where.sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error class where diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped yield.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped yield.sdstest index 49b64014..965b87c3 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped yield.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped yield.sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error class yield diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/good-escapedKeywords.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/good-escapedKeywords.sdstest index bf629b32..b44cdb5f 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/good-escapedKeywords.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/good-escapedKeywords.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error class `_` class `and` diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/good-escapedNonKeyword.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/good-escapedNonKeyword.sdstest index 42bd6d11..2a9df26c 100644 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/good-escapedNonKeyword.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/good-escapedNonKeyword.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error class `Bla` diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/bad-annotation call after declaration.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/bad-annotation call after declaration.sdstest index 60963b7b..32b6ba5f 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/bad-annotation call after declaration.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/bad-annotation call after declaration.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error class C diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/bad-annotation call after import.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/bad-annotation call after import.sdstest index cbbcf31d..69fd2c16 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/bad-annotation call after import.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/bad-annotation call after import.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error from myPackage import MyClass diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/bad-annotation call after package name.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/bad-annotation call after package name.sdstest index 73f0ce27..c0f18f3a 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/bad-annotation call after package name.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/bad-annotation call after package name.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error package test diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/bad-annotation call between package name and import.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/bad-annotation call between package name and import.sdstest index 394f34fa..d0692375 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/bad-annotation call between package name and import.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/bad-annotation call between package name and import.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error package test diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/bad-duplicate package name.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/bad-duplicate package name.sdstest index 5fb58823..6c3bb4d6 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/bad-duplicate package name.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/bad-duplicate package name.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error package test diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/bad-import after declaration.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/bad-import after declaration.sdstest index 081196c6..37d05a95 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/bad-import after declaration.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/bad-import after declaration.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error class C diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/bad-import without declarations.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/bad-import without declarations.sdstest index 562cc7b4..8e5e68c4 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/bad-import without declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/bad-import without declarations.sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error from myPackage import diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/bad-import without package.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/bad-import without package.sdstest index d39b8f36..e81a3ffe 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/bad-import without package.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/bad-import without package.sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error from import MyClass diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/bad-package name after declaration.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/bad-package name after declaration.sdstest index ed52d4d8..0050a51d 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/bad-package name after declaration.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/bad-package name after declaration.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error class C diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/bad-package name after import.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/bad-package name after import.sdstest index a8fd8c07..fb1df5eb 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/bad-package name after import.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/bad-package name after import.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error from myPackage import someDeclaration diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and declaration.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and declaration.sdstest index 445f2646..4ad22173 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and declaration.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and declaration.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error @Annotation1 diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and import and declaration.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and import and declaration.sdstest index a05b3a00..23513163 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and import and declaration.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and import and declaration.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error @Annotation1 diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and import.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and import.sdstest index 23894a2a..9412b051 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and import.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and import.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error @Annotation1 diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and package name and declaration.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and package name and declaration.sdstest index f08ca10f..bcdd8aca 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and package name and declaration.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and package name and declaration.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error @Annotation1 diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and package name and import and declaration.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and package name and import and declaration.sdstest index 07d2f1f7..417eab28 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and package name and import and declaration.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and package name and import and declaration.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error @Annotation1 diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and package name and import.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and package name and import.sdstest index 2ede89b6..6e382d8d 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and package name and import.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and package name and import.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error @Annotation1 diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and package name.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and package name.sdstest index a15eb2ed..bebb420a 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and package name.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and package name.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error @Annotation1 diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call.sdstest index a3a0576c..d99e5e6a 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error @Annotation1 diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and declarations.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and declarations.sdstest index 5c8529cb..527c03d0 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and declarations.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error @Annotation1 @Annotation2 diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and imports and declarations.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and imports and declarations.sdstest index af4e0e1a..1405718a 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and imports and declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and imports and declarations.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error @Annotation1 @Annotation2 diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and imports.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and imports.sdstest index bda0cf39..091c3ceb 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and imports.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and imports.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error @Annotation1 @Annotation2 diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and package name and declarations.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and package name and declarations.sdstest index 4465b9ff..670d85b1 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and package name and declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and package name and declarations.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error @Annotation1 @Annotation2 diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and package name and imports and declarations.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and package name and imports and declarations.sdstest index 2d8f4c4a..cef48d9c 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and package name and imports and declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and package name and imports and declarations.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error @Annotation1 @Annotation2 diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and package name and imports.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and package name and imports.sdstest index a649152a..c35fd05c 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and package name and imports.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and package name and imports.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error @Annotation1 @Annotation2 diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and package name.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and package name.sdstest index 4c61fdf8..777ab87a 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and package name.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and package name.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error @Annotation1 @Annotation2 diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls.sdstest index bd0b6e64..2c41fba2 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error @Annotation1 @Annotation2 diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-declaration.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-declaration.sdstest index 69044739..04c83e5f 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-declaration.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-declaration.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error class C diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-declarations.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-declarations.sdstest index 83efc408..e64324dd 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-declarations.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error class C class D diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-empty.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-empty.sdstest index 4fdd9ba3..665cb888 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-empty.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-empty.sdstest @@ -1 +1 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-import and declaration.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-import and declaration.sdstest index 53a89afd..ba1a0a17 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-import and declaration.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-import and declaration.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error from myPackage import MyClass diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-import.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-import.sdstest index 7dc1b9af..4cd7febc 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-import.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-import.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error from myPackage import MyClass diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-imports and declarations.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-imports and declarations.sdstest index 91077664..c999e0d4 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-imports and declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-imports and declarations.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error from myPackage import MyClass from myPackage import MyClass as Class diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-imports.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-imports.sdstest index 1ee8d640..117cdede 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-imports.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-imports.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error from myPackage import MyClass from myPackage import MyClass as Class diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and declaration.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and declaration.sdstest index 4a1e020d..467c84b6 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and declaration.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and declaration.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error package myPackage diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and declarations.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and declarations.sdstest index 2afcc045..5d53478e 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and declarations.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error package myPackage diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and import and declaration.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and import and declaration.sdstest index 2a6f32f6..a15f84d0 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and import and declaration.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and import and declaration.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error package myPackage diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and import.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and import.sdstest index bde88774..1e641a95 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and import.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and import.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error package myPackage diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and imports and declarations.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and imports and declarations.sdstest index e9745fa0..32276074 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and imports and declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and imports and declarations.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error package myPackage diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and imports.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and imports.sdstest index 52008f46..2e7a19d8 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and imports.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and imports.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error package myPackage diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-package name.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-package name.sdstest index 9cbefbb4..6cf287b7 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-package name.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-package name.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error package myPackage diff --git a/packages/ttsl-lang/tests/resources/grammar/schema/bad-no name (colon).sdstest b/packages/ttsl-lang/tests/resources/grammar/schema/bad-no name (colon).sdstest index eef2ab86..7e8ad729 100644 --- a/packages/ttsl-lang/tests/resources/grammar/schema/bad-no name (colon).sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/schema/bad-no name (colon).sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error schema MySchema { : Int diff --git a/packages/ttsl-lang/tests/resources/grammar/schema/bad-no name (no colon).sdstest b/packages/ttsl-lang/tests/resources/grammar/schema/bad-no name (no colon).sdstest index 224f7acd..b9972ace 100644 --- a/packages/ttsl-lang/tests/resources/grammar/schema/bad-no name (no colon).sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/schema/bad-no name (no colon).sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error schema MySchema { Int diff --git a/packages/ttsl-lang/tests/resources/grammar/schema/bad-no type (colon).sdstest b/packages/ttsl-lang/tests/resources/grammar/schema/bad-no type (colon).sdstest index 0f987c5d..0da371cb 100644 --- a/packages/ttsl-lang/tests/resources/grammar/schema/bad-no type (colon).sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/schema/bad-no type (colon).sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error schema MySchema { "column1" : diff --git a/packages/ttsl-lang/tests/resources/grammar/schema/bad-no type (no colon).sdstest b/packages/ttsl-lang/tests/resources/grammar/schema/bad-no type (no colon).sdstest index 0bd789c4..8a3589f9 100644 --- a/packages/ttsl-lang/tests/resources/grammar/schema/bad-no type (no colon).sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/schema/bad-no type (no colon).sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error schema MySchema { "column1" diff --git a/packages/ttsl-lang/tests/resources/grammar/schema/bad-switched name and type.sdstest b/packages/ttsl-lang/tests/resources/grammar/schema/bad-switched name and type.sdstest index 209d0a1e..35432749 100644 --- a/packages/ttsl-lang/tests/resources/grammar/schema/bad-switched name and type.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/schema/bad-switched name and type.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error schema MySchema { Int: "column1" diff --git a/packages/ttsl-lang/tests/resources/grammar/schema/bad-unclosed curly brace.sdstest b/packages/ttsl-lang/tests/resources/grammar/schema/bad-unclosed curly brace.sdstest index deec0956..344b89da 100644 --- a/packages/ttsl-lang/tests/resources/grammar/schema/bad-unclosed curly brace.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/schema/bad-unclosed curly brace.sdstest @@ -1,3 +1,3 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error schema MySchema { diff --git a/packages/ttsl-lang/tests/resources/grammar/schema/good-annotation call.sdstest b/packages/ttsl-lang/tests/resources/grammar/schema/good-annotation call.sdstest index 58bbc01f..6d802b73 100644 --- a/packages/ttsl-lang/tests/resources/grammar/schema/good-annotation call.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/schema/good-annotation call.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error package test diff --git a/packages/ttsl-lang/tests/resources/grammar/schema/good-empty schema.sdstest b/packages/ttsl-lang/tests/resources/grammar/schema/good-empty schema.sdstest index 6a4dd39b..f1e64b43 100644 --- a/packages/ttsl-lang/tests/resources/grammar/schema/good-empty schema.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/schema/good-empty schema.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error schema MySchema {} diff --git a/packages/ttsl-lang/tests/resources/grammar/schema/good-one column.sdstest b/packages/ttsl-lang/tests/resources/grammar/schema/good-one column.sdstest index ccc30da5..bea79ca3 100644 --- a/packages/ttsl-lang/tests/resources/grammar/schema/good-one column.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/schema/good-one column.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error schema MySchema { "column1": Int diff --git a/packages/ttsl-lang/tests/resources/grammar/schema/good-two columns.sdstest b/packages/ttsl-lang/tests/resources/grammar/schema/good-two columns.sdstest index f79a4356..5cd16453 100644 --- a/packages/ttsl-lang/tests/resources/grammar/schema/good-two columns.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/schema/good-two columns.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error schema MySchema { "column1": Int, diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in block lambda without assignees.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in block lambda without assignees.sdstest index 151973bc..670cdb28 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in block lambda without assignees.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in block lambda without assignees.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { () { diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in block lambda without expression.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in block lambda without expression.sdstest index 1d884a80..6d5ea11a 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in block lambda without expression.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in block lambda without expression.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { () { diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in block lambda without semicolon.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in block lambda without semicolon.sdstest index ffdb9f57..910fdb29 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in block lambda without semicolon.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in block lambda without semicolon.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { () { diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in pipeline without assignees.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in pipeline without assignees.sdstest index df2f3d5f..673d19d5 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in pipeline without assignees.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in pipeline without assignees.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { = 0; diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in pipeline without expression.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in pipeline without expression.sdstest index 2b5c1a5c..5bc01e5b 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in pipeline without expression.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in pipeline without expression.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { val a =; diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in pipeline without semicolon.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in pipeline without semicolon.sdstest index 966da2fd..1a5bd5ec 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in pipeline without semicolon.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in pipeline without semicolon.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { val a = 0 diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in segment without assignees.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in segment without assignees.sdstest index 6b059be1..886632c6 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in segment without assignees.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in segment without assignees.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error segment mySegment() { = 0; diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in segment without expression.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in segment without expression.sdstest index ab8cdf57..0d7b52fd 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in segment without expression.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in segment without expression.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error segment mySegment() { val a =; diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in segment without semicolon.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in segment without semicolon.sdstest index 06cac9d3..350dbd7d 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in segment without semicolon.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in segment without semicolon.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error segment mySegment() { val a = 0 diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/good-in block lambda.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/good-in block lambda.sdstest index 190ecc97..7f4f5a00 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/good-in block lambda.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/good-in block lambda.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { () { diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/good-in pipeline.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/good-in pipeline.sdstest index a73637e4..547464b3 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/good-in pipeline.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/good-in pipeline.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { val a = 0; diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/good-in segment.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/good-in segment.sdstest index bdbb994a..334f15ef 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/good-in segment.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/good-in segment.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error segment mySegment() { val a = 0; diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/bad-empty statement in block lambda.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/bad-empty statement in block lambda.sdstest index 0c48d0e3..47540d3b 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/bad-empty statement in block lambda.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/bad-empty statement in block lambda.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { () { diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/bad-empty statement in pipeline.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/bad-empty statement in pipeline.sdstest index 333ebefb..b49c045c 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/bad-empty statement in pipeline.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/bad-empty statement in pipeline.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { ; diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/bad-empty statement in segment.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/bad-empty statement in segment.sdstest index f17e3d06..ab3a700b 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/bad-empty statement in segment.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/bad-empty statement in segment.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error segment mySegment() { ; diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-without else missing block.tsltest b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-without else missing block.tsltest index c85ba297..415d8f91 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-without else missing block.tsltest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-without else missing block.tsltest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error function myFunction(): { if (true) diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-without else missing condition.tsltest b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-without else missing condition.tsltest index 42ef6b5b..1dca81c9 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-without else missing condition.tsltest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-without else missing condition.tsltest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error function myFunction(): { if (){} diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-with else false.tsltest b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-with else false.tsltest index 9ed45c37..0fac6980 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-with else false.tsltest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-with else false.tsltest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error function myFunction(): { if (false){} diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-with else true.tsltest b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-with else true.tsltest index 002c6c15..3a6bd8ee 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-with else true.tsltest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-with else true.tsltest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error function myFunction(): { if (true){} diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-without else.tsltest b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-without else.tsltest index d5956a99..abb59d8a 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-without else.tsltest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-without else.tsltest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error function myFunction(): { if (true){} diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/bad-in block lambda without semicolon.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/bad-in block lambda without semicolon.sdstest index feb115dc..6493c7e3 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/bad-in block lambda without semicolon.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/bad-in block lambda without semicolon.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { () { diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/bad-in pipeline without semicolon.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/bad-in pipeline without semicolon.sdstest index ff65d1ad..bcf2dbd2 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/bad-in pipeline without semicolon.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/bad-in pipeline without semicolon.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error pipeline myPipeline { call() diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/bad-in segment without semicolon.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/bad-in segment without semicolon.sdstest index e4b72cb9..8e9345f9 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/bad-in segment without semicolon.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/bad-in segment without semicolon.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error segment mySegment() { call() diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/good-in block lambda.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/good-in block lambda.sdstest index af2844a9..63f8f138 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/good-in block lambda.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/good-in block lambda.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { () { diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/good-in pipeline.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/good-in pipeline.sdstest index c1c2afd7..a3fb0130 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/good-in pipeline.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/good-in pipeline.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { call(); diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/good-in segment.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/good-in segment.sdstest index 9ef76b27..57c29420 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/good-in segment.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/good-in segment.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error segment mySegment() { call(); diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-argument list of annotation call.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-argument list of annotation call.sdstest index 7ac2dda3..f8be6908 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-argument list of annotation call.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-argument list of annotation call.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error @A(1, 2, ) diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-argument list of call.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-argument list of call.sdstest index 7ded7e6f..00d833f0 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-argument list of call.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-argument list of call.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline p { f(1, 2, ); diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-assignee list of assignment in block lambda.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-assignee list of assignment in block lambda.sdstest index f06aa4c1..397d4183 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-assignee list of assignment in block lambda.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-assignee list of assignment in block lambda.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline p { () { diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-assignee list of assignment.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-assignee list of assignment.sdstest index 1602c872..83e8ff91 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-assignee list of assignment.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-assignee list of assignment.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline p { val a, val b, = f(); diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-column list of schema.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-column list of schema.sdstest index a144f227..f4dd423f 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-column list of schema.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-column list of schema.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error schema MySchemaWithTrailingComma { "column1" : Int, diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-constraint list of annotation.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-constraint list of annotation.sdstest index 57a0170a..ab23f1ef 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-constraint list of annotation.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-constraint list of annotation.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error annotation A where { p < 0, diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-constraint list of class.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-constraint list of class.sdstest index 2c361e4d..c3b80dd9 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-constraint list of class.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-constraint list of class.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error class C where { p < 0, diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-constraint list of enum variant.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-constraint list of enum variant.sdstest index ab6384f6..8330bbf5 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-constraint list of enum variant.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-constraint list of enum variant.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error enum E { A where { diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-constraint list of function.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-constraint list of function.sdstest index 27a7f9a8..0520d786 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-constraint list of function.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-constraint list of function.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error fun f() where { p < 0, diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-elements of list.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-elements of list.sdstest index b4a98c08..be2054ad 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-elements of list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-elements of list.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { [1, 2, ]; diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-entries of map.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-entries of map.sdstest index 6b62e6a9..787c00d7 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-entries of map.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-entries of map.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline myPipeline { {1: "one", 2: "two", }; diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-imported declaration list of qualified import.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-imported declaration list of qualified import.sdstest index e4735b62..e98849e9 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-imported declaration list of qualified import.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-imported declaration list of qualified import.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error from myPackage import MyClass, MyClass as Class, \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-literal list of literal type.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-literal list of literal type.sdstest index c0cdfc01..0253c098 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-literal list of literal type.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-literal list of literal type.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error segment s( f: literal diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of annotation.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of annotation.sdstest index 6c4d85e0..da48dfa8 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of annotation.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of annotation.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error annotation A( a: Int, diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of block lambda.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of block lambda.sdstest index 0f0b93c3..a1f3e4e3 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of block lambda.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of block lambda.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline p { (first, second, ) {}; diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of callable type.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of callable type.sdstest index 527b372f..e1d85571 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of callable type.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of callable type.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error segment s( f: (x: Int, y: Int, ) -> () diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of class.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of class.sdstest index 9aa45910..5101eeba 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of class.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of class.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error class C(a: Int, b: Int, ) diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of enum variant.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of enum variant.sdstest index 18aa6ca9..449e1df0 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of enum variant.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of enum variant.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error enum E { A( diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of expression lambda.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of expression lambda.sdstest index c04a1d65..b8a58ec3 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of expression lambda.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of expression lambda.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error pipeline p { (first, second, ) -> 1; diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of function.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of function.sdstest index 5cd6104d..067186c8 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of function.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of function.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error fun f( a: Int, diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of segment.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of segment.sdstest index 7eb2519e..47f64488 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of segment.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of segment.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error segment s( a: Int, diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parent type list of class.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parent type list of class.sdstest index a705e37b..1bcd73e5 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parent type list of class.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parent type list of class.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error class C sub D, E, diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-result list of callable type.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-result list of callable type.sdstest index e8ff5ec0..e06ea897 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-result list of callable type.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-result list of callable type.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error segment s( f: () -> (x: Int, y: Int, ) diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-result list of function.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-result list of function.sdstest index fb3da56f..6900e96e 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-result list of function.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-result list of function.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error fun f() -> ( first: Int, diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-result list of segment.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-result list of segment.sdstest index 6f1c43cf..64c7b4b2 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-result list of segment.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-result list of segment.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error segment s() -> ( first: Int, diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-type argument list of named type.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-type argument list of named type.sdstest index b19dbc70..c4d43d35 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-type argument list of named type.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-type argument list of named type.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error segment s( f: Type diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-type argument list of union type.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-type argument list of union type.sdstest index a5915350..83b71756 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-type argument list of union type.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-type argument list of union type.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error segment s( f: union diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-type parameter list of class.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-type parameter list of class.sdstest index b2dd3728..8c208c01 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-type parameter list of class.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-type parameter list of class.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error class C diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-type parameter list of function.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-type parameter list of function.sdstest index 9b28068a..f139517e 100644 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-type parameter list of function.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-type parameter list of function.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error fun f() diff --git a/packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-missing arrow.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-missing arrow.sdstest index 38e12cf3..5674be22 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-missing arrow.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-missing arrow.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error segment mySegment( f: () () diff --git a/packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-missing parameter list.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-missing parameter list.sdstest index ac42849c..73927697 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-missing parameter list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-missing parameter list.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error segment mySegment( f: -> () diff --git a/packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-missing result list.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-missing result list.sdstest index 837aa711..89bb1850 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-missing result list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-missing result list.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error segment mySegment( f: () -> diff --git a/packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-unclosed parameter list.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-unclosed parameter list.sdstest index b9e2b5af..13278275 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-unclosed parameter list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-unclosed parameter list.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error segment mySegment( f: ( -> () diff --git a/packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-unclosed result list.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-unclosed result list.sdstest index d49d667a..3b2759a8 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-unclosed result list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-unclosed result list.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error segment mySegment( f: () -> ( diff --git a/packages/ttsl-lang/tests/resources/grammar/types/callable types/good-with parameter and result lists.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/callable types/good-with parameter and result lists.sdstest index a5a088c1..2baa7ff0 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/callable types/good-with parameter and result lists.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/callable types/good-with parameter and result lists.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error segment mySegment( f: () -> () diff --git a/packages/ttsl-lang/tests/resources/grammar/types/literal types/bad-nested.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/literal types/bad-nested.sdstest index fae94dc0..ce0e69ae 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/literal types/bad-nested.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/literal types/bad-nested.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error segment mySegment( x: literal> diff --git a/packages/ttsl-lang/tests/resources/grammar/types/literal types/bad-no literal list.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/literal types/bad-no literal list.sdstest index 5245213d..7c5a3834 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/literal types/bad-no literal list.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/literal types/bad-no literal list.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error segment mySegment( x: literal diff --git a/packages/ttsl-lang/tests/resources/grammar/types/literal types/bad-unclosed angle bracket.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/literal types/bad-unclosed angle bracket.sdstest index b5dc0d8e..abf93699 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/literal types/bad-unclosed angle bracket.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/literal types/bad-unclosed angle bracket.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error segment mySegment( x: literal< diff --git a/packages/ttsl-lang/tests/resources/grammar/types/literal types/good-empty.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/literal types/good-empty.sdstest index 794a4c62..66a936d1 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/literal types/good-empty.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/literal types/good-empty.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error segment mySegment( x: literal<> diff --git a/packages/ttsl-lang/tests/resources/grammar/types/literal types/good-with list literal.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/literal types/good-with list literal.sdstest index 7c5357c7..02435b25 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/literal types/good-with list literal.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/literal types/good-with list literal.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error segment mySegment( x: literal<[]> diff --git a/packages/ttsl-lang/tests/resources/grammar/types/literal types/good-with literals.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/literal types/good-with literals.sdstest index 54713226..3fbda1b5 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/literal types/good-with literals.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/literal types/good-with literals.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error segment mySegment( x: literal diff --git a/packages/ttsl-lang/tests/resources/grammar/types/literal types/good-with map literal.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/literal types/good-with map literal.sdstest index 60c1b6c0..d19c3930 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/literal types/good-with map literal.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/literal types/good-with map literal.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error segment mySegment( x: literal<{}> diff --git a/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-callable type as member.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-callable type as member.sdstest index 4eb240e5..11f5aba3 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-callable type as member.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-callable type as member.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error segment mySegment( x: OuterClass.() -> () diff --git a/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-literal type as member.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-literal type as member.sdstest index 615fe494..701706f1 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-literal type as member.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-literal type as member.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error segment mySegment( x: OuterClass.literal<> diff --git a/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-missing member.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-missing member.sdstest index 62eec592..9f4517d3 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-missing member.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-missing member.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error segment mySegment( x: OuterClass. diff --git a/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-missing receiver.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-missing receiver.sdstest index a123da6d..36d39ad5 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-missing receiver.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-missing receiver.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error segment mySegment( x: .InnerClass diff --git a/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-unclosed angle bracket.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-unclosed angle bracket.sdstest index ecf5fb40..b69e017b 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-unclosed angle bracket.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-unclosed angle bracket.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error segment mySegment( x: OuterClass.InnerClass< diff --git a/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-union type as member.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-union type as member.sdstest index a68de5a4..bdbd8075 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-union type as member.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-union type as member.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error segment mySegment( x: OuterClass.union<> diff --git a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-long complex chain.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/member types/good-long complex chain.sdstest index d0f73add..1a3867f8 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-long complex chain.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/member types/good-long complex chain.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error segment mySegment( x: union<>.MiddleClass?.InnerClass diff --git a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (callable) and member (not nullable).sdstest b/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (callable) and member (not nullable).sdstest index 00ed5e6c..4867643c 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (callable) and member (not nullable).sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (callable) and member (not nullable).sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error segment mySegment( x: () -> ().InnerClass diff --git a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (callable) and member (nullable).sdstest b/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (callable) and member (nullable).sdstest index f2857084..5cfef9a1 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (callable) and member (nullable).sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (callable) and member (nullable).sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error segment mySegment( x: () -> ().InnerClass? diff --git a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (literal) and member (not nullable).sdstest b/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (literal) and member (not nullable).sdstest index 18d08c95..6be0c881 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (literal) and member (not nullable).sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (literal) and member (not nullable).sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error segment mySegment( x: literal<>.InnerClass diff --git a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (literal) and member (nullable).sdstest b/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (literal) and member (nullable).sdstest index 94cb846f..2c8e93a9 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (literal) and member (nullable).sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (literal) and member (nullable).sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error segment mySegment( x: literal<>.InnerClass? diff --git a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (named, not nullable) and member (not nullable).sdstest b/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (named, not nullable) and member (not nullable).sdstest index 9317d711..56b6bf48 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (named, not nullable) and member (not nullable).sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (named, not nullable) and member (not nullable).sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error segment mySegment( x: OuterClass.InnerClass diff --git a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (named, not nullable) and member (nullable).sdstest b/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (named, not nullable) and member (nullable).sdstest index cb2c5a8f..118f8783 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (named, not nullable) and member (nullable).sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (named, not nullable) and member (nullable).sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error segment mySegment( x: OuterClass.InnerClass? diff --git a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (named, nullable) and member (not nullable).sdstest b/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (named, nullable) and member (not nullable).sdstest index 0d9e95f9..f74fa6e4 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (named, nullable) and member (not nullable).sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (named, nullable) and member (not nullable).sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error segment mySegment( x: OuterClass?.InnerClass diff --git a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (named, nullable) and member (nullable).sdstest b/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (named, nullable) and member (nullable).sdstest index cb2c5a8f..118f8783 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (named, nullable) and member (nullable).sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (named, nullable) and member (nullable).sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error segment mySegment( x: OuterClass.InnerClass? diff --git a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (union) and member (not nullable).sdstest b/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (union) and member (not nullable).sdstest index ae2f4e07..5d1d5321 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (union) and member (not nullable).sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (union) and member (not nullable).sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error segment mySegment( x: union<>.InnerClass diff --git a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (union) and member (nullable).sdstest b/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (union) and member (nullable).sdstest index 776fbab1..04ad20cc 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (union) and member (nullable).sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (union) and member (nullable).sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error segment mySegment( x: union<>.InnerClass? diff --git a/packages/ttsl-lang/tests/resources/grammar/types/named types/bad-unclosed angle bracket.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/named types/bad-unclosed angle bracket.sdstest index acb38b49..77d80695 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/named types/bad-unclosed angle bracket.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/named types/bad-unclosed angle bracket.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error segment mySegment( x: OuterClass< diff --git a/packages/ttsl-lang/tests/resources/grammar/types/named types/good-no type arguments and not nullable.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/named types/good-no type arguments and not nullable.sdstest index 574b8e8c..880fb7dd 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/named types/good-no type arguments and not nullable.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/named types/good-no type arguments and not nullable.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error segment mySegment( x: Int diff --git a/packages/ttsl-lang/tests/resources/grammar/types/named types/good-no type arguments and nullable.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/named types/good-no type arguments and nullable.sdstest index e8e044e3..9da0abc2 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/named types/good-no type arguments and nullable.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/named types/good-no type arguments and nullable.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error segment mySegment( x: Int? diff --git a/packages/ttsl-lang/tests/resources/grammar/types/named types/good-type argument and nullable.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/named types/good-type argument and nullable.sdstest index dfdcaae9..1959e858 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/named types/good-type argument and nullable.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/named types/good-type argument and nullable.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error segment mySegment( x: Int? diff --git a/packages/ttsl-lang/tests/resources/grammar/types/named types/good-type arguments and not nullable.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/named types/good-type arguments and not nullable.sdstest index 5ece5476..c814980e 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/named types/good-type arguments and not nullable.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/named types/good-type arguments and not nullable.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error segment mySegment( x: Int diff --git a/packages/ttsl-lang/tests/resources/grammar/types/union types/bad-unclosed angle bracket.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/union types/bad-unclosed angle bracket.sdstest index 2c052d03..05a407af 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/union types/bad-unclosed angle bracket.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/union types/bad-unclosed angle bracket.sdstest @@ -1,4 +1,4 @@ -# $TEST$ syntax_error +// $TEST$ syntax_error segment mySegment( x: union< diff --git a/packages/ttsl-lang/tests/resources/grammar/types/union types/good-empty.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/union types/good-empty.sdstest index 2d1fa8ce..0d4de615 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/union types/good-empty.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/union types/good-empty.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error segment mySegment( x: union<> diff --git a/packages/ttsl-lang/tests/resources/grammar/types/union types/good-nested.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/union types/good-nested.sdstest index 3e9785aa..9fbe2261 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/union types/good-nested.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/union types/good-nested.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error segment mySegment( x: union> diff --git a/packages/ttsl-lang/tests/resources/grammar/types/union types/good-with type arguments.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/union types/good-with type arguments.sdstest index e1246c7f..0d9fc775 100644 --- a/packages/ttsl-lang/tests/resources/grammar/types/union types/good-with type arguments.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/types/union types/good-with type arguments.sdstest @@ -1,4 +1,4 @@ -# $TEST$ no_syntax_error +// $TEST$ no_syntax_error segment mySegment( x: union diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/block lambdas/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/block lambdas/main.sdstest index 00c6e80d..5e1a56dd 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/block lambdas/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/block lambdas/main.sdstest @@ -1,6 +1,6 @@ package tests.partialValidation.baseCases.expressionLambdas pipeline test { - # $TEST$ serialization $expressionLambdaClosure + // $TEST$ serialization $expressionLambdaClosure »() -> 1«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/boolean literals/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/boolean literals/main.sdstest index e489cc2a..c12e0ca7 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/boolean literals/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/boolean literals/main.sdstest @@ -1,9 +1,9 @@ package tests.partialValidation.baseCases.booleanLiterals pipeline test { - # $TEST$ serialization false + // $TEST$ serialization false »false«; - # $TEST$ serialization true + // $TEST$ serialization true »true«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/classes/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/classes/main.sdstest index b7a98b21..372271be 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/classes/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/classes/main.sdstest @@ -1,4 +1,4 @@ package tests.partialValidation.baseCases.classes -# $TEST$ serialization C +// $TEST$ serialization C »class C« diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/enum variants/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/enum variants/main.sdstest index c5844cd6..8c4fcc88 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/enum variants/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/enum variants/main.sdstest @@ -1,6 +1,6 @@ package tests.partialValidation.baseCases.enumVariants enum MyEnum { - # $TEST$ serialization MyVariant + // $TEST$ serialization MyVariant »MyVariant« } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/expression lambdas/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/expression lambdas/main.sdstest index d0faa1c8..686070ce 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/expression lambdas/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/expression lambdas/main.sdstest @@ -1,6 +1,6 @@ package tests.partialValidation.baseCases.blockLambdas pipeline test { - # $TEST$ serialization $blockLambdaClosure + // $TEST$ serialization $blockLambdaClosure »() {}«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/float literals/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/float literals/main.sdstest index 7ed21a44..c5f6dab5 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/float literals/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/float literals/main.sdstest @@ -1,9 +1,9 @@ package tests.partialValidation.baseCases.floatLiterals pipeline test { - # $TEST$ serialization 1.25 + // $TEST$ serialization 1.25 »1.25«; - # $TEST$ serialization 0.02 + // $TEST$ serialization 0.02 »2e-2«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/functions/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/functions/main.sdstest index f5a02d39..1f0f1b21 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/functions/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/functions/main.sdstest @@ -1,4 +1,4 @@ package tests.partialValidation.baseCases.functions -# $TEST$ serialization f +// $TEST$ serialization f @Pure »fun f()« diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/int literals/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/int literals/main.sdstest index 4693cffb..6a9e1c38 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/int literals/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/int literals/main.sdstest @@ -1,6 +1,6 @@ package tests.partialValidation.baseCases.intLiterals pipeline test { - # $TEST$ serialization 123 + // $TEST$ serialization 123 »123«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/null literals/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/null literals/main.sdstest index c0f49eb5..ce8914a9 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/null literals/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/null literals/main.sdstest @@ -1,6 +1,6 @@ package tests.partialValidation.baseCases.nullLiterals pipeline test { - # $TEST$ serialization null + // $TEST$ serialization null »null«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/segments/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/segments/main.sdstest index 044fabca..fc5b4734 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/segments/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/segments/main.sdstest @@ -1,4 +1,4 @@ package tests.partialValidation.baseCases.segments -# $TEST$ serialization mySegment +// $TEST$ serialization mySegment »segment mySegment() {}« diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/string literals (without interpolation)/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/string literals (without interpolation)/main.sdstest index cb344f56..cfa452d8 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/string literals (without interpolation)/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/string literals (without interpolation)/main.sdstest @@ -1,9 +1,9 @@ package tests.partialValidation.baseCases.stringLiteralsWithoutInterpolation pipeline test { - # $TEST$ serialization "test" + // $TEST$ serialization "test" »"test"«; - # $TEST$ serialization "test\t" + // $TEST$ serialization "test\t" »"test\t"«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/invalid nodes/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/invalid nodes/main.sdstest index fcbb8463..90e69ec8 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/invalid nodes/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/invalid nodes/main.sdstest @@ -1,4 +1,4 @@ package tests.partialValidation.invalidNodes -# $TEST$ serialization ? +// $TEST$ serialization ? »schema mySchema {}« diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/arguments/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/arguments/main.sdstest index 5dbd87da..3513e80a 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/arguments/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/arguments/main.sdstest @@ -3,9 +3,9 @@ package tests.partialValidation.recursiveCases.arguments @Pure fun f(p: Any?) pipeline test { - # $TEST$ serialization 1 + // $TEST$ serialization 1 f(»p = 1«); - # $TEST$ serialization null + // $TEST$ serialization null f(»p = null«); } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/block lambda results/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/block lambda results/main.sdstest index f4370a32..8632b110 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/block lambda results/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/block lambda results/main.sdstest @@ -6,12 +6,12 @@ segment mySegment() -> r: Int { pipeline test { () { - # $TEST$ serialization 1 - # $TEST$ serialization ? + // $TEST$ serialization 1 + // $TEST$ serialization ? »yield a«, »yield b« = 1; - # $TEST$ serialization 2 - # $TEST$ serialization ? + // $TEST$ serialization 2 + // $TEST$ serialization ? »yield c«, »yield d« = mySegment(); }; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/placeholders/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/placeholders/main.sdstest index 1c8e4ec3..a3df4036 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/placeholders/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/placeholders/main.sdstest @@ -5,11 +5,11 @@ segment mySegment() -> r: Int { } pipeline test { - # $TEST$ serialization 1 - # $TEST$ serialization ? + // $TEST$ serialization 1 + // $TEST$ serialization ? »val a«, »val b« = 1; - # $TEST$ serialization 2 - # $TEST$ serialization ? + // $TEST$ serialization 2 + // $TEST$ serialization ? »val c«, »val d« = mySegment(); } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/wildcards/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/wildcards/main.sdstest index bbe19f58..a0876509 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/wildcards/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/wildcards/main.sdstest @@ -5,11 +5,11 @@ segment mySegment() -> r: Int { } pipeline test { - # $TEST$ serialization 1 - # $TEST$ serialization ? + // $TEST$ serialization 1 + // $TEST$ serialization ? »_«, »_« = 1; - # $TEST$ serialization 2 - # $TEST$ serialization ? + // $TEST$ serialization 2 + // $TEST$ serialization ? »_«, »_« = mySegment(); } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/yields/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/yields/main.sdstest index 98316b0e..8731cd3a 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/yields/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/yields/main.sdstest @@ -5,11 +5,11 @@ segment mySegment() -> r: Int { } segment mySegment2() -> (a: Int, b: Int, c: Int, d: Int) { - # $TEST$ serialization 1 - # $TEST$ serialization ? + // $TEST$ serialization 1 + // $TEST$ serialization ? »yield a«, »yield b« = 1; - # $TEST$ serialization 2 - # $TEST$ serialization ? + // $TEST$ serialization 2 + // $TEST$ serialization ? »yield c«, »yield d« = mySegment(); } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of block lambdas/closure.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of block lambdas/closure.sdstest index 7284631f..ab57993a 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of block lambdas/closure.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of block lambdas/closure.sdstest @@ -7,6 +7,6 @@ segment mySegment(p: Int) -> (closure: () -> (r: Int)) { } pipeline test { - # $TEST$ serialization 1 + // $TEST$ serialization 1 »mySegment(1)()«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of block lambdas/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of block lambdas/main.sdstest index cadf3d64..298349dd 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of block lambdas/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of block lambdas/main.sdstest @@ -6,6 +6,6 @@ pipeline test { yield s = 2; }; - # $TEST$ serialization (r = 1, s = 2) + // $TEST$ serialization (r = 1, s = 2) »blockLambda()«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of block lambdas/previous parameter value used as default value.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of block lambdas/previous parameter value used as default value.sdstest index 77fcbfa1..3a09c0d5 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of block lambdas/previous parameter value used as default value.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of block lambdas/previous parameter value used as default value.sdstest @@ -5,6 +5,6 @@ pipeline test { yield r = p2; }; - # $TEST$ serialization 1 + // $TEST$ serialization 1 »blockLambda(1)«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of classes/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of classes/main.sdstest index aa7d2186..fcceeec4 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of classes/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of classes/main.sdstest @@ -3,6 +3,6 @@ package tests.partialValidation.recursiveCases.calls.ofClasses class C() pipeline test { - # $TEST$ serialization ? + // $TEST$ serialization ? »C()«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of enum variants/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of enum variants/main.sdstest index d7b0851a..e972a57d 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of enum variants/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of enum variants/main.sdstest @@ -6,30 +6,30 @@ enum MyEnum { } pipeline test { - # $TEST$ serialization MyEnumVariantWithoutParameters() + // $TEST$ serialization MyEnumVariantWithoutParameters() »MyEnum.MyEnumVariantWithoutParameters()«; - # $TEST$ serialization MyEnumVariantWithParameters(p = ?, q = 3) + // $TEST$ serialization MyEnumVariantWithParameters(p = ?, q = 3) »MyEnum.MyEnumVariantWithParameters()«; - # $TEST$ serialization MyEnumVariantWithParameters(p = 1, q = 3) + // $TEST$ serialization MyEnumVariantWithParameters(p = 1, q = 3) »MyEnum.MyEnumVariantWithParameters(1)«; - # $TEST$ serialization MyEnumVariantWithParameters(p = 1, q = 2) + // $TEST$ serialization MyEnumVariantWithParameters(p = 1, q = 2) »MyEnum.MyEnumVariantWithParameters(1, 2)«; - # $TEST$ serialization MyEnumVariantWithParameters(p = 1, q = 2) + // $TEST$ serialization MyEnumVariantWithParameters(p = 1, q = 2) »MyEnum.MyEnumVariantWithParameters(q = 2, p = 1)«; - # $TEST$ serialization MyEnumVariantWithParameters(p = 1, q = ?) + // $TEST$ serialization MyEnumVariantWithParameters(p = 1, q = ?) »MyEnum.MyEnumVariantWithParameters(1, f())«; - # $TEST$ serialization MyEnumVariantWithParameters(p = 1, q = ?) + // $TEST$ serialization MyEnumVariantWithParameters(p = 1, q = ?) »MyEnum.MyEnumVariantWithParameters(1, f(), 3)«; - # $TEST$ serialization MyEnumVariantWithParameters(p = 1, q = ?) + // $TEST$ serialization MyEnumVariantWithParameters(p = 1, q = ?) »MyEnum.MyEnumVariantWithParameters(1, f(), r = 3)«; - # $TEST$ serialization ? + // $TEST$ serialization ? »MyEnum.MyEnumVariantWithParameters(q = 2, p = 1)()«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of expression lambdas/closure.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of expression lambdas/closure.sdstest index 5b435179..d21009b1 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of expression lambdas/closure.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of expression lambdas/closure.sdstest @@ -5,6 +5,6 @@ segment mySegment(p: Int) -> (closure: () -> (r: Int)) { } pipeline test { - # $TEST$ serialization 1 + // $TEST$ serialization 1 »mySegment(1)()«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of expression lambdas/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of expression lambdas/main.sdstest index f7ef355a..dc73fa86 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of expression lambdas/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of expression lambdas/main.sdstest @@ -3,6 +3,6 @@ package tests.partialValidation.recursiveCases.calls.ofExpressionLambdas pipeline test { val expressionLambda = () -> 1; - # $TEST$ serialization 1 + // $TEST$ serialization 1 »expressionLambda()«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of expression lambdas/previous parameter value used as default value.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of expression lambdas/previous parameter value used as default value.sdstest index 2cc827ac..0a679ab7 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of expression lambdas/previous parameter value used as default value.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of expression lambdas/previous parameter value used as default value.sdstest @@ -3,6 +3,6 @@ package tests.partialValidation.recursiveCases.calls.ofExpressionLambdas.previou pipeline test { val expressionLambda = (p1: Int, p2: Int = p1) -> p2; - # $TEST$ serialization 1 + // $TEST$ serialization 1 »expressionLambda(1)«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of functions/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of functions/main.sdstest index 96b1601c..afb1fb27 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of functions/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of functions/main.sdstest @@ -3,6 +3,6 @@ package tests.partialValidation.recursiveCases.calls.ofFunctions @Pure fun f() pipeline test { - # $TEST$ serialization ? + // $TEST$ serialization ? »f()«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of segments/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of segments/main.sdstest index 20da8842..ee852b01 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of segments/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of segments/main.sdstest @@ -5,6 +5,6 @@ segment mySegment() -> (r: Int, s: Int) { } pipeline test { - # $TEST$ serialization (r = 1, s = ?) + // $TEST$ serialization (r = 1, s = ?) »mySegment()«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of segments/previous parameter value used as default value.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of segments/previous parameter value used as default value.sdstest index edfa2a51..9963635f 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of segments/previous parameter value used as default value.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of segments/previous parameter value used as default value.sdstest @@ -5,6 +5,6 @@ segment mySegment(p1: Int, p2: Int = p1) -> r: Int { } pipeline test { - # $TEST$ serialization 1 + // $TEST$ serialization 1 »mySegment(1)«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of unknown parameter/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of unknown parameter/main.sdstest index 2a20f556..bc6e981f 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of unknown parameter/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of unknown parameter/main.sdstest @@ -1,6 +1,6 @@ package tests.partialValidation.recursiveCases.calls.ofUnknownParameter segment mySegment(p: () -> ()) { - # $TEST$ serialization ? + // $TEST$ serialization ? »p()«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/on null/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/on null/main.sdstest index 97e7d234..d09f45c6 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/on null/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/on null/main.sdstest @@ -1,9 +1,9 @@ package tests.partialValidation.recursiveCases.calls.onNull segment mySegment() { - # $TEST$ serialization ? + // $TEST$ serialization ? »null()«; - # $TEST$ serialization null + // $TEST$ serialization null »null?()«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/recursion/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/recursion/main.sdstest index 5a362728..bd812258 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/recursion/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/recursion/main.sdstest @@ -1,6 +1,6 @@ package tests.partialValidation.recursiveCases.calls.recursion segment mySegment() -> r: Int { - # $TEST$ serialization ? + // $TEST$ serialization ? yield r = »mySegment()«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/unresolved/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/unresolved/main.sdstest index f46df5d2..3fd30caf 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/unresolved/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/unresolved/main.sdstest @@ -5,9 +5,9 @@ enum MyEnum { } pipeline test { - # $TEST$ serialization ? + // $TEST$ serialization ? »unresolved.MyEnumVariant()«; - # $TEST$ serialization ? + // $TEST$ serialization ? »MyEnum.unresolved()«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on lists/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on lists/main.sdstest index 5fe5a058..eceb9abb 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on lists/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on lists/main.sdstest @@ -1,24 +1,24 @@ package tests.partialValidation.recursiveCases.indexedAccess.onLists pipeline test { - # $TEST$ serialization 2 + // $TEST$ serialization 2 »[1, 2, 3][1]«; - # $TEST$ serialization 1 + // $TEST$ serialization 1 »[1, 2, unresolved][0]«; - # $TEST$ serialization ? + // $TEST$ serialization ? »[1, 2, unresolved][2]«; - # $TEST$ serialization ? + // $TEST$ serialization ? »[][-1]«; - # $TEST$ serialization ? + // $TEST$ serialization ? »[][1]«; - # $TEST$ serialization ? + // $TEST$ serialization ? »[][""]«; - # $TEST$ serialization ? + // $TEST$ serialization ? »[][unresolved]«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on maps/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on maps/main.sdstest index c6922b8e..9a2e8d60 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on maps/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on maps/main.sdstest @@ -1,21 +1,21 @@ package tests.partialValidation.recursiveCases.indexedAccess.onMaps pipeline test { - # $TEST$ serialization 1 + // $TEST$ serialization 1 »{"1": 1}["1"]«; - # $TEST$ serialization 2 + // $TEST$ serialization 2 »{"1": 1, "1": 2}["1"]«; // In Python the last matching entry wins, so we need to mimic that behavior - # $TEST$ serialization 2 + // $TEST$ serialization 2 »{"1": 1, "2": 2, "3": unresolved}["2"]«; - # $TEST$ serialization ? + // $TEST$ serialization ? »{"1": 1, "2": 2, "3": unresolved}["3"]«; - # $TEST$ serialization ? + // $TEST$ serialization ? »{}[1]«; - # $TEST$ serialization ? + // $TEST$ serialization ? »{}[unresolved]«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on null/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on null/main.sdstest index 14e1e6b0..e19c2fea 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on null/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on null/main.sdstest @@ -1,9 +1,9 @@ package tests.partialValidation.recursiveCases.indexedAccess.onNull pipeline test { - # $TEST$ serialization ? + // $TEST$ serialization ? »null[0]«; - # $TEST$ serialization null + // $TEST$ serialization null »null?[0]«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on other/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on other/main.sdstest index 34e178a7..599dd967 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on other/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on other/main.sdstest @@ -1,9 +1,9 @@ package tests.partialValidation.recursiveCases.indexedAccess.onOther pipeline test { - # $TEST$ serialization ? + // $TEST$ serialization ? »1[1]«; - # $TEST$ serialization ? + // $TEST$ serialization ? »unresolved[1]«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/and/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/and/main.sdstest index da15394a..f9df8974 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/and/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/and/main.sdstest @@ -1,27 +1,27 @@ package tests.partialValidation.recursiveCases.infixOperations.`and` pipeline test { - # $TEST$ serialization false + // $TEST$ serialization false »false and false«; - # $TEST$ serialization false + // $TEST$ serialization false »false and true«; - # $TEST$ serialization false + // $TEST$ serialization false »true and false«; - # $TEST$ serialization true + // $TEST$ serialization true »true and true«; - # $TEST$ serialization ? + // $TEST$ serialization ? »1 and true«; - # $TEST$ serialization ? + // $TEST$ serialization ? »true and 0«; - # $TEST$ serialization ? + // $TEST$ serialization ? »unresolved and true«; - # $TEST$ serialization ? + // $TEST$ serialization ? »true and unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/and/short circuiting.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/and/short circuiting.sdstest index 21f27bb7..6a17bac2 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/and/short circuiting.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/and/short circuiting.sdstest @@ -10,21 +10,21 @@ fun functionWithoutSideEffects() -> result: Boolean fun functionWithSideEffects() -> result: Boolean pipeline test { - # $TEST$ serialization false + // $TEST$ serialization false »false and pureFunction()«; - # $TEST$ serialization false + // $TEST$ serialization false »false and functionWithoutSideEffects()«; - # $TEST$ serialization false + // $TEST$ serialization false »false and functionWithSideEffects()«; - # $TEST$ serialization ? + // $TEST$ serialization ? »true and pureFunction()«; - # $TEST$ serialization ? + // $TEST$ serialization ? »true and functionWithoutSideEffects()«; - # $TEST$ serialization ? + // $TEST$ serialization ? »true and functionWithSideEffects()«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/divided by/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/divided by/main.sdstest index 7c6db855..c04021c2 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/divided by/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/divided by/main.sdstest @@ -1,38 +1,38 @@ package tests.partialValidation.recursiveCases.infixOperations.dividedBy pipeline test { - # $TEST$ serialization 0.5 + // $TEST$ serialization 0.5 »0.25 / 0.5«; - # $TEST$ serialization 1.5 + // $TEST$ serialization 1.5 »1.5 / 1«; - # $TEST$ serialization 1.6 + // $TEST$ serialization 1.6 »1 / 0.625«; - # $TEST$ serialization 1 + // $TEST$ serialization 1 »1 / 1«; - # $TEST$ serialization ? + // $TEST$ serialization ? »1 / 0«; - # $TEST$ serialization ? + // $TEST$ serialization ? »1 / 0.0«; - # $TEST$ serialization ? + // $TEST$ serialization ? »1 / -0.0«; - # $TEST$ serialization ? + // $TEST$ serialization ? »true / 1«; - # $TEST$ serialization ? + // $TEST$ serialization ? »1 / true«; - # $TEST$ serialization ? + // $TEST$ serialization ? »unresolved / 1«; - # $TEST$ serialization ? + // $TEST$ serialization ? »1 / unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/elvis/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/elvis/main.sdstest index b0eeaf83..1b3d047c 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/elvis/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/elvis/main.sdstest @@ -1,21 +1,21 @@ package tests.partialValidation.recursiveCases.infixOperations.elvis pipeline test { - # $TEST$ serialization true + // $TEST$ serialization true »true ?: false«; - # $TEST$ serialization false + // $TEST$ serialization false »null ?: false«; - # $TEST$ serialization $expressionLambdaClosure + // $TEST$ serialization $expressionLambdaClosure »(() -> 1) ?: false«; - # $TEST$ serialization ? + // $TEST$ serialization ? »(() -> 1) ?: unresolved«; - # $TEST$ serialization ? + // $TEST$ serialization ? »unresolved ?: null«; - # $TEST$ serialization ? + // $TEST$ serialization ? »null ?: unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/elvis/short circuiting.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/elvis/short circuiting.sdstest index 6f9c0249..174cd208 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/elvis/short circuiting.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/elvis/short circuiting.sdstest @@ -10,21 +10,21 @@ fun functionWithoutSideEffects() -> result: Boolean fun functionWithSideEffects() -> result: Boolean pipeline test { - # $TEST$ serialization 1 + // $TEST$ serialization 1 »1 ?: pureFunction()«; - # $TEST$ serialization 1 + // $TEST$ serialization 1 »1 ?: functionWithoutSideEffects()«; - # $TEST$ serialization 1 + // $TEST$ serialization 1 »1 ?: functionWithSideEffects()«; - # $TEST$ serialization ? + // $TEST$ serialization ? »null ?: pureFunction()«; - # $TEST$ serialization ? + // $TEST$ serialization ? »null ?: functionWithoutSideEffects()«; - # $TEST$ serialization ? + // $TEST$ serialization ? »null ?: functionWithSideEffects()«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/equals/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/equals/main.sdstest index 340b013b..177b74c1 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/equals/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/equals/main.sdstest @@ -1,15 +1,15 @@ package tests.partialValidation.recursiveCases.infixOperations.equals pipeline test { - # $TEST$ serialization true + // $TEST$ serialization true »true == true«; - # $TEST$ serialization false + // $TEST$ serialization false »false == 1«; - # $TEST$ serialization ? + // $TEST$ serialization ? »1 == unresolved«; - # $TEST$ serialization ? + // $TEST$ serialization ? »unresolved == 1.25«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/greater than or equals/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/greater than or equals/main.sdstest index 94990a59..5f9e3f6b 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/greater than or equals/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/greater than or equals/main.sdstest @@ -1,41 +1,41 @@ package tests.partialValidation.recursiveCases.infixOperations.greaterThanOrEquals pipeline test { - # $TEST$ serialization true + // $TEST$ serialization true »0.5 >= 0.5«; - # $TEST$ serialization true + // $TEST$ serialization true »1.5 >= 0«; - # $TEST$ serialization true + // $TEST$ serialization true »1 >= 0.5«; - # $TEST$ serialization true + // $TEST$ serialization true »1 >= 0«; - # $TEST$ serialization false + // $TEST$ serialization false »0.5 >= 1.5«; - # $TEST$ serialization false + // $TEST$ serialization false »0.5 >= 1«; - # $TEST$ serialization false + // $TEST$ serialization false »0 >= 1.5«; - # $TEST$ serialization false + // $TEST$ serialization false »0 >= 1«; - # $TEST$ serialization ? + // $TEST$ serialization ? »1 >= true«; - # $TEST$ serialization ? + // $TEST$ serialization ? »false >= 0«; - # $TEST$ serialization ? + // $TEST$ serialization ? »unresolved >= false«; - # $TEST$ serialization ? + // $TEST$ serialization ? »true >= unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/greater than/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/greater than/main.sdstest index 792ad137..de60757f 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/greater than/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/greater than/main.sdstest @@ -1,41 +1,41 @@ package tests.partialValidation.recursiveCases.infixOperations.greaterThan pipeline test { - # $TEST$ serialization true + // $TEST$ serialization true »1.5 > 0.5«; - # $TEST$ serialization true + // $TEST$ serialization true »1.5 > 0«; - # $TEST$ serialization true + // $TEST$ serialization true »1 > 0.5«; - # $TEST$ serialization true + // $TEST$ serialization true »1 > 0«; - # $TEST$ serialization false + // $TEST$ serialization false »0.5 > 1.5«; - # $TEST$ serialization false + // $TEST$ serialization false »0.5 > 1«; - # $TEST$ serialization false + // $TEST$ serialization false »0 > 1.5«; - # $TEST$ serialization false + // $TEST$ serialization false »0 > 1«; - # $TEST$ serialization ? + // $TEST$ serialization ? »1 > true«; - # $TEST$ serialization ? + // $TEST$ serialization ? »false > 0«; - # $TEST$ serialization ? + // $TEST$ serialization ? »unresolved > false«; - # $TEST$ serialization ? + // $TEST$ serialization ? »true > unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/identical to/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/identical to/main.sdstest index 1b781031..9f663404 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/identical to/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/identical to/main.sdstest @@ -1,15 +1,15 @@ package tests.partialValidation.recursiveCases.infixOperations.identicalTo pipeline test { - # $TEST$ serialization true + // $TEST$ serialization true »true === true«; - # $TEST$ serialization false + // $TEST$ serialization false »false === 1«; - # $TEST$ serialization ? + // $TEST$ serialization ? »1 === unresolved«; - # $TEST$ serialization ? + // $TEST$ serialization ? »unresolved === 1.25«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/less than or equals/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/less than or equals/main.sdstest index 95465429..19420212 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/less than or equals/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/less than or equals/main.sdstest @@ -1,41 +1,41 @@ package tests.partialValidation.recursiveCases.infixOperations.lessThanOrEquals pipeline test { - # $TEST$ serialization true + // $TEST$ serialization true »0.5 <= 0.5«; - # $TEST$ serialization true + // $TEST$ serialization true »0.5 <= 1«; - # $TEST$ serialization true + // $TEST$ serialization true »0 <= 1.5«; - # $TEST$ serialization true + // $TEST$ serialization true »0 <= 1«; - # $TEST$ serialization false + // $TEST$ serialization false »1.5 <= 0.5«; - # $TEST$ serialization false + // $TEST$ serialization false »1.5 <= 0«; - # $TEST$ serialization false + // $TEST$ serialization false »1 <= 0.5«; - # $TEST$ serialization false + // $TEST$ serialization false »1 <= 0«; - # $TEST$ serialization ? + // $TEST$ serialization ? »1 <= true«; - # $TEST$ serialization ? + // $TEST$ serialization ? »false <= 0«; - # $TEST$ serialization ? + // $TEST$ serialization ? »unresolved <= false«; - # $TEST$ serialization ? + // $TEST$ serialization ? »true <= unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/less than/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/less than/main.sdstest index b8336325..c368f289 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/less than/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/less than/main.sdstest @@ -1,41 +1,41 @@ package tests.partialValidation.recursiveCases.infixOperations.lessThan pipeline test { - # $TEST$ serialization true + // $TEST$ serialization true »0.5 < 1.5«; - # $TEST$ serialization true + // $TEST$ serialization true »0.5 < 1«; - # $TEST$ serialization true + // $TEST$ serialization true »0 < 1.5«; - # $TEST$ serialization true + // $TEST$ serialization true »0 < 1«; - # $TEST$ serialization false + // $TEST$ serialization false »1.5 < 0.5«; - # $TEST$ serialization false + // $TEST$ serialization false »1.5 < 0«; - # $TEST$ serialization false + // $TEST$ serialization false »1 < 0.5«; - # $TEST$ serialization false + // $TEST$ serialization false »1 < 1«; - # $TEST$ serialization ? + // $TEST$ serialization ? »1 < true«; - # $TEST$ serialization ? + // $TEST$ serialization ? »false < 0«; - # $TEST$ serialization ? + // $TEST$ serialization ? »unresolved < false«; - # $TEST$ serialization ? + // $TEST$ serialization ? »true < unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/minus/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/minus/main.sdstest index f2c0f413..1ab3020d 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/minus/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/minus/main.sdstest @@ -1,28 +1,28 @@ package tests.partialValidation.recursiveCases.infixOperations.minus pipeline test { - # $TEST$ serialization 1.25 + // $TEST$ serialization 1.25 »1.5 - 0.25«; - # $TEST$ serialization 0.5 + // $TEST$ serialization 0.5 »1.5 - 1«; - # $TEST$ serialization 0.75 + // $TEST$ serialization 0.75 »1 - 0.25«; - # $TEST$ serialization 0 + // $TEST$ serialization 0 »1 - 1«; - # $TEST$ serialization ? + // $TEST$ serialization ? »true - 1«; - # $TEST$ serialization ? + // $TEST$ serialization ? »1 - true«; - # $TEST$ serialization ? + // $TEST$ serialization ? »unresolved - 1«; - # $TEST$ serialization ? + // $TEST$ serialization ? »1 - unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/not equals/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/not equals/main.sdstest index 7cb3534d..539dbf17 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/not equals/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/not equals/main.sdstest @@ -1,15 +1,15 @@ package tests.partialValidation.recursiveCases.infixOperations.notEquals pipeline test { - # $TEST$ serialization false + // $TEST$ serialization false »true != true«; - # $TEST$ serialization true + // $TEST$ serialization true »false != 1«; - # $TEST$ serialization ? + // $TEST$ serialization ? »1 != unresolved«; - # $TEST$ serialization ? + // $TEST$ serialization ? »unresolved != 1.25«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/not identical to/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/not identical to/main.sdstest index 6ba3ca08..32e217d9 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/not identical to/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/not identical to/main.sdstest @@ -1,15 +1,15 @@ package tests.partialValidation.recursiveCases.infixOperations.notIdenticalTo pipeline test { - # $TEST$ serialization false + // $TEST$ serialization false »true !== true«; - # $TEST$ serialization true + // $TEST$ serialization true »false !== 1«; - # $TEST$ serialization ? + // $TEST$ serialization ? »1 !== unresolved«; - # $TEST$ serialization ? + // $TEST$ serialization ? »unresolved !== 1.25«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/or/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/or/main.sdstest index 6057836b..5df518f9 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/or/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/or/main.sdstest @@ -1,27 +1,27 @@ package tests.partialValidation.recursiveCases.infixOperations.`or` pipeline test { - # $TEST$ serialization false + // $TEST$ serialization false »false or false«; - # $TEST$ serialization true + // $TEST$ serialization true »false or true«; - # $TEST$ serialization true + // $TEST$ serialization true »true or false«; - # $TEST$ serialization true + // $TEST$ serialization true »true or true«; - # $TEST$ serialization ? + // $TEST$ serialization ? »1 or false«; - # $TEST$ serialization ? + // $TEST$ serialization ? »false or 0«; - # $TEST$ serialization ? + // $TEST$ serialization ? »unresolved or false«; - # $TEST$ serialization ? + // $TEST$ serialization ? »false or unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/or/short circuiting.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/or/short circuiting.sdstest index e10600a3..0fa82fc0 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/or/short circuiting.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/or/short circuiting.sdstest @@ -10,21 +10,21 @@ fun functionWithoutSideEffects() -> result: Boolean fun functionWithSideEffects() -> result: Boolean pipeline test { - # $TEST$ serialization true + // $TEST$ serialization true »true or pureFunction()«; - # $TEST$ serialization true + // $TEST$ serialization true »true or functionWithoutSideEffects()«; - # $TEST$ serialization true + // $TEST$ serialization true »true or functionWithSideEffects()«; - # $TEST$ serialization ? + // $TEST$ serialization ? »false or pureFunction()«; - # $TEST$ serialization ? + // $TEST$ serialization ? »false or functionWithoutSideEffects()«; - # $TEST$ serialization ? + // $TEST$ serialization ? »false or functionWithSideEffects()«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/plus/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/plus/main.sdstest index 4ae3e069..0d5b0e7f 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/plus/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/plus/main.sdstest @@ -1,28 +1,28 @@ package tests.partialValidation.recursiveCases.infixOperations.plus pipeline test { - # $TEST$ serialization 1.75 + // $TEST$ serialization 1.75 »1.5 + 0.25«; - # $TEST$ serialization 2.5 + // $TEST$ serialization 2.5 »1.5 + 1«; - # $TEST$ serialization 1.25 + // $TEST$ serialization 1.25 »1 + 0.25«; - # $TEST$ serialization 2 + // $TEST$ serialization 2 »1 + 1«; - # $TEST$ serialization ? + // $TEST$ serialization ? »true + 1«; - # $TEST$ serialization ? + // $TEST$ serialization ? »1 + true«; - # $TEST$ serialization ? + // $TEST$ serialization ? »unresolved + 1«; - # $TEST$ serialization ? + // $TEST$ serialization ? »1 + unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/times/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/times/main.sdstest index 77294793..1bcac13f 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/times/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/times/main.sdstest @@ -1,28 +1,28 @@ package tests.partialValidation.recursiveCases.infixOperations.times pipeline test { - # $TEST$ serialization 0.75 + // $TEST$ serialization 0.75 »1.5 * 0.5«; - # $TEST$ serialization 1.5 + // $TEST$ serialization 1.5 »1.5 * 1«; - # $TEST$ serialization 0.25 + // $TEST$ serialization 0.25 »1 * 0.25«; - # $TEST$ serialization 1 + // $TEST$ serialization 1 »1 * 1«; - # $TEST$ serialization ? + // $TEST$ serialization ? »true * 1«; - # $TEST$ serialization ? + // $TEST$ serialization ? »1 * true«; - # $TEST$ serialization ? + // $TEST$ serialization ? »unresolved * 1«; - # $TEST$ serialization ? + // $TEST$ serialization ? »1 * unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/lists/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/lists/main.sdstest index c1b7ea16..eb3bf454 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/lists/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/lists/main.sdstest @@ -1,9 +1,9 @@ package tests.partialValidation.recursiveCases.lists pipeline test { - # $TEST$ serialization [] + // $TEST$ serialization [] »[]«; - # $TEST$ serialization [1, 2.5, null, ?] + // $TEST$ serialization [1, 2.5, null, ?] »[1, 2.5, null, unresolved]«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/maps/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/maps/main.sdstest index dad0445b..25c0ef45 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/maps/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/maps/main.sdstest @@ -1,10 +1,10 @@ package tests.partialValidation.recursiveCases.maps pipeline test { - # $TEST$ serialization {} + // $TEST$ serialization {} »{}«; - # $TEST$ serialization {"a": 1, "b": 2.5, "c": null, "d": ?, ?: true} + // $TEST$ serialization {"a": 1, "b": 2.5, "c": null, "d": ?, ?: true} »{ "a": 1, "b": 2.5, diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/of call results/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/of call results/main.sdstest index 1802b2c4..28a065d8 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/of call results/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/of call results/main.sdstest @@ -11,21 +11,21 @@ pipeline test { yield s = q; }; - # $TEST$ serialization 1 + // $TEST$ serialization 1 »mySegment(1).r«; - # $TEST$ serialization 2 + // $TEST$ serialization 2 »mySegment(1).s«; - # $TEST$ serialization ? + // $TEST$ serialization ? »mySegment(1).unresolved«; - # $TEST$ serialization 1 + // $TEST$ serialization 1 »blockLambda(1).r«; - # $TEST$ serialization 2 + // $TEST$ serialization 2 »blockLambda(1).s«; - # $TEST$ serialization ? + // $TEST$ serialization ? »blockLambda(1).unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/of enum variant parameters/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/of enum variant parameters/main.sdstest index ca4da19d..d99bebee 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/of enum variant parameters/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/of enum variant parameters/main.sdstest @@ -5,12 +5,12 @@ enum MyEnum { } pipeline test { - # $TEST$ serialization 1 + // $TEST$ serialization 1 »MyEnum.MyEnumVariantWithParameters(1).p«; - # $TEST$ serialization 2 + // $TEST$ serialization 2 »MyEnum.MyEnumVariantWithParameters(1).q«; - # $TEST$ serialization ? + // $TEST$ serialization ? »MyEnum.MyEnumVariantWithParameters(1).unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/of enum variants/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/of enum variants/main.sdstest index efac984c..e95c58d3 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/of enum variants/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/of enum variants/main.sdstest @@ -6,9 +6,9 @@ enum MyEnum { } pipeline test { - # $TEST$ serialization MyEnumVariantWithoutParameters + // $TEST$ serialization MyEnumVariantWithoutParameters »MyEnum.MyEnumVariantWithoutParameters«; - # $TEST$ serialization MyEnumVariantWithParameters + // $TEST$ serialization MyEnumVariantWithParameters »MyEnum.MyEnumVariantWithParameters«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/on null/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/on null/main.sdstest index f4e4bc84..85aa824e 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/on null/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/on null/main.sdstest @@ -1,9 +1,9 @@ package tests.partialValidation.recursiveCases.memberAccesses.onNull pipeline test { - # $TEST$ serialization ? + // $TEST$ serialization ? »null.toString«; - # $TEST$ serialization null + // $TEST$ serialization null »null?.toString«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/on other receivers/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/on other receivers/main.sdstest index 596704d9..583ff6fc 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/on other receivers/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/on other receivers/main.sdstest @@ -3,6 +3,6 @@ package tests.partialValidation.recursiveCases.memberAccesses.onOtherReceivers @Pure fun f() -> result: Int pipeline test { - # $TEST$ serialization ? + // $TEST$ serialization ? »f().result«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/unresolved/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/unresolved/main.sdstest index a9dcfe51..c5bf09ca 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/unresolved/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/unresolved/main.sdstest @@ -5,9 +5,9 @@ enum MyEnum { } pipeline test { - # $TEST$ serialization ? + // $TEST$ serialization ? »unresolved.MyEnumVariant«; - # $TEST$ serialization ? + // $TEST$ serialization ? »MyEnum.unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/parameters/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/parameters/main.sdstest index 957a35cd..0604d585 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/parameters/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/parameters/main.sdstest @@ -11,12 +11,12 @@ pipeline myPipeline { val expressionLambda = (p: Int) -> p; - # $TEST$ serialization 1 + // $TEST$ serialization 1 »mySegment(1)«; - # $TEST$ serialization 1 + // $TEST$ serialization 1 »blockLambda(1)«; - # $TEST$ serialization 1 + // $TEST$ serialization 1 »expressionLambda(1)«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/parenthesized expressions/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/parenthesized expressions/main.sdstest index 9e722e9c..81abee4d 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/parenthesized expressions/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/parenthesized expressions/main.sdstest @@ -1,11 +1,11 @@ package tests.partialValidation.recursiveCases.parenthesizedExpression pipeline test { - # $TEST$ equivalence_class value1 - # $TEST$ equivalence_class value1 + // $TEST$ equivalence_class value1 + // $TEST$ equivalence_class value1 »(»1«)«; - # $TEST$ equivalence_class value2 - # $TEST$ equivalence_class value2 + // $TEST$ equivalence_class value2 + // $TEST$ equivalence_class value2 »(»null«)«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/prefix operations/minus/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/prefix operations/minus/main.sdstest index 2bbbf1dc..e9bfcc35 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/prefix operations/minus/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/prefix operations/minus/main.sdstest @@ -1,15 +1,15 @@ package tests.partialValidation.recursiveCases.prefixOperations.minus pipeline test { - # $TEST$ serialization -1.5 + // $TEST$ serialization -1.5 »-1.5«; - # $TEST$ serialization -1 + // $TEST$ serialization -1 »-1«; - # $TEST$ serialization ? + // $TEST$ serialization ? »-true«; - # $TEST$ serialization ? + // $TEST$ serialization ? »-unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/prefix operations/not/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/prefix operations/not/main.sdstest index 1d7b07df..84c8e97a 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/prefix operations/not/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/prefix operations/not/main.sdstest @@ -1,15 +1,15 @@ package tests.partialValidation.recursiveCases.prefixOperations.`not` pipeline test { - # $TEST$ serialization true + // $TEST$ serialization true »not false«; - # $TEST$ serialization false + // $TEST$ serialization false »not true«; - # $TEST$ serialization ? + // $TEST$ serialization ? »not 0«; - # $TEST$ serialization ? + // $TEST$ serialization ? »not unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/references/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/references/main.sdstest index d775d6c2..f19cb14c 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/references/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/references/main.sdstest @@ -3,8 +3,8 @@ package tests.partialEvaluation.recursiveCases.assignees.references pipeline myPipeline { val a = 1; - # $TEST$ serialization 1 + // $TEST$ serialization 1 »a«; - # $TEST$ serialization ? + // $TEST$ serialization ? »unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/results/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/results/main.sdstest index 7dbe1e10..4b97763c 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/results/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/results/main.sdstest @@ -1,8 +1,8 @@ package tests.partialEvaluation.recursiveCases.assignees.results -# $TEST$ serialization ? -# $TEST$ serialization 1 -# $TEST$ serialization 2 +// $TEST$ serialization ? +// $TEST$ serialization 1 +// $TEST$ serialization 2 segment mySegment() -> (»a: Int«, »b: Int«, »c: Int«) { yield b = 1; diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/template strings/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/template strings/main.sdstest index 41407460..df5ab080 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/template strings/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/template strings/main.sdstest @@ -1,12 +1,12 @@ package tests.partialValidation.recursiveCases.templateStrings pipeline test { - # $TEST$ serialization "start 1 inner1 true inner2 test end" + // $TEST$ serialization "start 1 inner1 true inner2 test end" »"start {{ 1 }} inner1 {{ true }} inner2 {{ "test" }} end"«; - # $TEST$ serialization "start\\t1 inner1\\ttrue inner2\\ttest end\\t" + // $TEST$ serialization "start\\t1 inner1\\ttrue inner2\\ttest end\\t" »"start\t{{ 1 }} inner1\t{{ true }} inner2\t{{ "test" }} end\t"«; - # $TEST$ serialization ? + // $TEST$ serialization ? »"start {{ call() }} end"«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/type casts/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/type casts/main.sdstest index ea646121..5d61c482 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/type casts/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/type casts/main.sdstest @@ -1,9 +1,9 @@ package tests.partialValidation.recursiveCases.typeCasts pipeline test { - # $TEST$ serialization true + // $TEST$ serialization true »true as Boolean«; - # $TEST$ serialization 1 + // $TEST$ serialization 1 »1 as Boolean«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main no imports or own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main no imports or own declarations.sdstest index 42adc11b..bd7c452c 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main no imports or own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main no imports or own declarations.sdstest @@ -1,17 +1,17 @@ package tests.scoping.annotationCalls.acrossFiles -# $TEST$ references same_MyAnnotation +// $TEST$ references same_MyAnnotation @»MyAnnotation« -# $TEST$ references same_AnnotationInSamePackage +// $TEST$ references same_AnnotationInSamePackage @»AnnotationInSamePackage« -# $TEST$ references safeds_AnnotationInSafeDsPackage +// $TEST$ references safeds_AnnotationInSafeDsPackage @»AnnotationInSafeDsPackage« -# $TEST$ unresolved +// $TEST$ unresolved @»AnnotationInAnotherPackage« -# $TEST$ unresolved +// $TEST$ unresolved @»AnnotationWithoutPackage« pipeline myPipeline {} diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with imports and own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with imports and own declarations.sdstest index afb59e0b..26ce5d2b 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with imports and own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with imports and own declarations.sdstest @@ -3,24 +3,24 @@ package tests.scoping.annotationCalls.acrossFiles from safeds.scoping.annotationCalls.acrossFiles import MyAnnotation as MyOwnAnnotation from tests.scoping.annotationCalls.acrossFiles.other import AnnotationInAnotherPackage, Annotation2InAnotherPackage -# $TEST$ target own_MyOwnAnnotation +// $TEST$ target own_MyOwnAnnotation annotation »MyOwnAnnotation« -# $TEST$ references own_MyOwnAnnotation +// $TEST$ references own_MyOwnAnnotation @»MyOwnAnnotation« -# $TEST$ references same_AnnotationInSamePackage +// $TEST$ references same_AnnotationInSamePackage @»AnnotationInSamePackage« -# $TEST$ references safeds_AnnotationInSafeDsPackage +// $TEST$ references safeds_AnnotationInSafeDsPackage @»AnnotationInSafeDsPackage« -# $TEST$ references other_AnnotationInAnotherPackage +// $TEST$ references other_AnnotationInAnotherPackage @»AnnotationInAnotherPackage« -# $TEST$ references other_Annotation2InAnotherPackage +// $TEST$ references other_Annotation2InAnotherPackage @»Annotation2InAnotherPackage« -# $TEST$ unresolved +// $TEST$ unresolved @»AnnotationWithoutPackage« pipeline myPipeline {} diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with multiple imports of same name.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with multiple imports of same name.sdstest index bb4199dc..6a480c88 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with multiple imports of same name.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with multiple imports of same name.sdstest @@ -5,6 +5,6 @@ from tests.scoping.annotationCalls.acrossFiles.other import MyAnnotation from tests.scoping.annotationCalls.acrossFiles import MyAnnotation pipeline myPipeline { - # $TEST$ references safeds_MyAnnotation + // $TEST$ references safeds_MyAnnotation »MyAnnotation«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with qualified import with alias.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with qualified import with alias.sdstest index eace4460..1d3e552f 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with qualified import with alias.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with qualified import with alias.sdstest @@ -4,28 +4,28 @@ from tests.scoping.annotationCalls.acrossFiles import MyAnnotation as MyAnnotati from safeds.scoping.annotationCalls.acrossFiles import MyAnnotation as MyAnnotationInSafeDsPackage from tests.scoping.annotationCalls.acrossFiles.other import MyAnnotation as MyAnnotationInAnotherPackage -# $TEST$ references same_MyAnnotation +// $TEST$ references same_MyAnnotation @»MyAnnotation« -# $TEST$ references same_AnnotationInSamePackage +// $TEST$ references same_AnnotationInSamePackage @»AnnotationInSamePackage« -# $TEST$ references safeds_AnnotationInSafeDsPackage +// $TEST$ references safeds_AnnotationInSafeDsPackage @»AnnotationInSafeDsPackage« -# $TEST$ unresolved +// $TEST$ unresolved @»AnnotationInAnotherPackage« -# $TEST$ unresolved +// $TEST$ unresolved @»AnnotationWithoutPackage« -# $TEST$ references same_MyAnnotation +// $TEST$ references same_MyAnnotation @»MyAnnotationInSamePackage« -# $TEST$ references safeds_MyAnnotation +// $TEST$ references safeds_MyAnnotation @»MyAnnotationInSafeDsPackage« -# $TEST$ references other_MyAnnotation +// $TEST$ references other_MyAnnotation @»MyAnnotationInAnotherPackage« pipeline myPipeline {} diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with qualified import.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with qualified import.sdstest index add5f8e7..d6c494b7 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with qualified import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with qualified import.sdstest @@ -3,24 +3,24 @@ package tests.scoping.annotationCalls.acrossFiles from safeds.scoping.annotationCalls.acrossFiles import MyAnnotation from tests.scoping.annotationCalls.acrossFiles.other import AnnotationInAnotherPackage, Annotation2InAnotherPackage, NotAnAnnotation -# $TEST$ references safeds_MyAnnotation +// $TEST$ references safeds_MyAnnotation @»MyAnnotation« -# $TEST$ references same_AnnotationInSamePackage +// $TEST$ references same_AnnotationInSamePackage @»AnnotationInSamePackage« -# $TEST$ references safeds_AnnotationInSafeDsPackage +// $TEST$ references safeds_AnnotationInSafeDsPackage @»AnnotationInSafeDsPackage« -# $TEST$ references other_AnnotationInAnotherPackage +// $TEST$ references other_AnnotationInAnotherPackage @»AnnotationInAnotherPackage« -# $TEST$ references other_Annotation2InAnotherPackage +// $TEST$ references other_Annotation2InAnotherPackage @»Annotation2InAnotherPackage« -# $TEST$ unresolved +// $TEST$ unresolved @»NotAnAnnotation« -# $TEST$ unresolved +// $TEST$ unresolved @»AnnotationWithoutPackage« pipeline myPipeline {} diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with wildcard import.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with wildcard import.sdstest index 8e15e691..a1e2db9b 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with wildcard import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with wildcard import.sdstest @@ -2,18 +2,18 @@ package tests.scoping.annotationCalls.acrossFiles from safeds.scoping.annotationCalls.acrossFiles import * -# $TEST$ references safeds_MyAnnotation +// $TEST$ references safeds_MyAnnotation @»MyAnnotation« -# $TEST$ references same_AnnotationInSamePackage +// $TEST$ references same_AnnotationInSamePackage @»AnnotationInSamePackage« -# $TEST$ references safeds_AnnotationInSafeDsPackage +// $TEST$ references safeds_AnnotationInSafeDsPackage @»AnnotationInSafeDsPackage« -# $TEST$ unresolved +// $TEST$ unresolved @»AnnotationInAnotherPackage« -# $TEST$ unresolved +// $TEST$ unresolved @»AnnotationWithoutPackage« pipeline myPipeline {} diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/resource other package.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/resource other package.sdstest index 52b2263d..ca30cdcb 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/resource other package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/resource other package.sdstest @@ -1,13 +1,13 @@ package tests.scoping.annotationCalls.acrossFiles.other -# $TEST$ target other_MyAnnotation +// $TEST$ target other_MyAnnotation annotation »MyAnnotation« -# $TEST$ target other_AnnotationInAnotherPackage +// $TEST$ target other_AnnotationInAnotherPackage annotation »AnnotationInAnotherPackage« -# $TEST$ target other_Annotation2InAnotherPackage +// $TEST$ target other_Annotation2InAnotherPackage annotation »Annotation2InAnotherPackage« -# $TEST$ target other_NotAnAnnotation +// $TEST$ target other_NotAnAnnotation class »NotAnAnnotation« diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/resource safeds package.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/resource safeds package.sdstest index 2605ac41..ec8a3f21 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/resource safeds package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/resource safeds package.sdstest @@ -1,7 +1,7 @@ package safeds.scoping.annotationCalls.acrossFiles -# $TEST$ target safeds_MyAnnotation +// $TEST$ target safeds_MyAnnotation annotation »MyAnnotation« -# $TEST$ target safeds_AnnotationInSafeDsPackage +// $TEST$ target safeds_AnnotationInSafeDsPackage annotation »AnnotationInSafeDsPackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/resource same package.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/resource same package.sdstest index 9854b24a..1bb35a8b 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/resource same package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/resource same package.sdstest @@ -1,7 +1,7 @@ package tests.scoping.annotationCalls.acrossFiles -# $TEST$ target same_MyAnnotation +// $TEST$ target same_MyAnnotation annotation »MyAnnotation« -# $TEST$ target same_AnnotationInSamePackage +// $TEST$ target same_AnnotationInSamePackage annotation »AnnotationInSamePackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/resource without package.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/resource without package.sdstest index c4c3bc48..39a33d04 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/resource without package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/resource without package.sdstest @@ -1,5 +1,5 @@ -# $TEST$ target without_MyAnnotation +// $TEST$ target without_MyAnnotation annotation »MyAnnotation« -# $TEST$ target without_AnnotationWithoutPackage +// $TEST$ target without_AnnotationWithoutPackage annotation »AnnotationWithoutPackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on annotation/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on annotation/main.sdstest index 64f9c08c..80a2dca1 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on annotation/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on annotation/main.sdstest @@ -1,19 +1,19 @@ package tests.scoping.annotationCalls.onAnnotation -# $TEST$ target before +// $TEST$ target before annotation »Before« -# $TEST$ references before +// $TEST$ references before @»Before« -# $TEST$ references after +// $TEST$ references after @»After« -# $TEST$ unresolved +// $TEST$ unresolved @»NotAnAnnotation« -# $TEST$ unresolved +// $TEST$ unresolved @»Unresolved« annotation MyAnnotation -# $TEST$ target after +// $TEST$ target after annotation »After« class NotAnAnnotation diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on attribute/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on attribute/main.sdstest index 31eda997..125e7d75 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on attribute/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on attribute/main.sdstest @@ -1,21 +1,21 @@ package tests.scoping.annotationCalls.onAttribute -# $TEST$ target before +// $TEST$ target before annotation »Before« class MyClass { - # $TEST$ references before + // $TEST$ references before @»Before« - # $TEST$ references after + // $TEST$ references after @»After« - # $TEST$ unresolved + // $TEST$ unresolved @»NotAnAnnotation« - # $TEST$ unresolved + // $TEST$ unresolved @»Unresolved« attr myAttribute: Int } -# $TEST$ target after +// $TEST$ target after annotation »After« class NotAnAnnotation diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on class/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on class/main.sdstest index 4e12ad3a..ec43aa3c 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on class/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on class/main.sdstest @@ -1,19 +1,19 @@ package tests.scoping.annotationCalls.onClass -# $TEST$ target before +// $TEST$ target before annotation »Before« -# $TEST$ references before +// $TEST$ references before @»Before« -# $TEST$ references after +// $TEST$ references after @»After« -# $TEST$ unresolved +// $TEST$ unresolved @»NotAnAnnotation« -# $TEST$ unresolved +// $TEST$ unresolved @»Unresolved« class MyClass -# $TEST$ target after +// $TEST$ target after annotation »After« class NotAnAnnotation diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on enum variant/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on enum variant/main.sdstest index dfcb4aee..1253875f 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on enum variant/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on enum variant/main.sdstest @@ -1,21 +1,21 @@ package tests.scoping.annotationCalls.onEnumVariant -# $TEST$ target before +// $TEST$ target before annotation »Before« enum MyEnum { - # $TEST$ references before + // $TEST$ references before @»Before« - # $TEST$ references after + // $TEST$ references after @»After« - # $TEST$ unresolved + // $TEST$ unresolved @»NotAnAnnotation« - # $TEST$ unresolved + // $TEST$ unresolved @»Unresolved« MyEnumVariant } -# $TEST$ target after +// $TEST$ target after annotation »After« class NotAnAnnotation diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on enum/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on enum/main.sdstest index 25e03d30..161aaa07 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on enum/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on enum/main.sdstest @@ -1,19 +1,19 @@ package tests.scoping.annotationCalls.onEnum -# $TEST$ target before +// $TEST$ target before annotation »Before« -# $TEST$ references before +// $TEST$ references before @»Before« -# $TEST$ references after +// $TEST$ references after @»After« -# $TEST$ unresolved +// $TEST$ unresolved @»NotAnAnnotation« -# $TEST$ unresolved +// $TEST$ unresolved @»Unresolved« enum MyEnum -# $TEST$ target after +// $TEST$ target after annotation »After« class NotAnAnnotation diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on function/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on function/main.sdstest index 34d8a0d0..81bdfa2d 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on function/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on function/main.sdstest @@ -1,19 +1,19 @@ package tests.scoping.annotationCalls.onFunction -# $TEST$ target before +// $TEST$ target before annotation »Before« -# $TEST$ references before +// $TEST$ references before @»Before« -# $TEST$ references after +// $TEST$ references after @»After« -# $TEST$ unresolved +// $TEST$ unresolved @»NotAnAnnotation« -# $TEST$ unresolved +// $TEST$ unresolved @»Unresolved« fun myFunction() -# $TEST$ target after +// $TEST$ target after annotation »After« class NotAnAnnotation diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on module/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on module/main.sdstest index 6c06279d..54d5f865 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on module/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on module/main.sdstest @@ -1,13 +1,13 @@ -# $TEST$ references annotation +// $TEST$ references annotation @»MyAnnotation« -# $TEST$ unresolved +// $TEST$ unresolved @»NotAnAnnotation« -# $TEST$ unresolved +// $TEST$ unresolved @»Unresolved« package tests.scoping.annotationCalls.onModule -# $TEST$ target annotation +// $TEST$ target annotation annotation »MyAnnotation« class NotAnAnnotation diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on parameter/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on parameter/main.sdstest index e37541c2..2fbdde2c 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on parameter/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on parameter/main.sdstest @@ -1,16 +1,16 @@ package tests.scoping.annotationCalls.onParameter -# $TEST$ target before +// $TEST$ target before annotation »Before« fun myFunction( - # $TEST$ references before + // $TEST$ references before @»Before« - # $TEST$ references after + // $TEST$ references after @»After« - # $TEST$ unresolved + // $TEST$ unresolved @»NotAnAnnotation« - # $TEST$ unresolved + // $TEST$ unresolved @»Unresolved« myParameter: Int ) @@ -18,14 +18,14 @@ fun myFunction( pipeline myPipeline { val alias = Before; - # $TEST$ unresolved + // $TEST$ unresolved (@»alias« myParameter) {}; - # $TEST$ unresolved + // $TEST$ unresolved (@»alias« myParameter) -> 1; } -# $TEST$ target after +// $TEST$ target after annotation »After« class NotAnAnnotation diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on pipeline/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on pipeline/main.sdstest index 50ca055f..c57cae47 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on pipeline/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on pipeline/main.sdstest @@ -1,19 +1,19 @@ package tests.scoping.annotationCalls.onPipeline -# $TEST$ target before +// $TEST$ target before annotation »Before« -# $TEST$ references before +// $TEST$ references before @»Before« -# $TEST$ references after +// $TEST$ references after @»After« -# $TEST$ unresolved +// $TEST$ unresolved @»NotAnAnnotation« -# $TEST$ unresolved +// $TEST$ unresolved @»Unresolved« pipeline myPipeline {} -# $TEST$ target after +// $TEST$ target after annotation »After« class NotAnAnnotation diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on result/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on result/main.sdstest index 9aa81f3d..c34ac239 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on result/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on result/main.sdstest @@ -1,21 +1,21 @@ package tests.scoping.annotationCalls.onResult -# $TEST$ target before +// $TEST$ target before annotation »Before« fun myFunction() -> ( - # $TEST$ references before + // $TEST$ references before @»Before« - # $TEST$ references after + // $TEST$ references after @»After« - # $TEST$ unresolved + // $TEST$ unresolved @»NotAnAnnotation« - # $TEST$ unresolved + // $TEST$ unresolved @»Unresolved« myResult: Int ) -# $TEST$ target after +// $TEST$ target after annotation »After« class NotAnAnnotation diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on segment/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on segment/main.sdstest index dc296e02..db7a052a 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on segment/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on segment/main.sdstest @@ -1,19 +1,19 @@ package tests.scoping.annotationCalls.onSegment -# $TEST$ target before +// $TEST$ target before annotation »Before« -# $TEST$ references before +// $TEST$ references before @»Before« -# $TEST$ references after +// $TEST$ references after @»After« -# $TEST$ unresolved +// $TEST$ unresolved @»NotAnAnnotation« -# $TEST$ unresolved +// $TEST$ unresolved @»Unresolved« segment mySegment() {} -# $TEST$ target after +// $TEST$ target after annotation »After« class NotAnAnnotation diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on type parameter/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on type parameter/main.sdstest index 6080fcd4..fe990af1 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on type parameter/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on type parameter/main.sdstest @@ -1,21 +1,21 @@ package tests.scoping.annotationCalls.onTypeParameter -# $TEST$ target before +// $TEST$ target before annotation »Before« fun myFunction< - # $TEST$ references before + // $TEST$ references before @»Before« - # $TEST$ references after + // $TEST$ references after @»After« - # $TEST$ unresolved + // $TEST$ unresolved @»NotAnAnnotation« - # $TEST$ unresolved + // $TEST$ unresolved @»Unresolved« MyTypeParameter >() -# $TEST$ target after +// $TEST$ target after annotation »After« class NotAnAnnotation diff --git a/packages/ttsl-lang/tests/resources/scoping/arguments/of annotation calls/to parameter/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/arguments/of annotation calls/to parameter/main.sdstest index 974fcb0d..f718a1e6 100644 --- a/packages/ttsl-lang/tests/resources/scoping/arguments/of annotation calls/to parameter/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/arguments/of annotation calls/to parameter/main.sdstest @@ -1,20 +1,20 @@ package tests.scoping.arguments.ofAnnotationCalls.toParameter annotation MyAnnotation( - # $TEST$ target a + // $TEST$ target a »a«: Int, - # $TEST$ target b + // $TEST$ target b »b«: Int = 0, - # $TEST$ target c + // $TEST$ target c »c«: Int ) @MyAnnotation( - # $TEST$ references c + // $TEST$ references c »c« = 0, - # $TEST$ references a + // $TEST$ references a »a« = 0, - # $TEST$ references b + // $TEST$ references b »b« = 0 ) pipeline myPipeline {} diff --git a/packages/ttsl-lang/tests/resources/scoping/arguments/of annotation calls/to something other than parameter/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/arguments/of annotation calls/to something other than parameter/main.sdstest index 56c9c3e0..a0edd6f0 100644 --- a/packages/ttsl-lang/tests/resources/scoping/arguments/of annotation calls/to something other than parameter/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/arguments/of annotation calls/to something other than parameter/main.sdstest @@ -3,7 +3,7 @@ package tests.scoping.arguments.ofAnnotationCalls.toSomethingOtherThanParameter annotation MyAnnotation(a: Int) @MyAnnotation( - # $TEST$ unresolved + // $TEST$ unresolved »MyAnnotation« = 0, ) pipeline myPipeline {} diff --git a/packages/ttsl-lang/tests/resources/scoping/arguments/of annotation calls/unresolved/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/arguments/of annotation calls/unresolved/main.sdstest index 6be88d00..d391846e 100644 --- a/packages/ttsl-lang/tests/resources/scoping/arguments/of annotation calls/unresolved/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/arguments/of annotation calls/unresolved/main.sdstest @@ -3,11 +3,11 @@ package tests.scoping.arguments.ofAnnotationCalls.unresolved annotation MyAnnotation(a: Int) @MyAnnotation( - # $TEST$ unresolved + // $TEST$ unresolved »unresolved« = 0, ) @Unresolved( - # $TEST$ unresolved + // $TEST$ unresolved »a« = 0 ) pipeline myPipeline {} diff --git a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of annotation/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of annotation/main.sdstest index 5ef68672..97bfa9ed 100644 --- a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of annotation/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of annotation/main.sdstest @@ -1,31 +1,31 @@ package tests.scoping.arguments.ofCalls.toParameterOfAnnotation annotation MyAnnotation( - # $TEST$ target a + // $TEST$ target a »a«: Int, - # $TEST$ target b + // $TEST$ target b »b«: Int = 0, - # $TEST$ target c + // $TEST$ target c »c«: Int ) pipeline myPipeline { MyAnnotation( - # $TEST$ references c + // $TEST$ references c »c« = 0, - # $TEST$ references a + // $TEST$ references a »a« = 0, - # $TEST$ references b + // $TEST$ references b »b« = 0 ); val alias = MyAnnotation; alias( - # $TEST$ references c + // $TEST$ references c »c« = 0, - # $TEST$ references a + // $TEST$ references a »a« = 0, - # $TEST$ references b + // $TEST$ references b »b« = 0 ); } diff --git a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of block lambda/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of block lambda/main.sdstest index 22138415..0d1c6bf4 100644 --- a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of block lambda/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of block lambda/main.sdstest @@ -2,20 +2,20 @@ package tests.scoping.arguments.ofCalls.toParameterOfBlockLambda pipeline myPipeline { val myBlockLambda = ( - # $TEST$ target a + // $TEST$ target a »a«: Int, - # $TEST$ target b + // $TEST$ target b »b«: Int = 0, - # $TEST$ target c + // $TEST$ target c »c«: Int ) {}; myBlockLambda( - # $TEST$ references c + // $TEST$ references c »c« = 0, - # $TEST$ references a + // $TEST$ references a »a« = 0, - # $TEST$ references b + // $TEST$ references b »b« = 0 ); } diff --git a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of callable type/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of callable type/main.sdstest index 8a9d16d6..68626933 100644 --- a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of callable type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of callable type/main.sdstest @@ -1,29 +1,29 @@ package tests.scoping.arguments.ofCalls.toParameterOfCallableType segment mySegment(myCallableType: ( - # $TEST$ target a + // $TEST$ target a »a«: Int, - # $TEST$ target b + // $TEST$ target b »b«: Int = 0, - # $TEST$ target c + // $TEST$ target c »c«: Int ) -> ()) { myCallableType( - # $TEST$ references c + // $TEST$ references c »c« = 0, - # $TEST$ references a + // $TEST$ references a »a« = 0, - # $TEST$ references b + // $TEST$ references b »b« = 0 ); val alias = myCallableType; alias( - # $TEST$ references c + // $TEST$ references c »c« = 0, - # $TEST$ references a + // $TEST$ references a »a« = 0, - # $TEST$ references b + // $TEST$ references b »b« = 0 ); } diff --git a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of class/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of class/main.sdstest index 8630ba26..179e0353 100644 --- a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of class/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of class/main.sdstest @@ -1,31 +1,31 @@ package tests.scoping.arguments.ofCalls.toParameterOfClass class MyClass( - # $TEST$ target a + // $TEST$ target a »a«: Int, - # $TEST$ target b + // $TEST$ target b »b«: Int = 0, - # $TEST$ target c + // $TEST$ target c »c«: Int ) {} pipeline myPipeline { MyClass( - # $TEST$ references c + // $TEST$ references c »c« = 0, - # $TEST$ references a + // $TEST$ references a »a« = 0, - # $TEST$ references b + // $TEST$ references b »b« = 0 ); val alias = MyClass; alias( - # $TEST$ references c + // $TEST$ references c »c« = 0, - # $TEST$ references a + // $TEST$ references a »a« = 0, - # $TEST$ references b + // $TEST$ references b »b« = 0 ); } diff --git a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of enum variant/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of enum variant/main.sdstest index 2c3bdcfd..bcc2d952 100644 --- a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of enum variant/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of enum variant/main.sdstest @@ -2,11 +2,11 @@ package tests.scoping.arguments.ofCalls.toParameterOfEnumVariant enum MyEnum { MyEnumVariant( - # $TEST$ target a + // $TEST$ target a »a«: Int, - # $TEST$ target b + // $TEST$ target b »b«: Int = 0, - # $TEST$ target c + // $TEST$ target c »c«: Int ) } @@ -14,21 +14,21 @@ enum MyEnum { pipeline myPipeline { MyEnum.MyEnumVariant( - # $TEST$ references c + // $TEST$ references c »c« = 0, - # $TEST$ references a + // $TEST$ references a »a« = 0, - # $TEST$ references b + // $TEST$ references b »b« = 0 ); val alias = MyEnum.MyEnumVariant; alias( - # $TEST$ references c + // $TEST$ references c »c« = 0, - # $TEST$ references a + // $TEST$ references a »a« = 0, - # $TEST$ references b + // $TEST$ references b »b« = 0 ); } diff --git a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of expression lambda/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of expression lambda/main.sdstest index ef797025..79ce806f 100644 --- a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of expression lambda/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of expression lambda/main.sdstest @@ -2,20 +2,20 @@ package tests.scoping.arguments.ofCalls.toParameterOfExpressionLambda pipeline myPipeline { val myExpressionLambda = ( - # $TEST$ target a + // $TEST$ target a »a«: Int, - # $TEST$ target b + // $TEST$ target b »b«: Int = 0, - # $TEST$ target c + // $TEST$ target c »c«: Int ) -> 1; myExpressionLambda( - # $TEST$ references c + // $TEST$ references c »c« = 0, - # $TEST$ references a + // $TEST$ references a »a« = 0, - # $TEST$ references b + // $TEST$ references b »b« = 0 ); } diff --git a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of function/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of function/main.sdstest index 38d51082..73a81bc8 100644 --- a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of function/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of function/main.sdstest @@ -1,31 +1,31 @@ package tests.scoping.arguments.ofCalls.toParameterOfFunction fun myFunction( - # $TEST$ target a + // $TEST$ target a »a«: Int, - # $TEST$ target b + // $TEST$ target b »b«: Int = 0, - # $TEST$ target c + // $TEST$ target c »c«: Int ) pipeline myPipeline { myFunction( - # $TEST$ references c + // $TEST$ references c »c« = 0, - # $TEST$ references a + // $TEST$ references a »a« = 0, - # $TEST$ references b + // $TEST$ references b »b« = 0 ); val alias = myFunction; alias( - # $TEST$ references c + // $TEST$ references c »c« = 0, - # $TEST$ references a + // $TEST$ references a »a« = 0, - # $TEST$ references b + // $TEST$ references b »b« = 0 ); } diff --git a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of segment/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of segment/main.sdstest index c9710085..e4957c07 100644 --- a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of segment/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of segment/main.sdstest @@ -1,31 +1,31 @@ package tests.scoping.arguments.ofCalls.toParameterOfSegment segment mySegment( - # $TEST$ target a + // $TEST$ target a »a«: Int, - # $TEST$ target b + // $TEST$ target b »b«: Int = 0, - # $TEST$ target c + // $TEST$ target c »c«: Int ) {} pipeline myPipeline { mySegment( - # $TEST$ references c + // $TEST$ references c »c« = 0, - # $TEST$ references a + // $TEST$ references a »a« = 0, - # $TEST$ references b + // $TEST$ references b »b« = 0 ); val alias = mySegment; alias( - # $TEST$ references c + // $TEST$ references c »c« = 0, - # $TEST$ references a + // $TEST$ references a »a« = 0, - # $TEST$ references b + // $TEST$ references b »b« = 0 ); } diff --git a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to something other than parameter/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to something other than parameter/main.sdstest index 657adb16..9df97d67 100644 --- a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to something other than parameter/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to something other than parameter/main.sdstest @@ -3,6 +3,6 @@ package tests.scoping.arguments.ofCalls.toSomethingOtherThanParameter fun f(a: Int) pipeline myPipeline { - # $TEST$ unresolved + // $TEST$ unresolved f(»f« = 1); } diff --git a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/unresolved/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/unresolved/main.sdstest index 29d244a8..2c229246 100644 --- a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/unresolved/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/unresolved/main.sdstest @@ -3,9 +3,9 @@ package tests.scoping.arguments.ofCalls.unresolved fun f(a: Int) pipeline myPipeline { - # $TEST$ unresolved + // $TEST$ unresolved f(»unresolved« = 1); - # $TEST$ unresolved + // $TEST$ unresolved unresolved(»a« = 1); } diff --git a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/with nullable receiver/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/with nullable receiver/main.sdstest index 6f8cfe0f..e3429f92 100644 --- a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/with nullable receiver/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/with nullable receiver/main.sdstest @@ -2,11 +2,11 @@ package tests.scoping.arguments.ofCalls.withNullableReceiver class MyClass { fun myFunction( - # $TEST$ target a + // $TEST$ target a »a«: Int, - # $TEST$ target b + // $TEST$ target b »b«: Int = 0, - # $TEST$ target c + // $TEST$ target c »c«: Int ) } @@ -15,20 +15,20 @@ segment mySegment( myClassOrNull: MyClass? ) { myClassOrNull?.myFunction( - # $TEST$ references c + // $TEST$ references c »c« = 0, - # $TEST$ references a + // $TEST$ references a »a« = 0, - # $TEST$ references b + // $TEST$ references b »b« = 0 ); myClassOrNull?.myFunction?( - # $TEST$ references c + // $TEST$ references c »c« = 0, - # $TEST$ references a + // $TEST$ references a »a« = 0, - # $TEST$ references b + // $TEST$ references b »b« = 0 ); } diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to annotations/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to annotations/main.sdstest index 74253ce3..27dee140 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to annotations/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to annotations/main.sdstest @@ -1,26 +1,26 @@ package tests.scoping.importedDeclarations.toAnnotations -# $TEST$ references own_OwnAnnotation +// $TEST$ references own_OwnAnnotation from tests.scoping.importedDeclarations.toAnnotations import »OwnAnnotation« -# $TEST$ references firstPackage_AnnotationInFirstPackage +// $TEST$ references firstPackage_AnnotationInFirstPackage from tests.scoping.importedDeclarations.toAnnotations.first import »AnnotationInFirstPackage« -# $TEST$ references secondPackage_AnnotationInSecondPackage +// $TEST$ references secondPackage_AnnotationInSecondPackage from tests.scoping.importedDeclarations.toAnnotations.second import »AnnotationInSecondPackage« -# $TEST$ references secondPackage_RedeclaredAnnotationInSameFile -# $TEST$ references secondPackage_RedeclaredAnnotationInOtherFile +// $TEST$ references secondPackage_RedeclaredAnnotationInSameFile +// $TEST$ references secondPackage_RedeclaredAnnotationInOtherFile from tests.scoping.importedDeclarations.toAnnotations.second import »RedeclaredAnnotationInSameFile«, »RedeclaredAnnotationInOtherFile« -# $TEST$ references secondPackage_AnnotationInBothPackages +// $TEST$ references secondPackage_AnnotationInBothPackages from tests.scoping.importedDeclarations.toAnnotations.second import »AnnotationInBothPackages« -# $TEST$ unresolved +// $TEST$ unresolved from tests.scoping.importedDeclarations.toAnnotations.second import »AnnotationInFirstPackage« -# $TEST$ target own_OwnAnnotation +// $TEST$ target own_OwnAnnotation annotation »OwnAnnotation« diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to annotations/resource first package.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to annotations/resource first package.sdstest index 6e15db69..822775f8 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to annotations/resource first package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to annotations/resource first package.sdstest @@ -1,7 +1,7 @@ package tests.scoping.importedDeclarations.toAnnotations.first -# $TEST$ target firstPackage_AnnotationInFirstPackage +// $TEST$ target firstPackage_AnnotationInFirstPackage annotation »AnnotationInFirstPackage« -# $TEST$ target firstPackage_AnnotationInBothPackages +// $TEST$ target firstPackage_AnnotationInBothPackages annotation »AnnotationInBothPackages« diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to annotations/resource second package.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to annotations/resource second package.sdstest index ea410040..caaaed0f 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to annotations/resource second package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to annotations/resource second package.sdstest @@ -1,14 +1,14 @@ package tests.scoping.importedDeclarations.toAnnotations.second -# $TEST$ target secondPackage_AnnotationInSecondPackage +// $TEST$ target secondPackage_AnnotationInSecondPackage annotation »AnnotationInSecondPackage« -# $TEST$ target secondPackage_RedeclaredAnnotationInSameFile +// $TEST$ target secondPackage_RedeclaredAnnotationInSameFile annotation »RedeclaredAnnotationInSameFile« annotation RedeclaredAnnotationInSameFile -# $TEST$ target secondPackage_RedeclaredAnnotationInOtherFile +// $TEST$ target secondPackage_RedeclaredAnnotationInOtherFile annotation »RedeclaredAnnotationInOtherFile« -# $TEST$ target secondPackage_AnnotationInBothPackages +// $TEST$ target secondPackage_AnnotationInBothPackages annotation »AnnotationInBothPackages« diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global classes/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global classes/main.sdstest index 88c480bc..b3b7f341 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global classes/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global classes/main.sdstest @@ -1,26 +1,26 @@ package tests.scoping.importedDeclarations.toClasses -# $TEST$ references own_OwnClass +// $TEST$ references own_OwnClass from tests.scoping.importedDeclarations.toClasses import »OwnClass« -# $TEST$ references firstPackage_ClassInFirstPackage +// $TEST$ references firstPackage_ClassInFirstPackage from tests.scoping.importedDeclarations.toClasses.first import »ClassInFirstPackage« -# $TEST$ references secondPackage_ClassInSecondPackage +// $TEST$ references secondPackage_ClassInSecondPackage from tests.scoping.importedDeclarations.toClasses.second import »ClassInSecondPackage« -# $TEST$ references secondPackage_RedeclaredClassInSameFile -# $TEST$ references secondPackage_RedeclaredClassInOtherFile +// $TEST$ references secondPackage_RedeclaredClassInSameFile +// $TEST$ references secondPackage_RedeclaredClassInOtherFile from tests.scoping.importedDeclarations.toClasses.second import »RedeclaredClassInSameFile«, »RedeclaredClassInOtherFile« -# $TEST$ references secondPackage_ClassInBothPackages +// $TEST$ references secondPackage_ClassInBothPackages from tests.scoping.importedDeclarations.toClasses.second import »ClassInBothPackages« -# $TEST$ unresolved +// $TEST$ unresolved from tests.scoping.importedDeclarations.toClasses.second import »ClassInFirstPackage« -# $TEST$ target own_OwnClass +// $TEST$ target own_OwnClass class »OwnClass« diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global classes/resource first package.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global classes/resource first package.sdstest index f700aa6b..9a9ae936 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global classes/resource first package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global classes/resource first package.sdstest @@ -1,7 +1,7 @@ package tests.scoping.importedDeclarations.toClasses.first -# $TEST$ target firstPackage_ClassInFirstPackage +// $TEST$ target firstPackage_ClassInFirstPackage class »ClassInFirstPackage« -# $TEST$ target firstPackage_ClassInBothPackages +// $TEST$ target firstPackage_ClassInBothPackages class »ClassInBothPackages« diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global classes/resource second package.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global classes/resource second package.sdstest index 2ef76761..654d717e 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global classes/resource second package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global classes/resource second package.sdstest @@ -1,14 +1,14 @@ package tests.scoping.importedDeclarations.toClasses.second -# $TEST$ target secondPackage_ClassInSecondPackage +// $TEST$ target secondPackage_ClassInSecondPackage class »ClassInSecondPackage« -# $TEST$ target secondPackage_RedeclaredClassInSameFile +// $TEST$ target secondPackage_RedeclaredClassInSameFile class »RedeclaredClassInSameFile« class RedeclaredClassInSameFile -# $TEST$ target secondPackage_RedeclaredClassInOtherFile +// $TEST$ target secondPackage_RedeclaredClassInOtherFile class »RedeclaredClassInOtherFile« -# $TEST$ target secondPackage_ClassInBothPackages +// $TEST$ target secondPackage_ClassInBothPackages class »ClassInBothPackages« diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global enums/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global enums/main.sdstest index 74d82c32..66594ba3 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global enums/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global enums/main.sdstest @@ -1,26 +1,26 @@ package tests.scoping.importedDeclarations.toEnums -# $TEST$ references own_OwnEnum +// $TEST$ references own_OwnEnum from tests.scoping.importedDeclarations.toEnums import »OwnEnum« -# $TEST$ references firstPackage_EnumInFirstPackage +// $TEST$ references firstPackage_EnumInFirstPackage from tests.scoping.importedDeclarations.toEnums.first import »EnumInFirstPackage« -# $TEST$ references secondPackage_EnumInSecondPackage +// $TEST$ references secondPackage_EnumInSecondPackage from tests.scoping.importedDeclarations.toEnums.second import »EnumInSecondPackage« -# $TEST$ references secondPackage_RedeclaredEnumInSameFile -# $TEST$ references secondPackage_RedeclaredEnumInOtherFile +// $TEST$ references secondPackage_RedeclaredEnumInSameFile +// $TEST$ references secondPackage_RedeclaredEnumInOtherFile from tests.scoping.importedDeclarations.toEnums.second import »RedeclaredEnumInSameFile«, »RedeclaredEnumInOtherFile« -# $TEST$ references secondPackage_EnumInBothPackages +// $TEST$ references secondPackage_EnumInBothPackages from tests.scoping.importedDeclarations.toEnums.second import »EnumInBothPackages« -# $TEST$ unresolved +// $TEST$ unresolved from tests.scoping.importedDeclarations.toEnums.second import »EnumInFirstPackage« -# $TEST$ target own_OwnEnum +// $TEST$ target own_OwnEnum enum »OwnEnum« diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global enums/resource first package.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global enums/resource first package.sdstest index 15094ae9..a563a8f8 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global enums/resource first package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global enums/resource first package.sdstest @@ -1,7 +1,7 @@ package tests.scoping.importedDeclarations.toEnums.first -# $TEST$ target firstPackage_EnumInFirstPackage +// $TEST$ target firstPackage_EnumInFirstPackage enum »EnumInFirstPackage« -# $TEST$ target firstPackage_EnumInBothPackages +// $TEST$ target firstPackage_EnumInBothPackages enum »EnumInBothPackages« diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global enums/resource second package.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global enums/resource second package.sdstest index cc65e7ed..670236f5 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global enums/resource second package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global enums/resource second package.sdstest @@ -1,14 +1,14 @@ package tests.scoping.importedDeclarations.toEnums.second -# $TEST$ target secondPackage_EnumInSecondPackage +// $TEST$ target secondPackage_EnumInSecondPackage enum »EnumInSecondPackage« -# $TEST$ target secondPackage_RedeclaredEnumInSameFile +// $TEST$ target secondPackage_RedeclaredEnumInSameFile enum »RedeclaredEnumInSameFile« enum RedeclaredEnumInSameFile -# $TEST$ target secondPackage_RedeclaredEnumInOtherFile +// $TEST$ target secondPackage_RedeclaredEnumInOtherFile enum »RedeclaredEnumInOtherFile« -# $TEST$ target secondPackage_EnumInBothPackages +// $TEST$ target secondPackage_EnumInBothPackages enum »EnumInBothPackages« diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global functions/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global functions/main.sdstest index cc1a7bee..17f57d81 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global functions/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global functions/main.sdstest @@ -1,26 +1,26 @@ package tests.scoping.importedDeclarations.toFunctions -# $TEST$ references own_ownFunction +// $TEST$ references own_ownFunction from tests.scoping.importedDeclarations.toFunctions import »ownFunction« -# $TEST$ references firstPackage_functionInFirstPackage +// $TEST$ references firstPackage_functionInFirstPackage from tests.scoping.importedDeclarations.toFunctions.first import »functionInFirstPackage« -# $TEST$ references secondPackage_functionInSecondPackage +// $TEST$ references secondPackage_functionInSecondPackage from tests.scoping.importedDeclarations.toFunctions.second import »functionInSecondPackage« -# $TEST$ references secondPackage_redeclaredFunctionInSameFile -# $TEST$ references secondPackage_redeclaredFunctionInOtherFile +// $TEST$ references secondPackage_redeclaredFunctionInSameFile +// $TEST$ references secondPackage_redeclaredFunctionInOtherFile from tests.scoping.importedDeclarations.toFunctions.second import »redeclaredFunctionInSameFile«, »redeclaredFunctionInOtherFile« -# $TEST$ references secondPackage_functionInBothPackages +// $TEST$ references secondPackage_functionInBothPackages from tests.scoping.importedDeclarations.toFunctions.second import »functionInBothPackages« -# $TEST$ unresolved +// $TEST$ unresolved from tests.scoping.importedDeclarations.toFunctions.second import »functionInFirstPackage« -# $TEST$ target own_ownFunction +// $TEST$ target own_ownFunction fun »ownFunction«() diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global functions/resource first package.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global functions/resource first package.sdstest index 72fbec46..4fe65ce3 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global functions/resource first package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global functions/resource first package.sdstest @@ -1,7 +1,7 @@ package tests.scoping.importedDeclarations.toFunctions.first -# $TEST$ target firstPackage_functionInFirstPackage +// $TEST$ target firstPackage_functionInFirstPackage fun »functionInFirstPackage«() -# $TEST$ target firstPackage_functionInBothPackages +// $TEST$ target firstPackage_functionInBothPackages fun »functionInBothPackages«() diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global functions/resource second package.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global functions/resource second package.sdstest index dc61d0e2..0b857158 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global functions/resource second package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global functions/resource second package.sdstest @@ -1,14 +1,14 @@ package tests.scoping.importedDeclarations.toFunctions.second -# $TEST$ target secondPackage_functionInSecondPackage +// $TEST$ target secondPackage_functionInSecondPackage fun »functionInSecondPackage«() -# $TEST$ target secondPackage_redeclaredFunctionInSameFile +// $TEST$ target secondPackage_redeclaredFunctionInSameFile fun »redeclaredFunctionInSameFile«() fun redeclaredFunctionInSameFile() -# $TEST$ target secondPackage_redeclaredFunctionInOtherFile +// $TEST$ target secondPackage_redeclaredFunctionInOtherFile fun »redeclaredFunctionInOtherFile«() -# $TEST$ target secondPackage_functionInBothPackages +// $TEST$ target secondPackage_functionInBothPackages fun »functionInBothPackages«() diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to nested declaration/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to nested declaration/main.sdstest index dee44e90..e0216342 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to nested declaration/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to nested declaration/main.sdstest @@ -1,28 +1,28 @@ package tests.scoping.importedDeclarations.toNestedDeclaration -# $TEST$ unresolved +// $TEST$ unresolved from tests.scoping.importedDeclarations.toNestedDeclaration import »OwnClass« -# $TEST$ unresolved +// $TEST$ unresolved from tests.scoping.importedDeclarations.toNestedDeclaration.first import »ClassInFirstPackage« -# $TEST$ unresolved +// $TEST$ unresolved from tests.scoping.importedDeclarations.toNestedDeclaration.second import »ClassInSecondPackage« -# $TEST$ unresolved -# $TEST$ unresolved +// $TEST$ unresolved +// $TEST$ unresolved from tests.scoping.importedDeclarations.toNestedDeclaration.second import »RedeclaredClassInSameFile«, »RedeclaredClassInOtherFile« -# $TEST$ unresolved +// $TEST$ unresolved from tests.scoping.importedDeclarations.toNestedDeclaration.second import »ClassInBothPackages« -# $TEST$ unresolved +// $TEST$ unresolved from tests.scoping.importedDeclarations.toNestedDeclaration.second import »ClassInFirstPackage« class Outer { - # $TEST$ target own_OwnClass + // $TEST$ target own_OwnClass class »OwnClass« } diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to nested declaration/resource first package.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to nested declaration/resource first package.sdstest index 295affac..200bf7e8 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to nested declaration/resource first package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to nested declaration/resource first package.sdstest @@ -1,9 +1,9 @@ package tests.scoping.importedDeclarations.toNestedDeclaration.first class Outer { - # $TEST$ target firstPackage_ClassInFirstPackage + // $TEST$ target firstPackage_ClassInFirstPackage class »ClassInFirstPackage« - # $TEST$ target firstPackage_ClassInBothPackages + // $TEST$ target firstPackage_ClassInBothPackages class »ClassInBothPackages« } diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to nested declaration/resource second package.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to nested declaration/resource second package.sdstest index 6a341092..a2194dd8 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to nested declaration/resource second package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to nested declaration/resource second package.sdstest @@ -1,16 +1,16 @@ package tests.scoping.importedDeclarations.toNestedDeclaration.second class Outer { - # $TEST$ target secondPackage_ClassInSecondPackage + // $TEST$ target secondPackage_ClassInSecondPackage class »ClassInSecondPackage« - # $TEST$ target secondPackage_RedeclaredClassInSameFile + // $TEST$ target secondPackage_RedeclaredClassInSameFile class »RedeclaredClassInSameFile« class RedeclaredClassInSameFile - # $TEST$ target secondPackage_RedeclaredClassInOtherFile + // $TEST$ target secondPackage_RedeclaredClassInOtherFile class »RedeclaredClassInOtherFile« - # $TEST$ target secondPackage_ClassInBothPackages + // $TEST$ target secondPackage_ClassInBothPackages class »ClassInBothPackages« } diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to pipelines/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to pipelines/main.sdstest index 3ecf4ead..0085c16d 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to pipelines/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to pipelines/main.sdstest @@ -1,26 +1,26 @@ package tests.scoping.importedDeclarations.toPipelines -# $TEST$ unresolved +// $TEST$ unresolved from tests.scoping.importedDeclarations.toPipelines import »ownPipeline« -# $TEST$ unresolved +// $TEST$ unresolved from tests.scoping.importedDeclarations.toPipelines.first import »pipelineInFirstPackage« -# $TEST$ unresolved +// $TEST$ unresolved from tests.scoping.importedDeclarations.toPipelines.second import »pipelineInSecondPackage« -# $TEST$ unresolved -# $TEST$ unresolved +// $TEST$ unresolved +// $TEST$ unresolved from tests.scoping.importedDeclarations.toPipelines.second import »redeclaredPipelineInSameFile«, »redeclaredPipelineInOtherFile« -# $TEST$ unresolved +// $TEST$ unresolved from tests.scoping.importedDeclarations.toPipelines.second import »pipelineInBothPackages« -# $TEST$ unresolved +// $TEST$ unresolved from tests.scoping.importedDeclarations.toPipelines.second import »pipelineInFirstPackage« -# $TEST$ target own_ownPipeline +// $TEST$ target own_ownPipeline pipeline »ownPipeline« {} diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to pipelines/resource first package.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to pipelines/resource first package.sdstest index b8be21f4..0606253c 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to pipelines/resource first package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to pipelines/resource first package.sdstest @@ -1,7 +1,7 @@ package tests.scoping.importedDeclarations.toPipelines.first -# $TEST$ target firstPackage_pipelineInFirstPackage +// $TEST$ target firstPackage_pipelineInFirstPackage pipeline »pipelineInFirstPackage« {} -# $TEST$ target firstPackage_pipelineInBothPackages +// $TEST$ target firstPackage_pipelineInBothPackages pipeline »pipelineInBothPackages« {} diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to pipelines/resource second package.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to pipelines/resource second package.sdstest index 7ab64fe1..87a9d28b 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to pipelines/resource second package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to pipelines/resource second package.sdstest @@ -1,14 +1,14 @@ package tests.scoping.importedDeclarations.toPipelines.second -# $TEST$ target secondPackage_pipelineInSecondPackage +// $TEST$ target secondPackage_pipelineInSecondPackage pipeline »pipelineInSecondPackage« {} -# $TEST$ target secondPackage_redeclaredPipelineInSameFile +// $TEST$ target secondPackage_redeclaredPipelineInSameFile pipeline »redeclaredPipelineInSameFile« {} pipeline redeclaredPipelineInSameFile {} -# $TEST$ target secondPackage_redeclaredPipelineInOtherFile +// $TEST$ target secondPackage_redeclaredPipelineInOtherFile pipeline »redeclaredPipelineInOtherFile« {} -# $TEST$ target secondPackage_pipelineInBothPackages +// $TEST$ target secondPackage_pipelineInBothPackages pipeline »pipelineInBothPackages« {} diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to schemas/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to schemas/main.sdstest index c84bcafb..50e262a5 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to schemas/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to schemas/main.sdstest @@ -1,25 +1,25 @@ package tests.scoping.importedDeclarations.toSchemas -# $TEST$ references own_OwnSchema +// $TEST$ references own_OwnSchema from tests.scoping.importedDeclarations.toSchemas import »OwnSchema« -# $TEST$ references firstPackage_SchemaInFirstPackage +// $TEST$ references firstPackage_SchemaInFirstPackage from tests.scoping.importedDeclarations.toSchemas.first import »SchemaInFirstPackage« -# $TEST$ references secondPackage_SchemaInSecondPackage +// $TEST$ references secondPackage_SchemaInSecondPackage from tests.scoping.importedDeclarations.toSchemas.second import »SchemaInSecondPackage« -# $TEST$ references secondPackage_RedeclaredSchemaInSameFile -# $TEST$ references secondPackage_RedeclaredSchemaInOtherFile +// $TEST$ references secondPackage_RedeclaredSchemaInSameFile +// $TEST$ references secondPackage_RedeclaredSchemaInOtherFile from tests.scoping.importedDeclarations.toSchemas.second import »RedeclaredSchemaInSameFile«, »RedeclaredSchemaInOtherFile« -# $TEST$ references secondPackage_SchemaInBothPackages +// $TEST$ references secondPackage_SchemaInBothPackages from tests.scoping.importedDeclarations.toSchemas.second import »SchemaInBothPackages« -# $TEST$ unresolved +// $TEST$ unresolved from tests.scoping.importedDeclarations.toSchemas.second import »SchemaInFirstPackage« -# $TEST$ target own_OwnSchema +// $TEST$ target own_OwnSchema schema »OwnSchema« {} diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to schemas/resource first package.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to schemas/resource first package.sdstest index 6b1fd295..281edb62 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to schemas/resource first package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to schemas/resource first package.sdstest @@ -1,7 +1,7 @@ package tests.scoping.importedDeclarations.toSchemas.first -# $TEST$ target firstPackage_SchemaInFirstPackage +// $TEST$ target firstPackage_SchemaInFirstPackage schema »SchemaInFirstPackage« {} -# $TEST$ target firstPackage_SchemaInBothPackages +// $TEST$ target firstPackage_SchemaInBothPackages schema »SchemaInBothPackages« {} diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to schemas/resource second package.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to schemas/resource second package.sdstest index e83803bf..56f66891 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to schemas/resource second package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to schemas/resource second package.sdstest @@ -1,14 +1,14 @@ package tests.scoping.importedDeclarations.toSchemas.second -# $TEST$ target secondPackage_SchemaInSecondPackage +// $TEST$ target secondPackage_SchemaInSecondPackage schema »SchemaInSecondPackage« {} -# $TEST$ target secondPackage_RedeclaredSchemaInSameFile +// $TEST$ target secondPackage_RedeclaredSchemaInSameFile schema »RedeclaredSchemaInSameFile« {} schema RedeclaredSchemaInSameFile {} -# $TEST$ target secondPackage_RedeclaredSchemaInOtherFile +// $TEST$ target secondPackage_RedeclaredSchemaInOtherFile schema »RedeclaredSchemaInOtherFile« {} -# $TEST$ target secondPackage_SchemaInBothPackages +// $TEST$ target secondPackage_SchemaInBothPackages schema »SchemaInBothPackages« {} diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to segments/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to segments/main.sdstest index af003613..caff4fa1 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to segments/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to segments/main.sdstest @@ -1,42 +1,42 @@ package tests.scoping.importedDeclarations.toSegments -# $TEST$ references own_ownSegment +// $TEST$ references own_ownSegment from tests.scoping.importedDeclarations.toSegments import »ownSegment« -# $TEST$ references same_publicSegmentInSamePackage +// $TEST$ references same_publicSegmentInSamePackage from tests.scoping.importedDeclarations.toSegments import »publicSegmentInSamePackage« -# $TEST$ references same_internalSegmentInSamePackage +// $TEST$ references same_internalSegmentInSamePackage from tests.scoping.importedDeclarations.toSegments import »internalSegmentInSamePackage« -# $TEST$ unresolved +// $TEST$ unresolved from tests.scoping.importedDeclarations.toSegments import »privateSegmentInSamePackage« -# $TEST$ references firstPackage_segmentInFirstPackage +// $TEST$ references firstPackage_segmentInFirstPackage from tests.scoping.importedDeclarations.toSegments.first import »segmentInFirstPackage« -# $TEST$ references secondPackage_publicSegmentInSecondPackage +// $TEST$ references secondPackage_publicSegmentInSecondPackage from tests.scoping.importedDeclarations.toSegments.second import »publicSegmentInSecondPackage« -# $TEST$ unresolved +// $TEST$ unresolved from tests.scoping.importedDeclarations.toSegments.second import »internalSegmentInSecondPackage« -# $TEST$ unresolved +// $TEST$ unresolved from tests.scoping.importedDeclarations.toSegments.second import »privateSegmentInSecondPackage« -# $TEST$ references secondPackage_redeclaredSegmentInSameFile -# $TEST$ references secondPackage_redeclaredSegmentInOtherFile +// $TEST$ references secondPackage_redeclaredSegmentInSameFile +// $TEST$ references secondPackage_redeclaredSegmentInOtherFile from tests.scoping.importedDeclarations.toSegments.second import »redeclaredSegmentInSameFile«, »redeclaredSegmentInOtherFile« -# $TEST$ references secondPackage_segmentInBothPackages +// $TEST$ references secondPackage_segmentInBothPackages from tests.scoping.importedDeclarations.toSegments.second import »segmentInBothPackages« -# $TEST$ unresolved +// $TEST$ unresolved from tests.scoping.importedDeclarations.toSegments.second import »segmentInFirstPackage« -# $TEST$ target own_ownSegment +// $TEST$ target own_ownSegment segment »ownSegment«() {} diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to segments/resource first package.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to segments/resource first package.sdstest index 8afd310f..8ba7afa9 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to segments/resource first package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to segments/resource first package.sdstest @@ -1,7 +1,7 @@ package tests.scoping.importedDeclarations.toSegments.first -# $TEST$ target firstPackage_segmentInFirstPackage +// $TEST$ target firstPackage_segmentInFirstPackage segment »segmentInFirstPackage«() {} -# $TEST$ target firstPackage_segmentInBothPackages +// $TEST$ target firstPackage_segmentInBothPackages segment »segmentInBothPackages«() {} diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to segments/resource same package.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to segments/resource same package.sdstest index 3a335555..682f954b 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to segments/resource same package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to segments/resource same package.sdstest @@ -1,10 +1,10 @@ package tests.scoping.importedDeclarations.toSegments -# $TEST$ target same_publicSegmentInSamePackage +// $TEST$ target same_publicSegmentInSamePackage segment »publicSegmentInSamePackage«() {} -# $TEST$ target same_internalSegmentInSamePackage +// $TEST$ target same_internalSegmentInSamePackage internal segment »internalSegmentInSamePackage«() {} -# $TEST$ target same_privateSegmentInSamePackage +// $TEST$ target same_privateSegmentInSamePackage private segment »privateSegmentInSamePackage«() {} diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to segments/resource second package.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to segments/resource second package.sdstest index 73473ec7..b3ee4279 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to segments/resource second package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to segments/resource second package.sdstest @@ -1,20 +1,20 @@ package tests.scoping.importedDeclarations.toSegments.second -# $TEST$ target secondPackage_publicSegmentInSecondPackage +// $TEST$ target secondPackage_publicSegmentInSecondPackage segment »publicSegmentInSecondPackage«() {} -# $TEST$ target secondPackage_internalSegmentInSecondPackage +// $TEST$ target secondPackage_internalSegmentInSecondPackage internal segment »internalSegmentInSecondPackage«() {} -# $TEST$ target secondPackage_privateSegmentInSecondPackage +// $TEST$ target secondPackage_privateSegmentInSecondPackage private segment »privateSegmentInSecondPackage«() {} -# $TEST$ target secondPackage_redeclaredSegmentInSameFile +// $TEST$ target secondPackage_redeclaredSegmentInSameFile segment »redeclaredSegmentInSameFile«() {} segment redeclaredSegmentInSameFile() {} -# $TEST$ target secondPackage_redeclaredSegmentInOtherFile +// $TEST$ target secondPackage_redeclaredSegmentInOtherFile segment »redeclaredSegmentInOtherFile«() {} -# $TEST$ target secondPackage_segmentInBothPackages +// $TEST$ target secondPackage_segmentInBothPackages segment »segmentInBothPackages«() {} diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/unresolved/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/unresolved/main.sdstest index 7c0095b4..f536308a 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/unresolved/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/unresolved/main.sdstest @@ -1,4 +1,4 @@ package tests.scoping.importedDeclarations.unresolved -# $TEST$ unresolved +// $TEST$ unresolved from tests.scoping.importedDeclarations.toAnnotations import »unresolved« diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/on type parameters/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/on type parameters/main.sdstest index 3fc35f6f..4883da99 100644 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/on type parameters/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/member accesses/on type parameters/main.sdstest @@ -1,7 +1,7 @@ package tests.scoping.memberAccesses.onTypeParameters class C { - # $TEST$ target attribute + // $TEST$ target attribute attr »a«: Int } @@ -9,9 +9,9 @@ class MyClass( unbounded: Unbounded, upperBound: UpperBound, - # $TEST$ unresolved + // $TEST$ unresolved p1: Any = unbounded.»a«, - # $TEST$ references attribute + // $TEST$ references attribute p2: Any = upperBound.»a«, ) { attr unbounded: Unbounded @@ -19,9 +19,9 @@ class MyClass( } segment mySegment(instance: MyClass) { - # $TEST$ references attribute + // $TEST$ references attribute instance.unbounded.»a«; - # $TEST$ references attribute + // $TEST$ references attribute instance.upperBound.»a«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/hiding/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/hiding/main.sdstest index fabcc576..8f4afe94 100644 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/hiding/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/hiding/main.sdstest @@ -1,43 +1,43 @@ package tests.scoping.memberAccesses.toClassMembers.hiding class MySuperClass { - # $TEST$ target MySuperClass_myStaticAttribute + // $TEST$ target MySuperClass_myStaticAttribute static attr »myStaticAttribute«: Int - # $TEST$ target MySuperClass_myNestedClass + // $TEST$ target MySuperClass_myNestedClass class »MyNestedClass« - # $TEST$ target MySuperClass_myNestedEnum + // $TEST$ target MySuperClass_myNestedEnum enum »MyNestedEnum« - # $TEST$ target MySuperClass_myStaticMethod + // $TEST$ target MySuperClass_myStaticMethod static fun »myStaticMethod1«() } class MyClass sub MySuperClass { - # $TEST$ target MyClass_myStaticAttribute + // $TEST$ target MyClass_myStaticAttribute static attr »myStaticAttribute«: Int - # $TEST$ target MyClass_myNestedClass + // $TEST$ target MyClass_myNestedClass class »MyNestedClass« - # $TEST$ target MyClass_myNestedEnum + // $TEST$ target MyClass_myNestedEnum enum »MyNestedEnum« - # $TEST$ target MyClass_myStaticMethod + // $TEST$ target MyClass_myStaticMethod static fun »myStaticMethod1«() } pipeline myPipeline { - # $TEST$ references MyClass_myStaticAttribute + // $TEST$ references MyClass_myStaticAttribute MyClass.»myStaticAttribute«; - # $TEST$ references MyClass_myNestedClass + // $TEST$ references MyClass_myNestedClass MyClass.»MyNestedClass«; - # $TEST$ references MyClass_myNestedEnum + // $TEST$ references MyClass_myNestedEnum MyClass.»MyNestedEnum«; - # $TEST$ references MyClass_myStaticMethod + // $TEST$ references MyClass_myStaticMethod MyClass.»myStaticMethod1«(); } diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/inheritance/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/inheritance/main.sdstest index 93954673..ae51019d 100644 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/inheritance/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/inheritance/main.sdstest @@ -1,84 +1,84 @@ package tests.scoping.memberAccesses.toClassMembers.inheritance class MySuperClass1 { - # $TEST$ target MySuperClass1_myInstanceAttribute + // $TEST$ target MySuperClass1_myInstanceAttribute attr »myInstanceAttribute1«: Int - # $TEST$ target MySuperClass1_myInstanceMethod + // $TEST$ target MySuperClass1_myInstanceMethod fun »myInstanceMethod1«() - # $TEST$ target MySuperClass1_myStaticAttribute + // $TEST$ target MySuperClass1_myStaticAttribute static attr »myStaticAttribute1«: Int - # $TEST$ target MySuperClass1_myNestedClass + // $TEST$ target MySuperClass1_myNestedClass class »MyNestedClass1« - # $TEST$ target MySuperClass1_myNestedEnum + // $TEST$ target MySuperClass1_myNestedEnum enum »MyNestedEnum1« - # $TEST$ target MySuperClass1_myStaticMethod + // $TEST$ target MySuperClass1_myStaticMethod static fun »myStaticMethod1«() } class MySuperClass2 { - # $TEST$ target MySuperClass2_myInstanceAttribute + // $TEST$ target MySuperClass2_myInstanceAttribute attr »myInstanceAttribute2«: Int - # $TEST$ target MySuperClass2_myInstanceMethod + // $TEST$ target MySuperClass2_myInstanceMethod fun »myInstanceMethod2«() - # $TEST$ target MySuperClass2_myStaticAttribute + // $TEST$ target MySuperClass2_myStaticAttribute static attr »myStaticAttribute2«: Int - # $TEST$ target MySuperClass2_myNestedClass + // $TEST$ target MySuperClass2_myNestedClass class »MyNestedClass2« - # $TEST$ target MySuperClass2_myNestedEnum + // $TEST$ target MySuperClass2_myNestedEnum enum »MyNestedEnum2« - # $TEST$ target MySuperClass2_myStaticMethod + // $TEST$ target MySuperClass2_myStaticMethod static fun »myStaticMethod2«() } class MyClass() sub MySuperClass1, MySuperClass2 pipeline myPipeline { - # $TEST$ references MySuperClass1_myInstanceAttribute + // $TEST$ references MySuperClass1_myInstanceAttribute MyClass().»myInstanceAttribute1«; - # $TEST$ references MySuperClass1_myInstanceMethod + // $TEST$ references MySuperClass1_myInstanceMethod MyClass().»myInstanceMethod1«(); - # $TEST$ references MySuperClass1_myStaticAttribute + // $TEST$ references MySuperClass1_myStaticAttribute MyClass.»myStaticAttribute1«; - # $TEST$ references MySuperClass1_myNestedClass + // $TEST$ references MySuperClass1_myNestedClass MyClass.»MyNestedClass1«; - # $TEST$ references MySuperClass1_myNestedEnum + // $TEST$ references MySuperClass1_myNestedEnum MyClass.»MyNestedEnum1«; - # $TEST$ references MySuperClass1_myStaticMethod + // $TEST$ references MySuperClass1_myStaticMethod MyClass.»myStaticMethod1«(); - # $TEST$ unresolved + // $TEST$ unresolved MyClass().»myInstanceAttribute2«; - # $TEST$ unresolved + // $TEST$ unresolved MyClass().»myInstanceMethod2«(); - # $TEST$ unresolved + // $TEST$ unresolved MyClass.»myStaticAttribute2«; - # $TEST$ unresolved + // $TEST$ unresolved MyClass.»MyNestedClass2«; - # $TEST$ unresolved + // $TEST$ unresolved MyClass.»MyNestedEnum2«; - # $TEST$ unresolved + // $TEST$ unresolved MyClass.»myStaticMethod2«(); } diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/instance attributes/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/instance attributes/main.sdstest index 7920af7b..4a5ddbcb 100644 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/instance attributes/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/instance attributes/main.sdstest @@ -1,48 +1,48 @@ package tests.scoping.memberAccesses.toClassMembers.instanceAttributes class MyClass { - # $TEST$ target myInstanceAttribute + // $TEST$ target myInstanceAttribute attr »myInstanceAttribute«: Int - # $TEST$ target redeclaredAsInstanceAttribute + // $TEST$ target redeclaredAsInstanceAttribute attr »redeclaredAsInstanceAttribute«: Int attr redeclaredAsInstanceAttribute: Int - # $TEST$ target redeclaredAsStaticAttribute + // $TEST$ target redeclaredAsStaticAttribute attr »redeclaredAsStaticAttribute«: Int static attr redeclaredAsStaticAttribute: Int - # $TEST$ target redeclaredAsNestedClass + // $TEST$ target redeclaredAsNestedClass attr »redeclaredAsNestedClass«: Int class redeclaredAsNestedClass - # $TEST$ target redeclaredAsNestedEnum + // $TEST$ target redeclaredAsNestedEnum attr »redeclaredAsNestedEnum«: Int enum redeclaredAsNestedEnum - # $TEST$ target redeclaredAsInstanceMethod + // $TEST$ target redeclaredAsInstanceMethod attr »redeclaredAsInstanceMethod«: Int fun redeclaredAsInstanceMethod() - # $TEST$ target redeclaredAsStaticMethod + // $TEST$ target redeclaredAsStaticMethod attr »redeclaredAsStaticMethod«: Int static fun redeclaredAsStaticMethod() - # $TEST$ target declaredPreviouslyAsStaticAttribute + // $TEST$ target declaredPreviouslyAsStaticAttribute static attr declaredPreviouslyAsStaticAttribute: Int attr »declaredPreviouslyAsStaticAttribute«: Int - # $TEST$ target declaredPreviouslyAsNestedClass + // $TEST$ target declaredPreviouslyAsNestedClass class declaredPreviouslyAsNestedClass attr »declaredPreviouslyAsNestedClass«: Int - # $TEST$ target declaredPreviouslyAsNestedEnum + // $TEST$ target declaredPreviouslyAsNestedEnum class declaredPreviouslyAsNestedEnum attr »declaredPreviouslyAsNestedEnum«: Int - # $TEST$ target declaredPreviouslyAsStaticMethod + // $TEST$ target declaredPreviouslyAsStaticMethod static fun declaredPreviouslyAsStaticMethod() attr »declaredPreviouslyAsStaticMethod«: Int } @@ -52,57 +52,57 @@ class AnotherClass fun nullableMyClass() -> result: MyClass? pipeline myPipeline { - # $TEST$ references myInstanceAttribute + // $TEST$ references myInstanceAttribute val myClass = MyClass(); myClass.»myInstanceAttribute«; - # $TEST$ references redeclaredAsInstanceAttribute + // $TEST$ references redeclaredAsInstanceAttribute MyClass().»redeclaredAsInstanceAttribute«; - # $TEST$ references redeclaredAsStaticAttribute + // $TEST$ references redeclaredAsStaticAttribute MyClass().»redeclaredAsStaticAttribute«; - # $TEST$ references redeclaredAsNestedClass + // $TEST$ references redeclaredAsNestedClass MyClass().»redeclaredAsNestedClass«; - # $TEST$ references redeclaredAsNestedEnum + // $TEST$ references redeclaredAsNestedEnum MyClass().»redeclaredAsNestedEnum«; - # $TEST$ references redeclaredAsInstanceMethod + // $TEST$ references redeclaredAsInstanceMethod MyClass().»redeclaredAsInstanceMethod«; - # $TEST$ references redeclaredAsStaticMethod + // $TEST$ references redeclaredAsStaticMethod MyClass().»redeclaredAsStaticMethod«; - # $TEST$ references declaredPreviouslyAsStaticAttribute + // $TEST$ references declaredPreviouslyAsStaticAttribute MyClass().»declaredPreviouslyAsStaticAttribute«; - # $TEST$ references declaredPreviouslyAsNestedClass + // $TEST$ references declaredPreviouslyAsNestedClass MyClass().»declaredPreviouslyAsNestedClass«; - # $TEST$ references declaredPreviouslyAsNestedEnum + // $TEST$ references declaredPreviouslyAsNestedEnum MyClass().»declaredPreviouslyAsNestedEnum«; - # $TEST$ references declaredPreviouslyAsStaticMethod + // $TEST$ references declaredPreviouslyAsStaticMethod MyClass().»declaredPreviouslyAsStaticMethod«; - # $TEST$ references myInstanceAttribute + // $TEST$ references myInstanceAttribute nullableMyClass().»myInstanceAttribute«; - # $TEST$ references myInstanceAttribute + // $TEST$ references myInstanceAttribute nullableMyClass()?.»myInstanceAttribute«; - # $TEST$ unresolved + // $TEST$ unresolved MyClass.»myInstanceAttribute«; - # $TEST$ unresolved + // $TEST$ unresolved AnotherClass().»myInstanceAttribute«; - # $TEST$ unresolved + // $TEST$ unresolved unresolved.»myInstanceAttribute«; - # $TEST$ unresolved + // $TEST$ unresolved MyClass.»unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/instance methods/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/instance methods/main.sdstest index 94ee9c29..109f228e 100644 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/instance methods/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/instance methods/main.sdstest @@ -1,48 +1,48 @@ package tests.scoping.memberAccesses.toClassMembers.instanceMethods class MyClass { - # $TEST$ target myInstanceMethod + // $TEST$ target myInstanceMethod fun »myInstanceMethod«() - # $TEST$ target redeclaredAsInstanceAttribute + // $TEST$ target redeclaredAsInstanceAttribute fun »redeclaredAsInstanceAttribute«() attr redeclaredAsInstanceAttribute: Int - # $TEST$ target redeclaredAsStaticAttribute + // $TEST$ target redeclaredAsStaticAttribute fun »redeclaredAsStaticAttribute«() static attr redeclaredAsStaticAttribute: Int - # $TEST$ target redeclaredAsNestedClass + // $TEST$ target redeclaredAsNestedClass fun »redeclaredAsNestedClass«() class redeclaredAsNestedClass - # $TEST$ target redeclaredAsNestedEnum + // $TEST$ target redeclaredAsNestedEnum fun »redeclaredAsNestedEnum«() enum redeclaredAsNestedEnum - # $TEST$ target redeclaredAsInstanceMethod + // $TEST$ target redeclaredAsInstanceMethod fun »redeclaredAsInstanceMethod«() fun redeclaredAsInstanceMethod() - # $TEST$ target redeclaredAsStaticMethod + // $TEST$ target redeclaredAsStaticMethod fun »redeclaredAsStaticMethod«() static fun redeclaredAsStaticMethod() - # $TEST$ target declaredPreviouslyAsStaticAttribute + // $TEST$ target declaredPreviouslyAsStaticAttribute static attr declaredPreviouslyAsStaticAttribute: Int fun »declaredPreviouslyAsStaticAttribute«() - # $TEST$ target declaredPreviouslyAsNestedClass + // $TEST$ target declaredPreviouslyAsNestedClass class declaredPreviouslyAsNestedClass fun »declaredPreviouslyAsNestedClass«() - # $TEST$ target declaredPreviouslyAsNestedEnum + // $TEST$ target declaredPreviouslyAsNestedEnum class declaredPreviouslyAsNestedEnum fun »declaredPreviouslyAsNestedEnum«() - # $TEST$ target declaredPreviouslyAsStaticMethod + // $TEST$ target declaredPreviouslyAsStaticMethod static fun declaredPreviouslyAsStaticMethod() fun »declaredPreviouslyAsStaticMethod«() } @@ -52,57 +52,57 @@ class AnotherClass fun nullableMyClass() -> result: MyClass? pipeline myPipeline { - # $TEST$ references myInstanceMethod + // $TEST$ references myInstanceMethod val myClass = MyClass(); myClass.»myInstanceMethod«(); - # $TEST$ references redeclaredAsInstanceAttribute + // $TEST$ references redeclaredAsInstanceAttribute MyClass().»redeclaredAsInstanceAttribute«(); - # $TEST$ references redeclaredAsStaticAttribute + // $TEST$ references redeclaredAsStaticAttribute MyClass().»redeclaredAsStaticAttribute«(); - # $TEST$ references redeclaredAsNestedClass + // $TEST$ references redeclaredAsNestedClass MyClass().»redeclaredAsNestedClass«(); - # $TEST$ references redeclaredAsNestedEnum + // $TEST$ references redeclaredAsNestedEnum MyClass().»redeclaredAsNestedEnum«(); - # $TEST$ references redeclaredAsInstanceMethod + // $TEST$ references redeclaredAsInstanceMethod MyClass().»redeclaredAsInstanceMethod«(); - # $TEST$ references redeclaredAsStaticMethod + // $TEST$ references redeclaredAsStaticMethod MyClass().»redeclaredAsStaticMethod«(); - # $TEST$ references declaredPreviouslyAsStaticAttribute + // $TEST$ references declaredPreviouslyAsStaticAttribute MyClass().»declaredPreviouslyAsStaticAttribute«(); - # $TEST$ references declaredPreviouslyAsNestedClass + // $TEST$ references declaredPreviouslyAsNestedClass MyClass().»declaredPreviouslyAsNestedClass«(); - # $TEST$ references declaredPreviouslyAsNestedEnum + // $TEST$ references declaredPreviouslyAsNestedEnum MyClass().»declaredPreviouslyAsNestedEnum«(); - # $TEST$ references declaredPreviouslyAsStaticMethod + // $TEST$ references declaredPreviouslyAsStaticMethod MyClass().»declaredPreviouslyAsStaticMethod«(); - # $TEST$ references myInstanceMethod + // $TEST$ references myInstanceMethod nullableMyClass().»myInstanceMethod«; - # $TEST$ references myInstanceMethod + // $TEST$ references myInstanceMethod nullableMyClass()?.»myInstanceMethod«(); - # $TEST$ unresolved + // $TEST$ unresolved MyClass.»myInstanceMethod«; - # $TEST$ unresolved + // $TEST$ unresolved AnotherClass().»myInstanceMethod«; - # $TEST$ unresolved + // $TEST$ unresolved unresolved.»myInstanceMethod«; - # $TEST$ unresolved + // $TEST$ unresolved MyClass.»unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/nested classes/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/nested classes/main.sdstest index 6b955ad9..deba1851 100644 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/nested classes/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/nested classes/main.sdstest @@ -1,40 +1,40 @@ package tests.scoping.memberAccesses.toClassMembers.nestedClasses class MyClass { - # $TEST$ target myNestedClass + // $TEST$ target myNestedClass class »MyNestedClass« - # $TEST$ target redeclaredAsInstanceAttribute + // $TEST$ target redeclaredAsInstanceAttribute class »RedeclaredAsInstanceAttribute« attr RedeclaredAsInstanceAttribute: Int - # $TEST$ target redeclaredAsStaticAttribute + // $TEST$ target redeclaredAsStaticAttribute class »RedeclaredAsStaticAttribute« static attr RedeclaredAsStaticAttribute: Int - # $TEST$ target redeclaredAsNestedClass + // $TEST$ target redeclaredAsNestedClass class »RedeclaredAsNestedClass« class RedeclaredAsNestedClass - # $TEST$ target redeclaredAsNestedEnum + // $TEST$ target redeclaredAsNestedEnum class »RedeclaredAsNestedEnum« enum RedeclaredAsNestedEnum - # $TEST$ target redeclaredAsInstanceMethod + // $TEST$ target redeclaredAsInstanceMethod class »RedeclaredAsInstanceMethod« fun RedeclaredAsInstanceMethod() - # $TEST$ target redeclaredAsStaticMethod + // $TEST$ target redeclaredAsStaticMethod class »RedeclaredAsStaticMethod« static fun RedeclaredAsStaticMethod() - # $TEST$ target declaredPreviouslyAsInstanceAttribute + // $TEST$ target declaredPreviouslyAsInstanceAttribute attr DeclaredPreviouslyAsInstanceAttribute: Int class »DeclaredPreviouslyAsInstanceAttribute« - # $TEST$ target declaredPreviouslyAsInstanceMethod + // $TEST$ target declaredPreviouslyAsInstanceMethod fun DeclaredPreviouslyAsInstanceMethod() class »DeclaredPreviouslyAsInstanceMethod« } @@ -43,47 +43,47 @@ class MyNestedClass class AnotherClass pipeline myPipeline { - # $TEST$ references myNestedClass + // $TEST$ references myNestedClass MyClass.»MyNestedClass«; - # $TEST$ references redeclaredAsInstanceAttribute + // $TEST$ references redeclaredAsInstanceAttribute MyClass.»RedeclaredAsInstanceAttribute«; - # $TEST$ references redeclaredAsStaticAttribute + // $TEST$ references redeclaredAsStaticAttribute MyClass.»RedeclaredAsStaticAttribute«; - # $TEST$ references redeclaredAsNestedClass + // $TEST$ references redeclaredAsNestedClass MyClass.»RedeclaredAsNestedClass«; - # $TEST$ references redeclaredAsNestedEnum + // $TEST$ references redeclaredAsNestedEnum MyClass.»RedeclaredAsNestedEnum«; - # $TEST$ references redeclaredAsInstanceMethod + // $TEST$ references redeclaredAsInstanceMethod MyClass.»RedeclaredAsInstanceMethod«; - # $TEST$ references redeclaredAsStaticMethod + // $TEST$ references redeclaredAsStaticMethod MyClass.»RedeclaredAsStaticMethod«; - # $TEST$ references declaredPreviouslyAsInstanceAttribute + // $TEST$ references declaredPreviouslyAsInstanceAttribute MyClass.»DeclaredPreviouslyAsInstanceAttribute«; - # $TEST$ references declaredPreviouslyAsInstanceMethod + // $TEST$ references declaredPreviouslyAsInstanceMethod MyClass.»DeclaredPreviouslyAsInstanceMethod«; - # $TEST$ unresolved + // $TEST$ unresolved MyClass().»MyNestedClass«; - # $TEST$ unresolved + // $TEST$ unresolved MyClass.»AnotherClass«; - # $TEST$ unresolved + // $TEST$ unresolved AnotherClass.»MyNestedClass«; - # $TEST$ unresolved + // $TEST$ unresolved unresolved.»MyNestedClass«; - # $TEST$ unresolved + // $TEST$ unresolved MyClass.»unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/nested enums/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/nested enums/main.sdstest index 09b24d12..8829f39c 100644 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/nested enums/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/nested enums/main.sdstest @@ -1,40 +1,40 @@ package tests.scoping.memberAccesses.toClassMembers.nestedEnums class MyClass { - # $TEST$ target myNestedEnum + // $TEST$ target myNestedEnum enum »MyNestedEnum« - # $TEST$ target redeclaredAsInstanceAttribute + // $TEST$ target redeclaredAsInstanceAttribute enum »RedeclaredAsInstanceAttribute« attr RedeclaredAsInstanceAttribute: Int - # $TEST$ target redeclaredAsStaticAttribute + // $TEST$ target redeclaredAsStaticAttribute enum »RedeclaredAsStaticAttribute« static attr RedeclaredAsStaticAttribute: Int - # $TEST$ target redeclaredAsNestedClass + // $TEST$ target redeclaredAsNestedClass enum »RedeclaredAsNestedClass« class RedeclaredAsNestedClass - # $TEST$ target redeclaredAsNestedEnum + // $TEST$ target redeclaredAsNestedEnum enum »RedeclaredAsNestedEnum« enum RedeclaredAsNestedEnum - # $TEST$ target redeclaredAsInstanceMethod + // $TEST$ target redeclaredAsInstanceMethod enum »RedeclaredAsInstanceMethod« fun RedeclaredAsInstanceMethod() - # $TEST$ target redeclaredAsStaticMethod + // $TEST$ target redeclaredAsStaticMethod enum »RedeclaredAsStaticMethod« static fun RedeclaredAsStaticMethod() - # $TEST$ target declaredPreviouslyAsInstanceAttribute + // $TEST$ target declaredPreviouslyAsInstanceAttribute attr DeclaredPreviouslyAsInstanceAttribute: Int enum »DeclaredPreviouslyAsInstanceAttribute« - # $TEST$ target declaredPreviouslyAsInstanceMethod + // $TEST$ target declaredPreviouslyAsInstanceMethod fun DeclaredPreviouslyAsInstanceMethod() enum »DeclaredPreviouslyAsInstanceMethod« } @@ -44,47 +44,47 @@ class AnotherClass enum AnotherEnum pipeline myPipeline { - # $TEST$ references myNestedEnum + // $TEST$ references myNestedEnum MyClass.»MyNestedEnum«; - # $TEST$ references redeclaredAsInstanceAttribute + // $TEST$ references redeclaredAsInstanceAttribute MyClass.»RedeclaredAsInstanceAttribute«; - # $TEST$ references redeclaredAsStaticAttribute + // $TEST$ references redeclaredAsStaticAttribute MyClass.»RedeclaredAsStaticAttribute«; - # $TEST$ references redeclaredAsNestedClass + // $TEST$ references redeclaredAsNestedClass MyClass.»RedeclaredAsNestedClass«; - # $TEST$ references redeclaredAsNestedEnum + // $TEST$ references redeclaredAsNestedEnum MyClass.»RedeclaredAsNestedEnum«; - # $TEST$ references redeclaredAsInstanceMethod + // $TEST$ references redeclaredAsInstanceMethod MyClass.»RedeclaredAsInstanceMethod«; - # $TEST$ references redeclaredAsStaticMethod + // $TEST$ references redeclaredAsStaticMethod MyClass.»RedeclaredAsStaticMethod«; - # $TEST$ references declaredPreviouslyAsInstanceAttribute + // $TEST$ references declaredPreviouslyAsInstanceAttribute MyClass.»DeclaredPreviouslyAsInstanceAttribute«; - # $TEST$ references declaredPreviouslyAsInstanceMethod + // $TEST$ references declaredPreviouslyAsInstanceMethod MyClass.»DeclaredPreviouslyAsInstanceMethod«; - # $TEST$ unresolved + // $TEST$ unresolved MyClass().»MyNestedEnum«; - # $TEST$ unresolved + // $TEST$ unresolved MyClass.»AnotherEnum«; - # $TEST$ unresolved + // $TEST$ unresolved AnotherClass.»MyNestedEnum«; - # $TEST$ unresolved + // $TEST$ unresolved unresolved.»MyNestedEnum«; - # $TEST$ unresolved + // $TEST$ unresolved MyClass.»unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/overriding/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/overriding/main.sdstest index eab702f7..67073732 100644 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/overriding/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/overriding/main.sdstest @@ -1,25 +1,25 @@ package tests.scoping.memberAccesses.toClassMembers.overriding class MySuperClass { - # $TEST$ target MySuperClass_myInstanceAttribute + // $TEST$ target MySuperClass_myInstanceAttribute attr »myInstanceAttribute«: Int - # $TEST$ target MySuperClass_myInstanceMethod + // $TEST$ target MySuperClass_myInstanceMethod fun »myInstanceMethod1«() } class MyClass() sub MySuperClass { - # $TEST$ target MyClass_myInstanceAttribute + // $TEST$ target MyClass_myInstanceAttribute attr »myInstanceAttribute«: Int - # $TEST$ target MyClass_myInstanceMethod + // $TEST$ target MyClass_myInstanceMethod fun »myInstanceMethod1«() } pipeline myPipeline { - # $TEST$ references MyClass_myInstanceAttribute + // $TEST$ references MyClass_myInstanceAttribute MyClass().»myInstanceAttribute«; - # $TEST$ references MyClass_myInstanceMethod + // $TEST$ references MyClass_myInstanceMethod MyClass().»myInstanceMethod1«(); } diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/static attributes/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/static attributes/main.sdstest index 1065e3a4..0c9d77c5 100644 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/static attributes/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/static attributes/main.sdstest @@ -1,40 +1,40 @@ package tests.scoping.memberAccesses.toClassMembers.staticAttributes class MyClass() { - # $TEST$ target myStaticAttribute + // $TEST$ target myStaticAttribute static attr »myStaticAttribute«: Int - # $TEST$ target redeclaredAsInstanceAttribute + // $TEST$ target redeclaredAsInstanceAttribute static attr »redeclaredAsInstanceAttribute«: Int attr redeclaredAsInstanceAttribute: Int - # $TEST$ target redeclaredAsStaticAttribute + // $TEST$ target redeclaredAsStaticAttribute static attr »redeclaredAsStaticAttribute«: Int static attr redeclaredAsStaticAttribute: Int - # $TEST$ target redeclaredAsNestedClass + // $TEST$ target redeclaredAsNestedClass static attr »redeclaredAsNestedClass«: Int class redeclaredAsNestedClass - # $TEST$ target redeclaredAsNestedEnum + // $TEST$ target redeclaredAsNestedEnum static attr »redeclaredAsNestedEnum«: Int enum redeclaredAsNestedEnum - # $TEST$ target redeclaredAsInstanceMethod + // $TEST$ target redeclaredAsInstanceMethod static attr »redeclaredAsInstanceMethod«: Int fun redeclaredAsInstanceMethod() - # $TEST$ target redeclaredAsStaticMethod + // $TEST$ target redeclaredAsStaticMethod static attr »redeclaredAsStaticMethod«: Int static fun redeclaredAsStaticMethod() - # $TEST$ target declaredPreviouslyAsInstanceAttribute + // $TEST$ target declaredPreviouslyAsInstanceAttribute attr declaredPreviouslyAsInstanceAttribute: Int static attr »declaredPreviouslyAsInstanceAttribute«: Int - # $TEST$ target declaredPreviouslyAsInstanceMethod + // $TEST$ target declaredPreviouslyAsInstanceMethod fun declaredPreviouslyAsInstanceMethod() static attr »declaredPreviouslyAsInstanceMethod«: Int } @@ -42,44 +42,44 @@ class MyClass() { class AnotherClass pipeline myPipeline { - # $TEST$ references myStaticAttribute + // $TEST$ references myStaticAttribute MyClass.»myStaticAttribute«; - # $TEST$ references redeclaredAsInstanceAttribute + // $TEST$ references redeclaredAsInstanceAttribute MyClass.»redeclaredAsInstanceAttribute«; - # $TEST$ references redeclaredAsStaticAttribute + // $TEST$ references redeclaredAsStaticAttribute MyClass.»redeclaredAsStaticAttribute«; - # $TEST$ references redeclaredAsNestedClass + // $TEST$ references redeclaredAsNestedClass MyClass.»redeclaredAsNestedClass«; - # $TEST$ references redeclaredAsNestedEnum + // $TEST$ references redeclaredAsNestedEnum MyClass.»redeclaredAsNestedEnum«; - # $TEST$ references redeclaredAsInstanceMethod + // $TEST$ references redeclaredAsInstanceMethod MyClass.»redeclaredAsInstanceMethod«; - # $TEST$ references redeclaredAsStaticMethod + // $TEST$ references redeclaredAsStaticMethod MyClass.»redeclaredAsStaticMethod«; - # $TEST$ references declaredPreviouslyAsInstanceAttribute + // $TEST$ references declaredPreviouslyAsInstanceAttribute MyClass.»declaredPreviouslyAsInstanceAttribute«; - # $TEST$ references declaredPreviouslyAsInstanceMethod + // $TEST$ references declaredPreviouslyAsInstanceMethod MyClass.»declaredPreviouslyAsInstanceMethod«; - # $TEST$ unresolved + // $TEST$ unresolved MyClass().»myStaticAttribute«; - # $TEST$ unresolved + // $TEST$ unresolved AnotherClass.»myStaticAttribute«; - # $TEST$ unresolved + // $TEST$ unresolved unresolved.»myStaticAttribute«; - # $TEST$ unresolved + // $TEST$ unresolved MyClass.»unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/static methods/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/static methods/main.sdstest index 0388e103..7467d7dc 100644 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/static methods/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/static methods/main.sdstest @@ -1,40 +1,40 @@ package tests.scoping.memberAccesses.toClassMembers.staticMethods class MyClass { - # $TEST$ target myStaticMethod + // $TEST$ target myStaticMethod static fun »myStaticMethod«() - # $TEST$ target redeclaredAsInstanceAttribute + // $TEST$ target redeclaredAsInstanceAttribute static fun »redeclaredAsInstanceAttribute«() attr redeclaredAsInstanceAttribute: Int - # $TEST$ target redeclaredAsStaticAttribute + // $TEST$ target redeclaredAsStaticAttribute static fun »redeclaredAsStaticAttribute«() static attr redeclaredAsStaticAttribute: Int - # $TEST$ target redeclaredAsNestedClass + // $TEST$ target redeclaredAsNestedClass static fun »redeclaredAsNestedClass«() class redeclaredAsNestedClass - # $TEST$ target redeclaredAsNestedEnum + // $TEST$ target redeclaredAsNestedEnum static fun »redeclaredAsNestedEnum«() enum redeclaredAsNestedEnum - # $TEST$ target redeclaredAsInstanceMethod + // $TEST$ target redeclaredAsInstanceMethod static fun »redeclaredAsInstanceMethod«() fun redeclaredAsInstanceMethod() - # $TEST$ target redeclaredAsStaticMethod + // $TEST$ target redeclaredAsStaticMethod static fun »redeclaredAsStaticMethod«() static fun redeclaredAsStaticMethod() - # $TEST$ target declaredPreviouslyAsInstanceAttribute + // $TEST$ target declaredPreviouslyAsInstanceAttribute attr declaredPreviouslyAsInstanceAttribute: Int static fun »declaredPreviouslyAsInstanceAttribute«() - # $TEST$ target declaredPreviouslyAsInstanceMethod + // $TEST$ target declaredPreviouslyAsInstanceMethod fun declaredPreviouslyAsInstanceMethod() static fun »declaredPreviouslyAsInstanceMethod«() } @@ -43,47 +43,47 @@ class AnotherClass fun anotherFunction() pipeline myPipeline { - # $TEST$ references myStaticMethod + // $TEST$ references myStaticMethod MyClass.»myStaticMethod«; - # $TEST$ references redeclaredAsInstanceAttribute + // $TEST$ references redeclaredAsInstanceAttribute MyClass.»redeclaredAsInstanceAttribute«; - # $TEST$ references redeclaredAsStaticAttribute + // $TEST$ references redeclaredAsStaticAttribute MyClass.»redeclaredAsStaticAttribute«; - # $TEST$ references redeclaredAsNestedClass + // $TEST$ references redeclaredAsNestedClass MyClass.»redeclaredAsNestedClass«; - # $TEST$ references redeclaredAsNestedEnum + // $TEST$ references redeclaredAsNestedEnum MyClass.»redeclaredAsNestedEnum«; - # $TEST$ references redeclaredAsInstanceMethod + // $TEST$ references redeclaredAsInstanceMethod MyClass.»redeclaredAsInstanceMethod«; - # $TEST$ references redeclaredAsStaticMethod + // $TEST$ references redeclaredAsStaticMethod MyClass.»redeclaredAsStaticMethod«; - # $TEST$ references declaredPreviouslyAsInstanceAttribute + // $TEST$ references declaredPreviouslyAsInstanceAttribute MyClass.»declaredPreviouslyAsInstanceAttribute«; - # $TEST$ references declaredPreviouslyAsInstanceMethod + // $TEST$ references declaredPreviouslyAsInstanceMethod MyClass.»declaredPreviouslyAsInstanceMethod«; - # $TEST$ unresolved + // $TEST$ unresolved MyClass().»myStaticMethod«; - # $TEST$ unresolved + // $TEST$ unresolved MyClass.»anotherFunction«; - # $TEST$ unresolved + // $TEST$ unresolved AnotherClass.»myStaticMethod«; - # $TEST$ unresolved + // $TEST$ unresolved unresolved.»myStaticMethod«; - # $TEST$ unresolved + // $TEST$ unresolved MyClass.»unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to enum variants/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to enum variants/main.sdstest index e5956c84..3f913c06 100644 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to enum variants/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/member accesses/to enum variants/main.sdstest @@ -1,10 +1,10 @@ package tests.scoping.memberAccesses.toEnumVariants enum MyEnum { - # $TEST$ target myEnumVariant + // $TEST$ target myEnumVariant »MyEnumVariant« - # $TEST$ target redeclaredEnumVariant + // $TEST$ target redeclaredEnumVariant »RedeclaredEnumVariant« RedeclaredEnumVariant } @@ -12,22 +12,22 @@ enum MyEnum { enum AnotherEnum pipeline myPipeline { - # $TEST$ references myEnumVariant + // $TEST$ references myEnumVariant MyEnum.»MyEnumVariant«; - # $TEST$ references redeclaredEnumVariant + // $TEST$ references redeclaredEnumVariant MyEnum.»RedeclaredEnumVariant«; - # $TEST$ unresolved + // $TEST$ unresolved AnotherEnum().»MyEnumVariant«; - # $TEST$ unresolved + // $TEST$ unresolved AnotherEnum.»MyEnumVariant«; - # $TEST$ unresolved + // $TEST$ unresolved unresolved.»MyEnumVariant«; - # $TEST$ unresolved + // $TEST$ unresolved MyEnum.»unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to parameter of enum variants/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to parameter of enum variants/main.sdstest index b7acda8a..2ba689a1 100644 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to parameter of enum variants/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/member accesses/to parameter of enum variants/main.sdstest @@ -2,10 +2,10 @@ package tests.scoping.memberAccesses.toParametersOfEnumVariants enum MyEnum { MyEnumVariant( - # $TEST$ target param + // $TEST$ target param »param«: Int, - # $TEST$ target redeclared + // $TEST$ target redeclared »redeclared«: Int, redeclared: Int, ) @@ -18,28 +18,28 @@ enum MyOtherEnum { } pipeline myPipeline { - # $TEST$ references param + // $TEST$ references param MyEnum.MyEnumVariant().»param«; - # $TEST$ references redeclared + // $TEST$ references redeclared MyEnum.MyEnumVariant().»redeclared«; - # $TEST$ unresolved + // $TEST$ unresolved MyOtherEnum.MyEnumVariant.»param«; - # $TEST$ unresolved + // $TEST$ unresolved MyEnum.MyOtherEnumVariant().»param«; - # $TEST$ unresolved + // $TEST$ unresolved MyOtherEnum.MyEnumVariant().»param«; - # $TEST$ unresolved + // $TEST$ unresolved MyEnum.MyEnumVariant().»unresolved«; - # $TEST$ unresolved + // $TEST$ unresolved MyEnum.unresolved().»param«; - # $TEST$ unresolved + // $TEST$ unresolved unresolved.MyEnumVariant().»param«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/call with nullable receiver/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/call with nullable receiver/main.sdstest index 8b07eec6..85517938 100644 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/call with nullable receiver/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/call with nullable receiver/main.sdstest @@ -1,33 +1,33 @@ package tests.scoping.memberAccesses.toResults.callWithNullableReceiver class MyClass { - # $TEST$ target functionWithOneResult_singleResult + // $TEST$ target functionWithOneResult_singleResult fun functionWithOneResult() -> »singleResult«: Int - # $TEST$ target functionWithTwoResults_result1 + // $TEST$ target functionWithTwoResults_result1 fun functionWithTwoResults() -> (»result1«: Int, result2: Int) } segment mySegment( myClassOrNull: MyClass? ) { - # $TEST$ references functionWithOneResult_singleResult + // $TEST$ references functionWithOneResult_singleResult myClassOrNull?.functionWithOneResult().»singleResult«; - # $TEST$ references functionWithTwoResults_result1 + // $TEST$ references functionWithTwoResults_result1 myClassOrNull?.functionWithTwoResults().»result1«; - # $TEST$ references functionWithOneResult_singleResult + // $TEST$ references functionWithOneResult_singleResult myClassOrNull?.functionWithOneResult?().»singleResult«; - # $TEST$ references functionWithTwoResults_result1 + // $TEST$ references functionWithTwoResults_result1 myClassOrNull?.functionWithTwoResults?().»result1«; - # $TEST$ references functionWithOneResult_singleResult + // $TEST$ references functionWithOneResult_singleResult myClassOrNull?.functionWithOneResult?()?.»singleResult«; - # $TEST$ references functionWithTwoResults_result1 + // $TEST$ references functionWithTwoResults_result1 myClassOrNull?.functionWithTwoResults?()?.»result1«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of block lambdas (matching member)/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of block lambdas (matching member)/main.sdstest index 2c8dda49..b197f34b 100644 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of block lambdas (matching member)/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of block lambdas (matching member)/main.sdstest @@ -1,12 +1,12 @@ package tests.scoping.memberAccesses.toResults.ofBlockLambdas.matchingMember class MyClass() { - # $TEST$ target MyClass_result + // $TEST$ target MyClass_result attr »result«: Int } enum MyEnum { - # $TEST$ target MyEnum_result + // $TEST$ target MyEnum_result MyEnumVariant(»result«: Int) } @@ -19,9 +19,9 @@ pipeline myPipeline { yield result = MyEnum.MyEnumVariant(0); }; - # $TEST$ references MyClass_result + // $TEST$ references MyClass_result f1().»result«; - # $TEST$ references MyEnum_result + // $TEST$ references MyEnum_result f2().»result«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of block lambdas/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of block lambdas/main.sdstest index ffe311a9..208ee9b3 100644 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of block lambdas/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of block lambdas/main.sdstest @@ -2,19 +2,19 @@ package tests.scoping.memberAccesses.toResults.ofBlockLambdas pipeline myPipeline { val lambdaWithOneResult = () { - # $TEST$ target lambdaWithOneResult_singleResult + // $TEST$ target lambdaWithOneResult_singleResult yield »singleResult« = 1; }; val lambdaWithTwoResults = () { - # $TEST$ target lambdaWithTwoResults_result1 + // $TEST$ target lambdaWithTwoResults_result1 yield »result1« = 1; yield result1 = 1; yield result2 = 1; }; - # $TEST$ references lambdaWithOneResult_singleResult + // $TEST$ references lambdaWithOneResult_singleResult lambdaWithOneResult().»singleResult«; - # $TEST$ references lambdaWithTwoResults_result1 + // $TEST$ references lambdaWithTwoResults_result1 lambdaWithTwoResults().»result1«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of callable types (matching member)/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of callable types (matching member)/main.sdstest index 559e905d..a7cc1c82 100644 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of callable types (matching member)/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of callable types (matching member)/main.sdstest @@ -1,12 +1,12 @@ package tests.scoping.memberAccesses.toResults.ofCallableTypes.matchingMember class MyClass() { - # $TEST$ target MyClass_result + // $TEST$ target MyClass_result attr »result«: Int } enum MyEnum { - # $TEST$ target MyEnum_result + // $TEST$ target MyEnum_result MyEnumVariant(»result«: Int) } @@ -15,9 +15,9 @@ segment mySegment( f2: () -> result: MyEnum.MyEnumVariant, ) { - # $TEST$ references MyClass_result + // $TEST$ references MyClass_result f1().»result«; - # $TEST$ references MyEnum_result + // $TEST$ references MyEnum_result f2().»result«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of callable types/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of callable types/main.sdstest index 63220e69..1e4d3c66 100644 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of callable types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of callable types/main.sdstest @@ -1,15 +1,15 @@ package tests.scoping.memberAccesses.toResults.ofCallableTypes segment mySegment( - # $TEST$ target callableWithOneResult_singleResult + // $TEST$ target callableWithOneResult_singleResult callableWithOneResult: () -> »singleResult«: Int, - # $TEST$ target callableWithTwoResults_result1 + // $TEST$ target callableWithTwoResults_result1 callableWithTwoResults: () -> (»result1«: Int, result2: Int), ) { - # $TEST$ references callableWithOneResult_singleResult + // $TEST$ references callableWithOneResult_singleResult callableWithOneResult().»singleResult«; - # $TEST$ references callableWithTwoResults_result1 + // $TEST$ references callableWithTwoResults_result1 callableWithTwoResults().»result1«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of functions (matching member)/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of functions (matching member)/main.sdstest index 59dad608..263e0eec 100644 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of functions (matching member)/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of functions (matching member)/main.sdstest @@ -1,12 +1,12 @@ package tests.scoping.memberAccesses.toResults.ofFunctions.matchingMember class MyClass() { - # $TEST$ target MyClass_result + // $TEST$ target MyClass_result attr »result«: Int } enum MyEnum { - # $TEST$ target MyEnum_result + // $TEST$ target MyEnum_result MyEnumVariant(»result«: Int) } @@ -14,9 +14,9 @@ fun f1() -> result: MyClass fun f2() -> result: MyEnum.MyEnumVariant pipeline myPipeline { - # $TEST$ references MyClass_result + // $TEST$ references MyClass_result f1().»result«; - # $TEST$ references MyEnum_result + // $TEST$ references MyEnum_result f2().»result«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of functions/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of functions/main.sdstest index ec56084d..eeba6f3f 100644 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of functions/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of functions/main.sdstest @@ -1,15 +1,15 @@ package tests.scoping.memberAccesses.toResults.ofFunctions -# $TEST$ target functionWithOneResult_singleResult +// $TEST$ target functionWithOneResult_singleResult fun functionWithOneResult() -> »singleResult«: Int -# $TEST$ target functionWithTwoResults_result1 +// $TEST$ target functionWithTwoResults_result1 fun functionWithTwoResults() -> (»result1«: Int, result2: Int) pipeline myPipeline { - # $TEST$ references functionWithOneResult_singleResult + // $TEST$ references functionWithOneResult_singleResult functionWithOneResult().»singleResult«; - # $TEST$ references functionWithTwoResults_result1 + // $TEST$ references functionWithTwoResults_result1 functionWithTwoResults().»result1«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of segments (matching member)/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of segments (matching member)/main.sdstest index ac4de705..79463aae 100644 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of segments (matching member)/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of segments (matching member)/main.sdstest @@ -1,12 +1,12 @@ package tests.scoping.memberAccesses.toResults.ofSegments.matchingMember class MyClass() { - # $TEST$ target MyClass_result + // $TEST$ target MyClass_result attr »result«: Int } enum MyEnum { - # $TEST$ target MyEnum_result + // $TEST$ target MyEnum_result MyEnumVariant(»result«: Int) } @@ -14,9 +14,9 @@ segment s1() -> result: MyClass {} segment s2() -> result: MyEnum.MyEnumVariant {} pipeline myPipeline { - # $TEST$ references MyClass_result + // $TEST$ references MyClass_result s1().»result«; - # $TEST$ references MyEnum_result + // $TEST$ references MyEnum_result s2().»result«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of segments/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of segments/main.sdstest index 05dbec12..ca1dbcaa 100644 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of segments/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of segments/main.sdstest @@ -1,15 +1,15 @@ package tests.scoping.memberAccesses.toResults.ofSegments -# $TEST$ target segmentWithOneResult_singleResult +// $TEST$ target segmentWithOneResult_singleResult segment segmentWithOneResult() -> »singleResult«: Int {} -# $TEST$ target segmentWithTwoResults_result1 +// $TEST$ target segmentWithTwoResults_result1 segment segmentWithTwoResults() -> (»result1«: Int, result2: Int) {} pipeline myPipeline { - # $TEST$ references segmentWithOneResult_singleResult + // $TEST$ references segmentWithOneResult_singleResult segmentWithOneResult().»singleResult«; - # $TEST$ references segmentWithTwoResults_result1 + // $TEST$ references segmentWithTwoResults_result1 segmentWithTwoResults().»result1«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main no imports or own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main no imports or own declarations.sdstest index 0bb2fb47..83bf6e2d 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main no imports or own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main no imports or own declarations.sdstest @@ -1,18 +1,18 @@ package tests.scoping.namedTypes.acrossFiles.toGlobalClasses segment mySegment( - # $TEST$ references same_MyClass + // $TEST$ references same_MyClass p1: »MyClass«, - # $TEST$ references same_ClassInSamePackage + // $TEST$ references same_ClassInSamePackage p2: »ClassInSamePackage«, - # $TEST$ references safeds_ClassInSafeDsPackage + // $TEST$ references safeds_ClassInSafeDsPackage p3: »ClassInSafeDsPackage«, - # $TEST$ unresolved + // $TEST$ unresolved p4: »ClassInAnotherPackage«, - # $TEST$ unresolved + // $TEST$ unresolved p5: »ClassWithoutPackage«, ) {} diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with imports and own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with imports and own declarations.sdstest index 52085076..86ba33e0 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with imports and own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with imports and own declarations.sdstest @@ -3,25 +3,25 @@ package tests.scoping.namedTypes.acrossFiles.toGlobalClasses from safeds.scoping.namedTypes.acrossFiles.toGlobalClasses import MyClass as MyOwnClass from tests.scoping.namedTypes.acrossFiles.toGlobalClasses.other import ClassInAnotherPackage, Class2InAnotherPackage -# $TEST$ target own_MyOwnClass +// $TEST$ target own_MyOwnClass class »MyOwnClass« segment mySegment( - # $TEST$ references own_MyOwnClass + // $TEST$ references own_MyOwnClass p1: »MyOwnClass«, - # $TEST$ references same_ClassInSamePackage + // $TEST$ references same_ClassInSamePackage p2: »ClassInSamePackage«, - # $TEST$ references safeds_ClassInSafeDsPackage + // $TEST$ references safeds_ClassInSafeDsPackage p3: »ClassInSafeDsPackage«, - # $TEST$ references other_ClassInAnotherPackage + // $TEST$ references other_ClassInAnotherPackage p4: »ClassInAnotherPackage«, - # $TEST$ references other_Class2InAnotherPackage + // $TEST$ references other_Class2InAnotherPackage p5: »Class2InAnotherPackage«, - # $TEST$ unresolved + // $TEST$ unresolved p6: »ClassWithoutPackage«, ) {} diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with multiple imports of same name.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with multiple imports of same name.sdstest index a1fd1f9e..2d9adf6d 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with multiple imports of same name.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with multiple imports of same name.sdstest @@ -5,6 +5,6 @@ from tests.scoping.namedTypes.acrossFiles.toGlobalClasses.other import MyClass from tests.scoping.namedTypes.acrossFiles.toGlobalClasses import MyClass segment mySegment( - # $TEST$ references safeds_MyClass + // $TEST$ references safeds_MyClass p: »MyClass«, ) {} diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with qualified import with alias.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with qualified import with alias.sdstest index 6f297e29..476df03c 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with qualified import with alias.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with qualified import with alias.sdstest @@ -5,28 +5,28 @@ from safeds.scoping.namedTypes.acrossFiles.toGlobalClasses import MyClass as MyC from tests.scoping.namedTypes.acrossFiles.toGlobalClasses.other import MyClass as MyClassInAnotherPackage segment mySegment( - # $TEST$ references same_MyClass + // $TEST$ references same_MyClass p1: »MyClass«, - # $TEST$ references same_ClassInSamePackage + // $TEST$ references same_ClassInSamePackage p2: »ClassInSamePackage«, - # $TEST$ references safeds_ClassInSafeDsPackage + // $TEST$ references safeds_ClassInSafeDsPackage p3: »ClassInSafeDsPackage«, - # $TEST$ unresolved + // $TEST$ unresolved p4: »ClassInAnotherPackage«, - # $TEST$ unresolved + // $TEST$ unresolved p5: »ClassWithoutPackage«, - # $TEST$ references same_MyClass + // $TEST$ references same_MyClass p6: »MyClassInSamePackage«, - # $TEST$ references safeds_MyClass + // $TEST$ references safeds_MyClass p7: »MyClassInSafeDsPackage«, - # $TEST$ references other_MyClass + // $TEST$ references other_MyClass p8: »MyClassInAnotherPackage«, ) {} diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with qualified import.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with qualified import.sdstest index 92cbabed..c29a526f 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with qualified import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with qualified import.sdstest @@ -4,24 +4,24 @@ from safeds.scoping.namedTypes.acrossFiles.toGlobalClasses import MyClass from tests.scoping.namedTypes.acrossFiles.toGlobalClasses.other import ClassInAnotherPackage, Class2InAnotherPackage, notANamedTypeDeclaration segment mySegment( - # $TEST$ references safeds_MyClass + // $TEST$ references safeds_MyClass p1: »MyClass«, - # $TEST$ references same_ClassInSamePackage + // $TEST$ references same_ClassInSamePackage p2: »ClassInSamePackage«, - # $TEST$ references safeds_ClassInSafeDsPackage + // $TEST$ references safeds_ClassInSafeDsPackage p3: »ClassInSafeDsPackage«, - # $TEST$ references other_ClassInAnotherPackage + // $TEST$ references other_ClassInAnotherPackage p4: »ClassInAnotherPackage«, - # $TEST$ references other_Class2InAnotherPackage + // $TEST$ references other_Class2InAnotherPackage p5: »Class2InAnotherPackage«, - # $TEST$ unresolved + // $TEST$ unresolved p6: »notANamedTypeDeclaration«, - # $TEST$ unresolved + // $TEST$ unresolved p7: »ClassWithoutPackage«, ) {} diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with wildcard import.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with wildcard import.sdstest index 161fc17e..c68c481c 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with wildcard import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with wildcard import.sdstest @@ -3,18 +3,18 @@ package tests.scoping.namedTypes.acrossFiles.toGlobalClasses from safeds.scoping.namedTypes.acrossFiles.toGlobalClasses import * segment mySegment( - # $TEST$ references safeds_MyClass + // $TEST$ references safeds_MyClass p1: »MyClass«, - # $TEST$ references same_ClassInSamePackage + // $TEST$ references same_ClassInSamePackage p2: »ClassInSamePackage«, - # $TEST$ references safeds_ClassInSafeDsPackage + // $TEST$ references safeds_ClassInSafeDsPackage p3: »ClassInSafeDsPackage«, - # $TEST$ unresolved + // $TEST$ unresolved p4: »ClassInAnotherPackage«, - # $TEST$ unresolved + // $TEST$ unresolved p5: »ClassWithoutPackage«, ) {} diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/resource other package.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/resource other package.sdstest index ede278c9..06528eef 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/resource other package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/resource other package.sdstest @@ -1,13 +1,13 @@ package tests.scoping.namedTypes.acrossFiles.toGlobalClasses.other -# $TEST$ target other_MyClass +// $TEST$ target other_MyClass class »MyClass« -# $TEST$ target other_ClassInAnotherPackage +// $TEST$ target other_ClassInAnotherPackage class »ClassInAnotherPackage« -# $TEST$ target other_Class2InAnotherPackage +// $TEST$ target other_Class2InAnotherPackage class »Class2InAnotherPackage« -# $TEST$ target other_notANamedTypeDeclaration +// $TEST$ target other_notANamedTypeDeclaration fun »notANamedTypeDeclaration«() diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/resource safeds package.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/resource safeds package.sdstest index fe9a62fc..a51a37c2 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/resource safeds package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/resource safeds package.sdstest @@ -1,7 +1,7 @@ package safeds.scoping.namedTypes.acrossFiles.toGlobalClasses -# $TEST$ target safeds_MyClass +// $TEST$ target safeds_MyClass class »MyClass« -# $TEST$ target safeds_ClassInSafeDsPackage +// $TEST$ target safeds_ClassInSafeDsPackage class »ClassInSafeDsPackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/resource same package.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/resource same package.sdstest index eeaf529c..742ed65e 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/resource same package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/resource same package.sdstest @@ -1,7 +1,7 @@ package tests.scoping.namedTypes.acrossFiles.toGlobalClasses -# $TEST$ target same_MyClass +// $TEST$ target same_MyClass class »MyClass« -# $TEST$ target same_ClassInSamePackage +// $TEST$ target same_ClassInSamePackage class »ClassInSamePackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/resource without package.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/resource without package.sdstest index 82705a3b..bcd07435 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/resource without package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/resource without package.sdstest @@ -1,5 +1,5 @@ -# $TEST$ target without_MyClass +// $TEST$ target without_MyClass class »MyClass« -# $TEST$ target without_ClassWithoutPackage +// $TEST$ target without_ClassWithoutPackage class »ClassWithoutPackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main no imports or own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main no imports or own declarations.sdstest index e7c60a79..7f0a0cef 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main no imports or own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main no imports or own declarations.sdstest @@ -1,18 +1,18 @@ package tests.scoping.namedTypes.acrossFiles.toGlobalEnums segment mySegment( - # $TEST$ references same_MyEnum + // $TEST$ references same_MyEnum p1: »MyEnum«, - # $TEST$ references same_EnumInSamePackage + // $TEST$ references same_EnumInSamePackage p2: »EnumInSamePackage«, - # $TEST$ references safeds_EnumInSafeDsPackage + // $TEST$ references safeds_EnumInSafeDsPackage p3: »EnumInSafeDsPackage«, - # $TEST$ unresolved + // $TEST$ unresolved p4: »EnumInAnotherPackage«, - # $TEST$ unresolved + // $TEST$ unresolved p5: »EnumWithoutPackage«, ) {} diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with imports and own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with imports and own declarations.sdstest index c226dfa2..e56ba80a 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with imports and own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with imports and own declarations.sdstest @@ -3,25 +3,25 @@ package tests.scoping.namedTypes.acrossFiles.toGlobalEnums from safeds.scoping.namedTypes.acrossFiles.toGlobalEnums import MyEnum as MyOwnEnum from tests.scoping.namedTypes.acrossFiles.toGlobalEnums.other import EnumInAnotherPackage, Enum2InAnotherPackage -# $TEST$ target own_MyOwnEnum +// $TEST$ target own_MyOwnEnum enum »MyOwnEnum« segment mySegment( - # $TEST$ references own_MyOwnEnum + // $TEST$ references own_MyOwnEnum p1: »MyOwnEnum«, - # $TEST$ references same_EnumInSamePackage + // $TEST$ references same_EnumInSamePackage p2: »EnumInSamePackage«, - # $TEST$ references safeds_EnumInSafeDsPackage + // $TEST$ references safeds_EnumInSafeDsPackage p3: »EnumInSafeDsPackage«, - # $TEST$ references other_EnumInAnotherPackage + // $TEST$ references other_EnumInAnotherPackage p4: »EnumInAnotherPackage«, - # $TEST$ references other_Enum2InAnotherPackage + // $TEST$ references other_Enum2InAnotherPackage p5: »Enum2InAnotherPackage«, - # $TEST$ unresolved + // $TEST$ unresolved p6: »EnumWithoutPackage«, ) {} diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with multiple imports of same name.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with multiple imports of same name.sdstest index 80a11ede..b13ad0d2 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with multiple imports of same name.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with multiple imports of same name.sdstest @@ -5,6 +5,6 @@ from tests.scoping.namedTypes.acrossFiles.toGlobalEnums.other import MyEnum from tests.scoping.namedTypes.acrossFiles.toGlobalEnums import MyEnum segment mySegment( - # $TEST$ references safeds_MyEnum + // $TEST$ references safeds_MyEnum p: »MyEnum«, ) {} diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with qualified import with alias.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with qualified import with alias.sdstest index 9de0ca25..fbd4b754 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with qualified import with alias.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with qualified import with alias.sdstest @@ -5,29 +5,29 @@ from safeds.scoping.namedTypes.acrossFiles.toGlobalEnums import MyEnum as MyEnum from tests.scoping.namedTypes.acrossFiles.toGlobalEnums.other import MyEnum as MyEnumInAnotherPackage segment mySegment( - # $TEST$ references same_MyEnum + // $TEST$ references same_MyEnum p1: »MyEnum«, - # $TEST$ references same_EnumInSamePackage + // $TEST$ references same_EnumInSamePackage p2: »EnumInSamePackage«, - # $TEST$ references safeds_EnumInSafeDsPackage + // $TEST$ references safeds_EnumInSafeDsPackage p3: »EnumInSafeDsPackage«, - # $TEST$ unresolved + // $TEST$ unresolved p4: »EnumInAnotherPackage«, - # $TEST$ unresolved + // $TEST$ unresolved p5: »EnumWithoutPackage«, - # $TEST$ references same_MyEnum + // $TEST$ references same_MyEnum p6: »MyEnumInSamePackage«, - # $TEST$ references safeds_MyEnum + // $TEST$ references safeds_MyEnum p7: »MyEnumInSafeDsPackage«, - # $TEST$ references other_MyEnum + // $TEST$ references other_MyEnum p8: »MyEnumInAnotherPackage«, ) {} diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with qualified import.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with qualified import.sdstest index 64313d79..155e02e5 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with qualified import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with qualified import.sdstest @@ -4,24 +4,24 @@ from safeds.scoping.namedTypes.acrossFiles.toGlobalEnums import MyEnum from tests.scoping.namedTypes.acrossFiles.toGlobalEnums.other import EnumInAnotherPackage, Enum2InAnotherPackage, notANamedTypeDeclaration segment mySegment( - # $TEST$ references safeds_MyEnum + // $TEST$ references safeds_MyEnum p1: »MyEnum«, - # $TEST$ references same_EnumInSamePackage + // $TEST$ references same_EnumInSamePackage p2: »EnumInSamePackage«, - # $TEST$ references safeds_EnumInSafeDsPackage + // $TEST$ references safeds_EnumInSafeDsPackage p3: »EnumInSafeDsPackage«, - # $TEST$ references other_EnumInAnotherPackage + // $TEST$ references other_EnumInAnotherPackage p4: »EnumInAnotherPackage«, - # $TEST$ references other_Enum2InAnotherPackage + // $TEST$ references other_Enum2InAnotherPackage p5: »Enum2InAnotherPackage«, - # $TEST$ unresolved + // $TEST$ unresolved p6: »notANamedTypeDeclaration«, - # $TEST$ unresolved + // $TEST$ unresolved p7: »EnumWithoutPackage«, ) {} diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with wildcard import.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with wildcard import.sdstest index b1e1c5f1..a3970f20 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with wildcard import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with wildcard import.sdstest @@ -3,18 +3,18 @@ package tests.scoping.namedTypes.acrossFiles.toGlobalEnums from safeds.scoping.namedTypes.acrossFiles.toGlobalEnums import * segment mySegment( - # $TEST$ references safeds_MyEnum + // $TEST$ references safeds_MyEnum p1: »MyEnum«, - # $TEST$ references same_EnumInSamePackage + // $TEST$ references same_EnumInSamePackage p2: »EnumInSamePackage«, - # $TEST$ references safeds_EnumInSafeDsPackage + // $TEST$ references safeds_EnumInSafeDsPackage p3: »EnumInSafeDsPackage«, - # $TEST$ unresolved + // $TEST$ unresolved p4: »EnumInAnotherPackage«, - # $TEST$ unresolved + // $TEST$ unresolved p5: »EnumWithoutPackage«, ) {} diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/resource other package.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/resource other package.sdstest index 63d3323f..d5c036c0 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/resource other package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/resource other package.sdstest @@ -1,13 +1,13 @@ package tests.scoping.namedTypes.acrossFiles.toGlobalEnums.other -# $TEST$ target other_MyEnum +// $TEST$ target other_MyEnum enum »MyEnum« -# $TEST$ target other_EnumInAnotherPackage +// $TEST$ target other_EnumInAnotherPackage enum »EnumInAnotherPackage« -# $TEST$ target other_Enum2InAnotherPackage +// $TEST$ target other_Enum2InAnotherPackage enum »Enum2InAnotherPackage« -# $TEST$ target other_notANamedTypeDeclaration +// $TEST$ target other_notANamedTypeDeclaration fun »notANamedTypeDeclaration«() diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/resource safeds package.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/resource safeds package.sdstest index 25160a64..0c032246 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/resource safeds package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/resource safeds package.sdstest @@ -1,7 +1,7 @@ package safeds.scoping.namedTypes.acrossFiles.toGlobalEnums -# $TEST$ target safeds_MyEnum +// $TEST$ target safeds_MyEnum enum »MyEnum« -# $TEST$ target safeds_EnumInSafeDsPackage +// $TEST$ target safeds_EnumInSafeDsPackage enum »EnumInSafeDsPackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/resource same package.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/resource same package.sdstest index 952f0a87..c5e7e0f0 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/resource same package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/resource same package.sdstest @@ -1,7 +1,7 @@ package tests.scoping.namedTypes.acrossFiles.toGlobalEnums -# $TEST$ target same_MyEnum +// $TEST$ target same_MyEnum enum »MyEnum« -# $TEST$ target same_EnumInSamePackage +// $TEST$ target same_EnumInSamePackage enum »EnumInSamePackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/resource without package.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/resource without package.sdstest index b0052f12..7587c7e2 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/resource without package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/resource without package.sdstest @@ -1,5 +1,5 @@ -# $TEST$ target without_MyEnum +// $TEST$ target without_MyEnum enum »MyEnum« -# $TEST$ target without_EnumWithoutPackage +// $TEST$ target without_EnumWithoutPackage enum »EnumWithoutPackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to containing named type declarations/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to containing named type declarations/main.sdstest index d9b0d992..6f334dad 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to containing named type declarations/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to containing named type declarations/main.sdstest @@ -1,89 +1,89 @@ package tests.scoping.namedTypes.inSameFile.toContainingNamedTypeDeclarations -# $TEST$ target outerClass +// $TEST$ target outerClass class »MyClass«< - # $TEST$ references outerClass + // $TEST$ references outerClass T sub »MyClass« >( - # $TEST$ references outerClass + // $TEST$ references outerClass p: »MyClass« -# $TEST$ references outerClass +// $TEST$ references outerClass ) sub »MyClass« { - # $TEST$ references outerClass + // $TEST$ references outerClass attr a1: »MyClass« - # $TEST$ unresolved + // $TEST$ unresolved attr a2: »MyEnum« fun f< - # $TEST$ references outerClass + // $TEST$ references outerClass T1 sub »MyClass«, - # $TEST$ unresolved + // $TEST$ unresolved T2 sub »MyEnum«, >( - # $TEST$ references outerClass + // $TEST$ references outerClass p1: »MyClass«, - # $TEST$ unresolved + // $TEST$ unresolved p2: »MyEnum« ) -> ( - # $TEST$ references outerClass + // $TEST$ references outerClass r1: »MyClass«, - # $TEST$ unresolved + // $TEST$ unresolved r2: »MyEnum« ) - # $TEST$ target enum + // $TEST$ target enum enum »MyEnum« { - # $TEST$ target variant + // $TEST$ target variant »MyEnumVariant«( - # $TEST$ references outerClass + // $TEST$ references outerClass p1: »MyClass«, - # $TEST$ references enum + // $TEST$ references enum p2: »MyEnum«, - # $TEST$ references variant + // $TEST$ references variant p3: »MyEnumVariant«, ) } - # $TEST$ target innerClass + // $TEST$ target innerClass class »MyClass«( - # $TEST$ references innerClass + // $TEST$ references innerClass p1: »MyClass«, - # $TEST$ unresolved + // $TEST$ unresolved p2: »MyEnum«, - # $TEST$ references innerClass - # $TEST$ unresolved + // $TEST$ references innerClass + // $TEST$ unresolved ) sub »MyClass«, »MyEnum« { - # $TEST$ references innerClass + // $TEST$ references innerClass attr a1: »MyClass« - # $TEST$ unresolved + // $TEST$ unresolved attr a2: »MyEnum« fun f< - # $TEST$ references innerClass + // $TEST$ references innerClass T1 sub »MyClass«, - # $TEST$ unresolved + // $TEST$ unresolved T2 sub »MyEnum«, >( - # $TEST$ references innerClass + // $TEST$ references innerClass p1: »MyClass«, - # $TEST$ unresolved + // $TEST$ unresolved p2: »MyEnum«, ) -> ( - # $TEST$ references innerClass + // $TEST$ references innerClass r1: »MyClass«, - # $TEST$ unresolved + // $TEST$ unresolved r2: »MyEnum«, ) } diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to enum variants in global enums/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to enum variants in global enums/main.sdstest index 257d200b..47638259 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to enum variants in global enums/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to enum variants in global enums/main.sdstest @@ -1,46 +1,46 @@ package tests.scoping.namedTypes.inSameFile.toEnumVariantInGlobalEnums enum BeforeEnum { - # $TEST$ target before + // $TEST$ target before »BeforeVariant« Variant1 - # $TEST$ unresolved + // $TEST$ unresolved Variant2(a: »Variant1«) } class BeforeVariant segment mySegment( - # $TEST$ references before + // $TEST$ references before p1: BeforeEnum.»BeforeVariant«, - # $TEST$ references after + // $TEST$ references after p2: AfterEnum.»AfterVariant«, - # $TEST$ unresolved + // $TEST$ unresolved p3: AfterEnum.»BeforeVariant«, - # $TEST$ unresolved + // $TEST$ unresolved p4: BeforeEnum.»AfterVariant«, - # $TEST$ unresolved + // $TEST$ unresolved p5: BeforeEnum.»Unresolved«, - # $TEST$ unresolved + // $TEST$ unresolved p6: AfterEnum.»Unresolved«, - # $TEST$ unresolved + // $TEST$ unresolved p7: Unresolved.»BeforeVariant«, - # $TEST$ unresolved + // $TEST$ unresolved p8: Unresolved.»AfterVariant«, ) {} class AfterVariant enum AfterEnum { - # $TEST$ target after + // $TEST$ target after »AfterVariant« } diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to enum variants in nested enums/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to enum variants in nested enums/main.sdstest index ab8ce73e..26c1e68f 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to enum variants in nested enums/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to enum variants in nested enums/main.sdstest @@ -2,12 +2,12 @@ package tests.scoping.namedTypes.inSameFile.toEnumVariantsInNestedEnums class BeforeClass { enum BeforeEnum { - # $TEST$ target before + // $TEST$ target before »BeforeVariant« Variant1 - # $TEST$ unresolved + // $TEST$ unresolved Variant2(a: »Variant1«) } } @@ -17,28 +17,28 @@ enum BeforeEnum { } segment mySegment( - # $TEST$ references before + // $TEST$ references before p1: BeforeClass.BeforeEnum.»BeforeVariant«, - # $TEST$ references after + // $TEST$ references after p2: AfterClass.AfterEnum.»AfterVariant«, - # $TEST$ unresolved + // $TEST$ unresolved p3: AfterClass.AfterEnum.»BeforeVariant«, - # $TEST$ unresolved + // $TEST$ unresolved p4: BeforeClass.BeforeEnum.»AfterVariant«, - # $TEST$ unresolved + // $TEST$ unresolved p5: BeforeClass.BeforeEnum.»Unresolved«, - # $TEST$ unresolved + // $TEST$ unresolved p6: AfterClass.AfterEnum.»Unresolved«, - # $TEST$ unresolved + // $TEST$ unresolved p7: BeforeClass.Unresolved.»BeforeVariant«, - # $TEST$ unresolved + // $TEST$ unresolved p8: AfterClass.Unresolved.»AfterVariant«, ) {} @@ -48,7 +48,7 @@ enum AfterEnum { class AfterClass { enum AfterEnum { - # $TEST$ target after + // $TEST$ target after »AfterVariant« } } diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to global classes/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to global classes/main.sdstest index 8e1be901..412e4c4e 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to global classes/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to global classes/main.sdstest @@ -1,18 +1,18 @@ package tests.scoping.namedTypes.inSameFile.toGlobalClasses -# $TEST$ target before +// $TEST$ target before class »BeforeClass« segment mySegment( - # $TEST$ references before + // $TEST$ references before p1: »BeforeClass«, - # $TEST$ references after + // $TEST$ references after p2: »AfterClass«, - # $TEST$ unresolved + // $TEST$ unresolved p3: »Unresolved«, ) {} -# $TEST$ target after +// $TEST$ target after class »AfterClass« diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to global enums/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to global enums/main.sdstest index 5c15fd09..dfa877d5 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to global enums/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to global enums/main.sdstest @@ -1,18 +1,18 @@ package tests.scoping.namedTypes.inSameFile.toGlobalEnums -# $TEST$ target before +// $TEST$ target before enum »BeforeEnum« segment mySegment( - # $TEST$ references before + // $TEST$ references before p1: »BeforeEnum«, - # $TEST$ references after + // $TEST$ references after p2: »AfterEnum«, - # $TEST$ unresolved + // $TEST$ unresolved p3: »Unresolved«, ) {} -# $TEST$ target after +// $TEST$ target after enum »AfterEnum« diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to nested classes/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to nested classes/main.sdstest index 2a9927dc..5b92a43c 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to nested classes/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to nested classes/main.sdstest @@ -1,32 +1,32 @@ package tests.scoping.namedTypes.inSameFile.toNestedClasses class BeforeOuterClass { - # $TEST$ target before + // $TEST$ target before class »BeforeInnerClass« } class BeforeInnerClass segment mySegment( - # $TEST$ references before + // $TEST$ references before p1: BeforeOuterClass.»BeforeInnerClass«, - # $TEST$ references after + // $TEST$ references after p2: AfterOuterClass.»AfterInnerClass«, - # $TEST$ unresolved + // $TEST$ unresolved p3: BeforeOuterClass.»AfterInnerClass«, - # $TEST$ unresolved + // $TEST$ unresolved p4: AfterOuterClass.»BeforeInnerClass«, - # $TEST$ unresolved + // $TEST$ unresolved p5: BeforeOuterClass.»Unresolved«, ) {} class AfterInnerClass class AfterOuterClass { - # $TEST$ target after + // $TEST$ target after class »AfterInnerClass« } diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to nested enums/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to nested enums/main.sdstest index ba0e4244..a210c859 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to nested enums/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to nested enums/main.sdstest @@ -1,32 +1,32 @@ package tests.scoping.namedTypes.inSameFile.toNestedEnums class BeforeClass { - # $TEST$ target before + // $TEST$ target before enum »BeforeEnum« } enum BeforeEnum segment mySegment( - # $TEST$ references before + // $TEST$ references before p1: BeforeClass.»BeforeEnum«, - # $TEST$ references after + // $TEST$ references after p2: AfterClass.»AfterEnum«, - # $TEST$ unresolved + // $TEST$ unresolved p3: BeforeClass.»AfterEnum«, - # $TEST$ unresolved + // $TEST$ unresolved p4: AfterClass.»BeforeEnum«, - # $TEST$ unresolved + // $TEST$ unresolved p5: BeforeClass.»Unresolved«, ) {} enum AfterEnum class AfterClass { - # $TEST$ target after + // $TEST$ target after enum »AfterEnum« } diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to something other than named type declarations/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to something other than named type declarations/main.sdstest index 14ecdc30..f94e1210 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to something other than named type declarations/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to something other than named type declarations/main.sdstest @@ -1,6 +1,6 @@ package tests.scoping.namedTypes.inSameFile.toSomethingOtherThanNamedTypeDeclarations -# $TEST$ unresolved +// $TEST$ unresolved segment mySegment(p: »notANamedTypeDeclaration«) {} fun notANamedTypeDeclaration() diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in enum variants in nested enums/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in enum variants in nested enums/main.sdstest index 684ddf4a..94290c0c 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in enum variants in nested enums/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in enum variants in nested enums/main.sdstest @@ -1,21 +1,21 @@ package tests.scoping.namedTypes.inSameFile.toTypeParameter.inEnumVariantsInNestedEnums -# $TEST$ target container +// $TEST$ target container class MyClass<»Container«> { fun myFunction1() enum MyEnum { MyEnumVariant( - # $TEST$ references container + // $TEST$ references container a: »Container«, - # $TEST$ unresolved + // $TEST$ unresolved b: »BeforeEnum«, - # $TEST$ unresolved + // $TEST$ unresolved c: »AfterEnum«, - # $TEST$ unresolved + // $TEST$ unresolved d: »Unresolved«, ) } diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in global classes/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in global classes/main.sdstest index ff99c460..c4dfd05f 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in global classes/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in global classes/main.sdstest @@ -3,50 +3,50 @@ package tests.scoping.namedTypes.inSameFile.toTypeParameter.inGlobalClasses fun myFunction1() class MyClass< - # $TEST$ target own + // $TEST$ target own »Own«, - # $TEST$ references own + // $TEST$ references own T1 sub »Own«, - # $TEST$ unresolved + // $TEST$ unresolved T2 sub »Before«, - # $TEST$ unresolved + // $TEST$ unresolved T3 sub »After«, - # $TEST$ unresolved + // $TEST$ unresolved T4 sub »Unresolved«, - # $TEST$ unresolved + // $TEST$ unresolved T5 sub »Forward«, Forward, >( - # $TEST$ references own + // $TEST$ references own a: »Own«, - # $TEST$ unresolved + // $TEST$ unresolved b: »Before«, - # $TEST$ unresolved + // $TEST$ unresolved c: »After«, - # $TEST$ unresolved + // $TEST$ unresolved d: »Unresolved«, ) -# $TEST$ references own +// $TEST$ references own sub »Own« { - # $TEST$ references own + // $TEST$ references own attr z: »Own« - # $TEST$ unresolved + // $TEST$ unresolved attr y: »Before« - # $TEST$ unresolved + // $TEST$ unresolved attr x: »After« - # $TEST$ unresolved + // $TEST$ unresolved attr w: »Unresolved« } diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in global functions/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in global functions/main.sdstest index c2db8fd3..b53c3115 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in global functions/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in global functions/main.sdstest @@ -3,48 +3,48 @@ package tests.scoping.namedTypes.inSameFile.toTypeParameter.inGlobalFunctions fun myFunction1() fun myFunction2< - # $TEST$ target own + // $TEST$ target own »Own«, - # $TEST$ references own + // $TEST$ references own T1 sub »Own«, - # $TEST$ unresolved + // $TEST$ unresolved T2 sub »Before«, - # $TEST$ unresolved + // $TEST$ unresolved T3 sub »After«, - # $TEST$ unresolved + // $TEST$ unresolved T4 sub »Unresolved«, - # $TEST$ unresolved + // $TEST$ unresolved T5 sub »Forward«, Forward, >( - # $TEST$ references own + // $TEST$ references own a: »Own«, - # $TEST$ unresolved + // $TEST$ unresolved b: »Before«, - # $TEST$ unresolved + // $TEST$ unresolved c: »After«, - # $TEST$ unresolved + // $TEST$ unresolved d: »Unresolved« ) -> ( - # $TEST$ references own + // $TEST$ references own z: »Own«, - # $TEST$ unresolved + // $TEST$ unresolved y: »Before«, - # $TEST$ unresolved + // $TEST$ unresolved x: »After«, - # $TEST$ unresolved + // $TEST$ unresolved w: »Unresolved« ) diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in methods/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in methods/main.sdstest index 1f27c50c..47d173c4 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in methods/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in methods/main.sdstest @@ -2,92 +2,92 @@ package tests.scoping.namedTypes.inSameFile.toTypeParameter.inMethods fun myFunction1() -# $TEST$ target container +// $TEST$ target container class MyClass1<»Container«, Overridden> { fun myFunction2() fun myFunction3< - # $TEST$ target own + // $TEST$ target own »Own«, - # $TEST$ target overridden + // $TEST$ target overridden »Overridden«, - # $TEST$ references own + // $TEST$ references own T1 sub »Own«, - # $TEST$ references overridden + // $TEST$ references overridden T2 sub »Overridden«, - # $TEST$ references container + // $TEST$ references container T3 sub »Container«, - # $TEST$ unresolved + // $TEST$ unresolved T4 sub »BeforeMember«, - # $TEST$ unresolved + // $TEST$ unresolved T5 sub »AfterMember«, - # $TEST$ unresolved + // $TEST$ unresolved T6 sub »BeforeGlobal«, - # $TEST$ unresolved + // $TEST$ unresolved T7 sub »AfterGlobal«, - # $TEST$ unresolved + // $TEST$ unresolved T8 sub »Unresolved«, - # $TEST$ unresolved + // $TEST$ unresolved T9 sub »Forward«, Forward, >( - # $TEST$ references own + // $TEST$ references own a: »Own«, - # $TEST$ references overridden + // $TEST$ references overridden b: »Overridden«, - # $TEST$ references container + // $TEST$ references container c: »Container«, - # $TEST$ unresolved + // $TEST$ unresolved d: »BeforeMember«, - # $TEST$ unresolved + // $TEST$ unresolved e: »AfterMember«, - # $TEST$ unresolved + // $TEST$ unresolved g: »BeforeGlobal«, - # $TEST$ unresolved + // $TEST$ unresolved h: »AfterGlobal«, - # $TEST$ unresolved + // $TEST$ unresolved i: »Unresolved«, ) -> ( - # $TEST$ references own + // $TEST$ references own z: »Own«, - # $TEST$ references overridden + // $TEST$ references overridden y: »Overridden«, - # $TEST$ references container + // $TEST$ references container x: »Container«, - # $TEST$ unresolved + // $TEST$ unresolved w: »BeforeMember«, - # $TEST$ unresolved + // $TEST$ unresolved v: »AfterMember«, - # $TEST$ unresolved + // $TEST$ unresolved u: »BeforeGlobal«, - # $TEST$ unresolved + // $TEST$ unresolved t: »AfterGlobal«, - # $TEST$ unresolved + // $TEST$ unresolved s: »Unresolved«, ) diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in nested classes/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in nested classes/main.sdstest index 7f766424..16e72565 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in nested classes/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in nested classes/main.sdstest @@ -2,97 +2,97 @@ package tests.scoping.namedTypes.inSameFile.toTypeParameter.inNestedClasses fun myFunction1() -# $TEST$ target container +// $TEST$ target container class MyClass1<»Container«, Overridden> { fun myFunction2() class MyClass2< - # $TEST$ target own + // $TEST$ target own »Own«, - # $TEST$ target overridden + // $TEST$ target overridden »Overridden«, - # $TEST$ references own + // $TEST$ references own T1 sub »Own«, - # $TEST$ references overridden + // $TEST$ references overridden T2 sub »Overridden«, - # $TEST$ references container + // $TEST$ references container T3 sub »Container«, - # $TEST$ unresolved + // $TEST$ unresolved T4 sub »BeforeMember«, - # $TEST$ unresolved + // $TEST$ unresolved T5 sub »AfterMember«, - # $TEST$ unresolved + // $TEST$ unresolved T6 sub »BeforeGlobal«, - # $TEST$ unresolved + // $TEST$ unresolved T7 sub »AfterGlobal«, - # $TEST$ unresolved + // $TEST$ unresolved T8 sub »Unresolved«, - # $TEST$ unresolved + // $TEST$ unresolved T9 sub »Forward«, Forward, >( - # $TEST$ references own + // $TEST$ references own a: »Own«, - # $TEST$ references overridden + // $TEST$ references overridden b: »Overridden«, - # $TEST$ references container + // $TEST$ references container c: »Container«, - # $TEST$ unresolved + // $TEST$ unresolved d: »BeforeMember«, - # $TEST$ unresolved + // $TEST$ unresolved e: »AfterMember«, - # $TEST$ unresolved + // $TEST$ unresolved f: »BeforeGlobal«, - # $TEST$ unresolved + // $TEST$ unresolved g: »AfterGlobal«, - # $TEST$ unresolved + // $TEST$ unresolved h: »Unresolved«, ) - # $TEST$ references own - # $TEST$ references overridden - # $TEST$ references container + // $TEST$ references own + // $TEST$ references overridden + // $TEST$ references container sub »Own«, »Overridden«, »Container« { - # $TEST$ references own + // $TEST$ references own attr z: »Own« - # $TEST$ references overridden + // $TEST$ references overridden attr y: »Overridden« - # $TEST$ references container + // $TEST$ references container attr x: »Container« - # $TEST$ unresolved + // $TEST$ unresolved attr w: »BeforeMember« - # $TEST$ unresolved + // $TEST$ unresolved attr v: »AfterMember« - # $TEST$ unresolved + // $TEST$ unresolved attr u: »BeforeGlobal« - # $TEST$ unresolved + // $TEST$ unresolved attr t: »AfterGlobal« - # $TEST$ unresolved + // $TEST$ unresolved attr s: »Unresolved« } diff --git a/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in annotation/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in annotation/main.sdstest index f92ce51b..314584ad 100644 --- a/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in annotation/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in annotation/main.sdstest @@ -3,22 +3,22 @@ package tests.scoping.parameterBounds.inAnnotation fun myFunction1(before: Int) annotation MyAnnotation( - # $TEST$ target own + // $TEST$ target own »own«: Int ) where { - # $TEST$ references own + // $TEST$ references own »own« < 0, - # $TEST$ unresolved + // $TEST$ unresolved »before« < 0, - # $TEST$ unresolved + // $TEST$ unresolved »after« < 0, - # $TEST$ unresolved + // $TEST$ unresolved »notAParameter« < 0, - # $TEST$ unresolved + // $TEST$ unresolved »unresolved« < 0 } diff --git a/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in enum variant in nested enum/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in enum variant in nested enum/main.sdstest index 9225e907..16e0811f 100644 --- a/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in enum variant in nested enum/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in enum variant in nested enum/main.sdstest @@ -5,25 +5,25 @@ class MyClass(container: Int) { enum MyEnum { MyEnumVariant( - # $TEST$ target own + // $TEST$ target own »own«: Int ) where { - # $TEST$ references own + // $TEST$ references own »own« < 0, - # $TEST$ unresolved + // $TEST$ unresolved »container« < 0, - # $TEST$ unresolved + // $TEST$ unresolved »beforeEnum« < 0, - # $TEST$ unresolved + // $TEST$ unresolved »afterEnum« < 0, - # $TEST$ unresolved + // $TEST$ unresolved »notAParameter« < 0, - # $TEST$ unresolved + // $TEST$ unresolved »unresolved« < 0 } } diff --git a/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in global class/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in global class/main.sdstest index 2b4fea6f..e3ada215 100644 --- a/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in global class/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in global class/main.sdstest @@ -3,22 +3,22 @@ package tests.scoping.parameterBounds.inGlobalClass fun myFunction1(before: Int) class MyClass( - # $TEST$ target own + // $TEST$ target own »own«: Int ) where { - # $TEST$ references own + // $TEST$ references own »own« < 0, - # $TEST$ unresolved + // $TEST$ unresolved »before« < 0, - # $TEST$ unresolved + // $TEST$ unresolved »after« < 0, - # $TEST$ unresolved + // $TEST$ unresolved »notAParameter« < 0, - # $TEST$ unresolved + // $TEST$ unresolved »unresolved« < 0 } diff --git a/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in global function/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in global function/main.sdstest index 86b4434a..79641217 100644 --- a/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in global function/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in global function/main.sdstest @@ -3,22 +3,22 @@ package tests.scoping.parameterBounds.inGlobalFunction fun myFunction1(before: Int) fun myFunction2( - # $TEST$ target own + // $TEST$ target own »own«: Int ) where { - # $TEST$ references own + // $TEST$ references own »own« < 0, - # $TEST$ unresolved + // $TEST$ unresolved »before« < 0, - # $TEST$ unresolved + // $TEST$ unresolved »after« < 0, - # $TEST$ unresolved + // $TEST$ unresolved »notAParameter« < 0, - # $TEST$ unresolved + // $TEST$ unresolved »unresolved« < 0 } diff --git a/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in method/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in method/main.sdstest index 77710ef3..3ea3d3bc 100644 --- a/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in method/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in method/main.sdstest @@ -6,37 +6,37 @@ class MyClass1(container: Int, overridden: Int) { fun myFunction2(beforeMember: Int) fun myFunction3( - # $TEST$ target own + // $TEST$ target own »own«: Int, - # $TEST$ target overridden + // $TEST$ target overridden »overridden«: Int, ) where { - # $TEST$ references own + // $TEST$ references own »own« < 0, - # $TEST$ references overridden + // $TEST$ references overridden »overridden« < 0, - # $TEST$ unresolved + // $TEST$ unresolved »container« < 0, - # $TEST$ unresolved + // $TEST$ unresolved »beforeMember« < 0, - # $TEST$ unresolved + // $TEST$ unresolved »afterMember« < 0, - # $TEST$ unresolved + // $TEST$ unresolved »beforeGlobal« < 0, - # $TEST$ unresolved + // $TEST$ unresolved »afterGlobal« < 0, - # $TEST$ unresolved + // $TEST$ unresolved »notAParameter« < 0, - # $TEST$ unresolved + // $TEST$ unresolved »unresolved« < 0 } diff --git a/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in nested class/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in nested class/main.sdstest index e9227c88..1d4ec748 100644 --- a/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in nested class/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in nested class/main.sdstest @@ -6,37 +6,37 @@ class MyClass1(container: Int, overridden: Int){ fun myFunction2(beforeMember: Int) class MyClass2( - # $TEST$ target own + // $TEST$ target own »own«: Int, - # $TEST$ target overridden + // $TEST$ target overridden »overridden«: Int, ) where { - # $TEST$ references own + // $TEST$ references own »own« < 0, - # $TEST$ references overridden + // $TEST$ references overridden »overridden« < 0, - # $TEST$ unresolved + // $TEST$ unresolved »container« < 0, - # $TEST$ unresolved + // $TEST$ unresolved »beforeMember« < 0, - # $TEST$ unresolved + // $TEST$ unresolved »afterMember« < 0, - # $TEST$ unresolved + // $TEST$ unresolved »beforeGlobal« < 0, - # $TEST$ unresolved + // $TEST$ unresolved »afterGlobal« < 0, - # $TEST$ unresolved + // $TEST$ unresolved »notAParameter« < 0, - # $TEST$ unresolved + // $TEST$ unresolved »unresolved« < 0 } diff --git a/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in segment/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in segment/main.sdstest index c6344698..d426d269 100644 --- a/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in segment/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in segment/main.sdstest @@ -3,22 +3,22 @@ package tests.scoping.parameterBounds.inSegment segment mySegment1(before: Int) {} segment mySegment2( - # $TEST$ target own + // $TEST$ target own »own«: Int ) where { - # $TEST$ references own + // $TEST$ references own »own« < 0, - # $TEST$ unresolved + // $TEST$ unresolved »before« < 0, - # $TEST$ unresolved + // $TEST$ unresolved »after« < 0, - # $TEST$ unresolved + // $TEST$ unresolved »notAParameter« < 0, - # $TEST$ unresolved + // $TEST$ unresolved »unresolved« < 0 } {} diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main no imports or own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main no imports or own declarations.sdstest index 2547d874..343ec013 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main no imports or own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main no imports or own declarations.sdstest @@ -1,18 +1,18 @@ package tests.scoping.references.acrossFiles.toAnnotations pipeline myPipeline { - # $TEST$ references same_MyAnnotation + // $TEST$ references same_MyAnnotation »MyAnnotation«; - # $TEST$ references same_AnnotationInSamePackage + // $TEST$ references same_AnnotationInSamePackage »AnnotationInSamePackage«; - # $TEST$ references safeds_AnnotationInSafeDsPackage + // $TEST$ references safeds_AnnotationInSafeDsPackage »AnnotationInSafeDsPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »AnnotationInAnotherPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »AnnotationWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with imports and own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with imports and own declarations.sdstest index e6d72433..795246ef 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with imports and own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with imports and own declarations.sdstest @@ -3,25 +3,25 @@ package tests.scoping.references.acrossFiles.toAnnotations from safeds.scoping.references.acrossFiles.toAnnotations import MyAnnotation as MyOwnAnnotation from tests.scoping.references.acrossFiles.toAnnotations.other import AnnotationInAnotherPackage, Annotation2InAnotherPackage -# $TEST$ target own_MyOwnAnnotation +// $TEST$ target own_MyOwnAnnotation annotation »MyOwnAnnotation« pipeline myPipeline { - # $TEST$ references own_MyOwnAnnotation + // $TEST$ references own_MyOwnAnnotation »MyOwnAnnotation«; - # $TEST$ references same_AnnotationInSamePackage + // $TEST$ references same_AnnotationInSamePackage »AnnotationInSamePackage«; - # $TEST$ references safeds_AnnotationInSafeDsPackage + // $TEST$ references safeds_AnnotationInSafeDsPackage »AnnotationInSafeDsPackage«; - # $TEST$ references other_AnnotationInAnotherPackage + // $TEST$ references other_AnnotationInAnotherPackage »AnnotationInAnotherPackage«; - # $TEST$ references other_Annotation2InAnotherPackage + // $TEST$ references other_Annotation2InAnotherPackage »Annotation2InAnotherPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »AnnotationWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with multiple imports of same name.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with multiple imports of same name.sdstest index d4bd8629..9c10eff5 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with multiple imports of same name.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with multiple imports of same name.sdstest @@ -5,6 +5,6 @@ from tests.scoping.references.acrossFiles.toAnnotations.other import MyAnnotatio from tests.scoping.references.acrossFiles.toAnnotations import MyAnnotation pipeline myPipeline { - # $TEST$ references safeds_MyAnnotation + // $TEST$ references safeds_MyAnnotation »MyAnnotation«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with qualified import with alias.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with qualified import with alias.sdstest index ac651e59..8e57d387 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with qualified import with alias.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with qualified import with alias.sdstest @@ -5,28 +5,28 @@ from safeds.scoping.references.acrossFiles.toAnnotations import MyAnnotation as from tests.scoping.references.acrossFiles.toAnnotations.other import MyAnnotation as MyAnnotationInAnotherPackage pipeline myPipeline { - # $TEST$ references same_MyAnnotation + // $TEST$ references same_MyAnnotation »MyAnnotation«; - # $TEST$ references same_AnnotationInSamePackage + // $TEST$ references same_AnnotationInSamePackage »AnnotationInSamePackage«; - # $TEST$ references safeds_AnnotationInSafeDsPackage + // $TEST$ references safeds_AnnotationInSafeDsPackage »AnnotationInSafeDsPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »AnnotationInAnotherPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »AnnotationWithoutPackage«; - # $TEST$ references same_MyAnnotation + // $TEST$ references same_MyAnnotation »MyAnnotationInSamePackage«; - # $TEST$ references safeds_MyAnnotation + // $TEST$ references safeds_MyAnnotation »MyAnnotationInSafeDsPackage«; - # $TEST$ references other_MyAnnotation + // $TEST$ references other_MyAnnotation »MyAnnotationInAnotherPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with qualified import.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with qualified import.sdstest index 4d6a9b2a..f2e10fd9 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with qualified import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with qualified import.sdstest @@ -4,21 +4,21 @@ from safeds.scoping.references.acrossFiles.toAnnotations import MyAnnotation from tests.scoping.references.acrossFiles.toAnnotations.other import AnnotationInAnotherPackage, Annotation2InAnotherPackage pipeline myPipeline { - # $TEST$ references safeds_MyAnnotation + // $TEST$ references safeds_MyAnnotation »MyAnnotation«; - # $TEST$ references same_AnnotationInSamePackage + // $TEST$ references same_AnnotationInSamePackage »AnnotationInSamePackage«; - # $TEST$ references safeds_AnnotationInSafeDsPackage + // $TEST$ references safeds_AnnotationInSafeDsPackage »AnnotationInSafeDsPackage«; - # $TEST$ references other_AnnotationInAnotherPackage + // $TEST$ references other_AnnotationInAnotherPackage »AnnotationInAnotherPackage«; - # $TEST$ references other_Annotation2InAnotherPackage + // $TEST$ references other_Annotation2InAnotherPackage »Annotation2InAnotherPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »AnnotationWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with wildcard import.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with wildcard import.sdstest index 033fc98d..db146974 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with wildcard import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with wildcard import.sdstest @@ -3,18 +3,18 @@ package tests.scoping.references.acrossFiles.toAnnotations from safeds.scoping.references.acrossFiles.toAnnotations import * pipeline myPipeline { - # $TEST$ references safeds_MyAnnotation + // $TEST$ references safeds_MyAnnotation »MyAnnotation«; - # $TEST$ references same_AnnotationInSamePackage + // $TEST$ references same_AnnotationInSamePackage »AnnotationInSamePackage«; - # $TEST$ references safeds_AnnotationInSafeDsPackage + // $TEST$ references safeds_AnnotationInSafeDsPackage »AnnotationInSafeDsPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »AnnotationInAnotherPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »AnnotationWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/resource other package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/resource other package.sdstest index df6ccb25..88ac9ad5 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/resource other package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/resource other package.sdstest @@ -1,10 +1,10 @@ package tests.scoping.references.acrossFiles.toAnnotations.other -# $TEST$ target other_MyAnnotation +// $TEST$ target other_MyAnnotation annotation »MyAnnotation« -# $TEST$ target other_AnnotationInAnotherPackage +// $TEST$ target other_AnnotationInAnotherPackage annotation »AnnotationInAnotherPackage« -# $TEST$ target other_Annotation2InAnotherPackage +// $TEST$ target other_Annotation2InAnotherPackage annotation »Annotation2InAnotherPackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/resource safeds package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/resource safeds package.sdstest index b8bc9f89..3febd64f 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/resource safeds package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/resource safeds package.sdstest @@ -1,7 +1,7 @@ package safeds.scoping.references.acrossFiles.toAnnotations -# $TEST$ target safeds_MyAnnotation +// $TEST$ target safeds_MyAnnotation annotation »MyAnnotation« -# $TEST$ target safeds_AnnotationInSafeDsPackage +// $TEST$ target safeds_AnnotationInSafeDsPackage annotation »AnnotationInSafeDsPackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/resource same package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/resource same package.sdstest index 14a44a20..03f61011 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/resource same package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/resource same package.sdstest @@ -1,7 +1,7 @@ package tests.scoping.references.acrossFiles.toAnnotations -# $TEST$ target same_MyAnnotation +// $TEST$ target same_MyAnnotation annotation »MyAnnotation« -# $TEST$ target same_AnnotationInSamePackage +// $TEST$ target same_AnnotationInSamePackage annotation »AnnotationInSamePackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/resource without package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/resource without package.sdstest index c4c3bc48..39a33d04 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/resource without package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/resource without package.sdstest @@ -1,5 +1,5 @@ -# $TEST$ target without_MyAnnotation +// $TEST$ target without_MyAnnotation annotation »MyAnnotation« -# $TEST$ target without_AnnotationWithoutPackage +// $TEST$ target without_AnnotationWithoutPackage annotation »AnnotationWithoutPackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main no imports or own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main no imports or own declarations.sdstest index 7c0e3ff8..14832a0e 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main no imports or own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main no imports or own declarations.sdstest @@ -1,18 +1,18 @@ package tests.scoping.references.acrossFiles.toGlobalClasses pipeline myPipeline { - # $TEST$ references same_MyClass + // $TEST$ references same_MyClass »MyClass«; - # $TEST$ references same_ClassInSamePackage + // $TEST$ references same_ClassInSamePackage »ClassInSamePackage«; - # $TEST$ references safeds_ClassInSafeDsPackage + // $TEST$ references safeds_ClassInSafeDsPackage »ClassInSafeDsPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »ClassInAnotherPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »ClassWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with imports and own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with imports and own declarations.sdstest index 1f211248..1f05fa8b 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with imports and own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with imports and own declarations.sdstest @@ -3,25 +3,25 @@ package tests.scoping.references.acrossFiles.toGlobalClasses from safeds.scoping.references.acrossFiles.toGlobalClasses import MyClass as MyOwnClass from tests.scoping.references.acrossFiles.toGlobalClasses.other import ClassInAnotherPackage, Class2InAnotherPackage -# $TEST$ target own_MyOwnClass +// $TEST$ target own_MyOwnClass class »MyOwnClass« pipeline myPipeline { - # $TEST$ references own_MyOwnClass + // $TEST$ references own_MyOwnClass »MyOwnClass«; - # $TEST$ references same_ClassInSamePackage + // $TEST$ references same_ClassInSamePackage »ClassInSamePackage«; - # $TEST$ references safeds_ClassInSafeDsPackage + // $TEST$ references safeds_ClassInSafeDsPackage »ClassInSafeDsPackage«; - # $TEST$ references other_ClassInAnotherPackage + // $TEST$ references other_ClassInAnotherPackage »ClassInAnotherPackage«; - # $TEST$ references other_Class2InAnotherPackage + // $TEST$ references other_Class2InAnotherPackage »Class2InAnotherPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »ClassWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with multiple imports of same name.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with multiple imports of same name.sdstest index a18fe36a..8b624512 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with multiple imports of same name.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with multiple imports of same name.sdstest @@ -5,6 +5,6 @@ from tests.scoping.references.acrossFiles.toGlobalClasses.other import MyClass from tests.scoping.references.acrossFiles.toGlobalClasses import MyClass pipeline myPipeline { - # $TEST$ references safeds_MyClass + // $TEST$ references safeds_MyClass »MyClass«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with qualified import with alias.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with qualified import with alias.sdstest index 02c0a5e4..2a7d6d90 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with qualified import with alias.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with qualified import with alias.sdstest @@ -5,28 +5,28 @@ from safeds.scoping.references.acrossFiles.toGlobalClasses import MyClass as MyC from tests.scoping.references.acrossFiles.toGlobalClasses.other import MyClass as MyClassInAnotherPackage pipeline myPipeline { - # $TEST$ references same_MyClass + // $TEST$ references same_MyClass »MyClass«; - # $TEST$ references same_ClassInSamePackage + // $TEST$ references same_ClassInSamePackage »ClassInSamePackage«; - # $TEST$ references safeds_ClassInSafeDsPackage + // $TEST$ references safeds_ClassInSafeDsPackage »ClassInSafeDsPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »ClassInAnotherPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »ClassWithoutPackage«; - # $TEST$ references same_MyClass + // $TEST$ references same_MyClass »MyClassInSamePackage«; - # $TEST$ references safeds_MyClass + // $TEST$ references safeds_MyClass »MyClassInSafeDsPackage«; - # $TEST$ references other_MyClass + // $TEST$ references other_MyClass »MyClassInAnotherPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with qualified import.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with qualified import.sdstest index 314d80e9..10bf0a70 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with qualified import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with qualified import.sdstest @@ -4,21 +4,21 @@ from safeds.scoping.references.acrossFiles.toGlobalClasses import MyClass from tests.scoping.references.acrossFiles.toGlobalClasses.other import ClassInAnotherPackage, Class2InAnotherPackage pipeline myPipeline { - # $TEST$ references safeds_MyClass + // $TEST$ references safeds_MyClass »MyClass«; - # $TEST$ references same_ClassInSamePackage + // $TEST$ references same_ClassInSamePackage »ClassInSamePackage«; - # $TEST$ references safeds_ClassInSafeDsPackage + // $TEST$ references safeds_ClassInSafeDsPackage »ClassInSafeDsPackage«; - # $TEST$ references other_ClassInAnotherPackage + // $TEST$ references other_ClassInAnotherPackage »ClassInAnotherPackage«; - # $TEST$ references other_Class2InAnotherPackage + // $TEST$ references other_Class2InAnotherPackage »Class2InAnotherPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »ClassWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with wildcard import.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with wildcard import.sdstest index 2e852a7b..2e24c405 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with wildcard import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with wildcard import.sdstest @@ -3,18 +3,18 @@ package tests.scoping.references.acrossFiles.toGlobalClasses from safeds.scoping.references.acrossFiles.toGlobalClasses import * pipeline myPipeline { - # $TEST$ references safeds_MyClass + // $TEST$ references safeds_MyClass »MyClass«; - # $TEST$ references same_ClassInSamePackage + // $TEST$ references same_ClassInSamePackage »ClassInSamePackage«; - # $TEST$ references safeds_ClassInSafeDsPackage + // $TEST$ references safeds_ClassInSafeDsPackage »ClassInSafeDsPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »ClassInAnotherPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »ClassWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/resource other package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/resource other package.sdstest index 92d67f2c..67c9b8be 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/resource other package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/resource other package.sdstest @@ -1,10 +1,10 @@ package tests.scoping.references.acrossFiles.toGlobalClasses.other -# $TEST$ target other_MyClass +// $TEST$ target other_MyClass class »MyClass« -# $TEST$ target other_ClassInAnotherPackage +// $TEST$ target other_ClassInAnotherPackage class »ClassInAnotherPackage« -# $TEST$ target other_Class2InAnotherPackage +// $TEST$ target other_Class2InAnotherPackage class »Class2InAnotherPackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/resource safeds package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/resource safeds package.sdstest index 3da34893..f9bbc9a9 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/resource safeds package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/resource safeds package.sdstest @@ -1,7 +1,7 @@ package safeds.scoping.references.acrossFiles.toGlobalClasses -# $TEST$ target safeds_MyClass +// $TEST$ target safeds_MyClass class »MyClass« -# $TEST$ target safeds_ClassInSafeDsPackage +// $TEST$ target safeds_ClassInSafeDsPackage class »ClassInSafeDsPackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/resource same package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/resource same package.sdstest index 17f76130..5f358622 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/resource same package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/resource same package.sdstest @@ -1,7 +1,7 @@ package tests.scoping.references.acrossFiles.toGlobalClasses -# $TEST$ target same_MyClass +// $TEST$ target same_MyClass class »MyClass« -# $TEST$ target same_ClassInSamePackage +// $TEST$ target same_ClassInSamePackage class »ClassInSamePackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/resource without package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/resource without package.sdstest index 82705a3b..bcd07435 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/resource without package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/resource without package.sdstest @@ -1,5 +1,5 @@ -# $TEST$ target without_MyClass +// $TEST$ target without_MyClass class »MyClass« -# $TEST$ target without_ClassWithoutPackage +// $TEST$ target without_ClassWithoutPackage class »ClassWithoutPackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main no imports or own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main no imports or own declarations.sdstest index 169c166b..0271f2e5 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main no imports or own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main no imports or own declarations.sdstest @@ -1,18 +1,18 @@ package tests.scoping.references.acrossFiles.toGlobalEnums pipeline myPipeline { - # $TEST$ references same_MyEnum + // $TEST$ references same_MyEnum »MyEnum«; - # $TEST$ references same_EnumInSamePackage + // $TEST$ references same_EnumInSamePackage »EnumInSamePackage«; - # $TEST$ references safeds_EnumInSafeDsPackage + // $TEST$ references safeds_EnumInSafeDsPackage »EnumInSafeDsPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »EnumInAnotherPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »EnumWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with imports and own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with imports and own declarations.sdstest index d6e0ee1a..5d3127fa 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with imports and own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with imports and own declarations.sdstest @@ -3,25 +3,25 @@ package tests.scoping.references.acrossFiles.toGlobalEnums from safeds.scoping.references.acrossFiles.toGlobalEnums import MyEnum as MyOwnEnum from tests.scoping.references.acrossFiles.toGlobalEnums.other import EnumInAnotherPackage, Enum2InAnotherPackage -# $TEST$ target own_MyOwnEnum +// $TEST$ target own_MyOwnEnum enum »MyOwnEnum« pipeline myPipeline { - # $TEST$ references own_MyOwnEnum + // $TEST$ references own_MyOwnEnum »MyOwnEnum«; - # $TEST$ references same_EnumInSamePackage + // $TEST$ references same_EnumInSamePackage »EnumInSamePackage«; - # $TEST$ references safeds_EnumInSafeDsPackage + // $TEST$ references safeds_EnumInSafeDsPackage »EnumInSafeDsPackage«; - # $TEST$ references other_EnumInAnotherPackage + // $TEST$ references other_EnumInAnotherPackage »EnumInAnotherPackage«; - # $TEST$ references other_Enum2InAnotherPackage + // $TEST$ references other_Enum2InAnotherPackage »Enum2InAnotherPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »EnumWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with multiple imports of same name.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with multiple imports of same name.sdstest index 2e53d5b0..6a8fe5b7 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with multiple imports of same name.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with multiple imports of same name.sdstest @@ -5,6 +5,6 @@ from tests.scoping.references.acrossFiles.toGlobalEnums.other import MyEnum from tests.scoping.references.acrossFiles.toGlobalEnums import MyEnum pipeline myPipeline { - # $TEST$ references safeds_MyEnum + // $TEST$ references safeds_MyEnum »MyEnum«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with qualified import with alias.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with qualified import with alias.sdstest index e37bb443..6139ad2f 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with qualified import with alias.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with qualified import with alias.sdstest @@ -5,29 +5,29 @@ from safeds.scoping.references.acrossFiles.toGlobalEnums import MyEnum as MyEnum from tests.scoping.references.acrossFiles.toGlobalEnums.other import MyEnum as MyEnumInAnotherPackage pipeline myPipeline { - # $TEST$ references same_MyEnum + // $TEST$ references same_MyEnum »MyEnum«; - # $TEST$ references same_EnumInSamePackage + // $TEST$ references same_EnumInSamePackage »EnumInSamePackage«; - # $TEST$ references safeds_EnumInSafeDsPackage + // $TEST$ references safeds_EnumInSafeDsPackage »EnumInSafeDsPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »EnumInAnotherPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »EnumWithoutPackage«; - # $TEST$ references same_MyEnum + // $TEST$ references same_MyEnum »MyEnumInSamePackage«; - # $TEST$ references safeds_MyEnum + // $TEST$ references safeds_MyEnum »MyEnumInSafeDsPackage«; - # $TEST$ references other_MyEnum + // $TEST$ references other_MyEnum »MyEnumInAnotherPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with qualified import.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with qualified import.sdstest index db403cc5..c844cc99 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with qualified import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with qualified import.sdstest @@ -4,21 +4,21 @@ from safeds.scoping.references.acrossFiles.toGlobalEnums import MyEnum from tests.scoping.references.acrossFiles.toGlobalEnums.other import EnumInAnotherPackage, Enum2InAnotherPackage pipeline myPipeline { - # $TEST$ references safeds_MyEnum + // $TEST$ references safeds_MyEnum »MyEnum«; - # $TEST$ references same_EnumInSamePackage + // $TEST$ references same_EnumInSamePackage »EnumInSamePackage«; - # $TEST$ references safeds_EnumInSafeDsPackage + // $TEST$ references safeds_EnumInSafeDsPackage »EnumInSafeDsPackage«; - # $TEST$ references other_EnumInAnotherPackage + // $TEST$ references other_EnumInAnotherPackage »EnumInAnotherPackage«; - # $TEST$ references other_Enum2InAnotherPackage + // $TEST$ references other_Enum2InAnotherPackage »Enum2InAnotherPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »EnumWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with wildcard import.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with wildcard import.sdstest index 00201f84..391d353e 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with wildcard import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with wildcard import.sdstest @@ -3,18 +3,18 @@ package tests.scoping.references.acrossFiles.toGlobalEnums from safeds.scoping.references.acrossFiles.toGlobalEnums import * pipeline myPipeline { - # $TEST$ references safeds_MyEnum + // $TEST$ references safeds_MyEnum »MyEnum«; - # $TEST$ references same_EnumInSamePackage + // $TEST$ references same_EnumInSamePackage »EnumInSamePackage«; - # $TEST$ references safeds_EnumInSafeDsPackage + // $TEST$ references safeds_EnumInSafeDsPackage »EnumInSafeDsPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »EnumInAnotherPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »EnumWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/resource other package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/resource other package.sdstest index 5ac5748d..a561a587 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/resource other package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/resource other package.sdstest @@ -1,10 +1,10 @@ package tests.scoping.references.acrossFiles.toGlobalEnums.other -# $TEST$ target other_MyEnum +// $TEST$ target other_MyEnum enum »MyEnum« -# $TEST$ target other_EnumInAnotherPackage +// $TEST$ target other_EnumInAnotherPackage enum »EnumInAnotherPackage« -# $TEST$ target other_Enum2InAnotherPackage +// $TEST$ target other_Enum2InAnotherPackage enum »Enum2InAnotherPackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/resource safeds package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/resource safeds package.sdstest index ba6c6b01..44e595fc 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/resource safeds package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/resource safeds package.sdstest @@ -1,7 +1,7 @@ package safeds.scoping.references.acrossFiles.toGlobalEnums -# $TEST$ target safeds_MyEnum +// $TEST$ target safeds_MyEnum enum »MyEnum« -# $TEST$ target safeds_EnumInSafeDsPackage +// $TEST$ target safeds_EnumInSafeDsPackage enum »EnumInSafeDsPackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/resource same package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/resource same package.sdstest index 7710a15d..43c20ebc 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/resource same package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/resource same package.sdstest @@ -1,7 +1,7 @@ package tests.scoping.references.acrossFiles.toGlobalEnums -# $TEST$ target same_MyEnum +// $TEST$ target same_MyEnum enum »MyEnum« -# $TEST$ target same_EnumInSamePackage +// $TEST$ target same_EnumInSamePackage enum »EnumInSamePackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/resource without package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/resource without package.sdstest index b0052f12..7587c7e2 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/resource without package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/resource without package.sdstest @@ -1,5 +1,5 @@ -# $TEST$ target without_MyEnum +// $TEST$ target without_MyEnum enum »MyEnum« -# $TEST$ target without_EnumWithoutPackage +// $TEST$ target without_EnumWithoutPackage enum »EnumWithoutPackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main no imports or own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main no imports or own declarations.sdstest index c158cb96..aa95d66f 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main no imports or own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main no imports or own declarations.sdstest @@ -1,18 +1,18 @@ package tests.scoping.references.acrossFiles.toGlobalFunctions pipeline myPipeline { - # $TEST$ references same_myFunction + // $TEST$ references same_myFunction »myFunction«; - # $TEST$ references same_functionInSamePackage + // $TEST$ references same_functionInSamePackage »functionInSamePackage«; - # $TEST$ references safeds_functionInSafeDsPackage + // $TEST$ references safeds_functionInSafeDsPackage »functionInSafeDsPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »functionInAnotherPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »functionWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with imports and own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with imports and own declarations.sdstest index 8d37eb3c..822b94b9 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with imports and own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with imports and own declarations.sdstest @@ -3,25 +3,25 @@ package tests.scoping.references.acrossFiles.toGlobalFunctions from safeds.scoping.references.acrossFiles.toGlobalFunctions import myFunction as myOwnFunction from tests.scoping.references.acrossFiles.toGlobalFunctions.other import functionInAnotherPackage, function2InAnotherPackage -# $TEST$ target own_myOwnFunction +// $TEST$ target own_myOwnFunction fun »myOwnFunction«() pipeline myPipeline { - # $TEST$ references own_myOwnFunction + // $TEST$ references own_myOwnFunction »myOwnFunction«; - # $TEST$ references same_functionInSamePackage + // $TEST$ references same_functionInSamePackage »functionInSamePackage«; - # $TEST$ references safeds_functionInSafeDsPackage + // $TEST$ references safeds_functionInSafeDsPackage »functionInSafeDsPackage«; - # $TEST$ references other_functionInAnotherPackage + // $TEST$ references other_functionInAnotherPackage »functionInAnotherPackage«; - # $TEST$ references other_function2InAnotherPackage + // $TEST$ references other_function2InAnotherPackage »function2InAnotherPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »functionWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with multiple imports of same name.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with multiple imports of same name.sdstest index ddee893c..d19d3dff 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with multiple imports of same name.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with multiple imports of same name.sdstest @@ -5,6 +5,6 @@ from tests.scoping.references.acrossFiles.toGlobalFunctions.other import myFunct from tests.scoping.references.acrossFiles.toGlobalFunctions import myFunction pipeline myPipeline { - # $TEST$ references safeds_myFunction + // $TEST$ references safeds_myFunction »myFunction«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with qualified import with alias.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with qualified import with alias.sdstest index cd0eff17..fd2a9cb9 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with qualified import with alias.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with qualified import with alias.sdstest @@ -5,29 +5,29 @@ from safeds.scoping.references.acrossFiles.toGlobalFunctions import myFunction a from tests.scoping.references.acrossFiles.toGlobalFunctions.other import myFunction as myFunctionInAnotherPackage pipeline myPipeline { - # $TEST$ references same_myFunction + // $TEST$ references same_myFunction »myFunction«; - # $TEST$ references same_functionInSamePackage + // $TEST$ references same_functionInSamePackage »functionInSamePackage«; - # $TEST$ references safeds_functionInSafeDsPackage + // $TEST$ references safeds_functionInSafeDsPackage »functionInSafeDsPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »functionInAnotherPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »functionWithoutPackage«; - # $TEST$ references same_myFunction + // $TEST$ references same_myFunction »myFunctionInSamePackage«; - # $TEST$ references safeds_myFunction + // $TEST$ references safeds_myFunction »myFunctionInSafeDsPackage«; - # $TEST$ references other_myFunction + // $TEST$ references other_myFunction »myFunctionInAnotherPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with qualified import.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with qualified import.sdstest index 6cb0e73d..056e08fc 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with qualified import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with qualified import.sdstest @@ -4,21 +4,21 @@ from safeds.scoping.references.acrossFiles.toGlobalFunctions import myFunction from tests.scoping.references.acrossFiles.toGlobalFunctions.other import functionInAnotherPackage, function2InAnotherPackage pipeline myPipeline { - # $TEST$ references safeds_myFunction + // $TEST$ references safeds_myFunction »myFunction«; - # $TEST$ references same_functionInSamePackage + // $TEST$ references same_functionInSamePackage »functionInSamePackage«; - # $TEST$ references safeds_functionInSafeDsPackage + // $TEST$ references safeds_functionInSafeDsPackage »functionInSafeDsPackage«; - # $TEST$ references other_functionInAnotherPackage + // $TEST$ references other_functionInAnotherPackage »functionInAnotherPackage«; - # $TEST$ references other_function2InAnotherPackage + // $TEST$ references other_function2InAnotherPackage »function2InAnotherPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »functionWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with wildcard import.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with wildcard import.sdstest index 0b998b96..e152bdc8 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with wildcard import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with wildcard import.sdstest @@ -3,18 +3,18 @@ package tests.scoping.references.acrossFiles.toGlobalFunctions from safeds.scoping.references.acrossFiles.toGlobalFunctions import * pipeline myPipeline { - # $TEST$ references safeds_myFunction + // $TEST$ references safeds_myFunction »myFunction«; - # $TEST$ references same_functionInSamePackage + // $TEST$ references same_functionInSamePackage »functionInSamePackage«; - # $TEST$ references safeds_functionInSafeDsPackage + // $TEST$ references safeds_functionInSafeDsPackage »functionInSafeDsPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »functionInAnotherPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »functionWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/resource other package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/resource other package.sdstest index 7a774965..350069f5 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/resource other package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/resource other package.sdstest @@ -1,10 +1,10 @@ package tests.scoping.references.acrossFiles.toGlobalFunctions.other -# $TEST$ target other_myFunction +// $TEST$ target other_myFunction fun »myFunction«() -# $TEST$ target other_functionInAnotherPackage +// $TEST$ target other_functionInAnotherPackage fun »functionInAnotherPackage«() -# $TEST$ target other_function2InAnotherPackage +// $TEST$ target other_function2InAnotherPackage fun »function2InAnotherPackage«() diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/resource safeds package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/resource safeds package.sdstest index 5591bde0..42f3f9bd 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/resource safeds package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/resource safeds package.sdstest @@ -1,7 +1,7 @@ package safeds.scoping.references.acrossFiles.toGlobalFunctions -# $TEST$ target safeds_myFunction +// $TEST$ target safeds_myFunction fun »myFunction«() -# $TEST$ target safeds_functionInSafeDsPackage +// $TEST$ target safeds_functionInSafeDsPackage fun »functionInSafeDsPackage«() diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/resource same package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/resource same package.sdstest index eec5e663..969c2847 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/resource same package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/resource same package.sdstest @@ -1,7 +1,7 @@ package tests.scoping.references.acrossFiles.toGlobalFunctions -# $TEST$ target same_myFunction +// $TEST$ target same_myFunction fun »myFunction«() -# $TEST$ target same_functionInSamePackage +// $TEST$ target same_functionInSamePackage fun »functionInSamePackage«() diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/resource without package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/resource without package.sdstest index bbead6af..fc524811 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/resource without package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/resource without package.sdstest @@ -1,5 +1,5 @@ -# $TEST$ target without_myFunction +// $TEST$ target without_myFunction fun »myFunction«() -# $TEST$ target without_functionWithoutPackage +// $TEST$ target without_functionWithoutPackage fun »functionWithoutPackage«() diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main no imports or own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main no imports or own declarations.sdstest index f7fbcf05..2a5d9174 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main no imports or own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main no imports or own declarations.sdstest @@ -1,18 +1,18 @@ package tests.scoping.references.acrossFiles.toPipelines segment mySegment() { - # $TEST$ unresolved + // $TEST$ unresolved »myPipeline«; - # $TEST$ unresolved + // $TEST$ unresolved »pipelineInSamePackage«; - # $TEST$ unresolved + // $TEST$ unresolved »pipelineInSafeDsPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »pipelineInAnotherPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »pipelineWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with imports and own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with imports and own declarations.sdstest index 037f300d..18d49714 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with imports and own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with imports and own declarations.sdstest @@ -3,25 +3,25 @@ package tests.scoping.references.acrossFiles.toPipelines from safeds.scoping.references.acrossFiles.toPipelines import myPipeline as myOwnPipeline from tests.scoping.references.acrossFiles.toPipelines.other import pipelineInAnotherPackage, pipeline2InAnotherPackage -# $TEST$ target own_myOwnPipeline +// $TEST$ target own_myOwnPipeline pipeline »myOwnPipeline« {} segment mySegment() { - # $TEST$ references own_myOwnPipeline + // $TEST$ references own_myOwnPipeline »myOwnPipeline«; - # $TEST$ unresolved + // $TEST$ unresolved »pipelineInSamePackage«; - # $TEST$ unresolved + // $TEST$ unresolved »pipelineInSafeDsPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »pipelineInAnotherPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »pipeline2InAnotherPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »pipelineWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with multiple imports of same name.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with multiple imports of same name.sdstest index 6e29ff58..9720b43e 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with multiple imports of same name.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with multiple imports of same name.sdstest @@ -5,6 +5,6 @@ from tests.scoping.references.acrossFiles.toPipelines.other import myPipeline from tests.scoping.references.acrossFiles.toPipelines import myPipeline segment mySegment() { - # $TEST$ unresolved + // $TEST$ unresolved »myPipeline«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with qualified import with alias.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with qualified import with alias.sdstest index f85da9f7..9f3eb5e3 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with qualified import with alias.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with qualified import with alias.sdstest @@ -5,29 +5,29 @@ from safeds.scoping.references.acrossFiles.toPipelines import myPipeline as myPi from tests.scoping.references.acrossFiles.toPipelines.other import myPipeline as myPipelineInAnotherPackage segment mySegment() { - # $TEST$ unresolved + // $TEST$ unresolved »myPipeline«; - # $TEST$ unresolved + // $TEST$ unresolved »pipelineInSamePackage«; - # $TEST$ unresolved + // $TEST$ unresolved »pipelineInSafeDsPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »pipelineInAnotherPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »pipelineWithoutPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »myPipelineInSamePackage«; - # $TEST$ unresolved + // $TEST$ unresolved »myPipelineInSafeDsPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »myPipelineInAnotherPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with qualified import.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with qualified import.sdstest index 91dae559..5b97bbc9 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with qualified import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with qualified import.sdstest @@ -4,21 +4,21 @@ from safeds.scoping.references.acrossFiles.toPipelines import myPipeline from tests.scoping.references.acrossFiles.toPipelines.other import pipelineInAnotherPackage, pipeline2InAnotherPackage segment mySegment() { - # $TEST$ unresolved + // $TEST$ unresolved »myPipeline«; - # $TEST$ unresolved + // $TEST$ unresolved »pipelineInSamePackage«; - # $TEST$ unresolved + // $TEST$ unresolved »pipelineInSafeDsPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »pipelineInAnotherPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »pipeline2InAnotherPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »pipelineWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with wildcard import.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with wildcard import.sdstest index 1483767b..8747eb06 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with wildcard import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with wildcard import.sdstest @@ -3,18 +3,18 @@ package tests.scoping.references.acrossFiles.toPipelines from safeds.scoping.references.acrossFiles.toPipelines import * segment mySegment() { - # $TEST$ unresolved + // $TEST$ unresolved »myPipeline«; - # $TEST$ unresolved + // $TEST$ unresolved »pipelineInSamePackage«; - # $TEST$ unresolved + // $TEST$ unresolved »pipelineInSafeDsPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »pipelineInAnotherPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »pipelineWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/resource other package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/resource other package.sdstest index 76010a15..3adecca8 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/resource other package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/resource other package.sdstest @@ -1,10 +1,10 @@ package tests.scoping.references.acrossFiles.toPipelines.other -# $TEST$ target other_myPipeline +// $TEST$ target other_myPipeline pipeline »myPipeline« {} -# $TEST$ target other_pipelineInAnotherPackage +// $TEST$ target other_pipelineInAnotherPackage pipeline »pipelineInAnotherPackage« {} -# $TEST$ target other_pipeline2InAnotherPackage +// $TEST$ target other_pipeline2InAnotherPackage pipeline »pipeline2InAnotherPackage« {} diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/resource safeds package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/resource safeds package.sdstest index 9369b87c..9f66ceb0 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/resource safeds package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/resource safeds package.sdstest @@ -1,7 +1,7 @@ package safeds.scoping.references.acrossFiles.toPipelines -# $TEST$ target safeds_myPipeline +// $TEST$ target safeds_myPipeline pipeline »myPipeline« {} -# $TEST$ target safeds_pipelineInSafeDsPackage +// $TEST$ target safeds_pipelineInSafeDsPackage pipeline »pipelineInSafeDsPackage« {} diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/resource same package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/resource same package.sdstest index 5bf4de88..34cec8ca 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/resource same package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/resource same package.sdstest @@ -1,7 +1,7 @@ package tests.scoping.references.acrossFiles.toPipelines -# $TEST$ target same_myPipeline +// $TEST$ target same_myPipeline pipeline »myPipeline« {} -# $TEST$ target same_pipelineInSamePackage +// $TEST$ target same_pipelineInSamePackage pipeline »pipelineInSamePackage« {} diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/resource without package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/resource without package.sdstest index 45977c18..da94d86f 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/resource without package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/resource without package.sdstest @@ -1,5 +1,5 @@ -# $TEST$ target without_myPipeline +// $TEST$ target without_myPipeline pipeline »myPipeline« {} -# $TEST$ target without_pipelineWithoutPackage +// $TEST$ target without_pipelineWithoutPackage pipeline »pipelineWithoutPackage« {} diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main no imports or own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main no imports or own declarations.sdstest index 4fddfd95..9d84b922 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main no imports or own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main no imports or own declarations.sdstest @@ -1,18 +1,18 @@ package tests.scoping.references.acrossFiles.toSchemas pipeline myPipeline { - # $TEST$ references same_MySchema + // $TEST$ references same_MySchema »MySchema«; - # $TEST$ references same_SchemaInSamePackage + // $TEST$ references same_SchemaInSamePackage »SchemaInSamePackage«; - # $TEST$ references safeds_SchemaInSafeDsPackage + // $TEST$ references safeds_SchemaInSafeDsPackage »SchemaInSafeDsPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »SchemaInAnotherPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »SchemaWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with imports and own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with imports and own declarations.sdstest index 43bc5a88..3aa40542 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with imports and own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with imports and own declarations.sdstest @@ -3,25 +3,25 @@ package tests.scoping.references.acrossFiles.toSchemas from safeds.scoping.references.acrossFiles.toSchemas import MySchema as MyOwnSchema from tests.scoping.references.acrossFiles.toSchemas.other import SchemaInAnotherPackage, Schema2InAnotherPackage -# $TEST$ target own_MyOwnSchema +// $TEST$ target own_MyOwnSchema schema »MyOwnSchema« {} pipeline myPipeline { - # $TEST$ references own_MyOwnSchema + // $TEST$ references own_MyOwnSchema »MyOwnSchema«; - # $TEST$ references same_SchemaInSamePackage + // $TEST$ references same_SchemaInSamePackage »SchemaInSamePackage«; - # $TEST$ references safeds_SchemaInSafeDsPackage + // $TEST$ references safeds_SchemaInSafeDsPackage »SchemaInSafeDsPackage«; - # $TEST$ references other_SchemaInAnotherPackage + // $TEST$ references other_SchemaInAnotherPackage »SchemaInAnotherPackage«; - # $TEST$ references other_Schema2InAnotherPackage + // $TEST$ references other_Schema2InAnotherPackage »Schema2InAnotherPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »SchemaWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with multiple imports of same name.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with multiple imports of same name.sdstest index b71d43f7..1fb7f3e6 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with multiple imports of same name.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with multiple imports of same name.sdstest @@ -5,6 +5,6 @@ from tests.scoping.references.acrossFiles.toSchemas.other import MySchema from tests.scoping.references.acrossFiles.toSchemas import MySchema pipeline myPipeline { - # $TEST$ references safeds_MySchema + // $TEST$ references safeds_MySchema »MySchema«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with qualified import with alias.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with qualified import with alias.sdstest index f67c8eda..a4d0ffb9 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with qualified import with alias.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with qualified import with alias.sdstest @@ -5,29 +5,29 @@ from safeds.scoping.references.acrossFiles.toSchemas import MySchema as MySchema from tests.scoping.references.acrossFiles.toSchemas.other import MySchema as MySchemaInAnotherPackage pipeline myPipeline { - # $TEST$ references same_MySchema + // $TEST$ references same_MySchema »MySchema«; - # $TEST$ references same_SchemaInSamePackage + // $TEST$ references same_SchemaInSamePackage »SchemaInSamePackage«; - # $TEST$ references safeds_SchemaInSafeDsPackage + // $TEST$ references safeds_SchemaInSafeDsPackage »SchemaInSafeDsPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »SchemaInAnotherPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »SchemaWithoutPackage«; - # $TEST$ references same_MySchema + // $TEST$ references same_MySchema »MySchemaInSamePackage«; - # $TEST$ references safeds_MySchema + // $TEST$ references safeds_MySchema »MySchemaInSafeDsPackage«; - # $TEST$ references other_MySchema + // $TEST$ references other_MySchema »MySchemaInAnotherPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with qualified import.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with qualified import.sdstest index 294ef945..49e62144 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with qualified import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with qualified import.sdstest @@ -4,21 +4,21 @@ from safeds.scoping.references.acrossFiles.toSchemas import MySchema from tests.scoping.references.acrossFiles.toSchemas.other import SchemaInAnotherPackage, Schema2InAnotherPackage pipeline myPipeline { - # $TEST$ references safeds_MySchema + // $TEST$ references safeds_MySchema »MySchema«; - # $TEST$ references same_SchemaInSamePackage + // $TEST$ references same_SchemaInSamePackage »SchemaInSamePackage«; - # $TEST$ references safeds_SchemaInSafeDsPackage + // $TEST$ references safeds_SchemaInSafeDsPackage »SchemaInSafeDsPackage«; - # $TEST$ references other_SchemaInAnotherPackage + // $TEST$ references other_SchemaInAnotherPackage »SchemaInAnotherPackage«; - # $TEST$ references other_Schema2InAnotherPackage + // $TEST$ references other_Schema2InAnotherPackage »Schema2InAnotherPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »SchemaWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with wildcard import.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with wildcard import.sdstest index 6af6cc0b..c7beb819 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with wildcard import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with wildcard import.sdstest @@ -3,18 +3,18 @@ package tests.scoping.references.acrossFiles.toSchemas from safeds.scoping.references.acrossFiles.toSchemas import * pipeline myPipeline { - # $TEST$ references safeds_MySchema + // $TEST$ references safeds_MySchema »MySchema«; - # $TEST$ references same_SchemaInSamePackage + // $TEST$ references same_SchemaInSamePackage »SchemaInSamePackage«; - # $TEST$ references safeds_SchemaInSafeDsPackage + // $TEST$ references safeds_SchemaInSafeDsPackage »SchemaInSafeDsPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »SchemaInAnotherPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »SchemaWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/resource other package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/resource other package.sdstest index 4fb6033e..27b7146e 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/resource other package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/resource other package.sdstest @@ -1,10 +1,10 @@ package tests.scoping.references.acrossFiles.toSchemas.other -# $TEST$ target other_MySchema +// $TEST$ target other_MySchema schema »MySchema« {} -# $TEST$ target other_SchemaInAnotherPackage +// $TEST$ target other_SchemaInAnotherPackage schema »SchemaInAnotherPackage« {} -# $TEST$ target other_Schema2InAnotherPackage +// $TEST$ target other_Schema2InAnotherPackage schema »Schema2InAnotherPackage« {} diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/resource safeds package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/resource safeds package.sdstest index 7a023633..f8f5a10c 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/resource safeds package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/resource safeds package.sdstest @@ -1,7 +1,7 @@ package safeds.scoping.references.acrossFiles.toSchemas -# $TEST$ target safeds_MySchema +// $TEST$ target safeds_MySchema schema »MySchema« {} -# $TEST$ target safeds_SchemaInSafeDsPackage +// $TEST$ target safeds_SchemaInSafeDsPackage schema »SchemaInSafeDsPackage« {} diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/resource same package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/resource same package.sdstest index 7207677e..2fdfc079 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/resource same package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/resource same package.sdstest @@ -1,7 +1,7 @@ package tests.scoping.references.acrossFiles.toSchemas -# $TEST$ target same_MySchema +// $TEST$ target same_MySchema schema »MySchema« {} -# $TEST$ target same_SchemaInSamePackage +// $TEST$ target same_SchemaInSamePackage schema »SchemaInSamePackage« {} diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/resource without package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/resource without package.sdstest index 3412fadb..89cd8480 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/resource without package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/resource without package.sdstest @@ -1,5 +1,5 @@ -# $TEST$ target without_MySchema +// $TEST$ target without_MySchema schema »MySchema« {} -# $TEST$ target without_SchemaWithoutPackage +// $TEST$ target without_SchemaWithoutPackage schema »SchemaWithoutPackage« {} diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main no imports or own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main no imports or own declarations.sdstest index cc2d2cdd..97e096ed 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main no imports or own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main no imports or own declarations.sdstest @@ -1,46 +1,46 @@ package tests.scoping.references.acrossFiles.toSegments pipeline myPipeline { - # $TEST$ references same_mySegment + // $TEST$ references same_mySegment »mySegment«; - # $TEST$ references same_publicSegmentInSamePackage + // $TEST$ references same_publicSegmentInSamePackage »publicSegmentInSamePackage«; - # $TEST$ references same_internalSegmentInSamePackage + // $TEST$ references same_internalSegmentInSamePackage »internalSegmentInSamePackage«; - # $TEST$ unresolved + // $TEST$ unresolved »privateSegmentInSamePackage«; - # $TEST$ references safeds_publicSegmentInSafeDsPackage + // $TEST$ references safeds_publicSegmentInSafeDsPackage »publicSegmentInSafeDsPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »internalSegmentInSafeDsPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »privateSegmentInSafeDsPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »publicSegmentInAnotherPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »internalSegmentInAnotherPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »privateSegmentInAnotherPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »publicSegmentWithoutPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »internalSegmentWithoutPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »privateSegmentWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with imports and own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with imports and own declarations.sdstest index 20131d86..f179230e 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with imports and own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with imports and own declarations.sdstest @@ -5,53 +5,53 @@ from tests.scoping.references.acrossFiles.toSegments.other import publicSegmentI from tests.scoping.references.acrossFiles.toSegments.other import internalSegmentInAnotherPackage from tests.scoping.references.acrossFiles.toSegments.other import privateSegmentInAnotherPackage -# $TEST$ target own_myOwnSegment +// $TEST$ target own_myOwnSegment segment »myOwnSegment«() {} pipeline myPipeline { - # $TEST$ references own_myOwnSegment + // $TEST$ references own_myOwnSegment »myOwnSegment«; - # $TEST$ references same_publicSegmentInSamePackage + // $TEST$ references same_publicSegmentInSamePackage »publicSegmentInSamePackage«; - # $TEST$ references same_internalSegmentInSamePackage + // $TEST$ references same_internalSegmentInSamePackage »internalSegmentInSamePackage«; - # $TEST$ unresolved + // $TEST$ unresolved »privateSegmentInSamePackage«; - # $TEST$ references safeds_publicSegmentInSafeDsPackage + // $TEST$ references safeds_publicSegmentInSafeDsPackage »publicSegmentInSafeDsPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »internalSegmentInSafeDsPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »privateSegmentInSafeDsPackage«; - # $TEST$ references other_publicSegmentInAnotherPackage + // $TEST$ references other_publicSegmentInAnotherPackage »publicSegmentInAnotherPackage«; - # $TEST$ references other_public2SegmentInAnotherPackage + // $TEST$ references other_public2SegmentInAnotherPackage »public2SegmentInAnotherPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »internalSegmentInAnotherPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »privateSegmentInAnotherPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »publicSegmentWithoutPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »internalSegmentWithoutPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »privateSegmentWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with multiple imports of same name.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with multiple imports of same name.sdstest index ebd4460d..3f6a60a0 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with multiple imports of same name.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with multiple imports of same name.sdstest @@ -5,6 +5,6 @@ from tests.scoping.references.acrossFiles.toSegments.other import mySegment from tests.scoping.references.acrossFiles.toSegments import mySegment pipeline myPipeline { - # $TEST$ references safeds_mySegment + // $TEST$ references safeds_mySegment »mySegment«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with qualified import with alias.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with qualified import with alias.sdstest index e719bb17..a82b6d78 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with qualified import with alias.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with qualified import with alias.sdstest @@ -5,56 +5,56 @@ from safeds.scoping.references.acrossFiles.toSegments import mySegment as mySegm from tests.scoping.references.acrossFiles.toSegments.other import mySegment as mySegmentInAnotherPackage pipeline myPipeline { - # $TEST$ references same_mySegment + // $TEST$ references same_mySegment »mySegment«; - # $TEST$ references same_publicSegmentInSamePackage + // $TEST$ references same_publicSegmentInSamePackage »publicSegmentInSamePackage«; - # $TEST$ references same_internalSegmentInSamePackage + // $TEST$ references same_internalSegmentInSamePackage »internalSegmentInSamePackage«; - # $TEST$ unresolved + // $TEST$ unresolved »privateSegmentInSamePackage«; - # $TEST$ references safeds_publicSegmentInSafeDsPackage + // $TEST$ references safeds_publicSegmentInSafeDsPackage »publicSegmentInSafeDsPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »internalSegmentInSafeDsPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »privateSegmentInSafeDsPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »publicSegmentInAnotherPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »internalSegmentInAnotherPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »privateSegmentInAnotherPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »publicSegmentWithoutPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »internalSegmentWithoutPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »privateSegmentWithoutPackage«; - # $TEST$ references same_mySegment + // $TEST$ references same_mySegment »mySegmentInSamePackage«; - # $TEST$ references safeds_mySegment + // $TEST$ references safeds_mySegment »mySegmentInSafeDsPackage«; - # $TEST$ references other_mySegment + // $TEST$ references other_mySegment »mySegmentInAnotherPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with qualified import.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with qualified import.sdstest index 8c9d7f67..b0a350a4 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with qualified import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with qualified import.sdstest @@ -6,49 +6,49 @@ from tests.scoping.references.acrossFiles.toSegments.other import internalSegmen from tests.scoping.references.acrossFiles.toSegments.other import privateSegmentInAnotherPackage pipeline myPipeline { - # $TEST$ references safeds_mySegment + // $TEST$ references safeds_mySegment »mySegment«; - # $TEST$ references same_publicSegmentInSamePackage + // $TEST$ references same_publicSegmentInSamePackage »publicSegmentInSamePackage«; - # $TEST$ references same_internalSegmentInSamePackage + // $TEST$ references same_internalSegmentInSamePackage »internalSegmentInSamePackage«; - # $TEST$ unresolved + // $TEST$ unresolved »privateSegmentInSamePackage«; - # $TEST$ references safeds_publicSegmentInSafeDsPackage + // $TEST$ references safeds_publicSegmentInSafeDsPackage »publicSegmentInSafeDsPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »internalSegmentInSafeDsPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »privateSegmentInSafeDsPackage«; - # $TEST$ references other_publicSegmentInAnotherPackage + // $TEST$ references other_publicSegmentInAnotherPackage »publicSegmentInAnotherPackage«; - # $TEST$ references other_public2SegmentInAnotherPackage + // $TEST$ references other_public2SegmentInAnotherPackage »public2SegmentInAnotherPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »internalSegmentInAnotherPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »privateSegmentInAnotherPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »publicSegmentWithoutPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »internalSegmentWithoutPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »privateSegmentWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with wildcard import.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with wildcard import.sdstest index 4bfb2141..86caa307 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with wildcard import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with wildcard import.sdstest @@ -3,46 +3,46 @@ package tests.scoping.references.acrossFiles.toSegments from safeds.scoping.references.acrossFiles.toSegments import * pipeline myPipeline { - # $TEST$ references safeds_mySegment + // $TEST$ references safeds_mySegment »mySegment«; - # $TEST$ references same_publicSegmentInSamePackage + // $TEST$ references same_publicSegmentInSamePackage »publicSegmentInSamePackage«; - # $TEST$ references same_internalSegmentInSamePackage + // $TEST$ references same_internalSegmentInSamePackage »internalSegmentInSamePackage«; - # $TEST$ unresolved + // $TEST$ unresolved »privateSegmentInSamePackage«; - # $TEST$ references safeds_publicSegmentInSafeDsPackage + // $TEST$ references safeds_publicSegmentInSafeDsPackage »publicSegmentInSafeDsPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »internalSegmentInSafeDsPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »privateSegmentInSafeDsPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »publicSegmentInAnotherPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »internalSegmentInAnotherPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »privateSegmentInAnotherPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »publicSegmentWithoutPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »internalSegmentWithoutPackage«; - # $TEST$ unresolved + // $TEST$ unresolved »privateSegmentWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/resource other package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/resource other package.sdstest index c1699e56..02cd0f13 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/resource other package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/resource other package.sdstest @@ -1,16 +1,16 @@ package tests.scoping.references.acrossFiles.toSegments.other -# $TEST$ target other_mySegment +// $TEST$ target other_mySegment segment »mySegment«() {} -# $TEST$ target other_publicSegmentInAnotherPackage +// $TEST$ target other_publicSegmentInAnotherPackage segment »publicSegmentInAnotherPackage«() {} -# $TEST$ target other_public2SegmentInAnotherPackage +// $TEST$ target other_public2SegmentInAnotherPackage segment »public2SegmentInAnotherPackage«() {} -# $TEST$ target other_internalSegmentInAnotherPackage +// $TEST$ target other_internalSegmentInAnotherPackage internal segment »internalSegmentInAnotherPackage«() {} -# $TEST$ target other_privateSegmentInAnotherPackage +// $TEST$ target other_privateSegmentInAnotherPackage private segment »privateSegmentInAnotherPackage«() {} diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/resource safeds package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/resource safeds package.sdstest index 0ebbd989..2f1e577e 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/resource safeds package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/resource safeds package.sdstest @@ -1,13 +1,13 @@ package safeds.scoping.references.acrossFiles.toSegments -# $TEST$ target safeds_mySegment +// $TEST$ target safeds_mySegment segment »mySegment«() {} -# $TEST$ target safeds_publicSegmentInSafeDsPackage +// $TEST$ target safeds_publicSegmentInSafeDsPackage segment »publicSegmentInSafeDsPackage«() {} -# $TEST$ target safeds_internalSegmentInSafeDsPackage +// $TEST$ target safeds_internalSegmentInSafeDsPackage internal segment »internalSegmentInSafeDsPackage«() {} -# $TEST$ target safeds_privateSegmentInSafeDsPackage +// $TEST$ target safeds_privateSegmentInSafeDsPackage private segment »privateSegmentInSafeDsPackage«() {} diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/resource same package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/resource same package.sdstest index a3ea3df3..9d1f66b4 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/resource same package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/resource same package.sdstest @@ -1,13 +1,13 @@ package tests.scoping.references.acrossFiles.toSegments -# $TEST$ target same_mySegment +// $TEST$ target same_mySegment segment »mySegment«() {} -# $TEST$ target same_publicSegmentInSamePackage +// $TEST$ target same_publicSegmentInSamePackage segment »publicSegmentInSamePackage«() {} -# $TEST$ target same_internalSegmentInSamePackage +// $TEST$ target same_internalSegmentInSamePackage internal segment »internalSegmentInSamePackage«() {} -# $TEST$ target same_privateSegmentInSamePackage +// $TEST$ target same_privateSegmentInSamePackage private segment »privateSegmentInSamePackage«() {} diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/resource without package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/resource without package.sdstest index de228f0d..6c6e2ca6 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/resource without package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/resource without package.sdstest @@ -1,11 +1,11 @@ -# $TEST$ target without_mySegment +// $TEST$ target without_mySegment segment »mySegment«() {} -# $TEST$ target without_publicSegmentWithoutPackage +// $TEST$ target without_publicSegmentWithoutPackage segment »publicSegmentWithoutPackage«() {} -# $TEST$ target without_internalSegmentWithoutPackage +// $TEST$ target without_internalSegmentWithoutPackage internal segment »internalSegmentWithoutPackage«() {} -# $TEST$ target without_privateSegmentWithoutPackage +// $TEST$ target without_privateSegmentWithoutPackage private segment »privateSegmentWithoutPackage«() {} diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to annotations/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to annotations/main.sdstest index dbc3ba36..1564119c 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to annotations/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to annotations/main.sdstest @@ -1,15 +1,15 @@ package tests.scoping.references.inSameFile.toAnnotations -# $TEST$ target before +// $TEST$ target before annotation »Before« segment mySegment() { - # $TEST$ references before + // $TEST$ references before »Before«; - # $TEST$ references after + // $TEST$ references after »After«; } -# $TEST$ target after +// $TEST$ target after annotation »After« diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to block lambda results/from outside/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to block lambda results/from outside/main.sdstest index f7656821..95875b7d 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to block lambda results/from outside/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to block lambda results/from outside/main.sdstest @@ -5,6 +5,6 @@ pipeline myPipeline { yield myBlockLambdaResult = 1; }; - # $TEST$ unresolved + // $TEST$ unresolved »myBlockLambdaResult«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to block lambda results/of containing block lambda/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to block lambda results/of containing block lambda/main.sdstest index f154af03..4a06f68d 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to block lambda results/of containing block lambda/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to block lambda results/of containing block lambda/main.sdstest @@ -3,7 +3,7 @@ package tests.scoping.references.inSameFile.toBlockLambdaResults.ofContainingBlo pipeline myPipeline { () { yield lambdaResult = 1; - # $TEST$ unresolved + // $TEST$ unresolved »lambdaResult«; }; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to class members/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to class members/main.sdstest index 90e4f88a..373eceea 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to class members/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to class members/main.sdstest @@ -13,21 +13,21 @@ class MyClass { } pipeline myPipeline { - # $TEST$ unresolved + // $TEST$ unresolved »staticAttribute«; - # $TEST$ unresolved + // $TEST$ unresolved »instanceAttribute«; - # $TEST$ unresolved + // $TEST$ unresolved »NestedClass«; - # $TEST$ unresolved + // $TEST$ unresolved »NestedEnum«; - # $TEST$ unresolved + // $TEST$ unresolved »staticMethod«; - # $TEST$ unresolved + // $TEST$ unresolved »instanceMethod«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to containing declarations/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to containing declarations/main.sdstest index 86bfd661..daee4dd2 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to containing declarations/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to containing declarations/main.sdstest @@ -3,112 +3,112 @@ package tests.scoping.references.inSameFile.toContainingDeclarations @Repeatable annotation MyAnnotation(p: Any?) -# $TEST$ target outerClass +// $TEST$ target outerClass class »MyClass«( @MyAnnotation( - # $TEST$ references outerClass + // $TEST$ references outerClass p = »MyClass«() ) - # $TEST$ references outerClass + // $TEST$ references outerClass p: Any? = »MyClass«() ) { @MyAnnotation( - # $TEST$ references outerClass + // $TEST$ references outerClass p = »MyClass«() ) @MyAnnotation( - # $TEST$ unresolved + // $TEST$ unresolved p = »MyEnum« ) fun f( @MyAnnotation( - # $TEST$ references outerClass + // $TEST$ references outerClass p = »MyClass«() ) - # $TEST$ references outerClass + // $TEST$ references outerClass p1: Any? = »MyClass«(), @MyAnnotation( - # $TEST$ unresolved + // $TEST$ unresolved p = »MyEnum« ) - # $TEST$ unresolved + // $TEST$ unresolved p2: Any? = »MyEnum« ) @MyAnnotation( - # $TEST$ references outerClass + // $TEST$ references outerClass p = »MyClass«() ) @MyAnnotation( - # $TEST$ unresolved + // $TEST$ unresolved p = »MyEnum« ) - # $TEST$ target enum + // $TEST$ target enum enum »MyEnum« { - # $TEST$ target variant + // $TEST$ target variant »MyEnumVariant«( @MyAnnotation( - # $TEST$ references outerClass + // $TEST$ references outerClass p = »MyClass«() ) - # $TEST$ references outerClass + // $TEST$ references outerClass p1: Any? = »MyClass«(), @MyAnnotation( - # $TEST$ references enum + // $TEST$ references enum p = »MyEnum« ) - # $TEST$ references enum + // $TEST$ references enum p2: Any? = »MyEnum«, @MyAnnotation( - # $TEST$ references variant + // $TEST$ references variant p = »MyEnumVariant« ) - # $TEST$ references variant + // $TEST$ references variant p3: Any? = »MyEnumVariant«, ) } @MyAnnotation( - # $TEST$ references outerClass + // $TEST$ references outerClass p = »MyClass«() ) @MyAnnotation( - # $TEST$ unresolved + // $TEST$ unresolved p = »MyEnum« ) - # $TEST$ target innerClass + // $TEST$ target innerClass class »MyClass«( @MyAnnotation( - # $TEST$ references innerClass + // $TEST$ references innerClass p = »MyClass«() ) - # $TEST$ references innerClass + // $TEST$ references innerClass p1: Any? = »MyClass«(), @MyAnnotation( - # $TEST$ unresolved + // $TEST$ unresolved p = »MyEnum« ) - # $TEST$ unresolved + // $TEST$ unresolved p2: Any? = »MyEnum« ) { fun f( @MyAnnotation( - # $TEST$ references innerClass + // $TEST$ references innerClass p = »MyClass«() ) - # $TEST$ references innerClass + // $TEST$ references innerClass p1: Any? = »MyClass«(), @MyAnnotation( - # $TEST$ unresolved + // $TEST$ unresolved p = »MyEnum« ) - # $TEST$ unresolved + // $TEST$ unresolved p2: Any? = »MyEnum« ) } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to enum variants/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to enum variants/main.sdstest index bfe6cdcb..180d015c 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to enum variants/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to enum variants/main.sdstest @@ -5,6 +5,6 @@ enum MyEnum { } pipeline myPipeline { - # $TEST$ unresolved + // $TEST$ unresolved »MyEnumVariant«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to global classes/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to global classes/main.sdstest index 8d3fefae..0085cf6c 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to global classes/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to global classes/main.sdstest @@ -1,15 +1,15 @@ package tests.scoping.references.inSameFile.toGlobalClasses -# $TEST$ target before +// $TEST$ target before class »Before«() pipeline myPipeline { - # $TEST$ references before + // $TEST$ references before »Before«; - # $TEST$ references after + // $TEST$ references after »After«; } -# $TEST$ target after +// $TEST$ target after class »After«() diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to global enums/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to global enums/main.sdstest index a70096c7..9ec1275a 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to global enums/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to global enums/main.sdstest @@ -1,15 +1,15 @@ package tests.scoping.references.inSameFile.toGlobalEnums -# $TEST$ target before +// $TEST$ target before enum »Before« pipeline myPipeline { - # $TEST$ references before + // $TEST$ references before »Before«(); - # $TEST$ references after + // $TEST$ references after »After«(); } -# $TEST$ target after +// $TEST$ target after enum »After« diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to global functions/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to global functions/main.sdstest index eb08a324..7f07163a 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to global functions/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to global functions/main.sdstest @@ -1,15 +1,15 @@ package tests.scoping.references.inSameFile.toGlobalFunctions -# $TEST$ target before +// $TEST$ target before fun »before«() pipeline myPipeline { - # $TEST$ references before + // $TEST$ references before »before«(); - # $TEST$ references after + // $TEST$ references after »after«(); } -# $TEST$ target after +// $TEST$ target after fun »after«() diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to modules/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to modules/main.sdstest index da5ea19e..2904f0e2 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to modules/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to modules/main.sdstest @@ -1,6 +1,6 @@ package tests pipeline myPipeline { - # $TEST$ unresolved + // $TEST$ unresolved »tests«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/from default value of parameter/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/from default value of parameter/main.sdstest index 3b48e359..bdd2e7af 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/from default value of parameter/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/from default value of parameter/main.sdstest @@ -1,84 +1,84 @@ package tests.scoping.references.inSameFile.toParameters.fromDefaultValueOfParameter annotation MyAnnotation( - # $TEST$ target annotation_param - # $TEST$ unresolved + // $TEST$ target annotation_param + // $TEST$ unresolved »p«: String = »q«, - # $TEST$ references annotation_param + // $TEST$ references annotation_param q: String = »p«, - # $TEST$ unresolved + // $TEST$ unresolved r: String = »r«, ) class MyClass( - # $TEST$ target class_param - # $TEST$ unresolved + // $TEST$ target class_param + // $TEST$ unresolved »p«: String = »q«, - # $TEST$ references class_param + // $TEST$ references class_param q: String = »p«, - # $TEST$ unresolved + // $TEST$ unresolved r: String = »r«, ) enum MyEnum { MyEnumVariant( - # $TEST$ target enum_variant_param - # $TEST$ unresolved + // $TEST$ target enum_variant_param + // $TEST$ unresolved »p«: String = »q«, - # $TEST$ references enum_variant_param + // $TEST$ references enum_variant_param q: String = »p«, - # $TEST$ unresolved + // $TEST$ unresolved r: String = »r«, ) } fun myFunction( - # $TEST$ target function_param - # $TEST$ unresolved + // $TEST$ target function_param + // $TEST$ unresolved »p«: String = »q«, - # $TEST$ references function_param + // $TEST$ references function_param q: String = »p«, - # $TEST$ unresolved + // $TEST$ unresolved r: String = »r«, ) segment mySegment1( - # $TEST$ target segment_param - # $TEST$ unresolved + // $TEST$ target segment_param + // $TEST$ unresolved »p«: String = »q«, - # $TEST$ references segment_param + // $TEST$ references segment_param q: String = »p«, - # $TEST$ unresolved + // $TEST$ unresolved r: String = »r«, ) {} segment mySegment2( p: ( - # $TEST$ target callable_type_param - # $TEST$ unresolved + // $TEST$ target callable_type_param + // $TEST$ unresolved »p«: String = »q«, - # $TEST$ references callable_type_param + // $TEST$ references callable_type_param q: String = »p«, - # $TEST$ unresolved + // $TEST$ unresolved r: String = »r«, ) -> () ) { ( - # $TEST$ target block_lambda_param - # $TEST$ unresolved + // $TEST$ target block_lambda_param + // $TEST$ unresolved »p«: String = »q«, - # $TEST$ references block_lambda_param + // $TEST$ references block_lambda_param q: String = »p«, - # $TEST$ unresolved + // $TEST$ unresolved r: String = »r«, ) {}; ( - # $TEST$ target block_function_param - # $TEST$ unresolved + // $TEST$ target block_function_param + // $TEST$ unresolved »p«: String = »q«, - # $TEST$ references block_function_param + // $TEST$ references block_function_param q: String = »p«, - # $TEST$ unresolved + // $TEST$ unresolved r: String = »r«, ) -> 1; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/from outside/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/from outside/main.sdstest index 6af77d45..d923ca8e 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/from outside/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/from outside/main.sdstest @@ -18,27 +18,27 @@ segment mySegment2( (myBlockLambdaParameter) {}; (myExpressionLambdaParameter) -> 1; - # $TEST$ unresolved + // $TEST$ unresolved »myAnnotationParameter«; - # $TEST$ unresolved + // $TEST$ unresolved »myClassParameter«; - # $TEST$ unresolved + // $TEST$ unresolved »myEnumVariantParameter«; - # $TEST$ unresolved + // $TEST$ unresolved »myFunctionParameter«; - # $TEST$ unresolved + // $TEST$ unresolved »mySegmentParameter«; - # $TEST$ unresolved + // $TEST$ unresolved »myCallableTypeParameter«; - # $TEST$ unresolved + // $TEST$ unresolved »myBlockLambdaParameter«; - # $TEST$ unresolved + // $TEST$ unresolved »myExpressionLambdaParameter«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/from parameter bound/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/from parameter bound/main.sdstest index 3948dc6e..dfd795e3 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/from parameter bound/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/from parameter bound/main.sdstest @@ -1,39 +1,39 @@ package tests.scoping.references.inSameFile.toParameters.fromParameterBound -# $TEST$ target annotation_p +// $TEST$ target annotation_p annotation MyAnnotation(»p«: Int) where { - # $TEST$ references annotation_p + // $TEST$ references annotation_p p < »p«, - # $TEST$ unresolved + // $TEST$ unresolved p > »unresolved«, } -# $TEST$ target class_p +// $TEST$ target class_p class MyClass(»p«: Int) where { - # $TEST$ references class_p + // $TEST$ references class_p p < »p«, - # $TEST$ unresolved + // $TEST$ unresolved p > »unresolved«, } -# $TEST$ target enumVariant_p +// $TEST$ target enumVariant_p enum MyEnum { MyEnumVariant(»p«: Int) where { - # $TEST$ references enumVariant_p + // $TEST$ references enumVariant_p p < »p«, - # $TEST$ unresolved + // $TEST$ unresolved p > »unresolved«, } } -# $TEST$ target function_p +// $TEST$ target function_p fun myFunction(»p«: Int) where { - # $TEST$ references function_p + // $TEST$ references function_p p < »p«, - # $TEST$ unresolved + // $TEST$ unresolved p > »unresolved«, } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/of containing block lambda/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/of containing block lambda/main.sdstest index e6ee997b..5ca399e9 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/of containing block lambda/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/of containing block lambda/main.sdstest @@ -4,75 +4,75 @@ segment mySegment(myShadowedSegmentParameter: Int) { val myShadowedPlaceholder = 0; ( - # $TEST$ target outer_myOuterBlockLambdaParameter + // $TEST$ target outer_myOuterBlockLambdaParameter »myOuterBlockLambdaParameter«, - # $TEST$ target outer_myShadowedSegmentParameter + // $TEST$ target outer_myShadowedSegmentParameter »myShadowedSegmentParameter«, - # $TEST$ target outer_myShadowedBlockLambdaParameter + // $TEST$ target outer_myShadowedBlockLambdaParameter »myShadowedBlockLambdaParameter«, - # $TEST$ target outer_myShadowedPlaceholder + // $TEST$ target outer_myShadowedPlaceholder »myShadowedPlaceholder«, - # $TEST$ target redeclaredAsParameter + // $TEST$ target redeclaredAsParameter »redeclaredAsParameter«, redeclaredAsParameter, - # $TEST$ target redeclaredAsPlaceholder + // $TEST$ target redeclaredAsPlaceholder »redeclaredAsPlaceholder«, ) { val redeclaredAsPlaceholder = 0; - # $TEST$ references outer_myOuterBlockLambdaParameter + // $TEST$ references outer_myOuterBlockLambdaParameter »myOuterBlockLambdaParameter«; - # $TEST$ references outer_myShadowedSegmentParameter + // $TEST$ references outer_myShadowedSegmentParameter »myShadowedSegmentParameter«; - # $TEST$ references outer_myShadowedBlockLambdaParameter + // $TEST$ references outer_myShadowedBlockLambdaParameter »myShadowedBlockLambdaParameter«; - # $TEST$ references outer_myShadowedPlaceholder + // $TEST$ references outer_myShadowedPlaceholder »myShadowedPlaceholder«; - # $TEST$ references redeclaredAsParameter + // $TEST$ references redeclaredAsParameter »redeclaredAsParameter«; - # $TEST$ references redeclaredAsPlaceholder + // $TEST$ references redeclaredAsPlaceholder »redeclaredAsPlaceholder«; - # $TEST$ unresolved + // $TEST$ unresolved »myInnerBlockLambdaParameter«; ( - # $TEST$ target inner_myInnerBlockLambdaParameter + // $TEST$ target inner_myInnerBlockLambdaParameter »myInnerBlockLambdaParameter«, - # $TEST$ target inner_myShadowedBlockLambdaParameter + // $TEST$ target inner_myShadowedBlockLambdaParameter »myShadowedBlockLambdaParameter« ) { () -> - # $TEST$ references outer_myOuterBlockLambdaParameter + // $TEST$ references outer_myOuterBlockLambdaParameter »myOuterBlockLambdaParameter« + - # $TEST$ references outer_myShadowedSegmentParameter + // $TEST$ references outer_myShadowedSegmentParameter »myShadowedSegmentParameter« + - # $TEST$ references inner_myShadowedBlockLambdaParameter + // $TEST$ references inner_myShadowedBlockLambdaParameter »myShadowedBlockLambdaParameter«; - # $TEST$ references outer_myShadowedPlaceholder + // $TEST$ references outer_myShadowedPlaceholder »myShadowedPlaceholder« + - # $TEST$ references redeclaredAsParameter + // $TEST$ references redeclaredAsParameter »redeclaredAsParameter« + - # $TEST$ references redeclaredAsPlaceholder + // $TEST$ references redeclaredAsPlaceholder »redeclaredAsPlaceholder« + - # $TEST$ references inner_myInnerBlockLambdaParameter + // $TEST$ references inner_myInnerBlockLambdaParameter »myInnerBlockLambdaParameter«; }; diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/of containing expression lambda/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/of containing expression lambda/main.sdstest index fc2a78fb..1f5fd6cc 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/of containing expression lambda/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/of containing expression lambda/main.sdstest @@ -4,64 +4,64 @@ segment mySegment(myShadowedSegmentParameter: Int) { val myShadowedPlaceholder = 0; ( - # $TEST$ target outer_myOuterExpressionLambdaParameter + // $TEST$ target outer_myOuterExpressionLambdaParameter »myOuterExpressionLambdaParameter«, - # $TEST$ target outer_myShadowedSegmentParameter + // $TEST$ target outer_myShadowedSegmentParameter »myShadowedSegmentParameter«, - # $TEST$ target outer_myShadowedExpressionLambdaParameter + // $TEST$ target outer_myShadowedExpressionLambdaParameter »myShadowedExpressionLambdaParameter«, - # $TEST$ target outer_myShadowedPlaceholder + // $TEST$ target outer_myShadowedPlaceholder »myShadowedPlaceholder«, - # $TEST$ target outer_redeclaredAsParameter + // $TEST$ target outer_redeclaredAsParameter »redeclaredAsParameter«, redeclaredAsParameter ) -> - # $TEST$ references outer_myOuterExpressionLambdaParameter + // $TEST$ references outer_myOuterExpressionLambdaParameter »myOuterExpressionLambdaParameter« + - # $TEST$ references outer_myShadowedSegmentParameter + // $TEST$ references outer_myShadowedSegmentParameter »myShadowedSegmentParameter« + - # $TEST$ references outer_myShadowedPlaceholder + // $TEST$ references outer_myShadowedPlaceholder »myShadowedPlaceholder« + - # $TEST$ references outer_redeclaredAsParameter + // $TEST$ references outer_redeclaredAsParameter »redeclaredAsParameter« + - # $TEST$ unresolved + // $TEST$ unresolved »myInnerExpressionLambdaParameter« + - # $TEST$ references outer_myShadowedExpressionLambdaParameter + // $TEST$ references outer_myShadowedExpressionLambdaParameter »myShadowedExpressionLambdaParameter« + (( - # $TEST$ target inner_myInnerExpressionLambdaParameter + // $TEST$ target inner_myInnerExpressionLambdaParameter »myInnerExpressionLambdaParameter«, - # $TEST$ target inner_myShadowedExpressionLambdaParameter + // $TEST$ target inner_myShadowedExpressionLambdaParameter »myShadowedExpressionLambdaParameter«, ) -> () { - # $TEST$ references outer_myOuterExpressionLambdaParameter + // $TEST$ references outer_myOuterExpressionLambdaParameter »myOuterExpressionLambdaParameter«; - # $TEST$ references outer_myShadowedSegmentParameter + // $TEST$ references outer_myShadowedSegmentParameter »myShadowedSegmentParameter«; - # $TEST$ references outer_myShadowedPlaceholder + // $TEST$ references outer_myShadowedPlaceholder »myShadowedPlaceholder«; - # $TEST$ references outer_redeclaredAsParameter + // $TEST$ references outer_redeclaredAsParameter »redeclaredAsParameter«; - # $TEST$ references inner_myInnerExpressionLambdaParameter + // $TEST$ references inner_myInnerExpressionLambdaParameter »myInnerExpressionLambdaParameter«; - # $TEST$ references inner_myShadowedExpressionLambdaParameter + // $TEST$ references inner_myShadowedExpressionLambdaParameter »myShadowedExpressionLambdaParameter«; } ) diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/of containing segment/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/of containing segment/main.sdstest index cfba356d..6d0766b7 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/of containing segment/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/of containing segment/main.sdstest @@ -1,45 +1,45 @@ package tests.scoping.references.inSameFile.toParameters.ofContainingExpressionLambda segment mySegment( - # $TEST$ target parameter + // $TEST$ target parameter »myParameter«: Int, - # $TEST$ target redeclaredAsParameter + // $TEST$ target redeclaredAsParameter »redeclaredAsParameter«: Int, redeclaredAsParameter: Int, - # $TEST$ target redeclaredAsPlaceholder + // $TEST$ target redeclaredAsPlaceholder »redeclaredAsPlaceholder«: Int ) { val redeclaredAsPlaceholder = 0; - # $TEST$ references parameter + // $TEST$ references parameter »myParameter«; - # $TEST$ references redeclaredAsParameter + // $TEST$ references redeclaredAsParameter »redeclaredAsParameter«; - # $TEST$ references redeclaredAsPlaceholder + // $TEST$ references redeclaredAsPlaceholder »redeclaredAsPlaceholder«; () { - # $TEST$ references parameter + // $TEST$ references parameter »myParameter«; - # $TEST$ references redeclaredAsParameter + // $TEST$ references redeclaredAsParameter »redeclaredAsParameter«; - # $TEST$ references redeclaredAsPlaceholder + // $TEST$ references redeclaredAsPlaceholder »redeclaredAsPlaceholder«; }; () -> - # $TEST$ references parameter + // $TEST$ references parameter »myParameter« + - # $TEST$ references redeclaredAsParameter + // $TEST$ references redeclaredAsParameter »redeclaredAsParameter« + - # $TEST$ references redeclaredAsPlaceholder + // $TEST$ references redeclaredAsPlaceholder »redeclaredAsPlaceholder«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to pipelines/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to pipelines/main.sdstest index 9ad61ad5..6a0fe7a3 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to pipelines/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to pipelines/main.sdstest @@ -1,15 +1,15 @@ package tests.scoping.references.inSameFile.toPipelines -# $TEST$ target before +// $TEST$ target before pipeline »before« {} segment mySegment() { - # $TEST$ references before + // $TEST$ references before »before«; - # $TEST$ references after + // $TEST$ references after »after«; } -# $TEST$ target after +// $TEST$ target after pipeline »after« {} diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to placeholders/from outside/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to placeholders/from outside/main.sdstest index 54858704..6c0aa54d 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to placeholders/from outside/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to placeholders/from outside/main.sdstest @@ -13,12 +13,12 @@ pipeline myPipeline2 { val blockLambdaPlaceholder = 1; }; - # $TEST$ unresolved + // $TEST$ unresolved »pipelinePlaceholder«; - # $TEST$ unresolved + // $TEST$ unresolved »segmentPlaceholder«; - # $TEST$ unresolved + // $TEST$ unresolved »blockLambdaPlaceholder«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to placeholders/of containing block lambda/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to placeholders/of containing block lambda/main.sdstest index 3fe2022c..434bf178 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to placeholders/of containing block lambda/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to placeholders/of containing block lambda/main.sdstest @@ -4,123 +4,123 @@ segment mySegment(mySegmentParameter: Int) { val mySegmentPlaceholder = 0; (myOuterBlockLambdaParameter) { - # $TEST$ target outer_mySegmentParameter + // $TEST$ target outer_mySegmentParameter val »mySegmentParameter« = 0; - # $TEST$ target outer_mySegmentPlaceholder + // $TEST$ target outer_mySegmentPlaceholder val »mySegmentPlaceholder« = 0; - # $TEST$ target outer_myOuterBlockLambdaPlaceholderBefore + // $TEST$ target outer_myOuterBlockLambdaPlaceholderBefore val »myOuterBlockLambdaPlaceholderBefore« = 0; - # $TEST$ target outer_redeclared + // $TEST$ target outer_redeclared val »redeclared« = 0; val redeclared = 0; - # $TEST$ references outer_mySegmentParameter + // $TEST$ references outer_mySegmentParameter »mySegmentParameter«; - # $TEST$ references outer_mySegmentPlaceholder + // $TEST$ references outer_mySegmentPlaceholder »mySegmentPlaceholder«; - # $TEST$ references outer_myOuterBlockLambdaPlaceholderBefore + // $TEST$ references outer_myOuterBlockLambdaPlaceholderBefore »myOuterBlockLambdaPlaceholderBefore«; - # $TEST$ references outer_redeclared + // $TEST$ references outer_redeclared »redeclared«; - # $TEST$ unresolved + // $TEST$ unresolved »myOuterBlockLambdaPlaceholderAfter«; val blockLambda = () { - # $TEST$ target inner_mySegmentParameter + // $TEST$ target inner_mySegmentParameter val »mySegmentParameter« = 0; - # $TEST$ target inner_mySegmentPlaceholder + // $TEST$ target inner_mySegmentPlaceholder val »mySegmentPlaceholder« = 0; - # $TEST$ target inner_myOuterBlockLambdaParameter + // $TEST$ target inner_myOuterBlockLambdaParameter val »myOuterBlockLambdaParameter« = 0; - # $TEST$ target inner_myOuterBlockLambdaPlaceholderBefore + // $TEST$ target inner_myOuterBlockLambdaPlaceholderBefore val »myOuterBlockLambdaPlaceholderBefore« = 0; - # $TEST$ references inner_mySegmentParameter + // $TEST$ references inner_mySegmentParameter »mySegmentParameter«; - # $TEST$ references inner_mySegmentPlaceholder + // $TEST$ references inner_mySegmentPlaceholder »mySegmentPlaceholder«; - # $TEST$ references inner_myOuterBlockLambdaParameter + // $TEST$ references inner_myOuterBlockLambdaParameter »myOuterBlockLambdaParameter«; - # $TEST$ references inner_myOuterBlockLambdaPlaceholderBefore + // $TEST$ references inner_myOuterBlockLambdaPlaceholderBefore »myOuterBlockLambdaPlaceholderBefore«; - # $TEST$ references outer_redeclared + // $TEST$ references outer_redeclared »redeclared«; - # $TEST$ unresolved + // $TEST$ unresolved »blockLambda«; - # $TEST$ unresolved + // $TEST$ unresolved »myOuterBlockLambdaPlaceholderAfter«; val expressionLambda = () -> - # $TEST$ references inner_mySegmentParameter + // $TEST$ references inner_mySegmentParameter »mySegmentParameter« + - # $TEST$ references inner_mySegmentPlaceholder + // $TEST$ references inner_mySegmentPlaceholder »mySegmentPlaceholder« + - # $TEST$ references inner_myOuterBlockLambdaParameter + // $TEST$ references inner_myOuterBlockLambdaParameter »myOuterBlockLambdaParameter« + - # $TEST$ references inner_myOuterBlockLambdaPlaceholderBefore + // $TEST$ references inner_myOuterBlockLambdaPlaceholderBefore »myOuterBlockLambdaPlaceholderBefore« + - # $TEST$ references outer_redeclared + // $TEST$ references outer_redeclared »redeclared« + - # $TEST$ unresolved + // $TEST$ unresolved »blockLambda« + - # $TEST$ unresolved + // $TEST$ unresolved »expressionLambda« + - # $TEST$ unresolved + // $TEST$ unresolved »myOuterBlockLambdaPlaceholderAfter«; }; () -> () { - # $TEST$ target blockLambdaInExpressionLambda_mySegmentParameter + // $TEST$ target blockLambdaInExpressionLambda_mySegmentParameter val »mySegmentParameter« = 0; - # $TEST$ target blockLambdaInExpressionLambda_mySegmentPlaceholder + // $TEST$ target blockLambdaInExpressionLambda_mySegmentPlaceholder val »mySegmentPlaceholder« = 0; - # $TEST$ target blockLambdaInExpressionLambda_myOuterBlockLambdaParameter + // $TEST$ target blockLambdaInExpressionLambda_myOuterBlockLambdaParameter val »myOuterBlockLambdaParameter« = 0; - # $TEST$ target blockLambdaInExpressionLambda_myOuterBlockLambdaPlaceholderBefore + // $TEST$ target blockLambdaInExpressionLambda_myOuterBlockLambdaPlaceholderBefore val »myOuterBlockLambdaPlaceholderBefore« = 0; - # $TEST$ references blockLambdaInExpressionLambda_mySegmentParameter + // $TEST$ references blockLambdaInExpressionLambda_mySegmentParameter »mySegmentParameter«; - # $TEST$ references blockLambdaInExpressionLambda_mySegmentPlaceholder + // $TEST$ references blockLambdaInExpressionLambda_mySegmentPlaceholder »mySegmentPlaceholder«; - # $TEST$ references blockLambdaInExpressionLambda_myOuterBlockLambdaPlaceholderBefore + // $TEST$ references blockLambdaInExpressionLambda_myOuterBlockLambdaPlaceholderBefore »myOuterBlockLambdaPlaceholderBefore«; - # $TEST$ references outer_redeclared + // $TEST$ references outer_redeclared »redeclared«; - # $TEST$ unresolved + // $TEST$ unresolved »myOuterBlockLambdaPlaceholderAfter«; }; diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to placeholders/of containing pipeline/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to placeholders/of containing pipeline/main.sdstest index 8baecf46..48ceac04 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to placeholders/of containing pipeline/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to placeholders/of containing pipeline/main.sdstest @@ -1,61 +1,61 @@ package tests.scoping.references.inSameFile.toPlaceholders.ofContainingPipeline pipeline myPipeline { - # $TEST$ target before + // $TEST$ target before val »before« = 0; - # $TEST$ target redeclared + // $TEST$ target redeclared val »redeclared« = 0; val redeclared = 0; - # $TEST$ references before + // $TEST$ references before »before«; - # $TEST$ references redeclared + // $TEST$ references redeclared »redeclared«; - # $TEST$ unresolved + // $TEST$ unresolved »after«; val blockLambda = () { - # $TEST$ references before + // $TEST$ references before »before«; - # $TEST$ references redeclared + // $TEST$ references redeclared »redeclared«; - # $TEST$ unresolved + // $TEST$ unresolved »blockLambda«; - # $TEST$ unresolved + // $TEST$ unresolved »after«; () { - # $TEST$ references before + // $TEST$ references before »before«; - # $TEST$ references redeclared + // $TEST$ references redeclared »redeclared«; - # $TEST$ unresolved + // $TEST$ unresolved »blockLambda«; - # $TEST$ unresolved + // $TEST$ unresolved »after«; }; }; val expressionLambda = () -> - # $TEST$ references before + // $TEST$ references before »before« + - # $TEST$ references redeclared + // $TEST$ references redeclared »redeclared« + - # $TEST$ unresolved + // $TEST$ unresolved »expressionLambda« + - # $TEST$ unresolved + // $TEST$ unresolved »after«; val after = 1; diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to placeholders/of containing segment/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to placeholders/of containing segment/main.sdstest index 9f9e467c..4105498b 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to placeholders/of containing segment/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to placeholders/of containing segment/main.sdstest @@ -1,61 +1,61 @@ package tests.scoping.references.inSameFile.toPlaceholders.ofContainingSegment segment mySegment() { - # $TEST$ target before + // $TEST$ target before val »before« = 0; - # $TEST$ target redeclared + // $TEST$ target redeclared val »redeclared« = 0; val redeclared = 0; - # $TEST$ references before + // $TEST$ references before »before«; - # $TEST$ references redeclared + // $TEST$ references redeclared »redeclared«; - # $TEST$ unresolved + // $TEST$ unresolved »after«; val blockLambda = () { - # $TEST$ references before + // $TEST$ references before »before«; - # $TEST$ references redeclared + // $TEST$ references redeclared »redeclared«; - # $TEST$ unresolved + // $TEST$ unresolved »blockLambda«; - # $TEST$ unresolved + // $TEST$ unresolved »after«; () { - # $TEST$ references before + // $TEST$ references before »before«; - # $TEST$ references redeclared + // $TEST$ references redeclared »redeclared«; - # $TEST$ unresolved + // $TEST$ unresolved »blockLambda«; - # $TEST$ unresolved + // $TEST$ unresolved »after«; }; }; val expressionLambda = () -> - # $TEST$ references before + // $TEST$ references before »before« + - # $TEST$ references redeclared + // $TEST$ references redeclared »redeclared« + - # $TEST$ unresolved + // $TEST$ unresolved »expressionLambda« + - # $TEST$ unresolved + // $TEST$ unresolved »after«; val after = 1; diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to redeclared module member/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to redeclared module member/main.sdstest index 5594298f..55939d2f 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to redeclared module member/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to redeclared module member/main.sdstest @@ -1,19 +1,19 @@ package tests.scoping.references.inSameFile.toRedeclaredModuleMember -# $TEST$ target before +// $TEST$ target before class »Before« class Before segment mySegment() { - # $TEST$ references before + // $TEST$ references before »Before«; - # $TEST$ references after + // $TEST$ references after »after«; } -# $TEST$ target after +// $TEST$ target after fun »after«() fun after() diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to results/from outside/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to results/from outside/main.sdstest index 686d9132..4943e09c 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to results/from outside/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to results/from outside/main.sdstest @@ -7,12 +7,12 @@ segment mySegment1() -> (mySegmentResult: String) {} segment mySegment2( p: () -> (myCallableTypeResult: String) ) { - # $TEST$ unresolved + // $TEST$ unresolved »myFunctionResult«; - # $TEST$ unresolved + // $TEST$ unresolved »mySegmentResult«; - # $TEST$ unresolved + // $TEST$ unresolved »myCallableTypeResult«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to results/of containing segment/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to results/of containing segment/main.sdstest index 7f000da8..e0727091 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to results/of containing segment/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to results/of containing segment/main.sdstest @@ -1,6 +1,6 @@ package tests.scoping.references.inSameFile.toResults.ofContainingSegment segment mySegment() -> myResult: Int { - # $TEST$ unresolved + // $TEST$ unresolved »myResult«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to schemas/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to schemas/main.sdstest index 1b2ecb43..a3832361 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to schemas/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to schemas/main.sdstest @@ -1,15 +1,15 @@ package tests.scoping.references.inSameFile.toSchemas -# $TEST$ target before +// $TEST$ target before schema »Before« {} segment mySegment() { - # $TEST$ references before + // $TEST$ references before »Before«; - # $TEST$ references after + // $TEST$ references after »After«; } -# $TEST$ target after +// $TEST$ target after schema »After« {} diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to segments/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to segments/main.sdstest index 10ce68d0..6223ba59 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to segments/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to segments/main.sdstest @@ -1,32 +1,32 @@ package tests.scoping.references.inSameFile.toSegments -# $TEST$ target privateBefore +// $TEST$ target privateBefore private segment »privateBefore«() {} -# $TEST$ target internalBefore +// $TEST$ target internalBefore internal segment »internalBefore«() {} -# $TEST$ target publicBefore +// $TEST$ target publicBefore segment »publicBefore«() {} pipeline myPipeline { - # $TEST$ references privateBefore + // $TEST$ references privateBefore »privateBefore«(); - # $TEST$ references internalBefore + // $TEST$ references internalBefore »internalBefore«(); - # $TEST$ references publicBefore + // $TEST$ references publicBefore »publicBefore«(); - # $TEST$ references privateAfter + // $TEST$ references privateAfter »privateAfter«(); - # $TEST$ references internalAfter + // $TEST$ references internalAfter »internalAfter«(); } -# $TEST$ target privateAfter +// $TEST$ target privateAfter private segment »privateAfter«() {} -# $TEST$ target internalAfter +// $TEST$ target internalAfter internal segment »internalAfter«() {} -# $TEST$ target publicAfter +// $TEST$ target publicAfter segment »publicAfter«() {} diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to type parameters/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to type parameters/main.sdstest index ce3c2a4a..8416c939 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to type parameters/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to type parameters/main.sdstest @@ -3,6 +3,6 @@ package tests.scoping.references.inSameFile.toTypeParameters class MyClass() pipeline myPipeline { - # $TEST$ unresolved + // $TEST$ unresolved »T«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/unresolved/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/unresolved/main.sdstest index 98e4389d..6bb2abd3 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/unresolved/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/unresolved/main.sdstest @@ -1,6 +1,6 @@ package tests.scoping.references.unresolved segment mySegment() { - # $TEST$ unresolved + // $TEST$ unresolved »unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/type arguments/to something other than type parameter/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/type arguments/to something other than type parameter/main.sdstest index 1b8a3ca3..d0006b66 100644 --- a/packages/ttsl-lang/tests/resources/scoping/type arguments/to something other than type parameter/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/type arguments/to something other than type parameter/main.sdstest @@ -1,6 +1,6 @@ package tests.scoping.typeArguments.toSomethingOtherThanTypeParameter -# $TEST$ unresolved +// $TEST$ unresolved segment mySegment(p: MyClass<»notAtypeParameter« = Int>) {} class MyClass diff --git a/packages/ttsl-lang/tests/resources/scoping/type arguments/to type parameter in containing named type declaration/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/type arguments/to type parameter in containing named type declaration/main.sdstest index 74f47b34..fa3253f8 100644 --- a/packages/ttsl-lang/tests/resources/scoping/type arguments/to type parameter in containing named type declaration/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/type arguments/to type parameter in containing named type declaration/main.sdstest @@ -1,45 +1,45 @@ package tests.scoping.typeArguments.toTypeParameterInContainingNamedTypeDeclaration -# $TEST$ target outerClass +// $TEST$ target outerClass class MyClass<»T«>( - # $TEST$ references outerClass + // $TEST$ references outerClass p: MyClass<»T« = Int>, -# $TEST$ references outerClass +// $TEST$ references outerClass ) sub MyClass<»T« = Int> { - # $TEST$ references outerClass + // $TEST$ references outerClass attr a: MyClass<»T« = Int> fun f( - # $TEST$ references outerClass + // $TEST$ references outerClass p: MyClass<»T« = Int>, ) -> ( - # $TEST$ references outerClass + // $TEST$ references outerClass r: MyClass<»T« = Int>, ) enum MyEnum { MyEnumVariant( - # $TEST$ references outerClass + // $TEST$ references outerClass p: MyClass<»T« = Int>, ) } - # $TEST$ target innerClass + // $TEST$ target innerClass class MyClass<»T«>( - # $TEST$ references innerClass + // $TEST$ references innerClass p: MyClass<»T« = Int>, - # $TEST$ references innerClass + // $TEST$ references innerClass ) sub MyClass<»T« = Int> { - # $TEST$ references innerClass + // $TEST$ references innerClass attr a: MyClass<»T« = Int> fun f( - # $TEST$ references innerClass + // $TEST$ references innerClass p: MyClass<»T« = Int>, ) -> ( - # $TEST$ references innerClass + // $TEST$ references innerClass r: MyClass<»T« = Int>, ) } diff --git a/packages/ttsl-lang/tests/resources/scoping/type arguments/to type parameter in global class/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/type arguments/to type parameter in global class/main.sdstest index 8142d6d2..5ac02bf5 100644 --- a/packages/ttsl-lang/tests/resources/scoping/type arguments/to type parameter in global class/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/type arguments/to type parameter in global class/main.sdstest @@ -1,9 +1,9 @@ package tests.scoping.typeArguments.toTypeParameterInGlobalClass -# $TEST$ target t +// $TEST$ target t class MyClass<»T«> segment mySegment( - # $TEST$ references t + // $TEST$ references t p: MyClass<»T« = Int> ) {} diff --git a/packages/ttsl-lang/tests/resources/scoping/type arguments/to type parameter in nested class/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/type arguments/to type parameter in nested class/main.sdstest index 1a8674b2..5f02c2b8 100644 --- a/packages/ttsl-lang/tests/resources/scoping/type arguments/to type parameter in nested class/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/type arguments/to type parameter in nested class/main.sdstest @@ -1,11 +1,11 @@ package tests.scoping.typeArguments.toTypeParameterInNestedClass class MyClass { - # $TEST$ target t + // $TEST$ target t class MyNestedClass<»T«> } segment mySegment( - # $TEST$ references t + // $TEST$ references t p: MyClass.MyNestedClass<»T« = Int> ) {} diff --git a/packages/ttsl-lang/tests/resources/scoping/type arguments/to unresolved/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/type arguments/to unresolved/main.sdstest index b8bf729e..808373e7 100644 --- a/packages/ttsl-lang/tests/resources/scoping/type arguments/to unresolved/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/type arguments/to unresolved/main.sdstest @@ -1,10 +1,10 @@ package tests.scoping.typeArguments.toUnresolved segment mySegment( - # $TEST$ unresolved + // $TEST$ unresolved p1: MyClass<»unresolved« = Int>, - # $TEST$ unresolved + // $TEST$ unresolved p2: unresolved<»T« = Int>, ) {} diff --git a/packages/ttsl-lang/tests/resources/scoping/yields/in pipeline/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/yields/in pipeline/main.sdstest index cb5357e1..c43abe9d 100644 --- a/packages/ttsl-lang/tests/resources/scoping/yields/in pipeline/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/yields/in pipeline/main.sdstest @@ -3,16 +3,16 @@ package tests.scoping.yields.inPipeline segment mySegment1() -> before: Int {} pipeline myPipeline { - # $TEST$ unresolved + // $TEST$ unresolved yield »before« = 1; - # $TEST$ unresolved + // $TEST$ unresolved yield »after« = 1; - # $TEST$ unresolved + // $TEST$ unresolved yield »NotAResult« = 1; - # $TEST$ unresolved + // $TEST$ unresolved yield »unresolved« = 1; } diff --git a/packages/ttsl-lang/tests/resources/scoping/yields/in segment/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/yields/in segment/main.sdstest index 655a7b32..56b29de9 100644 --- a/packages/ttsl-lang/tests/resources/scoping/yields/in segment/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/yields/in segment/main.sdstest @@ -3,29 +3,29 @@ package tests.scoping.yields.inSegment segment mySegment1() -> before: Int {} segment mySegment() -> ( - # $TEST$ target result + // $TEST$ target result »result«: Int, - # $TEST$ target redeclared + // $TEST$ target redeclared »redeclared«: Int, redeclared: Int, ) { - # $TEST$ references result + // $TEST$ references result yield »result« = 1; - # $TEST$ references redeclared + // $TEST$ references redeclared yield »redeclared« = 1; - # $TEST$ unresolved + // $TEST$ unresolved yield »before« = 1; - # $TEST$ unresolved + // $TEST$ unresolved yield »after« = 1; - # $TEST$ unresolved + // $TEST$ unresolved yield »NotAResult« = 1; - # $TEST$ unresolved + // $TEST$ unresolved yield »unresolved« = 1; } diff --git a/packages/ttsl-lang/tests/resources/typing/assignees/block lambda results/main.sdstest b/packages/ttsl-lang/tests/resources/typing/assignees/block lambda results/main.sdstest index 28fc7cc7..a6f46d81 100644 --- a/packages/ttsl-lang/tests/resources/typing/assignees/block lambda results/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/assignees/block lambda results/main.sdstest @@ -4,20 +4,20 @@ fun f() -> (r1: Int, r2: Float, r3: String) segment mySegment() -> (r: Int) { () { - # $TEST$ equivalence_class assignedValue - # $TEST$ equivalence_class assignedValue + // $TEST$ equivalence_class assignedValue + // $TEST$ equivalence_class assignedValue yield »r« = »1«; }; () { - # $TEST$ serialization literal<1> - # $TEST$ serialization $unknown + // $TEST$ serialization literal<1> + // $TEST$ serialization $unknown yield »r«, yield »s« = 1; }; () { - # $TEST$ serialization Int - # $TEST$ serialization String + // $TEST$ serialization Int + // $TEST$ serialization String yield »r«, _, yield »s« = f(); }; } diff --git a/packages/ttsl-lang/tests/resources/typing/assignees/placeholders/main.sdstest b/packages/ttsl-lang/tests/resources/typing/assignees/placeholders/main.sdstest index 16cce0ac..144cda8d 100644 --- a/packages/ttsl-lang/tests/resources/typing/assignees/placeholders/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/assignees/placeholders/main.sdstest @@ -3,19 +3,19 @@ package tests.typing.assignees.placeholders fun f() -> (r1: Int, r2: Float, r3: String) segment mySegment1() -> (r: Int) { - # $TEST$ equivalence_class assignedValue - # $TEST$ equivalence_class assignedValue + // $TEST$ equivalence_class assignedValue + // $TEST$ equivalence_class assignedValue val »r« = »1«; } segment mySegment2() -> (r: Int, s: String) { - # $TEST$ serialization literal<1> - # $TEST$ serialization $unknown + // $TEST$ serialization literal<1> + // $TEST$ serialization $unknown val »r«, val »s« = 1; } segment mySegment3() -> (r: Int, s: String) { - # $TEST$ serialization Int - # $TEST$ serialization String + // $TEST$ serialization Int + // $TEST$ serialization String val »r«, _, val »s« = f(); } diff --git a/packages/ttsl-lang/tests/resources/typing/assignees/yields/main.sdstest b/packages/ttsl-lang/tests/resources/typing/assignees/yields/main.sdstest index 9248abac..b26079cd 100644 --- a/packages/ttsl-lang/tests/resources/typing/assignees/yields/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/assignees/yields/main.sdstest @@ -3,19 +3,19 @@ package tests.typing.assignees.yields fun f() -> (r1: Int, r2: Float, r3: String) segment mySegment1() -> (r: Int) { - # $TEST$ equivalence_class assignedValue - # $TEST$ equivalence_class assignedValue + // $TEST$ equivalence_class assignedValue + // $TEST$ equivalence_class assignedValue »yield r«, _ = »1«; // the wildcards prevents the marker from matching the entire assignee list } segment mySegment2() -> (r: Int, s: String) { - # $TEST$ serialization literal<1> - # $TEST$ serialization $unknown + // $TEST$ serialization literal<1> + // $TEST$ serialization $unknown »yield r«, »yield s« = 1; } segment mySegment3() -> (r: Int, s: String) { - # $TEST$ serialization Int - # $TEST$ serialization String + // $TEST$ serialization Int + // $TEST$ serialization String »yield r«, _, »yield s« = f(); } diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/annotations/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/annotations/main.sdstest index 8963f2a4..d3e2a94a 100644 --- a/packages/ttsl-lang/tests/resources/typing/declarations/annotations/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/declarations/annotations/main.sdstest @@ -1,10 +1,10 @@ package tests.typing.declarations.annotations -# $TEST$ serialization () -> () +// $TEST$ serialization () -> () annotation »myAnnotation1« -# $TEST$ serialization (p1: Int, p2: String) -> () +// $TEST$ serialization (p1: Int, p2: String) -> () annotation »myAnnotation3«(p1: Int, p2: String) -# $TEST$ serialization (p1: $unknown) -> () +// $TEST$ serialization (p1: $unknown) -> () annotation »myAnnotation5«(p1) diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/attributes/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/attributes/main.sdstest index d765b9a8..7b10c3bc 100644 --- a/packages/ttsl-lang/tests/resources/typing/declarations/attributes/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/declarations/attributes/main.sdstest @@ -1,17 +1,17 @@ package tests.typing.declarations.attributes class C { - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown attr »a« - # $TEST$ equivalence_class instanceAttribute - # $TEST$ equivalence_class instanceAttribute + // $TEST$ equivalence_class instanceAttribute + // $TEST$ equivalence_class instanceAttribute attr »b«: »Int« - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown static attr »c« - # $TEST$ equivalence_class staticAttribute - # $TEST$ equivalence_class staticAttribute + // $TEST$ equivalence_class staticAttribute + // $TEST$ equivalence_class staticAttribute static attr »d«: »Int« } diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/classes/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/classes/main.sdstest index 30332402..17c8bbeb 100644 --- a/packages/ttsl-lang/tests/resources/typing/declarations/classes/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/declarations/classes/main.sdstest @@ -1,7 +1,7 @@ package tests.typing.declarations.classes -# $TEST$ serialization MyClass1 +// $TEST$ serialization MyClass1 class »MyClass1« -# $TEST$ serialization MyClass2 +// $TEST$ serialization MyClass2 class »MyClass2« diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/enum variants/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/enum variants/main.sdstest index 28018ebc..1cdf36ae 100644 --- a/packages/ttsl-lang/tests/resources/typing/declarations/enum variants/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/declarations/enum variants/main.sdstest @@ -1,9 +1,9 @@ package tests.typing.declarations.enumVariants enum MyEnum { - # $TEST$ serialization MyEnum.MyEnumVariant1 + // $TEST$ serialization MyEnum.MyEnumVariant1 »MyEnumVariant1« - # $TEST$ serialization MyEnum.MyEnumVariant2 + // $TEST$ serialization MyEnum.MyEnumVariant2 »MyEnumVariant2« } diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/enums/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/enums/main.sdstest index 57879457..e1297fb1 100644 --- a/packages/ttsl-lang/tests/resources/typing/declarations/enums/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/declarations/enums/main.sdstest @@ -1,7 +1,7 @@ package tests.typing.declarations.enums -# $TEST$ serialization MyEnum1 +// $TEST$ serialization MyEnum1 enum »MyEnum1« -# $TEST$ serialization MyEnum2 +// $TEST$ serialization MyEnum2 enum »MyEnum2« diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/functions/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/functions/main.sdstest index ae1a9951..d8e86e84 100644 --- a/packages/ttsl-lang/tests/resources/typing/declarations/functions/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/declarations/functions/main.sdstest @@ -1,16 +1,16 @@ package tests.typing.declarations.functions -# $TEST$ serialization () -> () +// $TEST$ serialization () -> () fun »myFunction1«() -# $TEST$ serialization () -> (r1: Int, r2: String) +// $TEST$ serialization () -> (r1: Int, r2: String) fun »myFunction2«() -> (r1: Int, r2: String) -# $TEST$ serialization (p1: Int, p2: String) -> () +// $TEST$ serialization (p1: Int, p2: String) -> () fun »myFunction3«(p1: Int, p2: String) -# $TEST$ serialization (p1: Int, p2: String) -> (r1: Int, r2: String) +// $TEST$ serialization (p1: Int, p2: String) -> (r1: Int, r2: String) fun »myFunction4«(p1: Int, p2: String) -> (r1: Int, r2: String) -# $TEST$ serialization (p1: $unknown) -> (r1: $unknown) +// $TEST$ serialization (p1: $unknown) -> (r1: $unknown) fun »myFunction5«(p1) -> (r1) diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of annotations/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of annotations/main.sdstest index 87209cf5..765e82e7 100644 --- a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of annotations/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of annotations/main.sdstest @@ -1,8 +1,8 @@ package tests.typing.declarations.parameters.ofAnnotations -# $TEST$ equivalence_class parameterType -# $TEST$ equivalence_class parameterType +// $TEST$ equivalence_class parameterType +// $TEST$ equivalence_class parameterType annotation MyAnnotation1(»p«: »Int«) -# $TEST$ serialization $unknown +// $TEST$ serialization $unknown annotation MyAnnotation2(»p«) diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/that are isolated/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/that are isolated/main.sdstest index 24200463..bc78c346 100644 --- a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/that are isolated/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/that are isolated/main.sdstest @@ -1,6 +1,6 @@ package tests.typing.declarations.parameters.ofBlockLambdas.thatAreIsolated segment mySegment() { - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown (»p«) {}; } diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/that are passed as arguments/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/that are passed as arguments/main.sdstest index 79e0b0ae..6acee7d5 100644 --- a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/that are passed as arguments/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/that are passed as arguments/main.sdstest @@ -1,26 +1,26 @@ package tests.typing.declarations.parameters.ofBlockLambdas.thatArePassedAsArguments -# $TEST$ equivalence_class parameterType1 +// $TEST$ equivalence_class parameterType1 fun higherOrderFunction1(param: (a: »String«) -> ()) fun higherOrderFunction2(param: () -> ()) fun normalFunction(param: Int) segment mySegment() { - # $TEST$ equivalence_class parameterType1 + // $TEST$ equivalence_class parameterType1 higherOrderFunction1((»p«) {}); - # $TEST$ equivalence_class parameterType1 + // $TEST$ equivalence_class parameterType1 higherOrderFunction1(param = (»p«) {}); - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown higherOrderFunction2((»p«) {}); - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown higherOrderFunction2(param = (»p«) {}); - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown normalFunction((»p«) {}); - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown normalFunction(param = (»p«) {}); } diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/that are passed as default values/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/that are passed as default values/main.sdstest index 31156f05..4cbdf821 100644 --- a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/that are passed as default values/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/that are passed as default values/main.sdstest @@ -1,17 +1,17 @@ package tests.typing.declarations.parameters.ofBlockLambdas.thatArePassedAsDefaultValues fun higherOrderFunction1( - # $TEST$ equivalence_class parameterType1 - # $TEST$ equivalence_class parameterType1 + // $TEST$ equivalence_class parameterType1 + // $TEST$ equivalence_class parameterType1 param: (p: »String«) -> () = (»p«) {} ) fun higherOrderFunction2( - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown param: () -> () = (»p«) {} ) fun normalFunction( - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown param: Int = (»p«) {} ) diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/that are yielded/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/that are yielded/main.sdstest index ef607296..bcb8aca8 100644 --- a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/that are yielded/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/that are yielded/main.sdstest @@ -1,17 +1,17 @@ package tests.typing.declarations.parameters.ofBlockLambdas.thatAreYielded segment mySegment() -> ( - # $TEST$ equivalence_class parameterType2 + // $TEST$ equivalence_class parameterType2 r: (p: »String«) -> (), s: () -> (), t: Int, ) { - # $TEST$ equivalence_class parameterType2 + // $TEST$ equivalence_class parameterType2 yield r = (»p«) {}; - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown yield s = (»p«) {}; - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown yield t = (»p«) {}; } diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/with manifest types/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/with manifest types/main.sdstest index 172f5221..4b0564d6 100644 --- a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/with manifest types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/with manifest types/main.sdstest @@ -1,7 +1,7 @@ package tests.typing.declarations.parameters.ofBlockLambdas.withManifestTypes segment mySegment() { - # $TEST$ equivalence_class parameterType3 - # $TEST$ equivalence_class parameterType3 + // $TEST$ equivalence_class parameterType3 + // $TEST$ equivalence_class parameterType3 (»p«: »Int«) {}; } diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of callable types/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of callable types/main.sdstest index 091ec607..17a6a703 100644 --- a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of callable types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of callable types/main.sdstest @@ -1,8 +1,8 @@ package tests.typing.declarations.parameters.ofCallableTypes -# $TEST$ equivalence_class parameterType -# $TEST$ equivalence_class parameterType +// $TEST$ equivalence_class parameterType +// $TEST$ equivalence_class parameterType annotation MyAnnotation1(f: (»p«: »Int«) -> ()) -# $TEST$ serialization $unknown +// $TEST$ serialization $unknown annotation MyAnnotation2(f: (»p«) -> ()) diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of classes/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of classes/main.sdstest index d0587b89..9185e184 100644 --- a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of classes/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of classes/main.sdstest @@ -1,8 +1,8 @@ package tests.typing.declarations.parameters.ofClasses -# $TEST$ equivalence_class parameterType -# $TEST$ equivalence_class parameterType +// $TEST$ equivalence_class parameterType +// $TEST$ equivalence_class parameterType class MyClass1(»p«: »Int«) -# $TEST$ serialization $unknown +// $TEST$ serialization $unknown class MyClass2(»p«) diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of enum variants/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of enum variants/main.sdstest index 4db3c11c..8267ac61 100644 --- a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of enum variants/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of enum variants/main.sdstest @@ -1,10 +1,10 @@ package tests.typing.declarations.parameters.ofEnumVariants enum MyEnum { - # $TEST$ equivalence_class parameterType - # $TEST$ equivalence_class parameterType + // $TEST$ equivalence_class parameterType + // $TEST$ equivalence_class parameterType MyEnumVariant1(»p«: »Int«) - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown MyEnumVariant2(»p«) } diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/that are isolated/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/that are isolated/main.sdstest index bd6ee113..51f0a097 100644 --- a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/that are isolated/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/that are isolated/main.sdstest @@ -1,6 +1,6 @@ package tests.typing.declarations.parameters.ofExpressionLambdas.thatAreIsolated segment mySegment() { - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown (»p«) -> 1; } diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/that are passed as arguments/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/that are passed as arguments/main.sdstest index b0ac2203..5244fdaf 100644 --- a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/that are passed as arguments/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/that are passed as arguments/main.sdstest @@ -1,26 +1,26 @@ package tests.typing.declarations.parameters.ofExpressionLambdas.thatArePassedAsArguments -# $TEST$ equivalence_class parameterType1 +// $TEST$ equivalence_class parameterType1 fun higherOrderFunction1(param: (a: »String«) -> r: String) fun higherOrderFunction2(param: () -> r: String) fun normalFunction(param: Int) segment mySegment() { - # $TEST$ equivalence_class parameterType1 + // $TEST$ equivalence_class parameterType1 higherOrderFunction1((»p«) -> ""); - # $TEST$ equivalence_class parameterType1 + // $TEST$ equivalence_class parameterType1 higherOrderFunction1(param = (»p«) -> ""); - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown higherOrderFunction2((»p«) -> ""); - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown higherOrderFunction2(param = (»p«) -> ""); - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown normalFunction((»p«) -> ""); - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown normalFunction(param = (»p«) -> ""); } diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/that are passed as default values/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/that are passed as default values/main.sdstest index 0064d395..0476e790 100644 --- a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/that are passed as default values/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/that are passed as default values/main.sdstest @@ -1,17 +1,17 @@ package tests.typing.declarations.parameters.ofExpressionLambdas.thatArePassedAsArguments fun higherOrderFunction1( - # $TEST$ equivalence_class parameterType1 - # $TEST$ equivalence_class parameterType1 + // $TEST$ equivalence_class parameterType1 + // $TEST$ equivalence_class parameterType1 param: (p: »String«) -> r: String = (»p«) -> "" ) fun higherOrderFunction2( - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown param: () -> r: String = (»p«) -> "" ) fun normalFunction( - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown param: Int = (»p«) -> "" ) diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/that are yielded/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/that are yielded/main.sdstest index 2a3c9588..c5da2c33 100644 --- a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/that are yielded/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/that are yielded/main.sdstest @@ -1,17 +1,17 @@ package tests.typing.declarations.parameters.ofExpressionLambdas.thatAreYielded segment mySegment() -> ( - # $TEST$ equivalence_class parameterType2 + // $TEST$ equivalence_class parameterType2 r: (p: »String«) -> r: String, s: () -> r: String, t: Int, ) { - # $TEST$ equivalence_class parameterType2 + // $TEST$ equivalence_class parameterType2 yield r = (»p«) -> true; - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown yield s = (»p«) -> true; - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown yield t = (»p«) -> true; } diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/with manifest types/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/with manifest types/main.sdstest index 7b88ab7c..21689517 100644 --- a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/with manifest types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/with manifest types/main.sdstest @@ -1,7 +1,7 @@ package tests.typing.declarations.parameters.ofExpressionLambdas.withManifestTypes segment mySegment() { - # $TEST$ equivalence_class parameterType3 - # $TEST$ equivalence_class parameterType3 + // $TEST$ equivalence_class parameterType3 + // $TEST$ equivalence_class parameterType3 (»p«: »Int«) -> 1; } diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of functions/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of functions/main.sdstest index 9d3eac6d..854f7a2a 100644 --- a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of functions/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of functions/main.sdstest @@ -1,8 +1,8 @@ package tests.typing.declarations.parameters.ofFunctions -# $TEST$ equivalence_class parameterType -# $TEST$ equivalence_class parameterType +// $TEST$ equivalence_class parameterType +// $TEST$ equivalence_class parameterType fun myFunction1(»p«: »Int«) -# $TEST$ serialization $unknown +// $TEST$ serialization $unknown fun myFunction2(»p«) diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of segments/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of segments/main.sdstest index b4aa6612..5937cb36 100644 --- a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of segments/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of segments/main.sdstest @@ -1,8 +1,8 @@ package tests.typing.declarations.parameters.ofSegments -# $TEST$ equivalence_class parameterType -# $TEST$ equivalence_class parameterType +// $TEST$ equivalence_class parameterType +// $TEST$ equivalence_class parameterType segment mySegment1(»p«: »Int«) {} -# $TEST$ serialization $unknown +// $TEST$ serialization $unknown segment mySegment2(»p«) {} diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/pipelines/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/pipelines/main.sdstest index 635d52fd..51dd507d 100644 --- a/packages/ttsl-lang/tests/resources/typing/declarations/pipelines/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/declarations/pipelines/main.sdstest @@ -1,4 +1,4 @@ package tests.typing.declarations.pipelines -# $TEST$ serialization $unknown +// $TEST$ serialization $unknown pipeline »myPipeline« {} diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/results/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/results/main.sdstest index 5b25d60c..fe03bfa5 100644 --- a/packages/ttsl-lang/tests/resources/typing/declarations/results/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/declarations/results/main.sdstest @@ -1,14 +1,14 @@ package tests.typing.declarations.results -# $TEST$ equivalence_class functionResult -# $TEST$ equivalence_class functionResult +// $TEST$ equivalence_class functionResult +// $TEST$ equivalence_class functionResult fun myFun() -> (»r«: »String«) segment mySegment( - # $TEST$ equivalence_class callableTypeResult - # $TEST$ equivalence_class callableTypeResult + // $TEST$ equivalence_class callableTypeResult + // $TEST$ equivalence_class callableTypeResult p: () -> (»r«: »String«) -# $TEST$ equivalence_class segmentResult -# $TEST$ equivalence_class segmentResult +// $TEST$ equivalence_class segmentResult +// $TEST$ equivalence_class segmentResult ) -> (»r«: »String«) {} diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/segments/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/segments/main.sdstest index a07d5928..953e8a87 100644 --- a/packages/ttsl-lang/tests/resources/typing/declarations/segments/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/declarations/segments/main.sdstest @@ -1,16 +1,16 @@ package tests.typing.declarations.segments -# $TEST$ serialization () -> () +// $TEST$ serialization () -> () segment »mySegment1«() {} -# $TEST$ serialization () -> (r1: Int, r2: String) +// $TEST$ serialization () -> (r1: Int, r2: String) segment »mySegment2«() -> (r1: Int, r2: String) {} -# $TEST$ serialization (p1: Int, p2: String) -> () +// $TEST$ serialization (p1: Int, p2: String) -> () segment »mySegment3«(p1: Int, p2: String) {} -# $TEST$ serialization (p1: Int, p2: String) -> (r1: Int, r2: String) +// $TEST$ serialization (p1: Int, p2: String) -> (r1: Int, r2: String) segment »mySegment4«(p1: Int, p2: String) -> (r1: Int, r2: String) {} -# $TEST$ serialization (p1: $unknown) -> (r1: $unknown) +// $TEST$ serialization (p1: $unknown) -> (r1: $unknown) segment »mySegment5«(p1) -> (r1) {} diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/type parameters/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/type parameters/main.sdstest index 9b62b388..52586950 100644 --- a/packages/ttsl-lang/tests/resources/typing/declarations/type parameters/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/declarations/type parameters/main.sdstest @@ -1,5 +1,5 @@ package tests.typing.declarations.typeParameters -# $TEST$ serialization K -# $TEST$ serialization V +// $TEST$ serialization K +// $TEST$ serialization V class MyClass<»K«, »V«> diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/arguments/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/arguments/main.sdstest index 89899653..8efa9e45 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/arguments/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/arguments/main.sdstest @@ -3,37 +3,37 @@ package tests.typing.expressions.arguments fun f(p: Any?) pipeline myPipeline { - # $TEST$ equivalence_class boolean - # $TEST$ equivalence_class boolean - # $TEST$ equivalence_class boolean + // $TEST$ equivalence_class boolean + // $TEST$ equivalence_class boolean + // $TEST$ equivalence_class boolean »true«; f(»true«); f(»p = true«); - # $TEST$ equivalence_class float - # $TEST$ equivalence_class float - # $TEST$ equivalence_class float + // $TEST$ equivalence_class float + // $TEST$ equivalence_class float + // $TEST$ equivalence_class float »1.0«; f(»1.0«); f(»p = 1.0«); - # $TEST$ equivalence_class int - # $TEST$ equivalence_class int - # $TEST$ equivalence_class int + // $TEST$ equivalence_class int + // $TEST$ equivalence_class int + // $TEST$ equivalence_class int »1«; f(»1«); f(»p = 1«); - # $TEST$ equivalence_class null - # $TEST$ equivalence_class null - # $TEST$ equivalence_class null + // $TEST$ equivalence_class null + // $TEST$ equivalence_class null + // $TEST$ equivalence_class null »null«; f(»null«); f(»p = null«); - # $TEST$ equivalence_class string - # $TEST$ equivalence_class string - # $TEST$ equivalence_class string + // $TEST$ equivalence_class string + // $TEST$ equivalence_class string + // $TEST$ equivalence_class string »""«; f(»""«); f(»p = ""«); diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/that are isolated/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/that are isolated/main.sdstest index 47f67353..157a8127 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/that are isolated/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/that are isolated/main.sdstest @@ -3,12 +3,12 @@ package tests.typing.expressions.blockLambdas.thatAreIsolated fun g() -> r: Int segment mySegment() { - # $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: $unknown) + // $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: $unknown) »(p) { yield r, yield s = 1; }«; - # $TEST$ serialization (p: $unknown) -> (r: Int, s: $unknown) + // $TEST$ serialization (p: $unknown) -> (r: Int, s: $unknown) val f = »(p) { yield r, yield s = g(); }«; diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/that are passed as arguments/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/that are passed as arguments/main.sdstest index 0382bc4e..4303239a 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/that are passed as arguments/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/that are passed as arguments/main.sdstest @@ -6,40 +6,40 @@ fun normalFunction(param: Int) fun parameterlessFunction() segment mySegment() { - # $TEST$ serialization (p: String) -> (r: literal<1>, s: literal<"">) + // $TEST$ serialization (p: String) -> (r: literal<1>, s: literal<"">) higherOrderFunction1(»(p) { yield r = 1; yield s = ""; }«); - # $TEST$ serialization (p: String) -> (r: literal<1>, s: $unknown) + // $TEST$ serialization (p: String) -> (r: literal<1>, s: $unknown) higherOrderFunction1(param = »(p) { yield r, yield s = 1; }«); - # $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: literal<"">) + // $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: literal<"">) higherOrderFunction2(»(p) { yield r = 1; yield s = ""; }«); - # $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: $unknown) + // $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: $unknown) higherOrderFunction2(param = »(p) { yield r, yield s = 1; }«); - # $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: literal<"">) + // $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: literal<"">) normalFunction(»(p) { yield r = 1; yield s = ""; }«); - # $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: $unknown) + // $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: $unknown) normalFunction(param = »(p) { yield r, yield s = 1; }«); - # $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: $unknown) + // $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: $unknown) parameterlessFunction(»(p) { yield r, yield s = 1; }«); diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/that are passed as default values/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/that are passed as default values/main.sdstest index 19893075..d77d639a 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/that are passed as default values/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/that are passed as default values/main.sdstest @@ -1,36 +1,36 @@ package tests.typing.expressions.blockLambdas.thatArePassedAsDefaultValues fun higherOrderFunction1( - # $TEST$ serialization (p: String) -> (r: literal<1>, s: literal<"">) + // $TEST$ serialization (p: String) -> (r: literal<1>, s: literal<"">) param1: (p: String) -> (r: Int, s: String) = »(p) { yield r = 1; yield s = ""; }«, - # $TEST$ serialization (p: String) -> (r: literal<1>, s: $unknown) + // $TEST$ serialization (p: String) -> (r: literal<1>, s: $unknown) param2: (p: String) -> (r: Int, s: String) = »(p) { yield r, yield s = 1; }«, ) fun higherOrderFunction2( - # $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: literal<"">) + // $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: literal<"">) param1: () -> () = »(p) { yield r = 1; yield s = ""; }«, - # $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: $unknown) + // $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: $unknown) param2: () -> () = »(p) { yield r, yield s = 1; }«, ) fun normalFunction( - # $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: literal<"">) + // $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: literal<"">) param1: Int = »(p) { yield r = 1; yield s = ""; }«, - # $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: $unknown) + // $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: $unknown) param2: Int = »(p) { yield r, yield s = 1; }«, diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/that are yielded/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/that are yielded/main.sdstest index 2aee7d41..7eaf2d53 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/that are yielded/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/that are yielded/main.sdstest @@ -5,19 +5,19 @@ segment mySegment() -> ( s: () -> (), t: Int, ) { - # $TEST$ serialization (p: String) -> (r: literal<1>, s: literal<"">) + // $TEST$ serialization (p: String) -> (r: literal<1>, s: literal<"">) yield r = »(p) { yield r = 1; yield s = ""; }«; - # $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: literal<"">) + // $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: literal<"">) yield s = »(p) { yield r = 1; yield s = ""; }«; - # $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: $unknown) + // $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: $unknown) yield t = »(p) { yield r, yield s = 1; }«; diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/with manifest types/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/with manifest types/main.sdstest index fff6cd35..aa34f81a 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/with manifest types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/with manifest types/main.sdstest @@ -1,13 +1,13 @@ package tests.typing.expressions.blockLambdas.withManifestTypes segment mySegment() { - # $TEST$ serialization (p: Int) -> (r: literal<1>, s: literal<"">) + // $TEST$ serialization (p: Int) -> (r: literal<1>, s: literal<"">) »(p: Int) { yield r = 1; yield s = ""; }«; - # $TEST$ serialization (p: String) -> (r: literal<1>, s: $unknown) + // $TEST$ serialization (p: String) -> (r: literal<1>, s: $unknown) »(p: String) { yield r, yield s = 1; }«; diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of annotations/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/of annotations/main.sdstest index 59f5d871..350c95c8 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of annotations/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/calls/of annotations/main.sdstest @@ -3,9 +3,9 @@ package tests.typing.expressions.calls.ofAnnotations annotation MyAnnotation pipeline myPipeline { - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown »MyAnnotation()«; - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown »MyAnnotation?()«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of block lambdas/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/of block lambdas/main.sdstest index a41b2e0c..264025a9 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of block lambdas/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/calls/of block lambdas/main.sdstest @@ -1,23 +1,23 @@ package tests.typing.expressions.calls.ofBlockLambdas pipeline myPipeline { - # $TEST$ serialization literal<""> + // $TEST$ serialization literal<""> »(() { yield r = ""; })()«; - # $TEST$ serialization (r: literal<"">, s: literal<1>) + // $TEST$ serialization (r: literal<"">, s: literal<1>) »(() { yield r = ""; yield s = 1; })()«; - # $TEST$ serialization literal<""> + // $TEST$ serialization literal<""> »(() { yield r = ""; })?()«; - # $TEST$ serialization (r: literal<"">, s: literal<1>) + // $TEST$ serialization (r: literal<"">, s: literal<1>) »(() { yield r = ""; yield s = 1; diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of callable types/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/of callable types/main.sdstest index 9996e9d7..9e8a2521 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of callable types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/calls/of callable types/main.sdstest @@ -4,15 +4,15 @@ segment mySegment( p1: () -> r: String, p2: () -> (r: String, s: Int) ) { - # $TEST$ serialization String + // $TEST$ serialization String »p1()«; - # $TEST$ serialization (r: String, s: Int) + // $TEST$ serialization (r: String, s: Int) »p2()«; - # $TEST$ serialization String + // $TEST$ serialization String »p1?()«; - # $TEST$ serialization (r: String, s: Int) + // $TEST$ serialization (r: String, s: Int) »p2?()«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of classes/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/of classes/main.sdstest index b44955a2..0e9e5bf9 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of classes/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/calls/of classes/main.sdstest @@ -3,15 +3,15 @@ package tests.typing.expressions.calls.ofClasses class C() pipeline myPipeline { - # $TEST$ serialization C + // $TEST$ serialization C »C()«; - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown »C()()«; - # $TEST$ serialization C + // $TEST$ serialization C »C?()«; - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown »C?()?()«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of enum variants/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/of enum variants/main.sdstest index e5f90a70..04387c9b 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of enum variants/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/calls/of enum variants/main.sdstest @@ -7,76 +7,76 @@ enum MyEnum { } pipeline myPipeline { - # $TEST$ serialization MyEnum.MyEnumVariantWithoutParameterList + // $TEST$ serialization MyEnum.MyEnumVariantWithoutParameterList »MyEnum.MyEnumVariantWithoutParameterList()«; - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown val alias1 = MyEnum.MyEnumVariantWithoutParameterList; »alias1()«; - # $TEST$ serialization MyEnum.MyEnumVariantWithoutParameters + // $TEST$ serialization MyEnum.MyEnumVariantWithoutParameters »MyEnum.MyEnumVariantWithoutParameters()«; - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown val alias2 = MyEnum.MyEnumVariantWithoutParameters; »alias2()«; - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown »MyEnum.MyEnumVariantWithoutParameters()()«; - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown val alias3 = MyEnum.MyEnumVariantWithoutParameters(); »alias3()«; - # $TEST$ serialization MyEnum.MyEnumVariantWithParameters + // $TEST$ serialization MyEnum.MyEnumVariantWithParameters »MyEnum.MyEnumVariantWithParameters(1)«; - # $TEST$ serialization MyEnum.MyEnumVariantWithParameters + // $TEST$ serialization MyEnum.MyEnumVariantWithParameters val alias4 = MyEnum.MyEnumVariantWithParameters; »alias4(1)«; - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown »MyEnum.MyEnumVariantWithParameters(1)()«; - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown val alias5 = MyEnum.MyEnumVariantWithParameters(1); »alias5()«; // Null-safe calls ------------------------------------------------------------------------------------------------- - # $TEST$ serialization MyEnum.MyEnumVariantWithoutParameterList + // $TEST$ serialization MyEnum.MyEnumVariantWithoutParameterList »MyEnum.MyEnumVariantWithoutParameterList?()«; - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown val alias1 = MyEnum.MyEnumVariantWithoutParameterList; »alias1?()«; - # $TEST$ serialization MyEnum.MyEnumVariantWithoutParameters + // $TEST$ serialization MyEnum.MyEnumVariantWithoutParameters »MyEnum.MyEnumVariantWithoutParameters?()«; - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown val alias2 = MyEnum.MyEnumVariantWithoutParameters; »alias2?()«; - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown »MyEnum.MyEnumVariantWithoutParameters?()?()«; - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown val alias3 = MyEnum.MyEnumVariantWithoutParameters?(); »alias3?()«; - # $TEST$ serialization MyEnum.MyEnumVariantWithParameters + // $TEST$ serialization MyEnum.MyEnumVariantWithParameters »MyEnum.MyEnumVariantWithParameters(1)«; - # $TEST$ serialization MyEnum.MyEnumVariantWithParameters + // $TEST$ serialization MyEnum.MyEnumVariantWithParameters val alias4 = MyEnum.MyEnumVariantWithParameters; »alias4?(1)«; - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown »MyEnum.MyEnumVariantWithParameters(1)?()«; - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown val alias5 = MyEnum.MyEnumVariantWithParameters(1); »alias5?()«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of expression lambdas/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/of expression lambdas/main.sdstest index 4ef52a6c..5c255a9f 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of expression lambdas/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/calls/of expression lambdas/main.sdstest @@ -1,9 +1,9 @@ package tests.typing.expressions.calls.ofExpressionLambdas pipeline myPipeline { - # $TEST$ serialization literal<1> + // $TEST$ serialization literal<1> »(() -> 1)()«; - # $TEST$ serialization literal<1> + // $TEST$ serialization literal<1> »(() -> 1)?()«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of functions/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/of functions/main.sdstest index cadcd1b5..2df9dfa6 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of functions/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/calls/of functions/main.sdstest @@ -4,15 +4,15 @@ fun f1() -> r: String fun f2() -> (r: String, s: Int) pipeline myPipeline { - # $TEST$ serialization String + // $TEST$ serialization String »f1()«; - # $TEST$ serialization (r: String, s: Int) + // $TEST$ serialization (r: String, s: Int) »f2()«; - # $TEST$ serialization String + // $TEST$ serialization String »f1?()«; - # $TEST$ serialization (r: String, s: Int) + // $TEST$ serialization (r: String, s: Int) »f2?()«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of non-callable/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/of non-callable/main.sdstest index 077a6cd0..3948cb8f 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of non-callable/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/calls/of non-callable/main.sdstest @@ -3,9 +3,9 @@ package tests.typing.expressions.calls.ofNonCallables enum MyEnum pipeline myPipeline { - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown »MyEnum()«; - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown »MyEnum?()«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of nullable receiver/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/of nullable receiver/main.sdstest index b433f33d..358ca43a 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of nullable receiver/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/calls/of nullable receiver/main.sdstest @@ -8,13 +8,13 @@ class MyClass { segment mySegment( myClassOrNull: MyClass? ) { - # $TEST$ serialization Int + // $TEST$ serialization Int »myClassOrNull?.a()«; - # $TEST$ serialization Int + // $TEST$ serialization Int »myClassOrNull?.f()«; - # $TEST$ serialization Int? + // $TEST$ serialization Int? »myClassOrNull?.f?()«; - # $TEST$ serialization Int? + // $TEST$ serialization Int? »myClassOrNull?.f?()«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of segments/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/of segments/main.sdstest index 7c293e09..713685eb 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of segments/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/calls/of segments/main.sdstest @@ -7,15 +7,15 @@ segment s2() -> (r: String, s: Int) { } pipeline myPipeline { - # $TEST$ serialization String + // $TEST$ serialization String »s1()«; - # $TEST$ serialization (r: String, s: Int) + // $TEST$ serialization (r: String, s: Int) »s2()«; - # $TEST$ serialization String + // $TEST$ serialization String »s1?()«; - # $TEST$ serialization (r: String, s: Int) + // $TEST$ serialization (r: String, s: Int) »s2?()«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/clamp to upper bound/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/clamp to upper bound/main.sdstest index 8b02e652..8d16db57 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/clamp to upper bound/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/clamp to upper bound/main.sdstest @@ -5,15 +5,15 @@ class C1(p1: T) @Pure fun f1(p1: T) -> r1: T pipeline myPipeline { - # $TEST$ serialization C1 + // $TEST$ serialization C1 »C1("")«; - # $TEST$ serialization C1 + // $TEST$ serialization C1 »C1()«; - # $TEST$ serialization Int + // $TEST$ serialization Int »f1("")«; - # $TEST$ serialization Int + // $TEST$ serialization Int »f1()«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/deep nesting/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/deep nesting/main.sdstest index 5a1291b3..78c0bbae 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/deep nesting/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/deep nesting/main.sdstest @@ -16,25 +16,25 @@ segment mySegment( a4: Contravariant, a5: Contravariant>, ) { - # $TEST$ serialization C1 + // $TEST$ serialization C1 »C1(a2, a1)«; - # $TEST$ serialization C1 + // $TEST$ serialization C1 »C1(a2, a2)«; - # $TEST$ serialization C1 + // $TEST$ serialization C1 »C1(a2, a3)«; - # $TEST$ serialization C1 + // $TEST$ serialization C1 »C1(a2, a4)«; - # $TEST$ serialization C1 + // $TEST$ serialization C1 »C1(a2, a5)«; - # $TEST$ serialization Int + // $TEST$ serialization Int »f1(a2, a1)«; - # $TEST$ serialization Number + // $TEST$ serialization Number »f1(a2, a2)«; - # $TEST$ serialization Number + // $TEST$ serialization Number »f1(a2, a3)«; - # $TEST$ serialization Number + // $TEST$ serialization Number »f1(a2, a4)«; - # $TEST$ serialization Number + // $TEST$ serialization Number »f1(a2, a5)«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/default value of parameter/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/default value of parameter/main.sdstest index 98e5935e..55ffe280 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/default value of parameter/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/default value of parameter/main.sdstest @@ -5,9 +5,9 @@ class C1(p1: T = 0) @Pure fun f1(p1: T = 0) -> r1: T pipeline myPipeline { - # $TEST$ serialization C1> + // $TEST$ serialization C1> »C1()«; - # $TEST$ serialization literal<0> + // $TEST$ serialization literal<0> »f1()«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/default value of type parameter/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/default value of type parameter/main.sdstest index 6589d9ae..52921225 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/default value of type parameter/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/default value of type parameter/main.sdstest @@ -7,13 +7,13 @@ class C2() @Pure fun f2() -> r1: T pipeline myPipeline { - # $TEST$ serialization C1 + // $TEST$ serialization C1 »C1()«; - # $TEST$ serialization C2 + // $TEST$ serialization C2 »C2()«; - # $TEST$ serialization Nothing + // $TEST$ serialization Nothing »f1()«; - # $TEST$ serialization Int + // $TEST$ serialization Int »f2()«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/differing variance/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/differing variance/main.sdstest index 7f9b5e12..b97517ee 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/differing variance/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/differing variance/main.sdstest @@ -19,40 +19,40 @@ segment mySegment( b2: Invariant, b3: Covariant, ) { - # $TEST$ serialization C1 + // $TEST$ serialization C1 »C1(a1, a2)«; - # $TEST$ serialization C1 + // $TEST$ serialization C1 »C1(a1, b2)«; - # $TEST$ serialization C1 + // $TEST$ serialization C1 »C1(b1, a2)«; - # $TEST$ serialization C1 + // $TEST$ serialization C1 »C1(b1, b2)«; - # $TEST$ serialization C2 + // $TEST$ serialization C2 »C2(a1, a3)«; - # $TEST$ serialization C2 + // $TEST$ serialization C2 »C2(a1, b3)«; - # $TEST$ serialization C2 + // $TEST$ serialization C2 »C2(b1, a3)«; - # $TEST$ serialization C2 + // $TEST$ serialization C2 »C2(b1, b3)«; - # $TEST$ serialization Nothing + // $TEST$ serialization Nothing »f1(a1, a2)«; - # $TEST$ serialization Nothing + // $TEST$ serialization Nothing »f1(a1, b2)«; - # $TEST$ serialization Number + // $TEST$ serialization Number »f1(b1, a2)«; - # $TEST$ serialization Number + // $TEST$ serialization Number »f1(b1, b2)«; - # $TEST$ serialization Nothing + // $TEST$ serialization Nothing »f2(a1, a3)«; - # $TEST$ serialization Nothing + // $TEST$ serialization Nothing »f2(a1, b3)«; - # $TEST$ serialization Number + // $TEST$ serialization Number »f2(b1, a3)«; - # $TEST$ serialization Number + // $TEST$ serialization Number »f2(b1, b3)«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/multiple contravariant/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/multiple contravariant/main.sdstest index 156235a9..1a0e825f 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/multiple contravariant/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/multiple contravariant/main.sdstest @@ -16,29 +16,29 @@ segment mySegment( c: (p1: Number) -> () ) { - # $TEST$ serialization C1 + // $TEST$ serialization C1 »C1(a1, c)«; - # $TEST$ serialization C1 + // $TEST$ serialization C1 »C1(a2, c)«; - # $TEST$ serialization C1 + // $TEST$ serialization C1 »C1(a3, c)«; - # $TEST$ serialization C1 + // $TEST$ serialization C1 »C1(a4, c)«; - # $TEST$ serialization C1 + // $TEST$ serialization C1 »C1(a5, c)«; - # $TEST$ serialization C1 + // $TEST$ serialization C1 »C1(a1, (p1) {})«; - # $TEST$ serialization Int + // $TEST$ serialization Int »f1(a1, c)«; - # $TEST$ serialization Number + // $TEST$ serialization Number »f1(a2, c)«; - # $TEST$ serialization Number + // $TEST$ serialization Number »f1(a3, c)«; - # $TEST$ serialization Number + // $TEST$ serialization Number »f1(a4, c)«; - # $TEST$ serialization Nothing + // $TEST$ serialization Nothing »f1(a5, c)«; - # $TEST$ serialization Int + // $TEST$ serialization Int »f1(a1, (p1) {})«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/multiple covariant/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/multiple covariant/main.sdstest index 11653b31..c573e92d 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/multiple covariant/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/multiple covariant/main.sdstest @@ -20,33 +20,33 @@ segment mySegment( c: () -> r1: Number ) { - # $TEST$ serialization C1 + // $TEST$ serialization C1 »C1(a1, b1, c)«; - # $TEST$ serialization C1 + // $TEST$ serialization C1 »C1(a2, b1, c)«; - # $TEST$ serialization C1 + // $TEST$ serialization C1 »C1(a3, b1, c)«; - # $TEST$ serialization C1 + // $TEST$ serialization C1 »C1(a1, b2, c)«; - # $TEST$ serialization C1 + // $TEST$ serialization C1 »C1(a1, b3, c)«; - # $TEST$ serialization C1 + // $TEST$ serialization C1 »C1(a1, b1, () -> "")«; - # $TEST$ serialization C1 + // $TEST$ serialization C1 »C1(a1, b1, SomeClass)«; - # $TEST$ serialization Number + // $TEST$ serialization Number »f1(a1, b1, c)«; - # $TEST$ serialization Number + // $TEST$ serialization Number »f1(a2, b1, c)«; - # $TEST$ serialization Any? + // $TEST$ serialization Any? »f1(a3, b1, c)«; - # $TEST$ serialization Number + // $TEST$ serialization Number »f1(a1, b2, c)«; - # $TEST$ serialization Any? + // $TEST$ serialization Any? »f1(a1, b3, c)«; - # $TEST$ serialization Any + // $TEST$ serialization Any »f1(a1, b1, () -> "")«; - # $TEST$ serialization Any + // $TEST$ serialization Any »f1(a1, b1, SomeClass)«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/single contravariant/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/single contravariant/main.sdstest index e727dc47..f6338b6e 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/single contravariant/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/single contravariant/main.sdstest @@ -8,9 +8,9 @@ class C1(p1: Contravariant) segment mySegment( p1: Contravariant, ) { - # $TEST$ serialization C1 + // $TEST$ serialization C1 »C1(p1)«; - # $TEST$ serialization Int + // $TEST$ serialization Int »f1(p1)«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/single covariant/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/single covariant/main.sdstest index 852ee30e..06b195bb 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/single covariant/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/single covariant/main.sdstest @@ -6,9 +6,9 @@ class C1(p1: T) segment mySegment( p1: Int, ) { - # $TEST$ serialization C1 + // $TEST$ serialization C1 »C1(p1)«; - # $TEST$ serialization Int + // $TEST$ serialization Int »f1(p1)«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/unresolved/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/unresolved/main.sdstest index 47edf418..4ad038be 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/unresolved/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/calls/unresolved/main.sdstest @@ -1,9 +1,9 @@ package tests.typing.expressions.calls.ofUnresolved pipeline myPipeline { - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown »unresolved()«; - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown »unresolved?()«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/that are isolated/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/that are isolated/main.sdstest index 7858e777..1cca1cc2 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/that are isolated/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/that are isolated/main.sdstest @@ -3,9 +3,9 @@ package tests.typing.expressions.expressionLambdas.thatAreIsolated fun g() -> r: Int segment mySegment() { - # $TEST$ serialization (p: $unknown) -> (result: Int) + // $TEST$ serialization (p: $unknown) -> (result: Int) »(p) -> g()«; - # $TEST$ serialization (p: $unknown) -> (result: literal<1>) + // $TEST$ serialization (p: $unknown) -> (result: literal<1>) val f = »(p) -> 1«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/that are passed as arguments/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/that are passed as arguments/main.sdstest index 42032365..4277aabf 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/that are passed as arguments/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/that are passed as arguments/main.sdstest @@ -6,24 +6,24 @@ fun normalFunction(param: Int) fun parameterlessFunction() segment mySegment() { - # $TEST$ serialization (p: String) -> (result: literal<1>) + // $TEST$ serialization (p: String) -> (result: literal<1>) higherOrderFunction1(»(p) -> 1«); - # $TEST$ serialization (p: String) -> (result: literal<1>) + // $TEST$ serialization (p: String) -> (result: literal<1>) higherOrderFunction1(param = »(p) -> 1«); - # $TEST$ serialization (p: $unknown) -> (result: literal<1>) + // $TEST$ serialization (p: $unknown) -> (result: literal<1>) higherOrderFunction2(»(p) -> 1«); - # $TEST$ serialization (p: $unknown) -> (result: literal<1>) + // $TEST$ serialization (p: $unknown) -> (result: literal<1>) higherOrderFunction2(param = »(p) -> 1«); - # $TEST$ serialization (p: $unknown) -> (result: literal<1>) + // $TEST$ serialization (p: $unknown) -> (result: literal<1>) normalFunction(»(p) -> 1«); - # $TEST$ serialization (p: $unknown) -> (result: literal<1>) + // $TEST$ serialization (p: $unknown) -> (result: literal<1>) normalFunction(param = »(p) -> 1«); - # $TEST$ serialization (p: $unknown) -> (result: literal<1>) + // $TEST$ serialization (p: $unknown) -> (result: literal<1>) parameterlessFunction(»(p) -> 1«); } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/that are passed as default values/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/that are passed as default values/main.sdstest index c86065a4..201a0594 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/that are passed as default values/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/that are passed as default values/main.sdstest @@ -1,16 +1,16 @@ package tests.typing.expressions.expressionLambdas.thatArePassedAsDefaultValues fun higherOrderFunction1( - # $TEST$ serialization (p: String) -> (result: literal<1>) + // $TEST$ serialization (p: String) -> (result: literal<1>) param: (p: String) -> (r: Int) = »(p) -> 1« ) fun higherOrderFunction2( - # $TEST$ serialization (p: $unknown) -> (result: literal<1>) + // $TEST$ serialization (p: $unknown) -> (result: literal<1>) param: () -> () = »(p) -> 1« ) fun normalFunction( - # $TEST$ serialization (p: $unknown) -> (result: literal<1>) + // $TEST$ serialization (p: $unknown) -> (result: literal<1>) param: Int = »(p) -> 1« ) diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/that are yielded/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/that are yielded/main.sdstest index 1d40039f..c8f26c2a 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/that are yielded/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/that are yielded/main.sdstest @@ -5,12 +5,12 @@ segment mySegment() -> ( s: () -> (), t: Int, ) { - # $TEST$ serialization (p: String) -> (result: literal<1>) + // $TEST$ serialization (p: String) -> (result: literal<1>) yield r = »(p) -> 1«; - # $TEST$ serialization (p: $unknown) -> (result: literal<1>) + // $TEST$ serialization (p: $unknown) -> (result: literal<1>) yield s = »(p) -> 1«; - # $TEST$ serialization (p: $unknown) -> (result: literal<1>) + // $TEST$ serialization (p: $unknown) -> (result: literal<1>) yield t = »(p) -> 1«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/with manifest types/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/with manifest types/main.sdstest index 4e8331d5..5ad3d084 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/with manifest types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/with manifest types/main.sdstest @@ -1,6 +1,6 @@ package tests.typing.expressions.expressionLambdas.withManifestTypes segment mySegment() { - # $TEST$ serialization (p: Int) -> (result: literal<1>) + // $TEST$ serialization (p: Int) -> (result: literal<1>) »(p: Int) -> 1«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on lists/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on lists/main.sdstest index 5e775222..99e63e19 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on lists/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on lists/main.sdstest @@ -3,41 +3,41 @@ package tests.typing.expressions.indexedAccesses.onLists class IntList sub List segment mySegment(param1: List, param2: List?, param3: IntList) { - # $TEST$ serialization Int + // $TEST$ serialization Int »param1[0]«; - # $TEST$ serialization Int + // $TEST$ serialization Int »param1[unresolved]«; - # $TEST$ serialization Int + // $TEST$ serialization Int »param2[0]«; - # $TEST$ serialization Int + // $TEST$ serialization Int »param2[unresolved]«; - # $TEST$ serialization Int + // $TEST$ serialization Int »param3[0]«; - # $TEST$ serialization Int + // $TEST$ serialization Int »param3[unresolved]«; - # $TEST$ serialization Int + // $TEST$ serialization Int »param1?[0]«; - # $TEST$ serialization Int + // $TEST$ serialization Int »param1?[unresolved]«; - # $TEST$ serialization Int? + // $TEST$ serialization Int? »param2?[0]«; - # $TEST$ serialization Int? + // $TEST$ serialization Int? »param2?[unresolved]«; - # $TEST$ serialization Int + // $TEST$ serialization Int »param3?[0]«; - # $TEST$ serialization Int + // $TEST$ serialization Int »param3?[unresolved]«; } @@ -46,40 +46,40 @@ class MyClass, MyNullableList sub List?>( param2: MyList?, param3: MyNullableList, - # $TEST$ serialization Int + // $TEST$ serialization Int p1: Any? = »param1[0]«, - # $TEST$ serialization Int + // $TEST$ serialization Int p2: Any? = »param1[unresolved]«, - # $TEST$ serialization Int + // $TEST$ serialization Int p3: Any? = »param2[0]«, - # $TEST$ serialization Int + // $TEST$ serialization Int p4: Any? = »param2[unresolved]«, - # $TEST$ serialization Int + // $TEST$ serialization Int p5: Any? = »param3[0]«, - # $TEST$ serialization Int + // $TEST$ serialization Int p6: Any? = »param3[unresolved]«, - # $TEST$ serialization Int + // $TEST$ serialization Int p7: Any? = »param1?[0]«, - # $TEST$ serialization Int + // $TEST$ serialization Int p8: Any? = »param1?[unresolved]«, - # $TEST$ serialization Int? + // $TEST$ serialization Int? p9: Any? = »param2?[0]«, - # $TEST$ serialization Int? + // $TEST$ serialization Int? p10: Any? = »param2?[unresolved]«, - # $TEST$ serialization Int? + // $TEST$ serialization Int? p11: Any? = »param3?[0]«, - # $TEST$ serialization Int? + // $TEST$ serialization Int? p12: Any? = »param3?[unresolved]«, ) diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on maps/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on maps/main.sdstest index b2641234..b55e8e77 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on maps/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on maps/main.sdstest @@ -3,41 +3,41 @@ package tests.typing.expressions.indexedAccesses.onMaps class MyMap sub Map segment mySegment(param1: Map, param2: Map?, param3: MyMap) { - # $TEST$ serialization Int + // $TEST$ serialization Int »param1[""]«; - # $TEST$ serialization Int + // $TEST$ serialization Int »param1[unresolved]«; - # $TEST$ serialization Int + // $TEST$ serialization Int »param2[""]«; - # $TEST$ serialization Int + // $TEST$ serialization Int »param2[unresolved]«; - # $TEST$ serialization Int + // $TEST$ serialization Int »param3[""]«; - # $TEST$ serialization Int + // $TEST$ serialization Int »param3[unresolved]«; - # $TEST$ serialization Int + // $TEST$ serialization Int »param1?[""]«; - # $TEST$ serialization Int + // $TEST$ serialization Int »param1?[unresolved]«; - # $TEST$ serialization Int? + // $TEST$ serialization Int? »param2?[""]«; - # $TEST$ serialization Int? + // $TEST$ serialization Int? »param2?[unresolved]«; - # $TEST$ serialization Int + // $TEST$ serialization Int »param3?[""]«; - # $TEST$ serialization Int + // $TEST$ serialization Int »param3?[unresolved]«; } @@ -46,40 +46,40 @@ class MyClass, MyNullableMap sub Map?>( param2: MyMap?, param3: MyNullableMap, - # $TEST$ serialization Int + // $TEST$ serialization Int p1: Any? = »param1[""]«, - # $TEST$ serialization Int + // $TEST$ serialization Int p2: Any? = »param1[unresolved]«, - # $TEST$ serialization Int + // $TEST$ serialization Int p3: Any? = »param2[""]«, - # $TEST$ serialization Int + // $TEST$ serialization Int p4: Any? = »param2[unresolved]«, - # $TEST$ serialization Int + // $TEST$ serialization Int p5: Any? = »param3[""]«, - # $TEST$ serialization Int + // $TEST$ serialization Int p6: Any? = »param3[unresolved]«, - # $TEST$ serialization Int + // $TEST$ serialization Int p7: Any? = »param1?[""]«, - # $TEST$ serialization Int + // $TEST$ serialization Int p8: Any? = »param1?[unresolved]«, - # $TEST$ serialization Int? + // $TEST$ serialization Int? p9: Any? = »param2?[""]«, - # $TEST$ serialization Int? + // $TEST$ serialization Int? p10: Any? = »param2?[unresolved]«, - # $TEST$ serialization Int? + // $TEST$ serialization Int? p11: Any? = »param3?[""]«, - # $TEST$ serialization Int? + // $TEST$ serialization Int? p12: Any? = »param3?[unresolved]«, ) diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on other/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on other/main.sdstest index c8e72cd1..12637d99 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on other/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on other/main.sdstest @@ -1,16 +1,16 @@ package tests.typing.expressions.indexedAccesses.onOther segment mySegment3(param1: String, param2: String?) { - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown »param1[0]«; - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown »param2[0]«; - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown »param1?[0]«; - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown »param2?[0]«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on unresolved/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on unresolved/main.sdstest index 079f641c..352d9f4b 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on unresolved/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on unresolved/main.sdstest @@ -1,9 +1,9 @@ package tests.typing.expressions.indexedAccesses.onUnresolved segment mySegment() { - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown »unresolved[0]«; - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown »unresolved?[0]«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/lists/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/lists/main.sdstest index dd3cc8f0..270f8de3 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/lists/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/lists/main.sdstest @@ -5,18 +5,18 @@ package tests.typing.expressions.lists pipeline myPipeline { - # $TEST$ serialization List + // $TEST$ serialization List »[]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[1, 2, 3]«; - # $TEST$ serialization List + // $TEST$ serialization List »[1, float(), 3]«; - # $TEST$ serialization List + // $TEST$ serialization List »[1, string(), 3]«; - # $TEST$ serialization List + // $TEST$ serialization List »[1, string(), null]«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/literals/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/literals/main.sdstest index ac8bf6e6..f17a08ae 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/literals/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/literals/main.sdstest @@ -2,18 +2,18 @@ package tests.typing.expressions.literals pipeline myPipeline { - # $TEST$ serialization literal + // $TEST$ serialization literal val booleanLiteral = »true«; - # $TEST$ serialization literal<1.5> + // $TEST$ serialization literal<1.5> val floatLiteral = »1.5«; - # $TEST$ serialization literal<1> + // $TEST$ serialization literal<1> val intLiteral = »1«; - # $TEST$ serialization Nothing? + // $TEST$ serialization Nothing? val nullLiteral = »null«; - # $TEST$ serialization literal<"myString"> + // $TEST$ serialization literal<"myString"> val stringLiteral = »"myString"«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/maps/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/maps/main.sdstest index 23572818..2d055e1f 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/maps/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/maps/main.sdstest @@ -5,21 +5,21 @@ package tests.typing.expressions.maps pipeline myPipeline { - # $TEST$ serialization Map + // $TEST$ serialization Map »{}«; - # $TEST$ serialization Map> + // $TEST$ serialization Map> »{1: 1, 2: 2, 3: 3}«; - # $TEST$ serialization Map + // $TEST$ serialization Map »{1: 1, float(): float(), 3: 3}«; - # $TEST$ serialization Map + // $TEST$ serialization Map »{1: 1, string(): string(), 3: 3}«; - # $TEST$ serialization Map + // $TEST$ serialization Map »{1: 1, string(): string(), null: null}«; - # $TEST$ serialization Map + // $TEST$ serialization Map »{float(): string(), 1: null}«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/on class with type parameters/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/on class with type parameters/main.sdstest index f1510c95..219a7319 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/on class with type parameters/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/on class with type parameters/main.sdstest @@ -13,64 +13,64 @@ class D sub C // Accessing own members segment mySegment1(p: C) { - # $TEST$ serialization Int + // $TEST$ serialization Int »p.nonNullableMember«; - # $TEST$ serialization Int? + // $TEST$ serialization Int? »p.nullableMember«; - # $TEST$ serialization () -> (r: Int) + // $TEST$ serialization () -> (r: Int) »p.method«; - # $TEST$ serialization Int + // $TEST$ serialization Int »p?.nonNullableMember«; - # $TEST$ serialization Int? + // $TEST$ serialization Int? »p?.nullableMember«; - # $TEST$ serialization () -> (r: Int) + // $TEST$ serialization () -> (r: Int) »p?.method«; - # $TEST$ serialization Int + // $TEST$ serialization Int »nullableC().nonNullableMember«; - # $TEST$ serialization Int? + // $TEST$ serialization Int? »nullableC().nullableMember«; - # $TEST$ serialization () -> (r: Int) + // $TEST$ serialization () -> (r: Int) »nullableC().method«; - # $TEST$ serialization Int? + // $TEST$ serialization Int? »nullableC()?.nonNullableMember«; - # $TEST$ serialization Int? + // $TEST$ serialization Int? »nullableC()?.nullableMember«; - # $TEST$ serialization union<() -> (r: Int), Nothing?> + // $TEST$ serialization union<() -> (r: Int), Nothing?> »nullableC()?.method«; } // Accessing inherited members segment mySegment2(p: D) { - # $TEST$ serialization Int + // $TEST$ serialization Int »p.nonNullableMember«; - # $TEST$ serialization Int? + // $TEST$ serialization Int? »p.nullableMember«; - # $TEST$ serialization () -> (r: Int) + // $TEST$ serialization () -> (r: Int) »p.method«; - # $TEST$ serialization Int + // $TEST$ serialization Int »p?.nonNullableMember«; - # $TEST$ serialization Int? + // $TEST$ serialization Int? »p?.nullableMember«; - # $TEST$ serialization () -> (r: Int) + // $TEST$ serialization () -> (r: Int) »p?.method«; - # $TEST$ serialization Int + // $TEST$ serialization Int »nullableD().nonNullableMember«; - # $TEST$ serialization Int? + // $TEST$ serialization Int? »nullableD().nullableMember«; - # $TEST$ serialization () -> (r: Int) + // $TEST$ serialization () -> (r: Int) »nullableD().method«; - # $TEST$ serialization Int? + // $TEST$ serialization Int? »nullableD()?.nonNullableMember«; - # $TEST$ serialization Int? + // $TEST$ serialization Int? »nullableD()?.nullableMember«; - # $TEST$ serialization union<() -> (r: Int), Nothing?> + // $TEST$ serialization union<() -> (r: Int), Nothing?> »nullableD()?.method«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/to enum variants/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/to enum variants/main.sdstest index 41d68be7..d970d712 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/to enum variants/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/to enum variants/main.sdstest @@ -7,22 +7,22 @@ enum MyEnum { } pipeline myPipeline { - # $TEST$ serialization MyEnum.MyEnumVariantWithoutParameterList + // $TEST$ serialization MyEnum.MyEnumVariantWithoutParameterList »MyEnum.MyEnumVariantWithoutParameterList«; - # $TEST$ serialization MyEnum.MyEnumVariantWithoutParameters + // $TEST$ serialization MyEnum.MyEnumVariantWithoutParameters »MyEnum.MyEnumVariantWithoutParameters«; - # $TEST$ serialization $type + // $TEST$ serialization $type »MyEnum.MyEnumVariantWithParameters«; - # $TEST$ serialization MyEnum.MyEnumVariantWithoutParameterList + // $TEST$ serialization MyEnum.MyEnumVariantWithoutParameterList »MyEnum?.MyEnumVariantWithoutParameterList«; - # $TEST$ serialization MyEnum.MyEnumVariantWithoutParameters + // $TEST$ serialization MyEnum.MyEnumVariantWithoutParameters »MyEnum?.MyEnumVariantWithoutParameters«; - # $TEST$ serialization $type + // $TEST$ serialization $type »MyEnum?.MyEnumVariantWithParameters«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/to nested classes/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/to nested classes/main.sdstest index dbd6501f..9c9ae1ed 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/to nested classes/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/to nested classes/main.sdstest @@ -5,9 +5,9 @@ class MyClass { } pipeline myPipeline { - # $TEST$ serialization $type + // $TEST$ serialization $type »MyClass.MyNestedClass«; - # $TEST$ serialization $type + // $TEST$ serialization $type »MyClass?.MyNestedClass«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/to nested enums/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/to nested enums/main.sdstest index 2e4b2a0b..66e3c74b 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/to nested enums/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/to nested enums/main.sdstest @@ -5,9 +5,9 @@ class MyClass { } pipeline myPipeline { - # $TEST$ serialization $type + // $TEST$ serialization $type »MyClass.MyNestedEnum«; - # $TEST$ serialization $type + // $TEST$ serialization $type »MyClass?.MyNestedEnum«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/to other/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/to other/main.sdstest index 9961d582..f77c4900 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/to other/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/to other/main.sdstest @@ -1,45 +1,45 @@ package tests.typing.expressions.memberAccesses.toOther class C() { - # $TEST$ equivalence_class nonNullableMember + // $TEST$ equivalence_class nonNullableMember attr »nonNullableMember«: Int - # $TEST$ equivalence_class nullableMember + // $TEST$ equivalence_class nullableMember attr »nullableMember«: Any? - # $TEST$ equivalence_class method + // $TEST$ equivalence_class method @Pure fun »method«() -> r: Int } fun nullableC() -> result: C? pipeline myPipeline { - # $TEST$ equivalence_class nonNullableMember + // $TEST$ equivalence_class nonNullableMember »C().nonNullableMember«; - # $TEST$ equivalence_class nullableMember + // $TEST$ equivalence_class nullableMember »C().nullableMember«; - # $TEST$ equivalence_class method + // $TEST$ equivalence_class method »C().method«; - # $TEST$ equivalence_class nonNullableMember + // $TEST$ equivalence_class nonNullableMember »C()?.nonNullableMember«; - # $TEST$ equivalence_class nullableMember + // $TEST$ equivalence_class nullableMember »C()?.nullableMember«; - # $TEST$ equivalence_class method + // $TEST$ equivalence_class method »C()?.method«; - # $TEST$ equivalence_class nonNullableMember + // $TEST$ equivalence_class nonNullableMember »nullableC().nonNullableMember«; - # $TEST$ equivalence_class nullableMember + // $TEST$ equivalence_class nullableMember »nullableC().nullableMember«; - # $TEST$ equivalence_class method + // $TEST$ equivalence_class method »nullableC().method«; - # $TEST$ serialization Int? + // $TEST$ serialization Int? »nullableC()?.nonNullableMember«; - # $TEST$ equivalence_class nullableMember + // $TEST$ equivalence_class nullableMember »nullableC()?.nullableMember«; - # $TEST$ serialization union<() -> (r: Int), Nothing?> + // $TEST$ serialization union<() -> (r: Int), Nothing?> »nullableC()?.method«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/unresolved/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/unresolved/main.sdstest index 601e131a..9cef6afd 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/unresolved/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/unresolved/main.sdstest @@ -3,9 +3,9 @@ package tests.typing.expressions.memberAccesses.unresolved class C pipeline myPipeline { - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown »C.unresolved«; - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown »C?.unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/operations/arithmetic/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/operations/arithmetic/main.sdstest index 984f4461..57046ac4 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/operations/arithmetic/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/operations/arithmetic/main.sdstest @@ -4,140 +4,140 @@ fun anyInt() -> r: Int fun anyFloat() -> r: Float pipeline constantOperands { - # $TEST$ serialization literal<2> + // $TEST$ serialization literal<2> val additionIntInt = »1 + 1«; - # $TEST$ serialization literal<0> + // $TEST$ serialization literal<0> val subtractionIntInt = »1 - 1«; - # $TEST$ serialization literal<1> + // $TEST$ serialization literal<1> val multiplicationIntInt = »1 * 1«; - # $TEST$ serialization literal<1> + // $TEST$ serialization literal<1> val divisionIntInt = »1 / 1«; - # $TEST$ serialization literal<2.5> + // $TEST$ serialization literal<2.5> val additionIntFloat = »1 + 1.5«; - # $TEST$ serialization literal<-0.5> + // $TEST$ serialization literal<-0.5> val subtractionIntFloat = »1 - 1.5«; - # $TEST$ serialization literal<1.5> + // $TEST$ serialization literal<1.5> val multiplicationIntFloat = »1 * 1.5«; - # $TEST$ serialization literal<1.6> + // $TEST$ serialization literal<1.6> val divisionIntFloat = »1 / 0.625«; - # $TEST$ serialization literal<2.5> + // $TEST$ serialization literal<2.5> val additionFloatInt = »1.5 + 1«; - # $TEST$ serialization literal<0.5> + // $TEST$ serialization literal<0.5> val subtractionFloatInt = »1.5 - 1«; - # $TEST$ serialization literal<1.5> + // $TEST$ serialization literal<1.5> val multiplicationFloatInt = »1.5 * 1«; - # $TEST$ serialization literal<1.5> + // $TEST$ serialization literal<1.5> val divisionFloatInt = »1.5 / 1«; - # $TEST$ serialization literal<2.75> + // $TEST$ serialization literal<2.75> val additionFloatFloat = »1.5 + 1.25«; - # $TEST$ serialization literal<0.25> + // $TEST$ serialization literal<0.25> val subtractionFloatFloat = »1.5 - 1.25«; - # $TEST$ serialization literal<1.875> + // $TEST$ serialization literal<1.875> val multiplicationFloatFloat = »1.5 * 1.25«; - # $TEST$ serialization literal<0.6> + // $TEST$ serialization literal<0.6> val divisionFloatFloat = »1.5 / 2.5«; - # $TEST$ serialization literal<-1> + // $TEST$ serialization literal<-1> val negationInt = »-1«; - # $TEST$ serialization literal<-1.5> + // $TEST$ serialization literal<-1.5> val negationFloat = »-1.5«; } pipeline invalidOperands { - # $TEST$ serialization Float + // $TEST$ serialization Float val additionInvalid = »true + true«; - # $TEST$ serialization Float + // $TEST$ serialization Float val subtractionInvalid = »true - true«; - # $TEST$ serialization Float + // $TEST$ serialization Float val multiplicationInvalid = »true * true«; - # $TEST$ serialization Float + // $TEST$ serialization Float val divisionInvalid = »true / true«; - # $TEST$ serialization Float + // $TEST$ serialization Float val negationInvalid = »-true«; } pipeline nonConstantOperands { - # $TEST$ serialization Int + // $TEST$ serialization Int val additionIntInt = »anyInt() + anyInt()«; - # $TEST$ serialization Int + // $TEST$ serialization Int val subtractionIntInt = »anyInt() - anyInt()«; - # $TEST$ serialization Int + // $TEST$ serialization Int val multiplicationIntInt = »anyInt() * anyInt()«; - # $TEST$ serialization Int + // $TEST$ serialization Int val divisionIntInt = »anyInt() / anyInt()«; - # $TEST$ serialization Float + // $TEST$ serialization Float val additionIntFloat = »anyInt() + anyFloat()«; - # $TEST$ serialization Float + // $TEST$ serialization Float val subtractionIntFloat = »anyInt() - anyFloat()«; - # $TEST$ serialization Float + // $TEST$ serialization Float val multiplicationIntFloat = »anyInt() * anyFloat()«; - # $TEST$ serialization Float + // $TEST$ serialization Float val divisionIntFloat = »anyInt() / anyFloat()«; - # $TEST$ serialization Float + // $TEST$ serialization Float val additionFloatInt = »anyFloat() + anyInt()«; - # $TEST$ serialization Float + // $TEST$ serialization Float val subtractionFloatInt = »anyFloat() - anyInt()«; - # $TEST$ serialization Float + // $TEST$ serialization Float val multiplicationFloatInt = »anyFloat() * anyInt()«; - # $TEST$ serialization Float + // $TEST$ serialization Float val divisionFloatInt = »anyFloat() / anyInt()«; - # $TEST$ serialization Float + // $TEST$ serialization Float val additionFloatFloat = »anyFloat() + anyFloat()«; - # $TEST$ serialization Float + // $TEST$ serialization Float val subtractionFloatFloat = »anyFloat() - anyFloat()«; - # $TEST$ serialization Float + // $TEST$ serialization Float val multiplicationFloatFloat = »anyFloat() * anyFloat()«; - # $TEST$ serialization Float + // $TEST$ serialization Float val divisionFloatFloat = »anyFloat() / anyFloat()«; - # $TEST$ serialization Int + // $TEST$ serialization Int val negationInt = »-anyInt()«; - # $TEST$ serialization Float + // $TEST$ serialization Float val negationFloat = »-anyFloat()«; } pipeline mixedOperands { - # $TEST$ serialization Int + // $TEST$ serialization Int val additionIntInt = »10 + anyInt()«; - # $TEST$ serialization Int + // $TEST$ serialization Int val subtractionIntInt = »10 - anyInt()«; - # $TEST$ serialization Int + // $TEST$ serialization Int val multiplicationIntInt = »10 * anyInt()«; - # $TEST$ serialization Int + // $TEST$ serialization Int val divisionIntInt = »10 / anyInt()«; - # $TEST$ serialization Float + // $TEST$ serialization Float val additionIntFloat = »10 + anyFloat()«; - # $TEST$ serialization Float + // $TEST$ serialization Float val subtractionIntFloat = »10 - anyFloat()«; - # $TEST$ serialization Float + // $TEST$ serialization Float val multiplicationIntFloat = »10 * anyFloat()«; - # $TEST$ serialization Float + // $TEST$ serialization Float val divisionIntFloat = »10 / anyFloat()«; - # $TEST$ serialization Float + // $TEST$ serialization Float val additionFloatInt = »1.5 + anyInt()«; - # $TEST$ serialization Float + // $TEST$ serialization Float val subtractionFloatInt = »1.5 - anyInt()«; - # $TEST$ serialization Float + // $TEST$ serialization Float val multiplicationFloatInt = »1.5 * anyInt()«; - # $TEST$ serialization Float + // $TEST$ serialization Float val divisionFloatInt = »1.5 / anyInt()«; - # $TEST$ serialization Float + // $TEST$ serialization Float val additionFloatFloat = »1.5 + anyFloat()«; - # $TEST$ serialization Float + // $TEST$ serialization Float val subtractionFloatFloat = »1.5 - anyFloat()«; - # $TEST$ serialization Float + // $TEST$ serialization Float val multiplicationFloatFloat = »1.5 * anyFloat()«; - # $TEST$ serialization Float + // $TEST$ serialization Float val divisionFloatFloat = »1.5 / anyFloat()«; } @@ -145,10 +145,10 @@ pipeline mixedOperands { class MyClass( p1: T, - # $TEST$ serialization Float + // $TEST$ serialization Float p2: Any? = »p1 + 1«, - # $TEST$ serialization Float + // $TEST$ serialization Float p3: Any? = »1 + p1«, - # $TEST$ serialization Float + // $TEST$ serialization Float p4: Any? = »-p1«, ) diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/operations/comparison/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/operations/comparison/main.sdstest index e362d0c2..1aa39738 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/operations/comparison/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/operations/comparison/main.sdstest @@ -1,21 +1,21 @@ package tests.typing.operations.comparison pipeline myPipeline { - # $TEST$ serialization literal + // $TEST$ serialization literal val lessThan = »1 < 1«; - # $TEST$ serialization literal + // $TEST$ serialization literal val lessThanOrEquals = »1 <= 1«; - # $TEST$ serialization literal + // $TEST$ serialization literal val greaterThanOrEquals = »1 >= 1«; - # $TEST$ serialization literal + // $TEST$ serialization literal val greaterThan = »1 > 1«; - # $TEST$ serialization Boolean + // $TEST$ serialization Boolean val lessThanInvalid = »true < true«; - # $TEST$ serialization Boolean + // $TEST$ serialization Boolean val lessThanOrEqualsInvalid = »true <= true«; - # $TEST$ serialization Boolean + // $TEST$ serialization Boolean val greaterThanOrEqualsInvalid = »true >= true«; - # $TEST$ serialization Boolean + // $TEST$ serialization Boolean val greaterThanInvalid = »true > true«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/operations/elvis/non nullable left operand.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/operations/elvis/non nullable left operand.sdstest index 8e4e33ef..0c69a9d1 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/operations/elvis/non nullable left operand.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/operations/elvis/non nullable left operand.sdstest @@ -4,29 +4,29 @@ package tests.typing.operations.elvis.nonNullableLeftOperand @Pure fun intOrNull() -> a: Int? pipeline elvisWithNonNullableLeftOperand { - # $TEST$ equivalence_class leftOperand1 + // $TEST$ equivalence_class leftOperand1 »1«; - # $TEST$ equivalence_class leftOperand1 + // $TEST$ equivalence_class leftOperand1 »1 ?: intOrNull()«; - # $TEST$ equivalence_class leftOperand1 + // $TEST$ equivalence_class leftOperand1 »1 ?: 1«; - # $TEST$ equivalence_class leftOperand1 + // $TEST$ equivalence_class leftOperand1 »1 ?: 1.0«; - # $TEST$ equivalence_class leftOperand1 + // $TEST$ equivalence_class leftOperand1 »1 ?: ""«; - # $TEST$ equivalence_class leftOperand1 + // $TEST$ equivalence_class leftOperand1 »1 ?: null«; - # $TEST$ equivalence_class leftOperand2 + // $TEST$ equivalence_class leftOperand2 »int()«; - # $TEST$ equivalence_class leftOperand2 + // $TEST$ equivalence_class leftOperand2 »int() ?: intOrNull()«; - # $TEST$ equivalence_class leftOperand2 + // $TEST$ equivalence_class leftOperand2 »int() ?: 1«; - # $TEST$ equivalence_class leftOperand2 + // $TEST$ equivalence_class leftOperand2 »int() ?: 1.0«; - # $TEST$ equivalence_class leftOperand2 + // $TEST$ equivalence_class leftOperand2 »int() ?: ""«; - # $TEST$ equivalence_class leftOperand2 + // $TEST$ equivalence_class leftOperand2 »int() ?: null«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/operations/elvis/nullable left operand.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/operations/elvis/nullable left operand.sdstest index 7b4dbd9a..099e092e 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/operations/elvis/nullable left operand.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/operations/elvis/nullable left operand.sdstest @@ -4,16 +4,16 @@ package tests.typing.operations.elvis.nullableLeftOperand @Pure fun stringOrNull() -> s: String? pipeline elvisWithNullableLeftOperand { - # $TEST$ serialization Int? + // $TEST$ serialization Int? »intOrNull() ?: intOrNull()«; - # $TEST$ serialization Int? + // $TEST$ serialization Int? »intOrNull() ?: null«; - # $TEST$ serialization Int + // $TEST$ serialization Int »intOrNull() ?: 1«; - # $TEST$ serialization Number + // $TEST$ serialization Number »intOrNull() ?: 1.0«; - # $TEST$ serialization Any + // $TEST$ serialization Any »intOrNull() ?: ""«; - # $TEST$ serialization Any? + // $TEST$ serialization Any? »intOrNull() ?: stringOrNull()«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/operations/equality/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/operations/equality/main.sdstest index e2b6223b..6d7ffa53 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/operations/equality/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/operations/equality/main.sdstest @@ -1,22 +1,22 @@ package tests.typing.operations.equality pipeline myPipeline { - # $TEST$ serialization literal + // $TEST$ serialization literal val equals = (»1 == 1«); - # $TEST$ serialization literal + // $TEST$ serialization literal val notEquals = (»1 != 1«); - # $TEST$ serialization literal + // $TEST$ serialization literal val identicalTo = (»1 === 1«); - # $TEST$ serialization literal + // $TEST$ serialization literal val notIdenticalTo = (»1 !== 1«); - # $TEST$ serialization Boolean + // $TEST$ serialization Boolean val nonConstantEquals = (»1 == unresolved«); - # $TEST$ serialization Boolean + // $TEST$ serialization Boolean val nonConstantNotEquals = (»1 != unresolved«); - # $TEST$ serialization Boolean + // $TEST$ serialization Boolean val nonConstantIdenticalTo = (»1 === unresolved«); - # $TEST$ serialization Boolean + // $TEST$ serialization Boolean val nonConstantNotIdenticalTo = (»1 !== unresolved«); } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/operations/logical/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/operations/logical/main.sdstest index 39c328fa..2428e6b4 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/operations/logical/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/operations/logical/main.sdstest @@ -1,17 +1,17 @@ package tests.typing.operations.logical pipeline myPipeline { - # $TEST$ serialization literal + // $TEST$ serialization literal val conjunction = »true and true«; - # $TEST$ serialization literal + // $TEST$ serialization literal val disjunction = »true or true«; - # $TEST$ serialization literal + // $TEST$ serialization literal val negation = »not true«; - # $TEST$ serialization Boolean + // $TEST$ serialization Boolean val conjunctionInvalid = »1 and 1«; - # $TEST$ serialization Boolean + // $TEST$ serialization Boolean val disjunctionInvalid = »1.0 or 1.0«; - # $TEST$ serialization Boolean + // $TEST$ serialization Boolean val negationInvalid = »not "true"«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/parenthesized expressions/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/parenthesized expressions/main.sdstest index 8da5a246..7695ced7 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/parenthesized expressions/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/parenthesized expressions/main.sdstest @@ -1,23 +1,23 @@ package tests.typing.expressions.parenthesizedExpressions pipeline myPipeline { - # $TEST$ equivalence_class boolean - # $TEST$ equivalence_class boolean + // $TEST$ equivalence_class boolean + // $TEST$ equivalence_class boolean »(»true«)«; - # $TEST$ equivalence_class float - # $TEST$ equivalence_class float + // $TEST$ equivalence_class float + // $TEST$ equivalence_class float »(»1.0«)«; - # $TEST$ equivalence_class int - # $TEST$ equivalence_class int + // $TEST$ equivalence_class int + // $TEST$ equivalence_class int »(»1«)«; - # $TEST$ equivalence_class null - # $TEST$ equivalence_class null + // $TEST$ equivalence_class null + // $TEST$ equivalence_class null »(»null«)«; - # $TEST$ equivalence_class string - # $TEST$ equivalence_class string + // $TEST$ equivalence_class string + // $TEST$ equivalence_class string »(»""«)«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/references/to global classes/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/references/to global classes/main.sdstest index ae1d50c4..1d2be92c 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/references/to global classes/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/references/to global classes/main.sdstest @@ -3,6 +3,6 @@ package tests.typing.expressions.references.toGlobalClasses class MyClass pipeline myPipeline { - # $TEST$ serialization $type + // $TEST$ serialization $type »MyClass«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/references/to global enums/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/references/to global enums/main.sdstest index a75c2e08..03b51756 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/references/to global enums/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/references/to global enums/main.sdstest @@ -3,6 +3,6 @@ package tests.typing.expressions.references.toGlobalEnums enum MyEnum pipeline myPipeline { - # $TEST$ serialization $type + // $TEST$ serialization $type »MyEnum«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/references/to other/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/references/to other/main.sdstest index 6c197d53..e284e171 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/references/to other/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/references/to other/main.sdstest @@ -1,13 +1,13 @@ package tests.typing.expressions.references.toOther segment mySegment( - # $TEST$ equivalence_class p1 + // $TEST$ equivalence_class p1 »p1«: Int, - # $TEST$ equivalence_class p2 + // $TEST$ equivalence_class p2 »p2«: String ) { - # $TEST$ equivalence_class p1 + // $TEST$ equivalence_class p1 »p1«; - # $TEST$ equivalence_class p2 + // $TEST$ equivalence_class p2 »p2«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/references/unresolved/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/references/unresolved/main.sdstest index 355117c4..a14b2c6e 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/references/unresolved/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/references/unresolved/main.sdstest @@ -1,6 +1,6 @@ package tests.typing.expressions.references.unresolved pipeline myPipeline { - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown »unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/template strings/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/template strings/main.sdstest index 98786622..bf878f09 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/template strings/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/template strings/main.sdstest @@ -1,9 +1,9 @@ package tests.typing.expressions.templateStrings pipeline myPipeline { - # $TEST$ serialization literal<"1 + 2 = 3"> + // $TEST$ serialization literal<"1 + 2 = 3"> val valid = »"1 + 2 = {{ 1 + 2 }}"«; - # $TEST$ serialization String + // $TEST$ serialization String val invalid = »"1 + 2 = {{ unresolved }}"«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/type casts/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/type casts/main.sdstest index 07ee7569..aee79776 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/type casts/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/type casts/main.sdstest @@ -3,12 +3,12 @@ package tests.typing.expressions.typeCasts @Pure fun f() -> r: Int pipeline myPipeline { - # $TEST$ serialization Boolean + // $TEST$ serialization Boolean »1 as Boolean«; // Partial evaluator can handle expression - # $TEST$ serialization Boolean + // $TEST$ serialization Boolean »r as Boolean«; // Partial evaluator cannot handle expression - # $TEST$ serialization Boolean + // $TEST$ serialization Boolean »unresolved as Boolean«; // Expression has unknown type } diff --git a/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and class type/cannot stop if class has no type parameters.sdstest b/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and class type/cannot stop if class has no type parameters.sdstest index b59396de..5743b68c 100644 --- a/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and class type/cannot stop if class has no type parameters.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and class type/cannot stop if class has no type parameters.sdstest @@ -9,6 +9,6 @@ segment mySegment( p1: Contravariant>, p2: Contravariant, ) { - # $TEST$ serialization List> + // $TEST$ serialization List> »[p1, p2]«; } diff --git a/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and class type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and class type/main.sdstest index 21958d20..0282a7a4 100644 --- a/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and class type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and class type/main.sdstest @@ -16,27 +16,27 @@ segment mySegment1( e: Contravariant, eOrNull: Contravariant, ) { - # $TEST$ serialization List> + // $TEST$ serialization List> »[c, c]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[c, cOrNull]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[c, d]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[c, dOrNull]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[c, e]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[c, eOrNull]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[cOrNull, cOrNull]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[cOrNull, d]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[cOrNull, dOrNull]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[cOrNull, e]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[cOrNull, eOrNull]«; } diff --git a/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and class type/with type parameters.sdstest b/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and class type/with type parameters.sdstest index 1ee940c0..f67c8743 100644 --- a/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and class type/with type parameters.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and class type/with type parameters.sdstest @@ -11,39 +11,39 @@ segment covariant( coFloat: Contravariant, coFloat2: Contravariant>, ) { - # $TEST$ serialization List>> + // $TEST$ serialization List>> »[coNumber, coNumber]«; - # $TEST$ serialization List>> + // $TEST$ serialization List>> »[coNumber, coInt]«; - # $TEST$ serialization List>> + // $TEST$ serialization List>> »[coNumber, coString]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[coNumber, coFloat]«; - # $TEST$ serialization List>> + // $TEST$ serialization List>> »[coNumber, coFloat2]«; - # $TEST$ serialization List>> + // $TEST$ serialization List>> »[coInt, coInt]«; - # $TEST$ serialization List>> + // $TEST$ serialization List>> »[coInt, coString]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[coInt, coFloat]«; - # $TEST$ serialization List>> + // $TEST$ serialization List>> »[coInt, coFloat2]«; - # $TEST$ serialization List>> + // $TEST$ serialization List>> »[coString, coString]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[coString, coFloat]«; - # $TEST$ serialization List>> + // $TEST$ serialization List>> »[coString, coFloat2]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[coFloat, coFloat]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[coFloat, coFloat2]«; - # $TEST$ serialization List>> + // $TEST$ serialization List>> »[coFloat2, coFloat2]«; } @@ -55,7 +55,7 @@ segment contravariant( ) { // Most tests are in the "lowest common supertype" folder. Here we only test that we call the right method. - # $TEST$ serialization List>> + // $TEST$ serialization List>> »[contraFloat, contraInt]«; } @@ -70,39 +70,39 @@ segment invariant( invInt2: Contravariant, invInt3: Contravariant>, ) { - # $TEST$ serialization List>> + // $TEST$ serialization List>> »[invNumber, invNumber]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[invNumber, invInt]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[invNumber, invString]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[invNumber, invInt2]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[invNumber, invInt3]«; - # $TEST$ serialization List>> + // $TEST$ serialization List>> »[invInt, invInt]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[invInt, invString]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[invInt, invInt2]«; - # $TEST$ serialization List>> + // $TEST$ serialization List>> »[invInt, invInt3]«; - # $TEST$ serialization List>> + // $TEST$ serialization List>> »[invString, invString]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[invString, invInt2]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[invString, invInt3]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[invInt2, invInt2]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[invInt2, invInt3]«; - # $TEST$ serialization List>> + // $TEST$ serialization List>> »[invInt3, invInt3]«; } @@ -112,11 +112,11 @@ segment multiple( multipleNumberNumber: Contravariant>, multipleNumberFloat: Contravariant>, ) { - # $TEST$ serialization List>> + // $TEST$ serialization List>> »[multipleNumberNumber, multipleNumberNumber]«; - # $TEST$ serialization List>> + // $TEST$ serialization List>> »[multipleNumberNumber, multipleNumberFloat]«; - # $TEST$ serialization List>> + // $TEST$ serialization List>> »[multipleNumberFloat, multipleNumberFloat]«; } diff --git a/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and enum type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and enum type/main.sdstest index 5c0a1ee2..a36b52cc 100644 --- a/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and enum type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and enum type/main.sdstest @@ -14,21 +14,21 @@ segment mySegment( e: Contravariant, eOrNull: Contravariant, ) { - # $TEST$ serialization List> + // $TEST$ serialization List> »[any, e]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[anyOrNull, e]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[any, eOrNull]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[anyOrNull, eOrNull]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[c, e]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[cOrNull, e]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[c, eOrNull]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[cOrNull, eOrNull]«; } diff --git a/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and enum variant/main.sdstest b/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and enum variant/main.sdstest index 64a697bb..f7ff7cc1 100644 --- a/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and enum variant/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and enum variant/main.sdstest @@ -16,21 +16,21 @@ segment mySegment( v: Contravariant, vOrNull: Contravariant, ) { - # $TEST$ serialization List> + // $TEST$ serialization List> »[any, v]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[anyOrNull, v]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[any, vOrNull]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[anyOrNull, vOrNull]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[c, v]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[cOrNull, v]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[c, vOrNull]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[cOrNull, vOrNull]«; } diff --git a/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and literal type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and literal type/main.sdstest index e17eee28..c228385c 100644 --- a/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and literal type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and literal type/main.sdstest @@ -19,52 +19,52 @@ segment mySegment( nothing: Contravariant, nothingOrNull: Contravariant, ) { - # $TEST$ serialization List> + // $TEST$ serialization List> »[one, c]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[one, cOrNull]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[oneOrNull, cOrNull]«; - # $TEST$ serialization List>> + // $TEST$ serialization List>> »[one, int]«; - # $TEST$ serialization List>> + // $TEST$ serialization List>> »[one, intOrNull]«; - # $TEST$ serialization List>> + // $TEST$ serialization List>> »[oneOrNull, intOrNull]«; - # $TEST$ serialization List>> + // $TEST$ serialization List>> »[one, number]«; - # $TEST$ serialization List>> + // $TEST$ serialization List>> »[one, numberOrNull]«; - # $TEST$ serialization List>> + // $TEST$ serialization List>> »[oneOrNull, numberOrNull]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[one, string]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[one, stringOrNull]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[oneOrNull, stringOrNull]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[one, nothing]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[one, nothingOrNull]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[oneOrNull, nothingOrNull]«; } diff --git a/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and type parameter type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and type parameter type/main.sdstest index 4abae894..9586a80c 100644 --- a/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and type parameter type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and type parameter type/main.sdstest @@ -22,29 +22,29 @@ class Test< toDOrNullExplicit: Contravariant, toE: Contravariant, - # $TEST$ serialization List> + // $TEST$ serialization List> a1: Any = »[c, toAnyOrNull]«, - # $TEST$ serialization List> + // $TEST$ serialization List> a2: Any = »[c, toAnyOrNullExplicit]«, - # $TEST$ serialization List> + // $TEST$ serialization List> a3: Any = »[c, toC]«, - # $TEST$ serialization List> + // $TEST$ serialization List> a4: Any = »[c, toD]«, - # $TEST$ serialization List> + // $TEST$ serialization List> a5: Any = »[c, toDOrNullExplicit]«, - # $TEST$ serialization List> + // $TEST$ serialization List> a6: Any = »[c, toE]«, - # $TEST$ serialization List> + // $TEST$ serialization List> b1: Any = »[cOrNull, toAnyOrNull]«, - # $TEST$ serialization List> + // $TEST$ serialization List> b2: Any = »[cOrNull, toAnyOrNullExplicit]«, - # $TEST$ serialization List> + // $TEST$ serialization List> b3: Any = »[cOrNull, toC]«, - # $TEST$ serialization List> + // $TEST$ serialization List> b4: Any = »[cOrNull, toD]«, - # $TEST$ serialization List> + // $TEST$ serialization List> b5: Any = »[cOrNull, toDOrNullExplicit]«, - # $TEST$ serialization List> + // $TEST$ serialization List> b6: Any = »[cOrNull, toE]«, ) diff --git a/packages/ttsl-lang/tests/resources/typing/highest common subtype/enum type and enum type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/highest common subtype/enum type and enum type/main.sdstest index accbcf08..c2d540b2 100644 --- a/packages/ttsl-lang/tests/resources/typing/highest common subtype/enum type and enum type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/highest common subtype/enum type and enum type/main.sdstest @@ -11,22 +11,22 @@ segment mySegment( e2: Contravariant, e2OrNull: Contravariant ) { - # $TEST$ serialization List> + // $TEST$ serialization List> »[e1, e1]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[e1, e1OrNull]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[e1OrNull, e1OrNull]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[e1, e2]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[e1, e2OrNull]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[e1OrNull, e2OrNull]«; } diff --git a/packages/ttsl-lang/tests/resources/typing/highest common subtype/enum type and enum variant type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/highest common subtype/enum type and enum variant type/main.sdstest index 1d58e7fe..459b2b93 100644 --- a/packages/ttsl-lang/tests/resources/typing/highest common subtype/enum type and enum variant type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/highest common subtype/enum type and enum variant type/main.sdstest @@ -17,22 +17,22 @@ segment mySegment( v2: Contravariant, v2OrNull: Contravariant, ) { - # $TEST$ serialization List> + // $TEST$ serialization List> »[e1, v1]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[e1, v1OrNull]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[e1OrNull, v1OrNull]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[e1, v2]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[e1, v2OrNull]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[e1OrNull, v2OrNull]«; } diff --git a/packages/ttsl-lang/tests/resources/typing/highest common subtype/enum type and type parameter type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/highest common subtype/enum type and type parameter type/main.sdstest index 1a629057..852368bf 100644 --- a/packages/ttsl-lang/tests/resources/typing/highest common subtype/enum type and type parameter type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/highest common subtype/enum type and type parameter type/main.sdstest @@ -24,29 +24,29 @@ class Test< toVOrNullExplicit: Contravariant, toF: Contravariant, - # $TEST$ serialization List> + // $TEST$ serialization List> a1: Any = »[e, toAnyOrNull]«, - # $TEST$ serialization List> + // $TEST$ serialization List> a2: Any = »[e, toAnyOrNullExplicit]«, - # $TEST$ serialization List> + // $TEST$ serialization List> a3: Any = »[e, toE]«, - # $TEST$ serialization List> + // $TEST$ serialization List> a4: Any = »[e, toV]«, - # $TEST$ serialization List> + // $TEST$ serialization List> a5: Any = »[e, toVOrNullExplicit]«, - # $TEST$ serialization List> + // $TEST$ serialization List> a6: Any = »[e, toF]«, - # $TEST$ serialization List> + // $TEST$ serialization List> b1: Any = »[eOrNull, toAnyOrNull]«, - # $TEST$ serialization List> + // $TEST$ serialization List> b2: Any = »[eOrNull, toAnyOrNullExplicit]«, - # $TEST$ serialization List> + // $TEST$ serialization List> b3: Any = »[eOrNull, toE]«, - # $TEST$ serialization List> + // $TEST$ serialization List> b4: Any = »[eOrNull, toV]«, - # $TEST$ serialization List> + // $TEST$ serialization List> b5: Any = »[eOrNull, toVOrNullExplicit]«, - # $TEST$ serialization List> + // $TEST$ serialization List> b6: Any = »[eOrNull, toF]«, ) diff --git a/packages/ttsl-lang/tests/resources/typing/highest common subtype/enum variant type and enum variant type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/highest common subtype/enum variant type and enum variant type/main.sdstest index 9a62e91b..33c9919e 100644 --- a/packages/ttsl-lang/tests/resources/typing/highest common subtype/enum variant type and enum variant type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/highest common subtype/enum variant type and enum variant type/main.sdstest @@ -18,32 +18,32 @@ segment mySegment( v3: Contravariant, v3OrNull: Contravariant ) { - # $TEST$ serialization List> + // $TEST$ serialization List> »[v1, v1]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[v1, v1OrNull]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[v1OrNull, v1OrNull]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[v1, v2]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[v1, v2OrNull]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[v1OrNull, v2OrNull]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[v1, v3]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[v1, v3OrNull]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[v1OrNull, v3OrNull]«; } diff --git a/packages/ttsl-lang/tests/resources/typing/highest common subtype/enum variant type and type parameter type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/highest common subtype/enum variant type and type parameter type/main.sdstest index 09b54a37..82b1ef21 100644 --- a/packages/ttsl-lang/tests/resources/typing/highest common subtype/enum variant type and type parameter type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/highest common subtype/enum variant type and type parameter type/main.sdstest @@ -21,25 +21,25 @@ class Test< toV1OrNullExplicit: Contravariant, toV2: Contravariant, - # $TEST$ serialization List> + // $TEST$ serialization List> a1: Any = »[v1, toAnyOrNull]«, - # $TEST$ serialization List> + // $TEST$ serialization List> a2: Any = »[v1, toAnyOrNullExplicit]«, - # $TEST$ serialization List> + // $TEST$ serialization List> a3: Any = »[v1, toV1]«, - # $TEST$ serialization List> + // $TEST$ serialization List> a4: Any = »[v1, toV1OrNullExplicit]«, - # $TEST$ serialization List> + // $TEST$ serialization List> a5: Any = »[v1, toV2]«, - # $TEST$ serialization List> + // $TEST$ serialization List> b1: Any = »[v1OrNull, toAnyOrNull]«, - # $TEST$ serialization List> + // $TEST$ serialization List> b2: Any = »[v1OrNull, toAnyOrNullExplicit]«, - # $TEST$ serialization List> + // $TEST$ serialization List> b3: Any = »[v1OrNull, toV1]«, - # $TEST$ serialization List> + // $TEST$ serialization List> b4: Any = »[v1OrNull, toV1OrNullExplicit]«, - # $TEST$ serialization List> + // $TEST$ serialization List> b5: Any = »[v1OrNull, toV2]«, ) diff --git a/packages/ttsl-lang/tests/resources/typing/highest common subtype/incompatible types/main.sdstest b/packages/ttsl-lang/tests/resources/typing/highest common subtype/incompatible types/main.sdstest index 0c731ad0..870a0a6f 100644 --- a/packages/ttsl-lang/tests/resources/typing/highest common subtype/incompatible types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/highest common subtype/incompatible types/main.sdstest @@ -16,24 +16,24 @@ segment mySegment( v: Contravariant, vOrNull: Contravariant ) { - # $TEST$ serialization List> + // $TEST$ serialization List> »[one, e]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[oneOrNull, e]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[one, eOrNull]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[oneOrNull, eOrNull]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[one, v]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[oneOrNull, v]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[one, vOrNull]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[oneOrNull, vOrNull]«; } @@ -44,13 +44,13 @@ class Test( t: Contravariant, tOrNull: Contravariant, - # $TEST$ serialization List> + // $TEST$ serialization List> p1: Any = »[one, t]«, - # $TEST$ serialization List> + // $TEST$ serialization List> p2: Any = »[one, tOrNull]«, - # $TEST$ serialization List> + // $TEST$ serialization List> p3: Any = »[oneOrNull, t]«, - # $TEST$ serialization List> + // $TEST$ serialization List> p4: Any = »[oneOrNull, tOrNull]« ) diff --git a/packages/ttsl-lang/tests/resources/typing/highest common subtype/literal type and literal type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/highest common subtype/literal type and literal type/main.sdstest index 3e8070c8..01be3a8c 100644 --- a/packages/ttsl-lang/tests/resources/typing/highest common subtype/literal type and literal type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/highest common subtype/literal type and literal type/main.sdstest @@ -7,12 +7,12 @@ segment mySegment( p2: Contravariant>, p3: Contravariant>, ) { - # $TEST$ serialization List>> + // $TEST$ serialization List>> »[p1, p1]«; - # $TEST$ serialization List>> + // $TEST$ serialization List>> »[p1, p2]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[p1, p3]«; } diff --git a/packages/ttsl-lang/tests/resources/typing/highest common subtype/simplification/main.sdstest b/packages/ttsl-lang/tests/resources/typing/highest common subtype/simplification/main.sdstest index a565e0de..8afda84c 100644 --- a/packages/ttsl-lang/tests/resources/typing/highest common subtype/simplification/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/highest common subtype/simplification/main.sdstest @@ -7,15 +7,15 @@ segment mySegment( p2: Contravariant>, p3: Contravariant, literal>>, ) { - # $TEST$ serialization List> + // $TEST$ serialization List> »[p1, p2]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[p1, p3]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[p2, p3]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[p3, p3]«; } diff --git a/packages/ttsl-lang/tests/resources/typing/highest common subtype/type parameter type and type parameter type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/highest common subtype/type parameter type and type parameter type/main.sdstest index 02d37d94..829c20a9 100644 --- a/packages/ttsl-lang/tests/resources/typing/highest common subtype/type parameter type and type parameter type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/highest common subtype/type parameter type and type parameter type/main.sdstest @@ -8,19 +8,19 @@ class Test( t2: Contravariant, t2OrNull: Contravariant, - # $TEST$ serialization List> + // $TEST$ serialization List> a1: Any = »[t1, t1]«, - # $TEST$ serialization List> + // $TEST$ serialization List> a2: Any = »[t1, t1OrNull]«, - # $TEST$ serialization List> + // $TEST$ serialization List> a3: Any = »[t1, t2]«, - # $TEST$ serialization List> + // $TEST$ serialization List> a4: Any = »[t1, t2OrNull]«, - # $TEST$ serialization List> + // $TEST$ serialization List> b1: Any = »[t1OrNull, t1OrNull]«, - # $TEST$ serialization List> + // $TEST$ serialization List> b2: Any = »[t1OrNull, t2]«, - # $TEST$ serialization List> + // $TEST$ serialization List> b3: Any = »[t1OrNull, t2OrNull]«, ) diff --git a/packages/ttsl-lang/tests/resources/typing/highest common subtype/unhandled type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/highest common subtype/unhandled type/main.sdstest index 09a3c2da..15f6062d 100644 --- a/packages/ttsl-lang/tests/resources/typing/highest common subtype/unhandled type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/highest common subtype/unhandled type/main.sdstest @@ -13,21 +13,21 @@ segment mySegment( // Named tuple types and static types are also not handled, but we can't test them here ) { - # $TEST$ serialization List> + // $TEST$ serialization List> »[one, `union`]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[oneOrNull, `union`]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[one, unionOrNull]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[oneOrNull, unionOrNull]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[one, callable]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[oneOrNull, callable]«; } diff --git a/packages/ttsl-lang/tests/resources/typing/highest common subtype/unknown type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/highest common subtype/unknown type/main.sdstest index 31749d27..2ad0d112 100644 --- a/packages/ttsl-lang/tests/resources/typing/highest common subtype/unknown type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/highest common subtype/unknown type/main.sdstest @@ -7,9 +7,9 @@ segment mySegment( nullable: Contravariant>, unknown: Contravariant, ) { - # $TEST$ serialization List> + // $TEST$ serialization List> »[one, unknown]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[nullable, unknown]«; } diff --git a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/class type and class type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/class type and class type/main.sdstest index 86843c9c..56108684 100644 --- a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/class type and class type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/class type and class type/main.sdstest @@ -12,23 +12,23 @@ segment mySegment1( e: E, eOrNull: E?, ) { - # $TEST$ serialization List + // $TEST$ serialization List »[c, c]«; - # $TEST$ serialization List + // $TEST$ serialization List »[c, cOrNull]«; - # $TEST$ serialization List + // $TEST$ serialization List »[c, d]«; - # $TEST$ serialization List + // $TEST$ serialization List »[c, dOrNull]«; - # $TEST$ serialization List + // $TEST$ serialization List »[c, e]«; - # $TEST$ serialization List + // $TEST$ serialization List »[c, eOrNull]«; } diff --git a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/class type and class type/with type parameters.sdstest b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/class type and class type/with type parameters.sdstest index ec54d142..ed059df9 100644 --- a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/class type and class type/with type parameters.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/class type and class type/with type parameters.sdstest @@ -9,28 +9,28 @@ segment covariant( coString: Covariant, coFloat: FloatCovariant, ) { - # $TEST$ serialization List> + // $TEST$ serialization List> »[coNumber, coNumber]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[coNumber, coInt]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[coNumber, coString]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[coNumber, coFloat]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[coInt, coInt]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[coInt, coString]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[coInt, coFloat]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[coString, coString]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[coString, coFloat]«; - # $TEST$ serialization List + // $TEST$ serialization List »[coFloat, coFloat]«; } @@ -42,7 +42,7 @@ segment contravariant( ) { // Most tests are in the "highest common subtype" folder. Here we only test that we call the right method. - # $TEST$ serialization List> + // $TEST$ serialization List> »[contraFloat, contraInt]«; } @@ -55,28 +55,28 @@ segment invariant( invString: Invariant, invFloat: FloatInvariant ) { - # $TEST$ serialization List> + // $TEST$ serialization List> »[invNumber, invNumber]«; - # $TEST$ serialization List + // $TEST$ serialization List »[invNumber, invInt]«; - # $TEST$ serialization List + // $TEST$ serialization List »[invNumber, invString]«; - # $TEST$ serialization List + // $TEST$ serialization List »[invNumber, invFloat]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[invInt, invInt]«; - # $TEST$ serialization List + // $TEST$ serialization List »[invInt, invString]«; - # $TEST$ serialization List + // $TEST$ serialization List »[invInt, invFloat]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[invString, invString]«; - # $TEST$ serialization List + // $TEST$ serialization List »[invString, invFloat]«; - # $TEST$ serialization List + // $TEST$ serialization List »[invFloat, invFloat]«; } @@ -86,11 +86,11 @@ segment multiple( multipleNumberInt: Multiple, multipleNumberFloat: Multiple, ) { - # $TEST$ serialization List> + // $TEST$ serialization List> »[multipleNumberInt, multipleNumberInt]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[multipleNumberInt, multipleNumberFloat]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[multipleNumberFloat, multipleNumberFloat]«; } diff --git a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/class type and literal type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/class type and literal type/main.sdstest index ffa04adf..93b2dfb4 100644 --- a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/class type and literal type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/class type and literal type/main.sdstest @@ -14,37 +14,37 @@ segment mySegment( nothing: Nothing, nothingOrNull: Nothing?, ) { - # $TEST$ serialization List + // $TEST$ serialization List »[1, c]«; - # $TEST$ serialization List + // $TEST$ serialization List »[1, cOrNull]«; - # $TEST$ serialization List + // $TEST$ serialization List »[1, int]«; - # $TEST$ serialization List + // $TEST$ serialization List »[1, intOrNull]«; - # $TEST$ serialization List + // $TEST$ serialization List »[1, number]«; - # $TEST$ serialization List + // $TEST$ serialization List »[1, numberOrNull]«; - # $TEST$ serialization List + // $TEST$ serialization List »[1, string]«; - # $TEST$ serialization List + // $TEST$ serialization List »[1, stringOrNull]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[1, nothing]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[1, nothingOrNull]«; } diff --git a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/class type and type parameter type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/class type and type parameter type/main.sdstest index d88dd4ab..6b68b829 100644 --- a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/class type and type parameter type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/class type and type parameter type/main.sdstest @@ -12,14 +12,14 @@ class Test + // $TEST$ serialization List p1: Any = »[c, unbounded]«, - # $TEST$ serialization List + // $TEST$ serialization List p2: Any = »[c, unboundedOrNull]«, - # $TEST$ serialization List + // $TEST$ serialization List p3: Any = »[c, boundedByC]«, - # $TEST$ serialization List + // $TEST$ serialization List p4: Any = »[c, boundedByD]«, - # $TEST$ serialization List + // $TEST$ serialization List p5: Any = »[c, boundedByDOrNull]«, ) diff --git a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum type and enum type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum type and enum type/main.sdstest index 95f9a847..a25495d2 100644 --- a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum type and enum type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum type and enum type/main.sdstest @@ -9,16 +9,16 @@ segment mySegment( e2: E2, e2OrNull: E2? ) { - # $TEST$ serialization List + // $TEST$ serialization List »[e1, e1]«; - # $TEST$ serialization List + // $TEST$ serialization List »[e1, e1OrNull]«; - # $TEST$ serialization List + // $TEST$ serialization List »[e1, e2]«; - # $TEST$ serialization List + // $TEST$ serialization List »[e1, e2OrNull]«; } diff --git a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum type and enum variant type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum type and enum variant type/main.sdstest index 3c230209..0f2a8f8c 100644 --- a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum type and enum variant type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum type and enum variant type/main.sdstest @@ -14,16 +14,16 @@ segment mySegment( v2: E2.V2, v2OrNull: E2.V2? ) { - # $TEST$ serialization List + // $TEST$ serialization List »[e1, v1]«; - # $TEST$ serialization List + // $TEST$ serialization List »[e1, v1OrNull]«; - # $TEST$ serialization List + // $TEST$ serialization List »[e1, v2]«; - # $TEST$ serialization List + // $TEST$ serialization List »[e1, v2OrNull]«; } diff --git a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum type and type parameter type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum type and type parameter type/main.sdstest index de50e13c..14568f31 100644 --- a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum type and type parameter type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum type and type parameter type/main.sdstest @@ -22,16 +22,16 @@ class Test< boundedByOtherEnum: BoundedByOtherEnum, boundedByOtherEnumOrNull: BoundedByOtherEnumOrNull, - # $TEST$ serialization List + // $TEST$ serialization List p1: Any = »[e, unbounded]«, - # $TEST$ serialization List + // $TEST$ serialization List p2: Any = »[e, unboundedOrNull]«, - # $TEST$ serialization List + // $TEST$ serialization List p3: Any = »[e, boundedByEnum]«, - # $TEST$ serialization List + // $TEST$ serialization List p4: Any = »[e, boundedByEnumVariant]«, - # $TEST$ serialization List + // $TEST$ serialization List p5: Any = »[e, boundedByOtherEnum]«, - # $TEST$ serialization List + // $TEST$ serialization List p6: Any = »[e, boundedByOtherEnumOrNull]«, ) diff --git a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum variant type and enum variant type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum variant type and enum variant type/main.sdstest index f8b7a80b..1baf1b84 100644 --- a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum variant type and enum variant type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum variant type and enum variant type/main.sdstest @@ -16,23 +16,23 @@ segment mySegment( v3: E3.V3, v3OrNull: E3.V3? ) { - # $TEST$ serialization List + // $TEST$ serialization List »[v1, v1]«; - # $TEST$ serialization List + // $TEST$ serialization List »[v1, v1OrNull]«; - # $TEST$ serialization List + // $TEST$ serialization List »[v1, v2]«; - # $TEST$ serialization List + // $TEST$ serialization List »[v1, v2OrNull]«; - # $TEST$ serialization List + // $TEST$ serialization List »[v1, v3]«; - # $TEST$ serialization List + // $TEST$ serialization List »[v1, v3OrNull]«; } diff --git a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum variant type and type parameter type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum variant type and type parameter type/main.sdstest index ab92e965..45eeb432 100644 --- a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum variant type and type parameter type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum variant type and type parameter type/main.sdstest @@ -19,14 +19,14 @@ class D< boundedByOtherEnumVariant: BoundedByOtherEnumVariant, boundedByOtherEnumVariantOrNull: BoundedByOtherEnumVariantOrNull, - # $TEST$ serialization List + // $TEST$ serialization List p1: Any = »[v, unbounded]«, - # $TEST$ serialization List + // $TEST$ serialization List p2: Any = »[v, unboundedOrNull]«, - # $TEST$ serialization List + // $TEST$ serialization List p3: Any = »[v, boundedByEnumVariant]«, - # $TEST$ serialization List + // $TEST$ serialization List p4: Any = »[v, boundedByOtherEnumVariant]«, - # $TEST$ serialization List + // $TEST$ serialization List p5: Any = »[v, boundedByOtherEnumVariantOrNull]«, ) diff --git a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/incompatible types/main.sdstest b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/incompatible types/main.sdstest index 4354b1e7..34d6a492 100644 --- a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/incompatible types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/incompatible types/main.sdstest @@ -10,30 +10,30 @@ segment mySegment( eOrNull: E?, vOrNull: E.V? ) { - # $TEST$ serialization List + // $TEST$ serialization List »[C(), e]«; - # $TEST$ serialization List + // $TEST$ serialization List »[C(), eOrNull]«; - # $TEST$ serialization List + // $TEST$ serialization List »[C(), E.V]«; - # $TEST$ serialization List + // $TEST$ serialization List »[C(), vOrNull]«; - # $TEST$ serialization List + // $TEST$ serialization List »[1, e]«; - # $TEST$ serialization List + // $TEST$ serialization List »[1, eOrNull]«; - # $TEST$ serialization List + // $TEST$ serialization List »[1, E.V]«; - # $TEST$ serialization List + // $TEST$ serialization List »[1, vOrNull]«; } diff --git a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/literal type and literal type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/literal type and literal type/main.sdstest index 39548649..e69766be 100644 --- a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/literal type and literal type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/literal type and literal type/main.sdstest @@ -1,9 +1,9 @@ package tests.typing.lowestCommonSupertype.literalTypeAndLiteralType segment mySegment() { - # $TEST$ serialization List> + // $TEST$ serialization List> »[true, 1]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[true, null]«; } diff --git a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/literal type and type parameter type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/literal type and type parameter type/main.sdstest index 51554bb3..59380141 100644 --- a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/literal type and type parameter type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/literal type and type parameter type/main.sdstest @@ -12,14 +12,14 @@ class Test< boundedByString: BoundedByString, boundedByStringOrNull: BoundedByStringOrNull, - # $TEST$ serialization List + // $TEST$ serialization List p1: Any = »[1, unbounded]«, - # $TEST$ serialization List + // $TEST$ serialization List p2: Any = »[1, unboundedOrNull]«, - # $TEST$ serialization List + // $TEST$ serialization List p3: Any = »[1, boundedByInt]«, - # $TEST$ serialization List + // $TEST$ serialization List p4: Any = »[1, boundedByString]«, - # $TEST$ serialization List + // $TEST$ serialization List p5: Any = »[1, boundedByStringOrNull]«, ) diff --git a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/no types after simplification/main.sdstest b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/no types after simplification/main.sdstest index e0e9aea0..9b35a2f7 100644 --- a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/no types after simplification/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/no types after simplification/main.sdstest @@ -4,15 +4,15 @@ segment mySegment( p1: literal<>, p2: union<>, ) { - # $TEST$ serialization List + // $TEST$ serialization List »[]«; - # $TEST$ serialization List + // $TEST$ serialization List »[p1]«; - # $TEST$ serialization List + // $TEST$ serialization List »[p2]«; - # $TEST$ serialization List + // $TEST$ serialization List »[p1, p2]«; } diff --git a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/simplification/main.sdstest b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/simplification/main.sdstest index 419cfd66..942901e0 100644 --- a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/simplification/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/simplification/main.sdstest @@ -6,15 +6,15 @@ segment mySegment( p1: union, literal>, p2: literal<> ) { - # $TEST$ serialization List + // $TEST$ serialization List »[p1, p1]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[1, 1.5]«; - # $TEST$ serialization List + // $TEST$ serialization List »[C(), p2]«; - # $TEST$ serialization List + // $TEST$ serialization List »[C(), null]«; } diff --git a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/singular type after simplification/main.sdstest b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/singular type after simplification/main.sdstest index d83bdf21..72381e3e 100644 --- a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/singular type after simplification/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/singular type after simplification/main.sdstest @@ -10,30 +10,30 @@ enum E { segment mySegment( p1: E ) { - # $TEST$ serialization List<() -> ()> + // $TEST$ serialization List<() -> ()> »[() {}]«; - # $TEST$ serialization List> + // $TEST$ serialization List> »[1]«; - # $TEST$ serialization List<(r1: Int, r2: Int)> + // $TEST$ serialization List<(r1: Int, r2: Int)> »[f()]«; - # $TEST$ serialization List + // $TEST$ serialization List »[C()]«; - # $TEST$ serialization List + // $TEST$ serialization List »[p1]«; - # $TEST$ serialization List + // $TEST$ serialization List »[E.V]«; - # $TEST$ serialization List<$type> + // $TEST$ serialization List<$type> »[C]«; - # $TEST$ serialization List<$unknown> + // $TEST$ serialization List<$unknown> »[unknown]«; } -# $TEST$ serialization List +// $TEST$ serialization List class D(t: T, list: Any = »[t]«) diff --git a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/type parameter type and type parameter type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/type parameter type and type parameter type/main.sdstest index b65344cf..7a1d97b6 100644 --- a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/type parameter type and type parameter type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/type parameter type and type parameter type/main.sdstest @@ -11,27 +11,27 @@ class Test + // $TEST$ serialization List a1: Any = »[nothingToAnyOrNull, nothingToAnyOrNull]«, - # $TEST$ serialization List + // $TEST$ serialization List a2: Any = »[nothingToAnyOrNull, nothingToD]«, - # $TEST$ serialization List + // $TEST$ serialization List a3: Any = »[nothingToAnyOrNull, nothingToE]«, - # $TEST$ serialization List + // $TEST$ serialization List a4: Any = »[nothingToAnyOrNull, nothingToF]«, - # $TEST$ serialization List + // $TEST$ serialization List b1: Any = »[nothingToD, nothingToD]«, - # $TEST$ serialization List + // $TEST$ serialization List b2: Any = »[nothingToD, nothingToE]«, - # $TEST$ serialization List + // $TEST$ serialization List b3: Any = »[nothingToD, nothingToF]«, - # $TEST$ serialization List + // $TEST$ serialization List c1: Any = »[nothingToE, nothingToE]«, - # $TEST$ serialization List + // $TEST$ serialization List c2: Any = »[nothingToE, nothingToF]«, - # $TEST$ serialization List + // $TEST$ serialization List d1: Any = »[nothingToF, nothingToF]« ) diff --git a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/unhandled type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/unhandled type/main.sdstest index 636712b7..b9e60d1b 100644 --- a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/unhandled type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/unhandled type/main.sdstest @@ -4,21 +4,21 @@ class C @Pure fun f() -> (r1: Int, r2: Int) segment mySegment() { - # $TEST$ serialization List + // $TEST$ serialization List »[1, f]«; - # $TEST$ serialization List + // $TEST$ serialization List »[null, f]«; - # $TEST$ serialization List + // $TEST$ serialization List »[1, C]«; - # $TEST$ serialization List + // $TEST$ serialization List »[null, C]«; - # $TEST$ serialization List + // $TEST$ serialization List »[1, f()]«; - # $TEST$ serialization List + // $TEST$ serialization List »[null, f()]«; } diff --git a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/unknown type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/unknown type/main.sdstest index 20ca17f7..e73d1d98 100644 --- a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/unknown type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/unknown type/main.sdstest @@ -1,9 +1,9 @@ package tests.typing.lowestCommonSupertype.unknownType segment mySegment() { - # $TEST$ serialization List + // $TEST$ serialization List »[1, unknown]«; - # $TEST$ serialization List + // $TEST$ serialization List »[null, unknown]«; } diff --git a/packages/ttsl-lang/tests/resources/typing/simplification/merge literal types in union types/main.sdstest b/packages/ttsl-lang/tests/resources/typing/simplification/merge literal types in union types/main.sdstest index 94c06954..ddadce8a 100644 --- a/packages/ttsl-lang/tests/resources/typing/simplification/merge literal types in union types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/simplification/merge literal types in union types/main.sdstest @@ -1,18 +1,18 @@ package tests.typing.simplification.mergeLiteralTypesInUnionTypes class C( - # $TEST$ serialization literal<1> + // $TEST$ serialization literal<1> p1: »union, literal<1, 1>>«, - # $TEST$ serialization literal<1, 2> + // $TEST$ serialization literal<1, 2> p2: »union, literal<1, 2>>«, - # $TEST$ serialization literal<1, 2, 3> + // $TEST$ serialization literal<1, 2, 3> p3: »union, literal<2, 3>>«, - # $TEST$ serialization literal<1, 2, 3> + // $TEST$ serialization literal<1, 2, 3> p4: »union, literal<2>, literal<3>>«, - # $TEST$ serialization union, String> + // $TEST$ serialization union, String> p5: »union, String, literal<2, 3>>«, ) diff --git a/packages/ttsl-lang/tests/resources/typing/simplification/remove duplicate constants from literal types/main.sdstest b/packages/ttsl-lang/tests/resources/typing/simplification/remove duplicate constants from literal types/main.sdstest index 957e2f33..4aeb7c89 100644 --- a/packages/ttsl-lang/tests/resources/typing/simplification/remove duplicate constants from literal types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/simplification/remove duplicate constants from literal types/main.sdstest @@ -1,12 +1,12 @@ package tests.typing.simplification.removeDuplicateConstantsFromLiteralTypes class C( - # $TEST$ serialization literal<1> + // $TEST$ serialization literal<1> p1: »literal<1, 1>«, - # $TEST$ serialization literal<1, 2> + // $TEST$ serialization literal<1, 2> p2: »literal<1, 2>«, - # $TEST$ serialization literal<1, 1.0> + // $TEST$ serialization literal<1, 1.0> p3: »literal<1, 1.0>«, ) diff --git a/packages/ttsl-lang/tests/resources/typing/simplification/remove unneeded entries from union types/main.sdstest b/packages/ttsl-lang/tests/resources/typing/simplification/remove unneeded entries from union types/main.sdstest index 42e4218a..f26435ca 100644 --- a/packages/ttsl-lang/tests/resources/typing/simplification/remove unneeded entries from union types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/simplification/remove unneeded entries from union types/main.sdstest @@ -1,126 +1,126 @@ package tests.typing.simplification.removeUnneededEntriesFromUnionTypes class C( - # $TEST$ serialization Int + // $TEST$ serialization Int p1: »union«, - # $TEST$ serialization union + // $TEST$ serialization union p2: »union«, - # $TEST$ serialization Number + // $TEST$ serialization Number p3: »union«, - # $TEST$ serialization Number + // $TEST$ serialization Number p4: »union«, - # $TEST$ serialization Number? + // $TEST$ serialization Number? p5: »union«, - # $TEST$ serialization Any + // $TEST$ serialization Any p6: »union«, - # $TEST$ serialization Any + // $TEST$ serialization Any p7: »union«, - # $TEST$ serialization Any? + // $TEST$ serialization Any? p8: »union«, - # $TEST$ serialization union + // $TEST$ serialization union p9: »union«, - # $TEST$ serialization union + // $TEST$ serialization union p10: »union«, - # $TEST$ serialization union + // $TEST$ serialization union p11: »union«, - # $TEST$ serialization union + // $TEST$ serialization union p12: »union«, - # $TEST$ serialization Any + // $TEST$ serialization Any p13: »union«, - # $TEST$ serialization Any? + // $TEST$ serialization Any? p14: »union«, - # $TEST$ serialization Any + // $TEST$ serialization Any p15: »union«, - # $TEST$ serialization Any? + // $TEST$ serialization Any? p16: »union«, ) class TestsInvolvingNothing( - # $TEST$ serialization Any + // $TEST$ serialization Any p1: »union«, - # $TEST$ serialization Any? + // $TEST$ serialization Any? p2: »union«, - # $TEST$ serialization literal<1> + // $TEST$ serialization literal<1> p3: »union, Nothing>«, - # $TEST$ serialization literal<1, null> + // $TEST$ serialization literal<1, null> p4: »union, Nothing?>«, - # $TEST$ serialization () -> () + // $TEST$ serialization () -> () p5: »union<() -> (), Nothing>«, - # $TEST$ serialization union<() -> (), Nothing?> + // $TEST$ serialization union<() -> (), Nothing?> p6: »union<() -> (), Nothing?>«, ) class TestsInvolvingTypeParameters( - # $TEST$ serialization Unbounded + // $TEST$ serialization Unbounded a1: »union«, - # $TEST$ serialization Unbounded + // $TEST$ serialization Unbounded a2: »union«, - # $TEST$ serialization Unbounded? + // $TEST$ serialization Unbounded? a3: »union«, - # $TEST$ serialization Unbounded? + // $TEST$ serialization Unbounded? a4: »union«, - # $TEST$ serialization union + // $TEST$ serialization union a5: »union«, - # $TEST$ serialization union + // $TEST$ serialization union a6: »union«, - # $TEST$ serialization Any? + // $TEST$ serialization Any? a7: »union«, - # $TEST$ serialization Any? + // $TEST$ serialization Any? a8: »union«, - # $TEST$ serialization UpperBound + // $TEST$ serialization UpperBound b1: »union«, - # $TEST$ serialization UpperBound + // $TEST$ serialization UpperBound b2: »union«, - # $TEST$ serialization UpperBound? + // $TEST$ serialization UpperBound? b3: »union«, - # $TEST$ serialization UpperBound? + // $TEST$ serialization UpperBound? b4: »union«, - # $TEST$ serialization union + // $TEST$ serialization union b5: »union«, - # $TEST$ serialization union + // $TEST$ serialization union b6: »union«, - # $TEST$ serialization Number + // $TEST$ serialization Number b7: »union«, - # $TEST$ serialization Number + // $TEST$ serialization Number b8: »union«, - # $TEST$ serialization Number? + // $TEST$ serialization Number? b9: »union«, - # $TEST$ serialization Number? + // $TEST$ serialization Number? b10: »union«, - # $TEST$ serialization Any? + // $TEST$ serialization Any? b11: »union«, - # $TEST$ serialization Any? + // $TEST$ serialization Any? b12: »union«, ) diff --git a/packages/ttsl-lang/tests/resources/typing/simplification/replace empty literal types with Nothing/main.sdstest b/packages/ttsl-lang/tests/resources/typing/simplification/replace empty literal types with Nothing/main.sdstest index 78accc9e..01740bae 100644 --- a/packages/ttsl-lang/tests/resources/typing/simplification/replace empty literal types with Nothing/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/simplification/replace empty literal types with Nothing/main.sdstest @@ -1,6 +1,6 @@ package tests.typing.simplification.replaceEmptyLiteralTypesWithNothing class C( - # $TEST$ serialization Nothing + // $TEST$ serialization Nothing p1: »literal<>« ) diff --git a/packages/ttsl-lang/tests/resources/typing/simplification/replace empty union types with Nothing/main.sdstest b/packages/ttsl-lang/tests/resources/typing/simplification/replace empty union types with Nothing/main.sdstest index 02203b85..f556c923 100644 --- a/packages/ttsl-lang/tests/resources/typing/simplification/replace empty union types with Nothing/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/simplification/replace empty union types with Nothing/main.sdstest @@ -1,6 +1,6 @@ package tests.typing.simplification.replaceEmptyUnionTypesWithNothing class C( - # $TEST$ serialization Nothing + // $TEST$ serialization Nothing p1: »union<>« ) diff --git a/packages/ttsl-lang/tests/resources/typing/simplification/replace literals types that allow only null with NothingOrNull/main.sdstest b/packages/ttsl-lang/tests/resources/typing/simplification/replace literals types that allow only null with NothingOrNull/main.sdstest index 2c0e822f..b52fa6af 100644 --- a/packages/ttsl-lang/tests/resources/typing/simplification/replace literals types that allow only null with NothingOrNull/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/simplification/replace literals types that allow only null with NothingOrNull/main.sdstest @@ -1,9 +1,9 @@ package tests.typing.simplification.replaceLiteralTypesThatAllowOnlyNullWithNothingOrNull class C( - # $TEST$ serialization Nothing? + // $TEST$ serialization Nothing? p1: »literal«, - # $TEST$ serialization Nothing? + // $TEST$ serialization Nothing? p2: »literal« ) diff --git a/packages/ttsl-lang/tests/resources/typing/simplification/unwrap/main.sdstest b/packages/ttsl-lang/tests/resources/typing/simplification/unwrap/main.sdstest index 24d7c621..45ad15cb 100644 --- a/packages/ttsl-lang/tests/resources/typing/simplification/unwrap/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/simplification/unwrap/main.sdstest @@ -1,10 +1,10 @@ package tests.typing.simplification.unwrap segment callableType( - # $TEST$ serialization () -> () + // $TEST$ serialization () -> () f1: »() -> ()«, - # $TEST$ serialization (p: String) -> (r: String) + // $TEST$ serialization (p: String) -> (r: String) f2: »(p: union>) -> (r: union>)« ) {} @@ -13,34 +13,34 @@ segment namedTupleType( f2: () -> (r: String), f3: () -> (r1: union>, r2: union>) ) { - # $TEST$ serialization () + // $TEST$ serialization () »f1()«; - # $TEST$ serialization String + // $TEST$ serialization String »f2()«; - # $TEST$ serialization (r1: String, r2: String) + // $TEST$ serialization (r1: String, r2: String) »f3()«; } segment classType( - # $TEST$ serialization String + // $TEST$ serialization String p1: »String«, - # $TEST$ serialization List + // $TEST$ serialization List p2: »List«, - # $TEST$ serialization List + // $TEST$ serialization List p3: »List>>«, ) {} segment unionType( - # $TEST$ serialization String + // $TEST$ serialization String p1: »union«, - # $TEST$ serialization String + // $TEST$ serialization String p2: »union>«, - # $TEST$ serialization union + // $TEST$ serialization union p3: »union, Boolean>«, ) {} diff --git a/packages/ttsl-lang/tests/resources/typing/types/callable types/main.sdstest b/packages/ttsl-lang/tests/resources/typing/types/callable types/main.sdstest index a991a982..da9f77e1 100644 --- a/packages/ttsl-lang/tests/resources/typing/types/callable types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/types/callable types/main.sdstest @@ -1,16 +1,16 @@ package tests.typing.types.callableTypes -# $TEST$ serialization () -> () +// $TEST$ serialization () -> () fun myFunction1(f: »() -> ()«) -# $TEST$ serialization () -> (r1: Int, r2: String) +// $TEST$ serialization () -> (r1: Int, r2: String) fun myFunction2(f: »() -> (r1: Int, r2: String)«) -# $TEST$ serialization (p1: Int, p2: String) -> () +// $TEST$ serialization (p1: Int, p2: String) -> () fun myFunction3(f: »(p1: Int, p2: String) -> ()«) -# $TEST$ serialization (p1: Int, p2: String) -> (r1: Int, r2: String) +// $TEST$ serialization (p1: Int, p2: String) -> (r1: Int, r2: String) fun myFunction4(f: »(p1: Int, p2: String) -> (r1: Int, r2: String)«) -# $TEST$ serialization (p1: $unknown) -> (r1: $unknown) +// $TEST$ serialization (p1: $unknown) -> (r1: $unknown) fun myFunction5(f: »(p1) -> (r1)«) diff --git a/packages/ttsl-lang/tests/resources/typing/types/literal types/main.sdstest b/packages/ttsl-lang/tests/resources/typing/types/literal types/main.sdstest index a0622293..4adb84d6 100644 --- a/packages/ttsl-lang/tests/resources/typing/types/literal types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/types/literal types/main.sdstest @@ -1,10 +1,10 @@ package tests.typing.types.literalTypes -# $TEST$ serialization Nothing +// $TEST$ serialization Nothing fun myFunction1(f: »literal<>«) -# $TEST$ serialization literal<1, 2> +// $TEST$ serialization literal<1, 2> fun myFunction2(f: »literal<1, 2>«) -# $TEST$ serialization literal<1, ""> +// $TEST$ serialization literal<1, ""> fun myFunction3(f: »literal<1, "">«) diff --git a/packages/ttsl-lang/tests/resources/typing/types/member types/main.sdstest b/packages/ttsl-lang/tests/resources/typing/types/member types/main.sdstest index c53fc9cc..e90431a0 100644 --- a/packages/ttsl-lang/tests/resources/typing/types/member types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/types/member types/main.sdstest @@ -1,36 +1,36 @@ package tests.typing.types.memberTypes class MyClass { - # $TEST$ equivalence_class myNestedClass + // $TEST$ equivalence_class myNestedClass class »MyNestedClass« - # $TEST$ equivalence_class myNestedEnum + // $TEST$ equivalence_class myNestedEnum enum »MyNestedEnum« } enum MyEnum { - # $TEST$ equivalence_class myEnumVariant + // $TEST$ equivalence_class myEnumVariant »MyEnumVariant« } fun nonNullableMemberTypes( - # $TEST$ equivalence_class myNestedClass + // $TEST$ equivalence_class myNestedClass a: »MyClass.MyNestedClass«, - # $TEST$ equivalence_class myNestedEnum + // $TEST$ equivalence_class myNestedEnum b: »MyClass.MyNestedEnum«, - # $TEST$ equivalence_class myEnumVariant + // $TEST$ equivalence_class myEnumVariant d: »MyEnum.MyEnumVariant«, - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown e: »MyEnum.unresolved«, ) fun nullableMemberTypes( - # $TEST$ serialization MyNestedClass? + // $TEST$ serialization MyNestedClass? a: »MyClass.MyNestedClass?«, - # $TEST$ serialization MyNestedEnum? + // $TEST$ serialization MyNestedEnum? b: »MyClass.MyNestedEnum?«, - # $TEST$ serialization MyEnum.MyEnumVariant? + // $TEST$ serialization MyEnum.MyEnumVariant? d: »MyEnum.MyEnumVariant?«, - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown e: »MyEnum.unresolved?«, ) diff --git a/packages/ttsl-lang/tests/resources/typing/types/named types/main.sdstest b/packages/ttsl-lang/tests/resources/typing/types/named types/main.sdstest index 5d0d5b3d..a8863f83 100644 --- a/packages/ttsl-lang/tests/resources/typing/types/named types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/types/named types/main.sdstest @@ -5,19 +5,19 @@ class MyClass enum MyEnum fun nonNullableNamedTypes( - # $TEST$ serialization MyClass + // $TEST$ serialization MyClass a: »MyClass«, - # $TEST$ serialization MyEnum + // $TEST$ serialization MyEnum b: »MyEnum«, - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown c: »unresolved«, ) fun nullableNamedTypes( - # $TEST$ serialization MyClass? + // $TEST$ serialization MyClass? a: »MyClass?«, - # $TEST$ serialization MyEnum? + // $TEST$ serialization MyEnum? b: »MyEnum?«, - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown c: »unresolved?«, ) diff --git a/packages/ttsl-lang/tests/resources/typing/types/named types/with type parameters.sdstest b/packages/ttsl-lang/tests/resources/typing/types/named types/with type parameters.sdstest index a5ef1bc4..05cd2dd7 100644 --- a/packages/ttsl-lang/tests/resources/typing/types/named types/with type parameters.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/types/named types/with type parameters.sdstest @@ -4,33 +4,33 @@ class MyClass2 class MyClass3 fun nonNullableNamedTypes( - # $TEST$ serialization MyClass2 + // $TEST$ serialization MyClass2 a: »MyClass2«, - # $TEST$ serialization MyClass2<$unknown> + // $TEST$ serialization MyClass2<$unknown> b: »MyClass2«, - # $TEST$ serialization MyClass2<$unknown> + // $TEST$ serialization MyClass2<$unknown> c: »MyClass2«, - # $TEST$ serialization MyClass2 + // $TEST$ serialization MyClass2 d: »MyClass2«, - # $TEST$ serialization MyClass3 + // $TEST$ serialization MyClass3 y: »MyClass3«, - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown z: »unresolved«, ) fun nullableNamedTypes( - # $TEST$ serialization MyClass2? + // $TEST$ serialization MyClass2? a: »MyClass2?«, - # $TEST$ serialization MyClass2<$unknown>? + // $TEST$ serialization MyClass2<$unknown>? b: »MyClass2?«, - # $TEST$ serialization MyClass2<$unknown>? + // $TEST$ serialization MyClass2<$unknown>? c: »MyClass2?«, - # $TEST$ serialization MyClass2? + // $TEST$ serialization MyClass2? d: »MyClass2?«, - # $TEST$ serialization MyClass3? + // $TEST$ serialization MyClass3? y: »MyClass3?«, - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown z: »unresolved?«, ) diff --git a/packages/ttsl-lang/tests/resources/typing/types/type arguments/main.sdstest b/packages/ttsl-lang/tests/resources/typing/types/type arguments/main.sdstest index d0685d09..0f6b3c21 100644 --- a/packages/ttsl-lang/tests/resources/typing/types/type arguments/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/types/type arguments/main.sdstest @@ -3,18 +3,18 @@ package tests.typing.types.typeArguments class MyClass fun myFunction( - # $TEST$ serialization Int + // $TEST$ serialization Int a: MyClass<»Int«>, - # $TEST$ serialization Int + // $TEST$ serialization Int b: MyClass<»T = Int«>, - # $TEST$ serialization Boolean + // $TEST$ serialization Boolean e: unresolved<»Boolean«>, - # $TEST$ serialization Boolean + // $TEST$ serialization Boolean f: unresolved<»T = Boolean«>, - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown g: MyClass<»unresolved«>, - # $TEST$ serialization $unknown + // $TEST$ serialization $unknown h: MyClass<»T = unresolved«>, ) diff --git a/packages/ttsl-lang/tests/resources/typing/types/union types/main.sdstest b/packages/ttsl-lang/tests/resources/typing/types/union types/main.sdstest index 4e41c6bc..12ed6e73 100644 --- a/packages/ttsl-lang/tests/resources/typing/types/union types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/types/union types/main.sdstest @@ -1,7 +1,7 @@ package tests.typing.types.unionTypes -# $TEST$ serialization Nothing +// $TEST$ serialization Nothing fun myFunction(a: »union<>«) -# $TEST$ serialization union +// $TEST$ serialization union fun myFunction(a: »union«) diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/assigned result/main.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/assigned result/main.sdstest index 6ec94a14..f4cc1bd1 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/assigned result/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/assigned result/main.sdstest @@ -6,25 +6,25 @@ fun myFunction() -> ( ) segment mySegment() -> (result1: Int, result2: Int, result3: Int) { - # $TEST$ warning "The assigned result 'deprecatedResult' is deprecated." - # $TEST$ no warning r"The assigned result '\w*' is deprecated\." - # $TEST$ no warning r"The assigned result '\w*' is deprecated\." + // $TEST$ warning "The assigned result 'deprecatedResult' is deprecated." + // $TEST$ no warning r"The assigned result '\w*' is deprecated\." + // $TEST$ no warning r"The assigned result '\w*' is deprecated\." »val a«, »val b«, »val c« = myFunction(); - # $TEST$ warning "The assigned result 'deprecatedResult' is deprecated." - # $TEST$ no warning r"The assigned result '\w*' is deprecated\." - # $TEST$ no warning r"The assigned result '\w*' is deprecated\." + // $TEST$ warning "The assigned result 'deprecatedResult' is deprecated." + // $TEST$ no warning r"The assigned result '\w*' is deprecated\." + // $TEST$ no warning r"The assigned result '\w*' is deprecated\." »yield result1«, »yield result2«, »yield result3« = myFunction(); - # $TEST$ no warning r"The assigned result '\w*' is deprecated\." - # $TEST$ no warning r"The assigned result '\w*' is deprecated\." - # $TEST$ no warning r"The assigned result '\w*' is deprecated\." + // $TEST$ no warning r"The assigned result '\w*' is deprecated\." + // $TEST$ no warning r"The assigned result '\w*' is deprecated\." + // $TEST$ no warning r"The assigned result '\w*' is deprecated\." »_«, »_«, »_« = myFunction(); - # $TEST$ no warning r"The assigned result '\w*' is deprecated\." + // $TEST$ no warning r"The assigned result '\w*' is deprecated\." »val d« = a; - # $TEST$ no warning r"The assigned result '\w*' is deprecated\." + // $TEST$ no warning r"The assigned result '\w*' is deprecated\." »val e« = b; - # $TEST$ no warning r"The assigned result '\w*' is deprecated\." + // $TEST$ no warning r"The assigned result '\w*' is deprecated\." »val f« = 1; } diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/called annotation/main.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/called annotation/main.sdstest index b3a60e3e..c7ac37d1 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/called annotation/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/called annotation/main.sdstest @@ -4,10 +4,10 @@ package tests.validation.builtins.deprecated.calledAnnotation annotation DeprecatedAnnotation annotation ValidAnnotation -# $TEST$ warning "The called annotation 'DeprecatedAnnotation' is deprecated." +// $TEST$ warning "The called annotation 'DeprecatedAnnotation' is deprecated." @»DeprecatedAnnotation« -# $TEST$ no warning r"The called annotation '\w*' is deprecated\." +// $TEST$ no warning r"The called annotation '\w*' is deprecated\." @»ValidAnnotation« -# $TEST$ no warning r"The called annotation '\w*' is deprecated\." +// $TEST$ no warning r"The called annotation '\w*' is deprecated\." @»Unresolved« pipeline myPipeline {} diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/corresponding parameter/main.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/corresponding parameter/main.sdstest index 846680f4..752ebb63 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/corresponding parameter/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/corresponding parameter/main.sdstest @@ -7,20 +7,20 @@ fun f( pipeline myPipeline { f( - # $TEST$ warning "The corresponding parameter 'deprecatedParameter' is deprecated." + // $TEST$ warning "The corresponding parameter 'deprecatedParameter' is deprecated." »deprecatedParameter = 1«, - # $TEST$ no warning r"The corresponding parameter '\w*' is deprecated\." + // $TEST$ no warning r"The corresponding parameter '\w*' is deprecated\." »validParameter = 1«, - # $TEST$ no warning r"The corresponding parameter '\w*' is deprecated\." + // $TEST$ no warning r"The corresponding parameter '\w*' is deprecated\." »unresolved = 1«, ); f( - # $TEST$ warning "The corresponding parameter 'deprecatedParameter' is deprecated." + // $TEST$ warning "The corresponding parameter 'deprecatedParameter' is deprecated." »1«, - # $TEST$ no warning r"The corresponding parameter '\w*' is deprecated\." + // $TEST$ no warning r"The corresponding parameter '\w*' is deprecated\." »1«, - # $TEST$ no warning r"The corresponding parameter '\w*' is deprecated\." + // $TEST$ no warning r"The corresponding parameter '\w*' is deprecated\." »1«, ); } diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/must not be used on required parameters/main.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/must not be used on required parameters/main.sdstest index 395606fb..201f9c0c 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/must not be used on required parameters/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/must not be used on required parameters/main.sdstest @@ -1,48 +1,48 @@ package tests.validation.builtins.deprecated.mustNotBeUsedOnRequiredParameters -# $TEST$ error "A deprecated parameter must be optional." -# $TEST$ no error "A deprecated parameter must be optional." +// $TEST$ error "A deprecated parameter must be optional." +// $TEST$ no error "A deprecated parameter must be optional." annotation MyAnnotation(@Deprecated »a«: Int, @Deprecated »b«: Int = 3) -# $TEST$ error "A deprecated parameter must be optional." -# $TEST$ no error "A deprecated parameter must be optional." +// $TEST$ error "A deprecated parameter must be optional." +// $TEST$ no error "A deprecated parameter must be optional." class MyClass(@Deprecated »a«: Int, @Deprecated »b«: Int = 3) { - # $TEST$ error "A deprecated parameter must be optional." - # $TEST$ no error "A deprecated parameter must be optional." + // $TEST$ error "A deprecated parameter must be optional." + // $TEST$ no error "A deprecated parameter must be optional." class MyClass(@Deprecated »a«: Int, @Deprecated »b«: Int = 3) - # $TEST$ error "A deprecated parameter must be optional." - # $TEST$ no error "A deprecated parameter must be optional." + // $TEST$ error "A deprecated parameter must be optional." + // $TEST$ no error "A deprecated parameter must be optional." fun myFunction(@Deprecated »a«: Int, @Deprecated »b«: Int = 3) } enum MyEnum { - # $TEST$ error "A deprecated parameter must be optional." - # $TEST$ no error "A deprecated parameter must be optional." + // $TEST$ error "A deprecated parameter must be optional." + // $TEST$ no error "A deprecated parameter must be optional." MyEnumVariant(@Deprecated »a«: Int, @Deprecated »b«: Int = 3) } -# $TEST$ error "A deprecated parameter must be optional." -# $TEST$ no error "A deprecated parameter must be optional." +// $TEST$ error "A deprecated parameter must be optional." +// $TEST$ no error "A deprecated parameter must be optional." fun myFunction(@Deprecated »a«: Int, @Deprecated »b«: Int = 3) -# $TEST$ error "A deprecated parameter must be optional." -# $TEST$ no error "A deprecated parameter must be optional." +// $TEST$ error "A deprecated parameter must be optional." +// $TEST$ no error "A deprecated parameter must be optional." segment mySegment1(@Deprecated »a«: Int, @Deprecated »b«: Int = 3) {} -# $TEST$ no error "A deprecated parameter must be optional." -# $TEST$ no error "A deprecated parameter must be optional." +// $TEST$ no error "A deprecated parameter must be optional." +// $TEST$ no error "A deprecated parameter must be optional." segment mySegment2( f: (@Deprecated »a«: Int, @Deprecated »b«: Int = 3) -> () ) { - # $TEST$ no error "A deprecated parameter must be optional." - # $TEST$ no error "A deprecated parameter must be optional." + // $TEST$ no error "A deprecated parameter must be optional." + // $TEST$ no error "A deprecated parameter must be optional." val g = (@Deprecated »a«: Int, @Deprecated »b«: Int = 3) {}; - # $TEST$ no error "A deprecated parameter must be optional." - # $TEST$ no error "A deprecated parameter must be optional." + // $TEST$ no error "A deprecated parameter must be optional." + // $TEST$ no error "A deprecated parameter must be optional." val h = (@Deprecated »a«: Int, @Deprecated »b«: Int = 3) -> 1; } diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/referenced declaration/from named type/main.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/referenced declaration/from named type/main.sdstest index 6f2d798d..8de79583 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/referenced declaration/from named type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/referenced declaration/from named type/main.sdstest @@ -12,21 +12,21 @@ enum ValidEnum { } segment mySegment( - # $TEST$ warning "The referenced declaration 'DeprecatedClass' is deprecated." + // $TEST$ warning "The referenced declaration 'DeprecatedClass' is deprecated." p1: »DeprecatedClass«, - # $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." + // $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." p2: »ValidClass«, - # $TEST$ warning "The referenced declaration 'DeprecatedEnum' is deprecated." + // $TEST$ warning "The referenced declaration 'DeprecatedEnum' is deprecated." p3: »DeprecatedEnum«, - # $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." + // $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." p4: »ValidEnum«, - # $TEST$ warning "The referenced declaration 'DeprecatedEnumVariant' is deprecated." + // $TEST$ warning "The referenced declaration 'DeprecatedEnumVariant' is deprecated." p5: ValidEnum.»DeprecatedEnumVariant«, - # $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." + // $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." p6: ValidEnum.»ValidEnumVariant«, - # $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." + // $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." p7: »Unresolved« ) {} diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/referenced declaration/from reference/main.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/referenced declaration/from reference/main.sdstest index 1be35303..71a50203 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/referenced declaration/from reference/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/referenced declaration/from reference/main.sdstest @@ -41,56 +41,56 @@ segment mySegment( * Deprecation is only relevant for callers */ - # $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." + // $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." »deprecatedParameter«; - # $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." + // $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." »validParameter«; - # $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." + // $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." yield »deprecatedResult« = 1; - # $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." + // $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." yield »validResult« = 1; - # $TEST$ warning "The referenced declaration 'DeprecatedClass' is deprecated." + // $TEST$ warning "The referenced declaration 'DeprecatedClass' is deprecated." »DeprecatedClass«; - # $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." + // $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." »ValidClass«; - # $TEST$ warning "The referenced declaration 'deprecatedAttribute' is deprecated." + // $TEST$ warning "The referenced declaration 'deprecatedAttribute' is deprecated." ValidClass.»deprecatedAttribute«; - # $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." + // $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." ValidClass.»validAttribute«; - # $TEST$ warning "The referenced declaration 'DeprecatedEnum' is deprecated." + // $TEST$ warning "The referenced declaration 'DeprecatedEnum' is deprecated." »DeprecatedEnum«; - # $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." + // $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." »ValidEnum«; - # $TEST$ warning "The referenced declaration 'DeprecatedEnumVariant' is deprecated." + // $TEST$ warning "The referenced declaration 'DeprecatedEnumVariant' is deprecated." ValidEnum.»DeprecatedEnumVariant«; - # $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." + // $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." ValidEnum.»ValidEnumVariant«; - # $TEST$ warning "The referenced declaration 'deprecatedFunction' is deprecated." + // $TEST$ warning "The referenced declaration 'deprecatedFunction' is deprecated." »deprecatedFunction«(); - # $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." + // $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." »validFunction«(); - # $TEST$ warning "The referenced declaration 'deprecatedResult' is deprecated." + // $TEST$ warning "The referenced declaration 'deprecatedResult' is deprecated." validFunction().»deprecatedResult«; - # $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." + // $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." validFunction().»validResult«; - # $TEST$ warning "The referenced declaration 'deprecatedSegment' is deprecated." + // $TEST$ warning "The referenced declaration 'deprecatedSegment' is deprecated." »deprecatedSegment«(); - # $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." + // $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." »validSegment«(); - # $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." + // $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." »unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/assigned result/main.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/assigned result/main.sdstest index 99e1b4c8..97c2171c 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/assigned result/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/assigned result/main.sdstest @@ -6,25 +6,25 @@ fun myFunction() -> ( ) segment mySegment() -> (result1: Int, result2: Int, result3: Int) { - # $TEST$ warning "The assigned result 'experimentalResult' is experimental." - # $TEST$ no warning r"The assigned result '\w*' is experimental\." - # $TEST$ no warning r"The assigned result '\w*' is experimental\." + // $TEST$ warning "The assigned result 'experimentalResult' is experimental." + // $TEST$ no warning r"The assigned result '\w*' is experimental\." + // $TEST$ no warning r"The assigned result '\w*' is experimental\." »val a«, »val b«, »val c« = myFunction(); - # $TEST$ warning "The assigned result 'experimentalResult' is experimental." - # $TEST$ no warning r"The assigned result '\w*' is experimental\." - # $TEST$ no warning r"The assigned result '\w*' is experimental\." + // $TEST$ warning "The assigned result 'experimentalResult' is experimental." + // $TEST$ no warning r"The assigned result '\w*' is experimental\." + // $TEST$ no warning r"The assigned result '\w*' is experimental\." »yield result1«, »yield result2«, »yield result3« = myFunction(); - # $TEST$ no warning r"The assigned result '\w*' is experimental\." - # $TEST$ no warning r"The assigned result '\w*' is experimental\." - # $TEST$ no warning r"The assigned result '\w*' is experimental\." + // $TEST$ no warning r"The assigned result '\w*' is experimental\." + // $TEST$ no warning r"The assigned result '\w*' is experimental\." + // $TEST$ no warning r"The assigned result '\w*' is experimental\." »_«, »_«, »_« = myFunction(); - # $TEST$ no warning r"The assigned result '\w*' is experimental\." + // $TEST$ no warning r"The assigned result '\w*' is experimental\." »val d« = a; - # $TEST$ no warning r"The assigned result '\w*' is experimental\." + // $TEST$ no warning r"The assigned result '\w*' is experimental\." »val e« = b; - # $TEST$ no warning r"The assigned result '\w*' is experimental\." + // $TEST$ no warning r"The assigned result '\w*' is experimental\." »val f« = 1; } diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/called annotation/main.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/called annotation/main.sdstest index 7413bb0e..3792aada 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/called annotation/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/called annotation/main.sdstest @@ -4,10 +4,10 @@ package tests.validation.builtins.experimental.calledAnnotation annotation ExperimentalAnnotation annotation ValidAnnotation -# $TEST$ warning "The called annotation 'ExperimentalAnnotation' is experimental." +// $TEST$ warning "The called annotation 'ExperimentalAnnotation' is experimental." @»ExperimentalAnnotation« -# $TEST$ no warning r"The called annotation '\w*' is experimental\." +// $TEST$ no warning r"The called annotation '\w*' is experimental\." @»ValidAnnotation« -# $TEST$ no warning r"The called annotation '\w*' is experimental\." +// $TEST$ no warning r"The called annotation '\w*' is experimental\." @»Unresolved« pipeline myPipeline {} diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/corresponding parameter/main.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/corresponding parameter/main.sdstest index 623ec92b..ba5934cf 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/corresponding parameter/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/corresponding parameter/main.sdstest @@ -7,20 +7,20 @@ fun f( pipeline myPipeline { f( - # $TEST$ warning "The corresponding parameter 'experimentalParameter' is experimental." + // $TEST$ warning "The corresponding parameter 'experimentalParameter' is experimental." »experimentalParameter = 1«, - # $TEST$ no warning r"The corresponding parameter '\w*' is experimental\." + // $TEST$ no warning r"The corresponding parameter '\w*' is experimental\." »validParameter = 1«, - # $TEST$ no warning r"The corresponding parameter '\w*' is experimental\." + // $TEST$ no warning r"The corresponding parameter '\w*' is experimental\." »unresolved = 1«, ); f( - # $TEST$ warning "The corresponding parameter 'experimentalParameter' is experimental." + // $TEST$ warning "The corresponding parameter 'experimentalParameter' is experimental." »1«, - # $TEST$ no warning r"The corresponding parameter '\w*' is experimental\." + // $TEST$ no warning r"The corresponding parameter '\w*' is experimental\." »1«, - # $TEST$ no warning r"The corresponding parameter '\w*' is experimental\." + // $TEST$ no warning r"The corresponding parameter '\w*' is experimental\." »1«, ); } diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/referenced declaration/from named type/main.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/referenced declaration/from named type/main.sdstest index 4e3671ca..b2be9f45 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/referenced declaration/from named type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/referenced declaration/from named type/main.sdstest @@ -12,21 +12,21 @@ enum ValidEnum { } segment mySegment( - # $TEST$ warning "The referenced declaration 'ExperimentalClass' is experimental." + // $TEST$ warning "The referenced declaration 'ExperimentalClass' is experimental." p1: »ExperimentalClass«, - # $TEST$ no warning r"The referenced declaration '\w*' is experimental\." + // $TEST$ no warning r"The referenced declaration '\w*' is experimental\." p2: »ValidClass«, - # $TEST$ warning "The referenced declaration 'ExperimentalEnum' is experimental." + // $TEST$ warning "The referenced declaration 'ExperimentalEnum' is experimental." p3: »ExperimentalEnum«, - # $TEST$ no warning r"The referenced declaration '\w*' is experimental\." + // $TEST$ no warning r"The referenced declaration '\w*' is experimental\." p4: »ValidEnum«, - # $TEST$ warning "The referenced declaration 'ExperimentalEnumVariant' is experimental." + // $TEST$ warning "The referenced declaration 'ExperimentalEnumVariant' is experimental." p5: ValidEnum.»ExperimentalEnumVariant«, - # $TEST$ no warning r"The referenced declaration '\w*' is experimental\." + // $TEST$ no warning r"The referenced declaration '\w*' is experimental\." p6: ValidEnum.»ValidEnumVariant«, - # $TEST$ no warning r"The referenced declaration '\w*' is experimental\." + // $TEST$ no warning r"The referenced declaration '\w*' is experimental\." p7: »Unresolved« ) {} diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/referenced declaration/from reference/main.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/referenced declaration/from reference/main.sdstest index e055945c..10745a35 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/referenced declaration/from reference/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/referenced declaration/from reference/main.sdstest @@ -41,56 +41,56 @@ segment mySegment( * Deprecation is only relevant for callers */ - # $TEST$ no warning r"The referenced declaration '\w*' is experimental\." + // $TEST$ no warning r"The referenced declaration '\w*' is experimental\." »experimentalParameter«; - # $TEST$ no warning r"The referenced declaration '\w*' is experimental\." + // $TEST$ no warning r"The referenced declaration '\w*' is experimental\." »validParameter«; - # $TEST$ no warning r"The referenced declaration '\w*' is experimental\." + // $TEST$ no warning r"The referenced declaration '\w*' is experimental\." yield »experimentalResult« = 1; - # $TEST$ no warning r"The referenced declaration '\w*' is experimental\." + // $TEST$ no warning r"The referenced declaration '\w*' is experimental\." yield »validResult« = 1; - # $TEST$ warning "The referenced declaration 'ExperimentalClass' is experimental." + // $TEST$ warning "The referenced declaration 'ExperimentalClass' is experimental." »ExperimentalClass«; - # $TEST$ no warning r"The referenced declaration '\w*' is experimental\." + // $TEST$ no warning r"The referenced declaration '\w*' is experimental\." »ValidClass«; - # $TEST$ warning "The referenced declaration 'experimentalAttribute' is experimental." + // $TEST$ warning "The referenced declaration 'experimentalAttribute' is experimental." ValidClass.»experimentalAttribute«; - # $TEST$ no warning r"The referenced declaration '\w*' is experimental\." + // $TEST$ no warning r"The referenced declaration '\w*' is experimental\." ValidClass.»validAttribute«; - # $TEST$ warning "The referenced declaration 'ExperimentalEnum' is experimental." + // $TEST$ warning "The referenced declaration 'ExperimentalEnum' is experimental." »ExperimentalEnum«; - # $TEST$ no warning r"The referenced declaration '\w*' is experimental\." + // $TEST$ no warning r"The referenced declaration '\w*' is experimental\." »ValidEnum«; - # $TEST$ warning "The referenced declaration 'ExperimentalEnumVariant' is experimental." + // $TEST$ warning "The referenced declaration 'ExperimentalEnumVariant' is experimental." ValidEnum.»ExperimentalEnumVariant«; - # $TEST$ no warning r"The referenced declaration '\w*' is experimental\." + // $TEST$ no warning r"The referenced declaration '\w*' is experimental\." ValidEnum.»ValidEnumVariant«; - # $TEST$ warning "The referenced declaration 'experimentalFunction' is experimental." + // $TEST$ warning "The referenced declaration 'experimentalFunction' is experimental." »experimentalFunction«(); - # $TEST$ no warning r"The referenced declaration '\w*' is experimental\." + // $TEST$ no warning r"The referenced declaration '\w*' is experimental\." »validFunction«(); - # $TEST$ warning "The referenced declaration 'experimentalResult' is experimental." + // $TEST$ warning "The referenced declaration 'experimentalResult' is experimental." validFunction().»experimentalResult«; - # $TEST$ no warning r"The referenced declaration '\w*' is experimental\." + // $TEST$ no warning r"The referenced declaration '\w*' is experimental\." validFunction().»validResult«; - # $TEST$ warning "The referenced declaration 'experimentalSegment' is experimental." + // $TEST$ warning "The referenced declaration 'experimentalSegment' is experimental." »experimentalSegment«(); - # $TEST$ no warning r"The referenced declaration '\w*' is experimental\." + // $TEST$ no warning r"The referenced declaration '\w*' is experimental\." »validSegment«(); - # $TEST$ no warning r"The referenced declaration '\w*' is experimental\." + // $TEST$ no warning r"The referenced declaration '\w*' is experimental\." »unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/expert/must not be used on required parameters/main.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/expert/must not be used on required parameters/main.sdstest index a543e272..9fe2d13d 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/expert/must not be used on required parameters/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/expert/must not be used on required parameters/main.sdstest @@ -1,48 +1,48 @@ package tests.validation.builtins.expert.mustNotBeUsedOnRequiredParameters -# $TEST$ error "An expert parameter must be optional." -# $TEST$ no error "An expert parameter must be optional." +// $TEST$ error "An expert parameter must be optional." +// $TEST$ no error "An expert parameter must be optional." annotation MyAnnotation(@Expert »a«: Int, @Expert »b«: Int = 3) -# $TEST$ error "An expert parameter must be optional." -# $TEST$ no error "An expert parameter must be optional." +// $TEST$ error "An expert parameter must be optional." +// $TEST$ no error "An expert parameter must be optional." class MyClass(@Expert »a«: Int, @Expert »b«: Int = 3) { - # $TEST$ error "An expert parameter must be optional." - # $TEST$ no error "An expert parameter must be optional." + // $TEST$ error "An expert parameter must be optional." + // $TEST$ no error "An expert parameter must be optional." class MyClass(@Expert »a«: Int, @Expert »b«: Int = 3) - # $TEST$ error "An expert parameter must be optional." - # $TEST$ no error "An expert parameter must be optional." + // $TEST$ error "An expert parameter must be optional." + // $TEST$ no error "An expert parameter must be optional." fun myFunction(@Expert »a«: Int, @Expert »b«: Int = 3) } enum MyEnum { - # $TEST$ error "An expert parameter must be optional." - # $TEST$ no error "An expert parameter must be optional." + // $TEST$ error "An expert parameter must be optional." + // $TEST$ no error "An expert parameter must be optional." MyEnumVariant(@Expert »a«: Int, @Expert »b«: Int = 3) } -# $TEST$ error "An expert parameter must be optional." -# $TEST$ no error "An expert parameter must be optional." +// $TEST$ error "An expert parameter must be optional." +// $TEST$ no error "An expert parameter must be optional." fun myFunction(@Expert »a«: Int, @Expert »b«: Int = 3) -# $TEST$ error "An expert parameter must be optional." -# $TEST$ no error "An expert parameter must be optional." +// $TEST$ error "An expert parameter must be optional." +// $TEST$ no error "An expert parameter must be optional." segment mySegment1(@Expert »a«: Int, @Expert »b«: Int = 3) {} -# $TEST$ no error "An expert parameter must be optional." -# $TEST$ no error "An expert parameter must be optional." +// $TEST$ no error "An expert parameter must be optional." +// $TEST$ no error "An expert parameter must be optional." segment mySegment2( f: (@Expert »a«: Int, @Expert »b«: Int = 3) -> () ) { - # $TEST$ no error "An expert parameter must be optional." - # $TEST$ no error "An expert parameter must be optional." + // $TEST$ no error "An expert parameter must be optional." + // $TEST$ no error "An expert parameter must be optional." val g = (@Expert »a«: Int, @Expert »b«: Int = 3) {}; - # $TEST$ no error "An expert parameter must be optional." - # $TEST$ no error "An expert parameter must be optional." + // $TEST$ no error "An expert parameter must be optional." + // $TEST$ no error "An expert parameter must be optional." val h = (@Expert »a«: Int, @Expert »b«: Int = 3) -> 1; } diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonCall/main.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonCall/main.sdstest index 14395788..80b97dcb 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonCall/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonCall/main.sdstest @@ -1,39 +1,39 @@ package tests.validation.builtins.pythonCall class MyClass { - # $TEST$ no error r"The template expressions? .* cannot be interpreted." + // $TEST$ no error r"The template expressions? .* cannot be interpreted." @»PythonCall«("myMethod1($param)") fun myMethod1(param: Int) - # $TEST$ no error r"The template expressions? .* cannot be interpreted." + // $TEST$ no error r"The template expressions? .* cannot be interpreted." @»PythonCall«("myMethod2($this)") fun myMethod2(this: Int) - # $TEST$ no error "The template expression '$this' cannot be interpreted." + // $TEST$ no error "The template expression '$this' cannot be interpreted." @»PythonCall«("myMethod3($this)") fun myMethod3() - # $TEST$ error "The template expressions '$param1', '$param2' cannot be interpreted." + // $TEST$ error "The template expressions '$param1', '$param2' cannot be interpreted." @»PythonCall«("myMethod4($param1, $param2)") fun myMethod4() } -# $TEST$ no error r"The template expressions? .* cannot be interpreted." +// $TEST$ no error r"The template expressions? .* cannot be interpreted." @»PythonCall«("myFunction1($param)") fun myFunction1(param: Int) -# $TEST$ no error r"The template expressions? .* cannot be interpreted." +// $TEST$ no error r"The template expressions? .* cannot be interpreted." @»PythonCall«("myFunction2($this)") fun myFunction2(this: Int) -# $TEST$ error "The template expression '$this' cannot be interpreted." +// $TEST$ error "The template expression '$this' cannot be interpreted." @»PythonCall«("myFunction3($this)") fun myFunction3() -# $TEST$ error "The template expressions '$param1', '$param2' cannot be interpreted." +// $TEST$ error "The template expressions '$param1', '$param2' cannot be interpreted." @»PythonCall«("myFunction4($param1, $param2)") fun myFunction4() -# $TEST$ no error "An expert parameter must be optional." +// $TEST$ no error "An expert parameter must be optional." @»PythonCall«("$this") annotation MyAnnotation() diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonModule/error.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonModule/error.sdstest index 3e323ec9..97adb358 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonModule/error.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonModule/error.sdstest @@ -1,4 +1,4 @@ -# $TEST$ info "The Python module is identical to the Safe-DS package, so the annotation call can be removed." +// $TEST$ info "The Python module is identical to the Safe-DS package, so the annotation call can be removed." @»PythonModule«("tests.validation.builtins.annotations.pythonModule") package tests.validation.builtins.annotations.pythonModule diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonModule/no annotation.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonModule/no annotation.sdstest index 4bdb4d13..057e3d85 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonModule/no annotation.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonModule/no annotation.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no info "The Python module is identical to the Safe-DS package, so the annotation call can be removed." +// $TEST$ no info "The Python module is identical to the Safe-DS package, so the annotation call can be removed." package tests.validation.builtins.annotations.pythonModule diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonModule/no error.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonModule/no error.sdstest index 0f978ab4..fa3f4fe9 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonModule/no error.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonModule/no error.sdstest @@ -1,6 +1,6 @@ -# $TEST$ no info "The Python module is identical to the Safe-DS package, so the annotation call can be removed." +// $TEST$ no info "The Python module is identical to the Safe-DS package, so the annotation call can be removed." @»PythonModule«("tests.validation.builtins.annotations.pythonModule.other") -# $TEST$ no info "The Python module is identical to the Safe-DS package, so the annotation call can be removed." +// $TEST$ no info "The Python module is identical to the Safe-DS package, so the annotation call can be removed." @»PythonModule«("tests.validation.builtins.annotations.pythonModule") package tests.validation.builtins.annotations.pythonModule diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonName/identical to safe-ds name/main.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonName/identical to safe-ds name/main.sdstest index 717a97fb..cae7182c 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonName/identical to safe-ds name/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonName/identical to safe-ds name/main.sdstest @@ -1,11 +1,11 @@ package tests.validation.builtins.annotations.pythonName.identicalToSafeDsName -# $TEST$ info "The Python name is identical to the Safe-DS name, so the annotation call can be removed." +// $TEST$ info "The Python name is identical to the Safe-DS name, so the annotation call can be removed." @»PythonName«("TestClass1") class TestClass1 -# $TEST$ no info "The Python name is identical to the Safe-DS name, so the annotation call can be removed." +// $TEST$ no info "The Python name is identical to the Safe-DS name, so the annotation call can be removed." @»PythonName«("Test_Class_2") -# $TEST$ no info "The Python name is identical to the Safe-DS name, so the annotation call can be removed." +// $TEST$ no info "The Python name is identical to the Safe-DS name, so the annotation call can be removed." @»PythonName«("TestClass2") class TestClass2 diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonName/identical to safe-ds name/no annotation.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonName/identical to safe-ds name/no annotation.sdstest index 17bd1b1d..de231603 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonName/identical to safe-ds name/no annotation.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonName/identical to safe-ds name/no annotation.sdstest @@ -1,4 +1,4 @@ package tests.validation.builtins.annotations.pythonName.identicalToSafeDsName -# $TEST$ no info "The Python name is identical to the Safe-DS name, so the annotation call can be removed." +// $TEST$ no info "The Python name is identical to the Safe-DS name, so the annotation call can be removed." class TestClass3 diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonName/mutually exclusive with python call/main.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonName/mutually exclusive with python call/main.sdstest index f30c3d34..23901ea2 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonName/mutually exclusive with python call/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonName/mutually exclusive with python call/main.sdstest @@ -1,26 +1,26 @@ package tests.validation.builtins.annotations.pythonName.mutuallyExclusiveWithPythonCall @PythonCall("myFunction1()") -# $TEST$ error "A Python name must not be set if a Python call is set." +// $TEST$ error "A Python name must not be set if a Python call is set." @»PythonName«("my_function_1") -# $TEST$ no error "A Python name must not be set if a Python call is set." +// $TEST$ no error "A Python name must not be set if a Python call is set." @»PythonName«("my_function_1") fun myFunction1() -# $TEST$ error "A Python name must not be set if a Python call is set." +// $TEST$ error "A Python name must not be set if a Python call is set." @»PythonName«("my_function_2") -# $TEST$ no error "A Python name must not be set if a Python call is set." +// $TEST$ no error "A Python name must not be set if a Python call is set." @»PythonName«("my_function_2") @PythonCall("myFunction2()") fun myFunction2() -# $TEST$ no error "A Python name must not be set if a Python call is set." +// $TEST$ no error "A Python name must not be set if a Python call is set." @»PythonName«("my_function_3") fun myFunction3() -# $TEST$ no error "A Python name must not be set if a Python call is set." +// $TEST$ no error "A Python name must not be set if a Python call is set." @»PythonName«("my_function_2") -# $TEST$ no error "A Python name must not be set if a Python call is set." +// $TEST$ no error "A Python name must not be set if a Python call is set." @»PythonName«("my_function_2") @PythonCall("myFunction2()") class MyClass() diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/repeatable/main.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/repeatable/main.sdstest index 10b91850..ffbe0d36 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/repeatable/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/repeatable/main.sdstest @@ -5,20 +5,20 @@ annotation SingleUse @Repeatable annotation MultiUse -# $TEST$ no error r"The annotation '\w*' is not repeatable\." +// $TEST$ no error r"The annotation '\w*' is not repeatable\." @»SingleUse« -# $TEST$ no error r"The annotation '\w*' is not repeatable\." +// $TEST$ no error r"The annotation '\w*' is not repeatable\." @»MultiUse« -# $TEST$ no error r"The annotation '\w*' is not repeatable\." +// $TEST$ no error r"The annotation '\w*' is not repeatable\." @»MultiUse« -# $TEST$ no error r"The annotation '\w*' is not repeatable\." +// $TEST$ no error r"The annotation '\w*' is not repeatable\." @»UnresolvedAnnotation« -# $TEST$ no error r"The annotation '\w*' is not repeatable\." +// $TEST$ no error r"The annotation '\w*' is not repeatable\." @»UnresolvedAnnotation« class CorrectUse -# $TEST$ no error r"The annotation '\w*' is not repeatable\." +// $TEST$ no error r"The annotation '\w*' is not repeatable\." @»SingleUse« -# $TEST$ error "The annotation 'SingleUse' is not repeatable." +// $TEST$ error "The annotation 'SingleUse' is not repeatable." @»SingleUse« class IncorrectUse diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/target/duplicate target/main.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/target/duplicate target/main.sdstest index a89a21b1..72baa16f 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/target/duplicate target/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/target/duplicate target/main.sdstest @@ -1,7 +1,7 @@ package tests.validation.builtins.annotations.target.duplicateTarget @Target([ - # $TEST$ no warning "The target 'Annotation' was set already." + // $TEST$ no warning "The target 'Annotation' was set already." »AnnotationTarget.Annotation« ]) @@ -10,33 +10,33 @@ package tests.validation.builtins.annotations.target.duplicateTarget */ @Target([ - # $TEST$ no warning "The target 'Annotation' was set already." + // $TEST$ no warning "The target 'Annotation' was set already." »AnnotationTarget.Annotation«, - # $TEST$ no warning "The target 'Annotation' was set already." + // $TEST$ no warning "The target 'Annotation' was set already." »AnnotationTarget.Annotation«, ]) annotation TestAnnotation1 @Target([ - # $TEST$ no warning "The target 'Annotation' was set already." + // $TEST$ no warning "The target 'Annotation' was set already." »AnnotationTarget.Annotation«, - # $TEST$ warning "The target 'Annotation' was set already." + // $TEST$ warning "The target 'Annotation' was set already." »AnnotationTarget.Annotation«, ]) annotation TestAnnotation2 @Target([ - # $TEST$ no warning "The target 'Class' was set already." + // $TEST$ no warning "The target 'Class' was set already." »AnnotationTarget.Class«, - # $TEST$ warning "The target 'Class' was set already." + // $TEST$ warning "The target 'Class' was set already." »AnnotationTarget.Class«, - # $TEST$ warning "The target 'Class' was set already." + // $TEST$ warning "The target 'Class' was set already." »AnnotationTarget.Class«, - # $TEST$ no warning "The target 'Annotation' was set already." + // $TEST$ no warning "The target 'Annotation' was set already." »AnnotationTarget.Annotation«, - # $TEST$ warning "The target 'Annotation' was set already." + // $TEST$ warning "The target 'Annotation' was set already." »AnnotationTarget.Annotation«, - # $TEST$ warning "The target 'Annotation' was set already." + // $TEST$ warning "The target 'Annotation' was set already." »AnnotationTarget.Annotation«, ]) annotation TestAnnotation3 @@ -46,17 +46,17 @@ annotation TestAnnotation3 */ @Target( - # $TEST$ no warning "The target 'Class' was set already." + // $TEST$ no warning "The target 'Class' was set already." »AnnotationTarget.Class«, - # $TEST$ no warning "The target 'Class' was set already." + // $TEST$ no warning "The target 'Class' was set already." »AnnotationTarget.Class« ) annotation TestAnnotation4 @Target([ - # $TEST$ no warning r"The target '.*' was set already\." + // $TEST$ no warning r"The target '.*' was set already\." »1«, - # $TEST$ no warning r"The target '.*' was set already\." + // $TEST$ no warning r"The target '.*' was set already\." »1«, ]) annotation TestAnnotation5 diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/target/duplicate target/no target annotation.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/target/duplicate target/no target annotation.sdstest index 8264ccf4..c23ee214 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/target/duplicate target/no target annotation.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/target/duplicate target/no target annotation.sdstest @@ -1,5 +1,5 @@ package tests.validation.builtins.annotations.target.duplicateTarget -# $TEST$ no warning r"The target '.*' was already set\." +// $TEST$ no warning r"The target '.*' was already set\." annotation TestAnnotation6 diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/target/wrong target/main.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/target/wrong target/main.sdstest index 643571a9..b506ff37 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/target/wrong target/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/target/wrong target/main.sdstest @@ -1,12 +1,12 @@ -# $TEST$ error "The annotation 'AnnotationForEnums' cannot be applied to a module." +// $TEST$ error "The annotation 'AnnotationForEnums' cannot be applied to a module." @»AnnotationForEnums« -# $TEST$ no error r"This annotation '.*' cannot be applied to .*" +// $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForModules« -# $TEST$ no error r"This annotation '.*' cannot be applied to .*" +// $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForMultipleTargets« -# $TEST$ no error r"This annotation '.*' cannot be applied to .*" +// $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForAnything« -# $TEST$ no error r"This annotation '.*' cannot be applied to .*" +// $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»Unresolved« package tests.validation.builtins.annotations.target.wrongTarget @@ -54,119 +54,119 @@ annotation AnnotationForAnything /* Test declarations -------------------------------------------------------- */ -# $TEST$ error "The annotation 'AnnotationForAttributes' cannot be applied to an annotation." +// $TEST$ error "The annotation 'AnnotationForAttributes' cannot be applied to an annotation." @»AnnotationForAttributes« -# $TEST$ no error r"This annotation '.*' cannot be applied to .*" +// $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForAnnotations« -# $TEST$ no error r"This annotation '.*' cannot be applied to .*" +// $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForAnything« -# $TEST$ no error r"This annotation '.*' cannot be applied to .*" +// $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»Unresolved« annotation TestAnnotation -# $TEST$ error "The annotation 'AnnotationForModules' cannot be applied to a class." +// $TEST$ error "The annotation 'AnnotationForModules' cannot be applied to a class." @»AnnotationForModules« -# $TEST$ no error r"This annotation '.*' cannot be applied to .*" +// $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForClasses« -# $TEST$ no error r"This annotation '.*' cannot be applied to .*" +// $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForMultipleTargets« -# $TEST$ no error r"This annotation '.*' cannot be applied to .*" +// $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForAnything« -# $TEST$ no error r"This annotation '.*' cannot be applied to .*" +// $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»Unresolved« class TestClass< - # $TEST$ error "The annotation 'AnnotationForPipelines' cannot be applied to a type parameter." + // $TEST$ error "The annotation 'AnnotationForPipelines' cannot be applied to a type parameter." @»AnnotationForPipelines« - # $TEST$ no error r"This annotation '.*' cannot be applied to .*" + // $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForTypeParameters« - # $TEST$ no error r"This annotation '.*' cannot be applied to .*" + // $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForAnything« - # $TEST$ no error r"This annotation '.*' cannot be applied to .*" + // $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»Unresolved« TEST_TYPE_PARAMETER > { - # $TEST$ error "The annotation 'AnnotationForClasses' cannot be applied to an attribute." + // $TEST$ error "The annotation 'AnnotationForClasses' cannot be applied to an attribute." @»AnnotationForClasses« - # $TEST$ no error r"This annotation '.*' cannot be applied to .*" + // $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForAttributes« - # $TEST$ no error r"This annotation '.*' cannot be applied to .*" + // $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForAnything« - # $TEST$ no error r"This annotation '.*' cannot be applied to .*" + // $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»Unresolved« attr testAttribute: Int } -# $TEST$ error "The annotation 'AnnotationForEnumVariants' cannot be applied to an enum." +// $TEST$ error "The annotation 'AnnotationForEnumVariants' cannot be applied to an enum." @»AnnotationForEnumVariants« -# $TEST$ no error r"This annotation '.*' cannot be applied to .*" +// $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForEnums« -# $TEST$ no error r"This annotation '.*' cannot be applied to .*" +// $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForAnything« -# $TEST$ no error r"This annotation '.*' cannot be applied to .*" +// $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»Unresolved« enum TestEnum { - # $TEST$ error "The annotation 'AnnotationForFunctions' cannot be applied to an enum variant." + // $TEST$ error "The annotation 'AnnotationForFunctions' cannot be applied to an enum variant." @»AnnotationForFunctions« - # $TEST$ no error r"This annotation '.*' cannot be applied to .*" + // $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForEnumVariants« - # $TEST$ no error r"This annotation '.*' cannot be applied to .*" + // $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForAnything« - # $TEST$ no error r"This annotation '.*' cannot be applied to .*" + // $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»Unresolved« TestEnumVariant } -# $TEST$ error "The annotation 'AnnotationForParameters' cannot be applied to a function." +// $TEST$ error "The annotation 'AnnotationForParameters' cannot be applied to a function." @»AnnotationForParameters« -# $TEST$ no error r"This annotation '.*' cannot be applied to .*" +// $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForFunctions« -# $TEST$ no error r"This annotation '.*' cannot be applied to .*" +// $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForAnything« -# $TEST$ no error r"This annotation '.*' cannot be applied to .*" +// $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»Unresolved« fun testFunction( - # $TEST$ error "The annotation 'AnnotationForResults' cannot be applied to a parameter." + // $TEST$ error "The annotation 'AnnotationForResults' cannot be applied to a parameter." @»AnnotationForResults« - # $TEST$ no error r"This annotation '.*' cannot be applied to .*" + // $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForParameters« - # $TEST$ no error r"This annotation '.*' cannot be applied to .*" + // $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForAnything« - # $TEST$ no error r"This annotation '.*' cannot be applied to .*" + // $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»Unresolved« testParameter: Int ) -> ( - # $TEST$ error "The annotation 'AnnotationForTypeParameters' cannot be applied to a result." + // $TEST$ error "The annotation 'AnnotationForTypeParameters' cannot be applied to a result." @»AnnotationForTypeParameters« - # $TEST$ no error r"This annotation '.*' cannot be applied to .*" + // $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForResults« - # $TEST$ no error r"This annotation '.*' cannot be applied to .*" + // $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForAnything« - # $TEST$ no error r"This annotation '.*' cannot be applied to .*" + // $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»Unresolved« testResult: Int ) -# $TEST$ error "The annotation 'AnnotationForSegments' cannot be applied to a pipeline." +// $TEST$ error "The annotation 'AnnotationForSegments' cannot be applied to a pipeline." @»AnnotationForSegments« -# $TEST$ no error r"This annotation '.*' cannot be applied to .*" +// $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForPipelines« -# $TEST$ no error r"This annotation '.*' cannot be applied to .*" +// $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForAnything« -# $TEST$ no error r"This annotation '.*' cannot be applied to .*" +// $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»Unresolved« pipeline testPipeline {} -# $TEST$ error "The annotation 'AnnotationForAnnotations' cannot be applied to a segment." +// $TEST$ error "The annotation 'AnnotationForAnnotations' cannot be applied to a segment." @»AnnotationForAnnotations« -# $TEST$ no error r"This annotation '.*' cannot be applied to .*" +// $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForSegments« -# $TEST$ no error r"This annotation '.*' cannot be applied to .*" +// $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForAnything« -# $TEST$ no error r"This annotation '.*' cannot be applied to .*" +// $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»Unresolved« segment testSegment() {} diff --git a/packages/ttsl-lang/tests/resources/validation/experimental language feature/constraint lists/main.sdstest b/packages/ttsl-lang/tests/resources/validation/experimental language feature/constraint lists/main.sdstest index 16e84f21..d76b39b0 100644 --- a/packages/ttsl-lang/tests/resources/validation/experimental language feature/constraint lists/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/experimental language feature/constraint lists/main.sdstest @@ -1,4 +1,4 @@ package tests.validation.experimentalLanguageFeature.constraintLists -# $TEST$ warning "Constraint lists & constraints are experimental and may change without prior notice." +// $TEST$ warning "Constraint lists & constraints are experimental and may change without prior notice." fun myFunction() »where« {} diff --git a/packages/ttsl-lang/tests/resources/validation/experimental language feature/literal types/main.sdstest b/packages/ttsl-lang/tests/resources/validation/experimental language feature/literal types/main.sdstest index 0cee689c..369e22d5 100644 --- a/packages/ttsl-lang/tests/resources/validation/experimental language feature/literal types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/experimental language feature/literal types/main.sdstest @@ -1,6 +1,6 @@ package tests.validation.experimentalLanguageFeature.literalTypes fun myFunction( - # $TEST$ warning "Literal types are experimental and may change without prior notice." + // $TEST$ warning "Literal types are experimental and may change without prior notice." p: »literal«<> ) diff --git a/packages/ttsl-lang/tests/resources/validation/experimental language feature/maps/main.sdstest b/packages/ttsl-lang/tests/resources/validation/experimental language feature/maps/main.sdstest index b45710df..9addb92a 100644 --- a/packages/ttsl-lang/tests/resources/validation/experimental language feature/maps/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/experimental language feature/maps/main.sdstest @@ -1,9 +1,9 @@ package tests.validation.experimentalLanguageFeature.maps pipeline myPipeline { - # $TEST$ warning "Map literals are experimental and may change without prior notice." + // $TEST$ warning "Map literals are experimental and may change without prior notice." »{"a": "b"}«; - # $TEST$ no warning "Map literals are experimental and may change without prior notice." + // $TEST$ no warning "Map literals are experimental and may change without prior notice." {"a": »{}«}; } diff --git a/packages/ttsl-lang/tests/resources/validation/experimental language feature/union types/main.sdstest b/packages/ttsl-lang/tests/resources/validation/experimental language feature/union types/main.sdstest index 64322513..2db26e87 100644 --- a/packages/ttsl-lang/tests/resources/validation/experimental language feature/union types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/experimental language feature/union types/main.sdstest @@ -1,13 +1,13 @@ package tests.validation.experimentalLanguageFeature.unionTypes fun myFunction( - # $TEST$ warning "Union types are experimental and may change without prior notice." + // $TEST$ warning "Union types are experimental and may change without prior notice." p: »union«, - # $TEST$ no warning "Union types are experimental and may change without prior notice." + // $TEST$ no warning "Union types are experimental and may change without prior notice." q: union<»union«, Int>, - # $TEST$ no warning "Union types are experimental and may change without prior notice." - # $TEST$ no warning "Union types are experimental and may change without prior notice." + // $TEST$ no warning "Union types are experimental and may change without prior notice." + // $TEST$ no warning "Union types are experimental and may change without prior notice." r: union<(p: »union«) -> (r: »union«), Int>, ) diff --git a/packages/ttsl-lang/tests/resources/validation/inheritance/must be acyclic/main.sdstest b/packages/ttsl-lang/tests/resources/validation/inheritance/must be acyclic/main.sdstest index ee488f61..84def22e 100644 --- a/packages/ttsl-lang/tests/resources/validation/inheritance/must be acyclic/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/inheritance/must be acyclic/main.sdstest @@ -1,22 +1,22 @@ package tests.validation.inheritance.mustBeAcyclic -# $TEST$ error "A class must not directly or indirectly be a subtype of itself." +// $TEST$ error "A class must not directly or indirectly be a subtype of itself." class MyClass1 sub »MyClass3« -# $TEST$ error "A class must not directly or indirectly be a subtype of itself." +// $TEST$ error "A class must not directly or indirectly be a subtype of itself." class MyClass2 sub »MyClass1« -# $TEST$ error "A class must not directly or indirectly be a subtype of itself." +// $TEST$ error "A class must not directly or indirectly be a subtype of itself." class MyClass3 sub »MyClass2« class MyClass4 -# $TEST$ no error "A class must not directly or indirectly be a subtype of itself." +// $TEST$ no error "A class must not directly or indirectly be a subtype of itself." class MyClass5 sub »MyClass4« -# $TEST$ no error "A class must not directly or indirectly be a subtype of itself." +// $TEST$ no error "A class must not directly or indirectly be a subtype of itself." class MyClass6 sub »MyClass7« -# $TEST$ no error "A class must not directly or indirectly be a subtype of itself." +// $TEST$ no error "A class must not directly or indirectly be a subtype of itself." class MyClass7 sub Any, »MyClass6« -# $TEST$ no error "A class must not directly or indirectly be a subtype of itself." +// $TEST$ no error "A class must not directly or indirectly be a subtype of itself." class MyClass8 sub »Unresolved« -# $TEST$ no error "A class must not directly or indirectly be a subtype of itself." +// $TEST$ no error "A class must not directly or indirectly be a subtype of itself." class MyClass9 sub »MyClass8« diff --git a/packages/ttsl-lang/tests/resources/validation/inheritance/must inherit only classes/class with parent types.sdstest b/packages/ttsl-lang/tests/resources/validation/inheritance/must inherit only classes/class with parent types.sdstest index 71de5ac8..fcb6c6c0 100644 --- a/packages/ttsl-lang/tests/resources/validation/inheritance/must inherit only classes/class with parent types.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/inheritance/must inherit only classes/class with parent types.sdstest @@ -7,28 +7,28 @@ enum MyEnum { MyEnumVariant } -# $TEST$ no error "A class must only inherit classes." -# $TEST$ no error "A class must only inherit classes." -# $TEST$ no error "A class must only inherit classes." -# $TEST$ no error "A class must only inherit classes." -# $TEST$ no error "A class must only inherit classes." +// $TEST$ no error "A class must only inherit classes." +// $TEST$ no error "A class must only inherit classes." +// $TEST$ no error "A class must only inherit classes." +// $TEST$ no error "A class must only inherit classes." +// $TEST$ no error "A class must only inherit classes." class TestClass1 sub »MyClass«, »MyClass.MyNestedClass«, »MyEnum«, »MyEnum.MyEnumVariant«, »Unresolved« -# $TEST$ no error "A class must only inherit classes." +// $TEST$ no error "A class must only inherit classes." class TestClass2 sub »MyClass« -# $TEST$ no error "A class must only inherit classes." +// $TEST$ no error "A class must only inherit classes." class TestClass3 sub »MyClass.MyNestedClass« -# $TEST$ error "A class must only inherit classes." +// $TEST$ error "A class must only inherit classes." class TestClass4 sub »MyEnum« -# $TEST$ error "A class must only inherit classes." +// $TEST$ error "A class must only inherit classes." class TestClass5 sub »MyEnum.MyEnumVariant« -# $TEST$ no error "A class must only inherit classes." +// $TEST$ no error "A class must only inherit classes." class TestClass6 sub »Unresolved« diff --git a/packages/ttsl-lang/tests/resources/validation/inheritance/must inherit only classes/class without parent types.sdstest b/packages/ttsl-lang/tests/resources/validation/inheritance/must inherit only classes/class without parent types.sdstest index 306d5a81..eb1fc7ec 100644 --- a/packages/ttsl-lang/tests/resources/validation/inheritance/must inherit only classes/class without parent types.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/inheritance/must inherit only classes/class without parent types.sdstest @@ -1,4 +1,4 @@ package tests.validation.inheritance.mustInheritOnlyClasses -# $TEST$ no error "A class must only inherit classes." +// $TEST$ no error "A class must only inherit classes." class TestClass7 diff --git a/packages/ttsl-lang/tests/resources/validation/inheritance/must not be nullable/class with parent types.sdstest b/packages/ttsl-lang/tests/resources/validation/inheritance/must not be nullable/class with parent types.sdstest index 4574d236..78a28da2 100644 --- a/packages/ttsl-lang/tests/resources/validation/inheritance/must not be nullable/class with parent types.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/inheritance/must not be nullable/class with parent types.sdstest @@ -7,28 +7,28 @@ enum MyEnum { MyEnumVariant } -# $TEST$ no error "The parent type must not be nullable." -# $TEST$ no error "The parent type must not be nullable." -# $TEST$ no error "The parent type must not be nullable." -# $TEST$ no error "The parent type must not be nullable." -# $TEST$ no error "The parent type must not be nullable." +// $TEST$ no error "The parent type must not be nullable." +// $TEST$ no error "The parent type must not be nullable." +// $TEST$ no error "The parent type must not be nullable." +// $TEST$ no error "The parent type must not be nullable." +// $TEST$ no error "The parent type must not be nullable." class TestClass1 sub »MyClass«, »MyClass.MyNestedClass?«, »MyEnum?«, »MyEnum.MyEnumVariant?«, »Unresolved?« -# $TEST$ error "The parent type must not be nullable." +// $TEST$ error "The parent type must not be nullable." class TestClass2 sub »MyClass?« -# $TEST$ error "The parent type must not be nullable." +// $TEST$ error "The parent type must not be nullable." class TestClass3 sub »MyClass.MyNestedClass?« -# $TEST$ no error "The parent type must not be nullable." +// $TEST$ no error "The parent type must not be nullable." class TestClass4 sub »MyEnum?« -# $TEST$ no error "The parent type must not be nullable." +// $TEST$ no error "The parent type must not be nullable." class TestClass5 sub »MyEnum.MyEnumVariant?« -# $TEST$ no error "The parent type must not be nullable." +// $TEST$ no error "The parent type must not be nullable." class TestClass6 sub »Unresolved?« diff --git a/packages/ttsl-lang/tests/resources/validation/inheritance/no multiple inheritance/class with parent types.sdstest b/packages/ttsl-lang/tests/resources/validation/inheritance/no multiple inheritance/class with parent types.sdstest index 5d4ed2a2..60b064db 100644 --- a/packages/ttsl-lang/tests/resources/validation/inheritance/no multiple inheritance/class with parent types.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/inheritance/no multiple inheritance/class with parent types.sdstest @@ -7,12 +7,12 @@ enum MyEnum { MyEnumVariant } -# $TEST$ no error "Multiple inheritance is not supported. Only the first parent type will be considered." -# $TEST$ error "Multiple inheritance is not supported. Only the first parent type will be considered." -# $TEST$ error "Multiple inheritance is not supported. Only the first parent type will be considered." -# $TEST$ error "Multiple inheritance is not supported. Only the first parent type will be considered." -# $TEST$ error "Multiple inheritance is not supported. Only the first parent type will be considered." -# $TEST$ error "Multiple inheritance is not supported. Only the first parent type will be considered." +// $TEST$ no error "Multiple inheritance is not supported. Only the first parent type will be considered." +// $TEST$ error "Multiple inheritance is not supported. Only the first parent type will be considered." +// $TEST$ error "Multiple inheritance is not supported. Only the first parent type will be considered." +// $TEST$ error "Multiple inheritance is not supported. Only the first parent type will be considered." +// $TEST$ error "Multiple inheritance is not supported. Only the first parent type will be considered." +// $TEST$ error "Multiple inheritance is not supported. Only the first parent type will be considered." class TestClass1 sub »MyClass«, »MyClass.MyNestedClass«, »MyEnum«, diff --git a/packages/ttsl-lang/tests/resources/validation/inheritance/no multiple inheritance/class without parent types.sdstest b/packages/ttsl-lang/tests/resources/validation/inheritance/no multiple inheritance/class without parent types.sdstest index ac4fdf60..3233e0ff 100644 --- a/packages/ttsl-lang/tests/resources/validation/inheritance/no multiple inheritance/class without parent types.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/inheritance/no multiple inheritance/class without parent types.sdstest @@ -1,4 +1,4 @@ package tests.validation.inheritance.noMultipleInheritance -# $TEST$ no error "Multiple inheritance is not supported. Only the first parent type will be considered." +// $TEST$ no error "Multiple inheritance is not supported. Only the first parent type will be considered." class TestClass2 diff --git a/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method must match overridden method/main.sdstest b/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method must match overridden method/main.sdstest index 0de22fd9..05d224e1 100644 --- a/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method must match overridden method/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method must match overridden method/main.sdstest @@ -9,47 +9,47 @@ class MySuperClass1 { } class MyClass1 sub MySuperClass1 { - # $TEST$ no error r"Overriding member does not match the overridden member:.*" + // $TEST$ no error r"Overriding member does not match the overridden member:.*" attr »myInstanceAttribute«: Int - # $TEST$ no error r"Overriding member does not match the overridden member:.*" + // $TEST$ no error r"Overriding member does not match the overridden member:.*" static attr »myStaticAttribute«: Int - # $TEST$ no error r"Overriding member does not match the overridden member:.*" + // $TEST$ no error r"Overriding member does not match the overridden member:.*" attr »myInstanceAttribute«: Any - # $TEST$ no error r"Overriding member does not match the overridden member:.*" + // $TEST$ no error r"Overriding member does not match the overridden member:.*" static attr »myStaticAttribute«: Any - # $TEST$ no error r"Overriding member does not match the overridden member:.*" + // $TEST$ no error r"Overriding member does not match the overridden member:.*" attr »myOwnInstanceAttribute«: Int - # $TEST$ no error r"Overriding member does not match the overridden member:.*" + // $TEST$ no error r"Overriding member does not match the overridden member:.*" static attr »myOwnStaticAttribute«: Int - # $TEST$ no error r"Overriding member does not match the overridden member:.*" + // $TEST$ no error r"Overriding member does not match the overridden member:.*" @Pure fun »myInstanceMethod«(a: Any = 0) -> r: Int - # $TEST$ no error r"Overriding member does not match the overridden member:.*" + // $TEST$ no error r"Overriding member does not match the overridden member:.*" @Pure static fun »myStaticMethod«(a: Any = 0) -> r: Int - # $TEST$ no error r"Overriding member does not match the overridden member:.*" + // $TEST$ no error r"Overriding member does not match the overridden member:.*" @Pure fun »myInstanceMethod«() -> r: Int - # $TEST$ no error r"Overriding member does not match the overridden member:.*" + // $TEST$ no error r"Overriding member does not match the overridden member:.*" @Pure static fun »myStaticMethod«() -> r: Int - # $TEST$ no error r"Overriding member does not match the overridden member:.*" + // $TEST$ no error r"Overriding member does not match the overridden member:.*" @Pure fun »myOwnInstanceMethod«(a: Any = 0) -> r: Int - # $TEST$ no error r"Overriding member does not match the overridden member:.*" + // $TEST$ no error r"Overriding member does not match the overridden member:.*" @Pure static fun »myOwnStaticMethod«(a: Any = 0) -> r: Int } class MyClass2 sub MySuperClass1 { - # $TEST$ error r"Overriding member does not match the overridden member:.*" + // $TEST$ error r"Overriding member does not match the overridden member:.*" attr »myInstanceAttribute«: Any - # $TEST$ no error r"Overriding member does not match the overridden member:.*" + // $TEST$ no error r"Overriding member does not match the overridden member:.*" static attr »myStaticAttribute«: Any - # $TEST$ error r"Overriding member does not match the overridden member:.*" + // $TEST$ error r"Overriding member does not match the overridden member:.*" @Pure fun »myInstanceMethod«(a: Number = 0) -> r: Any - # $TEST$ no error r"Overriding member does not match the overridden member:.*" + // $TEST$ no error r"Overriding member does not match the overridden member:.*" @Pure static fun »myStaticMethod«(a: Number = 0) -> r: Any } diff --git a/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method must match overridden method/type parameters.sdstest b/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method must match overridden method/type parameters.sdstest index 5d404836..04b5fcea 100644 --- a/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method must match overridden method/type parameters.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method must match overridden method/type parameters.sdstest @@ -8,39 +8,39 @@ class MySuperClass { } class MyClass1 sub MySuperClass { - # $TEST$ no error r"Overriding member does not match the overridden member:.*" + // $TEST$ no error r"Overriding member does not match the overridden member:.*" attr »myInstanceAttribute«: Int - # $TEST$ no error r"Overriding member does not match the overridden member:.*" + // $TEST$ no error r"Overriding member does not match the overridden member:.*" @Pure fun »myInstanceMethod1«(a: Any = 0) -> r: Int } class MyClass2 sub MySuperClass { - # $TEST$ no error r"Overriding member does not match the overridden member:.*" + // $TEST$ no error r"Overriding member does not match the overridden member:.*" attr »myInstanceAttribute«: T - # $TEST$ no error r"Overriding member does not match the overridden member:.*" + // $TEST$ no error r"Overriding member does not match the overridden member:.*" @Pure fun »myInstanceMethod1«(a: T = 0) -> r: T } class MyClass3 sub MySuperClass { - # $TEST$ error r"Overriding member does not match the overridden member:.*" + // $TEST$ error r"Overriding member does not match the overridden member:.*" attr »myInstanceAttribute«: Any - # $TEST$ error r"Overriding member does not match the overridden member:.*" + // $TEST$ error r"Overriding member does not match the overridden member:.*" @Pure fun »myInstanceMethod1«(a: Number = 0) -> r: Any } class MyClass4 sub MySuperClass { - # $TEST$ no error r"Overriding member does not match the overridden member:.*" + // $TEST$ no error r"Overriding member does not match the overridden member:.*" @Pure fun »myInstanceMethod2«(a: T) -> r: T - # $TEST$ no error r"Overriding member does not match the overridden member:.*" + // $TEST$ no error r"Overriding member does not match the overridden member:.*" @Pure fun »myInstanceMethod3«(a: T) -> r: T } class MyClass5 sub MySuperClass { - # $TEST$ error r"Overriding member does not match the overridden member:.*" + // $TEST$ error r"Overriding member does not match the overridden member:.*" @Pure fun »myInstanceMethod3«(a: Int) -> r: Int } class MyClass6 sub MySuperClass { - # $TEST$ error r"Overriding member does not match the overridden member:.*" + // $TEST$ error r"Overriding member does not match the overridden member:.*" attr »myInstanceAttribute«: T } diff --git a/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method should differ from overridden method/main.sdstest b/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method should differ from overridden method/main.sdstest index f91e098d..ea87ac37 100644 --- a/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method should differ from overridden method/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method should differ from overridden method/main.sdstest @@ -9,47 +9,47 @@ class MySuperClass1 { } class MyClass1 sub MySuperClass1 { - # $TEST$ info "Overriding member is identical to overridden member and can be removed." + // $TEST$ info "Overriding member is identical to overridden member and can be removed." attr »myInstanceAttribute«: Number - # $TEST$ no info "Overriding member is identical to overridden member and can be removed." + // $TEST$ no info "Overriding member is identical to overridden member and can be removed." static attr »myStaticAttribute«: Number - # $TEST$ no info "Overriding member is identical to overridden member and can be removed." + // $TEST$ no info "Overriding member is identical to overridden member and can be removed." attr »myInstanceAttribute«: Number - # $TEST$ no info "Overriding member is identical to overridden member and can be removed." + // $TEST$ no info "Overriding member is identical to overridden member and can be removed." static attr »myStaticAttribute«: Number - # $TEST$ no info "Overriding member is identical to overridden member and can be removed." + // $TEST$ no info "Overriding member is identical to overridden member and can be removed." attr »myOwnInstanceAttribute«: Number - # $TEST$ no info "Overriding member is identical to overridden member and can be removed." + // $TEST$ no info "Overriding member is identical to overridden member and can be removed." static attr »myOwnStaticAttribute«: Number - # $TEST$ info "Overriding member is identical to overridden member and can be removed." + // $TEST$ info "Overriding member is identical to overridden member and can be removed." @Pure fun »myInstanceMethod«(a: Number = 0) -> r: Number - # $TEST$ no info "Overriding member is identical to overridden member and can be removed." + // $TEST$ no info "Overriding member is identical to overridden member and can be removed." @Pure static fun »myStaticMethod«(a: Number = 0) -> r: Number - # $TEST$ no info "Overriding member is identical to overridden member and can be removed." + // $TEST$ no info "Overriding member is identical to overridden member and can be removed." @Pure fun »myInstanceMethod«() -> r: Number - # $TEST$ no info "Overriding member is identical to overridden member and can be removed." + // $TEST$ no info "Overriding member is identical to overridden member and can be removed." @Pure static fun »myStaticMethod«() -> r: Number - # $TEST$ no info "Overriding member is identical to overridden member and can be removed." + // $TEST$ no info "Overriding member is identical to overridden member and can be removed." @Pure fun »myOwnInstanceMethod«(a: Number = 0) -> r: Number - # $TEST$ no info "Overriding member is identical to overridden member and can be removed." + // $TEST$ no info "Overriding member is identical to overridden member and can be removed." @Pure static fun »myOwnStaticMethod«(a: Number = 0) -> r: Number } class MyClass2 sub MySuperClass1 { - # $TEST$ no info "Overriding member is identical to overridden member and can be removed." + // $TEST$ no info "Overriding member is identical to overridden member and can be removed." attr »myInstanceAttribute«: Int - # $TEST$ no info "Overriding member is identical to overridden member and can be removed." + // $TEST$ no info "Overriding member is identical to overridden member and can be removed." static attr »myStaticAttribute«: Int - # $TEST$ no info "Overriding member is identical to overridden member and can be removed." + // $TEST$ no info "Overriding member is identical to overridden member and can be removed." @Pure fun »myInstanceMethod«(a: Number = 0) -> r: Int - # $TEST$ no info "Overriding member is identical to overridden member and can be removed." + // $TEST$ no info "Overriding member is identical to overridden member and can be removed." @Pure static fun »myStaticMethod«(a: Number = 0) -> r: Int } diff --git a/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method should differ from overridden method/purity.sdstest b/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method should differ from overridden method/purity.sdstest index 6ff91e70..8ef0a9e8 100644 --- a/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method should differ from overridden method/purity.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method should differ from overridden method/purity.sdstest @@ -8,19 +8,19 @@ class MySuperClass2 { } class MyClass3 sub MySuperClass2 { - # $TEST$ no info "Overriding member is identical to overridden member and can be removed." + // $TEST$ no info "Overriding member is identical to overridden member and can be removed." @Pure fun »myInstanceMethod«(a: Number = 0) -> r: Number - # $TEST$ no info "Overriding member is identical to overridden member and can be removed." + // $TEST$ no info "Overriding member is identical to overridden member and can be removed." @Pure static fun »myStaticMethod«(a: Number = 0) -> r: Number } class MyClass4 sub MySuperClass2 { - # $TEST$ no info "Overriding member is identical to overridden member and can be removed." + // $TEST$ no info "Overriding member is identical to overridden member and can be removed." @Impure([]) fun »myInstanceMethod«(a: Number = 0) -> r: Number - # $TEST$ no info "Overriding member is identical to overridden member and can be removed." + // $TEST$ no info "Overriding member is identical to overridden member and can be removed." @Impure([]) static fun »myStaticMethod«(a: Number = 0) -> r: Number } diff --git a/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method should differ from overridden method/safeds lang any.sdstest b/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method should differ from overridden method/safeds lang any.sdstest index 56c02bb1..891d2056 100644 --- a/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method should differ from overridden method/safeds lang any.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method should differ from overridden method/safeds lang any.sdstest @@ -1,6 +1,6 @@ package safeds.lang class Any { - # $TEST$ no info "Overriding member is identical to overridden member and can be removed." + // $TEST$ no info "Overriding member is identical to overridden member and can be removed." fun »toString«() -> s: String } diff --git a/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method should differ from overridden method/type parameters.sdstest b/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method should differ from overridden method/type parameters.sdstest index 46b66ada..d6e2216f 100644 --- a/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method should differ from overridden method/type parameters.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method should differ from overridden method/type parameters.sdstest @@ -8,34 +8,34 @@ class MySuperClass { } class MyClass2 sub MySuperClass { - # $TEST$ info "Overriding member is identical to overridden member and can be removed." + // $TEST$ info "Overriding member is identical to overridden member and can be removed." attr »myInstanceAttribute«: T - # $TEST$ info "Overriding member is identical to overridden member and can be removed." + // $TEST$ info "Overriding member is identical to overridden member and can be removed." @Pure fun »myInstanceMethod1«(a: T = 0) -> r: T } class MyClass1 sub MySuperClass { - # $TEST$ info "Overriding member is identical to overridden member and can be removed." + // $TEST$ info "Overriding member is identical to overridden member and can be removed." attr »myInstanceAttribute«: Number - # $TEST$ info "Overriding member is identical to overridden member and can be removed." + // $TEST$ info "Overriding member is identical to overridden member and can be removed." @Pure fun »myInstanceMethod1«(a: Number = 0) -> r: Number } class MyClass3 sub MySuperClass { - # $TEST$ no info "Overriding member is identical to overridden member and can be removed." + // $TEST$ no info "Overriding member is identical to overridden member and can be removed." attr »myInstanceAttribute«: Int - # $TEST$ no info "Overriding member is identical to overridden member and can be removed." + // $TEST$ no info "Overriding member is identical to overridden member and can be removed." @Pure fun »myInstanceMethod1«(a: Number = 0) -> r: Int } class MyClass4 sub MySuperClass { - # $TEST$ no info "Overriding member is identical to overridden member and can be removed." + // $TEST$ no info "Overriding member is identical to overridden member and can be removed." @Pure fun »myInstanceMethod2«(a: T) -> r: T - # $TEST$ info "Overriding member is identical to overridden member and can be removed." + // $TEST$ info "Overriding member is identical to overridden member and can be removed." @Pure fun »myInstanceMethod3«(a: T) -> r: T } class MyClass5 sub MySuperClass { - # $TEST$ no info "Overriding member is identical to overridden member and can be removed." + // $TEST$ no info "Overriding member is identical to overridden member and can be removed." @Pure fun »myInstanceMethod3«(a: Int) -> r: Int } diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/annotations.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/annotations.sdstest index afac890b..d1b1be50 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/annotations.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/annotations.sdstest @@ -1,12 +1,12 @@ package tests.validation.names.casing -# $TEST$ no warning "Names of annotations should be UpperCamelCase." +// $TEST$ no warning "Names of annotations should be UpperCamelCase." annotation »AnnotationUppercase1« -# $TEST$ no warning "Names of annotations should be UpperCamelCase." +// $TEST$ no warning "Names of annotations should be UpperCamelCase." annotation »`AnnotationUppercase2`« -# $TEST$ warning "Names of annotations should be UpperCamelCase." +// $TEST$ warning "Names of annotations should be UpperCamelCase." annotation »annotationLowercase« -# $TEST$ warning "Names of annotations should be UpperCamelCase." +// $TEST$ warning "Names of annotations should be UpperCamelCase." annotation »_annotationUnderscore« -# $TEST$ warning "Names of annotations should be UpperCamelCase." +// $TEST$ warning "Names of annotations should be UpperCamelCase." annotation »Annotation_Snake_Case« diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/attributes.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/attributes.sdstest index 469bd6e8..66099ce6 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/attributes.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/attributes.sdstest @@ -1,14 +1,14 @@ package tests.validation.names.casing class MyClass { - # $TEST$ warning "Names of attributes should be lowerCamelCase." + // $TEST$ warning "Names of attributes should be lowerCamelCase." attr »AttributeUppercase«: Int - # $TEST$ no warning "Names of attributes should be lowerCamelCase." + // $TEST$ no warning "Names of attributes should be lowerCamelCase." attr »attributeLowercase1«: Int - # $TEST$ no warning "Names of attributes should be lowerCamelCase." + // $TEST$ no warning "Names of attributes should be lowerCamelCase." attr »`attributeLowercase2`«: Int - # $TEST$ warning "Names of attributes should be lowerCamelCase." + // $TEST$ warning "Names of attributes should be lowerCamelCase." attr »_attributeUnderscore«: Int - # $TEST$ warning "Names of attributes should be lowerCamelCase." + // $TEST$ warning "Names of attributes should be lowerCamelCase." attr »attribute_snake_case«: Int } diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/block lambda results.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/block lambda results.sdstest index 0913cb3b..63ca47c3 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/block lambda results.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/block lambda results.sdstest @@ -2,15 +2,15 @@ package tests.validation.names.casing pipeline myPipeline1 { () { - # $TEST$ warning "Names of block lambda results should be lowerCamelCase." + // $TEST$ warning "Names of block lambda results should be lowerCamelCase." yield »LambdaResultUppercase« = 1; - # $TEST$ no warning "Names of block lambda results should be lowerCamelCase." + // $TEST$ no warning "Names of block lambda results should be lowerCamelCase." yield »lambdaResultLowercase1« = 1; - # $TEST$ no warning "Names of block lambda results should be lowerCamelCase." + // $TEST$ no warning "Names of block lambda results should be lowerCamelCase." yield »`lambdaResultLowercase2`« = 1; - # $TEST$ warning "Names of block lambda results should be lowerCamelCase." + // $TEST$ warning "Names of block lambda results should be lowerCamelCase." yield »_lambdaResultUnderscore« = 1; - # $TEST$ warning "Names of block lambda results should be lowerCamelCase." + // $TEST$ warning "Names of block lambda results should be lowerCamelCase." yield »lambdaResult_snake_case« = 1; }; } diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/classes.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/classes.sdstest index b33faf44..8c571f72 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/classes.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/classes.sdstest @@ -1,12 +1,12 @@ package tests.validation.names.casing -# $TEST$ no warning "Names of classes should be UpperCamelCase." +// $TEST$ no warning "Names of classes should be UpperCamelCase." class »ClassUppercase1« -# $TEST$ no warning "Names of classes should be UpperCamelCase." +// $TEST$ no warning "Names of classes should be UpperCamelCase." class »`ClassUppercase2`« -# $TEST$ warning "Names of classes should be UpperCamelCase." +// $TEST$ warning "Names of classes should be UpperCamelCase." class »classLowercase« -# $TEST$ warning "Names of classes should be UpperCamelCase." +// $TEST$ warning "Names of classes should be UpperCamelCase." class »_classUnderscore« -# $TEST$ warning "Names of classes should be UpperCamelCase." +// $TEST$ warning "Names of classes should be UpperCamelCase." class »Class_Snake_Case« diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/enum variants.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/enum variants.sdstest index 4b5f0db9..11fbe086 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/enum variants.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/enum variants.sdstest @@ -1,14 +1,14 @@ package tests.validation.names.casing enum MyEnum { - # $TEST$ no warning "Names of enum variants should be UpperCamelCase." + // $TEST$ no warning "Names of enum variants should be UpperCamelCase." »EnumVariantUppercase1« - # $TEST$ no warning "Names of enum variants should be UpperCamelCase." + // $TEST$ no warning "Names of enum variants should be UpperCamelCase." »`EnumVariantUppercase2`« - # $TEST$ warning "Names of enum variants should be UpperCamelCase." + // $TEST$ warning "Names of enum variants should be UpperCamelCase." »enumVariantLowercase« - # $TEST$ warning "Names of enum variants should be UpperCamelCase." + // $TEST$ warning "Names of enum variants should be UpperCamelCase." »_enumVariantUnderscore« - # $TEST$ warning "Names of enum variants should be UpperCamelCase." + // $TEST$ warning "Names of enum variants should be UpperCamelCase." »Enum_Variant_Snake_Case« } diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/enums.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/enums.sdstest index f55b3ef7..90bf4cf0 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/enums.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/enums.sdstest @@ -1,12 +1,12 @@ package tests.validation.names.casing -# $TEST$ no warning "Names of enums should be UpperCamelCase." +// $TEST$ no warning "Names of enums should be UpperCamelCase." enum »EnumUppercase1« -# $TEST$ no warning "Names of enums should be UpperCamelCase." +// $TEST$ no warning "Names of enums should be UpperCamelCase." enum »`EnumUppercase2`« -# $TEST$ warning "Names of enums should be UpperCamelCase." +// $TEST$ warning "Names of enums should be UpperCamelCase." enum »enumLowercase« -# $TEST$ warning "Names of enums should be UpperCamelCase." +// $TEST$ warning "Names of enums should be UpperCamelCase." enum »_enumUnderscore« -# $TEST$ warning "Names of enums should be UpperCamelCase." +// $TEST$ warning "Names of enums should be UpperCamelCase." enum »Enum_Snake_Case« diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/functions.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/functions.sdstest index 8ed50041..41d16b3d 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/functions.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/functions.sdstest @@ -1,12 +1,12 @@ package tests.validation.names.casing -# $TEST$ warning "Names of functions should be lowerCamelCase." +// $TEST$ warning "Names of functions should be lowerCamelCase." fun »FunctionUppercase«() -# $TEST$ no warning "Names of functions should be lowerCamelCase." +// $TEST$ no warning "Names of functions should be lowerCamelCase." fun »functionLowercase1«() -# $TEST$ no warning "Names of functions should be lowerCamelCase." +// $TEST$ no warning "Names of functions should be lowerCamelCase." fun »`functionLowercase2`«() -# $TEST$ warning "Names of functions should be lowerCamelCase." +// $TEST$ warning "Names of functions should be lowerCamelCase." fun »_functionUnderscore«() -# $TEST$ warning "Names of functions should be lowerCamelCase." +// $TEST$ warning "Names of functions should be lowerCamelCase." fun »function_snake_case«() diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/no package name.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/no package name.sdstest index 3948a368..b31d16d3 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/no package name.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/no package name.sdstest @@ -1 +1 @@ -# $TEST$ no warning "All segments of the qualified name of a package should be lowerCamelCase." +// $TEST$ no warning "All segments of the qualified name of a package should be lowerCamelCase." diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/package name leading underscore.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/package name leading underscore.sdstest index c2ae50bb..252c47d9 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/package name leading underscore.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/package name leading underscore.sdstest @@ -1,2 +1,2 @@ -# $TEST$ warning "All segments of the qualified name of a package should be lowerCamelCase." +// $TEST$ warning "All segments of the qualified name of a package should be lowerCamelCase." package »tests.validation.declarations._underscore« diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/package name lowercase escaped.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/package name lowercase escaped.sdstest index 2aff365f..c5bf8580 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/package name lowercase escaped.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/package name lowercase escaped.sdstest @@ -1,2 +1,2 @@ -# $TEST$ no warning "All segments of the qualified name of a package should be lowerCamelCase." +// $TEST$ no warning "All segments of the qualified name of a package should be lowerCamelCase." package »tests.validation.declarations.`lowercase1`« diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/package name lowercase.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/package name lowercase.sdstest index ad036921..44069623 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/package name lowercase.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/package name lowercase.sdstest @@ -1,2 +1,2 @@ -# $TEST$ no warning "All segments of the qualified name of a package should be lowerCamelCase." +// $TEST$ no warning "All segments of the qualified name of a package should be lowerCamelCase." package »tests.validation.declarations.lowercase1« diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/package name snake case.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/package name snake case.sdstest index efe68e9d..41197e77 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/package name snake case.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/package name snake case.sdstest @@ -1,2 +1,2 @@ -# $TEST$ warning "All segments of the qualified name of a package should be lowerCamelCase." +// $TEST$ warning "All segments of the qualified name of a package should be lowerCamelCase." package »tests.validation.declarations.snake_case« diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/package name uppercase.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/package name uppercase.sdstest index 3ef878ac..07272cee 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/package name uppercase.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/package name uppercase.sdstest @@ -1,2 +1,2 @@ -# $TEST$ warning "All segments of the qualified name of a package should be lowerCamelCase." +// $TEST$ warning "All segments of the qualified name of a package should be lowerCamelCase." package »tests.validation.declarations.Uppercase« diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/parameters.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/parameters.sdstest index 15f15a52..59b57573 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/parameters.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/parameters.sdstest @@ -1,14 +1,14 @@ package tests.validation.names.casing fun myFunction1( - # $TEST$ warning "Names of parameters should be lowerCamelCase." + // $TEST$ warning "Names of parameters should be lowerCamelCase." »ParameterUppercase«: Int, - # $TEST$ no warning "Names of parameters should be lowerCamelCase." + // $TEST$ no warning "Names of parameters should be lowerCamelCase." »parameterLowercase1«: Int, - # $TEST$ no warning "Names of parameters should be lowerCamelCase." + // $TEST$ no warning "Names of parameters should be lowerCamelCase." »`parameterLowercase2`«: Int, - # $TEST$ warning "Names of parameters should be lowerCamelCase." + // $TEST$ warning "Names of parameters should be lowerCamelCase." »_parameterUnderscore«: Int, - # $TEST$ warning "Names of parameters should be lowerCamelCase." + // $TEST$ warning "Names of parameters should be lowerCamelCase." »parameter_snake_case«: Int ) diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/pipelines.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/pipelines.sdstest index 5b31adeb..c9a46ef9 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/pipelines.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/pipelines.sdstest @@ -1,12 +1,12 @@ package tests.validation.names.casing -# $TEST$ warning "Names of pipelines should be lowerCamelCase." +// $TEST$ warning "Names of pipelines should be lowerCamelCase." pipeline »PipelineUppercase« {} -# $TEST$ no warning "Names of pipelines should be lowerCamelCase." +// $TEST$ no warning "Names of pipelines should be lowerCamelCase." pipeline »pipelineLowercase1« {} -# $TEST$ no warning "Names of pipelines should be lowerCamelCase." +// $TEST$ no warning "Names of pipelines should be lowerCamelCase." pipeline »`pipelineLowercase2`« {} -# $TEST$ warning "Names of pipelines should be lowerCamelCase." +// $TEST$ warning "Names of pipelines should be lowerCamelCase." pipeline »_pipelineUnderscore« {} -# $TEST$ warning "Names of pipelines should be lowerCamelCase." +// $TEST$ warning "Names of pipelines should be lowerCamelCase." pipeline »pipeline_snake_case« {} diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/placeholders.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/placeholders.sdstest index d3abe702..1cb0658b 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/placeholders.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/placeholders.sdstest @@ -1,14 +1,14 @@ package tests.validation.names.casing pipeline myPipeline2 { - # $TEST$ warning "Names of placeholders should be lowerCamelCase." + // $TEST$ warning "Names of placeholders should be lowerCamelCase." val »PlaceholderUppercase« = 1; - # $TEST$ no warning "Names of placeholders should be lowerCamelCase." + // $TEST$ no warning "Names of placeholders should be lowerCamelCase." val »placeholderLowercase1« = 1; - # $TEST$ no warning "Names of placeholders should be lowerCamelCase." + // $TEST$ no warning "Names of placeholders should be lowerCamelCase." val »`placeholderLowercase2`« = 1; - # $TEST$ warning "Names of placeholders should be lowerCamelCase." + // $TEST$ warning "Names of placeholders should be lowerCamelCase." val »_placeholderUnderscore« = 1; - # $TEST$ warning "Names of placeholders should be lowerCamelCase." + // $TEST$ warning "Names of placeholders should be lowerCamelCase." val »placeholder_snake_case« = 1; } diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/results.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/results.sdstest index 5299c82e..f0d2a048 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/results.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/results.sdstest @@ -1,14 +1,14 @@ package tests.validation.names.casing fun myFunction2() -> ( - # $TEST$ warning "Names of results should be lowerCamelCase." + // $TEST$ warning "Names of results should be lowerCamelCase." »ResultUppercase«: Int, - # $TEST$ no warning "Names of results should be lowerCamelCase." + // $TEST$ no warning "Names of results should be lowerCamelCase." »resultLowercase1«: Int, - # $TEST$ no warning "Names of results should be lowerCamelCase." + // $TEST$ no warning "Names of results should be lowerCamelCase." »`resultLowercase2`«: Int, - # $TEST$ warning "Names of results should be lowerCamelCase." + // $TEST$ warning "Names of results should be lowerCamelCase." »_resultUnderscore«: Int, - # $TEST$ warning "Names of results should be lowerCamelCase." + // $TEST$ warning "Names of results should be lowerCamelCase." »result_snake_case«: Int ) diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/schemas.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/schemas.sdstest index b53308ca..a456b764 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/schemas.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/schemas.sdstest @@ -1,12 +1,12 @@ package tests.validation.names.casing -# $TEST$ no warning "Names of schemas should be UpperCamelCase." +// $TEST$ no warning "Names of schemas should be UpperCamelCase." schema »SchemaUppercase1« {} -# $TEST$ no warning "Names of schemas should be UpperCamelCase." +// $TEST$ no warning "Names of schemas should be UpperCamelCase." schema »`SchemaUppercase2`« {} -# $TEST$ warning "Names of schemas should be UpperCamelCase." +// $TEST$ warning "Names of schemas should be UpperCamelCase." schema »schemaLowercase« {} -# $TEST$ warning "Names of schemas should be UpperCamelCase." +// $TEST$ warning "Names of schemas should be UpperCamelCase." schema »_schemaUnderscore« {} -# $TEST$ warning "Names of schemas should be UpperCamelCase." +// $TEST$ warning "Names of schemas should be UpperCamelCase." schema »Schema_Snake_Case« {} diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/segments.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/segments.sdstest index 38d40953..b06585eb 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/segments.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/segments.sdstest @@ -1,12 +1,12 @@ package tests.validation.names.casing -# $TEST$ warning "Names of segments should be lowerCamelCase." +// $TEST$ warning "Names of segments should be lowerCamelCase." segment »SegmentUppercase«() {} -# $TEST$ no warning "Names of segments should be lowerCamelCase." +// $TEST$ no warning "Names of segments should be lowerCamelCase." segment »segmentLowercase1«() {} -# $TEST$ no warning "Names of segments should be lowerCamelCase." +// $TEST$ no warning "Names of segments should be lowerCamelCase." segment »`segmentLowercase2`«() {} -# $TEST$ warning "Names of segments should be lowerCamelCase." +// $TEST$ warning "Names of segments should be lowerCamelCase." segment »_segmentUnderscore«() {} -# $TEST$ warning "Names of segments should be lowerCamelCase." +// $TEST$ warning "Names of segments should be lowerCamelCase." segment »segment_snake_case«() {} diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/type parameters.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/type parameters.sdstest index 9e2bf7eb..267bec76 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/type parameters.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/type parameters.sdstest @@ -1,14 +1,14 @@ package tests.validation.names.casing fun myFunction3< - # $TEST$ no warning "Names of type parameters should be UpperCamelCase." + // $TEST$ no warning "Names of type parameters should be UpperCamelCase." »TypeParameterUppercase1«, - # $TEST$ no warning "Names of type parameters should be UpperCamelCase." + // $TEST$ no warning "Names of type parameters should be UpperCamelCase." »`TypeParameterUppercase2`«, - # $TEST$ warning "Names of type parameters should be UpperCamelCase." + // $TEST$ warning "Names of type parameters should be UpperCamelCase." »typeParameterLowercase«, - # $TEST$ warning "Names of type parameters should be UpperCamelCase." + // $TEST$ warning "Names of type parameters should be UpperCamelCase." »_typeParameterUnderscore«, - # $TEST$ warning "Names of type parameters should be UpperCamelCase." + // $TEST$ warning "Names of type parameters should be UpperCamelCase." »Type_Parameter_Snake_Case« >() diff --git a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/annotations.sdstest b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/annotations.sdstest index de2b2d78..2f1ed513 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/annotations.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/annotations.sdstest @@ -1,7 +1,7 @@ package tests.validation.names.blockLambdaPrefix -# $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." +// $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." annotation »__gen_0« -# $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." +// $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." annotation »_gen_1« diff --git a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/attributes.sdstest b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/attributes.sdstest index 0dcf4433..410cd100 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/attributes.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/attributes.sdstest @@ -1,9 +1,9 @@ package tests.validation.names.blockLambdaPrefix class MyClass { - # $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." + // $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." attr »__gen_0«: Int - # $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." + // $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." attr »_gen_1«: Int } diff --git a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/block lambda results.sdstest b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/block lambda results.sdstest index 1f092d73..dcb4646b 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/block lambda results.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/block lambda results.sdstest @@ -2,10 +2,10 @@ package tests.validation.names.blockLambdaPrefix pipeline myPipeline2 { () { - # $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." + // $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." yield »__gen_0« = 1; - # $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." + // $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." yield »_gen_1« = 1; }; } diff --git a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/classes.sdstest b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/classes.sdstest index 0eb9ea1f..d7e77027 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/classes.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/classes.sdstest @@ -1,7 +1,7 @@ package tests.validation.names.blockLambdaPrefix -# $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." +// $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." class »__gen_0« -# $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." +// $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." class »_gen_1« diff --git a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/enum variants.sdstest b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/enum variants.sdstest index 7c352b41..d69569bd 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/enum variants.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/enum variants.sdstest @@ -1,9 +1,9 @@ package tests.validation.names.blockLambdaPrefix enum MyEnum { - # $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." + // $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." »__gen_0« - # $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." + // $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." »_gen_1« } diff --git a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/enums.sdstest b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/enums.sdstest index 4d1d05e4..c549ec75 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/enums.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/enums.sdstest @@ -1,7 +1,7 @@ package tests.validation.names.blockLambdaPrefix -# $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." +// $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." enum »__gen_0« -# $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." +// $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." enum »_gen_1« diff --git a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/functions.sdstest b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/functions.sdstest index e263101b..bdd235e7 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/functions.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/functions.sdstest @@ -1,7 +1,7 @@ package tests.validation.names.blockLambdaPrefix -# $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." +// $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." fun »__gen_0«() -# $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." +// $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." fun »_gen_1«() diff --git a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/no package name.sdstest b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/no package name.sdstest index 1078f95c..961d17e5 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/no package name.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/no package name.sdstest @@ -1 +1 @@ -# $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." +// $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." diff --git a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/package name with codegen prefix.sdstest b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/package name with codegen prefix.sdstest index 6d083e3f..72430e42 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/package name with codegen prefix.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/package name with codegen prefix.sdstest @@ -1,2 +1,2 @@ -# $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." +// $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." package »__gen_0« diff --git a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/package name without codegen prefix.sdstest b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/package name without codegen prefix.sdstest index 74a1d36e..56bc1da4 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/package name without codegen prefix.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/package name without codegen prefix.sdstest @@ -1,2 +1,2 @@ -# $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." +// $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." package »_gen_1« diff --git a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/parameters.sdstest b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/parameters.sdstest index f1c36bd1..6fc81e57 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/parameters.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/parameters.sdstest @@ -1,9 +1,9 @@ package tests.validation.names.blockLambdaPrefix fun myFunction1( - # $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." + // $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." »__gen_0«: Int, - # $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." + // $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." »_gen_1«: Int, ) diff --git a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/pipelines.sdstest b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/pipelines.sdstest index cc0724f1..e5da70f5 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/pipelines.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/pipelines.sdstest @@ -1,7 +1,7 @@ package tests.validation.names.blockLambdaPrefix -# $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." +// $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." pipeline »__gen_0« {} -# $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." +// $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." pipeline »_gen_1« {} diff --git a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/placeholders.sdstest b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/placeholders.sdstest index 7933fd4b..7bb4abb1 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/placeholders.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/placeholders.sdstest @@ -1,9 +1,9 @@ package tests.validation.names.blockLambdaPrefix pipeline myPipeline1 { - # $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." + // $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." val »__gen_0« = 1; - # $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." + // $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." val »_gen_1« = 1; } diff --git a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/results.sdstest b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/results.sdstest index 23be1a97..654e3798 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/results.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/results.sdstest @@ -1,9 +1,9 @@ package tests.validation.names.blockLambdaPrefix fun myFunction2() -> ( - # $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." + // $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." »__gen_0«: Int, - # $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." + // $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." »_gen_1«: Int, ) diff --git a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/schemas.sdstest b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/schemas.sdstest index 17445874..7ec0a8ad 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/schemas.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/schemas.sdstest @@ -1,7 +1,7 @@ package tests.validation.names.blockLambdaPrefix -# $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." +// $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." schema »__gen_0« {} -# $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." +// $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." schema »_gen_1« {} diff --git a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/segments.sdstest b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/segments.sdstest index 42dae59c..fe7c64e4 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/segments.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/segments.sdstest @@ -1,7 +1,7 @@ package tests.validation.names.blockLambdaPrefix -# $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." +// $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." segment »__gen_0«() {} -# $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." +// $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." segment »_gen_1«() {} diff --git a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/type parameters.sdstest b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/type parameters.sdstest index 17ffc0ee..71f70028 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/type parameters.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/type parameters.sdstest @@ -1,9 +1,9 @@ package tests.validation.names.blockLambdaPrefix fun myFunction3< - # $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." + // $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." »__gen_0«, - # $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." + // $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." »_gen_1«, >() diff --git a/packages/ttsl-lang/tests/resources/validation/names/core names/in safeds lang.sdstest b/packages/ttsl-lang/tests/resources/validation/names/core names/in safeds lang.sdstest index 313fe0f9..e3a02f0a 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/core names/in safeds lang.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/core names/in safeds lang.sdstest @@ -1,4 +1,4 @@ package safeds.lang -# $TEST$ no error "Names of core declarations must not be used for own declarations." +// $TEST$ no error "Names of core declarations must not be used for own declarations." annotation »Number« diff --git a/packages/ttsl-lang/tests/resources/validation/names/core names/main.sdstest b/packages/ttsl-lang/tests/resources/validation/names/core names/main.sdstest index 03e5f4d2..78ccb7d0 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/core names/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/core names/main.sdstest @@ -1,7 +1,7 @@ package tests.validation.names.coreNames -# $TEST$ error "Names of core declarations must not be used for own declarations." +// $TEST$ error "Names of core declarations must not be used for own declarations." annotation »Any« -# $TEST$ no error "Names of core declarations must not be used for own declarations." +// $TEST$ no error "Names of core declarations must not be used for own declarations." annotation »Any1« diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/main.sdstest b/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/main.sdstest index b95de097..433eb345 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/main.sdstest @@ -1,78 +1,78 @@ package tests.validation.names.acrossFiles -# $TEST$ error "Multiple declarations in this package have the name 'DuplicateAnnotation'." +// $TEST$ error "Multiple declarations in this package have the name 'DuplicateAnnotation'." annotation »DuplicateAnnotation« -# $TEST$ error "Multiple declarations in this package have the name 'DuplicateClass'." +// $TEST$ error "Multiple declarations in this package have the name 'DuplicateClass'." class »DuplicateClass« -# $TEST$ error "Multiple declarations in this package have the name 'DuplicateEnum'." +// $TEST$ error "Multiple declarations in this package have the name 'DuplicateEnum'." enum »DuplicateEnum« -# $TEST$ error "Multiple declarations in this package have the name 'duplicateFunction'." +// $TEST$ error "Multiple declarations in this package have the name 'duplicateFunction'." fun »duplicateFunction«() -# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." pipeline »duplicatePipeline« {} -# $TEST$ error "Multiple declarations in this package have the name 'DuplicateSchema'." +// $TEST$ error "Multiple declarations in this package have the name 'DuplicateSchema'." schema »DuplicateSchema« {} -# $TEST$ error "Multiple declarations in this package have the name 'duplicatePublicSegment'." +// $TEST$ error "Multiple declarations in this package have the name 'duplicatePublicSegment'." segment »duplicatePublicSegment«() {} -# $TEST$ error "Multiple declarations in this package have the name 'duplicateInternalSegment'." +// $TEST$ error "Multiple declarations in this package have the name 'duplicateInternalSegment'." internal segment »duplicateInternalSegment«() {} -# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." private segment »duplicatePrivateSegment«() {} -# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." annotation »UniqueAnnotation« -# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." class »UniqueClass« -# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." enum »UniqueEnum« -# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." fun »uniqueFunction«() -# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." pipeline »uniquePipeline« {} -# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." schema »UniqueSchema« {} -# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." segment »uniquePublicSegment«() {} -# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." internal segment »uniqueInternalSegment«() {} -# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." private segment »uniquePrivateSegment«() {} -# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." annotation »MyAnnotation« -# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." annotation »MyAnnotation« -# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." class »MyClass« -# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." class »MyClass« -# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." enum »MyEnum« -# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." enum »MyEnum« -# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." fun »myFunction«() -# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." fun »myFunction«() -# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." pipeline »myPipeline« {} -# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." pipeline »myPipeline« {} -# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." schema »MySchema« {} -# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." schema »MySchema« {} -# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." segment »myPublicSegment«() {} -# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." segment »myPublicSegment«() {} -# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." internal segment »myInternalSegment«() {} -# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." internal segment »myInternalSegment«() {} -# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." private segment »myPrivateSegment«() {} -# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." private segment »myPrivateSegment«() {} diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/other package.sdstest b/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/other package.sdstest index b61ab2b3..84389abf 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/other package.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/other package.sdstest @@ -1,20 +1,20 @@ package tests.validation.names.acrossFiles.other -# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." annotation »UniqueAnnotation« -# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." class »UniqueClass« -# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." enum »UniqueEnum« -# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." fun »uniqueFunction«() -# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." pipeline »uniquePipeline« {} -# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." schema »UniqueSchema« {} -# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." segment »uniquePublicSegment«() {} -# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." internal segment »uniqueInternalSegment«() {} -# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." private segment »uniquePrivateSegment«() {} diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/safeds 1.sdstest b/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/safeds 1.sdstest index 92ca0c67..605fa9d5 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/safeds 1.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/safeds 1.sdstest @@ -4,24 +4,24 @@ package safeds.lang * Declarations that only occur a second time in builtin files should be excluded, so we don't get errors while editing them. */ -# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." class »Any« -# $TEST$ error "Multiple builtin declarations have the name 'DuplicateAnnotation'." +// $TEST$ error "Multiple builtin declarations have the name 'DuplicateAnnotation'." annotation »DuplicateAnnotation« -# $TEST$ error "Multiple builtin declarations have the name 'DuplicateClass'." +// $TEST$ error "Multiple builtin declarations have the name 'DuplicateClass'." class »DuplicateClass« -# $TEST$ error "Multiple builtin declarations have the name 'DuplicateEnum'." +// $TEST$ error "Multiple builtin declarations have the name 'DuplicateEnum'." enum »DuplicateEnum« -# $TEST$ error "Multiple builtin declarations have the name 'duplicateFunction'." +// $TEST$ error "Multiple builtin declarations have the name 'duplicateFunction'." fun »duplicateFunction«() -# $TEST$ no error r"Multiple builtin declarations have the name '\w*'\." +// $TEST$ no error r"Multiple builtin declarations have the name '\w*'\." pipeline »duplicatePipeline« {} -# $TEST$ error "Multiple builtin declarations have the name 'DuplicateSchema'." +// $TEST$ error "Multiple builtin declarations have the name 'DuplicateSchema'." schema »DuplicateSchema« {} -# $TEST$ error "Multiple builtin declarations have the name 'duplicatePublicSegment'." +// $TEST$ error "Multiple builtin declarations have the name 'duplicatePublicSegment'." segment »duplicatePublicSegment«() {} -# $TEST$ error "Multiple builtin declarations have the name 'duplicateInternalSegment'." +// $TEST$ error "Multiple builtin declarations have the name 'duplicateInternalSegment'." internal segment »duplicateInternalSegment«() {} -# $TEST$ no error r"Multiple builtin declarations have the name '\w*'\." +// $TEST$ no error r"Multiple builtin declarations have the name '\w*'\." private segment »duplicatePrivateSegment«() {} diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/safeds 2.sdstest b/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/safeds 2.sdstest index 4c4763d8..c0f4a34d 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/safeds 2.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/safeds 2.sdstest @@ -1,20 +1,20 @@ package safeds.lang.other -# $TEST$ error "Multiple builtin declarations have the name 'DuplicateAnnotation'." +// $TEST$ error "Multiple builtin declarations have the name 'DuplicateAnnotation'." annotation »DuplicateAnnotation« -# $TEST$ error "Multiple builtin declarations have the name 'DuplicateClass'." +// $TEST$ error "Multiple builtin declarations have the name 'DuplicateClass'." class »DuplicateClass« -# $TEST$ error "Multiple builtin declarations have the name 'DuplicateEnum'." +// $TEST$ error "Multiple builtin declarations have the name 'DuplicateEnum'." enum »DuplicateEnum« -# $TEST$ error "Multiple builtin declarations have the name 'duplicateFunction'." +// $TEST$ error "Multiple builtin declarations have the name 'duplicateFunction'." fun »duplicateFunction«() -# $TEST$ no error r"Multiple builtin declarations have the name '\w*'\." +// $TEST$ no error r"Multiple builtin declarations have the name '\w*'\." pipeline »duplicatePipeline« {} -# $TEST$ error "Multiple builtin declarations have the name 'DuplicateSchema'." +// $TEST$ error "Multiple builtin declarations have the name 'DuplicateSchema'." schema »DuplicateSchema« {} -# $TEST$ error "Multiple builtin declarations have the name 'duplicatePublicSegment'." +// $TEST$ error "Multiple builtin declarations have the name 'duplicatePublicSegment'." segment »duplicatePublicSegment«() {} -# $TEST$ error "Multiple builtin declarations have the name 'duplicateInternalSegment'." +// $TEST$ error "Multiple builtin declarations have the name 'duplicateInternalSegment'." internal segment »duplicateInternalSegment«() {} -# $TEST$ no error r"Multiple builtin declarations have the name '\w*'\." +// $TEST$ no error r"Multiple builtin declarations have the name '\w*'\." private segment »duplicatePrivateSegment«() {} diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/same package.sdstest b/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/same package.sdstest index a3686834..ea17382a 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/same package.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/same package.sdstest @@ -1,20 +1,20 @@ package tests.validation.names.acrossFiles -# $TEST$ error "Multiple declarations in this package have the name 'DuplicateAnnotation'." +// $TEST$ error "Multiple declarations in this package have the name 'DuplicateAnnotation'." annotation »DuplicateAnnotation« -# $TEST$ error "Multiple declarations in this package have the name 'DuplicateClass'." +// $TEST$ error "Multiple declarations in this package have the name 'DuplicateClass'." class »DuplicateClass« -# $TEST$ error "Multiple declarations in this package have the name 'DuplicateEnum'." +// $TEST$ error "Multiple declarations in this package have the name 'DuplicateEnum'." enum »DuplicateEnum« -# $TEST$ error "Multiple declarations in this package have the name 'duplicateFunction'." +// $TEST$ error "Multiple declarations in this package have the name 'duplicateFunction'." fun »duplicateFunction«() -# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." pipeline »duplicatePipeline« {} -# $TEST$ error "Multiple declarations in this package have the name 'DuplicateSchema'." +// $TEST$ error "Multiple declarations in this package have the name 'DuplicateSchema'." schema »DuplicateSchema« {} -# $TEST$ error "Multiple declarations in this package have the name 'duplicatePublicSegment'." +// $TEST$ error "Multiple declarations in this package have the name 'duplicatePublicSegment'." segment »duplicatePublicSegment«() {} -# $TEST$ error "Multiple declarations in this package have the name 'duplicateInternalSegment'." +// $TEST$ error "Multiple declarations in this package have the name 'duplicateInternalSegment'." internal segment »duplicateInternalSegment«() {} -# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." private segment »duplicatePrivateSegment«() {} diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in annotation/main.sdstest b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in annotation/main.sdstest index 86e23675..425a5f85 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in annotation/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in annotation/main.sdstest @@ -1,10 +1,10 @@ package tests.validation.names.duplicates.inAnnotation annotation A( - # $TEST$ no error r"A parameter with name '\w*' exists already\." + // $TEST$ no error r"A parameter with name '\w*' exists already\." »duplicateParameter«: Int, - # $TEST$ error "A parameter with name 'duplicateParameter' exists already." + // $TEST$ error "A parameter with name 'duplicateParameter' exists already." »duplicateParameter«: Int, - # $TEST$ no error r"A parameter with name '\w*' exists already\." + // $TEST$ no error r"A parameter with name '\w*' exists already\." »uniqueParameter«: Int ) diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in block lambda/main.sdstest b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in block lambda/main.sdstest index df52dd99..5a2cbd98 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in block lambda/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in block lambda/main.sdstest @@ -2,50 +2,50 @@ package tests.validation.names.duplicates.inBlockLambda pipeline p { ( - # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." »duplicateParameter«, - # $TEST$ error "A parameter or placeholder with name 'duplicateParameter' exists already." + // $TEST$ error "A parameter or placeholder with name 'duplicateParameter' exists already." »duplicateParameter«, - # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." »uniqueParameter«, - # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." »parameterAndPlaceholder«, - # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." »parameterAndResult« ) { - # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." val »duplicatePlaceholder« = 1; - # $TEST$ error "A parameter or placeholder with name 'duplicatePlaceholder' exists already." + // $TEST$ error "A parameter or placeholder with name 'duplicatePlaceholder' exists already." val »duplicatePlaceholder« = 1; - # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." val »uniquePlaceholder« = 1; - # $TEST$ error "A parameter or placeholder with name 'parameterAndPlaceholder' exists already." + // $TEST$ error "A parameter or placeholder with name 'parameterAndPlaceholder' exists already." val »parameterAndPlaceholder« = 1; - # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." val »placeholderAndResult« = 1; - # $TEST$ no error r"A result with name '\w*' exists already\." + // $TEST$ no error r"A result with name '\w*' exists already\." yield »duplicateResult« = 0; - # $TEST$ error "A result with name 'duplicateResult' exists already." + // $TEST$ error "A result with name 'duplicateResult' exists already." yield »duplicateResult« = 0; - # $TEST$ no error r"A result with name '\w*' exists already\." + // $TEST$ no error r"A result with name '\w*' exists already\." yield »uniqueResult« = 0; - # $TEST$ no error r"A result with name '\w*' exists already\." + // $TEST$ no error r"A result with name '\w*' exists already\." yield »parameterAndResult« = 0; //$TEST$ no error r"A result with name '\w*' exists already\." yield »placeholderAndResult« = 0; //$TEST$ no error r"A result with name '\w*' exists already\." yield »resultAndPlaceholder« = 0; - # $TEST$ no error "A parameter or placeholder with name '\w*' exists already\." + // $TEST$ no error "A parameter or placeholder with name '\w*' exists already\." val »resultAndPlaceholder« = 1; () { - # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." val »duplicatePlaceholder« = 1; - # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." val »parameterAndPlaceholder« = 1; - # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." val »placeholderAndResult« = 1; }; }; diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in callable type/main.sdstest b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in callable type/main.sdstest index 2076ff96..9320563e 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in callable type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in callable type/main.sdstest @@ -2,22 +2,22 @@ package tests.validation.names.duplicates.inCallableType segment s( f: ( - # $TEST$ no error r"A parameter with name '\w*' exists already\." + // $TEST$ no error r"A parameter with name '\w*' exists already\." »duplicateParameter«: Int, - # $TEST$ error "A parameter with name 'duplicateParameter' exists already." + // $TEST$ error "A parameter with name 'duplicateParameter' exists already." »duplicateParameter«: Int, - # $TEST$ no error r"A parameter with name '\w*' exists already\." + // $TEST$ no error r"A parameter with name '\w*' exists already\." »uniqueParameter«: Int, - # $TEST$ no error r"A parameter with name '\w*' exists already\." + // $TEST$ no error r"A parameter with name '\w*' exists already\." »parameterAndResult«: Int ) -> ( - # $TEST$ no error r"A result with name '\w*' exists already\." + // $TEST$ no error r"A result with name '\w*' exists already\." »duplicateResult«: Int, - # $TEST$ error "A result with name 'duplicateResult' exists already." + // $TEST$ error "A result with name 'duplicateResult' exists already." »duplicateResult«: Int, - # $TEST$ no error r"A result with name '\w*' exists already\." + // $TEST$ no error r"A result with name '\w*' exists already\." »uniqueResult«: Int, - # $TEST$ no error r"A result with name '\w*' exists already\." + // $TEST$ no error r"A result with name '\w*' exists already\." »parameterAndResult«: Int ) ) {} diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in class/main.sdstest b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in class/main.sdstest index 5c05d96c..650707e0 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in class/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in class/main.sdstest @@ -1,241 +1,241 @@ package tests.validation.names.duplicates.inClass class MyClass1< - # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »DuplicateTypeParameter«, - # $TEST$ error "A type parameter or parameter with name 'DuplicateTypeParameter' exists already." + // $TEST$ error "A type parameter or parameter with name 'DuplicateTypeParameter' exists already." »DuplicateTypeParameter«, - # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »UniqueTypeParameter«, - # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »TypeParameterAndParameter«, - # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »TypeParameterAndMember«, >( - # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »duplicateParameter«: Int, - # $TEST$ error "A type parameter or parameter with name 'duplicateParameter' exists already." + // $TEST$ error "A type parameter or parameter with name 'duplicateParameter' exists already." »duplicateParameter«: Int, - # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »uniqueParameter«: Int, - # $TEST$ error "A type parameter or parameter with name 'TypeParameterAndParameter' exists already." + // $TEST$ error "A type parameter or parameter with name 'TypeParameterAndParameter' exists already." »TypeParameterAndParameter«: Int, - # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »parameterAndMember«: Int, ) { - # $TEST$ no error r"An instance member with name '\w*' exists already\." + // $TEST$ no error r"An instance member with name '\w*' exists already\." attr »duplicateInstanceAttribute«: Int - # $TEST$ error "An instance member with name 'duplicateInstanceAttribute' exists already." + // $TEST$ error "An instance member with name 'duplicateInstanceAttribute' exists already." attr »duplicateInstanceAttribute«: Int - # $TEST$ no error r"An instance member with name '\w*' exists already\." + // $TEST$ no error r"An instance member with name '\w*' exists already\." attr »uniqueInstanceAttribute«: Int - # $TEST$ no error r"A static member with name '\w*' exists already\." + // $TEST$ no error r"A static member with name '\w*' exists already\." static attr »duplicateStaticAttribute«: Int - # $TEST$ error "A static member with name 'duplicateStaticAttribute' exists already." + // $TEST$ error "A static member with name 'duplicateStaticAttribute' exists already." static attr »duplicateStaticAttribute«: Int - # $TEST$ no error r"A static member with name '\w*' exists already\." + // $TEST$ no error r"A static member with name '\w*' exists already\." static attr »uniqueStaticAttribute«: Int - # $TEST$ no error r"A static member with name '\w*' exists already\." + // $TEST$ no error r"A static member with name '\w*' exists already\." class »DuplicateClass« - # $TEST$ error "A static member with name 'DuplicateClass' exists already." + // $TEST$ error "A static member with name 'DuplicateClass' exists already." class »DuplicateClass« - # $TEST$ no error r"A static member with name '\w*' exists already\." + // $TEST$ no error r"A static member with name '\w*' exists already\." class »UniqueClass« - # $TEST$ no error r"A static member with name '\w*' exists already\." + // $TEST$ no error r"A static member with name '\w*' exists already\." enum »DuplicateEnum« - # $TEST$ error "A static member with name 'DuplicateEnum' exists already." + // $TEST$ error "A static member with name 'DuplicateEnum' exists already." enum »DuplicateEnum« - # $TEST$ no error r"A static member with name '\w*' exists already\." + // $TEST$ no error r"A static member with name '\w*' exists already\." enum »UniqueEnum« - # $TEST$ no error r"An instance member with name '\w*' exists already\." + // $TEST$ no error r"An instance member with name '\w*' exists already\." fun »duplicateInstanceMethod«() - # $TEST$ error "An instance member with name 'duplicateInstanceMethod' exists already." + // $TEST$ error "An instance member with name 'duplicateInstanceMethod' exists already." fun »duplicateInstanceMethod«() - # $TEST$ no error r"An instance member with name '\w*' exists already\." + // $TEST$ no error r"An instance member with name '\w*' exists already\." fun »uniqueInstanceMethod«() - # $TEST$ no error r"A static member with name '\w*' exists already\." + // $TEST$ no error r"A static member with name '\w*' exists already\." static fun »duplicateStaticMethod«() - # $TEST$ error "A static member with name 'duplicateStaticMethod' exists already." + // $TEST$ error "A static member with name 'duplicateStaticMethod' exists already." static fun »duplicateStaticMethod«() - # $TEST$ no error r"A static member with name '\w*' exists already\." + // $TEST$ no error r"A static member with name '\w*' exists already\." static fun »uniqueStaticMethod«() - # $TEST$ no error r"An instance member with name '\w*' exists already\." + // $TEST$ no error r"An instance member with name '\w*' exists already\." attr »duplicateInstanceMember«: Int - # $TEST$ error "An instance member with name 'duplicateInstanceMember' exists already." + // $TEST$ error "An instance member with name 'duplicateInstanceMember' exists already." fun »duplicateInstanceMember«() - # $TEST$ no error r"A static member with name '\w*' exists already\." + // $TEST$ no error r"A static member with name '\w*' exists already\." static attr »duplicateStaticMember«: Int - # $TEST$ error "A static member with name 'duplicateStaticMember' exists already." + // $TEST$ error "A static member with name 'duplicateStaticMember' exists already." class »duplicateStaticMember« - # $TEST$ error "A static member with name 'duplicateStaticMember' exists already." + // $TEST$ error "A static member with name 'duplicateStaticMember' exists already." enum »duplicateStaticMember« - # $TEST$ error "A static member with name 'duplicateStaticMember' exists already." + // $TEST$ error "A static member with name 'duplicateStaticMember' exists already." static fun »duplicateStaticMember«() } class MyClass2< - # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »TypeParameterAndMember«, > { - # $TEST$ no error r"A.*member with name '\w*' exists already\." + // $TEST$ no error r"A.*member with name '\w*' exists already\." attr »TypeParameterAndMember«: Int - # $TEST$ no error r"A.*member with name '\w*' exists already\." + // $TEST$ no error r"A.*member with name '\w*' exists already\." attr »instanceAndStaticMember«: Int - # $TEST$ no error "r"A.*member with name '\w*' exists already\." + // $TEST$ no error "r"A.*member with name '\w*' exists already\." static attr »instanceAndStaticMember«: Int - # $TEST$ no error "r"A.*member with name '\w*' exists already\." + // $TEST$ no error "r"A.*member with name '\w*' exists already\." static attr »staticAndInstanceMember«: Int - # $TEST$ no error r"A.*member with name '\w*' exists already\." + // $TEST$ no error r"A.*member with name '\w*' exists already\." attr »staticAndInstanceMember«: Int } class MyClass3< - # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »TypeParameterAndMember«, > { - # $TEST$ no error r"A.*member with name '\w*' exists already\." + // $TEST$ no error r"A.*member with name '\w*' exists already\." static attr »TypeParameterAndMember«: Int - # $TEST$ no error r"A.*member with name '\w*' exists already\." + // $TEST$ no error r"A.*member with name '\w*' exists already\." attr »instanceAndStaticMember«: Int - # $TEST$ no error "r"A.*member with name '\w*' exists already\." + // $TEST$ no error "r"A.*member with name '\w*' exists already\." class »instanceAndStaticMember« - # $TEST$ no error "r"A.*member with name '\w*' exists already\." + // $TEST$ no error "r"A.*member with name '\w*' exists already\." class »staticAndInstanceMember« - # $TEST$ no error r"A.*member with name '\w*' exists already\." + // $TEST$ no error r"A.*member with name '\w*' exists already\." attr »staticAndInstanceMember«: Int } class MyClass4< - # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »TypeParameterAndMember«, > { - # $TEST$ no error r"A.*member with name '\w*' exists already\." + // $TEST$ no error r"A.*member with name '\w*' exists already\." class »TypeParameterAndMember« - # $TEST$ no error r"A.*member with name '\w*' exists already\." + // $TEST$ no error r"A.*member with name '\w*' exists already\." attr »instanceAndStaticMember«: Int - # $TEST$ no error "r"A.*member with name '\w*' exists already\." + // $TEST$ no error "r"A.*member with name '\w*' exists already\." enum »instanceAndStaticMember« - # $TEST$ no error "r"A.*member with name '\w*' exists already\." + // $TEST$ no error "r"A.*member with name '\w*' exists already\." enum »staticAndInstanceMember« - # $TEST$ no error r"A.*member with name '\w*' exists already\." + // $TEST$ no error r"A.*member with name '\w*' exists already\." attr »staticAndInstanceMember«: Int } class MyClass5< - # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »TypeParameterAndMember«, > { - # $TEST$ no error r"A.*member with name '\w*' exists already\." + // $TEST$ no error r"A.*member with name '\w*' exists already\." enum »TypeParameterAndMember« - # $TEST$ no error r"A.*member with name '\w*' exists already\." + // $TEST$ no error r"A.*member with name '\w*' exists already\." attr »instanceAndStaticMember«: Int - # $TEST$ no error "r"A.*member with name '\w*' exists already\." + // $TEST$ no error "r"A.*member with name '\w*' exists already\." static fun »instanceAndStaticMember«() - # $TEST$ no error "r"A.*member with name '\w*' exists already\." + // $TEST$ no error "r"A.*member with name '\w*' exists already\." static fun »staticAndInstanceMember«() - # $TEST$ no error r"A.*member with name '\w*' exists already\." + // $TEST$ no error r"A.*member with name '\w*' exists already\." attr »staticAndInstanceMember«: Int } class MyClass6< - # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »TypeParameterAndMember«, > { - # $TEST$ no error r"A.*member with name '\w*' exists already\." + // $TEST$ no error r"A.*member with name '\w*' exists already\." fun »TypeParameterAndMember«() - # $TEST$ no error r"A.*member with name '\w*' exists already\." + // $TEST$ no error r"A.*member with name '\w*' exists already\." fun »instanceAndStaticMember«() - # $TEST$ no error "r"A.*member with name '\w*' exists already\." + // $TEST$ no error "r"A.*member with name '\w*' exists already\." static attr »instanceAndStaticMember«: Int - # $TEST$ no error "r"A.*member with name '\w*' exists already\." + // $TEST$ no error "r"A.*member with name '\w*' exists already\." static attr »staticAndInstanceMember«: Int - # $TEST$ no error r"A.*member with name '\w*' exists already\." + // $TEST$ no error r"A.*member with name '\w*' exists already\." fun »staticAndInstanceMember«() } class MyClass7< - # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »TypeParameterAndMember«, > { - # $TEST$ no error r"A.*member with name '\w*' exists already\." + // $TEST$ no error r"A.*member with name '\w*' exists already\." fun »TypeParameterAndMember«() - # $TEST$ no error r"A.*member with name '\w*' exists already\." + // $TEST$ no error r"A.*member with name '\w*' exists already\." fun »instanceAndStaticMember«() - # $TEST$ no error "r"A.*member with name '\w*' exists already\." + // $TEST$ no error "r"A.*member with name '\w*' exists already\." class »instanceAndStaticMember« - # $TEST$ no error "r"A.*member with name '\w*' exists already\." + // $TEST$ no error "r"A.*member with name '\w*' exists already\." class »staticAndInstanceMember« - # $TEST$ no error r"A.*member with name '\w*' exists already\." + // $TEST$ no error r"A.*member with name '\w*' exists already\." fun »staticAndInstanceMember«() } class MyClass8( - # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »parameterAndMember«: Int, ) { - # $TEST$ no error r"A.*member with name '\w*' exists already\." + // $TEST$ no error r"A.*member with name '\w*' exists already\." attr »parameterAndMember«: Int - # $TEST$ no error r"A.*member with name '\w*' exists already\." + // $TEST$ no error r"A.*member with name '\w*' exists already\." fun »instanceAndStaticMember«() - # $TEST$ no error "r"A.*member with name '\w*' exists already\." + // $TEST$ no error "r"A.*member with name '\w*' exists already\." enum »instanceAndStaticMember« - # $TEST$ no error "r"A.*member with name '\w*' exists already\." + // $TEST$ no error "r"A.*member with name '\w*' exists already\." enum »staticAndInstanceMember« - # $TEST$ no error r"A.*member with name '\w*' exists already\." + // $TEST$ no error r"A.*member with name '\w*' exists already\." fun »staticAndInstanceMember«() } class MyClass9( - # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »parameterAndMember«: Int, ) { - # $TEST$ no error r"A.*member with name '\w*' exists already\." + // $TEST$ no error r"A.*member with name '\w*' exists already\." class »parameterAndMember« - # $TEST$ no error r"A.*member with name '\w*' exists already\." + // $TEST$ no error r"A.*member with name '\w*' exists already\." fun »instanceAndStaticMember«() - # $TEST$ no error "r"A.*member with name '\w*' exists already\." + // $TEST$ no error "r"A.*member with name '\w*' exists already\." static fun »instanceAndStaticMember«() - # $TEST$ no error "r"A.*member with name '\w*' exists already\." + // $TEST$ no error "r"A.*member with name '\w*' exists already\." static fun »staticAndInstanceMember«() - # $TEST$ no error r"A.*member with name '\w*' exists already\." + // $TEST$ no error r"A.*member with name '\w*' exists already\." fun »staticAndInstanceMember«() } class MyClass10( - # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »parameterAndMember«: Int, ) { - # $TEST$ no error r"A.*member with name '\w*' exists already\." + // $TEST$ no error r"A.*member with name '\w*' exists already\." enum »parameterAndMember« } class MyClass11( - # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »parameterAndMember«: Int, ) { - # $TEST$ no error r"A.*member with name '\w*' exists already\." + // $TEST$ no error r"A.*member with name '\w*' exists already\." fun »parameterAndMember«() } diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in enum variant/main.sdstest b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in enum variant/main.sdstest index 3149a17a..e9f30a7c 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in enum variant/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in enum variant/main.sdstest @@ -2,11 +2,11 @@ package tests.validation.names.duplicates.inEnumVariant enum MyEnum { MyEnumVariant( - # $TEST$ no error r"A parameter with name '\w*' exists already\." + // $TEST$ no error r"A parameter with name '\w*' exists already\." »duplicateParameter«: Int, - # $TEST$ error "A parameter with name 'duplicateParameter' exists already." + // $TEST$ error "A parameter with name 'duplicateParameter' exists already." »duplicateParameter«: Int, - # $TEST$ no error r"A parameter with name '\w*' exists already\." + // $TEST$ no error r"A parameter with name '\w*' exists already\." »uniqueParameter«: Int, ) } diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in enum/main.sdstest b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in enum/main.sdstest index d868bab6..08903cba 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in enum/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in enum/main.sdstest @@ -1,10 +1,10 @@ package tests.validation.names.duplicates.inEnum enum MyEnum { - # $TEST$ no error r"A variant with name '\w*' exists already\." + // $TEST$ no error r"A variant with name '\w*' exists already\." »MyVariant1« - # $TEST$ error "A variant with name 'MyVariant1' exists already." + // $TEST$ error "A variant with name 'MyVariant1' exists already." »MyVariant1« - # $TEST$ no error r"A variant with name '\w*' exists already\." + // $TEST$ no error r"A variant with name '\w*' exists already\." »MyVariant2« } diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in expression lambda/main.sdstest b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in expression lambda/main.sdstest index 88a373fd..71f4bb00 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in expression lambda/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in expression lambda/main.sdstest @@ -2,11 +2,11 @@ package tests.validation.names.duplicates.inExpressionLambda pipeline p { ( - # $TEST$ no error r"A parameter with name '\w*' exists already\." + // $TEST$ no error r"A parameter with name '\w*' exists already\." »duplicateParameter«, - # $TEST$ error "A parameter with name 'duplicateParameter' exists already." + // $TEST$ error "A parameter with name 'duplicateParameter' exists already." »duplicateParameter«, - # $TEST$ no error r"A parameter with name '\w*' exists already\." + // $TEST$ no error r"A parameter with name '\w*' exists already\." »uniqueParameter«, ) -> 1; } diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in function/main.sdstest b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in function/main.sdstest index 6f75534b..802d3412 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in function/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in function/main.sdstest @@ -1,36 +1,36 @@ package tests.validation.names.duplicates.inFunction fun myFunction< - # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »DuplicateTypeParameter«, - # $TEST$ error "A type parameter or parameter with name 'DuplicateTypeParameter' exists already." + // $TEST$ error "A type parameter or parameter with name 'DuplicateTypeParameter' exists already." »DuplicateTypeParameter«, - # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »UniqueTypeParameter«, - # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »TypeParameterAndParameter«, - # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »TypeParameterAndResult«, >( - # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »duplicateParameter«: Int, - # $TEST$ error "A type parameter or parameter with name 'duplicateParameter' exists already." + // $TEST$ error "A type parameter or parameter with name 'duplicateParameter' exists already." »duplicateParameter«: Int, - # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »uniqueParameter«: Int, - # $TEST$ error "A type parameter or parameter with name 'TypeParameterAndParameter' exists already." + // $TEST$ error "A type parameter or parameter with name 'TypeParameterAndParameter' exists already." »TypeParameterAndParameter«: Int, - # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »parameterAndResult«: Int, ) -> ( - # $TEST$ no error r"A result with name '\w*' exists already\." + // $TEST$ no error r"A result with name '\w*' exists already\." »duplicateResult« : Int, - # $TEST$ error "A result with name 'duplicateResult' exists already." + // $TEST$ error "A result with name 'duplicateResult' exists already." »duplicateResult« : Int, - # $TEST$ no error r"A result with name '\w*' exists already\." + // $TEST$ no error r"A result with name '\w*' exists already\." »uniqueResult« : Int, - # $TEST$ no error r"A result with name '\w*' exists already\." + // $TEST$ no error r"A result with name '\w*' exists already\." »parameterAndResult« : Int, - # $TEST$ no error r"A result with name '\w*' exists already\." + // $TEST$ no error r"A result with name '\w*' exists already\." »TypeParameterAndResult« : Int, ) diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in pipeline file/main.sdspipe b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in pipeline file/main.sdspipe index c0c48adc..92c59bf4 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in pipeline file/main.sdspipe +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in pipeline file/main.sdspipe @@ -1,85 +1,85 @@ package tests.validation.names.inPipelineFile -# $TEST$ no error r"A declaration with name '\w*' was imported already\." +// $TEST$ no error r"A declaration with name '\w*' was imported already\." from tests.validation.names.inPipelineFile.other import »UniqueImport« -# $TEST$ no error r"A declaration with name '\w*' was imported already\." +// $TEST$ no error r"A declaration with name '\w*' was imported already\." from tests.validation.names.inPipelineFile.other import »DuplicateImport« -# $TEST$ error "A declaration with name 'DuplicateImport' was imported already." +// $TEST$ error "A declaration with name 'DuplicateImport' was imported already." from tests.validation.names.inPipelineFile.other import »DuplicateImport« -# $TEST$ no error r"A declaration with name '\w*' was imported already\." -# $TEST$ error "A declaration with name 'DuplicateAliasedImport' was imported already." +// $TEST$ no error r"A declaration with name '\w*' was imported already\." +// $TEST$ error "A declaration with name 'DuplicateAliasedImport' was imported already." from tests.validation.names.inPipelineFile.other import »DuplicateAliasedImport«, DuplicateImport as »DuplicateAliasedImport« -# $TEST$ no error r"A declaration with name '\w*' was imported already\." +// $TEST$ no error r"A declaration with name '\w*' was imported already\." from tests.validation.names.inPipelineFile.other import »Unresolved« -# $TEST$ no error r"A declaration with name '\w*' was imported already\." +// $TEST$ no error r"A declaration with name '\w*' was imported already\." from tests.validation.names.inPipelineFile.other import »Unresolved« -# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." annotation »UniqueAnnotation« -# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." annotation »DuplicateAnnotation« -# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." annotation »DuplicateAnnotation« -# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." class »UniqueClass« -# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." class »DuplicateClass« -# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." class »DuplicateClass« -# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." enum »UniqueEnum« -# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." enum »DuplicateEnum« -# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." enum »DuplicateEnum« -# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." fun »uniqueFunction«() -# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." fun »duplicateFunction«() -# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." fun »duplicateFunction«() -# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." schema »UniqueSchema« {} -# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." schema »DuplicateSchema« {} -# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." schema »DuplicateSchema« {} -# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." pipeline »uniquePipeline« {} -# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." pipeline »duplicatePipeline« {} -# $TEST$ error "A declaration with name 'duplicatePipeline' exists already in this file." +// $TEST$ error "A declaration with name 'duplicatePipeline' exists already in this file." pipeline »duplicatePipeline« {} -# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." segment »uniqueSegment«() {} -# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." segment »duplicateSegment«() {} -# $TEST$ error "A declaration with name 'duplicateSegment' exists already in this file." +// $TEST$ error "A declaration with name 'duplicateSegment' exists already in this file." segment »duplicateSegment«() {} -# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." annotation »DuplicateDeclaration« -# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." class »DuplicateDeclaration« -# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." enum »DuplicateDeclaration« -# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." fun »DuplicateDeclaration«() -# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." schema »DuplicateDeclaration« {} -# $TEST$ error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ error r"A declaration with name '\w*' exists already in this file\." pipeline »DuplicateDeclaration« {} -# $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." +// $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." segment »DuplicateDeclaration«() {} diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in pipeline/main.sdstest b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in pipeline/main.sdstest index 577f8d9c..f53765c2 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in pipeline/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in pipeline/main.sdstest @@ -1,10 +1,10 @@ package tests.validation.names.duplicates.inPipeline pipeline p { - # $TEST$ no error r"A placeholder with name '\w*' exists already\." + // $TEST$ no error r"A placeholder with name '\w*' exists already\." val »duplicatePlaceholder« = 1; - # $TEST$ error "A placeholder with name 'duplicatePlaceholder' exists already." + // $TEST$ error "A placeholder with name 'duplicatePlaceholder' exists already." val »duplicatePlaceholder« = 1; - # $TEST$ no error r"A placeholder with name '\w*' exists already\." + // $TEST$ no error r"A placeholder with name '\w*' exists already\." val »uniquePlaceholder« = 1; } diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in schema/main.sdstest b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in schema/main.sdstest index eab9185b..735d2be7 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in schema/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in schema/main.sdstest @@ -1,10 +1,10 @@ package tests.validation.names.duplicates.inSchema schema S { - # $TEST$ no error r"A column with name '\w*' exists already\." + // $TEST$ no error r"A column with name '\w*' exists already\." »"duplicateColumn"«: Int, - # $TEST$ error "A column with name 'duplicateColumn' exists already." + // $TEST$ error "A column with name 'duplicateColumn' exists already." »"duplicateColumn"«: Int, - # $TEST$ no error r"A column with name '\w*' exists already\." + // $TEST$ no error r"A column with name '\w*' exists already\." »"uniqueColumn"«: Int, } diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in segment/main.sdstest b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in segment/main.sdstest index e8e2c548..a46b224c 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in segment/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in segment/main.sdstest @@ -1,45 +1,45 @@ package tests.validation.names.duplicates.inSegment segment mySegment( - # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." »duplicateParameter«: Int, - # $TEST$ error "A parameter or placeholder with name 'duplicateParameter' exists already." + // $TEST$ error "A parameter or placeholder with name 'duplicateParameter' exists already." »duplicateParameter«: Int, - # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." »uniqueParameter«: Int, - # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." »parameterAndPlaceholder«: Int, - # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." »parameterAndResult«: Int, ) -> ( - # $TEST$ no error r"A result with name '\w*' exists already\." + // $TEST$ no error r"A result with name '\w*' exists already\." »duplicateResult« : Int, - # $TEST$ error "A result with name 'duplicateResult' exists already." + // $TEST$ error "A result with name 'duplicateResult' exists already." »duplicateResult« : Int, - # $TEST$ no error r"A result with name '\w*' exists already\." + // $TEST$ no error r"A result with name '\w*' exists already\." »uniqueResult« : Int, - # $TEST$ no error r"A result with name '\w*' exists already\." + // $TEST$ no error r"A result with name '\w*' exists already\." »parameterAndResult« : Int, - # $TEST$ no error r"A result with name '\w*' exists already\." + // $TEST$ no error r"A result with name '\w*' exists already\." »placeholderAndResult« : Int, ) { - # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." val »duplicatePlaceholder« = 1; - # $TEST$ error "A parameter or placeholder with name 'duplicatePlaceholder' exists already." + // $TEST$ error "A parameter or placeholder with name 'duplicatePlaceholder' exists already." val »duplicatePlaceholder« = 1; - # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." val »uniquePlaceholder« = 1; - # $TEST$ error "A parameter or placeholder with name 'parameterAndPlaceholder' exists already." + // $TEST$ error "A parameter or placeholder with name 'parameterAndPlaceholder' exists already." val »parameterAndPlaceholder« = 1; - # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." val »placeholderAndResult« = 1; () { - # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." val »duplicatePlaceholder« = 1; - # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." val »parameterAndPlaceholder« = 1; - # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." val »placeholderAndResult« = 1; }; } diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in stub file/main.sdsstub b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in stub file/main.sdsstub index e9a7c6ad..867baa1f 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in stub file/main.sdsstub +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in stub file/main.sdsstub @@ -1,85 +1,85 @@ package tests.validation.names.inStubFile -# $TEST$ no error r"A declaration with name '\w*' was imported already\." +// $TEST$ no error r"A declaration with name '\w*' was imported already\." from tests.validation.names.inStubFile.other import »UniqueImport« -# $TEST$ no error r"A declaration with name '\w*' was imported already\." +// $TEST$ no error r"A declaration with name '\w*' was imported already\." from tests.validation.names.inStubFile.other import »DuplicateImport« -# $TEST$ error "A declaration with name 'DuplicateImport' was imported already." +// $TEST$ error "A declaration with name 'DuplicateImport' was imported already." from tests.validation.names.inStubFile.other import »DuplicateImport« -# $TEST$ no error r"A declaration with name '\w*' was imported already\." -# $TEST$ error "A declaration with name 'DuplicateAliasedImport' was imported already." +// $TEST$ no error r"A declaration with name '\w*' was imported already\." +// $TEST$ error "A declaration with name 'DuplicateAliasedImport' was imported already." from tests.validation.names.inStubFile.other import »DuplicateAliasedImport«, DuplicateImport as »DuplicateAliasedImport« -# $TEST$ no error r"A declaration with name '\w*' was imported already\." +// $TEST$ no error r"A declaration with name '\w*' was imported already\." from tests.validation.names.inStubFile.other import »Unresolved« -# $TEST$ no error r"A declaration with name '\w*' was imported already\." +// $TEST$ no error r"A declaration with name '\w*' was imported already\." from tests.validation.names.inStubFile.other import »Unresolved« -# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." pipeline »uniqueTest« {} -# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." pipeline »duplicateTest« {} -# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." pipeline »duplicateTest« {} -# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." segment »uniqueSegment«() {} -# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." segment »duplicateSegment«() {} -# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." segment »duplicateSegment«() {} -# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." annotation »UniqueAnnotation« -# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." annotation »DuplicateAnnotation« -# $TEST$ error "A declaration with name 'DuplicateAnnotation' exists already in this file." +// $TEST$ error "A declaration with name 'DuplicateAnnotation' exists already in this file." annotation »DuplicateAnnotation« -# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." class »UniqueClass« -# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." class »DuplicateClass« -# $TEST$ error "A declaration with name 'DuplicateClass' exists already in this file." +// $TEST$ error "A declaration with name 'DuplicateClass' exists already in this file." class »DuplicateClass« -# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." enum »UniqueEnum« -# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." enum »DuplicateEnum« -# $TEST$ error "A declaration with name 'DuplicateEnum' exists already in this file." +// $TEST$ error "A declaration with name 'DuplicateEnum' exists already in this file." enum »DuplicateEnum« -# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." fun »uniqueFunction«() -# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." fun »duplicateFunction«() -# $TEST$ error "A declaration with name 'duplicateFunction' exists already in this file." +// $TEST$ error "A declaration with name 'duplicateFunction' exists already in this file." fun »duplicateFunction«() -# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." schema »UniqueSchema« {} -# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." schema »DuplicateSchema« {} -# $TEST$ error "A declaration with name 'DuplicateSchema' exists already in this file." +// $TEST$ error "A declaration with name 'DuplicateSchema' exists already in this file." schema »DuplicateSchema« {} -# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." pipeline »DuplicateDeclaration« {} -# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." segment »DuplicateDeclaration«() {} -# $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." +// $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." annotation »DuplicateDeclaration« -# $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." +// $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." class »DuplicateDeclaration« -# $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." +// $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." enum »DuplicateDeclaration« -# $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." +// $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." fun »DuplicateDeclaration«() -# $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." +// $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." schema »DuplicateDeclaration« {} diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in test file/main.sdstest b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in test file/main.sdstest index b6641e25..acd73161 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in test file/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in test file/main.sdstest @@ -1,84 +1,84 @@ package tests.validation.names.inTestFile -# $TEST$ no error r"A declaration with name '\w*' was imported already\." +// $TEST$ no error r"A declaration with name '\w*' was imported already\." from tests.validation.names.inTestFile.other import »UniqueImport« -# $TEST$ no error r"A declaration with name '\w*' was imported already\." +// $TEST$ no error r"A declaration with name '\w*' was imported already\." from tests.validation.names.inTestFile.other import »DuplicateImport« -# $TEST$ error "A declaration with name 'DuplicateImport' was imported already." +// $TEST$ error "A declaration with name 'DuplicateImport' was imported already." from tests.validation.names.inTestFile.other import »DuplicateImport« -# $TEST$ no error r"A declaration with name '\w*' was imported already\." -# $TEST$ error "A declaration with name 'DuplicateAliasedImport' was imported already." +// $TEST$ no error r"A declaration with name '\w*' was imported already\." +// $TEST$ error "A declaration with name 'DuplicateAliasedImport' was imported already." from tests.validation.names.inTestFile.other import »DuplicateAliasedImport«, DuplicateImport as »DuplicateAliasedImport« -# $TEST$ no error r"A declaration with name '\w*' was imported already\." +// $TEST$ no error r"A declaration with name '\w*' was imported already\." from tests.validation.names.inTestFile.other import »Unresolved« -# $TEST$ no error r"A declaration with name '\w*' was imported already\." +// $TEST$ no error r"A declaration with name '\w*' was imported already\." from tests.validation.names.inTestFile.other import »Unresolved« -# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." annotation »UniqueAnnotation« -# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." annotation »DuplicateAnnotation« -# $TEST$ error "A declaration with name 'DuplicateAnnotation' exists already in this file." +// $TEST$ error "A declaration with name 'DuplicateAnnotation' exists already in this file." annotation »DuplicateAnnotation« -# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." class »UniqueClass« -# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." class »DuplicateClass« -# $TEST$ error "A declaration with name 'DuplicateClass' exists already in this file." +// $TEST$ error "A declaration with name 'DuplicateClass' exists already in this file." class »DuplicateClass« -# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." enum »UniqueEnum« -# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." enum »DuplicateEnum« -# $TEST$ error "A declaration with name 'DuplicateEnum' exists already in this file." +// $TEST$ error "A declaration with name 'DuplicateEnum' exists already in this file." enum »DuplicateEnum« -# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." fun »uniqueFunction«() -# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." fun »duplicateFunction«() -# $TEST$ error "A declaration with name 'duplicateFunction' exists already in this file." +// $TEST$ error "A declaration with name 'duplicateFunction' exists already in this file." fun »duplicateFunction«() -# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." pipeline »uniquePipeline« {} -# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." pipeline »duplicatePipeline« {} -# $TEST$ error "A declaration with name 'duplicatePipeline' exists already in this file." +// $TEST$ error "A declaration with name 'duplicatePipeline' exists already in this file." pipeline »duplicatePipeline« {} -# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." schema »UniqueSchema« {} -# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." schema »DuplicateSchema« {} -# $TEST$ error "A declaration with name 'DuplicateSchema' exists already in this file." +// $TEST$ error "A declaration with name 'DuplicateSchema' exists already in this file." schema »DuplicateSchema« {} -# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." segment »uniqueSegment«() {} -# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." segment »duplicateSegment«() {} -# $TEST$ error "A declaration with name 'duplicateSegment' exists already in this file." +// $TEST$ error "A declaration with name 'duplicateSegment' exists already in this file." segment »duplicateSegment«() {} -# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." annotation »DuplicateDeclaration« -# $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." +// $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." class »DuplicateDeclaration« -# $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." +// $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." enum »DuplicateDeclaration« -# $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." +// $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." fun »DuplicateDeclaration«() -# $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." +// $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." pipeline »DuplicateDeclaration« {} -# $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." +// $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." segment »DuplicateDeclaration«() {} -# $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." +// $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." schema »DuplicateDeclaration« {} diff --git a/packages/ttsl-lang/tests/resources/validation/other/argument lists/duplicate parameter/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/argument lists/duplicate parameter/main.sdstest index 34610ab4..244b3d03 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/argument lists/duplicate parameter/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/argument lists/duplicate parameter/main.sdstest @@ -17,21 +17,21 @@ pipeline myPipeline {} @MyAnnotation( - # $TEST$ no error "The parameter 'a' is already set." + // $TEST$ no error "The parameter 'a' is already set." »1«, - # $TEST$ error "The parameter 'a' is already set." + // $TEST$ error "The parameter 'a' is already set." »a = 1« ) @MyAnnotation( - # $TEST$ no error r"The parameter '\w+' is already set\." + // $TEST$ no error r"The parameter '\w+' is already set\." »b = 1«, - # $TEST$ error "The parameter 'b' is already set." + // $TEST$ error "The parameter 'b' is already set." »b = 1« ) @MyAnnotation( - # $TEST$ no error "The parameter 'a' is already set." + // $TEST$ no error "The parameter 'a' is already set." »a = 1«, - # $TEST$ no error r"The parameter '\w+' is already set\." + // $TEST$ no error r"The parameter '\w+' is already set\." »b = 1« ) segment test( @@ -45,101 +45,101 @@ segment test( val myAnnotationAlias = MyAnnotation; MyAnnotation( - # $TEST$ no error "The parameter 'a' is already set." + // $TEST$ no error "The parameter 'a' is already set." »1«, - # $TEST$ no error "The parameter 'a' is already set." + // $TEST$ no error "The parameter 'a' is already set." »a = 1« ); myAnnotationAlias( - # $TEST$ no error "The parameter 'b' is already set." + // $TEST$ no error "The parameter 'b' is already set." »b = 1«, - # $TEST$ no error "The parameter 'b' is already set." + // $TEST$ no error "The parameter 'b' is already set." »b = 1« ); MyAnnotation( - # $TEST$ no error "The parameter 'a' is already set." + // $TEST$ no error "The parameter 'a' is already set." »a = 1«, - # $TEST$ no error r"The parameter '\w+' is already set\." + // $TEST$ no error r"The parameter '\w+' is already set\." »b = 1« ); MyClass( - # $TEST$ no error r"The parameter '\w+' is already set\." + // $TEST$ no error r"The parameter '\w+' is already set\." »1«, - # $TEST$ error "The parameter 'a' is already set." + // $TEST$ error "The parameter 'a' is already set." »a = 1« ); MyClass( - # $TEST$ no error r"The parameter '\w+' is already set\." + // $TEST$ no error r"The parameter '\w+' is already set\." »b = 1«, - # $TEST$ error "The parameter 'b' is already set." + // $TEST$ error "The parameter 'b' is already set." »b = 1« ); MyClass( - # $TEST$ no error r"The parameter '\w+' is already set\." + // $TEST$ no error r"The parameter '\w+' is already set\." »a = 1«, - # $TEST$ no error r"The parameter '\w+' is already set\." + // $TEST$ no error r"The parameter '\w+' is already set\." »b = 1« ); MyEnum.MyEnumVariant( - # $TEST$ no error r"The parameter '\w+' is already set\." + // $TEST$ no error r"The parameter '\w+' is already set\." »1«, - # $TEST$ error "The parameter 'a' is already set." + // $TEST$ error "The parameter 'a' is already set." »a = 1« ); MyEnum.MyEnumVariant( - # $TEST$ no error r"The parameter '\w+' is already set\." + // $TEST$ no error r"The parameter '\w+' is already set\." »b = 1«, - # $TEST$ error "The parameter 'b' is already set." + // $TEST$ error "The parameter 'b' is already set." »b = 1« ); MyEnum.MyEnumVariant( - # $TEST$ no error r"The parameter '\w+' is already set\." + // $TEST$ no error r"The parameter '\w+' is already set\." »a = 1«, - # $TEST$ no error r"The parameter '\w+' is already set\." + // $TEST$ no error r"The parameter '\w+' is already set\." »b = 1« ); myFunction( - # $TEST$ no error r"The parameter '\w+' is already set\." + // $TEST$ no error r"The parameter '\w+' is already set\." »1«, - # $TEST$ error "The parameter 'a' is already set." + // $TEST$ error "The parameter 'a' is already set." »a = 1« ); myFunction( - # $TEST$ no error r"The parameter '\w+' is already set\." + // $TEST$ no error r"The parameter '\w+' is already set\." »b = 1«, - # $TEST$ error "The parameter 'b' is already set." + // $TEST$ error "The parameter 'b' is already set." »b = 1« ); myFunction( - # $TEST$ no error r"The parameter '\w+' is already set\." + // $TEST$ no error r"The parameter '\w+' is already set\." »a = 1«, - # $TEST$ no error r"The parameter '\w+' is already set\." + // $TEST$ no error r"The parameter '\w+' is already set\." »b = 1« ); myCallableType( - # $TEST$ no error r"The parameter '\w+' is already set\." + // $TEST$ no error r"The parameter '\w+' is already set\." »1«, - # $TEST$ error "The parameter 'a' is already set." + // $TEST$ error "The parameter 'a' is already set." »a = 1« ); myCallableType( - # $TEST$ no error r"The parameter '\w+' is already set\." + // $TEST$ no error r"The parameter '\w+' is already set\." »b = 1«, - # $TEST$ error "The parameter 'b' is already set." + // $TEST$ error "The parameter 'b' is already set." »b = 1« ); myCallableType( - # $TEST$ no error r"The parameter '\w+' is already set\." + // $TEST$ no error r"The parameter '\w+' is already set\." »a = 1«, - # $TEST$ no error r"The parameter '\w+' is already set\." + // $TEST$ no error r"The parameter '\w+' is already set\." »b = 1« ); @@ -147,21 +147,21 @@ segment test( val myBlockLambda = (a, b) {}; ((a, b) {})( - # $TEST$ no error r"The parameter '\w+' is already set\." + // $TEST$ no error r"The parameter '\w+' is already set\." »1«, - # $TEST$ error "The parameter 'a' is already set." + // $TEST$ error "The parameter 'a' is already set." »a = 1« ); myBlockLambda( - # $TEST$ no error r"The parameter '\w+' is already set\." + // $TEST$ no error r"The parameter '\w+' is already set\." »b = 1«, - # $TEST$ error "The parameter 'b' is already set." + // $TEST$ error "The parameter 'b' is already set." »b = 1« ); ((a, b) {})( - # $TEST$ no error r"The parameter '\w+' is already set\." + // $TEST$ no error r"The parameter '\w+' is already set\." »a = 1«, - # $TEST$ no error r"The parameter '\w+' is already set\." + // $TEST$ no error r"The parameter '\w+' is already set\." »b = 1« ); @@ -169,47 +169,47 @@ segment test( val myExpressionLambda = (a, b) -> 1; ((a, b) -> 1)( - # $TEST$ no error r"The parameter '\w+' is already set\." + // $TEST$ no error r"The parameter '\w+' is already set\." »1«, - # $TEST$ error "The parameter 'a' is already set." + // $TEST$ error "The parameter 'a' is already set." »a = 1« ); myExpressionLambda( - # $TEST$ no error r"The parameter '\w+' is already set\." + // $TEST$ no error r"The parameter '\w+' is already set\." »b = 1«, - # $TEST$ error "The parameter 'b' is already set." + // $TEST$ error "The parameter 'b' is already set." »b = 1« ); ((a, b) -> 1)( - # $TEST$ no error r"The parameter '\w+' is already set\." + // $TEST$ no error r"The parameter '\w+' is already set\." »a = 1«, - # $TEST$ no error r"The parameter '\w+' is already set\." + // $TEST$ no error r"The parameter '\w+' is already set\." »b = 1« ); myPipeline( - # $TEST$ no error r"The parameter '\w+' is already set\." + // $TEST$ no error r"The parameter '\w+' is already set\." »1«, - # $TEST$ no error r"The parameter '\w+' is already set\." + // $TEST$ no error r"The parameter '\w+' is already set\." »1« ); myPipeline( - # $TEST$ no error r"The parameter '\w+' is already set\." + // $TEST$ no error r"The parameter '\w+' is already set\." »a = 1«, - # $TEST$ no error r"The parameter '\w+' is already set\." + // $TEST$ no error r"The parameter '\w+' is already set\." »a = 1« ); unresolved( - # $TEST$ no error r"The parameter '\w+' is already set\." + // $TEST$ no error r"The parameter '\w+' is already set\." »1«, - # $TEST$ no error r"The parameter '\w+' is already set\." + // $TEST$ no error r"The parameter '\w+' is already set\." »1« ); unresolved( - # $TEST$ no error r"The parameter '\w+' is already set\." + // $TEST$ no error r"The parameter '\w+' is already set\." »a = 1«, - # $TEST$ no error r"The parameter '\w+' is already set\." + // $TEST$ no error r"The parameter '\w+' is already set\." »a = 1« ); } diff --git a/packages/ttsl-lang/tests/resources/validation/other/argument lists/missing required parameter/dont show this error if the argument list is missing altogether.sdstest b/packages/ttsl-lang/tests/resources/validation/other/argument lists/missing required parameter/dont show this error if the argument list is missing altogether.sdstest index 9f6741d3..46a3935a 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/argument lists/missing required parameter/dont show this error if the argument list is missing altogether.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/argument lists/missing required parameter/dont show this error if the argument list is missing altogether.sdstest @@ -1,6 +1,6 @@ package tests.validation.other.argumentLists.missingRequiredParameter -# $TEST$ no error r"The parameters? .* must be set here\." +// $TEST$ no error r"The parameters? .* must be set here\." @MyAnnotation segment mySegment3( diff --git a/packages/ttsl-lang/tests/resources/validation/other/argument lists/missing required parameter/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/argument lists/missing required parameter/main.sdstest index bbc6105f..167d6fea 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/argument lists/missing required parameter/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/argument lists/missing required parameter/main.sdstest @@ -16,19 +16,19 @@ segment mySegment1(a: Int, b: Int, c: Int = 0) {} pipeline myPipeline {} -# $TEST$ error "The parameters 'a', 'b' must be set here." +// $TEST$ error "The parameters 'a', 'b' must be set here." @MyAnnotation»()« -# $TEST$ error "The parameter 'b' must be set here." +// $TEST$ error "The parameter 'b' must be set here." @MyAnnotation»(1)« -# $TEST$ no error r"The parameters? .* must be set here\." +// $TEST$ no error r"The parameters? .* must be set here\." @MyAnnotation»(1, 2)« -# $TEST$ no error r"The parameters? .* must be set here\." +// $TEST$ no error r"The parameters? .* must be set here\." @MyAnnotation»(1, 2, 3)« -# $TEST$ no error r"The parameters? .* must be set here\." +// $TEST$ no error r"The parameters? .* must be set here\." @MyAnnotation»(1, 2, 3, 4)« -# $TEST$ error "The parameter 'b' must be set here." +// $TEST$ error "The parameter 'b' must be set here." @MyAnnotation»(1, c = 2)« -# $TEST$ no error r"The parameters? .* must be set here\." +// $TEST$ no error r"The parameters? .* must be set here\." @MyAnnotation»(b = 1, a = 2)« segment mySegment2( myCallableType: (a: Int, b: Int, c: Int = 0) -> () @@ -40,136 +40,136 @@ segment mySegment2( * We can never call an annotation directly and should avoid showing additional errors. */ - # $TEST$ no error r"The parameters? .* must be set here\." + // $TEST$ no error r"The parameters? .* must be set here\." MyAnnotation»()«; - # $TEST$ no error r"The parameters? .* must be set here\." + // $TEST$ no error r"The parameters? .* must be set here\." MyAnnotation»(1)«; - # $TEST$ no error r"The parameters? .* must be set here\." + // $TEST$ no error r"The parameters? .* must be set here\." MyAnnotation»(1, 2)«; - # $TEST$ no error r"The parameters? .* must be set here\." + // $TEST$ no error r"The parameters? .* must be set here\." MyAnnotation»(1, 2, 3)«; - # $TEST$ no error r"The parameters? .* must be set here\." + // $TEST$ no error r"The parameters? .* must be set here\." MyAnnotation»(1, 2, 3, 4)«; - # $TEST$ no error r"The parameters? .* must be set here\." + // $TEST$ no error r"The parameters? .* must be set here\." MyAnnotation»(1, c = 2)«; - # $TEST$ no error r"The parameters? .* must be set here\." + // $TEST$ no error r"The parameters? .* must be set here\." MyAnnotation»(b = 1, a = 2)«; - # $TEST$ error "The parameters 'a', 'b' must be set here." + // $TEST$ error "The parameters 'a', 'b' must be set here." MyClass»()«; - # $TEST$ error "The parameter 'b' must be set here." + // $TEST$ error "The parameter 'b' must be set here." MyClass»(1)«; - # $TEST$ no error r"The parameters? .* must be set here\." + // $TEST$ no error r"The parameters? .* must be set here\." MyClass»(1, 2)«; - # $TEST$ no error r"The parameters? .* must be set here\." + // $TEST$ no error r"The parameters? .* must be set here\." MyClass»(1, 2, 3)«; - # $TEST$ no error r"The parameters? .* must be set here\." + // $TEST$ no error r"The parameters? .* must be set here\." MyClass»(1, 2, 3, 4)«; - # $TEST$ error "The parameter 'b' must be set here." + // $TEST$ error "The parameter 'b' must be set here." MyClass»(1, c = 2)«; - # $TEST$ no error r"The parameters? .* must be set here\." + // $TEST$ no error r"The parameters? .* must be set here\." MyClass»(b = 1, a = 2)«; - # $TEST$ error "The parameters 'a', 'b' must be set here." + // $TEST$ error "The parameters 'a', 'b' must be set here." MyEnum.MyEnumVariant»()«; - # $TEST$ error "The parameter 'b' must be set here." + // $TEST$ error "The parameter 'b' must be set here." MyEnum.MyEnumVariant»(1)«; - # $TEST$ no error r"The parameters? .* must be set here\." + // $TEST$ no error r"The parameters? .* must be set here\." MyEnum.MyEnumVariant»(1, 2)«; - # $TEST$ no error r"The parameters? .* must be set here\." + // $TEST$ no error r"The parameters? .* must be set here\." MyEnum.MyEnumVariant»(1, 2, 3)«; - # $TEST$ no error r"The parameters? .* must be set here\." + // $TEST$ no error r"The parameters? .* must be set here\." MyEnum.MyEnumVariant»(1, 2, 3, 4)«; - # $TEST$ error "The parameter 'b' must be set here." + // $TEST$ error "The parameter 'b' must be set here." MyEnum.MyEnumVariant»(1, c = 2)«; - # $TEST$ no error r"The parameters? .* must be set here\." + // $TEST$ no error r"The parameters? .* must be set here\." MyEnum.MyEnumVariant»(b = 1, a = 2)«; - # $TEST$ error "The parameters 'a', 'b' must be set here." + // $TEST$ error "The parameters 'a', 'b' must be set here." myFunction»()«; - # $TEST$ error "The parameter 'b' must be set here." + // $TEST$ error "The parameter 'b' must be set here." myFunction»(1)«; - # $TEST$ no error r"The parameters? .* must be set here\." + // $TEST$ no error r"The parameters? .* must be set here\." myFunction»(1, 2)«; - # $TEST$ no error r"The parameters? .* must be set here\." + // $TEST$ no error r"The parameters? .* must be set here\." myFunction»(1, 2, 3)«; - # $TEST$ no error r"The parameters? .* must be set here\." + // $TEST$ no error r"The parameters? .* must be set here\." myFunction»(1, 2, 3, 4)«; - # $TEST$ error "The parameter 'b' must be set here." + // $TEST$ error "The parameter 'b' must be set here." myFunction»(1, c = 2)«; - # $TEST$ no error r"The parameters? .* must be set here\." + // $TEST$ no error r"The parameters? .* must be set here\." myFunction»(b = 1, a = 2)«; - # $TEST$ error "The parameters 'a', 'b' must be set here." + // $TEST$ error "The parameters 'a', 'b' must be set here." mySegment1»()«; - # $TEST$ error "The parameter 'b' must be set here." + // $TEST$ error "The parameter 'b' must be set here." mySegment1»(1)«; - # $TEST$ no error r"The parameters? .* must be set here\." + // $TEST$ no error r"The parameters? .* must be set here\." mySegment1»(1, 2)«; - # $TEST$ no error r"The parameters? .* must be set here\." + // $TEST$ no error r"The parameters? .* must be set here\." mySegment1»(1, 2, 3)«; - # $TEST$ no error r"The parameters? .* must be set here\." + // $TEST$ no error r"The parameters? .* must be set here\." mySegment1»(1, 2, 3, 4)«; - # $TEST$ error "The parameter 'b' must be set here." + // $TEST$ error "The parameter 'b' must be set here." mySegment1»(1, c = 2)«; - # $TEST$ no error r"The parameters? .* must be set here\." + // $TEST$ no error r"The parameters? .* must be set here\." mySegment1»(b = 1, a = 2)«; - # $TEST$ error "The parameters 'a', 'b' must be set here." + // $TEST$ error "The parameters 'a', 'b' must be set here." myCallableType»()«; - # $TEST$ error "The parameter 'b' must be set here." + // $TEST$ error "The parameter 'b' must be set here." myCallableType»(1)«; - # $TEST$ no error r"The parameters? .* must be set here\." + // $TEST$ no error r"The parameters? .* must be set here\." myCallableType»(1, 2)«; - # $TEST$ no error r"The parameters? .* must be set here\." + // $TEST$ no error r"The parameters? .* must be set here\." myCallableType»(1, 2, 3)«; - # $TEST$ no error r"The parameters? .* must be set here\." + // $TEST$ no error r"The parameters? .* must be set here\." myCallableType»(1, 2, 3, 4)«; - # $TEST$ error "The parameter 'b' must be set here." + // $TEST$ error "The parameter 'b' must be set here." myCallableType»(1, c = 2)«; - # $TEST$ no error r"The parameters? .* must be set here\." + // $TEST$ no error r"The parameters? .* must be set here\." myCallableType»(b = 1, a = 2)«; - # $TEST$ error "The parameters 'a', 'b' must be set here." + // $TEST$ error "The parameters 'a', 'b' must be set here." myBlockLambda»()«; - # $TEST$ error "The parameter 'b' must be set here." + // $TEST$ error "The parameter 'b' must be set here." myBlockLambda»(1)«; - # $TEST$ no error r"The parameters? .* must be set here\." + // $TEST$ no error r"The parameters? .* must be set here\." myBlockLambda»(1, 2)«; - # $TEST$ no error r"The parameters? .* must be set here\." + // $TEST$ no error r"The parameters? .* must be set here\." myBlockLambda»(1, 2, 3)«; - # $TEST$ no error r"The parameters? .* must be set here\." + // $TEST$ no error r"The parameters? .* must be set here\." myBlockLambda»(1, 2, 3, 4)«; - # $TEST$ error "The parameter 'b' must be set here." + // $TEST$ error "The parameter 'b' must be set here." myBlockLambda»(1, c = 2)«; - # $TEST$ no error r"The parameters? .* must be set here\." + // $TEST$ no error r"The parameters? .* must be set here\." myBlockLambda»(b = 1, a = 2)«; - # $TEST$ error "The parameters 'a', 'b' must be set here." + // $TEST$ error "The parameters 'a', 'b' must be set here." myExpressionLambda»()«; - # $TEST$ error "The parameter 'b' must be set here." + // $TEST$ error "The parameter 'b' must be set here." myExpressionLambda»(1)«; - # $TEST$ no error r"The parameters? .* must be set here\." + // $TEST$ no error r"The parameters? .* must be set here\." myExpressionLambda»(1, 2)«; - # $TEST$ no error r"The parameters? .* must be set here\." + // $TEST$ no error r"The parameters? .* must be set here\." myExpressionLambda»(1, 2, 3)«; - # $TEST$ no error r"The parameters? .* must be set here\." + // $TEST$ no error r"The parameters? .* must be set here\." myExpressionLambda»(1, 2, 3, 4)«; - # $TEST$ error "The parameter 'b' must be set here." + // $TEST$ error "The parameter 'b' must be set here." myExpressionLambda»(1, c = 2)«; - # $TEST$ no error r"The parameters? .* must be set here\." + // $TEST$ no error r"The parameters? .* must be set here\." myExpressionLambda»(b = 1, a = 2)«; - # $TEST$ no error r"The parameters? .* must be set here\." + // $TEST$ no error r"The parameters? .* must be set here\." myPipeline»()«; - # $TEST$ no error r"The parameters? .* must be set here\." + // $TEST$ no error r"The parameters? .* must be set here\." unresolved»()«; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/argument lists/must not have positional argument after named argument/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/argument lists/must not have positional argument after named argument/main.sdstest index ea2fe81f..62634ca3 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/argument lists/must not have positional argument after named argument/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/argument lists/must not have positional argument after named argument/main.sdstest @@ -2,62 +2,62 @@ package tests.validation.other.argumentLists.mustNotHavePositionalArgumentAfterN annotation MyAnnotation(a: Int, b: Int = 0, c: Int = 0, d: Int = 0) -# $TEST$ no error "After the first named argument all arguments must be named." -# $TEST$ no error "After the first named argument all arguments must be named." -# $TEST$ error "After the first named argument all arguments must be named." -# $TEST$ no error "After the first named argument all arguments must be named." -# $TEST$ error "After the first named argument all arguments must be named." +// $TEST$ no error "After the first named argument all arguments must be named." +// $TEST$ no error "After the first named argument all arguments must be named." +// $TEST$ error "After the first named argument all arguments must be named." +// $TEST$ no error "After the first named argument all arguments must be named." +// $TEST$ error "After the first named argument all arguments must be named." @MyAnnotation(»0«, »a = 1«, »2«, »b = 3«, »4«) class MyClass1 -# $TEST$ no error "After the first named argument all arguments must be named." +// $TEST$ no error "After the first named argument all arguments must be named." @MyAnnotation(»0«) class MyClass2 -# $TEST$ no error "After the first named argument all arguments must be named." +// $TEST$ no error "After the first named argument all arguments must be named." @MyAnnotation(»a = 0«) class MyClass3 -# $TEST$ no error "After the first named argument all arguments must be named." -# $TEST$ no error "After the first named argument all arguments must be named." -# $TEST$ error "After the first named argument all arguments must be named." -# $TEST$ no error "After the first named argument all arguments must be named." +// $TEST$ no error "After the first named argument all arguments must be named." +// $TEST$ no error "After the first named argument all arguments must be named." +// $TEST$ error "After the first named argument all arguments must be named." +// $TEST$ no error "After the first named argument all arguments must be named." @UnresolvedAnnotation(»0«, »a = 1«, »2«, »b = 3«) class MyClass4 -# $TEST$ no error "After the first named argument all arguments must be named." +// $TEST$ no error "After the first named argument all arguments must be named." @UnresolvedAnnotation(»0«) class MyClass5 -# $TEST$ no error "After the first named argument all arguments must be named." +// $TEST$ no error "After the first named argument all arguments must be named." @UnresolvedAnnotation(»a = 0«) class MyClass3 fun f(a: Int, b: Int = 0, c: Int = 0, d: Int = 0) pipeline myPipeline { - # $TEST$ no error "After the first named argument all arguments must be named." - # $TEST$ no error "After the first named argument all arguments must be named." - # $TEST$ error "After the first named argument all arguments must be named." - # $TEST$ no error "After the first named argument all arguments must be named." - # $TEST$ error "After the first named argument all arguments must be named." + // $TEST$ no error "After the first named argument all arguments must be named." + // $TEST$ no error "After the first named argument all arguments must be named." + // $TEST$ error "After the first named argument all arguments must be named." + // $TEST$ no error "After the first named argument all arguments must be named." + // $TEST$ error "After the first named argument all arguments must be named." f(»0«, »a = 1«, »2«, »b = 3«, »4«); - # $TEST$ no error "After the first named argument all arguments must be named." + // $TEST$ no error "After the first named argument all arguments must be named." f(»0«); - # $TEST$ no error "After the first named argument all arguments must be named." + // $TEST$ no error "After the first named argument all arguments must be named." f(»a = 0«); - # $TEST$ no error "After the first named argument all arguments must be named." - # $TEST$ no error "After the first named argument all arguments must be named." - # $TEST$ error "After the first named argument all arguments must be named." - # $TEST$ no error "After the first named argument all arguments must be named." + // $TEST$ no error "After the first named argument all arguments must be named." + // $TEST$ no error "After the first named argument all arguments must be named." + // $TEST$ error "After the first named argument all arguments must be named." + // $TEST$ no error "After the first named argument all arguments must be named." unresolvedCallable(»0«, »a = 1«, »2«, »b = 3«); - # $TEST$ no error "After the first named argument all arguments must be named." + // $TEST$ no error "After the first named argument all arguments must be named." unresolvedCallable(»0«); - # $TEST$ no error "After the first named argument all arguments must be named." + // $TEST$ no error "After the first named argument all arguments must be named." unresolvedCallable(»a = 0«); } diff --git a/packages/ttsl-lang/tests/resources/validation/other/argument lists/too many arguments/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/argument lists/too many arguments/main.sdstest index 9f014d51..3934b8a0 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/argument lists/too many arguments/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/argument lists/too many arguments/main.sdstest @@ -22,19 +22,19 @@ segment mySegment2(a: Int, b: Int = 0) {} pipeline myPipeline {} -# $TEST$ no error r"Expected .* arguments? but got \d*\." +// $TEST$ no error r"Expected .* arguments? but got \d*\." @MyAnnotation1»(1)« -# $TEST$ no error r"Expected .* arguments? but got \d*\." +// $TEST$ no error r"Expected .* arguments? but got \d*\." @MyAnnotation1»(1, 2)« -# $TEST$ error "Expected exactly 2 arguments but got 3." +// $TEST$ error "Expected exactly 2 arguments but got 3." @MyAnnotation1»(1, 2, 3)« -# $TEST$ no error r"Expected .* arguments? but got \d*\." +// $TEST$ no error r"Expected .* arguments? but got \d*\." @MyAnnotation2»()« -# $TEST$ no error r"Expected .* arguments? but got \d*\." +// $TEST$ no error r"Expected .* arguments? but got \d*\." @MyAnnotation2»(1)« -# $TEST$ no error r"Expected .* arguments? but got \d*\." +// $TEST$ no error r"Expected .* arguments? but got \d*\." @MyAnnotation2»(1, 2)« -# $TEST$ error "Expected between 1 and 2 arguments but got 3." +// $TEST$ error "Expected between 1 and 2 arguments but got 3." @MyAnnotation2»(1, 2, 3)« segment mySegment3( myCallableType1: (a: Int, b: Int) -> (), @@ -51,136 +51,136 @@ segment mySegment3( * We can never call an annotation directly and should avoid showing additional errors. */ - # $TEST$ no error r"Expected .* arguments? but got \d*\." + // $TEST$ no error r"Expected .* arguments? but got \d*\." MyAnnotation1»(1)«; - # $TEST$ no error r"Expected .* arguments? but got \d*\." + // $TEST$ no error r"Expected .* arguments? but got \d*\." MyAnnotation1»(1, 2)«; - # $TEST$ no error r"Expected .* arguments? but got \d*\." + // $TEST$ no error r"Expected .* arguments? but got \d*\." MyAnnotation1»(1, 2, 3)«; - # $TEST$ no error r"Expected .* arguments? but got \d*\." + // $TEST$ no error r"Expected .* arguments? but got \d*\." MyAnnotation2»()«; - # $TEST$ no error r"Expected .* arguments? but got \d*\." + // $TEST$ no error r"Expected .* arguments? but got \d*\." MyAnnotation2»(1)«; - # $TEST$ no error r"Expected .* arguments? but got \d*\." + // $TEST$ no error r"Expected .* arguments? but got \d*\." MyAnnotation2»(1, 2)«; - # $TEST$ no error r"Expected .* arguments? but got \d*\." + // $TEST$ no error r"Expected .* arguments? but got \d*\." MyAnnotation2»(1, 2, 3)«; - # $TEST$ no error r"Expected .* arguments? but got \d*\." + // $TEST$ no error r"Expected .* arguments? but got \d*\." MyClass1»(1)«; - # $TEST$ no error r"Expected .* arguments? but got \d*\." + // $TEST$ no error r"Expected .* arguments? but got \d*\." MyClass1»(1, 2)«; - # $TEST$ error "Expected exactly 2 arguments but got 3." + // $TEST$ error "Expected exactly 2 arguments but got 3." MyClass1»(1, 2, 3)«; - # $TEST$ no error r"Expected .* arguments? but got \d*\." + // $TEST$ no error r"Expected .* arguments? but got \d*\." MyClass2»()«; - # $TEST$ no error r"Expected .* arguments? but got \d*\." + // $TEST$ no error r"Expected .* arguments? but got \d*\." MyClass2»(1)«; - # $TEST$ no error r"Expected .* arguments? but got \d*\." + // $TEST$ no error r"Expected .* arguments? but got \d*\." MyClass2»(1, 2)«; - # $TEST$ error "Expected between 1 and 2 arguments but got 3." + // $TEST$ error "Expected between 1 and 2 arguments but got 3." MyClass2»(1, 2, 3)«; - # $TEST$ no error r"Expected .* arguments? but got \d*\." + // $TEST$ no error r"Expected .* arguments? but got \d*\." MyEnum.MyEnumVariant1»(1)«; - # $TEST$ no error r"Expected .* arguments? but got \d*\." + // $TEST$ no error r"Expected .* arguments? but got \d*\." MyEnum.MyEnumVariant1»(1, 2)«; - # $TEST$ error "Expected exactly 2 arguments but got 3." + // $TEST$ error "Expected exactly 2 arguments but got 3." MyEnum.MyEnumVariant1»(1, 2, 3)«; - # $TEST$ no error r"Expected .* arguments? but got \d*\." + // $TEST$ no error r"Expected .* arguments? but got \d*\." MyEnum.MyEnumVariant2»()«; - # $TEST$ no error r"Expected .* arguments? but got \d*\." + // $TEST$ no error r"Expected .* arguments? but got \d*\." MyEnum.MyEnumVariant2»(1)«; - # $TEST$ no error r"Expected .* arguments? but got \d*\." + // $TEST$ no error r"Expected .* arguments? but got \d*\." MyEnum.MyEnumVariant2»(1, 2)«; - # $TEST$ error "Expected between 1 and 2 arguments but got 3." + // $TEST$ error "Expected between 1 and 2 arguments but got 3." MyEnum.MyEnumVariant2»(1, 2, 3)«; - # $TEST$ no error r"Expected .* arguments? but got \d*\." + // $TEST$ no error r"Expected .* arguments? but got \d*\." myFunction1»(1)«; - # $TEST$ no error r"Expected .* arguments? but got \d*\." + // $TEST$ no error r"Expected .* arguments? but got \d*\." myFunction1»(1, 2)«; - # $TEST$ error "Expected exactly 2 arguments but got 3." + // $TEST$ error "Expected exactly 2 arguments but got 3." myFunction1»(1, 2, 3)«; - # $TEST$ no error r"Expected .* arguments? but got \d*\." + // $TEST$ no error r"Expected .* arguments? but got \d*\." myFunction2»()«; - # $TEST$ no error r"Expected .* arguments? but got \d*\." + // $TEST$ no error r"Expected .* arguments? but got \d*\." myFunction2»(1)«; - # $TEST$ no error r"Expected .* arguments? but got \d*\." + // $TEST$ no error r"Expected .* arguments? but got \d*\." myFunction2»(1, 2)«; - # $TEST$ error "Expected between 1 and 2 arguments but got 3." + // $TEST$ error "Expected between 1 and 2 arguments but got 3." myFunction2»(1, 2, 3)«; - # $TEST$ no error r"Expected .* arguments? but got \d*\." + // $TEST$ no error r"Expected .* arguments? but got \d*\." mySegment1»(1)«; - # $TEST$ no error r"Expected .* arguments? but got \d*\." + // $TEST$ no error r"Expected .* arguments? but got \d*\." mySegment1»(1, 2)«; - # $TEST$ error "Expected exactly 2 arguments but got 3." + // $TEST$ error "Expected exactly 2 arguments but got 3." mySegment1»(1, 2, 3)«; - # $TEST$ no error r"Expected .* arguments? but got \d*\." + // $TEST$ no error r"Expected .* arguments? but got \d*\." mySegment2»()«; - # $TEST$ no error r"Expected .* arguments? but got \d*\." + // $TEST$ no error r"Expected .* arguments? but got \d*\." mySegment2»(1)«; - # $TEST$ no error r"Expected .* arguments? but got \d*\." + // $TEST$ no error r"Expected .* arguments? but got \d*\." mySegment2»(1, 2)«; - # $TEST$ error "Expected between 1 and 2 arguments but got 3." + // $TEST$ error "Expected between 1 and 2 arguments but got 3." mySegment2»(1, 2, 3)«; - # $TEST$ no error r"Expected .* arguments? but got \d*\." + // $TEST$ no error r"Expected .* arguments? but got \d*\." myCallableType1»(1)«; - # $TEST$ no error r"Expected .* arguments? but got \d*\." + // $TEST$ no error r"Expected .* arguments? but got \d*\." myCallableType1»(1, 2)«; - # $TEST$ error "Expected exactly 2 arguments but got 3." + // $TEST$ error "Expected exactly 2 arguments but got 3." myCallableType1»(1, 2, 3)«; - # $TEST$ no error r"Expected .* arguments? but got \d*\." + // $TEST$ no error r"Expected .* arguments? but got \d*\." myCallableType2»()«; - # $TEST$ no error r"Expected .* arguments? but got \d*\." + // $TEST$ no error r"Expected .* arguments? but got \d*\." myCallableType2»(1)«; - # $TEST$ no error r"Expected .* arguments? but got \d*\." + // $TEST$ no error r"Expected .* arguments? but got \d*\." myCallableType2»(1, 2)«; - # $TEST$ error "Expected between 1 and 2 arguments but got 3." + // $TEST$ error "Expected between 1 and 2 arguments but got 3." myCallableType2»(1, 2, 3)«; - # $TEST$ no error r"Expected .* arguments? but got \d*\." + // $TEST$ no error r"Expected .* arguments? but got \d*\." myBlockLambda1»(1)«; - # $TEST$ no error r"Expected .* arguments? but got \d*\." + // $TEST$ no error r"Expected .* arguments? but got \d*\." myBlockLambda1»(1, 2)«; - # $TEST$ error "Expected exactly 2 arguments but got 3." + // $TEST$ error "Expected exactly 2 arguments but got 3." myBlockLambda1»(1, 2, 3)«; - # $TEST$ no error r"Expected .* arguments? but got \d*\." + // $TEST$ no error r"Expected .* arguments? but got \d*\." myBlockLambda2»()«; - # $TEST$ no error r"Expected .* arguments? but got \d*\." + // $TEST$ no error r"Expected .* arguments? but got \d*\." myBlockLambda2»(1)«; - # $TEST$ no error r"Expected .* arguments? but got \d*\." + // $TEST$ no error r"Expected .* arguments? but got \d*\." myBlockLambda2»(1, 2)«; - # $TEST$ error "Expected between 1 and 2 arguments but got 3." + // $TEST$ error "Expected between 1 and 2 arguments but got 3." myBlockLambda2»(1, 2, 3)«; - # $TEST$ no error r"Expected .* arguments? but got \d*\." + // $TEST$ no error r"Expected .* arguments? but got \d*\." myExpressionLambda1»(1)«; - # $TEST$ no error r"Expected .* arguments? but got \d*\." + // $TEST$ no error r"Expected .* arguments? but got \d*\." myExpressionLambda1»(1, 2)«; - # $TEST$ error "Expected exactly 2 arguments but got 3." + // $TEST$ error "Expected exactly 2 arguments but got 3." myExpressionLambda1»(1, 2, 3)«; - # $TEST$ no error r"Expected .* arguments? but got \d*\." + // $TEST$ no error r"Expected .* arguments? but got \d*\." myExpressionLambda2»()«; - # $TEST$ no error r"Expected .* arguments? but got \d*\." + // $TEST$ no error r"Expected .* arguments? but got \d*\." myExpressionLambda2»(1)«; - # $TEST$ no error r"Expected .* arguments? but got \d*\." + // $TEST$ no error r"Expected .* arguments? but got \d*\." myExpressionLambda2»(1, 2)«; - # $TEST$ error "Expected between 1 and 2 arguments but got 3." + // $TEST$ error "Expected between 1 and 2 arguments but got 3." myExpressionLambda2»(1, 2, 3)«; - # $TEST$ no error r"Expected .* arguments? but got \d*\." + // $TEST$ no error r"Expected .* arguments? but got \d*\." myPipeline»(1)«; - # $TEST$ no error r"Expected .* arguments? but got \d*\." + // $TEST$ no error r"Expected .* arguments? but got \d*\." unresolved»(1)«; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/annotation calls/missing argument list/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/annotation calls/missing argument list/main.sdstest index b8909fa2..02d258d8 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/annotation calls/missing argument list/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/annotation calls/missing argument list/main.sdstest @@ -12,24 +12,24 @@ annotation AnnotationWithoutRequiredParameters(a: Int = 0) @Repeatable annotation AnnotationWithRequiredParameters(a: Int) -# $TEST$ no error r"The annotation '\w*' has required parameters, so an argument list must be added\." +// $TEST$ no error r"The annotation '\w*' has required parameters, so an argument list must be added\." @»AnnotationWithoutParameterList« -# $TEST$ no error r"The annotation '\w*' has required parameters, so an argument list must be added\." +// $TEST$ no error r"The annotation '\w*' has required parameters, so an argument list must be added\." @»AnnotationWithoutParameterList()« -# $TEST$ no error r"The annotation '\w*' has required parameters, so an argument list must be added\." +// $TEST$ no error r"The annotation '\w*' has required parameters, so an argument list must be added\." @»AnnotationWithEmptyParameterList« -# $TEST$ no error r"The annotation '\w*' has required parameters, so an argument list must be added\." +// $TEST$ no error r"The annotation '\w*' has required parameters, so an argument list must be added\." @»AnnotationWithEmptyParameterList()« -# $TEST$ no error r"The annotation '\w*' has required parameters, so an argument list must be added\." +// $TEST$ no error r"The annotation '\w*' has required parameters, so an argument list must be added\." @»AnnotationWithoutRequiredParameters« -# $TEST$ no error r"The annotation '\w*' has required parameters, so an argument list must be added\." +// $TEST$ no error r"The annotation '\w*' has required parameters, so an argument list must be added\." @»AnnotationWithoutRequiredParameters()« -# $TEST$ error "The annotation 'AnnotationWithRequiredParameters' has required parameters, so an argument list must be added." +// $TEST$ error "The annotation 'AnnotationWithRequiredParameters' has required parameters, so an argument list must be added." @»AnnotationWithRequiredParameters« -# $TEST$ no error r"The annotation '\w*' has required parameters, so an argument list must be added\." +// $TEST$ no error r"The annotation '\w*' has required parameters, so an argument list must be added\." @»AnnotationWithRequiredParameters()« -# $TEST$ no error r"The annotation '\w*' has required parameters, so an argument list must be added\." +// $TEST$ no error r"The annotation '\w*' has required parameters, so an argument list must be added\." @»UnresolvedAnnotation« -# $TEST$ no error r"The annotation '\w*' has required parameters, so an argument list must be added\." +// $TEST$ no error r"The annotation '\w*' has required parameters, so an argument list must be added\." @»UnresolvedAnnotation()« class MyClass diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/annotation calls/must not be used on lambda parameters/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/annotation calls/must not be used on lambda parameters/main.sdstest index 1ff4c1f3..a589ae4b 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/annotation calls/must not be used on lambda parameters/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/annotation calls/must not be used on lambda parameters/main.sdstest @@ -4,13 +4,13 @@ annotation MyAnnotation pipeline myPipeline { - # $TEST$ error "Lambda parameters must not be annotated." - # $TEST$ error "Lambda parameters must not be annotated." - # $TEST$ error "Lambda parameters must not be annotated." + // $TEST$ error "Lambda parameters must not be annotated." + // $TEST$ error "Lambda parameters must not be annotated." + // $TEST$ error "Lambda parameters must not be annotated." val f = (»@MyAnnotation« »@MyAnnotation« a: Int, »@MyAnnotation« b: Int = 3) {}; - # $TEST$ error "Lambda parameters must not be annotated." - # $TEST$ error "Lambda parameters must not be annotated." - # $TEST$ error "Lambda parameters must not be annotated." + // $TEST$ error "Lambda parameters must not be annotated." + // $TEST$ error "Lambda parameters must not be annotated." + // $TEST$ error "Lambda parameters must not be annotated." val g = (»@MyAnnotation« »@MyAnnotation« a: Int, »@MyAnnotation« b: Int = 3) -> 1; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/annotation calls/must not be used on parameters of callable types/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/annotation calls/must not be used on parameters of callable types/main.sdstest index 1e6911c6..03d930b8 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/annotation calls/must not be used on parameters of callable types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/annotation calls/must not be used on parameters of callable types/main.sdstest @@ -2,9 +2,9 @@ package tests.validation.other.declarations.annotationCalls.mustNotBeUsedOnParam annotation MyAnnotation -# $TEST$ error "Parameters of callable types must not be annotated." -# $TEST$ error "Parameters of callable types must not be annotated." -# $TEST$ error "Parameters of callable types must not be annotated." +// $TEST$ error "Parameters of callable types must not be annotated." +// $TEST$ error "Parameters of callable types must not be annotated." +// $TEST$ error "Parameters of callable types must not be annotated." segment mySegment( f: (»@MyAnnotation« »@MyAnnotation« a: Int, »@MyAnnotation« b: Int = 3) -> () ) {} diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/annotation calls/must not be used on results of callable types/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/annotation calls/must not be used on results of callable types/main.sdstest index b1376d9b..33657cbf 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/annotation calls/must not be used on results of callable types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/annotation calls/must not be used on results of callable types/main.sdstest @@ -2,9 +2,9 @@ package tests.validation.other.declarations.annotationCalls.mustNotBeUsedOnResul annotation MyAnnotation -# $TEST$ error "Results of callable types must not be annotated." -# $TEST$ error "Results of callable types must not be annotated." -# $TEST$ error "Results of callable types must not be annotated." +// $TEST$ error "Results of callable types must not be annotated." +// $TEST$ error "Results of callable types must not be annotated." +// $TEST$ error "Results of callable types must not be annotated." segment mySegment( f: () -> (»@MyAnnotation« »@MyAnnotation« a: Int, »@MyAnnotation« b: Int) ) {} diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/arguments must match parameter bounds/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/arguments must match parameter bounds/main.sdstest index da597b5a..7146498a 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/arguments must match parameter bounds/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/arguments must match parameter bounds/main.sdstest @@ -28,62 +28,62 @@ package tests.validation.other.declarations.parameterBounds.argumentsMustMatchPa } segment mySegment(p: Int) { - # $TEST$ error "The value of 'notConst' must be greater than 0 but was 0." + // $TEST$ error "The value of 'notConst' must be greater than 0 but was 0." f1(»0«); - # $TEST$ no error r"The value of '.*' must be .* but was .*\." + // $TEST$ no error r"The value of '.*' must be .* but was .*\." f1(»""«); - # $TEST$ no error r"The value of '.*' must be .* but was .*\." + // $TEST$ no error r"The value of '.*' must be .* but was .*\." f1(»p«); - # $TEST$ no error r"The value of '.*' must be .* but was .*\." + // $TEST$ no error r"The value of '.*' must be .* but was .*\." f1(»unresolved«); - # $TEST$ no error r"The value of '.*' must be .* but was .*\." + // $TEST$ no error r"The value of '.*' must be .* but was .*\." f1(unresolved = »1«); - # $TEST$ no error r"The value of '.*' must be .* but was .*\." + // $TEST$ no error r"The value of '.*' must be .* but was .*\." f2(»1«); - # $TEST$ no error r"The value of '.*' must be .* but was .*\." + // $TEST$ no error r"The value of '.*' must be .* but was .*\." f2(»""«); - # $TEST$ no error r"The value of '.*' must be .* but was .*\." + // $TEST$ no error r"The value of '.*' must be .* but was .*\." f2(»p«); - # $TEST$ no error r"The value of '.*' must be .* but was .*\." + // $TEST$ no error r"The value of '.*' must be .* but was .*\." f2(»unresolved«); - # $TEST$ no error r"The value of '.*' must be .* but was .*\." + // $TEST$ no error r"The value of '.*' must be .* but was .*\." f2(unresolved = »1«); - # $TEST$ error "The value of 'bothBounds' must be greater than 0 but was 0." + // $TEST$ error "The value of 'bothBounds' must be greater than 0 but was 0." f3(»0«); - # $TEST$ no error r"The value of '.*' must be .* but was .*\." + // $TEST$ no error r"The value of '.*' must be .* but was .*\." f3(»5«); - # $TEST$ error "The value of 'bothBounds' must be less than 10 but was 10." + // $TEST$ error "The value of 'bothBounds' must be less than 10 but was 10." f3(»10«); - # $TEST$ error "The value of 'lowerBound' must be greater than or equal to 0 but was -1." - # $TEST$ error "The value of 'indirectLowerBound' must be greater than or equal to -1 but was -2." + // $TEST$ error "The value of 'lowerBound' must be greater than or equal to 0 but was -1." + // $TEST$ error "The value of 'indirectLowerBound' must be greater than or equal to -1 but was -2." f4(»-1«, »-2«); - # $TEST$ error "The value of 'lowerBound' must be greater than or equal to 0 but was -1." - # $TEST$ no error r"The value of '.*' must be .* but was .*\." + // $TEST$ error "The value of 'lowerBound' must be greater than or equal to 0 but was -1." + // $TEST$ no error r"The value of '.*' must be .* but was .*\." f4(»-1«, »-1«); - # $TEST$ no error r"The value of '.*' must be .* but was .*\." - # $TEST$ error "The value of 'indirectLowerBound' must be greater than or equal to 0 but was -1." + // $TEST$ no error r"The value of '.*' must be .* but was .*\." + // $TEST$ error "The value of 'indirectLowerBound' must be greater than or equal to 0 but was -1." f4(»0«, »-1«); - # $TEST$ no error r"The value of '.*' must be .* but was .*\." - # $TEST$ no error r"The value of '.*' must be .* but was .*\." + // $TEST$ no error r"The value of '.*' must be .* but was .*\." + // $TEST$ no error r"The value of '.*' must be .* but was .*\." f4(»0«, »0«); - # $TEST$ error "The value of 'upperBound' must be less than or equal to 0 but was 1." - # $TEST$ error "The value of 'indirectUpperBound' must be less than or equal to 1 but was 2." + // $TEST$ error "The value of 'upperBound' must be less than or equal to 0 but was 1." + // $TEST$ error "The value of 'indirectUpperBound' must be less than or equal to 1 but was 2." f5(»1«, »2«); - # $TEST$ error "The value of 'upperBound' must be less than or equal to 0 but was 1." - # $TEST$ no error r"The value of '.*' must be .* but was .*\." + // $TEST$ error "The value of 'upperBound' must be less than or equal to 0 but was 1." + // $TEST$ no error r"The value of '.*' must be .* but was .*\." f5(»1«, »1«); - # $TEST$ no error r"The value of '.*' must be .* but was .*\." - # $TEST$ error "The value of 'indirectUpperBound' must be less than or equal to 0 but was 1." + // $TEST$ no error r"The value of '.*' must be .* but was .*\." + // $TEST$ error "The value of 'indirectUpperBound' must be less than or equal to 0 but was 1." f5(»0«, »1«); - # $TEST$ no error r"The value of '.*' must be .* but was .*\." - # $TEST$ no error r"The value of '.*' must be .* but was .*\." + // $TEST$ no error r"The value of '.*' must be .* but was .*\." + // $TEST$ no error r"The value of '.*' must be .* but was .*\." f5(»0«, »0«); - # $TEST$ error "The value of 'indirectUpperBound' must be less than or equal to -1 but was 0." + // $TEST$ error "The value of 'indirectUpperBound' must be less than or equal to -1 but was 0." f5(indirectUpperBound = »0«); - # $TEST$ no error r"The value of '.*' must be .* but was .*\." + // $TEST$ no error r"The value of '.*' must be .* but was .*\." f5(indirectUpperBound = »-1«); } diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/default values must match parameter bounds/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/default values must match parameter bounds/main.sdstest index f40bb5ac..54de5438 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/default values must match parameter bounds/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/default values must match parameter bounds/main.sdstest @@ -1,13 +1,13 @@ package tests.validation.other.declarations.parameterBounds.defaultValuesMustMatchParameterBounds @Pure fun f1( - # $TEST$ error "The value of 'notConst1' must be greater than 0 but was 0." + // $TEST$ error "The value of 'notConst1' must be greater than 0 but was 0." notConst1: Int = »0«, - # $TEST$ no error r"The value of '.*' must be .* but was .*\." + // $TEST$ no error r"The value of '.*' must be .* but was .*\." notConst2: Int = »""«, - # $TEST$ no error r"The value of '.*' must be .* but was .*\." + // $TEST$ no error r"The value of '.*' must be .* but was .*\." notConst3: Int = »p«, - # $TEST$ no error r"The value of '.*' must be .* but was .*\." + // $TEST$ no error r"The value of '.*' must be .* but was .*\." notConst4: Int = »unresolved«, ) where { notConst1 > 0, @@ -17,22 +17,22 @@ package tests.validation.other.declarations.parameterBounds.defaultValuesMustMat } @Pure fun f2( - # $TEST$ no error r"The value of '.*' must be .* but was .*\." + // $TEST$ no error r"The value of '.*' must be .* but was .*\." const unbounded1: Int = »1«, - # $TEST$ no error r"The value of '.*' must be .* but was .*\." + // $TEST$ no error r"The value of '.*' must be .* but was .*\." const unbounded2: Int = »""«, - # $TEST$ no error r"The value of '.*' must be .* but was .*\." + // $TEST$ no error r"The value of '.*' must be .* but was .*\." const unbounded3: Int = »p«, - # $TEST$ no error r"The value of '.*' must be .* but was .*\." + // $TEST$ no error r"The value of '.*' must be .* but was .*\." const unbounded4: Int = »unresolved«, ) @Pure fun f3( - # $TEST$ error "The value of 'bothBounds1' must be greater than 0 but was 0." + // $TEST$ error "The value of 'bothBounds1' must be greater than 0 but was 0." const bothBounds1: Int = »0«, - # $TEST$ no error r"The value of '.*' must be .* but was .*\." + // $TEST$ no error r"The value of '.*' must be .* but was .*\." const bothBounds2: Int= »5«, - # $TEST$ error "The value of 'bothBounds3' must be less than 10 but was 10." + // $TEST$ error "The value of 'bothBounds3' must be less than 10 but was 10." const bothBounds3: Int = »10«, ) where { bothBounds1 > 0, @@ -46,11 +46,11 @@ package tests.validation.other.declarations.parameterBounds.defaultValuesMustMat } @Pure fun f4( - # $TEST$ error "The value of 'lowerBound1' must be greater than or equal to 0 but was -1." + // $TEST$ error "The value of 'lowerBound1' must be greater than or equal to 0 but was -1." const lowerBound1: Int = »-1«, - # $TEST$ no error r"The value of '.*' must be .* but was .*\." + // $TEST$ no error r"The value of '.*' must be .* but was .*\." const lowerBound2: Int = »0«, - # $TEST$ error "Cannot verify whether the parameter bounds are always met." + // $TEST$ error "Cannot verify whether the parameter bounds are always met." const indirectLowerBound: Int = »0«, ) where { lowerBound1 >= 0, @@ -59,11 +59,11 @@ package tests.validation.other.declarations.parameterBounds.defaultValuesMustMat } @Pure fun f5( - # $TEST$ error "The value of 'upperBound1' must be less than or equal to 0 but was 1." + // $TEST$ error "The value of 'upperBound1' must be less than or equal to 0 but was 1." const upperBound1: Int = »1«, - # $TEST$ no error r"The value of '.*' must be .* but was .*\." + // $TEST$ no error r"The value of '.*' must be .* but was .*\." const upperBound2: Int = »0«, - # $TEST$ error "Cannot verify whether the parameter bounds are always met." + // $TEST$ error "Cannot verify whether the parameter bounds are always met." const indirectUpperBound: Int = »0«, ) where { upperBound1 <= 0, diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/parameter must be const/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/parameter must be const/main.sdstest index bad49358..3c494101 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/parameter must be const/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/parameter must be const/main.sdstest @@ -9,68 +9,68 @@ package tests.validation.other.declarations.parameterBounds.parameterMustBeConst const b2: Float, const b3: String ) where { - # $TEST$ error "Only constant parameters can have bounds." + // $TEST$ error "Only constant parameters can have bounds." »a1« < 0, - # $TEST$ error "Only constant parameters can have bounds." + // $TEST$ error "Only constant parameters can have bounds." »a1« <= 0, - # $TEST$ error "Only constant parameters can have bounds." + // $TEST$ error "Only constant parameters can have bounds." »a1« >= 0, - # $TEST$ error "Only constant parameters can have bounds." + // $TEST$ error "Only constant parameters can have bounds." »a1« > 0, - # $TEST$ error "Only constant parameters can have bounds." + // $TEST$ error "Only constant parameters can have bounds." »a2« < 0, - # $TEST$ error "Only constant parameters can have bounds." + // $TEST$ error "Only constant parameters can have bounds." »a2« <= 0, - # $TEST$ error "Only constant parameters can have bounds." + // $TEST$ error "Only constant parameters can have bounds." »a2« >= 0, - # $TEST$ error "Only constant parameters can have bounds." + // $TEST$ error "Only constant parameters can have bounds." »a2« > 0, - # $TEST$ no error "Only constant parameters can have bounds." + // $TEST$ no error "Only constant parameters can have bounds." »a3« < 0, - # $TEST$ no error "Only constant parameters can have bounds." + // $TEST$ no error "Only constant parameters can have bounds." »a3« <= 0, - # $TEST$ no error "Only constant parameters can have bounds." + // $TEST$ no error "Only constant parameters can have bounds." »a3« >= 0, - # $TEST$ no error "Only constant parameters can have bounds." + // $TEST$ no error "Only constant parameters can have bounds." »a3« > 0, - # $TEST$ no error "Only constant parameters can have bounds." + // $TEST$ no error "Only constant parameters can have bounds." »b1« < 0, - # $TEST$ no error "Only constant parameters can have bounds." + // $TEST$ no error "Only constant parameters can have bounds." »b1« <= 0, - # $TEST$ no error "Only constant parameters can have bounds." + // $TEST$ no error "Only constant parameters can have bounds." »b1« >= 0, - # $TEST$ no error "Only constant parameters can have bounds." + // $TEST$ no error "Only constant parameters can have bounds." »b1« > 0, - # $TEST$ no error "Only constant parameters can have bounds." + // $TEST$ no error "Only constant parameters can have bounds." »b2« < 0, - # $TEST$ no error "Only constant parameters can have bounds." + // $TEST$ no error "Only constant parameters can have bounds." »b2« <= 0, - # $TEST$ no error "Only constant parameters can have bounds." + // $TEST$ no error "Only constant parameters can have bounds." »b2« >= 0, - # $TEST$ no error "Only constant parameters can have bounds." + // $TEST$ no error "Only constant parameters can have bounds." »b2« > 0, - # $TEST$ no error "Only constant parameters can have bounds." + // $TEST$ no error "Only constant parameters can have bounds." »b3« < 0, - # $TEST$ no error "Only constant parameters can have bounds." + // $TEST$ no error "Only constant parameters can have bounds." »b3« <= 0, - # $TEST$ no error "Only constant parameters can have bounds." + // $TEST$ no error "Only constant parameters can have bounds." »b3« >= 0, - # $TEST$ no error "Only constant parameters can have bounds." + // $TEST$ no error "Only constant parameters can have bounds." »b3« > 0, - # $TEST$ no error "Only constant parameters can have bounds." + // $TEST$ no error "Only constant parameters can have bounds." »unresolved« < 0, - # $TEST$ no error "Only constant parameters can have bounds." + // $TEST$ no error "Only constant parameters can have bounds." »unresolved« <= 0, - # $TEST$ no error "Only constant parameters can have bounds." + // $TEST$ no error "Only constant parameters can have bounds." »unresolved« >= 0, - # $TEST$ no error "Only constant parameters can have bounds." + // $TEST$ no error "Only constant parameters can have bounds." »unresolved« > 0, } diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/parameter must be float or int/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/parameter must be float or int/main.sdstest index 2f370cd9..d3634119 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/parameter must be float or int/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/parameter must be float or int/main.sdstest @@ -5,40 +5,40 @@ package tests.validation.other.declarations.parameterBounds.parameterMustBeFloat p2: Float, p3: String ) where { - # $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." + // $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." »p1« < 0, - # $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." + // $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." »p1« <= 0, - # $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." + // $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." »p1« >= 0, - # $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." + // $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." »p1« > 0, - # $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." + // $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." »p2« < 0, - # $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." + // $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." »p2« <= 0, - # $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." + // $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." »p2« >= 0, - # $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." + // $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." »p2« > 0, - # $TEST$ error "Only 'Float' and 'Int' parameters can have bounds." + // $TEST$ error "Only 'Float' and 'Int' parameters can have bounds." »p3« < 0, - # $TEST$ error "Only 'Float' and 'Int' parameters can have bounds." + // $TEST$ error "Only 'Float' and 'Int' parameters can have bounds." »p3« <= 0, - # $TEST$ error "Only 'Float' and 'Int' parameters can have bounds." + // $TEST$ error "Only 'Float' and 'Int' parameters can have bounds." »p3« >= 0, - # $TEST$ error "Only 'Float' and 'Int' parameters can have bounds." + // $TEST$ error "Only 'Float' and 'Int' parameters can have bounds." »p3« > 0, - # $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." + // $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." »unresolved« < 0, - # $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." + // $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." »unresolved« <= 0, - # $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." + // $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." »unresolved« >= 0, - # $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." + // $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." »unresolved« > 0, } diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/right operand must evaluate to float constant or int constant/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/right operand must evaluate to float constant or int constant/main.sdstest index 3965dd39..3121d3d8 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/right operand must evaluate to float constant or int constant/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/right operand must evaluate to float constant or int constant/main.sdstest @@ -9,86 +9,86 @@ package tests.validation.other.declarations.parameterBounds.rightOperandMustEval const b2: Float, const b3: String, ) where { - # $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." + // $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." b1 < »0«, - # $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." + // $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." b1 <= »0«, - # $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." + // $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." b1 >= »0«, - # $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." + // $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." b1 > »0«, - # $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." + // $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." b1 < »0.5«, - # $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." + // $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." b1 <= »0.5«, - # $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." + // $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." b1 >= »0.5«, - # $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." + // $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." b1 > »0.5«, - # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 < »""«, - # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 <= »""«, - # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 >= »""«, - # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 > »""«, - # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 < »a1«, - # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 <= »a1«, - # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 >= »a1«, - # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 > »a1«, - # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 < »a2«, - # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 <= »a2«, - # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 >= »a2«, - # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 > »a2«, - # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 < »a3«, - # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 <= »a3«, - # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 >= »a3«, - # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 > »a3«, - # $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." + // $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." b1 < »b1«, - # $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." + // $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." b1 <= »b1«, - # $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." + // $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." b1 >= »b1«, - # $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." + // $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." b1 > »b1«, - # $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." + // $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." b1 < »b2«, - # $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." + // $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." b1 <= »b2«, - # $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." + // $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." b1 >= »b2«, - # $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." + // $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." b1 > »b2«, - # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 < »b3«, - # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 <= »b3«, - # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 >= »b3«, - # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 > »b3«, } diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter lists/must not have required after optional/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter lists/must not have required after optional/main.sdstest index ea9679a7..41c66761 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter lists/must not have required after optional/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter lists/must not have required after optional/main.sdstest @@ -1,118 +1,118 @@ package tests.validation.other.declarations.parameterLists.mustNotHaveRequiredAfterOptional -# $TEST$ no error "After the first optional parameter all parameters must be optional." -# $TEST$ no error "After the first optional parameter all parameters must be optional." -# $TEST$ error "After the first optional parameter all parameters must be optional." -# $TEST$ no error "After the first optional parameter all parameters must be optional." +// $TEST$ no error "After the first optional parameter all parameters must be optional." +// $TEST$ no error "After the first optional parameter all parameters must be optional." +// $TEST$ error "After the first optional parameter all parameters must be optional." +// $TEST$ no error "After the first optional parameter all parameters must be optional." annotation MyAnnotation1(»a«: Int, »b«: Int = 1, »c«: Int, »d«: Int = 2) -# $TEST$ no error "After the first optional parameter all parameters must be optional." -# $TEST$ no error "After the first optional parameter all parameters must be optional." +// $TEST$ no error "After the first optional parameter all parameters must be optional." +// $TEST$ no error "After the first optional parameter all parameters must be optional." annotation MyAnnotation2(»a«: Int, »b«: Int = 1) -# $TEST$ no error "After the first optional parameter all parameters must be optional." +// $TEST$ no error "After the first optional parameter all parameters must be optional." annotation MyAnnotation3(»a«: Int) -# $TEST$ no error "After the first optional parameter all parameters must be optional." -# $TEST$ no error "After the first optional parameter all parameters must be optional." -# $TEST$ error "After the first optional parameter all parameters must be optional." -# $TEST$ no error "After the first optional parameter all parameters must be optional." +// $TEST$ no error "After the first optional parameter all parameters must be optional." +// $TEST$ no error "After the first optional parameter all parameters must be optional." +// $TEST$ error "After the first optional parameter all parameters must be optional." +// $TEST$ no error "After the first optional parameter all parameters must be optional." class MyClass1(»a«: Int, »b«: Int = 1, »c«: Int, »d«: Int = 2) -# $TEST$ no error "After the first optional parameter all parameters must be optional." -# $TEST$ no error "After the first optional parameter all parameters must be optional." +// $TEST$ no error "After the first optional parameter all parameters must be optional." +// $TEST$ no error "After the first optional parameter all parameters must be optional." class MyClass2(»a«: Int, »b«: Int = 1) -# $TEST$ no error "After the first optional parameter all parameters must be optional." +// $TEST$ no error "After the first optional parameter all parameters must be optional." class MyClass3(»a«: Int) enum MyEnum { - # $TEST$ no error "After the first optional parameter all parameters must be optional." - # $TEST$ no error "After the first optional parameter all parameters must be optional." - # $TEST$ error "After the first optional parameter all parameters must be optional." - # $TEST$ no error "After the first optional parameter all parameters must be optional." + // $TEST$ no error "After the first optional parameter all parameters must be optional." + // $TEST$ no error "After the first optional parameter all parameters must be optional." + // $TEST$ error "After the first optional parameter all parameters must be optional." + // $TEST$ no error "After the first optional parameter all parameters must be optional." MyEnumVariant1(»a«: Int, »b«: Int = 1, »c«: Int, »d«: Int = 2) - # $TEST$ no error "After the first optional parameter all parameters must be optional." - # $TEST$ no error "After the first optional parameter all parameters must be optional." + // $TEST$ no error "After the first optional parameter all parameters must be optional." + // $TEST$ no error "After the first optional parameter all parameters must be optional." MyEnumVariant2(»a«: Int, »b«: Int = 1) - # $TEST$ no error "After the first optional parameter all parameters must be optional." + // $TEST$ no error "After the first optional parameter all parameters must be optional." MyEnumVariant3(»a«: Int) } -# $TEST$ no error "After the first optional parameter all parameters must be optional." -# $TEST$ no error "After the first optional parameter all parameters must be optional." -# $TEST$ error "After the first optional parameter all parameters must be optional." -# $TEST$ no error "After the first optional parameter all parameters must be optional." +// $TEST$ no error "After the first optional parameter all parameters must be optional." +// $TEST$ no error "After the first optional parameter all parameters must be optional." +// $TEST$ error "After the first optional parameter all parameters must be optional." +// $TEST$ no error "After the first optional parameter all parameters must be optional." fun myFunction1(»a«: Int, »b«: Int = 1, »c«: Int, »d«: Int = 2) -# $TEST$ no error "After the first optional parameter all parameters must be optional." -# $TEST$ no error "After the first optional parameter all parameters must be optional." +// $TEST$ no error "After the first optional parameter all parameters must be optional." +// $TEST$ no error "After the first optional parameter all parameters must be optional." fun myFunction2(»a«: Int, »b«: Int = 1) -# $TEST$ no error "After the first optional parameter all parameters must be optional." +// $TEST$ no error "After the first optional parameter all parameters must be optional." fun myFunction3(»a«: Int) -# $TEST$ no error "After the first optional parameter all parameters must be optional." -# $TEST$ no error "After the first optional parameter all parameters must be optional." -# $TEST$ error "After the first optional parameter all parameters must be optional." -# $TEST$ no error "After the first optional parameter all parameters must be optional." +// $TEST$ no error "After the first optional parameter all parameters must be optional." +// $TEST$ no error "After the first optional parameter all parameters must be optional." +// $TEST$ error "After the first optional parameter all parameters must be optional." +// $TEST$ no error "After the first optional parameter all parameters must be optional." segment mySegment1(»a«: Int, »b«: Int = 1, »c«: Int, »d«: Int = 2) {} -# $TEST$ no error "After the first optional parameter all parameters must be optional." -# $TEST$ no error "After the first optional parameter all parameters must be optional." +// $TEST$ no error "After the first optional parameter all parameters must be optional." +// $TEST$ no error "After the first optional parameter all parameters must be optional." segment mySegment2(»a«: Int, »b«: Int = 1) {} -# $TEST$ no error "After the first optional parameter all parameters must be optional." +// $TEST$ no error "After the first optional parameter all parameters must be optional." segment mySegment3(»a«: Int) {} pipeline myPipeline { - # $TEST$ no error "After the first optional parameter all parameters must be optional." - # $TEST$ no error "After the first optional parameter all parameters must be optional." - # $TEST$ error "After the first optional parameter all parameters must be optional." - # $TEST$ no error "After the first optional parameter all parameters must be optional." + // $TEST$ no error "After the first optional parameter all parameters must be optional." + // $TEST$ no error "After the first optional parameter all parameters must be optional." + // $TEST$ error "After the first optional parameter all parameters must be optional." + // $TEST$ no error "After the first optional parameter all parameters must be optional." (»a«: Int, »b«: Int = 1, »c«: Int, »d«: Int = 2) {}; - # $TEST$ no error "After the first optional parameter all parameters must be optional." - # $TEST$ no error "After the first optional parameter all parameters must be optional." + // $TEST$ no error "After the first optional parameter all parameters must be optional." + // $TEST$ no error "After the first optional parameter all parameters must be optional." (»a«: Int, »b«: Int = 1) {}; - # $TEST$ no error "After the first optional parameter all parameters must be optional." + // $TEST$ no error "After the first optional parameter all parameters must be optional." (»a«: Int) {}; - # $TEST$ no error "After the first optional parameter all parameters must be optional." - # $TEST$ no error "After the first optional parameter all parameters must be optional." - # $TEST$ error "After the first optional parameter all parameters must be optional." - # $TEST$ no error "After the first optional parameter all parameters must be optional." + // $TEST$ no error "After the first optional parameter all parameters must be optional." + // $TEST$ no error "After the first optional parameter all parameters must be optional." + // $TEST$ error "After the first optional parameter all parameters must be optional." + // $TEST$ no error "After the first optional parameter all parameters must be optional." (»a«: Int, »b«: Int = 1, »c«: Int, »d«: Int = 2) -> 1; - # $TEST$ no error "After the first optional parameter all parameters must be optional." - # $TEST$ no error "After the first optional parameter all parameters must be optional." + // $TEST$ no error "After the first optional parameter all parameters must be optional." + // $TEST$ no error "After the first optional parameter all parameters must be optional." (»a«: Int, »b«: Int = 1) -> 1; - # $TEST$ no error "After the first optional parameter all parameters must be optional." + // $TEST$ no error "After the first optional parameter all parameters must be optional." (»a«: Int) -> 1; } fun myFunction4( - # $TEST$ no error "After the first optional parameter all parameters must be optional." - # $TEST$ no error "After the first optional parameter all parameters must be optional." - # $TEST$ error "After the first optional parameter all parameters must be optional." - # $TEST$ no error "After the first optional parameter all parameters must be optional." + // $TEST$ no error "After the first optional parameter all parameters must be optional." + // $TEST$ no error "After the first optional parameter all parameters must be optional." + // $TEST$ error "After the first optional parameter all parameters must be optional." + // $TEST$ no error "After the first optional parameter all parameters must be optional." p1: (»a«: Int, »b«: Int = 1, »c«: Int, »d«: Int = 2) -> (), - # $TEST$ no error "After the first optional parameter all parameters must be optional." - # $TEST$ no error "After the first optional parameter all parameters must be optional." + // $TEST$ no error "After the first optional parameter all parameters must be optional." + // $TEST$ no error "After the first optional parameter all parameters must be optional." p2: (»a«: Int, »b«: Int = 1) -> (), - # $TEST$ no error "After the first optional parameter all parameters must be optional." + // $TEST$ no error "After the first optional parameter all parameters must be optional." p3: (»a«: Int) -> (), ) diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/const modifier/error.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/const modifier/error.sdstest index c12b62b9..891b8653 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/const modifier/error.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/const modifier/error.sdstest @@ -2,19 +2,19 @@ package tests.validation.other.declarations.parameters.illegalConstModifier fun f( g: ( - # $TEST$ error "The const modifier is not applicable to parameters of callable types." + // $TEST$ error "The const modifier is not applicable to parameters of callable types." »const« p1: Int ) -> () ) pipeline myPipeline { ( - # $TEST$ error "The const modifier is not applicable to parameters of lambdas." + // $TEST$ error "The const modifier is not applicable to parameters of lambdas." »const« p1: Int ) {}; ( - # $TEST$ error "The const modifier is not applicable to parameters of lambdas." + // $TEST$ error "The const modifier is not applicable to parameters of lambdas." »const« p1: Int ) -> 1; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/const modifier/no error.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/const modifier/no error.sdstest index bade60e5..1f0601ea 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/const modifier/no error.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/const modifier/no error.sdstest @@ -1,6 +1,6 @@ package tests.validation.other.declarations.parameters.illegalConstModifier -# $TEST$ no error "The const modifier is not applicable to parameters of callable types." +// $TEST$ no error "The const modifier is not applicable to parameters of callable types." fun f( g: (p2: Int) -> () diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/const must only be used for specific types/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/const must only be used for specific types/main.sdstest index 7aa07f4e..7e1c3865 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/const must only be used for specific types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/const must only be used for specific types/main.sdstest @@ -1,24 +1,24 @@ package tests.validation.other.declarations.parameters.constMustOnlyBeUsedForSpecificTypes annotation MyAnnotation( - # $TEST$ error "An annotation parameter cannot have type 'Any'." + // $TEST$ error "An annotation parameter cannot have type 'Any'." anyParam: »Any«, - # $TEST$ no error r"An annotation parameter cannot have type '.*'\." + // $TEST$ no error r"An annotation parameter cannot have type '.*'\." intParam: »Int«, ) @Pure fun functionWithConstantParameters( - # $TEST$ error "A constant parameter cannot have type 'Any'." + // $TEST$ error "A constant parameter cannot have type 'Any'." const anyParam: »Any«, - # $TEST$ no error r"A constant parameter cannot have type '.*'\." + // $TEST$ no error r"A constant parameter cannot have type '.*'\." const intParam: »Int«, ) @Pure fun functionWithNormalParameters( - # $TEST$ no error r"A constant parameter cannot have type '.*'\." + // $TEST$ no error r"A constant parameter cannot have type '.*'\." anyParam: »Any«, - # $TEST$ no error r"A constant parameter cannot have type '.*'\." + // $TEST$ no error r"A constant parameter cannot have type '.*'\." intParam: »Int«, ) diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/const must only be used for specific types/no type.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/const must only be used for specific types/no type.sdstest index 17033d15..9e604098 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/const must only be used for specific types/no type.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/const must only be used for specific types/no type.sdstest @@ -1,6 +1,6 @@ package tests.validation.other.declarations.parameters.constMustOnlyBeUsedForSpecificTypes -# $TEST$ no error r"A.* parameter cannot have type '.*'\." +// $TEST$ no error r"A.* parameter cannot have type '.*'\." annotation AnnotationMissingType(p) diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/default value must be constant if parameter is constant/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/default value must be constant if parameter is constant/main.sdstest index 9fc58284..6307cf81 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/default value must be constant if parameter is constant/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/default value must be constant if parameter is constant/main.sdstest @@ -4,132 +4,132 @@ package tests.validation.other.parameters.defaultValueMustBeConstantIfParameterI fun f() -> value: Int annotation MyAnnotation( - # $TEST$ no error "Default values of annotation parameters must be constant." + // $TEST$ no error "Default values of annotation parameters must be constant." param1: Int = »1«, - # $TEST$ no error "Default values of annotation parameters must be constant." + // $TEST$ no error "Default values of annotation parameters must be constant." param2: Int = »-2«, - # $TEST$ error "Default values of annotation parameters must be constant." + // $TEST$ error "Default values of annotation parameters must be constant." param3: Int = »f()«, - # $TEST$ no error "Default values of annotation parameters must be constant." + // $TEST$ no error "Default values of annotation parameters must be constant." const param4: Int = »1«, - # $TEST$ no error "Default values of annotation parameters must be constant." + // $TEST$ no error "Default values of annotation parameters must be constant." const param5: Int = »-2«, - # $TEST$ error "Default values of annotation parameters must be constant." + // $TEST$ error "Default values of annotation parameters must be constant." const param6: Int = »f()« ) class MyClass( - # $TEST$ no error "Default values of constant parameters must be constant." + // $TEST$ no error "Default values of constant parameters must be constant." param1: Int = »1«, - # $TEST$ no error "Default values of constant parameters must be constant." + // $TEST$ no error "Default values of constant parameters must be constant." param2: Int = »-2«, - # $TEST$ no error "Default values of constant parameters must be constant." + // $TEST$ no error "Default values of constant parameters must be constant." param3: Int = »f()«, - # $TEST$ no error "Default values of constant parameters must be constant." + // $TEST$ no error "Default values of constant parameters must be constant." const param4: Int = »1«, - # $TEST$ no error "Default values of constant parameters must be constant." + // $TEST$ no error "Default values of constant parameters must be constant." const param5: Int = »-2«, - # $TEST$ error "Default values of constant parameters must be constant." + // $TEST$ error "Default values of constant parameters must be constant." const param6: Int = »f()« ) enum MyEnum { MyEnumVariant( - # $TEST$ no error "Default values of constant parameters must be constant." + // $TEST$ no error "Default values of constant parameters must be constant." param1: Int = »1«, - # $TEST$ no error "Default values of constant parameters must be constant." + // $TEST$ no error "Default values of constant parameters must be constant." param2: Int = »-2«, - # $TEST$ no error "Default values of constant parameters must be constant." + // $TEST$ no error "Default values of constant parameters must be constant." param3: Int = »f()«, - # $TEST$ no error "Default values of constant parameters must be constant." + // $TEST$ no error "Default values of constant parameters must be constant." const param4: Int = »1«, - # $TEST$ no error "Default values of constant parameters must be constant." + // $TEST$ no error "Default values of constant parameters must be constant." const param5: Int = »-2«, - # $TEST$ error "Default values of constant parameters must be constant." + // $TEST$ error "Default values of constant parameters must be constant." const param6: Int = »f()« ) } @Pure fun myFunction( - # $TEST$ no error "Default values of constant parameters must be constant." + // $TEST$ no error "Default values of constant parameters must be constant." param1: Int = »1«, - # $TEST$ no error "Default values of constant parameters must be constant." + // $TEST$ no error "Default values of constant parameters must be constant." param2: Int = »-2«, - # $TEST$ no error "Default values of constant parameters must be constant." + // $TEST$ no error "Default values of constant parameters must be constant." param3: Int = »f()«, - # $TEST$ no error "Default values of constant parameters must be constant." + // $TEST$ no error "Default values of constant parameters must be constant." const param4: Int = »1«, - # $TEST$ no error "Default values of constant parameters must be constant." + // $TEST$ no error "Default values of constant parameters must be constant." const param5: Int = »-2«, - # $TEST$ error "Default values of constant parameters must be constant." + // $TEST$ error "Default values of constant parameters must be constant." const param6: Int = »f()« ) segment mySegment( callableType: ( - # $TEST$ no error "Default values of constant parameters must be constant." + // $TEST$ no error "Default values of constant parameters must be constant." param1: Int = »1«, - # $TEST$ no error "Default values of constant parameters must be constant." + // $TEST$ no error "Default values of constant parameters must be constant." param2: Int = »-2«, - # $TEST$ no error "Default values of constant parameters must be constant." + // $TEST$ no error "Default values of constant parameters must be constant." param3: Int = »f()«, - # $TEST$ no error "Default values of constant parameters must be constant." + // $TEST$ no error "Default values of constant parameters must be constant." const param4: Int = »1«, - # $TEST$ no error "Default values of constant parameters must be constant." + // $TEST$ no error "Default values of constant parameters must be constant." const param5: Int = »-2«, - # $TEST$ no error "Default values of constant parameters must be constant." + // $TEST$ no error "Default values of constant parameters must be constant." const param6: Int = »f()«, ) -> (), - # $TEST$ no error "Default values of constant parameters must be constant." + // $TEST$ no error "Default values of constant parameters must be constant." param1: Int = »1«, - # $TEST$ no error "Default values of constant parameters must be constant." + // $TEST$ no error "Default values of constant parameters must be constant." param2: Int = »-2«, - # $TEST$ no error "Default values of constant parameters must be constant." + // $TEST$ no error "Default values of constant parameters must be constant." param3: Int = »f()«, - # $TEST$ no error "Default values of constant parameters must be constant." + // $TEST$ no error "Default values of constant parameters must be constant." const param4: Int = »1«, - # $TEST$ no error "Default values of constant parameters must be constant." + // $TEST$ no error "Default values of constant parameters must be constant." const param5: Int = »-2«, - # $TEST$ error "Default values of constant parameters must be constant." + // $TEST$ error "Default values of constant parameters must be constant." const param6: Int = »f()«, ) { ( - # $TEST$ no error "Default values of constant parameters must be constant." + // $TEST$ no error "Default values of constant parameters must be constant." param1: Int = »1«, - # $TEST$ no error "Default values of constant parameters must be constant." + // $TEST$ no error "Default values of constant parameters must be constant." param2: Int = »-2«, - # $TEST$ no error "Default values of constant parameters must be constant." + // $TEST$ no error "Default values of constant parameters must be constant." param3: Int = »f()«, - # $TEST$ no error "Default values of constant parameters must be constant." + // $TEST$ no error "Default values of constant parameters must be constant." const param4: Int = »1«, - # $TEST$ no error "Default values of constant parameters must be constant." + // $TEST$ no error "Default values of constant parameters must be constant." const param5: Int = »-2«, - # $TEST$ no error "Default values of constant parameters must be constant." + // $TEST$ no error "Default values of constant parameters must be constant." const param6: Int = »f()«, ) {}; ( - # $TEST$ no error "Default values of constant parameters must be constant." + // $TEST$ no error "Default values of constant parameters must be constant." param1: Int = »1«, - # $TEST$ no error "Default values of constant parameters must be constant." + // $TEST$ no error "Default values of constant parameters must be constant." param2: Int = »-2«, - # $TEST$ no error "Default values of constant parameters must be constant." + // $TEST$ no error "Default values of constant parameters must be constant." param3: Int = »f()«, - # $TEST$ no error "Default values of constant parameters must be constant." + // $TEST$ no error "Default values of constant parameters must be constant." const param4: Int = »1«, - # $TEST$ no error "Default values of constant parameters must be constant." + // $TEST$ no error "Default values of constant parameters must be constant." const param5: Int = »-2«, - # $TEST$ no error "Default values of constant parameters must be constant." + // $TEST$ no error "Default values of constant parameters must be constant." const param6: Int = »f()«, ) -> 1; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/placeholders/alias/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/placeholders/alias/main.sdstest index a422fdf1..fe1b0230 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/placeholders/alias/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/placeholders/alias/main.sdstest @@ -21,32 +21,32 @@ schema MySchema {} segment mySegment1() {} segment mySegment2(myParameter: Int) { - # $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." + // $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." val »myPlaceholder« = 1; - # $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." + // $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." val »a« = MyAnnotation; - # $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." + // $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." val »b« = MyClass.myAttribute; - # $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." + // $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." val »c« = MyClass; - # $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." + // $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." val »d« = MyEnum; - # $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." + // $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." val »e« = MyEnum.MyEnumVariant; - # $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." + // $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." val »f« = myFunction; - # $TEST$ error "Aliases are not allowed to provide a cleaner graphical view." - # $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." + // $TEST$ error "Aliases are not allowed to provide a cleaner graphical view." + // $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." val »g1«, val »g2« = myParameter; - # $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." + // $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." val »h« = myPipeline; - # $TEST$ error "Aliases are not allowed to provide a cleaner graphical view." - # $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." + // $TEST$ error "Aliases are not allowed to provide a cleaner graphical view." + // $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." val »i1«, val »i2« = myPlaceholder; - # $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." + // $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." val »j« = MySchema; - # $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." + // $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." val »k« = mySegment1; - # $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." + // $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." val »l« = unresolved; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/placeholders/unused/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/placeholders/unused/main.sdstest index 1c8304b0..1527cb7a 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/placeholders/unused/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/placeholders/unused/main.sdstest @@ -3,42 +3,42 @@ package tests.validation.other.declarations.placeholders.unused fun f() -> (r1: Int, r2: Int) segment mySegment() { - # $TEST$ warning "This placeholder is unused and can be removed." + // $TEST$ warning "This placeholder is unused and can be removed." val »unused« = 1; - # $TEST$ no warning "This placeholder is unused and can be removed." + // $TEST$ no warning "This placeholder is unused and can be removed." val »used« = 1; used; - # $TEST$ no warning "This placeholder is unused and can be removed." - # $TEST$ no warning "This placeholder is unused and can be removed." + // $TEST$ no warning "This placeholder is unused and can be removed." + // $TEST$ no warning "This placeholder is unused and can be removed." val »last1«, val »last2« = f(); } pipeline myPipeline1 { - # $TEST$ warning "This placeholder is unused and can be removed." + // $TEST$ warning "This placeholder is unused and can be removed." val »unused« = 1; - # $TEST$ no warning "This placeholder is unused and can be removed." + // $TEST$ no warning "This placeholder is unused and can be removed." val »used« = 1; used; - # $TEST$ no warning "This placeholder is unused and can be removed." - # $TEST$ no warning "This placeholder is unused and can be removed." + // $TEST$ no warning "This placeholder is unused and can be removed." + // $TEST$ no warning "This placeholder is unused and can be removed." val »last1«, val »last2« = f(); } pipeline myPipeline2 { () { - # $TEST$ warning "This placeholder is unused and can be removed." + // $TEST$ warning "This placeholder is unused and can be removed." val »unused« = 1; - # $TEST$ no warning "This placeholder is unused and can be removed." + // $TEST$ no warning "This placeholder is unused and can be removed." val »used« = 1; used; - # $TEST$ no warning "This placeholder is unused and can be removed." - # $TEST$ no warning "This placeholder is unused and can be removed." + // $TEST$ no warning "This placeholder is unused and can be removed." + // $TEST$ no warning "This placeholder is unused and can be removed." val »last1«, val »last2« = f(); }; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/segments/duplicate yield/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/segments/duplicate yield/main.sdstest index 358a0988..f6677b70 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/segments/duplicate yield/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/segments/duplicate yield/main.sdstest @@ -1,20 +1,20 @@ package tests.validation.other.declarations.segments.duplicateYield segment mySegment() -> (a: Int, b: Int, c: Int) { - # $TEST$ no error r"The result '\w*' has been assigned already\." + // $TEST$ no error r"The result '\w*' has been assigned already\." yield »a« = 1; - # $TEST$ no error r"The result '\w*' has been assigned already\." + // $TEST$ no error r"The result '\w*' has been assigned already\." yield »b« = 1; - # $TEST$ error "The result 'b' has been assigned already." + // $TEST$ error "The result 'b' has been assigned already." yield »b« = 1; - # $TEST$ no error r"The result '\w*' has been assigned already\." - # $TEST$ error "The result 'c' has been assigned already." + // $TEST$ no error r"The result '\w*' has been assigned already\." + // $TEST$ error "The result 'c' has been assigned already." yield »c«, yield »c« = 1; - # $TEST$ no error r"The result '\w*' has been assigned already\." + // $TEST$ no error r"The result '\w*' has been assigned already\." yield »unresolved« = 1; - # $TEST$ no error r"The result '\w*' has been assigned already\." + // $TEST$ no error r"The result '\w*' has been assigned already\." yield »unresolved« = 1; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/segments/unassigned result/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/segments/unassigned result/main.sdstest index 4b85ce12..f4ef6680 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/segments/unassigned result/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/segments/unassigned result/main.sdstest @@ -1,10 +1,10 @@ package tests.validation.other.declarations.segments.unassignedResult -# $TEST$ no error "Nothing is assigned to this result." -# $TEST$ no error "Nothing is assigned to this result." -# $TEST$ no error "Nothing is assigned to this result." -# $TEST$ no error "Nothing is assigned to this result." -# $TEST$ error "Nothing is assigned to this result." +// $TEST$ no error "Nothing is assigned to this result." +// $TEST$ no error "Nothing is assigned to this result." +// $TEST$ no error "Nothing is assigned to this result." +// $TEST$ no error "Nothing is assigned to this result." +// $TEST$ error "Nothing is assigned to this result." segment mySegment() -> (»a«: Int, »b«: Int, »c«: Int, »d«: Int, »e«: Int) { yield b = 1; yield a = 1; diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/segments/unused parameter/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/segments/unused parameter/main.sdstest index 5a35cb31..aa0cdfdb 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/segments/unused parameter/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/segments/unused parameter/main.sdstest @@ -1,11 +1,11 @@ package tests.validation.other.declarations.segments.unusedParameters segment mySegment( - # $TEST$ warning "This parameter is unused and can be removed." + // $TEST$ warning "This parameter is unused and can be removed." »unused«: Int, - # $TEST$ warning "This parameter is unused and can be removed." + // $TEST$ warning "This parameter is unused and can be removed." »onlyHasBound«: Int, - # $TEST$ no warning "This parameter is unused and can be removed." + // $TEST$ no warning "This parameter is unused and can be removed." »used«: Int ) where { onlyHasBound < 0 @@ -17,37 +17,37 @@ segment mySegment( */ ( - # $TEST$ no warning "This parameter is unused and can be removed." + // $TEST$ no warning "This parameter is unused and can be removed." »unused«: Int, - # $TEST$ no warning "This parameter is unused and can be removed." + // $TEST$ no warning "This parameter is unused and can be removed." »used«: Int ) { used; }; ( - # $TEST$ no warning "This parameter is unused and can be removed." + // $TEST$ no warning "This parameter is unused and can be removed." »unused«: Int, - # $TEST$ no warning "This parameter is unused and can be removed." + // $TEST$ no warning "This parameter is unused and can be removed." »used«: Int ) -> used; } -# $TEST$ no warning "This parameter is unused and can be removed." +// $TEST$ no warning "This parameter is unused and can be removed." annotation MyAnnotation(»unused«: Int) -# $TEST$ no warning "This parameter is unused and can be removed." +// $TEST$ no warning "This parameter is unused and can be removed." class MyClass(»unused«: Int) enum MyEnum { - # $TEST$ no warning "This parameter is unused and can be removed." + // $TEST$ no warning "This parameter is unused and can be removed." MyEnumVariant(»unused«: Int) } fun myFunction( - # $TEST$ no warning "This parameter is unused and can be removed." + // $TEST$ no warning "This parameter is unused and can be removed." »unused«: Int, - # $TEST$ no warning "This parameter is unused and can be removed." + // $TEST$ no warning "This parameter is unused and can be removed." myCallableType: (»unused«: Int) -> (), ) diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/segments/unused/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/segments/unused/main.sdstest index 2bffbe16..4cf658e6 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/segments/unused/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/segments/unused/main.sdstest @@ -1,21 +1,21 @@ package tests.validation.other.declarations.segments.unused -# $TEST$ warning "This segment is unused and can be removed." +// $TEST$ warning "This segment is unused and can be removed." private segment »myUnusedPrivateSegment«() {} -# $TEST$ no warning "This segment is unused and can be removed." +// $TEST$ no warning "This segment is unused and can be removed." private segment »myUsedPrivateSegment«() {} -# $TEST$ warning "This segment is unused and can be removed." +// $TEST$ warning "This segment is unused and can be removed." internal segment »myUnusedInternalSegment«() {} -# $TEST$ no warning "This segment is unused and can be removed." +// $TEST$ no warning "This segment is unused and can be removed." internal segment »myUsedInternalSegment«() {} -# $TEST$ no warning "This segment is unused and can be removed." +// $TEST$ no warning "This segment is unused and can be removed." segment »myUnusedPublicSegment«() {} -# $TEST$ no warning "This segment is unused and can be removed." +// $TEST$ no warning "This segment is unused and can be removed." segment »myUsedPublicSegment«() {} pipeline myPipeline1 { diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameter lists/must not have required after optional/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameter lists/must not have required after optional/main.sdstest index 72fc5850..f759ad68 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameter lists/must not have required after optional/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameter lists/must not have required after optional/main.sdstest @@ -1,28 +1,28 @@ package tests.validation.other.declarations.typeParameterLists.mustNotHaveRequiredAfterOptional -# $TEST$ no error "After the first optional type parameter all type parameters must be optional." -# $TEST$ no error "After the first optional type parameter all type parameters must be optional." -# $TEST$ error "After the first optional type parameter all type parameters must be optional." -# $TEST$ no error "After the first optional type parameter all type parameters must be optional." +// $TEST$ no error "After the first optional type parameter all type parameters must be optional." +// $TEST$ no error "After the first optional type parameter all type parameters must be optional." +// $TEST$ error "After the first optional type parameter all type parameters must be optional." +// $TEST$ no error "After the first optional type parameter all type parameters must be optional." class MyClass1<»A«, »B« = Int, »C«, »D« = String> -# $TEST$ no error "After the first optional type parameter all type parameters must be optional." -# $TEST$ no error "After the first optional type parameter all type parameters must be optional." +// $TEST$ no error "After the first optional type parameter all type parameters must be optional." +// $TEST$ no error "After the first optional type parameter all type parameters must be optional." class MyClass2<»A«, »B« = Int> -# $TEST$ no error "After the first optional type parameter all type parameters must be optional." +// $TEST$ no error "After the first optional type parameter all type parameters must be optional." class MyClass3<»A«> -# $TEST$ no error "After the first optional type parameter all type parameters must be optional." -# $TEST$ no error "After the first optional type parameter all type parameters must be optional." -# $TEST$ error "After the first optional type parameter all type parameters must be optional." -# $TEST$ no error "After the first optional type parameter all type parameters must be optional." +// $TEST$ no error "After the first optional type parameter all type parameters must be optional." +// $TEST$ no error "After the first optional type parameter all type parameters must be optional." +// $TEST$ error "After the first optional type parameter all type parameters must be optional." +// $TEST$ no error "After the first optional type parameter all type parameters must be optional." fun myFunction1<»A«, »B« = Int, »C«, »D« = String>() -# $TEST$ no error "After the first optional type parameter all type parameters must be optional." -# $TEST$ no error "After the first optional type parameter all type parameters must be optional." +// $TEST$ no error "After the first optional type parameter all type parameters must be optional." +// $TEST$ no error "After the first optional type parameter all type parameters must be optional." fun myFunction2<»A«, »B« = Int>() -# $TEST$ no error "After the first optional type parameter all type parameters must be optional." +// $TEST$ no error "After the first optional type parameter all type parameters must be optional." fun myFunction3<»A«>() diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/insufficient context/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/insufficient context/main.sdstest index d41dacbc..be989fcd 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/insufficient context/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/insufficient context/main.sdstest @@ -1,41 +1,41 @@ package tests.validation.other.declarations.typeParameters.insufficientContext -# $TEST$ no error "Insufficient context to infer this type parameter." +// $TEST$ no error "Insufficient context to infer this type parameter." class MyClass1<»T«> -# $TEST$ error "Insufficient context to infer this type parameter." +// $TEST$ error "Insufficient context to infer this type parameter." class MyClass2<»T« sub Int>() -# $TEST$ error "Insufficient context to infer this type parameter." +// $TEST$ error "Insufficient context to infer this type parameter." class MyClass3<»T«>() { attr myAttr: T } -# $TEST$ no error "Insufficient context to infer this type parameter." +// $TEST$ no error "Insufficient context to infer this type parameter." class MyClass4<»T« sub Int>(param: T) -# $TEST$ no error "Insufficient context to infer this type parameter." +// $TEST$ no error "Insufficient context to infer this type parameter." class MyClass5<»T«>(param: MyClass4?) -# $TEST$ no error "Insufficient context to infer this type parameter." +// $TEST$ no error "Insufficient context to infer this type parameter." class MyClass6<»T«>(param: () -> (r: T)) -# $TEST$ error "Insufficient context to infer this type parameter." +// $TEST$ error "Insufficient context to infer this type parameter." class MyClass7<»T«>(param: (p: T) -> ()) -# $TEST$ error "Insufficient context to infer this type parameter." +// $TEST$ error "Insufficient context to infer this type parameter." class MyClass8<»T«>(param: () -> (r: (p: T) -> ())) -# $TEST$ error "Insufficient context to infer this type parameter." +// $TEST$ error "Insufficient context to infer this type parameter." class MyClass9<»T«>(param: union) -# $TEST$ error "Insufficient context to infer this type parameter." +// $TEST$ error "Insufficient context to infer this type parameter." class MyClass10<»T«>(param: union) -# $TEST$ error "Insufficient context to infer this type parameter." +// $TEST$ error "Insufficient context to infer this type parameter." fun myFunction1<»T« sub Int>() -# $TEST$ no error "Insufficient context to infer this type parameter." +// $TEST$ no error "Insufficient context to infer this type parameter." fun myFunction2<»T«>(param: T) -# $TEST$ no error "Insufficient context to infer this type parameter." +// $TEST$ no error "Insufficient context to infer this type parameter." fun myFunction3<»T«>(param: MyClass4?) -# $TEST$ no error "Insufficient context to infer this type parameter." +// $TEST$ no error "Insufficient context to infer this type parameter." fun myFunction4<»T«>(param: () -> (r: T)) -# $TEST$ error "Insufficient context to infer this type parameter." +// $TEST$ error "Insufficient context to infer this type parameter." fun myFunction5<»T«>(param: (p: T) -> ()) -# $TEST$ error "Insufficient context to infer this type parameter." +// $TEST$ error "Insufficient context to infer this type parameter." fun myFunction6<»T«>(param: () -> (r: (p: T) -> ())) -# $TEST$ error "Insufficient context to infer this type parameter." +// $TEST$ error "Insufficient context to infer this type parameter." fun myFunction7<»T«>(param: union) -# $TEST$ error "Insufficient context to infer this type parameter." +// $TEST$ error "Insufficient context to infer this type parameter." fun myFunction8<»T«>(param: union) diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/upper bound must be named type/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/upper bound must be named type/main.sdstest index c75c00df..5eeba74b 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/upper bound must be named type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/upper bound must be named type/main.sdstest @@ -5,27 +5,27 @@ enum E { V } -# $TEST$ error "The upper bound of a type parameter must be a named type." +// $TEST$ error "The upper bound of a type parameter must be a named type." class MyClass1 ()«> -# $TEST$ error "The upper bound of a type parameter must be a named type." +// $TEST$ error "The upper bound of a type parameter must be a named type." class MyClass2«> -# $TEST$ no error "The upper bound of a type parameter must be a named type." +// $TEST$ no error "The upper bound of a type parameter must be a named type." class MyClass3 -# $TEST$ no error "The upper bound of a type parameter must be a named type." +// $TEST$ no error "The upper bound of a type parameter must be a named type." class MyClass4 -# $TEST$ no error "The upper bound of a type parameter must be a named type." +// $TEST$ no error "The upper bound of a type parameter must be a named type." class MyClass5 -# $TEST$ no error "The upper bound of a type parameter must be a named type." -# $TEST$ no error "The upper bound of a type parameter must be a named type." +// $TEST$ no error "The upper bound of a type parameter must be a named type." +// $TEST$ no error "The upper bound of a type parameter must be a named type." class MyClass6 -# $TEST$ error "The upper bound of a type parameter must be a named type." +// $TEST$ error "The upper bound of a type parameter must be a named type." class MyClass7«> -# $TEST$ no error "The upper bound of a type parameter must be a named type." +// $TEST$ no error "The upper bound of a type parameter must be a named type." class MyClass8 diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of class type parameters/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of class type parameters/main.sdstest index 929598df..6a5b11d7 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of class type parameters/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of class type parameters/main.sdstest @@ -1,44 +1,44 @@ package tests.validation.other.declarations.typeParameters.usageOfClassTypeParameters -# $TEST$ no error "This type parameter of a containing class cannot be used here." -# $TEST$ no error "This type parameter of a containing class cannot be used here." +// $TEST$ no error "This type parameter of a containing class cannot be used here." +// $TEST$ no error "This type parameter of a containing class cannot be used here." class MyClass(p: »T«) sub »T« { - # $TEST$ no error "This type parameter of a containing class cannot be used here." + // $TEST$ no error "This type parameter of a containing class cannot be used here." attr a: »T« - # $TEST$ error "This type parameter of a containing class cannot be used here." + // $TEST$ error "This type parameter of a containing class cannot be used here." static attr a: »T« - # $TEST$ no error "This type parameter of a containing class cannot be used here." - # $TEST$ no error "This type parameter of a containing class cannot be used here." - # $TEST$ no error "This type parameter of a containing class cannot be used here." - # $TEST$ no error "This type parameter of a containing class cannot be used here." + // $TEST$ no error "This type parameter of a containing class cannot be used here." + // $TEST$ no error "This type parameter of a containing class cannot be used here." + // $TEST$ no error "This type parameter of a containing class cannot be used here." + // $TEST$ no error "This type parameter of a containing class cannot be used here." fun f(p1: »T«, p2: »S«) -> (r1: »T«, r2: »S«) - # $TEST$ error "This type parameter of a containing class cannot be used here." - # $TEST$ no error "This type parameter of a containing class cannot be used here." - # $TEST$ error "This type parameter of a containing class cannot be used here." - # $TEST$ no error "This type parameter of a containing class cannot be used here." + // $TEST$ error "This type parameter of a containing class cannot be used here." + // $TEST$ no error "This type parameter of a containing class cannot be used here." + // $TEST$ error "This type parameter of a containing class cannot be used here." + // $TEST$ no error "This type parameter of a containing class cannot be used here." static fun f(p1: »T«, p2: »S«) -> (r1: »T«, r2: »S«) - # $TEST$ error "This type parameter of a containing class cannot be used here." - # $TEST$ no error "This type parameter of a containing class cannot be used here." + // $TEST$ error "This type parameter of a containing class cannot be used here." + // $TEST$ no error "This type parameter of a containing class cannot be used here." class MyInnerClass(p1: »T«, p2: »S«) { - # $TEST$ error "This type parameter of a containing class cannot be used here." + // $TEST$ error "This type parameter of a containing class cannot be used here." attr a: »T« - # $TEST$ error "This type parameter of a containing class cannot be used here." + // $TEST$ error "This type parameter of a containing class cannot be used here." static attr a: »T« - # $TEST$ error "This type parameter of a containing class cannot be used here." + // $TEST$ error "This type parameter of a containing class cannot be used here." fun f(p: »T«) - # $TEST$ error "This type parameter of a containing class cannot be used here." + // $TEST$ error "This type parameter of a containing class cannot be used here." static fun f(p: »T«) } enum MyInnerEnum { - # $TEST$ error "This type parameter of a containing class cannot be used here." + // $TEST$ error "This type parameter of a containing class cannot be used here." MyEnumVariant(p1: »T«) } } diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of variant type parameter/contravariant type parameter.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of variant type parameter/contravariant type parameter.sdstest index daa47e14..f75cda4f 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of variant type parameter/contravariant type parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of variant type parameter/contravariant type parameter.sdstest @@ -1,78 +1,78 @@ package tests.validation.other.declarations.typeParameters.usageOfVariantTypeParameters -# $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." +// $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." class MyClass1(p1: »Contravariant«) -# $TEST$ error "A contravariant type parameter cannot be used in covariant position." -# $TEST$ error "A contravariant type parameter cannot be used in invariant position." -# $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." +// $TEST$ error "A contravariant type parameter cannot be used in covariant position." +// $TEST$ error "A contravariant type parameter cannot be used in invariant position." +// $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." sub Producer<»Contravariant«>, Middleware<»Contravariant«>, Consumer<»Contravariant«> { - # $TEST$ error "A contravariant type parameter cannot be used in covariant position." + // $TEST$ error "A contravariant type parameter cannot be used in covariant position." attr a1: »Contravariant« - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." - # $TEST$ error "A contravariant type parameter cannot be used in covariant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ error "A contravariant type parameter cannot be used in covariant position." attr a2: (a1: »Contravariant«) -> (r1: »Contravariant«) - # $TEST$ error "A contravariant type parameter cannot be used in covariant position." + // $TEST$ error "A contravariant type parameter cannot be used in covariant position." attr a3: Producer<»Contravariant«> - # $TEST$ error "A contravariant type parameter cannot be used in invariant position." + // $TEST$ error "A contravariant type parameter cannot be used in invariant position." attr a4: Middleware<»Contravariant«> - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." attr a5: Consumer<»Contravariant«> - # $TEST$ error "A contravariant type parameter cannot be used in covariant position." + // $TEST$ error "A contravariant type parameter cannot be used in covariant position." attr a6: Producer> - # $TEST$ error "A contravariant type parameter cannot be used in invariant position." + // $TEST$ error "A contravariant type parameter cannot be used in invariant position." attr a7: Middleware> - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." attr a8: Consumer> fun f( - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." p1: »Contravariant«, - # $TEST$ error "A contravariant type parameter cannot be used in covariant position." - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ error "A contravariant type parameter cannot be used in covariant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." p2: (a1: »Contravariant«) -> (r1: »Contravariant«), - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." p3: Producer<»Contravariant«>, - # $TEST$ error "A contravariant type parameter cannot be used in invariant position." + // $TEST$ error "A contravariant type parameter cannot be used in invariant position." p4: Middleware<»Contravariant«>, - # $TEST$ error "A contravariant type parameter cannot be used in covariant position." + // $TEST$ error "A contravariant type parameter cannot be used in covariant position." p5: Consumer<»Contravariant«>, ) -> ( - # $TEST$ error "A contravariant type parameter cannot be used in covariant position." + // $TEST$ error "A contravariant type parameter cannot be used in covariant position." r1: »Contravariant«, - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." - # $TEST$ error "A contravariant type parameter cannot be used in covariant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ error "A contravariant type parameter cannot be used in covariant position." r2: (a1: »Contravariant«) -> (r1: »Contravariant«), - # $TEST$ error "A contravariant type parameter cannot be used in covariant position." + // $TEST$ error "A contravariant type parameter cannot be used in covariant position." r3: Producer<»Contravariant«>, - # $TEST$ error "A contravariant type parameter cannot be used in invariant position." + // $TEST$ error "A contravariant type parameter cannot be used in invariant position." r4: Middleware<»Contravariant«>, - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." r5: Consumer<»Contravariant«>, ) } fun f1( - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." p1: »Contravariant«, - # $TEST$ error "A contravariant type parameter cannot be used in covariant position." - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ error "A contravariant type parameter cannot be used in covariant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." p2: (a1: »Contravariant«) -> (r1: »Contravariant«), - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." p3: Producer<»Contravariant«>, - # $TEST$ error "A contravariant type parameter cannot be used in invariant position." + // $TEST$ error "A contravariant type parameter cannot be used in invariant position." p4: Middleware<»Contravariant«>, - # $TEST$ error "A contravariant type parameter cannot be used in covariant position." + // $TEST$ error "A contravariant type parameter cannot be used in covariant position." p5: Consumer<»Contravariant«>, ) -> ( - # $TEST$ error "A contravariant type parameter cannot be used in covariant position." + // $TEST$ error "A contravariant type parameter cannot be used in covariant position." r1: »Contravariant«, - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." - # $TEST$ error "A contravariant type parameter cannot be used in covariant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ error "A contravariant type parameter cannot be used in covariant position." r2: (a1: »Contravariant«) -> (r1: »Contravariant«), - # $TEST$ error "A contravariant type parameter cannot be used in covariant position." + // $TEST$ error "A contravariant type parameter cannot be used in covariant position." r3: Producer<»Contravariant«>, - # $TEST$ error "A contravariant type parameter cannot be used in invariant position." + // $TEST$ error "A contravariant type parameter cannot be used in invariant position." r4: Middleware<»Contravariant«>, - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." r5: Consumer<»Contravariant«>, ) diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of variant type parameter/covariant type parameter.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of variant type parameter/covariant type parameter.sdstest index 0521acf5..a8c2a196 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of variant type parameter/covariant type parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of variant type parameter/covariant type parameter.sdstest @@ -1,78 +1,78 @@ package tests.validation.other.declarations.typeParameters.usageOfVariantTypeParameters -# $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." +// $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." class MyClass2(p1: »Covariant«) -# $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." -# $TEST$ error "A covariant type parameter cannot be used in invariant position." -# $TEST$ error "A covariant type parameter cannot be used in contravariant position." +// $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." +// $TEST$ error "A covariant type parameter cannot be used in invariant position." +// $TEST$ error "A covariant type parameter cannot be used in contravariant position." sub Producer<»Covariant«>, Middleware<»Covariant«>, Consumer<»Covariant«> { - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." attr a1: »Covariant« - # $TEST$ error "A covariant type parameter cannot be used in contravariant position." - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ error "A covariant type parameter cannot be used in contravariant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." attr a2: (a1: »Covariant«) -> (r1: »Covariant«) - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." attr a3: Producer<»Covariant«> - # $TEST$ error "A covariant type parameter cannot be used in invariant position." + // $TEST$ error "A covariant type parameter cannot be used in invariant position." attr a4: Middleware<»Covariant«> - # $TEST$ error "A covariant type parameter cannot be used in contravariant position." + // $TEST$ error "A covariant type parameter cannot be used in contravariant position." attr a5: Consumer<»Covariant«> - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." attr a6: Producer> - # $TEST$ error "A covariant type parameter cannot be used in invariant position." + // $TEST$ error "A covariant type parameter cannot be used in invariant position." attr a7: Middleware> - # $TEST$ error "A covariant type parameter cannot be used in contravariant position." + // $TEST$ error "A covariant type parameter cannot be used in contravariant position." attr a8: Consumer> fun f( - # $TEST$ error "A covariant type parameter cannot be used in contravariant position." + // $TEST$ error "A covariant type parameter cannot be used in contravariant position." p1: »Covariant«, - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." - # $TEST$ error "A covariant type parameter cannot be used in contravariant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ error "A covariant type parameter cannot be used in contravariant position." p2: (a1: »Covariant«) -> (r1: »Covariant«), - # $TEST$ error "A covariant type parameter cannot be used in contravariant position." + // $TEST$ error "A covariant type parameter cannot be used in contravariant position." p3: Producer<»Covariant«>, - # $TEST$ error "A covariant type parameter cannot be used in invariant position." + // $TEST$ error "A covariant type parameter cannot be used in invariant position." p4: Middleware<»Covariant«>, - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." p5: Consumer<»Covariant«>, ) -> ( - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." r1: »Covariant«, - # $TEST$ error "A covariant type parameter cannot be used in contravariant position." - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ error "A covariant type parameter cannot be used in contravariant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." r2: (a1: »Covariant«) -> (r1: »Covariant«), - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." r3: Producer<»Covariant«>, - # $TEST$ error "A covariant type parameter cannot be used in invariant position." + // $TEST$ error "A covariant type parameter cannot be used in invariant position." r4: Middleware<»Covariant«>, - # $TEST$ error "A covariant type parameter cannot be used in contravariant position." + // $TEST$ error "A covariant type parameter cannot be used in contravariant position." r5: Consumer<»Covariant«>, ) } fun f2( - # $TEST$ error "A covariant type parameter cannot be used in contravariant position." + // $TEST$ error "A covariant type parameter cannot be used in contravariant position." p1: »Covariant«, - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." - # $TEST$ error "A covariant type parameter cannot be used in contravariant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ error "A covariant type parameter cannot be used in contravariant position." p2: (a1: »Covariant«) -> (r1: »Covariant«), - # $TEST$ error "A covariant type parameter cannot be used in contravariant position." + // $TEST$ error "A covariant type parameter cannot be used in contravariant position." p3: Producer<»Covariant«>, - # $TEST$ error "A covariant type parameter cannot be used in invariant position." + // $TEST$ error "A covariant type parameter cannot be used in invariant position." p4: Middleware<»Covariant«>, - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." p5: Consumer<»Covariant«>, ) -> ( - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." r1: »Covariant«, - # $TEST$ error "A covariant type parameter cannot be used in contravariant position." - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ error "A covariant type parameter cannot be used in contravariant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." r2: (a1: »Covariant«) -> (r1: »Covariant«), - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." r3: Producer<»Covariant«>, - # $TEST$ error "A covariant type parameter cannot be used in invariant position." + // $TEST$ error "A covariant type parameter cannot be used in invariant position." r4: Middleware<»Covariant«>, - # $TEST$ error "A covariant type parameter cannot be used in contravariant position." + // $TEST$ error "A covariant type parameter cannot be used in contravariant position." r5: Consumer<»Covariant«>, ) diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of variant type parameter/invariant type parameter.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of variant type parameter/invariant type parameter.sdstest index 7dd84bb5..b9651f3d 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of variant type parameter/invariant type parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of variant type parameter/invariant type parameter.sdstest @@ -1,78 +1,78 @@ package tests.validation.other.declarations.typeParameters.usageOfVariantTypeParameters -# $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." +// $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." class MyClass3(p1: »Invariant«) -# $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." -# $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." -# $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." +// $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." +// $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." +// $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." sub Producer<»Invariant«>, Middleware<»Invariant«>, Consumer<»Invariant«> { - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." attr a1: »Invariant« - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." attr a2: (a1: »Invariant«) -> (r1: »Invariant«) - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." attr a3: Producer<»Invariant«> - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." attr a4: Middleware<»Invariant«> - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." attr a5: Consumer<»Invariant«> - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." attr a6: Producer> - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." attr a7: Middleware> - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." attr a8: Consumer> fun f( - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." p1: »Invariant«, - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." p2: (a1: »Invariant«) -> (r1: »Invariant«), - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." p3: Producer<»Invariant«>, - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." p4: Middleware<»Invariant«>, - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." p5: Consumer<»Invariant«>, ) -> ( - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." r1: »Invariant«, - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." r2: (a1: »Invariant«) -> (r1: »Invariant«), - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." r3: Producer<»Invariant«>, - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." r4: Middleware<»Invariant«>, - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." r5: Consumer<»Invariant«>, ) } fun f3( - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." p1: »Invariant«, - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." p2: (a1: »Invariant«) -> (r1: »Invariant«), - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." p3: Producer<»Invariant«>, - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." p4: Middleware<»Invariant«>, - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." p5: Consumer<»Invariant«>, ) -> ( - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." r1: »Invariant«, - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." r2: (a1: »Invariant«) -> (r1: »Invariant«), - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." r3: Producer<»Invariant«>, - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." r4: Middleware<»Invariant«>, - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." r5: Consumer<»Invariant«>, ) diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of variant type parameter/usage of class type parameters.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of variant type parameter/usage of class type parameters.sdstest index 0b43162a..faf8e0a2 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of variant type parameter/usage of class type parameters.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of variant type parameter/usage of class type parameters.sdstest @@ -3,32 +3,32 @@ package tests.validation.other.declarations.typeParameters.usageOfVariantTypePar // We already show other errors in those cases. class MyClass4() { - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." static attr a: »Contra« - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." static fun f(p1: »Co«) -> (r1: »Contra«) - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." class MyInnerClass(p1: »Co«) { - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." attr a: »Contra« - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." static attr a: »Contra« - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." fun f(p1: »Co«) -> (r1: »Contra«) - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." static fun f(p1: »Co«) -> (r1: »Contra«) } enum MyInnerEnum { - # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." MyEnumVariant(p1: »Co«) } } diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/variance only on classes/invariant.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/variance only on classes/invariant.sdstest index 59ecc452..e4a1859a 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/variance only on classes/invariant.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/variance only on classes/invariant.sdstest @@ -1,6 +1,6 @@ package tests.validation.other.declarations.typeParameters.varianceOnlyOnClasses -# $TEST$ no error "Only type parameters of classes can be variant." +// $TEST$ no error "Only type parameters of classes can be variant." class C1 diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/variance only on classes/variant.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/variance only on classes/variant.sdstest index daef18d3..a9ce52db 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/variance only on classes/variant.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/variance only on classes/variant.sdstest @@ -1,11 +1,11 @@ package tests.validation.other.declarations.typeParameters.varianceOnlyOnClasses -# $TEST$ no error "Only type parameters of classes can be variant." +// $TEST$ no error "Only type parameters of classes can be variant." class C2<»in« T> -# $TEST$ no error "Only type parameters of classes can be variant." +// $TEST$ no error "Only type parameters of classes can be variant." class C3<»out« T> -# $TEST$ error "Only type parameters of classes can be variant." +// $TEST$ error "Only type parameters of classes can be variant." fun f2<»in« T>() -# $TEST$ error "Only type parameters of classes can be variant." +// $TEST$ error "Only type parameters of classes can be variant." fun f3<»out« T>() diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/arguments/must be constant if parameter is constant/annotation calls.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/arguments/must be constant if parameter is constant/annotation calls.sdstest index b68ff36d..98ef0ddb 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/arguments/must be constant if parameter is constant/annotation calls.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/arguments/must be constant if parameter is constant/annotation calls.sdstest @@ -6,22 +6,22 @@ annotation MyAnnotation1(value: Int) @Repeatable annotation MyAnnotation2(constantParam: MyEnum) -# $TEST$ no error "Values assigned to annotation parameters must be constant." +// $TEST$ no error "Values assigned to annotation parameters must be constant." @MyAnnotation1(»1«) -# $TEST$ no error "Values assigned to annotation parameters must be constant." +// $TEST$ no error "Values assigned to annotation parameters must be constant." @MyAnnotation1(»-2«) -# $TEST$ error "Values assigned to annotation parameters must be constant." +// $TEST$ error "Values assigned to annotation parameters must be constant." @MyAnnotation1(»[1, 2][0]«) -# $TEST$ error "Values assigned to annotation parameters must be constant." +// $TEST$ error "Values assigned to annotation parameters must be constant." @MyAnnotation1(»intFunction()«) -# $TEST$ error "Values assigned to annotation parameters must be constant." +// $TEST$ error "Values assigned to annotation parameters must be constant." @MyAnnotation1(value = »intFunction()«) -# $TEST$ no error "Values assigned to annotation parameters must be constant." +// $TEST$ no error "Values assigned to annotation parameters must be constant." @MyAnnotation2(»MyEnum.MyConstantVariant(1)«) -# $TEST$ error "Values assigned to annotation parameters must be constant." +// $TEST$ error "Values assigned to annotation parameters must be constant." @Unresolved(»intFunction()«) -# $TEST$ error "Values assigned to annotation parameters must be constant." +// $TEST$ error "Values assigned to annotation parameters must be constant." @MyAnnotation1(unresolved = »intFunction()«) pipeline testPipeline {} diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/arguments/must be constant if parameter is constant/const parameters.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/arguments/must be constant if parameter is constant/const parameters.sdstest index d12779b7..a3608cd7 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/arguments/must be constant if parameter is constant/const parameters.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/arguments/must be constant if parameter is constant/const parameters.sdstest @@ -11,17 +11,17 @@ fun anotherFunctionWithConstantParameter( ) pipeline testPipeline { - # $TEST$ no error "Values assigned to constant parameters must be constant." + // $TEST$ no error "Values assigned to constant parameters must be constant." myFunctionWithConstantParameter(»1«); - # $TEST$ no error "Values assigned to constant parameters must be constant." + // $TEST$ no error "Values assigned to constant parameters must be constant." myFunctionWithConstantParameter(»-2«); - # $TEST$ error "Values assigned to constant parameters must be constant." + // $TEST$ error "Values assigned to constant parameters must be constant." myFunctionWithConstantParameter(»[1, 2][0]«); - # $TEST$ error "Values assigned to constant parameters must be constant." + // $TEST$ error "Values assigned to constant parameters must be constant." myFunctionWithConstantParameter(»intFunction()«); - # $TEST$ error "Values assigned to constant parameters must be constant." + // $TEST$ error "Values assigned to constant parameters must be constant." myFunctionWithConstantParameter(constantParam = »intFunction()«); - # $TEST$ no error "Values assigned to constant parameters must be constant." + // $TEST$ no error "Values assigned to constant parameters must be constant." anotherFunctionWithConstantParameter(»MyEnum.MyConstantVariant(1)«); } diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/arguments/must be constant if parameter is constant/normal parameters.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/arguments/must be constant if parameter is constant/normal parameters.sdstest index 86ac41b8..5cc70771 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/arguments/must be constant if parameter is constant/normal parameters.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/arguments/must be constant if parameter is constant/normal parameters.sdstest @@ -6,13 +6,13 @@ fun myFunctionWithNormalParameter( ) pipeline testPipeline { - # $TEST$ no error "Values assigned to constant parameters must be constant." + // $TEST$ no error "Values assigned to constant parameters must be constant." myFunctionWithNormalParameter(»intFunction()«); - # $TEST$ no error "Values assigned to constant parameters must be constant." + // $TEST$ no error "Values assigned to constant parameters must be constant." myFunctionWithNormalParameter(param = »intFunction()«); - # $TEST$ no error "Values assigned to constant parameters must be constant." + // $TEST$ no error "Values assigned to constant parameters must be constant." unresolved(»intFunction()«); - # $TEST$ no error "Values assigned to constant parameters must be constant." + // $TEST$ no error "Values assigned to constant parameters must be constant." myFunctionWithNormalParameter(unresolved = »intFunction()«); } diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/direct.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/direct.sdstest index 661a6546..5cd39024 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/direct.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/direct.sdstest @@ -1,16 +1,16 @@ package tests.validation.other.expression.calls.recurcion.direct segment s1() { - # $TEST$ error "Call leads to infinite recursion." + // $TEST$ error "Call leads to infinite recursion." »s2()«; } segment s2() { - # $TEST$ error "Call leads to infinite recursion." + // $TEST$ error "Call leads to infinite recursion." »s3()«; } segment s3() { - # $TEST$ error "Call leads to infinite recursion." + // $TEST$ error "Call leads to infinite recursion." »s2()«; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/not recursive.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/not recursive.sdstest index e4d3265b..56cca762 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/not recursive.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/not recursive.sdstest @@ -6,7 +6,7 @@ package tests.validation.other.expression.calls.recurcion.notRecursive */ segment s1() { - # $TEST$ no error "Call leads to infinite recursion." + // $TEST$ no error "Call leads to infinite recursion." »s2(() -> s2())«; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/transitive via function pointer argument.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/transitive via function pointer argument.sdstest index 8365b787..7b987816 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/transitive via function pointer argument.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/transitive via function pointer argument.sdstest @@ -1,7 +1,7 @@ package tests.validation.other.expression.calls.recurcion.transitiveViaFunctionPointerArgument segment s1() { - # $TEST$ error "Call leads to infinite recursion." + // $TEST$ error "Call leads to infinite recursion." »s2(s1)«; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/transitive via lambda argument.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/transitive via lambda argument.sdstest index 6118843f..04cda9eb 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/transitive via lambda argument.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/transitive via lambda argument.sdstest @@ -1,7 +1,7 @@ package tests.validation.other.expression.calls.recurcion.transitiveViaLambdaArgument segment s1() { - # $TEST$ error "Call leads to infinite recursion." + // $TEST$ error "Call leads to infinite recursion." »s2(() -> s1())«; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/transitive.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/transitive.sdstest index f27abb27..aac91299 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/transitive.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/transitive.sdstest @@ -1,16 +1,16 @@ package tests.validation.other.expression.calls.recurcion.transitive segment s1() { - # $TEST$ error "Call leads to infinite recursion." + // $TEST$ error "Call leads to infinite recursion." »s2()«; } segment s2() { - # $TEST$ error "Call leads to infinite recursion." + // $TEST$ error "Call leads to infinite recursion." »s3()«; } segment s3() { - # $TEST$ error "Call leads to infinite recursion." + // $TEST$ error "Call leads to infinite recursion." »s1()«; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/chained expression/missing null safety/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/chained expression/missing null safety/main.sdstest index 8b9d4324..8f3b9ca3 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/chained expression/missing null safety/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/chained expression/missing null safety/main.sdstest @@ -13,41 +13,41 @@ segment call( val myFunction = myClass.f; val myFunctionOrNull = myClassOrNull?.f; - # $TEST$ no error "The receiver can be null so a null-safe call must be used." + // $TEST$ no error "The receiver can be null so a null-safe call must be used." »(() {})()«; - # $TEST$ no error "The receiver can be null so a null-safe call must be used." + // $TEST$ no error "The receiver can be null so a null-safe call must be used." »1()«; - # $TEST$ no error "The receiver can be null so a null-safe call must be used." + // $TEST$ no error "The receiver can be null so a null-safe call must be used." »null()«; - # $TEST$ no error "The receiver can be null so a null-safe call must be used." + // $TEST$ no error "The receiver can be null so a null-safe call must be used." »myFunction()«; - # $TEST$ error "The receiver can be null so a null-safe call must be used." + // $TEST$ error "The receiver can be null so a null-safe call must be used." »myFunctionOrNull()«; - # $TEST$ no error "The receiver can be null so a null-safe call must be used." + // $TEST$ no error "The receiver can be null so a null-safe call must be used." »unresolved()«; - # $TEST$ no error "The receiver can be null so a null-safe call must be used." + // $TEST$ no error "The receiver can be null so a null-safe call must be used." »(() {})?()«; - # $TEST$ no error "The receiver can be null so a null-safe call must be used." + // $TEST$ no error "The receiver can be null so a null-safe call must be used." »1?()«; - # $TEST$ no error "The receiver can be null so a null-safe call must be used." + // $TEST$ no error "The receiver can be null so a null-safe call must be used." »null?()«; - # $TEST$ no error "The receiver can be null so a null-safe call must be used." + // $TEST$ no error "The receiver can be null so a null-safe call must be used." »myFunction?()«; - # $TEST$ no error "The receiver can be null so a null-safe call must be used." + // $TEST$ no error "The receiver can be null so a null-safe call must be used." »myFunctionOrNull?()«; - # $TEST$ no error "The receiver can be null so a null-safe call must be used." + // $TEST$ no error "The receiver can be null so a null-safe call must be used." »unresolved?()«; } @@ -58,38 +58,38 @@ segment indexedAccess( val myList = myClass.l; val myListOrNull = myClassOrNull?.l; - # $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." + // $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." »[1][0]«; - # $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." + // $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." »1[0]«; - # $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." + // $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." »null[0]«; - # $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." + // $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." »myList[0]«; - # $TEST$ error "The receiver can be null so a null-safe indexed access must be used." + // $TEST$ error "The receiver can be null so a null-safe indexed access must be used." »myListOrNull[0]«; - # $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." + // $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." »unresolved[0]«; - # $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." + // $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." »1?[0]«; - # $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." + // $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." »null?[0]«; - # $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." + // $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." »myList?[0]«; - # $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." + // $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." »myListOrNull?[0]«; - # $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." + // $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." »unresolved?[0]«; } @@ -97,14 +97,14 @@ class IndexedAccess?, NonNullable sub List>( nullable: Nullable, nonNullable: NonNullable, - # $TEST$ error "The receiver can be null so a null-safe indexed access must be used." + // $TEST$ error "The receiver can be null so a null-safe indexed access must be used." p1: Any? = »nullable[0]«, - # $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." + // $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." p2: Any? = »nonNullable[0]«, - # $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." + // $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." p3: Any? = »nullable?[0]«, - # $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." + // $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." p4: Any? = »nonNullable?[0]«, ) @@ -112,35 +112,35 @@ segment memberAccess( myClass: MyClass, myClassOrNull: MyClass?, ) { - # $TEST$ no error "The receiver can be null so a null-safe member access must be used." + // $TEST$ no error "The receiver can be null so a null-safe member access must be used." »1.a«; - # $TEST$ error "The receiver can be null so a null-safe member access must be used." + // $TEST$ error "The receiver can be null so a null-safe member access must be used." »null.a«; - # $TEST$ no error "The receiver can be null so a null-safe member access must be used." + // $TEST$ no error "The receiver can be null so a null-safe member access must be used." »myClass.a«; - # $TEST$ error "The receiver can be null so a null-safe member access must be used." + // $TEST$ error "The receiver can be null so a null-safe member access must be used." »myClassOrNull.a«; - # $TEST$ no error "The receiver can be null so a null-safe member access must be used." + // $TEST$ no error "The receiver can be null so a null-safe member access must be used." »unresolved.a«; - # $TEST$ no error "The receiver can be null so a null-safe member access must be used." + // $TEST$ no error "The receiver can be null so a null-safe member access must be used." »1?.a«; - # $TEST$ no error "The receiver can be null so a null-safe member access must be used." + // $TEST$ no error "The receiver can be null so a null-safe member access must be used." »null?.a«; - # $TEST$ no error "The receiver can be null so a null-safe member access must be used." + // $TEST$ no error "The receiver can be null so a null-safe member access must be used." »myClass?.a«; - # $TEST$ no error "The receiver can be null so a null-safe member access must be used." + // $TEST$ no error "The receiver can be null so a null-safe member access must be used." »myClassOrNull?.a«; - # $TEST$ no error "The receiver can be null so a null-safe member access must be used." + // $TEST$ no error "The receiver can be null so a null-safe member access must be used." »unresolved?.a«; } @@ -148,13 +148,13 @@ class MemberAccess( nullable: Nullable, nonNullable: NonNullable, - # $TEST$ error "The receiver can be null so a null-safe member access must be used." + // $TEST$ error "The receiver can be null so a null-safe member access must be used." p1: Any? = »nullable.a«, - # $TEST$ no error "The receiver can be null so a null-safe member access must be used." + // $TEST$ no error "The receiver can be null so a null-safe member access must be used." p2: Any? = »nonNullable.a«, - # $TEST$ no error "The receiver can be null so a null-safe member access must be used." + // $TEST$ no error "The receiver can be null so a null-safe member access must be used." p3: Any? = »nullable?.a«, - # $TEST$ no error "The receiver can be null so a null-safe member access must be used." + // $TEST$ no error "The receiver can be null so a null-safe member access must be used." p4: Any? = »nonNullable?.a«, ) diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/indexed access/list index out of bounds/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/indexed access/list index out of bounds/main.sdstest index dc78adfd..a22e3b64 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/indexed access/list index out of bounds/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/indexed access/list index out of bounds/main.sdstest @@ -10,44 +10,44 @@ segment mySegment( ) { val placeholderList = [1]; - # $TEST$ error "List index '-1' is out of bounds." + // $TEST$ error "List index '-1' is out of bounds." myFunction()[»-1«]; - # $TEST$ no error r"List index '.*' is out of bounds\." + // $TEST$ no error r"List index '.*' is out of bounds\." myFunction()[»0«]; - # $TEST$ no error r"List index '.*' is out of bounds\." + // $TEST$ no error r"List index '.*' is out of bounds\." myFunction()[»1«]; - # $TEST$ no error r"List index '.*' is out of bounds\." + // $TEST$ no error r"List index '.*' is out of bounds\." myFunction()[»parameterIndex«]; - # $TEST$ error "List index '-1' is out of bounds." + // $TEST$ error "List index '-1' is out of bounds." parameterList[»-1«]; - # $TEST$ no error r"List index '.*' is out of bounds\." + // $TEST$ no error r"List index '.*' is out of bounds\." parameterList[»0«]; - # $TEST$ no error r"List index '.*' is out of bounds\." + // $TEST$ no error r"List index '.*' is out of bounds\." parameterList[»1«]; - # $TEST$ no error r"List index '.*' is out of bounds\." + // $TEST$ no error r"List index '.*' is out of bounds\." parameterList[»parameterIndex«]; - # $TEST$ error "List index '-1' is out of bounds." + // $TEST$ error "List index '-1' is out of bounds." nullableList[»-1«]; - # $TEST$ no error r"List index '.*' is out of bounds\." + // $TEST$ no error r"List index '.*' is out of bounds\." nullableList[»0«]; - # $TEST$ no error r"List index '.*' is out of bounds\." + // $TEST$ no error r"List index '.*' is out of bounds\." nullableList[»1«]; - # $TEST$ no error r"List index '.*' is out of bounds\." + // $TEST$ no error r"List index '.*' is out of bounds\." nullableList[»parameterIndex«]; - # $TEST$ error "List index '-1' is out of bounds." + // $TEST$ error "List index '-1' is out of bounds." placeholderList[»-1«]; - # $TEST$ no error r"List index '.*' is out of bounds\." + // $TEST$ no error r"List index '.*' is out of bounds\." placeholderList[»0«]; - # $TEST$ error "List index '1' is out of bounds." + // $TEST$ error "List index '1' is out of bounds." placeholderList[»1«]; - # $TEST$ no error r"List index '.*' is out of bounds\." + // $TEST$ no error r"List index '.*' is out of bounds\." placeholderList[»parameterIndex«]; - # $TEST$ no error r"List index '.*' is out of bounds\." + // $TEST$ no error r"List index '.*' is out of bounds\." unresolved[»-1«]; - # $TEST$ no error r"List index '.*' is out of bounds\." + // $TEST$ no error r"List index '.*' is out of bounds\." placeholderList[»unresolved«]; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/indexed access/map key does not exist/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/indexed access/map key does not exist/main.sdstest index c266fd76..b2978f1e 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/indexed access/map key does not exist/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/indexed access/map key does not exist/main.sdstest @@ -6,29 +6,29 @@ fun myFunction() -> resultMap: Map segment mySegment(parameterMap: Map, parameterKey: String) { val placeholderMap = {"key": 1}; - # $TEST$ no error r"Map key '.*' does not exist\." + // $TEST$ no error r"Map key '.*' does not exist\." myFunction()[»"unknown"«]; - # $TEST$ no error r"Map key '.*' does not exist\." + // $TEST$ no error r"Map key '.*' does not exist\." myFunction()[»"key"«]; - # $TEST$ no error r"Map key '.*' does not exist\." + // $TEST$ no error r"Map key '.*' does not exist\." myFunction()[»parameterKey«]; - # $TEST$ no error r"Map key '.*' does not exist\." + // $TEST$ no error r"Map key '.*' does not exist\." parameterMap[»"unknown"«]; - # $TEST$ no error r"Map key '.*' does not exist\." + // $TEST$ no error r"Map key '.*' does not exist\." parameterMap[»"key"«]; - # $TEST$ no error r"Map key '.*' does not exist\." + // $TEST$ no error r"Map key '.*' does not exist\." parameterMap[»parameterKey«]; - # $TEST$ error "Map key '"unknown"' does not exist." + // $TEST$ error "Map key '"unknown"' does not exist." placeholderMap[»"unknown"«]; - # $TEST$ no error r"Map key '.*' does not exist\." + // $TEST$ no error r"Map key '.*' does not exist\." placeholderMap[»"key"«]; - # $TEST$ no error r"Map key '.*' does not exist\." + // $TEST$ no error r"Map key '.*' does not exist\." placeholderMap[»parameterKey«]; - # $TEST$ no error r"Map key '.*' does not exist\." + // $TEST$ no error r"Map key '.*' does not exist\." unresolved[»"unknown"«]; - # $TEST$ no error r"Map key '.*' does not exist\." + // $TEST$ no error r"Map key '.*' does not exist\." placeholderMap[»unresolved«]; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/infix operations/division by zero/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/infix operations/division by zero/main.sdstest index 9108d7a9..365a2c93 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/infix operations/division by zero/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/infix operations/division by zero/main.sdstest @@ -1,38 +1,38 @@ package tests.validation.other.expressions.infixOperations.divisionByZero pipeline test { - # $TEST$ error "Division by zero." + // $TEST$ error "Division by zero." »1.0 / 0.0«; - # $TEST$ error "Division by zero." + // $TEST$ error "Division by zero." »1.0 / -0.0«; - # $TEST$ no error "Division by zero." + // $TEST$ no error "Division by zero." »1.0 / 1.0«; - # $TEST$ error "Division by zero." + // $TEST$ error "Division by zero." »1.0 / 0«; - # $TEST$ no error "Division by zero." + // $TEST$ no error "Division by zero." »1.0 / 1«; - # $TEST$ error "Division by zero." + // $TEST$ error "Division by zero." »1 / 0.0«; - # $TEST$ error "Division by zero." + // $TEST$ error "Division by zero." »1 / -0.0«; - # $TEST$ no error "Division by zero." + // $TEST$ no error "Division by zero." »1 / 1.0«; - # $TEST$ error "Division by zero." + // $TEST$ error "Division by zero." »1 / 0«; - # $TEST$ no error "Division by zero." + // $TEST$ no error "Division by zero." »1 / 1«; - # $TEST$ no error "Division by zero." + // $TEST$ no error "Division by zero." »null / 0.0«; - # $TEST$ no error "Division by zero." + // $TEST$ no error "Division by zero." »null / -0.0«; - # $TEST$ no error "Division by zero." + // $TEST$ no error "Division by zero." »null / 1.0«; - # $TEST$ no error "Division by zero." + // $TEST$ no error "Division by zero." »null / 0«; - # $TEST$ no error "Division by zero." + // $TEST$ no error "Division by zero." »null / 1«; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/lambdas/context/assigned to typed parameter.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/lambdas/context/assigned to typed parameter.sdstest index bdb60e5e..5bdb35bc 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/lambdas/context/assigned to typed parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/lambdas/context/assigned to typed parameter.sdstest @@ -6,59 +6,59 @@ package tests.validation.other.expressions.lambdas.assignedToTypedParameter @Repeatable annotation MyAnnotation( - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." f: () -> () = »() {}«, - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." g: () -> r: Int = »() -> 1« ) class MyClass( - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." f: () -> () = »() {}«, - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." g: () -> r: Int = ((»() -> 1«)) ) enum MyEnum { MyEnumVariant( - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." f: () -> () = »() {}«, - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." g: () -> r: Int = ((»() -> 1«)) ) } fun myFunction( - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." f: () -> () = »() {}«, - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." g: () -> r: Int = ((»() -> 1«)) ) segment mySegment1( - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." f: () -> () = »() {}«, - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." g: () -> r: Int = ((»() -> 1«)) ) {} segment mySegment2( - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." f: (p: () -> () = »() {}«) -> (), - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." g: (p: () -> (r: Int) = ((»() -> 1«))) -> (), ) { ( - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." f: () -> () = »() {}«, - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." g: () -> r: Int = ((»() -> 1«)) ) {}; ( - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." f: () -> () = »() {}«, - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." g: () -> r: Int = ((»() -> 1«)) ) -> 1; } @@ -68,15 +68,15 @@ segment mySegment2( */ @MyAnnotation( - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." »() {}«, - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." ((»() -> 1«)) ) @MyAnnotation( - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." f = »() {}«, - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." g = ((»() -> 1«)) ) segment lambdasPassedAsArguments( @@ -86,106 +86,106 @@ segment lambdasPassedAsArguments( val expressionLambda = (p: () -> (), q: () -> (r: Int)) -> 1; MyAnnotation( - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." »() {}«, - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." ((»() -> 1«)) ); MyAnnotation( - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." f = »() {}«, - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." g = ((»() -> 1«)) ); MyClass( - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." »() {}«, - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." ((»() -> 1«)) ); MyClass( - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." f = »() {}«, - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." g = ((»() -> 1«)) ); MyEnum.MyEnumVariant( - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." »() {}«, - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." ((»() -> 1«)) ); MyEnum.MyEnumVariant( - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." f = »() {}«, - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." g = ((»() -> 1«)) ); myFunction( - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." »() {}«, - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." ((»() -> 1«)) ); myFunction( - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." f = »() {}«, - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." g = ((»() -> 1«)) ); mySegment1( - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." »() {}«, - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." ((»() -> 1«)) ); mySegment1( - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." f = »() {}«, - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." g = ((»() -> 1«)) ); callableType( - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." »() {}«, - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." ((»() -> 1«)) ); callableType( - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." p = »() {}«, - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." q = ((»() -> 1«)) ); blockLambda( - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." »() {}«, - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." ((»() -> 1«)) ); blockLambda( - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." p = »() {}«, - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." q = ((»() -> 1«)) ); expressionLambda( - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." »() {}«, - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." ((»() -> 1«)) ); expressionLambda( - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." p = »() {}«, - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." q = ((»() -> 1«)) ); } diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/lambdas/context/assigned to unresolved parameter.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/lambdas/context/assigned to unresolved parameter.sdstest index 9ef52e47..1f6db20d 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/lambdas/context/assigned to unresolved parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/lambdas/context/assigned to unresolved parameter.sdstest @@ -3,18 +3,18 @@ package tests.validation.other.expressions.lambdas.context.assignedToUnresolvedP fun myFunction() pipeline unresolvedParameter { - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." myFunction(»() {}«); - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." myFunction(»() -> 1«); - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." myFunction(unresolved = »() {}«); - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." myFunction(unresolved = »() -> 1«); - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." unresolved(»() {}«); - # $TEST$ no error "A lambda must be assigned to a typed parameter." + // $TEST$ no error "A lambda must be assigned to a typed parameter." unresolved(»() -> 1«); } diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/lambdas/context/assigned to untyped parameter.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/lambdas/context/assigned to untyped parameter.sdstest index 0e2b3cde..4a9b77d5 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/lambdas/context/assigned to untyped parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/lambdas/context/assigned to untyped parameter.sdstest @@ -6,59 +6,59 @@ package tests.validation.other.expressions.lambdas.context.assignedToUntypedPara @Repeatable annotation MyAnnotation( - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." f = (»() {}«), - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." g = »() -> 1« ) class MyClass( - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." f = (»() {}«), - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." g = »() -> 1« ) enum MyEnum { MyEnumVariant( - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." f = (»() {}«), - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." g = »() -> 1« ) } fun myFunction( - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." f = (»() {}«), - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." g = »() -> 1« ) segment mySegment1( - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." f = (»() {}«), - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." g = »() -> 1« ) {} segment mySegment2( - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." f: (p = (»() {}«)) -> (), - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." g: (p = »() -> 1«) -> (), ) { ( - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." f = (»() {}«), - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." g = »() -> 1« ) {}; ( - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." f = (»() {}«), - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." g = »() -> 1« ) -> 1; } @@ -68,15 +68,15 @@ segment mySegment2( */ @MyAnnotation( - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." (»() {}«), - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." »() -> 1« ) @MyAnnotation( - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." f = (»() {}«), - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." g = »() -> 1« ) segment lambdasPassedAsArguments( @@ -86,106 +86,106 @@ segment lambdasPassedAsArguments( val expressionLambda = (p, q) -> 1; MyAnnotation( - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." (»() {}«), - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." »() -> 1« ); MyAnnotation( - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." f = (»() {}«), - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." g = »() -> 1« ); MyClass( - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." (»() {}«), - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." »() -> 1« ); MyClass( - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." f = (»() {}«), - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." g = »() -> 1« ); MyEnum.MyEnumVariant( - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." (»() {}«), - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." »() -> 1« ); MyEnum.MyEnumVariant( - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." f = (»() {}«), - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." g = »() -> 1« ); myFunction( - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." (»() {}«), - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." »() -> 1« ); myFunction( - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." f = (»() {}«), - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." g = »() -> 1« ); mySegment1( - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." (»() {}«), - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." »() -> 1« ); mySegment1( - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." f = (»() {}«), - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." g = »() -> 1« ); callableType( - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." (»() {}«), - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." »() -> 1« ); callableType( - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." p = (»() {}«), - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." q = »() -> 1« ); blockLambda( - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." (»() {}«), - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." »() -> 1« ); blockLambda( - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." p = (»() {}«), - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." q = »() -> 1« ); expressionLambda( - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." (»() {}«), - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." »() -> 1« ); expressionLambda( - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." p = (»() {}«), - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." q = »() -> 1« ); } diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/lambdas/context/invalid context.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/lambdas/context/invalid context.sdstest index 53a576ef..192f8fea 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/lambdas/context/invalid context.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/lambdas/context/invalid context.sdstest @@ -1,16 +1,16 @@ package tests.validation.other.expressions.lambdas.context.invalidContext pipeline invalidContext { - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." »() {}«; - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." »() -> 1«; - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." (»() {}«)(); - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." (»() -> 1«)(); - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." val a = »() {}«; - # $TEST$ error "A lambda must be assigned to a typed parameter." + // $TEST$ error "A lambda must be assigned to a typed parameter." val b = »() -> 1«; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/member accesses/enum variant must be instantiated/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/member accesses/enum variant must be instantiated/main.sdstest index f6c890f5..48e97648 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/member accesses/enum variant must be instantiated/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/member accesses/enum variant must be instantiated/main.sdstest @@ -8,43 +8,43 @@ enum MyEnum { } pipeline test { - # $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." + // $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." MyEnum.»EnumVariantWithoutParameterList«; - # $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." + // $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." MyEnum.»EnumVariantWithoutParameterList«(); - # $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." + // $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." val alias1 = MyEnum.EnumVariantWithoutParameterList; »alias1«; - # $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." + // $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." MyEnum.»EnumVariantWithEmptyParameterList«; - # $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." + // $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." MyEnum.»EnumVariantWithEmptyParameterList«(); - # $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." + // $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." val alias2 = MyEnum.EnumVariantWithEmptyParameterList; »alias2«; - # $TEST$ error "The enum variant 'EnumVariantWithoutRequiredParameters' has parameters, so an argument list must be added." + // $TEST$ error "The enum variant 'EnumVariantWithoutRequiredParameters' has parameters, so an argument list must be added." MyEnum.»EnumVariantWithoutRequiredParameters«; - # $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." + // $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." MyEnum.»EnumVariantWithoutRequiredParameters«(); - # $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." + // $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." val alias3 = MyEnum.EnumVariantWithoutRequiredParameters; »alias3«; - # $TEST$ error "The enum variant 'EnumVariantWithRequiredParameters' has parameters, so an argument list must be added." + // $TEST$ error "The enum variant 'EnumVariantWithRequiredParameters' has parameters, so an argument list must be added." MyEnum.»EnumVariantWithRequiredParameters«; - # $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." + // $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." MyEnum.»EnumVariantWithRequiredParameters«(); - # $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." + // $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." val alias4 = MyEnum.EnumVariantWithRequiredParameters; »alias4«; - # $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." + // $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." MyEnum.»Unresolved«; - # $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." + // $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." MyEnum.»Unresolved«(); - # $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." + // $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." val alias5 = MyEnum.Unresolved; »alias5«; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/references/function pointer/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/references/function pointer/main.sdstest index b2cf5d7f..e5a957ba 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/references/function pointer/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/references/function pointer/main.sdstest @@ -11,58 +11,58 @@ fun myFunction2(p: Any) segment mySegment1() {} segment mySegment2() { - # $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + // $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." MyClass().»myInstanceMethod«; - # $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + // $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." MyClass().»myInstanceMethod«.a; - # $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + // $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." MyClass().»myInstanceMethod«.a(); - # $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + // $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." myFunction2(MyClass().»myInstanceMethod«); - # $TEST$ no error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + // $TEST$ no error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." MyClass().»myInstanceMethod«(); - # $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + // $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." MyClass.»myStaticMethod«; - # $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + // $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." MyClass.»myStaticMethod«.a; - # $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + // $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." MyClass.»myStaticMethod«.a(); - # $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + // $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." myFunction2(MyClass.»myStaticMethod«); - # $TEST$ no error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + // $TEST$ no error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." MyClass.»myStaticMethod«(); - # $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + // $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." »myFunction1«; - # $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + // $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." »myFunction1«.a; - # $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + // $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." »myFunction1«.a(); - # $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + // $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." myFunction2(»myFunction1«); - # $TEST$ no error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + // $TEST$ no error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." »myFunction1«(); - # $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + // $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." »mySegment1«; - # $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + // $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." »mySegment1«.a; - # $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + // $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." »mySegment1«.a(); - # $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + // $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." myFunction2(»mySegment1«); - # $TEST$ no error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + // $TEST$ no error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." »mySegment1«(); - # $TEST$ no error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + // $TEST$ no error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." »unresolved«; - # $TEST$ no error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + // $TEST$ no error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." »unresolved«.a; - # $TEST$ no error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + // $TEST$ no error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." »unresolved«.a(); - # $TEST$ no error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + // $TEST$ no error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." myFunction2(»unresolved«); - # $TEST$ no error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + // $TEST$ no error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." »unresolved«(); } diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/references/static class reference/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/references/static class reference/main.sdstest index 547e928b..729e2e53 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/references/static class reference/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/references/static class reference/main.sdstest @@ -15,30 +15,30 @@ class ClassWithStaticMembers { } pipeline test { - # $TEST$ no error "A class must not be statically referenced." + // $TEST$ no error "A class must not be statically referenced." »Unresolved«; - # $TEST$ error "A class must not be statically referenced." + // $TEST$ error "A class must not be statically referenced." »ClassWithConstructor«; - # $TEST$ error "A class must not be statically referenced." + // $TEST$ error "A class must not be statically referenced." »ClassWithoutConstructor«; - # $TEST$ no error "A class must not be statically referenced." + // $TEST$ no error "A class must not be statically referenced." »ClassWithoutConstructor«(); - # $TEST$ no error "A class must not be statically referenced." + // $TEST$ no error "A class must not be statically referenced." »ClassWithConstructor«(); - # $TEST$ no error "A class must not be statically referenced." + // $TEST$ no error "A class must not be statically referenced." »ClassWithStaticMembers«.myAttribute; - # $TEST$ no error "A class must not be statically referenced." + // $TEST$ no error "A class must not be statically referenced." »ClassWithStaticMembers«.unresolved; - # $TEST$ no error "A class must not be statically referenced." - # $TEST$ error "A class must not be statically referenced." + // $TEST$ no error "A class must not be statically referenced." + // $TEST$ error "A class must not be statically referenced." »ClassWithStaticMembers«.»InnerClassWithConstructor«; - # $TEST$ no error "A class must not be statically referenced." - # $TEST$ error "A class must not be statically referenced." + // $TEST$ no error "A class must not be statically referenced." + // $TEST$ error "A class must not be statically referenced." »ClassWithStaticMembers«.»InnerClassWithoutConstructor«; - # $TEST$ no error "A class must not be statically referenced." - # $TEST$ no error "A class must not be statically referenced." + // $TEST$ no error "A class must not be statically referenced." + // $TEST$ no error "A class must not be statically referenced." »ClassWithStaticMembers«.»InnerClassWithConstructor«(); - # $TEST$ no error "A class must not be statically referenced." - # $TEST$ no error "A class must not be statically referenced." + // $TEST$ no error "A class must not be statically referenced." + // $TEST$ no error "A class must not be statically referenced." »ClassWithStaticMembers«.»InnerClassWithConstructor«.myAttribute; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/references/static enum reference/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/references/static enum reference/main.sdstest index 9b9a3ed5..60fc554a 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/references/static enum reference/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/references/static enum reference/main.sdstest @@ -17,22 +17,22 @@ class ClassWithEnum { } pipeline test { - # $TEST$ no error "An enum must not be statically referenced." + // $TEST$ no error "An enum must not be statically referenced." »Unresolved«; - # $TEST$ error "An enum must not be statically referenced." + // $TEST$ error "An enum must not be statically referenced." »Enum«; - # $TEST$ no error "An enum must not be statically referenced." + // $TEST$ no error "An enum must not be statically referenced." »Enum«(); - # $TEST$ no error "An enum must not be statically referenced." + // $TEST$ no error "An enum must not be statically referenced." »Enum«.Variant; - # $TEST$ no error "An enum must not be statically referenced." + // $TEST$ no error "An enum must not be statically referenced." »Enum«.unresolved; - # $TEST$ error "An enum must not be statically referenced." + // $TEST$ error "An enum must not be statically referenced." ClassWithEnum.»Enum«; - # $TEST$ no error "An enum must not be statically referenced." + // $TEST$ no error "An enum must not be statically referenced." ClassWithEnum.»Enum«.Variant; - # $TEST$ error "An enum must not be statically referenced." + // $TEST$ error "An enum must not be statically referenced." ClassWithEnum.ClassWithEnum.»Enum«; - # $TEST$ no error "An enum must not be statically referenced." + // $TEST$ no error "An enum must not be statically referenced." ClassWithEnum.ClassWithEnum.»Enum«.Variant; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/references/target/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/references/target/main.sdstest index e8f144f8..1d2b7fac 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/references/target/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/references/target/main.sdstest @@ -7,12 +7,12 @@ pipeline myPipeline {} schema MySchema {} segment mySegment() { - # $TEST$ error "An annotation must not be the target of a reference." + // $TEST$ error "An annotation must not be the target of a reference." »MyAnnotation«; - # $TEST$ error "A pipeline must not be the target of a reference." + // $TEST$ error "A pipeline must not be the target of a reference." »myPipeline«; - # $TEST$ error "A schema must not be the target of a reference." + // $TEST$ error "A schema must not be the target of a reference." »MySchema«; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/template strings/missing template expression/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/template strings/missing template expression/main.sdstest index ddda7c84..4e394d56 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/template strings/missing template expression/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/template strings/missing template expression/main.sdstest @@ -1,11 +1,11 @@ package tests.validation.other.expressions.templateStrings.missingTemplateExpression pipeline test { - # $TEST$ error "There must be an expression between two string parts." - # $TEST$ error "There must be an expression between two string parts." + // $TEST$ error "There must be an expression between two string parts." + // $TEST$ error "There must be an expression between two string parts." "start {{ »}} inner {{« »}} end"«; - # $TEST$ no error "There must be an expression between two string parts." - # $TEST$ no error "There must be an expression between two string parts." + // $TEST$ no error "There must be an expression between two string parts." + // $TEST$ no error "There must be an expression between two string parts." "start {{ 1 »}} inner {{« 1 »}} end"«; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/imports/main with issues.sdstest b/packages/ttsl-lang/tests/resources/validation/other/imports/main with issues.sdstest index b3413319..85cdcf69 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/imports/main with issues.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/imports/main with issues.sdstest @@ -1,15 +1,15 @@ package tests.other.imports -# $TEST$ error "The package 'tests.other.imports.missing' does not exist." +// $TEST$ error "The package 'tests.other.imports.missing' does not exist." from »tests.other.imports.missing« import * -# $TEST$ error "The package 'tests.other.imports.missing' does not exist." +// $TEST$ error "The package 'tests.other.imports.missing' does not exist." from »tests.other.imports.missing« import C -# $TEST$ error "The package 'tests.other.imports.missing' does not exist." +// $TEST$ error "The package 'tests.other.imports.missing' does not exist." from »tests.other.imports.missing« import C as D -# $TEST$ warning "The package 'tests.other.imports.empty' is empty." +// $TEST$ warning "The package 'tests.other.imports.empty' is empty." from »tests.other.imports.empty« import * -# $TEST$ warning "The package 'tests.other.imports.empty' is empty." +// $TEST$ warning "The package 'tests.other.imports.empty' is empty." from »tests.other.imports.empty« import C -# $TEST$ warning "The package 'tests.other.imports.empty' is empty." +// $TEST$ warning "The package 'tests.other.imports.empty' is empty." from »tests.other.imports.empty« import C as D diff --git a/packages/ttsl-lang/tests/resources/validation/other/imports/main without issues.sdstest b/packages/ttsl-lang/tests/resources/validation/other/imports/main without issues.sdstest index 5e0b52df..193d07a8 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/imports/main without issues.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/imports/main without issues.sdstest @@ -1,7 +1,7 @@ package tests.other.imports -# $TEST$ no error r"The package '\.*' does not exist\." -# $TEST$ no warning r"The package '\.*' is empty\." +// $TEST$ no error r"The package '\.*' does not exist\." +// $TEST$ no warning r"The package '\.*' is empty\." from tests.other.imports.nonEmpty import * from tests.other.imports.nonEmpty import C diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/declarations in pipeline files/main.sdspipe b/packages/ttsl-lang/tests/resources/validation/other/modules/declarations in pipeline files/main.sdspipe index c4a9678c..522c1778 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/declarations in pipeline files/main.sdspipe +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/declarations in pipeline files/main.sdspipe @@ -1,33 +1,33 @@ package tests.validation.other.modules.declarationsInPipelineFiles -# $TEST$ error "A pipeline file must only declare pipelines and segments." +// $TEST$ error "A pipeline file must only declare pipelines and segments." annotation »MyAnnotation« -# $TEST$ error "A pipeline file must only declare pipelines and segments." +// $TEST$ error "A pipeline file must only declare pipelines and segments." class »MyClass« { - # $TEST$ no error "A pipeline file must only declare pipelines and segments." + // $TEST$ no error "A pipeline file must only declare pipelines and segments." attr »a«: Int - # $TEST$ no error "A pipeline file must only declare pipelines and segments." + // $TEST$ no error "A pipeline file must only declare pipelines and segments." class »MyNestedClass« - # $TEST$ no error "A pipeline file must only declare pipelines and segments." + // $TEST$ no error "A pipeline file must only declare pipelines and segments." enum »MyEnum« - # $TEST$ no error "A pipeline file must only declare pipelines and segments." + // $TEST$ no error "A pipeline file must only declare pipelines and segments." fun »myFunction«() } -# $TEST$ error "A pipeline file must only declare pipelines and segments." +// $TEST$ error "A pipeline file must only declare pipelines and segments." enum »MyEnum« { - # $TEST$ no error "A pipeline file must only declare pipelines and segments." + // $TEST$ no error "A pipeline file must only declare pipelines and segments." »MyEnumInstance« } -# $TEST$ error "A pipeline file must only declare pipelines and segments." +// $TEST$ error "A pipeline file must only declare pipelines and segments." fun »myFunction«() -# $TEST$ error "A pipeline file must only declare pipelines and segments." +// $TEST$ error "A pipeline file must only declare pipelines and segments." schema »MySchema« {} -# $TEST$ no error "A pipeline file must only declare pipelines and segments." +// $TEST$ no error "A pipeline file must only declare pipelines and segments." pipeline »myPipeline« {} -# $TEST$ no error "A pipeline file must only declare pipelines and segments." +// $TEST$ no error "A pipeline file must only declare pipelines and segments." segment »mySegment«() {} diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/declarations in stub files/main.sdsstub b/packages/ttsl-lang/tests/resources/validation/other/modules/declarations in stub files/main.sdsstub index dc1967cc..29a5e436 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/declarations in stub files/main.sdsstub +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/declarations in stub files/main.sdsstub @@ -1,33 +1,33 @@ package tests.validation.other.modules.declarationsInStubFiles -# $TEST$ error "A stub file must not declare pipelines or segments." +// $TEST$ error "A stub file must not declare pipelines or segments." pipeline »myPipeline« {} -# $TEST$ error "A stub file must not declare pipelines or segments." +// $TEST$ error "A stub file must not declare pipelines or segments." segment »mySegment«() {} -# $TEST$ no error "A stub file must not declare pipelines or segments." +// $TEST$ no error "A stub file must not declare pipelines or segments." annotation »MyAnnotation« -# $TEST$ no error "A stub file must not declare pipelines or segments." +// $TEST$ no error "A stub file must not declare pipelines or segments." class »MyClass« { - # $TEST$ no error "A stub file must not declare pipelines or segments." + // $TEST$ no error "A stub file must not declare pipelines or segments." attr »a«: Int - # $TEST$ no error "A stub file must not declare pipelines or segments." + // $TEST$ no error "A stub file must not declare pipelines or segments." class »MyNestedClass« - # $TEST$ no error "A stub file must not declare pipelines or segments." + // $TEST$ no error "A stub file must not declare pipelines or segments." enum »MyEnum« - # $TEST$ no error "A stub file must not declare pipelines or segments." + // $TEST$ no error "A stub file must not declare pipelines or segments." fun »myFunction«() } -# $TEST$ no error "A stub file must not declare pipelines or segments." +// $TEST$ no error "A stub file must not declare pipelines or segments." enum »MyEnum« { - # $TEST$ no error "A stub file must not declare pipelines or segments." + // $TEST$ no error "A stub file must not declare pipelines or segments." »MyEnumInstance« } -# $TEST$ no error "A stub file must not declare pipelines or segments." +// $TEST$ no error "A stub file must not declare pipelines or segments." fun »myFunction«() -# $TEST$ no error "A stub file must not declare pipelines or segments." +// $TEST$ no error "A stub file must not declare pipelines or segments." schema »MySchema« {} diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/declarations in test files/everything is allowed (no pipeline errors).sdstest b/packages/ttsl-lang/tests/resources/validation/other/modules/declarations in test files/everything is allowed (no pipeline errors).sdstest index 5524fd2f..d5fe1da7 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/declarations in test files/everything is allowed (no pipeline errors).sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/declarations in test files/everything is allowed (no pipeline errors).sdstest @@ -1,33 +1,33 @@ package tests.validation.other.modules.declarationsInTestFiles -# $TEST$ no error "A pipeline file must only declare pipelines and segments." +// $TEST$ no error "A pipeline file must only declare pipelines and segments." annotation »MyAnnotation« -# $TEST$ no error "A pipeline file must only declare pipelines and segments." +// $TEST$ no error "A pipeline file must only declare pipelines and segments." class »MyClass« { - # $TEST$ no error "A pipeline file must only declare pipelines and segments." + // $TEST$ no error "A pipeline file must only declare pipelines and segments." attr »a«: Int - # $TEST$ no error "A pipeline file must only declare pipelines and segments." + // $TEST$ no error "A pipeline file must only declare pipelines and segments." class »MyNestedClass« - # $TEST$ no error "A pipeline file must only declare pipelines and segments." + // $TEST$ no error "A pipeline file must only declare pipelines and segments." enum »MyEnum« - # $TEST$ no error "A pipeline file must only declare pipelines and segments." + // $TEST$ no error "A pipeline file must only declare pipelines and segments." fun »myFunction«() } -# $TEST$ no error "A pipeline file must only declare pipelines and segments." +// $TEST$ no error "A pipeline file must only declare pipelines and segments." enum »MyEnum« { - # $TEST$ no error "A pipeline file must only declare pipelines and segments." + // $TEST$ no error "A pipeline file must only declare pipelines and segments." »MyEnumInstance« } -# $TEST$ no error "A pipeline file must only declare pipelines and segments." +// $TEST$ no error "A pipeline file must only declare pipelines and segments." fun »myFunction«() -# $TEST$ no error "A pipeline file must only declare pipelines and segments." +// $TEST$ no error "A pipeline file must only declare pipelines and segments." schema »MySchema« {} -# $TEST$ no error "A pipeline file must only declare pipelines and segments." +// $TEST$ no error "A pipeline file must only declare pipelines and segments." pipeline »myPipeline« {} -# $TEST$ no error "A pipeline file must only declare pipelines and segments." +// $TEST$ no error "A pipeline file must only declare pipelines and segments." segment »mySegment«() {} diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/declarations in test files/everything is allowed (no stub errors).sdstest b/packages/ttsl-lang/tests/resources/validation/other/modules/declarations in test files/everything is allowed (no stub errors).sdstest index 70fa2ca0..cae23b56 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/declarations in test files/everything is allowed (no stub errors).sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/declarations in test files/everything is allowed (no stub errors).sdstest @@ -1,33 +1,33 @@ package tests.validation.other.modules.declarationsInTestFiles -# $TEST$ no error "A stub file must not declare pipelines or segments." +// $TEST$ no error "A stub file must not declare pipelines or segments." pipeline »myPipeline« {} -# $TEST$ no error "A stub file must not declare pipelines or segments." +// $TEST$ no error "A stub file must not declare pipelines or segments." segment »mySegment«() {} -# $TEST$ no error "A stub file must not declare pipelines or segments." +// $TEST$ no error "A stub file must not declare pipelines or segments." annotation »MyAnnotation« -# $TEST$ no error "A stub file must not declare pipelines or segments." +// $TEST$ no error "A stub file must not declare pipelines or segments." class »MyClass« { - # $TEST$ no error "A stub file must not declare pipelines or segments." + // $TEST$ no error "A stub file must not declare pipelines or segments." attr »a«: Int - # $TEST$ no error "A stub file must not declare pipelines or segments." + // $TEST$ no error "A stub file must not declare pipelines or segments." class »MyNestedClass« - # $TEST$ no error "A stub file must not declare pipelines or segments." + // $TEST$ no error "A stub file must not declare pipelines or segments." enum »MyEnum« - # $TEST$ no error "A stub file must not declare pipelines or segments." + // $TEST$ no error "A stub file must not declare pipelines or segments." fun »myFunction«() } -# $TEST$ no error "A stub file must not declare pipelines or segments." +// $TEST$ no error "A stub file must not declare pipelines or segments." enum »MyEnum« { - # $TEST$ no error "A stub file must not declare pipelines or segments." + // $TEST$ no error "A stub file must not declare pipelines or segments." »MyEnumInstance« } -# $TEST$ no error "A stub file must not declare pipelines or segments." +// $TEST$ no error "A stub file must not declare pipelines or segments." fun »myFunction«() -# $TEST$ no error "A stub file must not declare pipelines or segments." +// $TEST$ no error "A stub file must not declare pipelines or segments." schema »MySchema« {} diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (empty).sdspipe b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (empty).sdspipe index 1efef064..27af28cb 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (empty).sdspipe +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (empty).sdspipe @@ -1 +1 @@ -# $TEST$ no error "A module with declarations must state its package." +// $TEST$ no error "A module with declarations must state its package." diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (only annotations).sdspipe b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (only annotations).sdspipe index 7583c76e..d78842d9 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (only annotations).sdspipe +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (only annotations).sdspipe @@ -1,3 +1,3 @@ -# $TEST$ no error "A module with declarations must state its package." +// $TEST$ no error "A module with declarations must state its package." @AnnotationCall diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (only imports).sdspipe b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (only imports).sdspipe index 15f5d970..d27d113d 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (only imports).sdspipe +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (only imports).sdspipe @@ -1,3 +1,3 @@ -# $TEST$ no error "A module with declarations must state its package." +// $TEST$ no error "A module with declarations must state its package." from myPackage import MyClass diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (with declarations and package).sdspipe b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (with declarations and package).sdspipe index fd8c0c92..6f4bf0ff 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (with declarations and package).sdspipe +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (with declarations and package).sdspipe @@ -1,7 +1,7 @@ package tests.validation.other.modules.mustStatePackage -# $TEST$ no error "A module with declarations must state its package." +// $TEST$ no error "A module with declarations must state its package." segment »s«() {} -# $TEST$ no error "A module with declarations must state its package." +// $TEST$ no error "A module with declarations must state its package." segment »t«() {} diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (with declarations but no package).sdspipe b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (with declarations but no package).sdspipe index 192ad2b2..a55723f4 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (with declarations but no package).sdspipe +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (with declarations but no package).sdspipe @@ -1,5 +1,5 @@ -# $TEST$ error "A module with declarations must state its package." +// $TEST$ error "A module with declarations must state its package." segment »s«() {} -# $TEST$ no error "A module with declarations must state its package." +// $TEST$ no error "A module with declarations must state its package." segment »t«() {} diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (empty).sdsstub b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (empty).sdsstub index 1efef064..27af28cb 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (empty).sdsstub +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (empty).sdsstub @@ -1 +1 @@ -# $TEST$ no error "A module with declarations must state its package." +// $TEST$ no error "A module with declarations must state its package." diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (only annotations).sdsstub b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (only annotations).sdsstub index 7583c76e..d78842d9 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (only annotations).sdsstub +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (only annotations).sdsstub @@ -1,3 +1,3 @@ -# $TEST$ no error "A module with declarations must state its package." +// $TEST$ no error "A module with declarations must state its package." @AnnotationCall diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (only imports).sdsstub b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (only imports).sdsstub index 15f5d970..d27d113d 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (only imports).sdsstub +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (only imports).sdsstub @@ -1,3 +1,3 @@ -# $TEST$ no error "A module with declarations must state its package." +// $TEST$ no error "A module with declarations must state its package." from myPackage import MyClass diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (with declarations and package).sdsstub b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (with declarations and package).sdsstub index 80ece2d4..0a9fbaa5 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (with declarations and package).sdsstub +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (with declarations and package).sdsstub @@ -1,7 +1,7 @@ package tests.validation.other.modules.mustStatePackage -# $TEST$ no error "A module with declarations must state its package." +// $TEST$ no error "A module with declarations must state its package." class »C« -# $TEST$ no error "A module with declarations must state its package." +// $TEST$ no error "A module with declarations must state its package." class »D« diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (with declarations but no package).sdsstub b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (with declarations but no package).sdsstub index 1064b7c2..ca0e6e42 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (with declarations but no package).sdsstub +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (with declarations but no package).sdsstub @@ -1,5 +1,5 @@ -# $TEST$ error "A module with declarations must state its package." +// $TEST$ error "A module with declarations must state its package." class »C« -# $TEST$ no error "A module with declarations must state its package." +// $TEST$ no error "A module with declarations must state its package." class »D« diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/pipe elsewhere.sdspipe b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/pipe elsewhere.sdspipe index edad3c9d..f193b218 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/pipe elsewhere.sdspipe +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/pipe elsewhere.sdspipe @@ -1,3 +1,3 @@ -# $TEST$ no error "A pipeline file must not be in a 'safeds' package." +// $TEST$ no error "A pipeline file must not be in a 'safeds' package." package »tests.validation.other.modules.pipelineFilesMustNotBeInSafedsPackage« diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/pipe in safeds.sdspipe b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/pipe in safeds.sdspipe index 77a115e4..01bbbb02 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/pipe in safeds.sdspipe +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/pipe in safeds.sdspipe @@ -1,3 +1,3 @@ -# $TEST$ error "A pipeline file must not be in a 'safeds' package." +// $TEST$ error "A pipeline file must not be in a 'safeds' package." package »safeds« diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/pipe in subpackage of safeds.sdspipe b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/pipe in subpackage of safeds.sdspipe index 55feddd3..84d64908 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/pipe in subpackage of safeds.sdspipe +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/pipe in subpackage of safeds.sdspipe @@ -1,3 +1,3 @@ -# $TEST$ error "A pipeline file must not be in a 'safeds' package." +// $TEST$ error "A pipeline file must not be in a 'safeds' package." package »safeds.validation.other.modules.pipelineFilesMustNotBeInSafedsPackage« diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/stub elsewhere.sdsstub b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/stub elsewhere.sdsstub index edad3c9d..f193b218 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/stub elsewhere.sdsstub +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/stub elsewhere.sdsstub @@ -1,3 +1,3 @@ -# $TEST$ no error "A pipeline file must not be in a 'safeds' package." +// $TEST$ no error "A pipeline file must not be in a 'safeds' package." package »tests.validation.other.modules.pipelineFilesMustNotBeInSafedsPackage« diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/stub in safeds.sdsstub b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/stub in safeds.sdsstub index 91ef8016..07eecbb3 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/stub in safeds.sdsstub +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/stub in safeds.sdsstub @@ -1,3 +1,3 @@ -# $TEST$ no error "A pipeline file must not be in a 'safeds' package." +// $TEST$ no error "A pipeline file must not be in a 'safeds' package." package »safeds« diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/stub in subpackage of safeds.sdsstub b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/stub in subpackage of safeds.sdsstub index c263943e..0724b7d8 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/stub in subpackage of safeds.sdsstub +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/stub in subpackage of safeds.sdsstub @@ -1,3 +1,3 @@ -# $TEST$ no error "A pipeline file must not be in a 'safeds' package." +// $TEST$ no error "A pipeline file must not be in a 'safeds' package." package »safeds.validation.other.modules.pipelineFilesMustNotBeInSafedsPackage« diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/test elsewhere.sdstest b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/test elsewhere.sdstest index edad3c9d..f193b218 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/test elsewhere.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/test elsewhere.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no error "A pipeline file must not be in a 'safeds' package." +// $TEST$ no error "A pipeline file must not be in a 'safeds' package." package »tests.validation.other.modules.pipelineFilesMustNotBeInSafedsPackage« diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/test in safeds.sdstest b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/test in safeds.sdstest index 91ef8016..07eecbb3 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/test in safeds.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/test in safeds.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no error "A pipeline file must not be in a 'safeds' package." +// $TEST$ no error "A pipeline file must not be in a 'safeds' package." package »safeds« diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/test in subpackage of safeds.sdstest b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/test in subpackage of safeds.sdstest index c263943e..0724b7d8 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/test in subpackage of safeds.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/test in subpackage of safeds.sdstest @@ -1,3 +1,3 @@ -# $TEST$ no error "A pipeline file must not be in a 'safeds' package." +// $TEST$ no error "A pipeline file must not be in a 'safeds' package." package »safeds.validation.other.modules.pipelineFilesMustNotBeInSafedsPackage« diff --git a/packages/ttsl-lang/tests/resources/validation/other/statements/assignments/has no effect/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/statements/assignments/has no effect/main.sdstest index b6aa8c0f..10702000 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/statements/assignments/has no effect/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/statements/assignments/has no effect/main.sdstest @@ -1,29 +1,29 @@ package tests.validation.other.statements.assignments.hasNoEffect segment mySegment() -> a: Int { - # $TEST$ warning "This statement does nothing." + // $TEST$ warning "This statement does nothing." »_ = 1 + 2;« - # $TEST$ no warning "This statement does nothing." + // $TEST$ no warning "This statement does nothing." »val a = 1;« - # $TEST$ no warning "This statement does nothing." + // $TEST$ no warning "This statement does nothing." »yield a = 1;« () { - # $TEST$ warning "This statement does nothing." + // $TEST$ warning "This statement does nothing." »_ = 1 + 2;« - # $TEST$ no warning "This statement does nothing." + // $TEST$ no warning "This statement does nothing." »val a = 1;« - # $TEST$ no warning "This statement does nothing." + // $TEST$ no warning "This statement does nothing." »yield a = 1;« }; } segment mySegment2(f: () -> (r: Int)) { - # $TEST$ no warning "This statement does nothing." + // $TEST$ no warning "This statement does nothing." »_ = f();« - # $TEST$ no warning "This statement does nothing." + // $TEST$ no warning "This statement does nothing." »_ = unresolved();« } diff --git a/packages/ttsl-lang/tests/resources/validation/other/statements/assignments/implicitly ignore result/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/statements/assignments/implicitly ignore result/main.sdstest index 9b325710..1747c2f1 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/statements/assignments/implicitly ignore result/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/statements/assignments/implicitly ignore result/main.sdstest @@ -12,41 +12,41 @@ enum MyEnum { } pipeline myPipeline { - # $TEST$ warning "The assignment implicitly ignores the result 'second'." + // $TEST$ warning "The assignment implicitly ignores the result 'second'." »_ = twoResults();« - # $TEST$ warning "The assignment implicitly ignores the results 'second', 'third'." + // $TEST$ warning "The assignment implicitly ignores the results 'second', 'third'." »_ = threeResults();« - # $TEST$ no warning r"The assignment implicitly ignores the result\.*" + // $TEST$ no warning r"The assignment implicitly ignores the result\.*" »_ = oneResult();« - # $TEST$ no warning r"The assignment implicitly ignores the result\.*" + // $TEST$ no warning r"The assignment implicitly ignores the result\.*" »_, _ = twoResults();« - # $TEST$ no warning r"The assignment implicitly ignores the result\.*" + // $TEST$ no warning r"The assignment implicitly ignores the result\.*" »_, _, _ = threeResults();« - # $TEST$ no warning r"The assignment implicitly ignores the result\.*" + // $TEST$ no warning r"The assignment implicitly ignores the result\.*" »_ = MyClass();« - # $TEST$ no warning r"The assignment implicitly ignores the result\.*" + // $TEST$ no warning r"The assignment implicitly ignores the result\.*" »_ = MyEnum.MyEnumVariant();« - # $TEST$ no warning r"The assignment implicitly ignores the result\.*" + // $TEST$ no warning r"The assignment implicitly ignores the result\.*" »_ = 1;« - # $TEST$ no warning r"The assignment implicitly ignores the result\.*" + // $TEST$ no warning r"The assignment implicitly ignores the result\.*" »_ = noResults();« - # $TEST$ no warning r"The assignment implicitly ignores the result\.*" + // $TEST$ no warning r"The assignment implicitly ignores the result\.*" »_, _ = oneResult();« - # $TEST$ no warning r"The assignment implicitly ignores the result\.*" + // $TEST$ no warning r"The assignment implicitly ignores the result\.*" »_, _, _ = twoResults();« - # $TEST$ no warning r"The assignment implicitly ignores the result\.*" + // $TEST$ no warning r"The assignment implicitly ignores the result\.*" »_, _, _, _ = threeResults();« - # $TEST$ no warning r"The assignment implicitly ignores the result\.*" + // $TEST$ no warning r"The assignment implicitly ignores the result\.*" »_, _ = MyClass();« - # $TEST$ no warning r"The assignment implicitly ignores the result\.*" + // $TEST$ no warning r"The assignment implicitly ignores the result\.*" »_, _ = MyEnum.MyEnumVariant();« - # $TEST$ no warning r"The assignment implicitly ignores the result\.*" + // $TEST$ no warning r"The assignment implicitly ignores the result\.*" »_, _ = 1;« - # $TEST$ no warning r"The assignment implicitly ignores the result\.*" + // $TEST$ no warning r"The assignment implicitly ignores the result\.*" »_ = unresolved;« - # $TEST$ no warning r"The assignment implicitly ignores the result\.*" + // $TEST$ no warning r"The assignment implicitly ignores the result\.*" »_ = unresolved();« } diff --git a/packages/ttsl-lang/tests/resources/validation/other/statements/assignments/nothing assigned/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/statements/assignments/nothing assigned/main.sdstest index 3c04d43a..c0c6a2be 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/statements/assignments/nothing assigned/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/statements/assignments/nothing assigned/main.sdstest @@ -26,78 +26,78 @@ segment mySegment() -> ( r13: Any?, r14: Any?, ) { - # $TEST$ error "No value is assigned to this assignee." + // $TEST$ error "No value is assigned to this assignee." »_« = noResults(); - # $TEST$ no error "No value is assigned to this assignee." - # $TEST$ error "No value is assigned to this assignee." + // $TEST$ no error "No value is assigned to this assignee." + // $TEST$ error "No value is assigned to this assignee." »_«, »_« = oneResult(); - # $TEST$ no error "No value is assigned to this assignee." - # $TEST$ no error "No value is assigned to this assignee." - # $TEST$ error "No value is assigned to this assignee." + // $TEST$ no error "No value is assigned to this assignee." + // $TEST$ no error "No value is assigned to this assignee." + // $TEST$ error "No value is assigned to this assignee." »_«, »_«, »_« = twoResults(); - # $TEST$ no error "No value is assigned to this assignee." - # $TEST$ error "No value is assigned to this assignee." + // $TEST$ no error "No value is assigned to this assignee." + // $TEST$ error "No value is assigned to this assignee." »_«, »_« = MyClass(); - # $TEST$ no error "No value is assigned to this assignee." - # $TEST$ error "No value is assigned to this assignee." + // $TEST$ no error "No value is assigned to this assignee." + // $TEST$ error "No value is assigned to this assignee." »_«, »_« = MyEnum.MyEnumVariant(); - # $TEST$ no error "No value is assigned to this assignee." - # $TEST$ error "No value is assigned to this assignee." + // $TEST$ no error "No value is assigned to this assignee." + // $TEST$ error "No value is assigned to this assignee." »_«, »_« = 1; - # $TEST$ no error "No value is assigned to this assignee." - # $TEST$ error "No value is assigned to this assignee." + // $TEST$ no error "No value is assigned to this assignee." + // $TEST$ error "No value is assigned to this assignee." »_«, »_« = unresolved; - # $TEST$ error "No value is assigned to this assignee." - # $TEST$ error "No value is assigned to this assignee." + // $TEST$ error "No value is assigned to this assignee." + // $TEST$ error "No value is assigned to this assignee." »_«, »_« = unresolved(); - # $TEST$ error "No value is assigned to this assignee." + // $TEST$ error "No value is assigned to this assignee." »val a« = noResults(); - # $TEST$ no error "No value is assigned to this assignee." - # $TEST$ error "No value is assigned to this assignee." + // $TEST$ no error "No value is assigned to this assignee." + // $TEST$ error "No value is assigned to this assignee." »val b«, »val c« = oneResult(); - # $TEST$ no error "No value is assigned to this assignee." - # $TEST$ no error "No value is assigned to this assignee." - # $TEST$ error "No value is assigned to this assignee." + // $TEST$ no error "No value is assigned to this assignee." + // $TEST$ no error "No value is assigned to this assignee." + // $TEST$ error "No value is assigned to this assignee." »val d«, »val e«, »val f« = twoResults(); - # $TEST$ no error "No value is assigned to this assignee." - # $TEST$ error "No value is assigned to this assignee." + // $TEST$ no error "No value is assigned to this assignee." + // $TEST$ error "No value is assigned to this assignee." »val g«, »val h« = MyClass(); - # $TEST$ no error "No value is assigned to this assignee." - # $TEST$ error "No value is assigned to this assignee." + // $TEST$ no error "No value is assigned to this assignee." + // $TEST$ error "No value is assigned to this assignee." »val i«, »val j« = MyEnum.MyEnumVariant(); - # $TEST$ no error "No value is assigned to this assignee." - # $TEST$ error "No value is assigned to this assignee." + // $TEST$ no error "No value is assigned to this assignee." + // $TEST$ error "No value is assigned to this assignee." »val k«, »val l« = 1; - # $TEST$ no error "No value is assigned to this assignee." - # $TEST$ error "No value is assigned to this assignee." + // $TEST$ no error "No value is assigned to this assignee." + // $TEST$ error "No value is assigned to this assignee." »val m«, »val n« = unresolved; - # $TEST$ error "No value is assigned to this assignee." - # $TEST$ error "No value is assigned to this assignee." + // $TEST$ error "No value is assigned to this assignee." + // $TEST$ error "No value is assigned to this assignee." »val o«, »val p« = unresolved(); - # $TEST$ error "No value is assigned to this assignee." + // $TEST$ error "No value is assigned to this assignee." »yield r1« = noResults(); - # $TEST$ no error "No value is assigned to this assignee." - # $TEST$ error "No value is assigned to this assignee." + // $TEST$ no error "No value is assigned to this assignee." + // $TEST$ error "No value is assigned to this assignee." »yield r2«, »yield r3« = oneResult(); - # $TEST$ no error "No value is assigned to this assignee." - # $TEST$ no error "No value is assigned to this assignee." - # $TEST$ error "No value is assigned to this assignee." + // $TEST$ no error "No value is assigned to this assignee." + // $TEST$ no error "No value is assigned to this assignee." + // $TEST$ error "No value is assigned to this assignee." »yield r4«, »yield r5«, »yield r6« = twoResults(); - # $TEST$ no error "No value is assigned to this assignee." - # $TEST$ error "No value is assigned to this assignee." + // $TEST$ no error "No value is assigned to this assignee." + // $TEST$ error "No value is assigned to this assignee." »yield r7«, »yield r8« = MyClass(); - # $TEST$ no error "No value is assigned to this assignee." - # $TEST$ error "No value is assigned to this assignee." + // $TEST$ no error "No value is assigned to this assignee." + // $TEST$ error "No value is assigned to this assignee." »yield r9«, »yield r10« = MyEnum.MyEnumVariant(); - # $TEST$ no error "No value is assigned to this assignee." - # $TEST$ error "No value is assigned to this assignee." + // $TEST$ no error "No value is assigned to this assignee." + // $TEST$ error "No value is assigned to this assignee." »yield r11«, »yield r12« = 1; - # $TEST$ no error "No value is assigned to this assignee." - # $TEST$ error "No value is assigned to this assignee." + // $TEST$ no error "No value is assigned to this assignee." + // $TEST$ error "No value is assigned to this assignee." »yield r13«, »yield r14« = unresolved; - # $TEST$ error "No value is assigned to this assignee." - # $TEST$ error "No value is assigned to this assignee." + // $TEST$ error "No value is assigned to this assignee." + // $TEST$ error "No value is assigned to this assignee." »yield r15«, »yield r16« = unresolved(); } diff --git a/packages/ttsl-lang/tests/resources/validation/other/statements/assignments/yield forbidden in pipeline/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/statements/assignments/yield forbidden in pipeline/main.sdstest index d865f0be..95bc46e8 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/statements/assignments/yield forbidden in pipeline/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/statements/assignments/yield forbidden in pipeline/main.sdstest @@ -1,16 +1,16 @@ package tests.validation.other.statements.assignments.yieldForbiddenInPipeline segment s() { - # $TEST$ no error "Yield must not be used in a pipeline." + // $TEST$ no error "Yield must not be used in a pipeline." »yield a« = 1; } pipeline p { - # $TEST$ error "Yield must not be used in a pipeline." + // $TEST$ error "Yield must not be used in a pipeline." »yield a« = 1; () { - # $TEST$ no error "Yield must not be used in a pipeline." + // $TEST$ no error "Yield must not be used in a pipeline." »yield a« = 1; }; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/statements/expression statements/has no effect/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/statements/expression statements/has no effect/main.sdstest index c72c2b3d..5dcf20fe 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/statements/expression statements/has no effect/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/statements/expression statements/has no effect/main.sdstest @@ -30,62 +30,62 @@ segment recursiveB() { } segment mySegment() { - # $TEST$ warning "This statement does nothing." + // $TEST$ warning "This statement does nothing." »1 + 2;« - # $TEST$ warning "This statement does nothing." + // $TEST$ warning "This statement does nothing." »pureFunction();« - # $TEST$ warning "This statement does nothing." + // $TEST$ warning "This statement does nothing." »MyClass().pureFunction();« - # $TEST$ no warning "This statement does nothing." + // $TEST$ no warning "This statement does nothing." »impureFunction();« - # $TEST$ no warning "This statement does nothing." + // $TEST$ no warning "This statement does nothing." »MyClass().impureFunction();« () { - # $TEST$ warning "This statement does nothing." + // $TEST$ warning "This statement does nothing." »1 + 2;« - # $TEST$ warning "This statement does nothing." + // $TEST$ warning "This statement does nothing." »pureFunction();« - # $TEST$ warning "This statement does nothing." + // $TEST$ warning "This statement does nothing." »MyClass().pureFunction();« - # $TEST$ no warning "This statement does nothing." + // $TEST$ no warning "This statement does nothing." »impureFunction();« - # $TEST$ no warning "This statement does nothing." + // $TEST$ no warning "This statement does nothing." »MyClass().impureFunction();« }; - # $TEST$ warning "This statement does nothing." + // $TEST$ warning "This statement does nothing." »pureSegment();« - # $TEST$ no warning "This statement does nothing." + // $TEST$ no warning "This statement does nothing." »impureSegment();« - # $TEST$ warning "This statement does nothing." + // $TEST$ warning "This statement does nothing." »(() { pureFunction(); MyClass().pureFunction(); })();« - # $TEST$ no warning "This statement does nothing." + // $TEST$ no warning "This statement does nothing." »(() { impureFunction(); })();« - # $TEST$ no warning "This statement does nothing." + // $TEST$ no warning "This statement does nothing." »(() { MyClass().impureFunction(); })();« - # $TEST$ no warning "This statement does nothing." + // $TEST$ no warning "This statement does nothing." »recursiveA();« } segment mySegment2(f: () -> (r: Int)) { - # $TEST$ no warning "This statement does nothing." + // $TEST$ no warning "This statement does nothing." »f();« - # $TEST$ no warning "This statement does nothing." + // $TEST$ no warning "This statement does nothing." »unresolved();« } diff --git a/packages/ttsl-lang/tests/resources/validation/other/types/callable types/context/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/types/callable types/context/main.sdstest index 9f2b929c..b166586e 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/types/callable types/context/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/types/callable types/context/main.sdstest @@ -1,68 +1,68 @@ package tests.validation.other.types.callableTypes.context annotation MyAnnotation( - # $TEST$ no error "Callable types must only be used for parameters." + // $TEST$ no error "Callable types must only be used for parameters." p: »() -> ()«, ) class MyClass( - # $TEST$ no error "Callable types must only be used for parameters." + // $TEST$ no error "Callable types must only be used for parameters." p: »() -> ()«, ) { - # $TEST$ error "Callable types must only be used for parameters." + // $TEST$ error "Callable types must only be used for parameters." attr a: »() -> ()« } enum MyEnum { MyEnumVariant( - # $TEST$ no error "Callable types must only be used for parameters." + // $TEST$ no error "Callable types must only be used for parameters." p: »() -> ()«, ) } fun myFunction( - # $TEST$ no error "Callable types must only be used for parameters." + // $TEST$ no error "Callable types must only be used for parameters." p: »() -> ()«, ) -> ( - # $TEST$ error "Callable types must only be used for parameters." + // $TEST$ error "Callable types must only be used for parameters." r: »() -> ()«, ) segment mySegment1( - # $TEST$ no error "Callable types must only be used for parameters." + // $TEST$ no error "Callable types must only be used for parameters." p: »() -> ()«, ) -> ( - # $TEST$ error "Callable types must only be used for parameters." + // $TEST$ error "Callable types must only be used for parameters." r: »() -> ()«, ) {} segment mySegment2( - # $TEST$ no error "Callable types must only be used for parameters." - # $TEST$ error "Callable types must only be used for parameters." + // $TEST$ no error "Callable types must only be used for parameters." + // $TEST$ error "Callable types must only be used for parameters." c: (p: »() -> ()«) -> (r: »() -> ()«), ) { - # $TEST$ no error "Callable types must only be used for parameters." + // $TEST$ no error "Callable types must only be used for parameters." ( p: »() -> ()«, ) {}; - # $TEST$ no error "Callable types must only be used for parameters." + // $TEST$ no error "Callable types must only be used for parameters." ( p: »() -> ()«, ) -> 1; } segment mySegment3( - # $TEST$ error "Callable types must only be used for parameters." + // $TEST$ error "Callable types must only be used for parameters." p1: MyClass<»() -> ()«>, ) {} segment mySegment4( - # $TEST$ error "Callable types must only be used for parameters." + // $TEST$ error "Callable types must only be used for parameters." p1: »() -> ()«.MyClass ) {} segment mySegment5( - # $TEST$ error "Callable types must only be used for parameters." + // $TEST$ error "Callable types must only be used for parameters." p1: union<»() -> ()«> ) {} diff --git a/packages/ttsl-lang/tests/resources/validation/other/types/callable types/context/nested.sdstest b/packages/ttsl-lang/tests/resources/validation/other/types/callable types/context/nested.sdstest index 6add3efd..3389e2ac 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/types/callable types/context/nested.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/types/callable types/context/nested.sdstest @@ -5,12 +5,12 @@ package tests.validation.other.types.callableTypes.context */ class MyClass1 { - # $TEST$ no error "Callable types must only be used for parameters." + // $TEST$ no error "Callable types must only be used for parameters." attr a: () -> (r: »() -> ()«) } class MyClass2 { - # $TEST$ no error "Callable types must only be used for parameters." - # $TEST$ no error "Callable types must only be used for parameters." + // $TEST$ no error "Callable types must only be used for parameters." + // $TEST$ no error "Callable types must only be used for parameters." attr a: () -> (r: (p: »() -> ()«) -> (r: »() -> ()«)) } diff --git a/packages/ttsl-lang/tests/resources/validation/other/types/callable types/must not have optional parameters/optional.sdstest b/packages/ttsl-lang/tests/resources/validation/other/types/callable types/must not have optional parameters/optional.sdstest index 8ce5ad98..b7e13798 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/types/callable types/must not have optional parameters/optional.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/types/callable types/must not have optional parameters/optional.sdstest @@ -2,7 +2,7 @@ package tests.validation.other.types.callableTypes.mustNotHaveOptionalParameters fun f( g: ( - # $TEST$ error "A callable type must not have optional parameters." + // $TEST$ error "A callable type must not have optional parameters." p: Int = »1«, ) -> () ) diff --git a/packages/ttsl-lang/tests/resources/validation/other/types/callable types/must not have optional parameters/required.sdstest b/packages/ttsl-lang/tests/resources/validation/other/types/callable types/must not have optional parameters/required.sdstest index 68c4f378..a70ae8c0 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/types/callable types/must not have optional parameters/required.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/types/callable types/must not have optional parameters/required.sdstest @@ -2,7 +2,7 @@ package tests.validation.other.types.callableTypes.mustNotHaveOptionalParameters fun f( g: ( - # $TEST$ no error "A callable type must not have optional parameters." + // $TEST$ no error "A callable type must not have optional parameters." p: Int, ) -> () ) diff --git a/packages/ttsl-lang/tests/resources/validation/other/types/literal types/duplicate literals/empty list.sdstest b/packages/ttsl-lang/tests/resources/validation/other/types/literal types/duplicate literals/empty list.sdstest index ca1f7cdc..ad8a0237 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/types/literal types/duplicate literals/empty list.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/types/literal types/duplicate literals/empty list.sdstest @@ -1,6 +1,6 @@ package tests.validation.other.types.literalTypes.duplicateLiterals -# $TEST$ no warning r"The literal .* was already listed." +// $TEST$ no warning r"The literal .* was already listed." segment mySegment1( p: literal<> diff --git a/packages/ttsl-lang/tests/resources/validation/other/types/literal types/duplicate literals/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/types/literal types/duplicate literals/main.sdstest index 31457305..7ecff256 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/types/literal types/duplicate literals/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/types/literal types/duplicate literals/main.sdstest @@ -1,14 +1,14 @@ package tests.validation.other.types.literalTypes.duplicateLiterals segment mySegment( - # $TEST$ no warning r"The literal .* was already listed." + // $TEST$ no warning r"The literal .* was already listed." p: literal<»1«>, q: literal< - # $TEST$ no warning r"The literal .* was already listed." + // $TEST$ no warning r"The literal .* was already listed." »1«, - # $TEST$ no warning r"The literal .* was already listed." + // $TEST$ no warning r"The literal .* was already listed." »2«, - # $TEST$ warning r"The literal 1 was already listed." + // $TEST$ warning r"The literal 1 was already listed." »1«, >, ) {} diff --git a/packages/ttsl-lang/tests/resources/validation/other/types/literal types/must have literals/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/types/literal types/must have literals/main.sdstest index 89d7492e..e93a113f 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/types/literal types/must have literals/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/types/literal types/must have literals/main.sdstest @@ -1,16 +1,16 @@ package tests.validation.other.types.literalTypes.mustHaveLiterals -# $TEST$ error "A literal type must have at least one literal." +// $TEST$ error "A literal type must have at least one literal." segment mySegment1( p: literal»<>« ) {} -# $TEST$ no error "A literal type must have at least one literal." +// $TEST$ no error "A literal type must have at least one literal." segment mySegment2( p: literal»<1>« ) {} -# $TEST$ no error "A literal type must have at least one literal." +// $TEST$ no error "A literal type must have at least one literal." segment mySegment3( p: literal»<1, "">« ) {} diff --git a/packages/ttsl-lang/tests/resources/validation/other/types/literal types/must not contain list literals/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/types/literal types/must not contain list literals/main.sdstest index 356e8edd..d0e6cae7 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/types/literal types/must not contain list literals/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/types/literal types/must not contain list literals/main.sdstest @@ -1,6 +1,6 @@ package tests.validation.other.types.literalTypes.mustNotContanListLiterals -# $TEST$ error "Literal types must not contain list literals." +// $TEST$ error "Literal types must not contain list literals." segment mySegment( x: literal<»[]«> ) {} diff --git a/packages/ttsl-lang/tests/resources/validation/other/types/literal types/must not contain map literals/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/types/literal types/must not contain map literals/main.sdstest index e4acfaa9..08bdf73f 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/types/literal types/must not contain map literals/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/types/literal types/must not contain map literals/main.sdstest @@ -1,6 +1,6 @@ package tests.validation.other.types.literalsTypes.mustNotContainMapLiterals -# $TEST$ error "Literal types must not contain map literals." +// $TEST$ error "Literal types must not contain map literals." segment mySegment( x: literal<»{}«> ) {} diff --git a/packages/ttsl-lang/tests/resources/validation/other/types/type argument lists/duplicate type parameter/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/types/type argument lists/duplicate type parameter/main.sdstest index 2bae294e..0cbf53fe 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/types/type argument lists/duplicate type parameter/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/types/type argument lists/duplicate type parameter/main.sdstest @@ -4,33 +4,33 @@ class MyClass fun myFunction( f: MyClass< - # $TEST$ no error r"The type parameter '\w+' is already set\." + // $TEST$ no error r"The type parameter '\w+' is already set\." »Int«, - # $TEST$ error "The type parameter 'A' is already set." + // $TEST$ error "The type parameter 'A' is already set." »A = Int« >, g: MyClass< - # $TEST$ no error r"The type parameter '\w+' is already set\." + // $TEST$ no error r"The type parameter '\w+' is already set\." »B = Int«, - # $TEST$ error "The type parameter 'B' is already set." + // $TEST$ error "The type parameter 'B' is already set." »B = Int« >, h: MyClass< - # $TEST$ no error r"The type parameter '\w+' is already set\." + // $TEST$ no error r"The type parameter '\w+' is already set\." »A = Int«, - # $TEST$ no error r"The type parameter '\w+' is already set\." + // $TEST$ no error r"The type parameter '\w+' is already set\." »B = Int« >, i: MyClass< - # $TEST$ no error r"The type parameter '\w+' is already set\." + // $TEST$ no error r"The type parameter '\w+' is already set\." »Int«, - # $TEST$ no error r"The type parameter '\w+' is already set\." + // $TEST$ no error r"The type parameter '\w+' is already set\." »Int« >, j: MyClass< - # $TEST$ no error r"The type parameter '\w+' is already set\." + // $TEST$ no error r"The type parameter '\w+' is already set\." »Unresolved = Int«, - # $TEST$ no error r"The type parameter '\w+' is already set\." + // $TEST$ no error r"The type parameter '\w+' is already set\." »Unresolved = Int« > ) diff --git a/packages/ttsl-lang/tests/resources/validation/other/types/type argument lists/must not have positional type argument after named type argument/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/types/type argument lists/must not have positional type argument after named type argument/main.sdstest index eb18a08a..c6237952 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/types/type argument lists/must not have positional type argument after named type argument/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/types/type argument lists/must not have positional type argument after named type argument/main.sdstest @@ -1,19 +1,19 @@ package tests.validation.other.types.typeArgumentLists.mustNotHavePositionalTypeArgumentAfterNamedTypeArgument -# $TEST$ no error "After the first named type argument all type arguments must be named." -# $TEST$ no error "After the first named type argument all type arguments must be named." -# $TEST$ error "After the first named type argument all type arguments must be named." -# $TEST$ no error "After the first named type argument all type arguments must be named." +// $TEST$ no error "After the first named type argument all type arguments must be named." +// $TEST$ no error "After the first named type argument all type arguments must be named." +// $TEST$ error "After the first named type argument all type arguments must be named." +// $TEST$ no error "After the first named type argument all type arguments must be named." segment mySegment1( f: MyClass<»Int«, »A = Int«, »Int«, »B = Int«> ) {} -# $TEST$ no error "After the first named type argument all type arguments must be named." +// $TEST$ no error "After the first named type argument all type arguments must be named." segment mySegment2( f: MyClass<»Int«> ) {} -# $TEST$ no error "After the first named type argument all type arguments must be named." +// $TEST$ no error "After the first named type argument all type arguments must be named." segment mySegment2( f: MyClass<»A = Int«> ) {} diff --git a/packages/ttsl-lang/tests/resources/validation/other/types/type argument lists/too many type arguments/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/types/type argument lists/too many type arguments/main.sdstest index f7f7fc7b..564e9add 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/types/type argument lists/too many type arguments/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/types/type argument lists/too many type arguments/main.sdstest @@ -5,16 +5,16 @@ class MyClass2 class MyClass3 fun myFunction( - # $TEST$ no error r"Expected .* type arguments? but got \d*\." + // $TEST$ no error r"Expected .* type arguments? but got \d*\." a: MyClass1»<>«, - # $TEST$ no error r"Expected .* type arguments? but got \d*\." + // $TEST$ no error r"Expected .* type arguments? but got \d*\." b: MyClass1»«, - # $TEST$ error "Expected exactly 1 type argument but got 2." + // $TEST$ error "Expected exactly 1 type argument but got 2." c: MyClass1»«, - # $TEST$ error "Expected exactly 2 type arguments but got 3." + // $TEST$ error "Expected exactly 2 type arguments but got 3." d: MyClass2»«, - # $TEST$ error "Expected between 1 and 2 type arguments but got 3." + // $TEST$ error "Expected between 1 and 2 type arguments but got 3." f: MyClass3»«, - # $TEST$ no error r"Expected .* type arguments? but got \d*\." + // $TEST$ no error r"Expected .* type arguments? but got \d*\." g: Unresolved»« ) diff --git a/packages/ttsl-lang/tests/resources/validation/other/types/union types/context/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/types/union types/context/main.sdstest index a0585788..1060fd99 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/types/union types/context/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/types/union types/context/main.sdstest @@ -1,63 +1,63 @@ package tests.validation.other.types.unionTypes.context annotation MyAnnotation( - # $TEST$ no error "Union types must only be used for parameters of annotations, classes, and functions." + // $TEST$ no error "Union types must only be used for parameters of annotations, classes, and functions." p: »union«, ) class MyClass( - # $TEST$ no error "Union types must only be used for parameters of annotations, classes, and functions." + // $TEST$ no error "Union types must only be used for parameters of annotations, classes, and functions." p: »union«, ) { - # $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." + // $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." attr a: »union« } enum MyEnum { MyEnumVariant( - # $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." + // $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." p: »union«, ) } fun myFunction( - # $TEST$ no error "Union types must only be used for parameters of annotations, classes, and functions." + // $TEST$ no error "Union types must only be used for parameters of annotations, classes, and functions." p: »union«, ) -> ( - # $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." + // $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." r: »union«, ) segment mySegment1( - # $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." + // $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." p: »union«, ) -> ( - # $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." + // $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." r: »union«, ) {} segment mySegment2( - # $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." - # $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." + // $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." + // $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." c: (p: »union«) -> (r: »union«), ) { - # $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." + // $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." ( p: »union«, ) {}; - # $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." + // $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." ( p: »union«, ) -> 1; } segment mySegment3( - # $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." + // $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." p1: MyClass<»union«>, ) {} segment mySegment4( - # $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." + // $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." p1: »union«.MyClass ) {} diff --git a/packages/ttsl-lang/tests/resources/validation/other/types/union types/context/nested.sdstest b/packages/ttsl-lang/tests/resources/validation/other/types/union types/context/nested.sdstest index 5bc12c76..3c0707f3 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/types/union types/context/nested.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/types/union types/context/nested.sdstest @@ -5,12 +5,12 @@ package tests.validation.other.types.unionTypes.context */ class MyClass1 { - # $TEST$ no error "Union types must only be used for parameters of annotations, classes, and functions." + // $TEST$ no error "Union types must only be used for parameters of annotations, classes, and functions." attr a: union«> } class MyClass2 { - # $TEST$ no error "Union types must only be used for parameters of annotations, classes, and functions." - # $TEST$ no error "Union types must only be used for parameters of annotations, classes, and functions." + // $TEST$ no error "Union types must only be used for parameters of annotations, classes, and functions." + // $TEST$ no error "Union types must only be used for parameters of annotations, classes, and functions." attr a: union«) -> (r: »union«)> } diff --git a/packages/ttsl-lang/tests/resources/validation/other/types/union types/duplicate types/empty list.sdstest b/packages/ttsl-lang/tests/resources/validation/other/types/union types/duplicate types/empty list.sdstest index 26ee335b..cd81b4d1 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/types/union types/duplicate types/empty list.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/types/union types/duplicate types/empty list.sdstest @@ -1,6 +1,6 @@ package tests.validation.other.types.unionTypes.duplicateTypes -# $TEST$ no warning r"The type .* was already listed." +// $TEST$ no warning r"The type .* was already listed." fun myFunction1( p: union<> diff --git a/packages/ttsl-lang/tests/resources/validation/other/types/union types/duplicate types/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/types/union types/duplicate types/main.sdstest index 64dd8e67..bc3931b9 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/types/union types/duplicate types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/types/union types/duplicate types/main.sdstest @@ -1,14 +1,14 @@ package tests.validation.other.types.unionTypes.duplicateTypes fun myFunction2( - # $TEST$ no warning r"The type .* was already listed." + // $TEST$ no warning r"The type .* was already listed." p: union<»Int«>, q: union< - # $TEST$ no warning r"The type .* was already listed." + // $TEST$ no warning r"The type .* was already listed." »Int«, - # $TEST$ no warning r"The type .* was already listed." + // $TEST$ no warning r"The type .* was already listed." »String«, - # $TEST$ warning r"The type 'Int' was already listed." + // $TEST$ warning r"The type 'Int' was already listed." »Int«, >, ) diff --git a/packages/ttsl-lang/tests/resources/validation/other/types/union types/must have types/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/types/union types/must have types/main.sdstest index 3268a912..b4779c26 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/types/union types/must have types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/types/union types/must have types/main.sdstest @@ -1,16 +1,16 @@ package tests.validation.other.types.unionTypes.mustHaveTypes -# $TEST$ error "A union type must have at least one type." +// $TEST$ error "A union type must have at least one type." fun myFunction1( p: union»<>« ) -# $TEST$ no error "A union type must have at least one type." +// $TEST$ no error "A union type must have at least one type." fun myFunction2( p: union»« ) -# $TEST$ no error "A union type must have at least one type." +// $TEST$ no error "A union type must have at least one type." fun myFunction3( p: union»« ) diff --git a/packages/ttsl-lang/tests/resources/validation/purity/duplicate impurity reason/main.sdstest b/packages/ttsl-lang/tests/resources/validation/purity/duplicate impurity reason/main.sdstest index d7c09504..6a90b3b0 100644 --- a/packages/ttsl-lang/tests/resources/validation/purity/duplicate impurity reason/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/purity/duplicate impurity reason/main.sdstest @@ -1,7 +1,7 @@ package tests.validation.purity.duplicateImpurityReason @Impure([ - # $TEST$ no warning r"The impurity reason '.*' was set already\." + // $TEST$ no warning r"The impurity reason '.*' was set already\." »ImpurityReason.FileReadFromConstantPath("text.txt")« ]) @@ -10,33 +10,33 @@ package tests.validation.purity.duplicateImpurityReason */ @Impure([ - # $TEST$ no warning r"The impurity reason '.*' was set already\." + // $TEST$ no warning r"The impurity reason '.*' was set already\." »ImpurityReason.FileReadFromConstantPath("text.txt")«, - # $TEST$ no warning r"The impurity reason '.*' was set already\." + // $TEST$ no warning r"The impurity reason '.*' was set already\." »ImpurityReason.FileReadFromConstantPath("text.txt")«, ]) fun testFunction1() @Impure([ - # $TEST$ no warning r"The impurity reason '.*' was set already\." + // $TEST$ no warning r"The impurity reason '.*' was set already\." »ImpurityReason.FileReadFromConstantPath("text.txt")«, - # $TEST$ warning "The impurity reason 'FileReadFromConstantPath(path = "text.txt")' was set already." + // $TEST$ warning "The impurity reason 'FileReadFromConstantPath(path = "text.txt")' was set already." »ImpurityReason.FileReadFromConstantPath("text.txt")«, ]) fun testFunction2() @Impure([ - # $TEST$ no warning r"The impurity reason '.*' was set already\." + // $TEST$ no warning r"The impurity reason '.*' was set already\." »ImpurityReason.FileWriteToConstantPath("text.txt")«, - # $TEST$ warning "The impurity reason 'FileWriteToConstantPath(path = "text.txt")' was set already." + // $TEST$ warning "The impurity reason 'FileWriteToConstantPath(path = "text.txt")' was set already." »ImpurityReason.FileWriteToConstantPath("text.txt")«, - # $TEST$ warning "The impurity reason 'FileWriteToConstantPath(path = "text.txt")' was set already." + // $TEST$ warning "The impurity reason 'FileWriteToConstantPath(path = "text.txt")' was set already." »ImpurityReason.FileWriteToConstantPath("text.txt")«, - # $TEST$ no warning r"The impurity reason '.*' was set already\." + // $TEST$ no warning r"The impurity reason '.*' was set already\." »ImpurityReason.FileReadFromConstantPath("text.txt")«, - # $TEST$ warning "The impurity reason 'FileReadFromConstantPath(path = "text.txt")' was set already." + // $TEST$ warning "The impurity reason 'FileReadFromConstantPath(path = "text.txt")' was set already." »ImpurityReason.FileReadFromConstantPath("text.txt")«, - # $TEST$ warning "The impurity reason 'FileReadFromConstantPath(path = "text.txt")' was set already." + // $TEST$ warning "The impurity reason 'FileReadFromConstantPath(path = "text.txt")' was set already." »ImpurityReason.FileReadFromConstantPath("text.txt")«, ]) fun testFunction3() @@ -46,17 +46,17 @@ fun testFunction3() */ @Impure( - # $TEST$ no warning r"The impurity reason '.*' was set already\." + // $TEST$ no warning r"The impurity reason '.*' was set already\." »ImpurityReason.FileWriteToConstantPath("text.txt")«, - # $TEST$ no warning r"The impurity reason '.*' was set already\." + // $TEST$ no warning r"The impurity reason '.*' was set already\." »ImpurityReason.FileWriteToConstantPath("text.txt")« ) fun testFunction4() @Impure([ - # $TEST$ no warning r"The impurity reason '.*' was set already\." + // $TEST$ no warning r"The impurity reason '.*' was set already\." »1«, - # $TEST$ no warning r"The impurity reason '.*' was set already\." + // $TEST$ no warning r"The impurity reason '.*' was set already\." »1«, ]) fun testFunction5() diff --git a/packages/ttsl-lang/tests/resources/validation/purity/duplicate impurity reason/no impure annotation.sdstest b/packages/ttsl-lang/tests/resources/validation/purity/duplicate impurity reason/no impure annotation.sdstest index d48711b8..524b60ec 100644 --- a/packages/ttsl-lang/tests/resources/validation/purity/duplicate impurity reason/no impure annotation.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/purity/duplicate impurity reason/no impure annotation.sdstest @@ -1,5 +1,5 @@ package tests.validation.purity.duplicateImpurityReason -# $TEST$ no warning r"The impurity reason '.*' was set already\." +// $TEST$ no warning r"The impurity reason '.*' was set already\." fun testFunction6() diff --git a/packages/ttsl-lang/tests/resources/validation/purity/impure callable passed to pure parameter/arguments.sdstest b/packages/ttsl-lang/tests/resources/validation/purity/impure callable passed to pure parameter/arguments.sdstest index 3884c096..1be44b86 100644 --- a/packages/ttsl-lang/tests/resources/validation/purity/impure callable passed to pure parameter/arguments.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/purity/impure callable passed to pure parameter/arguments.sdstest @@ -53,68 +53,68 @@ segment mySegment2( other: Int = 1, ) -> 1; - # $TEST$ no error "Cannot pass an impure callable to a pure parameter." - # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + // $TEST$ no error "Cannot pass an impure callable to a pure parameter." MyAnnotation(»pureFunction«, »pureFunction«); - # $TEST$ error "Cannot pass an impure callable to a pure parameter." - # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + // $TEST$ error "Cannot pass an impure callable to a pure parameter." + // $TEST$ no error "Cannot pass an impure callable to a pure parameter." MyAnnotation(»impureFunction«, »impureFunction«); - # $TEST$ no error "Cannot pass an impure callable to a pure parameter." - # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + // $TEST$ no error "Cannot pass an impure callable to a pure parameter." MyClass(»pureFunction«, »pureFunction«); - # $TEST$ error "Cannot pass an impure callable to a pure parameter." - # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + // $TEST$ error "Cannot pass an impure callable to a pure parameter." + // $TEST$ no error "Cannot pass an impure callable to a pure parameter." MyClass(»impureFunction«, »impureFunction«); - # $TEST$ no error "Cannot pass an impure callable to a pure parameter." - # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + // $TEST$ no error "Cannot pass an impure callable to a pure parameter." MyEnum.MyEnumVariant(»pureFunction«, »pureFunction«); - # $TEST$ error "Cannot pass an impure callable to a pure parameter." - # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + // $TEST$ error "Cannot pass an impure callable to a pure parameter." + // $TEST$ no error "Cannot pass an impure callable to a pure parameter." MyEnum.MyEnumVariant(»impureFunction«, »impureFunction«); - # $TEST$ no error "Cannot pass an impure callable to a pure parameter." - # $TEST$ no error "Cannot pass an impure callable to a pure parameter." - # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + // $TEST$ no error "Cannot pass an impure callable to a pure parameter." myFunction(»pureFunction«, »pureFunction«, »pureFunction«); - # $TEST$ error "Cannot pass an impure callable to a pure parameter." - # $TEST$ no error "Cannot pass an impure callable to a pure parameter." - # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + // $TEST$ error "Cannot pass an impure callable to a pure parameter." + // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + // $TEST$ no error "Cannot pass an impure callable to a pure parameter." myFunction(»impureFunction«, »impureFunction«, »impureFunction«); - # $TEST$ no error "Cannot pass an impure callable to a pure parameter." - # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + // $TEST$ no error "Cannot pass an impure callable to a pure parameter." mySegment1(»pureFunction«, »pureFunction«); - # $TEST$ no error "Cannot pass an impure callable to a pure parameter." - # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + // $TEST$ no error "Cannot pass an impure callable to a pure parameter." mySegment1(»impureFunction«, »impureFunction«); - # $TEST$ no error "Cannot pass an impure callable to a pure parameter." - # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + // $TEST$ no error "Cannot pass an impure callable to a pure parameter." myCallableType(»pureFunction«, »pureFunction«); - # $TEST$ no error "Cannot pass an impure callable to a pure parameter." - # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + // $TEST$ no error "Cannot pass an impure callable to a pure parameter." myCallableType(»impureFunction«, »impureFunction«); - # $TEST$ no error "Cannot pass an impure callable to a pure parameter." - # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + // $TEST$ no error "Cannot pass an impure callable to a pure parameter." myBlockLambda(»pureFunction«, »pureFunction«); - # $TEST$ no error "Cannot pass an impure callable to a pure parameter." - # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + // $TEST$ no error "Cannot pass an impure callable to a pure parameter." myBlockLambda(»impureFunction«, »impureFunction«); - # $TEST$ no error "Cannot pass an impure callable to a pure parameter." - # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + // $TEST$ no error "Cannot pass an impure callable to a pure parameter." myExpressionLambda(»pureFunction«, »pureFunction«); - # $TEST$ no error "Cannot pass an impure callable to a pure parameter." - # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + // $TEST$ no error "Cannot pass an impure callable to a pure parameter." myExpressionLambda(»impureFunction«, »impureFunction«); } // Argument does not have callable type pipeline myPipeline { - # $TEST$ no error "Cannot pass an impure callable to a pure parameter." - # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + // $TEST$ no error "Cannot pass an impure callable to a pure parameter." MyClass(»1«, »1«); } diff --git a/packages/ttsl-lang/tests/resources/validation/purity/impure callable passed to pure parameter/default values.sdstest b/packages/ttsl-lang/tests/resources/validation/purity/impure callable passed to pure parameter/default values.sdstest index cbaa7af5..d6bfa9ac 100644 --- a/packages/ttsl-lang/tests/resources/validation/purity/impure callable passed to pure parameter/default values.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/purity/impure callable passed to pure parameter/default values.sdstest @@ -7,41 +7,41 @@ fun pureFunction() fun impureFunction() annotation MyAnnotation( - # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + // $TEST$ no error "Cannot pass an impure callable to a pure parameter." f: () -> () = »pureFunction«, - # $TEST$ error "Cannot pass an impure callable to a pure parameter." + // $TEST$ error "Cannot pass an impure callable to a pure parameter." g: () -> () = »impureFunction«, - # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + // $TEST$ no error "Cannot pass an impure callable to a pure parameter." other: Int = »impureFunction«, ) class MyClass1( - # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + // $TEST$ no error "Cannot pass an impure callable to a pure parameter." f: () -> () = »pureFunction«, - # $TEST$ error "Cannot pass an impure callable to a pure parameter." + // $TEST$ error "Cannot pass an impure callable to a pure parameter." g: () -> () = »impureFunction«, - # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + // $TEST$ no error "Cannot pass an impure callable to a pure parameter." other: Int = »impureFunction«, ) enum MyEnum { MyEnumVariant( - # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + // $TEST$ no error "Cannot pass an impure callable to a pure parameter." f: () -> () = »pureFunction«, - # $TEST$ error "Cannot pass an impure callable to a pure parameter." + // $TEST$ error "Cannot pass an impure callable to a pure parameter." g: () -> () = »impureFunction«, - # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + // $TEST$ no error "Cannot pass an impure callable to a pure parameter." other: Int = »impureFunction«, ) } @Pure fun myFunction1( - # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + // $TEST$ no error "Cannot pass an impure callable to a pure parameter." f: () -> () = »pureFunction«, - # $TEST$ error "Cannot pass an impure callable to a pure parameter." + // $TEST$ error "Cannot pass an impure callable to a pure parameter." g: () -> () = »impureFunction«, - # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + // $TEST$ no error "Cannot pass an impure callable to a pure parameter." other: Int = »impureFunction«, ) @@ -50,60 +50,60 @@ fun myFunction1( ImpurityReason.PotentiallyImpureParameterCall("g1"), ]) fun myFunction2( - # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + // $TEST$ no error "Cannot pass an impure callable to a pure parameter." f1: () -> () = »pureFunction«, - # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + // $TEST$ no error "Cannot pass an impure callable to a pure parameter." g1: () -> () = »impureFunction«, - # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + // $TEST$ no error "Cannot pass an impure callable to a pure parameter." f2: () -> () = »pureFunction«, - # $TEST$ error "Cannot pass an impure callable to a pure parameter." + // $TEST$ error "Cannot pass an impure callable to a pure parameter." g2: () -> () = »impureFunction«, - # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + // $TEST$ no error "Cannot pass an impure callable to a pure parameter." other: Int = »impureFunction«, ) segment mySegment1( myCallableType: ( - # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + // $TEST$ no error "Cannot pass an impure callable to a pure parameter." f: () -> () = »pureFunction«, - # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + // $TEST$ no error "Cannot pass an impure callable to a pure parameter." g: () -> () = »impureFunction«, - # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + // $TEST$ no error "Cannot pass an impure callable to a pure parameter." other: Int = »impureFunction«, ) -> () ) {} segment mySegment2( - # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + // $TEST$ no error "Cannot pass an impure callable to a pure parameter." f: () -> () = »pureFunction«, - # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + // $TEST$ no error "Cannot pass an impure callable to a pure parameter." g: () -> () = »impureFunction«, - # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + // $TEST$ no error "Cannot pass an impure callable to a pure parameter." other: Int = »impureFunction«, ) {} pipeline myPipeline { ( - # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + // $TEST$ no error "Cannot pass an impure callable to a pure parameter." f: () -> () = »pureFunction«, - # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + // $TEST$ no error "Cannot pass an impure callable to a pure parameter." g: () -> () = »impureFunction«, - # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + // $TEST$ no error "Cannot pass an impure callable to a pure parameter." other: Int = »impureFunction«, ) {}; ( - # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + // $TEST$ no error "Cannot pass an impure callable to a pure parameter." f: () -> () = »pureFunction«, - # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + // $TEST$ no error "Cannot pass an impure callable to a pure parameter." g: () -> () = »impureFunction«, - # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + // $TEST$ no error "Cannot pass an impure callable to a pure parameter." other: Int = »impureFunction«, ) -> 1; } // Default value does not have callable type class MyClass2( - # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + // $TEST$ no error "Cannot pass an impure callable to a pure parameter." f: () -> () = »1«, ) diff --git a/packages/ttsl-lang/tests/resources/validation/purity/invalid parameter name/main.sdstest b/packages/ttsl-lang/tests/resources/validation/purity/invalid parameter name/main.sdstest index b36d59b9..d7dc2b74 100644 --- a/packages/ttsl-lang/tests/resources/validation/purity/invalid parameter name/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/purity/invalid parameter name/main.sdstest @@ -1,26 +1,26 @@ package tests.validation.purity.parameterNamesMustBeValid @Impure([ - # $TEST$ no error r"The parameter '.*' does not exist\." + // $TEST$ no error r"The parameter '.*' does not exist\." ImpurityReason.FileReadFromConstantPath(»"text.txt"«), - # $TEST$ no error "The parameter 'p' does not exist." + // $TEST$ no error "The parameter 'p' does not exist." ImpurityReason.FileReadFromParameterizedPath(»"p"«), - # $TEST$ error "The parameter 'q' does not exist." + // $TEST$ error "The parameter 'q' does not exist." ImpurityReason.FileReadFromParameterizedPath(»"q"«), - # $TEST$ no error r"The parameter '.*' does not exist\." + // $TEST$ no error r"The parameter '.*' does not exist\." ImpurityReason.FileWriteToConstantPath(»"text.txt"«), - # $TEST$ no error "The parameter 'p' does not exist." + // $TEST$ no error "The parameter 'p' does not exist." ImpurityReason.FileWriteToParameterizedPath(»"p"«), - # $TEST$ error "The parameter 'q' does not exist." + // $TEST$ error "The parameter 'q' does not exist." ImpurityReason.FileWriteToParameterizedPath(»"q"«), - # $TEST$ no error "The parameter 'p' does not exist." + // $TEST$ no error "The parameter 'p' does not exist." ImpurityReason.PotentiallyImpureParameterCall(»"p"«), - # $TEST$ error "The parameter 'q' does not exist." + // $TEST$ error "The parameter 'q' does not exist." ImpurityReason.PotentiallyImpureParameterCall(»"q"«), - # $TEST$ no error r"The parameter '.*' does not exist\." + // $TEST$ no error r"The parameter '.*' does not exist\." ImpurityReason.PotentiallyImpureParameterCall(»1«), - # $TEST$ no error "The parameter 'q' does not exist." + // $TEST$ no error "The parameter 'q' does not exist." AnotherEnum.SomeVariant(»"q"«) ]) fun f(p: Int) diff --git a/packages/ttsl-lang/tests/resources/validation/purity/must be subset of impurity reasons of overridden method/main.sdstest b/packages/ttsl-lang/tests/resources/validation/purity/must be subset of impurity reasons of overridden method/main.sdstest index 3b4562a9..9267adaf 100644 --- a/packages/ttsl-lang/tests/resources/validation/purity/must be subset of impurity reasons of overridden method/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/purity/must be subset of impurity reasons of overridden method/main.sdstest @@ -1,15 +1,15 @@ package tests.validation.purity.mustBeSubsetOfImpurityReasonsOfOverriddenMethod class Superclass { - # $TEST$ no error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." + // $TEST$ no error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." @Pure fun »pureFunction«() - # $TEST$ no error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." + // $TEST$ no error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." @Impure([]) fun »impureFunctionWithoutReason«() - # $TEST$ no error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." + // $TEST$ no error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." @Impure([ImpurityReason.Other]) fun »impureFunctionWithReasons«() } @@ -19,40 +19,40 @@ class IdenticalSubclass sub Superclass { * We already show another error if the `@Impure` annotation is called multiple times. */ - # $TEST$ no error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." + // $TEST$ no error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." @Pure @Impure([ImpurityReason.Other]) fun »pureFunction«() - # $TEST$ no error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." + // $TEST$ no error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." @Impure([]) fun »impureFunctionWithoutReason«() - # $TEST$ no error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." + // $TEST$ no error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." @Impure([ImpurityReason.Other]) fun »impureFunctionWithReasons«() } class SubsetSubclass sub Superclass { - # $TEST$ no error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." + // $TEST$ no error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." @Pure fun »impureFunctionWithoutReason«() - # $TEST$ no error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." + // $TEST$ no error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." @Impure([]) fun »impureFunctionWithReasons«() } class IllegalSubclass sub Superclass { - # $TEST$ error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." + // $TEST$ error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." @Impure([ImpurityReason.Other]) fun »pureFunction«() - # $TEST$ error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." + // $TEST$ error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." @Impure([ImpurityReason.Other]) fun »impureFunctionWithoutReason«() - # $TEST$ error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." + // $TEST$ error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." @Impure([ImpurityReason.FileReadFromConstantPath("")]) fun impureFunctionWithReasons() } diff --git a/packages/ttsl-lang/tests/resources/validation/purity/must be subset of impurity reasons of overridden method/no purity annotation.sdstest b/packages/ttsl-lang/tests/resources/validation/purity/must be subset of impurity reasons of overridden method/no purity annotation.sdstest index a72973c7..8af99d5c 100644 --- a/packages/ttsl-lang/tests/resources/validation/purity/must be subset of impurity reasons of overridden method/no purity annotation.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/purity/must be subset of impurity reasons of overridden method/no purity annotation.sdstest @@ -1,6 +1,6 @@ package tests.validation.purity.mustBeSubsetOfImpurityReasonsOfOverriddenMethod -# $TEST$ no error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." +// $TEST$ no error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." class A { fun functionWithUnspecifiedPurity() diff --git a/packages/ttsl-lang/tests/resources/validation/purity/no impurity reasons/main.sdstest b/packages/ttsl-lang/tests/resources/validation/purity/no impurity reasons/main.sdstest index 0cc3820e..707de1cf 100644 --- a/packages/ttsl-lang/tests/resources/validation/purity/no impurity reasons/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/purity/no impurity reasons/main.sdstest @@ -1,21 +1,21 @@ package tests.validation.purity.noImpurityReasons -# $TEST$ error "At least one impurity reason must be specified." +// $TEST$ error "At least one impurity reason must be specified." @»Impure« fun f1() -# $TEST$ error "At least one impurity reason must be specified." +// $TEST$ error "At least one impurity reason must be specified." @»Impure«() fun f2() -# $TEST$ error "At least one impurity reason must be specified." +// $TEST$ error "At least one impurity reason must be specified." @»Impure«([]) -# $TEST$ no error "At least one impurity reason must be specified." +// $TEST$ no error "At least one impurity reason must be specified." @»Impure«([]) fun f3() -# $TEST$ no error "At least one impurity reason must be specified." +// $TEST$ no error "At least one impurity reason must be specified." @»Impure«([ImpurityReason.Other]) -# $TEST$ no error "At least one impurity reason must be specified." +// $TEST$ no error "At least one impurity reason must be specified." @»Impure«([ImpurityReason.Other]) fun f4() diff --git a/packages/ttsl-lang/tests/resources/validation/purity/not specified/main.sdstest b/packages/ttsl-lang/tests/resources/validation/purity/not specified/main.sdstest index ef447f26..5486cb11 100644 --- a/packages/ttsl-lang/tests/resources/validation/purity/not specified/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/purity/not specified/main.sdstest @@ -1,12 +1,12 @@ package tests.validation.purity.notSpecified -# $TEST$ error r"The purity of a function must be specified. Call the annotation '@Pure' or '@Impure'." +// $TEST$ error r"The purity of a function must be specified. Call the annotation '@Pure' or '@Impure'." fun »functionWithUnknownPurity«() -# $TEST$ no error r"The purity of a function must be specified. Call the annotation '@Pure' or '@Impure'." +// $TEST$ no error r"The purity of a function must be specified. Call the annotation '@Pure' or '@Impure'." @Impure([]) fun »impureFunction«() -# $TEST$ no error r"The purity of a function must be specified. Call the annotation '@Pure' or '@Impure'." +// $TEST$ no error r"The purity of a function must be specified. Call the annotation '@Pure' or '@Impure'." @Pure fun »pureFunction«() diff --git a/packages/ttsl-lang/tests/resources/validation/purity/potentially impure parameter must have callable type/main.sdstest b/packages/ttsl-lang/tests/resources/validation/purity/potentially impure parameter must have callable type/main.sdstest index 4044f91b..67f51a2b 100644 --- a/packages/ttsl-lang/tests/resources/validation/purity/potentially impure parameter must have callable type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/purity/potentially impure parameter must have callable type/main.sdstest @@ -1,15 +1,15 @@ package tests.validation.purity.potentiallyImpureParameterMustHaveCallableType @Impure([ - # $TEST$ error "The parameter 'a' must have a callable type." + // $TEST$ error "The parameter 'a' must have a callable type." ImpurityReason.PotentiallyImpureParameterCall(»"a"«), - # $TEST$ error "The parameter 'b' must have a callable type." + // $TEST$ error "The parameter 'b' must have a callable type." ImpurityReason.PotentiallyImpureParameterCall(»"b"«), - # $TEST$ no error r"The parameter '.*' must have a callable type\." + // $TEST$ no error r"The parameter '.*' must have a callable type\." ImpurityReason.PotentiallyImpureParameterCall(»"c"«), - # $TEST$ no error r"The parameter '.*' must have a callable type\." + // $TEST$ no error r"The parameter '.*' must have a callable type\." ImpurityReason.PotentiallyImpureParameterCall(»"d"«), - # $TEST$ no error r"The parameter '.*' must have a callable type\." + // $TEST$ no error r"The parameter '.*' must have a callable type\." ImpurityReason.PotentiallyImpureParameterCall(»"e"«), ]) fun myFunction( diff --git a/packages/ttsl-lang/tests/resources/validation/purity/pure and impure/main.sdstest b/packages/ttsl-lang/tests/resources/validation/purity/pure and impure/main.sdstest index fb3fd30b..308c281c 100644 --- a/packages/ttsl-lang/tests/resources/validation/purity/pure and impure/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/purity/pure and impure/main.sdstest @@ -1,17 +1,17 @@ package tests.validation.purity.pureAndImpure -# $TEST$ no error "'@Impure' and '@Pure' are mutually exclusive." +// $TEST$ no error "'@Impure' and '@Pure' are mutually exclusive." fun »neither«() -# $TEST$ no error "'@Impure' and '@Pure' are mutually exclusive." +// $TEST$ no error "'@Impure' and '@Pure' are mutually exclusive." @Impure fun »impure«() -# $TEST$ no error "'@Impure' and '@Pure' are mutually exclusive." +// $TEST$ no error "'@Impure' and '@Pure' are mutually exclusive." @Pure fun »pure«() -# $TEST$ error "'@Impure' and '@Pure' are mutually exclusive." +// $TEST$ error "'@Impure' and '@Pure' are mutually exclusive." @Impure @Pure fun »both«() diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary argument list in annotation call/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary argument list in annotation call/main.sdstest index 69696532..9889671f 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary argument list in annotation call/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary argument list in annotation call/main.sdstest @@ -12,24 +12,24 @@ annotation AnnotationWithoutRequiredParameters(a: Int = 0) @Repeatable annotation AnnotationWithRequiredParameters(a: Int) -# $TEST$ info "This argument list can be removed." +// $TEST$ info "This argument list can be removed." @AnnotationWithoutParameterList»()« -# $TEST$ no info "This argument list can be removed." +// $TEST$ no info "This argument list can be removed." @AnnotationWithoutParameterList»(1)« -# $TEST$ info "This argument list can be removed." +// $TEST$ info "This argument list can be removed." @AnnotationWithEmptyParameterList»()« -# $TEST$ no info "This argument list can be removed." +// $TEST$ no info "This argument list can be removed." @AnnotationWithEmptyParameterList»(1)« -# $TEST$ info "This argument list can be removed." +// $TEST$ info "This argument list can be removed." @AnnotationWithoutRequiredParameters»()« -# $TEST$ no info "This argument list can be removed." +// $TEST$ no info "This argument list can be removed." @AnnotationWithoutRequiredParameters»(1)« -# $TEST$ no info "This argument list can be removed." +// $TEST$ no info "This argument list can be removed." @AnnotationWithRequiredParameters»()« -# $TEST$ no info "This argument list can be removed." +// $TEST$ no info "This argument list can be removed." @AnnotationWithRequiredParameters»(1)« -# $TEST$ no info "This argument list can be removed." +// $TEST$ no info "This argument list can be removed." @Unresolved»()« -# $TEST$ no info "This argument list can be removed." +// $TEST$ no info "This argument list can be removed." @Unresolved»(1)« class MyClass diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary argument list in call/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary argument list in call/main.sdstest index 193f4ca2..c4abf085 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary argument list in call/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary argument list in call/main.sdstest @@ -21,45 +21,45 @@ segment mySegment2( val blockLambda = () {}; val expressionLambda = () -> 0; - # $TEST$ no info "This argument list can be removed." + // $TEST$ no info "This argument list can be removed." MyAnnotation»()«; - # $TEST$ no info "This argument list can be removed." + // $TEST$ no info "This argument list can be removed." MyClass»()«; - # $TEST$ info "This argument list can be removed." + // $TEST$ info "This argument list can be removed." MyEnum.EnumVariantWithoutParameterList»()«; - # $TEST$ no info "This argument list can be removed." + // $TEST$ no info "This argument list can be removed." MyEnum.EnumVariantWithoutParameterList»(1)«; - # $TEST$ info "This argument list can be removed." + // $TEST$ info "This argument list can be removed." MyEnum.EnumVariantWithEmptyParameterList»()«; - # $TEST$ no info "This argument list can be removed." + // $TEST$ no info "This argument list can be removed." MyEnum.EnumVariantWithEmptyParameterList»(1)«; - # $TEST$ no info "This argument list can be removed." + // $TEST$ no info "This argument list can be removed." MyEnum.EnumVariantWithoutRequiredParameters»()«; - # $TEST$ no info "This argument list can be removed." + // $TEST$ no info "This argument list can be removed." MyEnum.EnumVariantWithoutRequiredParameters»(1)«; - # $TEST$ no info "This argument list can be removed." + // $TEST$ no info "This argument list can be removed." MyEnum.EnumVariantWithRequiredParameters»()«; - # $TEST$ no info "This argument list can be removed." + // $TEST$ no info "This argument list can be removed." MyEnum.EnumVariantWithRequiredParameters»(1)«; - # $TEST$ no info "This argument list can be removed." + // $TEST$ no info "This argument list can be removed." MyEnum.Unresolved»()«; - # $TEST$ no info "This argument list can be removed." + // $TEST$ no info "This argument list can be removed." MyEnum.Unresolved»(1)«; - # $TEST$ no info "This argument list can be removed." + // $TEST$ no info "This argument list can be removed." myFunction»()«; - # $TEST$ no info "This argument list can be removed." + // $TEST$ no info "This argument list can be removed." mySegment1»()«; - # $TEST$ no info "This argument list can be removed." + // $TEST$ no info "This argument list can be removed." callableType»()«; - # $TEST$ no info "This argument list can be removed." + // $TEST$ no info "This argument list can be removed." blockLambda»()«; - # $TEST$ no info "This argument list can be removed." + // $TEST$ no info "This argument list can be removed." expressionLambda»()«; } diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary assignment/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary assignment/main.sdstest index eed80fa7..59097760 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary assignment/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary assignment/main.sdstest @@ -7,25 +7,25 @@ class MyClass { } segment mySegment() -> a: Int { - # $TEST$ info "This assignment can be replaced by an expression statement." + // $TEST$ info "This assignment can be replaced by an expression statement." »_, _ = f();« - # $TEST$ info "This assignment can be replaced by an expression statement." + // $TEST$ info "This assignment can be replaced by an expression statement." »_, _ = MyClass().f();« - # $TEST$ no info "This assignment can be replaced by an expression statement." + // $TEST$ no info "This assignment can be replaced by an expression statement." »val a = 1;« - # $TEST$ no info "This assignment can be replaced by an expression statement." + // $TEST$ no info "This assignment can be replaced by an expression statement." »yield a = 1;« () { - # $TEST$ info "This assignment can be replaced by an expression statement." + // $TEST$ info "This assignment can be replaced by an expression statement." »_, _ = f();« - # $TEST$ info "This assignment can be replaced by an expression statement." + // $TEST$ info "This assignment can be replaced by an expression statement." »_, _ = MyClass().f();« - # $TEST$ no info "This assignment can be replaced by an expression statement." + // $TEST$ no info "This assignment can be replaced by an expression statement." »val a = 1;« - # $TEST$ no info "This assignment can be replaced by an expression statement." + // $TEST$ no info "This assignment can be replaced by an expression statement." »yield a = 1;« }; } diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary body in class/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary body in class/main.sdstest index 16a3aefe..24001d56 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary body in class/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary body in class/main.sdstest @@ -1,14 +1,14 @@ package tests.validation.style.unnecessaryBodyInClass -# $TEST$ info "This body can be removed." +// $TEST$ info "This body can be removed." class MyClass1 »{}« -# $TEST$ no info "This body can be removed." +// $TEST$ no info "This body can be removed." class MyClass2 »{ fun f() }« -# $TEST$ no info "This body can be removed." +// $TEST$ no info "This body can be removed." class MyClass3 »{ attr a: Int }« diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary body in enum/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary body in enum/main.sdstest index 6bae5c77..91b9bf82 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary body in enum/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary body in enum/main.sdstest @@ -1,9 +1,9 @@ package tests.validation.style.unnecessaryBodyInEnum -# $TEST$ info "This body can be removed." +// $TEST$ info "This body can be removed." enum MyEnum1 »{}« -# $TEST$ no info "This body can be removed." +// $TEST$ no info "This body can be removed." enum MyEnum2 »{ Instance }« diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary const modifier on annotation parameter/info.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary const modifier on annotation parameter/info.sdstest index 89a5c24c..c23d3171 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary const modifier on annotation parameter/info.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary const modifier on annotation parameter/info.sdstest @@ -1,6 +1,6 @@ package tests.validation.style.unnecessaryConstModifierOnAnnotationParameters annotation MyAnnotation( - # $TEST$ info "Annotation parameters are always const, so this modifier can be removed." + // $TEST$ info "Annotation parameters are always const, so this modifier can be removed." »const« p1: Int ) diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary const modifier on annotation parameter/no info.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary const modifier on annotation parameter/no info.sdstest index 68c01ed3..d9d5f58f 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary const modifier on annotation parameter/no info.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary const modifier on annotation parameter/no info.sdstest @@ -1,6 +1,6 @@ package tests.validation.style.unnecessaryConstModifierOnAnnotationParameters annotation MyAnnotation( - # $TEST$ no info "Annotation parameters are always const, so this modifier can be removed." + // $TEST$ no info "Annotation parameters are always const, so this modifier can be removed." p2: Int, ) diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in annotation/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in annotation/main.sdstest index b8f39688..18384871 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in annotation/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in annotation/main.sdstest @@ -1,9 +1,9 @@ package tests.validation.style.unnecessaryConstraintListInAnnotation -# $TEST$ info "This constraint list can be removed." +// $TEST$ info "This constraint list can be removed." annotation MyAnnotation1 »where {}« -# $TEST$ no info "This constraint list can be removed." +// $TEST$ no info "This constraint list can be removed." annotation MyAnnotation2(p: Int) »where { p < 0 }« diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in class/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in class/main.sdstest index 5ab9591e..1819c189 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in class/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in class/main.sdstest @@ -1,9 +1,9 @@ package tests.validation.style.unnecessaryConstraintListInClass -# $TEST$ info "This constraint list can be removed." +// $TEST$ info "This constraint list can be removed." class MyClass1 »where {}« -# $TEST$ no info "This constraint list can be removed." +// $TEST$ no info "This constraint list can be removed." class MyClass2(p: Int) »where { p < 0 }« diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in enum variant/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in enum variant/main.sdstest index 1bc212ef..e2e51aea 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in enum variant/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in enum variant/main.sdstest @@ -1,10 +1,10 @@ package tests.validation.style.unnecessaryConstraintInEnumVariant enum MyEnum { - # $TEST$ info "This constraint list can be removed." + // $TEST$ info "This constraint list can be removed." MyVariant1 »where {}« - # $TEST$ no info "This constraint list can be removed." + // $TEST$ no info "This constraint list can be removed." MyVariant2(p: Int) »where { p < 0 }« diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in function/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in function/main.sdstest index eeadb021..e104e176 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in function/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in function/main.sdstest @@ -1,9 +1,9 @@ package tests.validation.style.unnecessaryConstraintListInFunction -# $TEST$ info "This constraint list can be removed." +// $TEST$ info "This constraint list can be removed." fun myFunction1() »where {}« -# $TEST$ no info "This constraint list can be removed." +// $TEST$ no info "This constraint list can be removed." fun myFunction2(p: Int) »where { p < 0 }« diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in segment/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in segment/main.sdstest index 893e2c85..45e9ca48 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in segment/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in segment/main.sdstest @@ -1,9 +1,9 @@ package tests.validation.style.unnecessaryConstraintListInSegment -# $TEST$ info "This constraint list can be removed." +// $TEST$ info "This constraint list can be removed." segment mySegment1() »where {}« {} -# $TEST$ no info "This constraint list can be removed." +// $TEST$ no info "This constraint list can be removed." segment mySegment2(p: Int) »where { p < 0 }« {} diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary elvis operator/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary elvis operator/main.sdstest index cffd46a5..3ba83ddc 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary elvis operator/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary elvis operator/main.sdstest @@ -4,40 +4,40 @@ package validation.style.unnecessaryElvisOperator pipeline test { - # $TEST$ info "The left operand is never null, so the elvis operator is unnecessary (keep the left operand)." + // $TEST$ info "The left operand is never null, so the elvis operator is unnecessary (keep the left operand)." »1 ?: 2«; - # $TEST$ info "The left operand is never null, so the elvis operator is unnecessary (keep the left operand)." + // $TEST$ info "The left operand is never null, so the elvis operator is unnecessary (keep the left operand)." »1 ?: null«; - # $TEST$ no info "The left operand is never null, so the elvis operator is unnecessary (keep the left operand)." + // $TEST$ no info "The left operand is never null, so the elvis operator is unnecessary (keep the left operand)." »null ?: 2«; - # $TEST$ no info "The left operand is never null, so the elvis operator is unnecessary (keep the left operand)." + // $TEST$ no info "The left operand is never null, so the elvis operator is unnecessary (keep the left operand)." »null ?: null«; - # $TEST$ no info "The right operand is always null, so the elvis operator is unnecessary (keep the left operand)." + // $TEST$ no info "The right operand is always null, so the elvis operator is unnecessary (keep the left operand)." »1 ?: 2«; - # $TEST$ info "The right operand is always null, so the elvis operator is unnecessary (keep the left operand)." + // $TEST$ info "The right operand is always null, so the elvis operator is unnecessary (keep the left operand)." »f() ?: null«; - # $TEST$ no info "The right operand is always null, so the elvis operator is unnecessary (keep the left operand)." + // $TEST$ no info "The right operand is always null, so the elvis operator is unnecessary (keep the left operand)." »null ?: 2«; - # $TEST$ no info "The right operand is always null, so the elvis operator is unnecessary (keep the left operand)." + // $TEST$ no info "The right operand is always null, so the elvis operator is unnecessary (keep the left operand)." »null ?: null«; - # $TEST$ no info "The left operand is always null, so the elvis operator is unnecessary (keep the right operand)." + // $TEST$ no info "The left operand is always null, so the elvis operator is unnecessary (keep the right operand)." »1 ?: 2«; - # $TEST$ no info "The left operand is always null, so the elvis operator is unnecessary (keep the right operand)." + // $TEST$ no info "The left operand is always null, so the elvis operator is unnecessary (keep the right operand)." »1 ?: null«; - # $TEST$ info "The left operand is always null, so the elvis operator is unnecessary (keep the right operand)." + // $TEST$ info "The left operand is always null, so the elvis operator is unnecessary (keep the right operand)." »null ?: 2«; - # $TEST$ no info "The left operand is always null, so the elvis operator is unnecessary (keep the right operand)." + // $TEST$ no info "The left operand is always null, so the elvis operator is unnecessary (keep the right operand)." »null ?: null«; - # $TEST$ no info "Both operands are always null, so the elvis operator is unnecessary (replace it with null)." + // $TEST$ no info "Both operands are always null, so the elvis operator is unnecessary (replace it with null)." »1 ?: 2«; - # $TEST$ no info "Both operands are always null, so the elvis operator is unnecessary (replace it with null)." + // $TEST$ no info "Both operands are always null, so the elvis operator is unnecessary (replace it with null)." »1 ?: null«; - # $TEST$ no info "Both operands are always null, so the elvis operator is unnecessary (replace it with null)." + // $TEST$ no info "Both operands are always null, so the elvis operator is unnecessary (replace it with null)." »null ?: 2«; - # $TEST$ info "Both operands are always null, so the elvis operator is unnecessary (replace it with null)." + // $TEST$ info "Both operands are always null, so the elvis operator is unnecessary (replace it with null)." »null ?: null«; } @@ -45,12 +45,12 @@ class TestsForTypeParameters( nullable: Nullable, nonNullable: NonNullable, - # $TEST$ no info "The left operand is never null, so the elvis operator is unnecessary (keep the left operand)." + // $TEST$ no info "The left operand is never null, so the elvis operator is unnecessary (keep the left operand)." p1: Any? = »nullable ?: 2«, - # $TEST$ no info "The left operand is never null, so the elvis operator is unnecessary (keep the left operand)." + // $TEST$ no info "The left operand is never null, so the elvis operator is unnecessary (keep the left operand)." p2: Any? = »nullable ?: null«, - # $TEST$ info "The left operand is never null, so the elvis operator is unnecessary (keep the left operand)." + // $TEST$ info "The left operand is never null, so the elvis operator is unnecessary (keep the left operand)." p3: Any? = »nonNullable ?: 2«, - # $TEST$ info "The left operand is never null, so the elvis operator is unnecessary (keep the left operand)." + // $TEST$ info "The left operand is never null, so the elvis operator is unnecessary (keep the left operand)." p4: Any? = »nonNullable ?: null«, ) diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary import alias/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary import alias/main.sdstest index 34d52b89..4e8c2468 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary import alias/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary import alias/main.sdstest @@ -1,7 +1,7 @@ package tests.validation.style.unnecessaryImportAlias -# $TEST$ no info "This alias can be removed." +// $TEST$ no info "This alias can be removed." from tests.validation.style.unnecessaryImportAlias.other import C »as D« -# $TEST$ info "This alias can be removed." -# $TEST$ info "This alias can be removed." +// $TEST$ info "This alias can be removed." +// $TEST$ info "This alias can be removed." from tests.validation.style.unnecessaryImportAlias.other import C »as C«, C »as C« diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary null safety/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary null safety/main.sdstest index 273bced1..a2bf48ff 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary null safety/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary null safety/main.sdstest @@ -13,41 +13,41 @@ segment call( val myFunction = myClass.f; val myFunctionOrNull = myClassOrNull?.f; - # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »(() {})()«; - # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »1()«; - # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »null()«; - # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »myFunction()«; - # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »myFunctionOrNull()«; - # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »unresolved()«; - # $TEST$ info "The receiver is never null, so null-safety is unnecessary." + // $TEST$ info "The receiver is never null, so null-safety is unnecessary." »(() {})?()«; - # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »1?()«; - # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »null?()«; - # $TEST$ info "The receiver is never null, so null-safety is unnecessary." + // $TEST$ info "The receiver is never null, so null-safety is unnecessary." »myFunction?()«; - # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »myFunctionOrNull?()«; - # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »unresolved?()«; } @@ -58,38 +58,38 @@ segment indexedAccess( val myList = myClass.l; val myListOrNull = myClassOrNull?.l; - # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »[1][0]«; - # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »1[0]«; - # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »null[0]«; - # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »myList[0]«; - # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »myListOrNull[0]«; - # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »unresolved[0]«; - # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »1?[0]«; - # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »null?[0]«; - # $TEST$ info "The receiver is never null, so null-safety is unnecessary." + // $TEST$ info "The receiver is never null, so null-safety is unnecessary." »myList?[0]«; - # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »myListOrNull?[0]«; - # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »unresolved?[0]«; } @@ -97,14 +97,14 @@ class IndexedAccess?, NonNullable sub List>( nullable: Nullable, nonNullable: NonNullable, - # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." p1: Any? = »nullable[0]«, - # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." p2: Any? = »nonNullable[0]«, - # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." p3: Any? = »nullable?[0]«, - # $TEST$ info "The receiver is never null, so null-safety is unnecessary." + // $TEST$ info "The receiver is never null, so null-safety is unnecessary." p4: Any? = »nonNullable?[0]«, ) @@ -112,35 +112,35 @@ segment memberAccess( myClass: MyClass, myClassOrNull: MyClass?, ) { - # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »1.a«; - # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »null.a«; - # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »myClass.a«; - # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »myClassOrNull.a«; - # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »unresolved.a«; - # $TEST$ info "The receiver is never null, so null-safety is unnecessary." + // $TEST$ info "The receiver is never null, so null-safety is unnecessary." »1?.a«; - # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »null?.a«; - # $TEST$ info "The receiver is never null, so null-safety is unnecessary." + // $TEST$ info "The receiver is never null, so null-safety is unnecessary." »myClass?.a«; - # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »myClassOrNull?.a«; - # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »unresolved?.a«; } @@ -148,13 +148,13 @@ class MemberAccess( nullable: Nullable, nonNullable: NonNullable, - # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." p1: Any? = »nullable.a«, - # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." p2: Any? = »nonNullable.a«, - # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." p3: Any? = »nullable?.a«, - # $TEST$ info "The receiver is never null, so null-safety is unnecessary." + // $TEST$ info "The receiver is never null, so null-safety is unnecessary." p4: Any? = »nonNullable?.a«, ) diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary parameter list in annotation/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary parameter list in annotation/main.sdstest index 85e0854d..9cdeefb3 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary parameter list in annotation/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary parameter list in annotation/main.sdstest @@ -1,7 +1,7 @@ package tests.validation.style.unnecessaryParameterListInAnnotation -# $TEST$ info "This parameter list can be removed." +// $TEST$ info "This parameter list can be removed." annotation MyAnnotation1»()« -# $TEST$ no info "This parameter list can be removed." +// $TEST$ no info "This parameter list can be removed." annotation MyAnnotation2»(a: Int)« diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary parameter list in enum variant/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary parameter list in enum variant/main.sdstest index 2caf017f..90c689b0 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary parameter list in enum variant/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary parameter list in enum variant/main.sdstest @@ -1,7 +1,7 @@ package tests.validation.style.unnecessaryParameterListInEnumVariant -# $TEST$ info "This parameter list can be removed." +// $TEST$ info "This parameter list can be removed." annotation MyAnnotation1»()« -# $TEST$ no info "This parameter list can be removed." +// $TEST$ no info "This parameter list can be removed." annotation MyAnnotation2»(a: Int)« diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary result list in function/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary result list in function/main.sdstest index 6e116a0c..edb55960 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary result list in function/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary result list in function/main.sdstest @@ -1,7 +1,7 @@ package tests.validation.style.unnecessaryResultListInFunction -# $TEST$ info "This result list can be removed." +// $TEST$ info "This result list can be removed." fun myFun1() »-> ()« -# $TEST$ no info "This result list can be removed." +// $TEST$ no info "This result list can be removed." fun myFun2() »-> (r: Int)« diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary result list in segment/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary result list in segment/main.sdstest index ec71f7e6..baea207e 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary result list in segment/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary result list in segment/main.sdstest @@ -1,7 +1,7 @@ package tests.validation.style.unnecessaryResultListInSegment -# $TEST$ info "This result list can be removed." +// $TEST$ info "This result list can be removed." segment mySegment1() »-> ()« {} -# $TEST$ no info "This result list can be removed." +// $TEST$ no info "This result list can be removed." segment mySegment2() »-> (r: Int)« {} diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary type argument list/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary type argument list/main.sdstest index 0105e424..ecc14ba0 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary type argument list/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary type argument list/main.sdstest @@ -5,21 +5,21 @@ class ClassWithEmptyTypeParameterList<> class ClassWithTypeParameters fun myFunction( - # $TEST$ info "This type argument list can be removed." + // $TEST$ info "This type argument list can be removed." a1: ClassWithoutTypeParameterList»<>«, - # $TEST$ no info "This type argument list can be removed." + // $TEST$ no info "This type argument list can be removed." a2: ClassWithoutTypeParameterList»«, - # $TEST$ info "This type argument list can be removed." + // $TEST$ info "This type argument list can be removed." a3: ClassWithEmptyTypeParameterList»<>«, - # $TEST$ no info "This type argument list can be removed." + // $TEST$ no info "This type argument list can be removed." a4: ClassWithEmptyTypeParameterList»«, - # $TEST$ no info "This type argument list can be removed." + // $TEST$ no info "This type argument list can be removed." a5: ClassWithTypeParameters»<>«, - # $TEST$ no info "This type argument list can be removed." + // $TEST$ no info "This type argument list can be removed." a6: ClassWithTypeParameters»«, - # $TEST$ no info "This type argument list can be removed." + // $TEST$ no info "This type argument list can be removed." d1: Unresolved»<>«, - # $TEST$ no info "This type argument list can be removed." + // $TEST$ no info "This type argument list can be removed." d2: Unresolved»«, ) diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary type parameter list in class/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary type parameter list in class/main.sdstest index ebe8411f..8d3f68db 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary type parameter list in class/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary type parameter list in class/main.sdstest @@ -1,7 +1,7 @@ package tests.validation.style.unnecessaryTypeParameterListInClass -# $TEST$ info "This type parameter list can be removed." +// $TEST$ info "This type parameter list can be removed." class MyClass1»<>« -# $TEST$ no info "This type parameter list can be removed." +// $TEST$ no info "This type parameter list can be removed." class MyClass2»« diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary type parameter list in function/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary type parameter list in function/main.sdstest index eeed1e9f..8c67cca9 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary type parameter list in function/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary type parameter list in function/main.sdstest @@ -1,7 +1,7 @@ package tests.validation.style.unnecessaryTypeParameterListInFunction -# $TEST$ info "This type parameter list can be removed." +// $TEST$ info "This type parameter list can be removed." fun myFunction1»<>«() -# $TEST$ no info "This type parameter list can be removed." +// $TEST$ no info "This type parameter list can be removed." fun myFunction2»«() diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary union type/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary union type/main.sdstest index f078b0ed..451142b8 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary union type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary union type/main.sdstest @@ -1,16 +1,16 @@ package tests.validation.style.unnecessaryUnionType -# $TEST$ no info "This can be replaced by the singular type argument of the union type." +// $TEST$ no info "This can be replaced by the singular type argument of the union type." segment mySegment1( p: »union<>« ) {} -# $TEST$ info "This can be replaced by the singular type argument of the union type." +// $TEST$ info "This can be replaced by the singular type argument of the union type." segment mySegment2( p: »union« ) {} -# $TEST$ no info "This can be replaced by the singular type argument of the union type." +// $TEST$ no info "This can be replaced by the singular type argument of the union type." segment mySegment3( p: »union« ) {} diff --git a/packages/ttsl-lang/tests/resources/validation/types/checking/arguments/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/checking/arguments/main.sdstest index 9e86a4a4..95aa5c2f 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/checking/arguments/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/checking/arguments/main.sdstest @@ -3,18 +3,18 @@ package tests.validation.types.checking.arguments fun f(p: Int) segment mySegment() { - # $TEST$ no error r"Expected type .* but got .*\." + // $TEST$ no error r"Expected type .* but got .*\." f(»1«); - # $TEST$ no error r"Expected type .* but got .*\." + // $TEST$ no error r"Expected type .* but got .*\." f(p = »1«); - # $TEST$ error "Expected type 'Int' but got 'literal<"">'." + // $TEST$ error "Expected type 'Int' but got 'literal<"">'." f(»""«); - # $TEST$ error "Expected type 'Int' but got 'literal<"">'." + // $TEST$ error "Expected type 'Int' but got 'literal<"">'." f(p = »""«); - # $TEST$ no error r"Expected type .* but got .*\." + // $TEST$ no error r"Expected type .* but got .*\." f(unresolved = »1«); } diff --git a/packages/ttsl-lang/tests/resources/validation/types/checking/arguments/with type parameters.sdstest b/packages/ttsl-lang/tests/resources/validation/types/checking/arguments/with type parameters.sdstest index 379f84fa..c1bb33da 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/checking/arguments/with type parameters.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/checking/arguments/with type parameters.sdstest @@ -26,50 +26,50 @@ segment mySegment( number: Number, contravariantInt: Contravariant, ) { - # $TEST$ no error r"Expected type .* but got .*\." - # $TEST$ no error r"Expected type .* but got .*\." + // $TEST$ no error r"Expected type .* but got .*\." + // $TEST$ no error r"Expected type .* but got .*\." C1(»1«, »2«); - # $TEST$ no error r"Expected type .* but got .*\." - # $TEST$ no error r"Expected type .* but got .*\." + // $TEST$ no error r"Expected type .* but got .*\." + // $TEST$ no error r"Expected type .* but got .*\." C1(»1«, »int«); - # $TEST$ no error r"Expected type .* but got .*\." - # $TEST$ no error r"Expected type .* but got .*\." + // $TEST$ no error r"Expected type .* but got .*\." + // $TEST$ no error r"Expected type .* but got .*\." C2(»1«, »2«); - # $TEST$ no error r"Expected type .* but got .*\." - # $TEST$ error "Expected type 'Number' but got 'literal<"">'." + // $TEST$ no error r"Expected type .* but got .*\." + // $TEST$ error "Expected type 'Number' but got 'literal<"">'." C2(»1«, »""«); - # $TEST$ no error r"Expected type .* but got .*\." - # $TEST$ no error r"Expected type .* but got .*\." + // $TEST$ no error r"Expected type .* but got .*\." + // $TEST$ no error r"Expected type .* but got .*\." C3(»1«, »contravariantInt«); - # $TEST$ no error r"Expected type .* but got .*\." - # $TEST$ no error r"Expected type .* but got .*\." + // $TEST$ no error r"Expected type .* but got .*\." + // $TEST$ no error r"Expected type .* but got .*\." C3(»int«, »contravariantInt«); - # $TEST$ no error r"Expected type .* but got .*\." - # $TEST$ error "Expected type 'Contravariant' but got 'Contravariant'." + // $TEST$ no error r"Expected type .* but got .*\." + // $TEST$ error "Expected type 'Contravariant' but got 'Contravariant'." C3(»number«, »contravariantInt«); - # $TEST$ no error r"Expected type .* but got .*\." - # $TEST$ error "Expected type 'Contravariant>' but got 'Contravariant'." + // $TEST$ no error r"Expected type .* but got .*\." + // $TEST$ error "Expected type 'Contravariant>' but got 'Contravariant'." C3(»""«, »contravariantInt«); - # $TEST$ no error r"Expected type .* but got .*\." + // $TEST$ no error r"Expected type .* but got .*\." f(»(p) -> p«); - # $TEST$ no error r"Expected type .* but got .*\." + // $TEST$ no error r"Expected type .* but got .*\." f(»(p) -> 1«); - # $TEST$ no error r"Expected type .* but got .*\." + // $TEST$ no error r"Expected type .* but got .*\." f(»(p: Int) -> p«); - # $TEST$ error "Expected type '(p: Int) -> (r: Int)' but got '(p: Int) -> (result: literal<"">)'." + // $TEST$ error "Expected type '(p: Int) -> (r: Int)' but got '(p: Int) -> (result: literal<"">)'." f(»(p: Int) -> ""«); } diff --git a/packages/ttsl-lang/tests/resources/validation/types/checking/call receiver/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/checking/call receiver/main.sdstest index aad2ea50..979cf38d 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/checking/call receiver/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/checking/call receiver/main.sdstest @@ -32,66 +32,66 @@ segment mySegment2( val blockLambda = () {}; val expressionLambda = () -> 1; - # $TEST$ no error "This expression is not callable." + // $TEST$ no error "This expression is not callable." »MyAnnotation«(); - # $TEST$ error "This expression is not callable." + // $TEST$ error "This expression is not callable." val myAnnotationAlias = MyAnnotation; »myAnnotationAlias«(); - # $TEST$ no error "This expression is not callable." + // $TEST$ no error "This expression is not callable." »MyClass«(); - # $TEST$ error "This expression is not callable." + // $TEST$ error "This expression is not callable." »MyClass.myAttribute«(); - # $TEST$ no error "This expression is not callable." + // $TEST$ no error "This expression is not callable." »MyClass.MyClass«(); - # $TEST$ error "This expression is not callable." + // $TEST$ error "This expression is not callable." »MyClass.MyEnum«(); - # $TEST$ no error "This expression is not callable." + // $TEST$ no error "This expression is not callable." »MyClass.myFunction«(); - # $TEST$ error "This expression is not callable." + // $TEST$ error "This expression is not callable." »MyEnum«(); - # $TEST$ no error "This expression is not callable." + // $TEST$ no error "This expression is not callable." »MyEnum.MySimpleEnumVariant«(); - # $TEST$ no error "This expression is not callable." + // $TEST$ no error "This expression is not callable." »MyEnum.MyComplexEnumVariant«(); - # $TEST$ no error "This expression is not callable." + // $TEST$ no error "This expression is not callable." »myFunction«(); - # $TEST$ no error "This expression is not callable." + // $TEST$ no error "This expression is not callable." »myPipeline«(); - # $TEST$ error "This expression is not callable." + // $TEST$ error "This expression is not callable." val myPipelineAlias = MyPipeline; »myPipelineAlias«(); - # $TEST$ no error "This expression is not callable." + // $TEST$ no error "This expression is not callable." »MySchema«(); - # $TEST$ error "This expression is not callable." + // $TEST$ error "This expression is not callable." val mySchemaAlias = MySchema; »mySchemaAlias«(); - # $TEST$ no error "This expression is not callable." + // $TEST$ no error "This expression is not callable." »mySegment1«(); - # $TEST$ error "This expression is not callable." + // $TEST$ error "This expression is not callable." »int«(); - # $TEST$ no error "This expression is not callable." + // $TEST$ no error "This expression is not callable." »callable«(); - # $TEST$ error "This expression is not callable." + // $TEST$ error "This expression is not callable." »intLiteral«(); - # $TEST$ no error "This expression is not callable." + // $TEST$ no error "This expression is not callable." »blockLambda«(); - # $TEST$ no error "This expression is not callable." + // $TEST$ no error "This expression is not callable." »expressionLambda«(); - # $TEST$ no error "This expression is not callable." + // $TEST$ no error "This expression is not callable." »(blockLambda)«(); - # $TEST$ no error "This expression is not callable." + // $TEST$ no error "This expression is not callable." »(expressionLambda)«(); - # $TEST$ error "This expression is not callable." + // $TEST$ error "This expression is not callable." »intOrNull«(); - # $TEST$ no error "This expression is not callable." + // $TEST$ no error "This expression is not callable." »callableOrNull«(); /* @@ -100,14 +100,14 @@ segment mySegment2( * distance to the linking error might be too large. */ - # $TEST$ no error "This expression is not callable." + // $TEST$ no error "This expression is not callable." »unknownGlobal«(); - # $TEST$ no error "This expression is not callable." + // $TEST$ no error "This expression is not callable." »MyClass.unknownMember«(); - # $TEST$ error "This expression is not callable." + // $TEST$ error "This expression is not callable." val alias1 = unknownGlobal; »alias1«(); - # $TEST$ error "This expression is not callable." + // $TEST$ error "This expression is not callable." val alias2 = MyClass.unknownMember; »alias2«(); } diff --git a/packages/ttsl-lang/tests/resources/validation/types/checking/called class must have constructor/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/checking/called class must have constructor/main.sdstest index 2f468fc9..d42292eb 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/checking/called class must have constructor/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/checking/called class must have constructor/main.sdstest @@ -6,9 +6,9 @@ class B() pipeline test { - # $TEST$ error "Cannot instantiate a class that has no constructor." + // $TEST$ error "Cannot instantiate a class that has no constructor." val a = »A«(); - # $TEST$ no error "Cannot instantiate a class that has no constructor." + // $TEST$ no error "Cannot instantiate a class that has no constructor." val b = »B«(); } diff --git a/packages/ttsl-lang/tests/resources/validation/types/checking/default values/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/checking/default values/main.sdstest index e246e86f..8dd59f9b 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/checking/default values/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/checking/default values/main.sdstest @@ -1,19 +1,19 @@ package tests.validation.types.checking.defaultValues fun myFun( - # $TEST$ no error r"Expected type .* but got .*\." + // $TEST$ no error r"Expected type .* but got .*\." param1: Int = »1«, - # $TEST$ error "Expected type 'Int' but got 'literal<"">'." + // $TEST$ error "Expected type 'Int' but got 'literal<"">'." param2: Int = »""«, ) fun myOtherFun(callback: (a: Int) -> ()) segment mySegment() { - # $TEST$ no error r"Expected type .* but got .*\." + // $TEST$ no error r"Expected type .* but got .*\." myOtherFun((a = »1«) {}); - # $TEST$ error "Expected type 'Int' but got 'literal<"">'." + // $TEST$ error "Expected type 'Int' but got 'literal<"">'." myOtherFun((a = »""«) {}); } diff --git a/packages/ttsl-lang/tests/resources/validation/types/checking/default values/with type parameters.sdstest b/packages/ttsl-lang/tests/resources/validation/types/checking/default values/with type parameters.sdstest index d37b3aeb..93259f6e 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/checking/default values/with type parameters.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/checking/default values/with type parameters.sdstest @@ -1,45 +1,45 @@ package tests.validation.types.checking.defaultValues class SomeClass( - # $TEST$ error "Expected type 'T1' but got 'literal'." + // $TEST$ error "Expected type 'T1' but got 'literal'." a1: T1 = »true«, - # $TEST$ error "Expected type 'T1' but got 'literal<1>'." + // $TEST$ error "Expected type 'T1' but got 'literal<1>'." a2: T1 = »1«, - # $TEST$ error "Expected type 'T2' but got 'literal<"">'." + // $TEST$ error "Expected type 'T2' but got 'literal<"">'." a3: T2 = »""«, - # $TEST$ error "Expected type 'T3' but got 'literal<1>'." + // $TEST$ error "Expected type 'T3' but got 'literal<1>'." a4: T3 = »1«, - # $TEST$ error "Expected type 'T3' but got 'literal<"">'." + // $TEST$ error "Expected type 'T3' but got 'literal<"">'." a5: T3 = »""«, - # $TEST$ no error r"Expected type .* but got .*\." + // $TEST$ no error r"Expected type .* but got .*\." b1: T1 = »a1«, - # $TEST$ error "Expected type 'T2' but got 'T1'." + // $TEST$ error "Expected type 'T2' but got 'T1'." b2: T2 = »a1«, - # $TEST$ error "Expected type 'T1' but got 'T2'." + // $TEST$ error "Expected type 'T1' but got 'T2'." b3: T1 = »a3«, - # $TEST$ no error r"Expected type .* but got .*\." + // $TEST$ no error r"Expected type .* but got .*\." b4: T2 = »a4«, ) @Pure fun someFunction( - # $TEST$ error "Expected type 'T1' but got 'literal'." + // $TEST$ error "Expected type 'T1' but got 'literal'." a1: T1 = »true«, - # $TEST$ error "Expected type 'T1' but got 'literal<1>'." + // $TEST$ error "Expected type 'T1' but got 'literal<1>'." a2: T1 = »1«, - # $TEST$ error "Expected type 'T2' but got 'literal<"">'." + // $TEST$ error "Expected type 'T2' but got 'literal<"">'." a3: T2 = »""«, - # $TEST$ error "Expected type 'T3' but got 'literal<1>'." + // $TEST$ error "Expected type 'T3' but got 'literal<1>'." a4: T3 = »1«, - # $TEST$ error "Expected type 'T3' but got 'literal<"">'." + // $TEST$ error "Expected type 'T3' but got 'literal<"">'." a5: T3 = »""«, - # $TEST$ no error r"Expected type .* but got .*\." + // $TEST$ no error r"Expected type .* but got .*\." b1: T1 = »a1«, - # $TEST$ error "Expected type 'T2' but got 'T1'." + // $TEST$ error "Expected type 'T2' but got 'T1'." b2: T2 = »a1«, - # $TEST$ error "Expected type 'T1' but got 'T2'." + // $TEST$ error "Expected type 'T1' but got 'T2'." b3: T1 = »a3«, - # $TEST$ no error r"Expected type .* but got .*\." + // $TEST$ no error r"Expected type .* but got .*\." b4: T2 = »a4«, ) diff --git a/packages/ttsl-lang/tests/resources/validation/types/checking/indexed access on list/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/checking/indexed access on list/main.sdstest index dbf4d841..dd10f865 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/checking/indexed access on list/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/checking/indexed access on list/main.sdstest @@ -4,25 +4,25 @@ package tests.validation.types.checking.indexedAccessOnList @Pure fun index() -> index: Int pipeline myPipeline { - # $TEST$ no error r"Expected type .* but got .*\." + // $TEST$ no error r"Expected type .* but got .*\." [0][»0«]; - # $TEST$ error "Expected type 'Int' but got 'literal<"">'." + // $TEST$ error "Expected type 'Int' but got 'literal<"">'." [0][»""«]; - # $TEST$ no error r"Expected type .* but got .*\." + // $TEST$ no error r"Expected type .* but got .*\." [0][»index()«]; - # $TEST$ no error r"Expected type .* but got .*\." + // $TEST$ no error r"Expected type .* but got .*\." list()[»0«]; - # $TEST$ error "Expected type 'Int' but got 'literal<"">'." + // $TEST$ error "Expected type 'Int' but got 'literal<"">'." list()[»""«]; - # $TEST$ no error r"Expected type .* but got .*\." + // $TEST$ no error r"Expected type .* but got .*\." list()[»index()«]; - # $TEST$ no error r"Expected type .* but got .*\." + // $TEST$ no error r"Expected type .* but got .*\." unresolved[»""«]; } @@ -30,6 +30,6 @@ pipeline myPipeline { class MyClass( p1: T, - # $TEST$ error "Expected type 'Int' but got 'T'." + // $TEST$ error "Expected type 'Int' but got 'T'." a: Any? = [0][»p1«], ) diff --git a/packages/ttsl-lang/tests/resources/validation/types/checking/indexed access on map/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/checking/indexed access on map/main.sdstest index 11651e6b..c47863f9 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/checking/indexed access on map/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/checking/indexed access on map/main.sdstest @@ -4,25 +4,25 @@ package tests.validation.types.checking.indexedAccessOnMap @Pure fun key() -> key: String pipeline myPipeline { - # $TEST$ no error r"Expected type .* but got .*\." + // $TEST$ no error r"Expected type .* but got .*\." {"": ""}[»""«]; - # $TEST$ error "Expected type 'String' but got 'literal<1>'." + // $TEST$ error "Expected type 'String' but got 'literal<1>'." {"": ""}[»1«]; - # $TEST$ no error r"Expected type .* but got .*\." + // $TEST$ no error r"Expected type .* but got .*\." {"": ""}[»key()«]; - # $TEST$ no error r"Expected type .* but got .*\." + // $TEST$ no error r"Expected type .* but got .*\." map()[»""«]; - # $TEST$ error "Expected type 'String' but got 'literal<1>'." + // $TEST$ error "Expected type 'String' but got 'literal<1>'." map()[»1«]; - # $TEST$ no error r"Expected type .* but got .*\." + // $TEST$ no error r"Expected type .* but got .*\." map()[»key()«]; - # $TEST$ no error r"Expected type .* but got .*\." + // $TEST$ no error r"Expected type .* but got .*\." unresolved[»""«]; } @@ -31,13 +31,13 @@ class MyMap sub Map segment mySegment( myMap: MyMap, ) { - # $TEST$ no error r"Expected type .* but got .*\." + // $TEST$ no error r"Expected type .* but got .*\." myMap[»""«]; - # $TEST$ error "Expected type 'String' but got 'literal<1>'." + // $TEST$ error "Expected type 'String' but got 'literal<1>'." myMap[»1«]; - # $TEST$ no error r"Expected type .* but got .*\." + // $TEST$ no error r"Expected type .* but got .*\." myMap[»key()«]; } @@ -45,6 +45,6 @@ segment mySegment( class MyClass( p1: T, - # $TEST$ error "Expected type 'String' but got 'T'." + // $TEST$ error "Expected type 'String' but got 'T'." a: Any? = {"": ""}[»p1«], ) diff --git a/packages/ttsl-lang/tests/resources/validation/types/checking/indexed access receiver/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/checking/indexed access receiver/main.sdstest index 761a23ab..7486419b 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/checking/indexed access receiver/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/checking/indexed access receiver/main.sdstest @@ -11,25 +11,25 @@ segment mySegment( myList: MyList, myMap: MyMap, ) { - # $TEST$ no error r"Expected type 'List' or 'Map' but got .*\." + // $TEST$ no error r"Expected type 'List' or 'Map' but got .*\." »[1]«[0]; - # $TEST$ no error r"Expected type 'List' or 'Map' but got .*\." + // $TEST$ no error r"Expected type 'List' or 'Map' but got .*\." »{0: 1}«[0]; - # $TEST$ error "Expected type 'List' or 'Map' but got 'literal<1>'." + // $TEST$ error "Expected type 'List' or 'Map' but got 'literal<1>'." »1«[0]; - # $TEST$ no error r"Expected type 'List' or 'Map' but got .*\." + // $TEST$ no error r"Expected type 'List' or 'Map' but got .*\." »listOrNull«[0]; - # $TEST$ no error r"Expected type 'List' or 'Map' but got .*\." + // $TEST$ no error r"Expected type 'List' or 'Map' but got .*\." »mapOrNull«[""]; - # $TEST$ error "Expected type 'List' or 'Map' but got 'Int?'." + // $TEST$ error "Expected type 'List' or 'Map' but got 'Int?'." »intOrNull«[0]; - # $TEST$ no error r"Expected type 'List' or 'Map' but got .*\." + // $TEST$ no error r"Expected type 'List' or 'Map' but got .*\." »myList«[0]; - # $TEST$ no error r"Expected type 'List' or 'Map' but got .*\." + // $TEST$ no error r"Expected type 'List' or 'Map' but got .*\." »myMap«[""]; - # $TEST$ error "Expected type 'List' or 'Map' but got '$unknown'." + // $TEST$ error "Expected type 'List' or 'Map' but got '$unknown'." »unresolved«[0]; } @@ -37,6 +37,6 @@ segment mySegment( class MyClass( p1: T, - # $TEST$ error "Expected type 'List' or 'Map' but got 'T'." + // $TEST$ error "Expected type 'List' or 'Map' but got 'T'." p2: Any? = »p1«[0], ) diff --git a/packages/ttsl-lang/tests/resources/validation/types/checking/infix operations/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/checking/infix operations/main.sdstest index 943cff73..ecb4643d 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/checking/infix operations/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/checking/infix operations/main.sdstest @@ -2,130 +2,130 @@ package tests.validation.types.checking.infixOperations pipeline myPipeline { - # $TEST$ no error r"Expected type 'Boolean' but got .*\." - # $TEST$ no error r"Expected type 'Boolean' but got .*\." + // $TEST$ no error r"Expected type 'Boolean' but got .*\." + // $TEST$ no error r"Expected type 'Boolean' but got .*\." »true« or »true« ; - # $TEST$ error "Expected type 'Boolean' but got 'literal<0>'." - # $TEST$ error "Expected type 'Boolean' but got 'literal<0>'." + // $TEST$ error "Expected type 'Boolean' but got 'literal<0>'." + // $TEST$ error "Expected type 'Boolean' but got 'literal<0>'." »0« or »0«; - # $TEST$ error "Expected type 'Boolean' but got '$unknown'." - # $TEST$ error "Expected type 'Boolean' but got '$unknown'." + // $TEST$ error "Expected type 'Boolean' but got '$unknown'." + // $TEST$ error "Expected type 'Boolean' but got '$unknown'." »unresolved« or »unresolved«; - # $TEST$ no error r"Expected type 'Boolean' but got .*\." - # $TEST$ no error r"Expected type 'Boolean' but got .*\." + // $TEST$ no error r"Expected type 'Boolean' but got .*\." + // $TEST$ no error r"Expected type 'Boolean' but got .*\." »true« and »true«; - # $TEST$ error "Expected type 'Boolean' but got 'literal<0>'." - # $TEST$ error "Expected type 'Boolean' but got 'literal<0>'." + // $TEST$ error "Expected type 'Boolean' but got 'literal<0>'." + // $TEST$ error "Expected type 'Boolean' but got 'literal<0>'." »0« and »0«; - # $TEST$ error "Expected type 'Boolean' but got '$unknown'." - # $TEST$ error "Expected type 'Boolean' but got '$unknown'." + // $TEST$ error "Expected type 'Boolean' but got '$unknown'." + // $TEST$ error "Expected type 'Boolean' but got '$unknown'." »unresolved« and »unresolved«; - # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." - # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." »0.0« + »0.0«; - # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." - # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." »0« + »0«; - # $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." - # $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." + // $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." + // $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." »""« + »""«; - # $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." - # $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." + // $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." + // $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." »unresolved« + »unresolved«; - # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." - # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." »0.0« - »0.0«; - # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." - # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." »0« - »0«; - # $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." - # $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." + // $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." + // $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." »""« - »""«; - # $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." - # $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." + // $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." + // $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." »unresolved« - »unresolved«; - # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." - # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." »0.0« * »0.0«; - # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." - # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." »0« * »0«; - # $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." - # $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." + // $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." + // $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." »""« * »""«; - # $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." - # $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." + // $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." + // $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." »unresolved« * »unresolved«; - # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." - # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." »0.0« / »0.0«; - # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." - # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." »0« / »0«; - # $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." - # $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." + // $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." + // $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." »""« / »""«; - # $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." - # $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." + // $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." + // $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." »unresolved« / »unresolved«; - # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." - # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." »0.0« < »0.0«; - # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." - # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." »0« < »0«; - # $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." - # $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." + // $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." + // $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." »""« < »""«; - # $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." - # $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." + // $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." + // $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." »unresolved« < »unresolved«; - # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." - # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." »0.0« <= »0.0«; - # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." - # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." »0« <= »0«; - # $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." - # $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." + // $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." + // $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." »""« <= »""«; - # $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." - # $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." + // $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." + // $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." »unresolved« <= »unresolved«; - # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." - # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." »0.0« >= »0.0«; - # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." - # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." »0« >= »0«; - # $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." - # $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." + // $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." + // $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." »""« >= »""«; - # $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." - # $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." + // $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." + // $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." »unresolved« >= »unresolved«; - # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." - # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." »0.0« > »0.0«; - # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." - # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." »0« > »0«; - # $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." - # $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." + // $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." + // $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." »""« > »""«; - # $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." - # $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." + // $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." + // $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." »unresolved« > »unresolved«; } @@ -133,36 +133,36 @@ pipeline myPipeline { class MyClass( p1: T, - # $TEST$ error "Expected type 'Boolean' but got 'T'." - # $TEST$ error "Expected type 'Boolean' but got 'T'." + // $TEST$ error "Expected type 'Boolean' but got 'T'." + // $TEST$ error "Expected type 'Boolean' but got 'T'." a1: Any? = »p1« or »p1«, - # $TEST$ error "Expected type 'Boolean' but got 'T'." - # $TEST$ error "Expected type 'Boolean' but got 'T'." + // $TEST$ error "Expected type 'Boolean' but got 'T'." + // $TEST$ error "Expected type 'Boolean' but got 'T'." a2: Any? = »p1« and »p1«, - # $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." - # $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." + // $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." + // $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." b1: Any? = »p1« + »p1«, - # $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." - # $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." + // $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." + // $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." b2: Any? = »p1« - »p1«, - # $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." - # $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." + // $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." + // $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." b3: Any? = »p1« * »p1«, - # $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." - # $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." + // $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." + // $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." b4: Any? = »p1« / »p1«, - # $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." - # $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." + // $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." + // $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." c1: Any? = »p1« < »p1«, - # $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." - # $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." + // $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." + // $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." c2: Any? = »p1« <= »p1«, - # $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." - # $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." + // $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." + // $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." c3: Any? = »p1« >= »p1«, - # $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." - # $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." + // $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." + // $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." c4: Any? = »p1« > »p1«, ) diff --git a/packages/ttsl-lang/tests/resources/validation/types/checking/lists/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/checking/lists/main.sdstest index d5a8dea5..aa7a127a 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/checking/lists/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/checking/lists/main.sdstest @@ -6,11 +6,11 @@ fun twoResults() -> (r1: Int, r2: Int) segment mySegment() { [ - # $TEST$ error "Cannot add a value of type '()' to a list." + // $TEST$ error "Cannot add a value of type '()' to a list." »noResults()«, - # $TEST$ no error r"Cannot add a value of type '.*' to a list\." + // $TEST$ no error r"Cannot add a value of type '.*' to a list\." »oneResult()«, - # $TEST$ error "Cannot add a value of type '(r1: Int, r2: Int)' to a list." + // $TEST$ error "Cannot add a value of type '(r1: Int, r2: Int)' to a list." »twoResults()« ]; } diff --git a/packages/ttsl-lang/tests/resources/validation/types/checking/maps/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/checking/maps/main.sdstest index b2786291..5ad3501f 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/checking/maps/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/checking/maps/main.sdstest @@ -6,14 +6,14 @@ fun twoResults() -> (r1: Int, r2: Int) segment mySegment() { { - # $TEST$ error "Cannot use a value of type '()' as a map key." - # $TEST$ error "Cannot use a value of type '()' as a map value." + // $TEST$ error "Cannot use a value of type '()' as a map key." + // $TEST$ error "Cannot use a value of type '()' as a map value." »noResults()«: »noResults()«, - # $TEST$ no error r"Cannot use a value of type '.*' as a map key\." - # $TEST$ no error r"Cannot use a value of type '.*' as a map value\." + // $TEST$ no error r"Cannot use a value of type '.*' as a map key\." + // $TEST$ no error r"Cannot use a value of type '.*' as a map value\." »oneResult()«: »oneResult()«, - # $TEST$ error "Cannot use a value of type '(r1: Int, r2: Int)' as a map key." - # $TEST$ error "Cannot use a value of type '(r1: Int, r2: Int)' as a map value." + // $TEST$ error "Cannot use a value of type '(r1: Int, r2: Int)' as a map key." + // $TEST$ error "Cannot use a value of type '(r1: Int, r2: Int)' as a map value." »twoResults()«: »twoResults()« }; } diff --git a/packages/ttsl-lang/tests/resources/validation/types/checking/prefix operations/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/checking/prefix operations/main.sdstest index 96583b8e..5a1c9fcc 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/checking/prefix operations/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/checking/prefix operations/main.sdstest @@ -2,20 +2,20 @@ package tests.validation.types.checking.prefixOperations segment mySegment() { - # $TEST$ no error r"Expected type 'Boolean' but got .*\." + // $TEST$ no error r"Expected type 'Boolean' but got .*\." not »true«; - # $TEST$ error "Expected type 'Boolean' but got 'literal<0>'." + // $TEST$ error "Expected type 'Boolean' but got 'literal<0>'." not »0«; - # $TEST$ error "Expected type 'Boolean' but got '$unknown'." + // $TEST$ error "Expected type 'Boolean' but got '$unknown'." not »unresolved«; - # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." -»0.0«; - # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." -»0«; - # $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." + // $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." -»""«; - # $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." + // $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." -»unresolved«; } @@ -23,9 +23,9 @@ segment mySegment() { class MyClass( p1: T, - # $TEST$ error "Expected type 'Boolean' but got 'T'." + // $TEST$ error "Expected type 'Boolean' but got 'T'." a: Any? = not »p1«, - # $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." + // $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." b: Any? = -»p1«, ) diff --git a/packages/ttsl-lang/tests/resources/validation/types/checking/type casts/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/checking/type casts/main.sdstest index 950846d7..10308aa4 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/checking/type casts/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/checking/type casts/main.sdstest @@ -1,9 +1,9 @@ package tests.validation.types.checking.typeCasts pipeline test { - # $TEST$ no error "Type casts can only be applied to expressions of unknown type." + // $TEST$ no error "Type casts can only be applied to expressions of unknown type." »unresolved« as Int; - # $TEST$ error "Type casts can only be applied to expressions of unknown type." + // $TEST$ error "Type casts can only be applied to expressions of unknown type." »1« as Int; } diff --git a/packages/ttsl-lang/tests/resources/validation/types/checking/type parameter bounds for default values/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/checking/type parameter bounds for default values/main.sdstest index eafdceea..08129ba3 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/checking/type parameter bounds for default values/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/checking/type parameter bounds for default values/main.sdstest @@ -2,60 +2,60 @@ package tests.validation.types.checking.typeParameterBoundsForDefaultValues class C1< T1 sub Any, - # $TEST$ error "Expected type 'Number' but got 'T1'." + // $TEST$ error "Expected type 'Number' but got 'T1'." T2 sub Number = »T1«, - # $TEST$ error "Expected type 'Number' but got 'Any'." + // $TEST$ error "Expected type 'Number' but got 'Any'." T3 sub Number = »Any«, - # $TEST$ error "Expected type 'T1' but got 'Any'." + // $TEST$ error "Expected type 'T1' but got 'Any'." T4 sub T1 = »Any«, > class C2< T1 sub Number, - # $TEST$ no error r"Expected type '.*' but got '.*'\." + // $TEST$ no error r"Expected type '.*' but got '.*'\." T2 sub Number = »T1«, - # $TEST$ no error r"Expected type '.*' but got '.*'\." + // $TEST$ no error r"Expected type '.*' but got '.*'\." T3 sub Number = »Number«, - # $TEST$ no error r"Expected type '.*' but got '.*'\." + // $TEST$ no error r"Expected type '.*' but got '.*'\." T4 sub T1 = »T1«, - # $TEST$ error "Expected type 'T1' but got 'T2'." + // $TEST$ error "Expected type 'T1' but got 'T2'." T5 sub T1 = »T2«, > class C3< T1 sub Int, - # $TEST$ no error r"Expected type '.*' but got '.*'\." + // $TEST$ no error r"Expected type '.*' but got '.*'\." T2 sub Number = »T1«, - # $TEST$ no error r"Expected type '.*' but got '.*'\." + // $TEST$ no error r"Expected type '.*' but got '.*'\." T3 sub Number = »Int«, - # $TEST$ no error r"Expected type '.*' but got '.*'\." + // $TEST$ no error r"Expected type '.*' but got '.*'\." T4 sub T1 = »Nothing«, > @Pure fun f1< T1 sub Any, - # $TEST$ error "Expected type 'Number' but got 'T1'." + // $TEST$ error "Expected type 'Number' but got 'T1'." T2 sub Number = »T1«, - # $TEST$ error "Expected type 'Number' but got 'Any'." + // $TEST$ error "Expected type 'Number' but got 'Any'." T3 sub Number = »Any«, - # $TEST$ error "Expected type 'T1' but got 'Any'." + // $TEST$ error "Expected type 'T1' but got 'Any'." T4 sub T1 = »Any«, >() @Pure fun f2< T1 sub Number, - # $TEST$ no error r"Expected type '.*' but got '.*'\." + // $TEST$ no error r"Expected type '.*' but got '.*'\." T2 sub Number = »T1«, - # $TEST$ no error r"Expected type '.*' but got '.*'\." + // $TEST$ no error r"Expected type '.*' but got '.*'\." T3 sub Number = »Number«, - # $TEST$ no error r"Expected type '.*' but got '.*'\." + // $TEST$ no error r"Expected type '.*' but got '.*'\." T4 sub T1 = »T1«, - # $TEST$ error "Expected type 'T1' but got 'T2'." + // $TEST$ error "Expected type 'T1' but got 'T2'." T5 sub T1 = »T2«, >() @Pure fun f3< T1 sub Int, - # $TEST$ no error r"Expected type '.*' but got '.*'\." + // $TEST$ no error r"Expected type '.*' but got '.*'\." T2 sub Number = »T1«, - # $TEST$ no error r"Expected type '.*' but got '.*'\." + // $TEST$ no error r"Expected type '.*' but got '.*'\." T3 sub Number = »Int«, - # $TEST$ no error r"Expected type '.*' but got '.*'\." + // $TEST$ no error r"Expected type '.*' but got '.*'\." T4 sub T1 = »Nothing«, >() diff --git a/packages/ttsl-lang/tests/resources/validation/types/checking/type parameter bounds for named types/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/checking/type parameter bounds for named types/main.sdstest index 3fe0f1dc..6b929029 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/checking/type parameter bounds for named types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/checking/type parameter bounds for named types/main.sdstest @@ -5,29 +5,29 @@ class C2 class C3 @Pure fun f( - # $TEST$ no error r"Expected type '.*' but got '.*'\." + // $TEST$ no error r"Expected type '.*' but got '.*'\." a1: C1<»Any?«>, - # $TEST$ no error r"Expected type '.*' but got '.*'\." + // $TEST$ no error r"Expected type '.*' but got '.*'\." a2: C1, - # $TEST$ no error r"Expected type '.*' but got '.*'\." + // $TEST$ no error r"Expected type '.*' but got '.*'\." a3: C1, - # $TEST$ no error r"Expected type '.*' but got '.*'\." + // $TEST$ no error r"Expected type '.*' but got '.*'\." a4: C1<»T«>, - # $TEST$ no error r"Expected type '.*' but got '.*'\." + // $TEST$ no error r"Expected type '.*' but got '.*'\." b1: C2<»Number«>, - # $TEST$ error "Expected type 'Number' but got 'String'." + // $TEST$ error "Expected type 'Number' but got 'String'." b2: C2<»String«>, - # $TEST$ error "Expected type 'Number' but got 'T'." + // $TEST$ error "Expected type 'Number' but got 'T'." b3: C2<»T«>, - # $TEST$ no error r"Expected type '.*' but got '.*'\." - # $TEST$ no error r"Expected type '.*' but got '.*'\." + // $TEST$ no error r"Expected type '.*' but got '.*'\." + // $TEST$ no error r"Expected type '.*' but got '.*'\." c1: C3<»Number«, »Number«>, - # $TEST$ no error r"Expected type '.*' but got '.*'\." - # $TEST$ no error r"Expected type '.*' but got '.*'\." + // $TEST$ no error r"Expected type '.*' but got '.*'\." + // $TEST$ no error r"Expected type '.*' but got '.*'\." c2: C3<»Number«, »Int«>, - # $TEST$ no error r"Expected type '.*' but got '.*'\." - # $TEST$ error "Expected type 'Int' but got 'Number'." + // $TEST$ no error r"Expected type '.*' but got '.*'\." + // $TEST$ error "Expected type 'Int' but got 'Number'." c3: C3<»Int«, »Number«>, ) diff --git a/packages/ttsl-lang/tests/resources/validation/types/checking/yields/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/checking/yields/main.sdstest index 3cdf080c..79a363df 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/checking/yields/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/checking/yields/main.sdstest @@ -1,16 +1,16 @@ package tests.validation.types.checking.yields segment mySegment1() -> result: Int { - # $TEST$ no error r"Expected type .* but got .*\." + // $TEST$ no error r"Expected type .* but got .*\." yield »result« = 1; } segment mySegment2() -> result: Int { - # $TEST$ error "Expected type 'Int' but got 'literal<"">'." + // $TEST$ error "Expected type 'Int' but got 'literal<"">'." yield »result« = ""; } segment mySegment3() { - # $TEST$ no error r"Expected type .* but got .*\." + // $TEST$ no error r"Expected type .* but got .*\." yield »unresolved« = 1; } diff --git a/packages/ttsl-lang/tests/resources/validation/types/named types/missing required type parameter/dont show this error if the type argument list is missing altogether.sdstest b/packages/ttsl-lang/tests/resources/validation/types/named types/missing required type parameter/dont show this error if the type argument list is missing altogether.sdstest index c80089de..1ee6c48c 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/named types/missing required type parameter/dont show this error if the type argument list is missing altogether.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/named types/missing required type parameter/dont show this error if the type argument list is missing altogether.sdstest @@ -1,6 +1,6 @@ package tests.validation.other.namedTypes.missingRequiredTypeParameter -# $TEST$ no error r"The type parameters? .* must be set here\." +// $TEST$ no error r"The type parameters? .* must be set here\." class MyClass diff --git a/packages/ttsl-lang/tests/resources/validation/types/named types/missing required type parameter/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/named types/missing required type parameter/main.sdstest index f2720e73..52049aea 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/named types/missing required type parameter/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/named types/missing required type parameter/main.sdstest @@ -5,28 +5,28 @@ class MyClassWithoutTypeParameter class MyClassWithTypeParameters fun myFunction1( - # $TEST$ no error r"The type parameters? .* must be set here\." + // $TEST$ no error r"The type parameters? .* must be set here\." a1: MyClassWithoutTypeParameter»<>«, - # $TEST$ no error r"The type parameters? .* must be set here\." + // $TEST$ no error r"The type parameters? .* must be set here\." a2: MyClassWithoutTypeParameter»«, - # $TEST$ no error r"The type parameters? .* must be set here\." + // $TEST$ no error r"The type parameters? .* must be set here\." a3: MyClassWithoutTypeParameter»«, - # $TEST$ error "The type parameters 'T1', 'T2' must be set here." + // $TEST$ error "The type parameters 'T1', 'T2' must be set here." b1: MyClassWithTypeParameters»<>«, - # $TEST$ error "The type parameter 'T2' must be set here." + // $TEST$ error "The type parameter 'T2' must be set here." b2: MyClassWithTypeParameters»«, - # $TEST$ error "The type parameter 'T1' must be set here." + // $TEST$ error "The type parameter 'T1' must be set here." b3: MyClassWithTypeParameters»«, - # $TEST$ no error r"The type parameters? .* must be set here\." + // $TEST$ no error r"The type parameters? .* must be set here\." b4: MyClassWithTypeParameters»«, - # $TEST$ no error r"The type parameters? .* must be set here\." + // $TEST$ no error r"The type parameters? .* must be set here\." b5: MyClassWithTypeParameters»«, - # $TEST$ no error r"The type parameters? .* must be set here\." + // $TEST$ no error r"The type parameters? .* must be set here\." d1: Unresolved»<>«, - # $TEST$ no error r"The type parameters? .* must be set here\." + // $TEST$ no error r"The type parameters? .* must be set here\." d2: Unresolved»«, - # $TEST$ no error r"The type parameters? .* must be set here\." + // $TEST$ no error r"The type parameters? .* must be set here\." d3: Unresolved»«, ) diff --git a/packages/ttsl-lang/tests/resources/validation/types/named types/missing type argument list/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/named types/missing type argument list/main.sdstest index 1b6302da..e7793cda 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/named types/missing type argument list/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/named types/missing type argument list/main.sdstest @@ -5,23 +5,23 @@ class MyClassWithRequiredTypeParameters class MyClassWithOptionalTypeParameters fun myFunction( - # $TEST$ no error r"The type '\w*' has required type parameters, so a type argument list must be added\." + // $TEST$ no error r"The type '\w*' has required type parameters, so a type argument list must be added\." a1: »MyClassWithoutTypeParameters«, - # $TEST$ no error r"The type '\w*' has required type parameters, so a type argument list must be added\." + // $TEST$ no error r"The type '\w*' has required type parameters, so a type argument list must be added\." a2: »MyClassWithoutTypeParameters«<>, - # $TEST$ error "The type 'MyClassWithRequiredTypeParameters' has required type parameters, so a type argument list must be added." + // $TEST$ error "The type 'MyClassWithRequiredTypeParameters' has required type parameters, so a type argument list must be added." b1: »MyClassWithRequiredTypeParameters«, - # $TEST$ no error r"The type '\w*' has required type parameters, so a type argument list must be added\." + // $TEST$ no error r"The type '\w*' has required type parameters, so a type argument list must be added\." b2: »MyClassWithRequiredTypeParameters«<>, - # $TEST$ no error r"The type '\w*' has required type parameters, so a type argument list must be added\." + // $TEST$ no error r"The type '\w*' has required type parameters, so a type argument list must be added\." c1: »MyClassWithOptionalTypeParameters«, - # $TEST$ no error r"The type '\w*' has required type parameters, so a type argument list must be added\." + // $TEST$ no error r"The type '\w*' has required type parameters, so a type argument list must be added\." c2: »MyClassWithOptionalTypeParameters«<>, - # $TEST$ no error r"The type '\w*' has required type parameters, so a type argument list must be added\." + // $TEST$ no error r"The type '\w*' has required type parameters, so a type argument list must be added\." d1: »UnresolvedClass«, - # $TEST$ no error r"The type '\w*' has required type parameters, so a type argument list must be added\." + // $TEST$ no error r"The type '\w*' has required type parameters, so a type argument list must be added\." d2: »UnresolvedClass«<>, ) diff --git a/packages/ttsl-lang/tests/resources/validation/types/type hints/missing for attribute/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/type hints/missing for attribute/main.sdstest index b8d46c41..06b9c856 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/type hints/missing for attribute/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/type hints/missing for attribute/main.sdstest @@ -1,9 +1,9 @@ package tests.validation.types.typeHints.missingForAttribute class MyClass { - # $TEST$ error "An attribute must have a type hint." + // $TEST$ error "An attribute must have a type hint." attr »myAttribute1« - # $TEST$ no error "An attribute must have a type hint." + // $TEST$ no error "An attribute must have a type hint." attr »myAttribute2«: Int } diff --git a/packages/ttsl-lang/tests/resources/validation/types/type hints/missing for parameter/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/type hints/missing for parameter/main.sdstest index 1f99516f..f7250652 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/type hints/missing for parameter/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/type hints/missing for parameter/main.sdstest @@ -1,39 +1,39 @@ package tests.validation.types.typeHints.missingForParameter -# $TEST$ error "A parameter must have a type hint." -# $TEST$ no error "A parameter must have a type hint." +// $TEST$ error "A parameter must have a type hint." +// $TEST$ no error "A parameter must have a type hint." annotation MyAnnotation(»a«, »b«: Int) -# $TEST$ error "A parameter must have a type hint." -# $TEST$ no error "A parameter must have a type hint." +// $TEST$ error "A parameter must have a type hint." +// $TEST$ no error "A parameter must have a type hint." class MyClass(»a«, »b«: Int) { - # $TEST$ error "A parameter must have a type hint." - # $TEST$ no error "A parameter must have a type hint." + // $TEST$ error "A parameter must have a type hint." + // $TEST$ no error "A parameter must have a type hint." class MyClass(»a«, »b«: Int) {} - # $TEST$ error "A parameter must have a type hint." - # $TEST$ no error "A parameter must have a type hint." + // $TEST$ error "A parameter must have a type hint." + // $TEST$ no error "A parameter must have a type hint." fun myFunction(»a«, »b«: Int) } -# $TEST$ error "A parameter must have a type hint." -# $TEST$ no error "A parameter must have a type hint." +// $TEST$ error "A parameter must have a type hint." +// $TEST$ no error "A parameter must have a type hint." fun myFunction(»a«, »b«: Int) pipeline myPipeline { - # $TEST$ no error "A parameter must have a type hint." + // $TEST$ no error "A parameter must have a type hint." (»a«) -> a; - # $TEST$ no error "A parameter must have a type hint." + // $TEST$ no error "A parameter must have a type hint." (»a«) {}; } -# $TEST$ error "A parameter must have a type hint." -# $TEST$ no error "A parameter must have a type hint." +// $TEST$ error "A parameter must have a type hint." +// $TEST$ no error "A parameter must have a type hint." segment mySegment1(»a«, »b«: Int) {} -# $TEST$ error "A parameter must have a type hint." -# $TEST$ no error "A parameter must have a type hint." +// $TEST$ error "A parameter must have a type hint." +// $TEST$ no error "A parameter must have a type hint." segment mySegment2( f: (»a«, »b«: Int) -> () ) {} diff --git a/packages/ttsl-lang/tests/resources/validation/types/type hints/missing for result/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/type hints/missing for result/main.sdstest index 3382cbf0..29e4df16 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/type hints/missing for result/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/type hints/missing for result/main.sdstest @@ -1,21 +1,21 @@ package tests.validation.types.typeHints.missingForResult class MyClass { - # $TEST$ error "A result must have a type hint." - # $TEST$ no error "A result must have a type hint." + // $TEST$ error "A result must have a type hint." + // $TEST$ no error "A result must have a type hint." fun myFunction() -> (»a«, »b«: Int) } -# $TEST$ error "A result must have a type hint." -# $TEST$ no error "A result must have a type hint." +// $TEST$ error "A result must have a type hint." +// $TEST$ no error "A result must have a type hint." fun myFunction() -> (»a«, »b«: Int) -# $TEST$ error "A result must have a type hint." -# $TEST$ no error "A result must have a type hint." +// $TEST$ error "A result must have a type hint." +// $TEST$ no error "A result must have a type hint." segment mySegment1() -> (»a«, »b«: Int) {} -# $TEST$ error "A result must have a type hint." -# $TEST$ no error "A result must have a type hint." +// $TEST$ error "A result must have a type hint." +// $TEST$ no error "A result must have a type hint." segment mySegment2( f: () -> (»a«, »b«: Int) ) {} From 4f6429d953c0a6cdc84927cebb0d8227e37bdfee Mon Sep 17 00:00:00 2001 From: methr0 Date: Wed, 15 May 2024 12:30:52 +0200 Subject: [PATCH 025/183] change definition of comments to // --- packages/ttsl-lang/src/language/grammar/safe-ds.langium | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/ttsl-lang/src/language/grammar/safe-ds.langium b/packages/ttsl-lang/src/language/grammar/safe-ds.langium index c0b7828f..73e7672a 100644 --- a/packages/ttsl-lang/src/language/grammar/safe-ds.langium +++ b/packages/ttsl-lang/src/language/grammar/safe-ds.langium @@ -1286,6 +1286,6 @@ terminal TEMPLATE_STRING_INNER returns string: TEMPLATE_EXPRESSION_END STRING_TE terminal TEMPLATE_STRING_END returns string: TEMPLATE_EXPRESSION_END STRING_TEXT* STRING_END; hidden terminal ML_COMMENT: /\/\*[\s\S]*?\*\//; -hidden terminal SL_COMMENT: /\#[^\n\r]*/; +hidden terminal SL_COMMENT: /\/\/[^\n\r]*/; hidden terminal TEST_MARKER: /[»«]/; hidden terminal WS: /\s+/; From bc7b0037ee74cd2db9b58aa9b99af5cb5d5b1e23 Mon Sep 17 00:00:00 2001 From: methr0 Date: Wed, 15 May 2024 12:36:10 +0200 Subject: [PATCH 026/183] fix function and conditional statement grammar tests --- .../declarations/functions/bad-missing functionbody.tsltest | 3 +++ .../declarations/functions/bad-missing parameter list.tsltest | 2 +- .../declarations/functions/bad-missing parameter type.tsltest | 2 +- .../declarations/functions/bad-unclosed parameter list.tsltest | 2 +- .../declarations/functions/bad-unclosed result list.tsltest | 2 +- .../declarations/functions/good-annotation call.tsltest | 2 +- .../declarations/functions/good-with parameter list.tsltest | 2 +- .../declarations/functions/good-with result list.tsltest | 2 +- .../functions/good-with type parameter list.tsltest | 2 +- .../bad-with else missing elseblock.tsltest | 2 +- .../bad-without else missing block.tsltest | 2 +- .../bad-without else missing condition.tsltest | 2 +- .../conditional statements/good-with else false.tsltest | 2 +- .../conditional statements/good-with else true.tsltest | 2 +- .../conditional statements/good-without else.tsltest | 2 +- 15 files changed, 17 insertions(+), 14 deletions(-) create mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing functionbody.tsltest diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing functionbody.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing functionbody.tsltest new file mode 100644 index 00000000..ee789e47 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing functionbody.tsltest @@ -0,0 +1,3 @@ +// $TEST$ syntax_error + +function myFunction() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing parameter list.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing parameter list.tsltest index 9a97324f..184ce723 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing parameter list.tsltest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing parameter list.tsltest @@ -1,3 +1,3 @@ // $TEST$ syntax_error -function myFunction +function myFunction {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing parameter type.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing parameter type.tsltest index 6daec909..63971670 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing parameter type.tsltest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing parameter type.tsltest @@ -1,3 +1,3 @@ // $TEST$ syntax_error -function myFunction(x:) +function myFunction(x:) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed parameter list.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed parameter list.tsltest index b76a08f4..138f26e2 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed parameter list.tsltest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed parameter list.tsltest @@ -1,3 +1,3 @@ // $TEST$ syntax_error -function myFunction( +function myFunction( {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed result list.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed result list.tsltest index ebcbdd44..506f5495 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed result list.tsltest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed result list.tsltest @@ -1,3 +1,3 @@ // $TEST$ syntax_error -function myFunction(): ( +function myFunction(): {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-annotation call.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-annotation call.tsltest index f556f0e6..7137f19d 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-annotation call.tsltest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-annotation call.tsltest @@ -3,4 +3,4 @@ package test @Annotation -function myFunction() +function myFunction() {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with parameter list.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with parameter list.tsltest index 36b85780..472e9a0b 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with parameter list.tsltest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with parameter list.tsltest @@ -1,3 +1,3 @@ // $TEST$ no_syntax_error -function myFunction() +function myFunction() {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with result list.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with result list.tsltest index 54bc099f..f8e478fc 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with result list.tsltest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with result list.tsltest @@ -1,3 +1,3 @@ // $TEST$ no_syntax_error -function myFunction() -> () +function myFunction(): Int {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with type parameter list.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with type parameter list.tsltest index d9f348cc..a3ea0554 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with type parameter list.tsltest +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with type parameter list.tsltest @@ -1,3 +1,3 @@ // $TEST$ no_syntax_error -function myFunction(x: Int) +function myFunction(x: Int) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-with else missing elseblock.tsltest b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-with else missing elseblock.tsltest index 2726729b..240cdeb9 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-with else missing elseblock.tsltest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-with else missing elseblock.tsltest @@ -1,6 +1,6 @@ // $TEST$ syntax_error -function myFunction(): { +function myFunction() { if (true){} else } \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-without else missing block.tsltest b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-without else missing block.tsltest index 415d8f91..f239f557 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-without else missing block.tsltest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-without else missing block.tsltest @@ -1,5 +1,5 @@ // $TEST$ syntax_error -function myFunction(): { +function myFunction() { if (true) } diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-without else missing condition.tsltest b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-without else missing condition.tsltest index 1dca81c9..460d45de 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-without else missing condition.tsltest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-without else missing condition.tsltest @@ -1,5 +1,5 @@ // $TEST$ syntax_error -function myFunction(): { +function myFunction() { if (){} } \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-with else false.tsltest b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-with else false.tsltest index 0fac6980..444d8dd5 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-with else false.tsltest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-with else false.tsltest @@ -1,6 +1,6 @@ // $TEST$ no_syntax_error -function myFunction(): { +function myFunction() { if (false){} else{} } diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-with else true.tsltest b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-with else true.tsltest index 3a6bd8ee..1fb4d176 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-with else true.tsltest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-with else true.tsltest @@ -1,6 +1,6 @@ // $TEST$ no_syntax_error -function myFunction(): { +function myFunction() { if (true){} else {} } diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-without else.tsltest b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-without else.tsltest index abb59d8a..604998d8 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-without else.tsltest +++ b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-without else.tsltest @@ -1,5 +1,5 @@ // $TEST$ no_syntax_error -function myFunction(): { +function myFunction() { if (true){} } From 26ecbe768b8a3d68d375b54f2a6f25ff3d46dc8d Mon Sep 17 00:00:00 2001 From: alex-senger Date: Thu, 16 May 2024 11:27:52 +0200 Subject: [PATCH 027/183] refactor: split parameters.ttsl into multiple packages --- .../builtins/abgeltungssteuersatz.ttsl | 12 + src/resources/builtins/arbeitslosengeld.ttsl | 118 + src/resources/builtins/arbeitslosengeld2.ttsl | 516 +++ src/resources/builtins/einkommenssteuer.ttsl | 358 ++ .../builtins/einkommenssteuerAbzuege.ttsl | 612 +++ src/resources/builtins/elterngeld.ttsl | 144 + .../builtins/erwerbsminderungsrente.ttsl | 152 + src/resources/builtins/erziehungsgeld.ttsl | 98 + src/resources/builtins/gesetzlicheRente.ttsl | 1651 ++++++++ .../builtins/grundsicherungImAlter.ttsl | 129 + src/resources/builtins/parameters.ttsl | 3748 ----------------- 11 files changed, 3790 insertions(+), 3748 deletions(-) create mode 100644 src/resources/builtins/abgeltungssteuersatz.ttsl create mode 100644 src/resources/builtins/arbeitslosengeld.ttsl create mode 100644 src/resources/builtins/arbeitslosengeld2.ttsl create mode 100644 src/resources/builtins/einkommenssteuer.ttsl create mode 100644 src/resources/builtins/einkommenssteuerAbzuege.ttsl create mode 100644 src/resources/builtins/elterngeld.ttsl create mode 100644 src/resources/builtins/erwerbsminderungsrente.ttsl create mode 100644 src/resources/builtins/erziehungsgeld.ttsl create mode 100644 src/resources/builtins/gesetzlicheRente.ttsl create mode 100644 src/resources/builtins/grundsicherungImAlter.ttsl delete mode 100644 src/resources/builtins/parameters.ttsl diff --git a/src/resources/builtins/abgeltungssteuersatz.ttsl b/src/resources/builtins/abgeltungssteuersatz.ttsl new file mode 100644 index 00000000..3f988295 --- /dev/null +++ b/src/resources/builtins/abgeltungssteuersatz.ttsl @@ -0,0 +1,12 @@ +package abgeltungssteuersatz + +// abgelt_st.yaml -------------------------------------------------------- + +/** + * Constant for the Capital Income Tax Rate as defined in §32d (1) EStG. + * Reference: Art. 1 G. v. 14.08.2007 + */ +public const abgeltungssteuersatz: Float { + from 1984-01-01 = 0.0; + from 2009-01-01 = 0.25; +} diff --git a/src/resources/builtins/arbeitslosengeld.ttsl b/src/resources/builtins/arbeitslosengeld.ttsl new file mode 100644 index 00000000..c47f51eb --- /dev/null +++ b/src/resources/builtins/arbeitslosengeld.ttsl @@ -0,0 +1,118 @@ +package arbeitslosengeld + +// arbeitsl_geld.yaml ---------------------------------------------------- + +/** + * Income which is not deducted from unemployment benefit. + * § 155 SGB III, vorher § 141 (1) S. 1 + */ +public const arbeitslosenGeldFreibetrag: Int { + // Art. 1 G. v. 21.07.1999 BGBl. I S. 1648 + from 1999-08-01 = 161; + + // Art. 3 G. v. 21.12.2000 BGBl. I S. 1983 + from 2002-01-01 = 165; +} + +/** + * Fictitious social insurance contribution rate + * § 153 (1) Nr. 1 SGB III. Wird angewendet auf das Bemessungsentgelt. ACHTUNG! Beim + * Elterngeld gibt es eine ähnliche Größe. + */ +public const sozialVersicherungsPauschale: Float { + from 1984-01-01 = 0.1727; + from 1985-01-01 = 0.1745; + from 1986-01-01 = 0.1775; + from 1987-01-01 = 0.1774; + from 1988-01-01 = 0.1794; + from 1989-01-01 = 0.1795; + from 1990-01-01 = 0.1775; + from 1991-01-01 = 0.179; + from 1992-01-01 = 0.184; + from 1993-01-01 = 0.187; + from 1994-01-01 = 0.1955; + from 1995-01-01 = 0.1915; + from 1996-01-01 = 0.1995; + from 1997-01-01 = 0.2095; + from 1998-01-01 = 0.2105; + from 2000-01-01 = 0.20535; + from 2001-01-01 = 0.2044; + from 2002-01-01 = 0.2065; + from 2003-01-01 = 0.2105; + from 2004-01-01 = 0.2095; + from 2005-01-01 = 0.2074; + from 2006-01-01 = 0.2141; + from 2007-01-01 = 0.2075; + from 2008-01-01 = 0.20475; + from 2009-01-01 = 0.20525; + from 2010-01-01 = 0.20225; + from 2011-01-01 = 0.20625; + + // Reference: Art. 2 G. v. 20.12.2011 BGBl. I S. 2854 + from 2012-01-01 = 0.21; + + // Reference: Art. 1 G. v. 18.12.2018 BGBl. I S. 2651 + from 2019-01-01 = 0.2; +} + +/** + * Replacement Rate Unemployment Benefit, for childless persons. + * §149 Nr. 2 SGB III, vorher § 129 (2) SGB III. Höhe des Arbeitslosengeldes im + * Verhältnis zum letzten Nettoentgelt bei Personen ohne Kinder im Sinne des EStG. + */ +public const satzOhneKinder: Float { + // Reference: Art. 1 G. v. 24.03.1997 BGBl. I S. 594 + from 1998-08-01 = 0.6; +} + +/** + * Replacement Rate Unemployment Benefit for persons with children. + * §149 Nr. 1 SGB III, vorher §129 Nr. 1 SGB III. Höhe des Arbeitslosengeldes im + * Verhältnis zum letzten Nettoentgelt bei Personen mit Kindern im Sinne des EStG + */ +public const satzMitKindern: Float { + // Reference: Art. 1 G. v. 24.03.1997 BGBl. I S. 594 + from 1998-08-01 = 0.67; +} + +/** + * Working hours limit to receive unemployment benefit + * §138 (3) SGB III, früher auch §102 (2) AFG. Grenze, ab der nicht mehr + * Arbeitslosigkeit unterstellt wird. + */ +public const stundengrenze: Int { + from 1969-07-01 = 20; + // Reference: Art. 1 G. v. 20.12.1985 BGBl I S. 2484 + from 1986-01-01 = 19; + + // Reference: Art. 1 G. v. 20.12.1988 BGBl I S. 2343 + from 1989-01-01 = 18; + + // Reference: Art. 2 G. v. 20.12.2011 BGBl I S. 2854 + from 2012-04-01 = 15; +} + +/** + * Length of ALG 1 eligibility + * Dauer des Anspruchs auf ALG 1 richtet sich nach Alter und wie viele Monate + * eine Person versicherungsplichtig in den letzten 5 Jahren war. + */ +public const anspruchsdauer: Dict { + from 1997-03-24 = { + nach_alter: { + 0: 12 + 50: 15 + 55: 18 + 58: 24 + }, + nach_versicherungspflichtige_monate: { + 12: 6 + 18: 8 + 20: 10 + 24: 12 + 30: 15 + 36: 18 + 48: 24 + } + } +} diff --git a/src/resources/builtins/arbeitslosengeld2.ttsl b/src/resources/builtins/arbeitslosengeld2.ttsl new file mode 100644 index 00000000..abd475a6 --- /dev/null +++ b/src/resources/builtins/arbeitslosengeld2.ttsl @@ -0,0 +1,516 @@ +package arbeitslosengeld2 + +// arbeitsl_geld_2.yaml -------------------------------------------------- + +/** + * Income shares not subject to transfer withdrawal. + * Einkommensanteile, die anrechnungsfrei bleiben. § 30 SGB II. Seit 01.10.2005 + * zudem definiert durch Freibetrag in § 11 SGB II, s. § 67 SGB II. Seit 01.04.2011 + * § 11b (2) SGB II (neugefasst durch B. v. 13.05.2011 BGBl. I S. 850. Artikel 2 + * G. v. 24.03.2011 BGBl. I S. 453). + */ +public const anrechnungsfreieEinkommensanteile: Dict>> { + // Reference: Artikel 1. G. v. 24.12.2003 BGBl. I S. 2954. + from 2005-01-01 = { + 0: { + lower_threshold: -inf, + upper_threshold: 0, + rate: 0, + intercept_at_lower_threshold: 0 + }, + 1: { + lower_threshold: 0, + upper_threshold: 400, + rate: 0.15 + }, + 2: { + upper_threshold: 900, + rate: 0.3 + }, + 3: { + upper_threshold: 1500, + rate: 0.15 + }, + 4: { + upper_threshold: inf, + rate: 0 + } + } + + // Reference: Artikel 1 G. v. 14.08.2005 BGBl. I S. 2407. + from 2005-10-01 = { + 0: { + lower_threshold: -inf, + upper_threshold: 0, + rate: 0, + intercept_at_lower_threshold: 0 + }, + 1: { + lower_threshold: 0, + upper_threshold: 100, + rate: 1.0 + }, + 2: { + upper_threshold: 800, + rate: 0.2 + }, + 3: { + upper_threshold: 1200, + rate: 0.1 + }, + 4: { + upper_threshold: inf, + rate: 0 + } + } + + // Reference: Artikel 1 G. v. 20.12.2011 BGBl. I 2854. + from 2011-04-01 = { + 2: { + upper_threshold: 1000 + } + } + + // Reference: G. v. 20.12.2022 BGBl. I S. 2328. + from 2023-07-01 = { + 0: { + lower_threshold: -inf, + upper_threshold: 0, + rate: 0, + intercept_at_lower_threshold: 0 + }, + 1: { + lower_threshold: 0, + upper_threshold: 100, + rate: 1.0 + }, + 2: { + upper_threshold: 520, + rate: 0.2 + }, + 3: { + upper_threshold: 1000, + rate: 0.3 + }, + 4: { + upper_threshold: 1200, + rate: 0.1 + }, + 5: { + upper_threshold: inf, + rate: 0 + } + } +} + +/** + * Abweichende anrechnungsfreie Einkommensanteile falls Kinder im Haushalt + * Obere Einkommensgrenze bei anzurechnendem Einkommen, Intervall 3, Haushalt mit + * Kindern. Gilt statt der Parameter in eink_anr_frei für Leistungsbezieher, die mit + * minderjährigem Kind in BG leben oder die ein minderjähriges Kind haben (zweiteres + * wird aktuell noch nicht im Code beachtet). § 30 SGB II. Seit 01.04.2011 § 11b SGB + * II (neugefasst durch B. v. 13.05.2011 BGBl. I S. 850. Artikel 2 G. v. 24.03.2011 + * BGBl. I S. 453). + */ +public const anrechnungsfreieEinkommensanteileFallsKinder: Dict>> { + // Reference: Artikel 1 G. v. 14.08.2005 BGBl. I S. 2407. + from 2005-10-01 = { + 3: { + upper_threshold: 1500 + } + } + + // Reference: G. v. 20.12.2022 BGBl. I S. 2328. + from 2023-07-01 = { + 4: { + upper_threshold: 1500 + } + } +} + +/** + * Regelsatz, seit 2011 Beträge differenzieren sich nach Regelbedarfsstufen + * § 20 V SGB II. Für 2005 bis 2010 siehe Bekanntmachungen zu § 20. Seit 2011 + * wird der Regelbedarf durch das Regelbedarfs-Ermittlungsgesetz (RBEG) ermittelt. + * Neufassung SGB II § 20 (1a) und (2) durch Artikel 6 G. v. 22.12.2016 BGBl. I + * S. + * 3159. + */ +public const regelsatz: Int | Dict { + from 2005-01-01 = { + scalar: 338, + reference: "Artikel 1 G. v. 24.12.2003 BGBl. I S. 2954.", + note: "Der tatsächliche Wert unterscheidet sich zwischen Ost und West. Korrekte Werte sind in den alten Bundesländern einschließlich Berlin (Ost) 345 Euro, in den neuen Bundesländern 331 Euro." + }, + + // Reference: B. v. 01.09.2005 BGBl. I S. 2718. + // Betrag unverändert. Der tatsächliche Wert unterscheidet sich zwischen Ost und West. Hier wurde vereinfachend 338 Euro als ungewichteter Mittelwert genommen. Korrekte Werte für die Zeit ab 1. Juli 2005 sind in den alten Bundesländern einschließlich Berlin (Ost) 345 Euro, in den neuen Bundesländern 331 Euro. + from 2005-07-01 = 338 + + // Reference: B. v. 20.07.2006 BGBl. I S. 1702. + from 2006-07-01 = 345 + + // Reference: B. v. 18.06.2007 BGBl. I S. 1139. + from 2007-07-01 = 347 + + // Reference: B. v. 26.06.2008 BGBl. I S. 1102. + from 2008-07-01 = 351 + + // Reference: B. v. 17.06.2009 BGBl. I S. 1342. + from 2009-07-01 = 359 + + // Reference: B. v. 07.06.2010 BGBl. I S. 820. Betrag unverändert. + from 2010-07-01 = 359 + + // Reference: Artikel 1 G. v. 24.03.2011 BGBl. I S. 453. + from 2011-01-01 = { + 1: 364, + 2: 328, + 3: 291, + 4: 287, + 5: 251, + 6: 215, + } + + // Reference: V. v. 20.10.2011 BGBl. I S. 2093. + from 2012-01-01 = { + 1: 374, + 2: 337, + 3: 299, + 4: 287, + 5: 251, + 6: 219, + } + + // Reference: B. v. 18.10.2012 BGBl. I S. 2175. + from 2013-01-01 = { + 1: 382, + 2: 345, + 3: 306, + 4: 289, + 5: 255, + 6: 224, + } + + // Reference: B. v. 16.10.2013 BGBl. I S. 3857. + from 2014-01-01 = { + 1: 391, + 2: 353, + 3: 313, + 4: 296, + 5: 261, + 6: 229, + } + + // Reference: B. v. 15.10.2014 BGBl. I S. 1620. + from 2015-01-01 = { + 1: 399, + 2: 360, + 3: 320, + 4: 302, + 5: 267, + 6: 234, + } + + // Reference: B. v. 22.10.2015 BGBl. I S. 1792. + from 2016-01-01 = { + 1: 404, + 2: 364, + 3: 324, + 4: 306, + 5: 270, + 6: 237, + } + + // Reference: G. v. 22.12.2016 BGBl. I S. 3159. + from 2017-01-01 = { + 1: 409, + 2: 368, + 3: 327, + 4: 311, + 5: 291, + 6: 236, + } + + // Reference: V. v. 08.11.2017 BGBl. I S. 3767. + from 2018-01-01 = { + 1: 416, + 2: 374, + 3: 332, + 4: 316, + 5: 296, + 6: 240, + } + + // Reference: V. v. 19.10.2018 BGBl. I S. 1766. + from 2019-01-01 = { + 1: 424, + 2: 382, + 3: 339, + 4: 322, + 5: 302, + 6: 245, + } + + // Reference: V. v. 18.10.2019 BGBl. I S. 1452. + from 2020-01-01 = { + 1: 432, + 2: 389, + 3: 345, + 4: 328, + 5: 308, + 6: 250 + } + + // Reference: G. v. 09.12.2020 BGBl. I S. 2855. + from 2021-01-01 = { + 1: 446, + 2: 401, + 3: 357, + 4: 373, + 5: 309, + 6: 283 + } + + // Reference: V. v. 13.10.2021 BGBl. I S. 4674. + from 2022-01-01 = { + 1: 449, + 2: 404, + 3: 360, + 4: 376, + 5: 311, + 6: 285 + } + + // Reference: G. v. 20.12.2022 BGBl. I S. 2328. + // Bürgergeld-Gesetz + from 2023-01-01 = { + 1: 502, + 2: 451, + 3: 402, + 4: 420, + 5: 348, + 6: 318 + } +} + +/** + * Anteil am Regelsatz für weitere Personen im Haushalt + * 20 (3) SGB II, eigentliche Wirknorm ist § 20 IV SGB II i.V.m Absatz V + * derselben Norm. 2005 bis 2010. + * 2005-2010 der Regelsatz für weitere Haushaltsmitglieder wurden als Anteil + * des Standardsatzes bestimmt. + */ + public const anteilRegelsatz: Dict { + // Reference: Artikel 1 G. v. 24.12.2003 BGBl. I S. 2954. + from 2005-01-01 = { + zwei_erwachsene: 0.9, + weitere_erwachsene: 0.8, + kinder_bis_5: 0.6, + kinder_ab_6_bis_13: 0.6, + kinder_ab_14_bis_24: 0.8 + } + + + // TODO: WAS HEIßT DEVIATION_FROM + // Reference: Artikel 1 G. v. 02.03.2009 BGBl. I S. 416. + from 2009-07-01 = { + zwei_erwachsene: 0.9, + weitere_erwachsene: 0.8, + kinder_bis_5: 0.6, + kinder_ab_6_bis_13: 0.7, + kinder_ab_14_bis_24: 0.8 + } + } + +/** + * Anteil am Regelsatz für weitere Personen im Haushalt + * ``kind_unter_7_oder_mehr`` gibt Mehrbedarf AE bei mind. einem Kind unter 7 Jahren + * oder zwei oder drei Kindern unter 16 Jahre an. ``min_1_kind`` gibt den Mehrbedarf + * an wenn der Anspruch größer ist als der für den ersten Schlüssel. ``max`` gibt + * den Maximalanteil für den Mehrbedarf für Alleinerziehende gemessen am + * maßgebenden Regelbedarf. + * § 21 (3) Nr. 1 SGB II. + * reference_period: Month + */ +public const mehrbedarfAnteil: Dict { + // Reference: G. v. 24.12.2003 BGBl. I S. 2954. + from 2005-01-01 = { + min_1_kind: 0.12, + kind_unter_7_oder_mehr: 0.36, + max: 0.6 + } +} + +/** + * Maximaler Vermögensgrundfreibetrag + * § 12 (2) Satz 1 Nr. 1 SGB II. Ausnahmeregelung für Personen, + * die vor 1948 geboren wurden. Die Ausnahmeregelung taucht im aktuellen Gesetz nicht + * mehr auf und ist nicht mehr relevant, + * da alle betroffenen Personen zu alt für ALG 2 sind. + */ + def vermögensGrundfreibetragObergrenze: Dict { + // Reference: Artikel 1 G. v. 23.12.2002 BGBl. I S. 4607. + from 2005-01-01 = { + 1947: 33800, + 1948: 13000, + 1958: 13000, + 1964: 13000 + } + + // Reference: Artikel 1 G. v. 20.07.2006 BGBl. I S. 1706. + from 2006-08-01 = { + 1947: 33800, + 1948: 9750, + 1958: 9750, + 1964: 9750 + } + + // Reference: Artikel 1 G. v. 20.04.2007 BGBl. I S. 554. + from 2008-01-01 = { + 1947: 33800, + 1948: 9750, + 1958: 9900, + 1964: 10050 + } + + // Reference: G. v. 20.12.2022 BGBl. I S. 2328. (Bürgergeld-Gesetz) + from 2023-01-01 = { + 1947: null, + 1948: null, + 1958: null, + 1964: null + } + } + +/** + * Schonvermögen beim Bürgergeld + * Seit der Einführung des Bürgergelds zum 01.01.2023 gilt ein Vermögensfreibetrag + * von 15.000 Euro pro Mitglied der Bedarfsgemeinschaft nach Ablauf der Karenzzeit + * von einem Jahr. Während der Karenzzeit ist ein Vermögen von 40.000 Euro für die + * erste Person einer Bedarfsgemeinschaft und 15.000 Euro für jede weitere erlaubt. + */ + const schonvermoegenBuergergeld: Dict { + // Reference: G. v. 20.12.2022 BGBl. I S. 2328. (Bürgergeld-Gesetz) + from 2023-01-01 = { + während_karenzzeit: 40000, + normaler_satz: 15000 + } + } + +/** + * Vermögensfreibetrag für Erstausstattung + * § 12 (2) Satz 1 Nr. 4 SGB II. + */ +const vermoegensfreibetragAusstattung: Int { + // Reference: Artikel 1 G. v. 24.12.2003 BGBl. I S. 2954. + from 2005-01-01 = 750; + + // Reference: G. v. 20.12.2022 BGBl. I S. 2328. (Bürgergeld-Gesetz) + from 2023-01-01 = null; +} + +/** + * Vermögensgrundfreibetrag je Kind + * § 12 (2) Satz 1 Nr. 1 SGB II. + */ +const vermoegensfreibetragKind: Int { + // Reference: Artikel 1 G. v. 24.12.2003 BGBl. I S. 2954. + from 2005-01-01 = 4100; + + // Reference: Artikel 1 G. v. 20.07.2006 BGBl. I S. 1706. + from 2006-08-01 = 3100; + + // Reference: G. v. 20.12.2022 BGBl. I S. 2328. (Bürgergeld-Gesetz) + from 2023-01-01 = null; +} + +/** + * Altersgrenzen für Vermögensfreibetrag + * Vermögensfreibetrag ändert sich nach Geburtsjahr + */ +const vermoegensfreibetragAlter: Dict { + 2005-01-01: { + 1: 1948, + 2: 1958, + 3: 1963 + } + + // Reference: G. v. 20.12.2022 BGBl. I S. 2328. (Bürgergeld-Gesetz) + 2023-01-01: { + 1: null, + 2: null, + 3: null + } +} + +/** + * Abzugsfähige Pauschalen für Werbungskosten und Versicherung + * § 6 (1) Nr. 3 a) ALG II-V. 2005-01.01 bis 2016-07-31. Betrag mit V. v. 26.07 + * .2016 BGBl. I S. 1858 entfallen. Wie entfallen? + * § 3 Alg II-V. Seit 01.01.2008 in § 6 Alg II-V. + */ +const abzugfaehigePauschale: Dict { + // Reference: V. v. 20.10.2004 BGBl. I S. 2622 + from 2005-01-01 = { + werbung: 15.33, + versicherung: 30.0 + } + + // Reference: V. v. 21.06.2011 BGBl. I S. 1175. + from 2011-01-01 = { + werbung: 15.33, + versicherung: 30.0 + } +} + +/** + * Obergenze Miete pro Quadratmeter + * Die Miete pro Quadratmeter darf einen angemessenen Betrag nicht übersteigen, um + * für ALG2 berechtigt zu sein. Diese Grenze ist nicht konkret im Gesetz + * festgehalten, sondern wird als Faustregel von den Arbeitsargenturen verwendet. + * § 22 SGB II + * unit: Euro / Quadratmeter + */ +const maxMieteProQuadratMeter: Int { + from 1984-01-01 = 10 +} + +/** + * Berechtigte Miet-Wohnfläche für ALG2-Empfänger*innen + * Eine Mietwohnung darf für einen Single 45 Quadratmeter (+15 für jede weitere + * Person) groß sein. + */ +const berechtigteWohnflaecheMiete: Dict { + from 1984-01-01 = { + single: 45, + je_weitere_person: 15 + } +} + +/** + * Berechtigte Eigentumsfläche für ALG2-Empfänger*innen + * Vor 2023 gilt, dass Eigentum für zwei Personen im Haushalt 80 Quadratmeter (+20 + * für jede weitere Person) groß sein darf. Ab 2023 ist die erlaubte Größe für + * Eigenheime auf 140 Quadratmeter (für Eigentumswohnungen aus 130 Quadratmeter) + * gestiegen und wird ab 5 Personen im Haushalt um 20 Quadratmeter pro Person + * angehoben. + */ +const berechtigteWohnflaecheEigentum: Dict { + from 1984-01-01 = { + 1: 80, + 2: 80, + 3: 100, + 4: 120, + je_weitere_person: 20 + } + + // Reference: Art. 1 Nr.12 Abschnitt 5, G. v. 20.12.2022 BGBl. I S. 2328 + from 2023-01-01 = { + 1: 140, + 2: 140, + 3: 140, + 4: 140, + je_weitere_person: 20 + } +} diff --git a/src/resources/builtins/einkommenssteuer.ttsl b/src/resources/builtins/einkommenssteuer.ttsl new file mode 100644 index 00000000..75773812 --- /dev/null +++ b/src/resources/builtins/einkommenssteuer.ttsl @@ -0,0 +1,358 @@ +package einkommenssteuer + +// eink_st.yaml ---------------------------------------------------------- + +/** + * Einkommenssteuer Tarif + * §32a EStG + * Der quadratische Anstieg in den mittleren Intervallen wird nach der Formel + * des Progressionsfaktors berechnet. Einzelheiten sind im docstring der Funktion + * add_progressionsfaktor beschrieben. + */ +const einkommenssteuerTarif: Dict> { + + // TODO: klären wie das mit deviation_from aussieht + + + from 2002-01-01 = { + 0: { + lower_threshold: -inf, + upper_threshold: 7235, + rate_linear: 0, + rate_quadratic: 0, + intercept_at_lower_threshold: 0 + }, + 1: { + upper_threshold: 9251, + rate_linear: 0.199 + }, + 2: { + upper_threshold: 55007, + rate_linear: 0.23 + }, + 3: { + upper_threshold: inf, + rate_linear: 0.485, + rate_quadratic: 0 + } + } + + from 2004-01-01 = { + 0: { + lower_threshold: -inf, + upper_threshold: 7664, + rate_linear: 0, + intercept_at_lower_threshold: 0 + }, + 1: { + upper_threshold: 12739, + rate_linear: 0.16 + }, + 2: { + upper_threshold: 52151, + rate_linear: 0.2405 + }, + 3: { + upper_threshold: inf, + rate_linear: 0.45, + rate_quadratic: 0 + } + } + + from 2005-01-01 = { + 0: { + lower_threshold: -inf, + upper_threshold: 7664, + rate_linear: 0, + rate_quadratic: 0, + intercept_at_lower_threshold: 0 + }, + 1: { + upper_threshold: 12739, + rate_linear: 0.15 + }, + 2: { + upper_threshold: 52151, + rate_linear: 0.2397 + }, + 3: { + upper_threshold: inf, + rate_linear: 0.42, + rate_quadratic: 0 + } + } + + from 2007-01-01 = { + 0: { + lower_threshold: -inf, + upper_threshold: 7664, + rate_linear: 0, + rate_quadratic: 0, + intercept_at_lower_threshold: 0 + }, + 1: { + upper_threshold: 12739, + rate_linear: 0.15 + }, + 2: { + upper_threshold: 52151, + rate_linear: 0.2397 + }, + 3: { + upper_threshold: 250000, + rate_linear: 0.42, + rate_quadratic: 0 + }, + 4: { + upper_threshold: inf, + rate_linear: 0.45, + rate_quadratic: 0 + } + } + + from 2009-01-01 = { + // deviation_from: previous, + 0: { + upper_threshold: 7834 + }, + 1: { + upper_threshold: 13139, + rate_linear: 0.14 + }, + 2: { + upper_threshold: 52551 + }, + 3: { + upper_threshold: 250400 + } + } + + from 2010-01-01 = { + // deviation_from: previous, + 0: { + upper_threshold: 8004 + }, + 1: { + upper_threshold: 13469 + }, + 2: { + upper_threshold: 52881 + }, + 3: { + upper_threshold: 250730 + } + } + + from 2013-01-01 = { + // deviation_from: previous, + 0: { + upper_threshold: 8130 + } + } + + from 2014-01-01 = { + // Reference: G. v. 20.2.2013, BGBl I S.283 + // deviation_from: previous, + 0: { + upper_threshold: 8354 + } + } + + from 2015-07-01 = { + // Reference: G. v. 15.07.2015, BGBl. Nr. 30 2015 + // deviation_from: previous, + 0: { + upper_threshold: 8472 + } + } + + from 2016-01-01 = { + // Reference: G. v. 15.07.2015, BGBl. Nr. 30 2015 + // deviation_from: previous, + 0: { + upper_threshold: 8652 + }, + 1: { + upper_threshold: 13669 + }, + 2: { + upper_threshold: 53665 + }, + 3: { + upper_threshold: 254446 + } + } + + from 2017-01-01 = { + // Reference: Artikel 8 G. v. 20.12.2016, BGBl I S. 3000 + // deviation_from: previous, + 0: { + upper_threshold: 8820 + }, + 1: { + upper_threshold: 13769 + }, + 2: { + upper_threshold: 54057 + }, + 3: { + upper_threshold: 256303 + } + } + + from 2018-01-01 = { + // Reference: Artikel 9 G. v 23.12.2016, BGBL I, S. 3000 + // deviation_from: previous, + 0: { + upper_threshold: 9000 + }, + 1: { + upper_threshold: 13996 + }, + 2: { + upper_threshold: 54949 + }, + 3: { + upper_threshold: 260532 + } + } + + from 2019-01-01 = { + // deviation_from: previous, + 0: { + upper_threshold: 9169 + }, + 1: { + upper_threshold: 14255 + }, + 2: { + upper_threshold: 55961 + }, + 3: { + upper_threshold: 265327 + } + } + + from 2020-01-01 = { + // Reference: Art. 3 G. v. 29.11.2018 BGBl. I S. 2210 + // deviation_from: previous, + 0: { + upper_threshold: 9408 + }, + 1: { + upper_threshold: 14532 + }, + 2: { + upper_threshold: 57051 + }, + 3: { + upper_threshold: 270501 + } + } + + from 2021-01-01 = { + // Reference: Art. 1 G. v. 01.12.2020 BGBl. I S. 2616 + // deviation_from: previous, + 0: { + upper_threshold: 9744 + }, + 1: { + upper_threshold: 14753 + }, + 2: { + upper_threshold: 57918 + }, + 3: { + upper_threshold: 274613 + } + } + + from 2022-01-01 = { + // Reference: Art. 1 G. v. 23.05.2022 BGBl. I S. 749 + // deviation_from: previous, + 0: { + upper_threshold: 10347 + }, + 1: { + upper_threshold: 14926 + }, + 2: { + upper_threshold: 58596 + }, + 3: { + upper_threshold: 277826 + } + } + + from 2023-01-01 = { + // Reference: Art. 2 G. v. 08.12.2022 BGBl. I S. 2230., + // deviation_from: previous + 0: { + upper_threshold: 10909 + }, + 1: { + upper_threshold: 16000 + }, + 2: { + upper_threshold: 62810 + }, + 3: { + upper_threshold: 277826 + } + } + + from 2024-01-01 = { + // Reference: Art. 3 G. v. 08.12.2022 BGBl. I S. 2230. + deviation_from: previous, + 0: { + upper_threshold: 11605 + }, + 1: { + upper_threshold: 17006 + }, + 2: { + upper_threshold: 66761 + }, + 3: { + upper_threshold: 277826 + } + } +} + +/** + * Ertragsanteil-Funktion für den Anteil an sozialversicherungspflichtigen + * Renteneinkommen, der versteuert werden muss (piecewise linear) + * § 22 EStG + * Diese Funktion ist hier ab 2002 angegeben. Vor 2002 das Steuersystem ist nicht + * implementiert. + */ +const renteErtragsanteil: Dict> { + from 2002-01-01 = { + 0: { + lower_threshold: -inf, + upper_threshold: 2005, + rate_linear: 0, + intercept_at_lower_threshold: 0.27 + }, + 1: { + lower_threshold: 2005, + upper_threshold: 2021, + rate_linear: 0.02, + intercept_at_lower_threshold: 0.5 + }, + 2: { + lower_threshold: 2021, + upper_threshold: 2041, + rate_linear: 0.01, + intercept_at_lower_threshold: 0.8 + }, + 3: { + lower_threshold: 2041, + upper_threshold: inf, + rate_linear: 0.0, + intercept_at_lower_threshold: 1 + } + } +} + +// TODO: rounding diff --git a/src/resources/builtins/einkommenssteuerAbzuege.ttsl b/src/resources/builtins/einkommenssteuerAbzuege.ttsl new file mode 100644 index 00000000..05cec07a --- /dev/null +++ b/src/resources/builtins/einkommenssteuerAbzuege.ttsl @@ -0,0 +1,612 @@ +pacakge einkommenssteuerAbzuege + +// eink_st_abzuege.yaml -------------------------------------------------- + +/** + * Kinderfreibetrag + * sächliches Existenzminimum des Kindes, seit 2000 auch der Freibetrag für + * Betreuungs-, Erziehungs- und Ausbildungskosten. Wird verdoppelt für gemeinsam + * veranlagte Paare. §32 (6) EStG, seit 2000. + * Pro Jahr + */ +const einkommensSteuerKinderFreibetrag: Dict { + // Reference: Art. 1 G. v. 23.12.1982 BGBl. I S. 1857. + from 1983-01-01 = { + saechlichesExistenzminimum: 110 + } + + // Reference: Art. 1 G. v. 26.06.1985 BGBl. I S. 1153. + from 1986-01-01 = { + saechlichesExistenzminimum: 635 + } + + // Reference: Artikel 1 G. v. 25.07.1988 BGBl. I S. 1093. + from 1990-01-01 = { + saechlichesExistenzminimum: 773 + } + + // Reference: Art. 1 G. v. 25.02.1992 BGBl. I S. 297. + from 1992-01-01 = { + saechlichesExistenzminimum: 1049 + } + + // Reference: Art. 1. G. v. 11.10.1995 BGBl. I S. 1250. + from 1996-01-01 = { + saechlichesExistenzminimum: 1601 + } + + from 1997-01-01 = { + saechlichesExistenzminimum: 1767 + } + + // Reference: Art. 1 G. v. 28.12.1999 BGBl. I. S. 2552. + from 2000-01-01 = { + beitragErziehungAusbildung: 774, + saechlichesExistenzminimum: 1767 + } + + // Reference: Art. 1 G. v. 16.08.2001 BGBl. I S. 2074 + from 2002-01-01 = { + beitragErziehungAusbildung: 1080, + saechlichesExistenzminimum: 1824 + } + + // Reference: Art. 1 G. v. 22.12.2008 BGBl. I S. 2955 + from 2009-01-01 = { + beitragErziehungAusbildung: 1080, // previous + saechlichesExistenzminimum: 1932 + } + + // Reference: Art. 1 G. v. 22.12.2009 BGBl. I S. 3950 + from 2010-01-01 = { + beitragErziehungAusbildung: 1320, + saechlichesExistenzminimum: 2184 + } + + // Reference: Art. 1 G. v. 16.07.2015 BGBl. I S. 1202 + from 2015-01-01 = { + beitragErziehungAusbildung: 1320, // previous + saechlichesExistenzminimum: 2256 + } + + // Reference: Art. 2 G. v. 16.07.2015 BGBl. I S. 1202 + from 2016-01-01 = { + beitragErziehungAusbildung: 1320, // previous + saechlichesExistenzminimum: 2304 + } + + // Reference: Art. 8 G. v. 20.12.2016 BGBl. I. S. 3000 + from 2017-01-01 = { + beitragErziehungAusbildung: 1320, // previous + saechlichesExistenzminimum: 2358 + } + + // Reference: Art. 9 G. v. 20.12.2016 BGBl. I. S. 3000 + from 2018-01-01 = { + beitragErziehungAusbildung: 1320, // previous + saechlichesExistenzminimum: 2394 + } + + // Reference: Art. 1 G. v. 29.11.2018 BGBl. I S. 2210 + from 2019-01-01 = { + beitragErziehungAusbildung: 1320, // previous + saechlichesExistenzminimum: 2490 + } + + // Reference: Art. 3 G. v. 29.11.2018 BGBl. I S. 2210 + from 2020-01-01 = { + beitragErziehungAusbildung: 1320, // previous + saechlichesExistenzminimum: 2586 + } + + // Reference: Art. 1 G. v. 01.12.2020 BGBl. I S. 2616 + from 2021-01-01 = { + saechlichesExistenzminimum: 2730, + beitr_erz_ausb: 1464 + } + + // Reference: Art. 1 G. v. 08.12.2022 BGBl. I S. 2230. + from 2022-01-01 = { + beitragErziehungAusbildung: 2730, // previous + saechlichesExistenzminimum: 2810 + } + + // Reference: Art. 2 G. v. 08.12.2022 BGBl. I S. 2230. + from 2023-01-01 = { + beitragErziehungAusbildung: 2730, // previous + saechlichesExistenzminimum: 3012 + } + + // Reference: Art. 3 G. v. 08.12.2022 BGBl. I S. 2230. + from 2024-01-01 = { + beitragErziehungAusbildung: 2730, // previous + saechlichesExistenzminimum: 3192 + } +} + +/** + * Vorwegabzug der Vorsorgeaufwendungen der Rechtslage vor 2004. + * § 10 (4a) EStG. Früher §10 (3) EStG. Hier steht jeweils der Wert für den + * Steuerpflichtigen. Wird verdoppelt für gemeinsam veranlagte Ehegatten. Der gesamte + * Zeitverlauf wurde bereits 2005 festgelegt. + */ +const vorsorge2004Vorwegabzug: Int { + from 1985-01-01 = 1534 + from 1989-01-01 = 2045 + from 1993-01-01 = 3068 + from 2011-01-01 = 2700 + from 2012-01-01 = 2400 + from 2013-01-01 = 2100 + from 2014-01-01 = 1800 + from 2015-01-01 = 1500 + from 2016-01-01 = 1200 + from 2017-01-01 = 900 + from 2018-01-01 = 600 + from 2019-01-01 = 300 +} + +/** + * Werbungskostenpauschbetrag bei nichtselbstständiger Arbeit. + * § 9a Nr. 1a) EStG + * This is the minimum amount deducted from any employment income. + */ +const werbungskostenpauschbetrag: Int { + from 1975-01-01 = 288 + from 1990-01-01 = 1044 + from 2004-01-01 = 920 + + // Reference: Art. 1 G. v. 01.11.2011 BGBl. I S. 2131. + from 2012-01-01 = 1000 + + // Reference: Art. 2 G. v. 23.05.2022 BGBl. I S. 749 + from 2022-01-01 = 1200 + + // Reference: G. v. 20.12.2022 BGBl. I S. 2294. + from 2023-01-01 = 1230 +} + +/** + * Sonderausgaben-Pauschbetrag + * § 10c EStG + */ +const sonderausgabenpauschbetrag: Int { + from 1984-01-01 = 138 + + // Reference: Art. 1 G. v. 25.07.1988, BGBl. I S. 1093 + from 1988-01-01 = 55 + + // Reference: Art. 1 G. v. 19.12.2000, BGBl. I S. 1790 + from 2002-01-01 = 36 +} + +/** + * Sparerpauschbetrag + * § 20 (9) EStG. Früher § 20 (4) EStG. Wert für Singles. Wird verdoppelt für + * gemeinsam veranlagte. seit 2009. vor 2008 Sparerfreibetrag. + */ +const sparerpauschbetrag: Int { + from 1975-01-01 = 153 + from 1990-01-01 = 307 + from 1993-01-01 = 3068 + from 2000-01-01 = 1534 + + // Reference: Art. 1 G. v. 19.12.2000 BGBl I S. 1790. + from 2002-01-01 = 1550 + from 2004-01-01 = 1370 + from 2007-01-01 = 750 + + // Reference: Art. 1 G. v. 14.08.2007 BGBl. I S. 1912 + from 2009-01-01 = 801 + + // Reference: G. v. 20.12.2022 BGBl. I S. 2294. + from 2023-01-01 = 1000 +} + +/** + * Sparerpauschbetrag + * § 20 (9) EStG. Früher § 20 (4) EStG. Wert für Singles. Wird verdoppelt für + * gemeinsam veranlagte. seit 2009. vor 2008 Sparerfreibetrag. + */ +const sparerWerbungskostenPauschbetrag: Int { + from 1975-01-01 = 51 + from 2009-01-01 = 0 +} + +/** + * Allgemeine Vorsorgepauschale Grundhöchstbetrag, Grundtabelle + * §10 (3) EStG bis 2004. + */ +const vorsorge2004Grundhoechstbetrag: Int { + from 1985-01-01 = 1196 + from 1992-01-01 = 1334 +} + +/** + * Höchstbetrag des Altersentlastungsbetrags + * 24a EStG S. 5. Tabelle legt die Werte bis 2040 fest. Bis 2004 erhalten alle + * Steuerpflichtigen, die im voherigen Kalenderjahr das 64. Lebensjahr vollendet + * haben, maximal den gleichen Altersentlastungsbetrag. Ab 2005 hängt dieser Betrag, + * den diese Steuerpflichtigen erhalten, vom Geburtsjahr ab. + */ +const altersentlastungsbetragMax: Int | Dict { + from 1984-01-01 = 1534 + from 1989-01-01 = 1902 + from 2002-01-01 = 1908 + + // Reference: Artikel 1 G. v. 05.07.2004 BGBl. I S. 1427. + 2005-01-01 = { + 1940: 1900, + 1941: 1824, + 1942: 1748, + 1943: 1672, + 1944: 1596, + 1945: 1520, + 1946: 1444, + 1947: 1368, + 1948: 1292, + 1949: 1216, + 1950: 1140, + 1951: 1064, + 1952: 988, + 1953: 912, + 1954: 836, + 1955: 760, + 1956: 722, + 1957: 684, + 1958: 646, + 1959: 608, + 1960: 570, + 1961: 532, + 1962: 494, + 1963: 456, + 1964: 418, + 1965: 380, + 1966: 342, + 1967: 304, + 1968: 266, + 1969: 228, + 1970: 190, + 1971: 152, + 1972: 114, + 1973: 76, + 1974: 38, + 1975: 0 + } +} + +/** + * Anteil des Altersentlastungsbetrags + * §24a EStG S.5. Tabelle legt alle Werte bis 2040 fest. Bis 2004 wird bei allen + * Steuerpflichtigen, die im voherigen Kalenderjahr das 64. Lebensjahr vollendet + * haben, die gleiche Altersentlastungsquote abgezogen. Ab 2005 hängt diese Quote, + * den diese Steuerpflichtigen erhalten, vom Geburtsjahr ab. + */ +const altersentlastungQuote: Float | Dict { + from 1984-01-01 = 0.4 + + // Reference: Artikel 1 G. v. 05.07.2004 BGBl. I S. 1427. + 2005-01-01 = { + 1940: 0.4, + 1941: 0.384, + 1942: 0.368, + 1943: 0.352, + 1944: 0.336, + 1945: 0.32, + 1946: 0.304, + 1947: 0.288, + 1948: 0.272, + 1949: 0.256, + 1950: 0.24, + 1951: 0.224, + 1952: 0.208, + 1953: 0.192, + 1954: 0.176, + 1955: 0.16, + 1956: 0.152, + 1957: 0.144, + 1958: 0.136, + 1959: 0.128, + 1960: 0.12, + 1961: 0.112, + 1962: 0.104, + 1963: 0.096, + 1964: 0.088, + 1965: 0.08, + 1966: 0.072, + 1967: 0.064, + 1968: 0.056, + 1969: 0.048, + 1970: 0.04, + 1971: 0.032, + 1972: 0.024, + 1973: 0.016, + 1974: 0.008, + 1975: 0 + } +} + +/** + * Altersgrenze für Altersentlastungsbetrag + * Der Altersentlastungsbetrag wird einem Steuerpflichtigen gewährt, der vor dem + * Beginn des Kalenderjahres, in dem er sein Einkommen bezogen hat, das 64. + * Lebensjahr vollendet hatte. + * Reference: § 24a Art. 3 EStG + */ +const altersentlastungsbetragAltersgrenze: Int { + from 1984-01-01 = 64 +} + +/** + * Einführungsfaktor für Altersvorsorge Aufwendung + * In den Jahren 2005-2022 stieg der Anteil der abzugsfähigen Beiträge von 60% in + * 2005 jährlich um 2 Prozentpunkte an bis 94% in 2022 erreicht wurden. Eigentlich + * war geplant, dass der Parameter weiter mit dieser Rate steigt, bis ab 2025 100% + * erreicht sind. Abweichend von diesem Plan, wurden die abzugfähigen Beiträge schon + * 2023 auf 100% gesetzt. + * Reference: § 10 Abs. 1 Nr. 2 Buchst. a und b EStG + */ +const einfuehrungsfaktor: { + from 2005-01-01 = { + 0: {lower_threshold: -inf, rate_linear: 0, intercept_at_lower_threshold: 0.6}, + 1: {lower_threshold: 2005, upper_threshold: 2025, rate_linear: 0.02}, + 2: {upper_threshold: inf, rate_linear: 0} + } + + // Reference: G. v. 20.12.2022 BGBl. I S. 2294. + from 2023-01-01 = { + 0: {lower_threshold: -inf, rate_linear: 0, intercept_at_lower_threshold: 0.6}, + 1: {lower_threshold: 2005, rate_linear: 0.02}, + 2: {lower_threshold: 2022, upper_threshold: 2023, rate_linear: 0.06}, + 3: {upper_threshold: inf, rate_linear: 0} + } +} + +/** + * Entlastungsbetrag für Alleinerziehende + * § 24b (1) EStG. vor 2004 "Haushaltsfreibetrag", § 32 (7) EStG + */ +const alleinerzFreibetrag: Int { + from 1984-01-01 = 2154 + from 1986-01-01 = 2319 + from 1989-01-01 = 2871 + from 2001-01-01 = 2916 + from 2002-01-01 = 2340 + from 2004-01-01 = 1308 + + // Reference: Art. 1 G. v. 16.07.2015 BGBl. I S.1202 + from 2015-01-01 = 1908 + + // Reference: Art. 3 Nr. 2 G. v. 29.12.2020 BGBl. I S.3096 + from 2020-01-01 = 4008 + + // Reference: G. v. 20.12.2022 BGBl. I S. 2294. + from 2023-01-01 = 4260 +} + +/** + * Entlastungsbetrag für Alleinerziehende, Zusatzbetrag + * §24b (2) S. 2 EStG. Alleinerziehenden-Entlastungsbetrag, Zusatzbetrag pro Kind ab + * dem 2. Kind. + */ +const alleinerzFreibetragZusatz: Int { + // Reference: Art. 1 G. vs. 16.07.2015 BGBl. I S.1202 + from 2015-01-01 = 240 +} + +/** + * Kürzung des Vorwegabzugs für Vorsorgeaufwendungen vor 2004. + * §10 (3) S. 2 EStG (vor 2004). Der Vorwegabzug wird pauschal um einen Anteil + * gekürzt bei abhängig Beschäftigten (vereinfacht). + */ +const vorsorge2004KuerzungVorwegabzug: Float { + from 1985-01-01 = 0.0935 + from 1986-01-01 = 0.096 + from 1987-01-01 = 0.0935 + + // Reference: Art. 1 G. v. 25.07.1988 BGBl. I S. 1093 + from 1989-01-01 = 0.12 + + // Reference: Art. 1 G. v. 21.12.1993 BGBl. I S. 2310. + from 1994-01-01 = 0.16 +} + +/** + * Regulärer Maximalbetrag für sonstige Vorsorgeaufwendungen (Kranken-, Pflege, + * AL-V), der für sozialverspfl. Beschäftigte gilt. + * §10 Abs. 4 S.1 EStG + */ +const vorsorgeSonstigeAufwendungenMax: Int { + // Reference: Art. 1 G. v. 05.07.2004 BGBl. I S.1427 + from 2005-01-01 = 1500 + + // Reference: Art. 1 G. v. 23.07.2009 BGBl. I S.1959. + from 2010-01-01 = 1900 +} + +/** + * Maximalbetrag der Altersvorsorgeaufwendungen, 2005er Rechtsstand + * §10 (3) EStG, Anlage 2 SGB VI + */ +const vorsorgeAltersvorsorgeaufwendungenMax: Int { + // Art. 1 G. v. 05.07.2004 BGBl. I S.1427 + from 2005-01-01 = 20000 + + // Ab 2015 knappschaftlicher Höchstbetrag, d.h. knappschaftlicher Beitragssatz * + // knappschaftliche Beitragsbemessungsgrenze + from 2015-01-01 = 22170 + + // .248 * 91800 + from 2016-01-01 = 22766 + + // .247 * 94200 + from 2017-01-01 = 23362 + + // .247 * 96000 + from 2018-01-01 = 23712 + + // .247 * 98400 + from 2019-01-01 = 24305 + + // .247 * 101400 + // Reference: Art. 3 V. v. 17.12.2019 BGBl I S. 2848. + from 2020-01-01 = 25046 + + // .247 * 104400 + // Reference: §3 V. v. 30.11.2020 BGBl. I S. 2612. + from 2021-01-01 = 25787 + + // .247 * 103800 + // Reference: §3 V. v. 30.11.2021, BGBl. I S. 5044. + from 2022-01-01 = 25640 +} + +/** + * Anteil, um den Krankenversicherungsbeiträge gemindert werden bei abhängig + * Beschäftigten. + * §10 (3) a) S.4 EStG + */ +const vorsorgeKrankenMinderung: Float { + // Reference: Art. 1 G. v. 16.07.2009 BGBl. I S. 1959 + from 2009-07-23 = 0.04 +} + +/** + * Behinderten-Pauschbetrag, in Abhängigkeit des Behinderungsgrads. + * § 33b (3) EStG. + */ +const behindertenPauschbetrag: Dict { + // Reference: G. v. 05.08.1974 BGBl. I S. 1769. + from 1975-01-01 = { + 0: 0, + 25: 307, + 35: 429, + 45: 568, + 55: 721, + 65: 890, + 75: 1058, + 85: 1227, + 95: 1411 + } + + // Reference: Art. 1 G. v. 19.12.2000 BGBl. I S. 1790. + from 2002-01-01 = { + 0: 0, + 25: 310, + 35: 430, + 45: 570, + 55: 720, + 65: 890, + 75: 1060, + 85: 1230, + 95: 1420 + } + + // Reference: Art. 1 G. v. 09.12.2020 BGBL. I S. 2770. + from 2021-01-01 = { + 0: 0, + 20: 384, + 30: 620, + 40: 860, + 50: 1140, + 60: 1440, + 70: 1780, + 80: 2120, + 90: 2460, + 100: 2840 + } +} + +/** + * Anteil der Betreuungsaufwendungen, der auf das zu versteuernde Einkommen + * anrechenbar ist + * §10 (1) Nr. 5 EStG + */ +const kinderbetreuungskostenAbzAnteil: Float { + // Reference: Art. 1 G. v. 01.11.2011 BGBl. I S.2131 + from 2012-01-01 = 0.6666666 +} + +/** + * Maximal abziehbare Betreuungsaufwendungen pro Kind + * §10 (1) Nr. 5 EStG + */ +const kinderbetreuungskostenAbzMaximum: Int { + // Reference: Art. 1 G. v. 01.11.2011 BGBl. I S.2131 + from 2012-01-01 = 4000 +} + +/** + * Anteil abgezogene Rentenversicherungsbeiträge + * §10 (3) a) S.4 EStG + */ +const vorsorgepauschaleRentenversicherungsAnteil: Dict> { + 2005-01-01 = { + 0: { + lower_threshold: -inf, + upper_threshold: 2005, + rate_linear: 0, + intercept_at_lower_threshold: 0.2 + }, + 1: { + lower_threshold: 2005, + upper_threshold: 2025, + rate_linear: 0.04, + intercept_at_lower_threshold: 0.2 + }, + 2: { + lower_threshold: 2025, + upper_threshold: inf, + rate_linear: 0, + intercept_at_lower_threshold: 1 + } + } + + 2023-01-01 = { + 0: { + lower_threshold: -inf, + rate_linear: 0, + intercept_at_lower_threshold: 0.2 + }, + 1: { + lower_threshold: 2005, + rate_linear: 0.04 + }, + 2: { + lower_threshold: 2022, + upper_threshold: 2023, + rate_linear: 0.12 + }, + 3: { + lower_threshold: 2023, + upper_threshold: inf, + rate_linear: 0 + } + } +} + +/** + * Mindestanteil für Mindestvorsorgepauschale + * Mindestanteil an Beiträgen zu GKV und GPV, der abgesetzt wird bei + * Mindestvorsorgepauschale + * Reference: 39b (2) Nr.3 EStG + */ +const vorsorgepauschaleMindestanteil: Float { + // Reference: Art. 1 G. v. 16.07.2009 BGBl. I S. 1959 + from 2009-07-23 = 0.12 +} + +/** + * Höchstbetrag Mindestvorsorgepauschale + * Höchsbetrag für Mindestvorsorgepauschale der Beiträge zu GKV und PKV, die von der + * Lohnsteuer abgesetzt werden können. + * Reference: 39b (2) Nr.3 EStG. Depends on Steuerklasse. + */ +const vorsorgepauschaleKvMax: Dict { + // Reference: Art. 1 G. v. 16.07.2009 BGBl. I S. 1959 + from 2009-07-23 = { + steuerklasse_3: 3000, + steuerklasse_nicht3: 1900 + } +} + +// TODO: rounding diff --git a/src/resources/builtins/elterngeld.ttsl b/src/resources/builtins/elterngeld.ttsl new file mode 100644 index 00000000..daba589e --- /dev/null +++ b/src/resources/builtins/elterngeld.ttsl @@ -0,0 +1,144 @@ +package elterngeld + +// elterngeld.yaml ------------------------------------------------------- + +/** + * Faktor bei der ElG-Berechung, 2. Stufe + * § 2 (1) BEEG + */ +const elterngeldFaktor: Float { + from 2007-01-01 = 0.67 +} + +/** + * Höchstbetrag des Elterngeldes + * § 2 (1) BEEG + */ +const elterngeldHoechstbetrag: Int { + from 2007-01-01 = 1800 +} + +/** + * Nettoeinkommen an 1. und 2. Stufe + * § 2 (2) BEEG. Maßgeblich ist das durchschnittlich erzielte monatliche Einkommen + * vor der Geburt + */ +const elterngeldNettoeinkommenStufen: Dict { + // Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 + from 2007-01-01 = { + 1: 1000, + 2: 1001 + } + + // Reference: Art. 14 G. v. 09.12.2010 BGBl. I S. 1885 + from 2011-01-01 = { + 1: 1000, + 2: 1201 + } +} + +/** + * Mindestbetrag des Elterngeldes + * § 2 (5) BEEG + */ +const elterngeldMindestbetrag: Int { + // Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 + from 2007-01-01 = 300 +} + +/** + * Korrektur des Prozentsatzes für hohe und niedrige Einkommen + * § 2 (2) BEEG + */ +const elterngeldProzentKorrektur: Float { + // Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 + from 2007-01-01 = 0.001 +} + +/** + * Minimaler Anteil des Elterngelds am vorherigen Nettoeinkommen + * § 2 (2) BEEG + */ +const elterngeldProzentMinimum: Float { + from 2007-01-01 = 0.67 + + // Reference: Art. 14 G. v. 09.12.2010 BGBl. I S. 1885 + from 2011-01-01 = 0.65 +} + +/** + * Einkommensschritte für die Korrektur + * § 2 (2) BEEG + */ +const elterngeldEinkommensSchrittKorrektur: Int { + // Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 + from 2007-01-01 = 2 +} + +/** + * Altersgrenzen für Geschwisterbonus + * Leben im Haushalt zwei Kinder unter 3 Jahren oder mehr als zwei unter 6 Jahren + * wird das Elterngeld um 10% (max. um 75€) erhöht. + * Reference: § 2a BEEG + */ +const elterngeldGeschwisterbonusAltersgrenzenKinder: Dict { + from 2007-01-01 = { + 3: 2, + 6: 3 + } +} + +/** + * Geschwisterbonus als prozentualer Aufschlag + * § 2a (1) BEEG. Früher § 2 (4) BEEG + */ +const elterngeldGeschwisterbonusAufschlag: Float { + // Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 + from 2007-01-01 = 0.1 +} + +/** + * Minimaler Geschwisterbonus als Euro-Betrag + * § 2a (1) BEEG. Früher §2 (4) BEEG + */ +const elterngeldGeschwisterbonusMinimum: Int { + // Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 + from 2007-01-01 = 75 +} + +/** + * Pauschale für jedes weitere Mehrlingskind + * § 2a (4) BEEG, früher §2 (6) BEEG. + * pro Monat + */ +const elterngeldMehrlingbonus: Int { + // Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 + from 2007-01-01 = 300 +} + +/** + * Sozialversicherungspauschale zur Berechnung des Nettoeinkommens + * §2f BEEG. Vor 2012 waren es die eigentlichen Pflichtbeiträge. + */ +const elterngeldSozialversicherungspauschale: Float { + // Reference: Art. 1 G. v. 10.09.2012 BGBl. I S. 1878 + from 2012-09-18 = 0.21 +} + +/** + * Maximale Anzahl an Monaten, in denen ein Paar Elterngeld erhält + * § 4 (3) BEEG + */ +const elterngeldMaxMonatePaar: Int { + // Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 + from 2007-01-01 = 14 +} + +/** + * Maximale Anzahl an Monaten, die jedes Elternteil Elterngeld erhält + * § 4 (3) BEEG + */ +const elterngeldMaxMonateIndividuell: Int { + // Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 + from 2007-01-01 = 12 +} diff --git a/src/resources/builtins/erwerbsminderungsrente.ttsl b/src/resources/builtins/erwerbsminderungsrente.ttsl new file mode 100644 index 00000000..4b46d6ec --- /dev/null +++ b/src/resources/builtins/erwerbsminderungsrente.ttsl @@ -0,0 +1,152 @@ +package Erwerbsminderungsrente + +// erwerbsm_rente.yaml --------------------------------------------------- + +/** + * Regelaltersgrenze + * Altersgrenze bis zu der man die Erwerbsminderungsrente ohne Abzüge in + * Anspruch nehmen kann. Bis 2012 lag die Regelaltersgrenze bei 63. Ab dann + * schrittweise Anhebung bis 65. + * Reference: § 77 SGB VI Zugangsfaktor + * pro Jahr + */ +const abschlagsfreieAltersgrenze: Dict { + from 2001-01-01 = 63 + from 2012-01-01 = 63.083333 + from 2012-02-01 = 63.166666 + from 2012-03-01 = 63.25 + from 2012-04-01 = 63.333333 + from 2012-05-01 = 63.416666 + from 2012-06-01 = 63.5 + from 2013-01-01 = 63.583333 + from 2014-01-01 = 63.666666 + from 2015-01-01 = 63.75 + from 2016-01-01 = 63.833333 + from 2017-01-01 = 63.916666 + from 2018-01-01 = 64 + from 2019-01-01 = 64.166666 + from 2020-01-01 = 64.333333 + from 2021-01-01 = 64.5 + from 2022-01-01 = 64.666666 + from 2023-01-01 = 64.833333 + from 2024-01-01 = 65 +} + +/** + * Regelaltersgrenze für langjährige Versicherte + * Altersgrenze bis zu der man bestimmte zeitliche Bedingungen + * erfüllt. Bedingungen werden in § 77 Abs. 4 SGB VI definiert. + * Reference: § 77 Abs. 4 SGB VI Zugangsfaktor + * pro Jahr + */ +const regelaltersgrezeLangjaehrigeVersicherte: Dict { + from 2001-01-01 = 63 +} + +/** + * Wartezeitgrenze für abschlagsfreie Erwerbsminderungsrente + * Anzahl an Wartezeitjahren nach § 51 Absatz 3a SGB VI, die für eine abschlagsfreie + * Erwerbsminderungsrente mit 63 nachgewiesen werden müssen. + * Reference: § 264d SGB VI Zugangsfaktor + * pro Jahr + */ +const wartezeitgrenzeLangjaehrigeVersicherteAbschlagsfrei: Dict { + from 2001-01-01 = 35 + from 2024-01-01 = 40 +} + +/** + * Zurechnungszeitgrenze + * Altersgrenze für die Zurechnungszeit der Erwerbsminderungsrente. + * Anhebung von 2020 bis 2027 um 1 Monat pro Kalendarjahr und ab 2028 + * jeweils 2 Monate bis 67 erreicht ist. + * Reference: § 59 SGB VI Zurechnungszeit + * pro Jahr + */ +const zurechnungszeitgrenze: Dict { + from 2001-01-01 = 62.916666 + from 2001-02-01 = 62.833333 + from 2001-03-01 = 62.75 + from 2001-04-01 = 62.666666 + from 2001-05-01 = 62.583333 + from 2001-06-01 = 62.5 + from 2001-07-01 = 62.416666 + from 2001-08-01 = 62.333333 + from 2001-09-01 = 62.25 + from 2001-10-01 = 62.166666 + from 2001-11-01 = 62.083333 + from 2001-12-01 = 62 + from 2002-01-01 = 61.916666 + from 2002-02-01 = 61.833333 + from 2002-03-01 = 61.75 + from 2002-04-01 = 61.666666 + from 2002-05-01 = 61.583333 + from 2002-06-01 = 61.5 + from 2002-07-01 = 61.416666 + from 2002-08-01 = 61.333333 + from 2002-09-01 = 61.25 + from 2002-10-01 = 61.166666 + from 2002-11-01 = 61.083333 + from 2002-12-01 = 61 + from 2003-01-01 = 60.916666 + from 2003-02-01 = 60.833333 + from 2003-03-01 = 60.75 + from 2003-04-01 = 60.666666 + from 2003-05-01 = 60.583333 + from 2003-06-01 = 60.5 + from 2003-07-01 = 60.416666 + from 2003-08-01 = 60.333333 + from 2003-09-01 = 60.25 + from 2003-10-01 = 60.166666 + from 2003-11-01 = 60.083333 + from 2003-12-01 = 60 + from 2014-07-01 = 62 + from 2019-01-01 = 65.666666 + from 2020-01-01 = 65.75 + from 2021-01-01 = 65.833333 + from 2022-01-01 = 65.916666 + from 2023-01-01 = 66 + from 2024-01-01 = 66.083333 + from 2025-01-01 = 66.166666 + from 2026-01-01 = 66.25 + from 2027-01-01 = 66.333333 + from 2028-01-01 = 66.5 + from 2029-01-01 = 66.666666 + from 2030-01-01 = 66.833333 + from 2031-01-01 = 67 +} + +/** + * Kleinster möglicher Zugangsfaktor bei der Erwerbsminderungsrente + * Abzüge wegen frühzeitigem Eintritt in die Erwerbsminderungsrente + * sind bei 10.8% gedeckelt. + * Reference: § 77 SGB VI Zugangsfaktor + */ +const minZugangsfaktor: Dict { + from 2000-01-01 = 0.892 +} + +/** + * Rentenartfaktor für teilweise Erwerbsminderungsrente + * Der Rentenartfaktor ist ein festgelegter Faktor für die + * Rentenberechnung und bestimmt + * das Sicherungsziel der Rentenart im Verhältnis zu einer Altersrente. + * Reference: § 67 SGB VI Rentenartfaktor + */ +const rentenartfaktor: Dict { + from 2001-01-01 = { + teilw: 0.5, + voll: 1.0 + } +} + +/** + * Altersgrenze des belegungsfähigen Gesamtzeitraum + * Als Teil der Grundbewertung wird der belegungsfähige Gesamtzeitraum + * berechnet. Dieser entspricht dem Zeitraum vom 17. + * Lebensjahr bis zum Beginn der Rente + * Reference: SGB VI § 72: Grundbewertung + */ +const altersgrenzeGrundbewertung: Dict { + from 2001-01-01 = 16 +} diff --git a/src/resources/builtins/erziehungsgeld.ttsl b/src/resources/builtins/erziehungsgeld.ttsl new file mode 100644 index 00000000..6c3644b5 --- /dev/null +++ b/src/resources/builtins/erziehungsgeld.ttsl @@ -0,0 +1,98 @@ +package erziehungsgeld + +// erziehungsgeld.yaml --------------------------------------------------- + +/** + * Einkommensgrenze für abzugsfreies Erziehungsgeld + * Reference: Bundesgesetzblatt Jahrgang 2004 Teil I Nr. 6 (p.209) + */ +const erziehungsgeldEinkommensgrenze: Dict>> { + from 2004-02-09 = { + limit: { + alleinerz: { + regelsatz: 23000, + budgetsatz: 19086 + }, + paar: { + regelsatz: 30000, + budgetsatz: 22086 + } + }, + reduced_limit: { + alleinerz: { + regelsatz: 13500, + budgetsatz: 13500 + }, + paar: { + regelsatz: 16500, + budgetsatz: 16500 + } + } + } +} + +/** + * Erhöhung der Einkommensgrenze pro weiterem Kind + * Reference: Bundesgesetzblatt Jahrgang 2004 Teil I Nr. 6 (p.209) + */ +const erziehungsgeldAufschlagEinkommen: Dict { + from 2004-02-09 = 3140 +} + +/** + * Höhe des Erziehungsgeldes abhängig vom beantragtem Satz + * Reference: Bundesgesetzblatt Jahrgang 2004 Teil I Nr. 6 § 5 (p.208) + */ +const erziehungsgeldSatz: Dict { + from 2004-02-09 = { + regelsatz: 300, + budgetsatz: 450 + } +} + +/** + * Faktor zur Berechnung des Abschlag des Erziehungsgeld bei einer + * Überschreitung der Einkommensgrenze ab dem 7 Lebensmonat. + * Der Faktor wird mit dem relevanten Einkommen multipliziert und + * das Produkt entsprechend vom Erziehungsgeld Anspruch abgezogen + * Reference: Bundesgesetzblatt Jahrgang 2004 Teil I Nr. 6 + */ +const erziehungsgeldAbschlagFaktor: Float { + from 2004-02-09 = 0.052 +} + +/** + * Faktor um den das Einkommen pauschal reduziert wird um das das + * relevanten Einkommen zu berechnen + * Reference: Bundesgesetzblatt Jahrgang 2004 Teil I Nr. 6 § 6 (p.209) + */ +const erziehungsgeldPauschalAbzugAufEinkommen: Float { + from 2004-02-09 = 0.76 +} + +/** + * Grenze der wöchentlichen Arbeitsstunden bis zu der Erziehungsgeld ausgezahlt wird + * Reference: Bundesgesetzblatt Jahrgang 2004 Teil I Nr. 6 § 15 (p.211) + */ +const erziehungsgeldArbeitsstundenWoechentlicheGrenze: Int { + from 2004-02-09 = 30 +} + +/** + * Alter des Kindes in Monaten bis zu dem der Regelsatz bezogen werden kann. + * Reference: Bundesgesetzblatt Jahrgang 2004 Teil I Nr. 6 + */ +const erziehungsgeldEndAlterKindRegelsatz: Int { + from 2004-01-01 = 24 +} + +/** + * Alter des Kindes in Monaten bis zu dem der Budgetsatz bezogen werden kann. + * Reference: Bundesgesetzblatt Jahrgang 2004 Teil I Nr. 6 + */ +const erziehungsgeldEndAlterKindBudgetsatz: Int { + from 2004-01-01 = 12 +} + +// TODO: rounding + diff --git a/src/resources/builtins/gesetzlicheRente.ttsl b/src/resources/builtins/gesetzlicheRente.ttsl new file mode 100644 index 00000000..03b80477 --- /dev/null +++ b/src/resources/builtins/gesetzlicheRente.ttsl @@ -0,0 +1,1651 @@ +package gesetzlicheRente + +// ges_rente.yaml -------------------------------------------------------- + +/** + * Teil des Nachhaltigkeitsfaktors in der Rentenanpassungsformel, welche das + * Verhältnis von Rentnern zu Beitragszahlern modifiziert + * Reference: §68 Abs. 4 S. 6 SGB VI + */ +const GesetzlicheRenteAlpha: Float { + from 1984-01-01 = 0.0 + from 2002-01-01 = 0.25 +} + +/** + * Teil des Riesterfaktors in der Rentenanpassungsformel + * Reference: §68 Abs. 5 SGB VI + */ +const gesetzlicheRenteAltersVorsorgeAnteil: Float { + from 1993-01-01 = 0.0 + from 2002-01-01 = 0.5 + from 2003-01-01 = 1.0 + from 2004-01-01 = 1.5 + from 2005-01-01 = 2.0 + from 2009-01-01 = 2.5 + from 2010-01-01 = 3.0 + from 2011-01-01 = 3.5 + from 2012-01-01 = 4.0 +} + +/** + * Summe der Beiträge zur Rentenversicherung aller rentenversicherungspflichtig + * Beschäftigten, der geringfügig Beschäftigten und der Bezieher von ALG. + * statistik-rente.de/drv + */ +const gesetzlicheRenteBeitragsvolumen: Dict { + from 1991-01-01 = 108688000 + from 1992-01-01 = 117359000 + from 1993-01-01 = 120559000 + from 1994-01-01 = 132938000 + from 1995-01-01 = 139921000 + from 1996-01-01 = 146160000 + from 1997-01-01 = 153658000 + from 1998-01-01 = 153763000 + from 1999-01-01 = 160506000 + from 2000-01-01 = 163367000 + from 2001-01-01 = 164694000 + from 2002-01-01 = 165481000 + from 2003-01-01 = 169425000 + from 2004-01-01 = 169399000 + from 2005-01-01 = 168954000 + from 2006-01-01 = 180545000 + from 2007-01-01 = 174726000 + from 2008-01-01 = 180028000 + from 2009-01-01 = 181572000 + from 2010-01-01 = 185288000 + from 2011-01-01 = 189850000 + from 2012-01-01 = 193687000 + from 2013-01-01 = 194334000 + from 2014-01-01 = 201647000 + from 2015-01-01 = 207317000 + from 2016-01-01 = 215422000 + from 2017-01-01 = 225244000 + from 2018-01-01 = 236404000 + from 2019-01-01 = 247949000 +} + +/** + * Regelaltersrente/ Standardrente + * Höhe einer abschlagsfreien Rente bei 45 Entgeltpunkten. Ergibt sich aus + * Multiplikation des Rentenwerts mit 45. statistik-rente.de/drv + * Reference: § 154 Abs. 3 Satz 1 Nr. 2 SGB VI + */ +const gesetzlicheRenteEckrente: Float { + from 1995-01-01 = 988.15 + from 1996-01-01 = 992.72 + from 1997-01-01 = 1009.1 + from 1998-01-01 = 1012.47 + from 1999-01-01 = 1026.62 + from 2000-01-01 = 1032.79 + from 2001-01-01 = 1051.99 + from 2002-01-01 = 1072.35 + from 2003-01-01 = 1081.79 + from 2004-01-01 = 1071.79 + from 2005-01-01 = 1063.41 + from 2006-01-01 = 1066.35 + from 2007-01-01 = 1067.8 + from 2008-01-01 = 1077.02 + from 2009-01-01 = 1100.84 + from 2010-01-01 = 1102.67 + from 2011-01-01 = 1109.91 + from 2012-01-01 = 1134.15 + from 2013-01-01 = 1135.71 + from 2014-01-01 = 1154.68 + from 2015-01-01 = 1174.96 + from 2016-01-01 = 1222.09 + from 2017-01-01 = 1242.58 + from 2018-01-01 = 1284.06 +} + +/** + * Durchschnittslohn + * Durchschnittsbruttolohn aller Arbeitnehmer:innen in einem Jahr + */ +const gesetzlicheRenteDurchschnittslohn: Float { + from 2005-01-01 = 28468.23 + from 2006-01-01 = 28673.22 + from 2007-01-01 = 28978.19 + from 2008-01-01 = 29262.71 + from 2009-01-01 = 29774.24 + from 2010-01-01 = 30086.57 + from 2011-01-01 = 30770.62 + from 2012-01-01 = 31452.49 + from 2013-01-01 = 31583.35 + from 2014-01-01 = 32313.66 + from 2015-01-01 = 33047.02 + from 2016-01-01 = 33608.42 +} + +/** + * Beitragspflichtiges Durchschnittsentgelt aller Versicherten + * Durchschnittsentgelt aller Versicherten im Sinne der deutschen Sozialversicherung. + * Dieses wird benötigt zur Berechnung der Entgeltpunkte. + */ +const gesetzlicheRenteBeitragspflichtigesDurchschnittsentgelt: Int { + from 2005-01-01 = 29202 + from 2006-01-01 = 29494 + from 2007-01-01 = 29951 + from 2008-01-01 = 30625 + from 2009-01-01 = 30506 + from 2010-01-01 = 31144 + from 2011-01-01 = 32100 + from 2012-01-01 = 33002 + from 2013-01-01 = 33659 + from 2014-01-01 = 34514 + from 2015-01-01 = 35363 + from 2016-01-01 = 36187 + from 2017-01-01 = 37077 + from 2018-01-01 = 38212 + from 2019-01-01 = 39301 + from 2020-01-01 = 39167 + from 2021-01-01 = 41541 + from 2022-01-01 = 38901 +} + +/** + * Umrechnung der Beitragsbemessungsgrundlagen des Beitrittgebietes + * Für die Berechnung der Entgeltpunkte wird das Einkommen im "Beitrittsgebiet" um + * diesen Faktor erhöht. + * Reference: §256a SGB VI and Anlage 10 SGB VI + */ +const gesetzlicheRenteUmrechnungEntgeltpBeitrittsgebiet: Float { + from 1945-01-01 = 1.0000 + from 1946-01-01 = 1.0000 + from 1947-01-01 = 1.0000 + from 1948-01-01 = 1.0000 + from 1949-01-01 = 1.0000 + from 1950-01-01 = 0.9931 + from 1951-01-01 = 1.0502 + from 1952-01-01 = 1.0617 + from 1953-01-01 = 1.0458 + from 1954-01-01 = 1.0185 + from 1955-01-01 = 1.0656 + from 1956-01-01 = 1.1029 + from 1957-01-01 = 1.1081 + from 1958-01-01 = 1.0992 + from 1959-01-01 = 1.0838 + from 1960-01-01 = 1.1451 + from 1961-01-01 = 1.2374 + from 1962-01-01 = 1.3156 + from 1963-01-01 = 1.3667 + from 1964-01-01 = 1.4568 + from 1965-01-01 = 1.5462 + from 1966-01-01 = 1.6018 + from 1967-01-01 = 1.5927 + from 1968-01-01 = 1.6405 + from 1969-01-01 = 1.7321 + from 1970-01-01 = 1.8875 + from 1971-01-01 = 2.0490 + from 1972-01-01 = 2.1705 + from 1973-01-01 = 2.3637 + from 1974-01-01 = 2.5451 + from 1975-01-01 = 2.6272 + from 1976-01-01 = 2.7344 + from 1977-01-01 = 2.8343 + from 1978-01-01 = 2.8923 + from 1979-01-01 = 2.9734 + from 1980-01-01 = 3.1208 + from 1981-01-01 = 3.1634 + from 1982-01-01 = 3.2147 + from 1983-01-01 = 3.2627 + from 1984-01-01 = 3.2885 + from 1985-01-01 = 3.3129 + from 1986-01-01 = 3.2968 + from 1987-01-01 = 3.2548 + from 1988-01-01 = 3.2381 + from 1989-01-01 = 3.2330 + from 1990-01-01 = 3.0707 + from 1990-06-01 = 2.3473 + from 1991-01-01 = 1.7235 + from 1992-01-01 = 1.4393 + from 1993-01-01 = 1.3197 + from 1994-01-01 = 1.2687 + from 1995-01-01 = 1.2317 + from 1996-01-01 = 1.2209 + from 1997-01-01 = 1.2089 + from 1998-01-01 = 1.2113 + from 1999-01-01 = 1.2054 + from 2000-01-01 = 1.2030 + from 2001-01-01 = 1.2003 + from 2002-01-01 = 1.1972 + from 2003-01-01 = 1.1943 + from 2004-01-01 = 1.1932 + from 2005-01-01 = 1.1827 + from 2006-01-01 = 1.1827 + from 2007-01-01 = 1.1841 + from 2008-01-01 = 1.1857 + from 2009-01-01 = 1.1712 + from 2010-01-01 = 1.1726 + from 2011-01-01 = 1.1740 + from 2012-01-01 = 1.1785 + from 2013-01-01 = 1.1762 + from 2014-01-01 = 1.1665 + from 2015-01-01 = 1.1502 + from 2016-01-01 = 1.1415 + from 2017-01-01 = 1.1374 + from 2018-01-01 = 1.1339 + from 2019-01-01 = 1.0840 + from 2020-01-01 = 1.0700 + from 2021-01-01 = 1.0560 + from 2022-01-01 = 1.0420 + from 2023-01-01 = 1.0280 + from 2024-01-01 = 1.0140 +} + +/** + * Rentenvolumen + * Gesamtvolumen der ausgezahlten Renten + */ +const gesetzlicheRenteGesamtesRentenvolumen: Int { + from 1991-01-01 = 117912000 + from 1992-01-01 = 130901000 + from 1993-01-01 = 141180000 + from 1994-01-01 = 152798000 + from 1995-01-01 = 162625000 + from 1996-01-01 = 168955000 + from 1997-01-01 = 174479000 + from 1998-01-01 = 180323800 + from 1999-01-01 = 184139000 + from 2000-01-01 = 190198000 + from 2001-01-01 = 195776000 + from 2002-01-01 = 202355000 + from 2003-01-01 = 207749000 + from 2004-01-01 = 210522000 + from 2005-01-01 = 211861000 + from 2006-01-01 = 212421000 + from 2007-01-01 = 213649000 + from 2008-01-01 = 216182000 + from 2009-01-01 = 220841000 + from 2010-01-01 = 224352000 + from 2011-01-01 = 225411000 + from 2012-01-01 = 229231000 + from 2013-01-01 = 232297000 + from 2014-01-01 = 238991000 + from 2015-01-01 = 249568000 + from 2016-01-01 = 259345000 + from 2017-01-01 = 286860000 + from 2018-01-01 = 277102000 + from 2019-01-01 = 291359000 +} + +/** + * Rentenwerte alte und neue Bundesländer + * Der aktuelle Rentenwert drückt den Betrag aus, der der monatlichen Rente für + * einen Entgeltpunkt entspricht. + * Reference: statistik-rente.de/drv, § 68 SGB VI + */ +const gesetzlicheRenteRentenwert: Dict { + from 1992-01-01 = { + west: 21.19, + ost: 12.05 + } + + from 1992-07-01 = { + west: 21.80, + ost: 13.59 + } + + from 1993-01-01 = { + west: 21.80, // deviation_from: previous + ost: 14.41 + } + + from 1993-07-01 = { + west: 22.75, + ost: 16.45 + } + + from 1994-01-01 = { + west: 22.75, // deviation_from: previous + ost: 17.05 + } + + from 1994-07-01 = { + west: 23.52, + ost: 17.63 + } + + from 1995-01-01 = { + west: 23.52, // deviation_from: previous + ost: 18.13 + } + + from 1995-07-01 = { + west: 23.64, + ost: 18.58 + } + + from 1996-01-01 = { + west: 23.64, // deviation_from: previous + ost: 19.39 + } + + from 1996-07-01 = { + west: 23.86, + ost: 19.62 + } + + from 1997-07-01 = { + west: 24.26, + ost: 20.71 + } + + from 1998-07-01 = { + west: 24.36, + ost: 20.90 + } + + from 1999-07-01 = { + west: 24.69, + ost: 21.48 + } + + from 2000-07-01 = { + west: 24.84, + ost: 21.61 + } + + from 2001-07-01 = { + west: 25.31, + ost: 22.06 + } + + from 2002-07-01 = { + west: 25.86, + ost: 22.70 + } + + from 2003-07-01 = { + west: 26.13, + ost: 22.97 + } + + from 2007-07-01 = { + west: 26.27, + ost: 23.09 + } + + from 2008-07-01 = { + west: 26.56, + ost: 23.34 + } + + from 2009-07-01 = { + west: 27.2, + ost: 24.13 + } + + from 2011-07-01 = { + west: 27.47, + ost: 24.37 + } + + from 2012-07-01 = { + west: 28.07, + ost: 24.92 + } + + from 2013-07-01 = { + west: 28.14, + ost: 25.74 + } + + from 2014-07-01 = { + west: 28.61, + ost: 26.39 + } + + from 2015-07-01 = { + west: 29.21, + ost: 27.05 + } + + from 2016-07-01 = { + west: 30.45, + ost: 28.66 + } + + from 2017-07-01 = { + west: 31.03, + ost: 29.69 + } + + from 2018-07-01 = { + west: 32.03, + ost: 30.69 + } + + from 2019-07-01 = { + west: 33.05, + ost: 31.89 + } + + from 2020-07-01 = { + west: 34.19, + ost: 33.23 + } + + from 2021-07-01 = { + west: 34.19, // deviation_from: previous + ost: 33.47 + } +} + +/** + * Höchstwert der Entgeltpunkte für Grundrente + * Konstante zur Bestimmung des Höchstwerts der durchschnittlichen Entgeltpunkte und + * des Effekts eines weiteren Monats an Grundrentenzeiten auf Höchstwert. + */ +const gesetzlicheRenteGrundrenteHöchstwert: Dict { + // Reference: § 76g Abs. 4 S. 3, 4 SGB VI + from 2021-01-01 = { + base: 0.0334, + increment: 0.001389, + } +} + +/** + * Zugangsfaktor bei Grundrente + * Der Zugangsfaktor für die Grundrente ist auf 1 begrenzt. + * Reference: § 77 Abs. 2 SGB VI + */ +const gesetzlicheRenteGrundrenteZugangsfaktorMax: Int { + from 2021-01-01 = 1 +} + +/** + * Grundrentenzeiten + * Minimal benötigte Grundrentenzeiten um zur Grundrente berechtigt zu sein und Zahl + * an Grundrentenzeiten ab der zusätzliche Monate an Grundrentenzeiten nicht + * berücksichtigt werden + */ +const gesetzlicheRenteGrundrenteZeiten: Dict { + // Reference: § 76g Abs. 4 S. 5,6 / Abs. 1 S. 1 SGB VI + from 2021-01-01 = { + min: 396, + max: 420, + } +} + +/** + * Einkommensanrechnung Grundrente für Personen ohne verheiratetem Partner + * Werte werden mit dem Rentenwert multipliziert, um Schwellen der + * Einkommensanrechnung des Grundrentenzuschlags zu ermitteln + * Reference: § 97a Abs. 4 S. 2, 4 SGB VI + */ +const gesetzlicheRenteGrundrenteEinkommensanrechnungSingle: Dict> { + // Reference: § 97a Abs. 4 S. 2, 4 SGB VI + from 2021-01-01 = { + 0: { + lower_threshold: -inf, + upper_threshold: 36.56, + rate_linear: 0, + intercept_at_lower_threshold: 0, + }, + 1: { + upper_threshold: 46.78, + rate_linear: 0.6, + }, + 2: { + upper_threshold: inf, + rate_linear: 1, + }, + } +} + +/** + * Einkommensanrechnung Grundrente für Personen mit verheiratetem Partner + * Werte werden mit dem Rentenwert multipliziert, um Schwellen der + * Einkommensanrechnung des Grundrentenzuschlags zu ermitteln + * Reference: § 97a Abs. 4 S. 2, 4 SGB VI + */ +const gesetzlicheRenteGrundrenteEinkommensanrechnungMarried: Dict> { + // Reference: § 97a Abs. 4 S. 2, 4 SGB VI + from 2021-01-01 = { + 0: { + lower_threshold: -inf, + upper_threshold: 57.03, + rate_linear: 0, + intercept_at_lower_threshold: 0, + }, + 1: { + upper_threshold: 67.27, + rate_linear: 0.6, + }, + 2: { + upper_threshold: inf, + rate_linear: 1, + }, + } +} + +/** + * Bonusfaktor aus Grundrente + * Faktor mit dem die durch die Grundrente zusätzlich erhaltenen Entgeltpunkte + * multipliziert werden. + */ +const gesetzlicheRenteGrundrenteFaktorBonus: Float { + // Reference: §§ 76g Abs. 4 S. 3, 4 SGB VI + from 2021-01-01 = 0.875 +} + +/** + * Veränderung des Zugangsfaktors pro Jahr + * Faktor um den sich der Zugangsfaktor für die staatliche Rente erhöht/senkt für + * jedes Jahr, das länger/kürzer gearbeitet wird + * Reference: §77 Abs. 2 Nr. 2 SGB VI + */ +const gesetzlicheRenteZugangsfaktorVeraenderungProJahr: Dict { + // Reference: §77 Abs. 2 Nr. 2 SGB VI + from 2001-01-01 = { + vorzeitiger_renteneintritt: 0.036, + späterer_renteneintritt: 0.06, + } +} + +/** + * Eintrittsalter für Regelaltersrente + * Stückweise lineare Funktion, die die Regelaltersgrenze angibt, bei der das + * Individuum mit seinem vollen Rentenanspruch in Rente gehen kann. Geht die Person + * früher oder später in Rente, ist der Zugangsfaktor und damit der Rentenanspruch + * höher oder niedriger, wenn keine Ausnahmeregelungen erfüllt sind. + * Reference: § 35 Satz 2 SGB VI + */ +const gesetzlicheRenteRegelaltersgrenze: Dict> { + from 1984-01-01 = { + 0: { + lower_threshold: -inf, + upper_threshold: 1946, + rate_linear: 0, + intercept_at_lower_threshold: 65, + }, + 1: { + upper_threshold: 1958, + rate_linear: 0.083333333, + }, + 2: { + upper_threshold: 1964, + rate_linear: 0.16666666, + }, + 3: { + upper_threshold: inf, + rate_linear: 0, + }, + } +} + +/** + * Eintrittsalter für Altersrente für Frauen + * Stückweise lineare Funktion, die die Altersgrenzen angibt, ab denen Frauen + * geboren vor 1952 in Rente gehen konnten. + * Reference: § 237a SGB VI + */ +const gesetzlicheRenteAltersgrenzeFrauen: Dict> { + from 1980-01-01 = { + 0: { + lower_threshold: -inf, + upper_threshold: 1939.916667, + rate_linear: 0, + intercept_at_lower_threshold: 60, + }, + 1: { + upper_threshold: 1944.916666666, + rate_linear: 1, + }, + 2: { + upper_threshold: 1951.916666666, // constant 65 + rate_linear: 0, + }, + 3: { + upper_threshold: 1952, + // since 1952 abolished - regelaltersgrenze applies - jump in theshold by 6 month + rate_linear: 6, + }, + 4: { + upper_threshold: 1958, + rate_linear: 0.083333333, + }, + 5: { + upper_threshold: 1964, + rate_linear: 0.16666666, + }, + 6: { + upper_threshold: inf, + rate_linear: 0, + }, + } +} + +/** + * Altersgrenze für vorzeitigen Bezug der Altersrente für Frauen. + * Frühestmögliches Alter ab dem die Altersrente für Frauen bezogen werden kann + * (mit Abschlägen). + * Reference: § 237a SGB VI + */ +const gesetzlicheRenteAltersgrenzeFrauenVorzeitig: Dict> { + from 1980-01-01 = { + 0: { + lower_threshold: -inf, + upper_threshold: 1952, + rate_linear: 0, + intercept_at_lower_threshold: 60, + }, + 1: { + upper_threshold: 1953, + rate_linear: 7, + }, + 2: { + upper_threshold: inf, // constant 67 + rate_linear: 0, + }, + } +} + +/** + * Kohorte Abschaffung Rente für Frauen + * Kohorte, ab der Rente für Frauen abgeschafft. + * Reference: § 237a SGB VI + */ +const gesetzlicheRenteFirstBirthyearWithoutRenteFrauen: Int { + from 1980-01-01 = 1952 +} + +/** + * Mindestpflichbeitragsjahre ab 40 für Rente für Frauen + ** Mindestpflichbeitragsjahre, nach dem 40. Lebensjahr, + * die für Rente für Frauen berechtigt. + * Wert ist als Jahr zu interpretieren. + * Reference: § 237a SGB VI + */ +const gesetzlicheRenteRenteFrauenPflichtbeitrag: Int { + from 1950-01-01 = 10 +} + +/** + * Altersgrenze für Altersrente wegen Arbeitslosigkeit (abschlagsfrei) + * Frühestmögliches Alter ab dem die Altersrente für Arbeitslose abschlagsfrei + * bezogen werden kann. + * Reference: § 237 SGB VI + */ +const gesetzlicheRenteAltersgrenzeArbeitslosigkeitAbschlagsfrei: Float | Dict> { + from 1980-01-01 = { + 0: { + scalar: 60.0, + }, + } + from 1992-01-01 = { + 0: { + scalar: 60.0, + }, + 1941: { + 1: 60.083333, + 2: 60.083333, + 3: 60.083333, + 4: 60.083333, + 5: 60.166667, + 6: 60.166667, + 7: 60.166667, + 8: 60.166667, + 9: 60.25, + 10: 60.25, + 11: 60.25, + 12: 60.25, + }, + 1942: { + 1: 60.333333, + 2: 60.333333, + 3: 60.333333, + 4: 60.333333, + 5: 60.416667, + 6: 60.416667, + 7: 60.416667, + 8: 60.416667, + 9: 60.5, + 10: 60.5, + 11: 60.5, + 12: 60.5, + }, + 1943: { + 1: 60.583333, + 2: 60.583333, + 3: 60.583333, + 4: 60.583333, + 5: 60.666667, + 6: 60.666667, + 7: 60.666667, + 8: 60.666667, + 9: 60.75, + 10: 60.75, + 11: 60.75, + 12: 60.75, + }, + 1944: { + 1: 60.833333, + 2: 60.833333, + 3: 60.833333, + 4: 60.833333, + 5: 61.916667, + 6: 61.916667, + 7: 61.916667, + 8: 61.916667, + 9: 61.0, + 10: 61, + 11: 61, + 12: 61, + }, + 1945: { + 1: 61.083333, + 2: 61.083333, + 3: 61.166667, + 4: 61.166667, + 5: 61.25, + 6: 61.25, + 7: 61.333333, + 8: 61.333333, + 9: 61.416667, + 10: 61.416667, + 11: 61.5, + 12: 61.5, + }, + 1946: { + 1: 61.583333, + 2: 61.583333, + 3: 61.666667, + 4: 61.666667, + 5: 61.75, + 6: 61.75, + 7: 61.833333, + 8: 61.833333, + 9: 61.916667, + 10: 61.916667, + 11: 62.0, + 12: 62.0, + }, + 1947: { + 1: 62.083333, + 2: 62.083333, + 3: 62.166667, + 4: 62.166667, + 5: 62.25, + 6: 62.25, + 7: 62.333333, + 8: 62.333333, + 9: 62.416667, + 10: 62.416667, + 11: 62.5, + 12: 62.5, + }, + 1948: { + 1: 62.583333, + 2: 62.583333, + 3: 62.666667, + 4: 62.666667, + 5: 62.75, + 6: 62.75, + 7: 62.833333, + 8: 62.833333, + 9: 62.916667, + 10: 62.916667, + 11: 63.0, + 12: 63.0, + }, + 1949: { + 1: 63.083333, + 2: 63.083333, + 3: 63.166667, + 4: 63.166667, + 5: 63.25, + 6: 63.25, + 7: 63.333333, + 8: 63.333333, + 9: 63.416667, + 10: 63.416667, + 11: 63.5, + 12: 63.5, + }, + 1950: { + 1: 63.583333, + 2: 63.583333, + 3: 63.666667, + 4: 63.666667, + 5: 63.75, + 6: 63.75, + 7: 63.833333, + 8: 63.833333, + 9: 63.916667, + 10: 63.916667, + 11: 64.0, + 12: 64.0, + }, + 1951: { + 1: 64.083333, + 2: 64.083333, + 3: 64.166667, + 4: 64.166667, + 5: 64.25, + 6: 64.25, + 7: 64.333333, + 8: 64.333333, + 9: 64.416667, + 10: 64.416667, + 11: 64.5, + 12: 64.5, + }, + 1952: { + 1: 64.583333, + 2: 64.583333, + 3: 64.666667, + 4: 64.666667, + 5: 64.75, + 6: 64.75, + 7: 64.833333, + 8: 64.833333, + 9: 64.916667, + 10: 64.916667, + 11: 65.0, + 12: 65.0, + }, + } + from 1996-07-29 = { + 0: { + scalar: 60.0, + }, + 1937: { + 1: 60.083333, + 2: 60.166667, + 3: 60.25, + 4: 60.333333, + 5: 60.416667, + 6: 60.5, + 7: 60.583333, + 8: 60.666667, + 9: 60.75, + 10: 60.833333, + 11: 60.916667, + 12: 61.0, + }, + 1938: { + 1: 61.083333, + 2: 61.166667, + 3: 61.25, + 4: 61.333333, + 5: 61.416667, + 6: 61.5, + 7: 61.583333, + 8: 61.666667, + 9: 61.75, + 10: 61.833333, + 11: 61.916667, + 12: 62.0, + }, + 1939: { + 1: 62.083333, + 2: 62.166667, + 3: 62.25, + 4: 62.333333, + 5: 62.416667, + 6: 62.5, + 7: 62.583333, + 8: 62.666667, + 9: 62.75, + 10: 62.833333, + 11: 62.916667, + 12: 63.0, + }, + 1940: { + 1: 63.0, + 2: 63.0, + 3: 63.0, + 4: 63.0, + 5: 63.0, + 6: 63.0, + 7: 63.0, + 8: 63.0, + 9: 63.0, + 10: 63.0, + 11: 63.0, + 12: 63.0, + }, + 1941: { + 1: 63.0, + 2: 63.0, + 3: 63.0, + 4: 63.0, + 5: 63.0, + 6: 63.0, + 7: 63.0, + 8: 63.0, + 9: 63.0, + 10: 63.0, + 11: 63.0, + 12: 63.0, + }, + 1942: { + 1: 63.0, + 2: 63.0, + 3: 63.0, + 4: 63.0, + 5: 63.0, + 6: 63.0, + 7: 63.0, + 8: 63.0, + 9: 63.0, + 10: 63.0, + 11: 63.0, + 12: 63.0, + }, + 1943: { + 1: 63.0, + 2: 63.0, + 3: 63.0, + 4: 63.0, + 5: 63.0, + 6: 63.0, + 7: 63.0, + 8: 63.0, + 9: 63.0, + 10: 63.0, + 11: 63.0, + 12: 63.0, + }, + 1944: { + 1: 63.0, + 2: 63.0, + 3: 63.0, + 4: 63.0, + 5: 63.0, + 6: 63.0, + 7: 63.0, + 8: 63.0, + 9: 63.0, + 10: 63.0, + 11: 63.0, + 12: 63.0, + }, + 1945: { + 1: 63.0, + 2: 63.0, + 3: 63.0, + 4: 63.0, + 5: 63.0, + 6: 63.0, + 7: 63.0, + 8: 63.0, + 9: 63.0, + 10: 63.0, + 11: 63.0, + 12: 63.0, + }, + 1946: { + 1: 63.0, + 2: 63.0, + 3: 63.0, + 4: 63.0, + 5: 63.0, + 6: 63.0, + 7: 63.0, + 8: 63.0, + 9: 63.0, + 10: 63.0, + 11: 63.0, + 12: 63.0, + }, + 1947: { + 1: 63.0, + 2: 63.0, + 3: 63.0, + 4: 63.0, + 5: 63.0, + 6: 63.0, + 7: 63.0, + 8: 63.0, + 9: 63.0, + 10: 63.0, + 11: 63.0, + 12: 63.0, + }, + 1948: { + 1: 63.0, + 2: 63.0, + 3: 63.0, + 4: 63.0, + 5: 63.0, + 6: 63.0, + 7: 63.0, + 8: 63.0, + 9: 63.0, + 10: 63.0, + 11: 63.0, + 12: 63.0, + }, + 1949: { + 1: 63.083333, + 2: 63.083333, + 3: 63.166667, + 4: 63.166667, + 5: 63.25, + 6: 63.25, + 7: 63.333333, + 8: 63.333333, + 9: 63.416667, + 10: 63.416667, + 11: 63.5, + 12: 63.5, + }, + 1950: { + 1: 63.583333, + 2: 63.583333, + 3: 63.666667, + 4: 63.666667, + 5: 63.75, + 6: 63.75, + 7: 63.833333, + 8: 63.833333, + 9: 63.916667, + 10: 63.916667, + 11: 64.0, + 12: 64.0, + }, + 1951: { + 1: 64.083333, + 2: 64.083333, + 3: 64.166667, + 4: 64.166667, + 5: 64.25, + 6: 64.25, + 7: 64.333333, + 8: 64.333333, + 9: 64.416667, + 10: 64.416667, + 11: 64.5, + 12: 64.5, + }, + 1952: { + 1: 64.583333, + 2: 64.583333, + 3: 64.666667, + 4: 64.666667, + 5: 64.75, + 6: 64.75, + 7: 64.833333, + 8: 64.833333, + 9: 64.916667, + 10: 64.916667, + 11: 65.0, + 12: 65.0, + }, + /* + Altersgrenze für Altersrente wegen Arbeitslosigkeit mit Vertrauensschutz + (abschlagsfrei). + Increase of full retirement age according to old law (RRG 1992) for individuals + covered under Vertrauensschutz. + Reference: § 237 SGB VI Abs. 4 + */ + vertrauensschutz: { + max_birthyear_old_regime: 1940, + entry_age_old_regime: 60.0, + 1941: { + 1: 60.083333, + 2: 60.083333, + 3: 60.083333, + 4: 60.083333, + 5: 60.166667, + 6: 60.166667, + 7: 60.166667, + 8: 60.166667, + 9: 60.25, + 10: 60.25, + 11: 60.25, + 12: 60.25, + }, + 1942: { + 1: 60.333333, + 2: 60.333333, + 3: 60.333333, + 4: 60.333333, + 5: 60.416667, + 6: 60.416667, + 7: 60.416667, + 8: 60.416667, + 9: 60.5, + 10: 60.5, + 11: 60.5, + 12: 60.5, + }, + 1943: { + 1: 60.583333, + 2: 60.583333, + 3: 60.583333, + 4: 60.583333, + 5: 60.666667, + 6: 60.666667, + 7: 60.666667, + 8: 60.666667, + 9: 60.75, + 10: 60.75, + 11: 60.75, + 12: 60.75, + }, + 1944: { + 1: 60.833333, + 2: 60.833333, + }, + }, + } + + // Reference: Wachstums- und Beschäftigungsförderungsgesetz 1996. BGBl. I S. 1461 1996 + // Increase of full retirement age from 60 to 65 for birth cohort 1937-1941. + from 1996-09-27 = { + max_birthyear_old_regime: 1936, + min_birthyear_new_regime: 1942, + entry_age_old_regime: 60.0, + entry_age_new_regime: 65.0, + 1937: { + 1: 60.083333, + 2: 60.166667, + 3: 60.25, + 4: 60.333333, + 5: 60.416667, + 6: 60.5, + 7: 60.583333, + 8: 60.666667, + 9: 60.75, + 10: 60.833333, + 11: 60.916667, + 12: 61.0, + }, + 1938: { + 1: 61.083333, + 2: 61.166667, + 3: 61.25, + 4: 61.333333, + 5: 61.416667, + 6: 61.5, + 7: 61.583333, + 8: 61.666667, + 9: 61.75, + 10: 61.833333, + 11: 61.916667, + 12: 62.0, + }, + 1939: { + 1: 62.083333, + 2: 62.166667, + 3: 62.25, + 4: 62.333333, + 5: 62.416667, + 6: 62.5, + 7: 62.583333, + 8: 62.666667, + 9: 62.75, + 10: 62.833333, + 11: 62.916667, + 12: 63.0, + }, + 1940: { + 1: 63.083333, + 2: 63.166667, + 3: 63.25, + 4: 63.333333, + 5: 63.416667, + 6: 63.5, + 7: 63.583333, + 8: 63.666667, + 9: 63.75, + 10: 63.833333, + 11: 63.916667, + 12: 64.0, + }, + 1941: { + 1: 64.083333, + 2: 64.166667, + 3: 64.25, + 4: 64.333333, + 5: 64.416667, + 6: 64.5, + 7: 64.583333, + 8: 64.666667, + 9: 64.75, + 10: 64.833333, + 11: 64.916667, + 12: 65.0, + }, + vertrauensschutz: { + /* + Altersgrenze für Altersrente wegen Arbeitslosigkeit mit Vertrauensschutz + (abschlagsfrei). + Increase of full retirement age according to old law (RRG 1992) for individuals + covered under Vertrauensschutz. + Reference: § 237 SGB VI Abs. 4 + */ + max_birthyear_old_regime: 1940, + entry_age_old_regime: 60.0, + 1941: { + 1: 60.083333, + 2: 60.083333, + 3: 60.083333, + 4: 60.083333, + 5: 60.166667, + 6: 60.166667, + 7: 60.166667, + 8: 60.166667, + 9: 60.25, + 10: 60.25, + 11: 60.25, + 12: 60.25, + }, + 1942: { + 1: 60.333333, + 2: 60.333333, + 3: 60.333333, + 4: 60.333333, + 5: 60.416667, + 6: 60.416667, + 7: 60.416667, + 8: 60.416667, + 9: 60.5, + 10: 60.5, + 11: 60.5, + 12: 60.5, + }, + 1943: { + 1: 60.583333, + 2: 60.583333, + 3: 60.583333, + 4: 60.583333, + 5: 60.666667, + 6: 60.666667, + 7: 60.666667, + 8: 60.666667, + 9: 60.75, + 10: 60.75, + 11: 60.75, + 12: 60.75, + }, + 1944: { + 1: 60.833333, + 2: 60.833333, + }, + }, + } +} + +/** + * Altersgrenze für vorzeitige Inanspruchnahme Altersrente wegen Arbeitslosigkeit + * Frühestmögliches Alter ab dem die Altersrente für Arbeitslose + * bezogen werden kann (mit Abschlägen), einschließlich Vertrauensschutz. + * Reference: § 237 SGB VI + */ +const gesetzlicheRenteAltersgrenzeArbeitslosigkeitVorzeitig: Float | Dict>{ + from 1980-01-01 = 60.0 + + // Increase of early retirement age from 60 to 62 for birth cohort 1949-1952. + // Reference: Rentenreformgesetz 1992. BGBl. I S. 2261 1989 § 41 + from 1992-01-01 = { + max_birthyear_old_regime: 1948, + min_birthyear_new_regime: 1953, + entry_age_old_regime: 60.0, + entry_age_new_regime: 62.0, + 1949: { + 1: 60.083333, + 2: 60.083333, + 3: 60.166667, + 4: 60.166667, + 5: 60.25, + 6: 60.25, + 7: 60.333333, + 8: 60.333333, + 9: 60.416667, + 10: 60.416667, + 11: 60.5, + 12: 60.5, + }, + 1950: { + 1: 60.583333, + 2: 60.583333, + 3: 60.666667, + 4: 60.666667, + 5: 60.75, + 6: 60.75, + 7: 60.833333, + 8: 60.833333, + 9: 60.916667, + 10: 60.916667, + 11: 61.0, + 12: 61.0, + }, + 1951: { + 1: 61.083333, + 2: 61.083333, + 3: 61.166667, + 4: 61.166667, + 5: 61.25, + 6: 61.25, + 7: 61.333333, + 8: 61.333333, + 9: 61.416667, + 10: 61.416667, + 11: 61.5, + 12: 61.5, + }, + 1952: { + 1: 61.583333, + 2: 61.583333, + 3: 61.666667, + 4: 61.666667, + 5: 61.75, + 6: 61.75, + 7: 61.833333, + 8: 61.833333, + 9: 61.916667, + 10: 61.916667, + 11: 62.0, + 12: 62.0, + }, + } + + // Increase of early retirement age from 60 to 65 for birth cohort 1937-1941. + // Reference: Wachstums- und Beschäftigungsförderungsgesetz 1996. BGBl. I S. 1461 1996 + from 1996-07-29 = { + max_birthyear_old_regime: 1948, + min_birthyear_new_regime: 1953, + entry_age_old_regime: 60.0, + entry_age_new_regime: 62.0, + 1949: { + 1: 60.083333, + 2: 60.083333, + 3: 60.166667, + 4: 60.166667, + 5: 60.25, + 6: 60.25, + 7: 60.333333, + 8: 60.333333, + 9: 60.416667, + 10: 60.416667, + 11: 60.5, + 12: 60.5, + }, + 1950: { + 1: 60.583333, + 2: 60.583333, + 3: 60.666667, + 4: 60.666667, + 5: 60.75, + 6: 60.75, + 7: 60.833333, + 8: 60.833333, + 9: 60.916667, + 10: 60.916667, + 11: 61.0, + 12: 61.0, + }, + 1951: { + 1: 61.083333, + 2: 61.083333, + 3: 61.166667, + 4: 61.166667, + 5: 61.25, + 6: 61.25, + 7: 61.333333, + 8: 61.333333, + 9: 61.416667, + 10: 61.416667, + 11: 61.5, + 12: 61.5, + }, + 1952: { + 1: 61.583333, + 2: 61.583333, + 3: 61.666667, + 4: 61.666667, + 5: 61.75, + 6: 61.75, + 7: 61.833333, + 8: 61.833333, + 9: 61.916667, + 10: 61.916667, + 11: 62.0, + 12: 62.0, + }, + vertrauensschutz: 60.0, + } + + // Increase of ERA was revoked. + // Reference: Wachstums- und Beschäftigungsförderungsgesetz 1996. BGBl. I S. 1461 1996 + from 1996-09-27 = 60.0, + + from 2004-07-26 = { + max_birthyear_old_regime: 1945, + min_birthyear_new_regime: 1949, + entry_age_old_regime: 60.0, + entry_age_new_regime: 63.0, + 1946: { + 1: 60.083333, + 2: 60.166667, + 3: 60.25, + 4: 60.333333, + 5: 60.416667, + 6: 60.5, + 7: 60.583333, + 8: 60.666667, + 9: 60.75, + 10: 60.833333, + 11: 60.916667, + 12: 61.0, + }, + 1947: { + 1: 61.083333, + 2: 61.166667, + 3: 61.25, + 4: 61.333333, + 5: 61.416667, + 6: 61.5, + 7: 61.583333, + 8: 61.666667, + 9: 61.75, + 10: 61.833333, + 11: 61.916667, + 12: 62.0, + }, + 1948: { + 1: 62.083333, + 2: 62.166667, + 3: 62.25, + 4: 62.333333, + 5: 62.416667, + 6: 62.5, + 7: 62.583333, + 8: 62.666667, + 9: 62.75, + 10: 62.833333, + 11: 62.916667, + 12: 63.0, + }, + vertrauensschutz: 60.0, + } + + // Same statutory retirement ages as before, but abolishment with birth cohort 1952. + // Reference: RV-Nachhaltigkeitsgesetz 2004 and RV-Altersgrenzenanpassungsgesetz 2007. + from 2007-04-30 = { + first_birthyear_without_rente_für_arbeitsl: 1952, + max_birthyear_old_regime: 1945, + min_birthyear_new_regime: 1949, + entry_age_old_regime: 60.0, + entry_age_new_regime: 63.0, + 1946: { + 1: 60.083333, + 2: 60.166667, + 3: 60.25, + 4: 60.333333, + 5: 60.416667, + 6: 60.5, + 7: 60.583333, + 8: 60.666667, + 9: 60.75, + 10: 60.833333, + 11: 60.916667, + 12: 61.0, + }, + 1947: { + 1: 61.083333, + 2: 61.166667, + 3: 61.25, + 4: 61.333333, + 5: 61.416667, + 6: 61.5, + 7: 61.583333, + 8: 61.666667, + 9: 61.75, + 10: 61.833333, + 11: 61.916667, + 12: 62.0, + }, + 1948: { + 1: 62.083333, + 2: 62.166667, + 3: 62.25, + 4: 62.333333, + 5: 62.416667, + 6: 62.5, + 7: 62.583333, + 8: 62.666667, + 9: 62.75, + 10: 62.833333, + 11: 62.916667, + 12: 63.0, + }, + vertrauensschutz: 60.0, + } +} + +/** + * Altersgrenze für vorzeitigen Bezug der Altersrente für langjährig Versicherte + * Frühestmögliches Alter ab dem die Altersrente für langjährig Versicherte + * bezogen werden kann (mit Abschlägen). + * Reference: § 236 SGB VI + */ +const gesetzlicheRenteAltersgrenzeLangjährigVersicherteVorzeitig: Float { + from 1980-01-01 = 63.0 +} + +/** + * Eintrittsalter für langjährig Versicherte - abschlagsfrei + * Stückweise lineare Funktion, die die Regelaltersgrenze angibt, bei der das + * Individuum mit seinem vollen Rentenanspruch in Rente gehen kann. Geht die Person + * früher oder später in Rente, ist der Zugangsfaktor und damit der Rentenanspruch + * höher oder niedriger, wenn keine Ausnahmeregelungen erfüllt sind. + * Reference: § 236 SGB VI + */ +const gesetzlicheRenteAltersgrenzeLangjährigVersicherteAbschlagsfrei: Dict> { + from 1984-01-01 = { + 0: { + lower_threshold: -inf, + upper_threshold: 1936.916666666, + rate_linear: 0, + intercept_at_lower_threshold: 63, + }, + 1: { + upper_threshold: 1938.916666666, + rate_linear: 1, + }, + 2: { + upper_threshold: 1948.916666666, + rate_linear: 0, + }, + 3: { + upper_threshold: 1949.25, + rate_linear: 1, + }, + 4: { + upper_threshold: 1950, // 1950.91667 + rate_linear: 0, + }, + 5: { + upper_threshold: 1958, + rate_linear: 0.083333333, + }, + 6: { + upper_threshold: 1964, + rate_linear: 0.16666666, + }, + 7: { + upper_threshold: inf, + rate_linear: 0, + }, + } +} + +/** + * Kohorte Angleichung Rente langjährig Versicherte + * Kohorte, ab der Altersgrenze für abschlagfreie Rente für langjährig Versicherte an + * Altersgrenze Regelaltersrente angeglichen wurde. + * Reference: § 237 SGB VI + */ +const gesetzlicheRenteAlignmentCohortLangjährigVersicherte: Int { + from 1980-01-01 = 1950 +} + +/** + * Eintrittsalter für besonders langjährig Versicherte - abschlagsfrei (Rente mit 63) + * Stückweise lineare Funktion, die die Regelaltersgrenze angibt, bei der das + * Individuum mit seinem vollen Rentenanspruch in Rente gehen kann. Geht die Person + * früher oder später in Rente, ist der Zugangsfaktor und damit der Rentenanspruch + * höher oder niedriger, wenn keine Ausnahmeregelungen erfüllt sind. + * Ab dem 1.7.2014 wurde die Altersgrenze für Kohorten bis 1952 auf 63 Jahre + * gesenkt (für nachfolgende Kohorten steigt sie um 2 Monate pro Kohorte bis + * 65). Personen, die vor dem 1.7.1951 (codiert als 1951.5) geboren wurden, + * waren zu diesem Zeitpunkt aber schon älter als 63 und hatten ensprechend ein + * höheres verfügbares Renteneintrittsalter. Nur Personen, die ab dem 1.7.1949 + * geboren wurden konnten überhaupt profitieren, da alle anderen schon über 65 + * waren. Für die Zugangsfaktor berechnung werden die tatsächlich verfügbaren + * Renteneintrittsalter benötigt. Daher brauchen wir für die inputs eine + * monatliche Präzision bis Kohorte 1952. + * Reference: § 38 SGB VI + */ +const gesetzlicheRenteAltersgrenzeBesondersLangjährigVersicherte: Dict> { + from 2012-01-01 = { + 0: { + lower_threshold: -inf, + upper_threshold: inf, + rate_linear: 0, + intercept_at_lower_threshold: 65, + }, + }, + from 2014-07-01 = { + 0: { + lower_threshold: -inf, + upper_threshold: 1949.5, + rate_linear: 0, + intercept_at_lower_threshold: 65, + }, + 1: { + upper_threshold: 1951.5, + rate_linear: -1, + }, + 2: { + upper_threshold: 1952, + rate_linear: 0, + }, + 3: { + upper_threshold: 1964, + rate_linear: 0.16666666, + }, + 4: { + upper_threshold: inf, + rate_linear: 0, + } + } +} + +/** + * Kohorte Implementierung Rente für besonders langjährig Versicherte + * Kohorte, ab der Rente für besonders langjährig Versicherte vollständig eingeführt. + * Reference: § 237 SGB VI + */ +const gesetzlicheRenteFirstBirthyearBesondersLangjährigVersicherte: Int { + from 2012-01-01 = 1952 +} + +// TODO: rounding +// TODO: threshholdswartezeiten diff --git a/src/resources/builtins/grundsicherungImAlter.ttsl b/src/resources/builtins/grundsicherungImAlter.ttsl new file mode 100644 index 00000000..5d50a934 --- /dev/null +++ b/src/resources/builtins/grundsicherungImAlter.ttsl @@ -0,0 +1,129 @@ +package grundsicherungImAlter + +// grunds_im_alter.yaml -------------------------------------------------- + +/** + * Schonvermögen für Grundsicherung im Alter + * Ab dieser Vermögensschwelle besteht kein Anspruch auf Grundsicherung im Alter / + * bei Erwerbsminderung. + * Reference: § 1 Verordnung zur Durchführung des § 90 Abs. 2 Nr. 9 des Zwölften Buches + * Sozialgesetzbuch + */ +const grundsicherungImAlterVermoegensfreibetrag: Dict { + from 1984-01-01: { + adult: 0, + child: 0, + }, + from 2003-01-01: { + adult: 2600, + child: 0, + }, + from 2017-04-01: { + adult: 5000, + child: 500, + }, +} + +/** + * Anrechnungsfreier Anteil der staatlichen Rente (bei mind. 33 Grundrentenzeiten) + * Anrechnungsfreie Anteile staatliche Rente wenn mindestens 33 Jahre + * Grundrentenzeiten erreicht wurden. + */ +const grundsicherungImAlterGesetzlicheRenteAnrechnungsfrei: Dict> { + from 1984-01-01: { + 0: { + lower_threshold: -inf, + upper_threshold: inf, + rate: 0, + intercept_at_lower_threshold: 0, + }, + }, + from 2021-01-01: { + 0: { + lower_threshold: -inf, + upper_threshold: 0, + rate: 0, + intercept_at_lower_threshold: 0, + }, + 1: { + lower_threshold: 0, + upper_threshold: 100, + rate: 1, + }, + 2: { + upper_threshold: inf, + rate: 0.3, + }, + }, +} + +/** + * Freibetrag des Kapitaleinkommens für Grundsicherung + * Nur das Kapitaleinkommens, das über diesem Freibetrag liegt, wird auf die + * Grundsicherung im Alter angerechnet. The reference is § 82 SGB XII Abs. 2. + */ +const grundsicherungImAlterKapitaleinkommensfreibetrag: Int { + from 1984-01-01 = 0 + + // Reference: § 43 SGB XII Abs. 2 + from 2016-01-01 = 26 +} + +/** + * Anrechnungsfreier Anteil des Erwerbseinkommens für Grundsicherung + * Anteil des Erwerbseinkommens, welcher bei der Berechnung der Grundsicherung nicht + * zum Einkommen addiert wird. + * Reference: § 82 SGB XII Abs. 3 + */ +const grundsicherungImAlterErwerbseinkommensfreibetrag: Float { + // Unclear how it was handled before 2005 + from 1984-01-01 = 0 + + from 2005-01-01 = 0.3 +} + +/** + * Anrechnungsfreie Anteile der privaten Rente für Grundsicherung + * Anteil der privaten Rente, welcher bei der Berechnung der Grundsicherung nicht zum + * Einkommen addiert wird. + * Reference: § 82 SGB XII Abs. 4 + */ +const grundsicherungImAlterPrivateRenteAnrechnungsfrei: Dict> { + from 1984-01-01: { + // Unclear how it was handled before 2005, + 0: { + lower_threshold: -inf, + upper_threshold: inf, + rate: 0, + intercept_at_lower_threshold: 0, + }, + }, + from 2005-01-01: { + 0: { + lower_threshold: -inf, + upper_threshold: 0, + rate: 0, + intercept_at_lower_threshold: 0, + }, + 1: { + lower_threshold: 0, + upper_threshold: 100, + rate: 1, + }, + 2: { + upper_threshold: inf, + rate: 0.3, + }, + }, +} + +/** + * Mehrbedarf bei Schwerbehinderung + * Dieser Prozentanteil des Regelbedarfs wird Menschen mit Schwerbehindertenausweis + * mit Merkzeichen G, die Grundsicherung im Alter oder bei Erwerbsminderung bekommen, + * als Mehrbedarf anerkannt. + * Reference: § 30 Abs. 1 SGB XII, https://www.buzer.de/gesetz/3415/al0-3758.htm + */ +const grundsicherungImAlterMehrbedarfSchwerbehinderung: Float { + from 2006-12-07 = 0.17 +} diff --git a/src/resources/builtins/parameters.ttsl b/src/resources/builtins/parameters.ttsl deleted file mode 100644 index 182101fb..00000000 --- a/src/resources/builtins/parameters.ttsl +++ /dev/null @@ -1,3748 +0,0 @@ -package parameter - -// abgelt_st.yaml -------------------------------------------------------- - -/** - * Constant for the Capital Income Tax Rate as defined in §32d (1) EStG. - * Reference: Art. 1 G. v. 14.08.2007 - */ -public const abgeltungssteuersatz: Float { - from 1984-01-01 = 0.0; - from 2009-01-01 = 0.25; -} - -// arbeitsl_geld_2.yaml -------------------------------------------------- - -/** - * Income shares not subject to transfer withdrawal. - * Einkommensanteile, die anrechnungsfrei bleiben. § 30 SGB II. Seit 01.10.2005 - * zudem definiert durch Freibetrag in § 11 SGB II, s. § 67 SGB II. Seit 01.04.2011 - * § 11b (2) SGB II (neugefasst durch B. v. 13.05.2011 BGBl. I S. 850. Artikel 2 - * G. v. 24.03.2011 BGBl. I S. 453). - */ -public const arbeitslosengeldAnrechnungsfreieEinkommensanteile: Dict>> { - // Reference: Artikel 1. G. v. 24.12.2003 BGBl. I S. 2954. - from 2005-01-01 = { - 0: { - lower_threshold: -inf, - upper_threshold: 0, - rate: 0, - intercept_at_lower_threshold: 0 - }, - 1: { - lower_threshold: 0, - upper_threshold: 400, - rate: 0.15 - }, - 2: { - upper_threshold: 900, - rate: 0.3 - }, - 3: { - upper_threshold: 1500, - rate: 0.15 - }, - 4: { - upper_threshold: inf, - rate: 0 - } - } - - // Reference: Artikel 1 G. v. 14.08.2005 BGBl. I S. 2407. - from 2005-10-01 = { - 0: { - lower_threshold: -inf, - upper_threshold: 0, - rate: 0, - intercept_at_lower_threshold: 0 - }, - 1: { - lower_threshold: 0, - upper_threshold: 100, - rate: 1.0 - }, - 2: { - upper_threshold: 800, - rate: 0.2 - }, - 3: { - upper_threshold: 1200, - rate: 0.1 - }, - 4: { - upper_threshold: inf, - rate: 0 - } - } - - // Reference: Artikel 1 G. v. 20.12.2011 BGBl. I 2854. - from 2011-04-01 = { - 2: { - upper_threshold: 1000 - } - } - - // Reference: G. v. 20.12.2022 BGBl. I S. 2328. - from 2023-07-01 = { - 0: { - lower_threshold: -inf, - upper_threshold: 0, - rate: 0, - intercept_at_lower_threshold: 0 - }, - 1: { - lower_threshold: 0, - upper_threshold: 100, - rate: 1.0 - }, - 2: { - upper_threshold: 520, - rate: 0.2 - }, - 3: { - upper_threshold: 1000, - rate: 0.3 - }, - 4: { - upper_threshold: 1200, - rate: 0.1 - }, - 5: { - upper_threshold: inf, - rate: 0 - } - } -} - -/** - * Abweichende anrechnungsfreie Einkommensanteile falls Kinder im Haushalt - * Obere Einkommensgrenze bei anzurechnendem Einkommen, Intervall 3, Haushalt mit - * Kindern. Gilt statt der Parameter in eink_anr_frei für Leistungsbezieher, die mit - * minderjährigem Kind in BG leben oder die ein minderjähriges Kind haben (zweiteres - * wird aktuell noch nicht im Code beachtet). § 30 SGB II. Seit 01.04.2011 § 11b SGB - * II (neugefasst durch B. v. 13.05.2011 BGBl. I S. 850. Artikel 2 G. v. 24.03.2011 - * BGBl. I S. 453). - */ -public const arbeitslosengeldAnrechnungsfreieEinkommensanteileFallsKinder: Dict>> { - // Reference: Artikel 1 G. v. 14.08.2005 BGBl. I S. 2407. - from 2005-10-01 = { - 3: { - upper_threshold: 1500 - } - } - - // Reference: G. v. 20.12.2022 BGBl. I S. 2328. - from 2023-07-01 = { - 4: { - upper_threshold: 1500 - } - } -} - -/** - * Regelsatz, seit 2011 Beträge differenzieren sich nach Regelbedarfsstufen - * § 20 V SGB II. Für 2005 bis 2010 siehe Bekanntmachungen zu § 20. Seit 2011 - * wird der Regelbedarf durch das Regelbedarfs-Ermittlungsgesetz (RBEG) ermittelt. - * Neufassung SGB II § 20 (1a) und (2) durch Artikel 6 G. v. 22.12.2016 BGBl. I - * S. - * 3159. - */ -public const arbeitslosenGeldRegelsatz: Int | Dict { - from 2005-01-01 = { - scalar: 338, - reference: "Artikel 1 G. v. 24.12.2003 BGBl. I S. 2954.", - note: "Der tatsächliche Wert unterscheidet sich zwischen Ost und West. Korrekte Werte sind in den alten Bundesländern einschließlich Berlin (Ost) 345 Euro, in den neuen Bundesländern 331 Euro." - }, - - // Reference: B. v. 01.09.2005 BGBl. I S. 2718. - // Betrag unverändert. Der tatsächliche Wert unterscheidet sich zwischen Ost und West. Hier wurde vereinfachend 338 Euro als ungewichteter Mittelwert genommen. Korrekte Werte für die Zeit ab 1. Juli 2005 sind in den alten Bundesländern einschließlich Berlin (Ost) 345 Euro, in den neuen Bundesländern 331 Euro. - from 2005-07-01 = 338 - - // Reference: B. v. 20.07.2006 BGBl. I S. 1702. - from 2006-07-01 = 345 - - // Reference: B. v. 18.06.2007 BGBl. I S. 1139. - from 2007-07-01 = 347 - - // Reference: B. v. 26.06.2008 BGBl. I S. 1102. - from 2008-07-01 = 351 - - // Reference: B. v. 17.06.2009 BGBl. I S. 1342. - from 2009-07-01 = 359 - - // Reference: B. v. 07.06.2010 BGBl. I S. 820. Betrag unverändert. - from 2010-07-01 = 359 - - // Reference: Artikel 1 G. v. 24.03.2011 BGBl. I S. 453. - from 2011-01-01 = { - 1: 364, - 2: 328, - 3: 291, - 4: 287, - 5: 251, - 6: 215, - } - - // Reference: V. v. 20.10.2011 BGBl. I S. 2093. - from 2012-01-01 = { - 1: 374, - 2: 337, - 3: 299, - 4: 287, - 5: 251, - 6: 219, - } - - // Reference: B. v. 18.10.2012 BGBl. I S. 2175. - from 2013-01-01 = { - 1: 382, - 2: 345, - 3: 306, - 4: 289, - 5: 255, - 6: 224, - } - - // Reference: B. v. 16.10.2013 BGBl. I S. 3857. - from 2014-01-01 = { - 1: 391, - 2: 353, - 3: 313, - 4: 296, - 5: 261, - 6: 229, - } - - // Reference: B. v. 15.10.2014 BGBl. I S. 1620. - from 2015-01-01 = { - 1: 399, - 2: 360, - 3: 320, - 4: 302, - 5: 267, - 6: 234, - } - - // Reference: B. v. 22.10.2015 BGBl. I S. 1792. - from 2016-01-01 = { - 1: 404, - 2: 364, - 3: 324, - 4: 306, - 5: 270, - 6: 237, - } - - // Reference: G. v. 22.12.2016 BGBl. I S. 3159. - from 2017-01-01 = { - 1: 409, - 2: 368, - 3: 327, - 4: 311, - 5: 291, - 6: 236, - } - - // Reference: V. v. 08.11.2017 BGBl. I S. 3767. - from 2018-01-01 = { - 1: 416, - 2: 374, - 3: 332, - 4: 316, - 5: 296, - 6: 240, - } - - // Reference: V. v. 19.10.2018 BGBl. I S. 1766. - from 2019-01-01 = { - 1: 424, - 2: 382, - 3: 339, - 4: 322, - 5: 302, - 6: 245, - } - - // Reference: V. v. 18.10.2019 BGBl. I S. 1452. - from 2020-01-01 = { - 1: 432, - 2: 389, - 3: 345, - 4: 328, - 5: 308, - 6: 250 - } - - // Reference: G. v. 09.12.2020 BGBl. I S. 2855. - from 2021-01-01 = { - 1: 446, - 2: 401, - 3: 357, - 4: 373, - 5: 309, - 6: 283 - } - - // Reference: V. v. 13.10.2021 BGBl. I S. 4674. - from 2022-01-01 = { - 1: 449, - 2: 404, - 3: 360, - 4: 376, - 5: 311, - 6: 285 - } - - // Reference: G. v. 20.12.2022 BGBl. I S. 2328. - // Bürgergeld-Gesetz - from 2023-01-01 = { - 1: 502, - 2: 451, - 3: 402, - 4: 420, - 5: 348, - 6: 318 - } -} - -/** - * Anteil am Regelsatz für weitere Personen im Haushalt - * 20 (3) SGB II, eigentliche Wirknorm ist § 20 IV SGB II i.V.m Absatz V - * derselben Norm. 2005 bis 2010. - * 2005-2010 der Regelsatz für weitere Haushaltsmitglieder wurden als Anteil - * des Standardsatzes bestimmt. - */ - public const arbeitslosenGeldAnteilRegelsatz: Dict { - // Reference: Artikel 1 G. v. 24.12.2003 BGBl. I S. 2954. - from 2005-01-01 = { - zwei_erwachsene: 0.9, - weitere_erwachsene: 0.8, - kinder_bis_5: 0.6, - kinder_ab_6_bis_13: 0.6, - kinder_ab_14_bis_24: 0.8 - } - - - // TODO: WAS HEIßT DEVIATION_FROM - // Reference: Artikel 1 G. v. 02.03.2009 BGBl. I S. 416. - from 2009-07-01 = { - zwei_erwachsene: 0.9, - weitere_erwachsene: 0.8, - kinder_bis_5: 0.6, - kinder_ab_6_bis_13: 0.7, - kinder_ab_14_bis_24: 0.8 - } - } - -/** - * Anteil am Regelsatz für weitere Personen im Haushalt - * ``kind_unter_7_oder_mehr`` gibt Mehrbedarf AE bei mind. einem Kind unter 7 Jahren - * oder zwei oder drei Kindern unter 16 Jahre an. ``min_1_kind`` gibt den Mehrbedarf - * an wenn der Anspruch größer ist als der für den ersten Schlüssel. ``max`` gibt - * den Maximalanteil für den Mehrbedarf für Alleinerziehende gemessen am - * maßgebenden Regelbedarf. - * § 21 (3) Nr. 1 SGB II. - * reference_period: Month - */ -public const arbeitslosenGeldMehrbedarfAnteil: Dict { - // Reference: G. v. 24.12.2003 BGBl. I S. 2954. - from 2005-01-01 = { - min_1_kind: 0.12, - kind_unter_7_oder_mehr: 0.36, - max: 0.6 - } -} - -/** - * Maximaler Vermögensgrundfreibetrag - * § 12 (2) Satz 1 Nr. 1 SGB II. Ausnahmeregelung für Personen, - * die vor 1948 geboren wurden. Die Ausnahmeregelung taucht im aktuellen Gesetz nicht - * mehr auf und ist nicht mehr relevant, - * da alle betroffenen Personen zu alt für ALG 2 sind. - */ - def arbeitslosenGeldVermögensGrundfreibetragObergrenze: Dict { - // Reference: Artikel 1 G. v. 23.12.2002 BGBl. I S. 4607. - from 2005-01-01 = { - 1947: 33800, - 1948: 13000, - 1958: 13000, - 1964: 13000 - } - - // Reference: Artikel 1 G. v. 20.07.2006 BGBl. I S. 1706. - from 2006-08-01 = { - 1947: 33800, - 1948: 9750, - 1958: 9750, - 1964: 9750 - } - - // Reference: Artikel 1 G. v. 20.04.2007 BGBl. I S. 554. - from 2008-01-01 = { - 1947: 33800, - 1948: 9750, - 1958: 9900, - 1964: 10050 - } - - // Reference: G. v. 20.12.2022 BGBl. I S. 2328. (Bürgergeld-Gesetz) - from 2023-01-01 = { - 1947: null, - 1948: null, - 1958: null, - 1964: null - } - } - -/** - * Schonvermögen beim Bürgergeld - * Seit der Einführung des Bürgergelds zum 01.01.2023 gilt ein Vermögensfreibetrag - * von 15.000 Euro pro Mitglied der Bedarfsgemeinschaft nach Ablauf der Karenzzeit - * von einem Jahr. Während der Karenzzeit ist ein Vermögen von 40.000 Euro für die - * erste Person einer Bedarfsgemeinschaft und 15.000 Euro für jede weitere erlaubt. - */ - const arbeitslosenGeldSchonvermoegenBuergergeld: Dict { - // Reference: G. v. 20.12.2022 BGBl. I S. 2328. (Bürgergeld-Gesetz) - from 2023-01-01 = { - während_karenzzeit: 40000, - normaler_satz: 15000 - } - } - -/** - * Vermögensfreibetrag für Erstausstattung - * § 12 (2) Satz 1 Nr. 4 SGB II. - */ -const arbeitslosenGeldVermoegensfreibetragAusstattung: Int { - // Reference: Artikel 1 G. v. 24.12.2003 BGBl. I S. 2954. - from 2005-01-01 = 750; - - // Reference: G. v. 20.12.2022 BGBl. I S. 2328. (Bürgergeld-Gesetz) - from 2023-01-01 = null; -} - -/** - * Vermögensgrundfreibetrag je Kind - * § 12 (2) Satz 1 Nr. 1 SGB II. - */ -const arbeitslosenGeldVermoegensfreibetragKind: Int { - // Reference: Artikel 1 G. v. 24.12.2003 BGBl. I S. 2954. - from 2005-01-01 = 4100; - - // Reference: Artikel 1 G. v. 20.07.2006 BGBl. I S. 1706. - from 2006-08-01 = 3100; - - // Reference: G. v. 20.12.2022 BGBl. I S. 2328. (Bürgergeld-Gesetz) - from 2023-01-01 = null; -} - -/** - * Altersgrenzen für Vermögensfreibetrag - * Vermögensfreibetrag ändert sich nach Geburtsjahr - */ -const arbeitslosenGeldVermoegensfreibetragAlter: Dict { - 2005-01-01: { - 1: 1948, - 2: 1958, - 3: 1963 - } - - // Reference: G. v. 20.12.2022 BGBl. I S. 2328. (Bürgergeld-Gesetz) - 2023-01-01: { - 1: null, - 2: null, - 3: null - } -} - -/** - * Abzugsfähige Pauschalen für Werbungskosten und Versicherung - * § 6 (1) Nr. 3 a) ALG II-V. 2005-01.01 bis 2016-07-31. Betrag mit V. v. 26.07 - * .2016 BGBl. I S. 1858 entfallen. Wie entfallen? - * § 3 Alg II-V. Seit 01.01.2008 in § 6 Alg II-V. - */ -const arbeitslosenGeldAbzugfaehigePauschale: Dict { - // Reference: V. v. 20.10.2004 BGBl. I S. 2622 - from 2005-01-01 = { - werbung: 15.33, - versicherung: 30.0 - } - - // Reference: V. v. 21.06.2011 BGBl. I S. 1175. - from 2011-01-01 = { - werbung: 15.33, - versicherung: 30.0 - } -} - -/** - * Obergenze Miete pro Quadratmeter - * Die Miete pro Quadratmeter darf einen angemessenen Betrag nicht übersteigen, um - * für ALG2 berechtigt zu sein. Diese Grenze ist nicht konkret im Gesetz - * festgehalten, sondern wird als Faustregel von den Arbeitsargenturen verwendet. - * § 22 SGB II - * unit: Euro / Quadratmeter - */ -const arbeitslosenGeldMaxMieteProQuadratMeter: Int { - from 1984-01-01 = 10 -} - -/** - * Berechtigte Miet-Wohnfläche für ALG2-Empfänger*innen - * Eine Mietwohnung darf für einen Single 45 Quadratmeter (+15 für jede weitere - * Person) groß sein. - */ -const arbeitslosenGeldBerechtigteWohnflaecheMiete: Dict { - from 1984-01-01 = { - single: 45, - je_weitere_person: 15 - } -} - -/** - * Berechtigte Eigentumsfläche für ALG2-Empfänger*innen - * Vor 2023 gilt, dass Eigentum für zwei Personen im Haushalt 80 Quadratmeter (+20 - * für jede weitere Person) groß sein darf. Ab 2023 ist die erlaubte Größe für - * Eigenheime auf 140 Quadratmeter (für Eigentumswohnungen aus 130 Quadratmeter) - * gestiegen und wird ab 5 Personen im Haushalt um 20 Quadratmeter pro Person - * angehoben. - */ -const arbeitslosenGeldBerechtigteWohnflaecheEigentum: Dict { - from 1984-01-01 = { - 1: 80, - 2: 80, - 3: 100, - 4: 120, - je_weitere_person: 20 - } - - // Reference: Art. 1 Nr.12 Abschnitt 5, G. v. 20.12.2022 BGBl. I S. 2328 - from 2023-01-01 = { - 1: 140, - 2: 140, - 3: 140, - 4: 140, - je_weitere_person: 20 - } -} - -// arbeitsl_geld.yaml ---------------------------------------------------- - -/** - * Income which is not deducted from unemployment benefit. - * § 155 SGB III, vorher § 141 (1) S. 1 - */ -public const arbeitslosenGeldFreibetrag: Int { - // Art. 1 G. v. 21.07.1999 BGBl. I S. 1648 - from 1999-08-01 = 161; - - // Art. 3 G. v. 21.12.2000 BGBl. I S. 1983 - from 2002-01-01 = 165; -} - -/** - * Fictitious social insurance contribution rate - * § 153 (1) Nr. 1 SGB III. Wird angewendet auf das Bemessungsentgelt. ACHTUNG! Beim - * Elterngeld gibt es eine ähnliche Größe. - */ -public const arbeitslosenGeldSozialVersicherungsPauschale: Float { - from 1984-01-01 = 0.1727; - from 1985-01-01 = 0.1745; - from 1986-01-01 = 0.1775; - from 1987-01-01 = 0.1774; - from 1988-01-01 = 0.1794; - from 1989-01-01 = 0.1795; - from 1990-01-01 = 0.1775; - from 1991-01-01 = 0.179; - from 1992-01-01 = 0.184; - from 1993-01-01 = 0.187; - from 1994-01-01 = 0.1955; - from 1995-01-01 = 0.1915; - from 1996-01-01 = 0.1995; - from 1997-01-01 = 0.2095; - from 1998-01-01 = 0.2105; - from 2000-01-01 = 0.20535; - from 2001-01-01 = 0.2044; - from 2002-01-01 = 0.2065; - from 2003-01-01 = 0.2105; - from 2004-01-01 = 0.2095; - from 2005-01-01 = 0.2074; - from 2006-01-01 = 0.2141; - from 2007-01-01 = 0.2075; - from 2008-01-01 = 0.20475; - from 2009-01-01 = 0.20525; - from 2010-01-01 = 0.20225; - from 2011-01-01 = 0.20625; - - // Reference: Art. 2 G. v. 20.12.2011 BGBl. I S. 2854 - from 2012-01-01 = 0.21; - - // Reference: Art. 1 G. v. 18.12.2018 BGBl. I S. 2651 - from 2019-01-01 = 0.2; -} - -/** - * Replacement Rate Unemployment Benefit, for childless persons. - * §149 Nr. 2 SGB III, vorher § 129 (2) SGB III. Höhe des Arbeitslosengeldes im - * Verhältnis zum letzten Nettoentgelt bei Personen ohne Kinder im Sinne des EStG. - */ -public const arbeitslosenGeldSatzOhneKinder: Float { - // Reference: Art. 1 G. v. 24.03.1997 BGBl. I S. 594 - from 1998-08-01 = 0.6; -} - -/** - * Replacement Rate Unemployment Benefit for persons with children. - * §149 Nr. 1 SGB III, vorher §129 Nr. 1 SGB III. Höhe des Arbeitslosengeldes im - * Verhältnis zum letzten Nettoentgelt bei Personen mit Kindern im Sinne des EStG - */ -public const arbeitslosenGeldSatzMitKindern: Float { - // Reference: Art. 1 G. v. 24.03.1997 BGBl. I S. 594 - from 1998-08-01 = 0.67; -} - -/** - * Working hours limit to receive unemployment benefit - * §138 (3) SGB III, früher auch §102 (2) AFG. Grenze, ab der nicht mehr - * Arbeitslosigkeit unterstellt wird. - */ -public const arbeitslosenGeldStundengrenze: Int { - from 1969-07-01 = 20; - // Reference: Art. 1 G. v. 20.12.1985 BGBl I S. 2484 - from 1986-01-01 = 19; - - // Reference: Art. 1 G. v. 20.12.1988 BGBl I S. 2343 - from 1989-01-01 = 18; - - // Reference: Art. 2 G. v. 20.12.2011 BGBl I S. 2854 - from 2012-04-01 = 15; -} - -/** - * Length of ALG 1 eligibility - * Dauer des Anspruchs auf ALG 1 richtet sich nach Alter und wie viele Monate - * eine Person versicherungsplichtig in den letzten 5 Jahren war. - */ -public const arbeitslosenGeldAnspruchsdauer: Dict { - from 1997-03-24 = { - nach_alter: { - 0: 12 - 50: 15 - 55: 18 - 58: 24 - }, - nach_versicherungspflichtige_monate: { - 12: 6 - 18: 8 - 20: 10 - 24: 12 - 30: 15 - 36: 18 - 48: 24 - } - } -} - -// eink_st_abzuege.yaml -------------------------------------------------- - -/** - * Kinderfreibetrag - * sächliches Existenzminimum des Kindes, seit 2000 auch der Freibetrag für - * Betreuungs-, Erziehungs- und Ausbildungskosten. Wird verdoppelt für gemeinsam - * veranlagte Paare. §32 (6) EStG, seit 2000. - * Pro Jahr - */ -const einkommensSteuerKinderFreibetrag: Dict { - // Reference: Art. 1 G. v. 23.12.1982 BGBl. I S. 1857. - from 1983-01-01 = { - saechlichesExistenzminimum: 110 - } - - // Reference: Art. 1 G. v. 26.06.1985 BGBl. I S. 1153. - from 1986-01-01 = { - saechlichesExistenzminimum: 635 - } - - // Reference: Artikel 1 G. v. 25.07.1988 BGBl. I S. 1093. - from 1990-01-01 = { - saechlichesExistenzminimum: 773 - } - - // Reference: Art. 1 G. v. 25.02.1992 BGBl. I S. 297. - from 1992-01-01 = { - saechlichesExistenzminimum: 1049 - } - - // Reference: Art. 1. G. v. 11.10.1995 BGBl. I S. 1250. - from 1996-01-01 = { - saechlichesExistenzminimum: 1601 - } - - from 1997-01-01 = { - saechlichesExistenzminimum: 1767 - } - - // Reference: Art. 1 G. v. 28.12.1999 BGBl. I. S. 2552. - from 2000-01-01 = { - beitragErziehungAusbildung: 774, - saechlichesExistenzminimum: 1767 - } - - // Reference: Art. 1 G. v. 16.08.2001 BGBl. I S. 2074 - from 2002-01-01 = { - beitragErziehungAusbildung: 1080, - saechlichesExistenzminimum: 1824 - } - - // Reference: Art. 1 G. v. 22.12.2008 BGBl. I S. 2955 - from 2009-01-01 = { - beitragErziehungAusbildung: 1080, // previous - saechlichesExistenzminimum: 1932 - } - - // Reference: Art. 1 G. v. 22.12.2009 BGBl. I S. 3950 - from 2010-01-01 = { - beitragErziehungAusbildung: 1320, - saechlichesExistenzminimum: 2184 - } - - // Reference: Art. 1 G. v. 16.07.2015 BGBl. I S. 1202 - from 2015-01-01 = { - beitragErziehungAusbildung: 1320, // previous - saechlichesExistenzminimum: 2256 - } - - // Reference: Art. 2 G. v. 16.07.2015 BGBl. I S. 1202 - from 2016-01-01 = { - beitragErziehungAusbildung: 1320, // previous - saechlichesExistenzminimum: 2304 - } - - // Reference: Art. 8 G. v. 20.12.2016 BGBl. I. S. 3000 - from 2017-01-01 = { - beitragErziehungAusbildung: 1320, // previous - saechlichesExistenzminimum: 2358 - } - - // Reference: Art. 9 G. v. 20.12.2016 BGBl. I. S. 3000 - from 2018-01-01 = { - beitragErziehungAusbildung: 1320, // previous - saechlichesExistenzminimum: 2394 - } - - // Reference: Art. 1 G. v. 29.11.2018 BGBl. I S. 2210 - from 2019-01-01 = { - beitragErziehungAusbildung: 1320, // previous - saechlichesExistenzminimum: 2490 - } - - // Reference: Art. 3 G. v. 29.11.2018 BGBl. I S. 2210 - from 2020-01-01 = { - beitragErziehungAusbildung: 1320, // previous - saechlichesExistenzminimum: 2586 - } - - // Reference: Art. 1 G. v. 01.12.2020 BGBl. I S. 2616 - from 2021-01-01 = { - saechlichesExistenzminimum: 2730, - beitr_erz_ausb: 1464 - } - - // Reference: Art. 1 G. v. 08.12.2022 BGBl. I S. 2230. - from 2022-01-01 = { - beitragErziehungAusbildung: 2730, // previous - saechlichesExistenzminimum: 2810 - } - - // Reference: Art. 2 G. v. 08.12.2022 BGBl. I S. 2230. - from 2023-01-01 = { - beitragErziehungAusbildung: 2730, // previous - saechlichesExistenzminimum: 3012 - } - - // Reference: Art. 3 G. v. 08.12.2022 BGBl. I S. 2230. - from 2024-01-01 = { - beitragErziehungAusbildung: 2730, // previous - saechlichesExistenzminimum: 3192 - } -} - -/** - * Vorwegabzug der Vorsorgeaufwendungen der Rechtslage vor 2004. - * § 10 (4a) EStG. Früher §10 (3) EStG. Hier steht jeweils der Wert für den - * Steuerpflichtigen. Wird verdoppelt für gemeinsam veranlagte Ehegatten. Der gesamte - * Zeitverlauf wurde bereits 2005 festgelegt. - */ -const vorsorge2004Vorwegabzug: Int { - from 1985-01-01 = 1534 - from 1989-01-01 = 2045 - from 1993-01-01 = 3068 - from 2011-01-01 = 2700 - from 2012-01-01 = 2400 - from 2013-01-01 = 2100 - from 2014-01-01 = 1800 - from 2015-01-01 = 1500 - from 2016-01-01 = 1200 - from 2017-01-01 = 900 - from 2018-01-01 = 600 - from 2019-01-01 = 300 -} - -/** - * Werbungskostenpauschbetrag bei nichtselbstständiger Arbeit. - * § 9a Nr. 1a) EStG - * This is the minimum amount deducted from any employment income. - */ -const werbungskostenpauschbetrag: Int { - from 1975-01-01 = 288 - from 1990-01-01 = 1044 - from 2004-01-01 = 920 - - // Reference: Art. 1 G. v. 01.11.2011 BGBl. I S. 2131. - from 2012-01-01 = 1000 - - // Reference: Art. 2 G. v. 23.05.2022 BGBl. I S. 749 - from 2022-01-01 = 1200 - - // Reference: G. v. 20.12.2022 BGBl. I S. 2294. - from 2023-01-01 = 1230 -} - -/** - * Sonderausgaben-Pauschbetrag - * § 10c EStG - */ -const sonderausgabenpauschbetrag: Int { - from 1984-01-01 = 138 - - // Reference: Art. 1 G. v. 25.07.1988, BGBl. I S. 1093 - from 1988-01-01 = 55 - - // Reference: Art. 1 G. v. 19.12.2000, BGBl. I S. 1790 - from 2002-01-01 = 36 -} - -/** - * Sparerpauschbetrag - * § 20 (9) EStG. Früher § 20 (4) EStG. Wert für Singles. Wird verdoppelt für - * gemeinsam veranlagte. seit 2009. vor 2008 Sparerfreibetrag. - */ -const sparerpauschbetrag: Int { - from 1975-01-01 = 153 - from 1990-01-01 = 307 - from 1993-01-01 = 3068 - from 2000-01-01 = 1534 - - // Reference: Art. 1 G. v. 19.12.2000 BGBl I S. 1790. - from 2002-01-01 = 1550 - from 2004-01-01 = 1370 - from 2007-01-01 = 750 - - // Reference: Art. 1 G. v. 14.08.2007 BGBl. I S. 1912 - from 2009-01-01 = 801 - - // Reference: G. v. 20.12.2022 BGBl. I S. 2294. - from 2023-01-01 = 1000 -} - -/** - * Sparerpauschbetrag - * § 20 (9) EStG. Früher § 20 (4) EStG. Wert für Singles. Wird verdoppelt für - * gemeinsam veranlagte. seit 2009. vor 2008 Sparerfreibetrag. - */ -const sparerWerbungskostenPauschbetrag: Int { - from 1975-01-01 = 51 - from 2009-01-01 = 0 -} - -/** - * Allgemeine Vorsorgepauschale Grundhöchstbetrag, Grundtabelle - * §10 (3) EStG bis 2004. - */ -const vorsorge2004Grundhoechstbetrag: Int { - from 1985-01-01 = 1196 - from 1992-01-01 = 1334 -} - -/** - * Höchstbetrag des Altersentlastungsbetrags - * 24a EStG S. 5. Tabelle legt die Werte bis 2040 fest. Bis 2004 erhalten alle - * Steuerpflichtigen, die im voherigen Kalenderjahr das 64. Lebensjahr vollendet - * haben, maximal den gleichen Altersentlastungsbetrag. Ab 2005 hängt dieser Betrag, - * den diese Steuerpflichtigen erhalten, vom Geburtsjahr ab. - */ -const altersentlastungsbetragMax: Int | Dict { - from 1984-01-01 = 1534 - from 1989-01-01 = 1902 - from 2002-01-01 = 1908 - - // Reference: Artikel 1 G. v. 05.07.2004 BGBl. I S. 1427. - 2005-01-01 = { - 1940: 1900, - 1941: 1824, - 1942: 1748, - 1943: 1672, - 1944: 1596, - 1945: 1520, - 1946: 1444, - 1947: 1368, - 1948: 1292, - 1949: 1216, - 1950: 1140, - 1951: 1064, - 1952: 988, - 1953: 912, - 1954: 836, - 1955: 760, - 1956: 722, - 1957: 684, - 1958: 646, - 1959: 608, - 1960: 570, - 1961: 532, - 1962: 494, - 1963: 456, - 1964: 418, - 1965: 380, - 1966: 342, - 1967: 304, - 1968: 266, - 1969: 228, - 1970: 190, - 1971: 152, - 1972: 114, - 1973: 76, - 1974: 38, - 1975: 0 - } -} - -/** - * Anteil des Altersentlastungsbetrags - * §24a EStG S.5. Tabelle legt alle Werte bis 2040 fest. Bis 2004 wird bei allen - * Steuerpflichtigen, die im voherigen Kalenderjahr das 64. Lebensjahr vollendet - * haben, die gleiche Altersentlastungsquote abgezogen. Ab 2005 hängt diese Quote, - * den diese Steuerpflichtigen erhalten, vom Geburtsjahr ab. - */ -const altersentlastungQuote: Float | Dict { - from 1984-01-01 = 0.4 - - // Reference: Artikel 1 G. v. 05.07.2004 BGBl. I S. 1427. - 2005-01-01 = { - 1940: 0.4, - 1941: 0.384, - 1942: 0.368, - 1943: 0.352, - 1944: 0.336, - 1945: 0.32, - 1946: 0.304, - 1947: 0.288, - 1948: 0.272, - 1949: 0.256, - 1950: 0.24, - 1951: 0.224, - 1952: 0.208, - 1953: 0.192, - 1954: 0.176, - 1955: 0.16, - 1956: 0.152, - 1957: 0.144, - 1958: 0.136, - 1959: 0.128, - 1960: 0.12, - 1961: 0.112, - 1962: 0.104, - 1963: 0.096, - 1964: 0.088, - 1965: 0.08, - 1966: 0.072, - 1967: 0.064, - 1968: 0.056, - 1969: 0.048, - 1970: 0.04, - 1971: 0.032, - 1972: 0.024, - 1973: 0.016, - 1974: 0.008, - 1975: 0 - } -} - -/** - * Altersgrenze für Altersentlastungsbetrag - * Der Altersentlastungsbetrag wird einem Steuerpflichtigen gewährt, der vor dem - * Beginn des Kalenderjahres, in dem er sein Einkommen bezogen hat, das 64. - * Lebensjahr vollendet hatte. - * Reference: § 24a Art. 3 EStG - */ -const altersentlastungsbetragAltersgrenze: Int { - from 1984-01-01 = 64 -} - -/** - * Einführungsfaktor für Altersvorsorge Aufwendung - * In den Jahren 2005-2022 stieg der Anteil der abzugsfähigen Beiträge von 60% in - * 2005 jährlich um 2 Prozentpunkte an bis 94% in 2022 erreicht wurden. Eigentlich - * war geplant, dass der Parameter weiter mit dieser Rate steigt, bis ab 2025 100% - * erreicht sind. Abweichend von diesem Plan, wurden die abzugfähigen Beiträge schon - * 2023 auf 100% gesetzt. - * Reference: § 10 Abs. 1 Nr. 2 Buchst. a und b EStG - */ -const einfuehrungsfaktor: { - from 2005-01-01 = { - 0: {lower_threshold: -inf, rate_linear: 0, intercept_at_lower_threshold: 0.6}, - 1: {lower_threshold: 2005, upper_threshold: 2025, rate_linear: 0.02}, - 2: {upper_threshold: inf, rate_linear: 0} - } - - // Reference: G. v. 20.12.2022 BGBl. I S. 2294. - from 2023-01-01 = { - 0: {lower_threshold: -inf, rate_linear: 0, intercept_at_lower_threshold: 0.6}, - 1: {lower_threshold: 2005, rate_linear: 0.02}, - 2: {lower_threshold: 2022, upper_threshold: 2023, rate_linear: 0.06}, - 3: {upper_threshold: inf, rate_linear: 0} - } -} - -/** - * Entlastungsbetrag für Alleinerziehende - * § 24b (1) EStG. vor 2004 "Haushaltsfreibetrag", § 32 (7) EStG - */ -const alleinerzFreibetrag: Int { - from 1984-01-01 = 2154 - from 1986-01-01 = 2319 - from 1989-01-01 = 2871 - from 2001-01-01 = 2916 - from 2002-01-01 = 2340 - from 2004-01-01 = 1308 - - // Reference: Art. 1 G. v. 16.07.2015 BGBl. I S.1202 - from 2015-01-01 = 1908 - - // Reference: Art. 3 Nr. 2 G. v. 29.12.2020 BGBl. I S.3096 - from 2020-01-01 = 4008 - - // Reference: G. v. 20.12.2022 BGBl. I S. 2294. - from 2023-01-01 = 4260 -} - -/** - * Entlastungsbetrag für Alleinerziehende, Zusatzbetrag - * §24b (2) S. 2 EStG. Alleinerziehenden-Entlastungsbetrag, Zusatzbetrag pro Kind ab - * dem 2. Kind. - */ -const alleinerzFreibetragZusatz: Int { - // Reference: Art. 1 G. vs. 16.07.2015 BGBl. I S.1202 - from 2015-01-01 = 240 -} - -/** - * Kürzung des Vorwegabzugs für Vorsorgeaufwendungen vor 2004. - * §10 (3) S. 2 EStG (vor 2004). Der Vorwegabzug wird pauschal um einen Anteil - * gekürzt bei abhängig Beschäftigten (vereinfacht). - */ -const vorsorge2004KuerzungVorwegabzug: Float { - from 1985-01-01 = 0.0935 - from 1986-01-01 = 0.096 - from 1987-01-01 = 0.0935 - - // Reference: Art. 1 G. v. 25.07.1988 BGBl. I S. 1093 - from 1989-01-01 = 0.12 - - // Reference: Art. 1 G. v. 21.12.1993 BGBl. I S. 2310. - from 1994-01-01 = 0.16 -} - -/** - * Regulärer Maximalbetrag für sonstige Vorsorgeaufwendungen (Kranken-, Pflege, - * AL-V), der für sozialverspfl. Beschäftigte gilt. - * §10 Abs. 4 S.1 EStG - */ -const vorsorgeSonstigeAufwendungenMax: Int { - // Reference: Art. 1 G. v. 05.07.2004 BGBl. I S.1427 - from 2005-01-01 = 1500 - - // Reference: Art. 1 G. v. 23.07.2009 BGBl. I S.1959. - from 2010-01-01 = 1900 -} - -/** - * Maximalbetrag der Altersvorsorgeaufwendungen, 2005er Rechtsstand - * §10 (3) EStG, Anlage 2 SGB VI - */ -const vorsorgeAltersvorsorgeaufwendungenMax: Int { - // Art. 1 G. v. 05.07.2004 BGBl. I S.1427 - from 2005-01-01 = 20000 - - // Ab 2015 knappschaftlicher Höchstbetrag, d.h. knappschaftlicher Beitragssatz * - // knappschaftliche Beitragsbemessungsgrenze - from 2015-01-01 = 22170 - - // .248 * 91800 - from 2016-01-01 = 22766 - - // .247 * 94200 - from 2017-01-01 = 23362 - - // .247 * 96000 - from 2018-01-01 = 23712 - - // .247 * 98400 - from 2019-01-01 = 24305 - - // .247 * 101400 - // Reference: Art. 3 V. v. 17.12.2019 BGBl I S. 2848. - from 2020-01-01 = 25046 - - // .247 * 104400 - // Reference: §3 V. v. 30.11.2020 BGBl. I S. 2612. - from 2021-01-01 = 25787 - - // .247 * 103800 - // Reference: §3 V. v. 30.11.2021, BGBl. I S. 5044. - from 2022-01-01 = 25640 -} - -/** - * Anteil, um den Krankenversicherungsbeiträge gemindert werden bei abhängig - * Beschäftigten. - * §10 (3) a) S.4 EStG - */ -const vorsorgeKrankenMinderung: Float { - // Reference: Art. 1 G. v. 16.07.2009 BGBl. I S. 1959 - from 2009-07-23 = 0.04 -} - -/** - * Behinderten-Pauschbetrag, in Abhängigkeit des Behinderungsgrads. - * § 33b (3) EStG. - */ -const behindertenPauschbetrag: Dict { - // Reference: G. v. 05.08.1974 BGBl. I S. 1769. - from 1975-01-01 = { - 0: 0, - 25: 307, - 35: 429, - 45: 568, - 55: 721, - 65: 890, - 75: 1058, - 85: 1227, - 95: 1411 - } - - // Reference: Art. 1 G. v. 19.12.2000 BGBl. I S. 1790. - from 2002-01-01 = { - 0: 0, - 25: 310, - 35: 430, - 45: 570, - 55: 720, - 65: 890, - 75: 1060, - 85: 1230, - 95: 1420 - } - - // Reference: Art. 1 G. v. 09.12.2020 BGBL. I S. 2770. - from 2021-01-01 = { - 0: 0, - 20: 384, - 30: 620, - 40: 860, - 50: 1140, - 60: 1440, - 70: 1780, - 80: 2120, - 90: 2460, - 100: 2840 - } -} - -/** - * Anteil der Betreuungsaufwendungen, der auf das zu versteuernde Einkommen - * anrechenbar ist - * §10 (1) Nr. 5 EStG - */ -const kinderbetreuungskostenAbzAnteil: Float { - // Reference: Art. 1 G. v. 01.11.2011 BGBl. I S.2131 - from 2012-01-01 = 0.6666666 -} - -/** - * Maximal abziehbare Betreuungsaufwendungen pro Kind - * §10 (1) Nr. 5 EStG - */ -const kinderbetreuungskostenAbzMaximum: Int { - // Reference: Art. 1 G. v. 01.11.2011 BGBl. I S.2131 - from 2012-01-01 = 4000 -} - -/** - * Anteil abgezogene Rentenversicherungsbeiträge - * §10 (3) a) S.4 EStG - */ -const vorsorgepauschaleRentenversicherungsAnteil: Dict> { - 2005-01-01 = { - 0: { - lower_threshold: -inf, - upper_threshold: 2005, - rate_linear: 0, - intercept_at_lower_threshold: 0.2 - }, - 1: { - lower_threshold: 2005, - upper_threshold: 2025, - rate_linear: 0.04, - intercept_at_lower_threshold: 0.2 - }, - 2: { - lower_threshold: 2025, - upper_threshold: inf, - rate_linear: 0, - intercept_at_lower_threshold: 1 - } - } - - 2023-01-01 = { - 0: { - lower_threshold: -inf, - rate_linear: 0, - intercept_at_lower_threshold: 0.2 - }, - 1: { - lower_threshold: 2005, - rate_linear: 0.04 - }, - 2: { - lower_threshold: 2022, - upper_threshold: 2023, - rate_linear: 0.12 - }, - 3: { - lower_threshold: 2023, - upper_threshold: inf, - rate_linear: 0 - } - } -} - -/** - * Mindestanteil für Mindestvorsorgepauschale - * Mindestanteil an Beiträgen zu GKV und GPV, der abgesetzt wird bei - * Mindestvorsorgepauschale - * Reference: 39b (2) Nr.3 EStG - */ -const vorsorgepauschaleMindestanteil: Float { - // Reference: Art. 1 G. v. 16.07.2009 BGBl. I S. 1959 - from 2009-07-23 = 0.12 -} - -/** - * Höchstbetrag Mindestvorsorgepauschale - * Höchsbetrag für Mindestvorsorgepauschale der Beiträge zu GKV und PKV, die von der - * Lohnsteuer abgesetzt werden können. - * Reference: 39b (2) Nr.3 EStG. Depends on Steuerklasse. - */ -const vorsorgepauschaleKvMax: Dict { - // Reference: Art. 1 G. v. 16.07.2009 BGBl. I S. 1959 - from 2009-07-23 = { - steuerklasse_3: 3000, - steuerklasse_nicht3: 1900 - } -} - -// TODO: rounding - -// eink_st.yaml ---------------------------------------------------------- - -/** - * Einkommenssteuer Tarif - * §32a EStG - * Der quadratische Anstieg in den mittleren Intervallen wird nach der Formel - * des Progressionsfaktors berechnet. Einzelheiten sind im docstring der Funktion - * add_progressionsfaktor beschrieben. - */ -const eink_st_tarif: Dict> { - - // TODO: klären wie das mit deviation_from aussieht - - - from 2002-01-01 = { - 0: {lower_threshold: -inf, upper_threshold: 7235, rate_linear: 0, rate_quadratic: 0, intercept_at_lower_threshold: 0}, - 1: {upper_threshold: 9251, rate_linear: 0.199}, - 2: {upper_threshold: 55007, rate_linear: 0.23}, - 3: {upper_threshold: inf, rate_linear: 0.485, rate_quadratic: 0} - } - - from 2004-01-01 = { - 0: {lower_threshold: -inf, upper_threshold: 7664, rate_linear: 0, intercept_at_lower_threshold: 0}, - 1: {upper_threshold: 12739, rate_linear: 0.16}, - 2: {upper_threshold: 52151, rate_linear: 0.2405}, - 3: {upper_threshold: inf, rate_linear: 0.45, rate_quadratic: 0} - } - - from 2005-01-01 = { - 0: {lower_threshold: -inf, upper_threshold: 7664, rate_linear: 0, rate_quadratic: 0, intercept_at_lower_threshold: 0}, - 1: {upper_threshold: 12739, rate_linear: 0.15}, - 2: {upper_threshold: 52151, rate_linear: 0.2397}, - 3: {upper_threshold: inf, rate_linear: 0.42, rate_quadratic: 0} - } - - from 2007-01-01 = { - 0: {lower_threshold: -inf, upper_threshold: 7664, rate_linear: 0, rate_quadratic: 0, intercept_at_lower_threshold: 0}, - 1: {upper_threshold: 12739, rate_linear: 0.15}, - 2: {upper_threshold: 52151, rate_linear: 0.2397}, - 3: {upper_threshold: 250000, rate_linear: 0.42, rate_quadratic: 0}, - 4: {upper_threshold: inf, rate_linear: 0.45, rate_quadratic: 0} - } - - from 2009-01-01 = { - deviation_from: previous, - 0: {upper_threshold: 7834}, - 1: {upper_threshold: 13139, rate_linear: 0.14}, - 2: {upper_threshold: 52551}, - 3: {upper_threshold: 250400} - } - - from 2010-01-01 = { - deviation_from: previous, - 0: {upper_threshold: 8004}, - 1: {upper_threshold: 13469}, - 2: {upper_threshold: 52881}, - 3: {upper_threshold: 250730} - } - - from 2013-01-01 = { - deviation_from: previous, - 0: {upper_threshold: 8130} - } - - from 2014-01-01 = { - // Reference: G. v. 20.2.2013, BGBl I S.283 - deviation_from: previous, - 0: {upper_threshold: 8354} - } - - from 2015-07-01 = { - // Reference: G. v. 15.07.2015, BGBl. Nr. 30 2015 - deviation_from: previous, - 0: {upper_threshold: 8472} - } - - from 2016-01-01 = { - // Reference: G. v. 15.07.2015, BGBl. Nr. 30 2015 - deviation_from: previous, - 0: {upper_threshold: 8652}, - 1: {upper_threshold: 13669}, - 2: {upper_threshold: 53665}, - 3: {upper_threshold: 254446} - } - - from 2017-01-01 = { - // Reference: Artikel 8 G. v. 20.12.2016, BGBl I S. 3000 - deviation_from: previous, - 0: {upper_threshold: 8820}, - 1: {upper_threshold: 13769}, - 2: {upper_threshold: 54057}, - 3: {upper_threshold: 256303} - } - - from 2018-01-01 = { - // Reference: Artikel 9 G. v 23.12.2016, BGBL I, S. 3000 - deviation_from: previous, - 0: {upper_threshold: 9000}, - 1: {upper_threshold: 13996}, - 2: {upper_threshold: 54949}, - 3: {upper_threshold: 260532} - } - - from 2019-01-01 = { - deviation_from: previous, - 0: {upper_threshold: 9169}, - 1: {upper_threshold: 14255}, - 2: {upper_threshold: 55961}, - 3: {upper_threshold: 265327} - } - - from 2020-01-01 = { - // Reference: Art. 3 G. v. 29.11.2018 BGBl. I S. 2210 - deviation_from: previous, - 0: {upper_threshold: 9408}, - 1: {upper_threshold: 14532}, - 2: {upper_threshold: 57051}, - 3: {upper_threshold: 270501} - } - - from 2021-01-01 = { - // Reference: Art. 1 G. v. 01.12.2020 BGBl. I S. 2616 - deviation_from: previous, - 0: {upper_threshold: 9744}, - 1: {upper_threshold: 14753}, - 2: {upper_threshold: 57918}, - 3: {upper_threshold: 274613} - } - - from 2022-01-01 = { - // Reference: Art. 1 G. v. 23.05.2022 BGBl. I S. 749 - deviation_from: previous, - 0: {upper_threshold: 10347}, - 1: {upper_threshold: 14926}, - 2: {upper_threshold: 58596}, - 3: {upper_threshold: 277826} - } - - from 2023-01-01 = { - // Reference: Art. 2 G. v. 08.12.2022 BGBl. I S. 2230., - deviation_from: previous, - 0: {upper_threshold: 10909}, - 1: {upper_threshold: 16000}, - 2: {upper_threshold: 62810}, - 3: {upper_threshold: 277826} - } - - from 2024-01-01 = { - // Reference: Art. 3 G. v. 08.12.2022 BGBl. I S. 2230. - deviation_from: previous, - 0: {upper_threshold: 11605}, - 1: {upper_threshold: 17006}, - 2: {upper_threshold: 66761}, - 3: {upper_threshold: 277826} - } -} - -/** - * Ertragsanteil-Funktion für den Anteil an sozialversicherungspflichtigen - * Renteneinkommen, der versteuert werden muss (piecewise linear) - * § 22 EStG - * Diese Funktion ist hier ab 2002 angegeben. Vor 2002 das Steuersystem ist nicht - * implementiert. - */ -const renteErtragsanteil: Dict> { - from 2002-01-01 = { - 0: {lower_threshold: -inf, upper_threshold: 2005, rate_linear: 0, intercept_at_lower_threshold: 0.27}, - 1: {lower_threshold: 2005, upper_threshold: 2021, rate_linear: 0.02, intercept_at_lower_threshold: 0.5}, - 2: {lower_threshold: 2021, upper_threshold: 2041, rate_linear: 0.01, intercept_at_lower_threshold: 0.8}, - 3: {lower_threshold: 2041, upper_threshold: inf, rate_linear: 0.0, intercept_at_lower_threshold: 1} - } -} - -// TODO: rounding - -// elterngeld.yaml ------------------------------------------------------- - -/** - * Faktor bei der ElG-Berechung, 2. Stufe - * § 2 (1) BEEG - */ -const elterngeldFaktor: Float { - from 2007-01-01 = 0.67 -} - -/** - * Höchstbetrag des Elterngeldes - * § 2 (1) BEEG - */ -const elterngeldHoechstbetrag: Int { - from 2007-01-01 = 1800 -} - -/** - * Nettoeinkommen an 1. und 2. Stufe - * § 2 (2) BEEG. Maßgeblich ist das durchschnittlich erzielte monatliche Einkommen - * vor der Geburt - */ -const elterngeldNettoeinkommenStufen: Dict { - // Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 - from 2007-01-01 = { - 1: 1000, - 2: 1001 - } - - // Reference: Art. 14 G. v. 09.12.2010 BGBl. I S. 1885 - from 2011-01-01 = { - 1: 1000, - 2: 1201 - } -} - -/** - * Mindestbetrag des Elterngeldes - * § 2 (5) BEEG - */ -const elterngeldMindestbetrag: Int { - // Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 - from 2007-01-01 = 300 -} - -/** - * Korrektur des Prozentsatzes für hohe und niedrige Einkommen - * § 2 (2) BEEG - */ -const elterngeldProzentKorrektur: Float { - // Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 - from 2007-01-01 = 0.001 -} - -/** - * Minimaler Anteil des Elterngelds am vorherigen Nettoeinkommen - * § 2 (2) BEEG - */ -const elterngeldProzentMinimum: Float { - from 2007-01-01 = 0.67 - - // Reference: Art. 14 G. v. 09.12.2010 BGBl. I S. 1885 - from 2011-01-01 = 0.65 -} - -/** - * Einkommensschritte für die Korrektur - * § 2 (2) BEEG - */ -const elterngeldEinkommensSchrittKorrektur: Int { - // Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 - from 2007-01-01 = 2 -} - -/** - * Altersgrenzen für Geschwisterbonus - * Leben im Haushalt zwei Kinder unter 3 Jahren oder mehr als zwei unter 6 Jahren - * wird das Elterngeld um 10% (max. um 75€) erhöht. - * Reference: § 2a BEEG - */ -const elterngeldGeschwisterbonusAltersgrenzenKinder: Dict { - from 2007-01-01 = { - 3: 2, - 6: 3 - } -} - -/** - * Geschwisterbonus als prozentualer Aufschlag - * § 2a (1) BEEG. Früher § 2 (4) BEEG - */ -const elterngeldGeschwisterbonusAufschlag: Float { - // Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 - from 2007-01-01 = 0.1 -} - -/** - * Minimaler Geschwisterbonus als Euro-Betrag - * § 2a (1) BEEG. Früher §2 (4) BEEG - */ -const elterngeldGeschwisterbonusMinimum: Int { - // Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 - from 2007-01-01 = 75 -} - -/** - * Pauschale für jedes weitere Mehrlingskind - * § 2a (4) BEEG, früher §2 (6) BEEG. - * pro Monat - */ -const elterngeldMehrlingbonus: Int { - // Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 - from 2007-01-01 = 300 -} - -/** - * Sozialversicherungspauschale zur Berechnung des Nettoeinkommens - * §2f BEEG. Vor 2012 waren es die eigentlichen Pflichtbeiträge. - */ -const elterngeldSozialversicherungspauschale: Float { - // Reference: Art. 1 G. v. 10.09.2012 BGBl. I S. 1878 - from 2012-09-18 = 0.21 -} - -/** - * Maximale Anzahl an Monaten, in denen ein Paar Elterngeld erhält - * § 4 (3) BEEG - */ -const elterngeldMaxMonatePaar: Int { - // Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 - from 2007-01-01 = 14 -} - -/** - * Maximale Anzahl an Monaten, die jedes Elternteil Elterngeld erhält - * § 4 (3) BEEG - */ -const elterngeldMaxMonateIndividuell: Int { - // Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 - from 2007-01-01 = 12 -} - -// erwerbsm_rente.yaml --------------------------------------------------- - -/** - * Regelaltersgrenze - * Altersgrenze bis zu der man die Erwerbsminderungsrente ohne Abzüge in - * Anspruch nehmen kann. Bis 2012 lag die Regelaltersgrenze bei 63. Ab dann - * schrittweise Anhebung bis 65. - * Reference: § 77 SGB VI Zugangsfaktor - * pro Jahr - */ -const abschlagsfreieAltersgrenze: Dict { - from 2001-01-01 = 63 - from 2012-01-01 = 63.083333 - from 2012-02-01 = 63.166666 - from 2012-03-01 = 63.25 - from 2012-04-01 = 63.333333 - from 2012-05-01 = 63.416666 - from 2012-06-01 = 63.5 - from 2013-01-01 = 63.583333 - from 2014-01-01 = 63.666666 - from 2015-01-01 = 63.75 - from 2016-01-01 = 63.833333 - from 2017-01-01 = 63.916666 - from 2018-01-01 = 64 - from 2019-01-01 = 64.166666 - from 2020-01-01 = 64.333333 - from 2021-01-01 = 64.5 - from 2022-01-01 = 64.666666 - from 2023-01-01 = 64.833333 - from 2024-01-01 = 65 -} - -/** - * Regelaltersgrenze für langjährige Versicherte - * Altersgrenze bis zu der man bestimmte zeitliche Bedingungen - * erfüllt. Bedingungen werden in § 77 Abs. 4 SGB VI definiert. - * Reference: § 77 Abs. 4 SGB VI Zugangsfaktor - * pro Jahr - */ -const regelaltersgrezeLangjaehrigeVersicherte: Dict { - from 2001-01-01 = 63 -} - -/** - * Wartezeitgrenze für abschlagsfreie Erwerbsminderungsrente - * Anzahl an Wartezeitjahren nach § 51 Absatz 3a SGB VI, die für eine abschlagsfreie - * Erwerbsminderungsrente mit 63 nachgewiesen werden müssen. - * Reference: § 264d SGB VI Zugangsfaktor - * pro Jahr - */ -const wartezeitgrenzeLangjaehrigeVersicherteAbschlagsfrei: Dict { - from 2001-01-01 = 35 - from 2024-01-01 = 40 -} - -/** - * Zurechnungszeitgrenze - * Altersgrenze für die Zurechnungszeit der Erwerbsminderungsrente. - * Anhebung von 2020 bis 2027 um 1 Monat pro Kalendarjahr und ab 2028 - * jeweils 2 Monate bis 67 erreicht ist. - * Reference: § 59 SGB VI Zurechnungszeit - * pro Jahr - */ -const zurechnungszeitgrenze: Dict { - from 2001-01-01 = 62.916666 - from 2001-02-01 = 62.833333 - from 2001-03-01 = 62.75 - from 2001-04-01 = 62.666666 - from 2001-05-01 = 62.583333 - from 2001-06-01 = 62.5 - from 2001-07-01 = 62.416666 - from 2001-08-01 = 62.333333 - from 2001-09-01 = 62.25 - from 2001-10-01 = 62.166666 - from 2001-11-01 = 62.083333 - from 2001-12-01 = 62 - from 2002-01-01 = 61.916666 - from 2002-02-01 = 61.833333 - from 2002-03-01 = 61.75 - from 2002-04-01 = 61.666666 - from 2002-05-01 = 61.583333 - from 2002-06-01 = 61.5 - from 2002-07-01 = 61.416666 - from 2002-08-01 = 61.333333 - from 2002-09-01 = 61.25 - from 2002-10-01 = 61.166666 - from 2002-11-01 = 61.083333 - from 2002-12-01 = 61 - from 2003-01-01 = 60.916666 - from 2003-02-01 = 60.833333 - from 2003-03-01 = 60.75 - from 2003-04-01 = 60.666666 - from 2003-05-01 = 60.583333 - from 2003-06-01 = 60.5 - from 2003-07-01 = 60.416666 - from 2003-08-01 = 60.333333 - from 2003-09-01 = 60.25 - from 2003-10-01 = 60.166666 - from 2003-11-01 = 60.083333 - from 2003-12-01 = 60 - from 2014-07-01 = 62 - from 2019-01-01 = 65.666666 - from 2020-01-01 = 65.75 - from 2021-01-01 = 65.833333 - from 2022-01-01 = 65.916666 - from 2023-01-01 = 66 - from 2024-01-01 = 66.083333 - from 2025-01-01 = 66.166666 - from 2026-01-01 = 66.25 - from 2027-01-01 = 66.333333 - from 2028-01-01 = 66.5 - from 2029-01-01 = 66.666666 - from 2030-01-01 = 66.833333 - from 2031-01-01 = 67 -} - -/** - * Kleinster möglicher Zugangsfaktor bei der Erwerbsminderungsrente - * Abzüge wegen frühzeitigem Eintritt in die Erwerbsminderungsrente - * sind bei 10.8% gedeckelt. - * Reference: § 77 SGB VI Zugangsfaktor - */ -const minZugangsfaktor: Dict { - from 2000-01-01 = 0.892 -} - -/** - * Rentenartfaktor für teilweise Erwerbsminderungsrente - * Der Rentenartfaktor ist ein festgelegter Faktor für die - * Rentenberechnung und bestimmt - * das Sicherungsziel der Rentenart im Verhältnis zu einer Altersrente. - * Reference: § 67 SGB VI Rentenartfaktor - */ -const rentenartfaktor: Dict { - from 2001-01-01 = { - teilw: 0.5, - voll: 1.0 - } -} - -/** - * Altersgrenze des belegungsfähigen Gesamtzeitraum - * Als Teil der Grundbewertung wird der belegungsfähige Gesamtzeitraum - * berechnet. Dieser entspricht dem Zeitraum vom 17. - * Lebensjahr bis zum Beginn der Rente - * Reference: SGB VI § 72: Grundbewertung - */ -const altersgrenzeGrundbewertung: Dict { - from 2001-01-01 = 16 -} - -// erziehungsgeld.yaml --------------------------------------------------- - -/** - * Einkommensgrenze für abzugsfreies Erziehungsgeld - * Reference: Bundesgesetzblatt Jahrgang 2004 Teil I Nr. 6 (p.209) - */ -const erziehungsgeldEinkommensgrenze: Dict>> { - from 2004-02-09 = { - limit: { - alleinerz: { - regelsatz: 23000, - budgetsatz: 19086 - }, - paar: { - regelsatz: 30000, - budgetsatz: 22086 - } - }, - reduced_limit: { - alleinerz: { - regelsatz: 13500, - budgetsatz: 13500 - }, - paar: { - regelsatz: 16500, - budgetsatz: 16500 - } - } - } -} - -/** - * Erhöhung der Einkommensgrenze pro weiterem Kind - * Reference: Bundesgesetzblatt Jahrgang 2004 Teil I Nr. 6 (p.209) - */ -const erziehungsgeldAufschlagEinkommen: Dict { - from 2004-02-09 = 3140 -} - -/** - * Höhe des Erziehungsgeldes abhängig vom beantragtem Satz - * Reference: Bundesgesetzblatt Jahrgang 2004 Teil I Nr. 6 § 5 (p.208) - */ -const erziehungsgeldSatz: Dict { - from 2004-02-09 = { - regelsatz: 300, - budgetsatz: 450 - } -} - -/** - * Faktor zur Berechnung des Abschlag des Erziehungsgeld bei einer - * Überschreitung der Einkommensgrenze ab dem 7 Lebensmonat. - * Der Faktor wird mit dem relevanten Einkommen multipliziert und - * das Produkt entsprechend vom Erziehungsgeld Anspruch abgezogen - * Reference: Bundesgesetzblatt Jahrgang 2004 Teil I Nr. 6 - */ -const erziehungsgeldAbschlagFaktor: Float { - from 2004-02-09 = 0.052 -} - -/** - * Faktor um den das Einkommen pauschal reduziert wird um das das - * relevanten Einkommen zu berechnen - * Reference: Bundesgesetzblatt Jahrgang 2004 Teil I Nr. 6 § 6 (p.209) - */ -const erziehungsgeldPauschalAbzugAufEinkommen: Float { - from 2004-02-09 = 0.76 -} - -/** - * Grenze der wöchentlichen Arbeitsstunden bis zu der Erziehungsgeld ausgezahlt wird - * Reference: Bundesgesetzblatt Jahrgang 2004 Teil I Nr. 6 § 15 (p.211) - */ -const erziehungsgeldArbeitsstundenWoechentlicheGrenze: Int { - from 2004-02-09 = 30 -} - -/** - * Alter des Kindes in Monaten bis zu dem der Regelsatz bezogen werden kann. - * Reference: Bundesgesetzblatt Jahrgang 2004 Teil I Nr. 6 - */ -const erziehungsgeldEndAlterKindRegelsatz: Int { - from 2004-01-01 = 24 -} - -/** - * Alter des Kindes in Monaten bis zu dem der Budgetsatz bezogen werden kann. - * Reference: Bundesgesetzblatt Jahrgang 2004 Teil I Nr. 6 - */ -const erziehungsgeldEndAlterKindBudgetsatz: Int { - from 2004-01-01 = 12 -} - -// TODO: rounding - -// ges_rente.yaml -------------------------------------------------------- - -/** - * Teil des Nachhaltigkeitsfaktors in der Rentenanpassungsformel, welche das - * Verhältnis von Rentnern zu Beitragszahlern modifiziert - * Reference: §68 Abs. 4 S. 6 SGB VI - */ -const GesetzlicheRenteAlpha: Float { - from 1984-01-01 = 0.0 - from 2002-01-01 = 0.25 -} - -/** - * Teil des Riesterfaktors in der Rentenanpassungsformel - * Reference: §68 Abs. 5 SGB VI - */ -const gesetzlicheRenteAltersVorsorgeAnteil: Float { - from 1993-01-01 = 0.0 - from 2002-01-01 = 0.5 - from 2003-01-01 = 1.0 - from 2004-01-01 = 1.5 - from 2005-01-01 = 2.0 - from 2009-01-01 = 2.5 - from 2010-01-01 = 3.0 - from 2011-01-01 = 3.5 - from 2012-01-01 = 4.0 -} - -/** - * Summe der Beiträge zur Rentenversicherung aller rentenversicherungspflichtig - * Beschäftigten, der geringfügig Beschäftigten und der Bezieher von ALG. - * statistik-rente.de/drv - */ -const gesetzlicheRenteBeitragsvolumen: Dict { - from 1991-01-01 = 108688000 - from 1992-01-01 = 117359000 - from 1993-01-01 = 120559000 - from 1994-01-01 = 132938000 - from 1995-01-01 = 139921000 - from 1996-01-01 = 146160000 - from 1997-01-01 = 153658000 - from 1998-01-01 = 153763000 - from 1999-01-01 = 160506000 - from 2000-01-01 = 163367000 - from 2001-01-01 = 164694000 - from 2002-01-01 = 165481000 - from 2003-01-01 = 169425000 - from 2004-01-01 = 169399000 - from 2005-01-01 = 168954000 - from 2006-01-01 = 180545000 - from 2007-01-01 = 174726000 - from 2008-01-01 = 180028000 - from 2009-01-01 = 181572000 - from 2010-01-01 = 185288000 - from 2011-01-01 = 189850000 - from 2012-01-01 = 193687000 - from 2013-01-01 = 194334000 - from 2014-01-01 = 201647000 - from 2015-01-01 = 207317000 - from 2016-01-01 = 215422000 - from 2017-01-01 = 225244000 - from 2018-01-01 = 236404000 - from 2019-01-01 = 247949000 -} - -/** - * Regelaltersrente/ Standardrente - * Höhe einer abschlagsfreien Rente bei 45 Entgeltpunkten. Ergibt sich aus - * Multiplikation des Rentenwerts mit 45. statistik-rente.de/drv - * Reference: § 154 Abs. 3 Satz 1 Nr. 2 SGB VI - */ -const gesetzlicheRenteEckrente: Float { - from 1995-01-01 = 988.15 - from 1996-01-01 = 992.72 - from 1997-01-01 = 1009.1 - from 1998-01-01 = 1012.47 - from 1999-01-01 = 1026.62 - from 2000-01-01 = 1032.79 - from 2001-01-01 = 1051.99 - from 2002-01-01 = 1072.35 - from 2003-01-01 = 1081.79 - from 2004-01-01 = 1071.79 - from 2005-01-01 = 1063.41 - from 2006-01-01 = 1066.35 - from 2007-01-01 = 1067.8 - from 2008-01-01 = 1077.02 - from 2009-01-01 = 1100.84 - from 2010-01-01 = 1102.67 - from 2011-01-01 = 1109.91 - from 2012-01-01 = 1134.15 - from 2013-01-01 = 1135.71 - from 2014-01-01 = 1154.68 - from 2015-01-01 = 1174.96 - from 2016-01-01 = 1222.09 - from 2017-01-01 = 1242.58 - from 2018-01-01 = 1284.06 -} - -/** - * Durchschnittslohn - * Durchschnittsbruttolohn aller Arbeitnehmer:innen in einem Jahr - */ -const gesetzlicheRenteDurchschnittslohn: Float { - from 2005-01-01 = 28468.23 - from 2006-01-01 = 28673.22 - from 2007-01-01 = 28978.19 - from 2008-01-01 = 29262.71 - from 2009-01-01 = 29774.24 - from 2010-01-01 = 30086.57 - from 2011-01-01 = 30770.62 - from 2012-01-01 = 31452.49 - from 2013-01-01 = 31583.35 - from 2014-01-01 = 32313.66 - from 2015-01-01 = 33047.02 - from 2016-01-01 = 33608.42 -} - -/** - * Beitragspflichtiges Durchschnittsentgelt aller Versicherten - * Durchschnittsentgelt aller Versicherten im Sinne der deutschen Sozialversicherung. - * Dieses wird benötigt zur Berechnung der Entgeltpunkte. - */ -const gesetzlicheRenteBeitragspflichtigesDurchschnittsentgelt: Int { - from 2005-01-01 = 29202 - from 2006-01-01 = 29494 - from 2007-01-01 = 29951 - from 2008-01-01 = 30625 - from 2009-01-01 = 30506 - from 2010-01-01 = 31144 - from 2011-01-01 = 32100 - from 2012-01-01 = 33002 - from 2013-01-01 = 33659 - from 2014-01-01 = 34514 - from 2015-01-01 = 35363 - from 2016-01-01 = 36187 - from 2017-01-01 = 37077 - from 2018-01-01 = 38212 - from 2019-01-01 = 39301 - from 2020-01-01 = 39167 - from 2021-01-01 = 41541 - from 2022-01-01 = 38901 -} - -/** - * Umrechnung der Beitragsbemessungsgrundlagen des Beitrittgebietes - * Für die Berechnung der Entgeltpunkte wird das Einkommen im "Beitrittsgebiet" um - * diesen Faktor erhöht. - * Reference: §256a SGB VI and Anlage 10 SGB VI - */ -const gesetzlicheRenteUmrechnungEntgeltpBeitrittsgebiet: Float { - from 1945-01-01 = 1.0000 - from 1946-01-01 = 1.0000 - from 1947-01-01 = 1.0000 - from 1948-01-01 = 1.0000 - from 1949-01-01 = 1.0000 - from 1950-01-01 = 0.9931 - from 1951-01-01 = 1.0502 - from 1952-01-01 = 1.0617 - from 1953-01-01 = 1.0458 - from 1954-01-01 = 1.0185 - from 1955-01-01 = 1.0656 - from 1956-01-01 = 1.1029 - from 1957-01-01 = 1.1081 - from 1958-01-01 = 1.0992 - from 1959-01-01 = 1.0838 - from 1960-01-01 = 1.1451 - from 1961-01-01 = 1.2374 - from 1962-01-01 = 1.3156 - from 1963-01-01 = 1.3667 - from 1964-01-01 = 1.4568 - from 1965-01-01 = 1.5462 - from 1966-01-01 = 1.6018 - from 1967-01-01 = 1.5927 - from 1968-01-01 = 1.6405 - from 1969-01-01 = 1.7321 - from 1970-01-01 = 1.8875 - from 1971-01-01 = 2.0490 - from 1972-01-01 = 2.1705 - from 1973-01-01 = 2.3637 - from 1974-01-01 = 2.5451 - from 1975-01-01 = 2.6272 - from 1976-01-01 = 2.7344 - from 1977-01-01 = 2.8343 - from 1978-01-01 = 2.8923 - from 1979-01-01 = 2.9734 - from 1980-01-01 = 3.1208 - from 1981-01-01 = 3.1634 - from 1982-01-01 = 3.2147 - from 1983-01-01 = 3.2627 - from 1984-01-01 = 3.2885 - from 1985-01-01 = 3.3129 - from 1986-01-01 = 3.2968 - from 1987-01-01 = 3.2548 - from 1988-01-01 = 3.2381 - from 1989-01-01 = 3.2330 - from 1990-01-01 = 3.0707 - from 1990-06-01 = 2.3473 - from 1991-01-01 = 1.7235 - from 1992-01-01 = 1.4393 - from 1993-01-01 = 1.3197 - from 1994-01-01 = 1.2687 - from 1995-01-01 = 1.2317 - from 1996-01-01 = 1.2209 - from 1997-01-01 = 1.2089 - from 1998-01-01 = 1.2113 - from 1999-01-01 = 1.2054 - from 2000-01-01 = 1.2030 - from 2001-01-01 = 1.2003 - from 2002-01-01 = 1.1972 - from 2003-01-01 = 1.1943 - from 2004-01-01 = 1.1932 - from 2005-01-01 = 1.1827 - from 2006-01-01 = 1.1827 - from 2007-01-01 = 1.1841 - from 2008-01-01 = 1.1857 - from 2009-01-01 = 1.1712 - from 2010-01-01 = 1.1726 - from 2011-01-01 = 1.1740 - from 2012-01-01 = 1.1785 - from 2013-01-01 = 1.1762 - from 2014-01-01 = 1.1665 - from 2015-01-01 = 1.1502 - from 2016-01-01 = 1.1415 - from 2017-01-01 = 1.1374 - from 2018-01-01 = 1.1339 - from 2019-01-01 = 1.0840 - from 2020-01-01 = 1.0700 - from 2021-01-01 = 1.0560 - from 2022-01-01 = 1.0420 - from 2023-01-01 = 1.0280 - from 2024-01-01 = 1.0140 -} - -/** - * Rentenvolumen - * Gesamtvolumen der ausgezahlten Renten - */ -const gesetzlicheRenteGesamtesRentenvolumen: Int { - from 1991-01-01 = 117912000 - from 1992-01-01 = 130901000 - from 1993-01-01 = 141180000 - from 1994-01-01 = 152798000 - from 1995-01-01 = 162625000 - from 1996-01-01 = 168955000 - from 1997-01-01 = 174479000 - from 1998-01-01 = 180323800 - from 1999-01-01 = 184139000 - from 2000-01-01 = 190198000 - from 2001-01-01 = 195776000 - from 2002-01-01 = 202355000 - from 2003-01-01 = 207749000 - from 2004-01-01 = 210522000 - from 2005-01-01 = 211861000 - from 2006-01-01 = 212421000 - from 2007-01-01 = 213649000 - from 2008-01-01 = 216182000 - from 2009-01-01 = 220841000 - from 2010-01-01 = 224352000 - from 2011-01-01 = 225411000 - from 2012-01-01 = 229231000 - from 2013-01-01 = 232297000 - from 2014-01-01 = 238991000 - from 2015-01-01 = 249568000 - from 2016-01-01 = 259345000 - from 2017-01-01 = 286860000 - from 2018-01-01 = 277102000 - from 2019-01-01 = 291359000 -} - -/** - * Rentenwerte alte und neue Bundesländer - * Der aktuelle Rentenwert drückt den Betrag aus, der der monatlichen Rente für - * einen Entgeltpunkt entspricht. - * Reference: statistik-rente.de/drv, § 68 SGB VI - */ -const gesetzlicheRenteRentenwert: Dict { - from 1992-01-01 = { - west: 21.19, - ost: 12.05 - } - - from 1992-07-01 = { - west: 21.80, - ost: 13.59 - } - - from 1993-01-01 = { - west: 21.80, // deviation_from: previous - ost: 14.41 - } - - from 1993-07-01 = { - west: 22.75, - ost: 16.45 - } - - from 1994-01-01 = { - west: 22.75, // deviation_from: previous - ost: 17.05 - } - - from 1994-07-01 = { - west: 23.52, - ost: 17.63 - } - - from 1995-01-01 = { - west: 23.52, // deviation_from: previous - ost: 18.13 - } - - from 1995-07-01 = { - west: 23.64, - ost: 18.58 - } - - from 1996-01-01 = { - west: 23.64, // deviation_from: previous - ost: 19.39 - } - - from 1996-07-01 = { - west: 23.86, - ost: 19.62 - } - - from 1997-07-01 = { - west: 24.26, - ost: 20.71 - } - - from 1998-07-01 = { - west: 24.36, - ost: 20.90 - } - - from 1999-07-01 = { - west: 24.69, - ost: 21.48 - } - - from 2000-07-01 = { - west: 24.84, - ost: 21.61 - } - - from 2001-07-01 = { - west: 25.31, - ost: 22.06 - } - - from 2002-07-01 = { - west: 25.86, - ost: 22.70 - } - - from 2003-07-01 = { - west: 26.13, - ost: 22.97 - } - - from 2007-07-01 = { - west: 26.27, - ost: 23.09 - } - - from 2008-07-01 = { - west: 26.56, - ost: 23.34 - } - - from 2009-07-01 = { - west: 27.2, - ost: 24.13 - } - - from 2011-07-01 = { - west: 27.47, - ost: 24.37 - } - - from 2012-07-01 = { - west: 28.07, - ost: 24.92 - } - - from 2013-07-01 = { - west: 28.14, - ost: 25.74 - } - - from 2014-07-01 = { - west: 28.61, - ost: 26.39 - } - - from 2015-07-01 = { - west: 29.21, - ost: 27.05 - } - - from 2016-07-01 = { - west: 30.45, - ost: 28.66 - } - - from 2017-07-01 = { - west: 31.03, - ost: 29.69 - } - - from 2018-07-01 = { - west: 32.03, - ost: 30.69 - } - - from 2019-07-01 = { - west: 33.05, - ost: 31.89 - } - - from 2020-07-01 = { - west: 34.19, - ost: 33.23 - } - - from 2021-07-01 = { - west: 34.19, // deviation_from: previous - ost: 33.47 - } -} - -/** - * Höchstwert der Entgeltpunkte für Grundrente - * Konstante zur Bestimmung des Höchstwerts der durchschnittlichen Entgeltpunkte und - * des Effekts eines weiteren Monats an Grundrentenzeiten auf Höchstwert. - */ -const gesetzlicheRenteGrundrenteHöchstwert: Dict { - // Reference: § 76g Abs. 4 S. 3, 4 SGB VI - from 2021-01-01 = { - base: 0.0334, - increment: 0.001389, - } -} - -/** - * Zugangsfaktor bei Grundrente - * Der Zugangsfaktor für die Grundrente ist auf 1 begrenzt. - * Reference: § 77 Abs. 2 SGB VI - */ -const gesetzlicheRenteGrundrenteZugangsfaktorMax: Int { - from 2021-01-01 = 1 -} - -/** - * Grundrentenzeiten - * Minimal benötigte Grundrentenzeiten um zur Grundrente berechtigt zu sein und Zahl - * an Grundrentenzeiten ab der zusätzliche Monate an Grundrentenzeiten nicht - * berücksichtigt werden - */ -const gesetzlicheRenteGrundrenteZeiten: Dict { - // Reference: § 76g Abs. 4 S. 5,6 / Abs. 1 S. 1 SGB VI - from 2021-01-01 = { - min: 396, - max: 420, - } -} - -/** - * Einkommensanrechnung Grundrente für Personen ohne verheiratetem Partner - * Werte werden mit dem Rentenwert multipliziert, um Schwellen der - * Einkommensanrechnung des Grundrentenzuschlags zu ermitteln - * Reference: § 97a Abs. 4 S. 2, 4 SGB VI - */ -const gesetzlicheRenteGrundrenteEinkommensanrechnungSingle: Dict> { - // Reference: § 97a Abs. 4 S. 2, 4 SGB VI - from 2021-01-01 = { - 0: { - lower_threshold: -inf, - upper_threshold: 36.56, - rate_linear: 0, - intercept_at_lower_threshold: 0, - }, - 1: { - upper_threshold: 46.78, - rate_linear: 0.6, - }, - 2: { - upper_threshold: inf, - rate_linear: 1, - }, - } -} - -/** - * Einkommensanrechnung Grundrente für Personen mit verheiratetem Partner - * Werte werden mit dem Rentenwert multipliziert, um Schwellen der - * Einkommensanrechnung des Grundrentenzuschlags zu ermitteln - * Reference: § 97a Abs. 4 S. 2, 4 SGB VI - */ -const gesetzlicheRenteGrundrenteEinkommensanrechnungMarried: Dict> { - // Reference: § 97a Abs. 4 S. 2, 4 SGB VI - from 2021-01-01 = { - 0: { - lower_threshold: -inf, - upper_threshold: 57.03, - rate_linear: 0, - intercept_at_lower_threshold: 0, - }, - 1: { - upper_threshold: 67.27, - rate_linear: 0.6, - }, - 2: { - upper_threshold: inf, - rate_linear: 1, - }, - } -} - -/** - * Bonusfaktor aus Grundrente - * Faktor mit dem die durch die Grundrente zusätzlich erhaltenen Entgeltpunkte - * multipliziert werden. - */ -const gesetzlicheRenteGrundrenteFaktorBonus: Float { - // Reference: §§ 76g Abs. 4 S. 3, 4 SGB VI - from 2021-01-01 = 0.875 -} - -/** - * Veränderung des Zugangsfaktors pro Jahr - * Faktor um den sich der Zugangsfaktor für die staatliche Rente erhöht/senkt für - * jedes Jahr, das länger/kürzer gearbeitet wird - * Reference: §77 Abs. 2 Nr. 2 SGB VI - */ -const gesetzlicheRenteZugangsfaktorVeraenderungProJahr: Dict { - // Reference: §77 Abs. 2 Nr. 2 SGB VI - from 2001-01-01 = { - vorzeitiger_renteneintritt: 0.036, - späterer_renteneintritt: 0.06, - } -} - -/** - * Eintrittsalter für Regelaltersrente - * Stückweise lineare Funktion, die die Regelaltersgrenze angibt, bei der das - * Individuum mit seinem vollen Rentenanspruch in Rente gehen kann. Geht die Person - * früher oder später in Rente, ist der Zugangsfaktor und damit der Rentenanspruch - * höher oder niedriger, wenn keine Ausnahmeregelungen erfüllt sind. - * Reference: § 35 Satz 2 SGB VI - */ -const gesetzlicheRenteRegelaltersgrenze: Dict> { - from 1984-01-01 = { - 0: { - lower_threshold: -inf, - upper_threshold: 1946, - rate_linear: 0, - intercept_at_lower_threshold: 65, - }, - 1: { - upper_threshold: 1958, - rate_linear: 0.083333333, - }, - 2: { - upper_threshold: 1964, - rate_linear: 0.16666666, - }, - 3: { - upper_threshold: inf, - rate_linear: 0, - }, - } -} - -/** - * Eintrittsalter für Altersrente für Frauen - * Stückweise lineare Funktion, die die Altersgrenzen angibt, ab denen Frauen - * geboren vor 1952 in Rente gehen konnten. - * Reference: § 237a SGB VI - */ -const gesetzlicheRenteAltersgrenzeFrauen: Dict> { - from 1980-01-01 = { - 0: { - lower_threshold: -inf, - upper_threshold: 1939.916667, - rate_linear: 0, - intercept_at_lower_threshold: 60, - }, - 1: { - upper_threshold: 1944.916666666, - rate_linear: 1, - }, - 2: { - upper_threshold: 1951.916666666, // constant 65 - rate_linear: 0, - }, - 3: { - upper_threshold: 1952, - // since 1952 abolished - regelaltersgrenze applies - jump in theshold by 6 month - rate_linear: 6, - }, - 4: { - upper_threshold: 1958, - rate_linear: 0.083333333, - }, - 5: { - upper_threshold: 1964, - rate_linear: 0.16666666, - }, - 6: { - upper_threshold: inf, - rate_linear: 0, - }, - } -} - -/** - * Altersgrenze für vorzeitigen Bezug der Altersrente für Frauen. - * Frühestmögliches Alter ab dem die Altersrente für Frauen bezogen werden kann - * (mit Abschlägen). - * Reference: § 237a SGB VI - */ -const gesetzlicheRenteAltersgrenzeFrauenVorzeitig: Dict> { - from 1980-01-01 = { - 0: { - lower_threshold: -inf, - upper_threshold: 1952, - rate_linear: 0, - intercept_at_lower_threshold: 60, - }, - 1: { - upper_threshold: 1953, - rate_linear: 7, - }, - 2: { - upper_threshold: inf, // constant 67 - rate_linear: 0, - }, - } -} - -/** - * Kohorte Abschaffung Rente für Frauen - * Kohorte, ab der Rente für Frauen abgeschafft. - * Reference: § 237a SGB VI - */ -const gesetzlicheRenteFirstBirthyearWithoutRenteFrauen: Int { - from 1980-01-01 = 1952 -} - -/** - * Mindestpflichbeitragsjahre ab 40 für Rente für Frauen - ** Mindestpflichbeitragsjahre, nach dem 40. Lebensjahr, - * die für Rente für Frauen berechtigt. - * Wert ist als Jahr zu interpretieren. - * Reference: § 237a SGB VI - */ -const gesetzlicheRenteRenteFrauenPflichtbeitrag: Int { - from 1950-01-01 = 10 -} - -/** - * Altersgrenze für Altersrente wegen Arbeitslosigkeit (abschlagsfrei) - * Frühestmögliches Alter ab dem die Altersrente für Arbeitslose abschlagsfrei - * bezogen werden kann. - * Reference: § 237 SGB VI - */ -const gesetzlicheRenteAltersgrenzeArbeitslosigkeitAbschlagsfrei: Float | Dict> { - from 1980-01-01 = { - 0: { - scalar: 60.0, - }, - } - from 1992-01-01 = { - 0: { - scalar: 60.0, - }, - 1941: { - 1: 60.083333, - 2: 60.083333, - 3: 60.083333, - 4: 60.083333, - 5: 60.166667, - 6: 60.166667, - 7: 60.166667, - 8: 60.166667, - 9: 60.25, - 10: 60.25, - 11: 60.25, - 12: 60.25, - }, - 1942: { - 1: 60.333333, - 2: 60.333333, - 3: 60.333333, - 4: 60.333333, - 5: 60.416667, - 6: 60.416667, - 7: 60.416667, - 8: 60.416667, - 9: 60.5, - 10: 60.5, - 11: 60.5, - 12: 60.5, - }, - 1943: { - 1: 60.583333, - 2: 60.583333, - 3: 60.583333, - 4: 60.583333, - 5: 60.666667, - 6: 60.666667, - 7: 60.666667, - 8: 60.666667, - 9: 60.75, - 10: 60.75, - 11: 60.75, - 12: 60.75, - }, - 1944: { - 1: 60.833333, - 2: 60.833333, - 3: 60.833333, - 4: 60.833333, - 5: 61.916667, - 6: 61.916667, - 7: 61.916667, - 8: 61.916667, - 9: 61.0, - 10: 61, - 11: 61, - 12: 61, - }, - 1945: { - 1: 61.083333, - 2: 61.083333, - 3: 61.166667, - 4: 61.166667, - 5: 61.25, - 6: 61.25, - 7: 61.333333, - 8: 61.333333, - 9: 61.416667, - 10: 61.416667, - 11: 61.5, - 12: 61.5, - }, - 1946: { - 1: 61.583333, - 2: 61.583333, - 3: 61.666667, - 4: 61.666667, - 5: 61.75, - 6: 61.75, - 7: 61.833333, - 8: 61.833333, - 9: 61.916667, - 10: 61.916667, - 11: 62.0, - 12: 62.0, - }, - 1947: { - 1: 62.083333, - 2: 62.083333, - 3: 62.166667, - 4: 62.166667, - 5: 62.25, - 6: 62.25, - 7: 62.333333, - 8: 62.333333, - 9: 62.416667, - 10: 62.416667, - 11: 62.5, - 12: 62.5, - }, - 1948: { - 1: 62.583333, - 2: 62.583333, - 3: 62.666667, - 4: 62.666667, - 5: 62.75, - 6: 62.75, - 7: 62.833333, - 8: 62.833333, - 9: 62.916667, - 10: 62.916667, - 11: 63.0, - 12: 63.0, - }, - 1949: { - 1: 63.083333, - 2: 63.083333, - 3: 63.166667, - 4: 63.166667, - 5: 63.25, - 6: 63.25, - 7: 63.333333, - 8: 63.333333, - 9: 63.416667, - 10: 63.416667, - 11: 63.5, - 12: 63.5, - }, - 1950: { - 1: 63.583333, - 2: 63.583333, - 3: 63.666667, - 4: 63.666667, - 5: 63.75, - 6: 63.75, - 7: 63.833333, - 8: 63.833333, - 9: 63.916667, - 10: 63.916667, - 11: 64.0, - 12: 64.0, - }, - 1951: { - 1: 64.083333, - 2: 64.083333, - 3: 64.166667, - 4: 64.166667, - 5: 64.25, - 6: 64.25, - 7: 64.333333, - 8: 64.333333, - 9: 64.416667, - 10: 64.416667, - 11: 64.5, - 12: 64.5, - }, - 1952: { - 1: 64.583333, - 2: 64.583333, - 3: 64.666667, - 4: 64.666667, - 5: 64.75, - 6: 64.75, - 7: 64.833333, - 8: 64.833333, - 9: 64.916667, - 10: 64.916667, - 11: 65.0, - 12: 65.0, - }, - } - from 1996-07-29 = { - 0: { - scalar: 60.0, - }, - 1937: { - 1: 60.083333, - 2: 60.166667, - 3: 60.25, - 4: 60.333333, - 5: 60.416667, - 6: 60.5, - 7: 60.583333, - 8: 60.666667, - 9: 60.75, - 10: 60.833333, - 11: 60.916667, - 12: 61.0, - }, - 1938: { - 1: 61.083333, - 2: 61.166667, - 3: 61.25, - 4: 61.333333, - 5: 61.416667, - 6: 61.5, - 7: 61.583333, - 8: 61.666667, - 9: 61.75, - 10: 61.833333, - 11: 61.916667, - 12: 62.0, - }, - 1939: { - 1: 62.083333, - 2: 62.166667, - 3: 62.25, - 4: 62.333333, - 5: 62.416667, - 6: 62.5, - 7: 62.583333, - 8: 62.666667, - 9: 62.75, - 10: 62.833333, - 11: 62.916667, - 12: 63.0, - }, - 1940: { - 1: 63.0, - 2: 63.0, - 3: 63.0, - 4: 63.0, - 5: 63.0, - 6: 63.0, - 7: 63.0, - 8: 63.0, - 9: 63.0, - 10: 63.0, - 11: 63.0, - 12: 63.0, - }, - 1941: { - 1: 63.0, - 2: 63.0, - 3: 63.0, - 4: 63.0, - 5: 63.0, - 6: 63.0, - 7: 63.0, - 8: 63.0, - 9: 63.0, - 10: 63.0, - 11: 63.0, - 12: 63.0, - }, - 1942: { - 1: 63.0, - 2: 63.0, - 3: 63.0, - 4: 63.0, - 5: 63.0, - 6: 63.0, - 7: 63.0, - 8: 63.0, - 9: 63.0, - 10: 63.0, - 11: 63.0, - 12: 63.0, - }, - 1943: { - 1: 63.0, - 2: 63.0, - 3: 63.0, - 4: 63.0, - 5: 63.0, - 6: 63.0, - 7: 63.0, - 8: 63.0, - 9: 63.0, - 10: 63.0, - 11: 63.0, - 12: 63.0, - }, - 1944: { - 1: 63.0, - 2: 63.0, - 3: 63.0, - 4: 63.0, - 5: 63.0, - 6: 63.0, - 7: 63.0, - 8: 63.0, - 9: 63.0, - 10: 63.0, - 11: 63.0, - 12: 63.0, - }, - 1945: { - 1: 63.0, - 2: 63.0, - 3: 63.0, - 4: 63.0, - 5: 63.0, - 6: 63.0, - 7: 63.0, - 8: 63.0, - 9: 63.0, - 10: 63.0, - 11: 63.0, - 12: 63.0, - }, - 1946: { - 1: 63.0, - 2: 63.0, - 3: 63.0, - 4: 63.0, - 5: 63.0, - 6: 63.0, - 7: 63.0, - 8: 63.0, - 9: 63.0, - 10: 63.0, - 11: 63.0, - 12: 63.0, - }, - 1947: { - 1: 63.0, - 2: 63.0, - 3: 63.0, - 4: 63.0, - 5: 63.0, - 6: 63.0, - 7: 63.0, - 8: 63.0, - 9: 63.0, - 10: 63.0, - 11: 63.0, - 12: 63.0, - }, - 1948: { - 1: 63.0, - 2: 63.0, - 3: 63.0, - 4: 63.0, - 5: 63.0, - 6: 63.0, - 7: 63.0, - 8: 63.0, - 9: 63.0, - 10: 63.0, - 11: 63.0, - 12: 63.0, - }, - 1949: { - 1: 63.083333, - 2: 63.083333, - 3: 63.166667, - 4: 63.166667, - 5: 63.25, - 6: 63.25, - 7: 63.333333, - 8: 63.333333, - 9: 63.416667, - 10: 63.416667, - 11: 63.5, - 12: 63.5, - }, - 1950: { - 1: 63.583333, - 2: 63.583333, - 3: 63.666667, - 4: 63.666667, - 5: 63.75, - 6: 63.75, - 7: 63.833333, - 8: 63.833333, - 9: 63.916667, - 10: 63.916667, - 11: 64.0, - 12: 64.0, - }, - 1951: { - 1: 64.083333, - 2: 64.083333, - 3: 64.166667, - 4: 64.166667, - 5: 64.25, - 6: 64.25, - 7: 64.333333, - 8: 64.333333, - 9: 64.416667, - 10: 64.416667, - 11: 64.5, - 12: 64.5, - }, - 1952: { - 1: 64.583333, - 2: 64.583333, - 3: 64.666667, - 4: 64.666667, - 5: 64.75, - 6: 64.75, - 7: 64.833333, - 8: 64.833333, - 9: 64.916667, - 10: 64.916667, - 11: 65.0, - 12: 65.0, - }, - /* - Altersgrenze für Altersrente wegen Arbeitslosigkeit mit Vertrauensschutz - (abschlagsfrei). - Increase of full retirement age according to old law (RRG 1992) for individuals - covered under Vertrauensschutz. - Reference: § 237 SGB VI Abs. 4 - */ - vertrauensschutz: { - max_birthyear_old_regime: 1940, - entry_age_old_regime: 60.0, - 1941: { - 1: 60.083333, - 2: 60.083333, - 3: 60.083333, - 4: 60.083333, - 5: 60.166667, - 6: 60.166667, - 7: 60.166667, - 8: 60.166667, - 9: 60.25, - 10: 60.25, - 11: 60.25, - 12: 60.25, - }, - 1942: { - 1: 60.333333, - 2: 60.333333, - 3: 60.333333, - 4: 60.333333, - 5: 60.416667, - 6: 60.416667, - 7: 60.416667, - 8: 60.416667, - 9: 60.5, - 10: 60.5, - 11: 60.5, - 12: 60.5, - }, - 1943: { - 1: 60.583333, - 2: 60.583333, - 3: 60.583333, - 4: 60.583333, - 5: 60.666667, - 6: 60.666667, - 7: 60.666667, - 8: 60.666667, - 9: 60.75, - 10: 60.75, - 11: 60.75, - 12: 60.75, - }, - 1944: { - 1: 60.833333, - 2: 60.833333, - }, - }, - } - - // Reference: Wachstums- und Beschäftigungsförderungsgesetz 1996. BGBl. I S. 1461 1996 - // Increase of full retirement age from 60 to 65 for birth cohort 1937-1941. - from 1996-09-27 = { - max_birthyear_old_regime: 1936, - min_birthyear_new_regime: 1942, - entry_age_old_regime: 60.0, - entry_age_new_regime: 65.0, - 1937: { - 1: 60.083333, - 2: 60.166667, - 3: 60.25, - 4: 60.333333, - 5: 60.416667, - 6: 60.5, - 7: 60.583333, - 8: 60.666667, - 9: 60.75, - 10: 60.833333, - 11: 60.916667, - 12: 61.0, - }, - 1938: { - 1: 61.083333, - 2: 61.166667, - 3: 61.25, - 4: 61.333333, - 5: 61.416667, - 6: 61.5, - 7: 61.583333, - 8: 61.666667, - 9: 61.75, - 10: 61.833333, - 11: 61.916667, - 12: 62.0, - }, - 1939: { - 1: 62.083333, - 2: 62.166667, - 3: 62.25, - 4: 62.333333, - 5: 62.416667, - 6: 62.5, - 7: 62.583333, - 8: 62.666667, - 9: 62.75, - 10: 62.833333, - 11: 62.916667, - 12: 63.0, - }, - 1940: { - 1: 63.083333, - 2: 63.166667, - 3: 63.25, - 4: 63.333333, - 5: 63.416667, - 6: 63.5, - 7: 63.583333, - 8: 63.666667, - 9: 63.75, - 10: 63.833333, - 11: 63.916667, - 12: 64.0, - }, - 1941: { - 1: 64.083333, - 2: 64.166667, - 3: 64.25, - 4: 64.333333, - 5: 64.416667, - 6: 64.5, - 7: 64.583333, - 8: 64.666667, - 9: 64.75, - 10: 64.833333, - 11: 64.916667, - 12: 65.0, - }, - vertrauensschutz: { - /* - Altersgrenze für Altersrente wegen Arbeitslosigkeit mit Vertrauensschutz - (abschlagsfrei). - Increase of full retirement age according to old law (RRG 1992) for individuals - covered under Vertrauensschutz. - Reference: § 237 SGB VI Abs. 4 - */ - max_birthyear_old_regime: 1940, - entry_age_old_regime: 60.0, - 1941: { - 1: 60.083333, - 2: 60.083333, - 3: 60.083333, - 4: 60.083333, - 5: 60.166667, - 6: 60.166667, - 7: 60.166667, - 8: 60.166667, - 9: 60.25, - 10: 60.25, - 11: 60.25, - 12: 60.25, - }, - 1942: { - 1: 60.333333, - 2: 60.333333, - 3: 60.333333, - 4: 60.333333, - 5: 60.416667, - 6: 60.416667, - 7: 60.416667, - 8: 60.416667, - 9: 60.5, - 10: 60.5, - 11: 60.5, - 12: 60.5, - }, - 1943: { - 1: 60.583333, - 2: 60.583333, - 3: 60.583333, - 4: 60.583333, - 5: 60.666667, - 6: 60.666667, - 7: 60.666667, - 8: 60.666667, - 9: 60.75, - 10: 60.75, - 11: 60.75, - 12: 60.75, - }, - 1944: { - 1: 60.833333, - 2: 60.833333, - }, - }, - } -} - -/** - * Altersgrenze für vorzeitige Inanspruchnahme Altersrente wegen Arbeitslosigkeit - * Frühestmögliches Alter ab dem die Altersrente für Arbeitslose - * bezogen werden kann (mit Abschlägen), einschließlich Vertrauensschutz. - * Reference: § 237 SGB VI - */ -const gesetzlicheRenteAltersgrenzeArbeitslosigkeitVorzeitig: Float | Dict>{ - from 1980-01-01 = 60.0 - - // Increase of early retirement age from 60 to 62 for birth cohort 1949-1952. - // Reference: Rentenreformgesetz 1992. BGBl. I S. 2261 1989 § 41 - from 1992-01-01 = { - max_birthyear_old_regime: 1948, - min_birthyear_new_regime: 1953, - entry_age_old_regime: 60.0, - entry_age_new_regime: 62.0, - 1949: { - 1: 60.083333, - 2: 60.083333, - 3: 60.166667, - 4: 60.166667, - 5: 60.25, - 6: 60.25, - 7: 60.333333, - 8: 60.333333, - 9: 60.416667, - 10: 60.416667, - 11: 60.5, - 12: 60.5, - }, - 1950: { - 1: 60.583333, - 2: 60.583333, - 3: 60.666667, - 4: 60.666667, - 5: 60.75, - 6: 60.75, - 7: 60.833333, - 8: 60.833333, - 9: 60.916667, - 10: 60.916667, - 11: 61.0, - 12: 61.0, - }, - 1951: { - 1: 61.083333, - 2: 61.083333, - 3: 61.166667, - 4: 61.166667, - 5: 61.25, - 6: 61.25, - 7: 61.333333, - 8: 61.333333, - 9: 61.416667, - 10: 61.416667, - 11: 61.5, - 12: 61.5, - }, - 1952: { - 1: 61.583333, - 2: 61.583333, - 3: 61.666667, - 4: 61.666667, - 5: 61.75, - 6: 61.75, - 7: 61.833333, - 8: 61.833333, - 9: 61.916667, - 10: 61.916667, - 11: 62.0, - 12: 62.0, - }, - } - - // Increase of early retirement age from 60 to 65 for birth cohort 1937-1941. - // Reference: Wachstums- und Beschäftigungsförderungsgesetz 1996. BGBl. I S. 1461 1996 - from 1996-07-29 = { - max_birthyear_old_regime: 1948, - min_birthyear_new_regime: 1953, - entry_age_old_regime: 60.0, - entry_age_new_regime: 62.0, - 1949: { - 1: 60.083333, - 2: 60.083333, - 3: 60.166667, - 4: 60.166667, - 5: 60.25, - 6: 60.25, - 7: 60.333333, - 8: 60.333333, - 9: 60.416667, - 10: 60.416667, - 11: 60.5, - 12: 60.5, - }, - 1950: { - 1: 60.583333, - 2: 60.583333, - 3: 60.666667, - 4: 60.666667, - 5: 60.75, - 6: 60.75, - 7: 60.833333, - 8: 60.833333, - 9: 60.916667, - 10: 60.916667, - 11: 61.0, - 12: 61.0, - }, - 1951: { - 1: 61.083333, - 2: 61.083333, - 3: 61.166667, - 4: 61.166667, - 5: 61.25, - 6: 61.25, - 7: 61.333333, - 8: 61.333333, - 9: 61.416667, - 10: 61.416667, - 11: 61.5, - 12: 61.5, - }, - 1952: { - 1: 61.583333, - 2: 61.583333, - 3: 61.666667, - 4: 61.666667, - 5: 61.75, - 6: 61.75, - 7: 61.833333, - 8: 61.833333, - 9: 61.916667, - 10: 61.916667, - 11: 62.0, - 12: 62.0, - }, - vertrauensschutz: 60.0, - } - - // Increase of ERA was revoked. - // Reference: Wachstums- und Beschäftigungsförderungsgesetz 1996. BGBl. I S. 1461 1996 - from 1996-09-27 = 60.0, - - from 2004-07-26 = { - max_birthyear_old_regime: 1945, - min_birthyear_new_regime: 1949, - entry_age_old_regime: 60.0, - entry_age_new_regime: 63.0, - 1946: { - 1: 60.083333, - 2: 60.166667, - 3: 60.25, - 4: 60.333333, - 5: 60.416667, - 6: 60.5, - 7: 60.583333, - 8: 60.666667, - 9: 60.75, - 10: 60.833333, - 11: 60.916667, - 12: 61.0, - }, - 1947: { - 1: 61.083333, - 2: 61.166667, - 3: 61.25, - 4: 61.333333, - 5: 61.416667, - 6: 61.5, - 7: 61.583333, - 8: 61.666667, - 9: 61.75, - 10: 61.833333, - 11: 61.916667, - 12: 62.0, - }, - 1948: { - 1: 62.083333, - 2: 62.166667, - 3: 62.25, - 4: 62.333333, - 5: 62.416667, - 6: 62.5, - 7: 62.583333, - 8: 62.666667, - 9: 62.75, - 10: 62.833333, - 11: 62.916667, - 12: 63.0, - }, - vertrauensschutz: 60.0, - } - - // Same statutory retirement ages as before, but abolishment with birth cohort 1952. - // Reference: RV-Nachhaltigkeitsgesetz 2004 and RV-Altersgrenzenanpassungsgesetz 2007. - from 2007-04-30 = { - first_birthyear_without_rente_für_arbeitsl: 1952, - max_birthyear_old_regime: 1945, - min_birthyear_new_regime: 1949, - entry_age_old_regime: 60.0, - entry_age_new_regime: 63.0, - 1946: { - 1: 60.083333, - 2: 60.166667, - 3: 60.25, - 4: 60.333333, - 5: 60.416667, - 6: 60.5, - 7: 60.583333, - 8: 60.666667, - 9: 60.75, - 10: 60.833333, - 11: 60.916667, - 12: 61.0, - }, - 1947: { - 1: 61.083333, - 2: 61.166667, - 3: 61.25, - 4: 61.333333, - 5: 61.416667, - 6: 61.5, - 7: 61.583333, - 8: 61.666667, - 9: 61.75, - 10: 61.833333, - 11: 61.916667, - 12: 62.0, - }, - 1948: { - 1: 62.083333, - 2: 62.166667, - 3: 62.25, - 4: 62.333333, - 5: 62.416667, - 6: 62.5, - 7: 62.583333, - 8: 62.666667, - 9: 62.75, - 10: 62.833333, - 11: 62.916667, - 12: 63.0, - }, - vertrauensschutz: 60.0, - } -} - -/** - * Altersgrenze für vorzeitigen Bezug der Altersrente für langjährig Versicherte - * Frühestmögliches Alter ab dem die Altersrente für langjährig Versicherte - * bezogen werden kann (mit Abschlägen). - * Reference: § 236 SGB VI - */ -const gesetzlicheRenteAltersgrenzeLangjährigVersicherteVorzeitig: Float { - from 1980-01-01 = 63.0 -} - -/** - * Eintrittsalter für langjährig Versicherte - abschlagsfrei - * Stückweise lineare Funktion, die die Regelaltersgrenze angibt, bei der das - * Individuum mit seinem vollen Rentenanspruch in Rente gehen kann. Geht die Person - * früher oder später in Rente, ist der Zugangsfaktor und damit der Rentenanspruch - * höher oder niedriger, wenn keine Ausnahmeregelungen erfüllt sind. - * Reference: § 236 SGB VI - */ -const gesetzlicheRenteAltersgrenzeLangjährigVersicherteAbschlagsfrei: Dict> { - from 1984-01-01 = { - 0: { - lower_threshold: -inf, - upper_threshold: 1936.916666666, - rate_linear: 0, - intercept_at_lower_threshold: 63, - }, - 1: { - upper_threshold: 1938.916666666, - rate_linear: 1, - }, - 2: { - upper_threshold: 1948.916666666, - rate_linear: 0, - }, - 3: { - upper_threshold: 1949.25, - rate_linear: 1, - }, - 4: { - upper_threshold: 1950, // 1950.91667 - rate_linear: 0, - }, - 5: { - upper_threshold: 1958, - rate_linear: 0.083333333, - }, - 6: { - upper_threshold: 1964, - rate_linear: 0.16666666, - }, - 7: { - upper_threshold: inf, - rate_linear: 0, - }, - } -} - -/** - * Kohorte Angleichung Rente langjährig Versicherte - * Kohorte, ab der Altersgrenze für abschlagfreie Rente für langjährig Versicherte an - * Altersgrenze Regelaltersrente angeglichen wurde. - * Reference: § 237 SGB VI - */ -const gesetzlicheRenteAlignmentCohortLangjährigVersicherte: Int { - from 1980-01-01 = 1950 -} - -/** - * Eintrittsalter für besonders langjährig Versicherte - abschlagsfrei (Rente mit 63) - * Stückweise lineare Funktion, die die Regelaltersgrenze angibt, bei der das - * Individuum mit seinem vollen Rentenanspruch in Rente gehen kann. Geht die Person - * früher oder später in Rente, ist der Zugangsfaktor und damit der Rentenanspruch - * höher oder niedriger, wenn keine Ausnahmeregelungen erfüllt sind. - * Ab dem 1.7.2014 wurde die Altersgrenze für Kohorten bis 1952 auf 63 Jahre - * gesenkt (für nachfolgende Kohorten steigt sie um 2 Monate pro Kohorte bis - * 65). Personen, die vor dem 1.7.1951 (codiert als 1951.5) geboren wurden, - * waren zu diesem Zeitpunkt aber schon älter als 63 und hatten ensprechend ein - * höheres verfügbares Renteneintrittsalter. Nur Personen, die ab dem 1.7.1949 - * geboren wurden konnten überhaupt profitieren, da alle anderen schon über 65 - * waren. Für die Zugangsfaktor berechnung werden die tatsächlich verfügbaren - * Renteneintrittsalter benötigt. Daher brauchen wir für die inputs eine - * monatliche Präzision bis Kohorte 1952. - * Reference: § 38 SGB VI - */ -const gesetzlicheRenteAltersgrenzeBesondersLangjährigVersicherte: Dict> { - from 2012-01-01 = { - 0: { - lower_threshold: -inf, - upper_threshold: inf, - rate_linear: 0, - intercept_at_lower_threshold: 65, - }, - }, - from 2014-07-01 = { - 0: { - lower_threshold: -inf, - upper_threshold: 1949.5, - rate_linear: 0, - intercept_at_lower_threshold: 65, - }, - 1: { - upper_threshold: 1951.5, - rate_linear: -1, - }, - 2: { - upper_threshold: 1952, - rate_linear: 0, - }, - 3: { - upper_threshold: 1964, - rate_linear: 0.16666666, - }, - 4: { - upper_threshold: inf, - rate_linear: 0, - } - } -} - -/** - * Kohorte Implementierung Rente für besonders langjährig Versicherte - * Kohorte, ab der Rente für besonders langjährig Versicherte vollständig eingeführt. - * Reference: § 237 SGB VI - */ -const gesetzlicheRenteFirstBirthyearBesondersLangjährigVersicherte: Int { - from 2012-01-01 = 1952 -} - -// TODO: rounding -// TODO: threshholdswartezeiten - -// grunds_im_alter.yaml -------------------------------------------------- - ---- -vermögensfreibetrag: - name: - de: Schonvermögen für Grundsicherung im Alter - en: Allowed amount of wealth for Grundsicherung im Alter - description: - de: >- - Ab dieser Vermögensschwelle besteht kein Anspruch auf Grundsicherung im Alter / - bei Erwerbsminderung. - en: >- - There is no entitlement to Grundsicherung im Alter / bei Erwerbsminderung if - assets exceed this threshold. - unit: Euro - reference: >- - § 1 Verordnung zur Durchführung des § 90 Abs. 2 Nr. 9 des Zwölften Buches - Sozialgesetzbuch - 1984-01-01: - adult: 0 - child: 0 - 2003-01-01: - adult: 2600 - child: 0 - 2017-04-01: - adult: 5000 - child: 500 -ges_rente_anr_frei: - name: - de: Anrechnungsfreier Anteil der staatlichen Rente (bei mind. 33 Grundrentenzeiten) - en: >- - Public pension share not subject to transfer withdrawal (if at least 33 - Grundrentenzeiten) - description: - de: >- - Anrechnungsfreie Anteile staatliche Rente wenn mindestens 33 Jahre - Grundrentenzeiten erreicht wurden. - en: >- - Public pension shares not subject to transfer withdrawal for subjects whose - Grundrentenzeiten exceeds 33 years. - unit: Share - type: piecewise_linear - 1984-01-01: - reference: No income could be deducted - 0: - lower_threshold: -inf - upper_threshold: inf - rate: 0 - intercept_at_lower_threshold: 0 - 2021-01-01: - reference: § 82a Abs. 1 und 2 SGB XII - 0: - lower_threshold: -inf - upper_threshold: 0 - rate: 0 - intercept_at_lower_threshold: 0 - 1: - lower_threshold: 0 - upper_threshold: 100 - rate: 1 - 2: - upper_threshold: inf - rate: 0.3 -kapitaleink_anr_frei: - name: - de: Freibetrag des Kapitaleinkommens für Grundsicherung - en: Amount of capital income not subject to transfer withdrawal - description: - de: >- - Nur das Kapitaleinkommens, das über diesem Freibetrag liegt, wird auf die - Grundsicherung im Alter angerechnet. The reference is § 82 SGB XII Abs. 2. - en: >- - Only the capital income above the threshold is considered for the calculation of - the Grundsicherung im Alter. - unit: Euro - reference_period: Year - 1984-01-01: - scalar: 0 - note: null - 2016-01-01: - reference: § 43 SGB XII Abs. 2 - scalar: 26 -erwerbseink_anr_frei: - name: - de: Anrechnungsfreier Anteil des Erwerbseinkommens für Grundsicherung - en: Income shares not subject to transfer withdrawal - description: - de: >- - Anteil des Erwerbseinkommens, welcher bei der Berechnung der Grundsicherung nicht - zum Einkommen addiert wird. - en: >- - Share of income, which is not added to the total income when calculating the - Grundsicherung. - unit: Share - reference: § 82 SGB XII Abs. 3 - 1984-01-01: - scalar: 0 - note: Unclear how it was handled before 2005 - 2005-01-01: - scalar: 0.3 -priv_rente_anr_frei: - name: - de: Anrechnungsfreie Anteile der privaten Rente für Grundsicherung - en: Private pension shares not subject to transfer withdrawal - description: - de: >- - Anteil der privaten Rente, welcher bei der Berechnung der Grundsicherung nicht zum - Einkommen addiert wird. - en: >- - Share of privat pension, which is not added to total income when calculating the - Grundsicherung. - unit: Share - type: piecewise_linear - reference: § 82 SGB XII Abs. 4 - 1984-01-01: - reference: Unclear how it was handled before 2005 - 0: - lower_threshold: -inf - upper_threshold: inf - rate: 0 - intercept_at_lower_threshold: 0 - 2005-01-01: - 0: - lower_threshold: -inf - upper_threshold: 0 - rate: 0 - intercept_at_lower_threshold: 0 - 1: - lower_threshold: 0 - upper_threshold: 100 - rate: 1 - 2: - upper_threshold: inf - rate: 0.3 -mehrbedarf_schwerbeh_g: - name: - de: Mehrbedarf bei Schwerbehinderung - en: Additional requirement when severely disabled - description: - de: >- - Dieser Prozentanteil des Regelbedarfs wird Menschen mit Schwerbehindertenausweis - mit Merkzeichen G, die Grundsicherung im Alter oder bei Erwerbsminderung bekommen, - als Mehrbedarf anerkannt. - en: >- - This percentage of the normal requirement is added as an additional requirement - for someone who has a severly disabled ID card which shows the code 'G' and is - entitled to the Grundsicherung. - unit: Percent - reference: § 30 Abs. 1 SGB XII, https://www.buzer.de/gesetz/3415/al0-3758.htm - 2006-12-07: - scalar: 0.17 - -/** - * Schonvermögen für Grundsicherung im Alter - * Ab dieser Vermögensschwelle besteht kein Anspruch auf Grundsicherung im Alter / - * bei Erwerbsminderung. - * Reference: § 1 Verordnung zur Durchführung des § 90 Abs. 2 Nr. 9 des Zwölften Buches - * Sozialgesetzbuch - */ -const grundsicherungImAlterVermoegensfreibetrag: Dict { - from 1984-01-01: { - adult: 0, - child: 0, - }, - from 2003-01-01: { - adult: 2600, - child: 0, - }, - from 2017-04-01: { - adult: 5000, - child: 500, - }, -} - -/** - * Anrechnungsfreier Anteil der staatlichen Rente (bei mind. 33 Grundrentenzeiten) - * Anrechnungsfreie Anteile staatliche Rente wenn mindestens 33 Jahre - * Grundrentenzeiten erreicht wurden. - */ -const grundsicherungImAlterGesetzlicheRenteAnrechnungsfrei: Dict> { - from 1984-01-01: { - 0: { - lower_threshold: -inf, - upper_threshold: inf, - rate: 0, - intercept_at_lower_threshold: 0, - }, - }, - from 2021-01-01: { - 0: { - lower_threshold: -inf, - upper_threshold: 0, - rate: 0, - intercept_at_lower_threshold: 0, - }, - 1: { - lower_threshold: 0, - upper_threshold: 100, - rate: 1, - }, - 2: { - upper_threshold: inf, - rate: 0.3, - }, - }, -} - -/** - * Freibetrag des Kapitaleinkommens für Grundsicherung - * Nur das Kapitaleinkommens, das über diesem Freibetrag liegt, wird auf die - * Grundsicherung im Alter angerechnet. The reference is § 82 SGB XII Abs. 2. - */ -const grundsicherungImAlterKapitaleinkommensfreibetrag: Int { - from 1984-01-01 = 0 - - // Reference: § 43 SGB XII Abs. 2 - from 2016-01-01 = 26 -} - -/** - * Anrechnungsfreier Anteil des Erwerbseinkommens für Grundsicherung - * Anteil des Erwerbseinkommens, welcher bei der Berechnung der Grundsicherung nicht - * zum Einkommen addiert wird. - * Reference: § 82 SGB XII Abs. 3 - */ -const grundsicherungImAlterErwerbseinkommensfreibetrag: Float { - // Unclear how it was handled before 2005 - from 1984-01-01 = 0 - - from 2005-01-01 = 0.3 -} - -/** - * Anrechnungsfreie Anteile der privaten Rente für Grundsicherung - * Anteil der privaten Rente, welcher bei der Berechnung der Grundsicherung nicht zum - * Einkommen addiert wird. - * Reference: § 82 SGB XII Abs. 4 - */ -const grundsicherungImAlterPrivateRenteAnrechnungsfrei: Dict> { - from 1984-01-01: { - // Unclear how it was handled before 2005, - 0: { - lower_threshold: -inf, - upper_threshold: inf, - rate: 0, - intercept_at_lower_threshold: 0, - }, - }, - from 2005-01-01: { - 0: { - lower_threshold: -inf, - upper_threshold: 0, - rate: 0, - intercept_at_lower_threshold: 0, - }, - 1: { - lower_threshold: 0, - upper_threshold: 100, - rate: 1, - }, - 2: { - upper_threshold: inf, - rate: 0.3, - }, - }, -} - -/** - * Mehrbedarf bei Schwerbehinderung - * Dieser Prozentanteil des Regelbedarfs wird Menschen mit Schwerbehindertenausweis - * mit Merkzeichen G, die Grundsicherung im Alter oder bei Erwerbsminderung bekommen, - * als Mehrbedarf anerkannt. - * Reference: § 30 Abs. 1 SGB XII, https://www.buzer.de/gesetz/3415/al0-3758.htm - */ -const grundsicherungImAlterMehrbedarfSchwerbehinderung: Float { - from 2006-12-07 = 0.17 -} From 386f8058ffd74519de8a0fb42716a531a57fc333 Mon Sep 17 00:00:00 2001 From: alex-senger Date: Thu, 16 May 2024 11:47:48 +0200 Subject: [PATCH 028/183] feat: add kindergeld parameters --- src/resources/builtins/kindergeld.ttsl | 257 +++++++++++++++++++++++++ 1 file changed, 257 insertions(+) create mode 100644 src/resources/builtins/kindergeld.ttsl diff --git a/src/resources/builtins/kindergeld.ttsl b/src/resources/builtins/kindergeld.ttsl new file mode 100644 index 00000000..f09add34 --- /dev/null +++ b/src/resources/builtins/kindergeld.ttsl @@ -0,0 +1,257 @@ +package kindergeld + +/** + * Alter, ab dem Kindergeld nicht mehr gezahlt wird. + * Für minderjährige Kinder besteht ohne Bedingungen ein Anspruch auf Kindergeld. + * Auch für erwachsene Kinder kann bis zu einer Altersgrenze unter bestimmten + * Bedingungen ein Anspruch auf Kindergeld bestehen. + * Reference: § 32 Art. 2-4 EStG. + */ +const altersgrenze: Dict { + from 1984-01-01 = { + mit_bedingungen: 27 + ohne_bedingungen: 18 + } + + // Reference: Art. 1 G. v. 19.07.2006 BGBl I S. 1652 + from 2007-01-01 = { + mit_bedingungen: 25 + ohne_bedingungen: 18 + } +} + +/** + * Kindergeld, Betrag je nach Reihenfolge der Kinder. + * § 66 (1) EStG. Identische Werte in §6 (1) BKGG, diese sind aber nur für beschränkt + * Steuerpflichtige relevant (d.h. Ausländer mit Erwerbstätigkeit in Deutschland). + * Für Werte vor 2002, siehe 'BMF - Datensammlung zur Steuerpolitik' + * reference period: Month + */ +const kindergeld: Dict { + from 1975-01-01 = { + 1: 26 + 2: 36 + 3: 61 + 4: 61 + } + + from 1978-01-01 = { + 1: 26 + 2: 41 + 3: 77 + 4: 77 + } + + from 1979-01-01 = { + 1: 26 + 2: 51 + 3: 102 + 4: 102 + } + + from 1979-07-01 = { + 1: 26 + 2: 61 + 3: 102 + 4: 102 + } + + from 1981-02-01 = { + 1: 26 + 2: 61 + 3: 123 + 4: 123 + } + + from 1982-01-01 = { + 1: 26 + 2: 51 + 3: 112 + 4: 123 + } + + from 1990-07-01 = { + 1: 26 + 2: 66 + 3: 112 + 4: 123 + } + + from 1992-01-01 = { + 1: 36 + 2: 66 + 3: 112 + 4: 123 + } + + from 1996-01-01 = { + 1: 102 + 2: 102 + 3: 153 + 4: 179 + } + + from 1997-01-01 = { + 1: 112 + 2: 112 + 3: 153 + 4: 179 + } + + from 1999-01-01 = { + 1: 128 + 2: 128 + 3: 153 + 4: 179 + } + + from 2000-01-01 = { + 1: 138 + 2: 138 + 3: 153 + 4: 179 + } + + from 2002-01-01 = { + 1: 154 + 2: 154 + 3: 154 + 4: 179 + } + + // Reference: Art. 1 G. v. 22.12.2008 BGBl. I S. 2955 + from 2009-01-01 = { + 1: 164 + 2: 164 + 3: 170 + 4: 195 + } + + // Reference: Art. 1 G. v. 02.03.2009 BGBl. I S. 416 + from 2009-03-01 = { + 1: 164 + 2: 164 + 3: 170 + 4: 195 + } + + // Reference: Art. 1 G. v. 22.12.2009 BGBl. I S. 3950 + from 2009-12-01 = { + 1: 184 + 2: 184 + 3: 190 + 4: 215 + } + + // Reference: Art. 1 G. v. 16.07.2015 BGBl. I S. 1202 + from 2015-07-01 = { + 1: 188 + 2: 188 + 3: 194 + 4: 219 + } + + // Reference: Art. 2 G. v. 16.07.2015 BGBl. I S. 1202 + from 2016-01-01 = { + 1: 190 + 2: 190 + 3: 196 + 4: 221 + } + + // Reference: Art. 8 G. v. 20.12.2016 BGBl. I S. 3000 + from 2017-01-01 = { + 1: 192 + 2: 192 + 3: 198 + 4: 223 + } + + // Reference: Art. 9 G. v. 20.12.2016 BGBl. I S. 3000. + from 2018-01-01 = { + 1: 194 + 2: 194 + 3: 200 + 4: 225 + } + + // Reference: Art. 2 G. v. 29.11.2018 BGBl. I S. 2210. + from 2019-07-01 = { + 1: 204 + 2: 204 + 3: 210 + 4: 235 + } + + // Reference: Art. 1 Abs. 9 G. v. 01.12.2020 BGBl. I S. 2616. + from 2021-01-01 = { + 1: 219 + 2: 219 + 3: 225 + 4: 250 + } + + // Reference: Art. 6 G. v. 08.12.2022 BGBl. I S. 2230. + from 2023-01-01 = { + 1: 250 + 2: 250 + 3: 250 + 4: 250 + } +} + +/** + * Einkommensgrenze der Kinder für Kindergeldanspruch + * § 32 (4) EStG. Wurde 2012 durch eine Höchstgrenze der gearbeiteten Stunden ersetzt. + * reference period: Year + */ +const einkommensgrenze: Int { + from 1984-01-01 = 0 + + // Reference: Art. 1 G. v. 11.10.1995 BGBl. I S. 1250 + from 1996-01-01 = 6136 + + from 1999-01-01 = 6657 + + from 2000-01-01 = 6902 + + from 2001-01-01 = 7179 + + // Reference: Art. 1 G. v. 16.08.2001 BGBl. I S. 2074 + from 2002-01-01 = 7188 + + from 2004-01-01 = 7680 + + // Reference: Art. 1 G. v. 16.07.2009 BGBl. I S. 1959 + from 2009-01-01 = 8004 +} + +/** + * Wochenstundengrenze für Kindergeldanspruch + * §32 (4) S. 3 EStG. Maximale Anzahl von erlaubten Wochenstunden des Kindes für den + * Bezug von Kindergeld + * reference period: Week + */ +const stundengrenze: Int { + // Reference: Art. 1 G. v. 01.11.2011 BGBl. I S. 2131 + from 2012-01-01 = 20 +} + +/** + * Kinderbonus (Einmalzahlung) + * Aufstockung des Kindergeldes während COVID-19 Pandemie. Wurde im September/Oktober + * 2020 bzw. Mai 2021 ausgezahlt, aber ist hier auf das volle Kalenderjahr angerechnet. + * reference period: Year + */ +const kinderbonus: Dict { + from 1984-01-01 = 0 + + // Reference: Art. 1 Zweites Corona-Steuerhilfegesetz v. 29.06.2020 BGBl. I S. 1512 + from 2020-01-01 = 300 + + // Reference: Art. 1 Drittes Corona-Steuerhilfegesetz v. 10.03.2021 BGBl. I S. 330 + from 2021-01-01 = 150 + + // only one-time payment + from 2022-01-01 = 0 +} From b6cca3a054e9517c24d53cbf5f157ad036693260 Mon Sep 17 00:00:00 2001 From: alex-senger Date: Sat, 18 May 2024 20:20:22 +0200 Subject: [PATCH 029/183] feat: add kinderzuschlag --- src/resources/builtins/kinderzuschlag.ttsl | 839 ++++++++++++++++++ .../builtins/kinderzuschlagEinkommen.ttsl | 18 + 2 files changed, 857 insertions(+) create mode 100644 src/resources/builtins/kinderzuschlag.ttsl create mode 100644 src/resources/builtins/kinderzuschlagEinkommen.ttsl diff --git a/src/resources/builtins/kinderzuschlag.ttsl b/src/resources/builtins/kinderzuschlag.ttsl new file mode 100644 index 00000000..72f22fd7 --- /dev/null +++ b/src/resources/builtins/kinderzuschlag.ttsl @@ -0,0 +1,839 @@ +package kidnerzuschlag + +--- +maximum: + name: + de: Maximale Höhe des Kinderzuschlags + en: Maximum additional child benefit + description: + de: § 6a (2) BKGG. Betrag pro Kind + en: Amount per child. + unit: Euro + reference_period: Month + 2005-01-01: + scalar: 140 + reference: Art. 46 G. v. 24.12.2003 BGBl. I S. 2954. + 2017-01-01: + scalar: 170 + reference: Art. 12 G. v. 20.12.2016 BGBl. I S. 3000. + 2019-07-01: + scalar: 185 + reference: Art. 1 G. v. 29.04.2019 BGBl. I S. 530. + note: For 2020, Art. 2 Nr. 4 G. v. 29.04.2019 BGBl. I S. 530. + 2021-01-01: + scalar: null + reference: § 6a (2) BKGG + note: Ab 2021 wird der Betrag aus anderen Parametern berechnet. + 2023-01-01: + scalar: 250 + reference: Art. 6 G. v. 08.12.2022 BGBl. I S. 2230. + note: Regelung für das Kalenderjahr 2023, abweichend von § 6a Absatz 2. + 2024-01-01: + scalar: null + reference: § 6a (2) BKGG + note: Ab 2024 wird der Betrag wieder aus anderen Parametern berechnet. +kindersofortzuschl: + name: + de: Kindersofortzuschlag für Kinderzuschlag + en: Instant surcharge for children for additional child benefit + description: + de: >- + Mit Einführung des Sofortzuschlags zum 1. Juli 2022 + steigt der Höchstbetrag im Kinderzuschlag um 20 Euro. + en: >- + With the introduction of the immediate supplement from July 1, 2022, + the maximum amount in the child supplement increases by 20 euros. + unit: Euros + reference: § 6a Abs. 2 Satz 4 BKGG + 2022-07-01: + scalar: 20 + 2023-01-01: + scalar: null + 2024-01-01: + scalar: 20 +min_eink_paare: + name: + de: Mindesteinkommen für Paare + en: Minimum income to be eligible for add. child benefit (couples) + description: + de: § 6a (1) Nr. 2 BKGG. + en: null + unit: Euro + reference_period: Month + 2005-01-01: + scalar: 0 + note: kein expliziter Wert im Gesetz. + 2008-10-01: + scalar: 900 + reference: Art. 1 G. v. 24.09.2008 BGBl. I S. 1854. +min_eink_alleinerz: + name: + de: Mindesteinkommen für Alleinerziehende + en: Minimum income for single parents + description: + de: § 6a (1) Nr. 2 BKGG. + en: null + unit: Euro + reference_period: Month + 2005-01-01: + scalar: 0 + note: kein expliziter Wert im Gesetz. + 2008-10-01: + scalar: 600 + reference: Art. 1 G. v. 24.09.2008 BGBl. I S. 1854. +entzugsrate_eltern: + name: + de: Minderungsrate durch Einkommen der Eltern über BMG + en: Transfer withdrawal rate for parent's income + description: + de: >- + § 6a (6) BKGG, bis 01.07.2019 § 6a (4) BKGG. Rate, mit der der + Gesamtkinderzuschlag nach Erreichen der Bemessungsgrenze durch Einkommen der + Eltern gemindert wird. Bis 07/2019 wurde das Einkommen nur in 10€-Schritten + berücksichtigt. + en: null + unit: Share + 2005-01-01: + scalar: 0.7 + reference: Art. 46 G. v. 24.12.2003 BGBl. I. S. 2954. + 2008-10-01: + scalar: 0.5 + reference: Art. 1 G. v. 24.09.2008 BGBl. I S. 1854. + 2020-01-01: + scalar: 0.45 + reference: Art. 1 G. v. 29.04.2019 BGBl. I S. 530. +entzugsrate_kind: + name: + de: Minderungsrate durch Einkommen des Kindes + en: Rate at which child income is deducted + description: + de: >- + § 6a (3) BKGG. Einkommen des Kindes beinhaltet auch Unterhalt und + Unterhaltsvorschuss. + en: >- + Child alimony and alimony advance payments are also attributed to the child. + unit: Share + 2005-01-01: + scalar: 1 + reference: Art. 46 G. v. 24.12.2003 BGBl. I. S. 2954. + 2019-07-01: + scalar: 0.45 + reference: Art. 1 G. v. 29.04.2019 BGBl. I S. 530. +existenzminimum: + name: + de: >- + Höhen des Existenzminimums, festgelegt im Existenzminimumsbericht der + Bundesregierung. + en: null + description: + de: >- + Berechnet für jeweils zwei Jahre die Höhe der steuerfrei zu stellenden + Existenzminima (nicht identisch mit dem steuerlichen Grundfreibetrag). + en: >- + Every two years, the government calculates the subsistence levels 'to be allowed + from taxation'. These form the basis for a number of kiz parameters. + unit: Euro + reference_period: Year + 2005-01-01: + regelsatz: + single: 4164 + paare: 7488 + kinder: 2688 + kosten_der_unterkunft: + single: 2592 + paare: 3984 + kinder: 804 + heizkosten: + single: 600 + paare: 768 + kinder: 156 + reference: 5. Existenzminimumsbericht, Bundestag Drucksache 15/2462, Übersicht 3 + 2008-01-01: + regelsatz: + single: 4140 + paare: 7464 + kinder: 2676 + kosten_der_unterkunft: + single: 2364 + paare: 4020 + kinder: 804 + heizkosten: + single: 636 + paare: 792 + kinder: 168 + reference: 6. Existenzminimumsbericht, Bundestag Drucksache 16/3265, Übersicht 3 + 2010-01-01: + regelsatz: + single: 4368 + paare: 7860 + kinder: 2820 + kosten_der_unterkunft: + single: 2520 + paare: 4164 + kinder: 840 + heizkosten: + single: 768 + paare: 972 + kinder: 204 + reference: 7. Existenzminimumsbericht, Bundestag Drucksache 16/11065, Übersicht 3 + 2012-01-01: + regelsatz: + single: 4488 + paare: 8064 + kinder: 2988 + bildung_und_teilhabe: + kinder: 228 + kosten_der_unterkunft: + single: 2724 + paare: 4344 + kinder: 876 + heizkosten: + single: 684 + paare: 864 + kinder: 180 + reference: 8. Existenzminimumsbericht, Bundestag Drucksache 17/5550, Übersicht 4 + 2013-01-01: + regelsatz: + single: 4584 + paare: 8064 + kinder: 2988 + bildung_und_teilhabe: + kinder: 228 + kosten_der_unterkunft: + single: 2796 + paare: 4344 + kinder: 876 + heizkosten: + single: 744 + paare: 864 + kinder: 180 + reference: >- + 9. Existenzminimumsbericht, Bundestag Drucksache 17/5550, Übersicht 5. Werte nur + für Singles anders + 2014-01-01: + regelsatz: + single: 4680 + paare: 8448 + kinder: 3096 + bildung_und_teilhabe: + kinder: 228 + kosten_der_unterkunft: + single: 2868 + paare: 4560 + kinder: 912 + heizkosten: + single: 804 + paare: 1008 + kinder: 204 + reference: 9. Existenzminimumsbericht, Bundestag Drucksache 17/5550, Übersicht 5. + 2015-01-01: + regelsatz: + single: 4788 + paare: 8448 + kinder: 3168 + bildung_und_teilhabe: + kinder: 228 + kosten_der_unterkunft: + single: 2988 + paare: 4560 + kinder: 936 + heizkosten: + single: 696 + paare: 1008 + kinder: 180 + reference: >- + 10. Existenzminimumsbericht, Bundestag Drucksache 17/5550, + Übersicht 4. Werte für Paare unverändert. + 2016-01-01: + regelsatz: + single: 4872 + paare: 8784 + kinder: 3228 + bildung_und_teilhabe: + kinder: 228 + kosten_der_unterkunft: + single: 3060 + paare: 4788 + kinder: 960 + heizkosten: + single: 720 + paare: 900 + kinder: 192 + reference: 10. Existenzminimumsbericht, Bundestag Drucksache 17/5550, Übersicht 4. + 2017-01-01: + regelsatz: + single: 4908 + paare: 8784 + kinder: 3336 + bildung_und_teilhabe: + kinder: 228 + kosten_der_unterkunft: + single: 3312 + paare: 4788 + kinder: 996 + heizkosten: + single: 600 + paare: 900 + kinder: 156 + reference: 11. Existenzminimumsbericht, Bundestag Drucksache 18/10220, Übersicht 4. + note: Werte für Paare unverändert. + 2018-01-01: + regelsatz: + single: 4968 + paare: 8952 + kinder: 3372 + bildung_und_teilhabe: + kinder: 228 + kosten_der_unterkunft: + single: 3396 + paare: 5088 + kinder: 1020 + heizkosten: + single: 636 + paare: 816 + kinder: 168 + reference: 11. Existenzminimumsbericht, Bundestag Drucksache 18/10220, Übersicht 4. + 2019-01-01: + regelsatz: + single: 5088 + paare: 8952 + kinder: 3456 + bildung_und_teilhabe: + kinder: 228 + kosten_der_unterkunft: + single: 3468 + paare: 5088 + kinder: 1044 + heizkosten: + single: 612 + paare: 816 + kinder: 168 + reference: 12. Existenzminimumsbericht, Bundestag Drucksache 19/5400, Übersicht 4. + 2020-01-01: + regelsatz: + single: 5196 + paare: 9360 + kinder: 3528 + bildung_und_teilhabe: + kinder: 228 + kosten_der_unterkunft: + single: 3552 + paare: 5328 + kinder: 1068 + heizkosten: + single: 660 + paare: 852 + kinder: 180 + reference: 12. Existenzminimumsbericht, Bundestag Drucksache 19/5400, Übersicht 4. + 2021-01-01: + regelsatz: + single: 5352 + paare: 9360 + kinder: 3780 + bildung_und_teilhabe: + kinder: 324 + kosten_der_unterkunft: + single: 3612 + paare: 5328 + kinder: 1092 + heizkosten: + single: 780 + paare: 852 + kinder: 216 + reference: 13. Existenzminimumsbericht, Bundestag Drucksache 19/22800, Übersicht 4. + 2022-01-01: + regelsatz: + single: 5400 + paare: 9720 + kinder: 3816 + bildung_und_teilhabe: + kinder: 324 + kosten_der_unterkunft: + single: 3684 + paare: 5520 + kinder: 1104 + heizkosten: + single: 804 + paare: 1080 + kinder: 216 + reference: 13. Existenzminimumsbericht, Bundestag Drucksache 19/22800, Übersicht 4. + 2023-01-01: + deviation_from: previous + regelsatz: + single: 6024 + kinder: 4248 + bildung_und_teilhabe: + kinder: 336 + kosten_der_unterkunft: + single: 3828 + kinder: 1152 + heizkosten: + single: 1056 + kinder: 288 + reference: 14. Existenzminimumsbericht, Bundestag Drucksache 20/4443, Übersicht 4. + 2024-01-01: + regelsatz: + single: 6444 + paare: 11592 + kinder: 4548 + bildung_und_teilhabe: + kinder: 336 + kosten_der_unterkunft: + single: 3684 + paare: 5892 + kinder: 1188 + heizkosten: + single: 1104 + paare: 1500 + kinder: 312 + reference: 14. Existenzminimumsbericht, Bundestag Drucksache 20/4443, Übersicht 4. + +/** + * Maximale Höhe des Kinderzuschlags + * Reference: § 6a (2) BKGG. Betrag pro Kind + */ +const maximum: Int { + // Reference: Art. 46 G. v. 24.12.2003 BGBl. I S. 2954. + from 2005-01-01 = 140 + + // Reference: Art. 12 G. v. 20.12.2016 BGBl. I S. 3000. + from 2017-01-01 = 170 + + // Reference: Art. 1 G. v. 29.04.2019 BGBl. I S. 530. + // Note: For 2020, Art. 2 Nr. 4 G. v. 29.04.2019 BGBl. I S. 530. + from 2019-07-01 = 185 + + // Reference: § 6a (2) BKGG + // Note: Ab 2021 wird der Betrag aus anderen Parametern berechnet. + from 2021-01-01 = null + + // Reference: Art. 6 G. v. 08.12.2022 BGBl. I S. 2230. + // Note: Regelung für das Kalenderjahr 2023, abweichend von § 6a Absatz 2. + from 2023-01-01 = 250 + + // Reference: § 6a (2) BKGG + // Note: Ab 2024 wird der Betrag wieder aus anderen Parametern berechnet. + from 2024-01-01 = null +} + +/** + * Kindersofortzuschlag für Kinderzuschlag + * With the introduction of the immediate supplement from July 1, 2022, + * the maximum amount in the child supplement increases by 20 euros. + * § 6a Abs. 2 Satz 4 BKGG + */ +const kindersofortzuschl: Int { + // Reference: § 6a Abs. 2 Satz 4 BKGG + from 2022-07-01 = 20 + + from 2023-01-01 = null + + from 2024-01-01 = 20 +} + +/** + * Mindesteinkommen für Paare + * Reference: § 6a (1) Nr. 2 BKGG. + */ +const min_eink_paare: Int { + // Reference: kein expliziter Wert im Gesetz. + from 2005-01-01 = 0 + + // Reference: Art. 1 G. v. 24.09.2008 BGBl. I S. 1854. + from 2008-10-01 = 900 +} + +/** + * Mindesteinkommen für Alleinerziehende + * Reference: § 6a (1) Nr. 2 BKGG. + */ +const min_eink_alleinerz: Int { + // Reference: kein expliziter Wert im Gesetz. + from 2005-01-01 = 0 + + // Reference: Art. 1 G. v. 24.09.2008 BGBl. I S. 1854. + from 2008-10-01 = 600 +} + +/** + * Minderungsrate durch Einkommen der Eltern über BMG + * § 6a (6) BKGG, bis 01.07.2019 § 6a (4) BKGG. Rate, mit der der + * Gesamtkinderzuschlag nach Erreichen der Bemessungsgrenze durch Einkommen der + * Eltern gemindert wird. Bis 07/2019 wurde das Einkommen nur in 10€-Schritten + * berücksichtigt. + */ +const entzugsrate_eltern: Float { + // Reference: Art. 46 G. v. 24.12.2003 BGBl. I. S. 2954. + from 2005-01-01 = 0.7 + + // Reference: Art. 1 G. v. 24.09.2008 BGBl. I S. 1854. + from 2008-10-01 = 0.5 + + // Reference: Art. 1 G. v. 29.04.2019 BGBl. I S. 530. + from 2020-01-01 = 0.45 +} + +/** + * Minderungsrate durch Einkommen des Kindes + * § 6a (3) BKGG. Einkommen des Kindes beinhaltet auch Unterhalt und + * Unterhaltsvorschuss. + * Reference: § 6a (3) BKGG + */ +const entzugsrate_kind: Float { + // Reference: Art. 46 G. v. 24.12.2003 BGBl. I. S. 2954. + from 2005-01-01 = 1 + + // Reference: Art. 1 G. v. 29.04.2019 BGBl. I S. 530. + from 2019-07-01 = 0.45 +} + +/** + * Höhen des Existenzminimums, festgelegt im Existenzminimumsbericht der + * Bundesregierung. + * Berechnet für jeweils zwei Jahre die Höhe der steuerfrei zu stellenden + * Existenzminima (nicht identisch mit dem steuerlichen Grundfreibetrag). + */ +const existenzminimum: Dict{ + // Reference: 5. Existenzminimumsbericht, Bundestag Drucksache 15/2462, Übersicht 3 + from 2005-01-01 = { + regelsatz: { + single: 4164 + paare: 7488 + kinder: 2688 + } + kosten_der_unterkunft: { + single: 2592 + paare: 3984 + kinder: 804 + } + heizkosten: { + single: 600 + paare: 768 + kinder: 156 + } + } + + // Reference: 6. Existenzminimumsbericht, Bundestag Drucksache 16/3265, Übersicht 3 + from 2008-01-01 = { + regelsatz: { + single: 4140 + paare: 7464 + kinder: 2676 + } + kosten_der_unterkunft: { + single: 2364 + paare: 4020 + kinder: 804 + } + heizkosten: { + single: 636 + paare: 792 + kinder: 168 + } + } + + // Reference: 7. Existenzminimumsbericht, Bundestag Drucksache 16/11065, Übersicht 3 + from 2010-01-01 = { + regelsatz: { + single: 4368 + paare: 7860 + kinder: 2820 + } + kosten_der_unterkunft: { + single: 2520 + paare: 4164 + kinder: 840 + } + heizkosten: { + single: 768 + paare: 972 + kinder: 204 + } + } + + // Reference: 8. Existenzminimumsbericht, Bundestag Drucksache 17/5550, Übersicht 4 + from 2012-01-01 = { + regelsatz: { + single: 4488 + paare: 8064 + kinder: 2988 + } + bildung_und_teilhabe: { + kinder: 228 + } + kosten_der_unterkunft: { + single: 2724 + paare: 4344 + kinder: 876 + } + heizkosten: { + single: 684 + paare: 864 + kinder: 180 + } + } + + // Reference: 9. Existenzminimumsbericht, Bundestag Drucksache 17/5550, Übersicht 5. Werte nur + // für Singles anders + from 2013-01-01 = { + regelsatz: { + single: 4584 + paare: 8064 + kinder: 2988 + } + bildung_und_teilhabe: { + kinder: 228 + } + kosten_der_unterkunft: { + single: 2796 + paare: 4344 + kinder: 876 + } + heizkosten: { + single: 744 + paare: 864 + kinder: 180 + } + } + + // Reference: 9. Existenzminimumsbericht, Bundestag Drucksache 17/5550, Übersicht 5. + from 2014-01-01 = { + regelsatz: { + single: 4680 + paare: 8448 + kinder: 3096 + } + bildung_und_teilhabe: { + kinder: 228 + } + kosten_der_unterkunft: { + single: 2868 + paare: 4560 + kinder: 912 + } + heizkosten: { + single: 804 + paare: 1008 + kinder: 204 + } + } + + // Reference: 10. Existenzminimumsbericht, Bundestag Drucksache 17/5550, + // Übersicht 4. Werte für Paare unverändert. + from 2015-01-01 = { + regelsatz: { + single: 4788 + paare: 8448 + kinder: 3168 + } + bildung_und_teilhabe: { + kinder: 228 + } + kosten_der_unterkunft: { + single: 2988 + paare: 4560 + kinder: 936 + } + heizkosten: { + single: 696 + paare: 1008 + kinder: 180 + } + } + + // Reference: 10. Existenzminimumsbericht, Bundestag Drucksache 17/5550, Übersicht 4. + from 2016-01-01 = { + regelsatz: { + single: 4872 + paare: 8784 + kinder: 3228 + } + bildung_und_teilhabe: { + kinder: 228 + } + kosten_der_unterkunft: { + single: 3060 + paare: 4788 + kinder: 960 + } + heizkosten: { + single: 720 + paare: 900 + kinder: 192 + } + } + + // Reference: 11. Existenzminimumsbericht, Bundestag Drucksache 18/10220, Übersicht 4. + from 2017-01-01 = { + regelsatz: { + single: 4908 + paare: 8784 + kinder: 3336 + } + bildung_und_teilhabe: { + kinder: 228 + } + kosten_der_unterkunft: { + single: 3312 + paare: 4788 + kinder: 996 + } + heizkosten: { + single: 600 + paare: 900 + kinder: 156 + } + } + + // Reference: 11. Existenzminimumsbericht, Bundestag Drucksache 18/10220, Übersicht 4. + from 2018-01-01 = { + regelsatz: { + single: 4968 + paare: 8952 + kinder: 3372 + } + bildung_und_teilhabe: { + kinder: 228 + } + kosten_der_unterkunft: { + single: 3396 + paare: 5088 + kinder: 1020 + } + heizkosten: { + single: 636 + paare: 816 + kinder: 168 + } + } + + // Reference: 12. Existenzminimumsbericht, Bundestag Drucksache 19/5400, Übersicht 4. + from 2019-01-01 = { + regelsatz: { + single: 5088 + paare: 8952 + kinder: 3456 + } + bildung_und_teilhabe: { + kinder: 228 + } + kosten_der_unterkunft: { + single: 3468 + paare: 5088 + kinder: 1044 + } + heizkosten: { + single: 612 + paare: 816 + kinder: 168 + } + } + + // Reference: 12. Existenzminimumsbericht, Bundestag Drucksache 19/5400, Übersicht 4. + from 2020-01-01 = { + regelsatz: { + single: 5196 + paare: 9360 + kinder: 3528 + } + bildung_und_teilhabe: { + kinder: 228 + } + kosten_der_unterkunft: { + single: 3552 + paare: 5328 + kinder: 1068 + } + heizkosten: { + single: 660 + paare: 852 + kinder: 180 + } + } + + // Reference: 13. Existenzminimumsbericht, Bundestag Drucksache 19/22800, Übersicht 4. + from 2021-01-01 = { + regelsatz: { + single: 5352 + paare: 9360 + kinder: 3780 + } + bildung_und_teilhabe: { + kinder: 324 + } + kosten_der_unterkunft: { + single: 3612 + paare: 5328 + kinder: 1092 + } + heizkosten: { + single: 780 + paare: 852 + kinder: 216 + } + } + + // Reference: 13. Existenzminimumsbericht, Bundestag Drucksache 19/22800, Übersicht 4. + from 2022-01-01 = { + regelsatz: { + single: 5400 + paare: 9720 + kinder: 3816 + } + bildung_und_teilhabe: { + kinder: 324 + } + kosten_der_unterkunft: { + single: 3684 + paare: 5520 + kinder: 1104 + } + heizkosten: { + single: 804 + paare: 1080 + kinder: 216 + } + } + + // Reference: 14. Existenzminimumsbericht, Bundestag Drucksache 20/4443, Übersicht 4. + from 2023-01-01 = { + deviation_from: previous + regelsatz: { + single: 6024 + kinder: 4248 + } + bildung_und_teilhabe: { + kinder: 336 + } + kosten_der_unterkunft: { + single: 3828 + kinder: 1152 + } + heizkosten: { + single: 1056 + kinder: 288 + } + } + + // Reference: 14. Existenzminimumsbericht, Bundestag Drucksache 20/4443, Übersicht 4. + from 2024-01-01 = { + regelsatz: { + single: 6444 + paare: 11592 + kinder: 4548 + } + bildung_und_teilhabe: { + kinder: 336 + } + kosten_der_unterkunft: { + single: 3684 + paare: 5892 + kinder: 1188 + } + heizkosten: { + single: 1104 + paare: 1500 + kinder: 312 + } + } +} diff --git a/src/resources/builtins/kinderzuschlagEinkommen.ttsl b/src/resources/builtins/kinderzuschlagEinkommen.ttsl new file mode 100644 index 00000000..0b2ebe81 --- /dev/null +++ b/src/resources/builtins/kinderzuschlagEinkommen.ttsl @@ -0,0 +1,18 @@ +package kidnerzuschlagEinkommen + +// TODO: rounding + +--- +rounding: + kinderzuschl_eink_eltern_m: + 2005-01-01: + base: 10 + direction: down + reference: § 6a Abs. 4 BKGG + note: + en: Rounding changed via BGBl. I S. 530 StaFamG Artikel 1 + 2019-07-01: + base: 1 + direction: nearest + reference: § 11 Abs. 2 BKGG + From bafb1b0fa183c5a0f1ea5f7521794914514b8530 Mon Sep 17 00:00:00 2001 From: alex-senger Date: Mon, 20 May 2024 17:43:56 +0200 Subject: [PATCH 030/183] remove yaml from kinderzuschlag.ttsl --- src/resources/builtins/kinderzuschlag.ttsl | 388 --------------------- 1 file changed, 388 deletions(-) diff --git a/src/resources/builtins/kinderzuschlag.ttsl b/src/resources/builtins/kinderzuschlag.ttsl index 72f22fd7..51c07949 100644 --- a/src/resources/builtins/kinderzuschlag.ttsl +++ b/src/resources/builtins/kinderzuschlag.ttsl @@ -1,393 +1,5 @@ package kidnerzuschlag ---- -maximum: - name: - de: Maximale Höhe des Kinderzuschlags - en: Maximum additional child benefit - description: - de: § 6a (2) BKGG. Betrag pro Kind - en: Amount per child. - unit: Euro - reference_period: Month - 2005-01-01: - scalar: 140 - reference: Art. 46 G. v. 24.12.2003 BGBl. I S. 2954. - 2017-01-01: - scalar: 170 - reference: Art. 12 G. v. 20.12.2016 BGBl. I S. 3000. - 2019-07-01: - scalar: 185 - reference: Art. 1 G. v. 29.04.2019 BGBl. I S. 530. - note: For 2020, Art. 2 Nr. 4 G. v. 29.04.2019 BGBl. I S. 530. - 2021-01-01: - scalar: null - reference: § 6a (2) BKGG - note: Ab 2021 wird der Betrag aus anderen Parametern berechnet. - 2023-01-01: - scalar: 250 - reference: Art. 6 G. v. 08.12.2022 BGBl. I S. 2230. - note: Regelung für das Kalenderjahr 2023, abweichend von § 6a Absatz 2. - 2024-01-01: - scalar: null - reference: § 6a (2) BKGG - note: Ab 2024 wird der Betrag wieder aus anderen Parametern berechnet. -kindersofortzuschl: - name: - de: Kindersofortzuschlag für Kinderzuschlag - en: Instant surcharge for children for additional child benefit - description: - de: >- - Mit Einführung des Sofortzuschlags zum 1. Juli 2022 - steigt der Höchstbetrag im Kinderzuschlag um 20 Euro. - en: >- - With the introduction of the immediate supplement from July 1, 2022, - the maximum amount in the child supplement increases by 20 euros. - unit: Euros - reference: § 6a Abs. 2 Satz 4 BKGG - 2022-07-01: - scalar: 20 - 2023-01-01: - scalar: null - 2024-01-01: - scalar: 20 -min_eink_paare: - name: - de: Mindesteinkommen für Paare - en: Minimum income to be eligible for add. child benefit (couples) - description: - de: § 6a (1) Nr. 2 BKGG. - en: null - unit: Euro - reference_period: Month - 2005-01-01: - scalar: 0 - note: kein expliziter Wert im Gesetz. - 2008-10-01: - scalar: 900 - reference: Art. 1 G. v. 24.09.2008 BGBl. I S. 1854. -min_eink_alleinerz: - name: - de: Mindesteinkommen für Alleinerziehende - en: Minimum income for single parents - description: - de: § 6a (1) Nr. 2 BKGG. - en: null - unit: Euro - reference_period: Month - 2005-01-01: - scalar: 0 - note: kein expliziter Wert im Gesetz. - 2008-10-01: - scalar: 600 - reference: Art. 1 G. v. 24.09.2008 BGBl. I S. 1854. -entzugsrate_eltern: - name: - de: Minderungsrate durch Einkommen der Eltern über BMG - en: Transfer withdrawal rate for parent's income - description: - de: >- - § 6a (6) BKGG, bis 01.07.2019 § 6a (4) BKGG. Rate, mit der der - Gesamtkinderzuschlag nach Erreichen der Bemessungsgrenze durch Einkommen der - Eltern gemindert wird. Bis 07/2019 wurde das Einkommen nur in 10€-Schritten - berücksichtigt. - en: null - unit: Share - 2005-01-01: - scalar: 0.7 - reference: Art. 46 G. v. 24.12.2003 BGBl. I. S. 2954. - 2008-10-01: - scalar: 0.5 - reference: Art. 1 G. v. 24.09.2008 BGBl. I S. 1854. - 2020-01-01: - scalar: 0.45 - reference: Art. 1 G. v. 29.04.2019 BGBl. I S. 530. -entzugsrate_kind: - name: - de: Minderungsrate durch Einkommen des Kindes - en: Rate at which child income is deducted - description: - de: >- - § 6a (3) BKGG. Einkommen des Kindes beinhaltet auch Unterhalt und - Unterhaltsvorschuss. - en: >- - Child alimony and alimony advance payments are also attributed to the child. - unit: Share - 2005-01-01: - scalar: 1 - reference: Art. 46 G. v. 24.12.2003 BGBl. I. S. 2954. - 2019-07-01: - scalar: 0.45 - reference: Art. 1 G. v. 29.04.2019 BGBl. I S. 530. -existenzminimum: - name: - de: >- - Höhen des Existenzminimums, festgelegt im Existenzminimumsbericht der - Bundesregierung. - en: null - description: - de: >- - Berechnet für jeweils zwei Jahre die Höhe der steuerfrei zu stellenden - Existenzminima (nicht identisch mit dem steuerlichen Grundfreibetrag). - en: >- - Every two years, the government calculates the subsistence levels 'to be allowed - from taxation'. These form the basis for a number of kiz parameters. - unit: Euro - reference_period: Year - 2005-01-01: - regelsatz: - single: 4164 - paare: 7488 - kinder: 2688 - kosten_der_unterkunft: - single: 2592 - paare: 3984 - kinder: 804 - heizkosten: - single: 600 - paare: 768 - kinder: 156 - reference: 5. Existenzminimumsbericht, Bundestag Drucksache 15/2462, Übersicht 3 - 2008-01-01: - regelsatz: - single: 4140 - paare: 7464 - kinder: 2676 - kosten_der_unterkunft: - single: 2364 - paare: 4020 - kinder: 804 - heizkosten: - single: 636 - paare: 792 - kinder: 168 - reference: 6. Existenzminimumsbericht, Bundestag Drucksache 16/3265, Übersicht 3 - 2010-01-01: - regelsatz: - single: 4368 - paare: 7860 - kinder: 2820 - kosten_der_unterkunft: - single: 2520 - paare: 4164 - kinder: 840 - heizkosten: - single: 768 - paare: 972 - kinder: 204 - reference: 7. Existenzminimumsbericht, Bundestag Drucksache 16/11065, Übersicht 3 - 2012-01-01: - regelsatz: - single: 4488 - paare: 8064 - kinder: 2988 - bildung_und_teilhabe: - kinder: 228 - kosten_der_unterkunft: - single: 2724 - paare: 4344 - kinder: 876 - heizkosten: - single: 684 - paare: 864 - kinder: 180 - reference: 8. Existenzminimumsbericht, Bundestag Drucksache 17/5550, Übersicht 4 - 2013-01-01: - regelsatz: - single: 4584 - paare: 8064 - kinder: 2988 - bildung_und_teilhabe: - kinder: 228 - kosten_der_unterkunft: - single: 2796 - paare: 4344 - kinder: 876 - heizkosten: - single: 744 - paare: 864 - kinder: 180 - reference: >- - 9. Existenzminimumsbericht, Bundestag Drucksache 17/5550, Übersicht 5. Werte nur - für Singles anders - 2014-01-01: - regelsatz: - single: 4680 - paare: 8448 - kinder: 3096 - bildung_und_teilhabe: - kinder: 228 - kosten_der_unterkunft: - single: 2868 - paare: 4560 - kinder: 912 - heizkosten: - single: 804 - paare: 1008 - kinder: 204 - reference: 9. Existenzminimumsbericht, Bundestag Drucksache 17/5550, Übersicht 5. - 2015-01-01: - regelsatz: - single: 4788 - paare: 8448 - kinder: 3168 - bildung_und_teilhabe: - kinder: 228 - kosten_der_unterkunft: - single: 2988 - paare: 4560 - kinder: 936 - heizkosten: - single: 696 - paare: 1008 - kinder: 180 - reference: >- - 10. Existenzminimumsbericht, Bundestag Drucksache 17/5550, - Übersicht 4. Werte für Paare unverändert. - 2016-01-01: - regelsatz: - single: 4872 - paare: 8784 - kinder: 3228 - bildung_und_teilhabe: - kinder: 228 - kosten_der_unterkunft: - single: 3060 - paare: 4788 - kinder: 960 - heizkosten: - single: 720 - paare: 900 - kinder: 192 - reference: 10. Existenzminimumsbericht, Bundestag Drucksache 17/5550, Übersicht 4. - 2017-01-01: - regelsatz: - single: 4908 - paare: 8784 - kinder: 3336 - bildung_und_teilhabe: - kinder: 228 - kosten_der_unterkunft: - single: 3312 - paare: 4788 - kinder: 996 - heizkosten: - single: 600 - paare: 900 - kinder: 156 - reference: 11. Existenzminimumsbericht, Bundestag Drucksache 18/10220, Übersicht 4. - note: Werte für Paare unverändert. - 2018-01-01: - regelsatz: - single: 4968 - paare: 8952 - kinder: 3372 - bildung_und_teilhabe: - kinder: 228 - kosten_der_unterkunft: - single: 3396 - paare: 5088 - kinder: 1020 - heizkosten: - single: 636 - paare: 816 - kinder: 168 - reference: 11. Existenzminimumsbericht, Bundestag Drucksache 18/10220, Übersicht 4. - 2019-01-01: - regelsatz: - single: 5088 - paare: 8952 - kinder: 3456 - bildung_und_teilhabe: - kinder: 228 - kosten_der_unterkunft: - single: 3468 - paare: 5088 - kinder: 1044 - heizkosten: - single: 612 - paare: 816 - kinder: 168 - reference: 12. Existenzminimumsbericht, Bundestag Drucksache 19/5400, Übersicht 4. - 2020-01-01: - regelsatz: - single: 5196 - paare: 9360 - kinder: 3528 - bildung_und_teilhabe: - kinder: 228 - kosten_der_unterkunft: - single: 3552 - paare: 5328 - kinder: 1068 - heizkosten: - single: 660 - paare: 852 - kinder: 180 - reference: 12. Existenzminimumsbericht, Bundestag Drucksache 19/5400, Übersicht 4. - 2021-01-01: - regelsatz: - single: 5352 - paare: 9360 - kinder: 3780 - bildung_und_teilhabe: - kinder: 324 - kosten_der_unterkunft: - single: 3612 - paare: 5328 - kinder: 1092 - heizkosten: - single: 780 - paare: 852 - kinder: 216 - reference: 13. Existenzminimumsbericht, Bundestag Drucksache 19/22800, Übersicht 4. - 2022-01-01: - regelsatz: - single: 5400 - paare: 9720 - kinder: 3816 - bildung_und_teilhabe: - kinder: 324 - kosten_der_unterkunft: - single: 3684 - paare: 5520 - kinder: 1104 - heizkosten: - single: 804 - paare: 1080 - kinder: 216 - reference: 13. Existenzminimumsbericht, Bundestag Drucksache 19/22800, Übersicht 4. - 2023-01-01: - deviation_from: previous - regelsatz: - single: 6024 - kinder: 4248 - bildung_und_teilhabe: - kinder: 336 - kosten_der_unterkunft: - single: 3828 - kinder: 1152 - heizkosten: - single: 1056 - kinder: 288 - reference: 14. Existenzminimumsbericht, Bundestag Drucksache 20/4443, Übersicht 4. - 2024-01-01: - regelsatz: - single: 6444 - paare: 11592 - kinder: 4548 - bildung_und_teilhabe: - kinder: 336 - kosten_der_unterkunft: - single: 3684 - paare: 5892 - kinder: 1188 - heizkosten: - single: 1104 - paare: 1500 - kinder: 312 - reference: 14. Existenzminimumsbericht, Bundestag Drucksache 20/4443, Übersicht 4. - /** * Maximale Höhe des Kinderzuschlags * Reference: § 6a (2) BKGG. Betrag pro Kind From 4dc29a5142ecc45eaf69f13d712390dc6598b6e6 Mon Sep 17 00:00:00 2001 From: alex-senger Date: Mon, 20 May 2024 17:47:19 +0200 Subject: [PATCH 031/183] feat: add lohnsteuer.ttsl --- src/resources/builtins/lohnsteuer.ttsl | 101 +++++++++++++++++++++++++ 1 file changed, 101 insertions(+) create mode 100644 src/resources/builtins/lohnsteuer.ttsl diff --git a/src/resources/builtins/lohnsteuer.ttsl b/src/resources/builtins/lohnsteuer.ttsl new file mode 100644 index 00000000..ebaf00ef --- /dev/null +++ b/src/resources/builtins/lohnsteuer.ttsl @@ -0,0 +1,101 @@ +package lohnsteuer + +/** + * Einkommensgrenzen für Steuerklasse 5 und 6 + * Einkommensgrenzen für Steuerklasse 5 und 6, innerhalb derer + * Mindest- und Maximalsteuern festgelegt sind. + * Referenz: § 39b Absatz 2 Satz 7 EStG + */ +const lohnsteuerEinkommensgrenzen: Dict { + from 2002-01-01 { + 0: 8946, + 1: 27306, + 2: 10000000, + } + + from 2004-01-01 { + 0: 9228, + 1: 26072, + 2: 10000000, + } + + from 2005-01-01 { + 0: 9144, + 1: 25812, + 2: 200000, + } + + from 2009-01-01 { + 0: 9225, + 1: 26276, + 2: 200320, + } + + from 2010-01-01 { + 0: 9429, + 1: 26441, + 2: 200584, + } + + from 2013-01-01 { + 0: 9550, + 1: 26441, + 2: 200584, + } + + from 2014-01-01 { + 0: 9763, + 1: 26441, + 2: 200584, + } + + from 2016-01-01 { + 0: 10070, + 1: 26832, + 2: 203557, + } + + from 2017-01-01 { + 0: 10240, + 1: 27029, + 2: 205043, + } + + from 2018-01-01 { + 0: 10440, + 1: 27475, + 2: 208426, + } + + from 2019-01-01 { + 0: 10635, + 1: 27980, + 2: 212261, + } + + from 2020-01-01 { + 0: 10898, + 1: 28526, + 2: 216400, + } + + from 2021-01-01 { + 0: 11237, + 1: 28959, + 2: 219690, + } + + from 2022-01-01 { + 0: 11793, + 1: 29298, + 2: 222260, + } + + from 2023-01-01 { + 0: 12485, + 1: 31404, + 2: 222260, + } +} + +// TODO: rounding From 39f15e70cd19b9054fb3b55496a82cc517b5c4fa Mon Sep 17 00:00:00 2001 From: alex-senger Date: Mon, 20 May 2024 18:09:54 +0200 Subject: [PATCH 032/183] feat: add solizuschlag --- .../builtins/solidaritaetszuschlag.ttsl | 222 ++++++++++++++++++ 1 file changed, 222 insertions(+) create mode 100644 src/resources/builtins/solidaritaetszuschlag.ttsl diff --git a/src/resources/builtins/solidaritaetszuschlag.ttsl b/src/resources/builtins/solidaritaetszuschlag.ttsl new file mode 100644 index 00000000..64fb4674 --- /dev/null +++ b/src/resources/builtins/solidaritaetszuschlag.ttsl @@ -0,0 +1,222 @@ +--- +soli_st: + name: + de: Solidaritätszuschlag + en: null + description: + de: >- + Ab 1995, der upper threshold im Intervall 1 ist nach der Formel + transition_threshold in soli_st.py berechnet. + en: null + type: piecewise_linear + 1991-01-01: + reference: Artikel 1 G. v. 24.06.1991 BGBl. I S. 1318. + 0: + lower_threshold: -inf + rate: 0 + intercept_at_lower_threshold: 0 + upper_threshold: 0 + 1: + lower_threshold: 0 + rate: 0.0375 + upper_threshold: inf + 1993-01-01: + 0: + lower_threshold: -inf + rate: 0 + intercept_at_lower_threshold: 0 + upper_threshold: inf + 1995-01-01: + reference: Artikel 31 G. v. 23.06.1993 BGBl. I S. 944. + 0: + lower_threshold: -inf + intercept_at_lower_threshold: 0 + rate: 0 + upper_threshold: 681 + 1: + upper_threshold: 1089.6 + rate: 0.2 + 2: + rate: 0.075 + upper_threshold: inf + 1998-01-01: + reference: Artikel 1 G. v. 21.11.1997 BGBl. I S. 2743. + 0: + lower_threshold: -inf + upper_threshold: 939 + rate: 0 + intercept_at_lower_threshold: 0 + 1: + upper_threshold: 1295.17 + rate: 0.2 + 2: + rate: 0.055 + upper_threshold: inf + 2002-01-01: + reference: G. v. 15.10.2002 BGBl. I S. 4131. + 0: + lower_threshold: -inf + upper_threshold: 972 + rate: 0 + intercept_at_lower_threshold: 0 + 1: + upper_threshold: 1340.69 + rate: 0.2 + 2: + rate: 0.055 + upper_threshold: inf + 2021-01-01: + reference: Artikel 1 G. v. 10.12.2019 BGBl. I S. 2115. + 0: + lower_threshold: -inf + upper_threshold: 16956 + rate: 0 + intercept_at_lower_threshold: 0 + 1: + upper_threshold: 31527.56 + rate: 0.119 + 2: + rate: 0.055 + upper_threshold: inf + 2023-01-01: + reference: Art. 4 G. v. 08.12.2022 BGBl. I S. 2230. + deviation_from: previous + 0: + upper_threshold: 17543 + 1: + upper_threshold: 32619.02 + 2024-01-01: + reference: Art. 5 G. v. 08.12.2022 BGBl. I S. 2230. + deviation_from: previous + 0: + upper_threshold: 18130 + 1: + upper_threshold: 33710.47 + + +package solidaritaetszuschlag + +/** + * Solidaritätszuschlag + * Ab 1995, der upper threshold im Intervall 1 ist nach der Formel + * transition_threshold in soli_st.py berechnet. + */ +const solidaritaetszuschlag: Dict> { + // Reference: Artikel 1 G. v. 24.06.1991 BGBl. I S. 1318. + from 1991-01-01 { + 0: { + lower_threshold: -inf + rate: 0 + intercept_at_lower_threshold: 0 + upper_threshold: 0 + }, + 1: { + lower_threshold: 0 + rate: 0.0375 + upper_threshold: inf + } + } + + from 1993-01-01 { + 0: { + lower_threshold: -inf + rate: 0 + intercept_at_lower_threshold: 0 + upper_threshold: inf + } + } // TODO: BEISPIEL FÜR DEVIATION!!!! + + // Reference: Artikel 31 G. v. 23.06.1993 BGBl. I S. 944. + from 1995-01-01 { + 0: { + lower_threshold: -inf + intercept_at_lower_threshold: 0 + rate: 0 + upper_threshold: 681 + }, + 1: { + upper_threshold: 1089.6 + rate: 0.2 + }, + 2: { + rate: 0.075 + upper_threshold: inf + } + } + + // Reference: Artikel 1 G. v. 21.11.1997 BGBl. I S. 2743. + from 1998-01-01 { + 0: { + lower_threshold: -inf + upper_threshold: 939 + rate: 0 + intercept_at_lower_threshold: 0 + }, + 1: { + upper_threshold: 1295.17 + rate: 0.2 + }, + 2: { + rate: 0.055 + upper_threshold: inf + } + } + + // Reference: G. v. 15.10.2002 BGBl. I S. 4131. + from 2002-01-01 { + 0: { + lower_threshold: -inf + upper_threshold: 972 + rate: 0 + intercept_at_lower_threshold: 0 + }, + 1: { + upper_threshold: 1340.69 + rate: 0.2 + }, + 2: { + rate: 0.055 + upper_threshold: inf + } + } + + // Reference: Artikel 1 G. v. 10.12.2019 BGBl. I S. 2115. + from 2021-01-01 { + 0: { + lower_threshold: -inf + upper_threshold: 16956 + rate: 0 + intercept_at_lower_threshold: 0 + }, + 1: { + upper_threshold: 31527.56 + rate: 0.119 + }, + 2: { + rate: 0.055 + upper_threshold: inf + } + } + + // Reference: Art. 4 G. v. 08.12.2022 BGBl. I S. 2230. + from 2023-01-01 { + // deviation_from: previous + 0: { + upper_threshold: 17543 + }, + 1: { + upper_threshold: 32619.02 + } + } + + // Reference: Art. 5 G. v. 08.12.2022 BGBl. I S. 2230. + from 2024-01-01 { + // deviation_from: previous + 0: { + upper_threshold: 18130 + }, + 1: { + upper_threshold: 33710.47 + } + } +} From 938e6bb72f0c74198a02328744b28659c1614e78 Mon Sep 17 00:00:00 2001 From: methr0 Date: Tue, 21 May 2024 13:48:14 +0200 Subject: [PATCH 033/183] generation tests for constants, data, empty function, aggregation and conditional statement --- .../tests/generator/const/gen_input.py | 20 ++++++++++++++++++ .../tests/generator/const/gen_input.py.map | 1 + .../tests/generator/const/gen_input_test.py | 4 ++++ .../declarations/constant/input.Tsltest | 3 +++ .../tests/generator/datas/gen_input.py | 3 +++ .../tests/generator/datas/gen_input.py.map | 1 + .../tests/generator/datas/gen_input_test.py | 4 ++++ .../declarations/data/input.Tsltest | 3 +++ .../generator/emptyFunction/gen_input.py | 4 ++++ .../generator/emptyFunction/gen_input.py.map | 1 + .../generator/emptyFunction/gen_input_test.py | 4 ++++ .../declarations/empty function/input.Tsltest | 3 +++ .../tests/generator/aggregation/gen_input.py | 21 +++++++++++++++++++ .../generator/aggregation/gen_input.py.map | 1 + .../generator/aggregation/gen_input_test.py | 4 ++++ .../expressions/aggregation/input.Tsltest | 9 ++++++++ .../conditionalStatement/gen_input.py | 7 +++++++ .../conditionalStatement/gen_input.py.map | 1 + .../gen_input_testPipeline.py | 4 ++++ .../conditional statement/input.Tsltest | 9 ++++++++ 20 files changed, 107 insertions(+) create mode 100644 packages/ttsl-lang/tests/resources/generation/declarations/constant/generated/tests/generator/const/gen_input.py create mode 100644 packages/ttsl-lang/tests/resources/generation/declarations/constant/generated/tests/generator/const/gen_input.py.map create mode 100644 packages/ttsl-lang/tests/resources/generation/declarations/constant/generated/tests/generator/const/gen_input_test.py create mode 100644 packages/ttsl-lang/tests/resources/generation/declarations/constant/input.Tsltest create mode 100644 packages/ttsl-lang/tests/resources/generation/declarations/data/generated/tests/generator/datas/gen_input.py create mode 100644 packages/ttsl-lang/tests/resources/generation/declarations/data/generated/tests/generator/datas/gen_input.py.map create mode 100644 packages/ttsl-lang/tests/resources/generation/declarations/data/generated/tests/generator/datas/gen_input_test.py create mode 100644 packages/ttsl-lang/tests/resources/generation/declarations/data/input.Tsltest create mode 100644 packages/ttsl-lang/tests/resources/generation/declarations/empty function/generated/tests/generator/emptyFunction/gen_input.py create mode 100644 packages/ttsl-lang/tests/resources/generation/declarations/empty function/generated/tests/generator/emptyFunction/gen_input.py.map create mode 100644 packages/ttsl-lang/tests/resources/generation/declarations/empty function/generated/tests/generator/emptyFunction/gen_input_test.py create mode 100644 packages/ttsl-lang/tests/resources/generation/declarations/empty function/input.Tsltest create mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/aggregation/generated/tests/generator/aggregation/gen_input.py create mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/aggregation/generated/tests/generator/aggregation/gen_input.py.map create mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/aggregation/generated/tests/generator/aggregation/gen_input_test.py create mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/aggregation/input.Tsltest create mode 100644 packages/ttsl-lang/tests/resources/generation/statements/conditional statement/generated/tests/generator/conditionalStatement/gen_input.py create mode 100644 packages/ttsl-lang/tests/resources/generation/statements/conditional statement/generated/tests/generator/conditionalStatement/gen_input.py.map create mode 100644 packages/ttsl-lang/tests/resources/generation/statements/conditional statement/generated/tests/generator/conditionalStatement/gen_input_testPipeline.py create mode 100644 packages/ttsl-lang/tests/resources/generation/statements/conditional statement/input.Tsltest diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/constant/generated/tests/generator/const/gen_input.py b/packages/ttsl-lang/tests/resources/generation/declarations/constant/generated/tests/generator/const/gen_input.py new file mode 100644 index 00000000..15777c50 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/declarations/constant/generated/tests/generator/const/gen_input.py @@ -0,0 +1,20 @@ +# Constants -------------------------------------------------------------------- + + +class __gen_ClassConstants(): + def __init__(self, dictionary: dict): + self.dict = dictionary + def getValue(self, date): + keys = sorted(self.dict.keys()) + if(keys[0] == 'empty'): + return self.dict['empty'] + for index, key in enumerate(keys): + if key[0] == 's': + if key.replace('s', '') <= date: + result = self.dict[key] + if key[0] == 'e': + if date <= keys[len(keys)-1 - index].replace('e', ''): + result = self.dict[keys[len(keys)-1 - index]] + return result + +test = __gen_ClassConstants() diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/constant/generated/tests/generator/const/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/declarations/constant/generated/tests/generator/const/gen_input.py.map new file mode 100644 index 00000000..ff83d01e --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/declarations/constant/generated/tests/generator/const/gen_input.py.map @@ -0,0 +1 @@ +{"version":3,"sources":["input.Tsltest"],"names":["test"],"mappings":"AAAA;;AAEA,IAASA,IAAI;IAAC,IAAE","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/constant/generated/tests/generator/const/gen_input_test.py b/packages/ttsl-lang/tests/resources/generation/declarations/constant/generated/tests/generator/const/gen_input_test.py new file mode 100644 index 00000000..77949bf1 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/declarations/constant/generated/tests/generator/const/gen_input_test.py @@ -0,0 +1,4 @@ +from .gen_input import test + +if __name__ == '__main__': + print(test) diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/constant/input.Tsltest b/packages/ttsl-lang/tests/resources/generation/declarations/constant/input.Tsltest new file mode 100644 index 00000000..3475818d --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/declarations/constant/input.Tsltest @@ -0,0 +1,3 @@ +package tests.generator.const // kann nicht constant heißen weil sonst als keyword gelesen wird + +constant test: Int = 1 diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/data/generated/tests/generator/datas/gen_input.py b/packages/ttsl-lang/tests/resources/generation/declarations/data/generated/tests/generator/datas/gen_input.py new file mode 100644 index 00000000..6a9e60f7 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/declarations/data/generated/tests/generator/datas/gen_input.py @@ -0,0 +1,3 @@ +# Data -------------------------------------------------------------------- + +test = int() \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/data/generated/tests/generator/datas/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/declarations/data/generated/tests/generator/datas/gen_input.py.map new file mode 100644 index 00000000..ff83d01e --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/declarations/data/generated/tests/generator/datas/gen_input.py.map @@ -0,0 +1 @@ +{"version":3,"sources":["input.Tsltest"],"names":["test"],"mappings":"AAAA;;AAEA,IAASA,IAAI;IAAC,IAAE","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/data/generated/tests/generator/datas/gen_input_test.py b/packages/ttsl-lang/tests/resources/generation/declarations/data/generated/tests/generator/datas/gen_input_test.py new file mode 100644 index 00000000..77949bf1 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/declarations/data/generated/tests/generator/datas/gen_input_test.py @@ -0,0 +1,4 @@ +from .gen_input import test + +if __name__ == '__main__': + print(test) diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/data/input.Tsltest b/packages/ttsl-lang/tests/resources/generation/declarations/data/input.Tsltest new file mode 100644 index 00000000..7af84e34 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/declarations/data/input.Tsltest @@ -0,0 +1,3 @@ +package tests.generator.datas + +data test: Int diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/empty function/generated/tests/generator/emptyFunction/gen_input.py b/packages/ttsl-lang/tests/resources/generation/declarations/empty function/generated/tests/generator/emptyFunction/gen_input.py new file mode 100644 index 00000000..4c320279 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/declarations/empty function/generated/tests/generator/emptyFunction/gen_input.py @@ -0,0 +1,4 @@ +# Functions -------------------------------------------------------------------- + +def test(timeunit, groupedBy, date): + pass \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/empty function/generated/tests/generator/emptyFunction/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/declarations/empty function/generated/tests/generator/emptyFunction/gen_input.py.map new file mode 100644 index 00000000..e4736f07 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/declarations/empty function/generated/tests/generator/emptyFunction/gen_input.py.map @@ -0,0 +1 @@ +{"version":3,"sources":["input.Tsltest"],"names":["test"],"mappings":"AAAA;;AAEA,IAASA,IAAI;IAAG,IAAE","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/empty function/generated/tests/generator/emptyFunction/gen_input_test.py b/packages/ttsl-lang/tests/resources/generation/declarations/empty function/generated/tests/generator/emptyFunction/gen_input_test.py new file mode 100644 index 00000000..af29cac4 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/declarations/empty function/generated/tests/generator/emptyFunction/gen_input_test.py @@ -0,0 +1,4 @@ +from .gen_input import test + +if __name__ == '__main__': + test(None, None, None) diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/empty function/input.Tsltest b/packages/ttsl-lang/tests/resources/generation/declarations/empty function/input.Tsltest new file mode 100644 index 00000000..5be3406c --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/declarations/empty function/input.Tsltest @@ -0,0 +1,3 @@ +package tests.generator.emptyFunction + +function test() {} diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/generated/tests/generator/aggregation/gen_input.py b/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/generated/tests/generator/aggregation/gen_input.py new file mode 100644 index 00000000..893101cf --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/generated/tests/generator/aggregation/gen_input.py @@ -0,0 +1,21 @@ +# Imports -------------------------------------------------------------------- + +from gettsim import (compute_taxes_and_transfers, create_synthetic_data, set_up_policy_environment) +import pandas as pd + +# Utils -------------------------------------------------------------------- + +def aggregation(dataFrame: pd, data: str, id: str, function: str) -> pd | None: + dataFrame = dataFrame.join(dataFrame[id]) + dataFrame[data] = dataFrame.groupby(id)[data].transform(function) + return dataFrame + +# Functions -------------------------------------------------------------------- + +def testFunction(timeunit, groupedBy, date): + aggregation(dataframe, testData, testID, 'sum') + +# Data -------------------------------------------------------------------- + +testData = int() +testID = int() \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/generated/tests/generator/aggregation/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/generated/tests/generator/aggregation/gen_input.py.map new file mode 100644 index 00000000..e4736f07 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/generated/tests/generator/aggregation/gen_input.py.map @@ -0,0 +1 @@ +{"version":3,"sources":["input.Tsltest"],"names":["test"],"mappings":"AAAA;;AAEA,IAASA,IAAI;IAAG,IAAE","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/generated/tests/generator/aggregation/gen_input_test.py b/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/generated/tests/generator/aggregation/gen_input_test.py new file mode 100644 index 00000000..af29cac4 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/generated/tests/generator/aggregation/gen_input_test.py @@ -0,0 +1,4 @@ +from .gen_input import test + +if __name__ == '__main__': + test(None, None, None) diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/input.Tsltest b/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/input.Tsltest new file mode 100644 index 00000000..842a0e37 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/input.Tsltest @@ -0,0 +1,9 @@ +package tests.generator.aggregation + +data testData: Int +id data testID: Int + +function testFunction() { + aggregate 'sum' of testData groupedBy testID; +} + diff --git a/packages/ttsl-lang/tests/resources/generation/statements/conditional statement/generated/tests/generator/conditionalStatement/gen_input.py b/packages/ttsl-lang/tests/resources/generation/statements/conditional statement/generated/tests/generator/conditionalStatement/gen_input.py new file mode 100644 index 00000000..dbcb8df5 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/statements/conditional statement/generated/tests/generator/conditionalStatement/gen_input.py @@ -0,0 +1,7 @@ +# Pipelines --------------------------------------------------------------------- + +def test(): + if 1 == 0: + pass + else: + pass diff --git a/packages/ttsl-lang/tests/resources/generation/statements/conditional statement/generated/tests/generator/conditionalStatement/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/statements/conditional statement/generated/tests/generator/conditionalStatement/gen_input.py.map new file mode 100644 index 00000000..5dd95cf8 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/statements/conditional statement/generated/tests/generator/conditionalStatement/gen_input.py.map @@ -0,0 +1 @@ +{"version":3,"sources":["input.Tsltest"],"names":["test"],"mappings":"AAAA;;AAEA,IAASA,IAAI;IACT,GAAG","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/statements/conditional statement/generated/tests/generator/conditionalStatement/gen_input_testPipeline.py b/packages/ttsl-lang/tests/resources/generation/statements/conditional statement/generated/tests/generator/conditionalStatement/gen_input_testPipeline.py new file mode 100644 index 00000000..af29cac4 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/statements/conditional statement/generated/tests/generator/conditionalStatement/gen_input_testPipeline.py @@ -0,0 +1,4 @@ +from .gen_input import test + +if __name__ == '__main__': + test(None, None, None) diff --git a/packages/ttsl-lang/tests/resources/generation/statements/conditional statement/input.Tsltest b/packages/ttsl-lang/tests/resources/generation/statements/conditional statement/input.Tsltest new file mode 100644 index 00000000..d08d4639 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/statements/conditional statement/input.Tsltest @@ -0,0 +1,9 @@ +package tests.generator.conditionalStatement + +pipeline test { + if(1 == 0){ + 1; + }else{ + 2; + } +} \ No newline at end of file From b6bc6f6074ca2d625927de6f5d27af330b97d948 Mon Sep 17 00:00:00 2001 From: methr0 Date: Tue, 21 May 2024 13:59:48 +0200 Subject: [PATCH 034/183] data extends tsldeclaration, DATE has the time as optional addition, aggregations get the function as a string --- packages/ttsl-lang/src/language/grammar/safe-ds.langium | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/packages/ttsl-lang/src/language/grammar/safe-ds.langium b/packages/ttsl-lang/src/language/grammar/safe-ds.langium index 73e7672a..592938dd 100644 --- a/packages/ttsl-lang/src/language/grammar/safe-ds.langium +++ b/packages/ttsl-lang/src/language/grammar/safe-ds.langium @@ -354,7 +354,7 @@ fragment TslConstantFragment: '=' value=TslExpression) ';'? ; -interface TslData extends TslModuleMember { +interface TslData extends TslModuleMember, TslDeclaration { isID: boolean ^type: TslType timeunit?: TslTimeunit @@ -642,13 +642,13 @@ TslExpression returns TslExpression: ; interface TslAggregation extends TslExpression{ - function: TslExpression + function: TslString data: TslExpression groupedBy: TslGroupedBy } TslAggregation returns TslAggregation: - 'aggregate' function=TslExpression 'of' data=TslExpression groupedBy=TslGroupedBy + 'aggregate' function=TslString 'of' data=TslExpression groupedBy=TslGroupedBy ; interface TslLambda extends TslCallable, TslExpression {} @@ -1267,7 +1267,7 @@ terminal FLOAT returns number : DECIMAL_DIGIT+ '.' DECIMAL_DIGIT+ FLOAT_EXPONENT? | DECIMAL_DIGIT+ FLOAT_EXPONENT; terminal fragment DECIMAL_DIGIT: /[0-9]/; -terminal DATE returns Date: /[0-9]{4}-[0-9]{2}-[0-9]{2}T[0-9]{2}:[0-9]{2}/; +terminal DATE returns Date: /[0-9]{4}-[0-9]{2}-[0-9]{2}(T[0-9]{2}:[0-9]{2})?/; terminal fragment FLOAT_EXPONENT: ('e' | 'E' )('+' | '-' )? DECIMAL_DIGIT+; terminal INT returns bigint: DECIMAL_DIGIT+; terminal STRING returns string: STRING_START STRING_TEXT* STRING_END; From da34a83fd1094b66eddd4c7b9dd989ae72efd164 Mon Sep 17 00:00:00 2001 From: alex-senger Date: Tue, 21 May 2024 14:19:50 +0200 Subject: [PATCH 035/183] feat: add sozialversicherungsbeitrag.ttsl --- .../builtins/sozialversicherungsbeitrag.ttsl | 1466 +++++++++++++++++ 1 file changed, 1466 insertions(+) create mode 100644 src/resources/builtins/sozialversicherungsbeitrag.ttsl diff --git a/src/resources/builtins/sozialversicherungsbeitrag.ttsl b/src/resources/builtins/sozialversicherungsbeitrag.ttsl new file mode 100644 index 00000000..89313197 --- /dev/null +++ b/src/resources/builtins/sozialversicherungsbeitrag.ttsl @@ -0,0 +1,1466 @@ +package sozialversicherungsbeitrag + +/** + * Beitragssätze zu den gesetzlichen Sozialversicherungen + * + * gesetzliche Krankenversicherung: + * Beitragssätze für gesetzliche Krankenversicherung. mean_allgemein - + * durchschnittlicher Beitragssatz, bis 2008 allgemein - allgemeiner Satz (§241 SGB + * V), ab 2009 sonderbeitrag - bezahlt von Arbeitnehmern, ab Jul 2005 bis 2014 + * ermäßigt - ermäßigter Satz (§243 SGB V) zusatz - durchschnittlicher + * Zusatzbeitragssatz. + * + * gesetzliche Pflegeversicherung: + * Beitragssätze für gesetzliche Pflegeversicherung (seit 1995). standard - + * Beitragssatz für Arbeitnehmer zusatz_kinderlos - Beitragszuschlag für kinderlose + * Versicherte, die das 23. Lebensjahr vollendet haben. Wird vom Arbeitnehmer + * alleine getragen. Eingeführt 2005. + * + * arbeitslosenversicherung: + * Beitragssätze zur Arbeitslosenversicherung für Arbeitnehmer. + * + * gesetzliche Rentenversicherung: + * Beitragssätze zur allgemeinen Rentenversicherung für Arbeitnehmer. + * + * access_different_date: jahresanfang + */ +const beitragssatz: Dict> { + from 1984-01-01 { + gesetzlicheKrankenversicherung: { + mean_allgemein: 0.134 + } + gesetzlichePflegeversicherung: 0.0085 + arbeitslosenversicherung: 0.0325 + gesetzlicheRentenversicherung: 0.0975 + } + + from 1985-01-01 { + gesetzlicheKrankenversicherung: { + mean_allgemein: 0.118 + } + arbeitslosenversicherung: 0.022 + gesetzlicheRentenversicherung: 0.0935 + } + + from 1986-01-01 { + gesetzlicheKrankenversicherung: { + mean_allgemein: 0.122 + } + arbeitslosenversicherung: 0.0205 + gesetzlicheRentenversicherung: 0.096 + } + + from 1987-01-01 { + gesetzlicheKrankenversicherung: { + mean_allgemein: 0.1248 + } + arbeitslosenversicherung: 0.0215 + gesetzlicheRentenversicherung: 0.0935 + } + + from 1988-01-01 { + // deviation_from: previous + gesetzlicheKrankenversicherung: { + mean_allgemein: 0.1288 + } + } + + from 1989-01-01 { + // deviation_from: previous + gesetzlicheKrankenversicherung: { + mean_allgemein: 0.129 + } + } + + from 1990-01-01 { + // deviation_from: previous + gesetzlicheKrankenversicherung: { + mean_allgemein: 0.125 + } + } + + from 1991-01-01 { + // deviation_from: previous + gesetzlicheKrankenversicherung: { + mean_allgemein: .128 + } + } + + from 1992-01-01 { + // deviation_from: previous + arbeitslosenversicherung: 0.0315 + gesetzlicheRentenversicherung: 0.0885 + } + + from 1993-01-01 { + gesetzlicheKrankenversicherung: { + mean_allgemein: 0.134 + } + arbeitslosenversicherung: 0.0325 + gesetzlicheRentenversicherung: 0.0875 + } + + from 1994-01-01 { + // deviation_from: previous + gesetzlicheRentenversicherung: 0.096 + } + + from 1995-01-01 { + arbeitslosenversicherung: 0.0325 + gesetzlicheKrankenversicherung: { + mean_allgemein: 0.132 + } + gesetzlichePflegeversicherung: 0.005 + gesetzlicheRentenversicherung: 0.093 + } + + from 1996-01-01 { + // deviation_from: previous + gesetzlicheRentenversicherung: 0.096 + } + + from 1997-01-01 { + gesetzlicheKrankenversicherung: { + mean_allgemein: 0.134 + } + gesetzlichePflegeversicherung: 0.0085 + arbeitslosenversicherung: 0.0325 + gesetzlicheRentenversicherung: 0.1015 + } + + from 1998-01-01 { + // deviation_from: previous + gesetzlicheKrankenversicherung: { + mean_allgemein: 0.136 + } + } + + from 2000-01-01 { + // deviation_from: previous + gesetzlicheKrankenversicherung: { + mean_allgemein: 0.1357 + } + gesetzlicheRentenversicherung: 0.0965 + } + + from 2001-01-01 { + // deviation_from: previous + gesetzlicheKrankenversicherung: { + mean_allgemein: 0.1358 + } + gesetzlicheRentenversicherung: 0.0955 + } + + from 2002-01-01 { + // deviation_from: previous + gesetzlicheKrankenversicherung: { + mean_allgemein: 0.14 + } + } + + from 2003-01-01 { + // deviation_from: previous + gesetzlicheKrankenversicherung: { + mean_allgemein: 0.144 + } + gesetzlicheRentenversicherung: 0.0975 + } + + from 2004-01-01 { + // deviation_from: previous + gesetzlicheKrankenversicherung: { + mean_allgemein: 0.142 + } + } + + from 2005-01-01 { + gesetzlicheKrankenversicherung: { + mean_allgemein: 0.142 + } + gesetzlichePflegeversicherung: { + standard: 0.0085 + zusatz_kinderlos: 0.0025 + } + arbeitslosenversicherung: 0.0325 + gesetzlicheRentenversicherung: 0.0975 + } + + // Allgemeiner Beitragssatz wird nicht mehr gleichmäßig aufgeteilt, Einführung des Sonderbeitrags + // Reference: Art. 1 G. v. 15.12.2004, BGBl I S. 3445. + from 2005-07-01 { + // deviation_from: previous + gesetzlicheKrankenversicherung: { + mean_allgemein: 0.133 + sonderbeitrag: 0.009 + } + } + + from 2007-01-01 { + // deviation_from: previous + gesetzlicheKrankenversicherung: { + mean_allgemein: 0.139 + } + arbeitslosenversicherung: 0.021 + gesetzlicheRentenversicherung: 0.0995 + } + + from 2008-01-01 { + gesetzlicheKrankenversicherung: { + mean_allgemein: 0.14 + sonderbeitrag: 0.009 + } + gesetzlichePflegeversicherung: { + standard: 0.00975 + zusatzKinderlos: 0.0025 + } + arbeitslosenversicherung: 0.016 + gesetzlicheRentenversicherung: 0.0995 + } + + from 2009-01-01 { + // deviation_from: previous + gesetzlicheKrankenversicherung: { + allgemein: 0.146 + sonderbeitrag: 0.009 + ermäßigt: 0.140 + } + arbeitslosenversicherung: 0.014 + } + + from 2009-07-01 { + // deviation_from: previous + gesetzlicheKrankenversicherung: { + allgemein: 0.14 + ermäßigt: 0.134 + sonderbeitrag: 0.009 + } + } + + // Reference: Art. 1 G. v. 22.12.2010 BGBl. I S. 2309 + from 2011-01-01 { + // deviation_from: previous + gesetzlicheKrankenversicherung: { + allgemein: 0.146 + ermäßigt: 0.14 + } + arbeitslosenversicherung: 0.015 + } + + // Quelle: http://www.bmas.de/DE/Service/Presse/Pressemitteilungen/rentenbericht-16-11-2011.html + from 2012-01-01 { + // deviation_from: previous + gesetzlicheRentenversicherung: 0.098 + } + + from 2013-01-01 { + // deviation_from: previous + gesetzlicheRentenversicherung: 0.0945 + gesetzlichePflegeversicherung: { + standard: 0.01025 + } + } + + // Abschaffung Sonderbeitrag, Einführung kassenabhängiger Zusatzbeitrag + from 2015-01-01 { + gesetzlicheKrankenversicherung: { + allgemein: 0.146 + ermäßigt: 0.14 + meanZusatzbeitrag: 0.009 + } + gesetzlichePflegeversicherung: { + standard: 0.01175 + zusatzKinderlos: 0.0025 + } + arbeitslosenversicherung: 0.015 + gesetzlicheRentenversicherung: 0.0935 + } + + // Bekanntmachung Bundesanzeiger 30.12.2015 + from 2016-01-01 { + // deviation_from: previous + gesetzlicheKrankenversicherung: { + meanZusatzbeitrag: 0.011 + } + } + + from 2017-01-01 { + // deviation_from: previous + gesetzlichePflegeversicherung: { + standard: 0.01275 + } + } + + from 2018-01-01 { + // deviation_from: previous + gesetzlicheKrankenversicherung: { + meanZusatzbeitrag: 0.01 + } + gesetzlicheRentenversicherung: 0.093 + } + + // Wieder-Einführung der Parität. Art. 2 G. v. 11.12.2018, BGBl. I S. 2387 + // (arbeitsl_v:) Set to 0.026 in Art. 2 Nr. 15 G. v. 18.12.2018 BGBl. I S. 2651. + // Temporarily reduced to 0.025 in BeiSaV 2019. + // Reference: (arbeitsl_v:) V. v. 21.12.2018 BGBl. I S. 2663 + from 2019-01-01 { + gesetzlicheKrankenversicherung: { + allgemein: 0.146 + ermäßigt: 0.14 + meanZusatzbeitrag: 0.009 + } + gesetzlichePflegeversicherung: { + standard: 0.01525 + zusatzKinderlos: 0.0025 + } + arbeitslosenversicherung: 0.0125 + gesetzlicheRentenversicherung: 0.093 + } + + // Temporarily reduced to 0.024 in BeiSaV 2019. + // Reference: (ges_krankenv mean_zusatzbeitrag:) BAnz AT 28.10.2019 B3 + // (arbeitsl_v:) V. v. 02.12.2019 BGBl. I S. 1998 + from 2020-01-01 { + // deviation_from: previous + gesetzlicheKrankenversicherung: { + meanZusatzbeitrag: 0.011 + } + arbeitslosenversicherung: 0.012 + } + + // Reference: (ges_krankenv mean_zusatzbeitrag:) BAnz AT 30.10.2020 B5 + from 2021-01-01 { + // deviation_from: previous + gesetzlicheKrankenversicherung: { + meanZusatzbeitrag: 0.013 + } + } + + // Reference: Art. 2 Nr. 14 G. v. 11.07.2021, BGBl. I S. 2754. + from 2022-01-01 { + // deviation_from: previous + gesetzlichePflegeversicherung: { + zusatzKinderlos: 0.0035 + } + } + + // Contribution rate for arbeitsl_v was temporarily reduced from 2019 to 2022 in BeiSaV 2019. + // Now back to level specified in § 341 Abs. 2 SGB III. + // Reference: (arbeitsl_v:) Art. 2 Nr. 15 G. v. 18.12.2018 BGBl. I S. 2651 + // (ges_krankenv mean_zusatzbeitrag:) BAnz AT 31.10.2022 B5 + from 2023-01-01 { + // deviation_from: previous + arbeitslosenversicherung: 0.013 + gesetzlicheKrankenversicherung: { + meanZusatzbeitrag: 0.016 + } + } +} + +/** + * Beitragssätze zu den gesetzlichen Sozialversicherungen + * Die Beitragsbemessungsgrenze für Kranken- und Pflegeversicherung ist identisch. + */ +const beitragsbemessungsgrenze: Dict> { + from 1984-01-01 { + ges_krankenv: { + west: 1994 + } + ges_rentenv: { + west: 2659 + } + } + + from 1985-01-01 { + ges_krankenv: { + west: 2071 + } + ges_rentenv: { + west: 2761 + } + } + + from 1986-01-01 { + ges_krankenv: { + west: 2147 + } + ges_rentenv: { + west: 2863 + } + } + + from 1987-01-01 { + ges_krankenv: { + west: 2186 + } + ges_rentenv: { + west: 2914 + } + } + + from 1988-01-01 { + ges_krankenv: { + west: 2301 + } + ges_rentenv: { + west: 3068 + } + } + + from 1989-01-01 { + ges_krankenv: { + west: 2339 + } + ges_rentenv: { + west: 3119 + } + } + + from 1990-01-01 { + ges_krankenv: { + west: 2416 + ost: 1035 + } + ges_rentenv: { + west: 3221 + ost: 1380 + } + } + + from 1991-01-01 { + ges_krankenv: { + west: 2493 + ost: 1151 + } + ges_rentenv: { + west: 3323 + ost: 1534 + } + } + + from 1992-01-01 { + ges_krankenv: { + west: 2608 + ost: 1841 + } + ges_rentenv: { + west: 3477 + ost: 2454 + } + } + + from 1993-01-01 { + ges_krankenv: { + west: 2761 + ost: 2032 + } + ges_rentenv: { + west: 3681 + ost: 271 + } + } + + from 1994-01-01 { + ges_krankenv: { + west: 2914 + ost: 2262 + } + ges_rentenv: { + west: 3886 + ost: 3017 + } + } + + from 1995-01-01 { + ges_krankenv: { + west: 2991 + ost: 2454 + } + ges_rentenv: { + west: 3988 + ost: 3272 + } + } + + from 1996-01-01 { + ges_krankenv: { + west: 3068 + ost: 2608 + } + ges_rentenv: { + west: 4090 + ost: 3477 + } + } + + from 1997-01-01 { + ges_krankenv: { + west: 3144 + ost: 2723 + } + ges_rentenv: { + west: 4193 + ost: 3630 + } + } + + from 1998-01-01 { + ges_krankenv: { + west: 3221 + ost: 2684 + } + ges_rentenv: { + west: 4295 + ost: 3579 + } + } + + from 1999-01-01 { + ges_krankenv: { + west: 3259 + ost: 2761 + } + ges_rentenv: { + west: 4339 + ost: 3681 + } + } + + from 2000-01-01 { + ges_krankenv: { + west: 3298 + ost: 2723 + } + ges_rentenv: { + west: 4397 + ost: 3630 + } + } + + from 2001-01-01 { + ges_krankenv: { + west: 3336 + ost: 3336 + } + ges_rentenv: { + west: 4448 + ost: 3732 + } + } + + from 2002-01-01 { + ges_krankenv: { + west: 3375 + ost: 3375 + } + ges_rentenv: { + west: 4500 + ost: 3750 + } + } + + from 2003-01-01 { + ges_krankenv: { + west: 3450 + ost: 3375 + } + ges_rentenv: { + west: 5100 + ost: 4250 + } + } + + from 2004-01-01 { + ges_krankenv: { + west: 3488 + ost: 3488 + } + ges_rentenv: { + west: 5150 + ost: 4350 + } + } + + from 2005-01-01 { + ges_krankenv: { + west: 3525 + ost: 3525 + } + ges_rentenv: { + west: 5200 + ost: 4400 + } + } + + from 2006-01-01 { + ges_krankenv: { + west: 3562.5 + ost: 3562.5 + } + ges_rentenv: { + west: 5250 + ost: 4400 + } + } + + from 2007-01-01 { + // deviation_from: previous + ges_rentenv: { + ost: 4550 + } + } + + from 2008-01-01 { + ges_krankenv: { + west: 3600 + ost: 3600 + } + ges_rentenv: { + west: 5300 + ost: 4500 + } + } + + from 2009-01-01 { + ges_krankenv: { + west: 3675 + ost: 3675 + } + ges_rentenv: { + west: 5400 + ost: 4550 + } + } + + from 2010-01-01 { + ges_krankenv: { + west: 3750 + ost: 3750 + } + ges_rentenv: { + west: 5500 + ost: 4650 + } + } + + from 2011-01-01 { + // deviation_from: previous + ges_krankenv: { + west: 3712.5 + ost: 3712.5 + } + ges_rentenv: { + ost: 4800 + } + } + + from 2012-01-01 { + // deviation_from: previous + ges_krankenv: { + west: 3825 + ost: 3825 + } + ges_rentenv: { + west: 5600 + } + } + + from 2013-01-01 { + ges_krankenv: { + west: 3937.5 + ost: 3937.5 + } + ges_rentenv: { + west: 5800 + ost: 4900 + } + } + + // http://www.bundesregierung.de/ContentArchiv/DE/Archiv17/Artikel/2013/10/2013-10-16-rechengroessen-sozialversicherung.html + from 2014-01-01 { + ges_krankenv: { + west: 4050 + ost: 4050 + } + ges_rentenv: { + west: 5950 + ost: 5000 + } + } + + from 2015-01-01 { + ges_krankenv: { + west: 4125 + ost: 4125 + } + ges_rentenv: { + west: 6050 + ost: 5200 + } + } + + // https://www.bundesregierung.de/Content/DE/Artikel/2015/10/2015-10-14-sozialversicherung.html + from 2016-01-01 { + ges_krankenv: { + west: 4237.5 + ost: 4237.5 + } + ges_rentenv: { + west: 6200 + ost: 5400 + } + } + + // https://www.bundesregierung.de/Content/DE/Artikel/2016/10/2016-10-12-bemessunggrenzen-sozialversicherung.html + from 2017-01-01 { + ges_krankenv: { + west: 4350 + ost: 4350 + } + ges_rentenv: { + west: 6350 + ost: 5700 + } + } + + from 2018-01-01 { + ges_krankenv: { + west: 4425 + ost: 4425 + } + ges_rentenv: { + west: 6500 + ost: 5800 + } + } + + from 2019-01-01 { + ges_krankenv: { + west: 4537.5 + ost: 4537.5 + } + ges_rentenv: { + west: 6700 + ost: 6150 + } + } + + // Reference: V. v. 17.12.2019 BGBl. I S. 2848 + from 2020-01-01 { + ges_krankenv: { + west: 4687.5 + ost: 4687.5 + } + ges_rentenv: { + west: 6900 + ost: 6450 + } + } + + // Reference: §3, §4 V. v. 30.11.2020, BGBl. I S. 2612. + from 2021-01-01 { + ges_krankenv: { + west: 4837.5 + ost: 4837.5 + } + ges_rentenv: { + west: 7100 + ost: 6700 + } + } + + // Reference: §3 V. v. 30.11.2021, BGBl. I S. 5044. + from 2022-01-01 { + // deviation_from: previous + ges_rentenv: { + west: 7050 + ost: 6750 + } + } + + // Reference: V. v. 28.11.2022 BGBl. I. S. 2128. + from 2023-01-01 { + ges_krankenv: { + west: 4987.5 + ost: 4987.5 + } + ges_rentenv: { + west: 7300 + ost: 7100 + } + } +} + +/** + * Monatliche Bezugsgröße + * §18 SGB IV and https://de.wikipedia.org/wiki/Bezugsgr%C3%B6%C3%9Fe + */ +const monatlicheBezugsgroeße: Dict { + from 1984-01-01 { + west: 1396 + } + + from 1985-01-01 { + west: 1432 + } + + from 1986-01-01 { + west: 1467 + } + + from 1987-01-01 { + west: 1539 + } + + from 1988-01-01 { + west: 1575 + } + + from 1989-01-01 { + west: 1611 + } + + from 1990-01-01 { + west: 1682 + ost: 715.8086336747059 + } + + from 1991-01-01 { + west: 1718 + ost: 787.3894970421765 + } + + from 1992-01-01 { + west: 1790 + ost: 1073.712950512059 + } + + from 1993-01-01 { + west: 1897 + ost: 1395.826835665677 + } + + from 1994-01-01 { + west: 2004 + ost: 1574.778994084353 + } + + from 1995-01-01 { + west: 2076 + ost: 1682.150289135559 + } + + from 1996-01-01 { + west: 2112 + ost: 1789.521584186765 + } + + from 1997-01-01 { + west: 2183 + ost: 1861.102447554235 + } + + from 1998-01-01 { + west: 2219 + ost: 1896.892879237971 + } + + from 1999-01-01 { + west: 2255 + ost: 1896.892879237971 + } + + from 2000-01-01 { + west: 2291 + ost: 1861.102447554235 + } + + from 2001-01-01 { + // deviation_from: previous + ost: 1932.683310921706 + } + + from 2002-01-01 { + west: 2345 + ost: 1960 + } + + from 2003-01-01 { + west: 2380 + ost: 1995 + } + + from 2004-01-01 { + west: 2415 + ost: 2030 + } + + from 2006-01-01 { + west: 2450 + ost: 2065 + } + + from 2007-01-01 { + // deviation_from: previous + ost: 2100 + } + + from 2008-01-01 { + // deviation_from: previous + west: 2485 + } + + from 2009-01-01 { + west: 2520 + ost: 2135 + } + + from 2010-01-01 { + west: 2555 + ost: 2170 + } + + from 2011-01-01 { + // deviation_from: previous + ost: 2240 + } + + from 2012-01-01 { + // deviation_from: previous + west: 2625 + } + + from 2013-01-01 { + west: 2695 + ost: 2275 + } + + // http://www.bundesregierung.de/ContentArchiv/DE/Archiv17/Artikel/2013/10/2013-10-16-rechengroessen-sozialversicherung.html + from 2014-01-01 { + west: 2765 + ost: 2345 + } + + from 2015-01-01 { + west: 2835 + ost: 2415 + } + + // https://www.bundesregierung.de/Content/DE/Artikel/2015/10/2015-10-14-sozialversicherung.html + from 2016-01-01 { + west: 2905 + ost: 2520 + } + + // https://www.bundesregierung.de/Content/DE/Artikel/2016/10/2016-10-12-bemessunggrenzen-sozialversicherung.html + from 2017-01-01 { + west: 2975 + ost: 2660 + } + + from 2018-01-01 { + west: 3045 + ost: 2695 + } + + // Sozialversicherungs-Rechengrößenverordnung 2019, BGBl I S. 2024, 27.11.2018 + from 2019-01-01 { + west: 3115 + ost: 2870 + } + + // Reference: §2 V. v. 17.12.2019 BGBl. I S. 2848 + from 2020-01-01 { + west: 3185 + ost: 3010 + } + + // Reference: §2 V. v. 30.11.2020, BGBl. I S. 2612. + from 2021-01-01 { + west: 3290 + ost: 3115 + } + + // Reference: §2 V. v. 30.11.2021, BGBl. I S. 5044. + from 2022-01-01 { + west: 3290 + ost: 3150 + } + + // Reference: V. v. 28.11.2022 BGBl. I. S. 2128. + from 2023-01-01 { + west: 3395 + ost: 3290 + } +} + +mindestanteil_bezugsgröße_beitragspf_einnahme_selbst: + name: + de: Mindestberechungsbeitrag für Selbstständige als Anteil der Bezugsgröße + en: Minimum contribution for self employed as fraction of Bezugsgröße + description: + de: >- + Als beitragspflichtige Einnahmen gilt für den Kalendertag mindestens der + neunzigste Teil der monatlichen Bezugsgröße (1/90*30) + en: >- + Health Insurance contributions have to be payed, at the minimum, on the ninetieth + part of the monthly Bezugsgröße for each calender day + unit: Share + reference: §240 SGB V Abs. 4 + note: Exact date of introduction of this parameter unclear (was in place in 2006) + 1990-01-01: + scalar: 0.33333333 +geringfügige_eink_grenzen_m: + name: + de: >- + Gleitzone (Midijob Grenze) und Minijob Grenze (bis 1999 unterschiedliche Grenzen) + en: Thresholds for marginal employment ('mini' and 'midi' jobs) + description: + de: Midijob § 20 (2) SGB IV, Minijob § 8 (1) Nr. 1 SGB IV + en: null + unit: Euro + reference_period: Month + 1984-01-01: + minijob: + west: 199 + 1985-01-01: + deviation_from: previous + minijob: + west: 205 + 1986-01-01: + deviation_from: previous + minijob: + west: 210 + 1987-01-01: + deviation_from: previous + minijob: + west: 220 + 1988-01-01: + deviation_from: previous + minijob: + west: 225 + 1989-01-01: + deviation_from: previous + minijob: + west: 230 + 1990-01-01: + minijob: + west: 240 + ost: 102 + 1991-01-01: + minijob: + west: 245 + ost: 120 + 1992-01-01: + minijob: + west: 256 + ost: 153 + 1993-01-01: + minijob: + west: 271 + ost: 199 + 1994-01-01: + minijob: + west: 286 + ost: 225 + 1995-01-01: + minijob: + west: 297 + ost: 240 + 1996-01-01: + minijob: + west: 302 + ost: 256 + 1997-01-01: + minijob: + west: 312 + ost: 266 + 1998-01-01: + deviation_from: previous + minijob: + west: 317 + 1999-01-01: + minijob: + west: 322 + ost: 271 + 2000-01-01: + minijob: 322 + 2002-01-01: + minijob: 325 + 2003-04-01: + minijob: 400 + midijob: 800 + 2013-01-01: + minijob: 450 + midijob: 850 + 2019-01-01: + deviation_from: previous + reference: Art. 4 G. v. 28.11.2018 BGBl. I S. 2016 + midijob: 1300 + 2022-10-01: + minijob: null + midijob: 1600 + reference: Art. 7 G. v. 28.06.2022 BGBl. I S. 969 + note: minijob thresholds now calculated based on statutory minimum wage + 2023-01-01: + deviation_from: previous + midijob: 2000 + reference: Art. 3 G. v. 11.11.2022 BGBl. I S. 1985 +geringf_eink_faktor: + name: + de: >- + Faktor, mit dem der Mindestlohn in der Berechnung der Geringfügigkeitsgrenze + multipliziert wird. + reference: §8 (1a) SGB IV + 2022-10-01: + scalar: 130 + reference: Art. 7 G. v. 28.06.2022 BGBl. I S. 969 +geringf_eink_divisor: + name: + de: >- + Betrag, durch den der Mindestlohn, multipliziert mit gering_eink_faktor, dividiert + wird, um die Geringfügigkeitsgrenze zu erhalten. + reference: §8 (1a) SGB IV + 2022-10-01: + scalar: 3 + reference: Art. 7 G. v. 28.06.2022 BGBl. I S. 969 +ag_abgaben_geringf: + name: + de: Pauschalabgaben bei geringf. Beschäftigung + en: null + description: + de: >- + Pauschalbeitrag zur Krankenversicherung (§ 249b SGB V), Pauschalbetrag zur + Rentenversicherung (§ 168 I Nr. 1b SGB VI), Pauschalierte Lohnsteuer (§40a II + EStG) + en: null + unit: Share + access_different_date: jahresanfang + 1984-01-01: + ges_krankenv: 0 + ges_rentenv: 0 + st: 0 + 1999-01-01: + ges_krankenv: 0.1 + ges_rentenv: 0.12 + st: 0 + 2003-04-01: + ges_krankenv: 0.11 + ges_rentenv: 0.12 + st: 0.02 + 2007-01-01: + ges_krankenv: 0.13 + ges_rentenv: 0.15 + st: 0.02 +ges_pflegev_zusatz_kinderlos_mindestalter: + name: + de: Mindestalter Beitragszuschlag für Kinderlose + en: Minimum age for additional contribution for childless + description: + de: >- + Kinderlose Mitglieder der sozialen Pflegeversicherung, die das 23. Lebensjahr + vollendet haben, müssen seit dem 1. Januar 2005 einen erhöhten Beitragssatz + entrichten. + en: >- + Childless members of the social care insurance, who have reached the age of 23, + have to pay a higher contribution rate since January 1, 2005. + unit: Year + reference: § 55 Abs. 3 SGB XI, KiBG Art. 1 + 2005-01-01: + scalar: 23 +mindestlohn: + name: + de: Allgemeiner gesetzlicher Mindestlohn pro Stunde + en: Statutory hourly minimum wage + unit: Euro + reference: §1 (2) Mindestlohngesetz + 2015-01-01: + scalar: 8.5 + 2017-01-01: + scalar: 8.84 + 2019-01-01: + scalar: 9.19 + 2020-01-01: + scalar: 9.35 + 2021-01-01: + scalar: 9.5 + 2021-07-01: + scalar: 9.6 + 2022-01-01: + scalar: 9.82 + 2022-07-01: + scalar: 10.45 + 2022-10-01: + scalar: 12 +rounding: + midijob_faktor_f: + 1990-01-01: + base: 0.0001 + direction: nearest + reference: null + minijob_grenze: + 1990-01-01: + base: 1 + direction: up + reference: §8 (1a) S.2 SGB IV. + +/** + * Mindestberechungsbeitrag für Selbstständige als Anteil der Bezugsgröße + * Als beitragspflichtige Einnahmen gilt für den Kalendertag mindestens der + * neunzigste Teil der monatlichen Bezugsgröße (1/90*30) + * Reference: §240 SGB V Abs. 4 + */ +const mindestanteilBezugsgroeßeBeitragspflichtigeEinnahmeSelbst: Float { + from 1990-01-01 { + scalar: 0.33333333 + } +} + +/** + * Gleitzone (Midijob Grenze) und Minijob Grenze (bis 1999 unterschiedliche Grenzen) + * Reference: Midijob § 20 (2) SGB IV, Minijob § 8 (1) Nr. 1 SGB IV + */ +const geringfuegigeEinkommensgrenzenMonatlich: Dict> { + from 1984-01-01 { + minijob: { + west: 199 + } + } + + from 1985-01-01 { + // deviation_from: previous + minijob: { + west: 205 + } + } + + from 1986-01-01 { + // deviation_from: previous + minijob: { + west: 210 + } + } + + from 1987-01-01 { + // deviation_from: previous + minijob: { + west: 220 + } + } + + from 1988-01-01 { + // deviation_from: previous + minijob: { + west: 225 + } + } + + from 1989-01-01 { + // deviation_from: previous + minijob: { + west: 230 + } + } + + from 1990-01-01 { + minijob: { + west: 240 + ost: 102 + } + } + + from 1991-01-01 { + // deviation_from: previous + minijob: { + west: 245 + ost: 120 + } + } + + from 1992-01-01 { + // deviation_from: previous + minijob: { + west: 256 + ost: 153 + } + } + + from 1993-01-01 { + // deviation_from: previous + minijob: { + west: 271 + ost: 199 + } + } + + from 1994-01-01 { + // deviation_from: previous + minijob: { + west: 286 + ost: 225 + } + } + + from 1995-01-01 { + // deviation_from: previous + minijob: { + west: 297 + ost: 240 + } + } + + from 1996-01-01 { + // deviation_from: previous + minijob: { + west: 302 + ost: 256 + } + } + + from 1997-01-01 { + // deviation_from: previous + minijob: { + west: 312 + ost: 266 + } + } + + from 1998-01-01 { + // deviation_from: previous + minijob: { + west: 317 + } + } + + from 1999-01-01 { + // deviation_from: previous + minijob: { + west: 322 + ost: 271 + } + } + + from 2000-01-01 { + // deviation_from: previous + minijob: 322 + } + + from 2002-01-01 { + // deviation_from: previous + minijob: 325 + } + + from 2003-04-01 { + // deviation_from: previous + minijob: 400 + midijob: 800 + } + + from 2013-01-01 { + // deviation_from: previous + minijob: 450 + midijob: 850 + } + + // Reference: Art. 4 G. v. 28.11.2018 BGBl. I S. 2016 + from 2019-01-01 { + // deviation_from: previous + midijob: 1300 + } + + // Reference: Art. 7 G. v. 28.06.2022 BGBl. I S. 969 + // minijob thresholds now calculated based on statutory minimum wage + from 2022-10-01 { + // deviation_from: previous + minijob: null + midijob: 1600 + } + + // Reference: Art. 3 G. v. 11.11.2022 BGBl. I S. 1985 + from 2023-01-01 { + // deviation_from: previous + midijob: 2000 + } +} + +/** + * Faktor, mit dem der Mindestlohn in der Berechnung der Geringfügigkeitsgrenze + * multipliziert wird. + * Reference: §8 (1a) SGB IV + */ +const geringfuegigeEinkommensfaktor: Int { + from 2022-10-01 = 130 +} + +/** + * Betrag, durch den der Mindestlohn, multipliziert mit geringf_eink_faktor, dividiert + * wird, um die Geringfügigkeitsgrenze zu erhalten. + * Reference: §8 (1a) SGB IV + */ +const geringfuegigeEinkommensdivisor: Int { + // Reference: Art. 7 G. v. 28.06.2022 BGBl. I S. 969 + from 2022-10-01 = 3 +} + +/** + * Pauschalabgaben bei geringf. Beschäftigung + * Pauschalbeitrag zur Krankenversicherung (§ 249b SGB V), Pauschalbetrag zur + * Rentenversicherung (§ 168 I Nr. 1b SGB VI), Pauschalierte Lohnsteuer (§40a II + * EStG) + */ +const pauschalabgabenGeringfuegigeBeschaeftigung: Dict { + from 1984-01-01 { + ges_krankenv: 0 + ges_rentenv: 0 + st: 0 + } + + from 1999-01-01 { + // deviation_from: previous + ges_krankenv: 0.1 + ges_rentenv: 0.12 + st: 0 + } + + from 2003-04-01 { + // deviation_from: previous + ges_krankenv: 0.11 + ges_rentenv: 0.12 + st: 0.02 + } + + from 2007-01-01 { + // deviation_from: previous + ges_krankenv: 0.13 + ges_rentenv: 0.15 + st: 0.02 + } +} + +/** + * Mindestalter Beitragszuschlag für Kinderlose + * Kinderlose Mitglieder der sozialen Pflegeversicherung, die das 23. Lebensjahr + * vollendet haben, müssen seit dem 1. Januar 2005 einen erhöhten Beitragssatz + * entrichten. + * Reference: § 55 Abs. 3 SGB XI, KiBG Art. 1 + */ +const mindestalterBeitragszuschlagKinderlose: Int { + from 2005-01-01 = 23 +} + +/** + * Allgemeiner gesetzlicher Mindestlohn pro Stunde + * Reference: §1 (2) Mindestlohngesetz + */ +const mindestlohn: Float { + from 2015-01-01 = 8.5 + from 2017-01-01 = 8.84 + from 2019-01-01 = 9.19 + from 2020-01-01 = 9.35 + from 2021-01-01 = 9.5 + from 2021-07-01 = 9.6 + from 2022-01-01 = 9.82 + from 2022-07-01 = 10.45 + from 2022-10-01 = 12 +} + +// TODO: rounding From 01163423ac2d7c762092d80953ce4b35800afe9c Mon Sep 17 00:00:00 2001 From: alex-senger Date: Tue, 21 May 2024 14:24:37 +0200 Subject: [PATCH 036/183] chore: remove yaml from sozialversicherungsbeitrag.ttsl --- .../builtins/sozialversicherungsbeitrag.ttsl | 210 ------------------ 1 file changed, 210 deletions(-) diff --git a/src/resources/builtins/sozialversicherungsbeitrag.ttsl b/src/resources/builtins/sozialversicherungsbeitrag.ttsl index 89313197..a24bc21e 100644 --- a/src/resources/builtins/sozialversicherungsbeitrag.ttsl +++ b/src/resources/builtins/sozialversicherungsbeitrag.ttsl @@ -993,216 +993,6 @@ const monatlicheBezugsgroeße: Dict { } } -mindestanteil_bezugsgröße_beitragspf_einnahme_selbst: - name: - de: Mindestberechungsbeitrag für Selbstständige als Anteil der Bezugsgröße - en: Minimum contribution for self employed as fraction of Bezugsgröße - description: - de: >- - Als beitragspflichtige Einnahmen gilt für den Kalendertag mindestens der - neunzigste Teil der monatlichen Bezugsgröße (1/90*30) - en: >- - Health Insurance contributions have to be payed, at the minimum, on the ninetieth - part of the monthly Bezugsgröße for each calender day - unit: Share - reference: §240 SGB V Abs. 4 - note: Exact date of introduction of this parameter unclear (was in place in 2006) - 1990-01-01: - scalar: 0.33333333 -geringfügige_eink_grenzen_m: - name: - de: >- - Gleitzone (Midijob Grenze) und Minijob Grenze (bis 1999 unterschiedliche Grenzen) - en: Thresholds for marginal employment ('mini' and 'midi' jobs) - description: - de: Midijob § 20 (2) SGB IV, Minijob § 8 (1) Nr. 1 SGB IV - en: null - unit: Euro - reference_period: Month - 1984-01-01: - minijob: - west: 199 - 1985-01-01: - deviation_from: previous - minijob: - west: 205 - 1986-01-01: - deviation_from: previous - minijob: - west: 210 - 1987-01-01: - deviation_from: previous - minijob: - west: 220 - 1988-01-01: - deviation_from: previous - minijob: - west: 225 - 1989-01-01: - deviation_from: previous - minijob: - west: 230 - 1990-01-01: - minijob: - west: 240 - ost: 102 - 1991-01-01: - minijob: - west: 245 - ost: 120 - 1992-01-01: - minijob: - west: 256 - ost: 153 - 1993-01-01: - minijob: - west: 271 - ost: 199 - 1994-01-01: - minijob: - west: 286 - ost: 225 - 1995-01-01: - minijob: - west: 297 - ost: 240 - 1996-01-01: - minijob: - west: 302 - ost: 256 - 1997-01-01: - minijob: - west: 312 - ost: 266 - 1998-01-01: - deviation_from: previous - minijob: - west: 317 - 1999-01-01: - minijob: - west: 322 - ost: 271 - 2000-01-01: - minijob: 322 - 2002-01-01: - minijob: 325 - 2003-04-01: - minijob: 400 - midijob: 800 - 2013-01-01: - minijob: 450 - midijob: 850 - 2019-01-01: - deviation_from: previous - reference: Art. 4 G. v. 28.11.2018 BGBl. I S. 2016 - midijob: 1300 - 2022-10-01: - minijob: null - midijob: 1600 - reference: Art. 7 G. v. 28.06.2022 BGBl. I S. 969 - note: minijob thresholds now calculated based on statutory minimum wage - 2023-01-01: - deviation_from: previous - midijob: 2000 - reference: Art. 3 G. v. 11.11.2022 BGBl. I S. 1985 -geringf_eink_faktor: - name: - de: >- - Faktor, mit dem der Mindestlohn in der Berechnung der Geringfügigkeitsgrenze - multipliziert wird. - reference: §8 (1a) SGB IV - 2022-10-01: - scalar: 130 - reference: Art. 7 G. v. 28.06.2022 BGBl. I S. 969 -geringf_eink_divisor: - name: - de: >- - Betrag, durch den der Mindestlohn, multipliziert mit gering_eink_faktor, dividiert - wird, um die Geringfügigkeitsgrenze zu erhalten. - reference: §8 (1a) SGB IV - 2022-10-01: - scalar: 3 - reference: Art. 7 G. v. 28.06.2022 BGBl. I S. 969 -ag_abgaben_geringf: - name: - de: Pauschalabgaben bei geringf. Beschäftigung - en: null - description: - de: >- - Pauschalbeitrag zur Krankenversicherung (§ 249b SGB V), Pauschalbetrag zur - Rentenversicherung (§ 168 I Nr. 1b SGB VI), Pauschalierte Lohnsteuer (§40a II - EStG) - en: null - unit: Share - access_different_date: jahresanfang - 1984-01-01: - ges_krankenv: 0 - ges_rentenv: 0 - st: 0 - 1999-01-01: - ges_krankenv: 0.1 - ges_rentenv: 0.12 - st: 0 - 2003-04-01: - ges_krankenv: 0.11 - ges_rentenv: 0.12 - st: 0.02 - 2007-01-01: - ges_krankenv: 0.13 - ges_rentenv: 0.15 - st: 0.02 -ges_pflegev_zusatz_kinderlos_mindestalter: - name: - de: Mindestalter Beitragszuschlag für Kinderlose - en: Minimum age for additional contribution for childless - description: - de: >- - Kinderlose Mitglieder der sozialen Pflegeversicherung, die das 23. Lebensjahr - vollendet haben, müssen seit dem 1. Januar 2005 einen erhöhten Beitragssatz - entrichten. - en: >- - Childless members of the social care insurance, who have reached the age of 23, - have to pay a higher contribution rate since January 1, 2005. - unit: Year - reference: § 55 Abs. 3 SGB XI, KiBG Art. 1 - 2005-01-01: - scalar: 23 -mindestlohn: - name: - de: Allgemeiner gesetzlicher Mindestlohn pro Stunde - en: Statutory hourly minimum wage - unit: Euro - reference: §1 (2) Mindestlohngesetz - 2015-01-01: - scalar: 8.5 - 2017-01-01: - scalar: 8.84 - 2019-01-01: - scalar: 9.19 - 2020-01-01: - scalar: 9.35 - 2021-01-01: - scalar: 9.5 - 2021-07-01: - scalar: 9.6 - 2022-01-01: - scalar: 9.82 - 2022-07-01: - scalar: 10.45 - 2022-10-01: - scalar: 12 -rounding: - midijob_faktor_f: - 1990-01-01: - base: 0.0001 - direction: nearest - reference: null - minijob_grenze: - 1990-01-01: - base: 1 - direction: up - reference: §8 (1a) S.2 SGB IV. - /** * Mindestberechungsbeitrag für Selbstständige als Anteil der Bezugsgröße * Als beitragspflichtige Einnahmen gilt für den Kalendertag mindestens der From bf3045a6c6387b2e745cf5c2ed1ab507e05319f4 Mon Sep 17 00:00:00 2001 From: alex-senger Date: Tue, 21 May 2024 14:24:50 +0200 Subject: [PATCH 037/183] feat: add unterhalt.ttsl --- src/resources/builtins/unterhalt.ttsl | 79 +++++++++++++++++++++++++++ 1 file changed, 79 insertions(+) create mode 100644 src/resources/builtins/unterhalt.ttsl diff --git a/src/resources/builtins/unterhalt.ttsl b/src/resources/builtins/unterhalt.ttsl new file mode 100644 index 00000000..167fb161 --- /dev/null +++ b/src/resources/builtins/unterhalt.ttsl @@ -0,0 +1,79 @@ +package unterhalt + +/** + * Mindestunterhalt für Kinder + * § 1612a BGB, § 1 Mindesunterhaltsverordnung. Mindestunterhalt für Kinder in + * Abhängigkeit des Alters (unter 6, unter 12, bis 17 Jahre) + */ +const mindestunterhalt: Dict { + // Reference: V. v. 03.12.2015 BGBl. I S. 2188. + from 2016-01-01 = { + 6: 335, + 12: 384, + 18: 450 + } + + // Reference: V. v. 03.12.2015 BGBl. I S. 2188. + from 2017-01-01 = { + 6: 342, + 12: 393, + 18: 460 + } + + // Reference: Artikel 1 V. v. 28.09.2017 BGBl. I S. 3525. + from 2018-01-01 = { + 6: 348, + 12: 399, + 18: 467 + } + + // Reference: Artikel 1 V. v. 28.09.2017 BGBl. I S. 3525. + from 2019-01-01 = { + 6: 354, + 12: 406, + 18: 476 + } + + // Reference: Artikel 1 V. v. 12.09.2019 BGBl. I S. 1393. + from 2020-01-01 = { + 6: 369, + 12: 424, + 18: 497 + } + + // Reference: Artikel 1 V. v. 03.11.2020 BGBl. I S. 2344. + from 2021-01-01 = { + 6: 393, + 12: 451, + 18: 528 + } + + // Reference: Artikel 1 V. v. 30.11.2021 BGBl. I S. 5066. + from 2022-01-01 = { + 6: 396, + 12: 455, + 18: 533 + } + + // Reference: Artikel 1 V. v. 30.11.2022 BGBl. I S. 2130. + from 2023-01-01 = { + 6: 437, + 12: 502, + 18: 588 + } +} + +/** + * Verringerung des Kindesunterhalts durch Kindergeld + * Das Kindergeld zählt als Einkommen des Kindes, weshalb es bei der Berechnung von + * Unterhalt Berücksichtigung findet. Erhält der betreuende Elternteil das + * Kindergeld für ein minderjähriges Kind, so kann der andere unterhaltspflichtige + * Elternteil das hälftige Kindergeld bei der Unterhaltsberechnung in Abzug bringen. + * Reference: § 1612b BGB + */ +const abzugsrateKindergeld: Dict { + from 2008-01-01 = { + kind: 0.5, + erwachsener: 1 + } +} \ No newline at end of file From b44f1ade81a53cb659e8c698e039ffa294ecdbce Mon Sep 17 00:00:00 2001 From: alex-senger Date: Tue, 21 May 2024 14:28:50 +0200 Subject: [PATCH 038/183] feat: unterhaltvorschuss --- .../builtins/unterhaltvorschuss.ttsl | 40 +++++++++++++++++++ 1 file changed, 40 insertions(+) create mode 100644 src/resources/builtins/unterhaltvorschuss.ttsl diff --git a/src/resources/builtins/unterhaltvorschuss.ttsl b/src/resources/builtins/unterhaltvorschuss.ttsl new file mode 100644 index 00000000..6c7b3269 --- /dev/null +++ b/src/resources/builtins/unterhaltvorschuss.ttsl @@ -0,0 +1,40 @@ +package unterhaltvorschuss + +/** + * Monatliches Mindesteinkommen, um UHV für Kinder ab + * `altersgrenze_mindesteinkommen` Jahren zu erhalten. + * Reference: § 1 (1a) Nr. 2 Unterhaltsvorschussgesetz + */ +const mindesteinkommen: Int = { + // Reference: Art. 23 G. v. 14.08.2017 BGBl. I S. 3122. + from 2017-01-01 = 600; +} + +/** + * Altersgrenze, ab der UHV nur mit einem Mindesteinkommen in Höhe von + * `mindesteinkommen` bezogen werden kann. + * Reference: § 1 (1a) Nr. 2 Unterhaltsvorschussgesetz + */ +const altersgrenzeMindesteinkommen: Int = { + // Reference: Art. 23 G. v. 14.08.2017 BGBl. I S. 3122. + from 2017-01-01 = 12; +} + +/** + * Altersgrenzen für den Bezug von Unterhaltsvorschuss + * Kinder, die das 12. Lebensjahr noch nicht vollendet haben und bei einem + * alleinerziehenden Elternteil leben haben Anspruch auf Unterhaltszahlungen. Zudem + * können auch Kinder bis zur Vollendung des 18. Lebensjahres Unterhaltsvorschuss + * bekommen, wenn das Elternteil ein Mindesteinkommen hat. + * Reference: § 1 Abs. 1, 1a UhVorschG + */ +const altersgrenzen: Dict = { + // Reference: § 1 Abs. 1, 1a UhVorschG + from 2017-01-01 = { + 1: 6, + 2: 12, + 3: 18, + }; +} + +// TODO: rounding From e30e893d024318478caada040f79999a6da48404 Mon Sep 17 00:00:00 2001 From: alex-senger Date: Tue, 21 May 2024 14:52:36 +0200 Subject: [PATCH 039/183] feat: implement 2024 changes --- src/resources/builtins/arbeitslosengeld2.ttsl | 10 +++ .../builtins/einkommenssteuerAbzuege.ttsl | 14 ++- src/resources/builtins/erziehungsgeld.ttsl | 11 +-- src/resources/builtins/gesetzlicheRente.ttsl | 88 ++++++++++++------- src/resources/builtins/kinderzuschlag.ttsl | 7 +- .../builtins/sozialversicherungsbeitrag.ttsl | 32 +++++++ src/resources/builtins/unterhalt.ttsl | 7 ++ 7 files changed, 131 insertions(+), 38 deletions(-) diff --git a/src/resources/builtins/arbeitslosengeld2.ttsl b/src/resources/builtins/arbeitslosengeld2.ttsl index abd475a6..f955ae1b 100644 --- a/src/resources/builtins/arbeitslosengeld2.ttsl +++ b/src/resources/builtins/arbeitslosengeld2.ttsl @@ -292,6 +292,16 @@ public const regelsatz: Int | Dict { 5: 348, 6: 318 } + + // Reference: §2 V. v. 24.10.2024 BGBl. I Nr. 287 + from 2024-01-01 = { + 1: 563, + 2: 506, + 3: 451, + 4: 471, + 5: 390, + 6: 357 + } } /** diff --git a/src/resources/builtins/einkommenssteuerAbzuege.ttsl b/src/resources/builtins/einkommenssteuerAbzuege.ttsl index 05cec07a..379bbf57 100644 --- a/src/resources/builtins/einkommenssteuerAbzuege.ttsl +++ b/src/resources/builtins/einkommenssteuerAbzuege.ttsl @@ -9,7 +9,7 @@ pacakge einkommenssteuerAbzuege * veranlagte Paare. §32 (6) EStG, seit 2000. * Pro Jahr */ -const einkommensSteuerKinderFreibetrag: Dict { +const kinderFreibetrag: Dict { // Reference: Art. 1 G. v. 23.12.1982 BGBl. I S. 1857. from 1983-01-01 = { saechlichesExistenzminimum: 110 @@ -117,10 +117,20 @@ const einkommensSteuerKinderFreibetrag: Dict { saechlichesExistenzminimum: 3012 } + 2024-01-01: + deviation_from: previous + sächl_existenzmin: 3306 + reference: >- + Not implemented in law yet, but announced. + https://www.bmfsfj.de/bmfsfj/aktuelles/alle-meldungen/ + spuerbare-verbesserungen-fuer-familien--234802 + // Reference: Art. 3 G. v. 08.12.2022 BGBl. I S. 2230. + // Not implemented in law yet, but announced. https://www.bmfsfj.de/bmfsfj/aktuelles/alle-meldungen/spuerbare-verbesserungen-fuer-familien--234802 from 2024-01-01 = { + // deviation_from: previous beitragErziehungAusbildung: 2730, // previous - saechlichesExistenzminimum: 3192 + saechlichesExistenzminimum: 3306 } } diff --git a/src/resources/builtins/erziehungsgeld.ttsl b/src/resources/builtins/erziehungsgeld.ttsl index 6c3644b5..5caa2dc7 100644 --- a/src/resources/builtins/erziehungsgeld.ttsl +++ b/src/resources/builtins/erziehungsgeld.ttsl @@ -51,13 +51,14 @@ const erziehungsgeldSatz: Dict { } /** + * Abschlagfaktor * Faktor zur Berechnung des Abschlag des Erziehungsgeld bei einer * Überschreitung der Einkommensgrenze ab dem 7 Lebensmonat. * Der Faktor wird mit dem relevanten Einkommen multipliziert und * das Produkt entsprechend vom Erziehungsgeld Anspruch abgezogen * Reference: Bundesgesetzblatt Jahrgang 2004 Teil I Nr. 6 */ -const erziehungsgeldAbschlagFaktor: Float { +const abschlagFaktor: Float { from 2004-02-09 = 0.052 } @@ -66,7 +67,7 @@ const erziehungsgeldAbschlagFaktor: Float { * relevanten Einkommen zu berechnen * Reference: Bundesgesetzblatt Jahrgang 2004 Teil I Nr. 6 § 6 (p.209) */ -const erziehungsgeldPauschalAbzugAufEinkommen: Float { +const pauschalAbzugAufEinkommen: Float { from 2004-02-09 = 0.76 } @@ -74,7 +75,7 @@ const erziehungsgeldPauschalAbzugAufEinkommen: Float { * Grenze der wöchentlichen Arbeitsstunden bis zu der Erziehungsgeld ausgezahlt wird * Reference: Bundesgesetzblatt Jahrgang 2004 Teil I Nr. 6 § 15 (p.211) */ -const erziehungsgeldArbeitsstundenWoechentlicheGrenze: Int { +const arbeitsstundenWoechentlicheGrenze: Int { from 2004-02-09 = 30 } @@ -82,7 +83,7 @@ const erziehungsgeldArbeitsstundenWoechentlicheGrenze: Int { * Alter des Kindes in Monaten bis zu dem der Regelsatz bezogen werden kann. * Reference: Bundesgesetzblatt Jahrgang 2004 Teil I Nr. 6 */ -const erziehungsgeldEndAlterKindRegelsatz: Int { +const endAlterKindRegelsatz: Int { from 2004-01-01 = 24 } @@ -90,7 +91,7 @@ const erziehungsgeldEndAlterKindRegelsatz: Int { * Alter des Kindes in Monaten bis zu dem der Budgetsatz bezogen werden kann. * Reference: Bundesgesetzblatt Jahrgang 2004 Teil I Nr. 6 */ -const erziehungsgeldEndAlterKindBudgetsatz: Int { +const endAlterKindBudgetsatz: Int { from 2004-01-01 = 12 } diff --git a/src/resources/builtins/gesetzlicheRente.ttsl b/src/resources/builtins/gesetzlicheRente.ttsl index 03b80477..75cbb42a 100644 --- a/src/resources/builtins/gesetzlicheRente.ttsl +++ b/src/resources/builtins/gesetzlicheRente.ttsl @@ -7,7 +7,7 @@ package gesetzlicheRente * Verhältnis von Rentnern zu Beitragszahlern modifiziert * Reference: §68 Abs. 4 S. 6 SGB VI */ -const GesetzlicheRenteAlpha: Float { +const alpha: Float { from 1984-01-01 = 0.0 from 2002-01-01 = 0.25 } @@ -16,7 +16,7 @@ const GesetzlicheRenteAlpha: Float { * Teil des Riesterfaktors in der Rentenanpassungsformel * Reference: §68 Abs. 5 SGB VI */ -const gesetzlicheRenteAltersVorsorgeAnteil: Float { +const altersVorsorgeAnteil: Float { from 1993-01-01 = 0.0 from 2002-01-01 = 0.5 from 2003-01-01 = 1.0 @@ -33,7 +33,7 @@ const gesetzlicheRenteAltersVorsorgeAnteil: Float { * Beschäftigten, der geringfügig Beschäftigten und der Bezieher von ALG. * statistik-rente.de/drv */ -const gesetzlicheRenteBeitragsvolumen: Dict { +const beitragsvolumen: Dict { from 1991-01-01 = 108688000 from 1992-01-01 = 117359000 from 1993-01-01 = 120559000 @@ -71,7 +71,7 @@ const gesetzlicheRenteBeitragsvolumen: Dict { * Multiplikation des Rentenwerts mit 45. statistik-rente.de/drv * Reference: § 154 Abs. 3 Satz 1 Nr. 2 SGB VI */ -const gesetzlicheRenteEckrente: Float { +const eckrente: Float { from 1995-01-01 = 988.15 from 1996-01-01 = 992.72 from 1997-01-01 = 1009.1 @@ -102,7 +102,7 @@ const gesetzlicheRenteEckrente: Float { * Durchschnittslohn * Durchschnittsbruttolohn aller Arbeitnehmer:innen in einem Jahr */ -const gesetzlicheRenteDurchschnittslohn: Float { +const durchschnittslohn: Float { from 2005-01-01 = 28468.23 from 2006-01-01 = 28673.22 from 2007-01-01 = 28978.19 @@ -122,7 +122,7 @@ const gesetzlicheRenteDurchschnittslohn: Float { * Durchschnittsentgelt aller Versicherten im Sinne der deutschen Sozialversicherung. * Dieses wird benötigt zur Berechnung der Entgeltpunkte. */ -const gesetzlicheRenteBeitragspflichtigesDurchschnittsentgelt: Int { +const beitragspflichtigesDurchschnittsentgelt: Int { from 2005-01-01 = 29202 from 2006-01-01 = 29494 from 2007-01-01 = 29951 @@ -136,11 +136,29 @@ const gesetzlicheRenteBeitragspflichtigesDurchschnittsentgelt: Int { from 2015-01-01 = 35363 from 2016-01-01 = 36187 from 2017-01-01 = 37077 + + // Reference: V. v. 17.12.2019 BGBl. I S. 2848. from 2018-01-01 = 38212 + + // Reference: V. v. 30.11.2020 BGBl. I S. 2612. from 2019-01-01 = 39301 + + // Reference: §1 V. v. 30.11.2021, BGBl. I S. 5044. from 2020-01-01 = 39167 - from 2021-01-01 = 41541 - from 2022-01-01 = 38901 + + // Reference: §3 V. v. 28.11.2022 BGBl. I S. 2128 (Nr. 47). + from 2021-01-01 = 40463 + + // Reference: §3 V. v. 24.11.2023 BGBl. 2023 I Nr. 322 + from 2022-01-01 = 42053 + + // Reference: §3 V. v. 28.11.2022 BGBl. 2022 I Nr. 2128 + // Vorläufiges Durchschnittsentgelt + from 2023-01-01 = 43142 + + // Reference: §3 V. v. 24.11.2023 BGBl. 2023 I Nr. 322 + // Vorläufiges Durchschnittsentgelt + from 2024-01-01 = 45358 } /** @@ -149,7 +167,7 @@ const gesetzlicheRenteBeitragspflichtigesDurchschnittsentgelt: Int { * diesen Faktor erhöht. * Reference: §256a SGB VI and Anlage 10 SGB VI */ -const gesetzlicheRenteUmrechnungEntgeltpBeitrittsgebiet: Float { +const umrechnungEntgeltpBeitrittsgebiet: Float { from 1945-01-01 = 1.0000 from 1946-01-01 = 1.0000 from 1947-01-01 = 1.0000 @@ -237,7 +255,7 @@ const gesetzlicheRenteUmrechnungEntgeltpBeitrittsgebiet: Float { * Rentenvolumen * Gesamtvolumen der ausgezahlten Renten */ -const gesetzlicheRenteGesamtesRentenvolumen: Int { +const gesamtesRentenvolumen: Int { from 1991-01-01 = 117912000 from 1992-01-01 = 130901000 from 1993-01-01 = 141180000 @@ -275,7 +293,7 @@ const gesetzlicheRenteGesamtesRentenvolumen: Int { * einen Entgeltpunkt entspricht. * Reference: statistik-rente.de/drv, § 68 SGB VI */ -const gesetzlicheRenteRentenwert: Dict { +const rentenwert: Dict { from 1992-01-01 = { west: 21.19, ost: 12.05 @@ -430,6 +448,16 @@ const gesetzlicheRenteRentenwert: Dict { west: 34.19, // deviation_from: previous ost: 33.47 } + + from 2022-07-01 = { + west: 36.02, + ost: 36.52 + } + + from 2023-07-01 = { + west: 37.60, + ost: 37.60 + } } /** @@ -437,7 +465,7 @@ const gesetzlicheRenteRentenwert: Dict { * Konstante zur Bestimmung des Höchstwerts der durchschnittlichen Entgeltpunkte und * des Effekts eines weiteren Monats an Grundrentenzeiten auf Höchstwert. */ -const gesetzlicheRenteGrundrenteHöchstwert: Dict { +const grundrenteHöchstwert: Dict { // Reference: § 76g Abs. 4 S. 3, 4 SGB VI from 2021-01-01 = { base: 0.0334, @@ -450,7 +478,7 @@ const gesetzlicheRenteGrundrenteHöchstwert: Dict { * Der Zugangsfaktor für die Grundrente ist auf 1 begrenzt. * Reference: § 77 Abs. 2 SGB VI */ -const gesetzlicheRenteGrundrenteZugangsfaktorMax: Int { +const grundrenteZugangsfaktorMax: Int { from 2021-01-01 = 1 } @@ -460,7 +488,7 @@ const gesetzlicheRenteGrundrenteZugangsfaktorMax: Int { * an Grundrentenzeiten ab der zusätzliche Monate an Grundrentenzeiten nicht * berücksichtigt werden */ -const gesetzlicheRenteGrundrenteZeiten: Dict { +const grundrenteZeiten: Dict { // Reference: § 76g Abs. 4 S. 5,6 / Abs. 1 S. 1 SGB VI from 2021-01-01 = { min: 396, @@ -474,7 +502,7 @@ const gesetzlicheRenteGrundrenteZeiten: Dict { * Einkommensanrechnung des Grundrentenzuschlags zu ermitteln * Reference: § 97a Abs. 4 S. 2, 4 SGB VI */ -const gesetzlicheRenteGrundrenteEinkommensanrechnungSingle: Dict> { +const grundrenteEinkommensanrechnungSingle: Dict> { // Reference: § 97a Abs. 4 S. 2, 4 SGB VI from 2021-01-01 = { 0: { @@ -500,7 +528,7 @@ const gesetzlicheRenteGrundrenteEinkommensanrechnungSingle: Dict> { +const grundrenteEinkommensanrechnungMarried: Dict> { // Reference: § 97a Abs. 4 S. 2, 4 SGB VI from 2021-01-01 = { 0: { @@ -525,7 +553,7 @@ const gesetzlicheRenteGrundrenteEinkommensanrechnungMarried: Dict { +const zugangsfaktorVeraenderungProJahr: Dict { // Reference: §77 Abs. 2 Nr. 2 SGB VI from 2001-01-01 = { vorzeitiger_renteneintritt: 0.036, @@ -552,7 +580,7 @@ const gesetzlicheRenteZugangsfaktorVeraenderungProJahr: Dict { * höher oder niedriger, wenn keine Ausnahmeregelungen erfüllt sind. * Reference: § 35 Satz 2 SGB VI */ -const gesetzlicheRenteRegelaltersgrenze: Dict> { +const regelaltersgrenze: Dict> { from 1984-01-01 = { 0: { lower_threshold: -inf, @@ -581,7 +609,7 @@ const gesetzlicheRenteRegelaltersgrenze: Dict> { * geboren vor 1952 in Rente gehen konnten. * Reference: § 237a SGB VI */ -const gesetzlicheRenteAltersgrenzeFrauen: Dict> { +const altersgrenzeFrauen: Dict> { from 1980-01-01 = { 0: { lower_threshold: -inf, @@ -623,7 +651,7 @@ const gesetzlicheRenteAltersgrenzeFrauen: Dict> { * (mit Abschlägen). * Reference: § 237a SGB VI */ -const gesetzlicheRenteAltersgrenzeFrauenVorzeitig: Dict> { +const altersgrenzeFrauenVorzeitig: Dict> { from 1980-01-01 = { 0: { lower_threshold: -inf, @@ -647,7 +675,7 @@ const gesetzlicheRenteAltersgrenzeFrauenVorzeitig: Dict * Kohorte, ab der Rente für Frauen abgeschafft. * Reference: § 237a SGB VI */ -const gesetzlicheRenteFirstBirthyearWithoutRenteFrauen: Int { +const firstBirthyearWithoutRenteFrauen: Int { from 1980-01-01 = 1952 } @@ -658,7 +686,7 @@ const gesetzlicheRenteFirstBirthyearWithoutRenteFrauen: Int { * Wert ist als Jahr zu interpretieren. * Reference: § 237a SGB VI */ -const gesetzlicheRenteRenteFrauenPflichtbeitrag: Int { +const renteFrauenPflichtbeitrag: Int { from 1950-01-01 = 10 } @@ -668,7 +696,7 @@ const gesetzlicheRenteRenteFrauenPflichtbeitrag: Int { * bezogen werden kann. * Reference: § 237 SGB VI */ -const gesetzlicheRenteAltersgrenzeArbeitslosigkeitAbschlagsfrei: Float | Dict> { +const altersgrenzeArbeitslosigkeitAbschlagsfrei: Float | Dict> { from 1980-01-01 = { 0: { scalar: 60.0, @@ -1277,7 +1305,7 @@ const gesetzlicheRenteAltersgrenzeArbeitslosigkeitAbschlagsfrei: Float | Dict>{ +const altersgrenzeArbeitslosigkeitVorzeitig: Float | Dict>{ from 1980-01-01 = 60.0 // Increase of early retirement age from 60 to 62 for birth cohort 1949-1952. @@ -1525,7 +1553,7 @@ const gesetzlicheRenteAltersgrenzeArbeitslosigkeitVorzeitig: Float | Dict> { +const altersgrenzeLangjährigVersicherteAbschlagsfrei: Dict> { from 1984-01-01 = { 0: { lower_threshold: -inf, @@ -1582,7 +1610,7 @@ const gesetzlicheRenteAltersgrenzeLangjährigVersicherteAbschlagsfrei: Dict> { +const altersgrenzeBesondersLangjährigVersicherte: Dict> { from 2012-01-01 = { 0: { lower_threshold: -inf, @@ -1643,7 +1671,7 @@ const gesetzlicheRenteAltersgrenzeBesondersLangjährigVersicherte: Dict{ kinder: 336 } kosten_der_unterkunft: { - single: 3684 + single: 3924 paare: 5892 kinder: 1188 } diff --git a/src/resources/builtins/sozialversicherungsbeitrag.ttsl b/src/resources/builtins/sozialversicherungsbeitrag.ttsl index a24bc21e..5c96cdfe 100644 --- a/src/resources/builtins/sozialversicherungsbeitrag.ttsl +++ b/src/resources/builtins/sozialversicherungsbeitrag.ttsl @@ -354,6 +354,14 @@ const beitragssatz: Dict> { meanZusatzbeitrag: 0.016 } } + + // Reference: BAnz AT 31.10.2023 B3 + from 2024-01-01 { + // deviation_from: previous + gesetzlicheKrankenversicherung: { + meanZusatzbeitrag: 0.017 + } + } } /** @@ -788,6 +796,18 @@ const beitragsbemessungsgrenze: Dict> { ost: 7100 } } + + // Reference: V. v. 24.11.2023 BGBl. 2023 I Nr. 322 + from 2024-01-01 { + ges_krankenv: { + west: 5175 + ost: 5175 + } + ges_rentenv: { + west: 7550 + ost: 7450 + } + } } /** @@ -991,6 +1011,12 @@ const monatlicheBezugsgroeße: Dict { west: 3395 ost: 3290 } + + // Reference: V. v. 29.11.2023 BGBl. 2023 I Nr. 322. + from 2024-01-01 { + west: 3535 + ost: 3465 + } } /** @@ -1251,6 +1277,12 @@ const mindestlohn: Float { from 2022-01-01 = 9.82 from 2022-07-01 = 10.45 from 2022-10-01 = 12 + + // Reference: V. v. 24.11.2023 BGBl. 2023 I Nr. 321 + from 2024-01-01 = 12.41 + + // Reference: V. v. 24.11.2023 BGBl. 2023 I Nr. 321 + from 2025-01-01 = 12.82 } // TODO: rounding diff --git a/src/resources/builtins/unterhalt.ttsl b/src/resources/builtins/unterhalt.ttsl index 167fb161..fa8fad44 100644 --- a/src/resources/builtins/unterhalt.ttsl +++ b/src/resources/builtins/unterhalt.ttsl @@ -61,6 +61,13 @@ const mindestunterhalt: Dict { 12: 502, 18: 588 } + + // Reference: Artikel 1 V. v. 29.11.2023 BGBl. I Nr. 330. + from 2024-01-01 = { + 6: 480, + 12: 551, + 18: 645 + } } /** From a3fa77cf70b544f6c0cf235eb6e90fe3cbb057e0 Mon Sep 17 00:00:00 2001 From: alex-senger Date: Tue, 21 May 2024 14:58:16 +0200 Subject: [PATCH 040/183] chore: cleanup --- src/resources/builtins/elterngeld.ttsl | 28 +++--- .../builtins/grundsicherungImAlter.ttsl | 12 +-- .../builtins/solidaritaetszuschlag.ttsl | 96 ------------------- 3 files changed, 20 insertions(+), 116 deletions(-) diff --git a/src/resources/builtins/elterngeld.ttsl b/src/resources/builtins/elterngeld.ttsl index daba589e..7d324bca 100644 --- a/src/resources/builtins/elterngeld.ttsl +++ b/src/resources/builtins/elterngeld.ttsl @@ -6,7 +6,7 @@ package elterngeld * Faktor bei der ElG-Berechung, 2. Stufe * § 2 (1) BEEG */ -const elterngeldFaktor: Float { +const faktor: Float { from 2007-01-01 = 0.67 } @@ -14,7 +14,7 @@ const elterngeldFaktor: Float { * Höchstbetrag des Elterngeldes * § 2 (1) BEEG */ -const elterngeldHoechstbetrag: Int { +const hoechstbetrag: Int { from 2007-01-01 = 1800 } @@ -23,7 +23,7 @@ const elterngeldHoechstbetrag: Int { * § 2 (2) BEEG. Maßgeblich ist das durchschnittlich erzielte monatliche Einkommen * vor der Geburt */ -const elterngeldNettoeinkommenStufen: Dict { +const nettoeinkommenStufen: Dict { // Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 from 2007-01-01 = { 1: 1000, @@ -41,7 +41,7 @@ const elterngeldNettoeinkommenStufen: Dict { * Mindestbetrag des Elterngeldes * § 2 (5) BEEG */ -const elterngeldMindestbetrag: Int { +const mindestbetrag: Int { // Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 from 2007-01-01 = 300 } @@ -50,7 +50,7 @@ const elterngeldMindestbetrag: Int { * Korrektur des Prozentsatzes für hohe und niedrige Einkommen * § 2 (2) BEEG */ -const elterngeldProzentKorrektur: Float { +const prozentKorrektur: Float { // Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 from 2007-01-01 = 0.001 } @@ -59,7 +59,7 @@ const elterngeldProzentKorrektur: Float { * Minimaler Anteil des Elterngelds am vorherigen Nettoeinkommen * § 2 (2) BEEG */ -const elterngeldProzentMinimum: Float { +const prozentMinimum: Float { from 2007-01-01 = 0.67 // Reference: Art. 14 G. v. 09.12.2010 BGBl. I S. 1885 @@ -70,7 +70,7 @@ const elterngeldProzentMinimum: Float { * Einkommensschritte für die Korrektur * § 2 (2) BEEG */ -const elterngeldEinkommensSchrittKorrektur: Int { +const einkommensSchrittKorrektur: Int { // Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 from 2007-01-01 = 2 } @@ -81,7 +81,7 @@ const elterngeldEinkommensSchrittKorrektur: Int { * wird das Elterngeld um 10% (max. um 75€) erhöht. * Reference: § 2a BEEG */ -const elterngeldGeschwisterbonusAltersgrenzenKinder: Dict { +const geschwisterbonusAltersgrenzenKinder: Dict { from 2007-01-01 = { 3: 2, 6: 3 @@ -92,7 +92,7 @@ const elterngeldGeschwisterbonusAltersgrenzenKinder: Dict { * Geschwisterbonus als prozentualer Aufschlag * § 2a (1) BEEG. Früher § 2 (4) BEEG */ -const elterngeldGeschwisterbonusAufschlag: Float { +const geschwisterbonusAufschlag: Float { // Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 from 2007-01-01 = 0.1 } @@ -101,7 +101,7 @@ const elterngeldGeschwisterbonusAufschlag: Float { * Minimaler Geschwisterbonus als Euro-Betrag * § 2a (1) BEEG. Früher §2 (4) BEEG */ -const elterngeldGeschwisterbonusMinimum: Int { +const geschwisterbonusMinimum: Int { // Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 from 2007-01-01 = 75 } @@ -111,7 +111,7 @@ const elterngeldGeschwisterbonusMinimum: Int { * § 2a (4) BEEG, früher §2 (6) BEEG. * pro Monat */ -const elterngeldMehrlingbonus: Int { +const mehrlingbonus: Int { // Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 from 2007-01-01 = 300 } @@ -120,7 +120,7 @@ const elterngeldMehrlingbonus: Int { * Sozialversicherungspauschale zur Berechnung des Nettoeinkommens * §2f BEEG. Vor 2012 waren es die eigentlichen Pflichtbeiträge. */ -const elterngeldSozialversicherungspauschale: Float { +const sozialversicherungspauschale: Float { // Reference: Art. 1 G. v. 10.09.2012 BGBl. I S. 1878 from 2012-09-18 = 0.21 } @@ -129,7 +129,7 @@ const elterngeldSozialversicherungspauschale: Float { * Maximale Anzahl an Monaten, in denen ein Paar Elterngeld erhält * § 4 (3) BEEG */ -const elterngeldMaxMonatePaar: Int { +const maxMonatePaar: Int { // Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 from 2007-01-01 = 14 } @@ -138,7 +138,7 @@ const elterngeldMaxMonatePaar: Int { * Maximale Anzahl an Monaten, die jedes Elternteil Elterngeld erhält * § 4 (3) BEEG */ -const elterngeldMaxMonateIndividuell: Int { +const maxMonateIndividuell: Int { // Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 from 2007-01-01 = 12 } diff --git a/src/resources/builtins/grundsicherungImAlter.ttsl b/src/resources/builtins/grundsicherungImAlter.ttsl index 5d50a934..c67be95d 100644 --- a/src/resources/builtins/grundsicherungImAlter.ttsl +++ b/src/resources/builtins/grundsicherungImAlter.ttsl @@ -9,7 +9,7 @@ package grundsicherungImAlter * Reference: § 1 Verordnung zur Durchführung des § 90 Abs. 2 Nr. 9 des Zwölften Buches * Sozialgesetzbuch */ -const grundsicherungImAlterVermoegensfreibetrag: Dict { +const vermoegensfreibetrag: Dict { from 1984-01-01: { adult: 0, child: 0, @@ -29,7 +29,7 @@ const grundsicherungImAlterVermoegensfreibetrag: Dict { * Anrechnungsfreie Anteile staatliche Rente wenn mindestens 33 Jahre * Grundrentenzeiten erreicht wurden. */ -const grundsicherungImAlterGesetzlicheRenteAnrechnungsfrei: Dict> { +const gesetzlicheRenteAnrechnungsfrei: Dict> { from 1984-01-01: { 0: { lower_threshold: -inf, @@ -62,7 +62,7 @@ const grundsicherungImAlterGesetzlicheRenteAnrechnungsfrei: Dict> { +const privateRenteAnrechnungsfrei: Dict> { from 1984-01-01: { // Unclear how it was handled before 2005, 0: { @@ -124,6 +124,6 @@ const grundsicherungImAlterPrivateRenteAnrechnungsfrei: Dict- - Ab 1995, der upper threshold im Intervall 1 ist nach der Formel - transition_threshold in soli_st.py berechnet. - en: null - type: piecewise_linear - 1991-01-01: - reference: Artikel 1 G. v. 24.06.1991 BGBl. I S. 1318. - 0: - lower_threshold: -inf - rate: 0 - intercept_at_lower_threshold: 0 - upper_threshold: 0 - 1: - lower_threshold: 0 - rate: 0.0375 - upper_threshold: inf - 1993-01-01: - 0: - lower_threshold: -inf - rate: 0 - intercept_at_lower_threshold: 0 - upper_threshold: inf - 1995-01-01: - reference: Artikel 31 G. v. 23.06.1993 BGBl. I S. 944. - 0: - lower_threshold: -inf - intercept_at_lower_threshold: 0 - rate: 0 - upper_threshold: 681 - 1: - upper_threshold: 1089.6 - rate: 0.2 - 2: - rate: 0.075 - upper_threshold: inf - 1998-01-01: - reference: Artikel 1 G. v. 21.11.1997 BGBl. I S. 2743. - 0: - lower_threshold: -inf - upper_threshold: 939 - rate: 0 - intercept_at_lower_threshold: 0 - 1: - upper_threshold: 1295.17 - rate: 0.2 - 2: - rate: 0.055 - upper_threshold: inf - 2002-01-01: - reference: G. v. 15.10.2002 BGBl. I S. 4131. - 0: - lower_threshold: -inf - upper_threshold: 972 - rate: 0 - intercept_at_lower_threshold: 0 - 1: - upper_threshold: 1340.69 - rate: 0.2 - 2: - rate: 0.055 - upper_threshold: inf - 2021-01-01: - reference: Artikel 1 G. v. 10.12.2019 BGBl. I S. 2115. - 0: - lower_threshold: -inf - upper_threshold: 16956 - rate: 0 - intercept_at_lower_threshold: 0 - 1: - upper_threshold: 31527.56 - rate: 0.119 - 2: - rate: 0.055 - upper_threshold: inf - 2023-01-01: - reference: Art. 4 G. v. 08.12.2022 BGBl. I S. 2230. - deviation_from: previous - 0: - upper_threshold: 17543 - 1: - upper_threshold: 32619.02 - 2024-01-01: - reference: Art. 5 G. v. 08.12.2022 BGBl. I S. 2230. - deviation_from: previous - 0: - upper_threshold: 18130 - 1: - upper_threshold: 33710.47 - - package solidaritaetszuschlag /** From d4ed9c3bbf1044457564cf5786c7c7fe612d8a41 Mon Sep 17 00:00:00 2001 From: methr0 Date: Wed, 22 May 2024 10:22:07 +0200 Subject: [PATCH 041/183] fix generate function parameter, fix generate constant, update constant utility function --- .../generation/safe-ds-python-generator.ts | 51 ++++++++++++++----- 1 file changed, 38 insertions(+), 13 deletions(-) diff --git a/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts b/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts index 22fc5f42..dd62dbd4 100644 --- a/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts +++ b/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts @@ -81,6 +81,7 @@ import { TslTimespan, isTslData, TslData, + isTslBlock, } from '../generated/ast.js'; import { isInStubFile, isStubFile } from '../helpers/fileExtensions.js'; import { IdManager } from '../helpers/idManager.js'; @@ -221,16 +222,37 @@ const UTILITY_CONSTANTS: UtilityFunction = { .append('def getValue(self, date):').appendNewLine() .indent(indentingNode => indentingNode.append( - 'for key in self.dict:' + 'keys = sorted(self.dict.keys())' + ).appendNewLine().append( + 'if(keys[0] == "empty"):' + ).appendNewLine().indent(indentingNode => + indentingNode.append( + 'return self.dict["empty"]' + )).appendNewLine() + .append( + 'for index, key in enumerate(keys):' ).appendNewLine() .indent(indentingNode => indentingNode.append( - 'if key <= date:' + 'if key[0] <= "s"' ).appendNewLine() - .indent({ - indentedChildren: ['result = self.dict[key]'], - indentation: PYTHON_INDENT - })).appendNewLine() + .indent(indentingNode => + indentingNode.append( + 'if key.replace("s", "") <= date:' + ).appendNewLine() + .indent(indentingNode => + indentingNode.append( + 'result = self.dict[key]' + )).appendNewLine() + .append('if key[0] == "e":').appendNewLine() + .indent(indentingNode => + indentingNode.append( + 'if date <= keys[len(keys)-1-index].replace("e",""):' + ).appendNewLine() + .indent(indentingNode => + indentingNode.append( + 'result = self.dict[keys[len(keys)-1-index]]' + ).appendNewLine())))) .append('return result'))), imports: [{ importPath: 'typing', declarationName: 'Any' }], typeVariables: [`${CODEGEN_PREFIX}T`], @@ -544,7 +566,7 @@ export class SafeDsPythonGenerator { return expandTracedToNode(funct)`def ${traceToNode( funct, 'name', - )(this.getPythonNameOrDefault(funct))}(${funct.timeunit}, ${funct.groupedBy}, date, ${funct.parameterList}):` + )(this.getPythonNameOrDefault(funct))}(timeunit, groupedBy, date`.appendIf(funct.parameterList?.parameters.length !== 0,`, ${this.generateParameters(funct.parameterList, infoFrame)}`).append(`):`) .appendNewLine() .indent({ indentedChildren: [this.generateFunctionBlock(funct.body, infoFrame)], indentation: PYTHON_INDENT }); } @@ -605,7 +627,7 @@ export class SafeDsPythonGenerator { )(this.generateExpression(entry.value, infoFrame))}`, { separator: ', ' }, )}}`.appendNewLine() - .append(expandTracedToNode(constant)`${traceToNode( + .append(expandTracedToNode(constant)`${constant.name} = ${traceToNode( constant )(UTILITY_CONSTANTS.name)}(${constant.name}Dict)`) } else{ @@ -856,12 +878,15 @@ export class SafeDsPythonGenerator { ${this.generateFunctionBlock(statement.block, frame)}`; } else if (isTslConditionalStatement(statement)) { let elseBlock = new CompositeGeneratorNode - if (statement.elseBlock){ - elseBlock = this.generateBlock((statement.elseBlock), frame, false) + if (isTslBlock(statement.elseBlock)){ + let generatedBlock = this.generateBlock((statement.elseBlock), frame, false) + elseBlock = expandTracedToNode(statement.elseBlock)`else:`.appendNewLine().indent(indentingNode => + indentingNode.append(`${generatedBlock}`)) } - return expandTracedToNode(statement)`if ${this.generateExpression((statement.expression), frame)}: - ${this.generateBlock((statement.ifBlock), frame)} - else: ${elseBlock}`; + return expandTracedToNode(statement)`if ${this.generateExpression((statement.expression), frame)}:` + .appendNewLine().indent(indentingNode => + indentingNode.append(`${this.generateBlock((statement.ifBlock), frame)}`)) + .appendNewLine().append(elseBlock); } else if (isTslLoop(statement)) { if (isTslWhileLoop(statement)){ return expandTracedToNode(statement)`while ${this.generateExpression((statement.condition), frame)}: From f6094c457e0909352e942ae77fc666aa7396c894 Mon Sep 17 00:00:00 2001 From: Alex Senger Date: Wed, 22 May 2024 11:32:57 +0200 Subject: [PATCH 042/183] feat: add wohngeld.ttsl --- src/resources/builtins/wohngeld.ttsl | 2312 ++++++++++++++++++++++++++ 1 file changed, 2312 insertions(+) create mode 100644 src/resources/builtins/wohngeld.ttsl diff --git a/src/resources/builtins/wohngeld.ttsl b/src/resources/builtins/wohngeld.ttsl new file mode 100644 index 00000000..70938878 --- /dev/null +++ b/src/resources/builtins/wohngeld.ttsl @@ -0,0 +1,2312 @@ +package wohngeld + +/** + * Faktor am Anfang der Wohngeldformel + * Anlage 2 WoGG zu §19 Abs. 2 WoGG + */ +const faktorBerechnungsformel: Float { + from 1984-01-01 = 1 + + // Reference: Art. 1 G. v. 24.09 2008 BGBl. I S. 1856 + from 2009-01-01 = 1.08 + + // Reference: Art. 1 G. v. 08.10.2015 BGBl 38 S.1610 + from 2016-01-01 = 1.15 +} + +/** + * Parameter a, b, c der Wohngeldformel + * WoGG - Anlage 2 (bis 2019 Anlage 1) (zu § 19 (1)). Seit 2022 auch §24 + * Wohngeldverordnung (WoGV). + * The keys from 1 to 12 below refer to the household size. + */ +const koeffizientenBerechnungsformel: Dict> { + // Parameter aus Regressionsanalyse der Wohngeldtabellen + from 1984-01-01 = { + 1: { + a: 0.0532, + b: 0.00135, + c: 0.0000632 + }, + 2: { + a: 0.0574, + b: 0.000957, + c: 0.0000352 + }, + 3: { + a: 0.0612, + b: 0.00078, + c: 0.0000202 + }, + 4: { + a: 0.0596, + b: 0.000613, + c: 2.78e-06 + }, + 5: { + a: 0.0572, + b: 0.000554, + c: 5.38e-07 + }, + 6: { + a: 0.0365, + b: 0.000531, + c: 4.62e-06 + }, + 7: { + a: 0.0129, + b: 0.000502, + c: 0.0000124 + }, + 8: { + a: -0.0176, + b: 0.000468, + c: 0.0000253 + }, + 9: { + a: -0.0397, + b: 0.000424, + c: 0.0000364 + }, + 10: { + a: -0.0595, + b: 0.000373, + c: 0.0000481 + }, + 11: { + a: -0.0595, + b: 0.000373, + c: 0.0000481 + }, + 12: { + a: -0.0595, + b: 0.000373, + c: 0.0000481 + } + } + + // Parameter aus Regressionsanalyse der Wohngeldtabellen + from 1990-01-01 = { + 1: { + a: 0.0648, + b: 0.00102, + c: 0.0000613 + }, + 2: { + a: 0.0694, + b: 0.000715, + c: 0.0000347 + }, + 3: { + a: 0.0741, + b: 0.000604, + c: 0.000011 + }, + 4: { + a: 0.0669, + b: 0.000476, + c: 1.75e-06 + }, + 5: { + a: 0.064, + b: 0.00043, + c: 9.14e-07 + }, + 6: { + a: 0.0445, + b: 0.000414, + c: 4.02e-06 + }, + 7: { + a: 0.0226, + b: 0.000397, + c: 9.44e-06 + }, + 8: { + a: -0.0005, + b: 0.000387, + c: 0.0000136 + }, + 9: { + a: -0.0281, + b: 0.000337, + c: 0.0000308 + }, + 10: { + a: -0.0455, + b: 0.000298, + c: 0.0000386 + }, + 11: { + a: -0.0455, + b: 0.000298, + c: 0.0000386 + }, + 12: { + a: -0.0455, + b: 0.000298, + c: 0.0000386 + } + } + + // Parameter aus Regressionsanalyse der Wohngeldtabellen + from 1992-01-01 = { + 1: { + a: 0.0666, + b: 0.00102, + c: 0.0000579 + }, + 2: { + a: 0.0716, + b: 0.000713, + c: 0.0000317 + }, + 3: { + a: 0.0748, + b: 0.000604, + c: 0.0000102 + }, + 4: { + a: 0.0671, + b: 0.000475, + c: 1.63e-06 + }, + 5: { + a: 0.0642, + b: 0.00043, + c: 8.96e-07 + }, + 6: { + a: 0.0463, + b: 0.000419, + c: 1.35e-06 + }, + 7: { + a: 0.0256, + b: 0.000404, + c: 5.66e-06 + }, + 8: { + a: -0.00252, + b: 0.000377, + c: 0.0000173 + }, + 9: { + a: -0.00252, + b: 0.000377, + c: 0.0000173 + }, + 10: { + a: -0.00252, + b: 0.000377, + c: 0.0000173 + }, + 11: { + a: -0.00252, + b: 0.000377, + c: 0.0000173 + }, + 12: { + a: -0.00252, + b: 0.000377, + c: 0.0000173 + } + } + + // Reference: Art. 5 G. v. 22.12.1999 BGBl. I S. 2671 + from 2001-01-01 = { + 1: { + a: 0.063, + b: 0.000796, + c: 0.00009102 + }, + 2: { + a: 0.057, + b: 0.000576, + c: 0.00006431 + }, + 3: { + a: 0.055, + b: 0.000518, + c: 0.0000325 + }, + 4: { + a: 0.047, + b: 0.000395, + c: 0.00002325 + }, + 5: { + a: 0.042, + b: 0.000348, + c: 0.00002151 + }, + 6: { + a: 0.037, + b: 0.000327, + c: 0.00001519 + }, + 7: { + a: 0.033, + b: 0.000313, + c: 8.745e-06 + }, + 8: { + a: 0.023, + b: 0.000296, + c: 7.44e-06 + }, + 9: { + a: -0.017, + b: 0.000225, + c: 0.00003522 + }, + 10: { + a: -0.037, + b: 0.000157, + c: 0.00005547 + }, + 11: { + a: -0.067, + b: 0.000153, + c: 0.00005686 + }, + 12: { + a: -0.092, + b: 0.000136, + c: 0.00006182 + } + } + + // Reference: Art. 1 G. v. 24.09 2008 BGBl. I S. 1856 + from 2009-01-01 = { + 1: { + a: 0.063, + b: 0.0007963, + c: 0.00009102 + }, + 2: { + a: 0.057, + b: 0.0005761, + c: 0.00006431 + }, + 3: { + a: 0.055, + b: 0.0005176, + c: 0.0000325 + }, + 4: { + a: 0.047, + b: 0.0003945, + c: 0.00002325 + }, + 5: { + a: 0.042, + b: 0.0003483, + c: 0.00002151 + }, + 6: { + a: 0.037, + b: 0.0003269, + c: 0.00001519 + }, + 7: { + a: 0.033, + b: 0.0003129, + c: 8.745e-06 + }, + 8: { + a: 0.023, + b: 0.0002959, + c: 7.44e-06 + }, + 9: { + a: -0.0197, + b: 0.0002245, + c: 0.00003459 + }, + 10: { + a: -0.0401, + b: 0.0001565, + c: 0.0000514 + }, + 11: { + a: -0.066, + b: 0.00012, + c: 0.00005686 + }, + 12: { + a: -0.0899, + b: 0.000109, + c: 0.00006182 + } + } + + // Reference: Art. 1 G. v. 08.10.2015 BGBl 38 S.1610 + from 2016-01-01 = { + 1: { + a: 0.04, + b: 0.00063, + c: 0.000138 + }, + 2: { + a: 0.03, + b: 0.00044, + c: 0.000103 + }, + 3: { + a: 0.02, + b: 0.00038, + c: 0.000083 + }, + 4: { + a: 0.01, + b: 0.00034, + c: 0.000043 + }, + 5: { + a: 0, + b: 0.0003, + c: 0.000042 + }, + 6: { + a: -0.01, + b: 0.00028, + c: 0.000036 + }, + 7: { + a: -0.02, + b: 0.00026, + c: 0.000037 + }, + 8: { + a: -0.03, + b: 0.00023, + c: 0.000037 + }, + 9: { + a: -0.04, + b: 0.0002, + c: 0.000039 + }, + 10: { + a: -0.06, + b: 0.00016, + c: 0.000045 + }, + 11: { + a: -0.1, + b: 0.00012, + c: 0.000053 + }, + 12: { + a: -0.14, + b: 0.00011, + c: 0.00006 + } + } + + // Reference: Art. 1 G. v. 30.11.2019 BGBl. I S. 1877 + from 2020-01-01 = { + 1: { + a: 0.04, + b: 0.00058, + c: 0.000118 + }, + 2: { + a: 0.03, + b: 0.000405, + c: 0.000088 + }, + 3: { + a: 0.02, + b: 0.00035, + c: 0.0000709 + }, + 4: { + a: 0.01, + b: 0.000313, + c: 0.0000368 + }, + 5: { + a: 0, + b: 0.000276, + c: 0.0000359 + }, + 6: { + a: -0.01, + b: 0.000258, + c: 0.0000308 + }, + 7: { + a: -0.02, + b: 0.000239, + c: 0.0000316 + }, + 8: { + a: -0.03, + b: 0.000212, + c: 0.0000316 + }, + 9: { + a: -0.04, + b: 0.000184, + c: 0.0000333 + }, + 10: { + a: -0.06, + b: 0.000147, + c: 0.0000385 + }, + 11: { + a: -0.1, + b: 0.00011, + c: 0.0000453 + }, + 12: { + a: -0.14, + b: 0.000101, + c: 0.0000513 + } + } + + // Reference: V. v. 03.06.2021 BGBl. I S. 1369. + from 2022-01-01 = { + 1: { + a: 0.04, + b: 0.000564, + c: 0.0001157 + }, + 2: { + a: 0.03, + b: 0.000394, + c: 0.0000863 + }, + 3: { + a: 0.02, + b: 0.00034, + c: 0.0000695 + }, + 4: { + a: 0.01, + b: 0.000304, + c: 0.0000361 + }, + 5: { + a: 0, + b: 0.000268, + c: 0.0000352 + }, + 6: { + a: -0.01, + b: 0.000251, + c: 0.0000302 + }, + 7: { + a: -0.02, + b: 0.000232, + c: 0.000031 + }, + 8: { + a: -0.03, + b: 0.000206, + c: 0.000031 + }, + 9: { + a: -0.04, + b: 0.000179, + c: 0.0000326 + }, + 10: { + a: -0.06, + b: 0.000143, + c: 0.0000377 + }, + 11: { + a: -0.1, + b: 0.000107, + c: 0.0000444 + }, + 12: { + a: -0.14, + b: 0.000098, + c: 0.0000503 + } + } + + // Reference: Art. 1 G. v. 08.12.2022 BGBl. I Nr. 48 S. 2160 + from 2023-01-01 = { + 1: { + a: 0.04, + b: 0.0004991, + c: 0.0000462 + }, + 2: { + a: 0.03, + b: 0.0003716, + c: 0.0000345 + }, + 3: { + a: 0.02, + b: 0.0003035, + c: 0.0000278 + }, + 4: { + a: 0.01, + b: 0.0002251, + c: 0.00002 + }, + 5: { + a: 0, + b: 0.0001985, + c: 0.0000195 + }, + 6: { + a: -0.01, + b: 0.0001792, + c: 0.0000188 + }, + 7: { + a: -0.02, + b: 0.0001657, + c: 0.0000187 + }, + 8: { + a: -0.03, + b: 0.0001648, + c: 0.0000187 + }, + 9: { + a: -0.04, + b: 0.0001432, + c: 0.0000188 + }, + 10: { + a: -0.06, + b: 0.00013, + c: 0.0000188 + }, + 11: { + a: -0.09, + b: 0.0001188, + c: 0.0000222 + }, + 12: { + a: -0.12, + b: 0.0001152, + c: 0.0000251 + } + } +} + +/** + * Zusätzlicher Betrag für große Haushalte + * Haushalte mit mehr als 12 Personen erhalten einen zusätzlichen Betrag pro Person, + * der auf das Wohngeld für einen Haushalt mit 12 Personen angerechnet wird. + * Reference: §19 Abs. 3 WoGG + */ +const bonusSehrGrosseHaushalte: Dict { + // Reference: Art. 5 G. v. 22.12.1999 BGBl. I S. 2671 + from 2001-01-01 = { + max_anz_personen_normale_berechnung: 12, + bonus_jede_weitere_person: 40 + } + + // Reference: Art. 1 G. v. 24.09 2008 BGBl. I S. 1856 + from 2009-01-01 = { + // deviation_from: previous + bonus_jede_weitere_person: 43 + } + + // Reference: Art. 1 G. v. 08.10.2015 BGBl 38 S.1610 + from 2016-01-01 = { + // deviation_from: previous + bonus_jede_weitere_person: 47 + } + + // Reference: Art. 1 G. v. 30.11.2019 BGBl. I S. 1877 + from 2020-01-01 = { + // deviation_from: previous + bonus_jede_weitere_person: 51 + } + + // Reference: Art. 1 G. v. 08.12.2022 BGBl. I Nr. 48 S. 2160 + from 2023-01-01 = { + // deviation_from: previous + bonus_jede_weitere_person: 57 + } +} + +/** + * Prozentualer Pauschalabzug vom Bruttoeinkommen, falls 0, 1, 2, 3 Kriterien erfüllt + * sind + * § 16 (1, 2) WoGG + * Kriterien sind - entrichtete Steuern - entrichtete GKV- und GPV-Beiträge - + * entrichtete GRV-Beiträge + */ +const abzugStufen: Dict { + from 1984-01-01 = { + 0: 0.06, + 1: 0.125, + 2: 0.2, + 3: 0.3 + } + + from 1991-01-01 = { + // deviation_from: previous + 3: 0.26 + } + + from 2002-01-01 = { + // deviation_from: previous + 1: 0.1, + 3: 0.3 + } + + // Reference: Art. G. v. 02.10.2015 BGBl I S. 1610 + from 2016-01-01 = { + // deviation_from: previous + 0: 0.0 + } +} + +/** + * Minimalwert für Parameter M + * WoGG - Anlage 3 (bis 2019 Anlage 2) (zu § 19 Abs. 2) + */ +const minMiete: Dict { + from 1984-01-01 = { + 1: 0, + 2: 0, + 3: 0, + 4: 0, + 5: 0, + 6: 0, + 7: 0, + 8: 0, + 9: 0, + 10: 0, + 11: 0, + 12: 0 + } + + from 2001-01-01 = { + 1: 22.5, + 2: 22.5, + 3: 27.5, + 4: 32.5, + 5: 32.5, + 6: 32.5, + 7: 35, + 8: 35, + 9: 37.5, + 10: 37.5, + 11: 75, + 12: 155 + } + + from 2009-01-01 = { + 1: 45, + 2: 55, + 3: 65, + 4: 75, + 5: 85, + 6: 85, + 7: 95, + 8: 105, + 9: 115, + 10: 125, + 11: 155, + 12: 245, + } + + // Reference: Art. 1 G. v. 08.10.2015 BGBl Nr.38, S.1617 + from 2016-01-01 = { + 1: 48, + 2: 59, + 3: 70, + 4: 81, + 5: 91, + 6: 91, + 7: 102, + 8: 113, + 9: 124, + 10: 134, + 11: 155, + 12: 263 + } + + // Reference: Art. 1 G. v. 30.11.2019 BGBl. I S. 1877 + from 2020-01-01 = { + 1: 52, + 2: 64, + 3: 76, + 4: 88, + 5: 99, + 6: 99, + 7: 111, + 8: 123, + 9: 135, + 10: 146, + 11: 180, + 12: 286 + } +} + +/** + * Minimalwert für Parameter Y + * WoGG - Anlage 3 (bis 2019 Anlage 2) (zu § 19 Abs. 2) + */ +const minEink: Dict { + from 1984-01-01 = { + 1: 0, + 2: 0, + 3: 0, + 4: 0, + 5: 0 + 6: 0, + 7: 0, + 8: 0, + 9: 0, + 10: 0, + 11: 0, + 12: 0 + } + + from 2001-01-01 = { + 1: 120, + 2: 150, + 3: 200, + 4: 250, + 5: 285, + 6: 320, + 7: 355, + 8: 385, + 9: 555, + 10: 730, + 11: 1000, + 12: 1175 + } + + from 2009-01-01 = { + 1: 205, + 2: 245, + 3: 265, + 4: 315, + 5: 345, + 6: 365, + 7: 385, + 8: 415, + 9: 585, + 10: 805, + 11: 1085, + 12: 1255 + } + + // Reference: Art. 1 G. v. 08.10.2015 BGBl Nr.38, S.1617 + from 2016-01-01 = { + 1: 239, + 2: 310, + 3: 360, + 4: 389, + 5: 463, + 6: 537, + 7: 610, + 8: 684, + 9: 758, + 10: 832, + 11: 1085, + 12: 1255 + } + + // reference: Art. 1 G. v. 30.11.2019 BGBl. I S. 1877 + from 2020-01-01 = { + 1: 275, + 2: 357, + 3: 414, + 4: 447, + 5: 532, + 6: 618, + 7: 702 + 8: 787, + 9: 872, + 10: 957, + 11: 1248, + 12: 1443 + } + + // Reference: Art. 1 G. v. 08.12.2022 BGBl. I Nr. 48 S. 2160 + from 2023-01-01 = { + 1: 350, + 2: 600, + 3: 800, + 4: 1000 + 5: 1200, + 6: 1400, + 7: 1600, + 8: 1800, + 9: 2000, + 10: 2200, + 11: 2400, + 12: 2600 + } +} + +/** + * Monatlicher Freibetrag für Alleinerziehende und arbeitende Kinder + * § 17 (4/5) WoGG + */ +const freibetragKinder: Dict { + from 1984-01-01 = { + alleinerz: 51, + arbeitendes_kind: 0 + } + + from 2001-01-01 = { + // deviation_from: previous + arbeitendes_kind: 51 + } + + from 2002-01-01 = { + alleinerz: 50, + arbeitendes_kind: 50 + } + + // Reference: Art. 1 G. v. 08.10.2015 BGBl Nr.38, S.1617 + // Neu §17 3. WoGG a) Alleinerziehend b) Kind unter 18 und neu §17 4. WoGG Kind noch nicht 25J. + from 2016-01-01 = { + alleinerz: 110, + arbeitendes_kind: 100 + } +} + +/** + * Jährlicher Freibetrag pro behindertes Haushaltsmitglied + * Der Betrag ist abhängig vom Behinderungsgrad der jeweiligen Person. Vor 2016 ist + * der Betrag unterschiedlich für Personen mit Behinderungsgrad über bzw unter 80%. + * Für Menschen mit Behinderungsgrad unter 100% muss zusätzlich Pflegebedürftigkeit + * gem. §14 SGB XI. und gleichzeitig Häusliche/teilstationäre/Kurzzeit-Pflege + * vorliegen. Dies ist aktuell nicht implementiert. § 17 Nr. 1 WoGG. (früher § 17 (2) + * WoGG) + */ +const freibetragBehinderung: Dict | Int { + from 1984-01-01 = { + 0: 0, + 1: 0, + 80: 1224 + } + + from 1986-01-01 = { + // deviation_from: previous + 80: 612 + } + + from 1991-01-01 = { + 0: 0, + 1: 1224, + 80: 1536 + } + + from 2002-01-01 = { + 0: 0, + 1: 1200, + 80: 1500 + } + + // Reference: 2 Art. 1 G. v. 08.10.2015 BGBl Nr.38 S.1612 + // neue Regelung - §17 1. WoGG a) GDB = 100 b) GDB < 100 & pflegebedürftig gem. §14 SGB XI. + gleichz. Häusliche/teilstationäre/Kurzzeit-Pflege + from 2016-01-01 = 1500 + + // Reference: Art. 1 G. v. 30.11.2019 BGBl. I S. 1877 + from 2020-01-01 = 1800 +} +// TODO: DEVIATION FROM BEISPIEL!!! + +/** + * Behinderungsgrad für Freibetrag + * Ein Wohngeld-Freibetrag wird Menschen mit Behinderung gewährt. Dabei hängt die + * Höhe des Freibetrages vom Behinderungsgrad ab. + * Reference: § 17 Abs. 1 WoGG + * in percent + */ +const behinderungsgrad: Dict { + from 1984-01-01 = { + 1: 0, + 2: 80 + } +} + +/** + * Höchstbeträge für Miete und Belastung + * Anlage 1 WoGG, bis 2019 §12 (1) WoGG. Vor 2009 §8 (1) WoGG. Seit 2022 auch §24 + * Wohngeldverordnung (WoGV). + * Die Werte sind nach Anzahl Personen - maximales Baujahr des Hauses (vor 2009) - + * Mietstufe geordnet. Alle Werte in vollen Euro. + */ +const maxMiete: Dit>> { + // Reference: Art. 1 G. v. 04.08.1980 BGBl I S. 1159. + // Bis 1985 nur drei Mietstufen, streng abhängig von der Größe der Gemeinde. Es wird "Wohnung mit Sammelheizung und mit Bad oder Duschraum" angenommen. + from 1981-01-01 = { + 1: { + 1965: { + 1: 130, + 2: 135, + 3: 143 + }, + 1971: { + 1: 148, + 2: 153, + 3: 161 + }, + 1977: { + 1: 161, + 2: 166, + 3: 174 + }, + 2009: { + 1: 169, + 2: 179, + 3: 189 + } + }, + 2: { + 1965: { + 1: 164, + 2: 171, + 3: 182 + }, + 1971: { + 1: 189, + 2: 197, + 3: 207 + }, + 1977: { + 1: 210, + 2: 217, + 3: 228 + }, + 2009: { + 1: 225, + 2: 235, + 3: 245 + } + }, + 3: { + 1965: { + 1: 199, + 2: 207, + 3: 215 + }, + 1971: { + 1: 233, + 2: 240, + 3: 251 + }, + 1977: { + 1: 256, + 2: 263, + 3: 274 + }, + 2009: { + 1: 276, + 2: 286, + 3: 297 + } + }, + 4: { + 1965: { + 1: 235, + 2: 245, + 3: 258 + }, + 1971: { + 1: 266, + 2: 276, + 3: 289 + }, + 1977: { + 1: 294, + 2: 304, + 3: 317 + }, + 2009: { + 1: 320, + 2: 332, + 3: 345 + } + }, + 5: { + 1965: { + 1: 268, + 2: 281, + 3: 294 + }, + 1971: { + 1: 304, + 2: 314, + 3: 330 + }, + 1977: { + 1: 335, + 2: 348, + 3: 363 + }, + 2009: { + 1: 366, + 2: 378, + 3: 394 + }, + }, + jede_weitere_person: { + 1965: { + 1: 33, + 2: 34, + 3: 36 + }, + 1971: { + 1: 37, + 2: 39, + 3: 40 + }, + 1977: { + 1: 41, + 2: 42, + 3: 44 + }, + 2009: { + 1: 45, + 2: 47, + 3: 48 + } + } + } + + + // Reference: Art. 1 G. v. 11.07.1985 BGBl I S. 1318. + // Es wird eine Wohnung mit "Sammelheizung und mit Bad oder Duschraum" angenommen. + from 1985-01-01 = { + 1: { + 1965: { + 1: 146, + 2: 156, + 3: 164, + 4: 174, + 5: 184 + }, + 1971: { + 1: 161, + 2: 174, + 3: 184, + 4: 194, + 5: 207 + }, + 1977: { + 1: 171, + 2: 182, + 3: 194, + 4: 205, + 5: 217 + }, + 2009: { + 1: 184, + 2: 194, + 3: 207, + 4: 220, + 5: 233 + } + }, + 2: { + 1965: { + 1: 187, + 2: 199, + 3: 212, + 4: 225, + 5: 238 + }, + 1971: { + 1: 210, + 2: 222, + 3: 238, + 4: 251, + 5: 266 + }, + 1977: { + 1: 220, + 2: 235, + 3: 251, + 4: 266, + 5: 281 + }, + 2009: { + 1: 235, + 2: 253, + 3: 268, + 4: 284, + 5: 302 + } + }, + 3: { + 1965: { + 1: 222, + 2: 238, + 3: 253, + 4: 268, + 5: 284 + }, + 1971: { + 1: 251, + 2: 266, + 3: 284, + 4: 299, + 5: 317 + }, + 1977: { + 1: 263, + 2: 281, + 3: 299, + 4: 317, + 5: 335 + }, + 2009: { + 1: 281, + 2: 302, + 3: 320, + 4: 340, + 5: 358 + } + }, + 4: { + 1965: { + 1: 261, + 2: 279, + 3: 294, + 4: 312, + 5: 330 + }, + 1971: { + 1: 289, + 2: 309, + 3: 330, + 4: 350, + 5: 368 + }, + 1977: { + 1: 307, + 2: 327, + 3: 348, + 4: 368, + 5: 389 + }, + 2009: { + 1: 327, + 2: 350, + 3: 373, + 4: 396, + 5: 417 + } + }, + 5: { + 1965: { + 1: 297, + 2: 317, + 3: 337, + 4: 355, + 5: 376 + }, + 1971: { + 1: 330, + 2: 353, + 3: 376, + 4: 399, + 5: 419 + }, + 1977: { + 1: 348, + 2: 373, + 3: 396, + 4: 419, + 5: 442 + }, + 2009: { + 1: 373, + 2: 399, + 3: 424, + 4: 450, + 5: 476 + } + }, + jede_weitere_person: { + 1965: { + 1: 36, + 2: 38, + 3: 41, + 4: 43, + 5: 46 + }, + 1971: { + 1: 41, + 2: 43, + 3: 46, + 4: 49, + 5: 51 + }, + 1977: { + 1: 41, + 2: 43, + 3: 46 + 4: 49, + 5: 51 + }, + 2009: { + 1: 46, + 2: 49, + 3: 51, + 4: 56, + 5: 59 + } + } + } + + // Reference: Art. 1 G. v. 13.12.1989 BGBl I S. 2148. + // Es wird eine Wohnung mit "Sammelheizung und mit Bad oder Duschraum" angenommen. + from 1990-01-01 = { + 1: { + 1965: { + 1: 146, + 2: 156, + 3: 164, + 4: 174, + 5: 184, + 6: 194 + }, + 1971: { + 1: 161, + 2: 174, + 3: 184, + 4: 194, + 5: 207, + 6: 220 + }, + 1977: { + 1: 171, + 2: 182, + 3: 194, + 4: 205, + 5: 217, + 6: 230 + }, + 2009: { + 1: 184, + 2: 194, + 3: 207, + 4: 220, + 5: 233, + 6: 245 + } + }, + 2: { + 1965: { + 1: 187, + 2: 199, + 3: 212, + 4: 225, + 5: 238, + 6: 251 + }, + 1971: { + 1: 210, + 2: 222, + 3: 238, + 4: 251, + 5: 266, + 6: 281 + }, + 1977: { + 1: 220, + 2: 235, + 3: 251, + 4: 266, + 5: 281, + 6: 297 + }, + 2009: { + 1: 235, + 2: 253, + 3: 268, + 4: 284, + 5: 302, + 6: 320 + } + }, + 3: { + 1965: { + 1: 222, + 2: 238, + 3: 253, + 4: 268, + 5: 284, + 6: 299 + }, + 1971: { + 1: 251, + 2: 266, + 3: 284, + 4: 299, + 5: 317, + 6: 335 + }, + 1977: { + 1: 263, + 2: 281, + 3: 299, + 4: 317, + 5: 335, + 6: 353 + }, + 2009: { + 1: 281, + 2: 302, + 3: 320, + 4: 340, + 5: 358, + 6: 376 + } + }, + 4: { + 1965: { + 1: 261, + 2: 279, + 3: 294, + 4: 312, + 5: 330, + 6: 348 + }, + 1971: { + 1: 289, + 2: 309, + 3: 330, + 4: 350, + 5: 368, + 6: 386 + }, + 1977: { + 1: 307, + 2: 327, + 3: 348, + 4: 368, + 5: 389, + 6: 409 + }, + 2009: { + 1: 327, + 2: 350, + 3: 373, + 4: 396, + 5: 417, + 6: 437 + } + }, + 5: { + 1965: { + 1: 297, + 2: 317, + 3: 337, + 4: 355, + 5: 376, + 6: 396 + }, + 1971: { + 1: 330, + 2: 353, + 3: 376, + 4: 399, + 5: 419, + 6: 440 + }, + 1977: { + 1: 348, + 2: 373, + 3: 396, + 4: 419, + 5: 442, + 6: 465 + }, + 2009: { + 1: 373, + 2: 399, + 3: 424, + 4: 450, + 5: 476, + 6: 501 + } + }, + jede_weitere_person: { + 1965: { + 1: 36, + 2: 38, + 3: 41, + 4: 43, + 5: 46, + 6: 49 + }, + 1971: { + 1: 41, + 2: 43, + 3: 46, + 4: 49, + 5: 51, + 6: 54 + }, + 1977: { + 1: 43, + 2: 46, + 3: 49, + 4: 51, + 5: 54, + 6: 56 + }, + 2009: { + 1: 46, + 2: 49, + 3: 51, + 4: 56, + 5: 59, + 6: 61 + } + } + } + + // Reference: Art. 1 G. v. 10.08.1990 BGBl I S. 1522. + // Es wird eine Wohnung mit "Sammelheizung und mit Bad oder Duschraum" angenommen. + from 1990-10-01 = { + 1: { + 1965: { + 1: 159, + 2: 171, + 3: 182, + 4: 194, + 5: 210, + 6: 225 + }, + 1977: { + 1: 182, + 2: 194, + 3: 207, + 4: 222, + 5: 240, + 6: 256 + }, + 2009: { + 1: 194, + 2: 207, + 3: 220, + 4: 238, + 5: 256, + 6: 274 + } + }, + 2: { + 1965: { + 1: 205, + 2: 220, + 3: 233, + 4: 253, + 5: 271, + 6: 289 + }, + 1977: { + 1: 235, + 2: 251, + 3: 268, + 4: 289, + 5: 309, + 6: 332 + }, + 2009: { + 1: 251, + 2: 268, + 3: 284, + 4: 307, + 5: 330, + 6: 353 + } + }, + 3: { + 1965: { + 1: 245, + 2: 263, + 3: 279, + 4: 302, + 5: 325, + 6: 345 + }, + 1977: { + 1: 281, + 2: 299, + 3: 320, + 4: 345, + 5: 371, + 6: 396 + }, + 2009: { + 1: 299, + 2: 320, + 3: 340, + 4: 366, + 5: 394, + 6: 422 + } + }, + 4: { + 1965: { + 1: 286, + 2: 304, + 3: 325, + 4: 350, + 5: 376, + 6: 401 + }, + 1977: { + 1: 327, + 2: 348, + 3: 371, + 4: 401, + 5: 429, + 6: 460 + }, + 2009: { + 1: 348, + 2: 371, + 3: 394, + 4: 427, + 5: 458, + 6: 488 + } + }, + 5: { + 1965: { + 1: 325, + 2: 348, + 3: 371, + 4: 399, + 5: 429, + 6: 458 + }, + 1977: { + 1: 373, + 2: 396, + 3: 422, + 4: 458, + 5: 491, + 6: 524 + }, + 2009: { + 1: 396, + 2: 422, + 3: 450, + 4: 486, + 5: 522, + 6: 557 + } + }, + jede_weitere_person: { + 1965: { + 1: 41, + 2: 43, + 3: 46, + 4: 49, + 5: 54, + 6: 56 + }, + 1977: { + 1: 46, + 2: 51, + 3: 54, + 4: 56, + 5: 61, + 6: 64 + }, + 2009: { + 1: 49, + 2: 51, + 3: 54, + 4: 56, + 5: 61, + 6: 64 + } + } + } + + // Reference: Neufassung WoGG v. 11.02.1993 BGBl I S. 183. + // Es wird eine Wohnung mit "Sammelheizung und mit Bad oder Duschraum" angenommen. + from 1993-01-01 = { + 1: { + 1965: { + 1: 159, + 2: 171, + 3: 182, + 4: 194, + 5: 210, + 6: 225 + }, + 1977: { + 1: 182, + 2: 194, + 3: 207, + 4: 222, + 5: 240, + 6: 256 + }, + 1991: { + 1: 194, + 2: 207, + 3: 220, + 4: 238, + 5: 256, + 6: 274 + }, + 2009: { + 1: 228, + 2: 243, + 3: 258, + 4: 279, + 5: 299, + 6: 320 + } + }, + 2: { + 1965: { + 1: 205, + 2: 220, + 3: 233, + 4: 253, + 5: 271, + 6: 289 + }, + 1977: { + 1: 235, + 2: 251, + 3: 268, + 4: 289, + 5: 309, + 6: 332 + }, + 1991: { + 1: 251, + 2: 268, + 3: 284, + 4: 307, + 5: 330, + 6: 353 + }, + 2009: { + 1: 294, + 2: 314, + 3: 335, + 4: 360, + 5: 389, + 6: 414 + } + }, + 3: { + 1965: { + 1: 245, + 2: 263, + 3: 279, + 4: 302, + 5: 325, + 6: 345 + }, + 1977: { + 1: 281, + 2: 299, + 3: 320, + 4: 345, + 5: 371, + 6: 396 + }, + 1991: { + 1: 299, + 2: 320, + 3: 340, + 4: 366, + 5: 394, + 6: 422 + }, + 2009: { + 1: 353, + 2: 378, + 3: 401, + 4: 435, + 5: 465, + 6: 496 + } + }, + 4: { + 1965: { + 1: 286, + 2: 304, + 3: 325, + 4: 350, + 5: 376, + 6: 401 + }, + 1977: { + 1: 327, + 2: 348, + 3: 371, + 4: 401, + 5: 429, + 6: 460 + }, + 1991: { + 1: 348, + 2: 371, + 3: 394, + 4: 427, + 5: 458, + 6: 488 + }, + 2009: { + 1: 409, + 2: 437, + 3: 465, + 4: 504, + 5: 539, + 6: 437 + } + }, + 5: { + 1965: { + 1: 325, + 2: 348, + 3: 371, + 4: 399, + 5: 429, + 6: 458 + }, + 1977: { + 1: 373, + 2: 396, + 3: 422, + 4: 458, + 5: 491, + 6: 524 + }, + 1991: { + 1: 396, + 2: 422, + 3: 450, + 4: 486, + 5: 522, + 6: 557 + }, + 2009: { + 1: 465, + 2: 499, + 3: 529, + 4: 573, + 5: 614, + 6: 657 + } + }, + jede_weitere_person: { + 1965: { + 1: 41, + 2: 43, + 3: 46, + 4: 49, + 5: 54, + 6: 56 + }, + 1977: { + 1: 46, + 2: 51, + 3: 54, + 4: 56, + 5: 61, + 6: 64 + }, + 1991: { + 1: 49, + 2: 54, + 3: 56, + 4: 61, + 5: 64, + 6: 69 + }, + 2009: { + 1: 56, + 2: 61, + 3: 64, + 4: 69, + 5: 74, + 6: 79 + } + } + } + + // Reference: Art. 5 G. v. 22.12.1999, BGBl I S. 2671. + // Nimmt die Umrechnung in Euro von 2002 vorweg. + from 2001-01-01: + 1: { + 1965: { + 1: 200, + 2: 210, + 3: 225, + 4: 245, + 5: 260, + 6: 280 + }, + 1991: { + 1: 215, + 2: 230, + 3: 245, + 4: 265, + 5: 285, + 6: 305 + }, + 2009: { + 1: 265, + 2: 280, + 3: 300, + 4: 325, + 5: 350, + 6: 370 + } + }, + 2: { + 1965: { + 1: 265, + 2: 285, + 3: 300, + 4: 325, + 5: 350, + 6: 375 + }, + 1991: { + 1: 290, + 2: 310, + 3: 330, + 4: 355, + 5: 380, + 6: 405 + }, + 2009: { + 1: 320, + 2: 345, + 3: 365, + 4: 395, + 5: 425, + 6: 455 + } + }, + 3: { + 1965: { + 1: 322, + 2: 340, + 3: 360, + 4: 390, + 5: 420, + 6: 445 + }, + 1991: { + 1: 345, + 2: 365, + 3: 390, + 4: 420, + 5: 455, + 6: 485 + }, + 2009: { + 1: 385, + 2: 410, + 3: 435, + 4: 470, + 5: 505, + 6: 540 + } + }, + 4: { + 1965: { + 1: 370, + 2: 395, + 3: 420, + 4: 454, + 5: 520 + // TODO: Eintrag vergessen? + }, + 1991: { + 1: 400, + 2: 425, + 3: 455, + 4: 490, + 5: 525, + 6: 565 + }, + 2009: { + 1: 445, + 2: 475, + 3: 505, + 4: 545, + 5: 590, + 6: 630 + } + }, + 5: { + 1965: { + 1: 420, + 2: 450, + 3: 480, + 4: 515, + 5: 555, + 6: 595 + }, + 1991: { + 1: 455, + 2: 485, + 3: 520, + 4: 560, + 5: 600, + 6: 640 + }, + 2009: { + 1: 510, + 2: 545, + 3: 580, + 4: 625, + 5: 670, + 6: 715 + } + }, + jede_weitere_person: { + 1965: { + 1: 50, + 2: 55, + 3: 60, + 4: 65, + 5: 70, + 6: 75 + }, + 1991: { + 1: 55, + 2: 60, + 3: 65, + 4: 70, + 5: 75, + 6: 80 + }, + 2009: { + 1: 60, + 2: 65, + 3: 70, + 4: 75, + 5: 80, + 6: 90 + } + } + } + + // Reference: Art. 1 G. v. 24.09.2008, BGBl I S. 1856. + from 2009-01-01 = { + 1: { + 1: 292, + 2: 308, + 3: 330, + 4: 358, + 5: 385, + 6: 407 + }, + 2: { + 1: 352, + 2: 380, + 3: 402, + 4: 435, + 5: 468, + 6: 501 + }, + 3: { + 1: 424, + 2: 451, + 3: 479, + 4: 517, + 5: 556, + 6: 594 + }, + 4: { + 1: 490, + 2: 523, + 3: 556, + 4: 600, + 5: 649, + 6: 693 + }, + 5: { + 1: 561, + 2: 600, + 3: 638, + 4: 688, + 5: 737, + 6: 787 + }, + jede_weitere_person: { + 1: 66, + 2: 72, + 3: 77, + 4: 83, + 5: 88, + 6: 99 + } + } + + // Reference: Art. 1 G. v. 02.10.2015, BGBl I S. 1610. + from 2016-01-01 = { + 1: { + 1: 312, + 2: 351, + 3: 390, + 4: 434, + 5: 482, + 6: 522 + }, + 2: { + 1: 378, + 2: 425, + 3: 473, + 4: 526, + 5: 584, + 6: 633 + }, + 3: { + 1: 450, + 2: 506, + 3: 563, + 4: 626, + 5: 695, + 6: 753 + }, + 4: { + 1: 525, + 2: 591, + 3: 656, + 4: 730, + 5: 811, + 6: 879 + }, + 5: { + 1: 600, + 2: 675, + 3: 750, + 4: 834, + 5: 927, + 6: 1004 + }, + jede_weitere_person: { + 1: 71, + 2: 81, + 3: 91, + 4: 101, + 5: 111, + 6: 126 + } + + // Reference: Art. 1 G. v. 30.11.2019, BGBl I S. 1877. + from 2020-01-01 = { + 1: { + 1: 338, + 2: 381, + 3: 426, + 4: 478, + 5: 525, + 6: 575, + 7: 633 + }, + 2: { + 1: 409, + 2: 461, + 3: 516, + 4: 579, + 5: 636, + 6: 697, + 7: 767 + }, + 3: { + 1: 487, + 2: 549, + 3: 614, + 4: 689, + 5: 757, + 6: 830, + 7: 912 + }, + 4: { + 1: 568, + 2: 641, + 3: 716, + 4: 803, + 5: 884, + 6: 968, + 7: 1065 + }, + 5: { + 1: 649, + 2: 732, + 3: 818, + 4: 918, + 5: 1010, + 6: 1106, + 7: 1217 + }, + jede_weitere_person: { + 1: 77, + 2: 88, + 3: 99, + 4: 111, + 5: 121, + 6: 139, + 7: 153 + } + } + + // Reference: V. v. 03.06.2021 BGBl. I S. 1369. + from 2022-01-01 = { + 1: { + 1: 347, + 2: 392, + 3: 438, + 4: 491, + 5: 540, + 6: 591, + 7: 651 + }, + 2: { + 1: 420, + 2: 474, + 3: 530, + 4: 595, + 5: 654, + 6: 716, + 7: 788 + }, + 3: { + 1: 501, + 2: 564, + 3: 631, + 4: 708, + 5: 778, + 6: 853, + 7: 937 + }, + 4: { + 1: 584, + 2: 659, + 3: 736, + 4: 825, + 5: 909, + 6: 995, + 7: 1095 + }, + 5: { + 1: 667, + 2: 752, + 3: 841, + 4: 944, + 5: 1038, + 6: 1137, + 7: 1251 + }, + jede_weitere_person: { + 1: 79, + 2: 90, + 3: 102, + 4: 114, + 5: 124, + 6: 143, + 7: 157 + } + } +} + +/** + * Vermögensgrundfreibetrag für den Haushalt + * Wohngeld-Verwaltungsvorschift 21.37. Seit 2009 (G. v. 24.09.2008, BGBl. I S. 1856) + * wird durch §21 Nr. 3 WoGG geregelt, dass hohes Vermögen ein Ausschlussgrund für + * Wohngeld sein kann. Die genauen Werte regelt die Verwaltungsvorschrift vom April + * 2009. Vorher war hohes Vermögen laut WoGG kein Ausschlussgrund. + */ +const vermoegensgrundfreibetrag: Float { + // No wealth threshold in place. + from 1970-01-01 = inf + + // Reference: Wohngeld-Verwaltungsvorschrift 2009. + // At least in place since then. + from 2009-01-01 = 60000 +} + +/** + * Vermögensfreibetrag für jedes weitere Haushaltsmitglied + * Wohngeld-Verwaltungsvorschift 21.37 + */ +const vermoegensfreibetragPerson: Float { + // No wealth threshold in place + from 1970-01-01 = inf + + // Reference: Wohngeld-Verwaltungsvorschrift 2009. + // At least in place since then. + from 2009-01-01 = 30000 +} + +/** + * Heizkostenentlastung aufgrund der CO2-Bepreisung + * Betrag zur Entlastung bei den Heizkosten aufgrund der CO2-Bepreisung in Euro in + * Anhängigkeit der Haushaltsgröße + * Reference: §12 (6) WoGG, Art. 1 G. v. 15.05.2020, BGBl I S. 1015. + * per month + */ +const heizkostenentlastung: Dict { + from 2021-01-01 { + 1: 14.4, + 2: 18.6, + 3: 22.2, + 4: 25.8, + 5: 29.4, + jede_weitere_person: 3.6 + } +} + +/** + * Dauerhafte Heizkostenkomponente + * Dauerhafte Heizkostenkomponente in Abhängigkeit der Haushaltsgröße eingeführt mit + * der Wohngeldreform 2023 + * Reference: Art. 1 G. v. 08.12.2022 BGBl. I Nr. 48 S. 2160 + * per month + */ +const dauerhafteHeizkostenkomponente: Dict { + from 2023-01-01 { + 1: 96, + 2: 124, + 3: 148, + 4: 172, + 5: 196, + jede_weitere_person: 24 + } + +/** + * Klimakomponente + * Als Klimakomponente zu berücksichtigender Zuschlag zu den Höchstbeträgen nach §12 + * Absatz 1 in Euro in Abhängigkeit der Haushaltsgröße; eingeführt mit der + * Wohngeldreform 2023 + * Reference: Art. 1 G. v. 08.12.2022 BGBl. I Nr. 48 S. 2160 + * per month + */ +const klimakomponente: Dict { + from 2023-01-01 = { + 1: 19.20, + 2: 24.80, + 3: 29.60, + 4: 34.40, + 5: 39.20, + jede_weitere_person: 4.8 + } +} + +// TODO: rounding \ No newline at end of file From 7c0efd1881385338881a52bda33e3b5fcfa43d95 Mon Sep 17 00:00:00 2001 From: Alex Senger Date: Wed, 22 May 2024 11:54:27 +0200 Subject: [PATCH 043/183] refactor: put parameters in own dir --- src/resources/builtins/{ => parameters}/abgeltungssteuersatz.ttsl | 0 src/resources/builtins/{ => parameters}/arbeitslosengeld.ttsl | 0 src/resources/builtins/{ => parameters}/arbeitslosengeld2.ttsl | 0 src/resources/builtins/{ => parameters}/einkommenssteuer.ttsl | 0 .../builtins/{ => parameters}/einkommenssteuerAbzuege.ttsl | 0 src/resources/builtins/{ => parameters}/elterngeld.ttsl | 0 .../builtins/{ => parameters}/erwerbsminderungsrente.ttsl | 0 src/resources/builtins/{ => parameters}/erziehungsgeld.ttsl | 0 src/resources/builtins/{ => parameters}/gesetzlicheRente.ttsl | 0 .../builtins/{ => parameters}/grundsicherungImAlter.ttsl | 0 src/resources/builtins/{ => parameters}/kindergeld.ttsl | 0 src/resources/builtins/{ => parameters}/kinderzuschlag.ttsl | 0 .../builtins/{ => parameters}/kinderzuschlagEinkommen.ttsl | 0 src/resources/builtins/{ => parameters}/lohnsteuer.ttsl | 0 .../builtins/{ => parameters}/solidaritaetszuschlag.ttsl | 0 .../builtins/{ => parameters}/sozialversicherungsbeitrag.ttsl | 0 src/resources/builtins/{ => parameters}/unterhalt.ttsl | 0 src/resources/builtins/{ => parameters}/unterhaltvorschuss.ttsl | 0 src/resources/builtins/{ => parameters}/wohngeld.ttsl | 0 19 files changed, 0 insertions(+), 0 deletions(-) rename src/resources/builtins/{ => parameters}/abgeltungssteuersatz.ttsl (100%) rename src/resources/builtins/{ => parameters}/arbeitslosengeld.ttsl (100%) rename src/resources/builtins/{ => parameters}/arbeitslosengeld2.ttsl (100%) rename src/resources/builtins/{ => parameters}/einkommenssteuer.ttsl (100%) rename src/resources/builtins/{ => parameters}/einkommenssteuerAbzuege.ttsl (100%) rename src/resources/builtins/{ => parameters}/elterngeld.ttsl (100%) rename src/resources/builtins/{ => parameters}/erwerbsminderungsrente.ttsl (100%) rename src/resources/builtins/{ => parameters}/erziehungsgeld.ttsl (100%) rename src/resources/builtins/{ => parameters}/gesetzlicheRente.ttsl (100%) rename src/resources/builtins/{ => parameters}/grundsicherungImAlter.ttsl (100%) rename src/resources/builtins/{ => parameters}/kindergeld.ttsl (100%) rename src/resources/builtins/{ => parameters}/kinderzuschlag.ttsl (100%) rename src/resources/builtins/{ => parameters}/kinderzuschlagEinkommen.ttsl (100%) rename src/resources/builtins/{ => parameters}/lohnsteuer.ttsl (100%) rename src/resources/builtins/{ => parameters}/solidaritaetszuschlag.ttsl (100%) rename src/resources/builtins/{ => parameters}/sozialversicherungsbeitrag.ttsl (100%) rename src/resources/builtins/{ => parameters}/unterhalt.ttsl (100%) rename src/resources/builtins/{ => parameters}/unterhaltvorschuss.ttsl (100%) rename src/resources/builtins/{ => parameters}/wohngeld.ttsl (100%) diff --git a/src/resources/builtins/abgeltungssteuersatz.ttsl b/src/resources/builtins/parameters/abgeltungssteuersatz.ttsl similarity index 100% rename from src/resources/builtins/abgeltungssteuersatz.ttsl rename to src/resources/builtins/parameters/abgeltungssteuersatz.ttsl diff --git a/src/resources/builtins/arbeitslosengeld.ttsl b/src/resources/builtins/parameters/arbeitslosengeld.ttsl similarity index 100% rename from src/resources/builtins/arbeitslosengeld.ttsl rename to src/resources/builtins/parameters/arbeitslosengeld.ttsl diff --git a/src/resources/builtins/arbeitslosengeld2.ttsl b/src/resources/builtins/parameters/arbeitslosengeld2.ttsl similarity index 100% rename from src/resources/builtins/arbeitslosengeld2.ttsl rename to src/resources/builtins/parameters/arbeitslosengeld2.ttsl diff --git a/src/resources/builtins/einkommenssteuer.ttsl b/src/resources/builtins/parameters/einkommenssteuer.ttsl similarity index 100% rename from src/resources/builtins/einkommenssteuer.ttsl rename to src/resources/builtins/parameters/einkommenssteuer.ttsl diff --git a/src/resources/builtins/einkommenssteuerAbzuege.ttsl b/src/resources/builtins/parameters/einkommenssteuerAbzuege.ttsl similarity index 100% rename from src/resources/builtins/einkommenssteuerAbzuege.ttsl rename to src/resources/builtins/parameters/einkommenssteuerAbzuege.ttsl diff --git a/src/resources/builtins/elterngeld.ttsl b/src/resources/builtins/parameters/elterngeld.ttsl similarity index 100% rename from src/resources/builtins/elterngeld.ttsl rename to src/resources/builtins/parameters/elterngeld.ttsl diff --git a/src/resources/builtins/erwerbsminderungsrente.ttsl b/src/resources/builtins/parameters/erwerbsminderungsrente.ttsl similarity index 100% rename from src/resources/builtins/erwerbsminderungsrente.ttsl rename to src/resources/builtins/parameters/erwerbsminderungsrente.ttsl diff --git a/src/resources/builtins/erziehungsgeld.ttsl b/src/resources/builtins/parameters/erziehungsgeld.ttsl similarity index 100% rename from src/resources/builtins/erziehungsgeld.ttsl rename to src/resources/builtins/parameters/erziehungsgeld.ttsl diff --git a/src/resources/builtins/gesetzlicheRente.ttsl b/src/resources/builtins/parameters/gesetzlicheRente.ttsl similarity index 100% rename from src/resources/builtins/gesetzlicheRente.ttsl rename to src/resources/builtins/parameters/gesetzlicheRente.ttsl diff --git a/src/resources/builtins/grundsicherungImAlter.ttsl b/src/resources/builtins/parameters/grundsicherungImAlter.ttsl similarity index 100% rename from src/resources/builtins/grundsicherungImAlter.ttsl rename to src/resources/builtins/parameters/grundsicherungImAlter.ttsl diff --git a/src/resources/builtins/kindergeld.ttsl b/src/resources/builtins/parameters/kindergeld.ttsl similarity index 100% rename from src/resources/builtins/kindergeld.ttsl rename to src/resources/builtins/parameters/kindergeld.ttsl diff --git a/src/resources/builtins/kinderzuschlag.ttsl b/src/resources/builtins/parameters/kinderzuschlag.ttsl similarity index 100% rename from src/resources/builtins/kinderzuschlag.ttsl rename to src/resources/builtins/parameters/kinderzuschlag.ttsl diff --git a/src/resources/builtins/kinderzuschlagEinkommen.ttsl b/src/resources/builtins/parameters/kinderzuschlagEinkommen.ttsl similarity index 100% rename from src/resources/builtins/kinderzuschlagEinkommen.ttsl rename to src/resources/builtins/parameters/kinderzuschlagEinkommen.ttsl diff --git a/src/resources/builtins/lohnsteuer.ttsl b/src/resources/builtins/parameters/lohnsteuer.ttsl similarity index 100% rename from src/resources/builtins/lohnsteuer.ttsl rename to src/resources/builtins/parameters/lohnsteuer.ttsl diff --git a/src/resources/builtins/solidaritaetszuschlag.ttsl b/src/resources/builtins/parameters/solidaritaetszuschlag.ttsl similarity index 100% rename from src/resources/builtins/solidaritaetszuschlag.ttsl rename to src/resources/builtins/parameters/solidaritaetszuschlag.ttsl diff --git a/src/resources/builtins/sozialversicherungsbeitrag.ttsl b/src/resources/builtins/parameters/sozialversicherungsbeitrag.ttsl similarity index 100% rename from src/resources/builtins/sozialversicherungsbeitrag.ttsl rename to src/resources/builtins/parameters/sozialversicherungsbeitrag.ttsl diff --git a/src/resources/builtins/unterhalt.ttsl b/src/resources/builtins/parameters/unterhalt.ttsl similarity index 100% rename from src/resources/builtins/unterhalt.ttsl rename to src/resources/builtins/parameters/unterhalt.ttsl diff --git a/src/resources/builtins/unterhaltvorschuss.ttsl b/src/resources/builtins/parameters/unterhaltvorschuss.ttsl similarity index 100% rename from src/resources/builtins/unterhaltvorschuss.ttsl rename to src/resources/builtins/parameters/unterhaltvorschuss.ttsl diff --git a/src/resources/builtins/wohngeld.ttsl b/src/resources/builtins/parameters/wohngeld.ttsl similarity index 100% rename from src/resources/builtins/wohngeld.ttsl rename to src/resources/builtins/parameters/wohngeld.ttsl From c9aec335abd114b5e9b898b3e47be5d691e184e6 Mon Sep 17 00:00:00 2001 From: methr0 Date: Wed, 22 May 2024 12:46:16 +0200 Subject: [PATCH 044/183] fix aggregation parameter types --- .../src/language/generation/safe-ds-python-generator.ts | 2 +- .../generated/tests/generator/aggregation/gen_input.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts b/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts index dd62dbd4..f5f396be 100644 --- a/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts +++ b/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts @@ -187,7 +187,7 @@ const UTILITY_NULL_SAFE_MEMBER_ACCESS: UtilityFunction = { const UTILITY_AGGREGATION: UtilityFunction = { name: `${CODEGEN_PREFIX}aggregation`, - code: expandToNode`def ${CODEGEN_PREFIX}aggregation(dataFrame: pd, data: str, id: str, function: str) -> pd | None:` + code: expandToNode`def ${CODEGEN_PREFIX}aggregation(dataFrame: pd, data, id, function: str) -> pd | None:` .appendNewLine() .indent({ indentedChildren:['dataFrame = dataFrame.join(dataFrame[id])'], diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/generated/tests/generator/aggregation/gen_input.py b/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/generated/tests/generator/aggregation/gen_input.py index 893101cf..9acd7f2a 100644 --- a/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/generated/tests/generator/aggregation/gen_input.py +++ b/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/generated/tests/generator/aggregation/gen_input.py @@ -5,7 +5,7 @@ # Utils -------------------------------------------------------------------- -def aggregation(dataFrame: pd, data: str, id: str, function: str) -> pd | None: +def aggregation(dataFrame: pd, data, id, function: str) -> pd | None: dataFrame = dataFrame.join(dataFrame[id]) dataFrame[data] = dataFrame.groupby(id)[data].transform(function) return dataFrame From bbcf2cf8af78f6962007c3910f6962923708552e Mon Sep 17 00:00:00 2001 From: methr0 Date: Wed, 22 May 2024 12:57:58 +0200 Subject: [PATCH 045/183] make constant extend TslDeclaration to be referenced --- packages/ttsl-lang/src/language/grammar/safe-ds.langium | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/ttsl-lang/src/language/grammar/safe-ds.langium b/packages/ttsl-lang/src/language/grammar/safe-ds.langium index 592938dd..f284802c 100644 --- a/packages/ttsl-lang/src/language/grammar/safe-ds.langium +++ b/packages/ttsl-lang/src/language/grammar/safe-ds.langium @@ -339,7 +339,7 @@ TslFunctionBlock returns TslFunctionBlock: '}' ; -interface TslConstant extends TslModuleMember { +interface TslConstant extends TslModuleMember, TslDeclaration { timespanValueEntries?: TslTimespanValueEntry[] ^type: TslType value?: TslExpression From a0da7998aeb43178d8f1e2e0b64ad6ff1e472dbd Mon Sep 17 00:00:00 2001 From: methr0 Date: Wed, 22 May 2024 13:00:38 +0200 Subject: [PATCH 046/183] purity of function doesn't have to be specified --- .../src/language/validation/purity.ts | 33 ------------------- 1 file changed, 33 deletions(-) diff --git a/packages/ttsl-lang/src/language/validation/purity.ts b/packages/ttsl-lang/src/language/validation/purity.ts index e57d73b9..543b5f0d 100644 --- a/packages/ttsl-lang/src/language/validation/purity.ts +++ b/packages/ttsl-lang/src/language/validation/purity.ts @@ -14,39 +14,6 @@ export const CODE_PURITY_MUST_BE_SPECIFIED = 'purity/must-be-specified'; export const CODE_PURITY_POTENTIALLY_IMPURE_PARAMETER_NOT_CALLABLE = 'purity/potentially-impure-parameter-not-callable'; export const CODE_PURITY_PURE_PARAMETER_SET_TO_IMPURE_CALLABLE = 'purity/pure-parameter-set-to-impure-callable'; -export const functionPurityMustBeSpecified = (services: SafeDsServices) => { - const annotations = services.builtins.Annotations; - - return (node: TslFunction, accept: ValidationAcceptor) => { - if (annotations.callsPure(node) && annotations.callsImpure(node)) { - return accept('error', "'@Impure' and '@Pure' are mutually exclusive.", { - node, - property: 'name', - code: CODE_PURITY_IMPURE_AND_PURE, - }); - } else if (!annotations.callsImpure(node) && !annotations.callsPure(node)) { - return accept( - 'error', - "The purity of a function must be specified. Call the annotation '@Pure' or '@Impure'.", - { - node, - property: 'name', - code: CODE_PURITY_MUST_BE_SPECIFIED, - }, - ); - } - - const impureAnnotationCall = findFirstAnnotationCallOf(node, annotations.Impure); - if (impureAnnotationCall && annotations.streamImpurityReasons(node).isEmpty()) { - accept('error', 'At least one impurity reason must be specified.', { - node: impureAnnotationCall, - property: 'annotation', - code: CODE_PURITY_MUST_BE_SPECIFIED, - }); - } - }; -}; - export const impurityReasonsOfOverridingMethodMustBeSubsetOfOverriddenMethod = (services: SafeDsServices) => { const builtinAnnotations = services.builtins.Annotations; const classHierarchy = services.types.ClassHierarchy; From 0be6b3de6aa38907b081dec4c2ea26b39faadc29 Mon Sep 17 00:00:00 2001 From: methr0 Date: Wed, 22 May 2024 13:02:58 +0200 Subject: [PATCH 047/183] purity of function doesn't have to be specified --- packages/ttsl-lang/src/language/validation/safe-ds-validator.ts | 1 - 1 file changed, 1 deletion(-) diff --git a/packages/ttsl-lang/src/language/validation/safe-ds-validator.ts b/packages/ttsl-lang/src/language/validation/safe-ds-validator.ts index cfa1fea5..70fdf68c 100644 --- a/packages/ttsl-lang/src/language/validation/safe-ds-validator.ts +++ b/packages/ttsl-lang/src/language/validation/safe-ds-validator.ts @@ -272,7 +272,6 @@ export const registerValidationChecks = function (services: SafeDsServices) { TslFunction: [ functionMustContainUniqueNames, functionResultListShouldNotBeEmpty(services), - functionPurityMustBeSpecified(services), impurityReasonsOfOverridingMethodMustBeSubsetOfOverriddenMethod(services), impurityReasonParameterNameMustBelongToParameterOfCorrectType(services), impurityReasonShouldNotBeSetMultipleTimes(services), From 94f2ba92a87bb063d87f53462f2080aa2d223824 Mon Sep 17 00:00:00 2001 From: alex-senger Date: Wed, 22 May 2024 20:56:25 +0200 Subject: [PATCH 048/183] fix: typo --- src/resources/builtins/parameters/wohngeld.ttsl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/resources/builtins/parameters/wohngeld.ttsl b/src/resources/builtins/parameters/wohngeld.ttsl index 70938878..0c566479 100644 --- a/src/resources/builtins/parameters/wohngeld.ttsl +++ b/src/resources/builtins/parameters/wohngeld.ttsl @@ -942,7 +942,7 @@ const behinderungsgrad: Dict { * Die Werte sind nach Anzahl Personen - maximales Baujahr des Hauses (vor 2009) - * Mietstufe geordnet. Alle Werte in vollen Euro. */ -const maxMiete: Dit>> { +const maxMiete: Dict>> { // Reference: Art. 1 G. v. 04.08.1980 BGBl I S. 1159. // Bis 1985 nur drei Mietstufen, streng abhängig von der Größe der Gemeinde. Es wird "Wohnung mit Sammelheizung und mit Bad oder Duschraum" angenommen. from 1981-01-01 = { From 66ad1da84830c6d9b307c69d608a062004b1e260 Mon Sep 17 00:00:00 2001 From: methr0 Date: Fri, 31 May 2024 10:55:15 +0200 Subject: [PATCH 049/183] fix new line appention in Module generation --- .../src/language/generation/safe-ds-python-generator.ts | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts b/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts index f5f396be..21e6a62d 100644 --- a/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts +++ b/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts @@ -481,7 +481,8 @@ export class SafeDsPythonGenerator { } if (functions.length > 0) { output.appendNewLineIf( - imports.length > 0 || typeVariableSet.size > 0 || utilitySet.size > 0 || segments.length > 0, + imports.length > 0 || typeVariableSet.size > 0 || utilitySet.size > 0 || segments.length > 0 + || pipelines.length > 0, ); output.append('# Functions --------------------------------------------------------------------'); output.appendNewLine(); @@ -491,7 +492,8 @@ export class SafeDsPythonGenerator { } if (constants.length > 0) { output.appendNewLineIf( - imports.length > 0 || typeVariableSet.size > 0 || utilitySet.size > 0 || segments.length > 0, + imports.length > 0 || typeVariableSet.size > 0 || utilitySet.size > 0 || segments.length > 0 + || pipelines.length > 0 || functions.length > 0, ); output.append('# Constants --------------------------------------------------------------------'); output.appendNewLine(); @@ -501,7 +503,8 @@ export class SafeDsPythonGenerator { } if (data.length > 0) { output.appendNewLineIf( - imports.length > 0 || typeVariableSet.size > 0 || utilitySet.size > 0 || segments.length > 0, + imports.length > 0 || typeVariableSet.size > 0 || utilitySet.size > 0 || segments.length > 0 + || pipelines.length > 0 || functions.length > 0 || constants.length > 0, ); output.append('# Data --------------------------------------------------------------------'); output.appendNewLine(); From 091789fbc753f65287a9f7183e40164d99a337f5 Mon Sep 17 00:00:00 2001 From: methr0 Date: Fri, 31 May 2024 12:14:32 +0200 Subject: [PATCH 050/183] add our types to the primary types, fix constant generation (mostly mistypes) --- .../generation/safe-ds-python-generator.ts | 13 +++++---- .../src/language/grammar/safe-ds.langium | 5 ++++ .../tests/generator/const/gen_input.py | 27 ++++++++++++------- .../tests/generator/const/gen_input.py.map | 2 +- .../tests/generator/datas/gen_input.py.map | 2 +- 5 files changed, 31 insertions(+), 18 deletions(-) diff --git a/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts b/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts index 21e6a62d..919efe05 100644 --- a/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts +++ b/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts @@ -234,7 +234,7 @@ const UTILITY_CONSTANTS: UtilityFunction = { ).appendNewLine() .indent(indentingNode => indentingNode.append( - 'if key[0] <= "s"' + 'if key[0] == "s":' ).appendNewLine() .indent(indentingNode => indentingNode.append( @@ -243,16 +243,16 @@ const UTILITY_CONSTANTS: UtilityFunction = { .indent(indentingNode => indentingNode.append( 'result = self.dict[key]' - )).appendNewLine() + ))).appendNewLine() .append('if key[0] == "e":').appendNewLine() .indent(indentingNode => indentingNode.append( - 'if date <= keys[len(keys)-1-index].replace("e",""):' + 'if date <= keys[len(keys)-1-index].replace("e", ""):' ).appendNewLine() .indent(indentingNode => indentingNode.append( 'result = self.dict[keys[len(keys)-1-index]]' - ).appendNewLine())))) + ).appendNewLine()))) .append('return result'))), imports: [{ importPath: 'typing', declarationName: 'Any' }], typeVariables: [`${CODEGEN_PREFIX}T`], @@ -616,7 +616,7 @@ export class SafeDsPythonGenerator { if(constant.value != null){ return expandTracedToNode(constant)`${traceToNode( constant - )(UTILITY_CONSTANTS.name)}({'empty': ${constant.value}})` + )(UTILITY_CONSTANTS.name)}({"empty": ${constant.value}})` } else if (constant.timespanValueEntries != null){ return expandTracedToNode(constant)`${constant.name}Dict = {${joinTracedToNode(constant, 'timespanValueEntries')( constant.timespanValueEntries, @@ -667,7 +667,6 @@ export class SafeDsPythonGenerator { generateOptions.targetPlaceholder, generateOptions.disableRunnerIntegration, ); - infoFrame.addUtility(UTILITY_CONSTANTS); return expandToNode`${data.name} = ${data.type}()` } @@ -764,7 +763,7 @@ export class SafeDsPythonGenerator { generateLambda: boolean = false, ): CompositeGeneratorNode { const targetPlaceholder = getPlaceholderByName(block, frame.targetPlaceholder); - let statements = getStatements(block).filter((stmt) => this.purityComputer.statementDoesSomething(stmt)); + let statements = getStatements(block)/*.filter((stmt) => this.purityComputer.statementDoesSomething(stmt))*/; if (targetPlaceholder) { statements = this.getStatementsNeededForPartialExecution(targetPlaceholder, statements); } diff --git a/packages/ttsl-lang/src/language/grammar/safe-ds.langium b/packages/ttsl-lang/src/language/grammar/safe-ds.langium index f284802c..f52dda28 100644 --- a/packages/ttsl-lang/src/language/grammar/safe-ds.langium +++ b/packages/ttsl-lang/src/language/grammar/safe-ds.langium @@ -1096,6 +1096,11 @@ TslPrimaryType returns TslType: | TslLiteralType | TslNamedType | TslUnionType + | 'Int' + | 'String' + | 'Boolean' + | 'Dict' + | 'List' ; interface TslCallableType extends TslCallable, TslType { diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/constant/generated/tests/generator/const/gen_input.py b/packages/ttsl-lang/tests/resources/generation/declarations/constant/generated/tests/generator/const/gen_input.py index 15777c50..becc2e27 100644 --- a/packages/ttsl-lang/tests/resources/generation/declarations/constant/generated/tests/generator/const/gen_input.py +++ b/packages/ttsl-lang/tests/resources/generation/declarations/constant/generated/tests/generator/const/gen_input.py @@ -1,20 +1,29 @@ -# Constants -------------------------------------------------------------------- +# Imports ---------------------------------------------------------------------- + +from typing import Any, TypeVar + +# Type variables --------------------------------------------------------------- +__gen_T = TypeVar("__gen_T") + +# Utils ------------------------------------------------------------------------ class __gen_ClassConstants(): def __init__(self, dictionary: dict): self.dict = dictionary def getValue(self, date): keys = sorted(self.dict.keys()) - if(keys[0] == 'empty'): - return self.dict['empty'] + if(keys[0] == "empty"): + return self.dict["empty"] for index, key in enumerate(keys): - if key[0] == 's': - if key.replace('s', '') <= date: + if key[0] == "s": + if key.replace("s", "") <= date: result = self.dict[key] - if key[0] == 'e': - if date <= keys[len(keys)-1 - index].replace('e', ''): - result = self.dict[keys[len(keys)-1 - index]] + if key[0] == "e": + if date <= keys[len(keys)-1-index].replace("e", ""): + result = self.dict[keys[len(keys)-1-index]] return result -test = __gen_ClassConstants() +# Constants -------------------------------------------------------------------- + +__gen_ClassConstants({"empty": 1}) diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/constant/generated/tests/generator/const/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/declarations/constant/generated/tests/generator/const/gen_input.py.map index ff83d01e..0b319309 100644 --- a/packages/ttsl-lang/tests/resources/generation/declarations/constant/generated/tests/generator/const/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/declarations/constant/generated/tests/generator/const/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.Tsltest"],"names":["test"],"mappings":"AAAA;;AAEA,IAASA,IAAI;IAAC,IAAE","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.Tsltest"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAEA","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/data/generated/tests/generator/datas/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/declarations/data/generated/tests/generator/datas/gen_input.py.map index ff83d01e..e0c06218 100644 --- a/packages/ttsl-lang/tests/resources/generation/declarations/data/generated/tests/generator/datas/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/declarations/data/generated/tests/generator/datas/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.Tsltest"],"names":["test"],"mappings":"AAAA;;AAEA,IAASA,IAAI;IAAC,IAAE","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.Tsltest"],"names":[],"mappings":"AAAA","file":"gen_input.py"} \ No newline at end of file From ae5923d20f3d5300d9dd30c2e6ca4b61d22c21bb Mon Sep 17 00:00:00 2001 From: methr0 Date: Thu, 6 Jun 2024 17:26:31 +0200 Subject: [PATCH 051/183] add utility functions for timeunits for functions --- .../generation/safe-ds-python-generator.ts | 74 ++++++++++++++++++- .../src/language/grammar/safe-ds.langium | 6 +- 2 files changed, 75 insertions(+), 5 deletions(-) diff --git a/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts b/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts index 919efe05..3e62c704 100644 --- a/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts +++ b/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts @@ -82,6 +82,11 @@ import { isTslData, TslData, isTslBlock, + TslTimeunit, + TslResultList, + isTslReturn, + TslType, + isTslExpression, } from '../generated/ast.js'; import { isInStubFile, isStubFile } from '../helpers/fileExtensions.js'; import { IdManager } from '../helpers/idManager.js'; @@ -258,6 +263,54 @@ const UTILITY_CONSTANTS: UtilityFunction = { typeVariables: [`${CODEGEN_PREFIX}T`], }; +const UTILITY_TIMEUNIT_DAY: UtilityFunction = { + name: `${CODEGEN_PREFIX}TimeUnitDay`, + code: expandToNode`def ${CODEGEN_PREFIX}TimeUnitDay(value, timeunit):` + .appendNewLine() + .indent(indentingNode => + indentingNode.append('if(timeunit == "per week"):').appendNewLine().indent([`result = result * 7`]) + .appendNewLine().append(`if(timeunit == 'per month')`).appendNewLine().indent([`result = result * 30`]) + .appendNewLine().append(`if(timeunit == 'per year')`).appendNewLine().indent([`result = result * 365`])), + imports: [{ importPath: 'typing', declarationName: 'Any' }], + typeVariables: [`${CODEGEN_PREFIX}T`], +}; + +const UTILITY_TIMEUNIT_WEEK: UtilityFunction = { + name: `${CODEGEN_PREFIX}TimeUnitWeek`, + code: expandToNode`def ${CODEGEN_PREFIX}TimeUnitWeek(value, timeunit):` + .appendNewLine() + .indent(indentingNode => + indentingNode.append(`if(timeunit == 'per day')`).appendNewLine().indent([`result = result / 7`]) + .appendNewLine().append(`if(timeunit == 'per month')`).appendNewLine().indent([`result = result * 4`]) + .appendNewLine().append(`if(timeunit == 'per year')`).appendNewLine().indent([`result = result * 52`])), + imports: [{ importPath: 'typing', declarationName: 'Any' }], + typeVariables: [`${CODEGEN_PREFIX}T`], +}; + +const UTILITY_TIMEUNIT_MONTH: UtilityFunction = { + name: `${CODEGEN_PREFIX}TimeUnitMonth`, + code: expandToNode`def ${CODEGEN_PREFIX}TimeUnitMonth(value, timeunit):` + .appendNewLine() + .indent(indentingNode => + indentingNode.append(`if(timeunit == 'per day')`).appendNewLine().indent([`result = result / 30`]) + .appendNewLine().append(`if(timeunit == 'per week')`).appendNewLine().indent([`result = result / 4`]) + .appendNewLine().append(`if(timeunit == 'per year')`).appendNewLine().indent([`result = result * 12`])), + imports: [{ importPath: 'typing', declarationName: 'Any' }], + typeVariables: [`${CODEGEN_PREFIX}T`], +}; + +const UTILITY_TIMEUNIT_YEAR: UtilityFunction = { + name: `${CODEGEN_PREFIX}TimeUnitYear`, + code: expandToNode`def ${CODEGEN_PREFIX}TimeUnitYear(value, timeunit):` + .appendNewLine() + .indent(indentingNode => + indentingNode.append(`if(timeunit == 'per day')`).appendNewLine().indent([`result = result / 365`]) + .appendNewLine().append(`if(timeunit == 'per week')`).appendNewLine().indent([`result = result / 52`]) + .appendNewLine().append(`if(timeunit == 'per month')`).appendNewLine().indent([`result = result / 12`])), + imports: [{ importPath: 'typing', declarationName: 'Any' }], + typeVariables: [`${CODEGEN_PREFIX}T`], +}; + export class SafeDsPythonGenerator { private readonly builtinAnnotations: SafeDsAnnotations; private readonly nodeMapper: SafeDsNodeMapper; @@ -571,13 +624,15 @@ export class SafeDsPythonGenerator { 'name', )(this.getPythonNameOrDefault(funct))}(timeunit, groupedBy, date`.appendIf(funct.parameterList?.parameters.length !== 0,`, ${this.generateParameters(funct.parameterList, infoFrame)}`).append(`):`) .appendNewLine() - .indent({ indentedChildren: [this.generateFunctionBlock(funct.body, infoFrame)], indentation: PYTHON_INDENT }); + .indent({ indentedChildren: [this.generateFunctionBlock(funct.body, infoFrame, undefined, funct.timeunit)], + indentation: PYTHON_INDENT }); } private generateFunctionBlock( block: TslFunctionBlock, frame: GenerationInfoFrame, generateLambda: boolean = false, + timeunit: TslTimeunit | undefined, ): CompositeGeneratorNode { const targetPlaceholder = getPlaceholderByName(block, frame.targetPlaceholder); let statements = getStatements(block).filter((stmt) => this.purityComputer.statementDoesSomething(stmt)); @@ -587,13 +642,26 @@ export class SafeDsPythonGenerator { if (statements.length === 0) { return traceToNode(block)('pass'); } + let resultBlock = new CompositeGeneratorNode() + if (isTslExpression(block.returnValue)){ + if (timeunit?.timeunit == 'day'){ + frame.addUtility(UTILITY_TIMEUNIT_DAY); + } else if (timeunit?.timeunit == 'week'){ + frame.addUtility(UTILITY_TIMEUNIT_WEEK); + } else if (timeunit?.timeunit == 'month'){ + frame.addUtility(UTILITY_TIMEUNIT_MONTH); + } else if (timeunit?.timeunit == 'year'){ + frame.addUtility(UTILITY_TIMEUNIT_YEAR); + } + resultBlock.append(`return ${this.generateExpression(block.returnValue, frame)}`) + } return joinTracedToNode(block, 'statements')( statements, (stmt) => this.generateStatement(stmt, frame, generateLambda), { separator: NL, }, - )!; + )?.appendNewLine().append(resultBlock)!; } private generateConstant( @@ -877,7 +945,7 @@ export class SafeDsPythonGenerator { throw new Error(`Timespan has neither a start nor an end value`); } return expandTracedToNode(statement)`if ${start} date ${end}: - ${this.generateFunctionBlock(statement.block, frame)}`; + ${this.generateFunctionBlock(statement.block, frame, false, undefined)}`; } else if (isTslConditionalStatement(statement)) { let elseBlock = new CompositeGeneratorNode if (isTslBlock(statement.elseBlock)){ diff --git a/packages/ttsl-lang/src/language/grammar/safe-ds.langium b/packages/ttsl-lang/src/language/grammar/safe-ds.langium index 6c6a694a..a18aea7a 100644 --- a/packages/ttsl-lang/src/language/grammar/safe-ds.langium +++ b/packages/ttsl-lang/src/language/grammar/safe-ds.langium @@ -307,7 +307,7 @@ TslEnumVariant returns TslEnumVariant: interface TslFunction extends TslCallable, TslClassMember, TslModuleMember { isID: boolean typeParameterList?: TslTypeParameterList - resultList?: TslResultList + resulttype?: TslType timeunit?: TslTimeunit groupedBy?: TslGroupedBy constraintList?: TslConstraintList @@ -322,7 +322,7 @@ fragment TslFunctionFragment: name=ID typeParameterList=TslTypeParameterList? parameterList=TslParameterList - resultList=TslResultList? + resulttype=TslType? (groupedBy=TslGroupedBy)? constraintList=TslConstraintList? body=TslFunctionBlock @@ -330,12 +330,14 @@ fragment TslFunctionFragment: interface TslFunctionBlock extends TslBlock{ timespanStatement: TslTimespanStatement[] + returnValue?: TslExpression } TslFunctionBlock returns TslFunctionBlock: {TslFunctionBlock} '{' ( timespanStatement+=TslTimespanStatement | statements+=TslStatement)* + ('returns' returnValue=TslExpression)? '}' ; From 069e1cb1f9d5b0d97100499b6fb9db6fee3580ec Mon Sep 17 00:00:00 2001 From: methr0 Date: Fri, 7 Jun 2024 11:10:31 +0200 Subject: [PATCH 052/183] update syntax for function parameters --- packages/ttsl-lang/src/language/grammar/safe-ds.langium | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/packages/ttsl-lang/src/language/grammar/safe-ds.langium b/packages/ttsl-lang/src/language/grammar/safe-ds.langium index a18aea7a..efe51fa6 100644 --- a/packages/ttsl-lang/src/language/grammar/safe-ds.langium +++ b/packages/ttsl-lang/src/language/grammar/safe-ds.langium @@ -306,7 +306,7 @@ TslEnumVariant returns TslEnumVariant: interface TslFunction extends TslCallable, TslClassMember, TslModuleMember { isID: boolean - typeParameterList?: TslTypeParameterList + typeParameterList?: TslTypeParameter[] resulttype?: TslType timeunit?: TslTimeunit groupedBy?: TslGroupedBy @@ -320,8 +320,8 @@ fragment TslFunctionFragment: 'function' (timeunit=TslTimeunit)? name=ID - typeParameterList=TslTypeParameterList? - parameterList=TslParameterList + (functParameterList+=TslParameter ':' + typeParameterList+=TslTypeParameter)* resulttype=TslType? (groupedBy=TslGroupedBy)? constraintList=TslConstraintList? @@ -466,6 +466,7 @@ TslParameterBound returns TslParameterBound: interface TslCallable extends TslObject { parameterList?: TslParameterList + functParameterList?: TslParameter[] } interface TslParameterList extends TslObject { From ac5b07a498c6326902e99718c41a5ad9e28dd124 Mon Sep 17 00:00:00 2001 From: methr0 Date: Fri, 7 Jun 2024 11:16:51 +0200 Subject: [PATCH 053/183] call the timeunit utility functions when needed in the functionbody --- .../generation/safe-ds-python-generator.ts | 36 +++++++++++-------- 1 file changed, 22 insertions(+), 14 deletions(-) diff --git a/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts b/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts index 3e62c704..6f9b45a1 100644 --- a/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts +++ b/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts @@ -84,7 +84,6 @@ import { isTslBlock, TslTimeunit, TslResultList, - isTslReturn, TslType, isTslExpression, } from '../generated/ast.js'; @@ -268,9 +267,10 @@ const UTILITY_TIMEUNIT_DAY: UtilityFunction = { code: expandToNode`def ${CODEGEN_PREFIX}TimeUnitDay(value, timeunit):` .appendNewLine() .indent(indentingNode => - indentingNode.append('if(timeunit == "per week"):').appendNewLine().indent([`result = result * 7`]) - .appendNewLine().append(`if(timeunit == 'per month')`).appendNewLine().indent([`result = result * 30`]) - .appendNewLine().append(`if(timeunit == 'per year')`).appendNewLine().indent([`result = result * 365`])), + indentingNode.append('if(timeunit == "per week"):').appendNewLine().indent([`return value * 7`]) + .appendNewLine().append(`if(timeunit == 'per month')`).appendNewLine().indent([`return value * 30`]) + .appendNewLine().append(`if(timeunit == 'per year')`).appendNewLine().indent([`return value * 365`]) + .appendNewLine().append(`return value')`)), imports: [{ importPath: 'typing', declarationName: 'Any' }], typeVariables: [`${CODEGEN_PREFIX}T`], }; @@ -280,9 +280,10 @@ const UTILITY_TIMEUNIT_WEEK: UtilityFunction = { code: expandToNode`def ${CODEGEN_PREFIX}TimeUnitWeek(value, timeunit):` .appendNewLine() .indent(indentingNode => - indentingNode.append(`if(timeunit == 'per day')`).appendNewLine().indent([`result = result / 7`]) - .appendNewLine().append(`if(timeunit == 'per month')`).appendNewLine().indent([`result = result * 4`]) - .appendNewLine().append(`if(timeunit == 'per year')`).appendNewLine().indent([`result = result * 52`])), + indentingNode.append(`if(timeunit == 'per day')`).appendNewLine().indent([`return value / 7`]) + .appendNewLine().append(`if(timeunit == 'per month')`).appendNewLine().indent([`return value * 4`]) + .appendNewLine().append(`if(timeunit == 'per year')`).appendNewLine().indent([`return value * 52`]) + .appendNewLine().append(`return value')`)), imports: [{ importPath: 'typing', declarationName: 'Any' }], typeVariables: [`${CODEGEN_PREFIX}T`], }; @@ -292,9 +293,10 @@ const UTILITY_TIMEUNIT_MONTH: UtilityFunction = { code: expandToNode`def ${CODEGEN_PREFIX}TimeUnitMonth(value, timeunit):` .appendNewLine() .indent(indentingNode => - indentingNode.append(`if(timeunit == 'per day')`).appendNewLine().indent([`result = result / 30`]) - .appendNewLine().append(`if(timeunit == 'per week')`).appendNewLine().indent([`result = result / 4`]) - .appendNewLine().append(`if(timeunit == 'per year')`).appendNewLine().indent([`result = result * 12`])), + indentingNode.append(`if(timeunit == 'per day')`).appendNewLine().indent([`return value / 30`]) + .appendNewLine().append(`if(timeunit == 'per week')`).appendNewLine().indent([`return value / 4`]) + .appendNewLine().append(`if(timeunit == 'per year')`).appendNewLine().indent([`return value * 12`]) + .appendNewLine().append(`return value')`)), imports: [{ importPath: 'typing', declarationName: 'Any' }], typeVariables: [`${CODEGEN_PREFIX}T`], }; @@ -304,9 +306,10 @@ const UTILITY_TIMEUNIT_YEAR: UtilityFunction = { code: expandToNode`def ${CODEGEN_PREFIX}TimeUnitYear(value, timeunit):` .appendNewLine() .indent(indentingNode => - indentingNode.append(`if(timeunit == 'per day')`).appendNewLine().indent([`result = result / 365`]) - .appendNewLine().append(`if(timeunit == 'per week')`).appendNewLine().indent([`result = result / 52`]) - .appendNewLine().append(`if(timeunit == 'per month')`).appendNewLine().indent([`result = result / 12`])), + indentingNode.append(`if(timeunit == 'per day')`).appendNewLine().indent([`return value / 365`]) + .appendNewLine().append(`if(timeunit == 'per week')`).appendNewLine().indent([`return value / 52`]) + .appendNewLine().append(`if(timeunit == 'per month')`).appendNewLine().indent([`return value / 12`]) + .appendNewLine().append(`return value')`)), imports: [{ importPath: 'typing', declarationName: 'Any' }], typeVariables: [`${CODEGEN_PREFIX}T`], }; @@ -644,16 +647,21 @@ export class SafeDsPythonGenerator { } let resultBlock = new CompositeGeneratorNode() if (isTslExpression(block.returnValue)){ + resultBlock.append(`if timeunit != None:`) if (timeunit?.timeunit == 'day'){ frame.addUtility(UTILITY_TIMEUNIT_DAY); + resultBlock.indent([`${UTILITY_TIMEUNIT_DAY.name}(${block.returnValue}, timeunit)`]) } else if (timeunit?.timeunit == 'week'){ frame.addUtility(UTILITY_TIMEUNIT_WEEK); + resultBlock.indent([`${UTILITY_TIMEUNIT_WEEK.name}(${block.returnValue}, timeunit)`]) } else if (timeunit?.timeunit == 'month'){ frame.addUtility(UTILITY_TIMEUNIT_MONTH); + resultBlock.indent([`${UTILITY_TIMEUNIT_MONTH.name}(${block.returnValue}, timeunit)`]) } else if (timeunit?.timeunit == 'year'){ frame.addUtility(UTILITY_TIMEUNIT_YEAR); + resultBlock.indent([`${UTILITY_TIMEUNIT_YEAR.name}(${block.returnValue}, timeunit)`]) } - resultBlock.append(`return ${this.generateExpression(block.returnValue, frame)}`) + resultBlock.appendNewLine().append(`return ${this.generateExpression(block.returnValue, frame)}`) } return joinTracedToNode(block, 'statements')( statements, From 1fb2097861ae07a944d03bae09d5a83c79c971d8 Mon Sep 17 00:00:00 2001 From: methr0 Date: Fri, 7 Jun 2024 11:18:35 +0200 Subject: [PATCH 054/183] right syntax for result type in function --- packages/ttsl-lang/src/language/grammar/safe-ds.langium | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/ttsl-lang/src/language/grammar/safe-ds.langium b/packages/ttsl-lang/src/language/grammar/safe-ds.langium index efe51fa6..701fdc1b 100644 --- a/packages/ttsl-lang/src/language/grammar/safe-ds.langium +++ b/packages/ttsl-lang/src/language/grammar/safe-ds.langium @@ -322,7 +322,7 @@ fragment TslFunctionFragment: name=ID (functParameterList+=TslParameter ':' typeParameterList+=TslTypeParameter)* - resulttype=TslType? + ':' resulttype=TslType? (groupedBy=TslGroupedBy)? constraintList=TslConstraintList? body=TslFunctionBlock From 8eae74365c96f0d0b2407fad31fdbbda4085cba3 Mon Sep 17 00:00:00 2001 From: methr0 Date: Fri, 7 Jun 2024 14:22:32 +0200 Subject: [PATCH 055/183] add timeunit agrument to the functioncall generation --- .../src/language/generation/safe-ds-python-generator.ts | 8 +++++++- packages/ttsl-lang/src/language/grammar/safe-ds.langium | 7 +++++++ 2 files changed, 14 insertions(+), 1 deletion(-) diff --git a/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts b/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts index 6f9b45a1..6075d05e 100644 --- a/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts +++ b/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts @@ -1300,7 +1300,13 @@ export class SafeDsPythonGenerator { sortedArgs: TslArgument[], frame: GenerationInfoFrame, ): CompositeGeneratorNode { - return expandTracedToNode(expression)`${this.generateExpression(expression.receiver, frame)}(${joinTracedToNode( + let timeunit = new CompositeGeneratorNode() + if(expression.timeunit != undefined){ + timeunit.append(`${expression.timeunit.timeunit}, `) + } else{ + timeunit.append(`None, `) + } + return expandTracedToNode(expression)`${this.generateExpression(expression.receiver, frame)}(${timeunit}${joinTracedToNode( expression.argumentList, 'arguments', )(sortedArgs, (arg) => this.generateArgument(arg, frame), { separator: ', ' })})`; diff --git a/packages/ttsl-lang/src/language/grammar/safe-ds.langium b/packages/ttsl-lang/src/language/grammar/safe-ds.langium index 701fdc1b..842a0cf5 100644 --- a/packages/ttsl-lang/src/language/grammar/safe-ds.langium +++ b/packages/ttsl-lang/src/language/grammar/safe-ds.langium @@ -811,6 +811,7 @@ TslUnaryOperation returns TslExpression: interface TslChainedExpression extends TslExpression { receiver: TslExpression + timeunit?: TslTimeunit isNullSafe: boolean } @@ -827,6 +828,12 @@ interface TslMemberAccess extends TslChainedExpression { TslChainedExpression returns TslExpression: TslPrimaryExpression ( + {TslCall.receiver=current} + timeunit=TslTimeunit + (isNullSafe?='?')? + argumentList=TslCallArgumentList + + | {TslCall.receiver=current} (isNullSafe?='?')? argumentList=TslCallArgumentList From 9c03b8307ee3622f7f365a69a949086bfff72611 Mon Sep 17 00:00:00 2001 From: methr0 Date: Fri, 7 Jun 2024 16:16:50 +0200 Subject: [PATCH 056/183] Fix aggregation Test errors --- .../generation/safe-ds-python-generator.ts | 12 ++++++++---- .../src/language/grammar/safe-ds.langium | 16 ++++++++-------- .../tests/generator/aggregation/gen_input.py | 15 ++++++++++----- .../tests/generator/aggregation/gen_input.py.map | 2 +- .../expressions/aggregation/input.Tsltest | 2 +- 5 files changed, 28 insertions(+), 19 deletions(-) diff --git a/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts b/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts index 6075d05e..484a670c 100644 --- a/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts +++ b/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts @@ -207,7 +207,7 @@ const UTILITY_AGGREGATION: UtilityFunction = { indentedChildren: ['return dataFrame'], indentation: PYTHON_INDENT, }), - imports: [{ importPath: 'gettsim', declarationName: '(compute_taxes_and_transfers, create_synthetic_data, set_up_policy_environment)' }], + imports: [{ importPath: 'gettsim', declarationName: '(compute_taxes_and_transfers, create_synthetic_data, set_up_policy_environment)' }, {importPath: '', declarationName: 'pandas', alias: 'pd'}], typeVariables: [`${CODEGEN_PREFIX}T`], }; @@ -625,7 +625,7 @@ export class SafeDsPythonGenerator { return expandTracedToNode(funct)`def ${traceToNode( funct, 'name', - )(this.getPythonNameOrDefault(funct))}(timeunit, groupedBy, date`.appendIf(funct.parameterList?.parameters.length !== 0,`, ${this.generateParameters(funct.parameterList, infoFrame)}`).append(`):`) + )(this.getPythonNameOrDefault(funct))}(timeunit, groupedBy, date`.appendIf(funct.parameterList != undefined,`, ${this.generateParameters(funct.parameterList, infoFrame)}`).append(`):`) .appendNewLine() .indent({ indentedChildren: [this.generateFunctionBlock(funct.body, infoFrame, undefined, funct.timeunit)], indentation: PYTHON_INDENT }); @@ -819,7 +819,11 @@ export class SafeDsPythonGenerator { ? `${localValue.declarationName} as ${localValue.alias}` : localValue.declarationName!, ) || []; - declaredImports.push(`from ${key} import ${[...new Set(importedDecls)].join(', ')}`); + if(key == ''){ + declaredImports.push(`import ${[...new Set(importedDecls)].join(', ')}`); + }else{ + declaredImports.push(`from ${key} import ${[...new Set(importedDecls)].join(', ')}`); + } } return [...new Set(qualifiedImports), ...new Set(declaredImports)]; } @@ -1289,7 +1293,7 @@ export class SafeDsPythonGenerator { frame.addUtility(UTILITY_AGGREGATION); return expandTracedToNode(expression)`${traceToNode( expression - )(UTILITY_AGGREGATION.name)}(${'dataframe'}, '${expression.data.toString()}', '${expression.groupedBy.id.toString()}', '${expression.function.toString()}')`; + )(UTILITY_AGGREGATION.name)}(${'dataframe'}, ${expression.data.target.ref?.name}, ${expression.groupedBy.id.target.ref?.name}, '${expression.function.value}')`; } /* c8 ignore next 2 */ throw new Error(`Unknown expression type: ${expression.$type}`); diff --git a/packages/ttsl-lang/src/language/grammar/safe-ds.langium b/packages/ttsl-lang/src/language/grammar/safe-ds.langium index 842a0cf5..25f24847 100644 --- a/packages/ttsl-lang/src/language/grammar/safe-ds.langium +++ b/packages/ttsl-lang/src/language/grammar/safe-ds.langium @@ -320,9 +320,9 @@ fragment TslFunctionFragment: 'function' (timeunit=TslTimeunit)? name=ID - (functParameterList+=TslParameter ':' - typeParameterList+=TslTypeParameter)* - ':' resulttype=TslType? + '('(functParameterList+=TslParameter ':' + typeParameterList+=TslTypeParameter)*')' + (':' resulttype=TslType)? (groupedBy=TslGroupedBy)? constraintList=TslConstraintList? body=TslFunctionBlock @@ -644,13 +644,13 @@ TslExpression returns TslExpression: ; interface TslAggregation extends TslExpression{ - function: @TslFunction - data: @TslData[] + function: TslString + data: TslReference groupedBy: TslGroupedBy } TslAggregation returns TslAggregation: - 'aggregate' function=[TslFunction:ID] 'of' data+=[TslData:ID] (',' data+=[TslData:ID])* groupedBy=TslGroupedBy + 'aggregate' function=TslString 'of' data=TslReference groupedBy=TslGroupedBy ; interface TslLambda extends TslCallable, TslExpression {} @@ -1045,11 +1045,11 @@ TslTimeunit returns TslTimeunit: ; interface TslGroupedBy extends TslModifier{ - id: TslExpression + id: TslReference } TslGroupedBy returns TslGroupedBy: - 'groupedBy' id=TslExpression + 'groupedBy' id=TslReference ; // ----------------------------------------------------------------------------- diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/generated/tests/generator/aggregation/gen_input.py b/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/generated/tests/generator/aggregation/gen_input.py index 9acd7f2a..4db27570 100644 --- a/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/generated/tests/generator/aggregation/gen_input.py +++ b/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/generated/tests/generator/aggregation/gen_input.py @@ -1,11 +1,16 @@ -# Imports -------------------------------------------------------------------- +# Imports ---------------------------------------------------------------------- -from gettsim import (compute_taxes_and_transfers, create_synthetic_data, set_up_policy_environment) import pandas as pd +from gettsim import (compute_taxes_and_transfers, create_synthetic_data, set_up_policy_environment) +from typing import TypeVar + +# Type variables --------------------------------------------------------------- + +__gen_T = TypeVar("__gen_T") -# Utils -------------------------------------------------------------------- +# Utils ------------------------------------------------------------------------ -def aggregation(dataFrame: pd, data, id, function: str) -> pd | None: +def __gen_aggregation(dataFrame: pd, data, id, function: str) -> pd | None: dataFrame = dataFrame.join(dataFrame[id]) dataFrame[data] = dataFrame.groupby(id)[data].transform(function) return dataFrame @@ -13,7 +18,7 @@ def aggregation(dataFrame: pd, data, id, function: str) -> pd | None: # Functions -------------------------------------------------------------------- def testFunction(timeunit, groupedBy, date): - aggregation(dataframe, testData, testID, 'sum') + __gen_aggregation(dataframe, testData, testID, 'sum') # Data -------------------------------------------------------------------- diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/generated/tests/generator/aggregation/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/generated/tests/generator/aggregation/gen_input.py.map index e4736f07..8fea3904 100644 --- a/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/generated/tests/generator/aggregation/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/generated/tests/generator/aggregation/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.Tsltest"],"names":["test"],"mappings":"AAAA;;AAEA,IAASA,IAAI;IAAG,IAAE","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.Tsltest"],"names":["testfunction"],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;AAKA,IAASA,YAAY;IACjB","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/input.Tsltest b/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/input.Tsltest index 842a0e37..5ce2264b 100644 --- a/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/input.Tsltest +++ b/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/input.Tsltest @@ -4,6 +4,6 @@ data testData: Int id data testID: Int function testFunction() { - aggregate 'sum' of testData groupedBy testID; + aggregate "sum" of testData groupedBy testID; } From 3d9715cee193838a02b2dd36140bd41f0c0c9134 Mon Sep 17 00:00:00 2001 From: methr0 Date: Wed, 12 Jun 2024 22:58:17 +0200 Subject: [PATCH 057/183] add id checks for aggregation and checks for grouped functions --- .../src/language/validation/aggregation.ts | 109 ++++++++++++++++++ .../language/validation/safe-ds-validator.ts | 6 + .../tests/generator/aggregation/gen_input.py | 4 +- .../generator/aggregation/gen_input.py.map | 2 +- .../expressions/aggregation/input.Tsltest | 4 +- 5 files changed, 121 insertions(+), 4 deletions(-) create mode 100644 packages/ttsl-lang/src/language/validation/aggregation.ts diff --git a/packages/ttsl-lang/src/language/validation/aggregation.ts b/packages/ttsl-lang/src/language/validation/aggregation.ts new file mode 100644 index 00000000..796c1d6a --- /dev/null +++ b/packages/ttsl-lang/src/language/validation/aggregation.ts @@ -0,0 +1,109 @@ +import {ValidationAcceptor } from 'langium'; +import { + TslAggregation, + TslFunction, + TslStatement, + isTslAggregation, + isTslAssignment, + isTslConditionalStatement, + isTslData, + isTslExpressionStatement, + isTslFunction, + isTslLoop, + isTslPlaceholder +} from '../generated/ast.js'; +import { getParameters } from '../helpers/nodeProperties.js'; + +export const CODE_REFERENCE_NO_ID = 'aggregation/no-id'; +export const CODE_NO_AGGREGATION_FOUND = 'type/no-aggregation-found'; + +// ----------------------------------------------------------------------------- +// ID checking in aggregation +// ----------------------------------------------------------------------------- + +export const groupByVariableMustBeAnID = () => { + return (node: TslAggregation, accept: ValidationAcceptor) => { + let ref = node.groupedBy.id.target.ref + if (isTslFunction(ref) && !ref.isID || isTslData(ref) && !ref.isID ) { + accept('error', `In aggregation referenced Variable to be grouped by - '${ref.name}' - is not an ID.`, { + node, + code: CODE_REFERENCE_NO_ID, + }); + } + } +}; + +// ----------------------------------------------------------------------------- +// ID checking in function +// ----------------------------------------------------------------------------- + + +export const groupedFunctionHasValidID = () => { + return (node: TslFunction, accept: ValidationAcceptor) => { + let ref = node.groupedBy?.id.target.ref + if (isTslFunction(ref) && !ref.isID || isTslData(ref) && !ref.isID ) { + accept('error', `The reference the function states to be grouped by - '${ref.name}' - is not an ID.`, { + node, + code: CODE_REFERENCE_NO_ID, + }); + } + + } +}; + +// ----------------------------------------------------------------------------- +// grouped function must has an aggregation or a grouped local variable +// ----------------------------------------------------------------------------- + +export const groupedFunctionHasAggregation = () => { + return (node: TslFunction, accept: ValidationAcceptor) => { + let id = node.groupedBy?.id.target.ref?.name + if (id != undefined){ + let parameters = getParameters(node) + let isGrouped = false + parameters.forEach(elm => { + if (elm.groupedBy?.id.target.ref?.name == id){ + isGrouped = true + } + }); + if (hasAggregation(node.body.statements, id)){ + isGrouped = true + } + if (!isGrouped) { + accept('error', `The Function '${node.name}' needs a grouped Parameter or an aggregation in the function body to aggregate over '${node.groupedBy?.id.target.ref?.name}'.`, { + node, + code: CODE_NO_AGGREGATION_FOUND, + }); + } + } + + } +}; + +function hasAggregation(statements: TslStatement[]| undefined, id: string): boolean{ + let result = false + if(statements == undefined){ + return result + } + statements.forEach(elm => { + if(isTslExpressionStatement(elm) && isTslAggregation(elm.expression) && elm.expression.groupedBy.id.target.ref?.name == id){ + result = true + } else if(isTslConditionalStatement(elm)){ + result = (hasAggregation(elm.ifBlock.statements, id) && hasAggregation(elm.elseBlock?.statements, id)) + } else if(isTslLoop(elm)){ + result = hasAggregation(elm.block.statements, id) + } else if(isTslAssignment(elm)){ + if(isTslAggregation(elm.expression)){ + result = true + }else if(elm.assigneeList?.assignees.filter(isTslPlaceholder)){ + elm.assigneeList.assignees.filter(isTslPlaceholder).forEach(elm => { + if(elm.groupedBy?.id.target.ref?.name == id){ + result = true + } + }) + } + } + }); + return result +} + diff --git a/packages/ttsl-lang/src/language/validation/safe-ds-validator.ts b/packages/ttsl-lang/src/language/validation/safe-ds-validator.ts index 70fdf68c..f1e28ceb 100644 --- a/packages/ttsl-lang/src/language/validation/safe-ds-validator.ts +++ b/packages/ttsl-lang/src/language/validation/safe-ds-validator.ts @@ -185,6 +185,7 @@ import { parameterBoundRightOperandMustEvaluateToFloatConstantOrIntConstant, parameterDefaultValueMustRespectParameterBounds, } from './other/declarations/parameterBounds.js'; +import { groupByVariableMustBeAnID, groupedFunctionHasAggregation, groupedFunctionHasValidID } from './aggregation.js'; /** * Register custom validation checks. @@ -228,6 +229,9 @@ export const registerValidationChecks = function (services: SafeDsServices) { argumentListMustNotSetParameterMultipleTimes(services), ], TslAttribute: [attributeMustHaveTypeHint], + TslAggregation: [ + groupByVariableMustBeAnID(), + ], TslBlockLambda: [blockLambdaMustContainUniqueNames], TslCall: [ callArgumentListShouldBeNeeded(services), @@ -277,6 +281,8 @@ export const registerValidationChecks = function (services: SafeDsServices) { impurityReasonShouldNotBeSetMultipleTimes(services), pythonCallMustOnlyContainValidTemplateExpressions(services), pythonNameMustNotBeSetIfPythonCallIsSet(services), + groupedFunctionHasAggregation(), + groupedFunctionHasValidID(), ], TslImport: [importPackageMustExist(services), importPackageShouldNotBeEmpty(services)], TslImportedDeclaration: [importedDeclarationAliasShouldDifferFromDeclarationName(services)], diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/generated/tests/generator/aggregation/gen_input.py b/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/generated/tests/generator/aggregation/gen_input.py index 4db27570..b95cafa9 100644 --- a/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/generated/tests/generator/aggregation/gen_input.py +++ b/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/generated/tests/generator/aggregation/gen_input.py @@ -19,8 +19,10 @@ def __gen_aggregation(dataFrame: pd, data, id, function: str) -> pd | None: def testFunction(timeunit, groupedBy, date): __gen_aggregation(dataframe, testData, testID, 'sum') - + + # Data -------------------------------------------------------------------- testData = int() + testID = int() \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/generated/tests/generator/aggregation/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/generated/tests/generator/aggregation/gen_input.py.map index 8fea3904..a8ab8a40 100644 --- a/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/generated/tests/generator/aggregation/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/generated/tests/generator/aggregation/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.Tsltest"],"names":["testfunction"],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;AAKA,IAASA,YAAY;IACjB","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.Tsltest"],"names":["testfunction"],"mappings":"AAAA;;AAKA,IAASA,YAAY;IAAoB","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/input.Tsltest b/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/input.Tsltest index 5ce2264b..d8c6d709 100644 --- a/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/input.Tsltest +++ b/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/input.Tsltest @@ -1,9 +1,9 @@ package tests.generator.aggregation -data testData: Int +data testData: Int id data testID: Int -function testFunction() { +function testFunction() groupedBy testID { aggregate "sum" of testData groupedBy testID; } From cb33995fc5c282538b7b3e7bf12fee49c9ba18f9 Mon Sep 17 00:00:00 2001 From: methr0 Date: Wed, 12 Jun 2024 22:58:54 +0200 Subject: [PATCH 058/183] started adding evaluations for aggregation and modifier --- .../safe-ds-partial-evaluator.ts | 28 +++++++++++++++++++ 1 file changed, 28 insertions(+) diff --git a/packages/ttsl-lang/src/language/partialEvaluation/safe-ds-partial-evaluator.ts b/packages/ttsl-lang/src/language/partialEvaluation/safe-ds-partial-evaluator.ts index bcacace3..0eb4de7f 100644 --- a/packages/ttsl-lang/src/language/partialEvaluation/safe-ds-partial-evaluator.ts +++ b/packages/ttsl-lang/src/language/partialEvaluation/safe-ds-partial-evaluator.ts @@ -48,6 +48,12 @@ import { type TslParameter, type TslPrefixOperation, type TslTemplateString, + isTslAggregation, + TslAggregation, + TslModifier, + isTslGroupedBy, + isTslVisibility, + isTslTimeunit, } from '../generated/ast.js'; import { getAbstractResults, getArguments, getParameters } from '../helpers/nodeProperties.js'; import { SafeDsNodeMapper } from '../helpers/safe-ds-node-mapper.js'; @@ -243,6 +249,8 @@ export class SafeDsPartialEvaluator { return this.evaluateTemplateString(node, substitutions, visited); } else if (isTslTypeCast(node)) { return this.evaluateWithRecursionCheck(node.expression, substitutions, visited); + } else if (isTslAggregation(node)) { + return this.evaluateAggregation(node, substitutions, visited); } /* c8 ignore start */ else { throw new Error(`Unexpected expression type: ${node.$type}`); } /* c8 ignore stop */ @@ -509,6 +517,26 @@ export class SafeDsPartialEvaluator { return UnknownEvaluatedNode; } + private evaluateAggregation(node: TslAggregation, substitutions: ParameterSubstitutions, visited: VisitedState[]): EvaluatedNode { + const data = this.evaluateExpression(node.data, substitutions, visited).unwrap(); + const funct = this.evaluateExpression(node.function, substitutions, visited).unwrap(); + const groupedBy = this.evaluateModifier(node.groupedBy, substitutions, visited).unwrap(); + + return UnknownEvaluatedNode; + } + + private evaluateModifier(node: TslModifier, substitutions: ParameterSubstitutions, visited: VisitedState[]): EvaluatedNode { + if (isTslGroupedBy(node)) { + return this.evaluateExpression(node.id, substitutions, visited); + } else if (isTslVisibility(node)) { + throw new Error(`noch nicht evaluierbar`); + } else if (isTslTimeunit(node)) { + throw new Error(`noch nicht evaluierbar`); + }/* c8 ignore start */ else { + throw new Error(`Unexpected Modifier type: ${node.$type}`); + } /* c8 ignore stop */ + } + private evaluateEnumVariantCall( receiver: EvaluatedEnumVariant, args: TslArgument[], From 9ca99ab47025e598f92e8ecb99e220794e9ab721 Mon Sep 17 00:00:00 2001 From: methr0 Date: Mon, 17 Jun 2024 10:25:19 +0200 Subject: [PATCH 059/183] function with timeunit test --- .../generation/safe-ds-python-generator.ts | 26 +++++++++---------- .../src/language/grammar/safe-ds.langium | 2 +- .../tests/generator/timeunit/gen_input.py | 26 +++++++++++++++++++ .../tests/generator/timeunit/gen_input.py.map | 1 + .../modifier/timeunit/input.Tsltest | 5 ++++ 5 files changed, 46 insertions(+), 14 deletions(-) create mode 100644 packages/ttsl-lang/tests/resources/generation/modifier/timeunit/generated/tests/generator/timeunit/gen_input.py create mode 100644 packages/ttsl-lang/tests/resources/generation/modifier/timeunit/generated/tests/generator/timeunit/gen_input.py.map create mode 100644 packages/ttsl-lang/tests/resources/generation/modifier/timeunit/input.Tsltest diff --git a/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts b/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts index 484a670c..63684408 100644 --- a/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts +++ b/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts @@ -270,7 +270,7 @@ const UTILITY_TIMEUNIT_DAY: UtilityFunction = { indentingNode.append('if(timeunit == "per week"):').appendNewLine().indent([`return value * 7`]) .appendNewLine().append(`if(timeunit == 'per month')`).appendNewLine().indent([`return value * 30`]) .appendNewLine().append(`if(timeunit == 'per year')`).appendNewLine().indent([`return value * 365`]) - .appendNewLine().append(`return value')`)), + .appendNewLine().append(`return value`)), imports: [{ importPath: 'typing', declarationName: 'Any' }], typeVariables: [`${CODEGEN_PREFIX}T`], }; @@ -283,7 +283,7 @@ const UTILITY_TIMEUNIT_WEEK: UtilityFunction = { indentingNode.append(`if(timeunit == 'per day')`).appendNewLine().indent([`return value / 7`]) .appendNewLine().append(`if(timeunit == 'per month')`).appendNewLine().indent([`return value * 4`]) .appendNewLine().append(`if(timeunit == 'per year')`).appendNewLine().indent([`return value * 52`]) - .appendNewLine().append(`return value')`)), + .appendNewLine().append(`return value`)), imports: [{ importPath: 'typing', declarationName: 'Any' }], typeVariables: [`${CODEGEN_PREFIX}T`], }; @@ -296,7 +296,7 @@ const UTILITY_TIMEUNIT_MONTH: UtilityFunction = { indentingNode.append(`if(timeunit == 'per day')`).appendNewLine().indent([`return value / 30`]) .appendNewLine().append(`if(timeunit == 'per week')`).appendNewLine().indent([`return value / 4`]) .appendNewLine().append(`if(timeunit == 'per year')`).appendNewLine().indent([`return value * 12`]) - .appendNewLine().append(`return value')`)), + .appendNewLine().append(`return value`)), imports: [{ importPath: 'typing', declarationName: 'Any' }], typeVariables: [`${CODEGEN_PREFIX}T`], }; @@ -309,7 +309,7 @@ const UTILITY_TIMEUNIT_YEAR: UtilityFunction = { indentingNode.append(`if(timeunit == 'per day')`).appendNewLine().indent([`return value / 365`]) .appendNewLine().append(`if(timeunit == 'per week')`).appendNewLine().indent([`return value / 52`]) .appendNewLine().append(`if(timeunit == 'per month')`).appendNewLine().indent([`return value / 12`]) - .appendNewLine().append(`return value')`)), + .appendNewLine().append(`return value`)), imports: [{ importPath: 'typing', declarationName: 'Any' }], typeVariables: [`${CODEGEN_PREFIX}T`], }; @@ -638,31 +638,31 @@ export class SafeDsPythonGenerator { timeunit: TslTimeunit | undefined, ): CompositeGeneratorNode { const targetPlaceholder = getPlaceholderByName(block, frame.targetPlaceholder); - let statements = getStatements(block).filter((stmt) => this.purityComputer.statementDoesSomething(stmt)); + let statements = getStatements(block)/*.filter((stmt) => this.purityComputer.statementDoesSomething(stmt))*/; if (targetPlaceholder) { statements = this.getStatementsNeededForPartialExecution(targetPlaceholder, statements); } - if (statements.length === 0) { - return traceToNode(block)('pass'); - } let resultBlock = new CompositeGeneratorNode() if (isTslExpression(block.returnValue)){ resultBlock.append(`if timeunit != None:`) if (timeunit?.timeunit == 'day'){ frame.addUtility(UTILITY_TIMEUNIT_DAY); - resultBlock.indent([`${UTILITY_TIMEUNIT_DAY.name}(${block.returnValue}, timeunit)`]) + resultBlock.appendNewLine().indent([`${UTILITY_TIMEUNIT_DAY.name}(${this.generateExpression(block.returnValue, frame).contents}, timeunit)`]) } else if (timeunit?.timeunit == 'week'){ frame.addUtility(UTILITY_TIMEUNIT_WEEK); - resultBlock.indent([`${UTILITY_TIMEUNIT_WEEK.name}(${block.returnValue}, timeunit)`]) + resultBlock.appendNewLine().indent([`${UTILITY_TIMEUNIT_WEEK.name}(${this.generateExpression(block.returnValue, frame).contents}, timeunit)`]) } else if (timeunit?.timeunit == 'month'){ frame.addUtility(UTILITY_TIMEUNIT_MONTH); - resultBlock.indent([`${UTILITY_TIMEUNIT_MONTH.name}(${block.returnValue}, timeunit)`]) + resultBlock.appendNewLine().indent([`${UTILITY_TIMEUNIT_MONTH.name}(${this.generateExpression(block.returnValue, frame).contents}, timeunit)`]) } else if (timeunit?.timeunit == 'year'){ frame.addUtility(UTILITY_TIMEUNIT_YEAR); - resultBlock.indent([`${UTILITY_TIMEUNIT_YEAR.name}(${block.returnValue}, timeunit)`]) + resultBlock.appendNewLine().indent([`${UTILITY_TIMEUNIT_YEAR.name}(${this.generateExpression(block.returnValue, frame).contents}, timeunit)`]) } - resultBlock.appendNewLine().append(`return ${this.generateExpression(block.returnValue, frame)}`) + resultBlock.appendNewLine().append(`return ${this.generateExpression(block.returnValue, frame).contents}`) + } else if (statements.length === 0) { + return traceToNode(block)('pass'); } + return joinTracedToNode(block, 'statements')( statements, (stmt) => this.generateStatement(stmt, frame, generateLambda), diff --git a/packages/ttsl-lang/src/language/grammar/safe-ds.langium b/packages/ttsl-lang/src/language/grammar/safe-ds.langium index 25f24847..58a3c2df 100644 --- a/packages/ttsl-lang/src/language/grammar/safe-ds.langium +++ b/packages/ttsl-lang/src/language/grammar/safe-ds.langium @@ -337,7 +337,7 @@ TslFunctionBlock returns TslFunctionBlock: {TslFunctionBlock} '{' ( timespanStatement+=TslTimespanStatement | statements+=TslStatement)* - ('returns' returnValue=TslExpression)? + ('return' returnValue=TslExpression)? '}' ; diff --git a/packages/ttsl-lang/tests/resources/generation/modifier/timeunit/generated/tests/generator/timeunit/gen_input.py b/packages/ttsl-lang/tests/resources/generation/modifier/timeunit/generated/tests/generator/timeunit/gen_input.py new file mode 100644 index 00000000..548a5cec --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/modifier/timeunit/generated/tests/generator/timeunit/gen_input.py @@ -0,0 +1,26 @@ +# Imports ---------------------------------------------------------------------- + +from typing import Any, TypeVar + +# Type variables --------------------------------------------------------------- + +__gen_T = TypeVar("__gen_T") + +# Utils ------------------------------------------------------------------------ + +def __gen_TimeUnitDay(value, timeunit): + if(timeunit == "per week"): + return value * 7 + if(timeunit == 'per month') + return value * 30 + if(timeunit == 'per year') + return value * 365 + return value + +# Functions -------------------------------------------------------------------- + +def test(timeunit, groupedBy, date): + + if timeunit != None: + __gen_TimeUnitDay(2, timeunit) + return 2 diff --git a/packages/ttsl-lang/tests/resources/generation/modifier/timeunit/generated/tests/generator/timeunit/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/modifier/timeunit/generated/tests/generator/timeunit/gen_input.py.map new file mode 100644 index 00000000..35807545 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/modifier/timeunit/generated/tests/generator/timeunit/gen_input.py.map @@ -0,0 +1 @@ +{"version":3,"sources":["input.Tsltest"],"names":["test"],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;AAEA,IAAiBA,IAAI","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/modifier/timeunit/input.Tsltest b/packages/ttsl-lang/tests/resources/generation/modifier/timeunit/input.Tsltest new file mode 100644 index 00000000..d6bc438c --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/modifier/timeunit/input.Tsltest @@ -0,0 +1,5 @@ +package tests.generator.timeunit + +function per day test (): Int { + return 1+1 +} From 6811b870960c278b3b8095df89a5c01d02825307 Mon Sep 17 00:00:00 2001 From: methr0 Date: Mon, 17 Jun 2024 15:40:21 +0200 Subject: [PATCH 060/183] fix bugs in function and constant generation --- .../generation/safe-ds-python-generator.ts | 22 ++++++------ .../src/language/grammar/safe-ds.langium | 28 +++++++++++---- .../tests/generator/const/gen_input.py.map | 2 +- .../generator/emptyFunction/gen_input.py | 2 +- .../functionWithParameter/gen_input.py | 4 +++ .../functionWithParameter/gen_input.py.map | 1 + .../function with parameter/input.Tsltest | 3 ++ .../functionWithReturnValue/gen_input.py | 35 +++++++++++++++++++ .../functionWithReturnValue/gen_input.py.map | 1 + .../function with return Value/input.Tsltest | 7 ++++ 10 files changed, 85 insertions(+), 20 deletions(-) create mode 100644 packages/ttsl-lang/tests/resources/generation/declarations/function with parameter/generated/tests/generator/functionWithParameter/gen_input.py create mode 100644 packages/ttsl-lang/tests/resources/generation/declarations/function with parameter/generated/tests/generator/functionWithParameter/gen_input.py.map create mode 100644 packages/ttsl-lang/tests/resources/generation/declarations/function with parameter/input.Tsltest create mode 100644 packages/ttsl-lang/tests/resources/generation/declarations/function with return Value/generated/tests/generator/functionWithReturnValue/gen_input.py create mode 100644 packages/ttsl-lang/tests/resources/generation/declarations/function with return Value/generated/tests/generator/functionWithReturnValue/gen_input.py.map create mode 100644 packages/ttsl-lang/tests/resources/generation/declarations/function with return Value/input.Tsltest diff --git a/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts b/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts index 63684408..e806cac1 100644 --- a/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts +++ b/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts @@ -621,14 +621,12 @@ export class SafeDsPythonGenerator { generateOptions.targetPlaceholder, generateOptions.disableRunnerIntegration, ); - return expandTracedToNode(funct)`def ${traceToNode( funct, 'name', - )(this.getPythonNameOrDefault(funct))}(timeunit, groupedBy, date`.appendIf(funct.parameterList != undefined,`, ${this.generateParameters(funct.parameterList, infoFrame)}`).append(`):`) + )(this.getPythonNameOrDefault(funct))}(timeunit, groupedBy, date, ${this.generateParameters(funct.parameterList, infoFrame)}):` .appendNewLine() - .indent({ indentedChildren: [this.generateFunctionBlock(funct.body, infoFrame, undefined, funct.timeunit)], - indentation: PYTHON_INDENT }); + .indent({ indentedChildren: [this.generateFunctionBlock(funct.body, infoFrame, undefined, funct.timeunit)], indentation: PYTHON_INDENT }); } private generateFunctionBlock( @@ -644,21 +642,23 @@ export class SafeDsPythonGenerator { } let resultBlock = new CompositeGeneratorNode() if (isTslExpression(block.returnValue)){ - resultBlock.append(`if timeunit != None:`) + if(timeunit){ + resultBlock.append(`if timeunit != None:`) + } if (timeunit?.timeunit == 'day'){ frame.addUtility(UTILITY_TIMEUNIT_DAY); - resultBlock.appendNewLine().indent([`${UTILITY_TIMEUNIT_DAY.name}(${this.generateExpression(block.returnValue, frame).contents}, timeunit)`]) + resultBlock.appendNewLine().indent([`${UTILITY_TIMEUNIT_DAY.name}(${this.generateExpression(block.returnValue, frame).contents}, timeunit)`]).appendNewLine() } else if (timeunit?.timeunit == 'week'){ frame.addUtility(UTILITY_TIMEUNIT_WEEK); - resultBlock.appendNewLine().indent([`${UTILITY_TIMEUNIT_WEEK.name}(${this.generateExpression(block.returnValue, frame).contents}, timeunit)`]) + resultBlock.appendNewLine().indent([`${UTILITY_TIMEUNIT_WEEK.name}(${this.generateExpression(block.returnValue, frame).contents}, timeunit)`]).appendNewLine() } else if (timeunit?.timeunit == 'month'){ frame.addUtility(UTILITY_TIMEUNIT_MONTH); - resultBlock.appendNewLine().indent([`${UTILITY_TIMEUNIT_MONTH.name}(${this.generateExpression(block.returnValue, frame).contents}, timeunit)`]) + resultBlock.appendNewLine().indent([`${UTILITY_TIMEUNIT_MONTH.name}(${this.generateExpression(block.returnValue, frame).contents}, timeunit)`]).appendNewLine() } else if (timeunit?.timeunit == 'year'){ frame.addUtility(UTILITY_TIMEUNIT_YEAR); - resultBlock.appendNewLine().indent([`${UTILITY_TIMEUNIT_YEAR.name}(${this.generateExpression(block.returnValue, frame).contents}, timeunit)`]) + resultBlock.appendNewLine().indent([`${UTILITY_TIMEUNIT_YEAR.name}(${this.generateExpression(block.returnValue, frame).contents}, timeunit)`]).appendNewLine() } - resultBlock.appendNewLine().append(`return ${this.generateExpression(block.returnValue, frame).contents}`) + resultBlock.append(`return ${this.generateExpression(block.returnValue, frame).contents}`) } else if (statements.length === 0) { return traceToNode(block)('pass'); } @@ -692,7 +692,7 @@ export class SafeDsPythonGenerator { if(constant.value != null){ return expandTracedToNode(constant)`${traceToNode( constant - )(UTILITY_CONSTANTS.name)}({"empty": ${constant.value}})` + )(UTILITY_CONSTANTS.name)}({"empty": ${this.generateExpression(constant.value, infoFrame)}})` } else if (constant.timespanValueEntries != null){ return expandTracedToNode(constant)`${constant.name}Dict = {${joinTracedToNode(constant, 'timespanValueEntries')( constant.timespanValueEntries, diff --git a/packages/ttsl-lang/src/language/grammar/safe-ds.langium b/packages/ttsl-lang/src/language/grammar/safe-ds.langium index 58a3c2df..c9770293 100644 --- a/packages/ttsl-lang/src/language/grammar/safe-ds.langium +++ b/packages/ttsl-lang/src/language/grammar/safe-ds.langium @@ -306,7 +306,6 @@ TslEnumVariant returns TslEnumVariant: interface TslFunction extends TslCallable, TslClassMember, TslModuleMember { isID: boolean - typeParameterList?: TslTypeParameter[] resulttype?: TslType timeunit?: TslTimeunit groupedBy?: TslGroupedBy @@ -320,8 +319,7 @@ fragment TslFunctionFragment: 'function' (timeunit=TslTimeunit)? name=ID - '('(functParameterList+=TslParameter ':' - typeParameterList+=TslTypeParameter)*')' + parameterList=TslParameterList (':' resulttype=TslType)? (groupedBy=TslGroupedBy)? constraintList=TslConstraintList? @@ -466,7 +464,6 @@ TslParameterBound returns TslParameterBound: interface TslCallable extends TslObject { parameterList?: TslParameterList - functParameterList?: TslParameter[] } interface TslParameterList extends TslObject { @@ -493,7 +490,7 @@ TslParameter returns TslParameter: annotationCalls+=TslAnnotationCall* isConstant?='constant'? name=ID - (':' ^type=TslType)? + ':' ^type=TslType ('=' defaultValue=TslExpression)? ; @@ -1106,10 +1103,11 @@ TslPrimaryType returns TslType: | TslNamedType | TslUnionType | 'Int' + | 'Float' | 'String' | 'Boolean' - | 'Dict' - | 'List' + | TslDictionaryType + | TslListType ; interface TslCallableType extends TslCallable, TslType { @@ -1237,6 +1235,22 @@ TslTypeArgument returns TslTypeArgument: value=TslType ; +interface TslDictionaryType extends TslType { + key: TslType + value: TslType +} + +TslDictionaryType returns TslDictionaryType: + 'Dict' '<' key=TslType ',' value=TslType '>' +; + +interface TslListType extends TslType { + type: TslType +} + +TslListType returns TslListType: + 'List' '<' type=TslType '>' +; // ----------------------------------------------------------------------------- // Schemas diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/constant/generated/tests/generator/const/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/declarations/constant/generated/tests/generator/const/gen_input.py.map index 0b319309..b76aa7e5 100644 --- a/packages/ttsl-lang/tests/resources/generation/declarations/constant/generated/tests/generator/const/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/declarations/constant/generated/tests/generator/const/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.Tsltest"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAEA","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.Tsltest"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAEA,+BAAqB,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/empty function/generated/tests/generator/emptyFunction/gen_input.py b/packages/ttsl-lang/tests/resources/generation/declarations/empty function/generated/tests/generator/emptyFunction/gen_input.py index 4c320279..7737df6d 100644 --- a/packages/ttsl-lang/tests/resources/generation/declarations/empty function/generated/tests/generator/emptyFunction/gen_input.py +++ b/packages/ttsl-lang/tests/resources/generation/declarations/empty function/generated/tests/generator/emptyFunction/gen_input.py @@ -1,4 +1,4 @@ # Functions -------------------------------------------------------------------- -def test(timeunit, groupedBy, date): +def test(timeunit, groupedBy, date, ): pass \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/function with parameter/generated/tests/generator/functionWithParameter/gen_input.py b/packages/ttsl-lang/tests/resources/generation/declarations/function with parameter/generated/tests/generator/functionWithParameter/gen_input.py new file mode 100644 index 00000000..4d0d9970 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/declarations/function with parameter/generated/tests/generator/functionWithParameter/gen_input.py @@ -0,0 +1,4 @@ +# Functions -------------------------------------------------------------------- + +def test(timeunit, groupedBy, date, x, y): + pass \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/function with parameter/generated/tests/generator/functionWithParameter/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/declarations/function with parameter/generated/tests/generator/functionWithParameter/gen_input.py.map new file mode 100644 index 00000000..e3a3b1db --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/declarations/function with parameter/generated/tests/generator/functionWithParameter/gen_input.py.map @@ -0,0 +1 @@ +{"version":3,"sources":["input.Tsltest"],"names":["test","x","y"],"mappings":"AAAA;;AAEA,IAASA,IAAI,4BAACC,CAAC,EAAOC,CAAC;IAAO,IAAE","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/function with parameter/input.Tsltest b/packages/ttsl-lang/tests/resources/generation/declarations/function with parameter/input.Tsltest new file mode 100644 index 00000000..72f98016 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/declarations/function with parameter/input.Tsltest @@ -0,0 +1,3 @@ +package tests.generator.functionWithParameter + +function test(x: Int, y: Int) {} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/function with return Value/generated/tests/generator/functionWithReturnValue/gen_input.py b/packages/ttsl-lang/tests/resources/generation/declarations/function with return Value/generated/tests/generator/functionWithReturnValue/gen_input.py new file mode 100644 index 00000000..9da47e93 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/declarations/function with return Value/generated/tests/generator/functionWithReturnValue/gen_input.py @@ -0,0 +1,35 @@ +# Imports ---------------------------------------------------------------------- + +from typing import Any, TypeVar + +# Type variables --------------------------------------------------------------- + +__gen_T = TypeVar("__gen_T") + +# Utils ------------------------------------------------------------------------ + +class __gen_ClassConstants(): + def __init__(self, dictionary: dict): + self.dict = dictionary + def getValue(self, date): + keys = sorted(self.dict.keys()) + if(keys[0] == "empty"): + return self.dict["empty"] + for index, key in enumerate(keys): + if key[0] == "s": + if key.replace("s", "") <= date: + result = self.dict[key] + if key[0] == "e": + if date <= keys[len(keys)-1-index].replace("e", ""): + result = self.dict[keys[len(keys)-1-index]] + return result + +# Functions -------------------------------------------------------------------- + +def test(timeunit, groupedBy, date, ): + + return 1 + +# Constants -------------------------------------------------------------------- + +__gen_ClassConstants({"empty": test(None, )}) diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/function with return Value/generated/tests/generator/functionWithReturnValue/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/declarations/function with return Value/generated/tests/generator/functionWithReturnValue/gen_input.py.map new file mode 100644 index 00000000..1eee6517 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/declarations/function with return Value/generated/tests/generator/functionWithReturnValue/gen_input.py.map @@ -0,0 +1 @@ +{"version":3,"sources":["input.Tsltest"],"names":["test"],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAEA,IAASA,IAAI;;;;;;AAIb,+BAAkBA,IAAI","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/function with return Value/input.Tsltest b/packages/ttsl-lang/tests/resources/generation/declarations/function with return Value/input.Tsltest new file mode 100644 index 00000000..b75d1a8a --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/declarations/function with return Value/input.Tsltest @@ -0,0 +1,7 @@ +package tests.generator.functionWithReturnValue + +function test(): Int { + return 1 +} + +constant x: Int = test() \ No newline at end of file From 8d389f97b6d01c8def64cee8531fff3a4d307ab2 Mon Sep 17 00:00:00 2001 From: methr0 Date: Tue, 18 Jun 2024 11:14:12 +0200 Subject: [PATCH 061/183] fix parameter bugs in function and constant generation --- .../generation/safe-ds-python-generator.ts | 24 +++++++++++-------- .../tests/generator/const/gen_input.py | 4 ++-- .../tests/generator/const/gen_input.py.map | 2 +- .../generator/emptyFunction/gen_input.py | 2 +- .../functionWithParameter/gen_input.py | 2 +- .../functionWithParameter/gen_input.py.map | 2 +- .../functionWithReturnValue/gen_input.py | 6 ++--- .../functionWithReturnValue/gen_input.py.map | 2 +- .../tests/generator/aggregation/gen_input.py | 2 +- .../tests/generator/timeunit/gen_input.py | 2 +- 10 files changed, 26 insertions(+), 22 deletions(-) diff --git a/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts b/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts index e806cac1..6bf35d79 100644 --- a/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts +++ b/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts @@ -223,7 +223,7 @@ const UTILITY_CONSTANTS: UtilityFunction = { indentedChildren: ['self.dict = dictionary'], indentation: PYTHON_INDENT }).appendNewLine() - .append('def getValue(self, date):').appendNewLine() + .append('def getValue(self, date = None):').appendNewLine() .indent(indentingNode => indentingNode.append( 'keys = sorted(self.dict.keys())' @@ -624,7 +624,7 @@ export class SafeDsPythonGenerator { return expandTracedToNode(funct)`def ${traceToNode( funct, 'name', - )(this.getPythonNameOrDefault(funct))}(timeunit, groupedBy, date, ${this.generateParameters(funct.parameterList, infoFrame)}):` + )(this.getPythonNameOrDefault(funct))}(${this.generateFunctionParameter(funct, infoFrame)}${this.generateParameters(funct.parameterList, infoFrame)}):` .appendNewLine() .indent({ indentedChildren: [this.generateFunctionBlock(funct.body, infoFrame, undefined, funct.timeunit)], indentation: PYTHON_INDENT }); } @@ -690,7 +690,7 @@ export class SafeDsPythonGenerator { infoFrame.addUtility(UTILITY_CONSTANTS); if(constant.value != null){ - return expandTracedToNode(constant)`${traceToNode( + return expandTracedToNode(constant)`${this.getPythonNameOrDefault(constant)} = ${traceToNode( constant )(UTILITY_CONSTANTS.name)}({"empty": ${this.generateExpression(constant.value, infoFrame)}})` } else if (constant.timespanValueEntries != null){ @@ -1304,18 +1304,22 @@ export class SafeDsPythonGenerator { sortedArgs: TslArgument[], frame: GenerationInfoFrame, ): CompositeGeneratorNode { - let timeunit = new CompositeGeneratorNode() - if(expression.timeunit != undefined){ - timeunit.append(`${expression.timeunit.timeunit}, `) - } else{ - timeunit.append(`None, `) - } - return expandTracedToNode(expression)`${this.generateExpression(expression.receiver, frame)}(${timeunit}${joinTracedToNode( + return expandTracedToNode(expression)`${this.generateExpression(expression.receiver, frame)}(${joinTracedToNode( expression.argumentList, 'arguments', )(sortedArgs, (arg) => this.generateArgument(arg, frame), { separator: ', ' })})`; } + private generateFunctionParameter( + funct: TslFunction, + frame: GenerationInfoFrame, + ): CompositeGeneratorNode | undefined { + if(funct.timeunit != undefined|| funct.groupedBy != undefined){ + return expandToNode`timeunit = None, groupedBy = None, date = None` + } + return undefined + } + private generatePythonCall( expression: TslCall, pythonCall: string, diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/constant/generated/tests/generator/const/gen_input.py b/packages/ttsl-lang/tests/resources/generation/declarations/constant/generated/tests/generator/const/gen_input.py index becc2e27..a936b4c4 100644 --- a/packages/ttsl-lang/tests/resources/generation/declarations/constant/generated/tests/generator/const/gen_input.py +++ b/packages/ttsl-lang/tests/resources/generation/declarations/constant/generated/tests/generator/const/gen_input.py @@ -11,7 +11,7 @@ class __gen_ClassConstants(): def __init__(self, dictionary: dict): self.dict = dictionary - def getValue(self, date): + def getValue(self, date = None): keys = sorted(self.dict.keys()) if(keys[0] == "empty"): return self.dict["empty"] @@ -26,4 +26,4 @@ def getValue(self, date): # Constants -------------------------------------------------------------------- -__gen_ClassConstants({"empty": 1}) +test = __gen_ClassConstants({"empty": 1}) diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/constant/generated/tests/generator/const/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/declarations/constant/generated/tests/generator/const/gen_input.py.map index b76aa7e5..7d71d49e 100644 --- a/packages/ttsl-lang/tests/resources/generation/declarations/constant/generated/tests/generator/const/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/declarations/constant/generated/tests/generator/const/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.Tsltest"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAEA,+BAAqB,CAAC","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.Tsltest"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAEA,OAAA,+BAAqB,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/empty function/generated/tests/generator/emptyFunction/gen_input.py b/packages/ttsl-lang/tests/resources/generation/declarations/empty function/generated/tests/generator/emptyFunction/gen_input.py index 7737df6d..85690fce 100644 --- a/packages/ttsl-lang/tests/resources/generation/declarations/empty function/generated/tests/generator/emptyFunction/gen_input.py +++ b/packages/ttsl-lang/tests/resources/generation/declarations/empty function/generated/tests/generator/emptyFunction/gen_input.py @@ -1,4 +1,4 @@ # Functions -------------------------------------------------------------------- -def test(timeunit, groupedBy, date, ): +def test(): pass \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/function with parameter/generated/tests/generator/functionWithParameter/gen_input.py b/packages/ttsl-lang/tests/resources/generation/declarations/function with parameter/generated/tests/generator/functionWithParameter/gen_input.py index 4d0d9970..c405de84 100644 --- a/packages/ttsl-lang/tests/resources/generation/declarations/function with parameter/generated/tests/generator/functionWithParameter/gen_input.py +++ b/packages/ttsl-lang/tests/resources/generation/declarations/function with parameter/generated/tests/generator/functionWithParameter/gen_input.py @@ -1,4 +1,4 @@ # Functions -------------------------------------------------------------------- -def test(timeunit, groupedBy, date, x, y): +def test(x, y): pass \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/function with parameter/generated/tests/generator/functionWithParameter/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/declarations/function with parameter/generated/tests/generator/functionWithParameter/gen_input.py.map index e3a3b1db..b3c2d9bb 100644 --- a/packages/ttsl-lang/tests/resources/generation/declarations/function with parameter/generated/tests/generator/functionWithParameter/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/declarations/function with parameter/generated/tests/generator/functionWithParameter/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.Tsltest"],"names":["test","x","y"],"mappings":"AAAA;;AAEA,IAASA,IAAI,4BAACC,CAAC,EAAOC,CAAC;IAAO,IAAE","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.Tsltest"],"names":["test","x","y"],"mappings":"AAAA;;AAEA,IAASA,IAAI,CAACC,CAAC,EAAOC,CAAC;IAAO,IAAE","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/function with return Value/generated/tests/generator/functionWithReturnValue/gen_input.py b/packages/ttsl-lang/tests/resources/generation/declarations/function with return Value/generated/tests/generator/functionWithReturnValue/gen_input.py index 9da47e93..310eac93 100644 --- a/packages/ttsl-lang/tests/resources/generation/declarations/function with return Value/generated/tests/generator/functionWithReturnValue/gen_input.py +++ b/packages/ttsl-lang/tests/resources/generation/declarations/function with return Value/generated/tests/generator/functionWithReturnValue/gen_input.py @@ -11,7 +11,7 @@ class __gen_ClassConstants(): def __init__(self, dictionary: dict): self.dict = dictionary - def getValue(self, date): + def getValue(self, date = None): keys = sorted(self.dict.keys()) if(keys[0] == "empty"): return self.dict["empty"] @@ -26,10 +26,10 @@ def getValue(self, date): # Functions -------------------------------------------------------------------- -def test(timeunit, groupedBy, date, ): +def test(): return 1 # Constants -------------------------------------------------------------------- -__gen_ClassConstants({"empty": test(None, )}) +x = __gen_ClassConstants({"empty": test()}) diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/function with return Value/generated/tests/generator/functionWithReturnValue/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/declarations/function with return Value/generated/tests/generator/functionWithReturnValue/gen_input.py.map index 1eee6517..bdd7d925 100644 --- a/packages/ttsl-lang/tests/resources/generation/declarations/function with return Value/generated/tests/generator/functionWithReturnValue/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/declarations/function with return Value/generated/tests/generator/functionWithReturnValue/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.Tsltest"],"names":["test"],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAEA,IAASA,IAAI;;;;;;AAIb,+BAAkBA,IAAI","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.Tsltest"],"names":["test"],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAEA,IAASA,IAAI;;;;;;AAIb,IAAA,+BAAkBA,IAAI","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/generated/tests/generator/aggregation/gen_input.py b/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/generated/tests/generator/aggregation/gen_input.py index b95cafa9..59178a7a 100644 --- a/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/generated/tests/generator/aggregation/gen_input.py +++ b/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/generated/tests/generator/aggregation/gen_input.py @@ -17,7 +17,7 @@ def __gen_aggregation(dataFrame: pd, data, id, function: str) -> pd | None: # Functions -------------------------------------------------------------------- -def testFunction(timeunit, groupedBy, date): +def testFunction(timeunit = None, groupedBy = None, date = None): __gen_aggregation(dataframe, testData, testID, 'sum') diff --git a/packages/ttsl-lang/tests/resources/generation/modifier/timeunit/generated/tests/generator/timeunit/gen_input.py b/packages/ttsl-lang/tests/resources/generation/modifier/timeunit/generated/tests/generator/timeunit/gen_input.py index 548a5cec..55992d6e 100644 --- a/packages/ttsl-lang/tests/resources/generation/modifier/timeunit/generated/tests/generator/timeunit/gen_input.py +++ b/packages/ttsl-lang/tests/resources/generation/modifier/timeunit/generated/tests/generator/timeunit/gen_input.py @@ -19,7 +19,7 @@ def __gen_TimeUnitDay(value, timeunit): # Functions -------------------------------------------------------------------- -def test(timeunit, groupedBy, date): +def test(timeunit = None, groupedBy = None, date = None): if timeunit != None: __gen_TimeUnitDay(2, timeunit) From 814d31e6f17d2ee54311e2f48c5328b0c88edf35 Mon Sep 17 00:00:00 2001 From: methr0 Date: Tue, 18 Jun 2024 11:30:03 +0200 Subject: [PATCH 062/183] fix timeunit test --- .../generation/safe-ds-python-generator.ts | 53 +++++++++--------- .../tests/generator/timeunit/gen_input.py | 55 +++++++++++++++++-- .../tests/generator/timeunit/gen_input.py.map | 2 +- .../modifier/timeunit/input.Tsltest | 16 +++++- 4 files changed, 93 insertions(+), 33 deletions(-) diff --git a/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts b/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts index 6bf35d79..48daf0b0 100644 --- a/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts +++ b/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts @@ -268,8 +268,8 @@ const UTILITY_TIMEUNIT_DAY: UtilityFunction = { .appendNewLine() .indent(indentingNode => indentingNode.append('if(timeunit == "per week"):').appendNewLine().indent([`return value * 7`]) - .appendNewLine().append(`if(timeunit == 'per month')`).appendNewLine().indent([`return value * 30`]) - .appendNewLine().append(`if(timeunit == 'per year')`).appendNewLine().indent([`return value * 365`]) + .appendNewLine().append(`if(timeunit == 'per month'):`).appendNewLine().indent([`return value * 30`]) + .appendNewLine().append(`if(timeunit == 'per year'):`).appendNewLine().indent([`return value * 365`]) .appendNewLine().append(`return value`)), imports: [{ importPath: 'typing', declarationName: 'Any' }], typeVariables: [`${CODEGEN_PREFIX}T`], @@ -280,9 +280,9 @@ const UTILITY_TIMEUNIT_WEEK: UtilityFunction = { code: expandToNode`def ${CODEGEN_PREFIX}TimeUnitWeek(value, timeunit):` .appendNewLine() .indent(indentingNode => - indentingNode.append(`if(timeunit == 'per day')`).appendNewLine().indent([`return value / 7`]) - .appendNewLine().append(`if(timeunit == 'per month')`).appendNewLine().indent([`return value * 4`]) - .appendNewLine().append(`if(timeunit == 'per year')`).appendNewLine().indent([`return value * 52`]) + indentingNode.append(`if(timeunit == 'per day'):`).appendNewLine().indent([`return value / 7`]) + .appendNewLine().append(`if(timeunit == 'per month'):`).appendNewLine().indent([`return value * 4`]) + .appendNewLine().append(`if(timeunit == 'per year'):`).appendNewLine().indent([`return value * 52`]) .appendNewLine().append(`return value`)), imports: [{ importPath: 'typing', declarationName: 'Any' }], typeVariables: [`${CODEGEN_PREFIX}T`], @@ -293,9 +293,9 @@ const UTILITY_TIMEUNIT_MONTH: UtilityFunction = { code: expandToNode`def ${CODEGEN_PREFIX}TimeUnitMonth(value, timeunit):` .appendNewLine() .indent(indentingNode => - indentingNode.append(`if(timeunit == 'per day')`).appendNewLine().indent([`return value / 30`]) - .appendNewLine().append(`if(timeunit == 'per week')`).appendNewLine().indent([`return value / 4`]) - .appendNewLine().append(`if(timeunit == 'per year')`).appendNewLine().indent([`return value * 12`]) + indentingNode.append(`if(timeunit == 'per day'):`).appendNewLine().indent([`return value / 30`]) + .appendNewLine().append(`if(timeunit == 'per week'):`).appendNewLine().indent([`return value / 4`]) + .appendNewLine().append(`if(timeunit == 'per year'):`).appendNewLine().indent([`return value * 12`]) .appendNewLine().append(`return value`)), imports: [{ importPath: 'typing', declarationName: 'Any' }], typeVariables: [`${CODEGEN_PREFIX}T`], @@ -306,9 +306,9 @@ const UTILITY_TIMEUNIT_YEAR: UtilityFunction = { code: expandToNode`def ${CODEGEN_PREFIX}TimeUnitYear(value, timeunit):` .appendNewLine() .indent(indentingNode => - indentingNode.append(`if(timeunit == 'per day')`).appendNewLine().indent([`return value / 365`]) - .appendNewLine().append(`if(timeunit == 'per week')`).appendNewLine().indent([`return value / 52`]) - .appendNewLine().append(`if(timeunit == 'per month')`).appendNewLine().indent([`return value / 12`]) + indentingNode.append(`if(timeunit == 'per day'):`).appendNewLine().indent([`return value / 365`]) + .appendNewLine().append(`if(timeunit == 'per week'):`).appendNewLine().indent([`return value / 52`]) + .appendNewLine().append(`if(timeunit == 'per month'):`).appendNewLine().indent([`return value / 12`]) .appendNewLine().append(`return value`)), imports: [{ importPath: 'typing', declarationName: 'Any' }], typeVariables: [`${CODEGEN_PREFIX}T`], @@ -644,21 +644,24 @@ export class SafeDsPythonGenerator { if (isTslExpression(block.returnValue)){ if(timeunit){ resultBlock.append(`if timeunit != None:`) + if (timeunit?.timeunit == 'day'){ + frame.addUtility(UTILITY_TIMEUNIT_DAY); + resultBlock.appendNewLine().indent([`result = ${UTILITY_TIMEUNIT_DAY.name}(${this.generateExpression(block.returnValue, frame).contents}, timeunit)`]).appendNewLine() + } else if (timeunit?.timeunit == 'week'){ + frame.addUtility(UTILITY_TIMEUNIT_WEEK); + resultBlock.appendNewLine().indent([`result = ${UTILITY_TIMEUNIT_WEEK.name}(${this.generateExpression(block.returnValue, frame).contents}, timeunit)`]).appendNewLine() + } else if (timeunit?.timeunit == 'month'){ + frame.addUtility(UTILITY_TIMEUNIT_MONTH); + resultBlock.appendNewLine().indent([`result = ${UTILITY_TIMEUNIT_MONTH.name}(${this.generateExpression(block.returnValue, frame).contents}, timeunit)`]).appendNewLine() + } else if (timeunit?.timeunit == 'year'){ + frame.addUtility(UTILITY_TIMEUNIT_YEAR); + resultBlock.appendNewLine().indent([`result = ${UTILITY_TIMEUNIT_YEAR.name}(${this.generateExpression(block.returnValue, frame).contents}, timeunit)`]).appendNewLine() + } + resultBlock.append(`return result`) + }else{ + resultBlock.append(`return ${this.generateExpression(block.returnValue, frame).contents}`) } - if (timeunit?.timeunit == 'day'){ - frame.addUtility(UTILITY_TIMEUNIT_DAY); - resultBlock.appendNewLine().indent([`${UTILITY_TIMEUNIT_DAY.name}(${this.generateExpression(block.returnValue, frame).contents}, timeunit)`]).appendNewLine() - } else if (timeunit?.timeunit == 'week'){ - frame.addUtility(UTILITY_TIMEUNIT_WEEK); - resultBlock.appendNewLine().indent([`${UTILITY_TIMEUNIT_WEEK.name}(${this.generateExpression(block.returnValue, frame).contents}, timeunit)`]).appendNewLine() - } else if (timeunit?.timeunit == 'month'){ - frame.addUtility(UTILITY_TIMEUNIT_MONTH); - resultBlock.appendNewLine().indent([`${UTILITY_TIMEUNIT_MONTH.name}(${this.generateExpression(block.returnValue, frame).contents}, timeunit)`]).appendNewLine() - } else if (timeunit?.timeunit == 'year'){ - frame.addUtility(UTILITY_TIMEUNIT_YEAR); - resultBlock.appendNewLine().indent([`${UTILITY_TIMEUNIT_YEAR.name}(${this.generateExpression(block.returnValue, frame).contents}, timeunit)`]).appendNewLine() - } - resultBlock.append(`return ${this.generateExpression(block.returnValue, frame).contents}`) + } else if (statements.length === 0) { return traceToNode(block)('pass'); } diff --git a/packages/ttsl-lang/tests/resources/generation/modifier/timeunit/generated/tests/generator/timeunit/gen_input.py b/packages/ttsl-lang/tests/resources/generation/modifier/timeunit/generated/tests/generator/timeunit/gen_input.py index 55992d6e..f442f39e 100644 --- a/packages/ttsl-lang/tests/resources/generation/modifier/timeunit/generated/tests/generator/timeunit/gen_input.py +++ b/packages/ttsl-lang/tests/resources/generation/modifier/timeunit/generated/tests/generator/timeunit/gen_input.py @@ -11,16 +11,61 @@ def __gen_TimeUnitDay(value, timeunit): if(timeunit == "per week"): return value * 7 - if(timeunit == 'per month') + if(timeunit == 'per month'): return value * 30 - if(timeunit == 'per year') + if(timeunit == 'per year'): return value * 365 return value +def __gen_TimeUnitWeek(value, timeunit): + if(timeunit == 'per day'): + return value / 7 + if(timeunit == 'per month'): + return value * 4 + if(timeunit == 'per year'): + return value * 52 + return value + +def __gen_TimeUnitMonth(value, timeunit): + if(timeunit == 'per day'): + return value / 30 + if(timeunit == 'per week'): + return value / 4 + if(timeunit == 'per year'): + return value * 12 + return value + +def __gen_TimeUnitYear(value, timeunit): + if(timeunit == 'per day'): + return value / 365 + if(timeunit == 'per week'): + return value / 52 + if(timeunit == 'per month'): + return value / 12 + return value + # Functions -------------------------------------------------------------------- -def test(timeunit = None, groupedBy = None, date = None): +def daytest(timeunit = None, groupedBy = None, date = None): + + if timeunit != None: + result = __gen_TimeUnitDay(100, timeunit) + return result + +def weektest(timeunit = None, groupedBy = None, date = None): + + if timeunit != None: + result = __gen_TimeUnitWeek(100, timeunit) + return result + +def monthtest(timeunit = None, groupedBy = None, date = None): + + if timeunit != None: + result = __gen_TimeUnitMonth(100, timeunit) + return result + +def yeartest(timeunit = None, groupedBy = None, date = None): if timeunit != None: - __gen_TimeUnitDay(2, timeunit) - return 2 + result = __gen_TimeUnitYear(100, timeunit) + return result \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/modifier/timeunit/generated/tests/generator/timeunit/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/modifier/timeunit/generated/tests/generator/timeunit/gen_input.py.map index 35807545..6acb6540 100644 --- a/packages/ttsl-lang/tests/resources/generation/modifier/timeunit/generated/tests/generator/timeunit/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/modifier/timeunit/generated/tests/generator/timeunit/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.Tsltest"],"names":["test"],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;AAEA,IAAiBA,IAAI","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.Tsltest"],"names":["daytest","weektest","monthtest","yeartest"],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAEA,IAAiBA,OAAO;;;;;;AAIxB,IAAkBC,QAAQ;;;;;;AAI1B,IAAmBC,SAAS;;;;;;AAI5B,IAAkBC,QAAQ","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/modifier/timeunit/input.Tsltest b/packages/ttsl-lang/tests/resources/generation/modifier/timeunit/input.Tsltest index d6bc438c..2d82469a 100644 --- a/packages/ttsl-lang/tests/resources/generation/modifier/timeunit/input.Tsltest +++ b/packages/ttsl-lang/tests/resources/generation/modifier/timeunit/input.Tsltest @@ -1,5 +1,17 @@ package tests.generator.timeunit -function per day test (): Int { - return 1+1 +function per day daytest (): Int { + return 100 } + +function per week weektest (): Int { + return 100 +} + +function per month monthtest (): Int { + return 100 +} + +function per year yeartest (): Int { + return 100 +} \ No newline at end of file From 5dae488cb01e8ff3dc2f50e7e1ce92249e2bca81 Mon Sep 17 00:00:00 2001 From: methr0 Date: Tue, 18 Jun 2024 14:30:17 +0200 Subject: [PATCH 063/183] add function scope --- .../scoping/safe-ds-scope-computation.ts | 21 +++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/packages/ttsl-lang/src/language/scoping/safe-ds-scope-computation.ts b/packages/ttsl-lang/src/language/scoping/safe-ds-scope-computation.ts index 35b86dd2..58855693 100644 --- a/packages/ttsl-lang/src/language/scoping/safe-ds-scope-computation.ts +++ b/packages/ttsl-lang/src/language/scoping/safe-ds-scope-computation.ts @@ -23,6 +23,7 @@ import { TslClass, TslEnum, TslEnumVariant, + TslFunction, TslParameter, TslTypeParameter, } from '../generated/ast.js'; @@ -46,6 +47,8 @@ export class SafeDsScopeComputation extends DefaultScopeComputation { protected override processNode(node: AstNode, document: LangiumDocument, scopes: PrecomputedScopes): void { if (isTslClass(node)) { this.processTslClass(node, document, scopes); + } else if (isTslFunction(node)) { + this.processTslFunction(node, document, scopes); } else if (isTslEnum(node)) { this.processTslEnum(node, document, scopes); } else if (isTslEnumVariant(node)) { @@ -78,6 +81,24 @@ export class SafeDsScopeComputation extends DefaultScopeComputation { } } + private processTslFunction(node: TslFunction, document: LangiumDocument, scopes: PrecomputedScopes): void { + const name = this.nameProvider.getName(node); + if (!name) { + return; + } + + const description = this.descriptions.createDescription(node, name, document); + + this.addToScopesIfKeyIsDefined(scopes, node.parameterList, description); + this.addToScopesIfKeyIsDefined(scopes, node.constraintList, description); + this.addToScopesIfKeyIsDefined(scopes, node.body, description); + + const containingDeclaration = AstUtils.getContainerOfType(node.$container, isTslDeclaration); + if (isTslModule(containingDeclaration)) { + this.addToScopesIfKeyIsDefined(scopes, containingDeclaration, description); + } + } + private processTslEnum(node: TslEnum, document: LangiumDocument, scopes: PrecomputedScopes): void { const name = this.nameProvider.getName(node); if (!name) { From 9e9ff6301e3b17805cb16d8400f96f530a845843 Mon Sep 17 00:00:00 2001 From: methr0 Date: Tue, 18 Jun 2024 16:25:09 +0200 Subject: [PATCH 064/183] fix build errors --- .../ttsl-lang/src/language/grammar/safe-ds.langium | 9 +++++---- .../src/language/helpers/nodeProperties.ts | 6 ++---- .../ttsl-lang/src/language/lsp/safe-ds-formatter.ts | 4 ++-- .../language/scoping/safe-ds-scope-computation.ts | 3 --- .../src/language/typing/safe-ds-type-computer.ts | 13 ++++++++++--- packages/ttsl-lang/src/language/validation/names.ts | 11 ----------- .../src/language/validation/safe-ds-validator.ts | 3 --- packages/ttsl-lang/src/language/validation/style.ts | 4 ++-- .../ttsl-lang/tests/language/typing/model.test.ts | 2 +- 9 files changed, 22 insertions(+), 33 deletions(-) diff --git a/packages/ttsl-lang/src/language/grammar/safe-ds.langium b/packages/ttsl-lang/src/language/grammar/safe-ds.langium index c9770293..ce772a65 100644 --- a/packages/ttsl-lang/src/language/grammar/safe-ds.langium +++ b/packages/ttsl-lang/src/language/grammar/safe-ds.langium @@ -306,7 +306,7 @@ TslEnumVariant returns TslEnumVariant: interface TslFunction extends TslCallable, TslClassMember, TslModuleMember { isID: boolean - resulttype?: TslType + result?: TslResult timeunit?: TslTimeunit groupedBy?: TslGroupedBy constraintList?: TslConstraintList @@ -320,7 +320,7 @@ fragment TslFunctionFragment: (timeunit=TslTimeunit)? name=ID parameterList=TslParameterList - (':' resulttype=TslType)? + (result=TslResult)? (groupedBy=TslGroupedBy)? constraintList=TslConstraintList? body=TslFunctionBlock @@ -511,7 +511,7 @@ interface TslResult extends TslAbstractResult { TslResult returns TslResult: annotationCalls+=TslAnnotationCall* - name=ID + (name=ID)? (':' ^type=TslType)? ; @@ -1304,9 +1304,10 @@ terminal fragment STRING_END: '{'? STRING_DELIMITER; terminal fragment STRING_DELIMITER: '"'; terminal fragment STRING_TEXT : '{'? ESCAPE_SEQUENCE - | /{?[^\\"{]/ + | OTHER_SEQUENCE ; terminal fragment ESCAPE_SEQUENCE: '\\' .; +terminal fragment OTHER_SEQUENCE: /{?[^\\"{]/; terminal fragment TEMPLATE_EXPRESSION_START: '{{'; terminal fragment TEMPLATE_EXPRESSION_END: '}}'; terminal TEMPLATE_STRING_START returns string: STRING_START STRING_TEXT* TEMPLATE_EXPRESSION_START; diff --git a/packages/ttsl-lang/src/language/helpers/nodeProperties.ts b/packages/ttsl-lang/src/language/helpers/nodeProperties.ts index 7e3554cd..5e7a9da0 100644 --- a/packages/ttsl-lang/src/language/helpers/nodeProperties.ts +++ b/packages/ttsl-lang/src/language/helpers/nodeProperties.ts @@ -194,8 +194,8 @@ export const getAbstractResults = (node: TslCallable | undefined): TslAbstractRe return streamBlockLambdaResults(node).toArray(); } else if (isTslCallableType(node)) { return getResults(node.resultList); - } else if (isTslFunction(node)) { - return getResults(node.resultList); + } else if (isTslFunction(node) && node.result) { + return [node.result]; } else if (isTslSegment(node)) { return getResults(node.resultList); } /* c8 ignore start */ else { @@ -375,8 +375,6 @@ export const getTypeParameters = ( return node.typeParameters; } else if (isTslClass(node)) { return getTypeParameters(node.typeParameterList); - } else if (isTslFunction(node)) { - return getTypeParameters(node.typeParameterList); } /* c8 ignore start */ else { return []; } /* c8 ignore stop */ diff --git a/packages/ttsl-lang/src/language/lsp/safe-ds-formatter.ts b/packages/ttsl-lang/src/language/lsp/safe-ds-formatter.ts index 17b48e57..b60e57b0 100644 --- a/packages/ttsl-lang/src/language/lsp/safe-ds-formatter.ts +++ b/packages/ttsl-lang/src/language/lsp/safe-ds-formatter.ts @@ -438,9 +438,9 @@ export class SafeDsFormatter extends AbstractFormatter { formatter.keyword('static').append(oneSpace()); formatter.property('name').prepend(oneSpace()); - formatter.property('typeParameterList').prepend(noSpace()); + formatter.property('visibility').prepend(noSpace()); formatter.property('parameterList').prepend(noSpace()); - formatter.property('resultList').prepend(oneSpace()); + formatter.property('result').prepend(oneSpace()); formatter.property('constraintList').prepend(oneSpace()); } diff --git a/packages/ttsl-lang/src/language/scoping/safe-ds-scope-computation.ts b/packages/ttsl-lang/src/language/scoping/safe-ds-scope-computation.ts index 58855693..787bd0d4 100644 --- a/packages/ttsl-lang/src/language/scoping/safe-ds-scope-computation.ts +++ b/packages/ttsl-lang/src/language/scoping/safe-ds-scope-computation.ts @@ -179,9 +179,6 @@ export class SafeDsScopeComputation extends DefaultScopeComputation { this.addToScopesIfKeyIsDefined(scopes, containingDeclaration.parameterList, description); this.addToScopesIfKeyIsDefined(scopes, containingDeclaration.parentTypeList, description); this.addToScopesIfKeyIsDefined(scopes, containingDeclaration.body, description); - } else if (isTslFunction(containingDeclaration)) { - this.addToScopesIfKeyIsDefined(scopes, containingDeclaration.parameterList, description); - this.addToScopesIfKeyIsDefined(scopes, containingDeclaration.resultList, description); } } diff --git a/packages/ttsl-lang/src/language/typing/safe-ds-type-computer.ts b/packages/ttsl-lang/src/language/typing/safe-ds-type-computer.ts index 974028eb..f8dcfd58 100644 --- a/packages/ttsl-lang/src/language/typing/safe-ds-type-computer.ts +++ b/packages/ttsl-lang/src/language/typing/safe-ds-type-computer.ts @@ -64,6 +64,7 @@ import { TslType, TslTypeArgument, TslTypeParameter, + TslResult, } from '../generated/ast.js'; import { getArguments, @@ -244,9 +245,15 @@ export class SafeDsTypeComputer { const parameterEntries = getParameters(node).map( (it) => new NamedTupleEntry(it, it.name, this.computeType(it.type)), ); - const resultEntries = getResults(node.resultList).map( - (it) => new NamedTupleEntry(it, it.name, this.computeType(it.type)), - ); + let resultEntries: NamedTupleEntry[] = [] + if(isTslFunction(node)){ + resultEntries.with(0, new NamedTupleEntry(node.result, node.name, this.computeType(node.result?.type))) + }else{ + resultEntries = getResults(node.resultList).map( + (it) => new NamedTupleEntry(it, it.name, this.computeType(it.type)), + ); + } + return this.factory.createCallableType( node, diff --git a/packages/ttsl-lang/src/language/validation/names.ts b/packages/ttsl-lang/src/language/validation/names.ts index 97adac9f..28814e67 100644 --- a/packages/ttsl-lang/src/language/validation/names.ts +++ b/packages/ttsl-lang/src/language/validation/names.ts @@ -244,17 +244,6 @@ export const expressionLambdaMustContainUniqueNames = (node: TslExpressionLambda namesMustBeUnique(getParameters(node), (name) => `A parameter with name '${name}' exists already.`, accept); }; -export const functionMustContainUniqueNames = (node: TslFunction, accept: ValidationAcceptor): void => { - const typeParametersAndParameters = [...getTypeParameters(node.typeParameterList), ...getParameters(node)]; - namesMustBeUnique( - typeParametersAndParameters, - (name) => `A type parameter or parameter with name '${name}' exists already.`, - accept, - ); - - namesMustBeUnique(getResults(node.resultList), (name) => `A result with name '${name}' exists already.`, accept); -}; - export const moduleMemberMustHaveNameThatIsUniqueInPackage = (services: SafeDsServices) => { const packageManager = services.workspace.PackageManager; const builtinUris = new Set(listBuiltinFiles().map((it) => it.toString())); diff --git a/packages/ttsl-lang/src/language/validation/safe-ds-validator.ts b/packages/ttsl-lang/src/language/validation/safe-ds-validator.ts index f1e28ceb..ccaecd9b 100644 --- a/packages/ttsl-lang/src/language/validation/safe-ds-validator.ts +++ b/packages/ttsl-lang/src/language/validation/safe-ds-validator.ts @@ -44,7 +44,6 @@ import { enumMustContainUniqueNames, enumVariantMustContainUniqueNames, expressionLambdaMustContainUniqueNames, - functionMustContainUniqueNames, moduleMemberMustHaveNameThatIsUniqueInPackage, moduleMustContainUniqueNames, nameMustNotOccurOnCoreDeclaration, @@ -131,7 +130,6 @@ import { } from './other/types/unionTypes.js'; import { callArgumentAssignedToPureParameterMustBePure, - functionPurityMustBeSpecified, impurityReasonParameterNameMustBelongToParameterOfCorrectType, impurityReasonShouldNotBeSetMultipleTimes, impurityReasonsOfOverridingMethodMustBeSubsetOfOverriddenMethod, @@ -274,7 +272,6 @@ export const registerValidationChecks = function (services: SafeDsServices) { TslEnumVariant: [enumVariantMustContainUniqueNames, enumVariantParameterListShouldNotBeEmpty(services)], TslExpressionLambda: [expressionLambdaMustContainUniqueNames], TslFunction: [ - functionMustContainUniqueNames, functionResultListShouldNotBeEmpty(services), impurityReasonsOfOverridingMethodMustBeSubsetOfOverriddenMethod(services), impurityReasonParameterNameMustBelongToParameterOfCorrectType(services), diff --git a/packages/ttsl-lang/src/language/validation/style.ts b/packages/ttsl-lang/src/language/validation/style.ts index 8ad1ae67..9407665b 100644 --- a/packages/ttsl-lang/src/language/validation/style.ts +++ b/packages/ttsl-lang/src/language/validation/style.ts @@ -395,10 +395,10 @@ export const functionResultListShouldNotBeEmpty = (services: SafeDsServices) => return; } - if (node.resultList && isEmpty(node.resultList.results)) { + if (node.result && node.body.returnValue == undefined) { accept('info', 'This result list can be removed.', { node, - property: 'resultList', + property: 'result', code: CODE_STYLE_UNNECESSARY_RESULT_LIST, }); } diff --git a/packages/ttsl-lang/tests/language/typing/model.test.ts b/packages/ttsl-lang/tests/language/typing/model.test.ts index da79ed23..e409ce05 100644 --- a/packages/ttsl-lang/tests/language/typing/model.test.ts +++ b/packages/ttsl-lang/tests/language/typing/model.test.ts @@ -37,7 +37,7 @@ const code = ` const callable1 = await getNodeOfType(services, code, isTslFunction, 0); const parameter1 = getParameters(callable1)[0]!; const parameter2 = getParameters(callable1)[1]!; -const result = getResults(callable1.resultList)[0]!; +const result = callable1.result!; const callable2 = await getNodeOfType(services, code, isTslFunction, 1); const class1 = await getNodeOfType(services, code, isTslClass, 0); const class2 = await getNodeOfType(services, code, isTslClass, 1); From c0ed8dee89c8c20a125a480c238f6526dcc090ba Mon Sep 17 00:00:00 2001 From: methr0 Date: Wed, 19 Jun 2024 19:37:12 +0200 Subject: [PATCH 065/183] add keywords to textMate file --- packages/ttsl-vscode/syntaxes/ttsl.tmLanguage.json | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/packages/ttsl-vscode/syntaxes/ttsl.tmLanguage.json b/packages/ttsl-vscode/syntaxes/ttsl.tmLanguage.json index 0caa05d5..9c795d7c 100644 --- a/packages/ttsl-vscode/syntaxes/ttsl.tmLanguage.json +++ b/packages/ttsl-vscode/syntaxes/ttsl.tmLanguage.json @@ -16,20 +16,24 @@ }, { "name": "storage.type.ttsl", - "match": "\\b(annotation|attr|class|enum|fun|package|pipeline|schema|segment|val)\\b" + "match": "\\b(annotation|attr|class|enum|function|constant|data|package|pipeline|schema|segment|var|return)\\b" }, { "name": "storage.modifier.ttsl", - "match": "\\b(const|in|internal|out|private|static)\\b" + "match": "\\b(const|in|internal|out|private|public|packageprivate|groupedBy|per day|per week|per month|per year|id|static|from|to)\\b" }, { "name": "keyword.operator.expression.ttsl", - "match": "\\b(and|not|or|sub)\\b" + "match": "\\b(and|not|or|sub|aggregation)\\b" }, { "name": "keyword.other.ttsl", "match": "\\b(as|from|import|literal|union|where|yield)\\b" }, + { + "name": "keyword.control.ttsl", + "match": "\\b(if|for|while|foreach)\\b" + }, { "name": "meta.ttsl", "begin": "\\`", From a4b220329a23eb4705aa70fd27817002f7c56902 Mon Sep 17 00:00:00 2001 From: methr0 Date: Thu, 20 Jun 2024 14:21:59 +0200 Subject: [PATCH 066/183] change file extension to '.ttsl' --- docs/development/call-graph-testing.md | 2 +- docs/development/formatting-testing.md | 2 +- docs/development/generation-testing.md | 2 +- docs/development/grammar-testing.md | 2 +- .../development/partial-evaluation-testing.md | 2 +- docs/development/scoping-testing.md | 2 +- docs/development/typing-testing.md | 2 +- docs/development/validation-testing.md | 2 +- packages/ttsl-cli/tests/cli/main.test.ts | 18 ++++++++--------- .../tests/helpers/diagnostics.test.ts | 14 ++++++------- .../ttsl-cli/tests/helpers/documents.test.ts | 12 +++++------ packages/ttsl-cli/tests/helpers/files.test.ts | 2 +- .../src/language/helpers/fileExtensions.ts | 2 +- .../__snapshots__/nodeFinder.test.ts.snap | 2 +- .../ttsl-lang/tests/helpers/diagnostics.ts | 2 +- .../ttsl-lang/tests/helpers/locations.test.ts | 20 +++++++++---------- .../tests/helpers/nodeFinder.test.ts | 2 +- .../tests/helpers/testChecks.test.ts | 2 +- .../tests/helpers/testResources.test.ts | 8 ++++---- .../lsp/safe-ds-inlay-hint-provider.test.ts | 2 +- .../tests/generator/const/gen_input.py.map | 2 +- .../constant/{input.Tsltest => input.ttsl} | 0 .../tests/generator/datas/gen_input.py.map | 2 +- .../data/{input.Tsltest => input.ttsl} | 0 .../generator/emptyFunction/gen_input.py.map | 2 +- .../{input.Tsltest => input.ttsl} | 0 .../generator/emptyPipeline/gen_input.py.map | 2 +- .../generator/emptySegment/gen_input.py.map | 2 +- .../functionWithParameter/gen_input.py.map | 2 +- .../{input.Tsltest => input.ttsl} | 0 .../functionWithReturnValue/gen_input.py.map | 2 +- .../{input.Tsltest => input.ttsl} | 0 .../parameterWithPythonName/gen_input.py.map | 2 +- .../pipelineWithPythonName/gen_input.py.map | 2 +- .../segmentWithPythonName/gen_input.py.map | 2 +- .../generator/twoPipelines/gen_input.py.map | 2 +- .../generator/twoSegments/gen_input.py.map | 2 +- .../generator/aggregation/gen_input.py.map | 2 +- .../aggregation/{input.Tsltest => input.ttsl} | 0 .../blockLambdaResult/gen_input.py.map | 2 +- .../generator/blockLambda/gen_input.py.map | 2 +- .../tests/generator/call/gen_input.py.map | 2 +- .../tests/generator/constant/gen_input.py.map | 2 +- .../enumVariantCall/gen_input.py.map | 2 +- .../expressionLambda/gen_input.py.map | 2 +- .../generator/indexedAccess/gen_input.py.map | 2 +- .../generator/infixOperation/gen_input.py.map | 2 +- .../tests/generator/lists/gen_input.py.map | 2 +- .../tests/generator/literals/gen_input.py.map | 2 +- .../tests/generator/maps/gen_input.py.map | 2 +- .../generator/memberAccess/gen_input.py.map | 2 +- .../parenthesizedExpression/gen_input.py.map | 2 +- .../prefixOperation/gen_input.py.map | 2 +- .../generator/reference/gen_input.py.map | 2 +- .../generator/sideEffects/gen_input.py.map | 2 +- .../generator/templateString/gen_input.py.map | 2 +- .../imports/gen_context_same_package.py.map | 2 +- .../tests/generator/imports/gen_input.py.map | 2 +- .../tests/generator/wildcard/gen_input.py.map | 2 +- .../tests/generator/timeunit/gen_input.py.map | 2 +- .../timeunit/{input.Tsltest => input.ttsl} | 0 .../gen_input.py.map | 2 +- .../gen_input.py.map | 2 +- .../partialImpureDependency/gen_input.py.map | 2 +- .../partialPureDependency/gen_input.py.map | 2 +- .../partialRedundantImpurity/gen_input.py.map | 2 +- .../generated/special_module/gen_input.py.map | 2 +- .../gen_input.py.map | 2 +- .../gen_input.py.map | 2 +- .../gen_context_same_package.py.map | 2 +- .../gen_input.py.map | 2 +- .../gen_input.py.map | 2 +- .../gen_input.py.map | 2 +- .../generator/assignment/gen_input.py.map | 2 +- .../conditionalStatement/gen_input.py.map | 2 +- .../{input.Tsltest => input.ttsl} | 0 .../expressionStatement/gen_input.py.map | 2 +- .../statementWithoutEffect/gen_input.py.map | 2 +- ...ing name.tsltest => bad-missing name.ttsl} | 0 ...ing type.tsltest => bad-missing type.ttsl} | 0 ...g value.tsltest => bad-missing value.ttsl} | 0 ....tsltest => good-with type and value.ttsl} | 0 ...ing name.tsltest => bad-missing name.ttsl} | 0 ...ing type.tsltest => bad-missing type.ttsl} | 0 ...e.tsltest => good-with type and name.ttsl} | 0 ....tsltest => bad-missing functionbody.ttsl} | 0 ...sltest => bad-missing parameter list.ttsl} | 0 ...sltest => bad-missing parameter type.ttsl} | 0 ...ltest => bad-unclosed parameter list.ttsl} | 0 ....tsltest => bad-unclosed result list.ttsl} | 0 ...call.tsltest => good-annotation call.ttsl} | 0 ....tsltest => good-with parameter list.ttsl} | 0 ...ist.tsltest => good-with result list.ttsl} | 0 ...est => good-with type parameter list.ttsl} | 0 ...t => bad-with else missing elseblock.ttsl} | 0 ...st => bad-without else missing block.ttsl} | 0 ...> bad-without else missing condition.ttsl} | 0 ...alse.tsltest => good-with else false.ttsl} | 0 ... true.tsltest => good-with else true.ttsl} | 0 ...ut else.tsltest => good-without else.ttsl} | 0 100 files changed, 101 insertions(+), 101 deletions(-) rename packages/ttsl-lang/tests/resources/generation/declarations/constant/{input.Tsltest => input.ttsl} (100%) rename packages/ttsl-lang/tests/resources/generation/declarations/data/{input.Tsltest => input.ttsl} (100%) rename packages/ttsl-lang/tests/resources/generation/declarations/empty function/{input.Tsltest => input.ttsl} (100%) rename packages/ttsl-lang/tests/resources/generation/declarations/function with parameter/{input.Tsltest => input.ttsl} (100%) rename packages/ttsl-lang/tests/resources/generation/declarations/function with return Value/{input.Tsltest => input.ttsl} (100%) rename packages/ttsl-lang/tests/resources/generation/expressions/aggregation/{input.Tsltest => input.ttsl} (100%) rename packages/ttsl-lang/tests/resources/generation/modifier/timeunit/{input.Tsltest => input.ttsl} (100%) rename packages/ttsl-lang/tests/resources/generation/statements/conditional statement/{input.Tsltest => input.ttsl} (100%) rename packages/ttsl-lang/tests/resources/grammar/declarations/constants/{bad-missing name.tsltest => bad-missing name.ttsl} (100%) rename packages/ttsl-lang/tests/resources/grammar/declarations/constants/{bad-missing type.tsltest => bad-missing type.ttsl} (100%) rename packages/ttsl-lang/tests/resources/grammar/declarations/constants/{bad-missing value.tsltest => bad-missing value.ttsl} (100%) rename packages/ttsl-lang/tests/resources/grammar/declarations/constants/{good-with type and value.tsltest => good-with type and value.ttsl} (100%) rename packages/ttsl-lang/tests/resources/grammar/declarations/data/{bad-missing name.tsltest => bad-missing name.ttsl} (100%) rename packages/ttsl-lang/tests/resources/grammar/declarations/data/{bad-missing type.tsltest => bad-missing type.ttsl} (100%) rename packages/ttsl-lang/tests/resources/grammar/declarations/data/{good-with type and name.tsltest => good-with type and name.ttsl} (100%) rename packages/ttsl-lang/tests/resources/grammar/declarations/functions/{bad-missing functionbody.tsltest => bad-missing functionbody.ttsl} (100%) rename packages/ttsl-lang/tests/resources/grammar/declarations/functions/{bad-missing parameter list.tsltest => bad-missing parameter list.ttsl} (100%) rename packages/ttsl-lang/tests/resources/grammar/declarations/functions/{bad-missing parameter type.tsltest => bad-missing parameter type.ttsl} (100%) rename packages/ttsl-lang/tests/resources/grammar/declarations/functions/{bad-unclosed parameter list.tsltest => bad-unclosed parameter list.ttsl} (100%) rename packages/ttsl-lang/tests/resources/grammar/declarations/functions/{bad-unclosed result list.tsltest => bad-unclosed result list.ttsl} (100%) rename packages/ttsl-lang/tests/resources/grammar/declarations/functions/{good-annotation call.tsltest => good-annotation call.ttsl} (100%) rename packages/ttsl-lang/tests/resources/grammar/declarations/functions/{good-with parameter list.tsltest => good-with parameter list.ttsl} (100%) rename packages/ttsl-lang/tests/resources/grammar/declarations/functions/{good-with result list.tsltest => good-with result list.ttsl} (100%) rename packages/ttsl-lang/tests/resources/grammar/declarations/functions/{good-with type parameter list.tsltest => good-with type parameter list.ttsl} (100%) rename packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/{bad-with else missing elseblock.tsltest => bad-with else missing elseblock.ttsl} (100%) rename packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/{bad-without else missing block.tsltest => bad-without else missing block.ttsl} (100%) rename packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/{bad-without else missing condition.tsltest => bad-without else missing condition.ttsl} (100%) rename packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/{good-with else false.tsltest => good-with else false.ttsl} (100%) rename packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/{good-with else true.tsltest => good-with else true.ttsl} (100%) rename packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/{good-without else.tsltest => good-without else.ttsl} (100%) diff --git a/docs/development/call-graph-testing.md b/docs/development/call-graph-testing.md index 5c497fce..0e4098a8 100644 --- a/docs/development/call-graph-testing.md +++ b/docs/development/call-graph-testing.md @@ -5,7 +5,7 @@ graph test. ## Adding a call graph test -1. Create a new file with the extension `.Tsltest` in the `tests/resources/call graph` directory or any subdirectory. +1. Create a new file with the extension `.ttsl` in the `tests/resources/call graph` directory or any subdirectory. Give the file a descriptive name, since the file name becomes part of the test name. !!! tip "Skipping a test" diff --git a/docs/development/formatting-testing.md b/docs/development/formatting-testing.md index faad08d6..3f78133c 100644 --- a/docs/development/formatting-testing.md +++ b/docs/development/formatting-testing.md @@ -5,7 +5,7 @@ formatting test. ## Adding a formatting test -1. Create a new file with the extension `.Tsltest` in the `tests/resources/formatting` directory or any subdirectory. +1. Create a new file with the extension `.ttsl` in the `tests/resources/formatting` directory or any subdirectory. Give the file a descriptive name, since the file name becomes part of the test name. !!! tip "Skipping a test" diff --git a/docs/development/generation-testing.md b/docs/development/generation-testing.md index 5bb97e77..e098ec80 100644 --- a/docs/development/generation-testing.md +++ b/docs/development/generation-testing.md @@ -14,7 +14,7 @@ generation test. If you want to skip a test, add the prefix `skip-` to the folder name. -2. Add files with the extension `.Tsltest`, `.Tslpipe`, or `.Tslstub` **directly inside the folder**. All files in a +2. Add files with the extension `.ttsl`, `.Tslpipe`, or `.Tslstub` **directly inside the folder**. All files in a folder will be loaded into the same workspace, so they can reference each other. Files in different folders are loaded into different workspaces, so they cannot reference each other. Generation will be triggered for all files in the folder. diff --git a/docs/development/grammar-testing.md b/docs/development/grammar-testing.md index 99bfe195..4f681d6c 100644 --- a/docs/development/grammar-testing.md +++ b/docs/development/grammar-testing.md @@ -5,7 +5,7 @@ test. ## Adding a grammar test -1. Create a new file with the extension `.Tsltest` in the `tests/resources/grammar` directory or any subdirectory. Give +1. Create a new file with the extension `.ttsl` in the `tests/resources/grammar` directory or any subdirectory. Give the file a descriptive name, since the file name becomes part of the test name. !!! note "Naming convention" diff --git a/docs/development/partial-evaluation-testing.md b/docs/development/partial-evaluation-testing.md index aae92008..526a5f85 100644 --- a/docs/development/partial-evaluation-testing.md +++ b/docs/development/partial-evaluation-testing.md @@ -12,7 +12,7 @@ partial evaluation test. If you want to skip a test, add the prefix `skip-` to the folder name. -2. Add files with the extension `.Tsltest` **directly inside the folder**. All files in a folder will be loaded into the +2. Add files with the extension `.ttsl` **directly inside the folder**. All files in a folder will be loaded into the same workspace, so they can reference each other. Files in different folders are loaded into different workspaces, so they cannot reference each other. 3. Add the Safe-DS code that you want to test to the files. diff --git a/docs/development/scoping-testing.md b/docs/development/scoping-testing.md index 854b1fcb..db1701ef 100644 --- a/docs/development/scoping-testing.md +++ b/docs/development/scoping-testing.md @@ -12,7 +12,7 @@ test. If you want to skip a test, add the prefix `skip-` to the folder name. -2. Add files with the extension `.Tsltest` **directly inside +2. Add files with the extension `.ttsl` **directly inside the folder**. All files in a folder will be loaded into the same workspace, so they can reference each other. Files in different folders are loaded into different workspaces, so they cannot reference each other. 3. Add the Safe-DS code that you want to test to the files. diff --git a/docs/development/typing-testing.md b/docs/development/typing-testing.md index 6f5405bb..daef3682 100644 --- a/docs/development/typing-testing.md +++ b/docs/development/typing-testing.md @@ -12,7 +12,7 @@ test. If you want to skip a test, add the prefix `skip-` to the folder name. -2. Add files with the extension `.Tsltest` **directly inside the folder**. All files in a folder will be loaded into the +2. Add files with the extension `.ttsl` **directly inside the folder**. All files in a folder will be loaded into the same workspace, so they can reference each other. Files in different folders are loaded into different workspaces, so they cannot reference each other. 3. Add the Safe-DS code that you want to test to the files. diff --git a/docs/development/validation-testing.md b/docs/development/validation-testing.md index 7b8b5be3..d7c38d36 100644 --- a/docs/development/validation-testing.md +++ b/docs/development/validation-testing.md @@ -12,7 +12,7 @@ validation test. If you want to skip a test, add the prefix `skip-` to the folder name. -2. Add files with the extension `.Tsltest`, `.Tslpipe`, or `.Tslstub` **directly inside the folder**. All files in a +2. Add files with the extension `.ttsl`, `.Tslpipe`, or `.Tslstub` **directly inside the folder**. All files in a folder will be loaded into the same workspace, so they can reference each other. Files in different folders are loaded into different workspaces, so they cannot reference each other. 3. Add the Safe-DS code that you want to test to the files. diff --git a/packages/ttsl-cli/tests/cli/main.test.ts b/packages/ttsl-cli/tests/cli/main.test.ts index 9b24f29e..1903baa1 100644 --- a/packages/ttsl-cli/tests/cli/main.test.ts +++ b/packages/ttsl-cli/tests/cli/main.test.ts @@ -63,25 +63,25 @@ describe('safe-ds', () => { }); it('should show not show errors in correct files', () => { - const process = spawnCheckProcess([], ['correct.Tsltest']); + const process = spawnCheckProcess([], ['correct.ttsl']); expect(process.stdout.toString()).toContain('No errors found.'); expect(process.status).toBe(ExitCode.Success); }); it('should handle references to builtins', () => { - const process = spawnCheckProcess([], ['references builtins.Tsltest']); + const process = spawnCheckProcess([], ['references builtins.ttsl']); expect(process.stdout.toString()).toContain('No errors found.'); expect(process.status).toBe(ExitCode.Success); }); it('should treat warnings as errors in strict mode', () => { - const process = spawnCheckProcess(['-s'], ['contains warnings.Tsltest']); + const process = spawnCheckProcess(['-s'], ['contains warnings.ttsl']); expect(process.stderr.toString()).toMatch(/Found \d+ errors?\./u); expect(process.status).toBe(ExitCode.FileHasErrors); }); it('should show an error if the file does not exist', () => { - const process = spawnCheckProcess([], ['missing.Tsltest']); + const process = spawnCheckProcess([], ['missing.ttsl']); expect(process.stderr.toString()).toMatch(/Path .* does not exist\./u); expect(process.status).toBe(ExitCode.MissingPath); }); @@ -121,13 +121,13 @@ describe('safe-ds', () => { }); it('should show not show errors in correct files', () => { - const process = spawnFormatProcess([], ['correct.Tsltest']); + const process = spawnFormatProcess([], ['correct.ttsl']); expect(process.stdout.toString()).toContain('Safe-DS code formatted successfully.'); expect(process.status).toBe(ExitCode.Success); }); it('should show an error if the file does not exist', () => { - const process = spawnFormatProcess([], ['missing.Tsltest']); + const process = spawnFormatProcess([], ['missing.ttsl']); expect(process.stderr.toString()).toMatch(/Path .* does not exist\./u); expect(process.status).toBe(ExitCode.MissingPath); }); @@ -165,19 +165,19 @@ describe('safe-ds', () => { }); it('should generate Python code', () => { - const process = spawnGenerateProcess([], ['correct.Tsltest']); + const process = spawnGenerateProcess([], ['correct.ttsl']); expect(process.stdout.toString()).toContain('Python code generated successfully.'); expect(process.status).toBe(ExitCode.Success); }); it('should generate Python code (Safe-DS code references builtins)', () => { - const process = spawnGenerateProcess([], ['references builtins.Tsltest']); + const process = spawnGenerateProcess([], ['references builtins.ttsl']); expect(process.stdout.toString()).toContain('Python code generated successfully.'); expect(process.status).toBe(ExitCode.Success); }); it('should show an error if the file does not exist', () => { - const process = spawnGenerateProcess([], ['missing.Tsltest']); + const process = spawnGenerateProcess([], ['missing.ttsl']); expect(process.stderr.toString()).toMatch(/Path .* does not exist./u); expect(process.status).toBe(ExitCode.MissingPath); }); diff --git a/packages/ttsl-cli/tests/helpers/diagnostics.test.ts b/packages/ttsl-cli/tests/helpers/diagnostics.test.ts index 085a3403..abdd3a30 100644 --- a/packages/ttsl-cli/tests/helpers/diagnostics.test.ts +++ b/packages/ttsl-cli/tests/helpers/diagnostics.test.ts @@ -26,7 +26,7 @@ describe('diagnosticToString', () => { range, message, }, - expected: chalk.red(`test.Tsltest:1:1: [error] message`), + expected: chalk.red(`test.ttsl:1:1: [error] message`), }, { testName: 'warning', @@ -35,7 +35,7 @@ describe('diagnosticToString', () => { range, message, }, - expected: chalk.yellow(`test.Tsltest:1:1: [warning] message`), + expected: chalk.yellow(`test.ttsl:1:1: [warning] message`), }, { testName: 'warning (strict)', @@ -47,7 +47,7 @@ describe('diagnosticToString', () => { options: { strict: true, }, - expected: chalk.red(`test.Tsltest:1:1: [warning] message`), + expected: chalk.red(`test.ttsl:1:1: [warning] message`), }, { testName: 'info', @@ -56,7 +56,7 @@ describe('diagnosticToString', () => { range, message, }, - expected: chalk.blue(`test.Tsltest:1:1: [info] message`), + expected: chalk.blue(`test.ttsl:1:1: [info] message`), }, { testName: 'hint', @@ -65,7 +65,7 @@ describe('diagnosticToString', () => { range, message, }, - expected: chalk.gray(`test.Tsltest:1:1: [hint] message`), + expected: chalk.gray(`test.ttsl:1:1: [hint] message`), }, { testName: 'with code', @@ -75,12 +75,12 @@ describe('diagnosticToString', () => { message, code: 'CODE', }, - expected: chalk.red(`test.Tsltest:1:1: [error] message (CODE)`), + expected: chalk.red(`test.ttsl:1:1: [error] message (CODE)`), }, ]; it.each(tests)('$testName', ({ diagnostic, options, expected }) => { - const uri = URI.file(path.join(process.cwd(), 'test.Tsltest')); + const uri = URI.file(path.join(process.cwd(), 'test.ttsl')); const actual = diagnosticToString(uri, diagnostic, options); expect(actual).toBe(expected); }); diff --git a/packages/ttsl-cli/tests/helpers/documents.test.ts b/packages/ttsl-cli/tests/helpers/documents.test.ts index 354fba54..d4b01851 100644 --- a/packages/ttsl-cli/tests/helpers/documents.test.ts +++ b/packages/ttsl-cli/tests/helpers/documents.test.ts @@ -24,13 +24,13 @@ describe('processPaths', async () => { }, { testName: 'test file', - paths: ['c.Tsltest'], - expected: Result.ok(['c.Tsltest']), + paths: ['c.ttsl'], + expected: Result.ok(['c.ttsl']), }, { testName: 'multiple files', - paths: ['a.Tslpipe', 'b.Tslstub', 'c.Tsltest'], - expected: Result.ok(['a.Tslpipe', 'b.Tslstub', 'c.Tsltest']), + paths: ['a.Tslpipe', 'b.Tslstub', 'c.ttsl'], + expected: Result.ok(['a.Tslpipe', 'b.Tslstub', 'c.ttsl']), }, { testName: 'duplicates', @@ -43,10 +43,10 @@ describe('processPaths', async () => { expected: Result.ok([ 'a.Tslpipe', 'b.Tslstub', - 'c.Tsltest', + 'c.ttsl', 'nested/a.Tslpipe', 'nested/b.Tslstub', - 'nested/c.Tsltest', + 'nested/c.ttsl', ]), }, { diff --git a/packages/ttsl-cli/tests/helpers/files.test.ts b/packages/ttsl-cli/tests/helpers/files.test.ts index e7a9bfee..4e72db24 100644 --- a/packages/ttsl-cli/tests/helpers/files.test.ts +++ b/packages/ttsl-cli/tests/helpers/files.test.ts @@ -5,7 +5,7 @@ import { uriToRelativePath } from '../../src/helpers/files.js'; describe('uriToRelativePath', () => { it('should return a path that is relative to the current working directory', () => { - const fileName = 'test.Tsltest'; + const fileName = 'test.ttsl'; const uri = URI.file(path.join(process.cwd(), fileName)); expect(uriToRelativePath(uri)).toBe(fileName); diff --git a/packages/ttsl-lang/src/language/helpers/fileExtensions.ts b/packages/ttsl-lang/src/language/helpers/fileExtensions.ts index 53aee54b..f4986c8f 100644 --- a/packages/ttsl-lang/src/language/helpers/fileExtensions.ts +++ b/packages/ttsl-lang/src/language/helpers/fileExtensions.ts @@ -23,7 +23,7 @@ export const STUB_FILE_EXTENSION = 'Tslstub'; * @see isInTestFile * @see isTestFile */ -export const TEST_FILE_EXTENSION = 'Tsltest'; +export const TEST_FILE_EXTENSION = 'ttsl'; /** * All file extensions that are supported by the Safe-DS language. diff --git a/packages/ttsl-lang/tests/helpers/__snapshots__/nodeFinder.test.ts.snap b/packages/ttsl-lang/tests/helpers/__snapshots__/nodeFinder.test.ts.snap index 743aaa89..2ab7b58f 100644 --- a/packages/ttsl-lang/tests/helpers/__snapshots__/nodeFinder.test.ts.snap +++ b/packages/ttsl-lang/tests/helpers/__snapshots__/nodeFinder.test.ts.snap @@ -1,6 +1,6 @@ // Vitest Snapshot v1, https://vitest.dev/guide/snapshot.html -exports[`getNodeByLocation > should throw if no document is found 1`] = `[AssertionError: No document found at file:///test.Tsltest]`; +exports[`getNodeByLocation > should throw if no document is found 1`] = `[AssertionError: No document found at file:///test.ttsl]`; exports[`getNodeOfType > should throw if no node is found 1`] = `[AssertionError: Expected to find a matching node but found none.]`; diff --git a/packages/ttsl-lang/tests/helpers/diagnostics.ts b/packages/ttsl-lang/tests/helpers/diagnostics.ts index 9ac70edd..59ac5efe 100644 --- a/packages/ttsl-lang/tests/helpers/diagnostics.ts +++ b/packages/ttsl-lang/tests/helpers/diagnostics.ts @@ -64,7 +64,7 @@ export const getErrorsAtURI = (services: LangiumServices, uri: URI): Diagnostic[ const getDiagnostics = async (services: LangiumServices, code: string): Promise => { const parse = parseHelper(services); const document = await parse(code, { - documentUri: `file:///$autogen$${nextId++}.Tsltest`, + documentUri: `file:///$autogen$${nextId++}.ttsl`, validation: true, }); return document.diagnostics ?? []; diff --git a/packages/ttsl-lang/tests/helpers/locations.test.ts b/packages/ttsl-lang/tests/helpers/locations.test.ts index 29151c9c..b8573548 100644 --- a/packages/ttsl-lang/tests/helpers/locations.test.ts +++ b/packages/ttsl-lang/tests/helpers/locations.test.ts @@ -35,17 +35,17 @@ describe('locationToString', () => { it.each([ { location: { - uri: 'file:///test.Tsltest', + uri: 'file:///test.ttsl', range: { start: { line: 0, character: 0 }, end: { line: 0, character: 0 } }, }, - expected: 'file:///test.Tsltest:1:1 -> 1:1', + expected: 'file:///test.ttsl:1:1 -> 1:1', }, { location: { - uri: 'file:///test.Tsltest', + uri: 'file:///test.ttsl', range: { start: { line: 0, character: 0 }, end: { line: 1, character: 0 } }, }, - expected: 'file:///test.Tsltest:1:1 -> 2:1', + expected: 'file:///test.ttsl:1:1 -> 2:1', }, ])(`should convert location to string ($expected)`, ({ location, expected }) => { expect(locationToString(location)).toBe(expected); @@ -56,11 +56,11 @@ describe('isLocationEqual', () => { it.each([ { location1: { - uri: 'file:///test.Tsltest', + uri: 'file:///test.ttsl', range: { start: { line: 0, character: 0 }, end: { line: 0, character: 0 } }, }, location2: { - uri: 'file:///test.Tsltest', + uri: 'file:///test.ttsl', range: { start: { line: 0, character: 0 }, end: { line: 0, character: 0 } }, }, expected: true, @@ -68,11 +68,11 @@ describe('isLocationEqual', () => { }, { location1: { - uri: 'file:///test.Tsltest', + uri: 'file:///test.ttsl', range: { start: { line: 0, character: 0 }, end: { line: 0, character: 0 } }, }, location2: { - uri: 'file:///test2.Tsltest', + uri: 'file:///test2.ttsl', range: { start: { line: 0, character: 0 }, end: { line: 0, character: 0 } }, }, expected: false, @@ -80,11 +80,11 @@ describe('isLocationEqual', () => { }, { location1: { - uri: 'file:///test.Tsltest', + uri: 'file:///test.ttsl', range: { start: { line: 0, character: 0 }, end: { line: 0, character: 0 } }, }, location2: { - uri: 'file:///test.Tsltest', + uri: 'file:///test.ttsl', range: { start: { line: 0, character: 0 }, end: { line: 1, character: 0 } }, }, expected: false, diff --git a/packages/ttsl-lang/tests/helpers/nodeFinder.test.ts b/packages/ttsl-lang/tests/helpers/nodeFinder.test.ts index 3878cd2a..2bd9133a 100644 --- a/packages/ttsl-lang/tests/helpers/nodeFinder.test.ts +++ b/packages/ttsl-lang/tests/helpers/nodeFinder.test.ts @@ -16,7 +16,7 @@ describe('getNodeByLocation', async () => { it('should throw if no document is found', () => { expect(() => { getNodeByLocation(services, { - uri: 'file:///test.Tsltest', + uri: 'file:///test.ttsl', range: { start: { line: 0, character: 0 }, end: { line: 0, character: 0 } }, }); }).toThrowErrorMatchingSnapshot(); diff --git a/packages/ttsl-lang/tests/helpers/testChecks.test.ts b/packages/ttsl-lang/tests/helpers/testChecks.test.ts index 1d789e94..f3a55f6b 100644 --- a/packages/ttsl-lang/tests/helpers/testChecks.test.ts +++ b/packages/ttsl-lang/tests/helpers/testChecks.test.ts @@ -10,7 +10,7 @@ import { import { Range } from 'vscode-languageserver'; import { URI } from 'langium'; -const uri = 'file:///test.Tsltest'; +const uri = 'file:///test.ttsl'; describe('findTestChecks', () => { it.each([ diff --git a/packages/ttsl-lang/tests/helpers/testResources.test.ts b/packages/ttsl-lang/tests/helpers/testResources.test.ts index 0c1f4f5b..38099123 100644 --- a/packages/ttsl-lang/tests/helpers/testResources.test.ts +++ b/packages/ttsl-lang/tests/helpers/testResources.test.ts @@ -31,10 +31,10 @@ describe('listTestSafeDsFiles', () => { const expected = [ 'pipeline file.Tslpipe', 'stub file.Tslstub', - 'test file.Tsltest', + 'test file.ttsl', 'nested/pipeline file.Tslpipe', 'nested/stub file.Tslstub', - 'nested/test file.Tsltest', + 'nested/test file.ttsl', ]; expectFileListsToMatch(rootResourceName, actual, expected); @@ -65,7 +65,7 @@ describe('listTestSafeDsFilesGroupedByParentDirectory', () => { const actualValuesDirectlyInRoot = [...result.entries()].find( ([key]) => uriToShortenedTestResourceName(key, rootResourceName) === '', )!; - const expectedValuesDirectlyInRoot = ['pipeline file.Tslpipe', 'stub file.Tslstub', 'test file.Tsltest']; + const expectedValuesDirectlyInRoot = ['pipeline file.Tslpipe', 'stub file.Tslstub', 'test file.ttsl']; expectFileListsToMatch(rootResourceName, actualValuesDirectlyInRoot[1], expectedValuesDirectlyInRoot); // Compare the values, i.e. the files, in the nested directory @@ -75,7 +75,7 @@ describe('listTestSafeDsFilesGroupedByParentDirectory', () => { const expectedValuesInNested = [ 'nested/pipeline file.Tslpipe', 'nested/stub file.Tslstub', - 'nested/test file.Tsltest', + 'nested/test file.ttsl', ]; expectFileListsToMatch(rootResourceName, actualValuesInNested[1], expectedValuesInNested); }); diff --git a/packages/ttsl-lang/tests/language/lsp/safe-ds-inlay-hint-provider.test.ts b/packages/ttsl-lang/tests/language/lsp/safe-ds-inlay-hint-provider.test.ts index f0ac8434..79999d3f 100644 --- a/packages/ttsl-lang/tests/language/lsp/safe-ds-inlay-hint-provider.test.ts +++ b/packages/ttsl-lang/tests/language/lsp/safe-ds-inlay-hint-provider.test.ts @@ -188,7 +188,7 @@ const getActualSimpleInlayHints = async (code: string): Promise { - const testChecks = findTestChecks(code, URI.file('file:///test.Tsltest'), { failIfFewerRangesThanComments: true }); + const testChecks = findTestChecks(code, URI.file('file:///test.ttsl'), { failIfFewerRangesThanComments: true }); if (testChecks.isErr) { throw new Error(testChecks.error.message); } diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/constant/generated/tests/generator/const/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/declarations/constant/generated/tests/generator/const/gen_input.py.map index 7d71d49e..44ddca76 100644 --- a/packages/ttsl-lang/tests/resources/generation/declarations/constant/generated/tests/generator/const/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/declarations/constant/generated/tests/generator/const/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.Tsltest"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAEA,OAAA,+BAAqB,CAAC","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAEA,OAAA,+BAAqB,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/constant/input.Tsltest b/packages/ttsl-lang/tests/resources/generation/declarations/constant/input.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/generation/declarations/constant/input.Tsltest rename to packages/ttsl-lang/tests/resources/generation/declarations/constant/input.ttsl diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/data/generated/tests/generator/datas/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/declarations/data/generated/tests/generator/datas/gen_input.py.map index e0c06218..f2c47116 100644 --- a/packages/ttsl-lang/tests/resources/generation/declarations/data/generated/tests/generator/datas/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/declarations/data/generated/tests/generator/datas/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.Tsltest"],"names":[],"mappings":"AAAA","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":[],"mappings":"AAAA","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/data/input.Tsltest b/packages/ttsl-lang/tests/resources/generation/declarations/data/input.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/generation/declarations/data/input.Tsltest rename to packages/ttsl-lang/tests/resources/generation/declarations/data/input.ttsl diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/empty function/generated/tests/generator/emptyFunction/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/declarations/empty function/generated/tests/generator/emptyFunction/gen_input.py.map index e4736f07..29450d7f 100644 --- a/packages/ttsl-lang/tests/resources/generation/declarations/empty function/generated/tests/generator/emptyFunction/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/declarations/empty function/generated/tests/generator/emptyFunction/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.Tsltest"],"names":["test"],"mappings":"AAAA;;AAEA,IAASA,IAAI;IAAG,IAAE","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["test"],"mappings":"AAAA;;AAEA,IAASA,IAAI;IAAG,IAAE","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/empty function/input.Tsltest b/packages/ttsl-lang/tests/resources/generation/declarations/empty function/input.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/generation/declarations/empty function/input.Tsltest rename to packages/ttsl-lang/tests/resources/generation/declarations/empty function/input.ttsl diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/empty pipeline/generated/tests/generator/emptyPipeline/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/declarations/empty pipeline/generated/tests/generator/emptyPipeline/gen_input.py.map index ff83d01e..684798b7 100644 --- a/packages/ttsl-lang/tests/resources/generation/declarations/empty pipeline/generated/tests/generator/emptyPipeline/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/declarations/empty pipeline/generated/tests/generator/emptyPipeline/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.Tsltest"],"names":["test"],"mappings":"AAAA;;AAEA,IAASA,IAAI;IAAC,IAAE","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["test"],"mappings":"AAAA;;AAEA,IAASA,IAAI;IAAC,IAAE","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/empty segment/generated/tests/generator/emptySegment/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/declarations/empty segment/generated/tests/generator/emptySegment/gen_input.py.map index 6de88b5a..a0aaca09 100644 --- a/packages/ttsl-lang/tests/resources/generation/declarations/empty segment/generated/tests/generator/emptySegment/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/declarations/empty segment/generated/tests/generator/emptySegment/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.Tsltest"],"names":["test"],"mappings":"AAAA;;AAEA,IAAQA,IAAI;IAAG,IAAE","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["test"],"mappings":"AAAA;;AAEA,IAAQA,IAAI;IAAG,IAAE","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/function with parameter/generated/tests/generator/functionWithParameter/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/declarations/function with parameter/generated/tests/generator/functionWithParameter/gen_input.py.map index b3c2d9bb..76147013 100644 --- a/packages/ttsl-lang/tests/resources/generation/declarations/function with parameter/generated/tests/generator/functionWithParameter/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/declarations/function with parameter/generated/tests/generator/functionWithParameter/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.Tsltest"],"names":["test","x","y"],"mappings":"AAAA;;AAEA,IAASA,IAAI,CAACC,CAAC,EAAOC,CAAC;IAAO,IAAE","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["test","x","y"],"mappings":"AAAA;;AAEA,IAASA,IAAI,CAACC,CAAC,EAAOC,CAAC;IAAO,IAAE","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/function with parameter/input.Tsltest b/packages/ttsl-lang/tests/resources/generation/declarations/function with parameter/input.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/generation/declarations/function with parameter/input.Tsltest rename to packages/ttsl-lang/tests/resources/generation/declarations/function with parameter/input.ttsl diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/function with return Value/generated/tests/generator/functionWithReturnValue/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/declarations/function with return Value/generated/tests/generator/functionWithReturnValue/gen_input.py.map index bdd7d925..4bfc54f8 100644 --- a/packages/ttsl-lang/tests/resources/generation/declarations/function with return Value/generated/tests/generator/functionWithReturnValue/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/declarations/function with return Value/generated/tests/generator/functionWithReturnValue/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.Tsltest"],"names":["test"],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAEA,IAASA,IAAI;;;;;;AAIb,IAAA,+BAAkBA,IAAI","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["test"],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAEA,IAASA,IAAI;;;;;;AAIb,IAAA,+BAAkBA,IAAI","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/function with return Value/input.Tsltest b/packages/ttsl-lang/tests/resources/generation/declarations/function with return Value/input.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/generation/declarations/function with return Value/input.Tsltest rename to packages/ttsl-lang/tests/resources/generation/declarations/function with return Value/input.ttsl diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/parameter with python name/generated/tests/generator/parameterWithPythonName/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/declarations/parameter with python name/generated/tests/generator/parameterWithPythonName/gen_input.py.map index 84eca513..33900acf 100644 --- a/packages/ttsl-lang/tests/resources/generation/declarations/parameter with python name/generated/tests/generator/parameterWithPythonName/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/declarations/parameter with python name/generated/tests/generator/parameterWithPythonName/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.Tsltest"],"names":["test","param1","param2","param3","f1","a","b","c","f2"],"mappings":"AAAA;;AAKA,IAAQA,IAAI,CAACC,MAAM,EAA8BC,OAAM,EAA8BC,OAAM,CAAQ,CAAC;IAChGC,EAAE,CAAC,OAACC,CAAC,EAAOC,CAAC,EAAOC,CAAC,CAAQ,CAAC,EAAK,CAAC;IACjC,yBAACF,CAAC,EAAOC,CAAC,EAAOC,CAAC,CAAQ,CAAC;QAAE,IAAE;IAAlCC,EAAE,CAAC","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["test","param1","param2","param3","f1","a","b","c","f2"],"mappings":"AAAA;;AAKA,IAAQA,IAAI,CAACC,MAAM,EAA8BC,OAAM,EAA8BC,OAAM,CAAQ,CAAC;IAChGC,EAAE,CAAC,OAACC,CAAC,EAAOC,CAAC,EAAOC,CAAC,CAAQ,CAAC,EAAK,CAAC;IACjC,yBAACF,CAAC,EAAOC,CAAC,EAAOC,CAAC,CAAQ,CAAC;QAAE,IAAE;IAAlCC,EAAE,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/pipeline with python name/generated/tests/generator/pipelineWithPythonName/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/declarations/pipeline with python name/generated/tests/generator/pipelineWithPythonName/gen_input.py.map index d9a1727d..0480f3c9 100644 --- a/packages/ttsl-lang/tests/resources/generation/declarations/pipeline with python name/generated/tests/generator/pipelineWithPythonName/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/declarations/pipeline with python name/generated/tests/generator/pipelineWithPythonName/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.Tsltest"],"names":["testpipeline","f"],"mappings":"AAAA;;AAKA,IAASA,aAAY;IACjBC,CAAC","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["testpipeline","f"],"mappings":"AAAA;;AAKA,IAASA,aAAY;IACjBC,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/segment with python name/generated/tests/generator/segmentWithPythonName/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/declarations/segment with python name/generated/tests/generator/segmentWithPythonName/gen_input.py.map index 28ef234b..54e89f45 100644 --- a/packages/ttsl-lang/tests/resources/generation/declarations/segment with python name/generated/tests/generator/segmentWithPythonName/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/declarations/segment with python name/generated/tests/generator/segmentWithPythonName/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.Tsltest"],"names":["testsegment","f"],"mappings":"AAAA;;AAKA,IAAQA,YAAW;IACfC,CAAC","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["testsegment","f"],"mappings":"AAAA;;AAKA,IAAQA,YAAW;IACfC,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/two pipelines/generated/tests/generator/twoPipelines/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/declarations/two pipelines/generated/tests/generator/twoPipelines/gen_input.py.map index 8857fa71..5f3b35a8 100644 --- a/packages/ttsl-lang/tests/resources/generation/declarations/two pipelines/generated/tests/generator/twoPipelines/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/declarations/two pipelines/generated/tests/generator/twoPipelines/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.Tsltest"],"names":["test1","f","test2"],"mappings":"AAAA;;AAIA,IAASA,KAAK;IACVC,CAAC;;AAGL,IAASC,KAAK;IACVD,CAAC","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["test1","f","test2"],"mappings":"AAAA;;AAIA,IAASA,KAAK;IACVC,CAAC;;AAGL,IAASC,KAAK;IACVD,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/two segments/generated/tests/generator/twoSegments/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/declarations/two segments/generated/tests/generator/twoSegments/gen_input.py.map index 3e9d8b94..94c870fe 100644 --- a/packages/ttsl-lang/tests/resources/generation/declarations/two segments/generated/tests/generator/twoSegments/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/declarations/two segments/generated/tests/generator/twoSegments/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.Tsltest"],"names":["test1","a","b","f","test2","c"],"mappings":"AAAA;;AAIA,IAAQA,KAAK,CAACC,CAAC,EAAOC,CAAC,CAAQ,CAAC;IAC5BC,CAAC;;AAGL,IAAQC,KAAK,CAACH,CAAC,EAAOI,CAAC;IACnBF,CAAC","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["test1","a","b","f","test2","c"],"mappings":"AAAA;;AAIA,IAAQA,KAAK,CAACC,CAAC,EAAOC,CAAC,CAAQ,CAAC;IAC5BC,CAAC;;AAGL,IAAQC,KAAK,CAACH,CAAC,EAAOI,CAAC;IACnBF,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/generated/tests/generator/aggregation/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/generated/tests/generator/aggregation/gen_input.py.map index a8ab8a40..bdee83c8 100644 --- a/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/generated/tests/generator/aggregation/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/generated/tests/generator/aggregation/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.Tsltest"],"names":["testfunction"],"mappings":"AAAA;;AAKA,IAASA,YAAY;IAAoB","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["testfunction"],"mappings":"AAAA;;AAKA,IAASA,YAAY;IAAoB","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/input.Tsltest b/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/input.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/generation/expressions/aggregation/input.Tsltest rename to packages/ttsl-lang/tests/resources/generation/expressions/aggregation/input.ttsl diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/block lambda result/generated/tests/generator/blockLambdaResult/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/expressions/block lambda result/generated/tests/generator/blockLambdaResult/gen_input.py.map index 311a2a0f..3ebd268f 100644 --- a/packages/ttsl-lang/tests/resources/generation/expressions/block lambda result/generated/tests/generator/blockLambdaResult/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/expressions/block lambda result/generated/tests/generator/blockLambdaResult/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.Tsltest"],"names":["f1","l","h","f2","e1","d1","test","a","b","d","g","e"],"mappings":"AAAA;;AAMA,IAAQA,EAAE,CAACC,CAAC;IACRC,CAAC,CAACD,CAAC,CAAC,CAAC,EAAE,CAAC;;AAGZ,IAAQE,EAAE,CAACF,CAAC;IACRC,CAAC,CAACD,CAAC,CAAC,CAAC,EAAE,CAAC,EAAEG,CAAE;IACZF,CAAC,CAACD,CAAC,CAAC,CAAC,EAAE,CAAC,EAAEI,CAAE;;;;AAGhB,IAASC,IAAI;IAEN,yBAACC,CAAC,EAAOC,CAAC;QACT,0BAAMC,CAAC,GAAGC,CAAC;QADZ,OACC,0BAAMD,CAAC;IADXT,EAAE,CAAC;IAGA,yBAACO,CAAC,EAAOC,CAAC;QACT,0BAAMC,CAAC,GAAGC,CAAC;QACX,0BAAMC,CAAC,GAAGD,CAAC;QAFZ,OACC,0BAAMD,CAAC,EACP,0BAAME,CAAC;IAFXR,EAAE,CAAC","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["f1","l","h","f2","e1","d1","test","a","b","d","g","e"],"mappings":"AAAA;;AAMA,IAAQA,EAAE,CAACC,CAAC;IACRC,CAAC,CAACD,CAAC,CAAC,CAAC,EAAE,CAAC;;AAGZ,IAAQE,EAAE,CAACF,CAAC;IACRC,CAAC,CAACD,CAAC,CAAC,CAAC,EAAE,CAAC,EAAEG,CAAE;IACZF,CAAC,CAACD,CAAC,CAAC,CAAC,EAAE,CAAC,EAAEI,CAAE;;;;AAGhB,IAASC,IAAI;IAEN,yBAACC,CAAC,EAAOC,CAAC;QACT,0BAAMC,CAAC,GAAGC,CAAC;QADZ,OACC,0BAAMD,CAAC;IADXT,EAAE,CAAC;IAGA,yBAACO,CAAC,EAAOC,CAAC;QACT,0BAAMC,CAAC,GAAGC,CAAC;QACX,0BAAMC,CAAC,GAAGD,CAAC;QAFZ,OACC,0BAAMD,CAAC,EACP,0BAAME,CAAC;IAFXR,EAAE,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/block lambda/generated/tests/generator/blockLambda/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/expressions/block lambda/generated/tests/generator/blockLambda/gen_input.py.map index 5b1f0e78..1e279783 100644 --- a/packages/ttsl-lang/tests/resources/generation/expressions/block lambda/generated/tests/generator/blockLambda/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/expressions/block lambda/generated/tests/generator/blockLambda/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.Tsltest"],"names":["test","a","b","d","g","f1","f2","g2","f3","c"],"mappings":"AAAA;;AASA,IAASA,IAAI;IACN,yBAACC,CAAC,EAAOC,CAAC,CAAQ,CAAC;QAClB,0BAAMC,CAAC,GAAGC,CAAC;QADZ,OACC,0BAAMD,CAAC;IADXE,EAAE,CAAC;IAGA,yBAACJ,CAAC,EAAOC,CAAC;QACT,0BAAMC,CAAC,GAAGC,CAAC;QADZ,OACC,0BAAMD,CAAC;IADXE,EAAE,CAAC;IAGA;QAAG,IAAE;IAARC,EAAE,CAAC;IACG,yBAACL,CAAC,EAAOC,CAAC,CAAQ,CAAC;QACrB,0BAAMC,CAAC,GAAGC,CAAC;QADT,OACF,0BAAMD,CAAC;IADXI,EAAE,CAACC,EAAE,CAAC;IAGK,yBAACP,CAAC,EAAOC,CAAC,CAAQ,CAAC;QAC1B,0BAAMC,CAAC,GAAGC,CAAC;QADJ,OACP,0BAAMD,CAAC;IADX,IAAQK,EAAE,CAAC;IAGXD,EAAE,CAACE,CAAC","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["test","a","b","d","g","f1","f2","g2","f3","c"],"mappings":"AAAA;;AASA,IAASA,IAAI;IACN,yBAACC,CAAC,EAAOC,CAAC,CAAQ,CAAC;QAClB,0BAAMC,CAAC,GAAGC,CAAC;QADZ,OACC,0BAAMD,CAAC;IADXE,EAAE,CAAC;IAGA,yBAACJ,CAAC,EAAOC,CAAC;QACT,0BAAMC,CAAC,GAAGC,CAAC;QADZ,OACC,0BAAMD,CAAC;IADXE,EAAE,CAAC;IAGA;QAAG,IAAE;IAARC,EAAE,CAAC;IACG,yBAACL,CAAC,EAAOC,CAAC,CAAQ,CAAC;QACrB,0BAAMC,CAAC,GAAGC,CAAC;QADT,OACF,0BAAMD,CAAC;IADXI,EAAE,CAACC,EAAE,CAAC;IAGK,yBAACP,CAAC,EAAOC,CAAC,CAAQ,CAAC;QAC1B,0BAAMC,CAAC,GAAGC,CAAC;QADJ,OACP,0BAAMD,CAAC;IADX,IAAQK,EAAE,CAAC;IAGXD,EAAE,CAACE,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/call/generated/tests/generator/call/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/expressions/call/generated/tests/generator/call/gen_input.py.map index 3c1bdd37..05070f44 100644 --- a/packages/ttsl-lang/tests/resources/generation/expressions/call/generated/tests/generator/call/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/expressions/call/generated/tests/generator/call/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.Tsltest"],"names":["test","f","g","param2","h","i","j","k"],"mappings":"AAAA;;;;;;;;;;;;;;;AA0BA,IAASA,IAAI;IACTC,CAAC,CAAEC,CAAC,CAAC,CAAC,EArBNC,MAAM,CAqBE,CAAC;IACTF,CAAC,CAAEC,CAAC,CAAsB,CAAC,EAtB3BC,MAAM,CAsBQ,CAAC;IACfF,CAAC,CAAEG,CAAC,CAAC,CAAC,EAlBiBD,OAAM,CAkBrB,CAAC;IACTF,CAAC,CAAEG,CAAC,CAAsB,CAAC,EAnBJD,OAAM,CAmBf,CAAC;IACfF,CAAC,CAAEG,CAAC,CAAU,CAAC;IACb,KAAK;IACL,KAAK,GAAE,GAAG;IACZ,EAAQ,GAAG,EAAT,IAAI;IAEL,oBAAC,CAAFH,CAAC,UAADA,CAAC,CAAGC,CAAC,CAAC,CAAC,EA9BPC,MAAM,CA8BG,CAAC;IACT,oBAAC,CAAFF,CAAC,UAADA,CAAC,CAAGC,CAAC,CAAsB,CAAC,EA/B5BC,MAAM,CA+BS,CAAC;IACf,oBAAC,CAAFF,CAAC,UAADA,CAAC,CAAGG,CAAC,CAAC,CAAC,EA3BgBD,OAAM,CA2BpB,CAAC;IACT,oBAAC,CAAFF,CAAC,UAADA,CAAC,CAAGG,CAAC,CAAsB,CAAC,EA5BLD,OAAM,CA4Bd,CAAC;IACf,oBAAC,CAAFF,CAAC,UAADA,CAAC,CAAGG,CAAC,CAAU,CAAC;IACf,oBAAC,CAAFC,CAAC,UAAE,KAAK;IACP,oBAAC,CAAFC,CAAC,UAAE,KAAK,GAAE,GAAG;IACZ,oBAAC,CAAFC,CAAC,UAAD,EAAS,GAAG,EAAT,IAAI","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["test","f","g","param2","h","i","j","k"],"mappings":"AAAA;;;;;;;;;;;;;;;AA0BA,IAASA,IAAI;IACTC,CAAC,CAAEC,CAAC,CAAC,CAAC,EArBNC,MAAM,CAqBE,CAAC;IACTF,CAAC,CAAEC,CAAC,CAAsB,CAAC,EAtB3BC,MAAM,CAsBQ,CAAC;IACfF,CAAC,CAAEG,CAAC,CAAC,CAAC,EAlBiBD,OAAM,CAkBrB,CAAC;IACTF,CAAC,CAAEG,CAAC,CAAsB,CAAC,EAnBJD,OAAM,CAmBf,CAAC;IACfF,CAAC,CAAEG,CAAC,CAAU,CAAC;IACb,KAAK;IACL,KAAK,GAAE,GAAG;IACZ,EAAQ,GAAG,EAAT,IAAI;IAEL,oBAAC,CAAFH,CAAC,UAADA,CAAC,CAAGC,CAAC,CAAC,CAAC,EA9BPC,MAAM,CA8BG,CAAC;IACT,oBAAC,CAAFF,CAAC,UAADA,CAAC,CAAGC,CAAC,CAAsB,CAAC,EA/B5BC,MAAM,CA+BS,CAAC;IACf,oBAAC,CAAFF,CAAC,UAADA,CAAC,CAAGG,CAAC,CAAC,CAAC,EA3BgBD,OAAM,CA2BpB,CAAC;IACT,oBAAC,CAAFF,CAAC,UAADA,CAAC,CAAGG,CAAC,CAAsB,CAAC,EA5BLD,OAAM,CA4Bd,CAAC;IACf,oBAAC,CAAFF,CAAC,UAADA,CAAC,CAAGG,CAAC,CAAU,CAAC;IACf,oBAAC,CAAFC,CAAC,UAAE,KAAK;IACP,oBAAC,CAAFC,CAAC,UAAE,KAAK,GAAE,GAAG;IACZ,oBAAC,CAAFC,CAAC,UAAD,EAAS,GAAG,EAAT,IAAI","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/constant/generated/tests/generator/constant/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/expressions/constant/generated/tests/generator/constant/gen_input.py.map index ce504c14..84416565 100644 --- a/packages/ttsl-lang/tests/resources/generation/expressions/constant/generated/tests/generator/constant/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/expressions/constant/generated/tests/generator/constant/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.Tsltest"],"names":["test","f","null"],"mappings":"AAAA;;AAIA,IAASA,IAAI;IACTC,CAAC,CAAC;IACFA,CAAC,CAAC;IACFA,CAAC,CAAC;IACFA,CAAC,CAACC,IAAI;IACND,CAAC,CAAC","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["test","f","null"],"mappings":"AAAA;;AAIA,IAASA,IAAI;IACTC,CAAC,CAAC;IACFA,CAAC,CAAC;IACFA,CAAC,CAAC;IACFA,CAAC,CAACC,IAAI;IACND,CAAC,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/enum variant call/generated/tests/generator/enumVariantCall/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/expressions/enum variant call/generated/tests/generator/enumVariantCall/gen_input.py.map index 1a6302ec..6ce0b8a5 100644 --- a/packages/ttsl-lang/tests/resources/generation/expressions/enum variant call/generated/tests/generator/enumVariantCall/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/expressions/enum variant call/generated/tests/generator/enumVariantCall/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.Tsltest"],"names":["test","f","myenum","variant1","variant2"],"mappings":"AAAA;;AASA,IAASA,IAAI;IACVC,CAAC,CAACC,MAAM,CAACC,QAAQ;IACjBF,CAAC,CAACC,MAAM,CAAEC,QAAQ;IAClBF,CAAC,CAACC,MAAM,CAACC,QAAQ;IACjBF,CAAC,CAACC,MAAM,CAAEC,QAAQ;IAClBF,CAAC,CAACC,MAAM,CAACE,QAAQ,CAAC,CAAC;IACnBH,CAAC,CAACC,MAAM,CAAEE,QAAQ,CAAC,CAAC","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["test","f","myenum","variant1","variant2"],"mappings":"AAAA;;AASA,IAASA,IAAI;IACVC,CAAC,CAACC,MAAM,CAACC,QAAQ;IACjBF,CAAC,CAACC,MAAM,CAAEC,QAAQ;IAClBF,CAAC,CAACC,MAAM,CAACC,QAAQ;IACjBF,CAAC,CAACC,MAAM,CAAEC,QAAQ;IAClBF,CAAC,CAACC,MAAM,CAACE,QAAQ,CAAC,CAAC;IACnBH,CAAC,CAACC,MAAM,CAAEE,QAAQ,CAAC,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/expression lambda/generated/tests/generator/expressionLambda/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/expressions/expression lambda/generated/tests/generator/expressionLambda/gen_input.py.map index eab38869..3131f969 100644 --- a/packages/ttsl-lang/tests/resources/generation/expressions/expression lambda/generated/tests/generator/expressionLambda/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/expressions/expression lambda/generated/tests/generator/expressionLambda/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.Tsltest"],"names":["test","f","a","b"],"mappings":"AAAA;;AAIA,IAASA,IAAI;IACTC,CAAC,CAAC,OAACC,CAAC,EAAEC,CAAC,CAAG,CAAC,EAAK,CAAC;IACjBF,CAAC,CAAC,OAACC,CAAC,EAAEC,CAAC,EAAK,CAAC","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["test","f","a","b"],"mappings":"AAAA;;AAIA,IAASA,IAAI;IACTC,CAAC,CAAC,OAACC,CAAC,EAAEC,CAAC,CAAG,CAAC,EAAK,CAAC;IACjBF,CAAC,CAAC,OAACC,CAAC,EAAEC,CAAC,EAAK,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/indexed access/generated/tests/generator/indexedAccess/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/expressions/indexed access/generated/tests/generator/indexedAccess/gen_input.py.map index 0421ba7a..b7ef7248 100644 --- a/packages/ttsl-lang/tests/resources/generation/expressions/indexed access/generated/tests/generator/indexedAccess/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/expressions/indexed access/generated/tests/generator/indexedAccess/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.Tsltest"],"names":["test","param1","param2","f"],"mappings":"AAAA;;;;;;;;;;;;;;;AAIA,IAAQA,IAAI,CAACC,MAAM,EAAaC,MAAM;IAClCC,CAAC,CAACF,MAAM,CAAC,CAAC;IACVE,CAAC,CAAO,8BAAC,CAAPD,MAAM,EAAE,CAAC","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["test","param1","param2","f"],"mappings":"AAAA;;;;;;;;;;;;;;;AAIA,IAAQA,IAAI,CAACC,MAAM,EAAaC,MAAM;IAClCC,CAAC,CAACF,MAAM,CAAC,CAAC;IACVE,CAAC,CAAO,8BAAC,CAAPD,MAAM,EAAE,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/infix operation/generated/tests/generator/infixOperation/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/expressions/infix operation/generated/tests/generator/infixOperation/gen_input.py.map index 12fe8644..7910ca30 100644 --- a/packages/ttsl-lang/tests/resources/generation/expressions/infix operation/generated/tests/generator/infixOperation/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/expressions/infix operation/generated/tests/generator/infixOperation/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.Tsltest"],"names":["test","f","or","g","and","h","i"],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;AAUA,IAASA,IAAI;IACTC,CAAC,CAAKC,cAAE,CAANC,CAAC,IAAMA,CAAC;IACVF,CAAC,CAAKG,eAAG,CAAPD,CAAC,IAAOA,CAAC;IAEXF,CAAC,CAAC,CAAAI,CAAC,IAAG,EAAE,EAACA,CAAC;IACVJ,CAAC,CAAC,CAAAI,CAAC,IAAG,EAAE,EAACA,CAAC;IACVJ,CAAC,CAAC,CAAAI,CAAC,IAAG,EAAG,EAACA,CAAC;IACXJ,CAAC,CAAC,CAAAI,CAAC,IAAG,QAAIA,CAAC;IAEXJ,CAAC,CAAC,CAAAI,CAAC,IAAG,CAAC,EAACA,CAAC;IACTJ,CAAC,CAAC,CAAAI,CAAC,IAAG,EAAE,EAACA,CAAC;IACVJ,CAAC,CAAC,CAAAI,CAAC,IAAG,EAAE,EAACA,CAAC;IACVJ,CAAC,CAAC,CAAAI,CAAC,IAAG,CAAC,EAACA,CAAC;IAETJ,CAAC,CAAC,CAAAI,CAAC,IAAG,CAAC,EAACA,CAAC;IACTJ,CAAC,CAAC,CAAAI,CAAC,IAAG,CAAC,EAACA,CAAC;IACTJ,CAAC,CAAC,CAAAI,CAAC,IAAG,CAAC,EAACA,CAAC;IACTJ,CAAC,CAAC,CAAAI,CAAC,IAAG,CAAC,EAACA,CAAC;IAETJ,CAAC,CAAK,iBAAE,CAANK,CAAC,IAAMA,CAAC","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["test","f","or","g","and","h","i"],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;AAUA,IAASA,IAAI;IACTC,CAAC,CAAKC,cAAE,CAANC,CAAC,IAAMA,CAAC;IACVF,CAAC,CAAKG,eAAG,CAAPD,CAAC,IAAOA,CAAC;IAEXF,CAAC,CAAC,CAAAI,CAAC,IAAG,EAAE,EAACA,CAAC;IACVJ,CAAC,CAAC,CAAAI,CAAC,IAAG,EAAE,EAACA,CAAC;IACVJ,CAAC,CAAC,CAAAI,CAAC,IAAG,EAAG,EAACA,CAAC;IACXJ,CAAC,CAAC,CAAAI,CAAC,IAAG,QAAIA,CAAC;IAEXJ,CAAC,CAAC,CAAAI,CAAC,IAAG,CAAC,EAACA,CAAC;IACTJ,CAAC,CAAC,CAAAI,CAAC,IAAG,EAAE,EAACA,CAAC;IACVJ,CAAC,CAAC,CAAAI,CAAC,IAAG,EAAE,EAACA,CAAC;IACVJ,CAAC,CAAC,CAAAI,CAAC,IAAG,CAAC,EAACA,CAAC;IAETJ,CAAC,CAAC,CAAAI,CAAC,IAAG,CAAC,EAACA,CAAC;IACTJ,CAAC,CAAC,CAAAI,CAAC,IAAG,CAAC,EAACA,CAAC;IACTJ,CAAC,CAAC,CAAAI,CAAC,IAAG,CAAC,EAACA,CAAC;IACTJ,CAAC,CAAC,CAAAI,CAAC,IAAG,CAAC,EAACA,CAAC;IAETJ,CAAC,CAAK,iBAAE,CAANK,CAAC,IAAMA,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/lists/generated/tests/generator/lists/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/expressions/lists/generated/tests/generator/lists/gen_input.py.map index 540067ef..5ef3b43e 100644 --- a/packages/ttsl-lang/tests/resources/generation/expressions/lists/generated/tests/generator/lists/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/expressions/lists/generated/tests/generator/lists/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.Tsltest"],"names":["test","f","h"],"mappings":"AAAA;;AAMA,IAASA,IAAI;IACTC,CAAC,CAAC,EAAE;IACJA,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC;IACVA,CAAC,CAAC,CAAC,CAAC,EAAEC,CAAC,IAAI,CAAAA,CAAC,IAAG,CAAC,EAAC,CAAC","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["test","f","h"],"mappings":"AAAA;;AAMA,IAASA,IAAI;IACTC,CAAC,CAAC,EAAE;IACJA,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC;IACVA,CAAC,CAAC,CAAC,CAAC,EAAEC,CAAC,IAAI,CAAAA,CAAC,IAAG,CAAC,EAAC,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/literals/generated/tests/generator/literals/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/expressions/literals/generated/tests/generator/literals/gen_input.py.map index d8f15757..b4c2d5a0 100644 --- a/packages/ttsl-lang/tests/resources/generation/expressions/literals/generated/tests/generator/literals/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/expressions/literals/generated/tests/generator/literals/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.Tsltest"],"names":["test","f","true","false","null"],"mappings":"AAAA;;AAIA,IAASA,IAAI;IACTC,CAAC,CAACC,IAAI;IACND,CAAC,CAACE,KAAK;IACPF,CAAC,CAAC,GAAG;IACLA,CAAC,CAAC,CAAC;IACHA,CAAC,CAACG,IAAI;IACNH,CAAC,CAAC,EAAE;IACJA,CAAC,CAAC","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["test","f","true","false","null"],"mappings":"AAAA;;AAIA,IAASA,IAAI;IACTC,CAAC,CAACC,IAAI;IACND,CAAC,CAACE,KAAK;IACPF,CAAC,CAAC,GAAG;IACLA,CAAC,CAAC,CAAC;IACHA,CAAC,CAACG,IAAI;IACNH,CAAC,CAAC,EAAE;IACJA,CAAC,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/maps/generated/tests/generator/maps/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/expressions/maps/generated/tests/generator/maps/gen_input.py.map index 6c773b68..9a167ee3 100644 --- a/packages/ttsl-lang/tests/resources/generation/expressions/maps/generated/tests/generator/maps/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/expressions/maps/generated/tests/generator/maps/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.Tsltest"],"names":["test","g1","g2","h2","h1","g3"],"mappings":"AAAA;;AAYA,IAASA,IAAI;IACTC,EAAE,CAAC,EAAE;IACLC,EAAE,CAAC,CAAC,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG;IACtBA,EAAE,CAAC,CAACC,EAAE,IAAI,IAAI,EAAE,GAAG,EAAEC,EAAE;IACvBC,EAAE,CAAC,CAAC,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG;IACtBA,EAAE,CAAC,CAAC,GAAG,EAAE,GAAG,EAAED,EAAE,IAAID,EAAE","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["test","g1","g2","h2","h1","g3"],"mappings":"AAAA;;AAYA,IAASA,IAAI;IACTC,EAAE,CAAC,EAAE;IACLC,EAAE,CAAC,CAAC,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG;IACtBA,EAAE,CAAC,CAACC,EAAE,IAAI,IAAI,EAAE,GAAG,EAAEC,EAAE;IACvBC,EAAE,CAAC,CAAC,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG;IACtBA,EAAE,CAAC,CAAC,GAAG,EAAE,GAAG,EAAED,EAAE,IAAID,EAAE","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/member access/generated/tests/generator/memberAccess/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/expressions/member access/generated/tests/generator/memberAccess/gen_input.py.map index 91922594..66696844 100644 --- a/packages/ttsl-lang/tests/resources/generation/expressions/member access/generated/tests/generator/memberAccess/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/expressions/member access/generated/tests/generator/memberAccess/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.Tsltest"],"names":["test","f","g","h","result1","result2","c","a","b","factory","j","k","from_csv_file"],"mappings":"AAAA;;;;;;;;;;;;;;;AA4BA,IAASA,IAAI;IACTC,CAAC,CAACC,CAAC;IACHD,CAAC,CAACE,CAAC,GAAGC,CAAO;IACbH,CAAC,CAACE,CAAC,GAAGE,CAAO;IACbJ,CAAC,CAACK,CAAC,GAAGC,CAAC;IACPN,CAAC,CAACK,CAAC,GAAGE,CAAC;IACPP,CAAC,CAAU,6BAAC,CAAVQ,OAAO,KAAIF,CAAC;IACdN,CAAC,CAAU,6BAAC,CAAVQ,OAAO,KAAID,CAAC;IACdP,CAAC,CAAO,CAAC,GAAPK,CAAC;IACHL,CAAC,CAACK,CAAC,GAAGI,CAAC,CAAC,GAAG;IACXT,CAAC,CAACK,CAAC,GAAGK,EAAC,CAAC,KAAK;IACbV,CAAC,CAACK,CAAC,CAACM,aAAa,CAAC,SAAS","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["test","f","g","h","result1","result2","c","a","b","factory","j","k","from_csv_file"],"mappings":"AAAA;;;;;;;;;;;;;;;AA4BA,IAASA,IAAI;IACTC,CAAC,CAACC,CAAC;IACHD,CAAC,CAACE,CAAC,GAAGC,CAAO;IACbH,CAAC,CAACE,CAAC,GAAGE,CAAO;IACbJ,CAAC,CAACK,CAAC,GAAGC,CAAC;IACPN,CAAC,CAACK,CAAC,GAAGE,CAAC;IACPP,CAAC,CAAU,6BAAC,CAAVQ,OAAO,KAAIF,CAAC;IACdN,CAAC,CAAU,6BAAC,CAAVQ,OAAO,KAAID,CAAC;IACdP,CAAC,CAAO,CAAC,GAAPK,CAAC;IACHL,CAAC,CAACK,CAAC,GAAGI,CAAC,CAAC,GAAG;IACXT,CAAC,CAACK,CAAC,GAAGK,EAAC,CAAC,KAAK;IACbV,CAAC,CAACK,CAAC,CAACM,aAAa,CAAC,SAAS","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/parenthesized expression/generated/tests/generator/parenthesizedExpression/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/expressions/parenthesized expression/generated/tests/generator/parenthesizedExpression/gen_input.py.map index c8a170fa..cd948ab4 100644 --- a/packages/ttsl-lang/tests/resources/generation/expressions/parenthesized expression/generated/tests/generator/parenthesizedExpression/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/expressions/parenthesized expression/generated/tests/generator/parenthesizedExpression/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.Tsltest"],"names":["test","f","g"],"mappings":"AAAA;;AAMA,IAASA,IAAI;IACTC,CAAC,CAAEC,CAAC","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["test","f","g"],"mappings":"AAAA;;AAMA,IAASA,IAAI;IACTC,CAAC,CAAEC,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/prefix operation/generated/tests/generator/prefixOperation/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/expressions/prefix operation/generated/tests/generator/prefixOperation/gen_input.py.map index c1f2fdf1..c108e1a3 100644 --- a/packages/ttsl-lang/tests/resources/generation/expressions/prefix operation/generated/tests/generator/prefixOperation/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/expressions/prefix operation/generated/tests/generator/prefixOperation/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.Tsltest"],"names":["test","f","not","g","h"],"mappings":"AAAA;;AAQA,IAASA,IAAI;IACTC,CAAC,CAACC,GAAG,EAACC,CAAC;IACPF,CAAC,CAAC,CAAC,CAAAG,CAAC","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["test","f","not","g","h"],"mappings":"AAAA;;AAQA,IAASA,IAAI;IACTC,CAAC,CAACC,GAAG,EAACC,CAAC;IACPF,CAAC,CAAC,CAAC,CAAAG,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/reference/generated/tests/generator/reference/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/expressions/reference/generated/tests/generator/reference/gen_input.py.map index ced05b26..136f1521 100644 --- a/packages/ttsl-lang/tests/resources/generation/expressions/reference/generated/tests/generator/reference/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/expressions/reference/generated/tests/generator/reference/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.Tsltest"],"names":["test","f","explainmodel"],"mappings":"AAAA;;AAQA,IAASA,IAAI;IACTC,CAAC,CAACC,aAAY","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["test","f","explainmodel"],"mappings":"AAAA;;AAQA,IAASA,IAAI;IACTC,CAAC,CAACC,aAAY","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/side effects/generated/tests/generator/sideEffects/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/expressions/side effects/generated/tests/generator/sideEffects/gen_input.py.map index 654b1853..96db5dbd 100644 --- a/packages/ttsl-lang/tests/resources/generation/expressions/side effects/generated/tests/generator/sideEffects/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/expressions/side effects/generated/tests/generator/sideEffects/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.Tsltest"],"names":["mysegment","param","f","result","test","null"],"mappings":"AAAA;;AAIA,IAAQA,SAAS,CAACC,KAAK;IACnBC,CAAC;IACD,YAAMC,MAAM,GAAGF,KAAK;IAFO,OAAG;;;;AAKlC,IAASG,IAAI;IACTJ,SAAS,CAAC;IACVA,SAAS,CAAC;IACVA,SAAS,CAAC;IACVA,SAAS,CAACK,IAAI;IACdL,SAAS,CAAC","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["mysegment","param","f","result","test","null"],"mappings":"AAAA;;AAIA,IAAQA,SAAS,CAACC,KAAK;IACnBC,CAAC;IACD,YAAMC,MAAM,GAAGF,KAAK;IAFO,OAAG;;;;AAKlC,IAASG,IAAI;IACTJ,SAAS,CAAC;IACVA,SAAS,CAAC;IACVA,SAAS,CAAC;IACVA,SAAS,CAACK,IAAI;IACdL,SAAS,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/template string/generated/tests/generator/templateString/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/expressions/template string/generated/tests/generator/templateString/gen_input.py.map index dbf94293..2e67c496 100644 --- a/packages/ttsl-lang/tests/resources/generation/expressions/template string/generated/tests/generator/templateString/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/expressions/template string/generated/tests/generator/templateString/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.Tsltest"],"names":["test","f","g"],"mappings":"AAAA;;AAMA,IAASA,IAAI;IACTC,CAAC,CAAC,EAAA,SACHC,CAAC,EAAG,YACEA,CAAC,EAAG","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["test","f","g"],"mappings":"AAAA;;AAMA,IAASA,IAAI;IACTC,CAAC,CAAC,EAAA,SACHC,CAAC,EAAG,YACEA,CAAC,EAAG","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_context_same_package.py.map b/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_context_same_package.py.map index cd6c46ee..8ee50011 100644 --- a/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_context_same_package.py.map +++ b/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_context_same_package.py.map @@ -1 +1 @@ -{"version":3,"sources":["context same package.Tsltest"],"names":["segment1insamepackage","result","impurefunction","segment2insamepackage"],"mappings":"AAAA;;AAIA,IAAQA,qBAAqB;IACzB,YAAMC,MAAM,GAAGC,cAAc;IADD,OAAG;;AAInC,IAAQC,qBAAqB;IACzB,YAAMF,MAAM,GAAGC,cAAc;IADD,OAAG","file":"gen_context_same_package.py"} \ No newline at end of file +{"version":3,"sources":["context same package.ttsl"],"names":["segment1insamepackage","result","impurefunction","segment2insamepackage"],"mappings":"AAAA;;AAIA,IAAQA,qBAAqB;IACzB,YAAMC,MAAM,GAAGC,cAAc;IADD,OAAG;;AAInC,IAAQC,qBAAqB;IACzB,YAAMF,MAAM,GAAGC,cAAc;IADD,OAAG","file":"gen_context_same_package.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_input.py.map index 787264a9..185b5027 100644 --- a/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.Tsltest"],"names":["test","f","segment1insamepackage","segment2insamepackage","function1indifferentpackage","g","function1incompilationunitwithpythonmodule","h"],"mappings":"AAAA;;;;;;;;AASA,IAASA,IAAI;IACTC,CAAC,CAACC,qBAAqB;IACvBD,CAAC,CAACC,qBAAqB;IACvBD,CAAC,CAACE,qBAAqB;IACvBF,CAAC,CAACE,qBAAqB;IAEvBF,CAAC,CAACG,2BAA2B;IAC7BH,CAAC,CAACG,2BAA2B;IAC7BH,CAAC,CAACI,CAAC;IACHJ,CAAC,CAACI,CAAC;IAEHJ,CAAC,CAACK,0CAA0C;IAC5CL,CAAC,CAACK,0CAA0C;IAC5CL,CAAC,CAACM,CAAC;IACHN,CAAC,CAACM,CAAC","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["test","f","segment1insamepackage","segment2insamepackage","function1indifferentpackage","g","function1incompilationunitwithpythonmodule","h"],"mappings":"AAAA;;;;;;;;AASA,IAASA,IAAI;IACTC,CAAC,CAACC,qBAAqB;IACvBD,CAAC,CAACC,qBAAqB;IACvBD,CAAC,CAACE,qBAAqB;IACvBF,CAAC,CAACE,qBAAqB;IAEvBF,CAAC,CAACG,2BAA2B;IAC7BH,CAAC,CAACG,2BAA2B;IAC7BH,CAAC,CAACI,CAAC;IACHJ,CAAC,CAACI,CAAC;IAEHJ,CAAC,CAACK,0CAA0C;IAC5CL,CAAC,CAACK,0CAA0C;IAC5CL,CAAC,CAACM,CAAC;IACHN,CAAC,CAACM,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/imports/wildcard/generated/tests/generator/wildcard/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/imports/wildcard/generated/tests/generator/wildcard/gen_input.py.map index ff584bdf..3f670bf1 100644 --- a/packages/ttsl-lang/tests/resources/generation/imports/wildcard/generated/tests/generator/wildcard/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/imports/wildcard/generated/tests/generator/wildcard/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.Tsltest"],"names":["test","f","function1indifferentpackage","function2indifferentpackage","function1incompilationunitwithpythonmodule","function2incompilationunitwithpythonmodule"],"mappings":"AAAA;;;;;;;AAOA,IAASA,IAAI;IACTC,CAAC,CAACC,2BAA2B;IAC7BD,CAAC,CAACC,2BAA2B;IAC7BD,CAAC,CAACE,2BAA2B;IAC7BF,CAAC,CAACE,2BAA2B;IAE7BF,CAAC,CAACG,0CAA0C;IAC5CH,CAAC,CAACG,0CAA0C;IAC5CH,CAAC,CAACI,0CAA0C;IAC5CJ,CAAC,CAACI,0CAA0C","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["test","f","function1indifferentpackage","function2indifferentpackage","function1incompilationunitwithpythonmodule","function2incompilationunitwithpythonmodule"],"mappings":"AAAA;;;;;;;AAOA,IAASA,IAAI;IACTC,CAAC,CAACC,2BAA2B;IAC7BD,CAAC,CAACC,2BAA2B;IAC7BD,CAAC,CAACE,2BAA2B;IAC7BF,CAAC,CAACE,2BAA2B;IAE7BF,CAAC,CAACG,0CAA0C;IAC5CH,CAAC,CAACG,0CAA0C;IAC5CH,CAAC,CAACI,0CAA0C;IAC5CJ,CAAC,CAACI,0CAA0C","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/modifier/timeunit/generated/tests/generator/timeunit/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/modifier/timeunit/generated/tests/generator/timeunit/gen_input.py.map index 6acb6540..4e145371 100644 --- a/packages/ttsl-lang/tests/resources/generation/modifier/timeunit/generated/tests/generator/timeunit/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/modifier/timeunit/generated/tests/generator/timeunit/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.Tsltest"],"names":["daytest","weektest","monthtest","yeartest"],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAEA,IAAiBA,OAAO;;;;;;AAIxB,IAAkBC,QAAQ;;;;;;AAI1B,IAAmBC,SAAS;;;;;;AAI5B,IAAkBC,QAAQ","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["daytest","weektest","monthtest","yeartest"],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAEA,IAAiBA,OAAO;;;;;;AAIxB,IAAkBC,QAAQ;;;;;;AAI1B,IAAmBC,SAAS;;;;;;AAI5B,IAAkBC,QAAQ","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/modifier/timeunit/input.Tsltest b/packages/ttsl-lang/tests/resources/generation/modifier/timeunit/input.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/generation/modifier/timeunit/input.Tsltest rename to packages/ttsl-lang/tests/resources/generation/modifier/timeunit/input.ttsl diff --git a/packages/ttsl-lang/tests/resources/generation/partial/impure dependency file constant/generated/tests/generator/partialImpureDependencyFileConstant/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/partial/impure dependency file constant/generated/tests/generator/partialImpureDependencyFileConstant/gen_input.py.map index dc85fe2a..e7dec750 100644 --- a/packages/ttsl-lang/tests/resources/generation/partial/impure dependency file constant/generated/tests/generator/partialImpureDependencyFileConstant/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/partial/impure dependency file constant/generated/tests/generator/partialImpureDependencyFileConstant/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.Tsltest"],"names":["testpipeline","ifilewritea","ifilereada","ifilewriteb","ifilereadb","impurefilereadagain","impurefilereadagainb"],"mappings":"AAAA;;AAUA,IAASA,YAAY;IAEjB,kBAAsBC,WAAW;IACjC,mBAAuBA,WAAW;IAClC,sBAA0BC,UAAU;IAGpC,mBAAuBC,WAAW;IAClC,oBAAwBA,WAAW;IACnC,uBAA2BC,UAAU;IAGrC,SAAe,CAAAC,mBAAmB,EAAC,CAAC,EAACC,oBAAoB","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["testpipeline","ifilewritea","ifilereada","ifilewriteb","ifilereadb","impurefilereadagain","impurefilereadagainb"],"mappings":"AAAA;;AAUA,IAASA,YAAY;IAEjB,kBAAsBC,WAAW;IACjC,mBAAuBA,WAAW;IAClC,sBAA0BC,UAAU;IAGpC,mBAAuBC,WAAW;IAClC,oBAAwBA,WAAW;IACnC,uBAA2BC,UAAU;IAGrC,SAAe,CAAAC,mBAAmB,EAAC,CAAC,EAACC,oBAAoB","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/partial/impure dependency file parameter/generated/tests/generator/partialImpureDependencyFileParameter/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/partial/impure dependency file parameter/generated/tests/generator/partialImpureDependencyFileParameter/gen_input.py.map index 82ce8ed5..62ef76a7 100644 --- a/packages/ttsl-lang/tests/resources/generation/partial/impure dependency file parameter/generated/tests/generator/partialImpureDependencyFileParameter/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/partial/impure dependency file parameter/generated/tests/generator/partialImpureDependencyFileParameter/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.Tsltest"],"names":["testpipeline","ifilewrite","ifileread","impurefilereadagain"],"mappings":"AAAA;;AAMA,IAASA,YAAY;IAEjB,kBAAsBC,UAAU,CAAC,OAAO;IACxC,mBAAuBA,UAAU,CAAC,OAAO;IACzC,sBAA0BC,SAAS,CAAC,OAAO;IAG3C,SAAe,CAAAC,mBAAmB,EAAC,CAAC,EAAC,CAAC","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["testpipeline","ifilewrite","ifileread","impurefilereadagain"],"mappings":"AAAA;;AAMA,IAASA,YAAY;IAEjB,kBAAsBC,UAAU,CAAC,OAAO;IACxC,mBAAuBA,UAAU,CAAC,OAAO;IACzC,sBAA0BC,SAAS,CAAC,OAAO;IAG3C,SAAe,CAAAC,mBAAmB,EAAC,CAAC,EAAC,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/partial/impure dependency/generated/tests/generator/partialImpureDependency/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/partial/impure dependency/generated/tests/generator/partialImpureDependency/gen_input.py.map index 1f45057d..5dd9271d 100644 --- a/packages/ttsl-lang/tests/resources/generation/partial/impure dependency/generated/tests/generator/partialImpureDependency/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/partial/impure dependency/generated/tests/generator/partialImpureDependency/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.Tsltest"],"names":["testpipeline","i1","ifilewrite","nopartialevalint","r","fp","purevalueforimpure2","purevalueforimpure3","impurea2"],"mappings":"AAAA;;AAeA,IAASA,YAAY;IACjBC,EAAE,CAAC,CAAC;IAGJ,kBAAsBC,UAAU;IAChC,mBAAuBA,UAAU;IAEjC,sBAA0BC,gBAAgB,CAAC,CAAC;IAC5C,sBAA0B,CAAC;IAExB;QACCF,EAAE,CAAC,CAAC;QACJ,0BAAMG,CAAC,GAAG,CAAC;QAFZ,OAEC,0BAAMA,CAAC;IAFXC,EAAE,CAAC;IAIHJ,EAAE,CAAC,CAAC;IACJ,WAAeA,EAAE,CAACK,mBAAmB;IACrC,WAAeL,EAAE,CAACE,gBAAgB,CAACI,CAAmB;IACtDN,EAAE,CAAC,CAAC;IAGJ,SAAeA,EAAE,CAACO,QAAQ","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["testpipeline","i1","ifilewrite","nopartialevalint","r","fp","purevalueforimpure2","purevalueforimpure3","impurea2"],"mappings":"AAAA;;AAeA,IAASA,YAAY;IACjBC,EAAE,CAAC,CAAC;IAGJ,kBAAsBC,UAAU;IAChC,mBAAuBA,UAAU;IAEjC,sBAA0BC,gBAAgB,CAAC,CAAC;IAC5C,sBAA0B,CAAC;IAExB;QACCF,EAAE,CAAC,CAAC;QACJ,0BAAMG,CAAC,GAAG,CAAC;QAFZ,OAEC,0BAAMA,CAAC;IAFXC,EAAE,CAAC;IAIHJ,EAAE,CAAC,CAAC;IACJ,WAAeA,EAAE,CAACK,mBAAmB;IACrC,WAAeL,EAAE,CAACE,gBAAgB,CAACI,CAAmB;IACtDN,EAAE,CAAC,CAAC;IAGJ,SAAeA,EAAE,CAACO,QAAQ","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/partial/pure dependency/generated/tests/generator/partialPureDependency/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/partial/pure dependency/generated/tests/generator/partialPureDependency/gen_input.py.map index af6e4ae8..98140f46 100644 --- a/packages/ttsl-lang/tests/resources/generation/partial/pure dependency/generated/tests/generator/partialPureDependency/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/partial/pure dependency/generated/tests/generator/partialPureDependency/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.Tsltest"],"names":["testpipeline","false","null","g","boolean1","ldouble","lint","lnull","lstrmulti","z","f","g2","mapkey","mapvalue","nopartialevalint","listv1","listv3","list3","g3","list","o","value1","mapresult","listresult","g4","listvalue"],"mappings":"AAAA;;AAcA,IAASA,YAAY;IACjB,SAAaC,KAAK;IAGlB,UAAc,IAAI;IAGlB,OAAW,CAAC;IAGZ,QAAYC,IAAI;IAGhB,YAAgB;IAIhB,WAAe;IAGf,SAAaC,CAAC,CAACC,IAAQ,EAAEC,IAAO,EAAEC,CAAI,EAAEC,IAAK,EAAEC,aAAS;IAG9C;QACN,IAAQ,CAAC;QACT,KAAS,CAAC;QACV,IAAQ;QACR,KAAS;QACT,0BAAMC,CAAC,GAAG;QALJ,OAKN,0BAAMA,CAAC;IALX,IAAQ,CAAAC,CAAC,CAAC,uBAMP,CAAC,EAACA,CAAC,CAAC,SAAM,CAAC;IAcd,SAAa,KAAK;IAClB,WAAe,OAAO;IACtB,YAAgBC,EAAE,CAAC,CAACC,KAAM,EAAEC,OAAQ;IAMpC,SAAa,CAAC;IAEd,SAAaC,gBAAgB,CAACC,CAAM;IAEpC,OAAW,CAACA,CAAM;IAElB,QAAY,CAACC,MAAM;IACnB,YAAgBC,KAAK,CAAC,CAAC;IAEvB,aAAiBC,EAAE,CAACC,IAAI;IAIxB,SAAe,CAAO,CAAP,CAAA,CAAC,CAAAC,CAAC,GAAC,CAAC,EAAC,CAAC,GAAC,CAAC,EAACC,MAAM,GAAC,CAAC,EAAwB,CAAvB,CAAAC,SAAS,EAAC,CAAC,EAACC,UAAU,GAAC,CAAC,EAACC,EAAE,CAACC,SAAS","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["testpipeline","false","null","g","boolean1","ldouble","lint","lnull","lstrmulti","z","f","g2","mapkey","mapvalue","nopartialevalint","listv1","listv3","list3","g3","list","o","value1","mapresult","listresult","g4","listvalue"],"mappings":"AAAA;;AAcA,IAASA,YAAY;IACjB,SAAaC,KAAK;IAGlB,UAAc,IAAI;IAGlB,OAAW,CAAC;IAGZ,QAAYC,IAAI;IAGhB,YAAgB;IAIhB,WAAe;IAGf,SAAaC,CAAC,CAACC,IAAQ,EAAEC,IAAO,EAAEC,CAAI,EAAEC,IAAK,EAAEC,aAAS;IAG9C;QACN,IAAQ,CAAC;QACT,KAAS,CAAC;QACV,IAAQ;QACR,KAAS;QACT,0BAAMC,CAAC,GAAG;QALJ,OAKN,0BAAMA,CAAC;IALX,IAAQ,CAAAC,CAAC,CAAC,uBAMP,CAAC,EAACA,CAAC,CAAC,SAAM,CAAC;IAcd,SAAa,KAAK;IAClB,WAAe,OAAO;IACtB,YAAgBC,EAAE,CAAC,CAACC,KAAM,EAAEC,OAAQ;IAMpC,SAAa,CAAC;IAEd,SAAaC,gBAAgB,CAACC,CAAM;IAEpC,OAAW,CAACA,CAAM;IAElB,QAAY,CAACC,MAAM;IACnB,YAAgBC,KAAK,CAAC,CAAC;IAEvB,aAAiBC,EAAE,CAACC,IAAI;IAIxB,SAAe,CAAO,CAAP,CAAA,CAAC,CAAAC,CAAC,GAAC,CAAC,EAAC,CAAC,GAAC,CAAC,EAACC,MAAM,GAAC,CAAC,EAAwB,CAAvB,CAAAC,SAAS,EAAC,CAAC,EAACC,UAAU,GAAC,CAAC,EAACC,EAAE,CAACC,SAAS","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/partial/redundant impurity/generated/tests/generator/partialRedundantImpurity/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/partial/redundant impurity/generated/tests/generator/partialRedundantImpurity/gen_input.py.map index c9d1eb53..373d097f 100644 --- a/packages/ttsl-lang/tests/resources/generation/partial/redundant impurity/generated/tests/generator/partialRedundantImpurity/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/partial/redundant impurity/generated/tests/generator/partialRedundantImpurity/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.Tsltest"],"names":["testpipeline","nopartialevalint","purevalue"],"mappings":"AAAA;;AAeA,IAASA,YAAY;IAMjB,YAAgBC,gBAAgB,CAAC,CAAC;IAalC,SAAe,CAAAC,SAAS,EAAC,CAAC,EAAC,CAAC","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["testpipeline","nopartialevalint","purevalue"],"mappings":"AAAA;;AAeA,IAASA,YAAY;IAMjB,YAAgBC,gBAAgB,CAAC,CAAC;IAalC,SAAe,CAAAC,SAAS,EAAC,CAAC,EAAC,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/python module/generated/special_module/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/python module/generated/special_module/gen_input.py.map index 8825658b..33a03492 100644 --- a/packages/ttsl-lang/tests/resources/generation/python module/generated/special_module/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/python module/generated/special_module/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.Tsltest"],"names":["test","f"],"mappings":"AAAA;;AAMA,IAAQA,IAAI;IACRC,CAAC","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["test","f"],"mappings":"AAAA;;AAMA,IAAQA,IAAI;IACRC,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/runner integration/expressions/call/generated/tests/generator/callWithRunnerIntegration/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/runner integration/expressions/call/generated/tests/generator/callWithRunnerIntegration/gen_input.py.map index 259b64d6..974ca873 100644 --- a/packages/ttsl-lang/tests/resources/generation/runner integration/expressions/call/generated/tests/generator/callWithRunnerIntegration/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/runner integration/expressions/call/generated/tests/generator/callWithRunnerIntegration/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.Tsltest"],"names":["segment_a","a","result","test","f","g","param2","h","i","j","k","readfile","l","m"],"mappings":"AAAA;;;;;;;;;;;;;;;;AAiEA,IAAQA,SAAS,CAACC,CAAC;IACf,YAAMC,MAAM,GAAG,CAAAD,CAAC,EAAC,CAAC,EAAC,CAAC;IADE,OAAG;;;;AA9B7B,IAASE,IAAI;IACTC,CAAC,CAAE,uFAAAC,CAAC,CAAC,CAAC,EA9BNC,MAAM,CA8BE,CAAC,IAAJ,CAAC,EAAE,CAAC;IACTF,CAAC,CAAE,uFAAAC,CAAC,CAAsB,CAAC,EA/B3BC,MAAM,CA+BQ,CAAC,IAAW,CAAC,EAAb,CAAC;IACfF,CAAC,CAAE,uFAAAG,CAAC,CAAC,CAAC,EA3BiBD,OAAM,CA2BrB,CAAC,IAAJ,CAAC,EAAE,CAAC;IACTF,CAAC,CAAE,uFAAAG,CAAC,CAAsB,CAAC,EA5BJD,OAAM,CA4Bf,CAAC,IAAW,CAAC,EAAb,CAAC;IACfF,CAAC,CAAE,2EAAAG,CAAC,GAAU,CAAC,EA7BsB,CAAC;IA8BpC,KAAK;IACL,KAAK,GAAE,GAAG;IACZ,EAAQ,GAAG,EAAT,IAAI;IAEL,oBAAC,CAAFH,CAAC,UAADA,CAAC,CAAG,uFAAAC,CAAC,CAAC,CAAC,EAvCPC,MAAM,CAuCG,CAAC,IAAJ,CAAC,EAAE,CAAC;IACT,oBAAC,CAAFF,CAAC,UAADA,CAAC,CAAG,uFAAAC,CAAC,CAAsB,CAAC,EAxC5BC,MAAM,CAwCS,CAAC,IAAW,CAAC,EAAb,CAAC;IACf,oBAAC,CAAFF,CAAC,UAADA,CAAC,CAAG,uFAAAG,CAAC,CAAC,CAAC,EApCgBD,OAAM,CAoCpB,CAAC,IAAJ,CAAC,EAAE,CAAC;IACT,oBAAC,CAAFF,CAAC,UAADA,CAAC,CAAG,uFAAAG,CAAC,CAAsB,CAAC,EArCLD,OAAM,CAqCd,CAAC,IAAW,CAAC,EAAb,CAAC;IACf,oBAAC,CAAFF,CAAC,UAADA,CAAC,CAAG,2EAAAG,CAAC,GAAU,CAAC,EAtCqB,CAAC;IAuCrC,oBAAC,CAAFC,CAAC,UAAE,KAAK;IACP,oBAAC,CAAFC,CAAC,UAAE,KAAK,GAAE,GAAG;IACZ,oBAAC,CAAFC,CAAC,UAAD,EAAS,GAAG,EAAT,IAAI;IAEPN,CAAC,CAAC,kFAAAO,QAAQ,OAAR,iCAAU;IACZP,CAAC,CAACQ,CAAC,CAAC,OAACX,CAAC,EAAKD,SAAS,CAACC,CAAC;IACtBG,CAAC,CAACQ,CAAC,CAAC,OAACX,CAAC,EAAK,CAAA,CAAC,EAAC,CAAC,EAACD,SAAS,CAACC,CAAC;IAC1BG,CAAC,CAACQ,CAAC,CAAC,OAACX,CAAC,EAAK,2EAAAY,CAAC,GAAC,CAAA,CAAC,EAAC,CAAC,EAACb,SAAS,CAACC,CAAC;IAC5BG,CAAC,CAACQ,CAAC,CAAC,OAACX,CAAC,EAAK,CAAA,CAAC,EAAC,CAAC,EAAC,2EAAAY,CAAC,GAAC,2EAAAA,CAAC,GAAC,CAAA,CAAC,EAAC,CAAC,EAACb,SAAS,CAACC,CAAC;IAC9B,yBAACA,CAAC;QAAG,0BAAMC,MAAM,GAAGF,SAAS,CAACC,CAAC;QAA/B,OAAK,0BAAMC,MAAM;IAArBE,CAAC,CAACQ,CAAC,CAAC;IACA,yBAACX,CAAC;QAAG,0BAAMC,MAAM,GAAG,2EAAAW,CAAC,GAACb,SAAS,CAACC,CAAC;QAAjC,OAAK,0BAAMC,MAAM;IAArBE,CAAC,CAACQ,CAAC,CAAC;IACJR,CAAC,CAAC,2EAAAQ,CAAC,GAAC,OAACX,CAAC,EAAK,CAAA,CAAC,EAAC,CAAC,EAACA,CAAC;IACZ,yBAACA,CAAC;QAAG,0BAAMC,MAAM,GAAG,CAAA,CAAC,EAAC,CAAC,EAAC,2EAAAW,CAAC,GAACZ,CAAC;QAA3B,OAAK,0BAAMC,MAAM;IAArBE,CAAC,CAAC,2EAAAQ,CAAC,GAAC","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["segment_a","a","result","test","f","g","param2","h","i","j","k","readfile","l","m"],"mappings":"AAAA;;;;;;;;;;;;;;;;AAiEA,IAAQA,SAAS,CAACC,CAAC;IACf,YAAMC,MAAM,GAAG,CAAAD,CAAC,EAAC,CAAC,EAAC,CAAC;IADE,OAAG;;;;AA9B7B,IAASE,IAAI;IACTC,CAAC,CAAE,uFAAAC,CAAC,CAAC,CAAC,EA9BNC,MAAM,CA8BE,CAAC,IAAJ,CAAC,EAAE,CAAC;IACTF,CAAC,CAAE,uFAAAC,CAAC,CAAsB,CAAC,EA/B3BC,MAAM,CA+BQ,CAAC,IAAW,CAAC,EAAb,CAAC;IACfF,CAAC,CAAE,uFAAAG,CAAC,CAAC,CAAC,EA3BiBD,OAAM,CA2BrB,CAAC,IAAJ,CAAC,EAAE,CAAC;IACTF,CAAC,CAAE,uFAAAG,CAAC,CAAsB,CAAC,EA5BJD,OAAM,CA4Bf,CAAC,IAAW,CAAC,EAAb,CAAC;IACfF,CAAC,CAAE,2EAAAG,CAAC,GAAU,CAAC,EA7BsB,CAAC;IA8BpC,KAAK;IACL,KAAK,GAAE,GAAG;IACZ,EAAQ,GAAG,EAAT,IAAI;IAEL,oBAAC,CAAFH,CAAC,UAADA,CAAC,CAAG,uFAAAC,CAAC,CAAC,CAAC,EAvCPC,MAAM,CAuCG,CAAC,IAAJ,CAAC,EAAE,CAAC;IACT,oBAAC,CAAFF,CAAC,UAADA,CAAC,CAAG,uFAAAC,CAAC,CAAsB,CAAC,EAxC5BC,MAAM,CAwCS,CAAC,IAAW,CAAC,EAAb,CAAC;IACf,oBAAC,CAAFF,CAAC,UAADA,CAAC,CAAG,uFAAAG,CAAC,CAAC,CAAC,EApCgBD,OAAM,CAoCpB,CAAC,IAAJ,CAAC,EAAE,CAAC;IACT,oBAAC,CAAFF,CAAC,UAADA,CAAC,CAAG,uFAAAG,CAAC,CAAsB,CAAC,EArCLD,OAAM,CAqCd,CAAC,IAAW,CAAC,EAAb,CAAC;IACf,oBAAC,CAAFF,CAAC,UAADA,CAAC,CAAG,2EAAAG,CAAC,GAAU,CAAC,EAtCqB,CAAC;IAuCrC,oBAAC,CAAFC,CAAC,UAAE,KAAK;IACP,oBAAC,CAAFC,CAAC,UAAE,KAAK,GAAE,GAAG;IACZ,oBAAC,CAAFC,CAAC,UAAD,EAAS,GAAG,EAAT,IAAI;IAEPN,CAAC,CAAC,kFAAAO,QAAQ,OAAR,iCAAU;IACZP,CAAC,CAACQ,CAAC,CAAC,OAACX,CAAC,EAAKD,SAAS,CAACC,CAAC;IACtBG,CAAC,CAACQ,CAAC,CAAC,OAACX,CAAC,EAAK,CAAA,CAAC,EAAC,CAAC,EAACD,SAAS,CAACC,CAAC;IAC1BG,CAAC,CAACQ,CAAC,CAAC,OAACX,CAAC,EAAK,2EAAAY,CAAC,GAAC,CAAA,CAAC,EAAC,CAAC,EAACb,SAAS,CAACC,CAAC;IAC5BG,CAAC,CAACQ,CAAC,CAAC,OAACX,CAAC,EAAK,CAAA,CAAC,EAAC,CAAC,EAAC,2EAAAY,CAAC,GAAC,2EAAAA,CAAC,GAAC,CAAA,CAAC,EAAC,CAAC,EAACb,SAAS,CAACC,CAAC;IAC9B,yBAACA,CAAC;QAAG,0BAAMC,MAAM,GAAGF,SAAS,CAACC,CAAC;QAA/B,OAAK,0BAAMC,MAAM;IAArBE,CAAC,CAACQ,CAAC,CAAC;IACA,yBAACX,CAAC;QAAG,0BAAMC,MAAM,GAAG,2EAAAW,CAAC,GAACb,SAAS,CAACC,CAAC;QAAjC,OAAK,0BAAMC,MAAM;IAArBE,CAAC,CAACQ,CAAC,CAAC;IACJR,CAAC,CAAC,2EAAAQ,CAAC,GAAC,OAACX,CAAC,EAAK,CAAA,CAAC,EAAC,CAAC,EAACA,CAAC;IACZ,yBAACA,CAAC;QAAG,0BAAMC,MAAM,GAAG,CAAA,CAAC,EAAC,CAAC,EAAC,2EAAAW,CAAC,GAACZ,CAAC;QAA3B,OAAK,0BAAMC,MAAM;IAArBE,CAAC,CAAC,2EAAAQ,CAAC,GAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/runner integration/expressions/member access/generated/tests/generator/memberAccessWithRunnerIntegration/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/runner integration/expressions/member access/generated/tests/generator/memberAccessWithRunnerIntegration/gen_input.py.map index 6be49ddc..54186000 100644 --- a/packages/ttsl-lang/tests/resources/generation/runner integration/expressions/member access/generated/tests/generator/memberAccessWithRunnerIntegration/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/runner integration/expressions/member access/generated/tests/generator/memberAccessWithRunnerIntegration/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.Tsltest"],"names":["test","f","g","h","result1","result2","c","a","b","factory","j","k","from_csv_file"],"mappings":"AAAA;;;;;;;;;;;;;;;;AA4BA,IAASA,IAAI;IACTC,CAAC,CAAC,mFAAAC,CAAC;IACHD,CAAC,CAAC,mFAAAE,CAAC,UAAGC,CAAO;IACbH,CAAC,CAAC,mFAAAE,CAAC,UAAGE,CAAO;IACbJ,CAAC,CAAC,mFAAAK,CAAC,UAAGC,CAAC;IACPN,CAAC,CAAC,mFAAAK,CAAC,UAAGE,CAAC;IACPP,CAAC,CAAU,6BAAC,CAAV,yFAAAQ,OAAO,YAAIF,CAAC;IACdN,CAAC,CAAU,6BAAC,CAAV,yFAAAQ,OAAO,YAAID,CAAC;IACdP,CAAC,CAAC,iGAAM,CAAC,GAAP,mFAAAK,CAAC,aAAK,CAAC;IACTL,CAAC,CAAC,qFAAAK,CAAC,CAAGI,CAAC,GAAL,mFAAAJ,CAAC,WAAK,GAAG;IACXL,CAAC,CAAC,sFAAAK,CAAC,CAAGK,EAAC,GAAL,mFAAAL,CAAC,WAAK,KAAK;IACbL,CAAC,CAAC,iGAAAK,CAAC,CAACM,aAAa,GAAC,SAAS,IAAT,yBAAA,SAAS","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["test","f","g","h","result1","result2","c","a","b","factory","j","k","from_csv_file"],"mappings":"AAAA;;;;;;;;;;;;;;;;AA4BA,IAASA,IAAI;IACTC,CAAC,CAAC,mFAAAC,CAAC;IACHD,CAAC,CAAC,mFAAAE,CAAC,UAAGC,CAAO;IACbH,CAAC,CAAC,mFAAAE,CAAC,UAAGE,CAAO;IACbJ,CAAC,CAAC,mFAAAK,CAAC,UAAGC,CAAC;IACPN,CAAC,CAAC,mFAAAK,CAAC,UAAGE,CAAC;IACPP,CAAC,CAAU,6BAAC,CAAV,yFAAAQ,OAAO,YAAIF,CAAC;IACdN,CAAC,CAAU,6BAAC,CAAV,yFAAAQ,OAAO,YAAID,CAAC;IACdP,CAAC,CAAC,iGAAM,CAAC,GAAP,mFAAAK,CAAC,aAAK,CAAC;IACTL,CAAC,CAAC,qFAAAK,CAAC,CAAGI,CAAC,GAAL,mFAAAJ,CAAC,WAAK,GAAG;IACXL,CAAC,CAAC,sFAAAK,CAAC,CAAGK,EAAC,GAAL,mFAAAL,CAAC,WAAK,KAAK;IACbL,CAAC,CAAC,iGAAAK,CAAC,CAACM,aAAa,GAAC,SAAS,IAAT,yBAAA,SAAS","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/runner integration/imports/general/generated/tests/generator/importsWithRunnerIntegration/gen_context_same_package.py.map b/packages/ttsl-lang/tests/resources/generation/runner integration/imports/general/generated/tests/generator/importsWithRunnerIntegration/gen_context_same_package.py.map index 24a4555a..f11ab0cb 100644 --- a/packages/ttsl-lang/tests/resources/generation/runner integration/imports/general/generated/tests/generator/importsWithRunnerIntegration/gen_context_same_package.py.map +++ b/packages/ttsl-lang/tests/resources/generation/runner integration/imports/general/generated/tests/generator/importsWithRunnerIntegration/gen_context_same_package.py.map @@ -1 +1 @@ -{"version":3,"sources":["context same package.Tsltest"],"names":["segment1insamepackage","result","impurefunction","segment2insamepackage"],"mappings":"AAAA;;;;;;AAIA,IAAQA,qBAAqB;IACzB,YAAMC,MAAM,GAAG,2FAAAC,cAAc;IADD,OAAG;;AAInC,IAAQC,qBAAqB;IACzB,YAAMF,MAAM,GAAG,2FAAAC,cAAc;IADD,OAAG","file":"gen_context_same_package.py"} \ No newline at end of file +{"version":3,"sources":["context same package.ttsl"],"names":["segment1insamepackage","result","impurefunction","segment2insamepackage"],"mappings":"AAAA;;;;;;AAIA,IAAQA,qBAAqB;IACzB,YAAMC,MAAM,GAAG,2FAAAC,cAAc;IADD,OAAG;;AAInC,IAAQC,qBAAqB;IACzB,YAAMF,MAAM,GAAG,2FAAAC,cAAc;IADD,OAAG","file":"gen_context_same_package.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/runner integration/imports/general/generated/tests/generator/importsWithRunnerIntegration/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/runner integration/imports/general/generated/tests/generator/importsWithRunnerIntegration/gen_input.py.map index ca42f256..af8c402d 100644 --- a/packages/ttsl-lang/tests/resources/generation/runner integration/imports/general/generated/tests/generator/importsWithRunnerIntegration/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/runner integration/imports/general/generated/tests/generator/importsWithRunnerIntegration/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.Tsltest"],"names":["test","f","segment1insamepackage","segment2insamepackage","function1indifferentpackage","g","function1incompilationunitwithpythonmodule","h"],"mappings":"AAAA;;;;;;;;;AASA,IAASA,IAAI;IACTC,CAAC,CAACC,qBAAqB;IACvBD,CAAC,CAACC,qBAAqB;IACvBD,CAAC,CAACE,qBAAqB;IACvBF,CAAC,CAACE,qBAAqB;IAEvBF,CAAC,CAAC,iHAAAG,2BAA2B;IAC7BH,CAAC,CAAC,iHAAAG,2BAA2B;IAC7BH,CAAC,CAAC,iHAAAI,CAAC;IACHJ,CAAC,CAAC,iHAAAI,CAAC;IAEHJ,CAAC,CAAC,2FAAAK,0CAA0C;IAC5CL,CAAC,CAAC,2FAAAK,0CAA0C;IAC5CL,CAAC,CAAC,2FAAAM,CAAC;IACHN,CAAC,CAAC,2FAAAM,CAAC","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["test","f","segment1insamepackage","segment2insamepackage","function1indifferentpackage","g","function1incompilationunitwithpythonmodule","h"],"mappings":"AAAA;;;;;;;;;AASA,IAASA,IAAI;IACTC,CAAC,CAACC,qBAAqB;IACvBD,CAAC,CAACC,qBAAqB;IACvBD,CAAC,CAACE,qBAAqB;IACvBF,CAAC,CAACE,qBAAqB;IAEvBF,CAAC,CAAC,iHAAAG,2BAA2B;IAC7BH,CAAC,CAAC,iHAAAG,2BAA2B;IAC7BH,CAAC,CAAC,iHAAAI,CAAC;IACHJ,CAAC,CAAC,iHAAAI,CAAC;IAEHJ,CAAC,CAAC,2FAAAK,0CAA0C;IAC5CL,CAAC,CAAC,2FAAAK,0CAA0C;IAC5CL,CAAC,CAAC,2FAAAM,CAAC;IACHN,CAAC,CAAC,2FAAAM,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/runner integration/imports/wildcard/generated/tests/generator/wildcardWithRunnerIntegration/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/runner integration/imports/wildcard/generated/tests/generator/wildcardWithRunnerIntegration/gen_input.py.map index ea43a305..5401fc79 100644 --- a/packages/ttsl-lang/tests/resources/generation/runner integration/imports/wildcard/generated/tests/generator/wildcardWithRunnerIntegration/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/runner integration/imports/wildcard/generated/tests/generator/wildcardWithRunnerIntegration/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.Tsltest"],"names":["test","f","function1indifferentpackage","function2indifferentpackage","function1incompilationunitwithpythonmodule","function2incompilationunitwithpythonmodule"],"mappings":"AAAA;;;;;;;;AAOA,IAASA,IAAI;IACTC,CAAC,CAAC,yHAAAC,2BAA2B;IAC7BD,CAAC,CAAC,yHAAAC,2BAA2B;IAC7BD,CAAC,CAAC,yHAAAE,2BAA2B;IAC7BF,CAAC,CAAC,yHAAAE,2BAA2B;IAE7BF,CAAC,CAAC,2FAAAG,0CAA0C;IAC5CH,CAAC,CAAC,2FAAAG,0CAA0C;IAC5CH,CAAC,CAAC,2FAAAI,0CAA0C;IAC5CJ,CAAC,CAAC,2FAAAI,0CAA0C","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["test","f","function1indifferentpackage","function2indifferentpackage","function1incompilationunitwithpythonmodule","function2incompilationunitwithpythonmodule"],"mappings":"AAAA;;;;;;;;AAOA,IAASA,IAAI;IACTC,CAAC,CAAC,yHAAAC,2BAA2B;IAC7BD,CAAC,CAAC,yHAAAC,2BAA2B;IAC7BD,CAAC,CAAC,yHAAAE,2BAA2B;IAC7BF,CAAC,CAAC,yHAAAE,2BAA2B;IAE7BF,CAAC,CAAC,2FAAAG,0CAA0C;IAC5CH,CAAC,CAAC,2FAAAG,0CAA0C;IAC5CH,CAAC,CAAC,2FAAAI,0CAA0C;IAC5CJ,CAAC,CAAC,2FAAAI,0CAA0C","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/runner integration/statements/assignment/generated/tests/generator/assignmentWithRunnerIntegration/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/runner integration/statements/assignment/generated/tests/generator/assignmentWithRunnerIntegration/gen_input.py.map index 02a465fd..54aa39d2 100644 --- a/packages/ttsl-lang/tests/resources/generation/runner integration/statements/assignment/generated/tests/generator/assignmentWithRunnerIntegration/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/runner integration/statements/assignment/generated/tests/generator/assignmentWithRunnerIntegration/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.Tsltest"],"names":["testsegment","g","_","c","f1","a","x","testpipeline","l","m","n","f2"],"mappings":"AAAA;;;;;;AA2BA,IAAQA,WAAW;IACLC,CAAC;IACX,GAAOC,CAAC,EAAE,YAAMC,CAAC,GAAGF,CAAC;IACrB,UAAQA,CAAC;IACTG,EAAE,CAACC,CAAC;IACJD,EAAE,CAACE,CAAC;IALc,OAAG;;;;AApBzB,IAASC,YAAY;IACPN,CAAC;IACX,GAAOC,CAAC,EAAEA,CAAC,GAAGD,CAAC;IAAf;IACA,UAAQA,CAAC;IAAT;IACAG,EAAE,CAACC,CAAC;IACJD,EAAE,CAACE,CAAC;IACJ,GAAO,GAAO,IAAQL,CAAC;IAAvB;IAAO;IAAO;IACdG,EAAE,CAACI,CAAC;IACJJ,EAAE,CAACK,CAAC;IACJL,EAAE,CAACM,CAAC;IAED;QACWT,CAAC;QACX,GAAOC,CAAC,EAAE,0BAAMC,CAAC,GAAGF,CAAC;QACrB,UAAQA,CAAC;QACTG,EAAE,CAACC,CAAC;QACJD,EAAE,CAACE,CAAC;QALL,OAEW,0BAAMH,CAAC;IAFrBQ,EAAE,CAAC","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["testsegment","g","_","c","f1","a","x","testpipeline","l","m","n","f2"],"mappings":"AAAA;;;;;;AA2BA,IAAQA,WAAW;IACLC,CAAC;IACX,GAAOC,CAAC,EAAE,YAAMC,CAAC,GAAGF,CAAC;IACrB,UAAQA,CAAC;IACTG,EAAE,CAACC,CAAC;IACJD,EAAE,CAACE,CAAC;IALc,OAAG;;;;AApBzB,IAASC,YAAY;IACPN,CAAC;IACX,GAAOC,CAAC,EAAEA,CAAC,GAAGD,CAAC;IAAf;IACA,UAAQA,CAAC;IAAT;IACAG,EAAE,CAACC,CAAC;IACJD,EAAE,CAACE,CAAC;IACJ,GAAO,GAAO,IAAQL,CAAC;IAAvB;IAAO;IAAO;IACdG,EAAE,CAACI,CAAC;IACJJ,EAAE,CAACK,CAAC;IACJL,EAAE,CAACM,CAAC;IAED;QACWT,CAAC;QACX,GAAOC,CAAC,EAAE,0BAAMC,CAAC,GAAGF,CAAC;QACrB,UAAQA,CAAC;QACTG,EAAE,CAACC,CAAC;QACJD,EAAE,CAACE,CAAC;QALL,OAEW,0BAAMH,CAAC;IAFrBQ,EAAE,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/statements/assignment/generated/tests/generator/assignment/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/statements/assignment/generated/tests/generator/assignment/gen_input.py.map index b6039970..20879674 100644 --- a/packages/ttsl-lang/tests/resources/generation/statements/assignment/generated/tests/generator/assignment/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/statements/assignment/generated/tests/generator/assignment/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.Tsltest"],"names":["testsegment","g","_","c","f1","a","x","testpipeline","l","m","n","f2"],"mappings":"AAAA;;AA2BA,IAAQA,WAAW;IACLC,CAAC;IACX,GAAOC,CAAC,EAAE,YAAMC,CAAC,GAAGF,CAAC;IACrB,UAAQA,CAAC;IACTG,EAAE,CAACC,CAAC;IACJD,EAAE,CAACE,CAAC;IALc,OAAG;;;;AApBzB,IAASC,YAAY;IACPN,CAAC;IACX,GAAOC,CAAC,EAAEA,CAAC,GAAGD,CAAC;IACf,UAAQA,CAAC;IACTG,EAAE,CAACC,CAAC;IACJD,EAAE,CAACE,CAAC;IACJ,GAAO,GAAO,IAAQL,CAAC;IACvBG,EAAE,CAACI,CAAC;IACJJ,EAAE,CAACK,CAAC;IACJL,EAAE,CAACM,CAAC;IAED;QACWT,CAAC;QACX,GAAOC,CAAC,EAAE,0BAAMC,CAAC,GAAGF,CAAC;QACrB,UAAQA,CAAC;QACTG,EAAE,CAACC,CAAC;QACJD,EAAE,CAACE,CAAC;QALL,OAEW,0BAAMH,CAAC;IAFrBQ,EAAE,CAAC","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["testsegment","g","_","c","f1","a","x","testpipeline","l","m","n","f2"],"mappings":"AAAA;;AA2BA,IAAQA,WAAW;IACLC,CAAC;IACX,GAAOC,CAAC,EAAE,YAAMC,CAAC,GAAGF,CAAC;IACrB,UAAQA,CAAC;IACTG,EAAE,CAACC,CAAC;IACJD,EAAE,CAACE,CAAC;IALc,OAAG;;;;AApBzB,IAASC,YAAY;IACPN,CAAC;IACX,GAAOC,CAAC,EAAEA,CAAC,GAAGD,CAAC;IACf,UAAQA,CAAC;IACTG,EAAE,CAACC,CAAC;IACJD,EAAE,CAACE,CAAC;IACJ,GAAO,GAAO,IAAQL,CAAC;IACvBG,EAAE,CAACI,CAAC;IACJJ,EAAE,CAACK,CAAC;IACJL,EAAE,CAACM,CAAC;IAED;QACWT,CAAC;QACX,GAAOC,CAAC,EAAE,0BAAMC,CAAC,GAAGF,CAAC;QACrB,UAAQA,CAAC;QACTG,EAAE,CAACC,CAAC;QACJD,EAAE,CAACE,CAAC;QALL,OAEW,0BAAMH,CAAC;IAFrBQ,EAAE,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/statements/conditional statement/generated/tests/generator/conditionalStatement/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/statements/conditional statement/generated/tests/generator/conditionalStatement/gen_input.py.map index 5dd95cf8..450b4723 100644 --- a/packages/ttsl-lang/tests/resources/generation/statements/conditional statement/generated/tests/generator/conditionalStatement/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/statements/conditional statement/generated/tests/generator/conditionalStatement/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.Tsltest"],"names":["test"],"mappings":"AAAA;;AAEA,IAASA,IAAI;IACT,GAAG","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["test"],"mappings":"AAAA;;AAEA,IAASA,IAAI;IACT,GAAG","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/statements/conditional statement/input.Tsltest b/packages/ttsl-lang/tests/resources/generation/statements/conditional statement/input.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/generation/statements/conditional statement/input.Tsltest rename to packages/ttsl-lang/tests/resources/generation/statements/conditional statement/input.ttsl diff --git a/packages/ttsl-lang/tests/resources/generation/statements/expression statement/generated/tests/generator/expressionStatement/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/statements/expression statement/generated/tests/generator/expressionStatement/gen_input.py.map index 1ef85039..ee062285 100644 --- a/packages/ttsl-lang/tests/resources/generation/statements/expression statement/generated/tests/generator/expressionStatement/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/statements/expression statement/generated/tests/generator/expressionStatement/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.Tsltest"],"names":["testsegment","g","testpipeline","f"],"mappings":"AAAA;;AAcA,IAAQA,WAAW;IACfC,CAAC;;;;AATL,IAASC,YAAY;IACjBD,CAAC;IAEC;QACEA,CAAC;IADLE,CAAC,CAAC","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["testsegment","g","testpipeline","f"],"mappings":"AAAA;;AAcA,IAAQA,WAAW;IACfC,CAAC;;;;AATL,IAASC,YAAY;IACjBD,CAAC;IAEC;QACEA,CAAC;IADLE,CAAC,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/statements/statement without effect/generated/tests/generator/statementWithoutEffect/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/statements/statement without effect/generated/tests/generator/statementWithoutEffect/gen_input.py.map index 2805beed..48b2d72c 100644 --- a/packages/ttsl-lang/tests/resources/generation/statements/statement without effect/generated/tests/generator/statementWithoutEffect/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/statements/statement without effect/generated/tests/generator/statementWithoutEffect/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.Tsltest"],"names":["testsegment","testpipeline","f"],"mappings":"AAAA;;AAcA,IAAQA,WAAW;IAAG;;;;AAVtB,IAASC,YAAY;IAIf;QAAG;IAALC,CAAC,CAAC","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["testsegment","testpipeline","f"],"mappings":"AAAA;;AAcA,IAAQA,WAAW;IAAG;;;;AAVtB,IAASC,YAAY;IAIf;QAAG;IAALC,CAAC,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing name.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing name.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing name.tsltest rename to packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing name.ttsl diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing type.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing type.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing type.tsltest rename to packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing type.ttsl diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing value.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing value.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing value.tsltest rename to packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing value.ttsl diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/constants/good-with type and value.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/constants/good-with type and value.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/grammar/declarations/constants/good-with type and value.tsltest rename to packages/ttsl-lang/tests/resources/grammar/declarations/constants/good-with type and value.ttsl diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/data/bad-missing name.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/data/bad-missing name.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/grammar/declarations/data/bad-missing name.tsltest rename to packages/ttsl-lang/tests/resources/grammar/declarations/data/bad-missing name.ttsl diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/data/bad-missing type.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/data/bad-missing type.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/grammar/declarations/data/bad-missing type.tsltest rename to packages/ttsl-lang/tests/resources/grammar/declarations/data/bad-missing type.ttsl diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/data/good-with type and name.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/data/good-with type and name.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/grammar/declarations/data/good-with type and name.tsltest rename to packages/ttsl-lang/tests/resources/grammar/declarations/data/good-with type and name.ttsl diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing functionbody.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing functionbody.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing functionbody.tsltest rename to packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing functionbody.ttsl diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing parameter list.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing parameter list.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing parameter list.tsltest rename to packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing parameter list.ttsl diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing parameter type.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing parameter type.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing parameter type.tsltest rename to packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing parameter type.ttsl diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed parameter list.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed parameter list.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed parameter list.tsltest rename to packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed parameter list.ttsl diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed result list.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed result list.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed result list.tsltest rename to packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed result list.ttsl diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-annotation call.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-annotation call.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-annotation call.tsltest rename to packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-annotation call.ttsl diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with parameter list.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with parameter list.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with parameter list.tsltest rename to packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with parameter list.ttsl diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with result list.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with result list.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with result list.tsltest rename to packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with result list.ttsl diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with type parameter list.tsltest b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with type parameter list.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with type parameter list.tsltest rename to packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with type parameter list.ttsl diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-with else missing elseblock.tsltest b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-with else missing elseblock.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-with else missing elseblock.tsltest rename to packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-with else missing elseblock.ttsl diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-without else missing block.tsltest b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-without else missing block.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-without else missing block.tsltest rename to packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-without else missing block.ttsl diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-without else missing condition.tsltest b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-without else missing condition.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-without else missing condition.tsltest rename to packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-without else missing condition.ttsl diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-with else false.tsltest b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-with else false.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-with else false.tsltest rename to packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-with else false.ttsl diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-with else true.tsltest b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-with else true.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-with else true.tsltest rename to packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-with else true.ttsl diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-without else.tsltest b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-without else.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-without else.tsltest rename to packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-without else.ttsl From 0afd3ab397dd25e5a8fc1e231d6024d9e46322bf Mon Sep 17 00:00:00 2001 From: methr0 Date: Thu, 20 Jun 2024 17:32:41 +0200 Subject: [PATCH 067/183] add NodeDescription to ttsl.json file --- packages/ttsl-vscode/snippets/ttsl.json | 62 ++++++++++++++++++++++++- 1 file changed, 61 insertions(+), 1 deletion(-) diff --git a/packages/ttsl-vscode/snippets/ttsl.json b/packages/ttsl-vscode/snippets/ttsl.json index 0f1d634b..932b12a7 100644 --- a/packages/ttsl-vscode/snippets/ttsl.json +++ b/packages/ttsl-vscode/snippets/ttsl.json @@ -41,7 +41,7 @@ }, "Function": { "prefix": ["function"], - "body": ["${1|@Pure,@Impure([])|}", "fun ${2:myFunction}${3:<$4>}($5) ${6:-> ($7)} ${8:where {$0\\}}"], + "body": ["function ${1:myFunction}($2)${3:: $4}{", " $0", "}"], "description": "A function." }, "Minimal Pure Method": { @@ -91,5 +91,65 @@ "prefix": ["documentation-comment"], "body": ["/**", " * $0", " */"], "description": "A documentation comment." + }, + "Constant": { + "prefix": ["constant"], + "body": ["constant ${1:myConstant}${2:: $3}${4:= $5}"], + "description": "A Constant." + }, + "Data": { + "prefix": ["data"], + "body": ["data ${1:myDatat}${2:: $3}"], + "description": "A Data." + }, + "Aggregation": { + "prefix": ["aggregate"], + "body": ["aggregate $1 of $2 groupedBy $3"], + "description": "An aggregation." + }, + "While": { + "prefix": ["while"], + "body": ["while($1){", " $0","}"], + "description": "A while-loop." + }, + "For": { + "prefix": ["for"], + "body": ["for($1; $2; $3){", " $0","}"], + "description": "A for-loop." + }, + "Foreach": { + "prefix": ["foreach"], + "body": ["foreach($1 in $2){", " $0","}"], + "description": "A foreach loop." + }, + "If": { + "prefix": ["if"], + "body": ["if($1){", " $0", "}"], + "description": "A conditional statement." + }, + "If-Else": { + "prefix": ["if-else"], + "body": ["if($1){", " $0", "} else {", " $0", "}"], + "description": "A conditional statement with an else-Block." + }, + "GroupedBy": { + "prefix": ["GroupedBy"], + "body": ["GroupedBy $1"], + "description": "A GroupedBy modifier." + }, + "TimeUnit": { + "prefix": ["per"], + "body": ["per ${1|day ,week ,month ,year |}"], + "description": "A Timeunit." + }, + "TimeStamp": { + "prefix": ["from-to"], + "body": ["from $1-$2-$3 to $4-$5-$6"], + "description": "A Timestamp from one Date to another." + }, + "LocalVariable": { + "prefix": ["var"], + "body": ["var ${1:myVariable}${2:: $3}"], + "description": "A Timestamp from one Date to another." } } From 147ffd0cb856c38c5d4a6fdc0f4b7fb8c4c57721 Mon Sep 17 00:00:00 2001 From: methr0 Date: Thu, 20 Jun 2024 18:22:59 +0200 Subject: [PATCH 068/183] scoping test in same file --- .../in same file/to constants/main.ttsl | 15 +++++++++++++++ .../in same file/to functions/main.ttsl | 15 +++++++++++++++ .../of containing function/main.ttsl | 16 ++++++++++++++++ 3 files changed, 46 insertions(+) create mode 100644 packages/ttsl-lang/tests/resources/scoping/references/in same file/to constants/main.ttsl create mode 100644 packages/ttsl-lang/tests/resources/scoping/references/in same file/to functions/main.ttsl create mode 100644 packages/ttsl-lang/tests/resources/scoping/references/in same file/to placeholders/of containing function/main.ttsl diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to constants/main.ttsl b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to constants/main.ttsl new file mode 100644 index 00000000..edfd3b55 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to constants/main.ttsl @@ -0,0 +1,15 @@ +package tests.scoping.references.inSameFile.toConstant + +// $TEST$ target before +constant »before« : Int = 1 + +function myFunction() { + // $TEST$ references before + »before«; + + // $TEST$ references after + »after«; +} + +// $TEST$ target after +constant »after«: Int = 2 \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to functions/main.ttsl b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to functions/main.ttsl new file mode 100644 index 00000000..765c97fb --- /dev/null +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to functions/main.ttsl @@ -0,0 +1,15 @@ +package tests.scoping.references.inSameFile.toFunction + +// $TEST$ target before +function »before«() {} + +function myFunction() { + // $TEST$ references before + »before«(); + + // $TEST$ references after + »after«(); +} + +// $TEST$ target after +function »after«() {} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to placeholders/of containing function/main.ttsl b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to placeholders/of containing function/main.ttsl new file mode 100644 index 00000000..1a25d494 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to placeholders/of containing function/main.ttsl @@ -0,0 +1,16 @@ +package tests.scoping.references.inSameFile.toPlaceholders.ofContainingFunction + +function myFunction() { + // $TEST$ target before + var »before«: Int = 0; + + // $TEST$ target redeclared + var »redeclared«: Int = 0; + var redeclared: Int = 0; + + // $TEST$ references before + »before«; + + // $TEST$ references redeclared + »redeclared«; +} \ No newline at end of file From 682881ea1df3c9e9b0571d4cf3cc7332d95d3c48 Mon Sep 17 00:00:00 2001 From: methr0 Date: Fri, 21 Jun 2024 22:33:25 +0200 Subject: [PATCH 069/183] update timestamp NodeDescription --- packages/ttsl-vscode/snippets/ttsl.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/ttsl-vscode/snippets/ttsl.json b/packages/ttsl-vscode/snippets/ttsl.json index 932b12a7..a6d1464f 100644 --- a/packages/ttsl-vscode/snippets/ttsl.json +++ b/packages/ttsl-vscode/snippets/ttsl.json @@ -144,7 +144,7 @@ }, "TimeStamp": { "prefix": ["from-to"], - "body": ["from $1-$2-$3 to $4-$5-$6"], + "body": ["from ${1:$2-$3-$4} to ${5 $6-$7-$8}"], "description": "A Timestamp from one Date to another." }, "LocalVariable": { From a352b463938ac0f2b0426e121562bf26d09b684a Mon Sep 17 00:00:00 2001 From: methr0 Date: Mon, 24 Jun 2024 22:55:12 +0200 Subject: [PATCH 070/183] remove unnecessary grammar --- .../src/language/grammar/ttsl.langium | 566 +----------------- 1 file changed, 32 insertions(+), 534 deletions(-) diff --git a/packages/ttsl-lang/src/language/grammar/ttsl.langium b/packages/ttsl-lang/src/language/grammar/ttsl.langium index 1b306f9e..834df770 100644 --- a/packages/ttsl-lang/src/language/grammar/ttsl.langium +++ b/packages/ttsl-lang/src/language/grammar/ttsl.langium @@ -6,22 +6,16 @@ grammar TTSL interface TslObject {} -interface TslAnnotatedObject extends TslObject { - annotationCalls?: TslAnnotationCall[] -} - interface TslAbstractCall extends TslObject { argumentList: TslArgumentList } -interface TslDeclaration extends TslAnnotatedObject { - annotationCallList?: TslAnnotationCallList +interface TslDeclaration extends TslObject { name: string } interface TslLocalVariable extends TslDeclaration { groupedBy?: TslGroupedBy - type: TslType value?: TslExpression } @@ -31,22 +25,20 @@ interface TslLocalVariable extends TslDeclaration { interface TslModule extends TslDeclaration { imports: TslImport[]; - members: TslAnnotatedObject[] + members: TslObject[] } entry TslModule returns TslModule: {TslModule} - annotationCalls+=TslAnnotationCall* ( ('package' name=QualifiedName) imports+=TslImport* - members+=(TslAnnotatedModuleMember | TslUnannotatedModuleMember)* + members+=TslModuleMember* | imports+=TslImport+ - members+=(TslAnnotatedModuleMember | TslUnannotatedModuleMember)* + members+=TslModuleMember* - | members+=TslUnannotatedModuleMember - members+=(TslAnnotatedModuleMember | TslUnannotatedModuleMember)* + | members+=TslModuleMember* )? ; @@ -118,44 +110,8 @@ interface TslModuleMember extends TslDeclaration { visibility?: TslVisibility } -TslAnnotatedModuleMember returns TslModuleMember: - {TslAnnotationCallList} - annotationCalls+=TslAnnotationCall+ - ( - {TslAnnotation.annotationCallList=current} - TslAnnotationFragment - - | {TslClass.annotationCallList=current} - TslClassFragment - - | {TslEnum.annotationCallList=current} - TslEnumFragment - - | {TslFunction.annotationCallList=current} - TslFunctionFragment - - | {TslSchema.annotationCallList=current} - TslSchemaFragment - - | {TslPipeline.annotationCallList=current} - TslPipelineFragment - - | {TslSegment.annotationCallList=current} - TslSegmentFragment - ) -; - -TslUnannotatedModuleMember returns TslModuleMember: - {TslAnnotation} - TslAnnotationFragment - - | {TslClass} - TslClassFragment - - | {TslEnum} - TslEnumFragment - - | {TslFunction} +TslModuleMember returns TslModuleMember: + {TslFunction} TslFunctionFragment | {TslConstant} @@ -163,153 +119,13 @@ TslUnannotatedModuleMember returns TslModuleMember: | {TslData} TslDataFragment - - | {TslSchema} - TslSchemaFragment - - | {TslPipeline} - TslPipelineFragment - - | {TslSegment} - TslSegmentFragment -; - -interface TslAnnotation extends TslCallable, TslModuleMember { - constraintList?: TslConstraintList -} - -fragment TslAnnotationFragment: - 'annotation' name=ID - parameterList=TslParameterList? - constraintList=TslConstraintList? -; - -interface TslClass extends TslCallable, TslClassMember, TslModuleMember, TslNamedTypeDeclaration { - typeParameterList?: TslTypeParameterList - parentTypeList?: TslParentTypeList - constraintList?: TslConstraintList - body?: TslClassBody -} - -fragment TslClassFragment: - 'class' - name=ID - typeParameterList=TslTypeParameterList? - parameterList=TslParameterList? - parentTypeList=TslParentTypeList? - constraintList=TslConstraintList? - body=TslClassBody? -; - -interface TslParentTypeList extends TslObject { - parentTypes: TslType[] -} - -TslParentTypeList returns TslParentTypeList: - 'sub' - parentTypes+=TslParentType - (',' parentTypes+=TslParentType)* - ','? -; - -interface TslClassBody extends TslObject { - members: TslClassMember[] -} - -TslClassBody returns TslClassBody: - {TslClassBody} '{' members+=TslClassMember* '}' -; - -interface TslClassMember extends TslDeclaration { - isStatic?: boolean -} - -TslClassMember returns TslClassMember: - TslAnnotatedClassMember - | TslUnannotatedClassMember -; - -TslAnnotatedClassMember returns TslClassMember: - {TslAnnotationCallList} - annotationCalls+=TslAnnotationCall+ - ( - {TslAttribute.annotationCallList=current} - TslAttributeFragment - - | {TslClass.annotationCallList=current} - TslClassFragment - - | {TslEnum.annotationCallList=current} - TslEnumFragment - - | {TslFunction.annotationCallList=current} - isStatic?='static'? - TslFunctionFragment - ) -; - -TslUnannotatedClassMember returns TslClassMember: - {TslAttribute} - TslAttributeFragment - - | {TslClass} - TslClassFragment - - | {TslEnum} - TslEnumFragment - - | {TslFunction} - isStatic?='static'? - TslFunctionFragment -; - -interface TslAttribute extends TslClassMember { - ^type?: TslType -} - -fragment TslAttributeFragment: - isStatic?='static'? - 'attr' - name=ID - (':' ^type=TslType)? -; - - -interface TslEnum extends TslNamedTypeDeclaration, TslClassMember, TslModuleMember { - body?: TslEnumBody -} - -fragment TslEnumFragment: - 'enum' - name=ID - body=TslEnumBody? -; - -interface TslEnumBody extends TslObject { - variants: TslEnumVariant[] -} - -TslEnumBody returns TslEnumBody: - {TslEnumBody} '{' variants+=TslEnumVariant * '}' -; - -interface TslEnumVariant extends TslCallable, TslNamedTypeDeclaration { - constraintList?: TslConstraintList -} - -TslEnumVariant returns TslEnumVariant: - annotationCalls+=TslAnnotationCall* - name=ID - parameterList=TslParameterList? - constraintList=TslConstraintList? ; -interface TslFunction extends TslCallable, TslClassMember, TslModuleMember { +interface TslFunction extends TslCallable, TslModuleMember { isID: boolean result?: TslResult timeunit?: TslTimeunit groupedBy?: TslGroupedBy - constraintList?: TslConstraintList body: TslFunctionBlock } @@ -322,23 +138,9 @@ fragment TslFunctionFragment: parameterList=TslParameterList (result=TslResult)? (groupedBy=TslGroupedBy)? - constraintList=TslConstraintList? body=TslFunctionBlock ; -interface TslFunctionBlock extends TslBlock{ - timespanStatement: TslTimespanStatement[] - returnValue?: TslExpression -} - -TslFunctionBlock returns TslFunctionBlock: - {TslFunctionBlock} - '{' ( timespanStatement+=TslTimespanStatement - | statements+=TslStatement)* - ('return' returnValue=TslExpression)? - '}' -; - interface TslConstant extends TslModuleMember, TslDeclaration { timespanValueEntries?: TslTimespanValueEntry[] ^type: TslType @@ -371,93 +173,6 @@ fragment TslDataFragment: (groupedBy=TslGroupedBy)? ';'? ; -interface TslPipeline extends TslModuleMember { - body: TslBlock -} - -fragment TslPipelineFragment: - 'pipeline' - name=ID - body=TslBlock -; - -interface TslSegment extends TslCallable, TslModuleMember { - resultList?: TslResultList - constraintList?: TslConstraintList - body: TslBlock -} - -fragment TslSegmentFragment: - 'segment' - name=ID - parameterList=TslParameterList - resultList=TslResultList? - constraintList=TslConstraintList? - body=TslBlock -; - - -// ----------------------------------------------------------------------------- -// Annotation calls -// ----------------------------------------------------------------------------- - -interface TslAnnotationCallList extends TslAnnotatedObject {} - -interface TslAnnotationCall extends TslAbstractCall { - annotation?: @TslAnnotation -} - -TslAnnotationCall returns TslAnnotationCall: - '@' annotation=[TslAnnotation:ID] argumentList=TslAnnotationCallArgumentList? -; - -TslAnnotationCallArgumentList returns TslArgumentList: - {TslArgumentList} '(' (arguments+=TslAnnotationCallArgument (',' arguments+=TslAnnotationCallArgument)* ','? )? ')' -; - -TslAnnotationCallArgument returns TslArgument: - (parameter=[TslParameter:ID ] '=')? value=TslExpression -; - - -// ----------------------------------------------------------------------------- -// Constraints -// ----------------------------------------------------------------------------- - -interface TslConstraintList extends TslObject { - constraints: TslConstraint[] -} - -TslConstraintList returns TslConstraintList: - 'where' - '{' - ( - constraints+=TslConstraint - (',' constraints+=TslConstraint)* - ','? - )? - '}' -; - -interface TslConstraint extends TslObject {} - -TslConstraint returns TslConstraint: - TslParameterBound -; - -interface TslParameterBound extends TslConstraint { - leftOperand?: @TslParameter - operator: string - rightOperand: TslExpression -} - -TslParameterBound returns TslParameterBound: - leftOperand=[TslParameter:ID] - operator=TslComparisonOperator - rightOperand=TslExpression -; - - // ----------------------------------------------------------------------------- // Callables, parameters, and results // ----------------------------------------------------------------------------- @@ -483,11 +198,11 @@ TslParameterList returns TslParameterList: interface TslParameter extends TslLocalVariable { isConstant: boolean + ^type: TslType defaultValue?: TslExpression } TslParameter returns TslParameter: - annotationCalls+=TslAnnotationCall* isConstant?='constant'? name=ID ':' ^type=TslType @@ -510,9 +225,8 @@ interface TslResult extends TslAbstractResult { } TslResult returns TslResult: - annotationCalls+=TslAnnotationCall* (name=ID)? - (':' ^type=TslType)? + ':' ^type=TslType ; @@ -530,6 +244,19 @@ TslBlock returns TslBlock: {TslBlock} '{' statements+=TslStatement* '}' ; +interface TslFunctionBlock extends TslBlock{ + timespanStatement: TslTimespanStatement[] + returnValue?: TslExpression +} + +TslFunctionBlock returns TslFunctionBlock: + {TslFunctionBlock} + '{' ( timespanStatement+=TslTimespanStatement + | statements+=TslStatement)* + ('return' returnValue=TslExpression)? + '}' +; + TslStatement returns TslStatement: TslAssignment | TslExpressionStatement @@ -558,16 +285,8 @@ interface TslAssignee extends TslObject {} interface TslPlaceholder extends TslAssignee, TslLocalVariable {} -interface TslWildcard extends TslAssignee {} - -interface TslYield extends TslAssignee { - result?: @TslResult -} - TslAssignee returns TslAssignee: - {TslPlaceholder} 'var' name=ID ':' type=TslType (groupedBy=TslGroupedBy)? - | {TslWildcard} '_' - | {TslYield} 'yield' result=[TslResult:ID] + {TslPlaceholder} 'var' name=ID (groupedBy=TslGroupedBy)? ; interface TslExpressionStatement extends TslStatement { @@ -637,59 +356,17 @@ TslForeachLoop returns TslForeachLoop: interface TslExpression extends TslObject {} TslExpression returns TslExpression: - TslLambda | TslOrExpression | TslAggregation + TslOrExpression | TslAggregation ; interface TslAggregation extends TslExpression{ - function: TslString + function: TslTemplateString data: TslReference groupedBy: TslGroupedBy } TslAggregation returns TslAggregation: - 'aggregate' function=TslString 'of' data=TslReference groupedBy=TslGroupedBy -; - -interface TslLambda extends TslCallable, TslExpression {} - -interface TslBlockLambda extends TslLambda { - body: TslBlock -} - -interface TslExpressionLambda extends TslLambda { - result: TslExpression -} - -TslLambda returns TslExpression: - TslParameterList - ( - {TslBlockLambda.parameterList=current} body=TslBlockLambdaBlock - | {TslExpressionLambda.parameterList=current} '->' result=TslExpression - ) -; - -TslBlockLambdaBlock returns TslBlock: - {TslBlock} '{' statements+=TslBlockLambdaStatement* '}' -; - -TslBlockLambdaStatement returns TslStatement: - TslBlockLambdaAssignment | TslExpressionStatement -; - -TslBlockLambdaAssignment returns TslAssignment: - assigneeList=TslBlockLambdaAssigneeList '=' expression=TslExpression ';' -; - -TslBlockLambdaAssigneeList returns TslAssigneeList: - assignees+=TslBlockLambdaAssignee (',' assignees+=TslBlockLambdaAssignee)* ','? -; - -interface TslBlockLambdaResult extends TslAssignee, TslAbstractResult {} - -TslBlockLambdaAssignee returns TslAssignee: - {TslWildcard} '_' - | {TslPlaceholder} 'var' name=ID ':' type=TslType (groupedBy=TslGroupedBy)? - | {TslBlockLambdaResult} 'yield' name=ID + 'aggregate' function=TslTemplateString 'of' data=TslReference groupedBy=TslGroupedBy ; interface TslInfixOperation extends TslExpression { @@ -825,12 +502,6 @@ interface TslMemberAccess extends TslChainedExpression { TslChainedExpression returns TslExpression: TslPrimaryExpression ( - {TslCall.receiver=current} - timeunit=TslTimeunit - (isNullSafe?='?')? - argumentList=TslCallArgumentList - - | {TslCall.receiver=current} (isNullSafe?='?')? argumentList=TslCallArgumentList @@ -872,9 +543,7 @@ TslCallArgument returns TslArgument: TslPrimaryExpression returns TslExpression: TslLiteral - | TslParenthesizedExpression | TslReference - | TslTemplateString ; interface TslLiteral extends TslExpression {} @@ -886,7 +555,7 @@ TslLiteral returns TslLiteral: | TslList | TslDictionary | TslNull - | TslString + | TslTemplateString | TslDate ; @@ -948,14 +617,6 @@ TslNull returns TslNull: {TslNull} 'null' ; -interface TslString extends TslLiteral { - value: string -} - -TslString returns TslString: - value=STRING -; - interface TslDate extends TslLiteral{ date: Date } @@ -964,15 +625,6 @@ TslDate returns TslDate: date=DATE ; - -interface TslParenthesizedExpression extends TslExpression { - expression: TslExpression -} - -TslParenthesizedExpression returns TslParenthesizedExpression: - '(' expression=TslExpression ')' -; - interface TslReference extends TslExpression { target: @TslDeclaration } @@ -1024,13 +676,11 @@ TslTemplateStringEnd returns TslExpression: interface TslModifier extends TslObject{} interface TslVisibility extends TslModifier{ - isPublic?: boolean - isPackageprivate?: boolean - isPrivate?: boolean + visibility: string } TslVisibility returns TslVisibility: - isPublic?='public'? | isPackageprivate?='packageprivate'? | isPrivate?='private'? + visibility=('public' | 'packageprivate' | 'private') ; interface TslTimeunit extends TslModifier{ @@ -1059,7 +709,7 @@ interface TslTimespan extends TslObject{ } TslTimespan returns TslTimespan: - ('from' start=TslDate)? ('to' end=TslDate)? + ('from' start=TslDate | 'to' end=TslDate | 'from' start=TslDate 'to' end=TslDate) ; interface TslTimespanStatement extends TslBlock, TslStatement{ @@ -1090,18 +740,14 @@ interface TslNamedTypeDeclaration extends TslDeclaration {} interface TslMemberType extends TslType { receiver: TslType - member?: TslNamedType } TslType returns TslType: - TslPrimaryType ({TslMemberType.receiver=current} '.' member=TslNamedType)* + TslPrimaryType ; TslPrimaryType returns TslType: TslCallableType - | TslLiteralType - | TslNamedType - | TslUnionType | 'Int' | 'Float' | 'String' @@ -1119,122 +765,6 @@ TslCallableType returns TslCallableType: resultList=TslResultList ; -interface TslLiteralType extends TslType { - literalList: TslLiteralList -} - -TslLiteralType returns TslLiteralType: - 'literal' literalList=TslLiteralList -; - -interface TslLiteralList extends TslObject { - literals: TslLiteral[] -} - -TslLiteralList returns TslLiteralList: - {TslLiteralList} - '<' - ( - literals+=TslLiteral - (',' literals+=TslLiteral)* - ','? - )? - '>' -; - -interface TslNamedType extends TslType { - declaration?: @TslNamedTypeDeclaration - typeArgumentList?: TslTypeArgumentList - isNullable: boolean -} - -TslNamedType returns TslNamedType: - declaration=[TslNamedTypeDeclaration:ID] - typeArgumentList=TslTypeArgumentList? - (isNullable?='?' )? -; - -interface TslUnionType extends TslType { - typeArgumentList: TslTypeArgumentList -} - -TslUnionType returns TslUnionType: - 'union' typeArgumentList=TslUnionTypeArgumentList -; - -TslUnionTypeArgumentList returns TslTypeArgumentList: - {TslTypeArgumentList} - '<' - ( - typeArguments+=TslUnionTypeArgument - (',' typeArguments+=TslUnionTypeArgument)* - ','? - )? - '>' -; - -TslUnionTypeArgument returns TslTypeArgument: - value=TslType -; - -TslParentType returns TslType: - TslNamedType ({TslMemberType.receiver=current} '.' member=TslNamedType)* -; - -interface TslTypeParameterList extends TslObject { - typeParameters: TslTypeParameter[] -} - -TslTypeParameterList returns TslTypeParameterList: - {TslTypeParameterList} - '<' - ( - typeParameters+=TslTypeParameter - (',' typeParameters+=TslTypeParameter)* - ','? - )? - '>' -; - -interface TslTypeParameter extends TslNamedTypeDeclaration { - variance?: string - upperBound?: TslType - defaultValue?: TslType -} - -TslTypeParameter returns TslTypeParameter: - annotationCalls+=TslAnnotationCall* - variance=TslTypeParameterVariance? - name=ID - ('sub' upperBound=TslType)? - ('=' defaultValue=TslType)? -; - -TslTypeParameterVariance returns string: - 'in' | 'out' -; - -interface TslTypeArgumentList extends TslObject { - typeArguments: TslTypeArgument[] -} - -TslTypeArgumentList returns TslTypeArgumentList: - {TslTypeArgumentList} - '<' - (typeArguments+=TslTypeArgument (',' typeArguments+=TslTypeArgument)* ','? )? - '>' -; - -interface TslTypeArgument extends TslObject { - typeParameter?: @TslTypeParameter - value: TslType -} - -TslTypeArgument returns TslTypeArgument: - (typeParameter=[TslTypeParameter:ID] '=' )? - value=TslType -; - interface TslDictionaryType extends TslType { key: TslType value: TslType @@ -1252,38 +782,6 @@ TslListType returns TslListType: 'List' '<' type=TslType '>' ; -// ----------------------------------------------------------------------------- -// Schemas -// ----------------------------------------------------------------------------- - -interface TslSchema extends TslModuleMember { - columnList: TslColumnList -} - -fragment TslSchemaFragment: - 'schema' - name=ID - columnList=TslColumnList -; - -interface TslColumnList extends TslObject { - columns: TslColumn[] -} - -TslColumnList returns TslColumnList: - {TslColumnList} '{' (columns+=TslColumn (',' columns+=TslColumn)* ','? )? '}' -; - -interface TslColumn extends TslObject { - columnName: TslString - columnType: TslType -} - -TslColumn returns TslColumn: - columnName=TslString ":" columnType=TslType -; - - // ----------------------------------------------------------------------------- // Terminals // ----------------------------------------------------------------------------- From 0a27eb72411442fbae70e63b3fc3e75d00f88ff6 Mon Sep 17 00:00:00 2001 From: methr0 Date: Mon, 24 Jun 2024 23:20:54 +0200 Subject: [PATCH 071/183] remove the generation of removed grammar --- .../generation/safe-ds-python-generator.ts | 335 +++--------------- .../src/language/grammar/ttsl.langium | 8 +- 2 files changed, 54 insertions(+), 289 deletions(-) diff --git a/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts b/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts index 48daf0b0..12e8c5c8 100644 --- a/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts +++ b/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts @@ -18,16 +18,10 @@ import { groupBy, isEmpty } from '../../helpers/collections.js'; import { SafeDsAnnotations } from '../builtins/safe-ds-annotations.js'; import { isTslAbstractCall, - isTslAbstractResult, isTslAssignment, - isTslBlockLambda, - isTslBlockLambdaResult, isTslCall, isTslCallable, - isTslClass, isTslDeclaration, - isTslEnumVariant, - isTslExpressionLambda, isTslExpressionStatement, isTslFunction, isTslIndexedAccess, @@ -37,35 +31,27 @@ import { isTslMemberAccess, isTslModule, isTslParameter, - isTslParenthesizedExpression, - isTslPipeline, isTslPlaceholder, isTslPrefixOperation, isTslQualifiedImport, isTslReference, - isTslSegment, isTslTemplateString, isTslTemplateStringEnd, isTslTemplateStringInner, isTslTemplateStringPart, isTslTemplateStringStart, - isTslWildcard, isTslWildcardImport, - isTslYield, TslArgument, TslAssignee, TslAssignment, TslBlock, - TslBlockLambda, TslCall, TslDeclaration, TslExpression, TslModule, TslParameter, TslParameterList, - TslPipeline, TslPlaceholder, - TslSegment, TslStatement, isTslConditionalStatement, isTslLoop, @@ -83,8 +69,6 @@ import { TslData, isTslBlock, TslTimeunit, - TslResultList, - TslType, isTslExpression, } from '../generated/ast.js'; import { isInStubFile, isStubFile } from '../helpers/fileExtensions.js'; @@ -351,22 +335,7 @@ export class SafeDsPythonGenerator { ); } generatedFiles.set(pythonOutputPath, text); - for (const pipeline of getModuleMembers(node).filter(isTslPipeline)) { - const entryPointFilename = `${path.join( - parentDirectoryPath, - `${this.formatGeneratedFileName(name)}_${this.getPythonNameOrDefault(pipeline)}`, - )}.py`; - const entryPointContent = expandTracedToNode(pipeline)`from .${this.formatGeneratedFileName( - name, - )} import ${this.getPythonNameOrDefault( - pipeline, - )}\n\nif __name__ == '__main__':\n${PYTHON_INDENT}${this.getPythonNameOrDefault( - pipeline, - )}()`.appendNewLine(); - const generatedPipelineEntry = toStringAndTrace(entryPointContent); - generatedFiles.set(entryPointFilename, generatedPipelineEntry.text); - } - + return Array.from(generatedFiles.entries()).map(([fsPath, content]) => TextDocument.create(URI.file(fsPath).toString(), 'py', 0, content), ); @@ -468,14 +437,7 @@ export class SafeDsPythonGenerator { const importSet = new Map(); const utilitySet = new Set(); const typeVariableSet = new Set(); - const segments = getModuleMembers(module) - .filter(isTslSegment) - .map((segment) => this.generateSegment(segment, importSet, utilitySet, typeVariableSet, generateOptions)); - const pipelines = getModuleMembers(module) - .filter(isTslPipeline) - .map((pipeline) => - this.generatePipeline(pipeline, importSet, utilitySet, typeVariableSet, generateOptions), - ); + const functions = getModuleMembers(module) .filter(isTslFunction) .map((funct) => @@ -517,28 +479,9 @@ export class SafeDsPythonGenerator { output.append(joinToNode(utilitySet, (importDecl) => importDecl.code, { separator: SPACING })); output.appendNewLine(); } - if (segments.length > 0) { - output.appendNewLineIf(imports.length > 0 || typeVariableSet.size > 0 || utilitySet.size > 0); - output.append('# Segments ---------------------------------------------------------------------'); - output.appendNewLine(); - output.appendNewLine(); - output.append(joinToNode(segments, (segment) => segment, { separator: SPACING })); - output.appendNewLine(); - } - if (pipelines.length > 0) { - output.appendNewLineIf( - imports.length > 0 || typeVariableSet.size > 0 || utilitySet.size > 0 || segments.length > 0, - ); - output.append('# Pipelines --------------------------------------------------------------------'); - output.appendNewLine(); - output.appendNewLine(); - output.append(joinToNode(pipelines, (pipeline) => pipeline, { separator: SPACING })); - output.appendNewLine(); - } if (functions.length > 0) { output.appendNewLineIf( - imports.length > 0 || typeVariableSet.size > 0 || utilitySet.size > 0 || segments.length > 0 - || pipelines.length > 0, + imports.length > 0 || typeVariableSet.size > 0 || utilitySet.size > 0, ); output.append('# Functions --------------------------------------------------------------------'); output.appendNewLine(); @@ -548,8 +491,7 @@ export class SafeDsPythonGenerator { } if (constants.length > 0) { output.appendNewLineIf( - imports.length > 0 || typeVariableSet.size > 0 || utilitySet.size > 0 || segments.length > 0 - || pipelines.length > 0 || functions.length > 0, + imports.length > 0 || typeVariableSet.size > 0 || utilitySet.size > 0 || functions.length > 0, ); output.append('# Constants --------------------------------------------------------------------'); output.appendNewLine(); @@ -559,8 +501,7 @@ export class SafeDsPythonGenerator { } if (data.length > 0) { output.appendNewLineIf( - imports.length > 0 || typeVariableSet.size > 0 || utilitySet.size > 0 || segments.length > 0 - || pipelines.length > 0 || functions.length > 0 || constants.length > 0, + imports.length > 0 || typeVariableSet.size > 0 || utilitySet.size > 0 || functions.length > 0 || constants.length > 0, ); output.append('# Data --------------------------------------------------------------------'); output.appendNewLine(); @@ -571,41 +512,6 @@ export class SafeDsPythonGenerator { return output; } - private generateSegment( - segment: TslSegment, - importSet: Map, - utilitySet: Set, - typeVariableSet: Set, - generateOptions: GenerateOptions, - ): CompositeGeneratorNode { - const infoFrame = new GenerationInfoFrame( - importSet, - utilitySet, - typeVariableSet, - false, - undefined, - generateOptions.disableRunnerIntegration, - ); - const segmentResult = segment.resultList?.results || []; - const segmentBlock = this.generateBlock(segment.body, infoFrame); - if (segmentResult.length !== 0) { - segmentBlock.appendNewLine(); - segmentBlock.append( - expandTracedToNode(segment.resultList!)`return ${joinTracedToNode(segment.resultList!, 'results')( - segmentResult, - (result) => expandTracedToNode(result)`${YIELD_PREFIX}${result.name}`, - { separator: ', ' }, - )}`, - ); - } - return expandTracedToNode(segment)`def ${traceToNode( - segment, - 'name', - )(this.getPythonNameOrDefault(segment))}(${this.generateParameters(segment.parameterList, infoFrame)}):` - .appendNewLine() - .indent({ indentedChildren: [segmentBlock], indentation: PYTHON_INDENT }); - } - private generateFunction( funct: TslFunction, importSet: Map, @@ -668,7 +574,7 @@ export class SafeDsPythonGenerator { return joinTracedToNode(block, 'statements')( statements, - (stmt) => this.generateStatement(stmt, frame, generateLambda), + (stmt) => this.generateStatement(stmt, frame), { separator: NL, }, @@ -777,29 +683,6 @@ export class SafeDsPythonGenerator { }`; } - private generatePipeline( - pipeline: TslPipeline, - importSet: Map, - utilitySet: Set, - typeVariableSet: Set, - generateOptions: GenerateOptions, - ): CompositeGeneratorNode { - const infoFrame = new GenerationInfoFrame( - importSet, - utilitySet, - typeVariableSet, - true, - generateOptions.targetPlaceholder, - generateOptions.disableRunnerIntegration, - ); - return expandTracedToNode(pipeline)`def ${traceToNode( - pipeline, - 'name', - )(this.getPythonNameOrDefault(pipeline))}():` - .appendNewLine() - .indent({ indentedChildren: [this.generateBlock(pipeline.body, infoFrame)], indentation: PYTHON_INDENT }); - } - private generateImports(importSet: ImportData[]): string[] { const qualifiedImports = importSet .filter((importStmt) => importStmt.declarationName === undefined) @@ -855,7 +738,7 @@ export class SafeDsPythonGenerator { } return joinTracedToNode(block, 'statements')( statements, - (stmt) => this.generateStatement(stmt, frame, generateLambda), + (stmt) => this.generateStatement(stmt, frame), { separator: NL, }, @@ -926,25 +809,19 @@ export class SafeDsPythonGenerator { private generateStatement( statement: TslStatement, frame: GenerationInfoFrame, - generateLambda: boolean, ): CompositeGeneratorNode { - const blockLambdaCode: CompositeGeneratorNode[] = []; + const code: CompositeGeneratorNode[] = []; if (isTslAssignment(statement)) { if (statement.expression) { - for (const lambda of AstUtils.streamAllContents(statement.expression).filter(isTslBlockLambda)) { - blockLambdaCode.push(this.generateBlockLambda(lambda, frame)); - } + code.push(this.generateExpression(statement.expression, frame)); } - blockLambdaCode.push(this.generateAssignment(statement, frame, generateLambda)); - return joinTracedToNode(statement)(blockLambdaCode, (stmt) => stmt, { + code.push(this.generateAssignment(statement, frame)); + return joinTracedToNode(statement)(code, (stmt) => stmt, { separator: NL, })!; } else if (isTslExpressionStatement(statement)) { - for (const lambda of AstUtils.streamAllContents(statement.expression).filter(isTslBlockLambda)) { - blockLambdaCode.push(this.generateBlockLambda(lambda, frame)); - } - blockLambdaCode.push(this.generateExpression(statement.expression, frame)); - return joinTracedToNode(statement)(blockLambdaCode, (stmt) => stmt, { + code.push(this.generateExpression(statement.expression, frame)); + return joinTracedToNode(statement)(code, (stmt) => stmt, { separator: NL, })!; } else if (isTslTimespanStatement(statement)) { @@ -979,10 +856,10 @@ export class SafeDsPythonGenerator { } else if (isTslForLoop(statement)){ let firstParameter, thirdParameter = new CompositeGeneratorNode if (statement.definitionStatement){ - firstParameter = this.generateStatement((statement.definitionStatement), frame, false) + firstParameter = this.generateStatement((statement.definitionStatement), frame) } if (statement.iteration){ - thirdParameter = this.generateStatement((statement.iteration), frame, false) + thirdParameter = this.generateStatement((statement.iteration), frame) } return expandTracedToNode(statement)`${firstParameter} while ${this.generateExpression((statement.condition), frame)}: @@ -1000,98 +877,45 @@ export class SafeDsPythonGenerator { private generateAssignment( assignment: TslAssignment, frame: GenerationInfoFrame, - generateLambda: boolean, ): CompositeGeneratorNode { const requiredAssignees = isTslCall(assignment.expression) ? getAbstractResults(this.nodeMapper.callToCallable(assignment.expression)).length : /* c8 ignore next */ 1; const assignees = getAssignees(assignment); - if (assignees.some((value) => !isTslWildcard(value))) { - const actualAssignees = assignees.map(this.generateAssignee); - const assignmentStatements = []; - if (requiredAssignees === actualAssignees.length) { - assignmentStatements.push( - expandTracedToNode(assignment)`${joinToNode(actualAssignees, (actualAssignee) => actualAssignee, { - separator: ', ', - })} = ${this.generateExpression(assignment.expression!, frame)}`, - ); - } else { - // Add wildcards to match given results + const actualAssignees = assignees.map(this.generateAssignee); + const assignmentStatements = []; + if (requiredAssignees === actualAssignees.length) { + assignmentStatements.push( + expandTracedToNode(assignment)`${joinToNode(actualAssignees, (actualAssignee) => actualAssignee, { + separator: ', ', + })} = ${this.generateExpression(assignment.expression!, frame)}`, + ); + } + if (frame.isInsideFunction && !frame.disableRunnerIntegration) { + for (const savableAssignment of assignees.filter(isTslPlaceholder)) { + // should always be TslPlaceholder + frame.addImport({ importPath: RUNNER_PACKAGE }); assignmentStatements.push( - expandTracedToNode(assignment)`${joinToNode( - actualAssignees.concat(Array(requiredAssignees - actualAssignees.length).fill('_')), - (actualAssignee) => actualAssignee, - { separator: ', ' }, - )} = ${this.generateExpression(assignment.expression!, frame)}`, + expandTracedToNode( + savableAssignment, + )`${RUNNER_PACKAGE}.save_placeholder('${savableAssignment.name}', ${savableAssignment.name})`, ); } - if (frame.isInsidePipeline && !generateLambda && !frame.disableRunnerIntegration) { - for (const savableAssignment of assignees.filter(isTslPlaceholder)) { - // should always be TslPlaceholder - frame.addImport({ importPath: RUNNER_PACKAGE }); - assignmentStatements.push( - expandTracedToNode( - savableAssignment, - )`${RUNNER_PACKAGE}.save_placeholder('${savableAssignment.name}', ${savableAssignment.name})`, - ); - } - } - return joinTracedToNode(assignment)(assignmentStatements, (stmt) => stmt, { - separator: NL, - })!; - } else { - return traceToNode(assignment)(this.generateExpression(assignment.expression!, frame)); } + return joinTracedToNode(assignment)(assignmentStatements, (stmt) => stmt, { + separator: NL, + })!; } private generateAssignee(assignee: TslAssignee): CompositeGeneratorNode { - if (isTslBlockLambdaResult(assignee)) { - return expandTracedToNode(assignee)`${BLOCK_LAMBDA_RESULT_PREFIX}${traceToNode( - assignee, - 'name', - )(assignee.name)}`; - } else if (isTslPlaceholder(assignee)) { + if (isTslPlaceholder(assignee)) { return traceToNode(assignee)(assignee.name); - } else if (isTslWildcard(assignee)) { - return traceToNode(assignee)('_'); - } else if (isTslYield(assignee)) { - return expandTracedToNode(assignee)`${YIELD_PREFIX}${traceToNode( - assignee, - 'result', - )(assignee.result?.ref?.name!)}`; - } + } /* c8 ignore next 2 */ throw new Error(`Unknown TslAssignment: ${assignee.$type}`); } - private generateBlockLambda(blockLambda: TslBlockLambda, frame: GenerationInfoFrame): CompositeGeneratorNode { - const results = streamBlockLambdaResults(blockLambda).toArray(); - const lambdaBlock = this.generateBlock(blockLambda.body, frame, true); - if (results.length !== 0) { - lambdaBlock.appendNewLine(); - lambdaBlock.append( - expandTracedToNode(blockLambda)`return ${joinToNode( - results, - (result) => - expandTracedToNode(result)`${BLOCK_LAMBDA_RESULT_PREFIX}${traceToNode( - result, - 'name', - )(result.name)}`, - { separator: ', ' }, - )}`, - ); - } - return expandTracedToNode(blockLambda)`def ${frame.getUniqueLambdaBlockName( - blockLambda, - )}(${this.generateParameters(blockLambda.parameterList, frame)}):` - .appendNewLine() - .indent({ - indentedChildren: [lambdaBlock], - indentation: PYTHON_INDENT, - }); - } - private generateExpression(expression: TslExpression, frame: GenerationInfoFrame): CompositeGeneratorNode { if (isTslTemplateStringPart(expression)) { if (isTslTemplateStringStart(expression)) { @@ -1145,8 +969,6 @@ export class SafeDsPythonGenerator { (value) => this.generateExpression(value, frame), { separator: ', ' }, )}]`; - } else if (isTslBlockLambda(expression)) { - return traceToNode(expression)(frame.getUniqueLambdaBlockName(expression)); } else if (isTslCall(expression)) { const callable = this.nodeMapper.callToCallable(expression); const sortedArgs = this.sortArguments(getArguments(expression)); @@ -1154,7 +976,7 @@ export class SafeDsPythonGenerator { let call: CompositeGeneratorNode | undefined = undefined; // Memoize constructor or function call - if (isTslFunction(callable) || isTslClass(callable)) { + if (isTslFunction(callable)) { if (isTslFunction(callable)) { const pythonCall = this.builtinAnnotations.getPythonCall(callable); if (pythonCall) { @@ -1188,11 +1010,6 @@ export class SafeDsPythonGenerator { } else { return call; } - } else if (isTslExpressionLambda(expression)) { - return expandTracedToNode(expression)`lambda ${this.generateParameters( - expression.parameterList, - frame, - )}: ${this.generateExpression(expression.result, frame)}`; } else if (isTslInfixOperation(expression)) { const leftOperand = this.generateExpression(expression.leftOperand, frame); const rightOperand = this.generateExpression(expression.rightOperand, frame); @@ -1250,33 +1067,16 @@ export class SafeDsPythonGenerator { } else if (isTslMemberAccess(expression)) { const member = expression.member?.target.ref!; const receiver = this.generateExpression(expression.receiver, frame); - if (isTslEnumVariant(member)) { - const enumMember = this.generateExpression(expression.member!, frame); - const suffix = isTslCall(expression.$container) ? '' : '()'; - return expandTracedToNode(expression)`${receiver}.${enumMember}${suffix}`; - } else if (isTslAbstractResult(member)) { - const resultList = getAbstractResults(AstUtils.getContainerOfType(member, isTslCallable)); - if (resultList.length === 1) { - return traceToNode(expression)(receiver); - } - const currentIndex = resultList.indexOf(member); - return expandTracedToNode(expression)`${receiver}[${traceToNode(expression.member!)( - String(currentIndex), - )}]`; + const memberExpression = this.generateExpression(expression.member!, frame); + if (expression.isNullSafe) { + frame.addUtility(UTILITY_NULL_SAFE_MEMBER_ACCESS); + return expandTracedToNode(expression)`${traceToNode( + expression, + 'isNullSafe', + )(UTILITY_NULL_SAFE_MEMBER_ACCESS.name)}(${receiver}, '${memberExpression}')`; } else { - const memberExpression = this.generateExpression(expression.member!, frame); - if (expression.isNullSafe) { - frame.addUtility(UTILITY_NULL_SAFE_MEMBER_ACCESS); - return expandTracedToNode(expression)`${traceToNode( - expression, - 'isNullSafe', - )(UTILITY_NULL_SAFE_MEMBER_ACCESS.name)}(${receiver}, '${memberExpression}')`; - } else { - return expandTracedToNode(expression)`${receiver}.${memberExpression}`; - } + return expandTracedToNode(expression)`${receiver}.${memberExpression}`; } - } else if (isTslParenthesizedExpression(expression)) { - return expandTracedToNode(expression)`${this.generateExpression(expression.expression, frame)}`; } else if (isTslPrefixOperation(expression)) { const operand = this.generateExpression(expression.operand, frame); switch (expression.operator) { @@ -1296,7 +1096,7 @@ export class SafeDsPythonGenerator { frame.addUtility(UTILITY_AGGREGATION); return expandTracedToNode(expression)`${traceToNode( expression - )(UTILITY_AGGREGATION.name)}(${'dataframe'}, ${expression.data.target.ref?.name}, ${expression.groupedBy.id.target.ref?.name}, '${expression.function.value}')`; + )(UTILITY_AGGREGATION.name)}(${'dataframe'}, ${expression.data.target.ref?.name}, ${expression.groupedBy.id.target.ref?.name}, '${expression.function}')`; } /* c8 ignore next 2 */ throw new Error(`Unknown expression type: ${expression.$type}`); @@ -1371,37 +1171,10 @@ export class SafeDsPythonGenerator { const impurityReasons = this.purityComputer.getImpurityReasonsForExpression(expression); // If the file is not known, the call is not memoizable return ( - !impurityReasons.some((reason) => !(reason instanceof FileRead) || reason.path === undefined) && - !this.doesCallContainLambdaReferencingSegment(expression) + !impurityReasons.some((reason) => !(reason instanceof FileRead) || reason.path === undefined) ); } - private doesCallContainLambdaReferencingSegment(expression: TslCall): boolean { - return getArguments(expression).some((arg) => { - if (isTslExpressionLambda(arg.value)) { - return this.containsSegmentCall(arg.value.result); - } else if (isTslBlockLambda(arg.value)) { - return this.containsSegmentCall(arg.value.body); - } else { - /* c8 ignore next 2 */ - return false; - } - }); - } - - private containsSegmentCall(node: AstNode | undefined): boolean { - if (!node) { - /* c8 ignore next 2 */ - return false; - } - return AstUtils.streamAst(node) - .filter(isTslAbstractCall) - .some((call) => { - const callable = this.nodeMapper.callToCallable(call); - return isTslSegment(callable); - }); - } - private generateMemoizedCall( expression: TslCall, sortedArgs: TslArgument[], @@ -1415,7 +1188,7 @@ export class SafeDsPythonGenerator { (parameter) => this.nodeMapper.callToParameterValue(expression, parameter)!, ); // For a static function, the thisParam would be the class containing the function. We do not need to generate it in this case - const generateThisParam = !isTslFunction(callable) || (!callable.isStatic && thisParam); + const generateThisParam = !isTslFunction(callable) || thisParam; const containsOptionalArgs = sortedArgs.some((arg) => Parameter.isOptional(this.nodeMapper.argumentToParameter(arg)), ); @@ -1612,11 +1385,10 @@ interface ImportData { } class GenerationInfoFrame { - private readonly blockLambdaManager: IdManager; private readonly importSet: Map; private readonly utilitySet: Set; private readonly typeVariableSet: Set; - public readonly isInsidePipeline: boolean; + public readonly isInsideFunction: boolean; public readonly targetPlaceholder: string | undefined; public readonly disableRunnerIntegration: boolean; @@ -1624,15 +1396,14 @@ class GenerationInfoFrame { importSet: Map = new Map(), utilitySet: Set = new Set(), typeVariableSet: Set = new Set(), - insidePipeline: boolean = false, + insideFunction: boolean = false, targetPlaceholder: string | undefined = undefined, disableRunnerIntegration: boolean = false, ) { - this.blockLambdaManager = new IdManager(); this.importSet = importSet; this.utilitySet = utilitySet; this.typeVariableSet = typeVariableSet; - this.isInsidePipeline = insidePipeline; + this.isInsideFunction = insideFunction; this.targetPlaceholder = targetPlaceholder; this.disableRunnerIntegration = disableRunnerIntegration; } @@ -1663,10 +1434,6 @@ class GenerationInfoFrame { this.typeVariableSet.add(typeVariable); } } - - getUniqueLambdaBlockName(lambda: TslBlockLambda): string { - return `${BLOCK_LAMBDA_PREFIX}${this.blockLambdaManager.assignId(lambda)}`; - } } export interface GenerateOptions { diff --git a/packages/ttsl-lang/src/language/grammar/ttsl.langium b/packages/ttsl-lang/src/language/grammar/ttsl.langium index 834df770..dfd342ae 100644 --- a/packages/ttsl-lang/src/language/grammar/ttsl.langium +++ b/packages/ttsl-lang/src/language/grammar/ttsl.langium @@ -218,9 +218,7 @@ TslResultList returns TslResultList: | {TslResultList} ':' '(' (results+=TslResult (',' results+=TslResult)* ','? )? ')' ; -interface TslAbstractResult extends TslDeclaration {} - -interface TslResult extends TslAbstractResult { +interface TslResult extends TslDeclaration { ^type?: TslType } @@ -360,13 +358,13 @@ TslExpression returns TslExpression: ; interface TslAggregation extends TslExpression{ - function: TslTemplateString + function: string data: TslReference groupedBy: TslGroupedBy } TslAggregation returns TslAggregation: - 'aggregate' function=TslTemplateString 'of' data=TslReference groupedBy=TslGroupedBy + 'aggregate' function=STRING 'of' data=TslReference groupedBy=TslGroupedBy ; interface TslInfixOperation extends TslExpression { From 0993c3ce6a0f7fe32fc1e85141c4666999ffdcf6 Mon Sep 17 00:00:00 2001 From: methr0 Date: Mon, 24 Jun 2024 23:24:14 +0200 Subject: [PATCH 072/183] remove unnecessary Validators --- .../language/validation/safe-ds-validator.ts | 165 +----------------- 1 file changed, 2 insertions(+), 163 deletions(-) diff --git a/packages/ttsl-lang/src/language/validation/safe-ds-validator.ts b/packages/ttsl-lang/src/language/validation/safe-ds-validator.ts index 5dfcfba7..37fc8606 100644 --- a/packages/ttsl-lang/src/language/validation/safe-ds-validator.ts +++ b/packages/ttsl-lang/src/language/validation/safe-ds-validator.ts @@ -2,18 +2,14 @@ import { ValidationChecks } from 'langium'; import { TTSLAstType } from '../generated/ast.js'; import type { SafeDsServices } from '../safe-ds-module.js'; import { - annotationCallAnnotationShouldNotBeDeprecated, argumentCorrespondingParameterShouldNotBeDeprecated, assigneeAssignedResultShouldNotBeDeprecated, - namedTypeDeclarationShouldNotBeDeprecated, referenceTargetShouldNotBeDeprecated, requiredParameterMustNotBeDeprecated, } from './builtins/deprecated.js'; import { - annotationCallAnnotationShouldNotBeExperimental, argumentCorrespondingParameterShouldNotBeExperimental, assigneeAssignedResultShouldNotBeExperimental, - namedTypeDeclarationShouldNotBeExperimental, referenceTargetShouldNotExperimental, } from './builtins/experimental.js'; import { requiredParameterMustNotBeExpert } from './builtins/expert.js'; @@ -24,34 +20,16 @@ import { pythonNameShouldDifferFromSafeDsName, } from './builtins/pythonName.js'; import { singleUseAnnotationsMustNotBeRepeated } from './builtins/repeatable.js'; -import { annotationCallMustHaveCorrectTarget, targetShouldNotHaveDuplicateEntries } from './builtins/target.js'; -import { - constraintListsShouldBeUsedWithCaution, - literalTypesShouldBeUsedWithCaution, +import { mapsShouldBeUsedWithCaution, - unionTypesShouldBeUsedWithCaution, } from './experimentalLanguageFeatures.js'; import { - classMemberMustMatchOverriddenMemberAndShouldBeNeeded, - classMustNotInheritItself, - classMustOnlyInheritASingleClass, -} from './inheritance.js'; -import { - annotationMustContainUniqueNames, - blockLambdaMustContainUniqueNames, callableTypeMustContainUniqueNames, - classMustContainUniqueNames, - enumMustContainUniqueNames, - enumVariantMustContainUniqueNames, - expressionLambdaMustContainUniqueNames, moduleMemberMustHaveNameThatIsUniqueInPackage, moduleMustContainUniqueNames, nameMustNotOccurOnCoreDeclaration, nameMustNotStartWithCodegenPrefix, nameShouldHaveCorrectCasing, - pipelineMustContainUniqueNames, - schemaMustContainUniqueNames, - segmentMustContainUniqueNames, } from './names.js'; import { argumentListMustNotHavePositionalArgumentsAfterNamedArguments, @@ -60,11 +38,8 @@ import { argumentListMustSetAllRequiredParameters, } from './other/argumentLists.js'; import { - annotationCallArgumentsMustBeConstant, - annotationCallMustNotLackArgumentList, callableTypeParametersMustNotBeAnnotated, callableTypeResultsMustNotBeAnnotated, - lambdaParametersMustNotBeAnnotated, } from './other/declarations/annotationCalls.js'; import { parameterListMustNotHaveRequiredParametersAfterOptionalParameters } from './other/declarations/parameterLists.js'; import { @@ -72,23 +47,8 @@ import { constantParameterMustHaveTypeThatCanBeEvaluatedToConstant, } from './other/declarations/parameters.js'; import { placeholderShouldBeUsed, placeholdersMustNotBeAnAlias } from './other/declarations/placeholders.js'; -import { - segmentParameterShouldBeUsed, - segmentResultMustBeAssignedExactlyOnce, - segmentShouldBeUsed, -} from './other/declarations/segments.js'; -import { - typeParameterMustBeUsedInCorrectPosition, - typeParameterMustHaveSufficientContext, - typeParameterMustOnlyBeVariantOnClass, - typeParameterUpperBoundMustBeNamedType, -} from './other/declarations/typeParameters.js'; import { callArgumentMustBeConstantIfParameterIsConstant, callMustNotBeRecursive } from './other/expressions/calls.js'; import { divisionDivisorMustNotBeZero } from './other/expressions/infixOperations.js'; -import { - lambdaMustBeAssignedToTypedParameter, - lambdaParameterMustNotHaveConstModifier, -} from './other/expressions/lambdas.js'; import { memberAccessOfEnumVariantMustNotLackInstantiation } from './other/expressions/memberAccesses.js'; import { referenceMustNotBeFunctionPointer, @@ -105,29 +65,12 @@ import { import { assignmentAssigneeMustGetValue, assignmentShouldNotImplicitlyIgnoreResult, - yieldMustNotBeUsedInPipeline, } from './other/statements/assignments.js'; import { callableTypeMustBeUsedInCorrectContext, callableTypeMustNotHaveOptionalParameters, callableTypeParameterMustNotHaveConstModifier, } from './other/types/callableTypes.js'; -import { - literalTypeMustHaveLiterals, - literalTypeMustNotContainListLiteral, - literalTypeMustNotContainMapLiteral, - literalTypeShouldNotHaveDuplicateLiteral, -} from './other/types/literalTypes.js'; -import { - namedTypeMustNotHaveTooManyTypeArguments, - namedTypeMustNotSetTypeParameterMultipleTimes, - namedTypeTypeArgumentListMustNotHavePositionalArgumentsAfterNamedArguments, -} from './other/types/namedTypes.js'; -import { - unionTypeMustBeUsedInCorrectContext, - unionTypeMustHaveTypes, - unionTypeShouldNotHaveDuplicateTypes, -} from './other/types/unionTypes.js'; import { callArgumentAssignedToPureParameterMustBePure, impurityReasonParameterNameMustBelongToParameterOfCorrectType, @@ -136,26 +79,14 @@ import { pureParameterDefaultValueMustBePure, } from './purity.js'; import { - annotationCallArgumentListShouldBeNeeded, - annotationParameterListShouldNotBeEmpty, - annotationParameterShouldNotHaveConstModifier, assignmentShouldHaveMoreThanWildcardsAsAssignees, callArgumentListShouldBeNeeded, chainedExpressionNullSafetyShouldBeNeeded, - classBodyShouldNotBeEmpty, - constraintListShouldNotBeEmpty, elvisOperatorShouldBeNeeded, - enumBodyShouldNotBeEmpty, - enumVariantParameterListShouldNotBeEmpty, functionResultListShouldNotBeEmpty, importedDeclarationAliasShouldDifferFromDeclarationName, - namedTypeTypeArgumentListShouldBeNeeded, - segmentResultListShouldNotBeEmpty, - typeParameterListShouldNotBeEmpty, - unionTypeShouldNotHaveASingularTypeArgument, } from './style.js'; import { - attributeMustHaveTypeHint, callArgumentTypesMustMatchParameterTypes, callReceiverMustBeCallable, indexedAccessIndexMustHaveCorrectType, @@ -163,27 +94,20 @@ import { infixOperationOperandsMustHaveCorrectType, listMustNotContainNamedTuples, mapMustNotContainNamedTuples, - namedTypeMustSetAllTypeParameters, - namedTypeTypeArgumentsMustMatchBounds, parameterDefaultValueTypeMustMatchParameterType, parameterMustHaveTypeHint, prefixOperationOperandMustHaveCorrectType, resultMustHaveTypeHint, typeCastExpressionMustHaveUnknownType, - typeParameterDefaultValueMustMatchUpperBound, - yieldTypeMustMatchResultType, } from './types.js'; import { statementMustDoSomething } from './other/statements/statements.js'; import { indexedAccessIndexMustBeValid } from './other/expressions/indexedAccess.js'; -import { typeParameterListMustNotHaveRequiredTypeParametersAfterOptionalTypeParameters } from './other/declarations/typeParameterLists.js'; import { chainedExpressionsMustBeNullSafeIfReceiverIsNullable } from './other/expressions/chainedExpressions.js'; import { callArgumentMustRespectParameterBounds, - parameterBoundParameterMustBeConstFloatOrInt, - parameterBoundRightOperandMustEvaluateToFloatConstantOrIntConstant, parameterDefaultValueMustRespectParameterBounds, } from './other/declarations/parameterBounds.js'; -import { groupByVariableMustBeAnID, groupedFunctionHasAggregation, groupedFunctionHasValidID } from './aggregation.js'; +import { groupedFunctionHasAggregation, groupedFunctionHasValidID } from './aggregation.js'; /** * Register custom validation checks. @@ -204,20 +128,6 @@ export const registerValidationChecks = function (services: SafeDsServices) { argumentListMustNotHaveTooManyArguments(services), argumentListMustSetAllRequiredParameters(services), ], - TslAnnotation: [ - annotationMustContainUniqueNames, - annotationParameterListShouldNotBeEmpty(services), - annotationParameterShouldNotHaveConstModifier(services), - targetShouldNotHaveDuplicateEntries(services), - ], - TslAnnotationCall: [ - annotationCallAnnotationShouldNotBeDeprecated(services), - annotationCallAnnotationShouldNotBeExperimental(services), - annotationCallArgumentListShouldBeNeeded(services), - annotationCallArgumentsMustBeConstant(services), - annotationCallMustHaveCorrectTarget(services), - annotationCallMustNotLackArgumentList, - ], TslArgument: [ argumentCorrespondingParameterShouldNotBeDeprecated(services), argumentCorrespondingParameterShouldNotBeExperimental(services), @@ -226,11 +136,6 @@ export const registerValidationChecks = function (services: SafeDsServices) { argumentListMustNotHavePositionalArgumentsAfterNamedArguments, argumentListMustNotSetParameterMultipleTimes(services), ], - TslAttribute: [attributeMustHaveTypeHint], - TslAggregation: [ - groupByVariableMustBeAnID(), - ], - TslBlockLambda: [blockLambdaMustContainUniqueNames], TslCall: [ callArgumentListShouldBeNeeded(services), callArgumentAssignedToPureParameterMustBePure(services), @@ -252,14 +157,6 @@ export const registerValidationChecks = function (services: SafeDsServices) { chainedExpressionsMustBeNullSafeIfReceiverIsNullable(services), chainedExpressionNullSafetyShouldBeNeeded(services), ], - TslClass: [ - classMustContainUniqueNames, - classMustOnlyInheritASingleClass(services), - classMustNotInheritItself(services), - ], - TslClassBody: [classBodyShouldNotBeEmpty(services)], - TslClassMember: [classMemberMustMatchOverriddenMemberAndShouldBeNeeded(services)], - TslConstraintList: [constraintListsShouldBeUsedWithCaution(services), constraintListShouldNotBeEmpty(services)], TslDeclaration: [ nameMustNotOccurOnCoreDeclaration(services), nameMustNotStartWithCodegenPrefix, @@ -267,10 +164,6 @@ export const registerValidationChecks = function (services: SafeDsServices) { pythonNameShouldDifferFromSafeDsName(services), singleUseAnnotationsMustNotBeRepeated(services), ], - TslEnum: [enumMustContainUniqueNames], - TslEnumBody: [enumBodyShouldNotBeEmpty(services)], - TslEnumVariant: [enumVariantMustContainUniqueNames, enumVariantParameterListShouldNotBeEmpty(services)], - TslExpressionLambda: [expressionLambdaMustContainUniqueNames], TslFunction: [ functionResultListShouldNotBeEmpty(services), impurityReasonsOfOverridingMethodMustBeSubsetOfOverriddenMethod(services), @@ -293,19 +186,7 @@ export const registerValidationChecks = function (services: SafeDsServices) { elvisOperatorShouldBeNeeded(services), infixOperationOperandsMustHaveCorrectType(services), ], - TslLambda: [ - lambdaMustBeAssignedToTypedParameter(services), - lambdaParametersMustNotBeAnnotated, - lambdaParameterMustNotHaveConstModifier, - ], TslList: [listMustNotContainNamedTuples(services)], - TslLiteralType: [ - literalTypeMustHaveLiterals, - literalTypeMustNotContainListLiteral, - literalTypeMustNotContainMapLiteral, - literalTypesShouldBeUsedWithCaution(services), - literalTypeShouldNotHaveDuplicateLiteral(services), - ], TslDictionary: [mapMustNotContainNamedTuples(services), mapsShouldBeUsedWithCaution(services)], TslMemberAccess: [memberAccessOfEnumVariantMustNotLackInstantiation], TslModule: [ @@ -316,16 +197,6 @@ export const registerValidationChecks = function (services: SafeDsServices) { pipelineFileMustNotBeInBuiltinPackage, pythonModuleShouldDifferFromSafeDsPackage(services), ], - TslNamedType: [ - namedTypeDeclarationShouldNotBeDeprecated(services), - namedTypeDeclarationShouldNotBeExperimental(services), - namedTypeMustNotHaveTooManyTypeArguments, - namedTypeMustNotSetTypeParameterMultipleTimes(services), - namedTypeMustSetAllTypeParameters(services), - namedTypeTypeArgumentListShouldBeNeeded(services), - namedTypeTypeArgumentListMustNotHavePositionalArgumentsAfterNamedArguments, - namedTypeTypeArgumentsMustMatchBounds(services), - ], TslParameter: [ constantParameterMustHaveConstantDefaultValue(services), constantParameterMustHaveTypeThatCanBeEvaluatedToConstant(services), @@ -336,12 +207,7 @@ export const registerValidationChecks = function (services: SafeDsServices) { requiredParameterMustNotBeDeprecated(services), requiredParameterMustNotBeExpert(services), ], - TslParameterBound: [ - parameterBoundParameterMustBeConstFloatOrInt(services), - parameterBoundRightOperandMustEvaluateToFloatConstantOrIntConstant(services), - ], TslParameterList: [parameterListMustNotHaveRequiredParametersAfterOptionalParameters], - TslPipeline: [pipelineMustContainUniqueNames], TslPlaceholder: [placeholdersMustNotBeAnAlias, placeholderShouldBeUsed(services)], TslPrefixOperation: [prefixOperationOperandMustHaveCorrectType(services)], TslReference: [ @@ -352,36 +218,9 @@ export const registerValidationChecks = function (services: SafeDsServices) { referenceTargetShouldNotExperimental(services), ], TslResult: [resultMustHaveTypeHint], - TslSchema: [schemaMustContainUniqueNames], - TslSegment: [ - segmentMustContainUniqueNames, - segmentParameterShouldBeUsed(services), - segmentResultMustBeAssignedExactlyOnce(services), - segmentResultListShouldNotBeEmpty(services), - segmentShouldBeUsed(services), - ], TslStatement: [statementMustDoSomething(services)], TslTemplateString: [templateStringMustHaveExpressionBetweenTwoStringParts], TslTypeCast: [typeCastExpressionMustHaveUnknownType(services)], - TslTypeParameter: [ - typeParameterDefaultValueMustMatchUpperBound(services), - typeParameterMustBeUsedInCorrectPosition(services), - typeParameterMustHaveSufficientContext, - typeParameterMustOnlyBeVariantOnClass, - typeParameterUpperBoundMustBeNamedType(services), - ], - TslTypeParameterList: [ - typeParameterListMustNotHaveRequiredTypeParametersAfterOptionalTypeParameters, - typeParameterListShouldNotBeEmpty(services), - ], - TslUnionType: [ - unionTypeMustBeUsedInCorrectContext, - unionTypeMustHaveTypes, - unionTypesShouldBeUsedWithCaution(services), - unionTypeShouldNotHaveDuplicateTypes(services), - unionTypeShouldNotHaveASingularTypeArgument(services), - ], - TslYield: [yieldMustNotBeUsedInPipeline, yieldTypeMustMatchResultType(services)], }; registry.register(checks); }; From d3926a5a40fbc5c615d32fa825881a0621faca8f Mon Sep 17 00:00:00 2001 From: methr0 Date: Tue, 25 Jun 2024 00:35:26 +0200 Subject: [PATCH 073/183] remove unnecessary Validation tests --- .../validation/builtins/deprecated.ts | 40 --- .../validation/builtins/experimental.ts | 54 ---- .../language/validation/builtins/target.ts | 162 ---------- .../experimentalLanguageFeatures.ts | 62 +--- .../src/language/validation/inheritance.ts | 203 ------------ .../src/language/validation/names.ts | 149 +-------- .../validation/other/argumentLists.ts | 13 +- .../other/declarations/annotationCalls.ts | 54 +--- .../other/declarations/parameterBounds.ts | 69 +--- .../other/declarations/parameters.ts | 12 +- .../validation/other/declarations/segments.ts | 78 ----- .../other/declarations/typeParameterLists.ts | 23 -- .../other/declarations/typeParameters.ts | 233 -------------- .../validation/other/expressions/lambdas.ts | 46 --- .../other/expressions/memberAccesses.ts | 24 -- .../other/expressions/references.ts | 72 +---- .../src/language/validation/other/modules.ts | 47 +-- .../other/statements/assignments.ts | 16 +- .../validation/other/types/literalTypes.ts | 64 ---- .../validation/other/types/namedTypes.ts | 93 ------ .../validation/other/types/unionTypes.ts | 77 ----- .../language/validation/safe-ds-validator.ts | 17 +- .../src/language/validation/style.ts | 303 +----------------- .../src/language/validation/types.ts | 169 +--------- 24 files changed, 30 insertions(+), 2050 deletions(-) delete mode 100644 packages/ttsl-lang/src/language/validation/builtins/target.ts delete mode 100644 packages/ttsl-lang/src/language/validation/inheritance.ts delete mode 100644 packages/ttsl-lang/src/language/validation/other/declarations/segments.ts delete mode 100644 packages/ttsl-lang/src/language/validation/other/declarations/typeParameterLists.ts delete mode 100644 packages/ttsl-lang/src/language/validation/other/declarations/typeParameters.ts delete mode 100644 packages/ttsl-lang/src/language/validation/other/expressions/lambdas.ts delete mode 100644 packages/ttsl-lang/src/language/validation/other/expressions/memberAccesses.ts delete mode 100644 packages/ttsl-lang/src/language/validation/other/types/literalTypes.ts delete mode 100644 packages/ttsl-lang/src/language/validation/other/types/namedTypes.ts delete mode 100644 packages/ttsl-lang/src/language/validation/other/types/unionTypes.ts diff --git a/packages/ttsl-lang/src/language/validation/builtins/deprecated.ts b/packages/ttsl-lang/src/language/validation/builtins/deprecated.ts index 4c17fc3d..94db79b6 100644 --- a/packages/ttsl-lang/src/language/validation/builtins/deprecated.ts +++ b/packages/ttsl-lang/src/language/validation/builtins/deprecated.ts @@ -3,11 +3,8 @@ import { DiagnosticTag } from 'vscode-languageserver'; import { isTslParameter, isTslResult, - isTslWildcard, - TslAnnotationCall, TslArgument, TslAssignee, - TslNamedType, TslParameter, TslReference, } from '../../generated/ast.js'; @@ -20,10 +17,6 @@ export const CODE_DEPRECATED_REQUIRED_PARAMETER = 'deprecated/required-parameter export const assigneeAssignedResultShouldNotBeDeprecated = (services: SafeDsServices) => (node: TslAssignee, accept: ValidationAcceptor) => { - if (isTslWildcard(node)) { - return; - } - const assignedObject = services.helpers.NodeMapper.assigneeToAssignedObject(node); if (!isTslResult(assignedObject)) { return; @@ -38,23 +31,6 @@ export const assigneeAssignedResultShouldNotBeDeprecated = } }; -export const annotationCallAnnotationShouldNotBeDeprecated = - (services: SafeDsServices) => (node: TslAnnotationCall, accept: ValidationAcceptor) => { - const annotation = node.annotation?.ref; - if (!annotation) { - return; - } - - if (services.builtins.Annotations.callsDeprecated(annotation)) { - accept('warning', `The called annotation '${annotation.name}' is deprecated.`, { - node, - property: 'annotation', - code: CODE_DEPRECATED_LIBRARY_ELEMENT, - tags: [DiagnosticTag.Deprecated], - }); - } - }; - export const argumentCorrespondingParameterShouldNotBeDeprecated = (services: SafeDsServices) => (node: TslArgument, accept: ValidationAcceptor) => { const parameter = services.helpers.NodeMapper.argumentToParameter(node); @@ -71,22 +47,6 @@ export const argumentCorrespondingParameterShouldNotBeDeprecated = } }; -export const namedTypeDeclarationShouldNotBeDeprecated = - (services: SafeDsServices) => (node: TslNamedType, accept: ValidationAcceptor) => { - const declaration = node.declaration?.ref; - if (!declaration) { - return; - } - - if (services.builtins.Annotations.callsDeprecated(declaration)) { - accept('warning', `The referenced declaration '${declaration.name}' is deprecated.`, { - node, - code: CODE_DEPRECATED_LIBRARY_ELEMENT, - tags: [DiagnosticTag.Deprecated], - }); - } - }; - export const referenceTargetShouldNotBeDeprecated = (services: SafeDsServices) => (node: TslReference, accept: ValidationAcceptor) => { const target = node.target.ref; diff --git a/packages/ttsl-lang/src/language/validation/builtins/experimental.ts b/packages/ttsl-lang/src/language/validation/builtins/experimental.ts index d2bde550..f1548501 100644 --- a/packages/ttsl-lang/src/language/validation/builtins/experimental.ts +++ b/packages/ttsl-lang/src/language/validation/builtins/experimental.ts @@ -2,11 +2,8 @@ import { ValidationAcceptor } from 'langium'; import { isTslParameter, isTslResult, - isTslWildcard, - TslAnnotationCall, TslArgument, TslAssignee, - TslNamedType, TslReference, } from '../../generated/ast.js'; import { SafeDsServices } from '../../safe-ds-module.js'; @@ -22,10 +19,6 @@ export const assigneeAssignedResultShouldNotBeExperimental = (services: SafeDsSe return; } - if (isTslWildcard(node)) { - return; - } - const assignedObject = services.helpers.NodeMapper.assigneeToAssignedObject(node); if (!isTslResult(assignedObject)) { return; @@ -40,30 +33,6 @@ export const assigneeAssignedResultShouldNotBeExperimental = (services: SafeDsSe }; }; -export const annotationCallAnnotationShouldNotBeExperimental = (services: SafeDsServices) => { - const settingsProvider = services.workspace.SettingsProvider; - - return async (node: TslAnnotationCall, accept: ValidationAcceptor) => { - if (!(await settingsProvider.shouldValidateExperimentalLibraryElement())) { - /* c8 ignore next 2 */ - return; - } - - const annotation = node.annotation?.ref; - if (!annotation) { - return; - } - - if (services.builtins.Annotations.callsExperimental(annotation)) { - accept('warning', `The called annotation '${annotation.name}' is experimental.`, { - node, - property: 'annotation', - code: CODE_EXPERIMENTAL_LIBRARY_ELEMENT, - }); - } - }; -}; - export const argumentCorrespondingParameterShouldNotBeExperimental = (services: SafeDsServices) => { const settingsProvider = services.workspace.SettingsProvider; @@ -87,29 +56,6 @@ export const argumentCorrespondingParameterShouldNotBeExperimental = (services: }; }; -export const namedTypeDeclarationShouldNotBeExperimental = (services: SafeDsServices) => { - const settingsProvider = services.workspace.SettingsProvider; - - return async (node: TslNamedType, accept: ValidationAcceptor) => { - if (!(await settingsProvider.shouldValidateExperimentalLibraryElement())) { - /* c8 ignore next 2 */ - return; - } - - const declaration = node.declaration?.ref; - if (!declaration) { - return; - } - - if (services.builtins.Annotations.callsExperimental(declaration)) { - accept('warning', `The referenced declaration '${declaration.name}' is experimental.`, { - node, - code: CODE_EXPERIMENTAL_LIBRARY_ELEMENT, - }); - } - }; -}; - export const referenceTargetShouldNotExperimental = (services: SafeDsServices) => { const settingsProvider = services.workspace.SettingsProvider; diff --git a/packages/ttsl-lang/src/language/validation/builtins/target.ts b/packages/ttsl-lang/src/language/validation/builtins/target.ts deleted file mode 100644 index 7fe4bc4e..00000000 --- a/packages/ttsl-lang/src/language/validation/builtins/target.ts +++ /dev/null @@ -1,162 +0,0 @@ -import { ValidationAcceptor } from 'langium'; -import { - isTslAnnotation, - isTslAttribute, - isTslClass, - isTslEnum, - isTslEnumVariant, - isTslFunction, - isTslList, - isTslModule, - isTslParameter, - isTslPipeline, - isTslResult, - isTslSegment, - isTslTypeParameter, - TslAnnotation, - TslAnnotationCall, - TslEnumVariant, -} from '../../generated/ast.js'; -import { findFirstAnnotationCallOf, getAnnotationCallTarget } from '../../helpers/nodeProperties.js'; -import { SafeDsServices } from '../../safe-ds-module.js'; - -export const CODE_TARGET_DUPLICATE_TARGET = 'target/duplicate-target'; -export const CODE_TARGET_WRONG_TARGET = 'target/wrong-target'; - -export const targetShouldNotHaveDuplicateEntries = (services: SafeDsServices) => { - const builtinAnnotations = services.builtins.Annotations; - const builtinEnums = services.builtins.Enums; - const partialEvaluator = services.evaluation.PartialEvaluator; - const nodeMapper = services.helpers.NodeMapper; - - return (node: TslAnnotation, accept: ValidationAcceptor) => { - const annotationCall = findFirstAnnotationCallOf(node, builtinAnnotations.Target); - if (!annotationCall) { - return; - } - - const targets = nodeMapper.callToParameterValue(annotationCall, 'targets'); - if (!isTslList(targets)) { - return; - } - - const knownTargets = new Set(); - for (const target of targets.elements) { - const evaluatedTarget = partialEvaluator.evaluate(target); - if (!builtinEnums.isEvaluatedAnnotationTarget(evaluatedTarget)) { - continue; - } - - if (knownTargets.has(evaluatedTarget.variant)) { - accept('warning', `The target '${evaluatedTarget.variant.name}' was set already.`, { - node: target, - code: CODE_TARGET_DUPLICATE_TARGET, - }); - } else { - knownTargets.add(evaluatedTarget.variant); - } - } - }; -}; - -export const annotationCallMustHaveCorrectTarget = (services: SafeDsServices) => { - const builtinAnnotations = services.builtins.Annotations; - - return (node: TslAnnotationCall, accept: ValidationAcceptor) => { - const annotation = node.annotation?.ref; - if (!annotation) { - return; - } - - const actualTarget = getActualTarget(node); - /* c8 ignore start */ - if (!actualTarget) { - return; - } - /* c8 ignore stop */ - - const validTargets = builtinAnnotations - .streamValidTargets(annotation) - .map((it) => it.name) - .toSet(); - - if (!validTargets.has(actualTarget.enumVariantName)) { - accept('error', `The annotation '${annotation.name}' cannot be applied to ${actualTarget.prettyName}.`, { - node, - property: 'annotation', - code: CODE_TARGET_WRONG_TARGET, - }); - } - }; -}; - -const getActualTarget = (node: TslAnnotationCall): GetActualTargetResult | void => { - const annotatedObject = getAnnotationCallTarget(node); - - if (isTslAnnotation(annotatedObject)) { - return { - enumVariantName: 'Annotation', - prettyName: 'an annotation', - }; - } else if (isTslAttribute(annotatedObject)) { - return { - enumVariantName: 'Attribute', - prettyName: 'an attribute', - }; - } else if (isTslClass(annotatedObject)) { - return { - enumVariantName: 'Class', - prettyName: 'a class', - }; - } else if (isTslEnum(annotatedObject)) { - return { - enumVariantName: 'Enum', - prettyName: 'an enum', - }; - } else if (isTslEnumVariant(annotatedObject)) { - return { - enumVariantName: 'EnumVariant', - prettyName: 'an enum variant', - }; - } else if (isTslFunction(annotatedObject)) { - return { - enumVariantName: 'Function', - prettyName: 'a function', - }; - } else if (isTslModule(annotatedObject)) { - return { - enumVariantName: 'Module', - prettyName: 'a module', - }; - } else if (isTslParameter(annotatedObject)) { - return { - enumVariantName: 'Parameter', - prettyName: 'a parameter', - }; - } else if (isTslPipeline(annotatedObject)) { - return { - enumVariantName: 'Pipeline', - prettyName: 'a pipeline', - }; - } else if (isTslResult(annotatedObject)) { - return { - enumVariantName: 'Result', - prettyName: 'a result', - }; - } else if (isTslSegment(annotatedObject)) { - return { - enumVariantName: 'Segment', - prettyName: 'a segment', - }; - } else if (isTslTypeParameter(annotatedObject)) { - return { - enumVariantName: 'TypeParameter', - prettyName: 'a type parameter', - }; - } -}; - -interface GetActualTargetResult { - enumVariantName: string; - prettyName: string; -} diff --git a/packages/ttsl-lang/src/language/validation/experimentalLanguageFeatures.ts b/packages/ttsl-lang/src/language/validation/experimentalLanguageFeatures.ts index bc8d5935..56d99aad 100644 --- a/packages/ttsl-lang/src/language/validation/experimentalLanguageFeatures.ts +++ b/packages/ttsl-lang/src/language/validation/experimentalLanguageFeatures.ts @@ -1,50 +1,12 @@ import { AstUtils, ValidationAcceptor } from 'langium'; import { isTslDictionary, - isTslUnionType, - type TslConstraintList, - type TslLiteralType, type TslDictionary, - type TslUnionType, } from '../generated/ast.js'; import { SafeDsServices } from '../safe-ds-module.js'; export const CODE_EXPERIMENTAL_LANGUAGE_FEATURE = 'experimental/language-feature'; -export const constraintListsShouldBeUsedWithCaution = (services: SafeDsServices) => { - const settingsProvider = services.workspace.SettingsProvider; - - return async (node: TslConstraintList, accept: ValidationAcceptor) => { - if (!(await settingsProvider.shouldValidateExperimentalLanguageFeature())) { - /* c8 ignore next 2 */ - return; - } - - accept('warning', 'Constraint lists & constraints are experimental and may change without prior notice.', { - node, - keyword: 'where', - code: CODE_EXPERIMENTAL_LANGUAGE_FEATURE, - }); - }; -}; - -export const literalTypesShouldBeUsedWithCaution = (services: SafeDsServices) => { - const settingsProvider = services.workspace.SettingsProvider; - - return async (node: TslLiteralType, accept: ValidationAcceptor) => { - if (!(await settingsProvider.shouldValidateExperimentalLanguageFeature())) { - /* c8 ignore next 2 */ - return; - } - - accept('warning', 'Literal types are experimental and may change without prior notice.', { - node, - keyword: 'literal', - code: CODE_EXPERIMENTAL_LANGUAGE_FEATURE, - }); - }; -}; - export const mapsShouldBeUsedWithCaution = (services: SafeDsServices) => { const settingsProvider = services.workspace.SettingsProvider; @@ -64,26 +26,4 @@ export const mapsShouldBeUsedWithCaution = (services: SafeDsServices) => { code: CODE_EXPERIMENTAL_LANGUAGE_FEATURE, }); }; -}; - -export const unionTypesShouldBeUsedWithCaution = (services: SafeDsServices) => { - const settingsProvider = services.workspace.SettingsProvider; - - return async (node: TslUnionType, accept: ValidationAcceptor) => { - if (!(await settingsProvider.shouldValidateExperimentalLanguageFeature())) { - /* c8 ignore next 2 */ - return; - } - - // There's already a warning on the container - if (AstUtils.hasContainerOfType(node.$container, isTslUnionType)) { - return; - } - - accept('warning', 'Union types are experimental and may change without prior notice.', { - node, - keyword: 'union', - code: CODE_EXPERIMENTAL_LANGUAGE_FEATURE, - }); - }; -}; +}; \ No newline at end of file diff --git a/packages/ttsl-lang/src/language/validation/inheritance.ts b/packages/ttsl-lang/src/language/validation/inheritance.ts deleted file mode 100644 index 599c410f..00000000 --- a/packages/ttsl-lang/src/language/validation/inheritance.ts +++ /dev/null @@ -1,203 +0,0 @@ -import { AstUtils, ValidationAcceptor } from 'langium'; -import { isEmpty, isEqualSet } from '../../helpers/collections.js'; -import { isTslClass, isTslFunction, TslClass, type TslClassMember } from '../generated/ast.js'; -import { getParentTypes, getQualifiedName } from '../helpers/nodeProperties.js'; -import { SafeDsServices } from '../safe-ds-module.js'; -import { ClassType, Type, UnknownType } from '../typing/model.js'; -import { SafeDsTypeComputer } from '../typing/safe-ds-type-computer.js'; -import { expandToStringWithNL } from 'langium/generate'; - -export const CODE_INHERITANCE_CYCLE = 'inheritance/cycle'; -export const CODE_INHERITANCE_MULTIPLE_INHERITANCE = 'inheritance/multiple-inheritance'; -export const CODE_INHERITANCE_IDENTICAL_TO_OVERRIDDEN_MEMBER = 'inheritance/identical-to-overridden-member'; -export const CODE_INHERITANCE_INCOMPATIBLE_TO_OVERRIDDEN_MEMBER = 'inheritance/incompatible-to-overridden-member'; -export const CODE_INHERITANCE_NOT_A_CLASS = 'inheritance/not-a-class'; -export const CODE_INHERITANCE_NULLABLE = 'inheritance/nullable'; - -export const classMemberMustMatchOverriddenMemberAndShouldBeNeeded = (services: SafeDsServices) => { - const builtinAnnotations = services.builtins.Annotations; - const classHierarchy = services.types.ClassHierarchy; - const typeChecker = services.types.TypeChecker; - const typeComputer = services.types.TypeComputer; - - return (node: TslClassMember, accept: ValidationAcceptor): void => { - // Check whether the member overrides something - const overriddenMember = classHierarchy.getOverriddenMember(node); - if (!overriddenMember) { - return; - } - - // Compute types - const { ownMemberType, overriddenMemberType, substitutedOwnMemberType, substitutedOverriddenMemberType } = - computeMemberTypes(node, overriddenMember, typeComputer); - - // Check whether the overriding is legal and needed - if (!typeChecker.isSubtypeOf(substitutedOwnMemberType, overriddenMemberType)) { - accept( - 'error', - expandToStringWithNL` - Overriding member does not match the overridden member: - - Expected type: ${overriddenMemberType} - - Actual type: ${ownMemberType} - `, - { - node, - property: 'name', - code: CODE_INHERITANCE_INCOMPATIBLE_TO_OVERRIDDEN_MEMBER, - }, - ); - } else if (typeChecker.isSubtypeOf(substitutedOverriddenMemberType, ownMemberType)) { - // Prevents the info from showing when editing the builtin files - if (isInSafedsLangAnyClass(services, node)) { - return; - } - - // Reasons for impurity must differ - if ( - isTslFunction(node) && - isTslFunction(overriddenMember) && - !isEqualSet( - builtinAnnotations - .streamImpurityReasons(node) - .map((it) => it.toString()) - .toSet(), - builtinAnnotations - .streamImpurityReasons(overriddenMember) - .map((it) => it.toString()) - .toSet(), - ) - ) { - return; - } - - accept('info', 'Overriding member is identical to overridden member and can be removed.', { - node, - property: 'name', - code: CODE_INHERITANCE_IDENTICAL_TO_OVERRIDDEN_MEMBER, - }); - } - }; -}; - -const computeMemberTypes = ( - ownMember: TslClassMember, - overriddenMember: TslClassMember, - typeComputer: SafeDsTypeComputer, -): ComputeMemberTypesResult => { - // Compute basic types (might contain type parameters) - const ownMemberType = typeComputer.computeType(ownMember); - let overriddenMemberType = typeComputer.computeType(overriddenMember); - - // Substitute type parameters of class containing the overridden member - const classContainingOwnMember = AstUtils.getContainerOfType(ownMember, isTslClass); - const typeContainingOwnMember = typeComputer.computeType(classContainingOwnMember); - - if (typeContainingOwnMember instanceof ClassType) { - const classContainingOverriddenMember = AstUtils.getContainerOfType(overriddenMember, isTslClass); - const typeContainingOverriddenMember = typeComputer.computeMatchingSupertype( - typeContainingOwnMember, - classContainingOverriddenMember, - ); - - if (typeContainingOverriddenMember) { - overriddenMemberType = overriddenMemberType.substituteTypeParameters( - typeContainingOverriddenMember.substitutions, - ); - } - } - - // Substitute type parameters of methods - const substitutedOwnMemberType = ownMemberType.substituteTypeParameters( - typeComputer.computeSubstitutionsForOverriding(ownMemberType, overriddenMemberType), - ); - const substitutedOverriddenMemberType = overriddenMemberType.substituteTypeParameters( - typeComputer.computeSubstitutionsForOverriding(overriddenMemberType, ownMemberType), - ); - - return { ownMemberType, overriddenMemberType, substitutedOwnMemberType, substitutedOverriddenMemberType }; -}; - -interface ComputeMemberTypesResult { - /** - * The type of the own member. Type parameters of the containing class or own member are not yet substituted. - */ - ownMemberType: Type; - - /** - * The type of the overridden member. Type parameters of the containing class are substituted, but not the type - * parameters of the overridden member. - */ - overriddenMemberType: Type; - - /** - * The type of the own member with all type parameters of the own member substituted. Substitutions are based on the - * types of the corresponding parameters of the overridden member. - */ - substitutedOwnMemberType: Type; - - /** - * The type of the overridden member with all type parameters of the overridden member substituted. Substitutions - * are based on the types of the corresponding parameters of the own member. - */ - substitutedOverriddenMemberType: Type; -} - -const isInSafedsLangAnyClass = (services: SafeDsServices, node: TslClassMember): boolean => { - const containingClass = AstUtils.getContainerOfType(node, isTslClass); - return ( - isTslClass(containingClass) && - getQualifiedName(containingClass) === getQualifiedName(services.builtins.Classes.Any) - ); -}; - -export const classMustOnlyInheritASingleClass = (services: SafeDsServices) => { - const typeComputer = services.types.TypeComputer; - const computeType = typeComputer.computeType.bind(typeComputer); - - return (node: TslClass, accept: ValidationAcceptor): void => { - const parentTypes = getParentTypes(node); - if (isEmpty(parentTypes)) { - return; - } - - const [firstParentType, ...otherParentTypes] = parentTypes; - - // First parent type must be a class - const computedType = computeType(firstParentType); - if (computedType !== UnknownType) { - if (!(computedType instanceof ClassType)) { - accept('error', 'A class must only inherit classes.', { - node: firstParentType!, - code: CODE_INHERITANCE_NOT_A_CLASS, - }); - } else if (computedType.isExplicitlyNullable) { - accept('error', 'The parent type must not be nullable.', { - node: firstParentType!, - code: CODE_INHERITANCE_NULLABLE, - }); - } - } - - // Must have only one parent type - for (const parentType of otherParentTypes) { - accept('error', 'Multiple inheritance is not supported. Only the first parent type will be considered.', { - node: parentType, - code: CODE_INHERITANCE_MULTIPLE_INHERITANCE, - }); - } - }; -}; - -export const classMustNotInheritItself = (services: SafeDsServices) => { - const classHierarchy = services.types.ClassHierarchy; - - return (node: TslClass, accept: ValidationAcceptor): void => { - const superClasses = classHierarchy.streamProperSuperclasses(node); - if (superClasses.includes(node)) { - accept('error', 'A class must not directly or indirectly be a subtype of itself.', { - node: getParentTypes(node)[0]!, - code: CODE_INHERITANCE_CYCLE, - }); - } - }; -}; diff --git a/packages/ttsl-lang/src/language/validation/names.ts b/packages/ttsl-lang/src/language/validation/names.ts index 28814e67..cc4f4040 100644 --- a/packages/ttsl-lang/src/language/validation/names.ts +++ b/packages/ttsl-lang/src/language/validation/names.ts @@ -4,46 +4,25 @@ import { listBuiltinFiles } from '../builtins/fileFinder.js'; import { BUILTINS_LANG_PACKAGE, BUILTINS_ROOT_PACKAGE } from '../builtins/packageNames.js'; import { isTslQualifiedImport, - TslAnnotation, - TslAttribute, - TslBlockLambda, - TslBlockLambdaResult, TslCallableType, - TslClass, TslDeclaration, - TslEnum, - TslEnumVariant, - TslExpressionLambda, TslFunction, TslImportedDeclaration, TslModule, TslParameter, - TslPipeline, TslPlaceholder, TslResult, - TslSchema, - TslSegment, - TslTypeParameter, } from '../generated/ast.js'; import { CODEGEN_PREFIX } from '../generation/safe-ds-python-generator.js'; -import { isInPipelineFile, isInStubFile, isInTestFile } from '../helpers/fileExtensions.js'; import { - getClassMembers, - getColumns, - getEnumVariants, getImportedDeclarations, getImports, getModuleMembers, getPackageName, getParameters, getResults, - getTypeParameters, - isStatic, - streamBlockLambdaResults, - streamPlaceholders, } from '../helpers/nodeProperties.js'; import { SafeDsServices } from '../safe-ds-module.js'; -import { declarationIsAllowedInPipelineFile, declarationIsAllowedInStubFile } from './other/modules.js'; export const CODE_NAME_CODEGEN_PREFIX = 'name/codegen-prefix'; export const CODE_NAME_CORE_DECLARATION = 'name/core-declaration'; @@ -113,18 +92,6 @@ export const nameShouldHaveCorrectCasing = (services: SafeDsServices) => { } switch (node.$type) { - case TslAnnotation: - return nameShouldBeUpperCamelCase(node, 'annotations', accept); - case TslAttribute: - return nameShouldBeLowerCamelCase(node, 'attributes', accept); - case TslBlockLambdaResult: - return nameShouldBeLowerCamelCase(node, 'block lambda results', accept); - case TslClass: - return nameShouldBeUpperCamelCase(node, 'classes', accept); - case TslEnum: - return nameShouldBeUpperCamelCase(node, 'enums', accept); - case TslEnumVariant: - return nameShouldBeUpperCamelCase(node, 'enum variants', accept); case TslFunction: return nameShouldBeLowerCamelCase(node, 'functions', accept); case TslModule: @@ -140,18 +107,10 @@ export const nameShouldHaveCorrectCasing = (services: SafeDsServices) => { return; case TslParameter: return nameShouldBeLowerCamelCase(node, 'parameters', accept); - case TslPipeline: - return nameShouldBeLowerCamelCase(node, 'pipelines', accept); case TslPlaceholder: return nameShouldBeLowerCamelCase(node, 'placeholders', accept); case TslResult: return nameShouldBeLowerCamelCase(node, 'results', accept); - case TslSchema: - return nameShouldBeUpperCamelCase(node, 'schemas', accept); - case TslSegment: - return nameShouldBeLowerCamelCase(node, 'segments', accept); - case TslTypeParameter: - return nameShouldBeUpperCamelCase(node, 'type parameters', accept); } /* c8 ignore next */ }; @@ -168,17 +127,6 @@ const isLowerCamelCase = (name: string): boolean => { return /^[a-z][a-zA-Z0-9]*$/gu.test(name); }; -const nameShouldBeUpperCamelCase = (node: TslDeclaration, nodeName: string, accept: ValidationAcceptor): void => { - const name = node.name ?? ''; - if (!isUpperCamelCase(name)) { - acceptCasingWarning(node, nodeName, 'UpperCamelCase', accept); - } -}; - -const isUpperCamelCase = (name: string): boolean => { - return /^[A-Z][a-zA-Z0-9]*$/gu.test(name); -}; - const acceptCasingWarning = ( node: TslDeclaration, nodeName: string, @@ -196,54 +144,11 @@ const acceptCasingWarning = ( // Uniqueness // ----------------------------------------------------------------------------- -export const annotationMustContainUniqueNames = (node: TslAnnotation, accept: ValidationAcceptor): void => { - namesMustBeUnique(getParameters(node), (name) => `A parameter with name '${name}' exists already.`, accept); -}; - -export const blockLambdaMustContainUniqueNames = (node: TslBlockLambda, accept: ValidationAcceptor): void => { - const parametersAndPlaceholders = [...getParameters(node), ...streamPlaceholders(node.body)]; - namesMustBeUnique( - parametersAndPlaceholders, - (name) => `A parameter or placeholder with name '${name}' exists already.`, - accept, - ); - - namesMustBeUnique(streamBlockLambdaResults(node), (name) => `A result with name '${name}' exists already.`, accept); -}; - export const callableTypeMustContainUniqueNames = (node: TslCallableType, accept: ValidationAcceptor): void => { namesMustBeUnique(getParameters(node), (name) => `A parameter with name '${name}' exists already.`, accept); namesMustBeUnique(getResults(node.resultList), (name) => `A result with name '${name}' exists already.`, accept); }; -export const classMustContainUniqueNames = (node: TslClass, accept: ValidationAcceptor): void => { - const typeParametersAndParameters = [...getTypeParameters(node.typeParameterList), ...getParameters(node)]; - namesMustBeUnique( - typeParametersAndParameters, - (name) => `A type parameter or parameter with name '${name}' exists already.`, - accept, - ); - - const instanceMembers = getClassMembers(node).filter((it) => !isStatic(it)); - namesMustBeUnique(instanceMembers, (name) => `An instance member with name '${name}' exists already.`, accept); - - const staticMembers = getClassMembers(node).filter(isStatic); - namesMustBeUnique(staticMembers, (name) => `A static member with name '${name}' exists already.`, accept); -}; - -export const enumMustContainUniqueNames = (node: TslEnum, accept: ValidationAcceptor): void => { - namesMustBeUnique(getEnumVariants(node), (name) => `A variant with name '${name}' exists already.`, accept); -}; - -export const enumVariantMustContainUniqueNames = (node: TslEnumVariant, accept: ValidationAcceptor): void => { - const parameters = [...getParameters(node)]; - namesMustBeUnique(parameters, (name) => `A parameter with name '${name}' exists already.`, accept); -}; - -export const expressionLambdaMustContainUniqueNames = (node: TslExpressionLambda, accept: ValidationAcceptor): void => { - namesMustBeUnique(getParameters(node), (name) => `A parameter with name '${name}' exists already.`, accept); -}; - export const moduleMemberMustHaveNameThatIsUniqueInPackage = (services: SafeDsServices) => { const packageManager = services.workspace.PackageManager; const builtinUris = new Set(listBuiltinFiles().map((it) => it.toString())); @@ -306,61 +211,15 @@ export const moduleMustContainUniqueNames = (node: TslModule, accept: Validation } // Names of module members must be unique - if (isInPipelineFile(node)) { - namesMustBeUnique( - getModuleMembers(node), - (name) => `A declaration with name '${name}' exists already in this file.`, - accept, - declarationIsAllowedInPipelineFile, - ); - } else if (isInStubFile(node)) { - namesMustBeUnique( - getModuleMembers(node), - (name) => `A declaration with name '${name}' exists already in this file.`, - accept, - declarationIsAllowedInStubFile, - ); - } else if (isInTestFile(node)) { - namesMustBeUnique( - getModuleMembers(node), - (name) => `A declaration with name '${name}' exists already in this file.`, - accept, - ); - } -}; - -const importedDeclarationName = (node: TslImportedDeclaration | undefined): string | undefined => { - return node?.alias?.alias ?? node?.declaration?.ref?.name; -}; - -export const pipelineMustContainUniqueNames = (node: TslPipeline, accept: ValidationAcceptor): void => { namesMustBeUnique( - streamPlaceholders(node.body), - (name) => `A placeholder with name '${name}' exists already.`, + getModuleMembers(node), + (name) => `A declaration with name '${name}' exists already in this file.`, accept, ); }; -export const schemaMustContainUniqueNames = (node: TslSchema, accept: ValidationAcceptor): void => { - const duplicates = duplicatesBy(getColumns(node), (it) => it.columnName.value); - for (const duplicate of duplicates) { - accept('error', `A column with name '${duplicate.columnName.value}' exists already.`, { - node: duplicate, - property: 'columnName', - code: CODE_NAME_DUPLICATE, - }); - } -}; - -export const segmentMustContainUniqueNames = (node: TslSegment, accept: ValidationAcceptor): void => { - const parametersAndPlaceholder = [...getParameters(node), ...streamPlaceholders(node.body)]; - namesMustBeUnique( - parametersAndPlaceholder, - (name) => `A parameter or placeholder with name '${name}' exists already.`, - accept, - ); - - namesMustBeUnique(getResults(node.resultList), (name) => `A result with name '${name}' exists already.`, accept); +const importedDeclarationName = (node: TslImportedDeclaration | undefined): string | undefined => { + return node?.alias?.alias ?? node?.declaration?.ref?.name; }; const namesMustBeUnique = ( diff --git a/packages/ttsl-lang/src/language/validation/other/argumentLists.ts b/packages/ttsl-lang/src/language/validation/other/argumentLists.ts index 2c902ac9..5cb232f2 100644 --- a/packages/ttsl-lang/src/language/validation/other/argumentLists.ts +++ b/packages/ttsl-lang/src/language/validation/other/argumentLists.ts @@ -1,7 +1,7 @@ import { AstUtils, ValidationAcceptor } from 'langium'; import { duplicatesBy, isEmpty } from '../../../helpers/collections.js'; import { pluralize } from '../../../helpers/strings.js'; -import { isTslAnnotation, isTslCall, TslAbstractCall, TslArgumentList } from '../../generated/ast.js'; +import { isTslCall, TslAbstractCall, TslArgumentList } from '../../generated/ast.js'; import { getArguments, getParameters, Parameter } from '../../helpers/nodeProperties.js'; import { SafeDsServices } from '../../safe-ds-module.js'; @@ -38,11 +38,7 @@ export const argumentListMustNotHaveTooManyArguments = (services: SafeDsServices return; } - // We already report other errors in those cases const callable = nodeMapper.callToCallable(node); - if (!callable || (isTslCall(node) && isTslAnnotation(callable))) { - return; - } const parameters = getParameters(callable); const maxArgumentCount = parameters.length; @@ -82,9 +78,6 @@ export const argumentListMustNotSetParameterMultipleTimes = (services: SafeDsSer // We already report other errors in this case const containingCall = AstUtils.getContainerOfType(node, isTslCall); const callable = nodeMapper.callToCallable(containingCall); - if (isTslAnnotation(callable)) { - return; - } const args = getArguments(node); const duplicates = duplicatesBy(args, argumentToParameterOrUndefined); @@ -108,11 +101,7 @@ export const argumentListMustSetAllRequiredParameters = (services: SafeDsService return; } - // We already report other errors in those cases const callable = nodeMapper.callToCallable(node); - if (!callable || (isTslCall(node) && isTslAnnotation(callable))) { - return; - } const expectedParameters = getParameters(callable).filter(Parameter.isRequired); if (isEmpty(expectedParameters)) { diff --git a/packages/ttsl-lang/src/language/validation/other/declarations/annotationCalls.ts b/packages/ttsl-lang/src/language/validation/other/declarations/annotationCalls.ts index cfbb9589..768f3baf 100644 --- a/packages/ttsl-lang/src/language/validation/other/declarations/annotationCalls.ts +++ b/packages/ttsl-lang/src/language/validation/other/declarations/annotationCalls.ts @@ -3,10 +3,7 @@ import { isEmpty } from '../../../../helpers/collections.js'; import { isTslCallable, isTslCallableType, - isTslLambda, - TslAnnotationCall, TslCallableType, - TslLambda, TslParameter, } from '../../../generated/ast.js'; import { @@ -16,48 +13,10 @@ import { getResults, Parameter, } from '../../../helpers/nodeProperties.js'; -import type { SafeDsServices } from '../../../safe-ds-module.js'; -export const CODE_ANNOTATION_CALL_CONSTANT_ARGUMENT = 'annotation-call/constant-argument'; -export const CODE_ANNOTATION_CALL_MISSING_ARGUMENT_LIST = 'annotation-call/missing-argument-list'; export const CODE_ANNOTATION_CALL_TARGET_PARAMETER = 'annotation-call/target-parameter'; export const CODE_ANNOTATION_CALL_TARGET_RESULT = 'annotation-call/target-result'; -export const annotationCallArgumentsMustBeConstant = (services: SafeDsServices) => { - const partialEvaluator = services.evaluation.PartialEvaluator; - - return (node: TslAnnotationCall, accept: ValidationAcceptor) => { - for (const argument of getArguments(node)) { - if (!partialEvaluator.canBeValueOfConstantParameter(argument.value)) { - accept('error', 'Values assigned to annotation parameters must be constant.', { - node: argument, - property: 'value', - code: CODE_ANNOTATION_CALL_CONSTANT_ARGUMENT, - }); - } - } - }; -}; - -export const annotationCallMustNotLackArgumentList = (node: TslAnnotationCall, accept: ValidationAcceptor) => { - if (node.argumentList) { - return; - } - - const requiredParameters = getParameters(node.annotation?.ref).filter(Parameter.isRequired); - if (!isEmpty(requiredParameters)) { - accept( - 'error', - `The annotation '${node.annotation?.$refText}' has required parameters, so an argument list must be added.`, - { - node, - property: 'annotation', - code: CODE_ANNOTATION_CALL_MISSING_ARGUMENT_LIST, - }, - ); - } -}; - export const callableTypeParametersMustNotBeAnnotated = (node: TslCallableType, accept: ValidationAcceptor) => { for (const parameter of getParameters(node)) { for (const annotationCall of getAnnotationCalls(parameter)) { @@ -80,18 +39,7 @@ export const callableTypeResultsMustNotBeAnnotated = (node: TslCallableType, acc } }; -export const lambdaParametersMustNotBeAnnotated = (node: TslLambda, accept: ValidationAcceptor) => { - for (const parameter of getParameters(node)) { - for (const annotationCall of getAnnotationCalls(parameter)) { - accept('error', 'Lambda parameters must not be annotated.', { - node: annotationCall, - code: CODE_ANNOTATION_CALL_TARGET_PARAMETER, - }); - } - } -}; - export const parameterCanBeAnnotated = (node: TslParameter) => { const containingCallable = AstUtils.getContainerOfType(node, isTslCallable); - return !isTslCallableType(containingCallable) && !isTslLambda(containingCallable); + return !isTslCallableType(containingCallable); }; diff --git a/packages/ttsl-lang/src/language/validation/other/declarations/parameterBounds.ts b/packages/ttsl-lang/src/language/validation/other/declarations/parameterBounds.ts index 043898d9..a79bdbd1 100644 --- a/packages/ttsl-lang/src/language/validation/other/declarations/parameterBounds.ts +++ b/packages/ttsl-lang/src/language/validation/other/declarations/parameterBounds.ts @@ -4,7 +4,6 @@ import { isTslComparisonOperator, type TslCall, TslParameter, - TslParameterBound, } from '../../../generated/ast.js'; import { AstUtils, ValidationAcceptor } from 'langium'; import { getArguments, getParameters, Parameter } from '../../../helpers/nodeProperties.js'; @@ -127,70 +126,4 @@ const checkBound = ( } return undefined; -}; - -export const parameterBoundParameterMustBeConstFloatOrInt = (services: SafeDsServices) => { - const coreTypes = services.types.CoreTypes; - const typeChecker = services.types.TypeChecker; - const typeComputer = services.types.TypeComputer; - - return (node: TslParameterBound, accept: ValidationAcceptor) => { - const parameter = node.leftOperand?.ref; - if (!parameter) { - return; - } - - const parameterType = typeComputer.computeType(parameter); - if ( - !typeChecker.isSubtypeOf(parameterType, coreTypes.Float) && - !typeChecker.isSubtypeOf(parameterType, coreTypes.Int) - ) { - accept('error', "Only 'Float' and 'Int' parameters can have bounds.", { - node, - property: 'leftOperand', - code: CODE_PARAMETER_BOUND_PARAMETER, - }); - } else if (!Parameter.isConstant(parameter)) { - accept('error', 'Only constant parameters can have bounds.', { - node, - property: 'leftOperand', - code: CODE_PARAMETER_BOUND_PARAMETER, - }); - } - }; -}; - -export const parameterBoundRightOperandMustEvaluateToFloatConstantOrIntConstant = (services: SafeDsServices) => { - const coreTypes = services.types.CoreTypes; - const typeChecker = services.types.TypeChecker; - const typeComputer = services.types.TypeComputer; - const partialEvaluator = services.evaluation.PartialEvaluator; - const one = new IntConstant(1n); - - return (node: TslParameterBound, accept: ValidationAcceptor) => { - const rightOperandType = typeComputer.computeType(node.rightOperand); - - // Must have correct type - let rightOperandIsValid = - typeChecker.isSubtypeOf(rightOperandType, coreTypes.Float) || - typeChecker.isSubtypeOf(rightOperandType, coreTypes.Int); - - // Must evaluate to a constant after substituting constant parameters - if (rightOperandIsValid) { - const containingCallable = AstUtils.getContainerOfType(node, isTslCallable); - const constantParameters = getParameters(containingCallable).filter(Parameter.isConstant); - const substitutions = new Map(constantParameters.map((it) => [it, one])); - const value = partialEvaluator.evaluate(node.rightOperand, substitutions); - - rightOperandIsValid = value instanceof FloatConstant || value instanceof IntConstant; - } - - if (!rightOperandIsValid) { - accept('error', 'The right operand of a parameter bound must evaluate to a float or int constant.', { - node, - property: 'rightOperand', - code: CODE_PARAMETER_BOUND_RIGHT_OPERAND, - }); - } - }; -}; +}; \ No newline at end of file diff --git a/packages/ttsl-lang/src/language/validation/other/declarations/parameters.ts b/packages/ttsl-lang/src/language/validation/other/declarations/parameters.ts index 746e5c2c..083b628c 100644 --- a/packages/ttsl-lang/src/language/validation/other/declarations/parameters.ts +++ b/packages/ttsl-lang/src/language/validation/other/declarations/parameters.ts @@ -1,5 +1,5 @@ import { AstUtils, ValidationAcceptor } from 'langium'; -import { isTslAnnotation, isTslCallable, TslParameter } from '../../../generated/ast.js'; +import { isTslCallable, TslParameter } from '../../../generated/ast.js'; import { Parameter } from '../../../helpers/nodeProperties.js'; import { SafeDsServices } from '../../../safe-ds-module.js'; @@ -15,10 +15,7 @@ export const constantParameterMustHaveConstantDefaultValue = (services: SafeDsSe } if (!partialEvaluator.canBeValueOfConstantParameter(node.defaultValue)) { - const containingCallable = AstUtils.getContainerOfType(node, isTslCallable); - const kind = isTslAnnotation(containingCallable) ? 'annotation' : 'constant'; - - accept('error', `Default values of ${kind} parameters must be constant.`, { + accept('error', `Default values of constant parameters must be constant.`, { node, property: 'defaultValue', code: CODE_PARAMETER_CONSTANT_DEFAULT_VALUE, @@ -38,10 +35,7 @@ export const constantParameterMustHaveTypeThatCanBeEvaluatedToConstant = (servic const type = typeComputer.computeType(node); if (!typeChecker.canBeTypeOfConstantParameter(type)) { - const containingCallable = AstUtils.getContainerOfType(node, isTslCallable); - const kind = isTslAnnotation(containingCallable) ? 'An annotation' : 'A constant'; - - accept('error', `${kind} parameter cannot have type '${type.toString()}'.`, { + accept('error', `A constant parameter cannot have type '${type.toString()}'.`, { node, property: 'type', code: CODE_PARAMETER_CONSTANT_TYPE, diff --git a/packages/ttsl-lang/src/language/validation/other/declarations/segments.ts b/packages/ttsl-lang/src/language/validation/other/declarations/segments.ts deleted file mode 100644 index 74a14a90..00000000 --- a/packages/ttsl-lang/src/language/validation/other/declarations/segments.ts +++ /dev/null @@ -1,78 +0,0 @@ -import { TslSegment } from '../../../generated/ast.js'; -import { ValidationAcceptor } from 'langium'; -import { getParameters, getResults } from '../../../helpers/nodeProperties.js'; -import { SafeDsServices } from '../../../safe-ds-module.js'; -import { DiagnosticTag } from 'vscode-languageserver'; - -export const CODE_SEGMENT_DUPLICATE_YIELD = 'segment/duplicate-yield'; -export const CODE_SEGMENT_UNASSIGNED_RESULT = 'segment/unassigned-result'; -export const CODE_SEGMENT_UNUSED = 'segment/unused'; -export const CODE_SEGMENT_UNUSED_PARAMETER = 'segment/unused-parameter'; - -export const segmentResultMustBeAssignedExactlyOnce = (services: SafeDsServices) => { - const nodeMapper = services.helpers.NodeMapper; - - return (node: TslSegment, accept: ValidationAcceptor) => { - const results = getResults(node.resultList); - for (const result of results) { - const yields = nodeMapper.resultToYields(result); - if (yields.isEmpty()) { - accept('error', 'Nothing is assigned to this result.', { - node: result, - property: 'name', - code: CODE_SEGMENT_UNASSIGNED_RESULT, - }); - continue; - } - - const duplicateYields = yields.tail(1); - for (const duplicate of duplicateYields) { - accept('error', `The result '${result.name}' has been assigned already.`, { - node: duplicate, - property: 'result', - code: CODE_SEGMENT_DUPLICATE_YIELD, - }); - } - } - }; -}; - -export const segmentShouldBeUsed = (services: SafeDsServices) => { - const referenceProvider = services.references.References; - - return (node: TslSegment, accept: ValidationAcceptor) => { - // Don't show this warning for public segments - if (node.visibility === undefined) { - return; - } - - const references = referenceProvider.findReferences(node, {}); - if (references.isEmpty()) { - accept('warning', 'This segment is unused and can be removed.', { - node, - property: 'name', - code: CODE_SEGMENT_UNUSED, - tags: [DiagnosticTag.Unnecessary], - }); - } - }; -}; - -export const segmentParameterShouldBeUsed = (services: SafeDsServices) => { - const nodeMapper = services.helpers.NodeMapper; - - return (node: TslSegment, accept: ValidationAcceptor) => { - for (const parameter of getParameters(node)) { - const usages = nodeMapper.parameterToReferences(parameter); - - if (usages.isEmpty()) { - accept('warning', 'This parameter is unused and can be removed.', { - node: parameter, - property: 'name', - code: CODE_SEGMENT_UNUSED_PARAMETER, - tags: [DiagnosticTag.Unnecessary], - }); - } - } - }; -}; diff --git a/packages/ttsl-lang/src/language/validation/other/declarations/typeParameterLists.ts b/packages/ttsl-lang/src/language/validation/other/declarations/typeParameterLists.ts deleted file mode 100644 index 10a2682f..00000000 --- a/packages/ttsl-lang/src/language/validation/other/declarations/typeParameterLists.ts +++ /dev/null @@ -1,23 +0,0 @@ -import { ValidationAcceptor } from 'langium'; -import { TslTypeParameterList } from '../../../generated/ast.js'; -import { TypeParameter } from '../../../helpers/nodeProperties.js'; - -export const CODE_TYPE_PARAMETER_LIST_REQUIRED_AFTER_OPTIONAL = 'type-parameter-list/required-after-optional'; - -export const typeParameterListMustNotHaveRequiredTypeParametersAfterOptionalTypeParameters = ( - node: TslTypeParameterList, - accept: ValidationAcceptor, -) => { - let foundOptional = false; - for (const typeParameter of node.typeParameters) { - if (TypeParameter.isOptional(typeParameter)) { - foundOptional = true; - } else if (foundOptional) { - accept('error', 'After the first optional type parameter all type parameters must be optional.', { - node: typeParameter, - property: 'name', - code: CODE_TYPE_PARAMETER_LIST_REQUIRED_AFTER_OPTIONAL, - }); - } - } -}; diff --git a/packages/ttsl-lang/src/language/validation/other/declarations/typeParameters.ts b/packages/ttsl-lang/src/language/validation/other/declarations/typeParameters.ts deleted file mode 100644 index 66829f22..00000000 --- a/packages/ttsl-lang/src/language/validation/other/declarations/typeParameters.ts +++ /dev/null @@ -1,233 +0,0 @@ -import { AstNode, AstUtils, ValidationAcceptor } from 'langium'; -import { - isTslCallable, - isTslClass, - isTslClassMember, - isTslDeclaration, - isTslNamedTypeDeclaration, - isTslParameter, - isTslParameterList, - isTslTypeArgument, - isTslUnionType, - TslClass, - TslDeclaration, - TslTypeParameter, -} from '../../../generated/ast.js'; -import { isStatic, TypeParameter } from '../../../helpers/nodeProperties.js'; -import { SafeDsServices } from '../../../safe-ds-module.js'; -import { SafeDsNodeMapper } from '../../../helpers/safe-ds-node-mapper.js'; -import { NamedType, UnknownType } from '../../../typing/model.js'; - -export const CODE_TYPE_PARAMETER_INSUFFICIENT_CONTEXT = 'type-parameter/insufficient-context'; -export const CODE_TYPE_PARAMETER_UPPER_BOUND = 'type-parameter/upper-bound'; -export const CODE_TYPE_PARAMETER_USAGE = 'type-parameter/usage'; -export const CODE_TYPE_PARAMETER_VARIANCE = 'type-parameter/variance'; - -export const typeParameterMustHaveSufficientContext = (node: TslTypeParameter, accept: ValidationAcceptor) => { - const containingCallable = AstUtils.getContainerOfType(node, isTslCallable); - /* c8 ignore start */ - if (!containingCallable) { - return; - } - /* c8 ignore stop */ - - // Classes without constructor can only be used as named types, where type arguments are manifest - if (isTslClass(containingCallable) && !containingCallable.parameterList) { - return; - } - - // A type parameter must be referenced in the parameter list of the containing callable... - let typeParameterHasInsufficientContext = - !containingCallable.parameterList || - AstUtils.findLocalReferences(node, containingCallable.parameterList) - // ...but references in a union type or in the parameter list of a callable type don't count - .filter((reference) => { - const referenceNode = reference.$refNode?.astNode; - const containingParameterList = AstUtils.getContainerOfType(referenceNode, isTslParameterList); - - return ( - !AstUtils.hasContainerOfType(referenceNode, isTslUnionType) && - containingParameterList === containingCallable.parameterList - ); - }) - .isEmpty(); - - if (typeParameterHasInsufficientContext) { - accept('error', 'Insufficient context to infer this type parameter.', { - node, - property: 'name', - code: CODE_TYPE_PARAMETER_INSUFFICIENT_CONTEXT, - }); - } -}; - -export const typeParameterUpperBoundMustBeNamedType = (services: SafeDsServices) => { - const typeComputer = services.types.TypeComputer; - - return (node: TslTypeParameter, accept: ValidationAcceptor) => { - const boundType = typeComputer.computeType(node.upperBound); - - if (boundType !== UnknownType && !(boundType instanceof NamedType)) { - accept('error', 'The upper bound of a type parameter must be a named type.', { - node, - property: 'upperBound', - code: CODE_TYPE_PARAMETER_UPPER_BOUND, - }); - } - }; -}; - -export const typeParameterMustBeUsedInCorrectPosition = (services: SafeDsServices) => { - const nodeMapper = services.helpers.NodeMapper; - - return (node: TslTypeParameter, accept: ValidationAcceptor) => { - const declarationWithTypeParameter = AstUtils.getContainerOfType(node.$container, isTslDeclaration); - - // Early exit - if ( - !declarationWithTypeParameter || - (!isTslClass(declarationWithTypeParameter) && TypeParameter.isInvariant(node)) - ) { - return; - } - - AstUtils.findLocalReferences(node).forEach((it) => { - const reference = it.$refNode?.astNode; - if (!reference) { - /* c8 ignore next 2 */ - return; - } - - // Check usage of class type parameters - if ( - isTslClass(declarationWithTypeParameter) && - !classTypeParameterIsUsedInCorrectPosition(declarationWithTypeParameter, reference) - ) { - accept('error', 'This type parameter of a containing class cannot be used here.', { - node: reference, - code: CODE_TYPE_PARAMETER_USAGE, - }); - return; // Don't show other errors for this reference - } - - // Usages in the **own constructor** are always correct. This check must come after the previous one, since - // that one filters out usages in **constructors of nested classes**. - if (isInConstructor(reference)) { - return; - } - - // Check usage of variant type parameters - if (TypeParameter.isContravariant(node)) { - const position = getTypePosition(nodeMapper, declarationWithTypeParameter, reference); - - if (position !== 'contravariant') { - accept('error', `A contravariant type parameter cannot be used in ${position} position.`, { - node: reference, - code: CODE_TYPE_PARAMETER_USAGE, - }); - } - } else if (TypeParameter.isCovariant(node)) { - const position = getTypePosition(nodeMapper, declarationWithTypeParameter, reference); - - if (position !== 'covariant') { - accept('error', `A covariant type parameter cannot be used in ${position} position.`, { - node: reference, - code: CODE_TYPE_PARAMETER_USAGE, - }); - } - } - }); - }; -}; - -const isInConstructor = (node: AstNode) => { - const parameterList = AstUtils.getContainerOfType(node, isTslParameterList); - return isTslClass(parameterList?.$container); -}; - -const classTypeParameterIsUsedInCorrectPosition = (classWithTypeParameter: TslClass, reference: AstNode) => { - const containingClassMember = AstUtils.getContainerOfType(reference, isTslClassMember); - - // Handle usage in constructor - if (!containingClassMember || containingClassMember === classWithTypeParameter) { - return true; - } - - // Handle usage in static member - if (isStatic(containingClassMember)) { - return false; - } - - // Handle usage inside nested enums and classes (could be an instance attribute/function) - const containingNamedTypeDeclaration = AstUtils.getContainerOfType(reference, isTslNamedTypeDeclaration); - return !containingNamedTypeDeclaration || containingNamedTypeDeclaration === classWithTypeParameter; -}; - -type TypePosition = 'contravariant' | 'covariant' | 'invariant'; - -const getTypePosition = ( - nodeMapper: SafeDsNodeMapper, - declarationWithTypeParameter: TslDeclaration, - reference: AstNode, -): TypePosition => { - let current: AstNode | undefined = reference; - let result: TypePosition = 'covariant'; - - while (current && current !== declarationWithTypeParameter && result !== 'invariant') { - let step: TypePosition; - - if (isTslParameter(current)) { - step = 'contravariant'; - } else if (isTslTypeArgument(current)) { - const typeParameter = nodeMapper.typeArgumentToTypeParameter(current); - - if (TypeParameter.isContravariant(typeParameter)) { - step = 'contravariant'; - } else if (TypeParameter.isCovariant(typeParameter)) { - step = 'covariant'; - } else { - step = 'invariant'; - } - } else { - step = 'covariant'; - } - - result = nextTypePosition(result, step); - current = current.$container; - } - - return result; -}; - -const nextTypePosition = (aggregator: TypePosition, step: TypePosition): TypePosition => { - // We could also get the result by mapping the following numbers to the positions and multiplying them: - // -1 = contravariant - // 0 = invariant - // 1 = covariant - - if (aggregator === 'invariant' || step === 'invariant') { - return 'invariant'; - } else if (aggregator === 'covariant') { - return step; - } else if (step === 'covariant') { - return aggregator; - } else { - // Both are contravariant - return 'covariant'; - } -}; - -export const typeParameterMustOnlyBeVariantOnClass = (node: TslTypeParameter, accept: ValidationAcceptor) => { - if (TypeParameter.isInvariant(node)) { - return; - } - - const declarationWithTypeParameter = AstUtils.getContainerOfType(node.$container, isTslDeclaration); - if (declarationWithTypeParameter && !isTslClass(declarationWithTypeParameter)) { - accept('error', 'Only type parameters of classes can be variant.', { - node, - property: 'variance', - code: CODE_TYPE_PARAMETER_VARIANCE, - }); - } -}; diff --git a/packages/ttsl-lang/src/language/validation/other/expressions/lambdas.ts b/packages/ttsl-lang/src/language/validation/other/expressions/lambdas.ts deleted file mode 100644 index 49c51f1b..00000000 --- a/packages/ttsl-lang/src/language/validation/other/expressions/lambdas.ts +++ /dev/null @@ -1,46 +0,0 @@ -import { isTslArgument, isTslParameter, isTslParenthesizedExpression, TslLambda } from '../../../generated/ast.js'; -import { ValidationAcceptor } from 'langium'; -import { getParameters } from '../../../helpers/nodeProperties.js'; -import { SafeDsServices } from '../../../safe-ds-module.js'; - -export const CODE_LAMBDA_CONTEXT = 'lambda/context'; -export const CODE_LAMBDA_CONST_MODIFIER = 'lambda/const-modifier'; - -export const lambdaMustBeAssignedToTypedParameter = (services: SafeDsServices) => { - const nodeMapper = services.helpers.NodeMapper; - - return (node: TslLambda, accept: ValidationAcceptor): void => { - let context = node.$container; - while (isTslParenthesizedExpression(context)) { - context = context.$container; - } - - let contextIsValid = false; - if (isTslParameter(context)) { - contextIsValid = context.type !== undefined; - } else if (isTslArgument(context)) { - const parameter = nodeMapper.argumentToParameter(context); - // If the resolution of the parameter failed, we already show another error nearby - contextIsValid = parameter === undefined || parameter.type !== undefined; - } - - if (!contextIsValid) { - accept('error', 'A lambda must be assigned to a typed parameter.', { - node, - code: CODE_LAMBDA_CONTEXT, - }); - } - }; -}; - -export const lambdaParameterMustNotHaveConstModifier = (node: TslLambda, accept: ValidationAcceptor): void => { - for (const parameter of getParameters(node)) { - if (parameter.isConstant) { - accept('error', 'The const modifier is not applicable to parameters of lambdas.', { - node: parameter, - property: 'isConstant', - code: CODE_LAMBDA_CONST_MODIFIER, - }); - } - } -}; diff --git a/packages/ttsl-lang/src/language/validation/other/expressions/memberAccesses.ts b/packages/ttsl-lang/src/language/validation/other/expressions/memberAccesses.ts deleted file mode 100644 index c0ae32ad..00000000 --- a/packages/ttsl-lang/src/language/validation/other/expressions/memberAccesses.ts +++ /dev/null @@ -1,24 +0,0 @@ -import { isTslCall, isTslEnumVariant, TslMemberAccess } from '../../../generated/ast.js'; -import { ValidationAcceptor } from 'langium'; -import { getParameters } from '../../../helpers/nodeProperties.js'; -import { isEmpty } from '../../../../helpers/collections.js'; - -export const CODE_MEMBER_ACCESS_MISSING_ENUM_VARIANT_INSTANTIATION = 'member-access/missing-enum-variant-instantiation'; - -export const memberAccessOfEnumVariantMustNotLackInstantiation = ( - node: TslMemberAccess, - accept: ValidationAcceptor, -): void => { - const declaration = node.member?.target?.ref; - if (!isTslEnumVariant(declaration)) { - return; - } - - if (!isTslCall(node.$container) && !isEmpty(getParameters(declaration))) { - accept('error', `The enum variant '${declaration.name}' has parameters, so an argument list must be added.`, { - node, - property: 'member', - code: CODE_MEMBER_ACCESS_MISSING_ENUM_VARIANT_INSTANTIATION, - }); - } -}; diff --git a/packages/ttsl-lang/src/language/validation/other/expressions/references.ts b/packages/ttsl-lang/src/language/validation/other/expressions/references.ts index b11e1504..68b90b01 100644 --- a/packages/ttsl-lang/src/language/validation/other/expressions/references.ts +++ b/packages/ttsl-lang/src/language/validation/other/expressions/references.ts @@ -1,25 +1,16 @@ import { - isTslAnnotation, isTslCall, - isTslClass, - isTslEnum, isTslFunction, isTslMemberAccess, - isTslPipeline, - isTslSchema, - isTslSegment, TslReference, } from '../../../generated/ast.js'; import { AstNode, ValidationAcceptor } from 'langium'; export const CODE_REFERENCE_FUNCTION_POINTER = 'reference/function-pointer'; -export const CODE_REFERENCE_STATIC_CLASS_REFERENCE = 'reference/static-class-reference'; -export const CODE_REFERENCE_STATIC_ENUM_REFERENCE = 'reference/static-enum-reference'; -export const CODE_REFERENCE_TARGET = 'reference/target'; export const referenceMustNotBeFunctionPointer = (node: TslReference, accept: ValidationAcceptor): void => { const target = node.target.ref; - if (!isTslFunction(target) && !isTslSegment(target)) { + if (!isTslFunction(target)) { return; } @@ -32,7 +23,7 @@ export const referenceMustNotBeFunctionPointer = (node: TslReference, accept: Va if (!isTslCall(nodeOrContainer?.$container)) { accept( 'error', - 'Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead.', + 'Function pointers are not allowed to provide a cleaner graphical view.', { node, code: CODE_REFERENCE_FUNCTION_POINTER, @@ -41,62 +32,3 @@ export const referenceMustNotBeFunctionPointer = (node: TslReference, accept: Va } }; -export const referenceMustNotBeStaticClassOrEnumReference = (node: TslReference, accept: ValidationAcceptor) => { - const target = node.target.ref; - if (!isTslClass(target) && !isTslEnum(target)) { - return; - } - - // Get the containing member access if the node is on its right side - let nodeOrContainer: AstNode | undefined = node; - if (isTslMemberAccess(node.$container) && node.$containerProperty === 'member') { - nodeOrContainer = nodeOrContainer.$container; - } - - // Access to a member of the class or enum - if (isTslMemberAccess(nodeOrContainer?.$container) && nodeOrContainer?.$containerProperty === 'receiver') { - return; - } - - // Call of the class or enum - if (isTslCall(nodeOrContainer?.$container)) { - return; - } - - // Static reference to the class or enum - if (isTslClass(target)) { - accept('error', 'A class must not be statically referenced.', { - node, - code: CODE_REFERENCE_STATIC_CLASS_REFERENCE, - }); - } else if (isTslEnum(target)) { - accept('error', 'An enum must not be statically referenced.', { - node, - code: CODE_REFERENCE_STATIC_ENUM_REFERENCE, - }); - } -}; - -export const referenceTargetMustNotBeAnnotationPipelineOrSchema = ( - node: TslReference, - accept: ValidationAcceptor, -): void => { - const target = node.target.ref; - - if (isTslAnnotation(target)) { - accept('error', 'An annotation must not be the target of a reference.', { - node, - code: CODE_REFERENCE_TARGET, - }); - } else if (isTslPipeline(target)) { - accept('error', 'A pipeline must not be the target of a reference.', { - node, - code: CODE_REFERENCE_TARGET, - }); - } else if (isTslSchema(target)) { - accept('error', 'A schema must not be the target of a reference.', { - node, - code: CODE_REFERENCE_TARGET, - }); - } -}; diff --git a/packages/ttsl-lang/src/language/validation/other/modules.ts b/packages/ttsl-lang/src/language/validation/other/modules.ts index 21a62b46..b6490881 100644 --- a/packages/ttsl-lang/src/language/validation/other/modules.ts +++ b/packages/ttsl-lang/src/language/validation/other/modules.ts @@ -1,48 +1,12 @@ import { ValidationAcceptor } from 'langium'; -import { isTslDeclaration, isTslPipeline, isTslSegment, TslDeclaration, TslModule } from '../../generated/ast.js'; -import { isInPipelineFile, isInStubFile } from '../../helpers/fileExtensions.js'; +import { TslModule } from '../../generated/ast.js'; import { getModuleMembers } from '../../helpers/nodeProperties.js'; -import { BUILTINS_ROOT_PACKAGE } from '../../builtins/packageNames.js'; export const CODE_MODULE_FORBIDDEN_IN_PIPELINE_FILE = 'module/forbidden-in-pipeline-file'; export const CODE_MODULE_FORBIDDEN_IN_STUB_FILE = 'module/forbidden-in-stub-file'; export const CODE_MODULE_MISSING_PACKAGE = 'module/missing-package'; export const CODE_MODULE_PIPELINE_FILE_IN_BUILTIN_PACKAGE = 'module/pipeline-file-in-builtin-package'; -export const moduleDeclarationsMustMatchFileKind = (node: TslModule, accept: ValidationAcceptor): void => { - const declarations = node.members.filter(isTslDeclaration); - - if (isInPipelineFile(node)) { - for (const declaration of declarations) { - if (!declarationIsAllowedInPipelineFile(declaration)) { - accept('error', 'A pipeline file must only declare pipelines and segments.', { - node: declaration, - property: 'name', - code: CODE_MODULE_FORBIDDEN_IN_PIPELINE_FILE, - }); - } - } - } else if (isInStubFile(node)) { - for (const declaration of declarations) { - if (!declarationIsAllowedInStubFile(declaration)) { - accept('error', 'A stub file must not declare pipelines or segments.', { - node: declaration, - property: 'name', - code: CODE_MODULE_FORBIDDEN_IN_STUB_FILE, - }); - } - } - } -}; - -export const declarationIsAllowedInPipelineFile = (declaration: TslDeclaration): boolean => { - return isTslPipeline(declaration) || isTslSegment(declaration); -}; - -export const declarationIsAllowedInStubFile = (declaration: TslDeclaration): boolean => { - return !isTslPipeline(declaration) && !isTslSegment(declaration); -}; - export const moduleWithDeclarationsMustStatePackage = (node: TslModule, accept: ValidationAcceptor): void => { if (!node.name) { const members = getModuleMembers(node); @@ -56,12 +20,3 @@ export const moduleWithDeclarationsMustStatePackage = (node: TslModule, accept: } }; -export const pipelineFileMustNotBeInBuiltinPackage = (node: TslModule, accept: ValidationAcceptor): void => { - if (isInPipelineFile(node) && node.name?.startsWith(BUILTINS_ROOT_PACKAGE)) { - accept('error', `A pipeline file must not be in a '${BUILTINS_ROOT_PACKAGE}' package.`, { - node, - property: 'name', - code: CODE_MODULE_PIPELINE_FILE_IN_BUILTIN_PACKAGE, - }); - } -}; diff --git a/packages/ttsl-lang/src/language/validation/other/statements/assignments.ts b/packages/ttsl-lang/src/language/validation/other/statements/assignments.ts index 37603c2e..1c82406e 100644 --- a/packages/ttsl-lang/src/language/validation/other/statements/assignments.ts +++ b/packages/ttsl-lang/src/language/validation/other/statements/assignments.ts @@ -1,12 +1,11 @@ -import { isTslCall, isTslPipeline, TslAssignment, TslYield } from '../../../generated/ast.js'; -import { AstUtils, ValidationAcceptor } from 'langium'; +import { isTslCall, TslAssignment} from '../../../generated/ast.js'; +import { ValidationAcceptor } from 'langium'; import { SafeDsServices } from '../../../safe-ds-module.js'; import { getAbstractResults, getAssignees } from '../../../helpers/nodeProperties.js'; import { pluralize } from '../../../../helpers/strings.js'; export const CODE_ASSIGNMENT_IMPLICITLY_IGNORED_RESULT = 'assignment/implicitly-ignored-result'; export const CODE_ASSIGMENT_NOTHING_ASSIGNED = 'assignment/nothing-assigned'; -export const CODE_ASSIGMENT_YIELD_FORBIDDEN_IN_PIPELINE = 'assignment/yield-forbidden-in-pipeline'; export const assignmentAssigneeMustGetValue = (services: SafeDsServices) => @@ -48,14 +47,3 @@ export const assignmentShouldNotImplicitlyIgnoreResult = (services: SafeDsServic } }; }; - -export const yieldMustNotBeUsedInPipeline = (node: TslYield, accept: ValidationAcceptor): void => { - const containingPipeline = AstUtils.getContainerOfType(node, isTslPipeline); - - if (containingPipeline) { - accept('error', 'Yield must not be used in a pipeline.', { - node, - code: CODE_ASSIGMENT_YIELD_FORBIDDEN_IN_PIPELINE, - }); - } -}; diff --git a/packages/ttsl-lang/src/language/validation/other/types/literalTypes.ts b/packages/ttsl-lang/src/language/validation/other/types/literalTypes.ts deleted file mode 100644 index 28531e84..00000000 --- a/packages/ttsl-lang/src/language/validation/other/types/literalTypes.ts +++ /dev/null @@ -1,64 +0,0 @@ -import { isTslList, isTslDictionary, TslLiteralType } from '../../../generated/ast.js'; -import { ValidationAcceptor } from 'langium'; -import { getLiterals } from '../../../helpers/nodeProperties.js'; -import { SafeDsServices } from '../../../safe-ds-module.js'; -import { EvaluatedNode } from '../../../partialEvaluation/model.js'; -import { isEmpty } from '../../../../helpers/collections.js'; - -export const CODE_LITERAL_TYPE_DUPLICATE_LITERAL = 'literal-type/duplicate-literal'; -export const CODE_LITERAL_TYPE_LIST_LITERAL = 'literal-type/list-literal'; -export const CODE_LITERAL_TYPE_MAP_LITERAL = 'literal-type/map-literal'; -export const CODE_LITERAL_TYPE_MISSING_LITERALS = 'literal-type/missing-literals'; - -export const literalTypeMustHaveLiterals = (node: TslLiteralType, accept: ValidationAcceptor): void => { - if (isEmpty(getLiterals(node))) { - accept('error', 'A literal type must have at least one literal.', { - node, - property: 'literalList', - code: CODE_LITERAL_TYPE_MISSING_LITERALS, - }); - } -}; - -export const literalTypeMustNotContainListLiteral = (node: TslLiteralType, accept: ValidationAcceptor): void => { - for (const literal of getLiterals(node)) { - if (isTslList(literal)) { - accept('error', 'Literal types must not contain list literals.', { - node: literal, - code: CODE_LITERAL_TYPE_LIST_LITERAL, - }); - } - } -}; - -export const literalTypeMustNotContainMapLiteral = (node: TslLiteralType, accept: ValidationAcceptor): void => { - for (const literal of getLiterals(node)) { - if (isTslDictionary(literal)) { - accept('error', 'Literal types must not contain map literals.', { - node: literal, - code: CODE_LITERAL_TYPE_MAP_LITERAL, - }); - } - } -}; - -export const literalTypeShouldNotHaveDuplicateLiteral = (services: SafeDsServices) => { - const partialEvaluator = services.evaluation.PartialEvaluator; - - return (node: TslLiteralType, accept: ValidationAcceptor): void => { - const literals = getLiterals(node); - const constants: EvaluatedNode[] = []; - - for (const literal of literals) { - const constant = partialEvaluator.evaluate(literal); - if (constants.some((it) => it.equals(constant))) { - accept('warning', `The literal ${constant.toString()} was already listed.`, { - node: literal, - code: CODE_LITERAL_TYPE_DUPLICATE_LITERAL, - }); - } else { - constants.push(constant); - } - } - }; -}; diff --git a/packages/ttsl-lang/src/language/validation/other/types/namedTypes.ts b/packages/ttsl-lang/src/language/validation/other/types/namedTypes.ts deleted file mode 100644 index d4f323fc..00000000 --- a/packages/ttsl-lang/src/language/validation/other/types/namedTypes.ts +++ /dev/null @@ -1,93 +0,0 @@ -import { TslNamedType } from '../../../generated/ast.js'; -import { ValidationAcceptor } from 'langium'; -import { SafeDsServices } from '../../../safe-ds-module.js'; -import { getTypeArguments, getTypeParameters, TypeParameter } from '../../../helpers/nodeProperties.js'; -import { duplicatesBy } from '../../../../helpers/collections.js'; -import { pluralize } from '../../../../helpers/strings.js'; - -export const CODE_NAMED_TYPE_DUPLICATE_TYPE_PARAMETER = 'named-type/duplicate-type-parameter'; -export const CODE_NAMED_TYPE_POSITIONAL_AFTER_NAMED = 'named-type/positional-after-named'; -export const CODE_NAMED_TYPE_TOO_MANY_TYPE_ARGUMENTS = 'named-type/too-many-type-arguments'; - -export const namedTypeMustNotSetTypeParameterMultipleTimes = (services: SafeDsServices) => { - const nodeMapper = services.helpers.NodeMapper; - const typeArgumentToTypeParameter = nodeMapper.typeArgumentToTypeParameter.bind(nodeMapper); - - return (node: TslNamedType, accept: ValidationAcceptor): void => { - const typeArguments = getTypeArguments(node.typeArgumentList); - const duplicates = duplicatesBy(typeArguments, typeArgumentToTypeParameter); - - for (const duplicate of duplicates) { - const correspondingTypeParameter = typeArgumentToTypeParameter(duplicate)!; - accept('error', `The type parameter '${correspondingTypeParameter.name}' is already set.`, { - node: duplicate, - code: CODE_NAMED_TYPE_DUPLICATE_TYPE_PARAMETER, - }); - } - }; -}; - -export const namedTypeTypeArgumentListMustNotHavePositionalArgumentsAfterNamedArguments = ( - node: TslNamedType, - accept: ValidationAcceptor, -): void => { - const typeArgumentList = node.typeArgumentList; - if (!typeArgumentList) { - return; - } - - let foundNamed = false; - for (const typeArgument of typeArgumentList.typeArguments) { - if (typeArgument.typeParameter) { - foundNamed = true; - } else if (foundNamed) { - accept('error', 'After the first named type argument all type arguments must be named.', { - node: typeArgument, - code: CODE_NAMED_TYPE_POSITIONAL_AFTER_NAMED, - }); - } - } -}; - -export const namedTypeMustNotHaveTooManyTypeArguments = (node: TslNamedType, accept: ValidationAcceptor): void => { - const actualTypeArgumentCount = getTypeArguments(node).length; - - // We can never have too many arguments in this case - if (actualTypeArgumentCount === 0) { - return; - } - - // If the declaration is unresolved, we already show another error - const namedTypeDeclaration = node.declaration?.ref; - if (!namedTypeDeclaration) { - return; - } - - const typeParameters = getTypeParameters(namedTypeDeclaration); - const maxTypeArgumentCount = typeParameters.length; - - // All is good - if (actualTypeArgumentCount <= maxTypeArgumentCount) { - return; - } - - const minTypeArgumentCount = typeParameters.filter(TypeParameter.isRequired).length; - const kind = pluralize(Math.max(minTypeArgumentCount, maxTypeArgumentCount), 'type argument'); - if (minTypeArgumentCount === maxTypeArgumentCount) { - accept('error', `Expected exactly ${minTypeArgumentCount} ${kind} but got ${actualTypeArgumentCount}.`, { - node, - property: 'typeArgumentList', - code: CODE_NAMED_TYPE_TOO_MANY_TYPE_ARGUMENTS, - }); - } else { - accept( - 'error', - `Expected between ${minTypeArgumentCount} and ${maxTypeArgumentCount} ${kind} but got ${actualTypeArgumentCount}.`, - { - node, - property: 'typeArgumentList', - code: CODE_NAMED_TYPE_TOO_MANY_TYPE_ARGUMENTS, - }, - ); - } -}; diff --git a/packages/ttsl-lang/src/language/validation/other/types/unionTypes.ts b/packages/ttsl-lang/src/language/validation/other/types/unionTypes.ts deleted file mode 100644 index 0b81a506..00000000 --- a/packages/ttsl-lang/src/language/validation/other/types/unionTypes.ts +++ /dev/null @@ -1,77 +0,0 @@ -import { - isTslAnnotation, - isTslCallable, - isTslClass, - isTslFunction, - isTslParameter, - isTslUnionType, - TslUnionType, -} from '../../../generated/ast.js'; -import { AstUtils, ValidationAcceptor } from 'langium'; -import { getTypeArguments } from '../../../helpers/nodeProperties.js'; -import { SafeDsServices } from '../../../safe-ds-module.js'; -import { Type } from '../../../typing/model.js'; -import { isEmpty } from '../../../../helpers/collections.js'; - -export const CODE_UNION_TYPE_CONTEXT = 'union-type/context'; -export const CODE_UNION_TYPE_DUPLICATE_TYPE = 'union-type/duplicate-type'; -export const CODE_UNION_TYPE_MISSING_TYPES = 'union-type/missing-types'; - -export const unionTypeMustBeUsedInCorrectContext = (node: TslUnionType, accept: ValidationAcceptor): void => { - if (!contextIsCorrect(node)) { - accept('error', 'Union types must only be used for parameters of annotations, classes, and functions.', { - node, - code: CODE_UNION_TYPE_CONTEXT, - }); - } -}; - -const contextIsCorrect = (node: TslUnionType): boolean => { - if (AstUtils.hasContainerOfType(node.$container, isTslUnionType)) { - return true; - } - - const container = node.$container; - if (!isTslParameter(container)) { - return false; - } - - const containingCallable = AstUtils.getContainerOfType(container, isTslCallable); - return ( - !containingCallable || - isTslAnnotation(containingCallable) || - isTslClass(containingCallable) || - isTslFunction(containingCallable) - ); -}; - -export const unionTypeMustHaveTypes = (node: TslUnionType, accept: ValidationAcceptor): void => { - if (isEmpty(getTypeArguments(node.typeArgumentList))) { - accept('error', 'A union type must have at least one type.', { - node, - property: 'typeArgumentList', - code: CODE_UNION_TYPE_MISSING_TYPES, - }); - } -}; - -export const unionTypeShouldNotHaveDuplicateTypes = (services: SafeDsServices) => { - const typeComputer = services.types.TypeComputer; - - return (node: TslUnionType, accept: ValidationAcceptor): void => { - const typeArguments = getTypeArguments(node.typeArgumentList); - const knownTypes: Type[] = []; - - for (const typeArgument of typeArguments) { - const type = typeComputer.computeType(typeArgument); - if (knownTypes.some((it) => it.equals(type))) { - accept('warning', `The type '${type.toString()}' was already listed.`, { - node: typeArgument, - code: CODE_UNION_TYPE_DUPLICATE_TYPE, - }); - } else { - knownTypes.push(type); - } - } - }; -}; diff --git a/packages/ttsl-lang/src/language/validation/safe-ds-validator.ts b/packages/ttsl-lang/src/language/validation/safe-ds-validator.ts index 37fc8606..2e3896b3 100644 --- a/packages/ttsl-lang/src/language/validation/safe-ds-validator.ts +++ b/packages/ttsl-lang/src/language/validation/safe-ds-validator.ts @@ -49,18 +49,13 @@ import { import { placeholderShouldBeUsed, placeholdersMustNotBeAnAlias } from './other/declarations/placeholders.js'; import { callArgumentMustBeConstantIfParameterIsConstant, callMustNotBeRecursive } from './other/expressions/calls.js'; import { divisionDivisorMustNotBeZero } from './other/expressions/infixOperations.js'; -import { memberAccessOfEnumVariantMustNotLackInstantiation } from './other/expressions/memberAccesses.js'; import { referenceMustNotBeFunctionPointer, - referenceMustNotBeStaticClassOrEnumReference, - referenceTargetMustNotBeAnnotationPipelineOrSchema, } from './other/expressions/references.js'; import { templateStringMustHaveExpressionBetweenTwoStringParts } from './other/expressions/templateStrings.js'; import { importPackageMustExist, importPackageShouldNotBeEmpty } from './other/imports.js'; import { - moduleDeclarationsMustMatchFileKind, moduleWithDeclarationsMustStatePackage, - pipelineFileMustNotBeInBuiltinPackage, } from './other/modules.js'; import { assignmentAssigneeMustGetValue, @@ -79,7 +74,6 @@ import { pureParameterDefaultValueMustBePure, } from './purity.js'; import { - assignmentShouldHaveMoreThanWildcardsAsAssignees, callArgumentListShouldBeNeeded, chainedExpressionNullSafetyShouldBeNeeded, elvisOperatorShouldBeNeeded, @@ -107,7 +101,7 @@ import { callArgumentMustRespectParameterBounds, parameterDefaultValueMustRespectParameterBounds, } from './other/declarations/parameterBounds.js'; -import { groupedFunctionHasAggregation, groupedFunctionHasValidID } from './aggregation.js'; +import { groupByVariableMustBeAnID, groupedFunctionHasAggregation, groupedFunctionHasValidID } from './aggregation.js'; /** * Register custom validation checks. @@ -122,7 +116,6 @@ export const registerValidationChecks = function (services: SafeDsServices) { TslAssignment: [ assignmentAssigneeMustGetValue(services), assignmentShouldNotImplicitlyIgnoreResult(services), - assignmentShouldHaveMoreThanWildcardsAsAssignees(services), ], TslAbstractCall: [ argumentListMustNotHaveTooManyArguments(services), @@ -136,6 +129,9 @@ export const registerValidationChecks = function (services: SafeDsServices) { argumentListMustNotHavePositionalArgumentsAfterNamedArguments, argumentListMustNotSetParameterMultipleTimes(services), ], + TslAggregation: [ + groupByVariableMustBeAnID(), + ], TslCall: [ callArgumentListShouldBeNeeded(services), callArgumentAssignedToPureParameterMustBePure(services), @@ -188,13 +184,10 @@ export const registerValidationChecks = function (services: SafeDsServices) { ], TslList: [listMustNotContainNamedTuples(services)], TslDictionary: [mapMustNotContainNamedTuples(services), mapsShouldBeUsedWithCaution(services)], - TslMemberAccess: [memberAccessOfEnumVariantMustNotLackInstantiation], TslModule: [ - moduleDeclarationsMustMatchFileKind, moduleMemberMustHaveNameThatIsUniqueInPackage(services), moduleMustContainUniqueNames, moduleWithDeclarationsMustStatePackage, - pipelineFileMustNotBeInBuiltinPackage, pythonModuleShouldDifferFromSafeDsPackage(services), ], TslParameter: [ @@ -212,8 +205,6 @@ export const registerValidationChecks = function (services: SafeDsServices) { TslPrefixOperation: [prefixOperationOperandMustHaveCorrectType(services)], TslReference: [ referenceMustNotBeFunctionPointer, - referenceMustNotBeStaticClassOrEnumReference, - referenceTargetMustNotBeAnnotationPipelineOrSchema, referenceTargetShouldNotBeDeprecated(services), referenceTargetShouldNotExperimental(services), ], diff --git a/packages/ttsl-lang/src/language/validation/style.ts b/packages/ttsl-lang/src/language/validation/style.ts index 9407665b..305e8043 100644 --- a/packages/ttsl-lang/src/language/validation/style.ts +++ b/packages/ttsl-lang/src/language/validation/style.ts @@ -2,80 +2,29 @@ import { ValidationAcceptor } from 'langium'; import { isEmpty } from '../../helpers/collections.js'; import { isTslCall, - isTslEnumVariant, isTslIndexedAccess, isTslMemberAccess, - isTslWildcard, - TslAnnotation, - TslAnnotationCall, - TslAssignment, TslCall, TslChainedExpression, - TslClassBody, - TslConstraintList, - TslEnumBody, - TslEnumVariant, TslFunction, TslImportedDeclaration, TslInfixOperation, - TslNamedType, - TslSegment, - TslTypeParameterList, - TslUnionType, } from '../generated/ast.js'; -import { getParameters, getTypeParameters, Parameter } from '../helpers/nodeProperties.js'; +import { getParameters} from '../helpers/nodeProperties.js'; import { NullConstant } from '../partialEvaluation/model.js'; import { SafeDsServices } from '../safe-ds-module.js'; import { UnknownType } from '../typing/model.js'; -export const CODE_STYLE_UNNECESSARY_ASSIGNMENT = 'style/unnecessary-assignment'; export const CODE_STYLE_UNNECESSARY_ARGUMENT_LIST = 'style/unnecessary-argument-list'; -export const CODE_STYLE_UNNECESSARY_BODY = 'style/unnecessary-body'; -export const CODE_STYLE_UNNECESSARY_CONST_MODIFIER = 'style/unnecessary-const-modifier'; -export const CODE_STYLE_UNNECESSARY_CONSTRAINT_LIST = 'style/unnecessary-constraint-list'; export const CODE_STYLE_UNNECESSARY_ELVIS_OPERATOR = 'style/unnecessary-elvis-operator'; export const CODE_STYLE_UNNECESSARY_IMPORT_ALIAS = 'style/unnecessary-import-alias'; export const CODE_STYLE_UNNECESSARY_NULL_SAFETY = 'style/unnecessary-null-safety'; -export const CODE_STYLE_UNNECESSARY_PARAMETER_LIST = 'style/unnecessary-parameter-list'; export const CODE_STYLE_UNNECESSARY_RESULT_LIST = 'style/unnecessary-result-list'; -export const CODE_STYLE_UNNECESSARY_TYPE_ARGUMENT_LIST = 'style/unnecessary-type-argument-list'; -export const CODE_STYLE_UNNECESSARY_TYPE_PARAMETER_LIST = 'style/unnecessary-type-parameter-list'; -export const CODE_STYLE_UNNECESSARY_UNION_TYPE = 'style/unnecessary-union-type'; // ----------------------------------------------------------------------------- // Unnecessary argument lists // ----------------------------------------------------------------------------- -export const annotationCallArgumentListShouldBeNeeded = (services: SafeDsServices) => { - const settingsProvider = services.workspace.SettingsProvider; - - return async (node: TslAnnotationCall, accept: ValidationAcceptor) => { - if (!(await settingsProvider.shouldValidateCodeStyle())) { - /* c8 ignore next 2 */ - return; - } - - const argumentList = node.argumentList; - if (!argumentList || !isEmpty(argumentList.arguments)) { - // If there are arguments, they are either needed or erroneous (i.e. we already show an error) - return; - } - - const annotation = node.annotation?.ref; - if (!annotation) { - return; - } - - const hasRequiredParameters = getParameters(annotation).some(Parameter.isRequired); - if (!hasRequiredParameters) { - accept('info', 'This argument list can be removed.', { - node: argumentList, - code: CODE_STYLE_UNNECESSARY_ARGUMENT_LIST, - }); - } - }; -}; - export const callArgumentListShouldBeNeeded = (services: SafeDsServices) => { const settingsProvider = services.workspace.SettingsProvider; @@ -92,9 +41,6 @@ export const callArgumentListShouldBeNeeded = (services: SafeDsServices) => { } const callable = services.helpers.NodeMapper.callToCallable(node); - if (!isTslEnumVariant(callable)) { - return; - } if (isEmpty(getParameters(callable))) { accept('info', 'This argument list can be removed.', { @@ -105,116 +51,10 @@ export const callArgumentListShouldBeNeeded = (services: SafeDsServices) => { }; }; -// ----------------------------------------------------------------------------- -// Unnecessary assignments -// ----------------------------------------------------------------------------- - -export const assignmentShouldHaveMoreThanWildcardsAsAssignees = (services: SafeDsServices) => { - const settingsProvider = services.workspace.SettingsProvider; - - return async (node: TslAssignment, accept: ValidationAcceptor) => { - if (!(await settingsProvider.shouldValidateCodeStyle())) { - /* c8 ignore next 2 */ - return; - } - - const assignees = node.assigneeList?.assignees ?? []; - if (assignees.every(isTslWildcard)) { - accept('info', 'This assignment can be replaced by an expression statement.', { - node, - code: CODE_STYLE_UNNECESSARY_ASSIGNMENT, - }); - } - }; -}; - // ----------------------------------------------------------------------------- // Unnecessary bodies // ----------------------------------------------------------------------------- -export const classBodyShouldNotBeEmpty = (services: SafeDsServices) => { - const settingsProvider = services.workspace.SettingsProvider; - - return async (node: TslClassBody, accept: ValidationAcceptor) => { - if (!(await settingsProvider.shouldValidateCodeStyle())) { - /* c8 ignore next 2 */ - return; - } - - if (isEmpty(node.members)) { - accept('info', 'This body can be removed.', { - node, - code: CODE_STYLE_UNNECESSARY_BODY, - }); - } - }; -}; - -export const enumBodyShouldNotBeEmpty = (services: SafeDsServices) => { - const settingsProvider = services.workspace.SettingsProvider; - - return async (node: TslEnumBody, accept: ValidationAcceptor) => { - if (!(await settingsProvider.shouldValidateCodeStyle())) { - /* c8 ignore next 2 */ - return; - } - - if (isEmpty(node.variants)) { - accept('info', 'This body can be removed.', { - node, - code: CODE_STYLE_UNNECESSARY_BODY, - }); - } - }; -}; - -// ----------------------------------------------------------------------------- -// Unnecessary const modifier -// ----------------------------------------------------------------------------- - -export const annotationParameterShouldNotHaveConstModifier = (services: SafeDsServices) => { - const settingsProvider = services.workspace.SettingsProvider; - - return async (node: TslAnnotation, accept: ValidationAcceptor) => { - if (!(await settingsProvider.shouldValidateCodeStyle())) { - /* c8 ignore next 2 */ - return; - } - - for (const parameter of getParameters(node)) { - if (parameter.isConstant) { - accept('info', 'Annotation parameters are always const, so this modifier can be removed.', { - node: parameter, - property: 'isConstant', - code: CODE_STYLE_UNNECESSARY_CONST_MODIFIER, - }); - } - } - }; -}; - -// ----------------------------------------------------------------------------- -// Unnecessary constraint lists -// ----------------------------------------------------------------------------- - -export const constraintListShouldNotBeEmpty = (services: SafeDsServices) => { - const settingsProvider = services.workspace.SettingsProvider; - - return async (node: TslConstraintList, accept: ValidationAcceptor) => { - if (!(await settingsProvider.shouldValidateCodeStyle())) { - /* c8 ignore next 2 */ - return; - } - - if (isEmpty(node.constraints)) { - accept('info', 'This constraint list can be removed.', { - node, - code: CODE_STYLE_UNNECESSARY_CONSTRAINT_LIST, - }); - } - }; -}; - // ----------------------------------------------------------------------------- // Unnecessary elvis operator // ----------------------------------------------------------------------------- @@ -340,48 +180,6 @@ export const chainedExpressionNullSafetyShouldBeNeeded = (services: SafeDsServic }; }; -// ----------------------------------------------------------------------------- -// Unnecessary parameter lists -// ----------------------------------------------------------------------------- - -export const annotationParameterListShouldNotBeEmpty = (services: SafeDsServices) => { - const settingsProvider = services.workspace.SettingsProvider; - - return async (node: TslAnnotation, accept: ValidationAcceptor) => { - if (!(await settingsProvider.shouldValidateCodeStyle())) { - /* c8 ignore next 2 */ - return; - } - - if (node.parameterList && isEmpty(node.parameterList.parameters)) { - accept('info', 'This parameter list can be removed.', { - node, - property: 'parameterList', - code: CODE_STYLE_UNNECESSARY_PARAMETER_LIST, - }); - } - }; -}; - -export const enumVariantParameterListShouldNotBeEmpty = (services: SafeDsServices) => { - const settingsProvider = services.workspace.SettingsProvider; - - return async (node: TslEnumVariant, accept: ValidationAcceptor) => { - if (!(await settingsProvider.shouldValidateCodeStyle())) { - /* c8 ignore next 2 */ - return; - } - - if (node.parameterList && isEmpty(node.parameterList.parameters)) { - accept('info', 'This parameter list can be removed.', { - node, - property: 'parameterList', - code: CODE_STYLE_UNNECESSARY_PARAMETER_LIST, - }); - } - }; -}; - // ----------------------------------------------------------------------------- // Unnecessary result lists // ----------------------------------------------------------------------------- @@ -403,101 +201,4 @@ export const functionResultListShouldNotBeEmpty = (services: SafeDsServices) => }); } }; -}; - -export const segmentResultListShouldNotBeEmpty = (services: SafeDsServices) => { - const settingsProvider = services.workspace.SettingsProvider; - - return async (node: TslSegment, accept: ValidationAcceptor) => { - if (!(await settingsProvider.shouldValidateCodeStyle())) { - /* c8 ignore next 2 */ - return; - } - - if (node.resultList && isEmpty(node.resultList.results)) { - accept('info', 'This result list can be removed.', { - node, - property: 'resultList', - code: CODE_STYLE_UNNECESSARY_RESULT_LIST, - }); - } - }; -}; - -// ----------------------------------------------------------------------------- -// Unnecessary type argument lists -// ----------------------------------------------------------------------------- - -export const namedTypeTypeArgumentListShouldBeNeeded = (services: SafeDsServices) => { - const settingsProvider = services.workspace.SettingsProvider; - - return async (node: TslNamedType, accept: ValidationAcceptor) => { - if (!(await settingsProvider.shouldValidateCodeStyle())) { - /* c8 ignore next 2 */ - return; - } - - const typeArgumentList = node.typeArgumentList; - if (!typeArgumentList || !isEmpty(typeArgumentList.typeArguments)) { - // If there are type arguments, they are either needed or erroneous (i.e. we already show an error) - return; - } - - const namedTypeDeclaration = node.declaration?.ref; - if (!namedTypeDeclaration) { - return; - } - - if (isEmpty(getTypeParameters(namedTypeDeclaration))) { - accept('info', 'This type argument list can be removed.', { - node: typeArgumentList, - code: CODE_STYLE_UNNECESSARY_TYPE_ARGUMENT_LIST, - }); - } - }; -}; - -// ----------------------------------------------------------------------------- -// Unnecessary type parameter lists -// ----------------------------------------------------------------------------- - -export const typeParameterListShouldNotBeEmpty = (services: SafeDsServices) => { - const settingsProvider = services.workspace.SettingsProvider; - - return async (node: TslTypeParameterList, accept: ValidationAcceptor) => { - if (!(await settingsProvider.shouldValidateCodeStyle())) { - /* c8 ignore next 2 */ - return; - } - - if (isEmpty(node.typeParameters)) { - accept('info', 'This type parameter list can be removed.', { - node, - code: CODE_STYLE_UNNECESSARY_TYPE_PARAMETER_LIST, - }); - } - }; -}; - -// ----------------------------------------------------------------------------- -// Unnecessary type parameter lists -// ----------------------------------------------------------------------------- - -export const unionTypeShouldNotHaveASingularTypeArgument = (services: SafeDsServices) => { - const settingsProvider = services.workspace.SettingsProvider; - - return async (node: TslUnionType, accept: ValidationAcceptor) => { - if (!(await settingsProvider.shouldValidateCodeStyle())) { - /* c8 ignore next 2 */ - return; - } - - const typeArguments = node.typeArgumentList?.typeArguments ?? []; - if (typeArguments.length === 1) { - accept('info', 'This can be replaced by the singular type argument of the union type.', { - node, - code: CODE_STYLE_UNNECESSARY_UNION_TYPE, - }); - } - }; -}; +}; \ No newline at end of file diff --git a/packages/ttsl-lang/src/language/validation/types.ts b/packages/ttsl-lang/src/language/validation/types.ts index f81c46d0..3796e5d1 100644 --- a/packages/ttsl-lang/src/language/validation/types.ts +++ b/packages/ttsl-lang/src/language/validation/types.ts @@ -1,36 +1,24 @@ -import { AstNode, AstUtils, ValidationAcceptor } from 'langium'; -import { isEmpty } from '../../helpers/collections.js'; -import { pluralize } from '../../helpers/strings.js'; +import { AstNode, ValidationAcceptor } from 'langium'; import { - isTslAnnotation, - isTslCallable, - isTslClass, - isTslLambda, isTslMemberAccess, - isTslPipeline, isTslReference, - isTslSchema, - TslAttribute, TslCall, TslIndexedAccess, TslInfixOperation, TslList, TslDictionary, - TslNamedType, TslParameter, TslPrefixOperation, TslResult, TslTypeCast, - TslTypeParameter, - TslYield, + isTslFunction, } from '../generated/ast.js'; -import { getArguments, getTypeArguments, getTypeParameters, TypeParameter } from '../helpers/nodeProperties.js'; +import { getArguments } from '../helpers/nodeProperties.js'; import { SafeDsServices } from '../safe-ds-module.js'; import { ClassType, NamedTupleType, TypeParameterType, UnknownType } from '../typing/model.js'; export const CODE_TYPE_CALLABLE_RECEIVER = 'type/callable-receiver'; export const CODE_TYPE_MISMATCH = 'type/mismatch'; -export const CODE_TYPE_MISSING_TYPE_ARGUMENTS = 'type/missing-type-arguments'; export const CODE_TYPE_MISSING_TYPE_HINT = 'type/missing-type-hint'; // ----------------------------------------------------------------------------- @@ -78,22 +66,17 @@ export const callReceiverMustBeCallable = (services: SafeDsServices) => { const target = receiver.target.ref; // We already report other errors at this position in those cases - if (!target || isTslAnnotation(target) || isTslPipeline(target) || isTslSchema(target)) { + if (!target || isTslFunction(target)) { return; } } const callable = nodeMapper.callToCallable(node); - if (node.receiver && (!callable || isTslAnnotation(callable))) { + if (node.receiver && !callable) { accept('error', 'This expression is not callable.', { node: node.receiver, code: CODE_TYPE_CALLABLE_RECEIVER, }); - } else if (node.receiver && isTslClass(callable) && !callable.parameterList) { - accept('error', 'Cannot instantiate a class that has no constructor.', { - node: node.receiver, - code: CODE_TYPE_CALLABLE_RECEIVER, - }); } }; }; @@ -255,44 +238,6 @@ export const mapMustNotContainNamedTuples = (services: SafeDsServices) => { }; }; -export const namedTypeTypeArgumentsMustMatchBounds = (services: SafeDsServices) => { - const nodeMapper = services.helpers.NodeMapper; - const typeChecker = services.types.TypeChecker; - const typeComputer = services.types.TypeComputer; - - return (node: TslNamedType, accept: ValidationAcceptor): void => { - const type = typeComputer.computeType(node); - if (!(type instanceof ClassType) || isEmpty(type.substitutions)) { - return; - } - - for (const typeArgument of getTypeArguments(node)) { - const typeParameter = nodeMapper.typeArgumentToTypeParameter(typeArgument); - if (!typeParameter) { - continue; - } - - const typeArgumentType = type.substitutions.get(typeParameter); - if (!typeArgumentType) { - /* c8 ignore next 2 */ - continue; - } - - const upperBound = typeComputer - .computeUpperBound(typeParameter, { stopAtTypeParameterType: true }) - .substituteTypeParameters(type.substitutions); - - if (!typeChecker.isSubtypeOf(typeArgumentType, upperBound)) { - accept('error', `Expected type '${upperBound}' but got '${typeArgumentType}'.`, { - node: typeArgument, - property: 'value', - code: CODE_TYPE_MISMATCH, - }); - } - } - }; -}; - export const parameterDefaultValueTypeMustMatchParameterType = (services: SafeDsServices) => { const typeChecker = services.types.TypeChecker; const typeComputer = services.types.TypeComputer; @@ -368,116 +313,18 @@ export const typeCastExpressionMustHaveUnknownType = (services: SafeDsServices) }; }; -export const typeParameterDefaultValueMustMatchUpperBound = (services: SafeDsServices) => { - const typeChecker = services.types.TypeChecker; - const typeComputer = services.types.TypeComputer; - - return (node: TslTypeParameter, accept: ValidationAcceptor): void => { - if (!node.defaultValue || !node.upperBound) { - return; - } - - const defaultValueType = typeComputer.computeType(node.defaultValue); - const upperBoundType = typeComputer.computeUpperBound(node, { stopAtTypeParameterType: true }); - - if (!typeChecker.isSubtypeOf(defaultValueType, upperBoundType)) { - accept('error', `Expected type '${upperBoundType}' but got '${defaultValueType}'.`, { - node, - property: 'defaultValue', - code: CODE_TYPE_MISMATCH, - }); - } - }; -}; - -export const yieldTypeMustMatchResultType = (services: SafeDsServices) => { - const typeChecker = services.types.TypeChecker; - const typeComputer = services.types.TypeComputer; - - return (node: TslYield, accept: ValidationAcceptor) => { - const result = node.result?.ref; - if (!result) { - return; - } - - const yieldType = typeComputer.computeType(node); - const resultType = typeComputer.computeType(result); - - if (!typeChecker.isSubtypeOf(yieldType, resultType)) { - accept('error', `Expected type '${resultType}' but got '${yieldType}'.`, { - node, - property: 'result', - code: CODE_TYPE_MISMATCH, - }); - } - }; -}; - -// ----------------------------------------------------------------------------- -// Missing type arguments -// ----------------------------------------------------------------------------- - -export const namedTypeMustSetAllTypeParameters = - (services: SafeDsServices) => - (node: TslNamedType, accept: ValidationAcceptor): void => { - const expectedTypeParameters = getTypeParameters(node.declaration?.ref).filter(TypeParameter.isRequired); - if (isEmpty(expectedTypeParameters)) { - return; - } - - if (node.typeArgumentList) { - const actualTypeParameters = getTypeArguments(node.typeArgumentList).map((it) => - services.helpers.NodeMapper.typeArgumentToTypeParameter(it), - ); - - const missingTypeParameters = expectedTypeParameters.filter((it) => !actualTypeParameters.includes(it)); - if (!isEmpty(missingTypeParameters)) { - const kind = pluralize(missingTypeParameters.length, 'type parameter'); - const missingTypeParametersString = missingTypeParameters.map((it) => `'${it.name}'`).join(', '); - - accept('error', `The ${kind} ${missingTypeParametersString} must be set here.`, { - node, - property: 'typeArgumentList', - code: CODE_TYPE_MISSING_TYPE_ARGUMENTS, - }); - } - } else { - accept( - 'error', - `The type '${node.declaration?.$refText}' has required type parameters, so a type argument list must be added.`, - { - node, - code: CODE_TYPE_MISSING_TYPE_ARGUMENTS, - }, - ); - } - }; - // ----------------------------------------------------------------------------- // Missing type hints // ----------------------------------------------------------------------------- -export const attributeMustHaveTypeHint = (node: TslAttribute, accept: ValidationAcceptor): void => { +export const parameterMustHaveTypeHint = (node: TslParameter, accept: ValidationAcceptor): void => { if (!node.type) { - accept('error', 'An attribute must have a type hint.', { + accept('error', 'A parameter must have a type hint.', { node, property: 'name', code: CODE_TYPE_MISSING_TYPE_HINT, }); - } -}; - -export const parameterMustHaveTypeHint = (node: TslParameter, accept: ValidationAcceptor): void => { - if (!node.type) { - const containingCallable = AstUtils.getContainerOfType(node, isTslCallable); - - if (!isTslLambda(containingCallable)) { - accept('error', 'A parameter must have a type hint.', { - node, - property: 'name', - code: CODE_TYPE_MISSING_TYPE_HINT, - }); - } + } }; From 23713696bdfa2ab68683bf3ae041734a19857687 Mon Sep 17 00:00:00 2001 From: methr0 Date: Tue, 25 Jun 2024 00:36:38 +0200 Subject: [PATCH 074/183] remove unnecessary validation tests --- .../ttsl-lang/src/language/validation/builtins/pythonCall.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/ttsl-lang/src/language/validation/builtins/pythonCall.ts b/packages/ttsl-lang/src/language/validation/builtins/pythonCall.ts index 551655a8..d23a4bbc 100644 --- a/packages/ttsl-lang/src/language/validation/builtins/pythonCall.ts +++ b/packages/ttsl-lang/src/language/validation/builtins/pythonCall.ts @@ -1,5 +1,5 @@ import { AstUtils, ValidationAcceptor } from 'langium'; -import { isTslClass, TslFunction } from '../../generated/ast.js'; +import { TslFunction } from '../../generated/ast.js'; import { SafeDsServices } from '../../safe-ds-module.js'; import { findFirstAnnotationCallOf, getParameters } from '../../helpers/nodeProperties.js'; import { pluralize } from '../../../helpers/strings.js'; From dcd6d72175bbb82cc3344fd9213f13c6aca58054 Mon Sep 17 00:00:00 2001 From: methr0 Date: Tue, 25 Jun 2024 00:47:24 +0200 Subject: [PATCH 075/183] remove unnecessary scoping functions --- .../scoping/safe-ds-scope-computation.ts | 129 +--------------- .../scoping/safe-ds-scope-provider.ts | 146 +----------------- .../validation/builtins/pythonCall.ts | 3 - 3 files changed, 4 insertions(+), 274 deletions(-) diff --git a/packages/ttsl-lang/src/language/scoping/safe-ds-scope-computation.ts b/packages/ttsl-lang/src/language/scoping/safe-ds-scope-computation.ts index 4ffe1e72..5bbaa22e 100644 --- a/packages/ttsl-lang/src/language/scoping/safe-ds-scope-computation.ts +++ b/packages/ttsl-lang/src/language/scoping/safe-ds-scope-computation.ts @@ -7,31 +7,19 @@ import { PrecomputedScopes, } from 'langium'; import { - isTslAnnotation, - isTslClass, isTslDeclaration, - isTslEnum, - isTslEnumVariant, isTslFunction, isTslModule, isTslParameter, isTslParameterList, - isTslPipeline, - isTslSegment, - isTslTypeParameter, - isTslTypeParameterList, - TslClass, - TslEnum, - TslEnumVariant, TslFunction, TslParameter, - TslTypeParameter, } from '../generated/ast.js'; export class SafeDsScopeComputation extends DefaultScopeComputation { protected override exportNode(node: AstNode, exports: AstNodeDescription[], document: LangiumDocument): void { // Modules, pipelines, and private segments cannot be referenced from other documents - if (isTslModule(node) || isTslPipeline(node) || (isTslSegment(node) && (node.visibility?.isPrivate ?? false))) { + if (isTslModule(node)) { return; } @@ -45,42 +33,13 @@ export class SafeDsScopeComputation extends DefaultScopeComputation { } protected override processNode(node: AstNode, document: LangiumDocument, scopes: PrecomputedScopes): void { - if (isTslClass(node)) { - this.processTslClass(node, document, scopes); - } else if (isTslFunction(node)) { + if (isTslFunction(node)) { this.processTslFunction(node, document, scopes); - } else if (isTslEnum(node)) { - this.processTslEnum(node, document, scopes); - } else if (isTslEnumVariant(node)) { - this.processTslEnumVariant(node, document, scopes); - } else if (isTslParameter(node)) { - this.processTslParameter(node, document, scopes); - } else if (isTslTypeParameter(node)) { - this.processTslTypeParameter(node, document, scopes); } else { super.processNode(node, document, scopes); } } - private processTslClass(node: TslClass, document: LangiumDocument, scopes: PrecomputedScopes): void { - const name = this.nameProvider.getName(node); - if (!name) { - return; - } - - const description = this.descriptions.createDescription(node, name, document); - - this.addToScopesIfKeyIsDefined(scopes, node.parameterList, description); - this.addToScopesIfKeyIsDefined(scopes, node.parentTypeList, description); - this.addToScopesIfKeyIsDefined(scopes, node.constraintList, description); - this.addToScopesIfKeyIsDefined(scopes, node.body, description); - - const containingDeclaration = AstUtils.getContainerOfType(node.$container, isTslDeclaration); - if (isTslModule(containingDeclaration)) { - this.addToScopesIfKeyIsDefined(scopes, containingDeclaration, description); - } - } - private processTslFunction(node: TslFunction, document: LangiumDocument, scopes: PrecomputedScopes): void { const name = this.nameProvider.getName(node); if (!name) { @@ -90,23 +49,6 @@ export class SafeDsScopeComputation extends DefaultScopeComputation { const description = this.descriptions.createDescription(node, name, document); this.addToScopesIfKeyIsDefined(scopes, node.parameterList, description); - this.addToScopesIfKeyIsDefined(scopes, node.constraintList, description); - this.addToScopesIfKeyIsDefined(scopes, node.body, description); - - const containingDeclaration = AstUtils.getContainerOfType(node.$container, isTslDeclaration); - if (isTslModule(containingDeclaration)) { - this.addToScopesIfKeyIsDefined(scopes, containingDeclaration, description); - } - } - - private processTslEnum(node: TslEnum, document: LangiumDocument, scopes: PrecomputedScopes): void { - const name = this.nameProvider.getName(node); - if (!name) { - return; - } - - const description = this.descriptions.createDescription(node, name, document); - this.addToScopesIfKeyIsDefined(scopes, node.body, description); const containingDeclaration = AstUtils.getContainerOfType(node.$container, isTslDeclaration); @@ -115,73 +57,6 @@ export class SafeDsScopeComputation extends DefaultScopeComputation { } } - private processTslEnumVariant(node: TslEnumVariant, document: LangiumDocument, scopes: PrecomputedScopes): void { - const name = this.nameProvider.getName(node); - if (!name) { - /* c8 ignore next 2 */ - return; - } - - const description = this.descriptions.createDescription(node, name, document); - - this.addToScopesIfKeyIsDefined(scopes, node.parameterList, description); - this.addToScopesIfKeyIsDefined(scopes, node.constraintList, description); - } - - private processTslParameter(node: TslParameter, document: LangiumDocument, scopes: PrecomputedScopes): void { - const containingCallable = AstUtils.getContainerOfType(node, isTslParameterList)?.$container; - if (!containingCallable) { - /* c8 ignore next 2 */ - return; - } - - const name = this.nameProvider.getName(node); - if (!name) { - /* c8 ignore next 2 */ - return; - } - - const description = this.descriptions.createDescription(node, name, document); - - if (isTslAnnotation(containingCallable)) { - this.addToScopesIfKeyIsDefined(scopes, containingCallable.constraintList, description); - } else if (isTslClass(containingCallable)) { - this.addToScopesIfKeyIsDefined(scopes, containingCallable.constraintList, description); - } else if (isTslEnumVariant(containingCallable)) { - this.addToScopesIfKeyIsDefined(scopes, containingCallable.constraintList, description); - } else if (isTslFunction(containingCallable)) { - this.addToScopesIfKeyIsDefined(scopes, containingCallable.constraintList, description); - } else if (isTslSegment(containingCallable)) { - this.addToScopesIfKeyIsDefined(scopes, containingCallable.constraintList, description); - } - } - - private processTslTypeParameter( - node: TslTypeParameter, - document: LangiumDocument, - scopes: PrecomputedScopes, - ): void { - const containingDeclaration = AstUtils.getContainerOfType(node, isTslTypeParameterList)?.$container; - if (!containingDeclaration) { - /* c8 ignore next 2 */ - return; - } - - const name = this.nameProvider.getName(node); - if (!name) { - /* c8 ignore next 2 */ - return; - } - - const description = this.descriptions.createDescription(node, name, document); - - if (isTslClass(containingDeclaration)) { - this.addToScopesIfKeyIsDefined(scopes, containingDeclaration.parameterList, description); - this.addToScopesIfKeyIsDefined(scopes, containingDeclaration.parentTypeList, description); - this.addToScopesIfKeyIsDefined(scopes, containingDeclaration.body, description); - } - } - /** * Adds the key/value pair to the scopes if the key is defined. * diff --git a/packages/ttsl-lang/src/language/scoping/safe-ds-scope-provider.ts b/packages/ttsl-lang/src/language/scoping/safe-ds-scope-provider.ts index ff1cffe9..a9975bda 100644 --- a/packages/ttsl-lang/src/language/scoping/safe-ds-scope-provider.ts +++ b/packages/ttsl-lang/src/language/scoping/safe-ds-scope-provider.ts @@ -11,32 +11,22 @@ import { } from 'langium'; import { isTslAbstractCall, - isTslAnnotationCall, isTslArgument, isTslAssignment, isTslBlock, isTslCall, isTslCallable, - isTslClass, - isTslEnum, isTslImportedDeclaration, - isTslLambda, isTslMemberAccess, isTslMemberType, isTslModule, - isTslNamedType, isTslNamedTypeDeclaration, isTslParameter, isTslPlaceholder, isTslQualifiedImport, isTslReference, - isTslSegment, isTslStatement, - isTslTypeArgument, - isTslTypeParameter, isTslWildcardImport, - isTslYield, - TslAnnotation, TslArgument, type TslCallable, TslDeclaration, @@ -44,15 +34,12 @@ import { TslImportedDeclaration, TslMemberAccess, TslMemberType, - TslNamedType, TslNamedTypeDeclaration, type TslParameter, TslPlaceholder, TslReference, TslStatement, TslType, - TslTypeArgument, - TslYield, } from '../generated/ast.js'; import { isContainedInOrEqual } from '../helpers/astUtils.js'; import { @@ -101,37 +88,21 @@ export class SafeDsScopeProvider extends DefaultScopeProvider { override getScope(context: ReferenceInfo): Scope { const node = context.container; - if (isTslAnnotationCall(node) && context.property === 'annotation') { - return this.getScopeForAnnotationCallAnnotation(context); - } else if (isTslArgument(node) && context.property === 'parameter') { + if (isTslArgument(node) && context.property === 'parameter') { return this.getScopeForArgumentParameter(node); } else if (isTslImportedDeclaration(node) && context.property === 'declaration') { return this.getScopeForImportedDeclarationDeclaration(node); - } else if (isTslNamedType(node) && context.property === 'declaration') { - if (isTslMemberType(node.$container) && node.$containerProperty === 'member') { - return this.getScopeForMemberTypeMember(node.$container); - } else { - return this.getScopeForNamedTypeDeclaration(node, context); - } } else if (isTslReference(node) && context.property === 'target') { if (isTslMemberAccess(node.$container) && node.$containerProperty === 'member') { return this.getScopeForMemberAccessMember(node.$container); } else { return this.getScopeForReferenceTarget(node, context); } - } else if (isTslTypeArgument(node) && context.property === 'typeParameter') { - return this.getScopeForTypeArgumentTypeParameter(node); - } else if (isTslYield(node) && context.property === 'result') { - return this.getScopeForYieldResult(node); } else { return super.getScope(context); } } - private getScopeForAnnotationCallAnnotation(context: ReferenceInfo) { - return this.coreDeclarations(TslAnnotation, super.getScope(context)); - } - private getScopeForArgumentParameter(node: TslArgument): Scope { const containingAbstractCall = AstUtils.getContainerOfType(node, isTslAbstractCall); const callable = this.nodeMapper.callToCallable(containingAbstractCall); @@ -159,67 +130,7 @@ export class SafeDsScopeProvider extends DefaultScopeProvider { return this.createScope(declarationsInPackage); } - private getScopeForMemberTypeMember(node: TslMemberType): Scope { - const declaration = this.getUniqueReferencedDeclarationForType(node.receiver); - if (!declaration) { - return EMPTY_SCOPE; - } - - if (isTslClass(declaration)) { - const members = declaration.body?.members ?? []; - return this.createScopeForNodes(members.filter(isTslNamedTypeDeclaration)); - } else if (isTslEnum(declaration)) { - const variants = declaration.body?.variants ?? []; - return this.createScopeForNodes(variants); - } else { - return EMPTY_SCOPE; - } - } - - /** - * Returns the unique declaration that is referenced by this type. If the type references none or multiple - * declarations, undefined is returned. - * - * @param node The type to get the referenced declaration for. - * @returns The referenced declaration or undefined. - */ - private getUniqueReferencedDeclarationForType(node: TslType): TslNamedTypeDeclaration | undefined { - if (isTslNamedType(node)) { - return node.declaration?.ref; - } else if (isTslMemberType(node)) { - return node.member?.declaration?.ref; - } else { - return undefined; - } - } - - private getScopeForNamedTypeDeclaration(node: TslNamedType, context: ReferenceInfo): Scope { - // Default scope - let currentScope = this.coreDeclarations(TslNamedTypeDeclaration, super.getScope(context)); - - // Type parameters (up to the containing type parameter) - const containingTypeParameter = AstUtils.getContainerOfType(node, isTslTypeParameter); - if (containingTypeParameter) { - const allTypeParameters = getTypeParameters(containingTypeParameter?.$container); - const priorTypeParameters = allTypeParameters.slice(0, containingTypeParameter.$containerIndex); - currentScope = this.createScopeForNodes(priorTypeParameters, currentScope); - } - - return currentScope; - } - private getScopeForMemberAccessMember(node: TslMemberAccess): Scope { - // Static access - const declaration = this.getUniqueReferencedDeclarationForExpression(node.receiver); - if (isTslClass(declaration)) { - const ownStaticMembers = getClassMembers(declaration).filter(isStatic); - const superclassStaticMembers = this.classHierarchy.streamSuperclassMembers(declaration).filter(isStatic); - - return this.createScopeForNodes(ownStaticMembers, this.createScopeForNodes(superclassStaticMembers)); - } else if (isTslEnum(declaration)) { - return this.createScopeForNodes(getEnumVariants(declaration)); - } - // Call results let resultScope = EMPTY_SCOPE; if (isTslCall(node.receiver)) { @@ -261,23 +172,6 @@ export class SafeDsScopeProvider extends DefaultScopeProvider { return resultScope; } - /** - * Returns the unique declaration that is referenced by this expression. If the expression references none or - * multiple declarations, undefined is returned. - * - * @param node The expression to get the referenced declaration for. - * @returns The referenced declaration or undefined. - */ - private getUniqueReferencedDeclarationForExpression(node: TslExpression): TslDeclaration | undefined { - if (isTslReference(node)) { - return node.target.ref; - } else if (isTslMemberAccess(node)) { - return node.member?.target?.ref; - } else { - return undefined; - } - } - private getScopeForReferenceTarget(node: TslReference, context: ReferenceInfo): Scope { // Declarations in other files let currentScope = this.getGlobalScope(TslDeclaration, context); @@ -300,12 +194,6 @@ export class SafeDsScopeProvider extends DefaultScopeProvider { // Cannot reference the target of an annotation call from inside the annotation call let start: AstNode | undefined; - const containingAnnotationCall = AstUtils.getContainerOfType(node, isTslAnnotationCall); - if (containingAnnotationCall) { - start = getAnnotationCallTarget(containingAnnotationCall)?.$container; - } else { - start = node.$container; - } // Only containing classes, enums, and enum variants can be referenced let current = AstUtils.getContainerOfType(start, isTslNamedTypeDeclaration); @@ -360,12 +248,7 @@ export class SafeDsScopeProvider extends DefaultScopeProvider { // Local declarations const localDeclarations = [...parameters, ...placeholders]; - // Lambdas can be nested - if (isTslLambda(containingCallable)) { - return this.createScopeForNodes(localDeclarations, this.localDeclarations(containingCallable, outerScope)); - } else { - return this.createScopeForNodes(localDeclarations, outerScope); - } + return this.createScopeForNodes(localDeclarations, outerScope); } private *parametersUpToParameter( @@ -400,31 +283,6 @@ export class SafeDsScopeProvider extends DefaultScopeProvider { } } - private getScopeForTypeArgumentTypeParameter(node: TslTypeArgument): Scope { - const containingNamedType = AstUtils.getContainerOfType(node, isTslNamedType); - if (!containingNamedType) { - /* c8 ignore next 2 */ - return EMPTY_SCOPE; - } - - const namedTypeDeclaration = containingNamedType.declaration?.ref; - if (isTslClass(namedTypeDeclaration)) { - const typeParameters = getTypeParameters(namedTypeDeclaration.typeParameterList); - return this.createScopeForNodes(typeParameters); - } else { - return EMPTY_SCOPE; - } - } - - private getScopeForYieldResult(node: TslYield): Scope { - const containingSegment = AstUtils.getContainerOfType(node, isTslSegment); - if (!containingSegment) { - return EMPTY_SCOPE; - } - - return this.createScopeForNodes(getResults(containingSegment.resultList)); - } - protected override getGlobalScope(referenceType: string, context: ReferenceInfo): Scope { const node = context.container; const key = `${AstUtils.getDocument(node).uri}~${referenceType}`; diff --git a/packages/ttsl-lang/src/language/validation/builtins/pythonCall.ts b/packages/ttsl-lang/src/language/validation/builtins/pythonCall.ts index d23a4bbc..36d441d9 100644 --- a/packages/ttsl-lang/src/language/validation/builtins/pythonCall.ts +++ b/packages/ttsl-lang/src/language/validation/builtins/pythonCall.ts @@ -21,9 +21,6 @@ export const pythonCallMustOnlyContainValidTemplateExpressions = (services: Safe // Compute valid template expressions const validTemplateExpressions = new Set(getParameters(node).map((it) => `\$${it.name}`)); - if (AstUtils.hasContainerOfType(node, isTslClass)) { - validTemplateExpressions.add('$this'); - } // Compute invalid template expressions const invalidTemplateExpressions = actualTemplateExpressions.filter((it) => !validTemplateExpressions.has(it)); From e4b573984ebb8e97eb5e3c621992d07f30b01ebc Mon Sep 17 00:00:00 2001 From: methr0 Date: Tue, 25 Jun 2024 00:55:17 +0200 Subject: [PATCH 076/183] remove unnecessary code from package manager --- .../src/language/workspace/safe-ds-package-manager.ts | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/packages/ttsl-lang/src/language/workspace/safe-ds-package-manager.ts b/packages/ttsl-lang/src/language/workspace/safe-ds-package-manager.ts index 945e60b2..d1944fdf 100644 --- a/packages/ttsl-lang/src/language/workspace/safe-ds-package-manager.ts +++ b/packages/ttsl-lang/src/language/workspace/safe-ds-package-manager.ts @@ -8,7 +8,6 @@ import { IndexManager, LangiumDocuments, } from 'langium'; -import { isTslSegment } from '../generated/ast.js'; import { getPackageName, isPackagePrivate } from '../helpers/nodeProperties.js'; export class SafeDsPackageManager { @@ -112,7 +111,7 @@ export class SafeDsPackageManager { } if (hideInternal) { - result = result.filter((it) => !isTslSegment(it.node) || !isPackagePrivate(it.node)); + result = result.filter((it) => !isPackagePrivate(it.node) && !isPrivate(it.node)); } return result; From f7540262db90d6dc3618fd845b7177c02523795c Mon Sep 17 00:00:00 2001 From: methr0 Date: Tue, 25 Jun 2024 01:00:21 +0200 Subject: [PATCH 077/183] remove unnecessary functions from nodeProperties --- .../src/language/helpers/nodeProperties.ts | 232 +----------------- 1 file changed, 10 insertions(+), 222 deletions(-) diff --git a/packages/ttsl-lang/src/language/helpers/nodeProperties.ts b/packages/ttsl-lang/src/language/helpers/nodeProperties.ts index 4af31538..3a87e034 100644 --- a/packages/ttsl-lang/src/language/helpers/nodeProperties.ts +++ b/packages/ttsl-lang/src/language/helpers/nodeProperties.ts @@ -1,90 +1,50 @@ import { AstNode, AstUtils, Stream, stream } from 'langium'; import { - isTslAnnotation, isTslArgument, isTslArgumentList, isTslAssignment, - isTslAttribute, - isTslBlockLambda, - isTslBlockLambdaResult, isTslCallable, isTslCallableType, - isTslClass, isTslDeclaration, - isTslEnum, - isTslEnumVariant, isTslFunction, - isTslLambda, isTslModule, isTslModuleMember, - isTslNamedType, isTslParameter, - isTslParameterBound, isTslPlaceholder, isTslQualifiedImport, - isTslSegment, - isTslTypeArgumentList, - isTslTypeParameter, - isTslTypeParameterList, TslAbstractCall, - TslAbstractResult, - TslAnnotatedObject, - TslAnnotation, - TslAnnotationCall, TslArgument, TslArgumentList, TslAssignee, TslAssignment, TslBlock, - TslBlockLambda, - TslBlockLambdaResult, TslCallable, - TslClass, - TslClassMember, - TslColumn, - TslConstraint, TslDeclaration, - TslEnum, - TslEnumVariant, TslImport, TslImportedDeclaration, TslLiteral, - TslLiteralType, TslModule, TslModuleMember, - TslNamedType, TslNamedTypeDeclaration, TslParameter, - TslParameterBound, TslPlaceholder, TslQualifiedImport, TslResult, TslResultList, - TslSchema, TslStatement, TslType, - TslTypeArgument, - TslTypeArgumentList, - TslTypeParameter, - TslTypeParameterList, } from '../generated/ast.js'; // ------------------------------------------------------------------------------------------------- // Checks // ------------------------------------------------------------------------------------------------- -export const hasAnnotationCallOf = ( - node: TslAnnotatedObject | undefined, - expected: TslAnnotation | undefined, -): boolean => { - return getAnnotationCalls(node).some((it) => { - const actual = it.annotation?.ref; - return actual === expected; - }); +export const isPackagePrivate = (node: TslModuleMember | undefined): boolean => { + return (node?.visibility?.visibility == 'packageprivate'); }; -export const isPackagePrivate = (node: TslDeclaration | undefined): boolean => { - return isTslSegment(node) && (node.visibility?.isPackageprivate ?? false); +export const isPrivate = (node: TslModuleMember | undefined): boolean => { + return (node?.visibility?.visibility == 'private'); }; export namespace Argument { @@ -97,18 +57,6 @@ export namespace Argument { }; } -export namespace Enum { - export const isConstant = (node: TslEnum | undefined): boolean => { - return Boolean(node) && getEnumVariants(node).every((it) => EnumVariant.isConstant(it)); - }; -} - -export namespace EnumVariant { - export const isConstant = (node: TslEnumVariant | undefined): boolean => { - return Boolean(node) && getParameters(node).every((it) => Parameter.isConstant(it)); - }; -} - export namespace Parameter { export const isConstant = (node: TslParameter | undefined): boolean => { if (!node) { @@ -118,11 +66,11 @@ export namespace Parameter { const containingCallable = AstUtils.getContainerOfType(node, isTslCallable); // In those cases, the const modifier is not applicable - if (isTslCallableType(containingCallable) || isTslLambda(containingCallable)) { + if (isTslCallableType(containingCallable)) { return false; } - return node.isConstant || isTslAnnotation(containingCallable); + return node.isConstant; }; export const isOptional = (node: TslParameter | undefined): boolean => { @@ -132,109 +80,26 @@ export namespace Parameter { export const isRequired = (node: TslParameter | undefined): boolean => { return isTslParameter(node) && !node.defaultValue; }; - - export const getBounds = (node: TslParameter | undefined): TslParameterBound[] => { - const callable = AstUtils.getContainerOfType(node, isTslCallable); - const result = getConstraints(callable).filter((it) => isTslParameterBound(it) && it.leftOperand?.ref === node); - return result as TslParameterBound[]; - }; -} - -export const isStatic = (node: TslClassMember | undefined): boolean => { - if (isTslClass(node) || isTslEnum(node)) { - return true; - } else if (isTslAttribute(node)) { - return node.isStatic; - } else if (isTslFunction(node)) { - return node.isStatic; - } else { - /* c8 ignore next 2 */ - return false; - } -}; - -export namespace TypeArgument { - export const isNamed = (node: TslTypeArgument | undefined): boolean => { - return Boolean(node?.typeParameter); - }; -} - -export namespace TypeParameter { - export const isOptional = (node: TslTypeParameter | undefined): boolean => { - return Boolean(node?.defaultValue); - }; - - export const isRequired = (node: TslTypeParameter | undefined): boolean => { - return isTslTypeParameter(node) && !node.defaultValue; - }; - - export const isContravariant = (node: TslTypeParameter | undefined): boolean => { - return isTslTypeParameter(node) && node.variance === 'in'; - }; - - export const isCovariant = (node: TslTypeParameter | undefined): boolean => { - return isTslTypeParameter(node) && node.variance === 'out'; - }; - - export const isInvariant = (node: TslTypeParameter | undefined): boolean => { - return isTslTypeParameter(node) && !node.variance; - }; } // ------------------------------------------------------------------------------------------------- // Accessors for list elements // ------------------------------------------------------------------------------------------------- -export const getAbstractResults = (node: TslCallable | undefined): TslAbstractResult[] => { +export const getyResults = (node: TslCallable | undefined): TslResult[] => { if (!node) { return []; } - if (isTslBlockLambda(node)) { - return streamBlockLambdaResults(node).toArray(); - } else if (isTslCallableType(node)) { - return getResults(node.resultList); + if (isTslCallableType(node)) { + return node.resultList.results ?? []; } else if (isTslFunction(node) && node.result) { return [node.result]; - } else if (isTslSegment(node)) { - return getResults(node.resultList); - } /* c8 ignore start */ else { + }/* c8 ignore start */ else { return []; } /* c8 ignore stop */ }; -export const getAnnotationCalls = (node: TslAnnotatedObject | undefined): TslAnnotationCall[] => { - if (!node) { - /* c8 ignore next 2 */ - return []; - } - - if (isTslDeclaration(node)) { - return node?.annotationCallList?.annotationCalls ?? node?.annotationCalls ?? []; - } else { - /* c8 ignore next 2 */ - return node?.annotationCalls ?? []; - } -}; - -export const getAnnotationCallTarget = (node: TslAnnotationCall | undefined): TslDeclaration | undefined => { - return AstUtils.getContainerOfType(node, isTslDeclaration); -}; - -export const findFirstAnnotationCallOf = ( - node: TslAnnotatedObject | undefined, - expected: TslAnnotation | undefined, -): TslAnnotationCall | undefined => { - if (!node || !expected) { - return undefined; - } - - return getAnnotationCalls(node).find((it) => { - const actual = it.annotation?.ref; - return actual === expected; - }); -}; - export const getArguments = (node: TslArgumentList | TslAbstractCall | undefined): TslArgument[] => { if (isTslArgumentList(node)) { return node.arguments; @@ -247,41 +112,6 @@ export const getAssignees = (node: TslAssignment | undefined): TslAssignee[] => return node?.assigneeList?.assignees ?? []; }; -export const streamBlockLambdaResults = (node: TslBlockLambda | undefined): Stream => { - return stream(getStatements(node?.body)) - .filter(isTslAssignment) - .flatMap(getAssignees) - .filter(isTslBlockLambdaResult); -}; - -export const getClassMembers = (node: TslClass | undefined): TslClassMember[] => { - return node?.body?.members ?? []; -}; - -export const getConstraints = (node: TslCallable | undefined): TslConstraint[] => { - if (isTslAnnotation(node)) { - return node.constraintList?.constraints ?? []; - } else if (isTslClass(node)) { - return node.constraintList?.constraints ?? []; - } else if (isTslEnumVariant(node)) { - return node.constraintList?.constraints ?? []; - } else if (isTslFunction(node)) { - return node.constraintList?.constraints ?? []; - } else if (isTslSegment(node)) { - return node.constraintList?.constraints ?? []; - } else { - return []; - } -}; - -export const getColumns = (node: TslSchema | undefined): TslColumn[] => { - return node?.columnList?.columns ?? []; -}; - -export const getEnumVariants = (node: TslEnum | undefined): TslEnumVariant[] => { - return node?.body?.variants ?? []; -}; - export const getImports = (node: TslModule | undefined): TslImport[] => { return node?.imports ?? []; }; @@ -300,10 +130,6 @@ export const getImportedDeclarations = (node: TslModule | TslQualifiedImport | u } }; -export const getLiterals = (node: TslLiteralType | undefined): TslLiteral[] => { - return node?.literalList?.literals ?? []; -}; - export const getModuleMembers = (node: TslModule | undefined): TslModuleMember[] => { return node?.members?.filter(isTslModuleMember) ?? []; }; @@ -316,10 +142,6 @@ export const getParameters = (node: TslCallable | undefined): TslParameter[] => return node?.parameterList?.parameters ?? []; }; -export const getParentTypes = (node: TslClass | undefined): TslType[] => { - return node?.parentTypeList?.parentTypes ?? []; -}; - export const getQualifiedName = (node: TslDeclaration | undefined): string | undefined => { const segments = []; @@ -342,40 +164,6 @@ export const getPlaceholderByName = (block: TslBlock, name: string | undefined): return name ? streamPlaceholders(block).find((placeholder) => placeholder.name === name) : undefined; }; -export const getResults = (node: TslResultList | undefined): TslResult[] => { - return node?.results ?? []; -}; - export const getStatements = (node: TslBlock | undefined): TslStatement[] => { return node?.statements ?? []; }; - -export const getTypeArguments = (node: TslTypeArgumentList | TslNamedType | undefined): TslTypeArgument[] => { - if (!node) { - return []; - } - - if (isTslTypeArgumentList(node)) { - return node.typeArguments; - } else if (isTslNamedType(node)) { - return getTypeArguments(node.typeArgumentList); - } /* c8 ignore start */ else { - return []; - } /* c8 ignore stop */ -}; - -export const getTypeParameters = ( - node: TslTypeParameterList | TslCallable | TslNamedTypeDeclaration | undefined, -): TslTypeParameter[] => { - if (!node) { - return []; - } - - if (isTslTypeParameterList(node)) { - return node.typeParameters; - } else if (isTslClass(node)) { - return getTypeParameters(node.typeParameterList); - } /* c8 ignore start */ else { - return []; - } /* c8 ignore stop */ -}; From 003c2c79125a67ece88936cda74d63ab14ed70d1 Mon Sep 17 00:00:00 2001 From: methr0 Date: Tue, 25 Jun 2024 01:03:57 +0200 Subject: [PATCH 078/183] fix typo in node Properties --- .../src/language/helpers/nodeProperties.ts | 6 +- .../other/declarations/parameterBounds.ts | 129 ------------------ 2 files changed, 1 insertion(+), 134 deletions(-) delete mode 100644 packages/ttsl-lang/src/language/validation/other/declarations/parameterBounds.ts diff --git a/packages/ttsl-lang/src/language/helpers/nodeProperties.ts b/packages/ttsl-lang/src/language/helpers/nodeProperties.ts index 3a87e034..14de4f62 100644 --- a/packages/ttsl-lang/src/language/helpers/nodeProperties.ts +++ b/packages/ttsl-lang/src/language/helpers/nodeProperties.ts @@ -22,17 +22,13 @@ import { TslDeclaration, TslImport, TslImportedDeclaration, - TslLiteral, TslModule, TslModuleMember, - TslNamedTypeDeclaration, TslParameter, TslPlaceholder, TslQualifiedImport, TslResult, - TslResultList, TslStatement, - TslType, } from '../generated/ast.js'; // ------------------------------------------------------------------------------------------------- @@ -86,7 +82,7 @@ export namespace Parameter { // Accessors for list elements // ------------------------------------------------------------------------------------------------- -export const getyResults = (node: TslCallable | undefined): TslResult[] => { +export const getResults = (node: TslCallable | undefined): TslResult[] => { if (!node) { return []; } diff --git a/packages/ttsl-lang/src/language/validation/other/declarations/parameterBounds.ts b/packages/ttsl-lang/src/language/validation/other/declarations/parameterBounds.ts deleted file mode 100644 index a79bdbd1..00000000 --- a/packages/ttsl-lang/src/language/validation/other/declarations/parameterBounds.ts +++ /dev/null @@ -1,129 +0,0 @@ -import { SafeDsServices } from '../../../safe-ds-module.js'; -import { - isTslCallable, - isTslComparisonOperator, - type TslCall, - TslParameter, -} from '../../../generated/ast.js'; -import { AstUtils, ValidationAcceptor } from 'langium'; -import { getArguments, getParameters, Parameter } from '../../../helpers/nodeProperties.js'; -import { Constant, EvaluatedNode, FloatConstant, IntConstant } from '../../../partialEvaluation/model.js'; - -export const CODE_PARAMETER_BOUND_INVALID_VALUE = 'parameter-bound/invalid-value'; -export const CODE_PARAMETER_BOUND_PARAMETER = 'parameter-bound/parameter'; -export const CODE_PARAMETER_BOUND_RIGHT_OPERAND = 'parameter-bound/right-operand'; - -export const callArgumentMustRespectParameterBounds = (services: SafeDsServices) => { - const nodeMapper = services.helpers.NodeMapper; - const partialEvaluator = services.evaluation.PartialEvaluator; - - return (node: TslCall, accept: ValidationAcceptor) => { - const substitutions = partialEvaluator.computeParameterSubstitutionsForCall(node); - - for (const argument of getArguments(node)) { - const value = partialEvaluator.evaluate(argument.value); - if (!(value instanceof Constant)) { - continue; - } - - const parameter = nodeMapper.argumentToParameter(argument); - if (!parameter) { - continue; - } - - for (const bound of Parameter.getBounds(parameter)) { - const rightOperand = partialEvaluator.evaluate(bound.rightOperand, substitutions); - const errorMessage = checkBound(parameter.name, value, bound.operator, rightOperand); - - if (errorMessage) { - accept('error', errorMessage, { - node: argument, - property: 'value', - code: CODE_PARAMETER_BOUND_INVALID_VALUE, - }); - } - } - } - }; -}; - -export const parameterDefaultValueMustRespectParameterBounds = (services: SafeDsServices) => { - const partialEvaluator = services.evaluation.PartialEvaluator; - - return (node: TslParameter, accept: ValidationAcceptor) => { - if (!node.defaultValue) { - return; - } - - const value = partialEvaluator.evaluate(node.defaultValue); - if (!(value instanceof Constant)) { - return; - } - - // Error if we cannot verify some bounds - for (const bound of Parameter.getBounds(node)) { - const rightOperand = partialEvaluator.evaluate(bound.rightOperand); - if (!(rightOperand instanceof Constant)) { - accept('error', 'Cannot verify whether the parameter bounds are always met.', { - node, - property: 'defaultValue', - code: CODE_PARAMETER_BOUND_INVALID_VALUE, - }); - return; - } - } - - // Error if the default value violates some bounds - for (const bound of Parameter.getBounds(node)) { - const rightOperand = partialEvaluator.evaluate(bound.rightOperand); - const errorMessage = checkBound(node.name, value, bound.operator, rightOperand); - if (errorMessage) { - accept('error', errorMessage, { - node, - property: 'defaultValue', - code: CODE_PARAMETER_BOUND_INVALID_VALUE, - }); - } - } - }; -}; - -const checkBound = ( - parameterName: string, - leftOperand: EvaluatedNode, - operator: string, - rightOperand: EvaluatedNode, -): string | undefined => { - // Arguments must be valid - if ( - (!(leftOperand instanceof FloatConstant) && !(leftOperand instanceof IntConstant)) || - !isTslComparisonOperator(operator) || - (!(rightOperand instanceof FloatConstant) && !(rightOperand instanceof IntConstant)) - ) { - return; - } - - const createMessage = (relation: string) => { - return `The value of '${parameterName}' must be ${relation} ${rightOperand.toString()} but was ${leftOperand.toString()}.`; - }; - - if (operator === '<') { - if (leftOperand.value >= rightOperand.value) { - return createMessage('less than'); - } - } else if (operator === '<=') { - if (leftOperand.value > rightOperand.value) { - return createMessage('less than or equal to'); - } - } else if (operator === '>=') { - if (leftOperand.value < rightOperand.value) { - return createMessage('greater than or equal to'); - } - } else if (operator === '>') { - if (leftOperand.value <= rightOperand.value) { - return createMessage('greater than'); - } - } - - return undefined; -}; \ No newline at end of file From dd9642e7eaaa9318ca9e4f0cc3b4cae8cf8abf55 Mon Sep 17 00:00:00 2001 From: methr0 Date: Tue, 25 Jun 2024 01:15:34 +0200 Subject: [PATCH 079/183] fix use of node property functions --- .../validation/builtins/deprecated.ts | 3 +- .../language/validation/builtins/expert.ts | 3 +- .../validation/builtins/pythonCall.ts | 6 +-- .../validation/builtins/pythonModule.ts | 3 +- .../validation/builtins/pythonName.ts | 8 +--- .../validation/builtins/repeatable.ts | 23 ---------- .../src/language/validation/names.ts | 2 +- .../other/declarations/annotationCalls.ts | 45 ------------------- .../other/statements/assignments.ts | 4 +- .../src/language/validation/purity.ts | 6 +-- .../language/validation/safe-ds-validator.ts | 14 ------ 11 files changed, 14 insertions(+), 103 deletions(-) delete mode 100644 packages/ttsl-lang/src/language/validation/builtins/repeatable.ts delete mode 100644 packages/ttsl-lang/src/language/validation/other/declarations/annotationCalls.ts diff --git a/packages/ttsl-lang/src/language/validation/builtins/deprecated.ts b/packages/ttsl-lang/src/language/validation/builtins/deprecated.ts index 94db79b6..890aef30 100644 --- a/packages/ttsl-lang/src/language/validation/builtins/deprecated.ts +++ b/packages/ttsl-lang/src/language/validation/builtins/deprecated.ts @@ -10,7 +10,6 @@ import { } from '../../generated/ast.js'; import { Parameter } from '../../helpers/nodeProperties.js'; import { SafeDsServices } from '../../safe-ds-module.js'; -import { parameterCanBeAnnotated } from '../other/declarations/annotationCalls.js'; export const CODE_DEPRECATED_LIBRARY_ELEMENT = 'deprecated/library-element'; export const CODE_DEPRECATED_REQUIRED_PARAMETER = 'deprecated/required-parameter'; @@ -65,7 +64,7 @@ export const referenceTargetShouldNotBeDeprecated = export const requiredParameterMustNotBeDeprecated = (services: SafeDsServices) => (node: TslParameter, accept: ValidationAcceptor) => { - if (Parameter.isRequired(node) && parameterCanBeAnnotated(node)) { + if (Parameter.isRequired(node)) { if (services.builtins.Annotations.callsDeprecated(node)) { accept('error', 'A deprecated parameter must be optional.', { node, diff --git a/packages/ttsl-lang/src/language/validation/builtins/expert.ts b/packages/ttsl-lang/src/language/validation/builtins/expert.ts index 58a2c595..2ec2ed67 100644 --- a/packages/ttsl-lang/src/language/validation/builtins/expert.ts +++ b/packages/ttsl-lang/src/language/validation/builtins/expert.ts @@ -2,13 +2,12 @@ import { ValidationAcceptor } from 'langium'; import { TslParameter } from '../../generated/ast.js'; import { Parameter } from '../../helpers/nodeProperties.js'; import { SafeDsServices } from '../../safe-ds-module.js'; -import { parameterCanBeAnnotated } from '../other/declarations/annotationCalls.js'; export const CODE_EXPERT_TARGET_PARAMETER = 'expert/target-parameter'; export const requiredParameterMustNotBeExpert = (services: SafeDsServices) => (node: TslParameter, accept: ValidationAcceptor) => { - if (Parameter.isRequired(node) && parameterCanBeAnnotated(node)) { + if (Parameter.isRequired(node)) { if (services.builtins.Annotations.callsExpert(node)) { accept('error', 'An expert parameter must be optional.', { node, diff --git a/packages/ttsl-lang/src/language/validation/builtins/pythonCall.ts b/packages/ttsl-lang/src/language/validation/builtins/pythonCall.ts index 36d441d9..1efdd255 100644 --- a/packages/ttsl-lang/src/language/validation/builtins/pythonCall.ts +++ b/packages/ttsl-lang/src/language/validation/builtins/pythonCall.ts @@ -1,7 +1,7 @@ -import { AstUtils, ValidationAcceptor } from 'langium'; +import { ValidationAcceptor } from 'langium'; import { TslFunction } from '../../generated/ast.js'; import { SafeDsServices } from '../../safe-ds-module.js'; -import { findFirstAnnotationCallOf, getParameters } from '../../helpers/nodeProperties.js'; +import { getParameters } from '../../helpers/nodeProperties.js'; import { pluralize } from '../../../helpers/strings.js'; export const CODE_PYTHON_CALL_INVALID_TEMPLATE_EXPRESSION = 'python-call/invalid-template-expression'; @@ -31,7 +31,7 @@ export const pythonCallMustOnlyContainValidTemplateExpressions = (services: Safe const invalidTemplateExpressionsString = invalidTemplateExpressions.map((it) => `'${it}'`).join(', '); accept('error', `The ${kind} ${invalidTemplateExpressionsString} cannot be interpreted.`, { - node: findFirstAnnotationCallOf(node, builtinAnnotations.PythonCall)!, + node: builtinAnnotations.PythonCall!, property: 'annotation', code: CODE_PYTHON_CALL_INVALID_TEMPLATE_EXPRESSION, }); diff --git a/packages/ttsl-lang/src/language/validation/builtins/pythonModule.ts b/packages/ttsl-lang/src/language/validation/builtins/pythonModule.ts index 11167755..791c216e 100644 --- a/packages/ttsl-lang/src/language/validation/builtins/pythonModule.ts +++ b/packages/ttsl-lang/src/language/validation/builtins/pythonModule.ts @@ -1,7 +1,6 @@ import { ValidationAcceptor } from 'langium'; import { TslModule } from '../../generated/ast.js'; import { SafeDsServices } from '../../safe-ds-module.js'; -import { findFirstAnnotationCallOf } from '../../helpers/nodeProperties.js'; export const CODE_PYTHON_MODULE_SAME_AS_SAFE_DS_PACKAGE = 'python-module/same-as-safe-ds-package'; @@ -14,7 +13,7 @@ export const pythonModuleShouldDifferFromSafeDsPackage = (services: SafeDsServic return; } - const annotationCall = findFirstAnnotationCallOf(node, builtinAnnotations.PythonModule)!; + const annotationCall = builtinAnnotations.PythonModule!; accept( 'info', 'The Python module is identical to the Safe-DS package, so the annotation call can be removed.', diff --git a/packages/ttsl-lang/src/language/validation/builtins/pythonName.ts b/packages/ttsl-lang/src/language/validation/builtins/pythonName.ts index d782ffe2..1ae75951 100644 --- a/packages/ttsl-lang/src/language/validation/builtins/pythonName.ts +++ b/packages/ttsl-lang/src/language/validation/builtins/pythonName.ts @@ -1,7 +1,6 @@ import { ValidationAcceptor } from 'langium'; import { TslDeclaration, TslFunction } from '../../generated/ast.js'; import { SafeDsServices } from '../../safe-ds-module.js'; -import { findFirstAnnotationCallOf, hasAnnotationCallOf } from '../../helpers/nodeProperties.js'; export const CODE_PYTHON_NAME_MUTUALLY_EXCLUSIVE_WITH_PYTHON_CALL = 'python-name/mutually-exclusive-with-python-call'; export const CODE_PYTHON_NAME_SAME_AS_SAFE_DS_NAME = 'python-name/same-as-safe-ds-name'; @@ -10,11 +9,8 @@ export const pythonNameMustNotBeSetIfPythonCallIsSet = (services: SafeDsServices const builtinAnnotations = services.builtins.Annotations; return (node: TslFunction, accept: ValidationAcceptor) => { - if (!hasAnnotationCallOf(node, builtinAnnotations.PythonCall)) { - return; - } - const firstPythonName = findFirstAnnotationCallOf(node, builtinAnnotations.PythonName); + const firstPythonName = builtinAnnotations.PythonName; if (!firstPythonName) { return; } @@ -36,7 +32,7 @@ export const pythonNameShouldDifferFromSafeDsName = (services: SafeDsServices) = return; } - const annotationCall = findFirstAnnotationCallOf(node, builtinAnnotations.PythonName)!; + const annotationCall = builtinAnnotations.PythonName!; accept('info', 'The Python name is identical to the Safe-DS name, so the annotation call can be removed.', { node: annotationCall, property: 'annotation', diff --git a/packages/ttsl-lang/src/language/validation/builtins/repeatable.ts b/packages/ttsl-lang/src/language/validation/builtins/repeatable.ts deleted file mode 100644 index 5a9aa97b..00000000 --- a/packages/ttsl-lang/src/language/validation/builtins/repeatable.ts +++ /dev/null @@ -1,23 +0,0 @@ -import { ValidationAcceptor } from 'langium'; -import { duplicatesBy } from '../../../helpers/collections.js'; -import { TslDeclaration } from '../../generated/ast.js'; -import { getAnnotationCalls } from '../../helpers/nodeProperties.js'; -import { SafeDsServices } from '../../safe-ds-module.js'; - -export const CODE_ANNOTATION_NOT_REPEATABLE = 'annotation/not-repeatable'; - -export const singleUseAnnotationsMustNotBeRepeated = - (services: SafeDsServices) => (node: TslDeclaration, accept: ValidationAcceptor) => { - const callsOfSingleUseAnnotations = getAnnotationCalls(node).filter((it) => { - const annotation = it.annotation?.ref; - return annotation && !services.builtins.Annotations.callsRepeatable(annotation); - }); - - for (const duplicate of duplicatesBy(callsOfSingleUseAnnotations, (it) => it.annotation?.ref)) { - accept('error', `The annotation '${duplicate.annotation?.$refText}' is not repeatable.`, { - node: duplicate, - property: 'annotation', - code: CODE_ANNOTATION_NOT_REPEATABLE, - }); - } - }; diff --git a/packages/ttsl-lang/src/language/validation/names.ts b/packages/ttsl-lang/src/language/validation/names.ts index cc4f4040..1a7809dd 100644 --- a/packages/ttsl-lang/src/language/validation/names.ts +++ b/packages/ttsl-lang/src/language/validation/names.ts @@ -146,7 +146,7 @@ const acceptCasingWarning = ( export const callableTypeMustContainUniqueNames = (node: TslCallableType, accept: ValidationAcceptor): void => { namesMustBeUnique(getParameters(node), (name) => `A parameter with name '${name}' exists already.`, accept); - namesMustBeUnique(getResults(node.resultList), (name) => `A result with name '${name}' exists already.`, accept); + namesMustBeUnique(getResults(node), (name) => `A result with name '${name}' exists already.`, accept); }; export const moduleMemberMustHaveNameThatIsUniqueInPackage = (services: SafeDsServices) => { diff --git a/packages/ttsl-lang/src/language/validation/other/declarations/annotationCalls.ts b/packages/ttsl-lang/src/language/validation/other/declarations/annotationCalls.ts deleted file mode 100644 index 768f3baf..00000000 --- a/packages/ttsl-lang/src/language/validation/other/declarations/annotationCalls.ts +++ /dev/null @@ -1,45 +0,0 @@ -import { AstUtils, ValidationAcceptor } from 'langium'; -import { isEmpty } from '../../../../helpers/collections.js'; -import { - isTslCallable, - isTslCallableType, - TslCallableType, - TslParameter, -} from '../../../generated/ast.js'; -import { - getAnnotationCalls, - getArguments, - getParameters, - getResults, - Parameter, -} from '../../../helpers/nodeProperties.js'; - -export const CODE_ANNOTATION_CALL_TARGET_PARAMETER = 'annotation-call/target-parameter'; -export const CODE_ANNOTATION_CALL_TARGET_RESULT = 'annotation-call/target-result'; - -export const callableTypeParametersMustNotBeAnnotated = (node: TslCallableType, accept: ValidationAcceptor) => { - for (const parameter of getParameters(node)) { - for (const annotationCall of getAnnotationCalls(parameter)) { - accept('error', 'Parameters of callable types must not be annotated.', { - node: annotationCall, - code: CODE_ANNOTATION_CALL_TARGET_PARAMETER, - }); - } - } -}; - -export const callableTypeResultsMustNotBeAnnotated = (node: TslCallableType, accept: ValidationAcceptor) => { - for (const result of getResults(node.resultList)) { - for (const annotationCall of getAnnotationCalls(result)) { - accept('error', 'Results of callable types must not be annotated.', { - node: annotationCall, - code: CODE_ANNOTATION_CALL_TARGET_RESULT, - }); - } - } -}; - -export const parameterCanBeAnnotated = (node: TslParameter) => { - const containingCallable = AstUtils.getContainerOfType(node, isTslCallable); - return !isTslCallableType(containingCallable); -}; diff --git a/packages/ttsl-lang/src/language/validation/other/statements/assignments.ts b/packages/ttsl-lang/src/language/validation/other/statements/assignments.ts index 1c82406e..e6e3cbce 100644 --- a/packages/ttsl-lang/src/language/validation/other/statements/assignments.ts +++ b/packages/ttsl-lang/src/language/validation/other/statements/assignments.ts @@ -1,7 +1,7 @@ import { isTslCall, TslAssignment} from '../../../generated/ast.js'; import { ValidationAcceptor } from 'langium'; import { SafeDsServices } from '../../../safe-ds-module.js'; -import { getAbstractResults, getAssignees } from '../../../helpers/nodeProperties.js'; +import { getResults, getAssignees } from '../../../helpers/nodeProperties.js'; import { pluralize } from '../../../../helpers/strings.js'; export const CODE_ASSIGNMENT_IMPLICITLY_IGNORED_RESULT = 'assignment/implicitly-ignored-result'; @@ -31,7 +31,7 @@ export const assignmentShouldNotImplicitlyIgnoreResult = (services: SafeDsServic const assignees = getAssignees(node); const callable = nodeMapper.callToCallable(expression); - const results = getAbstractResults(callable); + const results = getResults(callable); if (results.length > assignees.length) { const kind = pluralize(results.length - assignees.length, 'result'); diff --git a/packages/ttsl-lang/src/language/validation/purity.ts b/packages/ttsl-lang/src/language/validation/purity.ts index 543b5f0d..808f7ef1 100644 --- a/packages/ttsl-lang/src/language/validation/purity.ts +++ b/packages/ttsl-lang/src/language/validation/purity.ts @@ -1,7 +1,7 @@ import { stream, type ValidationAcceptor } from 'langium'; import { isSubset } from '../../helpers/collections.js'; import { isTslCall, isTslFunction, isTslList, TslCall, type TslFunction, TslParameter } from '../generated/ast.js'; -import { findFirstAnnotationCallOf, getArguments, getParameters } from '../helpers/nodeProperties.js'; +import { getArguments, getParameters } from '../helpers/nodeProperties.js'; import { StringConstant } from '../partialEvaluation/model.js'; import type { SafeDsServices } from '../safe-ds-module.js'; import { CallableType } from '../typing/model.js'; @@ -63,7 +63,7 @@ export const impurityReasonParameterNameMustBelongToParameterOfCorrectType = (se const typeComputer = services.types.TypeComputer; return (node: TslFunction, accept: ValidationAcceptor) => { - const annotationCall = findFirstAnnotationCallOf(node, builtinAnnotations.Impure); + const annotationCall = builtinAnnotations.Impure; // Don't further validate if the function is marked as impure and as pure if (!annotationCall || builtinAnnotations.callsPure(node)) { @@ -150,7 +150,7 @@ export const impurityReasonShouldNotBeSetMultipleTimes = (services: SafeDsServic const partialEvaluator = services.evaluation.PartialEvaluator; return (node: TslFunction, accept: ValidationAcceptor) => { - const annotationCall = findFirstAnnotationCallOf(node, builtinAnnotations.Impure); + const annotationCall = builtinAnnotations.Impure; // Don't further validate if the function is marked as impure and as pure if (!annotationCall || builtinAnnotations.callsPure(node)) { diff --git a/packages/ttsl-lang/src/language/validation/safe-ds-validator.ts b/packages/ttsl-lang/src/language/validation/safe-ds-validator.ts index 2e3896b3..4d3c3a06 100644 --- a/packages/ttsl-lang/src/language/validation/safe-ds-validator.ts +++ b/packages/ttsl-lang/src/language/validation/safe-ds-validator.ts @@ -19,7 +19,6 @@ import { pythonNameMustNotBeSetIfPythonCallIsSet, pythonNameShouldDifferFromSafeDsName, } from './builtins/pythonName.js'; -import { singleUseAnnotationsMustNotBeRepeated } from './builtins/repeatable.js'; import { mapsShouldBeUsedWithCaution, } from './experimentalLanguageFeatures.js'; @@ -37,10 +36,6 @@ import { argumentListMustNotSetParameterMultipleTimes, argumentListMustSetAllRequiredParameters, } from './other/argumentLists.js'; -import { - callableTypeParametersMustNotBeAnnotated, - callableTypeResultsMustNotBeAnnotated, -} from './other/declarations/annotationCalls.js'; import { parameterListMustNotHaveRequiredParametersAfterOptionalParameters } from './other/declarations/parameterLists.js'; import { constantParameterMustHaveConstantDefaultValue, @@ -97,10 +92,6 @@ import { import { statementMustDoSomething } from './other/statements/statements.js'; import { indexedAccessIndexMustBeValid } from './other/expressions/indexedAccess.js'; import { chainedExpressionsMustBeNullSafeIfReceiverIsNullable } from './other/expressions/chainedExpressions.js'; -import { - callArgumentMustRespectParameterBounds, - parameterDefaultValueMustRespectParameterBounds, -} from './other/declarations/parameterBounds.js'; import { groupByVariableMustBeAnID, groupedFunctionHasAggregation, groupedFunctionHasValidID } from './aggregation.js'; /** @@ -136,7 +127,6 @@ export const registerValidationChecks = function (services: SafeDsServices) { callArgumentListShouldBeNeeded(services), callArgumentAssignedToPureParameterMustBePure(services), callArgumentMustBeConstantIfParameterIsConstant(services), - callArgumentMustRespectParameterBounds(services), callArgumentTypesMustMatchParameterTypes(services), callMustNotBeRecursive(services), callReceiverMustBeCallable(services), @@ -145,9 +135,7 @@ export const registerValidationChecks = function (services: SafeDsServices) { callableTypeMustBeUsedInCorrectContext, callableTypeMustContainUniqueNames, callableTypeMustNotHaveOptionalParameters, - callableTypeParametersMustNotBeAnnotated, callableTypeParameterMustNotHaveConstModifier, - callableTypeResultsMustNotBeAnnotated, ], TslChainedExpression: [ chainedExpressionsMustBeNullSafeIfReceiverIsNullable(services), @@ -158,7 +146,6 @@ export const registerValidationChecks = function (services: SafeDsServices) { nameMustNotStartWithCodegenPrefix, nameShouldHaveCorrectCasing(services), pythonNameShouldDifferFromSafeDsName(services), - singleUseAnnotationsMustNotBeRepeated(services), ], TslFunction: [ functionResultListShouldNotBeEmpty(services), @@ -194,7 +181,6 @@ export const registerValidationChecks = function (services: SafeDsServices) { constantParameterMustHaveConstantDefaultValue(services), constantParameterMustHaveTypeThatCanBeEvaluatedToConstant(services), parameterMustHaveTypeHint, - parameterDefaultValueMustRespectParameterBounds(services), parameterDefaultValueTypeMustMatchParameterType(services), pureParameterDefaultValueMustBePure(services), requiredParameterMustNotBeDeprecated(services), From bb82883b0a531c4978a0e4c86352cfe275f93a11 Mon Sep 17 00:00:00 2001 From: methr0 Date: Tue, 25 Jun 2024 15:25:09 +0200 Subject: [PATCH 080/183] fix visibility --- packages/ttsl-lang/src/language/grammar/ttsl.langium | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/packages/ttsl-lang/src/language/grammar/ttsl.langium b/packages/ttsl-lang/src/language/grammar/ttsl.langium index dfd342ae..f6ba5f28 100644 --- a/packages/ttsl-lang/src/language/grammar/ttsl.langium +++ b/packages/ttsl-lang/src/language/grammar/ttsl.langium @@ -12,6 +12,7 @@ interface TslAbstractCall extends TslObject { interface TslDeclaration extends TslObject { name: string + visibility?: TslVisibility } interface TslLocalVariable extends TslDeclaration { @@ -106,9 +107,7 @@ QualifiedName returns string: // Declarations // ----------------------------------------------------------------------------- -interface TslModuleMember extends TslDeclaration { - visibility?: TslVisibility -} +interface TslModuleMember extends TslDeclaration {} TslModuleMember returns TslModuleMember: {TslFunction} @@ -674,11 +673,13 @@ TslTemplateStringEnd returns TslExpression: interface TslModifier extends TslObject{} interface TslVisibility extends TslModifier{ - visibility: string + isPublic?: boolean + isPackageprivate?: boolean + isPrivate?: boolean } TslVisibility returns TslVisibility: - visibility=('public' | 'packageprivate' | 'private') + isPublic?='public' | isPackageprivate?='packageprivate' | isPrivate?='private' ; interface TslTimeunit extends TslModifier{ From 87e1a7fef0253b950b23016209ba560761f89c5c Mon Sep 17 00:00:00 2001 From: methr0 Date: Tue, 25 Jun 2024 15:25:21 +0200 Subject: [PATCH 081/183] remove unnecessary types --- .../src/language/helpers/nodeProperties.ts | 8 +- .../scoping/safe-ds-scope-provider.ts | 37 +- .../ttsl-lang/src/language/typing/model.ts | 560 +----------------- .../src/language/validation/types.ts | 15 +- .../workspace/safe-ds-package-manager.ts | 5 +- 5 files changed, 19 insertions(+), 606 deletions(-) diff --git a/packages/ttsl-lang/src/language/helpers/nodeProperties.ts b/packages/ttsl-lang/src/language/helpers/nodeProperties.ts index 14de4f62..827a717c 100644 --- a/packages/ttsl-lang/src/language/helpers/nodeProperties.ts +++ b/packages/ttsl-lang/src/language/helpers/nodeProperties.ts @@ -35,12 +35,12 @@ import { // Checks // ------------------------------------------------------------------------------------------------- -export const isPackagePrivate = (node: TslModuleMember | undefined): boolean => { - return (node?.visibility?.visibility == 'packageprivate'); +export const isPackagePrivate = (node: TslDeclaration | undefined): boolean => { + return (node?.visibility?.isPackageprivate ?? false); }; -export const isPrivate = (node: TslModuleMember | undefined): boolean => { - return (node?.visibility?.visibility == 'private'); +export const isPrivate = (node: TslDeclaration | undefined): boolean => { + return (node?.visibility?.isPrivate ?? false); }; export namespace Argument { diff --git a/packages/ttsl-lang/src/language/scoping/safe-ds-scope-provider.ts b/packages/ttsl-lang/src/language/scoping/safe-ds-scope-provider.ts index a9975bda..ae257486 100644 --- a/packages/ttsl-lang/src/language/scoping/safe-ds-scope-provider.ts +++ b/packages/ttsl-lang/src/language/scoping/safe-ds-scope-provider.ts @@ -18,7 +18,6 @@ import { isTslCallable, isTslImportedDeclaration, isTslMemberAccess, - isTslMemberType, isTslModule, isTslNamedTypeDeclaration, isTslParameter, @@ -30,36 +29,25 @@ import { TslArgument, type TslCallable, TslDeclaration, - TslExpression, TslImportedDeclaration, TslMemberAccess, - TslMemberType, - TslNamedTypeDeclaration, type TslParameter, TslPlaceholder, TslReference, TslStatement, - TslType, } from '../generated/ast.js'; import { isContainedInOrEqual } from '../helpers/astUtils.js'; import { - getAbstractResults, - getAnnotationCallTarget, getAssignees, - getClassMembers, - getEnumVariants, getImportedDeclarations, getImports, getPackageName, getParameters, getResults, getStatements, - getTypeParameters, - isStatic, } from '../helpers/nodeProperties.js'; import { SafeDsNodeMapper } from '../helpers/safe-ds-node-mapper.js'; import { SafeDsServices } from '../safe-ds-module.js'; -import { ClassType, EnumVariantType, LiteralType, TypeParameterType } from '../typing/model.js'; import type { SafeDsClassHierarchy } from '../typing/safe-ds-class-hierarchy.js'; import { SafeDsTypeComputer } from '../typing/safe-ds-type-computer.js'; import { SafeDsPackageManager } from '../workspace/safe-ds-package-manager.js'; @@ -135,7 +123,7 @@ export class SafeDsScopeProvider extends DefaultScopeProvider { let resultScope = EMPTY_SCOPE; if (isTslCall(node.receiver)) { const callable = this.nodeMapper.callToCallable(node.receiver); - const results = getAbstractResults(callable); + const results = getResults(callable); if (results.length > 1) { return this.createScopeForNodes(results); @@ -146,29 +134,6 @@ export class SafeDsScopeProvider extends DefaultScopeProvider { } } - // Members - let receiverType = this.typeComputer.computeType(node.receiver); - if (receiverType instanceof LiteralType) { - receiverType = this.typeComputer.computeClassTypeForLiteralType(receiverType); - } else if (receiverType instanceof TypeParameterType) { - receiverType = this.typeComputer.computeUpperBound(receiverType); - } - - if (receiverType instanceof ClassType) { - const ownInstanceMembers = getClassMembers(receiverType.declaration).filter((it) => !isStatic(it)); - const superclassInstanceMembers = this.classHierarchy - .streamSuperclassMembers(receiverType.declaration) - .filter((it) => !isStatic(it)); - - return this.createScopeForNodes( - ownInstanceMembers, - this.createScopeForNodes(superclassInstanceMembers, resultScope), - ); - } else if (receiverType instanceof EnumVariantType) { - const parameters = getParameters(receiverType.declaration); - return this.createScopeForNodes(parameters, resultScope); - } - return resultScope; } diff --git a/packages/ttsl-lang/src/language/typing/model.ts b/packages/ttsl-lang/src/language/typing/model.ts index bf135e6f..9afa8770 100644 --- a/packages/ttsl-lang/src/language/typing/model.ts +++ b/packages/ttsl-lang/src/language/typing/model.ts @@ -1,24 +1,16 @@ import { isEmpty } from '../../helpers/collections.js'; import { - isTslEnum, - TslAbstractResult, TslCallable, - TslClass, TslDeclaration, - TslEnum, - TslEnumVariant, TslParameter, - TslTypeParameter, + TslResult, } from '../generated/ast.js'; -import { getTypeParameters, Parameter } from '../helpers/nodeProperties.js'; -import { Constant, NullConstant } from '../partialEvaluation/model.js'; -import { AstUtils, stream } from 'langium'; -import { SafeDsCoreTypes } from './safe-ds-core-types.js'; +import { Parameter } from '../helpers/nodeProperties.js'; +import { NullConstant } from '../partialEvaluation/model.js'; import { SafeDsServices } from '../safe-ds-module.js'; import { SafeDsTypeFactory } from './safe-ds-type-factory.js'; -import { SafeDsTypeChecker } from './safe-ds-type-checker.js'; -export type TypeParameterSubstitutions = Map; +export type ParameterSubstitutions = Map; /** * The type of an AST node. @@ -56,7 +48,7 @@ export abstract class Type { /** * Returns a copy of this type with the given type parameters substituted. */ - abstract substituteTypeParameters(substitutions: TypeParameterSubstitutions): Type; + abstract substituteTypeParameters(substitutions: ParameterSubstitutions): Type; /** * Returns a copy of this type with the given nullability. @@ -74,7 +66,7 @@ export class CallableType extends Type { readonly callable: TslCallable, readonly parameter: TslParameter | undefined, readonly inputType: NamedTupleType, - readonly outputType: NamedTupleType, + readonly outputType: NamedTupleType, ) { super(); @@ -124,7 +116,7 @@ export class CallableType extends Type { ); } - override substituteTypeParameters(substitutions: TypeParameterSubstitutions): CallableType { + override substituteTypeParameters(substitutions: ParameterSubstitutions): CallableType { if (isEmpty(substitutions) || this.isFullySubstituted) { return this; } @@ -146,92 +138,6 @@ export class CallableType extends Type { } } -export class LiteralType extends Type { - private readonly coreTypes: SafeDsCoreTypes; - private readonly factory: SafeDsTypeFactory; - - private _isExplicitlyNullable: boolean | undefined; - override readonly isFullySubstituted = true; - - constructor( - services: SafeDsServices, - readonly constants: Constant[], - ) { - super(); - - this.coreTypes = services.types.CoreTypes; - this.factory = services.types.TypeFactory; - } - - override get isExplicitlyNullable(): boolean { - if (this._isExplicitlyNullable === undefined) { - this._isExplicitlyNullable = this.constants.some((it) => it === NullConstant); - } - - return this._isExplicitlyNullable; - } - - override equals(other: unknown): boolean { - if (other === this) { - return true; - } else if (!(other instanceof LiteralType)) { - return false; - } - - return ( - this.constants.length === other.constants.length && - this.constants.every((constant, i) => constant.equals(other.constants[i])) - ); - } - - override toString(): string { - return `literal<${this.constants.join(', ')}>`; - } - - override simplify(): Type { - // Handle empty literal types - if (isEmpty(this.constants)) { - return this.coreTypes.Nothing; - } - - // Remove duplicate constants - const uniqueConstants: Constant[] = []; - const knownConstants = new Set(); - - for (const constant of this.constants) { - let key = constant.toString(); - - if (!knownConstants.has(key)) { - uniqueConstants.push(constant); - knownConstants.add(key); - } - } - - // Apply other simplifications - if (uniqueConstants.length === 1 && uniqueConstants[0] === NullConstant) { - return this.coreTypes.NothingOrNull; - } else if (uniqueConstants.length < this.constants.length) { - return this.factory.createLiteralType(...uniqueConstants); - } else { - return this; - } - } - - override substituteTypeParameters(_substitutions: TypeParameterSubstitutions): Type { - return this; - } - - override withExplicitNullability(isExplicitlyNullable: boolean): LiteralType { - if (this.isExplicitlyNullable && !isExplicitlyNullable) { - return this.factory.createLiteralType(...this.constants.filter((it) => it !== NullConstant)); - } else if (!this.isExplicitlyNullable && isExplicitlyNullable) { - return this.factory.createLiteralType(...this.constants, NullConstant); - } else { - return this; - } - } -} - export class NamedTupleType extends Type { private readonly factory: SafeDsTypeFactory; @@ -296,7 +202,7 @@ export class NamedTupleType extends Type { return this.factory.createNamedTupleType(...this.entries.map((it) => it.simplify())); } - override substituteTypeParameters(substitutions: TypeParameterSubstitutions): NamedTupleType { + override substituteTypeParameters(substitutions: ParameterSubstitutions): NamedTupleType { if (isEmpty(substitutions) || this.isFullySubstituted) { return this; } @@ -338,7 +244,7 @@ export class NamedTupleEntry { return `${this.name}: ${this.type}`; } - substituteTypeParameters(substitutions: TypeParameterSubstitutions): NamedTupleEntry { + substituteTypeParameters(substitutions: ParameterSubstitutions): NamedTupleEntry { if (isEmpty(substitutions) || this.type.isFullySubstituted) { /* c8 ignore next 2 */ return this; @@ -352,431 +258,6 @@ export class NamedTupleEntry { } } -export abstract class NamedType extends Type { - protected constructor(readonly declaration: T) { - super(); - } - - override toString(): string { - if (this.isExplicitlyNullable) { - return `${this.declaration.name}?`; - } else { - return this.declaration.name; - } - } - - simplify(): NamedType { - return this; - } - - abstract override withExplicitNullability(isExplicitlyNullable: boolean): NamedType; -} - -export class ClassType extends NamedType { - private _isFullySubstituted: boolean | undefined; - - constructor( - declaration: TslClass, - readonly substitutions: TypeParameterSubstitutions, - override readonly isExplicitlyNullable: boolean, - ) { - super(declaration); - } - - override get isFullySubstituted(): boolean { - if (this._isFullySubstituted === undefined) { - this._isFullySubstituted = stream(this.substitutions.values()).every((it) => it.isFullySubstituted); - } - - return this._isFullySubstituted; - } - - getTypeParameterTypeByIndex(index: number): Type { - const typeParameter = getTypeParameters(this.declaration)[index]; - if (!typeParameter) { - return UnknownType; - } - - return this.substitutions.get(typeParameter) ?? UnknownType; - } - - override equals(other: unknown): boolean { - if (other === this) { - return true; - } else if (!(other instanceof ClassType)) { - return false; - } - - return ( - other.declaration === this.declaration && - other.isExplicitlyNullable === this.isExplicitlyNullable && - substitutionsAreEqual(other.substitutions, this.substitutions) - ); - } - - override toString(): string { - let result = this.declaration.name; - - if (this.substitutions.size > 0) { - result += `<${Array.from(this.substitutions.values()) - .map((value) => value.toString()) - .join(', ')}>`; - } - - if (this.isExplicitlyNullable) { - result += '?'; - } - - return result; - } - - override simplify(): ClassType { - const newSubstitutions = new Map(stream(this.substitutions).map(([key, value]) => [key, value.simplify()])); - return new ClassType(this.declaration, newSubstitutions, this.isExplicitlyNullable); - } - - override substituteTypeParameters(substitutions: TypeParameterSubstitutions): ClassType { - if (isEmpty(substitutions) || this.isFullySubstituted) { - return this; - } - - const newSubstitutions = new Map( - stream(this.substitutions).map(([key, value]) => [key, value.substituteTypeParameters(substitutions)]), - ); - - return new ClassType(this.declaration, newSubstitutions, this.isExplicitlyNullable); - } - - override withExplicitNullability(isExplicitlyNullable: boolean): ClassType { - if (this.isExplicitlyNullable === isExplicitlyNullable) { - return this; - } - - return new ClassType(this.declaration, this.substitutions, isExplicitlyNullable); - } -} - -export class EnumType extends NamedType { - override readonly isFullySubstituted = true; - - constructor( - declaration: TslEnum, - override readonly isExplicitlyNullable: boolean, - ) { - super(declaration); - } - - override equals(other: unknown): boolean { - if (other === this) { - return true; - } else if (!(other instanceof EnumType)) { - return false; - } - - return other.declaration === this.declaration && other.isExplicitlyNullable === this.isExplicitlyNullable; - } - - override substituteTypeParameters(_substitutions: TypeParameterSubstitutions): Type { - return this; - } - - override withExplicitNullability(isExplicitlyNullable: boolean): EnumType { - if (this.isExplicitlyNullable === isExplicitlyNullable) { - return this; - } - - return new EnumType(this.declaration, isExplicitlyNullable); - } -} - -export class EnumVariantType extends NamedType { - override readonly isFullySubstituted = true; - - constructor( - declaration: TslEnumVariant, - override readonly isExplicitlyNullable: boolean, - ) { - super(declaration); - } - - override equals(other: unknown): boolean { - if (other === this) { - return true; - } else if (!(other instanceof EnumVariantType)) { - return false; - } - - return other.declaration === this.declaration && other.isExplicitlyNullable === this.isExplicitlyNullable; - } - - override substituteTypeParameters(_substitutions: TypeParameterSubstitutions): Type { - return this; - } - - override toString(): string { - const containingEnum = AstUtils.getContainerOfType(this.declaration, isTslEnum); - if (containingEnum) { - return `${containingEnum.name}.${super.toString()}`; - } else { - /* c8 ignore next 2 */ - return super.toString(); - } - } - - override withExplicitNullability(isExplicitlyNullable: boolean): EnumVariantType { - if (this.isExplicitlyNullable === isExplicitlyNullable) { - return this; - } - - return new EnumVariantType(this.declaration, isExplicitlyNullable); - } -} - -export class TypeParameterType extends NamedType { - override readonly isFullySubstituted = false; - - constructor( - declaration: TslTypeParameter, - override readonly isExplicitlyNullable: boolean, - ) { - super(declaration); - } - - override equals(other: unknown): boolean { - if (other === this) { - return true; - } else if (!(other instanceof TypeParameterType)) { - return false; - } - - return other.declaration === this.declaration && other.isExplicitlyNullable === this.isExplicitlyNullable; - } - - override substituteTypeParameters(substitutions: TypeParameterSubstitutions): Type { - const substitution = substitutions.get(this.declaration); - - if (!substitution) { - return this; - } else if (this.isExplicitlyNullable) { - return substitution.withExplicitNullability(true); - } else { - return substitution; - } - } - - override withExplicitNullability(isExplicitlyNullable: boolean): TypeParameterType { - if (this.isExplicitlyNullable === isExplicitlyNullable) { - return this; - } - - return new TypeParameterType(this.declaration, isExplicitlyNullable); - } -} - -/** - * A type that represents an actual named type declaration instead of an instance of it. - */ -export class StaticType extends Type { - private readonly factory: SafeDsTypeFactory; - - override readonly isExplicitlyNullable = false; - override readonly isFullySubstituted = true; - - constructor( - services: SafeDsServices, - readonly instanceType: NamedType, - ) { - super(); - - this.factory = services.types.TypeFactory; - } - - override equals(other: unknown): boolean { - if (other === this) { - return true; - } else if (!(other instanceof StaticType)) { - return false; - } - - return other.instanceType.equals(this.instanceType); - } - - override toString(): string { - return `$type<${this.instanceType}>`; - } - - override simplify(): Type { - return this; - } - - override substituteTypeParameters(_substitutions: TypeParameterSubstitutions): StaticType { - // The substitutions are only meaningful for instances of a declaration, not for the declaration itself. Hence, - // we don't substitute anything here. - return this; - } - - override withExplicitNullability(isExplicitlyNullable: boolean): Type { - if (!isExplicitlyNullable) { - return this; - } - - return this.factory.createUnionType(this, this.factory.createLiteralType(NullConstant)); - } -} - -export class UnionType extends Type { - private readonly coreTypes: SafeDsCoreTypes; - private readonly factory: SafeDsTypeFactory; - private readonly typeChecker: SafeDsTypeChecker; - - readonly types: Type[]; - private _isExplicitlyNullable: boolean | undefined; - private _isFullySubstituted: boolean | undefined; - - constructor(services: SafeDsServices, types: Type[]) { - super(); - - this.coreTypes = services.types.CoreTypes; - this.factory = services.types.TypeFactory; - this.typeChecker = services.types.TypeChecker; - - this.types = types; - } - - override get isExplicitlyNullable(): boolean { - if (this._isExplicitlyNullable === undefined) { - this._isExplicitlyNullable = this.types.some((it) => it.isExplicitlyNullable); - } - - return this._isExplicitlyNullable; - } - - override get isFullySubstituted(): boolean { - if (this._isFullySubstituted === undefined) { - this._isFullySubstituted = this.types.every((it) => it.isFullySubstituted); - } - - return this._isFullySubstituted; - } - - override equals(other: unknown): boolean { - if (other === this) { - return true; - } else if (!(other instanceof UnionType)) { - return false; - } - - return this.types.length === other.types.length && this.types.every((type, i) => type.equals(other.types[i])); - } - - override toString(): string { - return `union<${this.types.join(', ')}>`; - } - - override simplify(): Type { - // Handle empty union types - if (isEmpty(this.types)) { - return this.coreTypes.Nothing; - } - - // Flatten nested unions - const newTypes = this.types.flatMap((type) => { - const unwrappedType = type.simplify(); - if (unwrappedType instanceof UnionType) { - return unwrappedType.types; - } else { - return unwrappedType; - } - }); - - // Merge literal types and remove types that are subtypes of others. We do this back-to-front to keep the first - // occurrence of duplicate types. It's also makes splicing easier. - for (let i = newTypes.length - 1; i >= 0; i--) { - const currentType = newTypes[i]!; - const currentTypeIsNothingOrNull = currentType.equals(this.coreTypes.NothingOrNull); - - for (let j = newTypes.length - 1; j >= 0; j--) { - if (i === j) { - continue; - } - - const otherType = newTypes[j]!; - - // Remove identical types - if (currentType.equals(otherType)) { - // Remove the current type - newTypes.splice(i, 1); - break; - } - - // Don't merge `Nothing?` into callable types, named tuple types or static types, since that would - // create another union type. - if ( - currentTypeIsNothingOrNull && - (otherType instanceof CallableType || - otherType instanceof NamedTupleType || - otherType instanceof StaticType) - ) { - continue; - } - - // Merge literal types - if (currentType instanceof LiteralType && otherType instanceof LiteralType) { - // Other type always occurs before current type - const newConstants = [...otherType.constants, ...currentType.constants]; - const newLiteralType = this.factory.createLiteralType(...newConstants).simplify(); - - // Replace the other type with the new literal type - newTypes.splice(j, 1, newLiteralType); - // Remove the current type - newTypes.splice(i, 1); - break; - } - - // Remove subtypes of other types - const candidateType = otherType.withExplicitNullability( - currentType.isExplicitlyNullable || otherType.isExplicitlyNullable, - ); - if (this.typeChecker.isSupertypeOf(candidateType, currentType)) { - // Replace the other type with the candidate type (updated nullability) - newTypes.splice(j, 1, candidateType); - // Remove the current type - newTypes.splice(i, 1); - break; - } - } - } - - if (newTypes.length === 1) { - return newTypes[0]!; - } else { - return this.factory.createUnionType(...newTypes); - } - } - - override substituteTypeParameters(substitutions: TypeParameterSubstitutions): UnionType { - if (isEmpty(substitutions) || this.isFullySubstituted) { - return this; - } - - return this.factory.createUnionType(...this.types.map((it) => it.substituteTypeParameters(substitutions))); - } - - override withExplicitNullability(isExplicitlyNullable: boolean): Type { - if (isEmpty(this.types)) { - return this.coreTypes.Nothing.withExplicitNullability(isExplicitlyNullable); - } - - if (this.isExplicitlyNullable && !isExplicitlyNullable) { - return this.factory.createUnionType(...this.types.map((it) => it.withExplicitNullability(false))); - } else if (!this.isExplicitlyNullable && isExplicitlyNullable) { - return this.factory.createUnionType(...this.types.map((it) => it.withExplicitNullability(true))); - } else { - return this; - } - } -} - class UnknownTypeClass extends Type { override readonly isExplicitlyNullable = false; override readonly isFullySubstituted = true; @@ -793,7 +274,7 @@ class UnknownTypeClass extends Type { return this; } - override substituteTypeParameters(_substitutions: TypeParameterSubstitutions): Type { + override substituteTypeParameters(_substitutions: ParameterSubstitutions): Type { return this; } @@ -803,24 +284,3 @@ class UnknownTypeClass extends Type { } export const UnknownType = new UnknownTypeClass(); - -// ------------------------------------------------------------------------------------------------- -// Helpers -// ------------------------------------------------------------------------------------------------- - -const substitutionsAreEqual = ( - a: Map | undefined, - b: Map | undefined, -): boolean => { - if (a?.size !== b?.size) { - return false; - } - - const aEntries = Array.from(a?.entries() ?? []); - const bEntries = Array.from(b?.entries() ?? []); - - return aEntries.every(([aEntry, aValue], i) => { - const [bEntry, bValue] = bEntries[i]!; - return aEntry === bEntry && aValue.equals(bValue); - }); -}; diff --git a/packages/ttsl-lang/src/language/validation/types.ts b/packages/ttsl-lang/src/language/validation/types.ts index 3796e5d1..14659579 100644 --- a/packages/ttsl-lang/src/language/validation/types.ts +++ b/packages/ttsl-lang/src/language/validation/types.ts @@ -15,7 +15,7 @@ import { } from '../generated/ast.js'; import { getArguments } from '../helpers/nodeProperties.js'; import { SafeDsServices } from '../safe-ds-module.js'; -import { ClassType, NamedTupleType, TypeParameterType, UnknownType } from '../typing/model.js'; +import {NamedTupleType, UnknownType } from '../typing/model.js'; export const CODE_TYPE_CALLABLE_RECEIVER = 'type/callable-receiver'; export const CODE_TYPE_MISMATCH = 'type/mismatch'; @@ -118,19 +118,6 @@ export const indexedAccessIndexMustHaveCorrectType = (services: SafeDsServices) code: CODE_TYPE_MISMATCH, }); } - } else if (receiverType instanceof ClassType || receiverType instanceof TypeParameterType) { - const mapType = typeComputer.computeMatchingSupertype(receiverType, coreClasses.Map); - if (mapType) { - const keyType = mapType.getTypeParameterTypeByIndex(0); - const indexType = typeComputer.computeType(node.index); - if (!typeChecker.isSubtypeOf(indexType, keyType)) { - accept('error', `Expected type '${keyType}' but got '${indexType}'.`, { - node, - property: 'index', - code: CODE_TYPE_MISMATCH, - }); - } - } } }; }; diff --git a/packages/ttsl-lang/src/language/workspace/safe-ds-package-manager.ts b/packages/ttsl-lang/src/language/workspace/safe-ds-package-manager.ts index d1944fdf..8ed1f35d 100644 --- a/packages/ttsl-lang/src/language/workspace/safe-ds-package-manager.ts +++ b/packages/ttsl-lang/src/language/workspace/safe-ds-package-manager.ts @@ -8,7 +8,8 @@ import { IndexManager, LangiumDocuments, } from 'langium'; -import { getPackageName, isPackagePrivate } from '../helpers/nodeProperties.js'; +import { getPackageName, isPackagePrivate, isPrivate } from '../helpers/nodeProperties.js'; +import { isTslDeclaration, isTslFunction } from '../generated/ast.js'; export class SafeDsPackageManager { private readonly astNodeLocator: AstNodeLocator; @@ -111,7 +112,7 @@ export class SafeDsPackageManager { } if (hideInternal) { - result = result.filter((it) => !isPackagePrivate(it.node) && !isPrivate(it.node)); + result = result.filter((it) => !isTslDeclaration(it.node) || (!isPackagePrivate(it.node) && !isPrivate(it.node))); } return result; From 7f02abb0e6f16d08f408b5fb1920f944ea05ba4a Mon Sep 17 00:00:00 2001 From: methr0 Date: Tue, 25 Jun 2024 15:45:11 +0200 Subject: [PATCH 082/183] clean up lsp --- .../lsp/safe-ds-call-hierarchy-provider.ts | 1 - .../lsp/safe-ds-document-symbol-provider.ts | 18 - .../src/language/lsp/safe-ds-formatter.ts | 517 +----------------- .../lsp/safe-ds-inlay-hint-provider.ts | 10 +- .../lsp/safe-ds-node-info-provider.ts | 18 +- .../lsp/safe-ds-node-kind-provider.ts | 49 +- .../lsp/safe-ds-semantic-token-provider.ts | 123 +---- .../lsp/safe-ds-signature-help-provider.ts | 8 +- .../lsp/safe-ds-type-hierarchy-provider.ts | 134 ----- 9 files changed, 26 insertions(+), 852 deletions(-) delete mode 100644 packages/ttsl-lang/src/language/lsp/safe-ds-type-hierarchy-provider.ts diff --git a/packages/ttsl-lang/src/language/lsp/safe-ds-call-hierarchy-provider.ts b/packages/ttsl-lang/src/language/lsp/safe-ds-call-hierarchy-provider.ts index 2d6ee832..9d9e9cc3 100644 --- a/packages/ttsl-lang/src/language/lsp/safe-ds-call-hierarchy-provider.ts +++ b/packages/ttsl-lang/src/language/lsp/safe-ds-call-hierarchy-provider.ts @@ -41,7 +41,6 @@ export class SafeDsCallHierarchyProvider extends AbstractCallHierarchyProvider { } { return { kind: this.nodeKindProvider.getSymbolKind(targetNode), - tags: this.nodeInfoProvider.getTags(targetNode), detail: this.nodeInfoProvider.getDetails(targetNode), }; } diff --git a/packages/ttsl-lang/src/language/lsp/safe-ds-document-symbol-provider.ts b/packages/ttsl-lang/src/language/lsp/safe-ds-document-symbol-provider.ts index 02308c39..36d8f79f 100644 --- a/packages/ttsl-lang/src/language/lsp/safe-ds-document-symbol-provider.ts +++ b/packages/ttsl-lang/src/language/lsp/safe-ds-document-symbol-provider.ts @@ -1,13 +1,7 @@ import { type AstNode, type LangiumDocument } from 'langium'; import type { DocumentSymbol } from 'vscode-languageserver'; import { - isTslAnnotation, - isTslAttribute, - isTslClass, - isTslEnumVariant, isTslFunction, - isTslPipeline, - isTslSegment, } from '../generated/ast.js'; import type { SafeDsServices } from '../safe-ds-module.js'; import type { SafeDsNodeInfoProvider } from './safe-ds-node-info-provider.js'; @@ -31,7 +25,6 @@ export class SafeDsDocumentSymbolProvider extends DefaultDocumentSymbolProvider { name: name ?? nameNode.text, kind: this.nodeKindProvider.getSymbolKind(node), - tags: this.nodeInfoProvider.getTags(node), detail: this.nodeInfoProvider.getDetails(node), range: cstNode.range, selectionRange: nameNode.range, @@ -46,12 +39,6 @@ export class SafeDsDocumentSymbolProvider extends DefaultDocumentSymbolProvider protected override getChildSymbols(document: LangiumDocument, node: AstNode): DocumentSymbol[] | undefined { if (this.isLeaf(node)) { return undefined; - } else if (isTslClass(node)) { - if (node.body) { - return super.getChildSymbols(document, node.body); - } else { - return undefined; - } } else { return super.getChildSymbols(document, node); } @@ -59,12 +46,7 @@ export class SafeDsDocumentSymbolProvider extends DefaultDocumentSymbolProvider private isLeaf(node: AstNode): boolean { return ( - isTslAnnotation(node) || - isTslAttribute(node) || - isTslEnumVariant(node) || isTslFunction(node) || - isTslPipeline(node) || - isTslSegment(node) ); } } diff --git a/packages/ttsl-lang/src/language/lsp/safe-ds-formatter.ts b/packages/ttsl-lang/src/language/lsp/safe-ds-formatter.ts index b60e57b0..08d11179 100644 --- a/packages/ttsl-lang/src/language/lsp/safe-ds-formatter.ts +++ b/packages/ttsl-lang/src/language/lsp/safe-ds-formatter.ts @@ -1,7 +1,6 @@ import { AstNode, CstNode, CstUtils, isAstNode } from 'langium'; import { last } from '../../helpers/collections.js'; import * as ast from '../generated/ast.js'; -import { getAnnotationCalls, getLiterals, getTypeArguments } from '../helpers/nodeProperties.js'; import { AbstractFormatter, Formatting, FormattingAction, FormattingActionOptions } from 'langium/lsp'; import indent = Formatting.indent; import newLine = Formatting.newLine; @@ -41,46 +40,8 @@ export class SafeDsFormatter extends AbstractFormatter { // ----------------------------------------------------------------------------- // Declarations // ----------------------------------------------------------------------------- - else if (ast.isTslAnnotation(node)) { - this.formatTslAnnotation(node); - } else if (ast.isTslAttribute(node)) { - this.formatTslAttribute(node); - } else if (ast.isTslClass(node)) { - this.formatTslClass(node); - } else if (ast.isTslParentTypeList(node)) { - this.formatTslParentTypeList(node); - } else if (ast.isTslClassBody(node)) { - this.formatTslClassBody(node); - } else if (ast.isTslEnum(node)) { - this.formatTslEnum(node); - } else if (ast.isTslEnumBody(node)) { - this.formatTslEnumBody(node); - } else if (ast.isTslEnumVariant(node)) { - this.formatTslEnumVariant(node); - } else if (ast.isTslFunction(node)) { + else if (ast.isTslFunction(node)) { this.formatTslFunction(node); - } else if (ast.isTslPipeline(node)) { - this.formatTslPipeline(node); - } else if (ast.isTslSegment(node)) { - this.formatTslSegment(node); - } - - // ----------------------------------------------------------------------------- - // Annotation calls - // ----------------------------------------------------------------------------- - else if (ast.isTslAnnotationCallList(node)) { - this.formatTslAnnotationCallList(node); - } else if (ast.isTslAnnotationCall(node)) { - this.formatTslAnnotationCall(node); - } - - // ----------------------------------------------------------------------------- - // Constraints - // ----------------------------------------------------------------------------- - else if (ast.isTslConstraintList(node)) { - this.formatTslConstraintList(node); - } else if (ast.isTslParameterBound(node)) { - this.formatTslParameterBound(node); } // ----------------------------------------------------------------------------- @@ -107,8 +68,6 @@ export class SafeDsFormatter extends AbstractFormatter { this.formatTslAssigneeList(node); } else if (ast.isTslPlaceholder(node)) { this.formatTslPlaceholder(node); - } else if (ast.isTslYield(node)) { - this.formatTslYield(node); } else if (ast.isTslExpressionStatement(node)) { this.formatTslExpressionStatement(node); } @@ -116,13 +75,7 @@ export class SafeDsFormatter extends AbstractFormatter { // ----------------------------------------------------------------------------- // Expressions // ----------------------------------------------------------------------------- - else if (ast.isTslBlockLambda(node)) { - this.formatTslBlockLambda(node); - } else if (ast.isTslBlockLambdaResult(node)) { - this.formatTslBlockLambdaResult(node); - } else if (ast.isTslExpressionLambda(node)) { - this.formatTslExpressionLambda(node); - } else if (ast.isTslInfixOperation(node)) { + else if (ast.isTslInfixOperation(node)) { this.formatTslInfixOperation(node); } else if (ast.isTslPrefixOperation(node)) { this.formatTslPrefixOperation(node); @@ -142,8 +95,6 @@ export class SafeDsFormatter extends AbstractFormatter { this.formatTslDictionary(node); } else if (ast.isTslDictionaryEntry(node)) { this.formatTslDictionaryEntry(node); - } else if (ast.isTslParenthesizedExpression(node)) { - this.formatTslParenthesizedExpression(node); } else if (ast.isTslTemplateStringStart(node)) { this.formatTslTemplateStringStart(node); } else if (ast.isTslTemplateStringInner(node)) { @@ -161,34 +112,7 @@ export class SafeDsFormatter extends AbstractFormatter { this.formatTslMemberType(node); } else if (ast.isTslCallableType(node)) { this.formatTslCallableType(node); - } else if (ast.isTslLiteralType(node)) { - this.formatTslLiteralType(node); - } else if (ast.isTslLiteralList(node)) { - this.formatTslLiteralList(node); - } else if (ast.isTslNamedType(node)) { - this.formatTslNamedType(node); - } else if (ast.isTslUnionType(node)) { - this.formatTslUnionType(node); - } else if (ast.isTslTypeParameterList(node)) { - this.formatTslTypeParameterList(node); - } else if (ast.isTslTypeParameter(node)) { - this.formatTslTypeParameter(node); - } else if (ast.isTslTypeArgumentList(node)) { - this.formatTslTypeArgumentList(node); - } else if (ast.isTslTypeArgument(node)) { - this.formatTslTypeArgument(node); - } - - // ----------------------------------------------------------------------------- - // Schemas - // ----------------------------------------------------------------------------- - else if (ast.isTslSchema(node)) { - this.formatTslSchema(node); - } else if (ast.isTslColumnList(node)) { - this.formatTslColumnList(node); - } else if (ast.isTslColumn(node)) { - this.formatTslColumn(node); - } + } } // ----------------------------------------------------------------------------- @@ -197,36 +121,18 @@ export class SafeDsFormatter extends AbstractFormatter { private formatTslModule(node: ast.TslModule): void { const formatter = this.getNodeFormatter(node); - const annotations = getAnnotationCalls(node); const name = node.name; const imports = node.imports; const members = node.members; - // Annotations - annotations.forEach((value, index) => { - if (index === 0) { - if (this.hasComment(value)) { - formatter.node(value).prepend(newLine()); - } else { - formatter.node(value).prepend(noSpace()); - } - } else { - formatter.node(value).prepend(newLines(1)); - } - }); - // Package - if (annotations.length === 0) { - const packageKeyword = formatter.keyword('package'); - const cstNodes = packageKeyword.nodes; + const packageKeyword = formatter.keyword('package'); + const cstNodes = packageKeyword.nodes; - if (cstNodes.length > 0 && this.hasComment(cstNodes[0])) { - packageKeyword.prepend(newLine()); - } else { - packageKeyword.prepend(noSpace()); - } + if (cstNodes.length > 0 && this.hasComment(cstNodes[0])) { + packageKeyword.prepend(newLine()); } else { - formatter.keyword('package').prepend(newLines(2)); + packageKeyword.prepend(noSpace()); } formatter.keyword('package').append(oneSpace()); formatter.keyword('.').surround(noSpace()); @@ -234,7 +140,7 @@ export class SafeDsFormatter extends AbstractFormatter { // Imports imports.forEach((value, index) => { if (index === 0) { - if (annotations.length === 0 && !name) { + if (!name) { if (this.hasComment(value)) { formatter.node(value).prepend(newLine()); } else { @@ -251,27 +157,17 @@ export class SafeDsFormatter extends AbstractFormatter { // Members members.forEach((value, index) => { if (index === 0) { - if (annotations.length === 0 && !name && imports.length === 0) { + if (!name && imports.length === 0) { if (this.hasComment(value)) { formatter.node(value).prepend(newLine()); } else { formatter.node(value).prepend(noSpace()); } - } else { - const valueAnnotations = getAnnotationCalls(value); - if (valueAnnotations.length > 0) { - formatter.node(valueAnnotations[0]!).prepend(newLines(2)); - } else { - formatter.node(value).prepend(newLines(2)); - } - } - } else { - const valueAnnotations = getAnnotationCalls(value); - if (valueAnnotations.length > 0) { - formatter.node(valueAnnotations[0]!).prepend(newLines(2)); } else { formatter.node(value).prepend(newLines(2)); } + } else { + formatter.node(value).prepend(newLines(2)); } }); } @@ -306,226 +202,13 @@ export class SafeDsFormatter extends AbstractFormatter { // Declarations // ----------------------------------------------------------------------------- - private formatTslAnnotation(node: ast.TslAnnotation): void { - const formatter = this.getNodeFormatter(node); - - if (getAnnotationCalls(node).length > 0) { - formatter.keyword('annotation').prepend(newLine()); - } - - formatter.property('name').prepend(oneSpace()); - formatter.property('parameterList').prepend(noSpace()); - formatter.property('constraintList').prepend(oneSpace()); - } - - private formatTslAttribute(node: ast.TslAttribute): void { - const formatter = this.getNodeFormatter(node); - - if (getAnnotationCalls(node).length > 0) { - if (node.isStatic) { - formatter.keyword('static').prepend(newLine()); - } else { - formatter.keyword('attr').prepend(newLine()); - } - } - - formatter.keyword('static').append(oneSpace()); - formatter.property('name').prepend(oneSpace()); - formatter.keyword(':').prepend(noSpace()).append(oneSpace()); - } - - private formatTslClass(node: ast.TslClass): void { - const formatter = this.getNodeFormatter(node); - - if (getAnnotationCalls(node).length > 0) { - formatter.keyword('class').prepend(newLine()); - } - - formatter.property('name').prepend(oneSpace()); - formatter.property('typeParameterList').prepend(noSpace()); - formatter.property('parameterList').prepend(noSpace()); - formatter.property('parentTypeList').prepend(oneSpace()); - formatter.property('constraintList').prepend(oneSpace()); - - if (node.constraintList) { - formatter.property('body').prepend(newLine()); - } else { - formatter.property('body').prepend(oneSpace()); - } - } - - formatTslParentTypeList(node: ast.TslParentTypeList): void { - const formatter = this.getNodeFormatter(node); - - formatter.keyword('sub').append(oneSpace()); - formatter.keywords(',').prepend(noSpace()).append(oneSpace()); - } - - private formatTslClassBody(node: ast.TslClassBody): void { - const formatter = this.getNodeFormatter(node); - - const members = node.members ?? []; - if (members.length === 0) { - formatter.keyword('{').append(noSpace()); - formatter.keyword('}').prepend(noSpace()); - } else { - members.forEach((value, index) => { - if (index === 0) { - formatter.node(value).prepend(indent()); - } else { - formatter.node(value).prepend(newLinesWithIndent(2)); - } - }); - formatter.keyword('}').prepend(newLine()); - } - } - - private formatTslEnum(node: ast.TslEnum): void { - const formatter = this.getNodeFormatter(node); - - if (getAnnotationCalls(node).length > 0) { - formatter.keyword('enum').prepend(newLine()); - } - - formatter.property('name').prepend(oneSpace()); - formatter.property('body').prepend(oneSpace()); - } - - private formatTslEnumBody(node: ast.TslEnumBody): void { - const formatter = this.getNodeFormatter(node); - - const variants = node.variants ?? []; - if (variants.length === 0) { - formatter.keyword('{').append(noSpace()); - formatter.keyword('}').prepend(noSpace()); - } else { - variants.forEach((value, index) => { - if (index === 0) { - formatter.node(value).prepend(indent()); - } else { - formatter.node(value).prepend(newLinesWithIndent(2)); - } - }); - formatter.keyword('}').prepend(newLine()); - } - } - - private formatTslEnumVariant(node: ast.TslEnumVariant): void { - const formatter = this.getNodeFormatter(node); - - const annotationCalls = getAnnotationCalls(node); - - formatter.nodes(...annotationCalls.slice(1)).prepend(newLine()); - - if (getAnnotationCalls(node).length > 0) { - formatter.property('name').prepend(newLine()); - } - - formatter.property('parameterList').prepend(noSpace()); - formatter.property('constraintList').prepend(oneSpace()); - } - formatTslFunction(node: ast.TslFunction): void { const formatter = this.getNodeFormatter(node); - if (getAnnotationCalls(node).length > 0) { - if (node.isStatic) { - formatter.keyword('static').prepend(newLine()); - } else { - formatter.keyword('fun').prepend(newLine()); - } - } - - formatter.keyword('static').append(oneSpace()); formatter.property('name').prepend(oneSpace()); formatter.property('visibility').prepend(noSpace()); formatter.property('parameterList').prepend(noSpace()); formatter.property('result').prepend(oneSpace()); - formatter.property('constraintList').prepend(oneSpace()); - } - - private formatTslPipeline(node: ast.TslPipeline): void { - const formatter = this.getNodeFormatter(node); - - formatter.property('annotationCallList').prepend(noSpace()); - - if (getAnnotationCalls(node).length > 0) { - formatter.keyword('pipeline').prepend(newLine()); - } - - formatter.property('name').prepend(oneSpace()); - formatter.node(node.body).prepend(oneSpace()); - } - - private formatTslSegment(node: ast.TslSegment): void { - const formatter = this.getNodeFormatter(node); - - if (getAnnotationCalls(node).length === 0) { - if (node.visibility) { - formatter.keyword('segment').prepend(oneSpace()); - } - } else { - if (node.visibility) { - formatter.property('visibility').prepend(newLine()); - formatter.keyword('segment').prepend(oneSpace()); - } else { - formatter.keyword('segment').prepend(newLine()); - } - } - - formatter.property('name').prepend(oneSpace()); - formatter.property('parameterList').prepend(noSpace()); - formatter.property('resultList').prepend(oneSpace()); - formatter.property('constraintList').prepend(oneSpace()); - formatter.property('body').prepend(oneSpace()); - } - - // ----------------------------------------------------------------------------- - // Annotation calls - // ----------------------------------------------------------------------------- - - private formatTslAnnotationCallList(node: ast.TslAnnotationCallList): void { - const formatter = this.getNodeFormatter(node); - const annotationCalls = node.annotationCalls ?? []; - - formatter.nodes(...annotationCalls.slice(1)).prepend(newLine()); - } - - private formatTslAnnotationCall(node: ast.TslAnnotationCall): void { - const formatter = this.getNodeFormatter(node); - - formatter.keyword('@').append(noSpace()); - formatter.property('argumentList').prepend(noSpace()); - } - - // ----------------------------------------------------------------------------- - // Constraints - // ----------------------------------------------------------------------------- - - private formatTslConstraintList(node: ast.TslConstraintList) { - const formatter = this.getNodeFormatter(node); - - formatter.keyword('where').append(oneSpace()); - - const openingBrace = formatter.keyword('{'); - const closingBrace = formatter.keyword('}'); - - const constraints = node.constraints ?? []; - - if (constraints.length === 0) { - openingBrace.append(noSpace()); - closingBrace.prepend(noSpace()); - } else { - formatter.nodes(...constraints).prepend(indent()); - formatter.keywords(',').prepend(noSpace()); - closingBrace.prepend(newLine()); - } - } - - private formatTslParameterBound(node: ast.TslParameterBound) { - const formatter = this.getNodeFormatter(node); - - formatter.property('operator').surround(oneSpace()); } // ----------------------------------------------------------------------------- @@ -542,7 +225,7 @@ export class SafeDsFormatter extends AbstractFormatter { if ( parameters.length >= 3 || - parameters.some((it) => getAnnotationCalls(it).length > 0 || this.isComplexType(it.type)) + parameters.some((it) => this.isComplexType(it.type)) ) { formatter.nodes(...parameters).prepend(indent()); formatter.keywords(',').prepend(noSpace()); @@ -558,11 +241,6 @@ export class SafeDsFormatter extends AbstractFormatter { private formatTslParameter(node: ast.TslParameter): void { const formatter = this.getNodeFormatter(node); - const lastAnnotationCall = last(getAnnotationCalls(node)); - if (lastAnnotationCall) { - formatter.node(lastAnnotationCall).append(newLine()); - } - formatter.keyword('const').append(oneSpace()); formatter.keyword('vararg').append(oneSpace()); formatter.keyword(':').prepend(noSpace()).append(oneSpace()); @@ -581,7 +259,7 @@ export class SafeDsFormatter extends AbstractFormatter { if ( results.length >= 3 || - results.some((it) => getAnnotationCalls(it).length > 0 || this.isComplexType(it.type)) + results.some((it) => this.isComplexType(it.type)) ) { formatter.nodes(...results).prepend(indent()); formatter.keywords(',').prepend(noSpace()); @@ -597,10 +275,6 @@ export class SafeDsFormatter extends AbstractFormatter { private formatTslResult(node: ast.TslResult): void { const formatter = this.getNodeFormatter(node); - if (getAnnotationCalls(node).length > 0) { - formatter.property('name').prepend(newLine()); - } - formatter.keyword(':').prepend(noSpace()).append(oneSpace()); } @@ -641,13 +315,6 @@ export class SafeDsFormatter extends AbstractFormatter { formatter.keyword('val').append(oneSpace()); } - private formatTslYield(node: ast.TslYield) { - const formatter = this.getNodeFormatter(node); - - formatter.keyword('yield').append(oneSpace()); - formatter.property('result').prepend(oneSpace()); - } - private formatTslExpressionStatement(node: ast.TslExpressionStatement) { const formatter = this.getNodeFormatter(node); @@ -658,24 +325,6 @@ export class SafeDsFormatter extends AbstractFormatter { // Expressions // ----------------------------------------------------------------------------- - private formatTslBlockLambda(node: ast.TslBlockLambda): void { - const formatter = this.getNodeFormatter(node); - - formatter.property('body').prepend(oneSpace()); - } - - private formatTslBlockLambdaResult(node: ast.TslBlockLambdaResult) { - const formatter = this.getNodeFormatter(node); - - formatter.keyword('yield').append(oneSpace()); - } - - private formatTslExpressionLambda(node: ast.TslExpressionLambda) { - const formatter = this.getNodeFormatter(node); - - formatter.keyword('->').surround(oneSpace()); - } - private formatTslInfixOperation(node: ast.TslInfixOperation) { const formatter = this.getNodeFormatter(node); @@ -786,13 +435,6 @@ export class SafeDsFormatter extends AbstractFormatter { formatter.keyword(':').prepend(noSpace()).append(oneSpace()); } - private formatTslParenthesizedExpression(node: ast.TslParenthesizedExpression): void { - const formatter = this.getNodeFormatter(node); - - formatter.keyword('(').append(noSpace()); - formatter.keyword(')').prepend(noSpace()); - } - private formatTslTemplateStringStart(node: ast.TslTemplateStringStart) { const formatter = this.getNodeFormatter(node); @@ -843,94 +485,6 @@ export class SafeDsFormatter extends AbstractFormatter { formatter.keyword('->').surround(oneSpace()); } - private formatTslLiteralType(node: ast.TslLiteralType): void { - const formatter = this.getNodeFormatter(node); - - formatter.keyword('literal').append(noSpace()); - } - - private formatTslLiteralList(node: ast.TslLiteralList): void { - const formatter = this.getNodeFormatter(node); - const literals = node.literals ?? []; - - if (literals.length > 0) { - formatter.node(literals[0]!).prepend(noSpace()); - formatter.nodes(...literals.slice(1)).prepend(oneSpace()); - } - - formatter.keywords(',').prepend(noSpace()); - formatter.keyword('>').prepend(noSpace()); - } - - private formatTslNamedType(node: ast.TslNamedType) { - const formatter = this.getNodeFormatter(node); - - formatter.keyword('?').prepend(noSpace()); - formatter.property('typeArgumentList').prepend(noSpace()); - } - - private formatTslUnionType(node: ast.TslUnionType): void { - const formatter = this.getNodeFormatter(node); - - formatter.keyword('union').append(noSpace()); - } - - private formatTslTypeParameterList(node: ast.TslTypeParameterList): void { - const formatter = this.getNodeFormatter(node); - - const closingBracket = formatter.keyword('>'); - - const typeParameters = node.typeParameters ?? []; - - if (typeParameters.length >= 3 || typeParameters.some((it) => getAnnotationCalls(it).length > 0)) { - formatter.nodes(...typeParameters).prepend(indent()); - formatter.keywords(',').prepend(noSpace()); - closingBracket.prepend(newLine()); - } else { - if (typeParameters.length > 0) { - formatter.node(typeParameters[0]!).prepend(noSpace()); - formatter.nodes(...typeParameters.slice(1)).prepend(oneSpace()); - } - formatter.keywords(',').prepend(noSpace()); - closingBracket.prepend(noSpace()); - } - } - - private formatTslTypeParameter(node: ast.TslTypeParameter) { - const formatter = this.getNodeFormatter(node); - - if (getAnnotationCalls(node).length > 0) { - if (node.variance) { - formatter.property('variance').prepend(newLine()); - } else { - formatter.property('name').prepend(newLine()); - } - } - - formatter.property('variance').append(oneSpace()); - formatter.keyword('sub').surround(oneSpace()); - formatter.keyword('=').surround(oneSpace()); - } - - private formatTslTypeArgumentList(node: ast.TslTypeArgumentList): void { - const formatter = this.getNodeFormatter(node); - const typeArguments = node.typeArguments ?? []; - - if (typeArguments.length > 0) { - formatter.node(typeArguments[0]!).prepend(noSpace()); - formatter.nodes(...typeArguments.slice(1)).prepend(oneSpace()); - } - - formatter.keywords(',').prepend(noSpace()); - formatter.keyword('>').prepend(noSpace()); - } - - private formatTslTypeArgument(node: ast.TslTypeArgument) { - const formatter = this.getNodeFormatter(node); - - formatter.keyword('=').surround(oneSpace()); - } - /** * Returns whether the type is considered complex and requires special formatting like placing the associated * parameter on its own line. @@ -942,55 +496,14 @@ export class SafeDsFormatter extends AbstractFormatter { return false; } - if (ast.isTslCallableType(node) || ast.isTslMemberType(node)) { + if (ast.isTslCallableType(node)) { return true; - } else if (ast.isTslLiteralType(node)) { - return getLiterals(node).length > 0; - } else if (ast.isTslNamedType(node)) { - return getTypeArguments(node.typeArgumentList).length > 0; - } else if (ast.isTslUnionType(node)) { - return getTypeArguments(node.typeArgumentList).length > 0; } else { /* c8 ignore next 2 */ return false; } } - // ----------------------------------------------------------------------------- - // Schemas - // ----------------------------------------------------------------------------- - - private formatTslSchema(node: ast.TslSchema) { - const formatter = this.getNodeFormatter(node); - - if (getAnnotationCalls(node).length > 0) { - formatter.keyword('schema').prepend(newLine()); - } - - formatter.property('name').prepend(oneSpace()); - formatter.property('columnList').prepend(oneSpace()); - } - - private formatTslColumnList(node: ast.TslColumnList) { - const formatter = this.getNodeFormatter(node); - const columns = node.columns ?? []; - - if (columns.length === 0) { - formatter.keyword('{').append(noSpace()); - formatter.keyword('}').prepend(noSpace()); - } else { - formatter.nodes(...columns).prepend(indent()); - formatter.keywords(',').prepend(noSpace()); - formatter.keyword('}').prepend(newLine()); - } - } - - private formatTslColumn(node: ast.TslColumn) { - const formatter = this.getNodeFormatter(node); - - formatter.keyword(':').prepend(noSpace()).append(oneSpace()); - } - // ----------------------------------------------------------------------------- // Helpers // ----------------------------------------------------------------------------- diff --git a/packages/ttsl-lang/src/language/lsp/safe-ds-inlay-hint-provider.ts b/packages/ttsl-lang/src/language/lsp/safe-ds-inlay-hint-provider.ts index 0a005dfd..36b8aed8 100644 --- a/packages/ttsl-lang/src/language/lsp/safe-ds-inlay-hint-provider.ts +++ b/packages/ttsl-lang/src/language/lsp/safe-ds-inlay-hint-provider.ts @@ -1,11 +1,10 @@ import { AstNode, DocumentationProvider } from 'langium'; import { InlayHintKind, MarkupContent } from 'vscode-languageserver'; import { createMarkupContent } from '../documentation/safe-ds-comment-provider.js'; -import { isTslArgument, isTslBlockLambdaResult, isTslPlaceholder, isTslYield } from '../generated/ast.js'; +import { isTslArgument, isTslPlaceholder } from '../generated/ast.js'; import { Argument } from '../helpers/nodeProperties.js'; import { SafeDsNodeMapper } from '../helpers/safe-ds-node-mapper.js'; import { SafeDsServices } from '../safe-ds-module.js'; -import { NamedType } from '../typing/model.js'; import { SafeDsTypeComputer } from '../typing/safe-ds-type-computer.js'; import { AbstractInlayHintProvider, InlayHintAcceptor } from 'langium/lsp'; @@ -40,13 +39,10 @@ export class SafeDsInlayHintProvider extends AbstractInlayHintProvider { tooltip: createMarkupContent(this.documentationProvider.getDocumentation(parameter)), }); } - } else if (isTslBlockLambdaResult(node) || isTslPlaceholder(node) || isTslYield(node)) { + } else if (isTslPlaceholder(node)) { const type = this.typeComputer.computeType(node); let tooltip: MarkupContent | undefined = undefined; - if (type instanceof NamedType) { - tooltip = createMarkupContent(this.documentationProvider.getDocumentation(type.declaration)); - } - + acceptor({ position: cstNode.range.end, label: `: ${type}`, diff --git a/packages/ttsl-lang/src/language/lsp/safe-ds-node-info-provider.ts b/packages/ttsl-lang/src/language/lsp/safe-ds-node-info-provider.ts index b6e7415f..692306ed 100644 --- a/packages/ttsl-lang/src/language/lsp/safe-ds-node-info-provider.ts +++ b/packages/ttsl-lang/src/language/lsp/safe-ds-node-info-provider.ts @@ -1,7 +1,7 @@ import { AstNode } from 'langium'; import { SymbolTag } from 'vscode-languageserver'; import type { SafeDsAnnotations } from '../builtins/safe-ds-annotations.js'; -import { isTslAnnotatedObject, isTslAttribute, isTslFunction, isTslSegment } from '../generated/ast.js'; +import { isTslFunction } from '../generated/ast.js'; import type { SafeDsServices } from '../safe-ds-module.js'; import { SafeDsTypeComputer } from '../typing/safe-ds-type-computer.js'; @@ -19,24 +19,10 @@ export class SafeDsNodeInfoProvider { * hierarchies. */ getDetails(node: AstNode): string | undefined { - if (isTslAttribute(node)) { - return `: ${this.typeComputer.computeType(node)}`; - } else if (isTslFunction(node) || isTslSegment(node)) { + if (isTslFunction(node)) { return this.typeComputer.computeType(node)?.toString(); } else { return undefined; } } - - /** - * Returns the tags for the given node. This can be used, for example, to provide document symbols or call - * hierarchies. - */ - getTags(node: AstNode): SymbolTag[] | undefined { - if (isTslAnnotatedObject(node) && this.builtinAnnotations.callsDeprecated(node)) { - return [SymbolTag.Deprecated]; - } else { - return undefined; - } - } } diff --git a/packages/ttsl-lang/src/language/lsp/safe-ds-node-kind-provider.ts b/packages/ttsl-lang/src/language/lsp/safe-ds-node-kind-provider.ts index b41ed191..c6dcca07 100644 --- a/packages/ttsl-lang/src/language/lsp/safe-ds-node-kind-provider.ts +++ b/packages/ttsl-lang/src/language/lsp/safe-ds-node-kind-provider.ts @@ -1,49 +1,19 @@ -import { AstNode, AstNodeDescription, AstUtils, isAstNode } from 'langium'; +import { AstNode, AstNodeDescription, isAstNode } from 'langium'; import { CompletionItemKind, SymbolKind } from 'vscode-languageserver'; import { - isTslClass, - isTslFunction, - TslAnnotation, - TslAttribute, - TslBlockLambdaResult, - TslClass, - TslEnum, - TslEnumVariant, TslFunction, TslModule, TslParameter, - TslPipeline, TslPlaceholder, TslResult, - TslSchema, - TslSegment, - TslTypeParameter, } from '../generated/ast.js'; import { NodeKindProvider } from 'langium/lsp'; export class SafeDsNodeKindProvider implements NodeKindProvider { getSymbolKind(nodeOrDescription: AstNode | AstNodeDescription): SymbolKind { // The WorkspaceSymbolProvider only passes descriptions, where the node might be undefined - const node = this.getNode(nodeOrDescription); - if (isTslFunction(node) && AstUtils.hasContainerOfType(node, isTslClass)) { - return SymbolKind.Method; - } - const type = this.getNodeType(nodeOrDescription); switch (type) { - case TslAnnotation: - return SymbolKind.Interface; - case TslAttribute: - return SymbolKind.Property; - /* c8 ignore next 2 */ - case TslBlockLambdaResult: - return SymbolKind.Variable; - case TslClass: - return SymbolKind.Class; - case TslEnum: - return SymbolKind.Enum; - case TslEnumVariant: - return SymbolKind.EnumMember; case TslFunction: return SymbolKind.Function; case TslModule: @@ -51,21 +21,12 @@ export class SafeDsNodeKindProvider implements NodeKindProvider { /* c8 ignore next 2 */ case TslParameter: return SymbolKind.Variable; - case TslPipeline: - return SymbolKind.Function; /* c8 ignore next 2 */ case TslPlaceholder: return SymbolKind.Variable; /* c8 ignore next 2 */ case TslResult: return SymbolKind.Variable; - case TslSchema: - return SymbolKind.Struct; - case TslSegment: - return SymbolKind.Function; - /* c8 ignore next 2 */ - case TslTypeParameter: - return SymbolKind.TypeParameter; /* c8 ignore next 2 */ default: return SymbolKind.Null; @@ -79,14 +40,6 @@ export class SafeDsNodeKindProvider implements NodeKindProvider { /* c8 ignore stop */ - private getNode(nodeOrDescription: AstNode | AstNodeDescription): AstNode | undefined { - if (isAstNode(nodeOrDescription)) { - return nodeOrDescription; - } /* c8 ignore start */ else { - return nodeOrDescription.node; - } /* c8 ignore stop */ - } - private getNodeType(nodeOrDescription: AstNode | AstNodeDescription): string { if (isAstNode(nodeOrDescription)) { return nodeOrDescription.$type; diff --git a/packages/ttsl-lang/src/language/lsp/safe-ds-semantic-token-provider.ts b/packages/ttsl-lang/src/language/lsp/safe-ds-semantic-token-provider.ts index 29f98b7e..e0471362 100644 --- a/packages/ttsl-lang/src/language/lsp/safe-ds-semantic-token-provider.ts +++ b/packages/ttsl-lang/src/language/lsp/safe-ds-semantic-token-provider.ts @@ -3,30 +3,16 @@ import { AstNode, AstUtils } from 'langium'; import { SemanticTokenModifiers, SemanticTokenTypes } from 'vscode-languageserver'; import { SafeDsClasses } from '../builtins/safe-ds-classes.js'; import { - isTslAnnotation, - isTslAnnotationCall, isTslArgument, - isTslAttribute, - isTslClass, isTslDeclaration, - isTslEnum, - isTslEnumVariant, isTslFunction, isTslImport, isTslImportedDeclaration, isTslModule, - isTslNamedType, isTslParameter, - isTslParameterBound, - isTslPipeline, isTslPlaceholder, isTslReference, isTslResult, - isTslSchema, - isTslSegment, - isTslTypeArgument, - isTslTypeParameter, - isTslYield, } from '../generated/ast.js'; import { SafeDsServices } from '../safe-ds-module.js'; @@ -40,18 +26,7 @@ export class SafeDsSemanticTokenProvider extends AbstractSemanticTokenProvider { } protected highlightElement(node: AstNode, acceptor: SemanticTokenAcceptor): void { - if (isTslAnnotationCall(node)) { - acceptor({ - node, - keyword: '@', - type: SemanticTokenTypes.decorator, - }); - acceptor({ - node, - property: 'annotation', - type: SemanticTokenTypes.decorator, - }); - } else if (isTslArgument(node)) { + if (isTslArgument(node)) { if (node.parameter) { acceptor({ node, @@ -83,21 +58,6 @@ export class SafeDsSemanticTokenProvider extends AbstractSemanticTokenProvider { ...info, }); } - } else if (isTslNamedType(node)) { - const info = this.computeSemanticTokenInfoForDeclaration(node.declaration?.ref); - if (info) { - acceptor({ - node, - property: 'declaration', - ...info, - }); - } - } else if (isTslParameterBound(node)) { - acceptor({ - node, - property: 'leftOperand', - type: SemanticTokenTypes.parameter, - }); } else if (isTslReference(node)) { const info = this.computeSemanticTokenInfoForDeclaration(node.target.ref); if (info) { @@ -107,21 +67,6 @@ export class SafeDsSemanticTokenProvider extends AbstractSemanticTokenProvider { ...info, }); } - } else if (isTslTypeArgument(node)) { - if (node.typeParameter) { - acceptor({ - node, - property: 'typeParameter', - type: SemanticTokenTypes.typeParameter, - }); - } - } else if (isTslYield(node)) { - // For lack of a better option, we use the token type for parameters here - acceptor({ - node, - property: 'result', - type: SemanticTokenTypes.parameter, - }); } } @@ -135,53 +80,11 @@ export class SafeDsSemanticTokenProvider extends AbstractSemanticTokenProvider { } /* c8 ignore stop */ - if (isTslAnnotation(node)) { - return { - type: SemanticTokenTypes.decorator, - modifier: additionalModifiers, - }; - } else if (isTslAttribute(node)) { - const modifier = [SemanticTokenModifiers.readonly, ...additionalModifiers]; - if (node.isStatic) { - modifier.push(SemanticTokenModifiers.static); - } - - return { - type: SemanticTokenTypes.property, - modifier, - }; - } else if (isTslClass(node)) { - const isBuiltinClass = this.builtinClasses.isBuiltinClass(node); - return { - type: SemanticTokenTypes.class, - modifier: isBuiltinClass - ? [SemanticTokenModifiers.defaultLibrary, ...additionalModifiers] - : additionalModifiers, - }; - } else if (isTslEnum(node)) { - return { - type: SemanticTokenTypes.enum, - modifier: additionalModifiers, - }; - } else if (isTslEnumVariant(node)) { + if (isTslFunction(node)) { return { - type: SemanticTokenTypes.enumMember, + type: SemanticTokenTypes.function, modifier: additionalModifiers, }; - } else if (isTslFunction(node)) { - if (AstUtils.hasContainerOfType(node, isTslClass)) { - return { - type: SemanticTokenTypes.method, - modifier: node.isStatic - ? [SemanticTokenModifiers.static, ...additionalModifiers] - : additionalModifiers, - }; - } else { - return { - type: SemanticTokenTypes.function, - modifier: additionalModifiers, - }; - } } else if (isTslModule(node)) { return { type: SemanticTokenTypes.namespace, @@ -192,11 +95,6 @@ export class SafeDsSemanticTokenProvider extends AbstractSemanticTokenProvider { type: SemanticTokenTypes.parameter, modifier: additionalModifiers, }; - } else if (isTslPipeline(node)) { - return { - type: SemanticTokenTypes.function, - modifier: additionalModifiers, - }; } else if (isTslPlaceholder(node)) { return { type: SemanticTokenTypes.variable, @@ -208,21 +106,6 @@ export class SafeDsSemanticTokenProvider extends AbstractSemanticTokenProvider { type: SemanticTokenTypes.parameter, modifier: additionalModifiers, }; - } else if (isTslSchema(node)) { - return { - type: SemanticTokenTypes.type, - modifier: additionalModifiers, - }; - } else if (isTslSegment(node)) { - return { - type: SemanticTokenTypes.function, - modifier: additionalModifiers, - }; - } else if (isTslTypeParameter(node)) { - return { - type: SemanticTokenTypes.typeParameter, - modifier: additionalModifiers, - }; } } } diff --git a/packages/ttsl-lang/src/language/lsp/safe-ds-signature-help-provider.ts b/packages/ttsl-lang/src/language/lsp/safe-ds-signature-help-provider.ts index 7421fe92..a8a627d8 100644 --- a/packages/ttsl-lang/src/language/lsp/safe-ds-signature-help-provider.ts +++ b/packages/ttsl-lang/src/language/lsp/safe-ds-signature-help-provider.ts @@ -20,7 +20,7 @@ import { getParameters, Parameter } from '../helpers/nodeProperties.js'; import { type SafeDsNodeMapper } from '../helpers/safe-ds-node-mapper.js'; import type { SafeDsServices } from '../safe-ds-module.js'; import { type SafeDsTypeComputer } from '../typing/safe-ds-type-computer.js'; -import { CallableType, NamedType } from '../typing/model.js'; +import { CallableType } from '../typing/model.js'; import { SignatureHelpProvider } from 'langium/lsp'; export class SafeDsSignatureHelpProvider implements SignatureHelpProvider { @@ -90,11 +90,7 @@ export class SafeDsSignatureHelpProvider implements SignatureHelpProvider { private getLabel(callable: TslCallable): string { const type = this.typeComputer.computeType(callable); - if (type instanceof NamedType) { - return `${type.declaration.name}(${getParameters(callable) - .map((it) => this.getParameterLabel(it)) - .join(', ')})`; - } else if (type instanceof CallableType && isNamed(callable)) { + if (type instanceof CallableType && isNamed(callable)) { return `${callable.name}${type}`; } else { return type.toString(); diff --git a/packages/ttsl-lang/src/language/lsp/safe-ds-type-hierarchy-provider.ts b/packages/ttsl-lang/src/language/lsp/safe-ds-type-hierarchy-provider.ts deleted file mode 100644 index ef53bd44..00000000 --- a/packages/ttsl-lang/src/language/lsp/safe-ds-type-hierarchy-provider.ts +++ /dev/null @@ -1,134 +0,0 @@ -import { type AstNode, AstUtils, CstUtils, type ReferenceDescription, stream, type Stream } from 'langium'; -import { type TypeHierarchyItem } from 'vscode-languageserver'; -import { - isTslClass, - isTslEnum, - isTslEnumVariant, - isTslParentTypeList, - TslClass, - TslEnum, - TslEnumVariant, -} from '../generated/ast.js'; -import type { SafeDsServices } from '../safe-ds-module.js'; -import { SafeDsClassHierarchy } from '../typing/safe-ds-class-hierarchy.js'; -import { SafeDsNodeInfoProvider } from './safe-ds-node-info-provider.js'; -import { getEnumVariants } from '../helpers/nodeProperties.js'; -import { AbstractTypeHierarchyProvider, type NodeKindProvider } from 'langium/lsp'; - -export class SafeDsTypeHierarchyProvider extends AbstractTypeHierarchyProvider { - private readonly classHierarchy: SafeDsClassHierarchy; - private readonly nodeKindProvider: NodeKindProvider; - private readonly nodeInfoProvider: SafeDsNodeInfoProvider; - - constructor(services: SafeDsServices) { - super(services); - this.classHierarchy = services.types.ClassHierarchy; - this.nodeKindProvider = services.shared.lsp.NodeKindProvider; - this.nodeInfoProvider = services.lsp.NodeInfoProvider; - } - - protected override getTypeHierarchyItem(targetNode: AstNode): Partial | undefined { - { - return { - kind: this.nodeKindProvider.getSymbolKind(targetNode), - tags: this.nodeInfoProvider.getTags(targetNode), - detail: this.nodeInfoProvider.getDetails(targetNode), - }; - } - } - - protected override getSupertypes(node: AstNode): TypeHierarchyItem[] | undefined { - if (isTslClass(node)) { - return this.getSupertypesOfClass(node); - } else if (isTslEnumVariant(node)) { - return this.getSupertypesOfEnumVariant(node); - } else { - return undefined; - } - } - - private getSupertypesOfClass(node: TslClass): TypeHierarchyItem[] | undefined { - const parentClass = this.classHierarchy.streamProperSuperclasses(node).head(); - if (!parentClass) { - /* c8 ignore next 2 */ - return undefined; - } - - return this.getTypeHierarchyItems(parentClass, AstUtils.getDocument(parentClass)); - } - - private getSupertypesOfEnumVariant(node: TslEnumVariant): TypeHierarchyItem[] | undefined { - const containingEnum = AstUtils.getContainerOfType(node, isTslEnum); - if (!containingEnum) { - /* c8 ignore next 2 */ - return undefined; - } - - return this.getTypeHierarchyItems(containingEnum, AstUtils.getDocument(containingEnum)); - } - - protected override getSubtypes(node: AstNode): TypeHierarchyItem[] | undefined { - const references = this.references.findReferences(node, { - includeDeclaration: false, - }); - - let items: TypeHierarchyItem[]; - - if (isTslClass(node)) { - items = this.getSubtypesOfClass(references); - } else if (isTslEnum(node)) { - items = this.getSubtypesOfEnum(node); - } else { - return undefined; - } - - return items.length === 0 ? undefined : items; - } - - private getSubtypesOfClass(references: Stream): TypeHierarchyItem[] { - return references - .flatMap((it) => { - const document = this.documents.getDocument(it.sourceUri); - if (!document) { - /* c8 ignore next 2 */ - return []; - } - - const rootNode = document.parseResult.value; - if (!rootNode.$cstNode) { - /* c8 ignore next 2 */ - return []; - } - - const targetCstNode = CstUtils.findLeafNodeAtOffset(rootNode.$cstNode, it.segment.offset); - if (!targetCstNode) { - /* c8 ignore next 2 */ - return []; - } - - // Only consider the first parent type - const targetNode = targetCstNode.astNode; - if (!isTslParentTypeList(targetNode.$container) || targetNode.$containerIndex !== 0) { - return []; - } - - const containingClass = AstUtils.getContainerOfType(targetNode, isTslClass); - if (!containingClass) { - /* c8 ignore next 2 */ - return []; - } - - return this.getTypeHierarchyItems(containingClass, document) ?? []; - }) - .toArray(); - } - - private getSubtypesOfEnum(node: TslEnum): TypeHierarchyItem[] { - const variants = getEnumVariants(node); - const document = AstUtils.getDocument(node); - - return stream(variants) - .flatMap((it) => this.getTypeHierarchyItems(it, document) ?? []) - .toArray(); - } -} From e7d34b97918477ee8583de89dc7797d47a63f57f Mon Sep 17 00:00:00 2001 From: methr0 Date: Tue, 25 Jun 2024 15:46:01 +0200 Subject: [PATCH 083/183] fix build error --- .../src/language/lsp/safe-ds-document-symbol-provider.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/ttsl-lang/src/language/lsp/safe-ds-document-symbol-provider.ts b/packages/ttsl-lang/src/language/lsp/safe-ds-document-symbol-provider.ts index 36d8f79f..4a5ee166 100644 --- a/packages/ttsl-lang/src/language/lsp/safe-ds-document-symbol-provider.ts +++ b/packages/ttsl-lang/src/language/lsp/safe-ds-document-symbol-provider.ts @@ -46,7 +46,7 @@ export class SafeDsDocumentSymbolProvider extends DefaultDocumentSymbolProvider private isLeaf(node: AstNode): boolean { return ( - isTslFunction(node) || + isTslFunction(node) ); } } From e7f29b543214c85d2161f19c603ef4adad314ac5 Mon Sep 17 00:00:00 2001 From: methr0 Date: Tue, 25 Jun 2024 15:51:32 +0200 Subject: [PATCH 084/183] remove unnecessary code --- packages/ttsl-lang/src/language/safe-ds-module.ts | 2 -- 1 file changed, 2 deletions(-) diff --git a/packages/ttsl-lang/src/language/safe-ds-module.ts b/packages/ttsl-lang/src/language/safe-ds-module.ts index 747bc104..3f5db0a6 100644 --- a/packages/ttsl-lang/src/language/safe-ds-module.ts +++ b/packages/ttsl-lang/src/language/safe-ds-module.ts @@ -25,7 +25,6 @@ import { SafeDsNodeInfoProvider } from './lsp/safe-ds-node-info-provider.js'; import { SafeDsNodeKindProvider } from './lsp/safe-ds-node-kind-provider.js'; import { SafeDsSemanticTokenProvider } from './lsp/safe-ds-semantic-token-provider.js'; import { SafeDsSignatureHelpProvider } from './lsp/safe-ds-signature-help-provider.js'; -import { SafeDsTypeHierarchyProvider } from './lsp/safe-ds-type-hierarchy-provider.js'; import { SafeDsPartialEvaluator } from './partialEvaluation/safe-ds-partial-evaluator.js'; import { SafeDsScopeComputation } from './scoping/safe-ds-scope-computation.js'; import { SafeDsScopeProvider } from './scoping/safe-ds-scope-provider.js'; @@ -126,7 +125,6 @@ export const SafeDsModule: Module new SafeDsRenameProvider(services), SemanticTokenProvider: (services) => new SafeDsSemanticTokenProvider(services), SignatureHelp: (services) => new SafeDsSignatureHelpProvider(services), - TypeHierarchyProvider: (services) => new SafeDsTypeHierarchyProvider(services), }, parser: { ValueConverter: () => new SafeDsValueConverter(), From 33819381da88acbf76295ac79aeba2b64af9ee53 Mon Sep 17 00:00:00 2001 From: methr0 Date: Tue, 25 Jun 2024 15:51:54 +0200 Subject: [PATCH 085/183] fix build errors in python generator --- .../language/generation/safe-ds-python-generator.ts | 13 +++---------- 1 file changed, 3 insertions(+), 10 deletions(-) diff --git a/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts b/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts index 12e8c5c8..9777861b 100644 --- a/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts +++ b/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts @@ -1,4 +1,4 @@ -import { AstNode, AstUtils, LangiumDocument, TreeStreamImpl, URI } from 'langium'; +import {AstUtils, LangiumDocument, TreeStreamImpl, URI } from 'langium'; import { CompositeGeneratorNode, expandToNode, @@ -17,10 +17,8 @@ import { TextDocument } from 'vscode-languageserver-textdocument'; import { groupBy, isEmpty } from '../../helpers/collections.js'; import { SafeDsAnnotations } from '../builtins/safe-ds-annotations.js'; import { - isTslAbstractCall, isTslAssignment, isTslCall, - isTslCallable, isTslDeclaration, isTslExpressionStatement, isTslFunction, @@ -72,9 +70,7 @@ import { isTslExpression, } from '../generated/ast.js'; import { isInStubFile, isStubFile } from '../helpers/fileExtensions.js'; -import { IdManager } from '../helpers/idManager.js'; import { - getAbstractResults, getArguments, getAssignees, getImportedDeclarations, @@ -82,9 +78,9 @@ import { getModuleMembers, getParameters, getPlaceholderByName, + getResults, getStatements, Parameter, - streamBlockLambdaResults, } from '../helpers/nodeProperties.js'; import { SafeDsNodeMapper } from '../helpers/safe-ds-node-mapper.js'; import { @@ -100,9 +96,6 @@ import { SafeDsPurityComputer } from '../purity/safe-ds-purity-computer.js'; import { FileRead, ImpurityReason } from '../purity/model.js'; export const CODEGEN_PREFIX = '__gen_'; -const BLOCK_LAMBDA_PREFIX = `${CODEGEN_PREFIX}block_lambda_`; -const BLOCK_LAMBDA_RESULT_PREFIX = `${CODEGEN_PREFIX}block_lambda_result_`; -const YIELD_PREFIX = `${CODEGEN_PREFIX}yield_`; const RUNNER_PACKAGE = 'safeds_runner'; const PYTHON_INDENT = ' '; @@ -879,7 +872,7 @@ export class SafeDsPythonGenerator { frame: GenerationInfoFrame, ): CompositeGeneratorNode { const requiredAssignees = isTslCall(assignment.expression) - ? getAbstractResults(this.nodeMapper.callToCallable(assignment.expression)).length + ? getResults(this.nodeMapper.callToCallable(assignment.expression)).length : /* c8 ignore next */ 1; const assignees = getAssignees(assignment); From 53ff930fa2ba3effe0e06caae78c1332b37619b7 Mon Sep 17 00:00:00 2001 From: methr0 Date: Tue, 25 Jun 2024 15:56:04 +0200 Subject: [PATCH 086/183] remove unneccesarry purity computer --- .../language/purity/safe-ds-purity-computer.ts | 17 ++--------------- 1 file changed, 2 insertions(+), 15 deletions(-) diff --git a/packages/ttsl-lang/src/language/purity/safe-ds-purity-computer.ts b/packages/ttsl-lang/src/language/purity/safe-ds-purity-computer.ts index 3d19733c..4606f07a 100644 --- a/packages/ttsl-lang/src/language/purity/safe-ds-purity-computer.ts +++ b/packages/ttsl-lang/src/language/purity/safe-ds-purity-computer.ts @@ -12,16 +12,11 @@ import { UnknownCallableCall, } from './model.js'; import { - isTslAnnotation, isTslAssignment, isTslCallable, - isTslClass, - isTslEnumVariant, isTslExpressionStatement, isTslFunction, - isTslLambda, isTslParameter, - isTslWildcard, TslCall, TslCallable, TslExpression, @@ -93,10 +88,7 @@ export class SafeDsPurityComputer { isPureParameter(node: TslParameter | undefined): boolean { const containingCallable = AstUtils.getContainerOfType(node, isTslCallable); if ( - !containingCallable || - isTslAnnotation(containingCallable) || - isTslClass(containingCallable) || - isTslEnumVariant(containingCallable) + !containingCallable ) { return true; } else if (isTslFunction(containingCallable)) { @@ -151,7 +143,6 @@ export class SafeDsPurityComputer { statementDoesSomething(node: TslStatement, substitutions = NO_SUBSTITUTIONS): boolean { if (isTslAssignment(node)) { return ( - !getAssignees(node).every(isTslWildcard) || this.expressionHasSideEffects(node.expression, substitutions) ); } else if (isTslExpressionStatement(node)) { @@ -263,11 +254,7 @@ export class SafeDsPurityComputer { } private getExecutedCallsInExpression(expression: TslExpression | undefined): TslCall[] { - return this.callGraphComputer.getAllContainedCalls(expression).filter((it) => { - // Keep only calls that are not contained in a lambda inside the expression - const containingLambda = AstUtils.getContainerOfType(it, isTslLambda); - return !containingLambda || !isContainedInOrEqual(containingLambda, expression); - }); + return this.callGraphComputer.getAllContainedCalls(expression); } private getImpurityReasonsForFunction(node: TslFunction): Stream { From 8838880b37d5e2f177921a5ef4f4ce122970f0e1 Mon Sep 17 00:00:00 2001 From: methr0 Date: Tue, 25 Jun 2024 15:57:29 +0200 Subject: [PATCH 087/183] remove unnecessary functions in call graph computer --- .../flow/safe-ds-call-graph-computer.ts | 43 +------------------ 1 file changed, 2 insertions(+), 41 deletions(-) diff --git a/packages/ttsl-lang/src/language/flow/safe-ds-call-graph-computer.ts b/packages/ttsl-lang/src/language/flow/safe-ds-call-graph-computer.ts index 686ad0b3..bdc082b6 100644 --- a/packages/ttsl-lang/src/language/flow/safe-ds-call-graph-computer.ts +++ b/packages/ttsl-lang/src/language/flow/safe-ds-call-graph-computer.ts @@ -1,25 +1,15 @@ import { AstNode, type AstNodeLocator, AstUtils, stream, WorkspaceCache } from 'langium'; import { - isTslBlockLambda, isTslCall, isTslCallable, - isTslClass, - isTslEnumVariant, - isTslExpressionLambda, isTslFunction, isTslParameter, - isTslSegment, TslArgument, - TslBlockLambda, TslCall, TslCallable, - TslClass, - TslEnumVariant, TslExpression, - TslExpressionLambda, TslFunction, TslParameter, - TslSegment, } from '../generated/ast.js'; import type { SafeDsNodeMapper } from '../helpers/safe-ds-node-mapper.js'; import type { SafeDsServices } from '../safe-ds-module.js'; @@ -156,9 +146,7 @@ export class SafeDsCallGraphComputer { callable: TslCallable | TslParameter, substitutions: ParameterSubstitutions, ): SyntheticCall[] { - if (isTslBlockLambda(callable) || isTslExpressionLambda(callable) || isTslSegment(callable)) { - return this.getExecutedCallsInPipelineCallable(callable, substitutions); - } else if (isTslClass(callable) || isTslEnumVariant(callable) || isTslFunction(callable)) { + if (isTslFunction(callable)) { return this.getExecutedCallsInStubCallable(callable, substitutions); } else { /* c8 ignore next 2 */ @@ -166,35 +154,8 @@ export class SafeDsCallGraphComputer { } } - private getExecutedCallsInPipelineCallable( - callable: TslBlockLambda | TslExpressionLambda | TslSegment, - substitutions: ParameterSubstitutions, - ): SyntheticCall[] { - const callsInDefaultValues = getParameters(callable).flatMap((it) => { - // The default value is only executed if no argument is passed for the parameter - if (it.defaultValue && !substitutions.has(it)) { - return this.getAllContainedCalls(it.defaultValue); - } else { - return []; - } - }); - - let callsInBody: TslCall[]; - if (isTslBlockLambda(callable)) { - callsInBody = this.getAllContainedCalls(callable.body); - } else if (isTslExpressionLambda(callable)) { - callsInBody = this.getAllContainedCalls(callable.result); - } else { - callsInBody = this.getAllContainedCalls(callable.body); - } - - return [...callsInDefaultValues, ...callsInBody] - .filter((it) => AstUtils.getContainerOfType(it, isTslCallable) === callable) - .map((it) => this.createSyntheticCallForCall(it, substitutions)); - } - private getExecutedCallsInStubCallable( - callable: TslClass | TslEnumVariant | TslFunction, + callable: TslFunction, substitutions: ParameterSubstitutions, ): SyntheticCall[] { const callsInDefaultValues = getParameters(callable).flatMap((parameter) => { From a5c6c8c3b33d882590220900acaa4aafff8f529e Mon Sep 17 00:00:00 2001 From: methr0 Date: Wed, 26 Jun 2024 16:49:54 +0200 Subject: [PATCH 088/183] remove unnecessary documentation provider --- .../documentation/safe-ds-comment-provider.ts | 13 ++----------- .../documentation/safe-ds-documentation-provider.ts | 8 +++----- 2 files changed, 5 insertions(+), 16 deletions(-) diff --git a/packages/ttsl-lang/src/language/documentation/safe-ds-comment-provider.ts b/packages/ttsl-lang/src/language/documentation/safe-ds-comment-provider.ts index 7a493dd0..da2cdb96 100644 --- a/packages/ttsl-lang/src/language/documentation/safe-ds-comment-provider.ts +++ b/packages/ttsl-lang/src/language/documentation/safe-ds-comment-provider.ts @@ -1,12 +1,10 @@ import { AstNode, DefaultCommentProvider, isAstNodeWithComment } from 'langium'; import { MarkupContent } from 'vscode-languageserver'; import { - isTslBlockLambdaResult, isTslDeclaration, isTslParameter, isTslPlaceholder, isTslResult, - isTslTypeParameter, } from '../generated/ast.js'; export class SafeDsCommentProvider extends DefaultCommentProvider { @@ -15,21 +13,14 @@ export class SafeDsCommentProvider extends DefaultCommentProvider { return node.$comment; } /* c8 ignore stop */ else if ( !isTslDeclaration(node) || - isTslBlockLambdaResult(node) || isTslParameter(node) || isTslPlaceholder(node) || - isTslResult(node) || - isTslTypeParameter(node) + isTslResult(node) ) { return undefined; } - // The annotation call list is the previous sibling of the declaration in the CST, so we must step past it - if (node.annotationCallList) { - return super.getComment(node.annotationCallList); - } else { - return super.getComment(node); - } + return super.getComment(node); } } diff --git a/packages/ttsl-lang/src/language/documentation/safe-ds-documentation-provider.ts b/packages/ttsl-lang/src/language/documentation/safe-ds-documentation-provider.ts index a7029479..9ac76c62 100644 --- a/packages/ttsl-lang/src/language/documentation/safe-ds-documentation-provider.ts +++ b/packages/ttsl-lang/src/language/documentation/safe-ds-documentation-provider.ts @@ -12,10 +12,8 @@ import { isTslCallable, isTslParameter, isTslResult, - isTslTypeParameter, TslParameter, TslResult, - TslTypeParameter, } from '../generated/ast.js'; const PARAM_TAG = 'param'; @@ -24,7 +22,7 @@ const TYPE_PARAM_TAG = 'typeParam'; export class SafeDsDocumentationProvider extends JSDocDocumentationProvider { override getDocumentation(node: AstNode): string | undefined { - if (isTslParameter(node) || isTslResult(node) || isTslTypeParameter(node)) { + if (isTslParameter(node) || isTslResult(node)) { const containingCallable = AstUtils.getContainerOfType(node, isTslCallable); /* c8 ignore start */ if (!containingCallable) { @@ -64,7 +62,7 @@ export class SafeDsDocumentationProvider extends JSDocDocumentationProvider { private getMatchingTagContent( comment: JSDocComment, - node: TslParameter | TslResult | TslTypeParameter, + node: TslParameter | TslResult, ): string | undefined { const name = node.name; /* c8 ignore start */ @@ -83,7 +81,7 @@ export class SafeDsDocumentationProvider extends JSDocDocumentationProvider { ?.match(matchRegex)?.groups?.content; } - private getTagName(node: TslParameter | TslResult | TslTypeParameter): string { + private getTagName(node: TslParameter | TslResult): string { if (isTslParameter(node)) { return PARAM_TAG; } else if (isTslResult(node)) { From fc44b0db64d86930ec5de68d6c59de599b6ed232 Mon Sep 17 00:00:00 2001 From: methr0 Date: Wed, 26 Jun 2024 16:52:28 +0200 Subject: [PATCH 089/183] remove unnecessary buildins --- .../language/builtins/safe-ds-annotations.ts | 186 ------------------ .../src/language/builtins/safe-ds-classes.ts | 67 ------- .../src/language/builtins/safe-ds-enums.ts | 68 ------- 3 files changed, 321 deletions(-) delete mode 100644 packages/ttsl-lang/src/language/builtins/safe-ds-annotations.ts delete mode 100644 packages/ttsl-lang/src/language/builtins/safe-ds-classes.ts delete mode 100644 packages/ttsl-lang/src/language/builtins/safe-ds-enums.ts diff --git a/packages/ttsl-lang/src/language/builtins/safe-ds-annotations.ts b/packages/ttsl-lang/src/language/builtins/safe-ds-annotations.ts deleted file mode 100644 index a439dcfe..00000000 --- a/packages/ttsl-lang/src/language/builtins/safe-ds-annotations.ts +++ /dev/null @@ -1,186 +0,0 @@ -import { EMPTY_STREAM, Stream, stream, URI } from 'langium'; -import { resourceNameToUri } from '../../helpers/resources.js'; -import { - isTslAnnotation, - TslAnnotatedObject, - TslAnnotation, - TslEnumVariant, - TslFunction, - TslModule, - TslParameter, -} from '../generated/ast.js'; -import { findFirstAnnotationCallOf, getEnumVariants, hasAnnotationCallOf } from '../helpers/nodeProperties.js'; -import { SafeDsNodeMapper } from '../helpers/safe-ds-node-mapper.js'; -import { - EvaluatedEnumVariant, - EvaluatedList, - EvaluatedNode, - StringConstant, - UnknownEvaluatedNode, -} from '../partialEvaluation/model.js'; -import { SafeDsPartialEvaluator } from '../partialEvaluation/safe-ds-partial-evaluator.js'; -import { SafeDsServices } from '../safe-ds-module.js'; -import { SafeDsEnums } from './safe-ds-enums.js'; -import { SafeDsModuleMembers } from './safe-ds-module-members.js'; - -const ANNOTATION_USAGE_URI = resourceNameToUri('builtins/safeds/lang/annotationUsage.Tslstub'); -const CODE_GENERATION_URI = resourceNameToUri('builtins/safeds/lang/codeGeneration.Tslstub'); -const IDE_INTEGRATION_URI = resourceNameToUri('builtins/safeds/lang/ideIntegration.Tslstub'); -const MATURITY_URI = resourceNameToUri('builtins/safeds/lang/maturity.Tslstub'); -const PURITY_URI = resourceNameToUri('builtins/safeds/lang/purity.Tslstub'); - -export class SafeDsAnnotations extends SafeDsModuleMembers { - private readonly builtinEnums: SafeDsEnums; - private readonly nodeMapper: SafeDsNodeMapper; - private readonly partialEvaluator: SafeDsPartialEvaluator; - - constructor(services: SafeDsServices) { - super(services); - - this.builtinEnums = services.builtins.Enums; - this.nodeMapper = services.helpers.NodeMapper; - this.partialEvaluator = services.evaluation.PartialEvaluator; - } - - callsDeprecated(node: TslAnnotatedObject | undefined): boolean { - return hasAnnotationCallOf(node, this.Deprecated); - } - - private get Deprecated(): TslAnnotation | undefined { - return this.getAnnotation(MATURITY_URI, 'Deprecated'); - } - - callsExperimental(node: TslAnnotatedObject | undefined): boolean { - return hasAnnotationCallOf(node, this.Experimental); - } - - private get Experimental(): TslAnnotation | undefined { - return this.getAnnotation(MATURITY_URI, 'Experimental'); - } - - callsExpert(node: TslParameter | undefined): boolean { - return hasAnnotationCallOf(node, this.Expert); - } - - private get Expert(): TslAnnotation | undefined { - return this.getAnnotation(IDE_INTEGRATION_URI, 'Expert'); - } - - callsImpure(node: TslFunction | undefined): boolean { - return hasAnnotationCallOf(node, this.Impure); - } - - streamImpurityReasons(node: TslFunction | undefined): Stream { - // If allReasons are specified, but we could not evaluate them to a list, no reasons apply - const value = this.getParameterValue(node, this.Impure, 'allReasons'); - if (!(value instanceof EvaluatedList)) { - return EMPTY_STREAM; - } - - // Otherwise, filter the elements of the list and keep only variants of the ImpurityReason enum - return stream(value.elements).filter(this.builtinEnums.isEvaluatedImpurityReason); - } - - get Impure(): TslAnnotation | undefined { - return this.getAnnotation(PURITY_URI, 'Impure'); - } - - callsPure(node: TslFunction | undefined): boolean { - return hasAnnotationCallOf(node, this.Pure); - } - - get Pure(): TslAnnotation | undefined { - return this.getAnnotation(PURITY_URI, 'Pure'); - } - - getPythonCall(node: TslFunction | undefined): string | undefined { - const value = this.getParameterValue(node, this.PythonCall, 'callSpecification'); - if (value instanceof StringConstant) { - return value.value; - } else { - return undefined; - } - } - - get PythonCall(): TslAnnotation | undefined { - return this.getAnnotation(CODE_GENERATION_URI, 'PythonCall'); - } - - getPythonModule(node: TslModule | undefined): string | undefined { - const value = this.getParameterValue(node, this.PythonModule, 'qualifiedName'); - if (value instanceof StringConstant) { - return value.value; - } else { - return undefined; - } - } - - get PythonModule(): TslAnnotation | undefined { - return this.getAnnotation(CODE_GENERATION_URI, 'PythonModule'); - } - - getPythonName(node: TslAnnotatedObject | undefined): string | undefined { - const value = this.getParameterValue(node, this.PythonName, 'name'); - if (value instanceof StringConstant) { - return value.value; - } else { - return undefined; - } - } - - get PythonName(): TslAnnotation | undefined { - return this.getAnnotation(CODE_GENERATION_URI, 'PythonName'); - } - - callsRepeatable(node: TslAnnotation | undefined): boolean { - return hasAnnotationCallOf(node, this.Repeatable); - } - - private get Repeatable(): TslAnnotation | undefined { - return this.getAnnotation(ANNOTATION_USAGE_URI, 'Repeatable'); - } - - streamValidTargets(node: TslAnnotation | undefined): Stream { - // If no targets are specified, every target is valid - if (!hasAnnotationCallOf(node, this.Target)) { - return stream(getEnumVariants(this.builtinEnums.AnnotationTarget)); - } - - // If targets are specified, but we could not evaluate them to a list, no target is valid - const value = this.getParameterValue(node, this.Target, 'targets'); - if (!(value instanceof EvaluatedList)) { - return EMPTY_STREAM; - } - - // Otherwise, filter the elements of the list and keep only variants of the AnnotationTarget enum - return stream(value.elements) - .filter(this.builtinEnums.isEvaluatedAnnotationTarget) - .map((it) => it.variant); - } - - get Target(): TslAnnotation | undefined { - return this.getAnnotation(ANNOTATION_USAGE_URI, 'Target'); - } - - private getAnnotation(uri: URI, name: string): TslAnnotation | undefined { - return this.getModuleMember(uri, name, isTslAnnotation); - } - - /** - * Finds the first call of the given annotation on the given node and returns the value that is assigned to the - * parameter with the given name. - */ - private getParameterValue( - node: TslAnnotatedObject | undefined, - annotation: TslAnnotation | undefined, - parameterName: string, - ): EvaluatedNode { - const annotationCall = findFirstAnnotationCallOf(node, annotation); - if (!annotationCall) { - return UnknownEvaluatedNode; - } - - const parameterValue = this.nodeMapper.callToParameterValue(annotationCall, parameterName); - return this.partialEvaluator.evaluate(parameterValue); - } -} diff --git a/packages/ttsl-lang/src/language/builtins/safe-ds-classes.ts b/packages/ttsl-lang/src/language/builtins/safe-ds-classes.ts deleted file mode 100644 index d4663744..00000000 --- a/packages/ttsl-lang/src/language/builtins/safe-ds-classes.ts +++ /dev/null @@ -1,67 +0,0 @@ -import { isTslClass, TslClass } from '../generated/ast.js'; -import { SafeDsModuleMembers } from './safe-ds-module-members.js'; -import { resourceNameToUri } from '../../helpers/resources.js'; - -const CORE_CLASSES_URI = resourceNameToUri('builtins/safeds/lang/coreClasses.Tslstub'); - -export class SafeDsClasses extends SafeDsModuleMembers { - get Any(): TslClass | undefined { - return this.getClass('Any'); - } - - get Boolean(): TslClass | undefined { - return this.getClass('Boolean'); - } - - get Float(): TslClass | undefined { - return this.getClass('Float'); - } - - get Int(): TslClass | undefined { - return this.getClass('Int'); - } - - get List(): TslClass | undefined { - return this.getClass('List'); - } - - get Map(): TslClass | undefined { - return this.getClass('Map'); - } - - get Nothing(): TslClass | undefined { - return this.getClass('Nothing'); - } - - get Number(): TslClass | undefined { - return this.getClass('Number'); - } - - get String(): TslClass | undefined { - return this.getClass('String'); - } - - /** - * Returns whether the given node is a builtin class. - */ - isBuiltinClass(node: TslClass | undefined): boolean { - return ( - Boolean(node) && - [ - this.Any, - this.Boolean, - this.Float, - this.Int, - this.List, - this.Map, - this.Nothing, - this.Number, - this.String, - ].includes(node) - ); - } - - private getClass(name: string): TslClass | undefined { - return this.getModuleMember(CORE_CLASSES_URI, name, isTslClass); - } -} diff --git a/packages/ttsl-lang/src/language/builtins/safe-ds-enums.ts b/packages/ttsl-lang/src/language/builtins/safe-ds-enums.ts deleted file mode 100644 index caf1dabb..00000000 --- a/packages/ttsl-lang/src/language/builtins/safe-ds-enums.ts +++ /dev/null @@ -1,68 +0,0 @@ -import { AstUtils, URI } from 'langium'; -import { resourceNameToUri } from '../../helpers/resources.js'; -import { isTslEnum, TslEnum, type TslEnumVariant } from '../generated/ast.js'; -import { getEnumVariants } from '../helpers/nodeProperties.js'; -import { EvaluatedEnumVariant, EvaluatedNode } from '../partialEvaluation/model.js'; -import type { SafeDsServices } from '../safe-ds-module.js'; -import { SafeDsModuleMembers } from './safe-ds-module-members.js'; - -const ANNOTATION_USAGE_URI = resourceNameToUri('builtins/safeds/lang/annotationUsage.Tslstub'); -const PURITY_URI = resourceNameToUri('builtins/safeds/lang/purity.Tslstub'); - -export class SafeDsEnums extends SafeDsModuleMembers { - get AnnotationTarget(): TslEnum | undefined { - return this.getEnum(ANNOTATION_USAGE_URI, 'AnnotationTarget'); - } - - isEvaluatedAnnotationTarget = (node: EvaluatedNode): node is EvaluatedEnumVariant => - node instanceof EvaluatedEnumVariant && - AstUtils.getContainerOfType(node.variant, isTslEnum) === this.AnnotationTarget; - - get ImpurityReason(): TslEnum | undefined { - return this.getEnum(PURITY_URI, 'ImpurityReason'); - } - - isEvaluatedImpurityReason = (node: EvaluatedNode): node is EvaluatedEnumVariant => - node instanceof EvaluatedEnumVariant && - AstUtils.getContainerOfType(node.variant, isTslEnum) === this.ImpurityReason; - - private getEnum(uri: URI, name: string): TslEnum | undefined { - return this.getModuleMember(uri, name, isTslEnum); - } -} - -export class SafeDsImpurityReasons { - private readonly builtinEnums: SafeDsEnums; - - constructor(services: SafeDsServices) { - this.builtinEnums = services.builtins.Enums; - } - - get FileReadFromConstantPath(): TslEnumVariant | undefined { - return this.getEnumVariant('FileReadFromConstantPath'); - } - - get FileReadFromParameterizedPath(): TslEnumVariant | undefined { - return this.getEnumVariant('FileReadFromParameterizedPath'); - } - - get FileWriteToConstantPath(): TslEnumVariant | undefined { - return this.getEnumVariant('FileWriteToConstantPath'); - } - - get FileWriteToParameterizedPath(): TslEnumVariant | undefined { - return this.getEnumVariant('FileWriteToParameterizedPath'); - } - - get PotentiallyImpureParameterCall(): TslEnumVariant | undefined { - return this.getEnumVariant('PotentiallyImpureParameterCall'); - } - - get Other(): TslEnumVariant | undefined { - return this.getEnumVariant('Other'); - } - - private getEnumVariant(name: string): TslEnumVariant | undefined { - return getEnumVariants(this.builtinEnums.ImpurityReason).find((variant) => variant.name === name); - } -} From 542b0e34d7b808274fde0e173d56b6d741d30d66 Mon Sep 17 00:00:00 2001 From: methr0 Date: Fri, 28 Jun 2024 12:12:09 +0200 Subject: [PATCH 090/183] remove use of unnecessary builtins and add fuiltins for functions --- .../language/builtins/ttsl-ds-functions.ts | 82 +++++ .../generation/safe-ds-python-generator.ts | 16 +- .../lsp/safe-ds-node-info-provider.ts | 4 - .../lsp/safe-ds-semantic-token-provider.ts | 5 - .../ttsl-lang/src/language/purity/model.ts | 195 ----------- .../purity/safe-ds-purity-computer.ts | 307 ------------------ .../ttsl-lang/src/language/safe-ds-module.ts | 14 +- .../validation/builtins/deprecated.ts | 76 ----- .../validation/builtins/experimental.ts | 80 ----- .../language/validation/builtins/expert.ts | 19 -- .../validation/builtins/pythonCall.ts | 40 --- .../validation/builtins/pythonModule.ts | 27 -- .../validation/builtins/pythonName.ts | 42 --- .../src/language/validation/purity.ts | 245 -------------- .../language/validation/safe-ds-validator.ts | 42 --- .../src/language/validation/types.ts | 1 - 16 files changed, 94 insertions(+), 1101 deletions(-) create mode 100644 packages/ttsl-lang/src/language/builtins/ttsl-ds-functions.ts delete mode 100644 packages/ttsl-lang/src/language/purity/model.ts delete mode 100644 packages/ttsl-lang/src/language/purity/safe-ds-purity-computer.ts delete mode 100644 packages/ttsl-lang/src/language/validation/builtins/deprecated.ts delete mode 100644 packages/ttsl-lang/src/language/validation/builtins/experimental.ts delete mode 100644 packages/ttsl-lang/src/language/validation/builtins/expert.ts delete mode 100644 packages/ttsl-lang/src/language/validation/builtins/pythonCall.ts delete mode 100644 packages/ttsl-lang/src/language/validation/builtins/pythonModule.ts delete mode 100644 packages/ttsl-lang/src/language/validation/builtins/pythonName.ts delete mode 100644 packages/ttsl-lang/src/language/validation/purity.ts diff --git a/packages/ttsl-lang/src/language/builtins/ttsl-ds-functions.ts b/packages/ttsl-lang/src/language/builtins/ttsl-ds-functions.ts new file mode 100644 index 00000000..b4df9a5f --- /dev/null +++ b/packages/ttsl-lang/src/language/builtins/ttsl-ds-functions.ts @@ -0,0 +1,82 @@ +import { URI } from "langium"; +import { resourceNameToUri } from "../../helpers/resources.js"; +import { TslFunction, TslModule, TslObject, isTslFunction } from "../generated/ast.js"; +import { SafeDsNodeMapper } from "../helpers/safe-ds-node-mapper.js"; +import { EvaluatedNode, StringConstant, UnknownEvaluatedNode } from "../partialEvaluation/model.js"; +import { SafeDsPartialEvaluator } from "../partialEvaluation/safe-ds-partial-evaluator.js"; +import { SafeDsServices } from "../safe-ds-module.js"; +import { SafeDsModuleMembers } from "./safe-ds-module-members.js"; + +const CODE_GENERATION_URI = resourceNameToUri('builtins/safeds/lang/codeGeneration.sdsstub'); + +export class TTSLFunction extends SafeDsModuleMembers { + private readonly nodeMapper: SafeDsNodeMapper; + private readonly partialEvaluator: SafeDsPartialEvaluator; + + constructor(services: SafeDsServices) { + super(services); + + this.nodeMapper = services.helpers.NodeMapper; + this.partialEvaluator = services.evaluation.PartialEvaluator; + } + + getPythonCall(node: TslFunction | undefined): string | undefined { + const value = this.getParameterValue(node, this.PythonCall, 'callSpecification'); + if (value instanceof StringConstant) { + return value.value; + } else { + return undefined; + } + } + + get PythonCall(): TslFunction | undefined { + return this.getFunction(CODE_GENERATION_URI, 'PythonCall'); + } + + getPythonModule(node: TslModule | undefined): string | undefined { + const value = this.getParameterValue(node, this.PythonModule, 'qualifiedName'); + if (value instanceof StringConstant) { + return value.value; + } else { + return undefined; + } + } + + get PythonModule(): TslFunction | undefined { + return this.getFunction(CODE_GENERATION_URI, 'PythonModule'); + } + + getPythonName(node: TslObject | undefined): string | undefined { + const value = this.getParameterValue(node, this.PythonName, 'name'); + if (value instanceof StringConstant) { + return value.value; + } else { + return undefined; + } + } + + get PythonName(): TslFunction | undefined { + return this.getFunction(CODE_GENERATION_URI, 'PythonName'); + } + + private getFunction(uri: URI, name: string): TslFunction | undefined { + return this.getModuleMember(uri, name, isTslFunction); + } + + /** + * Returns the value that is assigned to the + * parameter with the given name. + */ + private getParameterValue( + node: TslObject | undefined, + funct: TslFunction | undefined, + parameterName: string, + ): EvaluatedNode { + const value = funct?.parameterList?.parameters.find((param) => param.name== parameterName) + if(!value){ + return UnknownEvaluatedNode + } + + return this.partialEvaluator.evaluate(value); + } +} diff --git a/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts b/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts index 9777861b..d35fde07 100644 --- a/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts +++ b/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts @@ -15,7 +15,6 @@ import path from 'path'; import { SourceMapGenerator, StartOfSourceMap } from 'source-map'; import { TextDocument } from 'vscode-languageserver-textdocument'; import { groupBy, isEmpty } from '../../helpers/collections.js'; -import { SafeDsAnnotations } from '../builtins/safe-ds-annotations.js'; import { isTslAssignment, isTslCall, @@ -68,6 +67,7 @@ import { isTslBlock, TslTimeunit, isTslExpression, + TslModuleMember, } from '../generated/ast.js'; import { isInStubFile, isStubFile } from '../helpers/fileExtensions.js'; import { @@ -94,6 +94,8 @@ import { SafeDsPartialEvaluator } from '../partialEvaluation/safe-ds-partial-eva import { SafeDsServices } from '../safe-ds-module.js'; import { SafeDsPurityComputer } from '../purity/safe-ds-purity-computer.js'; import { FileRead, ImpurityReason } from '../purity/model.js'; +import { SafeDsModuleMembers } from '../builtins/safe-ds-module-members.js'; +import { TTSLFunction } from '../builtins/ttsl-ds-functions.js'; export const CODEGEN_PREFIX = '__gen_'; @@ -292,13 +294,13 @@ const UTILITY_TIMEUNIT_YEAR: UtilityFunction = { }; export class SafeDsPythonGenerator { - private readonly builtinAnnotations: SafeDsAnnotations; + private readonly builtinFunction: TTSLFunction; private readonly nodeMapper: SafeDsNodeMapper; private readonly partialEvaluator: SafeDsPartialEvaluator; private readonly purityComputer: SafeDsPurityComputer; constructor(services: SafeDsServices) { - this.builtinAnnotations = services.builtins.Annotations; + this.builtinFunction = services.builtins.Functions; this.nodeMapper = services.helpers.NodeMapper; this.partialEvaluator = services.evaluation.PartialEvaluator; this.purityComputer = services.purity.PurityComputer; @@ -313,7 +315,7 @@ export class SafeDsPythonGenerator { } const name = path.parse(document.uri.fsPath).name; - const pythonModuleName = this.builtinAnnotations.getPythonModule(node); + const pythonModuleName = this.builtinFunction.getPythonModule(node); const packagePath = pythonModuleName === undefined ? node.name.split('.') : [pythonModuleName]; const parentDirectoryPath = path.join(generateOptions.destination!.fsPath, ...packagePath); @@ -394,11 +396,11 @@ export class SafeDsPythonGenerator { } private getPythonModuleOrDefault(object: TslModule) { - return this.builtinAnnotations.getPythonModule(object) || object.name; + return this.builtinFunction.getPythonModule(object) || object.name; } private getPythonNameOrDefault(object: TslDeclaration) { - return this.builtinAnnotations.getPythonName(object) || object.name; + return this.builtinFunction.getPythonName(object) || object.name; } private getQualifiedNamePythonCompatible(node: TslDeclaration | undefined): string | undefined { @@ -971,7 +973,7 @@ export class SafeDsPythonGenerator { // Memoize constructor or function call if (isTslFunction(callable)) { if (isTslFunction(callable)) { - const pythonCall = this.builtinAnnotations.getPythonCall(callable); + const pythonCall = this.builtinFunction.getPythonCall(callable); if (pythonCall) { let thisParam: CompositeGeneratorNode | undefined = undefined; if (isTslMemberAccess(expression.receiver)) { diff --git a/packages/ttsl-lang/src/language/lsp/safe-ds-node-info-provider.ts b/packages/ttsl-lang/src/language/lsp/safe-ds-node-info-provider.ts index 692306ed..167cb6ea 100644 --- a/packages/ttsl-lang/src/language/lsp/safe-ds-node-info-provider.ts +++ b/packages/ttsl-lang/src/language/lsp/safe-ds-node-info-provider.ts @@ -1,16 +1,12 @@ import { AstNode } from 'langium'; -import { SymbolTag } from 'vscode-languageserver'; -import type { SafeDsAnnotations } from '../builtins/safe-ds-annotations.js'; import { isTslFunction } from '../generated/ast.js'; import type { SafeDsServices } from '../safe-ds-module.js'; import { SafeDsTypeComputer } from '../typing/safe-ds-type-computer.js'; export class SafeDsNodeInfoProvider { - private readonly builtinAnnotations: SafeDsAnnotations; private readonly typeComputer: SafeDsTypeComputer; constructor(services: SafeDsServices) { - this.builtinAnnotations = services.builtins.Annotations; this.typeComputer = services.types.TypeComputer; } diff --git a/packages/ttsl-lang/src/language/lsp/safe-ds-semantic-token-provider.ts b/packages/ttsl-lang/src/language/lsp/safe-ds-semantic-token-provider.ts index e0471362..2e5e15ca 100644 --- a/packages/ttsl-lang/src/language/lsp/safe-ds-semantic-token-provider.ts +++ b/packages/ttsl-lang/src/language/lsp/safe-ds-semantic-token-provider.ts @@ -1,7 +1,6 @@ import { AbstractSemanticTokenProvider, SemanticTokenAcceptor } from 'langium/lsp'; import { AstNode, AstUtils } from 'langium'; import { SemanticTokenModifiers, SemanticTokenTypes } from 'vscode-languageserver'; -import { SafeDsClasses } from '../builtins/safe-ds-classes.js'; import { isTslArgument, isTslDeclaration, @@ -17,12 +16,8 @@ import { import { SafeDsServices } from '../safe-ds-module.js'; export class SafeDsSemanticTokenProvider extends AbstractSemanticTokenProvider { - private readonly builtinClasses: SafeDsClasses; - constructor(services: SafeDsServices) { super(services); - - this.builtinClasses = services.builtins.Classes; } protected highlightElement(node: AstNode, acceptor: SemanticTokenAcceptor): void { diff --git a/packages/ttsl-lang/src/language/purity/model.ts b/packages/ttsl-lang/src/language/purity/model.ts deleted file mode 100644 index 4f63298f..00000000 --- a/packages/ttsl-lang/src/language/purity/model.ts +++ /dev/null @@ -1,195 +0,0 @@ -import { isTslParameter, type TslParameter } from '../generated/ast.js'; -import { getQualifiedName } from '../helpers/nodeProperties.js'; - -/** - * A reason why a function is impure. - */ -export abstract class ImpurityReason { - /** - * Whether the impurity reason is a side effect. - */ - abstract isSideEffect: boolean; - - /** - * Returns whether this impurity reason is equal to another object. - */ - abstract equals(other: unknown): boolean; - - /** - * Returns a string representation of this impurity reason. - */ - abstract toString(): string; - - /** - * Returns whether this impurity reason can affect a future impurity reason. - * @param future Future Impurity reason to test, if this reason may have an effect on it. - */ - abstract canAffectFutureImpurityReason(future: ImpurityReason): boolean; -} - -/** - * The function reads from a file. - * - * @param path The path of the read file. This can either be a parameter or a constant string. - */ -export class FileRead extends ImpurityReason { - override isSideEffect = false; - - constructor(readonly path: TslParameter | string | undefined) { - super(); - } - - override equals(other: unknown): boolean { - return other instanceof FileRead && this.path === other.path; - } - - override toString(): string { - if (isTslParameter(this.path)) { - return `File read from ${getQualifiedName(this.path)}`; - } else if (typeof this.path === 'string') { - return `File read from "${this.path}"`; - } else { - return 'File read from ?'; - } - } - - override canAffectFutureImpurityReason(_future: ImpurityReason): boolean { - // Reads can't affect other reasons - return false; - } -} - -/** - * The function writes to a file. - * - * @param path The path of the written file. This can either be a parameter or a constant string. - */ -export class FileWrite extends ImpurityReason { - override isSideEffect = true; - - constructor(readonly path: TslParameter | string | undefined) { - super(); - } - - override equals(other: unknown): boolean { - return other instanceof FileWrite && this.path === other.path; - } - - override toString(): string { - if (isTslParameter(this.path)) { - return `File write to ${getQualifiedName(this.path)}`; - } else if (typeof this.path === 'string') { - return `File write to "${this.path}"`; - } else { - return 'File write to ?'; - } - } - - override canAffectFutureImpurityReason(future: ImpurityReason): boolean { - if (future instanceof FileWrite || future instanceof FileRead) { - if (typeof this.path === 'string' && typeof future.path === 'string') { - // Writes only have an effect on other reads and writes, if the files is known and is the same - return this.path === future.path; - } - } - return future !== EndlessRecursion; - } -} - -/** - * The function calls a callable that is given as a parameter and that might be impure. - * - * @param parameter The parameter that is called. - */ -export class PotentiallyImpureParameterCall extends ImpurityReason { - override isSideEffect = true; - - constructor(readonly parameter: TslParameter | undefined) { - super(); - } - - override equals(other: unknown): boolean { - return other instanceof PotentiallyImpureParameterCall && this.parameter === other.parameter; - } - - override toString(): string { - if (isTslParameter(this.parameter)) { - return `Potentially impure call of ${getQualifiedName(this.parameter)}`; - } else { - return 'Potentially impure call of ?'; - } - } - - override canAffectFutureImpurityReason(future: ImpurityReason): boolean { - return future !== EndlessRecursion; - } -} - -/** - * The function calls an unknown callable. - */ -class UnknownCallableCallClass extends ImpurityReason { - override isSideEffect = true; - - override equals(other: unknown): boolean { - return other instanceof UnknownCallableCallClass; - } - - override toString(): string { - return 'Unknown callable call'; - } - - canAffectFutureImpurityReason(future: ImpurityReason): boolean { - /* c8 ignore next 2 */ - return future !== EndlessRecursion; - } -} - -export const UnknownCallableCall = new UnknownCallableCallClass(); - -/** - * A function contains a call that leads to endless recursion. - */ -class EndlessRecursionClass extends ImpurityReason { - override isSideEffect = true; - - override equals(other: unknown): boolean { - return other instanceof EndlessRecursionClass; - } - - override toString(): string { - return 'Endless recursion'; - } - - override canAffectFutureImpurityReason(_future: ImpurityReason): boolean { - /* c8 ignore next 3 */ - // Endless recursions don't have any effect on others - return false; - } -} - -export const EndlessRecursion = new EndlessRecursionClass(); - -/** - * A function is impure due to some reason that is not covered by the other impurity reasons. - */ -class OtherImpurityReasonClass extends ImpurityReason { - override isSideEffect = true; - - override equals(other: unknown): boolean { - return other instanceof OtherImpurityReasonClass; - } - - override toString(): string { - return 'Other'; - } - - canAffectFutureImpurityReason(future: ImpurityReason): boolean { - return future !== EndlessRecursion; - } -} - -/** - * A function is impure due to some reason that is not covered by the other impurity reasons. - */ -export const OtherImpurityReason = new OtherImpurityReasonClass(); diff --git a/packages/ttsl-lang/src/language/purity/safe-ds-purity-computer.ts b/packages/ttsl-lang/src/language/purity/safe-ds-purity-computer.ts deleted file mode 100644 index 4606f07a..00000000 --- a/packages/ttsl-lang/src/language/purity/safe-ds-purity-computer.ts +++ /dev/null @@ -1,307 +0,0 @@ -import { type AstNode, type AstNodeLocator, AstUtils, EMPTY_STREAM, Stream, WorkspaceCache } from 'langium'; -import { isEmpty } from '../../helpers/collections.js'; -import type { SafeDsCallGraphComputer } from '../flow/safe-ds-call-graph-computer.js'; -import type { SafeDsServices } from '../safe-ds-module.js'; -import { - EndlessRecursion, - FileRead, - FileWrite, - type ImpurityReason, - OtherImpurityReason, - PotentiallyImpureParameterCall, - UnknownCallableCall, -} from './model.js'; -import { - isTslAssignment, - isTslCallable, - isTslExpressionStatement, - isTslFunction, - isTslParameter, - TslCall, - TslCallable, - TslExpression, - TslFunction, - TslParameter, - TslStatement, -} from '../generated/ast.js'; -import { EvaluatedEnumVariant, ParameterSubstitutions, StringConstant } from '../partialEvaluation/model.js'; -import { SafeDsAnnotations } from '../builtins/safe-ds-annotations.js'; -import { SafeDsImpurityReasons } from '../builtins/safe-ds-enums.js'; -import { getAssignees, getParameters } from '../helpers/nodeProperties.js'; -import { isContainedInOrEqual } from '../helpers/astUtils.js'; - -export class SafeDsPurityComputer { - private readonly astNodeLocator: AstNodeLocator; - private readonly builtinAnnotations: SafeDsAnnotations; - private readonly builtinImpurityReasons: SafeDsImpurityReasons; - private readonly callGraphComputer: SafeDsCallGraphComputer; - - private readonly reasonsCache: WorkspaceCache; - - constructor(services: SafeDsServices) { - this.astNodeLocator = services.workspace.AstNodeLocator; - this.builtinAnnotations = services.builtins.Annotations; - this.builtinImpurityReasons = services.builtins.ImpurityReasons; - this.callGraphComputer = services.flow.CallGraphComputer; - - this.reasonsCache = new WorkspaceCache(services.shared); - } - - // We need separate methods for callables and expressions because lambdas are both. The caller must decide whether - // the lambda should get "executed" (***Callable methods) when computing the impurity reasons or not (***Expression - // methods). - - /** - * Returns whether the given callable is pure. - * - * @param node - * The callable to check. - * - * @param substitutions - * The parameter substitutions to use. These are **not** the argument of a call, but the values of the parameters - * of any containing callables, i.e. the context of the node. - */ - isPureCallable(node: TslCallable | undefined, substitutions = NO_SUBSTITUTIONS): boolean { - return isEmpty(this.getImpurityReasonsForCallable(node, substitutions)); - } - - /** - * Returns whether the given expression is pure. - * - * @param node - * The expression to check. - * - * @param substitutions - * The parameter substitutions to use. These are **not** the argument of a call, but the values of the parameters - * of any containing callables, i.e. the context of the node. - */ - isPureExpression(node: TslExpression | undefined, substitutions = NO_SUBSTITUTIONS): boolean { - return isEmpty(this.getImpurityReasonsForExpression(node, substitutions)); - } - - /** - * Returns whether the given parameter is pure, i.e. only accepts pure callables. - * - * @param node - * The parameter to check. - */ - isPureParameter(node: TslParameter | undefined): boolean { - const containingCallable = AstUtils.getContainerOfType(node, isTslCallable); - if ( - !containingCallable - ) { - return true; - } else if (isTslFunction(containingCallable)) { - const expectedImpurityReason = new PotentiallyImpureParameterCall(node); - return !this.getImpurityReasons(containingCallable).some((it) => it.equals(expectedImpurityReason)); - } else { - return false; - } - } - - /** - * Returns whether the given callable has side effects. - * - * @param node - * The callable to check. - * - * @param substitutions - * The parameter substitutions to use. These are **not** the argument of a call, but the values of the parameters - * of any containing callables, i.e. the context of the node. - */ - callableHasSideEffects(node: TslCallable | undefined, substitutions = NO_SUBSTITUTIONS): boolean { - return this.getImpurityReasonsForCallable(node, substitutions).some((it) => it.isSideEffect); - } - - /** - * Returns whether the given expression has side effects. - * - * @param node - * The expression to check. - * - * @param substitutions - * The parameter substitutions to use. These are **not** the argument of a call, but the values of the parameters - * of any containing callables, i.e. the context of the node. - */ - expressionHasSideEffects(node: TslExpression | undefined, substitutions = NO_SUBSTITUTIONS): boolean { - return this.getImpurityReasonsForExpression(node, substitutions).some((it) => it.isSideEffect); - } - - /** - * Returns whether the given statement does something. It must either - * - create a placeholder, - * - assign to a result, or - * - call a function that has side effects. - * - * @param node - * The statement to check. - * - * @param substitutions - * The parameter substitutions to use. These are **not** the argument of a call, but the values of the parameters - * of any containing callables, i.e. the context of the node. - */ - statementDoesSomething(node: TslStatement, substitutions = NO_SUBSTITUTIONS): boolean { - if (isTslAssignment(node)) { - return ( - this.expressionHasSideEffects(node.expression, substitutions) - ); - } else if (isTslExpressionStatement(node)) { - return this.expressionHasSideEffects(node.expression, substitutions); - } else { - /* c8 ignore next 2 */ - return false; - } - } - - /** - * Returns the reasons why the given callable is impure. - * - * @param node - * The callable to check. - * - * @param substitutions - * The parameter substitutions to use. These are **not** the argument of a call, but the values of the parameters - * of any containing callables, i.e. the context of the node. - */ - getImpurityReasonsForCallable(node: TslCallable | undefined, substitutions = NO_SUBSTITUTIONS): ImpurityReason[] { - return this.getImpurityReasons(node, substitutions); - } - - /** - * Returns the reasons why the given statement is impure. - * - * @param node - * The statement to check. - * - * @param substitutions - * The parameter substitutions to use. These are **not** the argument of a call, but the values of the parameters - * of any containing callables, i.e. the context of the node. - */ - getImpurityReasonsForStatement(node: TslStatement | undefined, substitutions = NO_SUBSTITUTIONS): ImpurityReason[] { - if (isTslAssignment(node)) { - return this.getImpurityReasonsForExpression(node.expression, substitutions); - } else if (isTslExpressionStatement(node)) { - return this.getImpurityReasonsForExpression(node.expression, substitutions); - } else { - /* c8 ignore next 2 */ - return []; - } - } - - /** - * Returns the reasons why the given expression is impure. - * - * @param node - * The expression to check. - * - * @param substitutions - * The parameter substitutions to use. These are **not** the argument of a call, but the values of the parameters - * of any containing callables, i.e. the context of the node. - */ - getImpurityReasonsForExpression( - node: TslExpression | undefined, - substitutions = NO_SUBSTITUTIONS, - ): ImpurityReason[] { - return this.getExecutedCallsInExpression(node).flatMap((it) => this.getImpurityReasons(it, substitutions)); - } - - private getImpurityReasons( - node: TslCall | TslCallable | undefined, - substitutions = NO_SUBSTITUTIONS, - ): ImpurityReason[] { - if (!node) { - /* c8 ignore next 2 */ - return []; - } - - // Cache the result if no substitutions are given - if (isEmpty(substitutions)) { - const key = this.getNodeId(node); - return this.reasonsCache.get(key, () => this.doGetImpurityReasons(node, substitutions)); - } else { - /* c8 ignore next 2 */ - return this.doGetImpurityReasons(node, substitutions); - } - } - - private doGetImpurityReasons(node: TslCall | TslCallable, substitutions = NO_SUBSTITUTIONS): ImpurityReason[] { - const callGraph = this.callGraphComputer.getCallGraph(node, substitutions); - - const recursionImpurityReason: ImpurityReason[] = []; - if (callGraph.isRecursive) { - recursionImpurityReason.push(EndlessRecursion); - } - - const otherImpurityReasons = callGraph.streamCalledCallables().flatMap((it) => { - if (!it) { - return [UnknownCallableCall]; - } else if (isTslFunction(it)) { - return this.getImpurityReasonsForFunction(it); - } else if ( - isTslParameter(it) && - // Leads to endless recursion if we don't check this - // (see test case "should return the impurity reasons of a parameter call in a function") - !isTslFunction(AstUtils.getContainerOfType(it, isTslCallable)) && - !this.isPureParameter(it) - ) { - return [new PotentiallyImpureParameterCall(it)]; - } else { - return EMPTY_STREAM; - } - }); - - return [...recursionImpurityReason, ...otherImpurityReasons]; - } - - private getExecutedCallsInExpression(expression: TslExpression | undefined): TslCall[] { - return this.callGraphComputer.getAllContainedCalls(expression); - } - - private getImpurityReasonsForFunction(node: TslFunction): Stream { - return this.builtinAnnotations.streamImpurityReasons(node).flatMap((it) => { - switch (it.variant) { - case this.builtinImpurityReasons.FileReadFromConstantPath: - return new FileRead(this.getPath(it)); - case this.builtinImpurityReasons.FileReadFromParameterizedPath: - return new FileRead(this.getParameter(node, it)); - case this.builtinImpurityReasons.FileWriteToConstantPath: - return new FileWrite(this.getPath(it)); - case this.builtinImpurityReasons.FileWriteToParameterizedPath: - return new FileWrite(this.getParameter(node, it)); - case this.builtinImpurityReasons.PotentiallyImpureParameterCall: - return new PotentiallyImpureParameterCall(this.getParameter(node, it)); - case this.builtinImpurityReasons.Other: - return OtherImpurityReason; - default: - /* c8 ignore next */ - return EMPTY_STREAM; - } - }); - } - - private getPath(variant: EvaluatedEnumVariant): string | undefined { - const path = variant.getParameterValueByName('path'); - if (path instanceof StringConstant) { - return path.value; - } else { - return undefined; - } - } - - private getParameter(node: TslFunction, variant: EvaluatedEnumVariant): TslParameter | undefined { - const parameterName = variant.getParameterValueByName('parameterName'); - if (!(parameterName instanceof StringConstant)) { - return undefined; - } - - return getParameters(node).find((it) => it.name === parameterName.value); - } - - private getNodeId(node: AstNode) { - const documentUri = AstUtils.getDocument(node).uri.toString(); - const nodePath = this.astNodeLocator.getAstNodePath(node); - return `${documentUri}~${nodePath}`; - } -} - -const NO_SUBSTITUTIONS: ParameterSubstitutions = new Map(); diff --git a/packages/ttsl-lang/src/language/safe-ds-module.ts b/packages/ttsl-lang/src/language/safe-ds-module.ts index 3f5db0a6..76b37485 100644 --- a/packages/ttsl-lang/src/language/safe-ds-module.ts +++ b/packages/ttsl-lang/src/language/safe-ds-module.ts @@ -7,9 +7,6 @@ import { LangiumSharedServices, PartialLangiumServices, } from 'langium/lsp'; -import { SafeDsAnnotations } from './builtins/safe-ds-annotations.js'; -import { SafeDsClasses } from './builtins/safe-ds-classes.js'; -import { SafeDsEnums, SafeDsImpurityReasons } from './builtins/safe-ds-enums.js'; import { SafeDsCommentProvider } from './documentation/safe-ds-comment-provider.js'; import { SafeDsDocumentationProvider } from './documentation/safe-ds-documentation-provider.js'; import { SafeDsCallGraphComputer } from './flow/safe-ds-call-graph-computer.js'; @@ -40,16 +37,14 @@ import { SafeDsPurityComputer } from './purity/safe-ds-purity-computer.js'; import { SafeDsSettingsProvider } from './workspace/safe-ds-settings-provider.js'; import { SafeDsRenameProvider } from './lsp/safe-ds-rename-provider.js'; import { SafeDsTypeFactory } from './typing/safe-ds-type-factory.js'; +import { TTSLFunction } from './builtins/ttsl-ds-functions.js'; /** * Declaration of custom services - add your own service classes here. */ export type SafeDsAddedServices = { builtins: { - Annotations: SafeDsAnnotations; - Classes: SafeDsClasses; - Enums: SafeDsEnums; - ImpurityReasons: SafeDsImpurityReasons; + Functions: TTSLFunction; }; evaluation: { PartialEvaluator: SafeDsPartialEvaluator; @@ -95,10 +90,7 @@ export type SafeDsServices = LangiumServices & SafeDsAddedServices; */ export const SafeDsModule: Module = { builtins: { - Annotations: (services) => new SafeDsAnnotations(services), - Classes: (services) => new SafeDsClasses(services), - Enums: (services) => new SafeDsEnums(services), - ImpurityReasons: (services) => new SafeDsImpurityReasons(services), + Functions: (services) => new TTSLFunction(services), }, documentation: { CommentProvider: (services) => new SafeDsCommentProvider(services), diff --git a/packages/ttsl-lang/src/language/validation/builtins/deprecated.ts b/packages/ttsl-lang/src/language/validation/builtins/deprecated.ts deleted file mode 100644 index 890aef30..00000000 --- a/packages/ttsl-lang/src/language/validation/builtins/deprecated.ts +++ /dev/null @@ -1,76 +0,0 @@ -import { ValidationAcceptor } from 'langium'; -import { DiagnosticTag } from 'vscode-languageserver'; -import { - isTslParameter, - isTslResult, - TslArgument, - TslAssignee, - TslParameter, - TslReference, -} from '../../generated/ast.js'; -import { Parameter } from '../../helpers/nodeProperties.js'; -import { SafeDsServices } from '../../safe-ds-module.js'; - -export const CODE_DEPRECATED_LIBRARY_ELEMENT = 'deprecated/library-element'; -export const CODE_DEPRECATED_REQUIRED_PARAMETER = 'deprecated/required-parameter'; - -export const assigneeAssignedResultShouldNotBeDeprecated = - (services: SafeDsServices) => (node: TslAssignee, accept: ValidationAcceptor) => { - const assignedObject = services.helpers.NodeMapper.assigneeToAssignedObject(node); - if (!isTslResult(assignedObject)) { - return; - } - - if (services.builtins.Annotations.callsDeprecated(assignedObject)) { - accept('warning', `The assigned result '${assignedObject.name}' is deprecated.`, { - node, - code: CODE_DEPRECATED_LIBRARY_ELEMENT, - tags: [DiagnosticTag.Deprecated], - }); - } - }; - -export const argumentCorrespondingParameterShouldNotBeDeprecated = - (services: SafeDsServices) => (node: TslArgument, accept: ValidationAcceptor) => { - const parameter = services.helpers.NodeMapper.argumentToParameter(node); - if (!parameter) { - return; - } - - if (services.builtins.Annotations.callsDeprecated(parameter)) { - accept('warning', `The corresponding parameter '${parameter.name}' is deprecated.`, { - node, - code: CODE_DEPRECATED_LIBRARY_ELEMENT, - tags: [DiagnosticTag.Deprecated], - }); - } - }; - -export const referenceTargetShouldNotBeDeprecated = - (services: SafeDsServices) => (node: TslReference, accept: ValidationAcceptor) => { - const target = node.target.ref; - if (!target || isTslParameter(target)) { - return; - } - - if (services.builtins.Annotations.callsDeprecated(target)) { - accept('warning', `The referenced declaration '${target.name}' is deprecated.`, { - node, - code: CODE_DEPRECATED_LIBRARY_ELEMENT, - tags: [DiagnosticTag.Deprecated], - }); - } - }; - -export const requiredParameterMustNotBeDeprecated = - (services: SafeDsServices) => (node: TslParameter, accept: ValidationAcceptor) => { - if (Parameter.isRequired(node)) { - if (services.builtins.Annotations.callsDeprecated(node)) { - accept('error', 'A deprecated parameter must be optional.', { - node, - property: 'name', - code: CODE_DEPRECATED_REQUIRED_PARAMETER, - }); - } - } - }; diff --git a/packages/ttsl-lang/src/language/validation/builtins/experimental.ts b/packages/ttsl-lang/src/language/validation/builtins/experimental.ts deleted file mode 100644 index f1548501..00000000 --- a/packages/ttsl-lang/src/language/validation/builtins/experimental.ts +++ /dev/null @@ -1,80 +0,0 @@ -import { ValidationAcceptor } from 'langium'; -import { - isTslParameter, - isTslResult, - TslArgument, - TslAssignee, - TslReference, -} from '../../generated/ast.js'; -import { SafeDsServices } from '../../safe-ds-module.js'; - -export const CODE_EXPERIMENTAL_LIBRARY_ELEMENT = 'experimental/library-element'; - -export const assigneeAssignedResultShouldNotBeExperimental = (services: SafeDsServices) => { - const settingsProvider = services.workspace.SettingsProvider; - - return async (node: TslAssignee, accept: ValidationAcceptor) => { - if (!(await settingsProvider.shouldValidateExperimentalLibraryElement())) { - /* c8 ignore next 2 */ - return; - } - - const assignedObject = services.helpers.NodeMapper.assigneeToAssignedObject(node); - if (!isTslResult(assignedObject)) { - return; - } - - if (services.builtins.Annotations.callsExperimental(assignedObject)) { - accept('warning', `The assigned result '${assignedObject.name}' is experimental.`, { - node, - code: CODE_EXPERIMENTAL_LIBRARY_ELEMENT, - }); - } - }; -}; - -export const argumentCorrespondingParameterShouldNotBeExperimental = (services: SafeDsServices) => { - const settingsProvider = services.workspace.SettingsProvider; - - return async (node: TslArgument, accept: ValidationAcceptor) => { - if (!(await settingsProvider.shouldValidateExperimentalLibraryElement())) { - /* c8 ignore next 2 */ - return; - } - - const parameter = services.helpers.NodeMapper.argumentToParameter(node); - if (!parameter) { - return; - } - - if (services.builtins.Annotations.callsExperimental(parameter)) { - accept('warning', `The corresponding parameter '${parameter.name}' is experimental.`, { - node, - code: CODE_EXPERIMENTAL_LIBRARY_ELEMENT, - }); - } - }; -}; - -export const referenceTargetShouldNotExperimental = (services: SafeDsServices) => { - const settingsProvider = services.workspace.SettingsProvider; - - return async (node: TslReference, accept: ValidationAcceptor) => { - if (!(await settingsProvider.shouldValidateExperimentalLibraryElement())) { - /* c8 ignore next 2 */ - return; - } - - const target = node.target.ref; - if (!target || isTslParameter(target)) { - return; - } - - if (services.builtins.Annotations.callsExperimental(target)) { - accept('warning', `The referenced declaration '${target.name}' is experimental.`, { - node, - code: CODE_EXPERIMENTAL_LIBRARY_ELEMENT, - }); - } - }; -}; diff --git a/packages/ttsl-lang/src/language/validation/builtins/expert.ts b/packages/ttsl-lang/src/language/validation/builtins/expert.ts deleted file mode 100644 index 2ec2ed67..00000000 --- a/packages/ttsl-lang/src/language/validation/builtins/expert.ts +++ /dev/null @@ -1,19 +0,0 @@ -import { ValidationAcceptor } from 'langium'; -import { TslParameter } from '../../generated/ast.js'; -import { Parameter } from '../../helpers/nodeProperties.js'; -import { SafeDsServices } from '../../safe-ds-module.js'; - -export const CODE_EXPERT_TARGET_PARAMETER = 'expert/target-parameter'; - -export const requiredParameterMustNotBeExpert = - (services: SafeDsServices) => (node: TslParameter, accept: ValidationAcceptor) => { - if (Parameter.isRequired(node)) { - if (services.builtins.Annotations.callsExpert(node)) { - accept('error', 'An expert parameter must be optional.', { - node, - property: 'name', - code: CODE_EXPERT_TARGET_PARAMETER, - }); - } - } - }; diff --git a/packages/ttsl-lang/src/language/validation/builtins/pythonCall.ts b/packages/ttsl-lang/src/language/validation/builtins/pythonCall.ts deleted file mode 100644 index 1efdd255..00000000 --- a/packages/ttsl-lang/src/language/validation/builtins/pythonCall.ts +++ /dev/null @@ -1,40 +0,0 @@ -import { ValidationAcceptor } from 'langium'; -import { TslFunction } from '../../generated/ast.js'; -import { SafeDsServices } from '../../safe-ds-module.js'; -import { getParameters } from '../../helpers/nodeProperties.js'; -import { pluralize } from '../../../helpers/strings.js'; - -export const CODE_PYTHON_CALL_INVALID_TEMPLATE_EXPRESSION = 'python-call/invalid-template-expression'; - -export const pythonCallMustOnlyContainValidTemplateExpressions = (services: SafeDsServices) => { - const builtinAnnotations = services.builtins.Annotations; - - return (node: TslFunction, accept: ValidationAcceptor) => { - const pythonCall = builtinAnnotations.getPythonCall(node); - if (!pythonCall) { - return; - } - - // Get actual template expressions - const match = pythonCall.matchAll(/\$[_a-zA-Z][_a-zA-Z0-9]*/gu); - const actualTemplateExpressions = [...match].map((it) => it[0]); - - // Compute valid template expressions - const validTemplateExpressions = new Set(getParameters(node).map((it) => `\$${it.name}`)); - - // Compute invalid template expressions - const invalidTemplateExpressions = actualTemplateExpressions.filter((it) => !validTemplateExpressions.has(it)); - - // Report invalid template expressions - if (invalidTemplateExpressions.length > 0) { - const kind = pluralize(invalidTemplateExpressions.length, 'template expression'); - const invalidTemplateExpressionsString = invalidTemplateExpressions.map((it) => `'${it}'`).join(', '); - - accept('error', `The ${kind} ${invalidTemplateExpressionsString} cannot be interpreted.`, { - node: builtinAnnotations.PythonCall!, - property: 'annotation', - code: CODE_PYTHON_CALL_INVALID_TEMPLATE_EXPRESSION, - }); - } - }; -}; diff --git a/packages/ttsl-lang/src/language/validation/builtins/pythonModule.ts b/packages/ttsl-lang/src/language/validation/builtins/pythonModule.ts deleted file mode 100644 index 791c216e..00000000 --- a/packages/ttsl-lang/src/language/validation/builtins/pythonModule.ts +++ /dev/null @@ -1,27 +0,0 @@ -import { ValidationAcceptor } from 'langium'; -import { TslModule } from '../../generated/ast.js'; -import { SafeDsServices } from '../../safe-ds-module.js'; - -export const CODE_PYTHON_MODULE_SAME_AS_SAFE_DS_PACKAGE = 'python-module/same-as-safe-ds-package'; - -export const pythonModuleShouldDifferFromSafeDsPackage = (services: SafeDsServices) => { - const builtinAnnotations = services.builtins.Annotations; - - return (node: TslModule, accept: ValidationAcceptor) => { - const pythonModule = builtinAnnotations.getPythonModule(node); - if (!pythonModule || pythonModule !== node.name) { - return; - } - - const annotationCall = builtinAnnotations.PythonModule!; - accept( - 'info', - 'The Python module is identical to the Safe-DS package, so the annotation call can be removed.', - { - node: annotationCall, - property: 'annotation', - code: CODE_PYTHON_MODULE_SAME_AS_SAFE_DS_PACKAGE, - }, - ); - }; -}; diff --git a/packages/ttsl-lang/src/language/validation/builtins/pythonName.ts b/packages/ttsl-lang/src/language/validation/builtins/pythonName.ts deleted file mode 100644 index 1ae75951..00000000 --- a/packages/ttsl-lang/src/language/validation/builtins/pythonName.ts +++ /dev/null @@ -1,42 +0,0 @@ -import { ValidationAcceptor } from 'langium'; -import { TslDeclaration, TslFunction } from '../../generated/ast.js'; -import { SafeDsServices } from '../../safe-ds-module.js'; - -export const CODE_PYTHON_NAME_MUTUALLY_EXCLUSIVE_WITH_PYTHON_CALL = 'python-name/mutually-exclusive-with-python-call'; -export const CODE_PYTHON_NAME_SAME_AS_SAFE_DS_NAME = 'python-name/same-as-safe-ds-name'; - -export const pythonNameMustNotBeSetIfPythonCallIsSet = (services: SafeDsServices) => { - const builtinAnnotations = services.builtins.Annotations; - - return (node: TslFunction, accept: ValidationAcceptor) => { - - const firstPythonName = builtinAnnotations.PythonName; - if (!firstPythonName) { - return; - } - - accept('error', 'A Python name must not be set if a Python call is set.', { - node: firstPythonName, - property: 'annotation', - code: CODE_PYTHON_NAME_MUTUALLY_EXCLUSIVE_WITH_PYTHON_CALL, - }); - }; -}; - -export const pythonNameShouldDifferFromSafeDsName = (services: SafeDsServices) => { - const builtinAnnotations = services.builtins.Annotations; - - return (node: TslDeclaration, accept: ValidationAcceptor) => { - const pythonName = builtinAnnotations.getPythonName(node); - if (!pythonName || pythonName !== node.name) { - return; - } - - const annotationCall = builtinAnnotations.PythonName!; - accept('info', 'The Python name is identical to the Safe-DS name, so the annotation call can be removed.', { - node: annotationCall, - property: 'annotation', - code: CODE_PYTHON_NAME_SAME_AS_SAFE_DS_NAME, - }); - }; -}; diff --git a/packages/ttsl-lang/src/language/validation/purity.ts b/packages/ttsl-lang/src/language/validation/purity.ts deleted file mode 100644 index 808f7ef1..00000000 --- a/packages/ttsl-lang/src/language/validation/purity.ts +++ /dev/null @@ -1,245 +0,0 @@ -import { stream, type ValidationAcceptor } from 'langium'; -import { isSubset } from '../../helpers/collections.js'; -import { isTslCall, isTslFunction, isTslList, TslCall, type TslFunction, TslParameter } from '../generated/ast.js'; -import { getArguments, getParameters } from '../helpers/nodeProperties.js'; -import { StringConstant } from '../partialEvaluation/model.js'; -import type { SafeDsServices } from '../safe-ds-module.js'; -import { CallableType } from '../typing/model.js'; - -export const CODE_PURITY_DUPLICATE_IMPURITY_REASON = 'purity/duplicate-impurity-reason'; -export const CODE_PURITY_IMPURE_AND_PURE = 'purity/impure-and-pure'; -export const CODE_PURITY_IMPURITY_REASONS_OF_OVERRIDING_METHOD = 'purity/impurity-reasons-of-overriding-method'; -export const CODE_PURITY_INVALID_PARAMETER_NAME = 'purity/invalid-parameter-name'; -export const CODE_PURITY_MUST_BE_SPECIFIED = 'purity/must-be-specified'; -export const CODE_PURITY_POTENTIALLY_IMPURE_PARAMETER_NOT_CALLABLE = 'purity/potentially-impure-parameter-not-callable'; -export const CODE_PURITY_PURE_PARAMETER_SET_TO_IMPURE_CALLABLE = 'purity/pure-parameter-set-to-impure-callable'; - -export const impurityReasonsOfOverridingMethodMustBeSubsetOfOverriddenMethod = (services: SafeDsServices) => { - const builtinAnnotations = services.builtins.Annotations; - const classHierarchy = services.types.ClassHierarchy; - - return (node: TslFunction, accept: ValidationAcceptor): void => { - const overriddenMember = classHierarchy.getOverriddenMember(node); - if (!overriddenMember || !isTslFunction(overriddenMember)) { - return; - } - - // Don't further validate if the function is marked as impure and as pure - if (builtinAnnotations.callsImpure(node) && builtinAnnotations.callsPure(node)) { - return; - } - - if ( - !isSubset( - builtinAnnotations - .streamImpurityReasons(node) - .map((it) => it.toString()) - .toSet(), - builtinAnnotations - .streamImpurityReasons(overriddenMember) - .map((it) => it.toString()) - .toSet(), - ) - ) { - accept( - 'error', - 'The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function.', - { - node, - property: 'name', - code: CODE_PURITY_IMPURITY_REASONS_OF_OVERRIDING_METHOD, - }, - ); - } - }; -}; - -export const impurityReasonParameterNameMustBelongToParameterOfCorrectType = (services: SafeDsServices) => { - const builtinAnnotations = services.builtins.Annotations; - const builtinEnums = services.builtins.Enums; - const impurityReasons = services.builtins.ImpurityReasons; - const nodeMapper = services.helpers.NodeMapper; - const partialEvaluator = services.evaluation.PartialEvaluator; - const typeComputer = services.types.TypeComputer; - - return (node: TslFunction, accept: ValidationAcceptor) => { - const annotationCall = builtinAnnotations.Impure; - - // Don't further validate if the function is marked as impure and as pure - if (!annotationCall || builtinAnnotations.callsPure(node)) { - return; - } - - // Check whether allReasons is valid - const allReasons = nodeMapper.callToParameterValue(annotationCall, 'allReasons'); - if (!isTslList(allReasons)) { - return; - } - - const parameterNames = stream(getParameters(node)) - .map((it) => it.name) - .toSet(); - - for (const reason of allReasons.elements) { - // If it's not a call, no parameter name could've been provided - if (!isTslCall(reason)) { - continue; - } - - // Check whether the reason is valid - const evaluatedReason = partialEvaluator.evaluate(reason); - if (!builtinEnums.isEvaluatedImpurityReason(evaluatedReason)) { - continue; - } - - // Check whether a parameter name was provided - const parameterName = nodeMapper.callToParameterValue(reason, 'parameterName'); - if (!parameterName) { - continue; - } - - // Check whether parameterName is valid - const evaluatedParameterName = partialEvaluator.evaluate(parameterName); - if (!(evaluatedParameterName instanceof StringConstant)) { - continue; - } - - // A parameter with the given name must exist - if (!parameterNames.has(evaluatedParameterName.value)) { - const parameterNameArgument = getArguments(reason).find( - (it) => nodeMapper.argumentToParameter(it)?.name === 'parameterName', - )!; - - accept('error', `The parameter '${evaluatedParameterName.value}' does not exist.`, { - node: parameterNameArgument, - code: CODE_PURITY_INVALID_PARAMETER_NAME, - }); - - continue; - } - - // The parameter must have the correct type - if (evaluatedReason.variant === impurityReasons.PotentiallyImpureParameterCall) { - const parameter = getParameters(node).find((it) => it.name === evaluatedParameterName.value)!; - if (!parameter.type) { - continue; - } - - const parameterType = typeComputer.computeType(parameter); - if (parameterType instanceof CallableType) { - continue; - } - - const parameterNameArgument = getArguments(reason).find( - (it) => nodeMapper.argumentToParameter(it)?.name === 'parameterName', - )!; - - accept('error', `The parameter '${evaluatedParameterName.value}' must have a callable type.`, { - node: parameterNameArgument, - code: CODE_PURITY_POTENTIALLY_IMPURE_PARAMETER_NOT_CALLABLE, - }); - } - } - }; -}; - -export const impurityReasonShouldNotBeSetMultipleTimes = (services: SafeDsServices) => { - const builtinAnnotations = services.builtins.Annotations; - const builtinEnums = services.builtins.Enums; - const nodeMapper = services.helpers.NodeMapper; - const partialEvaluator = services.evaluation.PartialEvaluator; - - return (node: TslFunction, accept: ValidationAcceptor) => { - const annotationCall = builtinAnnotations.Impure; - - // Don't further validate if the function is marked as impure and as pure - if (!annotationCall || builtinAnnotations.callsPure(node)) { - return; - } - - // Check whether allReasons is valid - const allReasons = nodeMapper.callToParameterValue(annotationCall, 'allReasons'); - if (!isTslList(allReasons)) { - return; - } - - const knownReasons = new Set(); - for (const reason of allReasons.elements) { - // Check whether the reason is valid - const evaluatedReason = partialEvaluator.evaluate(reason); - if (!builtinEnums.isEvaluatedImpurityReason(evaluatedReason)) { - continue; - } - - const stringifiedReason = evaluatedReason.toString(); - if (knownReasons.has(stringifiedReason)) { - accept('warning', `The impurity reason '${stringifiedReason}' was set already.`, { - node: reason, - code: CODE_PURITY_DUPLICATE_IMPURITY_REASON, - }); - } else { - knownReasons.add(stringifiedReason); - } - } - }; -}; - -export const pureParameterDefaultValueMustBePure = (services: SafeDsServices) => { - const purityComputer = services.purity.PurityComputer; - const typeComputer = services.types.TypeComputer; - - return (node: TslParameter, accept: ValidationAcceptor) => { - if (!node.defaultValue) { - return; - } - - const parameterType = typeComputer.computeType(node); - if (!(parameterType instanceof CallableType) || !purityComputer.isPureParameter(node)) { - return; - } - - const defaultValueType = typeComputer.computeType(node.defaultValue); - if (!(defaultValueType instanceof CallableType)) { - return; - } - - if (!purityComputer.isPureCallable(defaultValueType.callable)) { - accept('error', 'Cannot pass an impure callable to a pure parameter.', { - node: node.defaultValue, - code: CODE_PURITY_PURE_PARAMETER_SET_TO_IMPURE_CALLABLE, - }); - } - }; -}; - -export const callArgumentAssignedToPureParameterMustBePure = (services: SafeDsServices) => { - const nodeMapper = services.helpers.NodeMapper; - const purityComputer = services.purity.PurityComputer; - const typeComputer = services.types.TypeComputer; - - return (node: TslCall, accept: ValidationAcceptor) => { - for (const argument of getArguments(node)) { - const parameter = nodeMapper.argumentToParameter(argument); - if (!parameter) { - continue; - } - - const parameterType = typeComputer.computeType(parameter); - if (!(parameterType instanceof CallableType) || !purityComputer.isPureParameter(parameter)) { - continue; - } - - const argumentType = typeComputer.computeType(argument); - if (!(argumentType instanceof CallableType)) { - continue; - } - - if (!purityComputer.isPureCallable(argumentType.callable)) { - accept('error', 'Cannot pass an impure callable to a pure parameter.', { - node: argument, - code: CODE_PURITY_PURE_PARAMETER_SET_TO_IMPURE_CALLABLE, - }); - } - } - }; -}; diff --git a/packages/ttsl-lang/src/language/validation/safe-ds-validator.ts b/packages/ttsl-lang/src/language/validation/safe-ds-validator.ts index 4d3c3a06..febd0d52 100644 --- a/packages/ttsl-lang/src/language/validation/safe-ds-validator.ts +++ b/packages/ttsl-lang/src/language/validation/safe-ds-validator.ts @@ -1,24 +1,6 @@ import { ValidationChecks } from 'langium'; import { TTSLAstType } from '../generated/ast.js'; import type { SafeDsServices } from '../safe-ds-module.js'; -import { - argumentCorrespondingParameterShouldNotBeDeprecated, - assigneeAssignedResultShouldNotBeDeprecated, - referenceTargetShouldNotBeDeprecated, - requiredParameterMustNotBeDeprecated, -} from './builtins/deprecated.js'; -import { - argumentCorrespondingParameterShouldNotBeExperimental, - assigneeAssignedResultShouldNotBeExperimental, - referenceTargetShouldNotExperimental, -} from './builtins/experimental.js'; -import { requiredParameterMustNotBeExpert } from './builtins/expert.js'; -import { pythonCallMustOnlyContainValidTemplateExpressions } from './builtins/pythonCall.js'; -import { pythonModuleShouldDifferFromSafeDsPackage } from './builtins/pythonModule.js'; -import { - pythonNameMustNotBeSetIfPythonCallIsSet, - pythonNameShouldDifferFromSafeDsName, -} from './builtins/pythonName.js'; import { mapsShouldBeUsedWithCaution, } from './experimentalLanguageFeatures.js'; @@ -61,13 +43,6 @@ import { callableTypeMustNotHaveOptionalParameters, callableTypeParameterMustNotHaveConstModifier, } from './other/types/callableTypes.js'; -import { - callArgumentAssignedToPureParameterMustBePure, - impurityReasonParameterNameMustBelongToParameterOfCorrectType, - impurityReasonShouldNotBeSetMultipleTimes, - impurityReasonsOfOverridingMethodMustBeSubsetOfOverriddenMethod, - pureParameterDefaultValueMustBePure, -} from './purity.js'; import { callArgumentListShouldBeNeeded, chainedExpressionNullSafetyShouldBeNeeded, @@ -101,8 +76,6 @@ export const registerValidationChecks = function (services: SafeDsServices) { const registry = services.validation.ValidationRegistry; const checks: ValidationChecks = { TslAssignee: [ - assigneeAssignedResultShouldNotBeDeprecated(services), - assigneeAssignedResultShouldNotBeExperimental(services), ], TslAssignment: [ assignmentAssigneeMustGetValue(services), @@ -113,8 +86,6 @@ export const registerValidationChecks = function (services: SafeDsServices) { argumentListMustSetAllRequiredParameters(services), ], TslArgument: [ - argumentCorrespondingParameterShouldNotBeDeprecated(services), - argumentCorrespondingParameterShouldNotBeExperimental(services), ], TslArgumentList: [ argumentListMustNotHavePositionalArgumentsAfterNamedArguments, @@ -125,7 +96,6 @@ export const registerValidationChecks = function (services: SafeDsServices) { ], TslCall: [ callArgumentListShouldBeNeeded(services), - callArgumentAssignedToPureParameterMustBePure(services), callArgumentMustBeConstantIfParameterIsConstant(services), callArgumentTypesMustMatchParameterTypes(services), callMustNotBeRecursive(services), @@ -145,15 +115,9 @@ export const registerValidationChecks = function (services: SafeDsServices) { nameMustNotOccurOnCoreDeclaration(services), nameMustNotStartWithCodegenPrefix, nameShouldHaveCorrectCasing(services), - pythonNameShouldDifferFromSafeDsName(services), ], TslFunction: [ functionResultListShouldNotBeEmpty(services), - impurityReasonsOfOverridingMethodMustBeSubsetOfOverriddenMethod(services), - impurityReasonParameterNameMustBelongToParameterOfCorrectType(services), - impurityReasonShouldNotBeSetMultipleTimes(services), - pythonCallMustOnlyContainValidTemplateExpressions(services), - pythonNameMustNotBeSetIfPythonCallIsSet(services), groupedFunctionHasAggregation(), groupedFunctionHasValidID(), ], @@ -175,24 +139,18 @@ export const registerValidationChecks = function (services: SafeDsServices) { moduleMemberMustHaveNameThatIsUniqueInPackage(services), moduleMustContainUniqueNames, moduleWithDeclarationsMustStatePackage, - pythonModuleShouldDifferFromSafeDsPackage(services), ], TslParameter: [ constantParameterMustHaveConstantDefaultValue(services), constantParameterMustHaveTypeThatCanBeEvaluatedToConstant(services), parameterMustHaveTypeHint, parameterDefaultValueTypeMustMatchParameterType(services), - pureParameterDefaultValueMustBePure(services), - requiredParameterMustNotBeDeprecated(services), - requiredParameterMustNotBeExpert(services), ], TslParameterList: [parameterListMustNotHaveRequiredParametersAfterOptionalParameters], TslPlaceholder: [placeholdersMustNotBeAnAlias, placeholderShouldBeUsed(services)], TslPrefixOperation: [prefixOperationOperandMustHaveCorrectType(services)], TslReference: [ referenceMustNotBeFunctionPointer, - referenceTargetShouldNotBeDeprecated(services), - referenceTargetShouldNotExperimental(services), ], TslResult: [resultMustHaveTypeHint], TslStatement: [statementMustDoSomething(services)], diff --git a/packages/ttsl-lang/src/language/validation/types.ts b/packages/ttsl-lang/src/language/validation/types.ts index 14659579..eda0ad93 100644 --- a/packages/ttsl-lang/src/language/validation/types.ts +++ b/packages/ttsl-lang/src/language/validation/types.ts @@ -102,7 +102,6 @@ export const indexedAccessReceiverMustBeListOrMap = (services: SafeDsServices) = }; export const indexedAccessIndexMustHaveCorrectType = (services: SafeDsServices) => { - const coreClasses = services.builtins.Classes; const coreTypes = services.types.CoreTypes; const typeChecker = services.types.TypeChecker; const typeComputer = services.types.TypeComputer; From c12da33be785b24945fc27f734f5b63b664fcc4d Mon Sep 17 00:00:00 2001 From: methr0 Date: Fri, 28 Jun 2024 12:14:54 +0200 Subject: [PATCH 091/183] remove unnecessary node mapper functions --- .../language/helpers/safe-ds-node-mapper.ts | 104 +----------------- 1 file changed, 6 insertions(+), 98 deletions(-) diff --git a/packages/ttsl-lang/src/language/helpers/safe-ds-node-mapper.ts b/packages/ttsl-lang/src/language/helpers/safe-ds-node-mapper.ts index 80fbd0ae..bf68d56f 100644 --- a/packages/ttsl-lang/src/language/helpers/safe-ds-node-mapper.ts +++ b/packages/ttsl-lang/src/language/helpers/safe-ds-node-mapper.ts @@ -1,22 +1,14 @@ import { AstUtils, EMPTY_STREAM, Stream } from 'langium'; import { isTslAbstractCall, - isTslAnnotationCall, isTslAssignment, isTslBlock, isTslCall, isTslCallable, - isTslClass, - isTslEnumVariant, - isTslExpressionLambda, - isTslNamedType, isTslParameter, isTslReference, - isTslSegment, isTslType, - isTslYield, TslAbstractCall, - TslAbstractResult, TslArgument, TslAssignee, TslCallable, @@ -25,21 +17,15 @@ import { TslPlaceholder, TslReference, TslResult, - TslTypeArgument, - TslTypeParameter, - TslYield, } from '../generated/ast.js'; import { SafeDsServices } from '../safe-ds-module.js'; -import { CallableType, StaticType } from '../typing/model.js'; +import { CallableType } from '../typing/model.js'; import { SafeDsTypeComputer } from '../typing/safe-ds-type-computer.js'; import { Argument, - getAbstractResults, getArguments, getParameters, - getTypeArguments, - getTypeParameters, - TypeArgument, + getResults, } from './nodeProperties.js'; export class SafeDsNodeMapper { @@ -88,7 +74,7 @@ export class SafeDsNodeMapper { * Returns the result, block lambda result, or expression that is assigned to the given assignee. If nothing is * assigned, `undefined` is returned. */ - assigneeToAssignedObject(node: TslAssignee | undefined): TslAbstractResult | TslExpression | undefined { + assigneeToAssignedObject(node: TslAssignee | undefined): TslResult | TslExpression | undefined { if (!node) { return undefined; } @@ -112,27 +98,10 @@ export class SafeDsNodeMapper { } } - // If the RHS instantiates a class or enum variant, the first assignee gets the entire RHS const callable = this.callToCallable(expression); - if (isTslClass(callable) || isTslEnumVariant(callable)) { - if (assigneePosition === 0) { - return expression; - } else { - return undefined; - } - } - - // If the RHS calls an expression lambda, the first assignee gets its result - if (isTslExpressionLambda(callable)) { - if (assigneePosition === 0) { - return callable.result; - } else { - return undefined; - } - } // Otherwise, the assignee gets the result at the same position - const abstractResults = getAbstractResults(callable); + const abstractResults = getResults(callable); return abstractResults[assigneePosition]; } @@ -143,10 +112,8 @@ export class SafeDsNodeMapper { if (!node) { return undefined; } - - if (isTslAnnotationCall(node)) { - return node.annotation?.ref; - } else if (isTslCall(node)) { + + if (isTslCall(node)) { // We ignore nullability, since calls can be made null-safe. For scoping, for instance, we still want to // link the arguments of the call properly, even if the user forgot to make the call null-safe. In this // case, an error is being shown anyway. @@ -155,11 +122,6 @@ export class SafeDsNodeMapper { if (nonNullableReceiverType instanceof CallableType) { return nonNullableReceiverType.callable; - } else if (nonNullableReceiverType instanceof StaticType) { - const declaration = nonNullableReceiverType.instanceType.declaration; - if (isTslCallable(declaration)) { - return declaration; - } } } @@ -280,58 +242,4 @@ export class SafeDsNodeMapper { .map((it) => it.$refNode?.astNode) .filter(isTslReference); } - - /** - * Returns all yields that assign to the given result. - */ - resultToYields(node: TslResult | undefined): Stream { - if (!node) { - return EMPTY_STREAM; - } - - const containingSegment = AstUtils.getContainerOfType(node, isTslSegment); - if (!containingSegment) { - return EMPTY_STREAM; - } - - return AstUtils.findLocalReferences(node, containingSegment) - .map((it) => it.$refNode?.astNode) - .filter(isTslYield); - } - - /** - * Returns the type parameter that the type argument is assigned to. If there is no matching type parameter, returns - * `undefined`. - */ - typeArgumentToTypeParameter(node: TslTypeArgument | undefined): TslTypeParameter | undefined { - if (!node) { - return undefined; - } - - // Named type argument - if (node.typeParameter) { - return node.typeParameter.ref; - } - - // Positional type argument - const containingType = AstUtils.getContainerOfType(node, isTslType); - if (!isTslNamedType(containingType)) { - return undefined; - } - - const typeArguments = getTypeArguments(containingType.typeArgumentList); - const typeArgumentPosition = node.$containerIndex ?? -1; - - // A prior type argument is named - for (let i = 0; i < typeArgumentPosition; i++) { - if (TypeArgument.isNamed(typeArguments[i]!)) { - return undefined; - } - } - - // Find type parameter at the same position - const namedTypeDeclaration = containingType.declaration?.ref; - const typeParameters = getTypeParameters(namedTypeDeclaration); - return typeParameters[typeArgumentPosition]; - } } From 7c992cbdb9dd0b22c9262d4a53b993a35a52632a Mon Sep 17 00:00:00 2001 From: methr0 Date: Sat, 29 Jun 2024 10:25:10 +0200 Subject: [PATCH 092/183] remove use of purity functions --- .../generation/safe-ds-python-generator.ts | 141 +----------------- .../ttsl-lang/src/language/safe-ds-module.ts | 7 - .../validation/other/statements/statements.ts | 18 --- 3 files changed, 6 insertions(+), 160 deletions(-) delete mode 100644 packages/ttsl-lang/src/language/validation/other/statements/statements.ts diff --git a/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts b/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts index d35fde07..fd23181a 100644 --- a/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts +++ b/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts @@ -3,7 +3,6 @@ import { CompositeGeneratorNode, expandToNode, expandTracedToNode, - IndentNode, joinToNode, joinTracedToNode, NL, @@ -27,7 +26,6 @@ import { isTslDictionary, isTslMemberAccess, isTslModule, - isTslParameter, isTslPlaceholder, isTslPrefixOperation, isTslQualifiedImport, @@ -67,7 +65,6 @@ import { isTslBlock, TslTimeunit, isTslExpression, - TslModuleMember, } from '../generated/ast.js'; import { isInStubFile, isStubFile } from '../helpers/fileExtensions.js'; import { @@ -83,18 +80,8 @@ import { Parameter, } from '../helpers/nodeProperties.js'; import { SafeDsNodeMapper } from '../helpers/safe-ds-node-mapper.js'; -import { - BooleanConstant, - FloatConstant, - IntConstant, - NullConstant, - StringConstant, -} from '../partialEvaluation/model.js'; import { SafeDsPartialEvaluator } from '../partialEvaluation/safe-ds-partial-evaluator.js'; import { SafeDsServices } from '../safe-ds-module.js'; -import { SafeDsPurityComputer } from '../purity/safe-ds-purity-computer.js'; -import { FileRead, ImpurityReason } from '../purity/model.js'; -import { SafeDsModuleMembers } from '../builtins/safe-ds-module-members.js'; import { TTSLFunction } from '../builtins/ttsl-ds-functions.js'; export const CODEGEN_PREFIX = '__gen_'; @@ -297,13 +284,11 @@ export class SafeDsPythonGenerator { private readonly builtinFunction: TTSLFunction; private readonly nodeMapper: SafeDsNodeMapper; private readonly partialEvaluator: SafeDsPartialEvaluator; - private readonly purityComputer: SafeDsPurityComputer; constructor(services: SafeDsServices) { this.builtinFunction = services.builtins.Functions; this.nodeMapper = services.helpers.NodeMapper; this.partialEvaluator = services.evaluation.PartialEvaluator; - this.purityComputer = services.purity.PurityComputer; } generate(document: LangiumDocument, generateOptions: GenerateOptions): TextDocument[] { @@ -537,7 +522,7 @@ export class SafeDsPythonGenerator { timeunit: TslTimeunit | undefined, ): CompositeGeneratorNode { const targetPlaceholder = getPlaceholderByName(block, frame.targetPlaceholder); - let statements = getStatements(block)/*.filter((stmt) => this.purityComputer.statementDoesSomething(stmt))*/; + let statements = getStatements(block); if (targetPlaceholder) { statements = this.getStatementsNeededForPartialExecution(targetPlaceholder, statements); } @@ -724,7 +709,7 @@ export class SafeDsPythonGenerator { generateLambda: boolean = false, ): CompositeGeneratorNode { const targetPlaceholder = getPlaceholderByName(block, frame.targetPlaceholder); - let statements = getStatements(block)/*.filter((stmt) => this.purityComputer.statementDoesSomething(stmt))*/; + let statements = getStatements(block); if (targetPlaceholder) { statements = this.getStatementsNeededForPartialExecution(targetPlaceholder, statements); } @@ -758,28 +743,20 @@ export class SafeDsPythonGenerator { .map((reference) => reference.target.ref!) .toArray(), ); - const impurityReasons = new Set(this.purityComputer.getImpurityReasonsForStatement(assignment)); const collectedStatements: TslStatement[] = [assignment]; for (const prevStatement of statementsWithEffect.reverse()) { // Statements after the target assignment can always be skipped if (prevStatement.$containerIndex! >= assignment.$containerIndex!) { continue; } - const prevStmtImpurityReasons: ImpurityReason[] = - this.purityComputer.getImpurityReasonsForStatement(prevStatement); if ( // Placeholder is relevant (isTslAssignment(prevStatement) && getAssignees(prevStatement) .filter(isTslPlaceholder) - .some((prevPlaceholder) => referencedPlaceholders.has(prevPlaceholder))) || - // Impurity is relevant - prevStmtImpurityReasons.some((pastReason) => - Array.from(impurityReasons).some((futureReason) => - pastReason.canAffectFutureImpurityReason(futureReason), - ), + .some((prevPlaceholder) => referencedPlaceholders.has(prevPlaceholder))) ) - ) { + { collectedStatements.push(prevStatement); // Collect all referenced placeholders if (isTslExpressionStatement(prevStatement) || isTslAssignment(prevStatement)) { @@ -791,10 +768,6 @@ export class SafeDsPythonGenerator { referencedPlaceholders.add(prevPlaceholder); }); } - // Collect impurity reasons - prevStmtImpurityReasons.forEach((prevReason) => { - impurityReasons.add(prevReason); - }); } } // Get all statements in sorted order @@ -922,21 +895,6 @@ export class SafeDsPythonGenerator { } } - if (!this.purityComputer.expressionHasSideEffects(expression)) { - const partiallyEvaluatedNode = this.partialEvaluator.evaluate(expression); - if (partiallyEvaluatedNode instanceof BooleanConstant) { - return traceToNode(expression)(partiallyEvaluatedNode.value ? 'True' : 'False'); - } else if (partiallyEvaluatedNode instanceof IntConstant) { - return traceToNode(expression)(String(partiallyEvaluatedNode.value)); - } else if (partiallyEvaluatedNode instanceof FloatConstant) { - const floatValue = partiallyEvaluatedNode.value; - return traceToNode(expression)(Number.isInteger(floatValue) ? `${floatValue}.0` : String(floatValue)); - } else if (partiallyEvaluatedNode === NullConstant) { - return traceToNode(expression)('None'); - } else if (partiallyEvaluatedNode instanceof StringConstant) { - return expandTracedToNode(expression)`'${this.formatStringSingleLine(partiallyEvaluatedNode.value)}'`; - } - } // Handled after constant expressions: EnumVariant, List, Dictionary if (isTslTemplateString(expression)) { @@ -983,13 +941,6 @@ export class SafeDsPythonGenerator { call = this.generatePythonCall(expression, pythonCall, argumentsMap, frame, thisParam); } } - if (!call && this.isMemoizableCall(expression) && !frame.disableRunnerIntegration) { - let thisParam: CompositeGeneratorNode | undefined = undefined; - if (isTslMemberAccess(expression.receiver)) { - thisParam = this.generateExpression(expression.receiver.receiver, frame); - } - call = this.generateMemoizedCall(expression, sortedArgs, frame, thisParam); - } } if (!call) { @@ -1142,11 +1093,10 @@ export class SafeDsPythonGenerator { { separator: '' }, )!; // Non-memoizable calls can be directly generated - if (!this.isMemoizableCall(expression) || frame.disableRunnerIntegration) { + if (frame.disableRunnerIntegration) { return generatedPythonCall; } frame.addImport({ importPath: RUNNER_PACKAGE }); - const hiddenParameters = this.getMemoizedCallHiddenParameters(expression, frame); const callable = this.nodeMapper.callToCallable(expression); const memoizedArgs = getParameters(callable).map( (parameter) => this.nodeMapper.callToParameterValue(expression, parameter)!, @@ -1159,86 +1109,7 @@ export class SafeDsPythonGenerator { memoizedArgs, (arg) => this.generateExpression(arg, frame), { separator: ', ' }, - )}], [${joinToNode(hiddenParameters, (param) => param, { separator: ', ' })}])`; - } - - private isMemoizableCall(expression: TslCall): boolean { - const impurityReasons = this.purityComputer.getImpurityReasonsForExpression(expression); - // If the file is not known, the call is not memoizable - return ( - !impurityReasons.some((reason) => !(reason instanceof FileRead) || reason.path === undefined) - ); - } - - private generateMemoizedCall( - expression: TslCall, - sortedArgs: TslArgument[], - frame: GenerationInfoFrame, - thisParam: CompositeGeneratorNode | undefined = undefined, - ): CompositeGeneratorNode { - frame.addImport({ importPath: RUNNER_PACKAGE }); - const hiddenParameters = this.getMemoizedCallHiddenParameters(expression, frame); - const callable = this.nodeMapper.callToCallable(expression); - const memoizedArgs = getParameters(callable).map( - (parameter) => this.nodeMapper.callToParameterValue(expression, parameter)!, - ); - // For a static function, the thisParam would be the class containing the function. We do not need to generate it in this case - const generateThisParam = !isTslFunction(callable) || thisParam; - const containsOptionalArgs = sortedArgs.some((arg) => - Parameter.isOptional(this.nodeMapper.argumentToParameter(arg)), - ); - const fullyQualifiedTargetName = this.generateFullyQualifiedFunctionName(expression); - return expandTracedToNode(expression)`${RUNNER_PACKAGE}.memoized_call("${fullyQualifiedTargetName}", ${ - containsOptionalArgs ? 'lambda *_ : ' : '' - }${ - containsOptionalArgs - ? this.generatePlainCall(expression, sortedArgs, frame) - : isTslMemberAccess(expression.receiver) && isTslCall(expression.receiver.receiver) - ? expandTracedToNode(expression.receiver)`${this.generateExpression( - expression.receiver.receiver.receiver, - frame, - )}.${this.generateExpression(expression.receiver.member!, frame)}` - : this.generateExpression(expression.receiver, frame) - }, [${generateThisParam ? thisParam : ''}${ - generateThisParam && memoizedArgs.length > 0 ? ', ' : '' - }${joinTracedToNode(expression.argumentList, 'arguments')( - memoizedArgs, - (arg) => this.generateExpression(arg, frame), - { - separator: ', ', - }, - )}], [${joinToNode(hiddenParameters, (param) => param, { separator: ', ' })}])`; - } - - private getMemoizedCallHiddenParameters(expression: TslCall, frame: GenerationInfoFrame): CompositeGeneratorNode[] { - const impurityReasons = this.purityComputer.getImpurityReasonsForExpression(expression); - const hiddenParameters: CompositeGeneratorNode[] = []; - for (const reason of impurityReasons) { - if (reason instanceof FileRead) { - if (typeof reason.path === 'string') { - hiddenParameters.push( - expandTracedToNode(expression)`${RUNNER_PACKAGE}.file_mtime('${reason.path}')`, - ); - } else if (isTslParameter(reason.path)) { - const argument = this.nodeMapper - .parametersToArguments([reason.path], getArguments(expression)) - .get(reason.path); - if (!argument) { - /* c8 ignore next 4 */ - throw new Error( - 'File Read impurity with dependency on parameter is present on call, but no argument has been provided.', - ); - } - hiddenParameters.push( - expandTracedToNode(argument)`${RUNNER_PACKAGE}.file_mtime(${this.generateArgument( - argument, - frame, - )})`, - ); - } - } - } - return hiddenParameters; + )}])`; } private generateFullyQualifiedFunctionName(expression: TslCall): string { diff --git a/packages/ttsl-lang/src/language/safe-ds-module.ts b/packages/ttsl-lang/src/language/safe-ds-module.ts index 76b37485..11f8434b 100644 --- a/packages/ttsl-lang/src/language/safe-ds-module.ts +++ b/packages/ttsl-lang/src/language/safe-ds-module.ts @@ -33,7 +33,6 @@ import { registerValidationChecks } from './validation/safe-ds-validator.js'; import { SafeDsDocumentBuilder } from './workspace/safe-ds-document-builder.js'; import { SafeDsPackageManager } from './workspace/safe-ds-package-manager.js'; import { SafeDsWorkspaceManager } from './workspace/safe-ds-workspace-manager.js'; -import { SafeDsPurityComputer } from './purity/safe-ds-purity-computer.js'; import { SafeDsSettingsProvider } from './workspace/safe-ds-settings-provider.js'; import { SafeDsRenameProvider } from './lsp/safe-ds-rename-provider.js'; import { SafeDsTypeFactory } from './typing/safe-ds-type-factory.js'; @@ -61,9 +60,6 @@ export type SafeDsAddedServices = { lsp: { NodeInfoProvider: SafeDsNodeInfoProvider; }; - purity: { - PurityComputer: SafeDsPurityComputer; - }; types: { ClassHierarchy: SafeDsClassHierarchy; CoreTypes: SafeDsCoreTypes; @@ -121,9 +117,6 @@ export const SafeDsModule: Module new SafeDsValueConverter(), }, - purity: { - PurityComputer: (services) => new SafeDsPurityComputer(services), - }, references: { ScopeComputation: (services) => new SafeDsScopeComputation(services), ScopeProvider: (services) => new SafeDsScopeProvider(services), diff --git a/packages/ttsl-lang/src/language/validation/other/statements/statements.ts b/packages/ttsl-lang/src/language/validation/other/statements/statements.ts deleted file mode 100644 index b34bb3b7..00000000 --- a/packages/ttsl-lang/src/language/validation/other/statements/statements.ts +++ /dev/null @@ -1,18 +0,0 @@ -import { TslStatement } from '../../../generated/ast.js'; -import { ValidationAcceptor } from 'langium'; -import { SafeDsServices } from '../../../safe-ds-module.js'; - -export const CODE_STATEMENT_HAS_NO_EFFECT = 'statement/has-no-effect'; - -export const statementMustDoSomething = (services: SafeDsServices) => { - const purityComputer = services.purity.PurityComputer; - - return (node: TslStatement, accept: ValidationAcceptor): void => { - if (!purityComputer.statementDoesSomething(node)) { - accept('warning', 'This statement does nothing.', { - node, - code: CODE_STATEMENT_HAS_NO_EFFECT, - }); - } - }; -}; From 1e86af4281d918fbb5817436db2ebfa47c9730f7 Mon Sep 17 00:00:00 2001 From: methr0 Date: Sat, 29 Jun 2024 10:27:20 +0200 Subject: [PATCH 093/183] remove statementMustDoSomething call in validator --- packages/ttsl-lang/src/language/validation/safe-ds-validator.ts | 2 -- 1 file changed, 2 deletions(-) diff --git a/packages/ttsl-lang/src/language/validation/safe-ds-validator.ts b/packages/ttsl-lang/src/language/validation/safe-ds-validator.ts index febd0d52..fbfa923b 100644 --- a/packages/ttsl-lang/src/language/validation/safe-ds-validator.ts +++ b/packages/ttsl-lang/src/language/validation/safe-ds-validator.ts @@ -64,7 +64,6 @@ import { resultMustHaveTypeHint, typeCastExpressionMustHaveUnknownType, } from './types.js'; -import { statementMustDoSomething } from './other/statements/statements.js'; import { indexedAccessIndexMustBeValid } from './other/expressions/indexedAccess.js'; import { chainedExpressionsMustBeNullSafeIfReceiverIsNullable } from './other/expressions/chainedExpressions.js'; import { groupByVariableMustBeAnID, groupedFunctionHasAggregation, groupedFunctionHasValidID } from './aggregation.js'; @@ -153,7 +152,6 @@ export const registerValidationChecks = function (services: SafeDsServices) { referenceMustNotBeFunctionPointer, ], TslResult: [resultMustHaveTypeHint], - TslStatement: [statementMustDoSomething(services)], TslTemplateString: [templateStringMustHaveExpressionBetweenTwoStringParts], TslTypeCast: [typeCastExpressionMustHaveUnknownType(services)], }; From 47b2e1fde3c80a1345155ce0bd13e4eb59e96b98 Mon Sep 17 00:00:00 2001 From: alex-senger Date: Sat, 29 Jun 2024 11:44:33 +0200 Subject: [PATCH 094/183] fix: single line comment syntax --- .../parameters/abgeltungssteuersatz.ttsl | 2 +- .../builtins/parameters/arbeitslosengeld.ttsl | 30 +-- .../parameters/arbeitslosengeld2.ttsl | 96 ++++---- .../builtins/parameters/einkommenssteuer.ttsl | 147 ++++++----- .../parameters/einkommenssteuerAbzuege.ttsl | 148 ++++++------ .../builtins/parameters/elterngeld.ttsl | 26 +- .../parameters/erwerbsminderungsrente.ttsl | 2 +- .../builtins/parameters/erziehungsgeld.ttsl | 4 +- .../builtins/parameters/gesetzlicheRente.ttsl | 86 +++---- .../parameters/grundsicherungImAlter.ttsl | 10 +- .../builtins/parameters/kindergeld.ttsl | 36 +-- .../builtins/parameters/kinderzuschlag.ttsl | 82 +++---- .../parameters/kinderzuschlagEinkommen.ttsl | 2 +- .../builtins/parameters/lohnsteuer.ttsl | 2 +- .../parameters/solidaritaetszuschlag.ttsl | 20 +- .../sozialversicherungsbeitrag.ttsl | 228 +++++++++--------- .../builtins/parameters/unterhalt.ttsl | 22 +- .../parameters/unterhaltvorschuss.ttsl | 8 +- .../builtins/parameters/wohngeld.ttsl | 132 +++++----- 19 files changed, 541 insertions(+), 542 deletions(-) diff --git a/src/resources/builtins/parameters/abgeltungssteuersatz.ttsl b/src/resources/builtins/parameters/abgeltungssteuersatz.ttsl index 3f988295..24b5ffdb 100644 --- a/src/resources/builtins/parameters/abgeltungssteuersatz.ttsl +++ b/src/resources/builtins/parameters/abgeltungssteuersatz.ttsl @@ -1,6 +1,6 @@ package abgeltungssteuersatz -// abgelt_st.yaml -------------------------------------------------------- +# abgelt_st.yaml -------------------------------------------------------- /** * Constant for the Capital Income Tax Rate as defined in §32d (1) EStG. diff --git a/src/resources/builtins/parameters/arbeitslosengeld.ttsl b/src/resources/builtins/parameters/arbeitslosengeld.ttsl index c47f51eb..b559bef4 100644 --- a/src/resources/builtins/parameters/arbeitslosengeld.ttsl +++ b/src/resources/builtins/parameters/arbeitslosengeld.ttsl @@ -1,16 +1,16 @@ package arbeitslosengeld -// arbeitsl_geld.yaml ---------------------------------------------------- +# arbeitsl_geld.yaml ---------------------------------------------------- /** * Income which is not deducted from unemployment benefit. * § 155 SGB III, vorher § 141 (1) S. 1 */ public const arbeitslosenGeldFreibetrag: Int { - // Art. 1 G. v. 21.07.1999 BGBl. I S. 1648 + # Art. 1 G. v. 21.07.1999 BGBl. I S. 1648 from 1999-08-01 = 161; - // Art. 3 G. v. 21.12.2000 BGBl. I S. 1983 + # Art. 3 G. v. 21.12.2000 BGBl. I S. 1983 from 2002-01-01 = 165; } @@ -48,11 +48,11 @@ public const sozialVersicherungsPauschale: Float { from 2010-01-01 = 0.20225; from 2011-01-01 = 0.20625; - // Reference: Art. 2 G. v. 20.12.2011 BGBl. I S. 2854 + # Reference: Art. 2 G. v. 20.12.2011 BGBl. I S. 2854 from 2012-01-01 = 0.21; - // Reference: Art. 1 G. v. 18.12.2018 BGBl. I S. 2651 - from 2019-01-01 = 0.2; + # Reference: Art. 1 G. v. 18.12.2018 BGBl. I S. 2651 + from 2019-01-01 = 0.2; } /** @@ -61,8 +61,8 @@ public const sozialVersicherungsPauschale: Float { * Verhältnis zum letzten Nettoentgelt bei Personen ohne Kinder im Sinne des EStG. */ public const satzOhneKinder: Float { - // Reference: Art. 1 G. v. 24.03.1997 BGBl. I S. 594 - from 1998-08-01 = 0.6; + # Reference: Art. 1 G. v. 24.03.1997 BGBl. I S. 594 + from 1998-08-01 = 0.6; } /** @@ -71,7 +71,7 @@ public const satzOhneKinder: Float { * Verhältnis zum letzten Nettoentgelt bei Personen mit Kindern im Sinne des EStG */ public const satzMitKindern: Float { - // Reference: Art. 1 G. v. 24.03.1997 BGBl. I S. 594 + # Reference: Art. 1 G. v. 24.03.1997 BGBl. I S. 594 from 1998-08-01 = 0.67; } @@ -82,14 +82,14 @@ public const satzMitKindern: Float { */ public const stundengrenze: Int { from 1969-07-01 = 20; - // Reference: Art. 1 G. v. 20.12.1985 BGBl I S. 2484 - from 1986-01-01 = 19; + # Reference: Art. 1 G. v. 20.12.1985 BGBl I S. 2484 + from 1986-01-01 = 19; - // Reference: Art. 1 G. v. 20.12.1988 BGBl I S. 2343 - from 1989-01-01 = 18; + # Reference: Art. 1 G. v. 20.12.1988 BGBl I S. 2343 + from 1989-01-01 = 18; - // Reference: Art. 2 G. v. 20.12.2011 BGBl I S. 2854 - from 2012-04-01 = 15; + # Reference: Art. 2 G. v. 20.12.2011 BGBl I S. 2854 + from 2012-04-01 = 15; } /** diff --git a/src/resources/builtins/parameters/arbeitslosengeld2.ttsl b/src/resources/builtins/parameters/arbeitslosengeld2.ttsl index f955ae1b..9663b83a 100644 --- a/src/resources/builtins/parameters/arbeitslosengeld2.ttsl +++ b/src/resources/builtins/parameters/arbeitslosengeld2.ttsl @@ -1,6 +1,6 @@ package arbeitslosengeld2 -// arbeitsl_geld_2.yaml -------------------------------------------------- +# arbeitsl_geld_2.yaml -------------------------------------------------- /** * Income shares not subject to transfer withdrawal. @@ -10,7 +10,7 @@ package arbeitslosengeld2 * G. v. 24.03.2011 BGBl. I S. 453). */ public const anrechnungsfreieEinkommensanteile: Dict>> { - // Reference: Artikel 1. G. v. 24.12.2003 BGBl. I S. 2954. + # Reference: Artikel 1. G. v. 24.12.2003 BGBl. I S. 2954. from 2005-01-01 = { 0: { lower_threshold: -inf, @@ -37,7 +37,7 @@ public const anrechnungsfreieEinkommensanteile: Dict>> { - // Reference: Artikel 1 G. v. 14.08.2005 BGBl. I S. 2407. + # Reference: Artikel 1 G. v. 14.08.2005 BGBl. I S. 2407. from 2005-10-01 = { 3: { upper_threshold: 1500 } } - // Reference: G. v. 20.12.2022 BGBl. I S. 2328. + # Reference: G. v. 20.12.2022 BGBl. I S. 2328. from 2023-07-01 = { 4: { upper_threshold: 1500 @@ -133,7 +133,7 @@ public const anrechnungsfreieEinkommensanteileFallsKinder: Dict { @@ -143,26 +143,26 @@ public const regelsatz: Int | Dict { note: "Der tatsächliche Wert unterscheidet sich zwischen Ost und West. Korrekte Werte sind in den alten Bundesländern einschließlich Berlin (Ost) 345 Euro, in den neuen Bundesländern 331 Euro." }, - // Reference: B. v. 01.09.2005 BGBl. I S. 2718. - // Betrag unverändert. Der tatsächliche Wert unterscheidet sich zwischen Ost und West. Hier wurde vereinfachend 338 Euro als ungewichteter Mittelwert genommen. Korrekte Werte für die Zeit ab 1. Juli 2005 sind in den alten Bundesländern einschließlich Berlin (Ost) 345 Euro, in den neuen Bundesländern 331 Euro. + # Reference: B. v. 01.09.2005 BGBl. I S. 2718. + # Betrag unverändert. Der tatsächliche Wert unterscheidet sich zwischen Ost und West. Hier wurde vereinfachend 338 Euro als ungewichteter Mittelwert genommen. Korrekte Werte für die Zeit ab 1. Juli 2005 sind in den alten Bundesländern einschließlich Berlin (Ost) 345 Euro, in den neuen Bundesländern 331 Euro. from 2005-07-01 = 338 - // Reference: B. v. 20.07.2006 BGBl. I S. 1702. + # Reference: B. v. 20.07.2006 BGBl. I S. 1702. from 2006-07-01 = 345 - // Reference: B. v. 18.06.2007 BGBl. I S. 1139. + # Reference: B. v. 18.06.2007 BGBl. I S. 1139. from 2007-07-01 = 347 - // Reference: B. v. 26.06.2008 BGBl. I S. 1102. + # Reference: B. v. 26.06.2008 BGBl. I S. 1102. from 2008-07-01 = 351 - // Reference: B. v. 17.06.2009 BGBl. I S. 1342. + # Reference: B. v. 17.06.2009 BGBl. I S. 1342. from 2009-07-01 = 359 - // Reference: B. v. 07.06.2010 BGBl. I S. 820. Betrag unverändert. + # Reference: B. v. 07.06.2010 BGBl. I S. 820. Betrag unverändert. from 2010-07-01 = 359 - // Reference: Artikel 1 G. v. 24.03.2011 BGBl. I S. 453. + # Reference: Artikel 1 G. v. 24.03.2011 BGBl. I S. 453. from 2011-01-01 = { 1: 364, 2: 328, @@ -172,7 +172,7 @@ public const regelsatz: Int | Dict { 6: 215, } - // Reference: V. v. 20.10.2011 BGBl. I S. 2093. + # Reference: V. v. 20.10.2011 BGBl. I S. 2093. from 2012-01-01 = { 1: 374, 2: 337, @@ -182,7 +182,7 @@ public const regelsatz: Int | Dict { 6: 219, } - // Reference: B. v. 18.10.2012 BGBl. I S. 2175. + # Reference: B. v. 18.10.2012 BGBl. I S. 2175. from 2013-01-01 = { 1: 382, 2: 345, @@ -192,7 +192,7 @@ public const regelsatz: Int | Dict { 6: 224, } - // Reference: B. v. 16.10.2013 BGBl. I S. 3857. + # Reference: B. v. 16.10.2013 BGBl. I S. 3857. from 2014-01-01 = { 1: 391, 2: 353, @@ -202,7 +202,7 @@ public const regelsatz: Int | Dict { 6: 229, } - // Reference: B. v. 15.10.2014 BGBl. I S. 1620. + # Reference: B. v. 15.10.2014 BGBl. I S. 1620. from 2015-01-01 = { 1: 399, 2: 360, @@ -212,7 +212,7 @@ public const regelsatz: Int | Dict { 6: 234, } - // Reference: B. v. 22.10.2015 BGBl. I S. 1792. + # Reference: B. v. 22.10.2015 BGBl. I S. 1792. from 2016-01-01 = { 1: 404, 2: 364, @@ -222,7 +222,7 @@ public const regelsatz: Int | Dict { 6: 237, } - // Reference: G. v. 22.12.2016 BGBl. I S. 3159. + # Reference: G. v. 22.12.2016 BGBl. I S. 3159. from 2017-01-01 = { 1: 409, 2: 368, @@ -232,7 +232,7 @@ public const regelsatz: Int | Dict { 6: 236, } - // Reference: V. v. 08.11.2017 BGBl. I S. 3767. + # Reference: V. v. 08.11.2017 BGBl. I S. 3767. from 2018-01-01 = { 1: 416, 2: 374, @@ -242,7 +242,7 @@ public const regelsatz: Int | Dict { 6: 240, } - // Reference: V. v. 19.10.2018 BGBl. I S. 1766. + # Reference: V. v. 19.10.2018 BGBl. I S. 1766. from 2019-01-01 = { 1: 424, 2: 382, @@ -252,7 +252,7 @@ public const regelsatz: Int | Dict { 6: 245, } - // Reference: V. v. 18.10.2019 BGBl. I S. 1452. + # Reference: V. v. 18.10.2019 BGBl. I S. 1452. from 2020-01-01 = { 1: 432, 2: 389, @@ -262,7 +262,7 @@ public const regelsatz: Int | Dict { 6: 250 } - // Reference: G. v. 09.12.2020 BGBl. I S. 2855. + # Reference: G. v. 09.12.2020 BGBl. I S. 2855. from 2021-01-01 = { 1: 446, 2: 401, @@ -272,7 +272,7 @@ public const regelsatz: Int | Dict { 6: 283 } - // Reference: V. v. 13.10.2021 BGBl. I S. 4674. + # Reference: V. v. 13.10.2021 BGBl. I S. 4674. from 2022-01-01 = { 1: 449, 2: 404, @@ -282,8 +282,8 @@ public const regelsatz: Int | Dict { 6: 285 } - // Reference: G. v. 20.12.2022 BGBl. I S. 2328. - // Bürgergeld-Gesetz + # Reference: G. v. 20.12.2022 BGBl. I S. 2328. + # Bürgergeld-Gesetz from 2023-01-01 = { 1: 502, 2: 451, @@ -293,7 +293,7 @@ public const regelsatz: Int | Dict { 6: 318 } - // Reference: §2 V. v. 24.10.2024 BGBl. I Nr. 287 + # Reference: §2 V. v. 24.10.2024 BGBl. I Nr. 287 from 2024-01-01 = { 1: 563, 2: 506, @@ -312,7 +312,7 @@ public const regelsatz: Int | Dict { * des Standardsatzes bestimmt. */ public const anteilRegelsatz: Dict { - // Reference: Artikel 1 G. v. 24.12.2003 BGBl. I S. 2954. + # Reference: Artikel 1 G. v. 24.12.2003 BGBl. I S. 2954. from 2005-01-01 = { zwei_erwachsene: 0.9, weitere_erwachsene: 0.8, @@ -322,8 +322,8 @@ public const regelsatz: Int | Dict { } - // TODO: WAS HEIßT DEVIATION_FROM - // Reference: Artikel 1 G. v. 02.03.2009 BGBl. I S. 416. + # TODO: WAS HEIßT DEVIATION_FROM + # Reference: Artikel 1 G. v. 02.03.2009 BGBl. I S. 416. from 2009-07-01 = { zwei_erwachsene: 0.9, weitere_erwachsene: 0.8, @@ -344,7 +344,7 @@ public const regelsatz: Int | Dict { * reference_period: Month */ public const mehrbedarfAnteil: Dict { - // Reference: G. v. 24.12.2003 BGBl. I S. 2954. + # Reference: G. v. 24.12.2003 BGBl. I S. 2954. from 2005-01-01 = { min_1_kind: 0.12, kind_unter_7_oder_mehr: 0.36, @@ -360,7 +360,7 @@ public const mehrbedarfAnteil: Dict { * da alle betroffenen Personen zu alt für ALG 2 sind. */ def vermögensGrundfreibetragObergrenze: Dict { - // Reference: Artikel 1 G. v. 23.12.2002 BGBl. I S. 4607. + # Reference: Artikel 1 G. v. 23.12.2002 BGBl. I S. 4607. from 2005-01-01 = { 1947: 33800, 1948: 13000, @@ -368,7 +368,7 @@ public const mehrbedarfAnteil: Dict { 1964: 13000 } - // Reference: Artikel 1 G. v. 20.07.2006 BGBl. I S. 1706. + # Reference: Artikel 1 G. v. 20.07.2006 BGBl. I S. 1706. from 2006-08-01 = { 1947: 33800, 1948: 9750, @@ -376,7 +376,7 @@ public const mehrbedarfAnteil: Dict { 1964: 9750 } - // Reference: Artikel 1 G. v. 20.04.2007 BGBl. I S. 554. + # Reference: Artikel 1 G. v. 20.04.2007 BGBl. I S. 554. from 2008-01-01 = { 1947: 33800, 1948: 9750, @@ -384,7 +384,7 @@ public const mehrbedarfAnteil: Dict { 1964: 10050 } - // Reference: G. v. 20.12.2022 BGBl. I S. 2328. (Bürgergeld-Gesetz) + # Reference: G. v. 20.12.2022 BGBl. I S. 2328. (Bürgergeld-Gesetz) from 2023-01-01 = { 1947: null, 1948: null, @@ -401,7 +401,7 @@ public const mehrbedarfAnteil: Dict { * erste Person einer Bedarfsgemeinschaft und 15.000 Euro für jede weitere erlaubt. */ const schonvermoegenBuergergeld: Dict { - // Reference: G. v. 20.12.2022 BGBl. I S. 2328. (Bürgergeld-Gesetz) + # Reference: G. v. 20.12.2022 BGBl. I S. 2328. (Bürgergeld-Gesetz) from 2023-01-01 = { während_karenzzeit: 40000, normaler_satz: 15000 @@ -413,10 +413,10 @@ public const mehrbedarfAnteil: Dict { * § 12 (2) Satz 1 Nr. 4 SGB II. */ const vermoegensfreibetragAusstattung: Int { - // Reference: Artikel 1 G. v. 24.12.2003 BGBl. I S. 2954. + # Reference: Artikel 1 G. v. 24.12.2003 BGBl. I S. 2954. from 2005-01-01 = 750; - // Reference: G. v. 20.12.2022 BGBl. I S. 2328. (Bürgergeld-Gesetz) + # Reference: G. v. 20.12.2022 BGBl. I S. 2328. (Bürgergeld-Gesetz) from 2023-01-01 = null; } @@ -425,13 +425,13 @@ const vermoegensfreibetragAusstattung: Int { * § 12 (2) Satz 1 Nr. 1 SGB II. */ const vermoegensfreibetragKind: Int { - // Reference: Artikel 1 G. v. 24.12.2003 BGBl. I S. 2954. + # Reference: Artikel 1 G. v. 24.12.2003 BGBl. I S. 2954. from 2005-01-01 = 4100; - // Reference: Artikel 1 G. v. 20.07.2006 BGBl. I S. 1706. + # Reference: Artikel 1 G. v. 20.07.2006 BGBl. I S. 1706. from 2006-08-01 = 3100; - // Reference: G. v. 20.12.2022 BGBl. I S. 2328. (Bürgergeld-Gesetz) + # Reference: G. v. 20.12.2022 BGBl. I S. 2328. (Bürgergeld-Gesetz) from 2023-01-01 = null; } @@ -446,7 +446,7 @@ const vermoegensfreibetragAlter: Dict { 3: 1963 } - // Reference: G. v. 20.12.2022 BGBl. I S. 2328. (Bürgergeld-Gesetz) + # Reference: G. v. 20.12.2022 BGBl. I S. 2328. (Bürgergeld-Gesetz) 2023-01-01: { 1: null, 2: null, @@ -461,13 +461,13 @@ const vermoegensfreibetragAlter: Dict { * § 3 Alg II-V. Seit 01.01.2008 in § 6 Alg II-V. */ const abzugfaehigePauschale: Dict { - // Reference: V. v. 20.10.2004 BGBl. I S. 2622 + # Reference: V. v. 20.10.2004 BGBl. I S. 2622 from 2005-01-01 = { werbung: 15.33, versicherung: 30.0 } - // Reference: V. v. 21.06.2011 BGBl. I S. 1175. + # Reference: V. v. 21.06.2011 BGBl. I S. 1175. from 2011-01-01 = { werbung: 15.33, versicherung: 30.0 @@ -515,7 +515,7 @@ const berechtigteWohnflaecheEigentum: Dict { je_weitere_person: 20 } - // Reference: Art. 1 Nr.12 Abschnitt 5, G. v. 20.12.2022 BGBl. I S. 2328 + # Reference: Art. 1 Nr.12 Abschnitt 5, G. v. 20.12.2022 BGBl. I S. 2328 from 2023-01-01 = { 1: 140, 2: 140, diff --git a/src/resources/builtins/parameters/einkommenssteuer.ttsl b/src/resources/builtins/parameters/einkommenssteuer.ttsl index 75773812..412da2fd 100644 --- a/src/resources/builtins/parameters/einkommenssteuer.ttsl +++ b/src/resources/builtins/parameters/einkommenssteuer.ttsl @@ -1,6 +1,6 @@ package einkommenssteuer -// eink_st.yaml ---------------------------------------------------------- +# eink_st.yaml ---------------------------------------------------------- /** * Einkommenssteuer Tarif @@ -9,114 +9,113 @@ package einkommenssteuer * des Progressionsfaktors berechnet. Einzelheiten sind im docstring der Funktion * add_progressionsfaktor beschrieben. */ -const einkommenssteuerTarif: Dict> { - - // TODO: klären wie das mit deviation_from aussieht +public const einkommenssteuerTarif: Dict> { + # TODO: klren wie das mit deviation_from aussieht from 2002-01-01 = { 0: { - lower_threshold: -inf, - upper_threshold: 7235, - rate_linear: 0, - rate_quadratic: 0, + lower_threshold: -inf, + upper_threshold: 7235, + rate_linear: 0, + rate_quadratic: 0, intercept_at_lower_threshold: 0 }, 1: { - upper_threshold: 9251, + upper_threshold: 9251, rate_linear: 0.199 }, 2: { - upper_threshold: 55007, + upper_threshold: 55007, rate_linear: 0.23 }, 3: { - upper_threshold: inf, - rate_linear: 0.485, + upper_threshold: inf, + rate_linear: 0.485, rate_quadratic: 0 } } from 2004-01-01 = { 0: { - lower_threshold: -inf, - upper_threshold: 7664, - rate_linear: 0, + lower_threshold: -inf, + upper_threshold: 7664, + rate_linear: 0, intercept_at_lower_threshold: 0 }, 1: { - upper_threshold: 12739, + upper_threshold: 12739, rate_linear: 0.16 }, 2: { - upper_threshold: 52151, + upper_threshold: 52151, rate_linear: 0.2405 }, 3: { - upper_threshold: inf, - rate_linear: 0.45, + upper_threshold: inf, + rate_linear: 0.45, rate_quadratic: 0 } } from 2005-01-01 = { 0: { - lower_threshold: -inf, - upper_threshold: 7664, - rate_linear: 0, - rate_quadratic: 0, + lower_threshold: -inf, + upper_threshold: 7664, + rate_linear: 0, + rate_quadratic: 0, intercept_at_lower_threshold: 0 }, 1: { - upper_threshold: 12739, + upper_threshold: 12739, rate_linear: 0.15 }, 2: { - upper_threshold: 52151, + upper_threshold: 52151, rate_linear: 0.2397 }, 3: { - upper_threshold: inf, - rate_linear: 0.42, + upper_threshold: inf, + rate_linear: 0.42, rate_quadratic: 0 } } from 2007-01-01 = { 0: { - lower_threshold: -inf, - upper_threshold: 7664, - rate_linear: 0, - rate_quadratic: 0, + lower_threshold: -inf, + upper_threshold: 7664, + rate_linear: 0, + rate_quadratic: 0, intercept_at_lower_threshold: 0 }, 1: { - upper_threshold: 12739, + upper_threshold: 12739, rate_linear: 0.15 }, 2: { - upper_threshold: 52151, + upper_threshold: 52151, rate_linear: 0.2397 }, 3: { - upper_threshold: 250000, - rate_linear: 0.42, + upper_threshold: 250000, + rate_linear: 0.42, rate_quadratic: 0 }, 4: { - upper_threshold: inf, - rate_linear: 0.45, + upper_threshold: inf, + rate_linear: 0.45, rate_quadratic: 0 } } from 2009-01-01 = { - // deviation_from: previous, + # deviation_from: previous, 0: { upper_threshold: 7834 }, 1: { - upper_threshold: 13139, + upper_threshold: 13139, rate_linear: 0.14 }, 2: { @@ -128,7 +127,7 @@ const einkommenssteuerTarif: Dict> { } from 2010-01-01 = { - // deviation_from: previous, + # deviation_from: previous, 0: { upper_threshold: 8004 }, @@ -144,31 +143,31 @@ const einkommenssteuerTarif: Dict> { } from 2013-01-01 = { - // deviation_from: previous, + # deviation_from: previous, 0: { upper_threshold: 8130 } } from 2014-01-01 = { - // Reference: G. v. 20.2.2013, BGBl I S.283 - // deviation_from: previous, + # Reference: G. v. 20.2.2013, BGBl I S.283 + # deviation_from: previous, 0: { upper_threshold: 8354 } } from 2015-07-01 = { - // Reference: G. v. 15.07.2015, BGBl. Nr. 30 2015 - // deviation_from: previous, + # Reference: G. v. 15.07.2015, BGBl. Nr. 30 2015 + # deviation_from: previous, 0: { upper_threshold: 8472 } } from 2016-01-01 = { - // Reference: G. v. 15.07.2015, BGBl. Nr. 30 2015 - // deviation_from: previous, + # Reference: G. v. 15.07.2015, BGBl. Nr. 30 2015 + # deviation_from: previous, 0: { upper_threshold: 8652 }, @@ -184,8 +183,8 @@ const einkommenssteuerTarif: Dict> { } from 2017-01-01 = { - // Reference: Artikel 8 G. v. 20.12.2016, BGBl I S. 3000 - // deviation_from: previous, + # Reference: Artikel 8 G. v. 20.12.2016, BGBl I S. 3000 + # deviation_from: previous, 0: { upper_threshold: 8820 }, @@ -201,8 +200,8 @@ const einkommenssteuerTarif: Dict> { } from 2018-01-01 = { - // Reference: Artikel 9 G. v 23.12.2016, BGBL I, S. 3000 - // deviation_from: previous, + # Reference: Artikel 9 G. v 23.12.2016, BGBL I, S. 3000 + # deviation_from: previous, 0: { upper_threshold: 9000 }, @@ -218,7 +217,7 @@ const einkommenssteuerTarif: Dict> { } from 2019-01-01 = { - // deviation_from: previous, + # deviation_from: previous, 0: { upper_threshold: 9169 }, @@ -234,8 +233,8 @@ const einkommenssteuerTarif: Dict> { } from 2020-01-01 = { - // Reference: Art. 3 G. v. 29.11.2018 BGBl. I S. 2210 - // deviation_from: previous, + # Reference: Art. 3 G. v. 29.11.2018 BGBl. I S. 2210 + # deviation_from: previous, 0: { upper_threshold: 9408 }, @@ -251,8 +250,8 @@ const einkommenssteuerTarif: Dict> { } from 2021-01-01 = { - // Reference: Art. 1 G. v. 01.12.2020 BGBl. I S. 2616 - // deviation_from: previous, + # Reference: Art. 1 G. v. 01.12.2020 BGBl. I S. 2616 + # deviation_from: previous, 0: { upper_threshold: 9744 }, @@ -268,8 +267,8 @@ const einkommenssteuerTarif: Dict> { } from 2022-01-01 = { - // Reference: Art. 1 G. v. 23.05.2022 BGBl. I S. 749 - // deviation_from: previous, + # Reference: Art. 1 G. v. 23.05.2022 BGBl. I S. 749 + # deviation_from: previous, 0: { upper_threshold: 10347 }, @@ -285,8 +284,8 @@ const einkommenssteuerTarif: Dict> { } from 2023-01-01 = { - // Reference: Art. 2 G. v. 08.12.2022 BGBl. I S. 2230., - // deviation_from: previous + # Reference: Art. 2 G. v. 08.12.2022 BGBl. I S. 2230., + # deviation_from: previous 0: { upper_threshold: 10909 }, @@ -302,7 +301,7 @@ const einkommenssteuerTarif: Dict> { } from 2024-01-01 = { - // Reference: Art. 3 G. v. 08.12.2022 BGBl. I S. 2230. + # Reference: Art. 3 G. v. 08.12.2022 BGBl. I S. 2230. deviation_from: previous, 0: { upper_threshold: 11605 @@ -329,30 +328,30 @@ const einkommenssteuerTarif: Dict> { const renteErtragsanteil: Dict> { from 2002-01-01 = { 0: { - lower_threshold: -inf, - upper_threshold: 2005, - rate_linear: 0, + lower_threshold: -inf, + upper_threshold: 2005, + rate_linear: 0, intercept_at_lower_threshold: 0.27 }, 1: { - lower_threshold: 2005, - upper_threshold: 2021, - rate_linear: 0.02, + lower_threshold: 2005, + upper_threshold: 2021, + rate_linear: 0.02, intercept_at_lower_threshold: 0.5 }, 2: { - lower_threshold: 2021, - upper_threshold: 2041, - rate_linear: 0.01, + lower_threshold: 2021, + upper_threshold: 2041, + rate_linear: 0.01, intercept_at_lower_threshold: 0.8 }, 3: { - lower_threshold: 2041, - upper_threshold: inf, - rate_linear: 0.0, + lower_threshold: 2041, + upper_threshold: inf, + rate_linear: 0.0, intercept_at_lower_threshold: 1 } } } -// TODO: rounding +# TODO: rounding diff --git a/src/resources/builtins/parameters/einkommenssteuerAbzuege.ttsl b/src/resources/builtins/parameters/einkommenssteuerAbzuege.ttsl index 379bbf57..d7ed150f 100644 --- a/src/resources/builtins/parameters/einkommenssteuerAbzuege.ttsl +++ b/src/resources/builtins/parameters/einkommenssteuerAbzuege.ttsl @@ -1,6 +1,6 @@ pacakge einkommenssteuerAbzuege -// eink_st_abzuege.yaml -------------------------------------------------- +# eink_st_abzuege.yaml -------------------------------------------------- /** * Kinderfreibetrag @@ -10,27 +10,27 @@ pacakge einkommenssteuerAbzuege * Pro Jahr */ const kinderFreibetrag: Dict { - // Reference: Art. 1 G. v. 23.12.1982 BGBl. I S. 1857. + # Reference: Art. 1 G. v. 23.12.1982 BGBl. I S. 1857. from 1983-01-01 = { saechlichesExistenzminimum: 110 } - // Reference: Art. 1 G. v. 26.06.1985 BGBl. I S. 1153. + # Reference: Art. 1 G. v. 26.06.1985 BGBl. I S. 1153. from 1986-01-01 = { saechlichesExistenzminimum: 635 } - // Reference: Artikel 1 G. v. 25.07.1988 BGBl. I S. 1093. + # Reference: Artikel 1 G. v. 25.07.1988 BGBl. I S. 1093. from 1990-01-01 = { saechlichesExistenzminimum: 773 } - // Reference: Art. 1 G. v. 25.02.1992 BGBl. I S. 297. + # Reference: Art. 1 G. v. 25.02.1992 BGBl. I S. 297. from 1992-01-01 = { saechlichesExistenzminimum: 1049 } - // Reference: Art. 1. G. v. 11.10.1995 BGBl. I S. 1250. + # Reference: Art. 1. G. v. 11.10.1995 BGBl. I S. 1250. from 1996-01-01 = { saechlichesExistenzminimum: 1601 } @@ -39,81 +39,81 @@ const kinderFreibetrag: Dict { saechlichesExistenzminimum: 1767 } - // Reference: Art. 1 G. v. 28.12.1999 BGBl. I. S. 2552. + # Reference: Art. 1 G. v. 28.12.1999 BGBl. I. S. 2552. from 2000-01-01 = { beitragErziehungAusbildung: 774, saechlichesExistenzminimum: 1767 } - // Reference: Art. 1 G. v. 16.08.2001 BGBl. I S. 2074 + # Reference: Art. 1 G. v. 16.08.2001 BGBl. I S. 2074 from 2002-01-01 = { beitragErziehungAusbildung: 1080, saechlichesExistenzminimum: 1824 } - // Reference: Art. 1 G. v. 22.12.2008 BGBl. I S. 2955 + # Reference: Art. 1 G. v. 22.12.2008 BGBl. I S. 2955 from 2009-01-01 = { - beitragErziehungAusbildung: 1080, // previous + beitragErziehungAusbildung: 1080, # previous saechlichesExistenzminimum: 1932 } - // Reference: Art. 1 G. v. 22.12.2009 BGBl. I S. 3950 + # Reference: Art. 1 G. v. 22.12.2009 BGBl. I S. 3950 from 2010-01-01 = { beitragErziehungAusbildung: 1320, saechlichesExistenzminimum: 2184 } - // Reference: Art. 1 G. v. 16.07.2015 BGBl. I S. 1202 + # Reference: Art. 1 G. v. 16.07.2015 BGBl. I S. 1202 from 2015-01-01 = { - beitragErziehungAusbildung: 1320, // previous + beitragErziehungAusbildung: 1320, # previous saechlichesExistenzminimum: 2256 } - // Reference: Art. 2 G. v. 16.07.2015 BGBl. I S. 1202 + # Reference: Art. 2 G. v. 16.07.2015 BGBl. I S. 1202 from 2016-01-01 = { - beitragErziehungAusbildung: 1320, // previous + beitragErziehungAusbildung: 1320, # previous saechlichesExistenzminimum: 2304 } - // Reference: Art. 8 G. v. 20.12.2016 BGBl. I. S. 3000 + # Reference: Art. 8 G. v. 20.12.2016 BGBl. I. S. 3000 from 2017-01-01 = { - beitragErziehungAusbildung: 1320, // previous + beitragErziehungAusbildung: 1320, # previous saechlichesExistenzminimum: 2358 } - // Reference: Art. 9 G. v. 20.12.2016 BGBl. I. S. 3000 + # Reference: Art. 9 G. v. 20.12.2016 BGBl. I. S. 3000 from 2018-01-01 = { - beitragErziehungAusbildung: 1320, // previous + beitragErziehungAusbildung: 1320, # previous saechlichesExistenzminimum: 2394 } - // Reference: Art. 1 G. v. 29.11.2018 BGBl. I S. 2210 + # Reference: Art. 1 G. v. 29.11.2018 BGBl. I S. 2210 from 2019-01-01 = { - beitragErziehungAusbildung: 1320, // previous + beitragErziehungAusbildung: 1320, # previous saechlichesExistenzminimum: 2490 } - // Reference: Art. 3 G. v. 29.11.2018 BGBl. I S. 2210 + # Reference: Art. 3 G. v. 29.11.2018 BGBl. I S. 2210 from 2020-01-01 = { - beitragErziehungAusbildung: 1320, // previous + beitragErziehungAusbildung: 1320, # previous saechlichesExistenzminimum: 2586 } - // Reference: Art. 1 G. v. 01.12.2020 BGBl. I S. 2616 + # Reference: Art. 1 G. v. 01.12.2020 BGBl. I S. 2616 from 2021-01-01 = { saechlichesExistenzminimum: 2730, beitr_erz_ausb: 1464 } - // Reference: Art. 1 G. v. 08.12.2022 BGBl. I S. 2230. + # Reference: Art. 1 G. v. 08.12.2022 BGBl. I S. 2230. from 2022-01-01 = { - beitragErziehungAusbildung: 2730, // previous + beitragErziehungAusbildung: 2730, # previous saechlichesExistenzminimum: 2810 } - // Reference: Art. 2 G. v. 08.12.2022 BGBl. I S. 2230. + # Reference: Art. 2 G. v. 08.12.2022 BGBl. I S. 2230. from 2023-01-01 = { - beitragErziehungAusbildung: 2730, // previous + beitragErziehungAusbildung: 2730, # previous saechlichesExistenzminimum: 3012 } @@ -122,14 +122,14 @@ const kinderFreibetrag: Dict { sächl_existenzmin: 3306 reference: >- Not implemented in law yet, but announced. - https://www.bmfsfj.de/bmfsfj/aktuelles/alle-meldungen/ + https:#www.bmfsfj.de/bmfsfj/aktuelles/alle-meldungen/ spuerbare-verbesserungen-fuer-familien--234802 - // Reference: Art. 3 G. v. 08.12.2022 BGBl. I S. 2230. - // Not implemented in law yet, but announced. https://www.bmfsfj.de/bmfsfj/aktuelles/alle-meldungen/spuerbare-verbesserungen-fuer-familien--234802 + # Reference: Art. 3 G. v. 08.12.2022 BGBl. I S. 2230. + # Not implemented in law yet, but announced. https:#www.bmfsfj.de/bmfsfj/aktuelles/alle-meldungen/spuerbare-verbesserungen-fuer-familien--234802 from 2024-01-01 = { - // deviation_from: previous - beitragErziehungAusbildung: 2730, // previous + # deviation_from: previous + beitragErziehungAusbildung: 2730, # previous saechlichesExistenzminimum: 3306 } } @@ -165,13 +165,13 @@ const werbungskostenpauschbetrag: Int { from 1990-01-01 = 1044 from 2004-01-01 = 920 - // Reference: Art. 1 G. v. 01.11.2011 BGBl. I S. 2131. + # Reference: Art. 1 G. v. 01.11.2011 BGBl. I S. 2131. from 2012-01-01 = 1000 - // Reference: Art. 2 G. v. 23.05.2022 BGBl. I S. 749 + # Reference: Art. 2 G. v. 23.05.2022 BGBl. I S. 749 from 2022-01-01 = 1200 - // Reference: G. v. 20.12.2022 BGBl. I S. 2294. + # Reference: G. v. 20.12.2022 BGBl. I S. 2294. from 2023-01-01 = 1230 } @@ -182,10 +182,10 @@ const werbungskostenpauschbetrag: Int { const sonderausgabenpauschbetrag: Int { from 1984-01-01 = 138 - // Reference: Art. 1 G. v. 25.07.1988, BGBl. I S. 1093 + # Reference: Art. 1 G. v. 25.07.1988, BGBl. I S. 1093 from 1988-01-01 = 55 - // Reference: Art. 1 G. v. 19.12.2000, BGBl. I S. 1790 + # Reference: Art. 1 G. v. 19.12.2000, BGBl. I S. 1790 from 2002-01-01 = 36 } @@ -200,15 +200,15 @@ const sparerpauschbetrag: Int { from 1993-01-01 = 3068 from 2000-01-01 = 1534 - // Reference: Art. 1 G. v. 19.12.2000 BGBl I S. 1790. + # Reference: Art. 1 G. v. 19.12.2000 BGBl I S. 1790. from 2002-01-01 = 1550 from 2004-01-01 = 1370 from 2007-01-01 = 750 - // Reference: Art. 1 G. v. 14.08.2007 BGBl. I S. 1912 + # Reference: Art. 1 G. v. 14.08.2007 BGBl. I S. 1912 from 2009-01-01 = 801 - // Reference: G. v. 20.12.2022 BGBl. I S. 2294. + # Reference: G. v. 20.12.2022 BGBl. I S. 2294. from 2023-01-01 = 1000 } @@ -243,7 +243,7 @@ const altersentlastungsbetragMax: Int | Dict { from 1989-01-01 = 1902 from 2002-01-01 = 1908 - // Reference: Artikel 1 G. v. 05.07.2004 BGBl. I S. 1427. + # Reference: Artikel 1 G. v. 05.07.2004 BGBl. I S. 1427. 2005-01-01 = { 1940: 1900, 1941: 1824, @@ -294,7 +294,7 @@ const altersentlastungsbetragMax: Int | Dict { const altersentlastungQuote: Float | Dict { from 1984-01-01 = 0.4 - // Reference: Artikel 1 G. v. 05.07.2004 BGBl. I S. 1427. + # Reference: Artikel 1 G. v. 05.07.2004 BGBl. I S. 1427. 2005-01-01 = { 1940: 0.4, 1941: 0.384, @@ -362,7 +362,7 @@ const einfuehrungsfaktor: { 2: {upper_threshold: inf, rate_linear: 0} } - // Reference: G. v. 20.12.2022 BGBl. I S. 2294. + # Reference: G. v. 20.12.2022 BGBl. I S. 2294. from 2023-01-01 = { 0: {lower_threshold: -inf, rate_linear: 0, intercept_at_lower_threshold: 0.6}, 1: {lower_threshold: 2005, rate_linear: 0.02}, @@ -383,13 +383,13 @@ const alleinerzFreibetrag: Int { from 2002-01-01 = 2340 from 2004-01-01 = 1308 - // Reference: Art. 1 G. v. 16.07.2015 BGBl. I S.1202 + # Reference: Art. 1 G. v. 16.07.2015 BGBl. I S.1202 from 2015-01-01 = 1908 - // Reference: Art. 3 Nr. 2 G. v. 29.12.2020 BGBl. I S.3096 + # Reference: Art. 3 Nr. 2 G. v. 29.12.2020 BGBl. I S.3096 from 2020-01-01 = 4008 - // Reference: G. v. 20.12.2022 BGBl. I S. 2294. + # Reference: G. v. 20.12.2022 BGBl. I S. 2294. from 2023-01-01 = 4260 } @@ -399,7 +399,7 @@ const alleinerzFreibetrag: Int { * dem 2. Kind. */ const alleinerzFreibetragZusatz: Int { - // Reference: Art. 1 G. vs. 16.07.2015 BGBl. I S.1202 + # Reference: Art. 1 G. vs. 16.07.2015 BGBl. I S.1202 from 2015-01-01 = 240 } @@ -413,10 +413,10 @@ const vorsorge2004KuerzungVorwegabzug: Float { from 1986-01-01 = 0.096 from 1987-01-01 = 0.0935 - // Reference: Art. 1 G. v. 25.07.1988 BGBl. I S. 1093 + # Reference: Art. 1 G. v. 25.07.1988 BGBl. I S. 1093 from 1989-01-01 = 0.12 - // Reference: Art. 1 G. v. 21.12.1993 BGBl. I S. 2310. + # Reference: Art. 1 G. v. 21.12.1993 BGBl. I S. 2310. from 1994-01-01 = 0.16 } @@ -426,10 +426,10 @@ const vorsorge2004KuerzungVorwegabzug: Float { * §10 Abs. 4 S.1 EStG */ const vorsorgeSonstigeAufwendungenMax: Int { - // Reference: Art. 1 G. v. 05.07.2004 BGBl. I S.1427 + # Reference: Art. 1 G. v. 05.07.2004 BGBl. I S.1427 from 2005-01-01 = 1500 - // Reference: Art. 1 G. v. 23.07.2009 BGBl. I S.1959. + # Reference: Art. 1 G. v. 23.07.2009 BGBl. I S.1959. from 2010-01-01 = 1900 } @@ -438,35 +438,35 @@ const vorsorgeSonstigeAufwendungenMax: Int { * §10 (3) EStG, Anlage 2 SGB VI */ const vorsorgeAltersvorsorgeaufwendungenMax: Int { - // Art. 1 G. v. 05.07.2004 BGBl. I S.1427 + # Art. 1 G. v. 05.07.2004 BGBl. I S.1427 from 2005-01-01 = 20000 - // Ab 2015 knappschaftlicher Höchstbetrag, d.h. knappschaftlicher Beitragssatz * - // knappschaftliche Beitragsbemessungsgrenze + # Ab 2015 knappschaftlicher Höchstbetrag, d.h. knappschaftlicher Beitragssatz * + # knappschaftliche Beitragsbemessungsgrenze from 2015-01-01 = 22170 - // .248 * 91800 + # .248 * 91800 from 2016-01-01 = 22766 - // .247 * 94200 + # .247 * 94200 from 2017-01-01 = 23362 - // .247 * 96000 + # .247 * 96000 from 2018-01-01 = 23712 - // .247 * 98400 + # .247 * 98400 from 2019-01-01 = 24305 - // .247 * 101400 - // Reference: Art. 3 V. v. 17.12.2019 BGBl I S. 2848. + # .247 * 101400 + # Reference: Art. 3 V. v. 17.12.2019 BGBl I S. 2848. from 2020-01-01 = 25046 - // .247 * 104400 - // Reference: §3 V. v. 30.11.2020 BGBl. I S. 2612. + # .247 * 104400 + # Reference: §3 V. v. 30.11.2020 BGBl. I S. 2612. from 2021-01-01 = 25787 - // .247 * 103800 - // Reference: §3 V. v. 30.11.2021, BGBl. I S. 5044. + # .247 * 103800 + # Reference: §3 V. v. 30.11.2021, BGBl. I S. 5044. from 2022-01-01 = 25640 } @@ -476,7 +476,7 @@ const vorsorgeAltersvorsorgeaufwendungenMax: Int { * §10 (3) a) S.4 EStG */ const vorsorgeKrankenMinderung: Float { - // Reference: Art. 1 G. v. 16.07.2009 BGBl. I S. 1959 + # Reference: Art. 1 G. v. 16.07.2009 BGBl. I S. 1959 from 2009-07-23 = 0.04 } @@ -485,7 +485,7 @@ const vorsorgeKrankenMinderung: Float { * § 33b (3) EStG. */ const behindertenPauschbetrag: Dict { - // Reference: G. v. 05.08.1974 BGBl. I S. 1769. + # Reference: G. v. 05.08.1974 BGBl. I S. 1769. from 1975-01-01 = { 0: 0, 25: 307, @@ -498,7 +498,7 @@ const behindertenPauschbetrag: Dict { 95: 1411 } - // Reference: Art. 1 G. v. 19.12.2000 BGBl. I S. 1790. + # Reference: Art. 1 G. v. 19.12.2000 BGBl. I S. 1790. from 2002-01-01 = { 0: 0, 25: 310, @@ -511,7 +511,7 @@ const behindertenPauschbetrag: Dict { 95: 1420 } - // Reference: Art. 1 G. v. 09.12.2020 BGBL. I S. 2770. + # Reference: Art. 1 G. v. 09.12.2020 BGBL. I S. 2770. from 2021-01-01 = { 0: 0, 20: 384, @@ -532,7 +532,7 @@ const behindertenPauschbetrag: Dict { * §10 (1) Nr. 5 EStG */ const kinderbetreuungskostenAbzAnteil: Float { - // Reference: Art. 1 G. v. 01.11.2011 BGBl. I S.2131 + # Reference: Art. 1 G. v. 01.11.2011 BGBl. I S.2131 from 2012-01-01 = 0.6666666 } @@ -541,7 +541,7 @@ const kinderbetreuungskostenAbzAnteil: Float { * §10 (1) Nr. 5 EStG */ const kinderbetreuungskostenAbzMaximum: Int { - // Reference: Art. 1 G. v. 01.11.2011 BGBl. I S.2131 + # Reference: Art. 1 G. v. 01.11.2011 BGBl. I S.2131 from 2012-01-01 = 4000 } @@ -601,7 +601,7 @@ const vorsorgepauschaleRentenversicherungsAnteil: Dict> * Reference: 39b (2) Nr.3 EStG */ const vorsorgepauschaleMindestanteil: Float { - // Reference: Art. 1 G. v. 16.07.2009 BGBl. I S. 1959 + # Reference: Art. 1 G. v. 16.07.2009 BGBl. I S. 1959 from 2009-07-23 = 0.12 } @@ -612,11 +612,11 @@ const vorsorgepauschaleMindestanteil: Float { * Reference: 39b (2) Nr.3 EStG. Depends on Steuerklasse. */ const vorsorgepauschaleKvMax: Dict { - // Reference: Art. 1 G. v. 16.07.2009 BGBl. I S. 1959 + # Reference: Art. 1 G. v. 16.07.2009 BGBl. I S. 1959 from 2009-07-23 = { steuerklasse_3: 3000, steuerklasse_nicht3: 1900 } } -// TODO: rounding +# TODO: rounding diff --git a/src/resources/builtins/parameters/elterngeld.ttsl b/src/resources/builtins/parameters/elterngeld.ttsl index 7d324bca..9c52c21f 100644 --- a/src/resources/builtins/parameters/elterngeld.ttsl +++ b/src/resources/builtins/parameters/elterngeld.ttsl @@ -1,6 +1,6 @@ package elterngeld -// elterngeld.yaml ------------------------------------------------------- +# elterngeld.yaml ------------------------------------------------------- /** * Faktor bei der ElG-Berechung, 2. Stufe @@ -24,13 +24,13 @@ const hoechstbetrag: Int { * vor der Geburt */ const nettoeinkommenStufen: Dict { - // Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 + # Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 from 2007-01-01 = { 1: 1000, 2: 1001 } - // Reference: Art. 14 G. v. 09.12.2010 BGBl. I S. 1885 + # Reference: Art. 14 G. v. 09.12.2010 BGBl. I S. 1885 from 2011-01-01 = { 1: 1000, 2: 1201 @@ -42,7 +42,7 @@ const nettoeinkommenStufen: Dict { * § 2 (5) BEEG */ const mindestbetrag: Int { - // Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 + # Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 from 2007-01-01 = 300 } @@ -51,7 +51,7 @@ const mindestbetrag: Int { * § 2 (2) BEEG */ const prozentKorrektur: Float { - // Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 + # Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 from 2007-01-01 = 0.001 } @@ -62,7 +62,7 @@ const prozentKorrektur: Float { const prozentMinimum: Float { from 2007-01-01 = 0.67 - // Reference: Art. 14 G. v. 09.12.2010 BGBl. I S. 1885 + # Reference: Art. 14 G. v. 09.12.2010 BGBl. I S. 1885 from 2011-01-01 = 0.65 } @@ -71,7 +71,7 @@ const prozentMinimum: Float { * § 2 (2) BEEG */ const einkommensSchrittKorrektur: Int { - // Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 + # Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 from 2007-01-01 = 2 } @@ -93,7 +93,7 @@ const geschwisterbonusAltersgrenzenKinder: Dict { * § 2a (1) BEEG. Früher § 2 (4) BEEG */ const geschwisterbonusAufschlag: Float { - // Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 + # Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 from 2007-01-01 = 0.1 } @@ -102,7 +102,7 @@ const geschwisterbonusAufschlag: Float { * § 2a (1) BEEG. Früher §2 (4) BEEG */ const geschwisterbonusMinimum: Int { - // Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 + # Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 from 2007-01-01 = 75 } @@ -112,7 +112,7 @@ const geschwisterbonusMinimum: Int { * pro Monat */ const mehrlingbonus: Int { - // Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 + # Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 from 2007-01-01 = 300 } @@ -121,7 +121,7 @@ const mehrlingbonus: Int { * §2f BEEG. Vor 2012 waren es die eigentlichen Pflichtbeiträge. */ const sozialversicherungspauschale: Float { - // Reference: Art. 1 G. v. 10.09.2012 BGBl. I S. 1878 + # Reference: Art. 1 G. v. 10.09.2012 BGBl. I S. 1878 from 2012-09-18 = 0.21 } @@ -130,7 +130,7 @@ const sozialversicherungspauschale: Float { * § 4 (3) BEEG */ const maxMonatePaar: Int { - // Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 + # Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 from 2007-01-01 = 14 } @@ -139,6 +139,6 @@ const maxMonatePaar: Int { * § 4 (3) BEEG */ const maxMonateIndividuell: Int { - // Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 + # Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 from 2007-01-01 = 12 } diff --git a/src/resources/builtins/parameters/erwerbsminderungsrente.ttsl b/src/resources/builtins/parameters/erwerbsminderungsrente.ttsl index 4b46d6ec..386fd935 100644 --- a/src/resources/builtins/parameters/erwerbsminderungsrente.ttsl +++ b/src/resources/builtins/parameters/erwerbsminderungsrente.ttsl @@ -1,6 +1,6 @@ package Erwerbsminderungsrente -// erwerbsm_rente.yaml --------------------------------------------------- +# erwerbsm_rente.yaml --------------------------------------------------- /** * Regelaltersgrenze diff --git a/src/resources/builtins/parameters/erziehungsgeld.ttsl b/src/resources/builtins/parameters/erziehungsgeld.ttsl index 5caa2dc7..d40d1083 100644 --- a/src/resources/builtins/parameters/erziehungsgeld.ttsl +++ b/src/resources/builtins/parameters/erziehungsgeld.ttsl @@ -1,6 +1,6 @@ package erziehungsgeld -// erziehungsgeld.yaml --------------------------------------------------- +# erziehungsgeld.yaml --------------------------------------------------- /** * Einkommensgrenze für abzugsfreies Erziehungsgeld @@ -95,5 +95,5 @@ const endAlterKindBudgetsatz: Int { from 2004-01-01 = 12 } -// TODO: rounding +# TODO: rounding diff --git a/src/resources/builtins/parameters/gesetzlicheRente.ttsl b/src/resources/builtins/parameters/gesetzlicheRente.ttsl index 75cbb42a..c5595358 100644 --- a/src/resources/builtins/parameters/gesetzlicheRente.ttsl +++ b/src/resources/builtins/parameters/gesetzlicheRente.ttsl @@ -1,6 +1,6 @@ package gesetzlicheRente -// ges_rente.yaml -------------------------------------------------------- +# ges_rente.yaml -------------------------------------------------------- /** * Teil des Nachhaltigkeitsfaktors in der Rentenanpassungsformel, welche das @@ -137,27 +137,27 @@ const beitragspflichtigesDurchschnittsentgelt: Int { from 2016-01-01 = 36187 from 2017-01-01 = 37077 - // Reference: V. v. 17.12.2019 BGBl. I S. 2848. + # Reference: V. v. 17.12.2019 BGBl. I S. 2848. from 2018-01-01 = 38212 - // Reference: V. v. 30.11.2020 BGBl. I S. 2612. + # Reference: V. v. 30.11.2020 BGBl. I S. 2612. from 2019-01-01 = 39301 - // Reference: §1 V. v. 30.11.2021, BGBl. I S. 5044. + # Reference: §1 V. v. 30.11.2021, BGBl. I S. 5044. from 2020-01-01 = 39167 - // Reference: §3 V. v. 28.11.2022 BGBl. I S. 2128 (Nr. 47). + # Reference: §3 V. v. 28.11.2022 BGBl. I S. 2128 (Nr. 47). from 2021-01-01 = 40463 - // Reference: §3 V. v. 24.11.2023 BGBl. 2023 I Nr. 322 + # Reference: §3 V. v. 24.11.2023 BGBl. 2023 I Nr. 322 from 2022-01-01 = 42053 - // Reference: §3 V. v. 28.11.2022 BGBl. 2022 I Nr. 2128 - // Vorläufiges Durchschnittsentgelt + # Reference: §3 V. v. 28.11.2022 BGBl. 2022 I Nr. 2128 + # Vorläufiges Durchschnittsentgelt from 2023-01-01 = 43142 - // Reference: §3 V. v. 24.11.2023 BGBl. 2023 I Nr. 322 - // Vorläufiges Durchschnittsentgelt + # Reference: §3 V. v. 24.11.2023 BGBl. 2023 I Nr. 322 + # Vorläufiges Durchschnittsentgelt from 2024-01-01 = 45358 } @@ -305,7 +305,7 @@ const rentenwert: Dict { } from 1993-01-01 = { - west: 21.80, // deviation_from: previous + west: 21.80, # deviation_from: previous ost: 14.41 } @@ -315,7 +315,7 @@ const rentenwert: Dict { } from 1994-01-01 = { - west: 22.75, // deviation_from: previous + west: 22.75, # deviation_from: previous ost: 17.05 } @@ -325,7 +325,7 @@ const rentenwert: Dict { } from 1995-01-01 = { - west: 23.52, // deviation_from: previous + west: 23.52, # deviation_from: previous ost: 18.13 } @@ -335,7 +335,7 @@ const rentenwert: Dict { } from 1996-01-01 = { - west: 23.64, // deviation_from: previous + west: 23.64, # deviation_from: previous ost: 19.39 } @@ -445,7 +445,7 @@ const rentenwert: Dict { } from 2021-07-01 = { - west: 34.19, // deviation_from: previous + west: 34.19, # deviation_from: previous ost: 33.47 } @@ -466,7 +466,7 @@ const rentenwert: Dict { * des Effekts eines weiteren Monats an Grundrentenzeiten auf Höchstwert. */ const grundrenteHöchstwert: Dict { - // Reference: § 76g Abs. 4 S. 3, 4 SGB VI + # Reference: § 76g Abs. 4 S. 3, 4 SGB VI from 2021-01-01 = { base: 0.0334, increment: 0.001389, @@ -489,7 +489,7 @@ const grundrenteZugangsfaktorMax: Int { * berücksichtigt werden */ const grundrenteZeiten: Dict { - // Reference: § 76g Abs. 4 S. 5,6 / Abs. 1 S. 1 SGB VI + # Reference: § 76g Abs. 4 S. 5,6 / Abs. 1 S. 1 SGB VI from 2021-01-01 = { min: 396, max: 420, @@ -503,7 +503,7 @@ const grundrenteZeiten: Dict { * Reference: § 97a Abs. 4 S. 2, 4 SGB VI */ const grundrenteEinkommensanrechnungSingle: Dict> { - // Reference: § 97a Abs. 4 S. 2, 4 SGB VI + # Reference: § 97a Abs. 4 S. 2, 4 SGB VI from 2021-01-01 = { 0: { lower_threshold: -inf, @@ -529,7 +529,7 @@ const grundrenteEinkommensanrechnungSingle: Dict> { * Reference: § 97a Abs. 4 S. 2, 4 SGB VI */ const grundrenteEinkommensanrechnungMarried: Dict> { - // Reference: § 97a Abs. 4 S. 2, 4 SGB VI + # Reference: § 97a Abs. 4 S. 2, 4 SGB VI from 2021-01-01 = { 0: { lower_threshold: -inf, @@ -554,7 +554,7 @@ const grundrenteEinkommensanrechnungMarried: Dict> { * multipliziert werden. */ const grundrenteFaktorBonus: Float { - // Reference: §§ 76g Abs. 4 S. 3, 4 SGB VI + # Reference: §§ 76g Abs. 4 S. 3, 4 SGB VI from 2021-01-01 = 0.875 } @@ -565,7 +565,7 @@ const grundrenteFaktorBonus: Float { * Reference: §77 Abs. 2 Nr. 2 SGB VI */ const zugangsfaktorVeraenderungProJahr: Dict { - // Reference: §77 Abs. 2 Nr. 2 SGB VI + # Reference: §77 Abs. 2 Nr. 2 SGB VI from 2001-01-01 = { vorzeitiger_renteneintritt: 0.036, späterer_renteneintritt: 0.06, @@ -622,12 +622,12 @@ const altersgrenzeFrauen: Dict> { rate_linear: 1, }, 2: { - upper_threshold: 1951.916666666, // constant 65 + upper_threshold: 1951.916666666, # constant 65 rate_linear: 0, }, 3: { upper_threshold: 1952, - // since 1952 abolished - regelaltersgrenze applies - jump in theshold by 6 month + # since 1952 abolished - regelaltersgrenze applies - jump in theshold by 6 month rate_linear: 6, }, 4: { @@ -664,7 +664,7 @@ const altersgrenzeFrauenVorzeitig: Dict> { rate_linear: 7, }, 2: { - upper_threshold: inf, // constant 67 + upper_threshold: inf, # constant 67 rate_linear: 0, }, } @@ -1103,13 +1103,13 @@ const altersgrenzeArbeitslosigkeitAbschlagsfrei: Float | Dict>{ from 1980-01-01 = 60.0 - // Increase of early retirement age from 60 to 62 for birth cohort 1949-1952. - // Reference: Rentenreformgesetz 1992. BGBl. I S. 2261 1989 § 41 + # Increase of early retirement age from 60 to 62 for birth cohort 1949-1952. + # Reference: Rentenreformgesetz 1992. BGBl. I S. 2261 1989 § 41 from 1992-01-01 = { max_birthyear_old_regime: 1948, min_birthyear_new_regime: 1953, @@ -1373,8 +1373,8 @@ const altersgrenzeArbeitslosigkeitVorzeitig: Float | Dict> }, } - // Increase of early retirement age from 60 to 65 for birth cohort 1937-1941. - // Reference: Wachstums- und Beschäftigungsförderungsgesetz 1996. BGBl. I S. 1461 1996 + # Increase of early retirement age from 60 to 65 for birth cohort 1937-1941. + # Reference: Wachstums- und Beschäftigungsförderungsgesetz 1996. BGBl. I S. 1461 1996 from 1996-07-29 = { max_birthyear_old_regime: 1948, min_birthyear_new_regime: 1953, @@ -1439,8 +1439,8 @@ const altersgrenzeArbeitslosigkeitVorzeitig: Float | Dict> vertrauensschutz: 60.0, } - // Increase of ERA was revoked. - // Reference: Wachstums- und Beschäftigungsförderungsgesetz 1996. BGBl. I S. 1461 1996 + # Increase of ERA was revoked. + # Reference: Wachstums- und Beschäftigungsförderungsgesetz 1996. BGBl. I S. 1461 1996 from 1996-09-27 = 60.0, from 2004-07-26 = { @@ -1493,8 +1493,8 @@ const altersgrenzeArbeitslosigkeitVorzeitig: Float | Dict> vertrauensschutz: 60.0, } - // Same statutory retirement ages as before, but abolishment with birth cohort 1952. - // Reference: RV-Nachhaltigkeitsgesetz 2004 and RV-Altersgrenzenanpassungsgesetz 2007. + # Same statutory retirement ages as before, but abolishment with birth cohort 1952. + # Reference: RV-Nachhaltigkeitsgesetz 2004 and RV-Altersgrenzenanpassungsgesetz 2007. from 2007-04-30 = { first_birthyear_without_rente_für_arbeitsl: 1952, max_birthyear_old_regime: 1945, @@ -1553,7 +1553,7 @@ const altersgrenzeArbeitslosigkeitVorzeitig: Float | Dict> * bezogen werden kann (mit Abschlägen). * Reference: § 236 SGB VI */ -const altersgrenzeLangjährigVersicherteVorzeitig: Float { +const altersgrenzeLangjährigVersicherteVorzeitig: Float { from 1980-01-01 = 63.0 } @@ -1586,7 +1586,7 @@ const altersgrenzeLangjährigVersicherteAbschlagsfrei: Dict> { const kapitaleinkommensfreibetrag: Int { from 1984-01-01 = 0 - // Reference: § 43 SGB XII Abs. 2 + # Reference: § 43 SGB XII Abs. 2 from 2016-01-01 = 26 } @@ -76,7 +76,7 @@ const kapitaleinkommensfreibetrag: Int { * Reference: § 82 SGB XII Abs. 3 */ const erwerbseinkommensfreibetrag: Float { - // Unclear how it was handled before 2005 + # Unclear how it was handled before 2005 from 1984-01-01 = 0 from 2005-01-01 = 0.3 @@ -90,7 +90,7 @@ const erwerbseinkommensfreibetrag: Float { */ const privateRenteAnrechnungsfrei: Dict> { from 1984-01-01: { - // Unclear how it was handled before 2005, + # Unclear how it was handled before 2005, 0: { lower_threshold: -inf, upper_threshold: inf, @@ -122,7 +122,7 @@ const privateRenteAnrechnungsfrei: Dict> { * Dieser Prozentanteil des Regelbedarfs wird Menschen mit Schwerbehindertenausweis * mit Merkzeichen G, die Grundsicherung im Alter oder bei Erwerbsminderung bekommen, * als Mehrbedarf anerkannt. - * Reference: § 30 Abs. 1 SGB XII, https://www.buzer.de/gesetz/3415/al0-3758.htm + * Reference: § 30 Abs. 1 SGB XII, https:#www.buzer.de/gesetz/3415/al0-3758.htm */ const mehrbedarfSchwerbehinderung: Float { from 2006-12-07 = 0.17 diff --git a/src/resources/builtins/parameters/kindergeld.ttsl b/src/resources/builtins/parameters/kindergeld.ttsl index f09add34..113ba43d 100644 --- a/src/resources/builtins/parameters/kindergeld.ttsl +++ b/src/resources/builtins/parameters/kindergeld.ttsl @@ -13,7 +13,7 @@ const altersgrenze: Dict { ohne_bedingungen: 18 } - // Reference: Art. 1 G. v. 19.07.2006 BGBl I S. 1652 + # Reference: Art. 1 G. v. 19.07.2006 BGBl I S. 1652 from 2007-01-01 = { mit_bedingungen: 25 ohne_bedingungen: 18 @@ -119,7 +119,7 @@ const kindergeld: Dict { 4: 179 } - // Reference: Art. 1 G. v. 22.12.2008 BGBl. I S. 2955 + # Reference: Art. 1 G. v. 22.12.2008 BGBl. I S. 2955 from 2009-01-01 = { 1: 164 2: 164 @@ -127,7 +127,7 @@ const kindergeld: Dict { 4: 195 } - // Reference: Art. 1 G. v. 02.03.2009 BGBl. I S. 416 + # Reference: Art. 1 G. v. 02.03.2009 BGBl. I S. 416 from 2009-03-01 = { 1: 164 2: 164 @@ -135,7 +135,7 @@ const kindergeld: Dict { 4: 195 } - // Reference: Art. 1 G. v. 22.12.2009 BGBl. I S. 3950 + # Reference: Art. 1 G. v. 22.12.2009 BGBl. I S. 3950 from 2009-12-01 = { 1: 184 2: 184 @@ -143,7 +143,7 @@ const kindergeld: Dict { 4: 215 } - // Reference: Art. 1 G. v. 16.07.2015 BGBl. I S. 1202 + # Reference: Art. 1 G. v. 16.07.2015 BGBl. I S. 1202 from 2015-07-01 = { 1: 188 2: 188 @@ -151,7 +151,7 @@ const kindergeld: Dict { 4: 219 } - // Reference: Art. 2 G. v. 16.07.2015 BGBl. I S. 1202 + # Reference: Art. 2 G. v. 16.07.2015 BGBl. I S. 1202 from 2016-01-01 = { 1: 190 2: 190 @@ -159,7 +159,7 @@ const kindergeld: Dict { 4: 221 } - // Reference: Art. 8 G. v. 20.12.2016 BGBl. I S. 3000 + # Reference: Art. 8 G. v. 20.12.2016 BGBl. I S. 3000 from 2017-01-01 = { 1: 192 2: 192 @@ -167,7 +167,7 @@ const kindergeld: Dict { 4: 223 } - // Reference: Art. 9 G. v. 20.12.2016 BGBl. I S. 3000. + # Reference: Art. 9 G. v. 20.12.2016 BGBl. I S. 3000. from 2018-01-01 = { 1: 194 2: 194 @@ -175,7 +175,7 @@ const kindergeld: Dict { 4: 225 } - // Reference: Art. 2 G. v. 29.11.2018 BGBl. I S. 2210. + # Reference: Art. 2 G. v. 29.11.2018 BGBl. I S. 2210. from 2019-07-01 = { 1: 204 2: 204 @@ -183,7 +183,7 @@ const kindergeld: Dict { 4: 235 } - // Reference: Art. 1 Abs. 9 G. v. 01.12.2020 BGBl. I S. 2616. + # Reference: Art. 1 Abs. 9 G. v. 01.12.2020 BGBl. I S. 2616. from 2021-01-01 = { 1: 219 2: 219 @@ -191,7 +191,7 @@ const kindergeld: Dict { 4: 250 } - // Reference: Art. 6 G. v. 08.12.2022 BGBl. I S. 2230. + # Reference: Art. 6 G. v. 08.12.2022 BGBl. I S. 2230. from 2023-01-01 = { 1: 250 2: 250 @@ -208,7 +208,7 @@ const kindergeld: Dict { const einkommensgrenze: Int { from 1984-01-01 = 0 - // Reference: Art. 1 G. v. 11.10.1995 BGBl. I S. 1250 + # Reference: Art. 1 G. v. 11.10.1995 BGBl. I S. 1250 from 1996-01-01 = 6136 from 1999-01-01 = 6657 @@ -217,12 +217,12 @@ const einkommensgrenze: Int { from 2001-01-01 = 7179 - // Reference: Art. 1 G. v. 16.08.2001 BGBl. I S. 2074 + # Reference: Art. 1 G. v. 16.08.2001 BGBl. I S. 2074 from 2002-01-01 = 7188 from 2004-01-01 = 7680 - // Reference: Art. 1 G. v. 16.07.2009 BGBl. I S. 1959 + # Reference: Art. 1 G. v. 16.07.2009 BGBl. I S. 1959 from 2009-01-01 = 8004 } @@ -233,7 +233,7 @@ const einkommensgrenze: Int { * reference period: Week */ const stundengrenze: Int { - // Reference: Art. 1 G. v. 01.11.2011 BGBl. I S. 2131 + # Reference: Art. 1 G. v. 01.11.2011 BGBl. I S. 2131 from 2012-01-01 = 20 } @@ -246,12 +246,12 @@ const stundengrenze: Int { const kinderbonus: Dict { from 1984-01-01 = 0 - // Reference: Art. 1 Zweites Corona-Steuerhilfegesetz v. 29.06.2020 BGBl. I S. 1512 + # Reference: Art. 1 Zweites Corona-Steuerhilfegesetz v. 29.06.2020 BGBl. I S. 1512 from 2020-01-01 = 300 - // Reference: Art. 1 Drittes Corona-Steuerhilfegesetz v. 10.03.2021 BGBl. I S. 330 + # Reference: Art. 1 Drittes Corona-Steuerhilfegesetz v. 10.03.2021 BGBl. I S. 330 from 2021-01-01 = 150 - // only one-time payment + # only one-time payment from 2022-01-01 = 0 } diff --git a/src/resources/builtins/parameters/kinderzuschlag.ttsl b/src/resources/builtins/parameters/kinderzuschlag.ttsl index 049b229a..057bba89 100644 --- a/src/resources/builtins/parameters/kinderzuschlag.ttsl +++ b/src/resources/builtins/parameters/kinderzuschlag.ttsl @@ -5,30 +5,30 @@ package kidnerzuschlag * Reference: § 6a (2) BKGG. Betrag pro Kind */ const maximum: Int { - // Reference: Art. 46 G. v. 24.12.2003 BGBl. I S. 2954. + # Reference: Art. 46 G. v. 24.12.2003 BGBl. I S. 2954. from 2005-01-01 = 140 - // Reference: Art. 12 G. v. 20.12.2016 BGBl. I S. 3000. + # Reference: Art. 12 G. v. 20.12.2016 BGBl. I S. 3000. from 2017-01-01 = 170 - // Reference: Art. 1 G. v. 29.04.2019 BGBl. I S. 530. - // Note: For 2020, Art. 2 Nr. 4 G. v. 29.04.2019 BGBl. I S. 530. + # Reference: Art. 1 G. v. 29.04.2019 BGBl. I S. 530. + # Note: For 2020, Art. 2 Nr. 4 G. v. 29.04.2019 BGBl. I S. 530. from 2019-07-01 = 185 - // Reference: § 6a (2) BKGG - // Note: Ab 2021 wird der Betrag aus anderen Parametern berechnet. + # Reference: § 6a (2) BKGG + # Note: Ab 2021 wird der Betrag aus anderen Parametern berechnet. from 2021-01-01 = null - // Reference: Art. 6 G. v. 08.12.2022 BGBl. I S. 2230. - // Note: Regelung für das Kalenderjahr 2023, abweichend von § 6a Absatz 2. + # Reference: Art. 6 G. v. 08.12.2022 BGBl. I S. 2230. + # Note: Regelung für das Kalenderjahr 2023, abweichend von § 6a Absatz 2. from 2023-01-01 = 250 - // Reference: § 6a (2) BKGG - // Note: Ab 2024 wird der Betrag wieder aus anderen Parametern berechnet. + # Reference: § 6a (2) BKGG + # Note: Ab 2024 wird der Betrag wieder aus anderen Parametern berechnet. from 2024-01-01 = null - // No law, should be calculated from other parameters (as 2021/2022), - // but parameters are not known yet. + # No law, should be calculated from other parameters (as 2021/2022), + # but parameters are not known yet. from 2024-01-01 = 292 } @@ -39,10 +39,10 @@ const maximum: Int { * § 6a Abs. 2 Satz 4 BKGG */ const kindersofortzuschl: Int { - // Reference: § 6a Abs. 2 Satz 4 BKGG + # Reference: § 6a Abs. 2 Satz 4 BKGG from 2022-07-01 = 20 - // Included in maximum Kinderzuschlag since 2023. + # Included in maximum Kinderzuschlag since 2023. from 2023-01-01 = null from 2024-01-01 = 20 @@ -53,10 +53,10 @@ const kindersofortzuschl: Int { * Reference: § 6a (1) Nr. 2 BKGG. */ const min_eink_paare: Int { - // Reference: kein expliziter Wert im Gesetz. + # Reference: kein expliziter Wert im Gesetz. from 2005-01-01 = 0 - // Reference: Art. 1 G. v. 24.09.2008 BGBl. I S. 1854. + # Reference: Art. 1 G. v. 24.09.2008 BGBl. I S. 1854. from 2008-10-01 = 900 } @@ -65,10 +65,10 @@ const min_eink_paare: Int { * Reference: § 6a (1) Nr. 2 BKGG. */ const min_eink_alleinerz: Int { - // Reference: kein expliziter Wert im Gesetz. + # Reference: kein expliziter Wert im Gesetz. from 2005-01-01 = 0 - // Reference: Art. 1 G. v. 24.09.2008 BGBl. I S. 1854. + # Reference: Art. 1 G. v. 24.09.2008 BGBl. I S. 1854. from 2008-10-01 = 600 } @@ -80,13 +80,13 @@ const min_eink_alleinerz: Int { * berücksichtigt. */ const entzugsrate_eltern: Float { - // Reference: Art. 46 G. v. 24.12.2003 BGBl. I. S. 2954. + # Reference: Art. 46 G. v. 24.12.2003 BGBl. I. S. 2954. from 2005-01-01 = 0.7 - // Reference: Art. 1 G. v. 24.09.2008 BGBl. I S. 1854. + # Reference: Art. 1 G. v. 24.09.2008 BGBl. I S. 1854. from 2008-10-01 = 0.5 - // Reference: Art. 1 G. v. 29.04.2019 BGBl. I S. 530. + # Reference: Art. 1 G. v. 29.04.2019 BGBl. I S. 530. from 2020-01-01 = 0.45 } @@ -97,10 +97,10 @@ const entzugsrate_eltern: Float { * Reference: § 6a (3) BKGG */ const entzugsrate_kind: Float { - // Reference: Art. 46 G. v. 24.12.2003 BGBl. I. S. 2954. + # Reference: Art. 46 G. v. 24.12.2003 BGBl. I. S. 2954. from 2005-01-01 = 1 - // Reference: Art. 1 G. v. 29.04.2019 BGBl. I S. 530. + # Reference: Art. 1 G. v. 29.04.2019 BGBl. I S. 530. from 2019-07-01 = 0.45 } @@ -111,7 +111,7 @@ const entzugsrate_kind: Float { * Existenzminima (nicht identisch mit dem steuerlichen Grundfreibetrag). */ const existenzminimum: Dict{ - // Reference: 5. Existenzminimumsbericht, Bundestag Drucksache 15/2462, Übersicht 3 + # Reference: 5. Existenzminimumsbericht, Bundestag Drucksache 15/2462, Übersicht 3 from 2005-01-01 = { regelsatz: { single: 4164 @@ -130,7 +130,7 @@ const existenzminimum: Dict{ } } - // Reference: 6. Existenzminimumsbericht, Bundestag Drucksache 16/3265, Übersicht 3 + # Reference: 6. Existenzminimumsbericht, Bundestag Drucksache 16/3265, Übersicht 3 from 2008-01-01 = { regelsatz: { single: 4140 @@ -149,7 +149,7 @@ const existenzminimum: Dict{ } } - // Reference: 7. Existenzminimumsbericht, Bundestag Drucksache 16/11065, Übersicht 3 + # Reference: 7. Existenzminimumsbericht, Bundestag Drucksache 16/11065, Übersicht 3 from 2010-01-01 = { regelsatz: { single: 4368 @@ -168,7 +168,7 @@ const existenzminimum: Dict{ } } - // Reference: 8. Existenzminimumsbericht, Bundestag Drucksache 17/5550, Übersicht 4 + # Reference: 8. Existenzminimumsbericht, Bundestag Drucksache 17/5550, Übersicht 4 from 2012-01-01 = { regelsatz: { single: 4488 @@ -190,8 +190,8 @@ const existenzminimum: Dict{ } } - // Reference: 9. Existenzminimumsbericht, Bundestag Drucksache 17/5550, Übersicht 5. Werte nur - // für Singles anders + # Reference: 9. Existenzminimumsbericht, Bundestag Drucksache 17/5550, Übersicht 5. Werte nur + # für Singles anders from 2013-01-01 = { regelsatz: { single: 4584 @@ -213,7 +213,7 @@ const existenzminimum: Dict{ } } - // Reference: 9. Existenzminimumsbericht, Bundestag Drucksache 17/5550, Übersicht 5. + # Reference: 9. Existenzminimumsbericht, Bundestag Drucksache 17/5550, Übersicht 5. from 2014-01-01 = { regelsatz: { single: 4680 @@ -235,8 +235,8 @@ const existenzminimum: Dict{ } } - // Reference: 10. Existenzminimumsbericht, Bundestag Drucksache 17/5550, - // Übersicht 4. Werte für Paare unverändert. + # Reference: 10. Existenzminimumsbericht, Bundestag Drucksache 17/5550, + # Übersicht 4. Werte für Paare unverändert. from 2015-01-01 = { regelsatz: { single: 4788 @@ -258,7 +258,7 @@ const existenzminimum: Dict{ } } - // Reference: 10. Existenzminimumsbericht, Bundestag Drucksache 17/5550, Übersicht 4. + # Reference: 10. Existenzminimumsbericht, Bundestag Drucksache 17/5550, Übersicht 4. from 2016-01-01 = { regelsatz: { single: 4872 @@ -280,7 +280,7 @@ const existenzminimum: Dict{ } } - // Reference: 11. Existenzminimumsbericht, Bundestag Drucksache 18/10220, Übersicht 4. + # Reference: 11. Existenzminimumsbericht, Bundestag Drucksache 18/10220, Übersicht 4. from 2017-01-01 = { regelsatz: { single: 4908 @@ -302,7 +302,7 @@ const existenzminimum: Dict{ } } - // Reference: 11. Existenzminimumsbericht, Bundestag Drucksache 18/10220, Übersicht 4. + # Reference: 11. Existenzminimumsbericht, Bundestag Drucksache 18/10220, Übersicht 4. from 2018-01-01 = { regelsatz: { single: 4968 @@ -324,7 +324,7 @@ const existenzminimum: Dict{ } } - // Reference: 12. Existenzminimumsbericht, Bundestag Drucksache 19/5400, Übersicht 4. + # Reference: 12. Existenzminimumsbericht, Bundestag Drucksache 19/5400, Übersicht 4. from 2019-01-01 = { regelsatz: { single: 5088 @@ -346,7 +346,7 @@ const existenzminimum: Dict{ } } - // Reference: 12. Existenzminimumsbericht, Bundestag Drucksache 19/5400, Übersicht 4. + # Reference: 12. Existenzminimumsbericht, Bundestag Drucksache 19/5400, Übersicht 4. from 2020-01-01 = { regelsatz: { single: 5196 @@ -368,7 +368,7 @@ const existenzminimum: Dict{ } } - // Reference: 13. Existenzminimumsbericht, Bundestag Drucksache 19/22800, Übersicht 4. + # Reference: 13. Existenzminimumsbericht, Bundestag Drucksache 19/22800, Übersicht 4. from 2021-01-01 = { regelsatz: { single: 5352 @@ -390,7 +390,7 @@ const existenzminimum: Dict{ } } - // Reference: 13. Existenzminimumsbericht, Bundestag Drucksache 19/22800, Übersicht 4. + # Reference: 13. Existenzminimumsbericht, Bundestag Drucksache 19/22800, Übersicht 4. from 2022-01-01 = { regelsatz: { single: 5400 @@ -412,7 +412,7 @@ const existenzminimum: Dict{ } } - // Reference: 14. Existenzminimumsbericht, Bundestag Drucksache 20/4443, Übersicht 4. + # Reference: 14. Existenzminimumsbericht, Bundestag Drucksache 20/4443, Übersicht 4. from 2023-01-01 = { deviation_from: previous regelsatz: { @@ -432,7 +432,7 @@ const existenzminimum: Dict{ } } - // Reference: 14. Existenzminimumsbericht, Bundestag Drucksache 20/4443, Übersicht 4. + # Reference: 14. Existenzminimumsbericht, Bundestag Drucksache 20/4443, Übersicht 4. from 2024-01-01 = { regelsatz: { single: 6444 diff --git a/src/resources/builtins/parameters/kinderzuschlagEinkommen.ttsl b/src/resources/builtins/parameters/kinderzuschlagEinkommen.ttsl index 0b2ebe81..362ef59c 100644 --- a/src/resources/builtins/parameters/kinderzuschlagEinkommen.ttsl +++ b/src/resources/builtins/parameters/kinderzuschlagEinkommen.ttsl @@ -1,6 +1,6 @@ package kidnerzuschlagEinkommen -// TODO: rounding +# TODO: rounding --- rounding: diff --git a/src/resources/builtins/parameters/lohnsteuer.ttsl b/src/resources/builtins/parameters/lohnsteuer.ttsl index ebaf00ef..38efe832 100644 --- a/src/resources/builtins/parameters/lohnsteuer.ttsl +++ b/src/resources/builtins/parameters/lohnsteuer.ttsl @@ -98,4 +98,4 @@ const lohnsteuerEinkommensgrenzen: Dict { } } -// TODO: rounding +# TODO: rounding diff --git a/src/resources/builtins/parameters/solidaritaetszuschlag.ttsl b/src/resources/builtins/parameters/solidaritaetszuschlag.ttsl index ac2c3ae8..3f5f318a 100644 --- a/src/resources/builtins/parameters/solidaritaetszuschlag.ttsl +++ b/src/resources/builtins/parameters/solidaritaetszuschlag.ttsl @@ -6,7 +6,7 @@ package solidaritaetszuschlag * transition_threshold in soli_st.py berechnet. */ const solidaritaetszuschlag: Dict> { - // Reference: Artikel 1 G. v. 24.06.1991 BGBl. I S. 1318. + # Reference: Artikel 1 G. v. 24.06.1991 BGBl. I S. 1318. from 1991-01-01 { 0: { lower_threshold: -inf @@ -28,9 +28,9 @@ const solidaritaetszuschlag: Dict> { intercept_at_lower_threshold: 0 upper_threshold: inf } - } // TODO: BEISPIEL FÜR DEVIATION!!!! + } # TODO: BEISPIEL FÜR DEVIATION!!!! - // Reference: Artikel 31 G. v. 23.06.1993 BGBl. I S. 944. + # Reference: Artikel 31 G. v. 23.06.1993 BGBl. I S. 944. from 1995-01-01 { 0: { lower_threshold: -inf @@ -48,7 +48,7 @@ const solidaritaetszuschlag: Dict> { } } - // Reference: Artikel 1 G. v. 21.11.1997 BGBl. I S. 2743. + # Reference: Artikel 1 G. v. 21.11.1997 BGBl. I S. 2743. from 1998-01-01 { 0: { lower_threshold: -inf @@ -66,7 +66,7 @@ const solidaritaetszuschlag: Dict> { } } - // Reference: G. v. 15.10.2002 BGBl. I S. 4131. + # Reference: G. v. 15.10.2002 BGBl. I S. 4131. from 2002-01-01 { 0: { lower_threshold: -inf @@ -84,7 +84,7 @@ const solidaritaetszuschlag: Dict> { } } - // Reference: Artikel 1 G. v. 10.12.2019 BGBl. I S. 2115. + # Reference: Artikel 1 G. v. 10.12.2019 BGBl. I S. 2115. from 2021-01-01 { 0: { lower_threshold: -inf @@ -102,9 +102,9 @@ const solidaritaetszuschlag: Dict> { } } - // Reference: Art. 4 G. v. 08.12.2022 BGBl. I S. 2230. + # Reference: Art. 4 G. v. 08.12.2022 BGBl. I S. 2230. from 2023-01-01 { - // deviation_from: previous + # deviation_from: previous 0: { upper_threshold: 17543 }, @@ -113,9 +113,9 @@ const solidaritaetszuschlag: Dict> { } } - // Reference: Art. 5 G. v. 08.12.2022 BGBl. I S. 2230. + # Reference: Art. 5 G. v. 08.12.2022 BGBl. I S. 2230. from 2024-01-01 { - // deviation_from: previous + # deviation_from: previous 0: { upper_threshold: 18130 }, diff --git a/src/resources/builtins/parameters/sozialversicherungsbeitrag.ttsl b/src/resources/builtins/parameters/sozialversicherungsbeitrag.ttsl index 5c96cdfe..77c86b8c 100644 --- a/src/resources/builtins/parameters/sozialversicherungsbeitrag.ttsl +++ b/src/resources/builtins/parameters/sozialversicherungsbeitrag.ttsl @@ -2,7 +2,7 @@ package sozialversicherungsbeitrag /** * Beitragssätze zu den gesetzlichen Sozialversicherungen - * + * * gesetzliche Krankenversicherung: * Beitragssätze für gesetzliche Krankenversicherung. mean_allgemein - * durchschnittlicher Beitragssatz, bis 2008 allgemein - allgemeiner Satz (§241 SGB @@ -15,13 +15,13 @@ package sozialversicherungsbeitrag * Beitragssatz für Arbeitnehmer zusatz_kinderlos - Beitragszuschlag für kinderlose * Versicherte, die das 23. Lebensjahr vollendet haben. Wird vom Arbeitnehmer * alleine getragen. Eingeführt 2005. - * + * * arbeitslosenversicherung: * Beitragssätze zur Arbeitslosenversicherung für Arbeitnehmer. - * + * * gesetzliche Rentenversicherung: * Beitragssätze zur allgemeinen Rentenversicherung für Arbeitnehmer. - * + * * access_different_date: jahresanfang */ const beitragssatz: Dict> { @@ -59,35 +59,35 @@ const beitragssatz: Dict> { } from 1988-01-01 { - // deviation_from: previous + # deviation_from: previous gesetzlicheKrankenversicherung: { mean_allgemein: 0.1288 } } from 1989-01-01 { - // deviation_from: previous + # deviation_from: previous gesetzlicheKrankenversicherung: { mean_allgemein: 0.129 } } from 1990-01-01 { - // deviation_from: previous + # deviation_from: previous gesetzlicheKrankenversicherung: { mean_allgemein: 0.125 } } from 1991-01-01 { - // deviation_from: previous + # deviation_from: previous gesetzlicheKrankenversicherung: { mean_allgemein: .128 } } from 1992-01-01 { - // deviation_from: previous + # deviation_from: previous arbeitslosenversicherung: 0.0315 gesetzlicheRentenversicherung: 0.0885 } @@ -101,7 +101,7 @@ const beitragssatz: Dict> { } from 1994-01-01 { - // deviation_from: previous + # deviation_from: previous gesetzlicheRentenversicherung: 0.096 } @@ -115,7 +115,7 @@ const beitragssatz: Dict> { } from 1996-01-01 { - // deviation_from: previous + # deviation_from: previous gesetzlicheRentenversicherung: 0.096 } @@ -129,14 +129,14 @@ const beitragssatz: Dict> { } from 1998-01-01 { - // deviation_from: previous + # deviation_from: previous gesetzlicheKrankenversicherung: { mean_allgemein: 0.136 } } from 2000-01-01 { - // deviation_from: previous + # deviation_from: previous gesetzlicheKrankenversicherung: { mean_allgemein: 0.1357 } @@ -144,7 +144,7 @@ const beitragssatz: Dict> { } from 2001-01-01 { - // deviation_from: previous + # deviation_from: previous gesetzlicheKrankenversicherung: { mean_allgemein: 0.1358 } @@ -152,14 +152,14 @@ const beitragssatz: Dict> { } from 2002-01-01 { - // deviation_from: previous + # deviation_from: previous gesetzlicheKrankenversicherung: { mean_allgemein: 0.14 } } from 2003-01-01 { - // deviation_from: previous + # deviation_from: previous gesetzlicheKrankenversicherung: { mean_allgemein: 0.144 } @@ -167,7 +167,7 @@ const beitragssatz: Dict> { } from 2004-01-01 { - // deviation_from: previous + # deviation_from: previous gesetzlicheKrankenversicherung: { mean_allgemein: 0.142 } @@ -185,10 +185,10 @@ const beitragssatz: Dict> { gesetzlicheRentenversicherung: 0.0975 } - // Allgemeiner Beitragssatz wird nicht mehr gleichmäßig aufgeteilt, Einführung des Sonderbeitrags - // Reference: Art. 1 G. v. 15.12.2004, BGBl I S. 3445. + # Allgemeiner Beitragssatz wird nicht mehr gleichmäßig aufgeteilt, Einführung des Sonderbeitrags + # Reference: Art. 1 G. v. 15.12.2004, BGBl I S. 3445. from 2005-07-01 { - // deviation_from: previous + # deviation_from: previous gesetzlicheKrankenversicherung: { mean_allgemein: 0.133 sonderbeitrag: 0.009 @@ -196,7 +196,7 @@ const beitragssatz: Dict> { } from 2007-01-01 { - // deviation_from: previous + # deviation_from: previous gesetzlicheKrankenversicherung: { mean_allgemein: 0.139 } @@ -218,7 +218,7 @@ const beitragssatz: Dict> { } from 2009-01-01 { - // deviation_from: previous + # deviation_from: previous gesetzlicheKrankenversicherung: { allgemein: 0.146 sonderbeitrag: 0.009 @@ -228,7 +228,7 @@ const beitragssatz: Dict> { } from 2009-07-01 { - // deviation_from: previous + # deviation_from: previous gesetzlicheKrankenversicherung: { allgemein: 0.14 ermäßigt: 0.134 @@ -236,9 +236,9 @@ const beitragssatz: Dict> { } } - // Reference: Art. 1 G. v. 22.12.2010 BGBl. I S. 2309 + # Reference: Art. 1 G. v. 22.12.2010 BGBl. I S. 2309 from 2011-01-01 { - // deviation_from: previous + # deviation_from: previous gesetzlicheKrankenversicherung: { allgemein: 0.146 ermäßigt: 0.14 @@ -246,21 +246,21 @@ const beitragssatz: Dict> { arbeitslosenversicherung: 0.015 } - // Quelle: http://www.bmas.de/DE/Service/Presse/Pressemitteilungen/rentenbericht-16-11-2011.html + # Quelle: http:#www.bmas.de/DE/Service/Presse/Pressemitteilungen/rentenbericht-16-11-2011.html from 2012-01-01 { - // deviation_from: previous + # deviation_from: previous gesetzlicheRentenversicherung: 0.098 } from 2013-01-01 { - // deviation_from: previous + # deviation_from: previous gesetzlicheRentenversicherung: 0.0945 gesetzlichePflegeversicherung: { standard: 0.01025 } } - // Abschaffung Sonderbeitrag, Einführung kassenabhängiger Zusatzbeitrag + # Abschaffung Sonderbeitrag, Einführung kassenabhängiger Zusatzbeitrag from 2015-01-01 { gesetzlicheKrankenversicherung: { allgemein: 0.146 @@ -275,33 +275,33 @@ const beitragssatz: Dict> { gesetzlicheRentenversicherung: 0.0935 } - // Bekanntmachung Bundesanzeiger 30.12.2015 + # Bekanntmachung Bundesanzeiger 30.12.2015 from 2016-01-01 { - // deviation_from: previous + # deviation_from: previous gesetzlicheKrankenversicherung: { meanZusatzbeitrag: 0.011 } } from 2017-01-01 { - // deviation_from: previous + # deviation_from: previous gesetzlichePflegeversicherung: { standard: 0.01275 } } from 2018-01-01 { - // deviation_from: previous + # deviation_from: previous gesetzlicheKrankenversicherung: { meanZusatzbeitrag: 0.01 } gesetzlicheRentenversicherung: 0.093 } - // Wieder-Einführung der Parität. Art. 2 G. v. 11.12.2018, BGBl. I S. 2387 - // (arbeitsl_v:) Set to 0.026 in Art. 2 Nr. 15 G. v. 18.12.2018 BGBl. I S. 2651. - // Temporarily reduced to 0.025 in BeiSaV 2019. - // Reference: (arbeitsl_v:) V. v. 21.12.2018 BGBl. I S. 2663 + # Wieder-Einführung der Parität. Art. 2 G. v. 11.12.2018, BGBl. I S. 2387 + # (arbeitsl_v:) Set to 0.026 in Art. 2 Nr. 15 G. v. 18.12.2018 BGBl. I S. 2651. + # Temporarily reduced to 0.025 in BeiSaV 2019. + # Reference: (arbeitsl_v:) V. v. 21.12.2018 BGBl. I S. 2663 from 2019-01-01 { gesetzlicheKrankenversicherung: { allgemein: 0.146 @@ -316,55 +316,55 @@ const beitragssatz: Dict> { gesetzlicheRentenversicherung: 0.093 } - // Temporarily reduced to 0.024 in BeiSaV 2019. - // Reference: (ges_krankenv mean_zusatzbeitrag:) BAnz AT 28.10.2019 B3 - // (arbeitsl_v:) V. v. 02.12.2019 BGBl. I S. 1998 + # Temporarily reduced to 0.024 in BeiSaV 2019. + # Reference: (ges_krankenv mean_zusatzbeitrag:) BAnz AT 28.10.2019 B3 + # (arbeitsl_v:) V. v. 02.12.2019 BGBl. I S. 1998 from 2020-01-01 { - // deviation_from: previous + # deviation_from: previous gesetzlicheKrankenversicherung: { meanZusatzbeitrag: 0.011 } arbeitslosenversicherung: 0.012 } - // Reference: (ges_krankenv mean_zusatzbeitrag:) BAnz AT 30.10.2020 B5 + # Reference: (ges_krankenv mean_zusatzbeitrag:) BAnz AT 30.10.2020 B5 from 2021-01-01 { - // deviation_from: previous + # deviation_from: previous gesetzlicheKrankenversicherung: { meanZusatzbeitrag: 0.013 } } - // Reference: Art. 2 Nr. 14 G. v. 11.07.2021, BGBl. I S. 2754. + # Reference: Art. 2 Nr. 14 G. v. 11.07.2021, BGBl. I S. 2754. from 2022-01-01 { - // deviation_from: previous + # deviation_from: previous gesetzlichePflegeversicherung: { zusatzKinderlos: 0.0035 } } - // Contribution rate for arbeitsl_v was temporarily reduced from 2019 to 2022 in BeiSaV 2019. - // Now back to level specified in § 341 Abs. 2 SGB III. - // Reference: (arbeitsl_v:) Art. 2 Nr. 15 G. v. 18.12.2018 BGBl. I S. 2651 - // (ges_krankenv mean_zusatzbeitrag:) BAnz AT 31.10.2022 B5 + # Contribution rate for arbeitsl_v was temporarily reduced from 2019 to 2022 in BeiSaV 2019. + # Now back to level specified in § 341 Abs. 2 SGB III. + # Reference: (arbeitsl_v:) Art. 2 Nr. 15 G. v. 18.12.2018 BGBl. I S. 2651 + # (ges_krankenv mean_zusatzbeitrag:) BAnz AT 31.10.2022 B5 from 2023-01-01 { - // deviation_from: previous + # deviation_from: previous arbeitslosenversicherung: 0.013 gesetzlicheKrankenversicherung: { meanZusatzbeitrag: 0.016 } } - // Reference: BAnz AT 31.10.2023 B3 + # Reference: BAnz AT 31.10.2023 B3 from 2024-01-01 { - // deviation_from: previous + # deviation_from: previous gesetzlicheKrankenversicherung: { meanZusatzbeitrag: 0.017 } } } -/** +/** * Beitragssätze zu den gesetzlichen Sozialversicherungen * Die Beitragsbemessungsgrenze für Kranken- und Pflegeversicherung ist identisch. */ @@ -611,7 +611,7 @@ const beitragsbemessungsgrenze: Dict> { } from 2007-01-01 { - // deviation_from: previous + # deviation_from: previous ges_rentenv: { ost: 4550 } @@ -651,7 +651,7 @@ const beitragsbemessungsgrenze: Dict> { } from 2011-01-01 { - // deviation_from: previous + # deviation_from: previous ges_krankenv: { west: 3712.5 ost: 3712.5 @@ -662,7 +662,7 @@ const beitragsbemessungsgrenze: Dict> { } from 2012-01-01 { - // deviation_from: previous + # deviation_from: previous ges_krankenv: { west: 3825 ost: 3825 @@ -683,7 +683,7 @@ const beitragsbemessungsgrenze: Dict> { } } - // http://www.bundesregierung.de/ContentArchiv/DE/Archiv17/Artikel/2013/10/2013-10-16-rechengroessen-sozialversicherung.html + # http:#www.bundesregierung.de/ContentArchiv/DE/Archiv17/Artikel/2013/10/2013-10-16-rechengroessen-sozialversicherung.html from 2014-01-01 { ges_krankenv: { west: 4050 @@ -706,7 +706,7 @@ const beitragsbemessungsgrenze: Dict> { } } - // https://www.bundesregierung.de/Content/DE/Artikel/2015/10/2015-10-14-sozialversicherung.html + # https:#www.bundesregierung.de/Content/DE/Artikel/2015/10/2015-10-14-sozialversicherung.html from 2016-01-01 { ges_krankenv: { west: 4237.5 @@ -718,7 +718,7 @@ const beitragsbemessungsgrenze: Dict> { } } - // https://www.bundesregierung.de/Content/DE/Artikel/2016/10/2016-10-12-bemessunggrenzen-sozialversicherung.html + # https:#www.bundesregierung.de/Content/DE/Artikel/2016/10/2016-10-12-bemessunggrenzen-sozialversicherung.html from 2017-01-01 { ges_krankenv: { west: 4350 @@ -752,7 +752,7 @@ const beitragsbemessungsgrenze: Dict> { } } - // Reference: V. v. 17.12.2019 BGBl. I S. 2848 + # Reference: V. v. 17.12.2019 BGBl. I S. 2848 from 2020-01-01 { ges_krankenv: { west: 4687.5 @@ -764,7 +764,7 @@ const beitragsbemessungsgrenze: Dict> { } } - // Reference: §3, §4 V. v. 30.11.2020, BGBl. I S. 2612. + # Reference: §3, §4 V. v. 30.11.2020, BGBl. I S. 2612. from 2021-01-01 { ges_krankenv: { west: 4837.5 @@ -776,16 +776,16 @@ const beitragsbemessungsgrenze: Dict> { } } - // Reference: §3 V. v. 30.11.2021, BGBl. I S. 5044. + # Reference: §3 V. v. 30.11.2021, BGBl. I S. 5044. from 2022-01-01 { - // deviation_from: previous + # deviation_from: previous ges_rentenv: { west: 7050 ost: 6750 } } - // Reference: V. v. 28.11.2022 BGBl. I. S. 2128. + # Reference: V. v. 28.11.2022 BGBl. I. S. 2128. from 2023-01-01 { ges_krankenv: { west: 4987.5 @@ -797,7 +797,7 @@ const beitragsbemessungsgrenze: Dict> { } } - // Reference: V. v. 24.11.2023 BGBl. 2023 I Nr. 322 + # Reference: V. v. 24.11.2023 BGBl. 2023 I Nr. 322 from 2024-01-01 { ges_krankenv: { west: 5175 @@ -810,9 +810,9 @@ const beitragsbemessungsgrenze: Dict> { } } -/** +/** * Monatliche Bezugsgröße - * §18 SGB IV and https://de.wikipedia.org/wiki/Bezugsgr%C3%B6%C3%9Fe + * §18 SGB IV and https:#de.wikipedia.org/wiki/Bezugsgr%C3%B6%C3%9Fe */ const monatlicheBezugsgroeße: Dict { from 1984-01-01 { @@ -895,7 +895,7 @@ const monatlicheBezugsgroeße: Dict { } from 2001-01-01 { - // deviation_from: previous + # deviation_from: previous ost: 1932.683310921706 } @@ -920,12 +920,12 @@ const monatlicheBezugsgroeße: Dict { } from 2007-01-01 { - // deviation_from: previous + # deviation_from: previous ost: 2100 } from 2008-01-01 { - // deviation_from: previous + # deviation_from: previous west: 2485 } @@ -940,12 +940,12 @@ const monatlicheBezugsgroeße: Dict { } from 2011-01-01 { - // deviation_from: previous + # deviation_from: previous ost: 2240 } from 2012-01-01 { - // deviation_from: previous + # deviation_from: previous west: 2625 } @@ -954,8 +954,8 @@ const monatlicheBezugsgroeße: Dict { ost: 2275 } - // http://www.bundesregierung.de/ContentArchiv/DE/Archiv17/Artikel/2013/10/2013-10-16-rechengroessen-sozialversicherung.html - from 2014-01-01 { + # http:#www.bundesregierung.de/ContentArchiv/DE/Archiv17/Artikel/2013/10/2013-10-16-rechengroessen-sozialversicherung.html + from 2014-01-01 { west: 2765 ost: 2345 } @@ -965,13 +965,13 @@ const monatlicheBezugsgroeße: Dict { ost: 2415 } - // https://www.bundesregierung.de/Content/DE/Artikel/2015/10/2015-10-14-sozialversicherung.html + # https:#www.bundesregierung.de/Content/DE/Artikel/2015/10/2015-10-14-sozialversicherung.html from 2016-01-01 { west: 2905 ost: 2520 } - // https://www.bundesregierung.de/Content/DE/Artikel/2016/10/2016-10-12-bemessunggrenzen-sozialversicherung.html + # https:#www.bundesregierung.de/Content/DE/Artikel/2016/10/2016-10-12-bemessunggrenzen-sozialversicherung.html from 2017-01-01 { west: 2975 ost: 2660 @@ -982,37 +982,37 @@ const monatlicheBezugsgroeße: Dict { ost: 2695 } - // Sozialversicherungs-Rechengrößenverordnung 2019, BGBl I S. 2024, 27.11.2018 + # Sozialversicherungs-Rechengrößenverordnung 2019, BGBl I S. 2024, 27.11.2018 from 2019-01-01 { west: 3115 ost: 2870 } - // Reference: §2 V. v. 17.12.2019 BGBl. I S. 2848 + # Reference: §2 V. v. 17.12.2019 BGBl. I S. 2848 from 2020-01-01 { west: 3185 ost: 3010 } - // Reference: §2 V. v. 30.11.2020, BGBl. I S. 2612. + # Reference: §2 V. v. 30.11.2020, BGBl. I S. 2612. from 2021-01-01 { west: 3290 ost: 3115 } - // Reference: §2 V. v. 30.11.2021, BGBl. I S. 5044. + # Reference: §2 V. v. 30.11.2021, BGBl. I S. 5044. from 2022-01-01 { west: 3290 ost: 3150 } - // Reference: V. v. 28.11.2022 BGBl. I. S. 2128. + # Reference: V. v. 28.11.2022 BGBl. I. S. 2128. from 2023-01-01 { west: 3395 ost: 3290 } - // Reference: V. v. 29.11.2023 BGBl. 2023 I Nr. 322. + # Reference: V. v. 29.11.2023 BGBl. 2023 I Nr. 322. from 2024-01-01 { west: 3535 ost: 3465 @@ -1043,35 +1043,35 @@ const geringfuegigeEinkommensgrenzenMonatlich: Dict { } from 1999-01-01 { - // deviation_from: previous + # deviation_from: previous ges_krankenv: 0.1 ges_rentenv: 0.12 st: 0 } from 2003-04-01 { - // deviation_from: previous + # deviation_from: previous ges_krankenv: 0.11 ges_rentenv: 0.12 st: 0.02 } from 2007-01-01 { - // deviation_from: previous + # deviation_from: previous ges_krankenv: 0.13 ges_rentenv: 0.15 st: 0.02 @@ -1278,11 +1278,11 @@ const mindestlohn: Float { from 2022-07-01 = 10.45 from 2022-10-01 = 12 - // Reference: V. v. 24.11.2023 BGBl. 2023 I Nr. 321 + # Reference: V. v. 24.11.2023 BGBl. 2023 I Nr. 321 from 2024-01-01 = 12.41 - // Reference: V. v. 24.11.2023 BGBl. 2023 I Nr. 321 + # Reference: V. v. 24.11.2023 BGBl. 2023 I Nr. 321 from 2025-01-01 = 12.82 } -// TODO: rounding +# TODO: rounding diff --git a/src/resources/builtins/parameters/unterhalt.ttsl b/src/resources/builtins/parameters/unterhalt.ttsl index fa8fad44..5be219d5 100644 --- a/src/resources/builtins/parameters/unterhalt.ttsl +++ b/src/resources/builtins/parameters/unterhalt.ttsl @@ -6,63 +6,63 @@ package unterhalt * Abhängigkeit des Alters (unter 6, unter 12, bis 17 Jahre) */ const mindestunterhalt: Dict { - // Reference: V. v. 03.12.2015 BGBl. I S. 2188. + # Reference: V. v. 03.12.2015 BGBl. I S. 2188. from 2016-01-01 = { 6: 335, 12: 384, 18: 450 } - - // Reference: V. v. 03.12.2015 BGBl. I S. 2188. + + # Reference: V. v. 03.12.2015 BGBl. I S. 2188. from 2017-01-01 = { 6: 342, 12: 393, 18: 460 } - // Reference: Artikel 1 V. v. 28.09.2017 BGBl. I S. 3525. + # Reference: Artikel 1 V. v. 28.09.2017 BGBl. I S. 3525. from 2018-01-01 = { 6: 348, 12: 399, 18: 467 } - // Reference: Artikel 1 V. v. 28.09.2017 BGBl. I S. 3525. + # Reference: Artikel 1 V. v. 28.09.2017 BGBl. I S. 3525. from 2019-01-01 = { 6: 354, 12: 406, 18: 476 } - // Reference: Artikel 1 V. v. 12.09.2019 BGBl. I S. 1393. + # Reference: Artikel 1 V. v. 12.09.2019 BGBl. I S. 1393. from 2020-01-01 = { 6: 369, 12: 424, 18: 497 } - // Reference: Artikel 1 V. v. 03.11.2020 BGBl. I S. 2344. + # Reference: Artikel 1 V. v. 03.11.2020 BGBl. I S. 2344. from 2021-01-01 = { 6: 393, 12: 451, 18: 528 } - // Reference: Artikel 1 V. v. 30.11.2021 BGBl. I S. 5066. + # Reference: Artikel 1 V. v. 30.11.2021 BGBl. I S. 5066. from 2022-01-01 = { 6: 396, 12: 455, 18: 533 } - // Reference: Artikel 1 V. v. 30.11.2022 BGBl. I S. 2130. + # Reference: Artikel 1 V. v. 30.11.2022 BGBl. I S. 2130. from 2023-01-01 = { 6: 437, 12: 502, 18: 588 } - - // Reference: Artikel 1 V. v. 29.11.2023 BGBl. I Nr. 330. + + # Reference: Artikel 1 V. v. 29.11.2023 BGBl. I Nr. 330. from 2024-01-01 = { 6: 480, 12: 551, diff --git a/src/resources/builtins/parameters/unterhaltvorschuss.ttsl b/src/resources/builtins/parameters/unterhaltvorschuss.ttsl index 6c7b3269..e6d91aab 100644 --- a/src/resources/builtins/parameters/unterhaltvorschuss.ttsl +++ b/src/resources/builtins/parameters/unterhaltvorschuss.ttsl @@ -6,7 +6,7 @@ package unterhaltvorschuss * Reference: § 1 (1a) Nr. 2 Unterhaltsvorschussgesetz */ const mindesteinkommen: Int = { - // Reference: Art. 23 G. v. 14.08.2017 BGBl. I S. 3122. + # Reference: Art. 23 G. v. 14.08.2017 BGBl. I S. 3122. from 2017-01-01 = 600; } @@ -16,7 +16,7 @@ const mindesteinkommen: Int = { * Reference: § 1 (1a) Nr. 2 Unterhaltsvorschussgesetz */ const altersgrenzeMindesteinkommen: Int = { - // Reference: Art. 23 G. v. 14.08.2017 BGBl. I S. 3122. + # Reference: Art. 23 G. v. 14.08.2017 BGBl. I S. 3122. from 2017-01-01 = 12; } @@ -29,7 +29,7 @@ const altersgrenzeMindesteinkommen: Int = { * Reference: § 1 Abs. 1, 1a UhVorschG */ const altersgrenzen: Dict = { - // Reference: § 1 Abs. 1, 1a UhVorschG + # Reference: § 1 Abs. 1, 1a UhVorschG from 2017-01-01 = { 1: 6, 2: 12, @@ -37,4 +37,4 @@ const altersgrenzen: Dict = { }; } -// TODO: rounding +# TODO: rounding diff --git a/src/resources/builtins/parameters/wohngeld.ttsl b/src/resources/builtins/parameters/wohngeld.ttsl index 0c566479..920b413e 100644 --- a/src/resources/builtins/parameters/wohngeld.ttsl +++ b/src/resources/builtins/parameters/wohngeld.ttsl @@ -7,10 +7,10 @@ package wohngeld const faktorBerechnungsformel: Float { from 1984-01-01 = 1 - // Reference: Art. 1 G. v. 24.09 2008 BGBl. I S. 1856 + # Reference: Art. 1 G. v. 24.09 2008 BGBl. I S. 1856 from 2009-01-01 = 1.08 - // Reference: Art. 1 G. v. 08.10.2015 BGBl 38 S.1610 + # Reference: Art. 1 G. v. 08.10.2015 BGBl 38 S.1610 from 2016-01-01 = 1.15 } @@ -21,7 +21,7 @@ const faktorBerechnungsformel: Float { * The keys from 1 to 12 below refer to the household size. */ const koeffizientenBerechnungsformel: Dict> { - // Parameter aus Regressionsanalyse der Wohngeldtabellen + # Parameter aus Regressionsanalyse der Wohngeldtabellen from 1984-01-01 = { 1: { a: 0.0532, @@ -85,7 +85,7 @@ const koeffizientenBerechnungsformel: Dict> { } } - // Parameter aus Regressionsanalyse der Wohngeldtabellen + # Parameter aus Regressionsanalyse der Wohngeldtabellen from 1990-01-01 = { 1: { a: 0.0648, @@ -149,7 +149,7 @@ const koeffizientenBerechnungsformel: Dict> { } } - // Parameter aus Regressionsanalyse der Wohngeldtabellen + # Parameter aus Regressionsanalyse der Wohngeldtabellen from 1992-01-01 = { 1: { a: 0.0666, @@ -213,7 +213,7 @@ const koeffizientenBerechnungsformel: Dict> { } } - // Reference: Art. 5 G. v. 22.12.1999 BGBl. I S. 2671 + # Reference: Art. 5 G. v. 22.12.1999 BGBl. I S. 2671 from 2001-01-01 = { 1: { a: 0.063, @@ -277,7 +277,7 @@ const koeffizientenBerechnungsformel: Dict> { } } - // Reference: Art. 1 G. v. 24.09 2008 BGBl. I S. 1856 + # Reference: Art. 1 G. v. 24.09 2008 BGBl. I S. 1856 from 2009-01-01 = { 1: { a: 0.063, @@ -341,7 +341,7 @@ const koeffizientenBerechnungsformel: Dict> { } } - // Reference: Art. 1 G. v. 08.10.2015 BGBl 38 S.1610 + # Reference: Art. 1 G. v. 08.10.2015 BGBl 38 S.1610 from 2016-01-01 = { 1: { a: 0.04, @@ -405,7 +405,7 @@ const koeffizientenBerechnungsformel: Dict> { } } - // Reference: Art. 1 G. v. 30.11.2019 BGBl. I S. 1877 + # Reference: Art. 1 G. v. 30.11.2019 BGBl. I S. 1877 from 2020-01-01 = { 1: { a: 0.04, @@ -469,7 +469,7 @@ const koeffizientenBerechnungsformel: Dict> { } } - // Reference: V. v. 03.06.2021 BGBl. I S. 1369. + # Reference: V. v. 03.06.2021 BGBl. I S. 1369. from 2022-01-01 = { 1: { a: 0.04, @@ -533,7 +533,7 @@ const koeffizientenBerechnungsformel: Dict> { } } - // Reference: Art. 1 G. v. 08.12.2022 BGBl. I Nr. 48 S. 2160 + # Reference: Art. 1 G. v. 08.12.2022 BGBl. I Nr. 48 S. 2160 from 2023-01-01 = { 1: { a: 0.04, @@ -598,40 +598,40 @@ const koeffizientenBerechnungsformel: Dict> { } } -/** +/** * Zusätzlicher Betrag für große Haushalte * Haushalte mit mehr als 12 Personen erhalten einen zusätzlichen Betrag pro Person, * der auf das Wohngeld für einen Haushalt mit 12 Personen angerechnet wird. * Reference: §19 Abs. 3 WoGG */ const bonusSehrGrosseHaushalte: Dict { - // Reference: Art. 5 G. v. 22.12.1999 BGBl. I S. 2671 + # Reference: Art. 5 G. v. 22.12.1999 BGBl. I S. 2671 from 2001-01-01 = { max_anz_personen_normale_berechnung: 12, bonus_jede_weitere_person: 40 } - // Reference: Art. 1 G. v. 24.09 2008 BGBl. I S. 1856 + # Reference: Art. 1 G. v. 24.09 2008 BGBl. I S. 1856 from 2009-01-01 = { - // deviation_from: previous + # deviation_from: previous bonus_jede_weitere_person: 43 } - // Reference: Art. 1 G. v. 08.10.2015 BGBl 38 S.1610 + # Reference: Art. 1 G. v. 08.10.2015 BGBl 38 S.1610 from 2016-01-01 = { - // deviation_from: previous + # deviation_from: previous bonus_jede_weitere_person: 47 } - // Reference: Art. 1 G. v. 30.11.2019 BGBl. I S. 1877 + # Reference: Art. 1 G. v. 30.11.2019 BGBl. I S. 1877 from 2020-01-01 = { - // deviation_from: previous + # deviation_from: previous bonus_jede_weitere_person: 51 } - // Reference: Art. 1 G. v. 08.12.2022 BGBl. I Nr. 48 S. 2160 + # Reference: Art. 1 G. v. 08.12.2022 BGBl. I Nr. 48 S. 2160 from 2023-01-01 = { - // deviation_from: previous + # deviation_from: previous bonus_jede_weitere_person: 57 } } @@ -652,19 +652,19 @@ const abzugStufen: Dict { } from 1991-01-01 = { - // deviation_from: previous + # deviation_from: previous 3: 0.26 } from 2002-01-01 = { - // deviation_from: previous + # deviation_from: previous 1: 0.1, 3: 0.3 - } + } - // Reference: Art. G. v. 02.10.2015 BGBl I S. 1610 + # Reference: Art. G. v. 02.10.2015 BGBl I S. 1610 from 2016-01-01 = { - // deviation_from: previous + # deviation_from: previous 0: 0.0 } } @@ -719,7 +719,7 @@ const minMiete: Dict { 12: 245, } - // Reference: Art. 1 G. v. 08.10.2015 BGBl Nr.38, S.1617 + # Reference: Art. 1 G. v. 08.10.2015 BGBl Nr.38, S.1617 from 2016-01-01 = { 1: 48, 2: 59, @@ -735,7 +735,7 @@ const minMiete: Dict { 12: 263 } - // Reference: Art. 1 G. v. 30.11.2019 BGBl. I S. 1877 + # Reference: Art. 1 G. v. 30.11.2019 BGBl. I S. 1877 from 2020-01-01 = { 1: 52, 2: 64, @@ -802,7 +802,7 @@ const minEink: Dict { 12: 1255 } - // Reference: Art. 1 G. v. 08.10.2015 BGBl Nr.38, S.1617 + # Reference: Art. 1 G. v. 08.10.2015 BGBl Nr.38, S.1617 from 2016-01-01 = { 1: 239, 2: 310, @@ -818,7 +818,7 @@ const minEink: Dict { 12: 1255 } - // reference: Art. 1 G. v. 30.11.2019 BGBl. I S. 1877 + # reference: Art. 1 G. v. 30.11.2019 BGBl. I S. 1877 from 2020-01-01 = { 1: 275, 2: 357, @@ -834,7 +834,7 @@ const minEink: Dict { 12: 1443 } - // Reference: Art. 1 G. v. 08.12.2022 BGBl. I Nr. 48 S. 2160 + # Reference: Art. 1 G. v. 08.12.2022 BGBl. I Nr. 48 S. 2160 from 2023-01-01 = { 1: 350, 2: 600, @@ -862,7 +862,7 @@ const freibetragKinder: Dict { } from 2001-01-01 = { - // deviation_from: previous + # deviation_from: previous arbeitendes_kind: 51 } @@ -871,8 +871,8 @@ const freibetragKinder: Dict { arbeitendes_kind: 50 } - // Reference: Art. 1 G. v. 08.10.2015 BGBl Nr.38, S.1617 - // Neu §17 3. WoGG a) Alleinerziehend b) Kind unter 18 und neu §17 4. WoGG Kind noch nicht 25J. + # Reference: Art. 1 G. v. 08.10.2015 BGBl Nr.38, S.1617 + # Neu §17 3. WoGG a) Alleinerziehend b) Kind unter 18 und neu §17 4. WoGG Kind noch nicht 25J. from 2016-01-01 = { alleinerz: 110, arbeitendes_kind: 100 @@ -896,7 +896,7 @@ const freibetragBehinderung: Dict | Int { } from 1986-01-01 = { - // deviation_from: previous + # deviation_from: previous 80: 612 } @@ -912,14 +912,14 @@ const freibetragBehinderung: Dict | Int { 80: 1500 } - // Reference: 2 Art. 1 G. v. 08.10.2015 BGBl Nr.38 S.1612 - // neue Regelung - §17 1. WoGG a) GDB = 100 b) GDB < 100 & pflegebedürftig gem. §14 SGB XI. + gleichz. Häusliche/teilstationäre/Kurzzeit-Pflege + # Reference: 2 Art. 1 G. v. 08.10.2015 BGBl Nr.38 S.1612 + # neue Regelung - §17 1. WoGG a) GDB = 100 b) GDB < 100 & pflegebedürftig gem. §14 SGB XI. + gleichz. Häusliche/teilstationäre/Kurzzeit-Pflege from 2016-01-01 = 1500 - // Reference: Art. 1 G. v. 30.11.2019 BGBl. I S. 1877 + # Reference: Art. 1 G. v. 30.11.2019 BGBl. I S. 1877 from 2020-01-01 = 1800 } -// TODO: DEVIATION FROM BEISPIEL!!! +# TODO: DEVIATION FROM BEISPIEL!!! /** * Behinderungsgrad für Freibetrag @@ -943,8 +943,8 @@ const behinderungsgrad: Dict { * Mietstufe geordnet. Alle Werte in vollen Euro. */ const maxMiete: Dict>> { - // Reference: Art. 1 G. v. 04.08.1980 BGBl I S. 1159. - // Bis 1985 nur drei Mietstufen, streng abhängig von der Größe der Gemeinde. Es wird "Wohnung mit Sammelheizung und mit Bad oder Duschraum" angenommen. + # Reference: Art. 1 G. v. 04.08.1980 BGBl I S. 1159. + # Bis 1985 nur drei Mietstufen, streng abhängig von der Größe der Gemeinde. Es wird "Wohnung mit Sammelheizung und mit Bad oder Duschraum" angenommen. from 1981-01-01 = { 1: { 1965: { @@ -1080,9 +1080,9 @@ const maxMiete: Dict>> { } } - - // Reference: Art. 1 G. v. 11.07.1985 BGBl I S. 1318. - // Es wird eine Wohnung mit "Sammelheizung und mit Bad oder Duschraum" angenommen. + + # Reference: Art. 1 G. v. 11.07.1985 BGBl I S. 1318. + # Es wird eine Wohnung mit "Sammelheizung und mit Bad oder Duschraum" angenommen. from 1985-01-01 = { 1: { 1965: { @@ -1266,8 +1266,8 @@ const maxMiete: Dict>> { } } - // Reference: Art. 1 G. v. 13.12.1989 BGBl I S. 2148. - // Es wird eine Wohnung mit "Sammelheizung und mit Bad oder Duschraum" angenommen. + # Reference: Art. 1 G. v. 13.12.1989 BGBl I S. 2148. + # Es wird eine Wohnung mit "Sammelheizung und mit Bad oder Duschraum" angenommen. from 1990-01-01 = { 1: { 1965: { @@ -1475,8 +1475,8 @@ const maxMiete: Dict>> { } } - // Reference: Art. 1 G. v. 10.08.1990 BGBl I S. 1522. - // Es wird eine Wohnung mit "Sammelheizung und mit Bad oder Duschraum" angenommen. + # Reference: Art. 1 G. v. 10.08.1990 BGBl I S. 1522. + # Es wird eine Wohnung mit "Sammelheizung und mit Bad oder Duschraum" angenommen. from 1990-10-01 = { 1: { 1965: { @@ -1636,8 +1636,8 @@ const maxMiete: Dict>> { } } - // Reference: Neufassung WoGG v. 11.02.1993 BGBl I S. 183. - // Es wird eine Wohnung mit "Sammelheizung und mit Bad oder Duschraum" angenommen. + # Reference: Neufassung WoGG v. 11.02.1993 BGBl I S. 183. + # Es wird eine Wohnung mit "Sammelheizung und mit Bad oder Duschraum" angenommen. from 1993-01-01 = { 1: { 1965: { @@ -1845,8 +1845,8 @@ const maxMiete: Dict>> { } } - // Reference: Art. 5 G. v. 22.12.1999, BGBl I S. 2671. - // Nimmt die Umrechnung in Euro von 2002 vorweg. + # Reference: Art. 5 G. v. 22.12.1999, BGBl I S. 2671. + # Nimmt die Umrechnung in Euro von 2002 vorweg. from 2001-01-01: 1: { 1965: { @@ -1933,7 +1933,7 @@ const maxMiete: Dict>> { 3: 420, 4: 454, 5: 520 - // TODO: Eintrag vergessen? + # TODO: Eintrag vergessen? }, 1991: { 1: 400, @@ -2006,7 +2006,7 @@ const maxMiete: Dict>> { } } - // Reference: Art. 1 G. v. 24.09.2008, BGBl I S. 1856. + # Reference: Art. 1 G. v. 24.09.2008, BGBl I S. 1856. from 2009-01-01 = { 1: { 1: 292, @@ -2057,8 +2057,8 @@ const maxMiete: Dict>> { 6: 99 } } - - // Reference: Art. 1 G. v. 02.10.2015, BGBl I S. 1610. + + # Reference: Art. 1 G. v. 02.10.2015, BGBl I S. 1610. from 2016-01-01 = { 1: { 1: 312, @@ -2108,8 +2108,8 @@ const maxMiete: Dict>> { 5: 111, 6: 126 } - - // Reference: Art. 1 G. v. 30.11.2019, BGBl I S. 1877. + + # Reference: Art. 1 G. v. 30.11.2019, BGBl I S. 1877. from 2020-01-01 = { 1: { 1: 338, @@ -2167,7 +2167,7 @@ const maxMiete: Dict>> { } } - // Reference: V. v. 03.06.2021 BGBl. I S. 1369. + # Reference: V. v. 03.06.2021 BGBl. I S. 1369. from 2022-01-01 = { 1: { 1: 347, @@ -2234,11 +2234,11 @@ const maxMiete: Dict>> { * 2009. Vorher war hohes Vermögen laut WoGG kein Ausschlussgrund. */ const vermoegensgrundfreibetrag: Float { - // No wealth threshold in place. + # No wealth threshold in place. from 1970-01-01 = inf - // Reference: Wohngeld-Verwaltungsvorschrift 2009. - // At least in place since then. + # Reference: Wohngeld-Verwaltungsvorschrift 2009. + # At least in place since then. from 2009-01-01 = 60000 } @@ -2247,11 +2247,11 @@ const vermoegensgrundfreibetrag: Float { * Wohngeld-Verwaltungsvorschift 21.37 */ const vermoegensfreibetragPerson: Float { - // No wealth threshold in place + # No wealth threshold in place from 1970-01-01 = inf - // Reference: Wohngeld-Verwaltungsvorschrift 2009. - // At least in place since then. + # Reference: Wohngeld-Verwaltungsvorschrift 2009. + # At least in place since then. from 2009-01-01 = 30000 } @@ -2309,4 +2309,4 @@ const klimakomponente: Dict { } } -// TODO: rounding \ No newline at end of file +# TODO: rounding \ No newline at end of file From 43359fc6460857bb15c58dd30ea7c5fbf142786f Mon Sep 17 00:00:00 2001 From: alex-senger Date: Sat, 29 Jun 2024 11:50:06 +0200 Subject: [PATCH 095/183] fix: add public visibility to each constant --- .../parameters/arbeitslosengeld2.ttsl | 20 +++---- .../builtins/parameters/einkommenssteuer.ttsl | 2 +- .../parameters/einkommenssteuerAbzuege.ttsl | 46 +++++++-------- .../builtins/parameters/elterngeld.ttsl | 28 +++++----- .../parameters/erwerbsminderungsrente.ttsl | 14 ++--- .../builtins/parameters/erziehungsgeld.ttsl | 16 +++--- .../builtins/parameters/gesetzlicheRente.ttsl | 56 +++++++++---------- .../parameters/grundsicherungImAlter.ttsl | 12 ++-- .../builtins/parameters/kindergeld.ttsl | 10 ++-- .../builtins/parameters/lohnsteuer.ttsl | 2 +- .../parameters/solidaritaetszuschlag.ttsl | 2 +- .../sozialversicherungsbeitrag.ttsl | 20 +++---- .../builtins/parameters/unterhalt.ttsl | 4 +- .../parameters/unterhaltvorschuss.ttsl | 6 +- .../builtins/parameters/wohngeld.ttsl | 30 +++++----- 15 files changed, 134 insertions(+), 134 deletions(-) diff --git a/src/resources/builtins/parameters/arbeitslosengeld2.ttsl b/src/resources/builtins/parameters/arbeitslosengeld2.ttsl index 9663b83a..6c39910b 100644 --- a/src/resources/builtins/parameters/arbeitslosengeld2.ttsl +++ b/src/resources/builtins/parameters/arbeitslosengeld2.ttsl @@ -311,7 +311,7 @@ public const regelsatz: Int | Dict { * 2005-2010 der Regelsatz für weitere Haushaltsmitglieder wurden als Anteil * des Standardsatzes bestimmt. */ - public const anteilRegelsatz: Dict { +public const anteilRegelsatz: Dict { # Reference: Artikel 1 G. v. 24.12.2003 BGBl. I S. 2954. from 2005-01-01 = { zwei_erwachsene: 0.9, @@ -359,7 +359,7 @@ public const mehrbedarfAnteil: Dict { * mehr auf und ist nicht mehr relevant, * da alle betroffenen Personen zu alt für ALG 2 sind. */ - def vermögensGrundfreibetragObergrenze: Dict { +public const vermögensGrundfreibetragObergrenze: Dict { # Reference: Artikel 1 G. v. 23.12.2002 BGBl. I S. 4607. from 2005-01-01 = { 1947: 33800, @@ -400,7 +400,7 @@ public const mehrbedarfAnteil: Dict { * von einem Jahr. Während der Karenzzeit ist ein Vermögen von 40.000 Euro für die * erste Person einer Bedarfsgemeinschaft und 15.000 Euro für jede weitere erlaubt. */ - const schonvermoegenBuergergeld: Dict { +public const schonvermoegenBuergergeld: Dict { # Reference: G. v. 20.12.2022 BGBl. I S. 2328. (Bürgergeld-Gesetz) from 2023-01-01 = { während_karenzzeit: 40000, @@ -412,7 +412,7 @@ public const mehrbedarfAnteil: Dict { * Vermögensfreibetrag für Erstausstattung * § 12 (2) Satz 1 Nr. 4 SGB II. */ -const vermoegensfreibetragAusstattung: Int { +public const vermoegensfreibetragAusstattung: Int { # Reference: Artikel 1 G. v. 24.12.2003 BGBl. I S. 2954. from 2005-01-01 = 750; @@ -424,7 +424,7 @@ const vermoegensfreibetragAusstattung: Int { * Vermögensgrundfreibetrag je Kind * § 12 (2) Satz 1 Nr. 1 SGB II. */ -const vermoegensfreibetragKind: Int { +public const vermoegensfreibetragKind: Int { # Reference: Artikel 1 G. v. 24.12.2003 BGBl. I S. 2954. from 2005-01-01 = 4100; @@ -439,7 +439,7 @@ const vermoegensfreibetragKind: Int { * Altersgrenzen für Vermögensfreibetrag * Vermögensfreibetrag ändert sich nach Geburtsjahr */ -const vermoegensfreibetragAlter: Dict { +public const vermoegensfreibetragAlter: Dict { 2005-01-01: { 1: 1948, 2: 1958, @@ -460,7 +460,7 @@ const vermoegensfreibetragAlter: Dict { * .2016 BGBl. I S. 1858 entfallen. Wie entfallen? * § 3 Alg II-V. Seit 01.01.2008 in § 6 Alg II-V. */ -const abzugfaehigePauschale: Dict { +public const abzugfaehigePauschale: Dict { # Reference: V. v. 20.10.2004 BGBl. I S. 2622 from 2005-01-01 = { werbung: 15.33, @@ -482,7 +482,7 @@ const abzugfaehigePauschale: Dict { * § 22 SGB II * unit: Euro / Quadratmeter */ -const maxMieteProQuadratMeter: Int { +public const maxMieteProQuadratMeter: Int { from 1984-01-01 = 10 } @@ -491,7 +491,7 @@ const maxMieteProQuadratMeter: Int { * Eine Mietwohnung darf für einen Single 45 Quadratmeter (+15 für jede weitere * Person) groß sein. */ -const berechtigteWohnflaecheMiete: Dict { +public const berechtigteWohnflaecheMiete: Dict { from 1984-01-01 = { single: 45, je_weitere_person: 15 @@ -506,7 +506,7 @@ const berechtigteWohnflaecheMiete: Dict { * gestiegen und wird ab 5 Personen im Haushalt um 20 Quadratmeter pro Person * angehoben. */ -const berechtigteWohnflaecheEigentum: Dict { +public const berechtigteWohnflaecheEigentum: Dict { from 1984-01-01 = { 1: 80, 2: 80, diff --git a/src/resources/builtins/parameters/einkommenssteuer.ttsl b/src/resources/builtins/parameters/einkommenssteuer.ttsl index 412da2fd..f5fb7c60 100644 --- a/src/resources/builtins/parameters/einkommenssteuer.ttsl +++ b/src/resources/builtins/parameters/einkommenssteuer.ttsl @@ -325,7 +325,7 @@ public const einkommenssteuerTarif: Dict> { * Diese Funktion ist hier ab 2002 angegeben. Vor 2002 das Steuersystem ist nicht * implementiert. */ -const renteErtragsanteil: Dict> { +public const renteErtragsanteil: Dict> { from 2002-01-01 = { 0: { lower_threshold: -inf, diff --git a/src/resources/builtins/parameters/einkommenssteuerAbzuege.ttsl b/src/resources/builtins/parameters/einkommenssteuerAbzuege.ttsl index d7ed150f..40e81ce6 100644 --- a/src/resources/builtins/parameters/einkommenssteuerAbzuege.ttsl +++ b/src/resources/builtins/parameters/einkommenssteuerAbzuege.ttsl @@ -9,7 +9,7 @@ pacakge einkommenssteuerAbzuege * veranlagte Paare. §32 (6) EStG, seit 2000. * Pro Jahr */ -const kinderFreibetrag: Dict { +public const kinderFreibetrag: Dict { # Reference: Art. 1 G. v. 23.12.1982 BGBl. I S. 1857. from 1983-01-01 = { saechlichesExistenzminimum: 110 @@ -140,7 +140,7 @@ const kinderFreibetrag: Dict { * Steuerpflichtigen. Wird verdoppelt für gemeinsam veranlagte Ehegatten. Der gesamte * Zeitverlauf wurde bereits 2005 festgelegt. */ -const vorsorge2004Vorwegabzug: Int { +public const vorsorge2004Vorwegabzug: Int { from 1985-01-01 = 1534 from 1989-01-01 = 2045 from 1993-01-01 = 3068 @@ -160,7 +160,7 @@ const vorsorge2004Vorwegabzug: Int { * § 9a Nr. 1a) EStG * This is the minimum amount deducted from any employment income. */ -const werbungskostenpauschbetrag: Int { +public const werbungskostenpauschbetrag: Int { from 1975-01-01 = 288 from 1990-01-01 = 1044 from 2004-01-01 = 920 @@ -179,7 +179,7 @@ const werbungskostenpauschbetrag: Int { * Sonderausgaben-Pauschbetrag * § 10c EStG */ -const sonderausgabenpauschbetrag: Int { +public const sonderausgabenpauschbetrag: Int { from 1984-01-01 = 138 # Reference: Art. 1 G. v. 25.07.1988, BGBl. I S. 1093 @@ -194,7 +194,7 @@ const sonderausgabenpauschbetrag: Int { * § 20 (9) EStG. Früher § 20 (4) EStG. Wert für Singles. Wird verdoppelt für * gemeinsam veranlagte. seit 2009. vor 2008 Sparerfreibetrag. */ -const sparerpauschbetrag: Int { +public const sparerpauschbetrag: Int { from 1975-01-01 = 153 from 1990-01-01 = 307 from 1993-01-01 = 3068 @@ -217,7 +217,7 @@ const sparerpauschbetrag: Int { * § 20 (9) EStG. Früher § 20 (4) EStG. Wert für Singles. Wird verdoppelt für * gemeinsam veranlagte. seit 2009. vor 2008 Sparerfreibetrag. */ -const sparerWerbungskostenPauschbetrag: Int { +public const sparerWerbungskostenPauschbetrag: Int { from 1975-01-01 = 51 from 2009-01-01 = 0 } @@ -226,7 +226,7 @@ const sparerWerbungskostenPauschbetrag: Int { * Allgemeine Vorsorgepauschale Grundhöchstbetrag, Grundtabelle * §10 (3) EStG bis 2004. */ -const vorsorge2004Grundhoechstbetrag: Int { +public const vorsorge2004Grundhoechstbetrag: Int { from 1985-01-01 = 1196 from 1992-01-01 = 1334 } @@ -238,7 +238,7 @@ const vorsorge2004Grundhoechstbetrag: Int { * haben, maximal den gleichen Altersentlastungsbetrag. Ab 2005 hängt dieser Betrag, * den diese Steuerpflichtigen erhalten, vom Geburtsjahr ab. */ -const altersentlastungsbetragMax: Int | Dict { +public const altersentlastungsbetragMax: Int | Dict { from 1984-01-01 = 1534 from 1989-01-01 = 1902 from 2002-01-01 = 1908 @@ -291,7 +291,7 @@ const altersentlastungsbetragMax: Int | Dict { * haben, die gleiche Altersentlastungsquote abgezogen. Ab 2005 hängt diese Quote, * den diese Steuerpflichtigen erhalten, vom Geburtsjahr ab. */ -const altersentlastungQuote: Float | Dict { +public const altersentlastungQuote: Float | Dict { from 1984-01-01 = 0.4 # Reference: Artikel 1 G. v. 05.07.2004 BGBl. I S. 1427. @@ -342,7 +342,7 @@ const altersentlastungQuote: Float | Dict { * Lebensjahr vollendet hatte. * Reference: § 24a Art. 3 EStG */ -const altersentlastungsbetragAltersgrenze: Int { +public const altersentlastungsbetragAltersgrenze: Int { from 1984-01-01 = 64 } @@ -355,7 +355,7 @@ const altersentlastungsbetragAltersgrenze: Int { * 2023 auf 100% gesetzt. * Reference: § 10 Abs. 1 Nr. 2 Buchst. a und b EStG */ -const einfuehrungsfaktor: { +public const einfuehrungsfaktor: { from 2005-01-01 = { 0: {lower_threshold: -inf, rate_linear: 0, intercept_at_lower_threshold: 0.6}, 1: {lower_threshold: 2005, upper_threshold: 2025, rate_linear: 0.02}, @@ -375,7 +375,7 @@ const einfuehrungsfaktor: { * Entlastungsbetrag für Alleinerziehende * § 24b (1) EStG. vor 2004 "Haushaltsfreibetrag", § 32 (7) EStG */ -const alleinerzFreibetrag: Int { +public const alleinerzFreibetrag: Int { from 1984-01-01 = 2154 from 1986-01-01 = 2319 from 1989-01-01 = 2871 @@ -398,7 +398,7 @@ const alleinerzFreibetrag: Int { * §24b (2) S. 2 EStG. Alleinerziehenden-Entlastungsbetrag, Zusatzbetrag pro Kind ab * dem 2. Kind. */ -const alleinerzFreibetragZusatz: Int { +public const alleinerzFreibetragZusatz: Int { # Reference: Art. 1 G. vs. 16.07.2015 BGBl. I S.1202 from 2015-01-01 = 240 } @@ -408,7 +408,7 @@ const alleinerzFreibetragZusatz: Int { * §10 (3) S. 2 EStG (vor 2004). Der Vorwegabzug wird pauschal um einen Anteil * gekürzt bei abhängig Beschäftigten (vereinfacht). */ -const vorsorge2004KuerzungVorwegabzug: Float { +public const vorsorge2004KuerzungVorwegabzug: Float { from 1985-01-01 = 0.0935 from 1986-01-01 = 0.096 from 1987-01-01 = 0.0935 @@ -425,7 +425,7 @@ const vorsorge2004KuerzungVorwegabzug: Float { * AL-V), der für sozialverspfl. Beschäftigte gilt. * §10 Abs. 4 S.1 EStG */ -const vorsorgeSonstigeAufwendungenMax: Int { +public const vorsorgeSonstigeAufwendungenMax: Int { # Reference: Art. 1 G. v. 05.07.2004 BGBl. I S.1427 from 2005-01-01 = 1500 @@ -437,7 +437,7 @@ const vorsorgeSonstigeAufwendungenMax: Int { * Maximalbetrag der Altersvorsorgeaufwendungen, 2005er Rechtsstand * §10 (3) EStG, Anlage 2 SGB VI */ -const vorsorgeAltersvorsorgeaufwendungenMax: Int { +public const vorsorgeAltersvorsorgeaufwendungenMax: Int { # Art. 1 G. v. 05.07.2004 BGBl. I S.1427 from 2005-01-01 = 20000 @@ -475,7 +475,7 @@ const vorsorgeAltersvorsorgeaufwendungenMax: Int { * Beschäftigten. * §10 (3) a) S.4 EStG */ -const vorsorgeKrankenMinderung: Float { +public const vorsorgeKrankenMinderung: Float { # Reference: Art. 1 G. v. 16.07.2009 BGBl. I S. 1959 from 2009-07-23 = 0.04 } @@ -484,7 +484,7 @@ const vorsorgeKrankenMinderung: Float { * Behinderten-Pauschbetrag, in Abhängigkeit des Behinderungsgrads. * § 33b (3) EStG. */ -const behindertenPauschbetrag: Dict { +public const behindertenPauschbetrag: Dict { # Reference: G. v. 05.08.1974 BGBl. I S. 1769. from 1975-01-01 = { 0: 0, @@ -531,7 +531,7 @@ const behindertenPauschbetrag: Dict { * anrechenbar ist * §10 (1) Nr. 5 EStG */ -const kinderbetreuungskostenAbzAnteil: Float { +public const kinderbetreuungskostenAbzAnteil: Float { # Reference: Art. 1 G. v. 01.11.2011 BGBl. I S.2131 from 2012-01-01 = 0.6666666 } @@ -540,7 +540,7 @@ const kinderbetreuungskostenAbzAnteil: Float { * Maximal abziehbare Betreuungsaufwendungen pro Kind * §10 (1) Nr. 5 EStG */ -const kinderbetreuungskostenAbzMaximum: Int { +public const kinderbetreuungskostenAbzMaximum: Int { # Reference: Art. 1 G. v. 01.11.2011 BGBl. I S.2131 from 2012-01-01 = 4000 } @@ -549,7 +549,7 @@ const kinderbetreuungskostenAbzMaximum: Int { * Anteil abgezogene Rentenversicherungsbeiträge * §10 (3) a) S.4 EStG */ -const vorsorgepauschaleRentenversicherungsAnteil: Dict> { +public const vorsorgepauschaleRentenversicherungsAnteil: Dict> { 2005-01-01 = { 0: { lower_threshold: -inf, @@ -600,7 +600,7 @@ const vorsorgepauschaleRentenversicherungsAnteil: Dict> * Mindestvorsorgepauschale * Reference: 39b (2) Nr.3 EStG */ -const vorsorgepauschaleMindestanteil: Float { +public const vorsorgepauschaleMindestanteil: Float { # Reference: Art. 1 G. v. 16.07.2009 BGBl. I S. 1959 from 2009-07-23 = 0.12 } @@ -611,7 +611,7 @@ const vorsorgepauschaleMindestanteil: Float { * Lohnsteuer abgesetzt werden können. * Reference: 39b (2) Nr.3 EStG. Depends on Steuerklasse. */ -const vorsorgepauschaleKvMax: Dict { +public const vorsorgepauschaleKvMax: Dict { # Reference: Art. 1 G. v. 16.07.2009 BGBl. I S. 1959 from 2009-07-23 = { steuerklasse_3: 3000, diff --git a/src/resources/builtins/parameters/elterngeld.ttsl b/src/resources/builtins/parameters/elterngeld.ttsl index 9c52c21f..a4626eab 100644 --- a/src/resources/builtins/parameters/elterngeld.ttsl +++ b/src/resources/builtins/parameters/elterngeld.ttsl @@ -6,7 +6,7 @@ package elterngeld * Faktor bei der ElG-Berechung, 2. Stufe * § 2 (1) BEEG */ -const faktor: Float { +public const faktor: Float { from 2007-01-01 = 0.67 } @@ -14,7 +14,7 @@ const faktor: Float { * Höchstbetrag des Elterngeldes * § 2 (1) BEEG */ -const hoechstbetrag: Int { +public const hoechstbetrag: Int { from 2007-01-01 = 1800 } @@ -23,7 +23,7 @@ const hoechstbetrag: Int { * § 2 (2) BEEG. Maßgeblich ist das durchschnittlich erzielte monatliche Einkommen * vor der Geburt */ -const nettoeinkommenStufen: Dict { +public const nettoeinkommenStufen: Dict { # Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 from 2007-01-01 = { 1: 1000, @@ -41,7 +41,7 @@ const nettoeinkommenStufen: Dict { * Mindestbetrag des Elterngeldes * § 2 (5) BEEG */ -const mindestbetrag: Int { +public const mindestbetrag: Int { # Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 from 2007-01-01 = 300 } @@ -50,7 +50,7 @@ const mindestbetrag: Int { * Korrektur des Prozentsatzes für hohe und niedrige Einkommen * § 2 (2) BEEG */ -const prozentKorrektur: Float { +public const prozentKorrektur: Float { # Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 from 2007-01-01 = 0.001 } @@ -59,7 +59,7 @@ const prozentKorrektur: Float { * Minimaler Anteil des Elterngelds am vorherigen Nettoeinkommen * § 2 (2) BEEG */ -const prozentMinimum: Float { +public const prozentMinimum: Float { from 2007-01-01 = 0.67 # Reference: Art. 14 G. v. 09.12.2010 BGBl. I S. 1885 @@ -70,7 +70,7 @@ const prozentMinimum: Float { * Einkommensschritte für die Korrektur * § 2 (2) BEEG */ -const einkommensSchrittKorrektur: Int { +public const einkommensSchrittKorrektur: Int { # Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 from 2007-01-01 = 2 } @@ -81,7 +81,7 @@ const einkommensSchrittKorrektur: Int { * wird das Elterngeld um 10% (max. um 75€) erhöht. * Reference: § 2a BEEG */ -const geschwisterbonusAltersgrenzenKinder: Dict { +public const geschwisterbonusAltersgrenzenKinder: Dict { from 2007-01-01 = { 3: 2, 6: 3 @@ -92,7 +92,7 @@ const geschwisterbonusAltersgrenzenKinder: Dict { * Geschwisterbonus als prozentualer Aufschlag * § 2a (1) BEEG. Früher § 2 (4) BEEG */ -const geschwisterbonusAufschlag: Float { +public const geschwisterbonusAufschlag: Float { # Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 from 2007-01-01 = 0.1 } @@ -101,7 +101,7 @@ const geschwisterbonusAufschlag: Float { * Minimaler Geschwisterbonus als Euro-Betrag * § 2a (1) BEEG. Früher §2 (4) BEEG */ -const geschwisterbonusMinimum: Int { +public const geschwisterbonusMinimum: Int { # Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 from 2007-01-01 = 75 } @@ -111,7 +111,7 @@ const geschwisterbonusMinimum: Int { * § 2a (4) BEEG, früher §2 (6) BEEG. * pro Monat */ -const mehrlingbonus: Int { +public const mehrlingbonus: Int { # Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 from 2007-01-01 = 300 } @@ -120,7 +120,7 @@ const mehrlingbonus: Int { * Sozialversicherungspauschale zur Berechnung des Nettoeinkommens * §2f BEEG. Vor 2012 waren es die eigentlichen Pflichtbeiträge. */ -const sozialversicherungspauschale: Float { +public const sozialversicherungspauschale: Float { # Reference: Art. 1 G. v. 10.09.2012 BGBl. I S. 1878 from 2012-09-18 = 0.21 } @@ -129,7 +129,7 @@ const sozialversicherungspauschale: Float { * Maximale Anzahl an Monaten, in denen ein Paar Elterngeld erhält * § 4 (3) BEEG */ -const maxMonatePaar: Int { +public const maxMonatePaar: Int { # Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 from 2007-01-01 = 14 } @@ -138,7 +138,7 @@ const maxMonatePaar: Int { * Maximale Anzahl an Monaten, die jedes Elternteil Elterngeld erhält * § 4 (3) BEEG */ -const maxMonateIndividuell: Int { +public const maxMonateIndividuell: Int { # Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 from 2007-01-01 = 12 } diff --git a/src/resources/builtins/parameters/erwerbsminderungsrente.ttsl b/src/resources/builtins/parameters/erwerbsminderungsrente.ttsl index 386fd935..42893173 100644 --- a/src/resources/builtins/parameters/erwerbsminderungsrente.ttsl +++ b/src/resources/builtins/parameters/erwerbsminderungsrente.ttsl @@ -10,7 +10,7 @@ package Erwerbsminderungsrente * Reference: § 77 SGB VI Zugangsfaktor * pro Jahr */ -const abschlagsfreieAltersgrenze: Dict { +public const abschlagsfreieAltersgrenze: Dict { from 2001-01-01 = 63 from 2012-01-01 = 63.083333 from 2012-02-01 = 63.166666 @@ -39,7 +39,7 @@ const abschlagsfreieAltersgrenze: Dict { * Reference: § 77 Abs. 4 SGB VI Zugangsfaktor * pro Jahr */ -const regelaltersgrezeLangjaehrigeVersicherte: Dict { +public const regelaltersgrezeLangjaehrigeVersicherte: Dict { from 2001-01-01 = 63 } @@ -50,7 +50,7 @@ const regelaltersgrezeLangjaehrigeVersicherte: Dict { * Reference: § 264d SGB VI Zugangsfaktor * pro Jahr */ -const wartezeitgrenzeLangjaehrigeVersicherteAbschlagsfrei: Dict { +public const wartezeitgrenzeLangjaehrigeVersicherteAbschlagsfrei: Dict { from 2001-01-01 = 35 from 2024-01-01 = 40 } @@ -63,7 +63,7 @@ const wartezeitgrenzeLangjaehrigeVersicherteAbschlagsfrei: Dict { * Reference: § 59 SGB VI Zurechnungszeit * pro Jahr */ -const zurechnungszeitgrenze: Dict { +public const zurechnungszeitgrenze: Dict { from 2001-01-01 = 62.916666 from 2001-02-01 = 62.833333 from 2001-03-01 = 62.75 @@ -122,7 +122,7 @@ const zurechnungszeitgrenze: Dict { * sind bei 10.8% gedeckelt. * Reference: § 77 SGB VI Zugangsfaktor */ -const minZugangsfaktor: Dict { +public const minZugangsfaktor: Dict { from 2000-01-01 = 0.892 } @@ -133,7 +133,7 @@ const minZugangsfaktor: Dict { * das Sicherungsziel der Rentenart im Verhältnis zu einer Altersrente. * Reference: § 67 SGB VI Rentenartfaktor */ -const rentenartfaktor: Dict { +public const rentenartfaktor: Dict { from 2001-01-01 = { teilw: 0.5, voll: 1.0 @@ -147,6 +147,6 @@ const rentenartfaktor: Dict { * Lebensjahr bis zum Beginn der Rente * Reference: SGB VI § 72: Grundbewertung */ -const altersgrenzeGrundbewertung: Dict { +public const altersgrenzeGrundbewertung: Dict { from 2001-01-01 = 16 } diff --git a/src/resources/builtins/parameters/erziehungsgeld.ttsl b/src/resources/builtins/parameters/erziehungsgeld.ttsl index d40d1083..1549dea2 100644 --- a/src/resources/builtins/parameters/erziehungsgeld.ttsl +++ b/src/resources/builtins/parameters/erziehungsgeld.ttsl @@ -6,7 +6,7 @@ package erziehungsgeld * Einkommensgrenze für abzugsfreies Erziehungsgeld * Reference: Bundesgesetzblatt Jahrgang 2004 Teil I Nr. 6 (p.209) */ -const erziehungsgeldEinkommensgrenze: Dict>> { +public const erziehungsgeldEinkommensgrenze: Dict>> { from 2004-02-09 = { limit: { alleinerz: { @@ -35,7 +35,7 @@ const erziehungsgeldEinkommensgrenze: Dict { +public const erziehungsgeldAufschlagEinkommen: Dict { from 2004-02-09 = 3140 } @@ -43,7 +43,7 @@ const erziehungsgeldAufschlagEinkommen: Dict { * Höhe des Erziehungsgeldes abhängig vom beantragtem Satz * Reference: Bundesgesetzblatt Jahrgang 2004 Teil I Nr. 6 § 5 (p.208) */ -const erziehungsgeldSatz: Dict { +public const erziehungsgeldSatz: Dict { from 2004-02-09 = { regelsatz: 300, budgetsatz: 450 @@ -58,7 +58,7 @@ const erziehungsgeldSatz: Dict { * das Produkt entsprechend vom Erziehungsgeld Anspruch abgezogen * Reference: Bundesgesetzblatt Jahrgang 2004 Teil I Nr. 6 */ -const abschlagFaktor: Float { +public const abschlagFaktor: Float { from 2004-02-09 = 0.052 } @@ -67,7 +67,7 @@ const abschlagFaktor: Float { * relevanten Einkommen zu berechnen * Reference: Bundesgesetzblatt Jahrgang 2004 Teil I Nr. 6 § 6 (p.209) */ -const pauschalAbzugAufEinkommen: Float { +public const pauschalAbzugAufEinkommen: Float { from 2004-02-09 = 0.76 } @@ -75,7 +75,7 @@ const pauschalAbzugAufEinkommen: Float { * Grenze der wöchentlichen Arbeitsstunden bis zu der Erziehungsgeld ausgezahlt wird * Reference: Bundesgesetzblatt Jahrgang 2004 Teil I Nr. 6 § 15 (p.211) */ -const arbeitsstundenWoechentlicheGrenze: Int { +public const arbeitsstundenWoechentlicheGrenze: Int { from 2004-02-09 = 30 } @@ -83,7 +83,7 @@ const arbeitsstundenWoechentlicheGrenze: Int { * Alter des Kindes in Monaten bis zu dem der Regelsatz bezogen werden kann. * Reference: Bundesgesetzblatt Jahrgang 2004 Teil I Nr. 6 */ -const endAlterKindRegelsatz: Int { +public const endAlterKindRegelsatz: Int { from 2004-01-01 = 24 } @@ -91,7 +91,7 @@ const endAlterKindRegelsatz: Int { * Alter des Kindes in Monaten bis zu dem der Budgetsatz bezogen werden kann. * Reference: Bundesgesetzblatt Jahrgang 2004 Teil I Nr. 6 */ -const endAlterKindBudgetsatz: Int { +public const endAlterKindBudgetsatz: Int { from 2004-01-01 = 12 } diff --git a/src/resources/builtins/parameters/gesetzlicheRente.ttsl b/src/resources/builtins/parameters/gesetzlicheRente.ttsl index c5595358..68ab6e82 100644 --- a/src/resources/builtins/parameters/gesetzlicheRente.ttsl +++ b/src/resources/builtins/parameters/gesetzlicheRente.ttsl @@ -7,7 +7,7 @@ package gesetzlicheRente * Verhältnis von Rentnern zu Beitragszahlern modifiziert * Reference: §68 Abs. 4 S. 6 SGB VI */ -const alpha: Float { +public const alpha: Float { from 1984-01-01 = 0.0 from 2002-01-01 = 0.25 } @@ -16,7 +16,7 @@ const alpha: Float { * Teil des Riesterfaktors in der Rentenanpassungsformel * Reference: §68 Abs. 5 SGB VI */ -const altersVorsorgeAnteil: Float { +public const altersVorsorgeAnteil: Float { from 1993-01-01 = 0.0 from 2002-01-01 = 0.5 from 2003-01-01 = 1.0 @@ -33,7 +33,7 @@ const altersVorsorgeAnteil: Float { * Beschäftigten, der geringfügig Beschäftigten und der Bezieher von ALG. * statistik-rente.de/drv */ -const beitragsvolumen: Dict { +public const beitragsvolumen: Dict { from 1991-01-01 = 108688000 from 1992-01-01 = 117359000 from 1993-01-01 = 120559000 @@ -71,7 +71,7 @@ const beitragsvolumen: Dict { * Multiplikation des Rentenwerts mit 45. statistik-rente.de/drv * Reference: § 154 Abs. 3 Satz 1 Nr. 2 SGB VI */ -const eckrente: Float { +public const eckrente: Float { from 1995-01-01 = 988.15 from 1996-01-01 = 992.72 from 1997-01-01 = 1009.1 @@ -102,7 +102,7 @@ const eckrente: Float { * Durchschnittslohn * Durchschnittsbruttolohn aller Arbeitnehmer:innen in einem Jahr */ -const durchschnittslohn: Float { +public const durchschnittslohn: Float { from 2005-01-01 = 28468.23 from 2006-01-01 = 28673.22 from 2007-01-01 = 28978.19 @@ -122,7 +122,7 @@ const durchschnittslohn: Float { * Durchschnittsentgelt aller Versicherten im Sinne der deutschen Sozialversicherung. * Dieses wird benötigt zur Berechnung der Entgeltpunkte. */ -const beitragspflichtigesDurchschnittsentgelt: Int { +public const beitragspflichtigesDurchschnittsentgelt: Int { from 2005-01-01 = 29202 from 2006-01-01 = 29494 from 2007-01-01 = 29951 @@ -167,7 +167,7 @@ const beitragspflichtigesDurchschnittsentgelt: Int { * diesen Faktor erhöht. * Reference: §256a SGB VI and Anlage 10 SGB VI */ -const umrechnungEntgeltpBeitrittsgebiet: Float { +public const umrechnungEntgeltpBeitrittsgebiet: Float { from 1945-01-01 = 1.0000 from 1946-01-01 = 1.0000 from 1947-01-01 = 1.0000 @@ -255,7 +255,7 @@ const umrechnungEntgeltpBeitrittsgebiet: Float { * Rentenvolumen * Gesamtvolumen der ausgezahlten Renten */ -const gesamtesRentenvolumen: Int { +public const gesamtesRentenvolumen: Int { from 1991-01-01 = 117912000 from 1992-01-01 = 130901000 from 1993-01-01 = 141180000 @@ -293,7 +293,7 @@ const gesamtesRentenvolumen: Int { * einen Entgeltpunkt entspricht. * Reference: statistik-rente.de/drv, § 68 SGB VI */ -const rentenwert: Dict { +public const rentenwert: Dict { from 1992-01-01 = { west: 21.19, ost: 12.05 @@ -465,7 +465,7 @@ const rentenwert: Dict { * Konstante zur Bestimmung des Höchstwerts der durchschnittlichen Entgeltpunkte und * des Effekts eines weiteren Monats an Grundrentenzeiten auf Höchstwert. */ -const grundrenteHöchstwert: Dict { +public const grundrenteHöchstwert: Dict { # Reference: § 76g Abs. 4 S. 3, 4 SGB VI from 2021-01-01 = { base: 0.0334, @@ -478,7 +478,7 @@ const grundrenteHöchstwert: Dict { * Der Zugangsfaktor für die Grundrente ist auf 1 begrenzt. * Reference: § 77 Abs. 2 SGB VI */ -const grundrenteZugangsfaktorMax: Int { +public const grundrenteZugangsfaktorMax: Int { from 2021-01-01 = 1 } @@ -488,7 +488,7 @@ const grundrenteZugangsfaktorMax: Int { * an Grundrentenzeiten ab der zusätzliche Monate an Grundrentenzeiten nicht * berücksichtigt werden */ -const grundrenteZeiten: Dict { +public const grundrenteZeiten: Dict { # Reference: § 76g Abs. 4 S. 5,6 / Abs. 1 S. 1 SGB VI from 2021-01-01 = { min: 396, @@ -502,7 +502,7 @@ const grundrenteZeiten: Dict { * Einkommensanrechnung des Grundrentenzuschlags zu ermitteln * Reference: § 97a Abs. 4 S. 2, 4 SGB VI */ -const grundrenteEinkommensanrechnungSingle: Dict> { +public const grundrenteEinkommensanrechnungSingle: Dict> { # Reference: § 97a Abs. 4 S. 2, 4 SGB VI from 2021-01-01 = { 0: { @@ -528,7 +528,7 @@ const grundrenteEinkommensanrechnungSingle: Dict> { * Einkommensanrechnung des Grundrentenzuschlags zu ermitteln * Reference: § 97a Abs. 4 S. 2, 4 SGB VI */ -const grundrenteEinkommensanrechnungMarried: Dict> { +public const grundrenteEinkommensanrechnungMarried: Dict> { # Reference: § 97a Abs. 4 S. 2, 4 SGB VI from 2021-01-01 = { 0: { @@ -553,7 +553,7 @@ const grundrenteEinkommensanrechnungMarried: Dict> { * Faktor mit dem die durch die Grundrente zusätzlich erhaltenen Entgeltpunkte * multipliziert werden. */ -const grundrenteFaktorBonus: Float { +public const grundrenteFaktorBonus: Float { # Reference: §§ 76g Abs. 4 S. 3, 4 SGB VI from 2021-01-01 = 0.875 } @@ -564,7 +564,7 @@ const grundrenteFaktorBonus: Float { * jedes Jahr, das länger/kürzer gearbeitet wird * Reference: §77 Abs. 2 Nr. 2 SGB VI */ -const zugangsfaktorVeraenderungProJahr: Dict { +public const zugangsfaktorVeraenderungProJahr: Dict { # Reference: §77 Abs. 2 Nr. 2 SGB VI from 2001-01-01 = { vorzeitiger_renteneintritt: 0.036, @@ -580,7 +580,7 @@ const zugangsfaktorVeraenderungProJahr: Dict { * höher oder niedriger, wenn keine Ausnahmeregelungen erfüllt sind. * Reference: § 35 Satz 2 SGB VI */ -const regelaltersgrenze: Dict> { +public const regelaltersgrenze: Dict> { from 1984-01-01 = { 0: { lower_threshold: -inf, @@ -609,7 +609,7 @@ const regelaltersgrenze: Dict> { * geboren vor 1952 in Rente gehen konnten. * Reference: § 237a SGB VI */ -const altersgrenzeFrauen: Dict> { +public const altersgrenzeFrauen: Dict> { from 1980-01-01 = { 0: { lower_threshold: -inf, @@ -651,7 +651,7 @@ const altersgrenzeFrauen: Dict> { * (mit Abschlägen). * Reference: § 237a SGB VI */ -const altersgrenzeFrauenVorzeitig: Dict> { +public const altersgrenzeFrauenVorzeitig: Dict> { from 1980-01-01 = { 0: { lower_threshold: -inf, @@ -675,7 +675,7 @@ const altersgrenzeFrauenVorzeitig: Dict> { * Kohorte, ab der Rente für Frauen abgeschafft. * Reference: § 237a SGB VI */ -const firstBirthyearWithoutRenteFrauen: Int { +public const firstBirthyearWithoutRenteFrauen: Int { from 1980-01-01 = 1952 } @@ -686,7 +686,7 @@ const firstBirthyearWithoutRenteFrauen: Int { * Wert ist als Jahr zu interpretieren. * Reference: § 237a SGB VI */ -const renteFrauenPflichtbeitrag: Int { +public const renteFrauenPflichtbeitrag: Int { from 1950-01-01 = 10 } @@ -696,7 +696,7 @@ const renteFrauenPflichtbeitrag: Int { * bezogen werden kann. * Reference: § 237 SGB VI */ -const altersgrenzeArbeitslosigkeitAbschlagsfrei: Float | Dict> { +public const altersgrenzeArbeitslosigkeitAbschlagsfrei: Float | Dict> { from 1980-01-01 = { 0: { scalar: 60.0, @@ -1305,7 +1305,7 @@ const altersgrenzeArbeitslosigkeitAbschlagsfrei: Float | Dict>{ +public const altersgrenzeArbeitslosigkeitVorzeitig: Float | Dict>{ from 1980-01-01 = 60.0 # Increase of early retirement age from 60 to 62 for birth cohort 1949-1952. @@ -1553,7 +1553,7 @@ const altersgrenzeArbeitslosigkeitVorzeitig: Float | Dict> * bezogen werden kann (mit Abschlägen). * Reference: § 236 SGB VI */ -const altersgrenzeLangjährigVersicherteVorzeitig: Float { +public const altersgrenzeLangjährigVersicherteVorzeitig: Float { from 1980-01-01 = 63.0 } @@ -1565,7 +1565,7 @@ const altersgrenzeLangjährigVersicherteVorzeitig: Float { * höher oder niedriger, wenn keine Ausnahmeregelungen erfüllt sind. * Reference: § 236 SGB VI */ -const altersgrenzeLangjährigVersicherteAbschlagsfrei: Dict> { +public const altersgrenzeLangjährigVersicherteAbschlagsfrei: Dict> { from 1984-01-01 = { 0: { lower_threshold: -inf, @@ -1610,7 +1610,7 @@ const altersgrenzeLangjährigVersicherteAbschlagsfrei: Dict> { +public const altersgrenzeBesondersLangjährigVersicherte: Dict> { from 2012-01-01 = { 0: { lower_threshold: -inf, @@ -1671,7 +1671,7 @@ const altersgrenzeBesondersLangjährigVersicherte: Dict> { * Kohorte, ab der Rente für besonders langjährig Versicherte vollständig eingeführt. * Reference: § 237 SGB VI */ -const firstBirthyearBesondersLangjährigVersicherte: Int { +public const firstBirthyearBesondersLangjährigVersicherte: Int { from 2012-01-01 = 1952 } diff --git a/src/resources/builtins/parameters/grundsicherungImAlter.ttsl b/src/resources/builtins/parameters/grundsicherungImAlter.ttsl index 69ac7228..de484b6e 100644 --- a/src/resources/builtins/parameters/grundsicherungImAlter.ttsl +++ b/src/resources/builtins/parameters/grundsicherungImAlter.ttsl @@ -9,7 +9,7 @@ package grundsicherungImAlter * Reference: § 1 Verordnung zur Durchführung des § 90 Abs. 2 Nr. 9 des Zwölften Buches * Sozialgesetzbuch */ -const vermoegensfreibetrag: Dict { +public const vermoegensfreibetrag: Dict { from 1984-01-01: { adult: 0, child: 0, @@ -29,7 +29,7 @@ const vermoegensfreibetrag: Dict { * Anrechnungsfreie Anteile staatliche Rente wenn mindestens 33 Jahre * Grundrentenzeiten erreicht wurden. */ -const gesetzlicheRenteAnrechnungsfrei: Dict> { +public const gesetzlicheRenteAnrechnungsfrei: Dict> { from 1984-01-01: { 0: { lower_threshold: -inf, @@ -62,7 +62,7 @@ const gesetzlicheRenteAnrechnungsfrei: Dict> { * Nur das Kapitaleinkommens, das über diesem Freibetrag liegt, wird auf die * Grundsicherung im Alter angerechnet. The reference is § 82 SGB XII Abs. 2. */ -const kapitaleinkommensfreibetrag: Int { +public const kapitaleinkommensfreibetrag: Int { from 1984-01-01 = 0 # Reference: § 43 SGB XII Abs. 2 @@ -75,7 +75,7 @@ const kapitaleinkommensfreibetrag: Int { * zum Einkommen addiert wird. * Reference: § 82 SGB XII Abs. 3 */ -const erwerbseinkommensfreibetrag: Float { +public const erwerbseinkommensfreibetrag: Float { # Unclear how it was handled before 2005 from 1984-01-01 = 0 @@ -88,7 +88,7 @@ const erwerbseinkommensfreibetrag: Float { * Einkommen addiert wird. * Reference: § 82 SGB XII Abs. 4 */ -const privateRenteAnrechnungsfrei: Dict> { +public const privateRenteAnrechnungsfrei: Dict> { from 1984-01-01: { # Unclear how it was handled before 2005, 0: { @@ -124,6 +124,6 @@ const privateRenteAnrechnungsfrei: Dict> { * als Mehrbedarf anerkannt. * Reference: § 30 Abs. 1 SGB XII, https:#www.buzer.de/gesetz/3415/al0-3758.htm */ -const mehrbedarfSchwerbehinderung: Float { +public const mehrbedarfSchwerbehinderung: Float { from 2006-12-07 = 0.17 } diff --git a/src/resources/builtins/parameters/kindergeld.ttsl b/src/resources/builtins/parameters/kindergeld.ttsl index 113ba43d..d431e1b6 100644 --- a/src/resources/builtins/parameters/kindergeld.ttsl +++ b/src/resources/builtins/parameters/kindergeld.ttsl @@ -7,7 +7,7 @@ package kindergeld * Bedingungen ein Anspruch auf Kindergeld bestehen. * Reference: § 32 Art. 2-4 EStG. */ -const altersgrenze: Dict { +public const altersgrenze: Dict { from 1984-01-01 = { mit_bedingungen: 27 ohne_bedingungen: 18 @@ -27,7 +27,7 @@ const altersgrenze: Dict { * Für Werte vor 2002, siehe 'BMF - Datensammlung zur Steuerpolitik' * reference period: Month */ -const kindergeld: Dict { +public const kindergeld: Dict { from 1975-01-01 = { 1: 26 2: 36 @@ -205,7 +205,7 @@ const kindergeld: Dict { * § 32 (4) EStG. Wurde 2012 durch eine Höchstgrenze der gearbeiteten Stunden ersetzt. * reference period: Year */ -const einkommensgrenze: Int { +public const einkommensgrenze: Int { from 1984-01-01 = 0 # Reference: Art. 1 G. v. 11.10.1995 BGBl. I S. 1250 @@ -232,7 +232,7 @@ const einkommensgrenze: Int { * Bezug von Kindergeld * reference period: Week */ -const stundengrenze: Int { +public const stundengrenze: Int { # Reference: Art. 1 G. v. 01.11.2011 BGBl. I S. 2131 from 2012-01-01 = 20 } @@ -243,7 +243,7 @@ const stundengrenze: Int { * 2020 bzw. Mai 2021 ausgezahlt, aber ist hier auf das volle Kalenderjahr angerechnet. * reference period: Year */ -const kinderbonus: Dict { +public const kinderbonus: Dict { from 1984-01-01 = 0 # Reference: Art. 1 Zweites Corona-Steuerhilfegesetz v. 29.06.2020 BGBl. I S. 1512 diff --git a/src/resources/builtins/parameters/lohnsteuer.ttsl b/src/resources/builtins/parameters/lohnsteuer.ttsl index 38efe832..3e6d7007 100644 --- a/src/resources/builtins/parameters/lohnsteuer.ttsl +++ b/src/resources/builtins/parameters/lohnsteuer.ttsl @@ -6,7 +6,7 @@ package lohnsteuer * Mindest- und Maximalsteuern festgelegt sind. * Referenz: § 39b Absatz 2 Satz 7 EStG */ -const lohnsteuerEinkommensgrenzen: Dict { +public const lohnsteuerEinkommensgrenzen: Dict { from 2002-01-01 { 0: 8946, 1: 27306, diff --git a/src/resources/builtins/parameters/solidaritaetszuschlag.ttsl b/src/resources/builtins/parameters/solidaritaetszuschlag.ttsl index 3f5f318a..e67d3960 100644 --- a/src/resources/builtins/parameters/solidaritaetszuschlag.ttsl +++ b/src/resources/builtins/parameters/solidaritaetszuschlag.ttsl @@ -5,7 +5,7 @@ package solidaritaetszuschlag * Ab 1995, der upper threshold im Intervall 1 ist nach der Formel * transition_threshold in soli_st.py berechnet. */ -const solidaritaetszuschlag: Dict> { +public const solidaritaetszuschlag: Dict> { # Reference: Artikel 1 G. v. 24.06.1991 BGBl. I S. 1318. from 1991-01-01 { 0: { diff --git a/src/resources/builtins/parameters/sozialversicherungsbeitrag.ttsl b/src/resources/builtins/parameters/sozialversicherungsbeitrag.ttsl index 77c86b8c..9fdcec67 100644 --- a/src/resources/builtins/parameters/sozialversicherungsbeitrag.ttsl +++ b/src/resources/builtins/parameters/sozialversicherungsbeitrag.ttsl @@ -24,7 +24,7 @@ package sozialversicherungsbeitrag * * access_different_date: jahresanfang */ -const beitragssatz: Dict> { +public const beitragssatz: Dict> { from 1984-01-01 { gesetzlicheKrankenversicherung: { mean_allgemein: 0.134 @@ -368,7 +368,7 @@ const beitragssatz: Dict> { * Beitragssätze zu den gesetzlichen Sozialversicherungen * Die Beitragsbemessungsgrenze für Kranken- und Pflegeversicherung ist identisch. */ -const beitragsbemessungsgrenze: Dict> { +public const beitragsbemessungsgrenze: Dict> { from 1984-01-01 { ges_krankenv: { west: 1994 @@ -814,7 +814,7 @@ const beitragsbemessungsgrenze: Dict> { * Monatliche Bezugsgröße * §18 SGB IV and https:#de.wikipedia.org/wiki/Bezugsgr%C3%B6%C3%9Fe */ -const monatlicheBezugsgroeße: Dict { +public const monatlicheBezugsgroeße: Dict { from 1984-01-01 { west: 1396 } @@ -1025,7 +1025,7 @@ const monatlicheBezugsgroeße: Dict { * neunzigste Teil der monatlichen Bezugsgröße (1/90*30) * Reference: §240 SGB V Abs. 4 */ -const mindestanteilBezugsgroeßeBeitragspflichtigeEinnahmeSelbst: Float { +public const mindestanteilBezugsgroeßeBeitragspflichtigeEinnahmeSelbst: Float { from 1990-01-01 { scalar: 0.33333333 } @@ -1035,7 +1035,7 @@ const mindestanteilBezugsgroeßeBeitragspflichtigeEinnahmeSelbst: Float { * Gleitzone (Midijob Grenze) und Minijob Grenze (bis 1999 unterschiedliche Grenzen) * Reference: Midijob § 20 (2) SGB IV, Minijob § 8 (1) Nr. 1 SGB IV */ -const geringfuegigeEinkommensgrenzenMonatlich: Dict> { +public const geringfuegigeEinkommensgrenzenMonatlich: Dict> { from 1984-01-01 { minijob: { west: 199 @@ -1203,7 +1203,7 @@ const geringfuegigeEinkommensgrenzenMonatlich: Dict { +public const pauschalabgabenGeringfuegigeBeschaeftigung: Dict { from 1984-01-01 { ges_krankenv: 0 ges_rentenv: 0 @@ -1259,7 +1259,7 @@ const pauschalabgabenGeringfuegigeBeschaeftigung: Dict { * entrichten. * Reference: § 55 Abs. 3 SGB XI, KiBG Art. 1 */ -const mindestalterBeitragszuschlagKinderlose: Int { +public const mindestalterBeitragszuschlagKinderlose: Int { from 2005-01-01 = 23 } @@ -1267,7 +1267,7 @@ const mindestalterBeitragszuschlagKinderlose: Int { * Allgemeiner gesetzlicher Mindestlohn pro Stunde * Reference: §1 (2) Mindestlohngesetz */ -const mindestlohn: Float { +public const mindestlohn: Float { from 2015-01-01 = 8.5 from 2017-01-01 = 8.84 from 2019-01-01 = 9.19 diff --git a/src/resources/builtins/parameters/unterhalt.ttsl b/src/resources/builtins/parameters/unterhalt.ttsl index 5be219d5..911e5cb9 100644 --- a/src/resources/builtins/parameters/unterhalt.ttsl +++ b/src/resources/builtins/parameters/unterhalt.ttsl @@ -5,7 +5,7 @@ package unterhalt * § 1612a BGB, § 1 Mindesunterhaltsverordnung. Mindestunterhalt für Kinder in * Abhängigkeit des Alters (unter 6, unter 12, bis 17 Jahre) */ -const mindestunterhalt: Dict { +public const mindestunterhalt: Dict { # Reference: V. v. 03.12.2015 BGBl. I S. 2188. from 2016-01-01 = { 6: 335, @@ -78,7 +78,7 @@ const mindestunterhalt: Dict { * Elternteil das hälftige Kindergeld bei der Unterhaltsberechnung in Abzug bringen. * Reference: § 1612b BGB */ -const abzugsrateKindergeld: Dict { +public const abzugsrateKindergeld: Dict { from 2008-01-01 = { kind: 0.5, erwachsener: 1 diff --git a/src/resources/builtins/parameters/unterhaltvorschuss.ttsl b/src/resources/builtins/parameters/unterhaltvorschuss.ttsl index e6d91aab..1b014ea4 100644 --- a/src/resources/builtins/parameters/unterhaltvorschuss.ttsl +++ b/src/resources/builtins/parameters/unterhaltvorschuss.ttsl @@ -5,7 +5,7 @@ package unterhaltvorschuss * `altersgrenze_mindesteinkommen` Jahren zu erhalten. * Reference: § 1 (1a) Nr. 2 Unterhaltsvorschussgesetz */ -const mindesteinkommen: Int = { +public const mindesteinkommen: Int = { # Reference: Art. 23 G. v. 14.08.2017 BGBl. I S. 3122. from 2017-01-01 = 600; } @@ -15,7 +15,7 @@ const mindesteinkommen: Int = { * `mindesteinkommen` bezogen werden kann. * Reference: § 1 (1a) Nr. 2 Unterhaltsvorschussgesetz */ -const altersgrenzeMindesteinkommen: Int = { +public const altersgrenzeMindesteinkommen: Int = { # Reference: Art. 23 G. v. 14.08.2017 BGBl. I S. 3122. from 2017-01-01 = 12; } @@ -28,7 +28,7 @@ const altersgrenzeMindesteinkommen: Int = { * bekommen, wenn das Elternteil ein Mindesteinkommen hat. * Reference: § 1 Abs. 1, 1a UhVorschG */ -const altersgrenzen: Dict = { +public const altersgrenzen: Dict = { # Reference: § 1 Abs. 1, 1a UhVorschG from 2017-01-01 = { 1: 6, diff --git a/src/resources/builtins/parameters/wohngeld.ttsl b/src/resources/builtins/parameters/wohngeld.ttsl index 920b413e..925932cd 100644 --- a/src/resources/builtins/parameters/wohngeld.ttsl +++ b/src/resources/builtins/parameters/wohngeld.ttsl @@ -4,7 +4,7 @@ package wohngeld * Faktor am Anfang der Wohngeldformel * Anlage 2 WoGG zu §19 Abs. 2 WoGG */ -const faktorBerechnungsformel: Float { +public const faktorBerechnungsformel: Float { from 1984-01-01 = 1 # Reference: Art. 1 G. v. 24.09 2008 BGBl. I S. 1856 @@ -20,7 +20,7 @@ const faktorBerechnungsformel: Float { * Wohngeldverordnung (WoGV). * The keys from 1 to 12 below refer to the household size. */ -const koeffizientenBerechnungsformel: Dict> { +public const koeffizientenBerechnungsformel: Dict> { # Parameter aus Regressionsanalyse der Wohngeldtabellen from 1984-01-01 = { 1: { @@ -604,7 +604,7 @@ const koeffizientenBerechnungsformel: Dict> { * der auf das Wohngeld für einen Haushalt mit 12 Personen angerechnet wird. * Reference: §19 Abs. 3 WoGG */ -const bonusSehrGrosseHaushalte: Dict { +public const bonusSehrGrosseHaushalte: Dict { # Reference: Art. 5 G. v. 22.12.1999 BGBl. I S. 2671 from 2001-01-01 = { max_anz_personen_normale_berechnung: 12, @@ -643,7 +643,7 @@ const bonusSehrGrosseHaushalte: Dict { * Kriterien sind - entrichtete Steuern - entrichtete GKV- und GPV-Beiträge - * entrichtete GRV-Beiträge */ -const abzugStufen: Dict { +public const abzugStufen: Dict { from 1984-01-01 = { 0: 0.06, 1: 0.125, @@ -673,7 +673,7 @@ const abzugStufen: Dict { * Minimalwert für Parameter M * WoGG - Anlage 3 (bis 2019 Anlage 2) (zu § 19 Abs. 2) */ -const minMiete: Dict { +public const minMiete: Dict { from 1984-01-01 = { 1: 0, 2: 0, @@ -756,7 +756,7 @@ const minMiete: Dict { * Minimalwert für Parameter Y * WoGG - Anlage 3 (bis 2019 Anlage 2) (zu § 19 Abs. 2) */ -const minEink: Dict { +public const minEink: Dict { from 1984-01-01 = { 1: 0, 2: 0, @@ -855,7 +855,7 @@ const minEink: Dict { * Monatlicher Freibetrag für Alleinerziehende und arbeitende Kinder * § 17 (4/5) WoGG */ -const freibetragKinder: Dict { +public const freibetragKinder: Dict { from 1984-01-01 = { alleinerz: 51, arbeitendes_kind: 0 @@ -888,7 +888,7 @@ const freibetragKinder: Dict { * vorliegen. Dies ist aktuell nicht implementiert. § 17 Nr. 1 WoGG. (früher § 17 (2) * WoGG) */ -const freibetragBehinderung: Dict | Int { +public const freibetragBehinderung: Dict | Int { from 1984-01-01 = { 0: 0, 1: 0, @@ -928,7 +928,7 @@ const freibetragBehinderung: Dict | Int { * Reference: § 17 Abs. 1 WoGG * in percent */ -const behinderungsgrad: Dict { +public const behinderungsgrad: Dict { from 1984-01-01 = { 1: 0, 2: 80 @@ -942,7 +942,7 @@ const behinderungsgrad: Dict { * Die Werte sind nach Anzahl Personen - maximales Baujahr des Hauses (vor 2009) - * Mietstufe geordnet. Alle Werte in vollen Euro. */ -const maxMiete: Dict>> { +public const maxMiete: Dict>> { # Reference: Art. 1 G. v. 04.08.1980 BGBl I S. 1159. # Bis 1985 nur drei Mietstufen, streng abhängig von der Größe der Gemeinde. Es wird "Wohnung mit Sammelheizung und mit Bad oder Duschraum" angenommen. from 1981-01-01 = { @@ -2233,7 +2233,7 @@ const maxMiete: Dict>> { * Wohngeld sein kann. Die genauen Werte regelt die Verwaltungsvorschrift vom April * 2009. Vorher war hohes Vermögen laut WoGG kein Ausschlussgrund. */ -const vermoegensgrundfreibetrag: Float { +public const vermoegensgrundfreibetrag: Float { # No wealth threshold in place. from 1970-01-01 = inf @@ -2246,7 +2246,7 @@ const vermoegensgrundfreibetrag: Float { * Vermögensfreibetrag für jedes weitere Haushaltsmitglied * Wohngeld-Verwaltungsvorschift 21.37 */ -const vermoegensfreibetragPerson: Float { +public const vermoegensfreibetragPerson: Float { # No wealth threshold in place from 1970-01-01 = inf @@ -2262,7 +2262,7 @@ const vermoegensfreibetragPerson: Float { * Reference: §12 (6) WoGG, Art. 1 G. v. 15.05.2020, BGBl I S. 1015. * per month */ -const heizkostenentlastung: Dict { +public const heizkostenentlastung: Dict { from 2021-01-01 { 1: 14.4, 2: 18.6, @@ -2280,7 +2280,7 @@ const heizkostenentlastung: Dict { * Reference: Art. 1 G. v. 08.12.2022 BGBl. I Nr. 48 S. 2160 * per month */ -const dauerhafteHeizkostenkomponente: Dict { +public const dauerhafteHeizkostenkomponente: Dict { from 2023-01-01 { 1: 96, 2: 124, @@ -2298,7 +2298,7 @@ const dauerhafteHeizkostenkomponente: Dict { * Reference: Art. 1 G. v. 08.12.2022 BGBl. I Nr. 48 S. 2160 * per month */ -const klimakomponente: Dict { +public const klimakomponente: Dict { from 2023-01-01 = { 1: 19.20, 2: 24.80, From e1326f0c5b55e431f077e0a2cb08e9f9b70265a3 Mon Sep 17 00:00:00 2001 From: alex-senger Date: Sat, 29 Jun 2024 11:52:16 +0200 Subject: [PATCH 096/183] fix: replace '|' with 'or' --- .../builtins/parameters/arbeitslosengeld2.ttsl | 2 +- .../builtins/parameters/einkommenssteuerAbzuege.ttsl | 4 ++-- .../builtins/parameters/gesetzlicheRente.ttsl | 4 ++-- .../parameters/sozialversicherungsbeitrag.ttsl | 4 ++-- src/resources/builtins/parameters/wohngeld.ttsl | 10 +++++----- 5 files changed, 12 insertions(+), 12 deletions(-) diff --git a/src/resources/builtins/parameters/arbeitslosengeld2.ttsl b/src/resources/builtins/parameters/arbeitslosengeld2.ttsl index 6c39910b..df634602 100644 --- a/src/resources/builtins/parameters/arbeitslosengeld2.ttsl +++ b/src/resources/builtins/parameters/arbeitslosengeld2.ttsl @@ -136,7 +136,7 @@ public const anrechnungsfreieEinkommensanteileFallsKinder: Dict { +public const regelsatz: Int or Dict { from 2005-01-01 = { scalar: 338, reference: "Artikel 1 G. v. 24.12.2003 BGBl. I S. 2954.", diff --git a/src/resources/builtins/parameters/einkommenssteuerAbzuege.ttsl b/src/resources/builtins/parameters/einkommenssteuerAbzuege.ttsl index 40e81ce6..1aa78665 100644 --- a/src/resources/builtins/parameters/einkommenssteuerAbzuege.ttsl +++ b/src/resources/builtins/parameters/einkommenssteuerAbzuege.ttsl @@ -238,7 +238,7 @@ public const vorsorge2004Grundhoechstbetrag: Int { * haben, maximal den gleichen Altersentlastungsbetrag. Ab 2005 hängt dieser Betrag, * den diese Steuerpflichtigen erhalten, vom Geburtsjahr ab. */ -public const altersentlastungsbetragMax: Int | Dict { +public const altersentlastungsbetragMax: Int or Dict { from 1984-01-01 = 1534 from 1989-01-01 = 1902 from 2002-01-01 = 1908 @@ -291,7 +291,7 @@ public const altersentlastungsbetragMax: Int | Dict { * haben, die gleiche Altersentlastungsquote abgezogen. Ab 2005 hängt diese Quote, * den diese Steuerpflichtigen erhalten, vom Geburtsjahr ab. */ -public const altersentlastungQuote: Float | Dict { +public const altersentlastungQuote: Float or Dict { from 1984-01-01 = 0.4 # Reference: Artikel 1 G. v. 05.07.2004 BGBl. I S. 1427. diff --git a/src/resources/builtins/parameters/gesetzlicheRente.ttsl b/src/resources/builtins/parameters/gesetzlicheRente.ttsl index 68ab6e82..2946b23b 100644 --- a/src/resources/builtins/parameters/gesetzlicheRente.ttsl +++ b/src/resources/builtins/parameters/gesetzlicheRente.ttsl @@ -696,7 +696,7 @@ public const renteFrauenPflichtbeitrag: Int { * bezogen werden kann. * Reference: § 237 SGB VI */ -public const altersgrenzeArbeitslosigkeitAbschlagsfrei: Float | Dict> { +public const altersgrenzeArbeitslosigkeitAbschlagsfrei: Float or Dict> { from 1980-01-01 = { 0: { scalar: 60.0, @@ -1305,7 +1305,7 @@ public const altersgrenzeArbeitslosigkeitAbschlagsfrei: Float | Dict>{ +public const altersgrenzeArbeitslosigkeitVorzeitig: Float or Dict>{ from 1980-01-01 = 60.0 # Increase of early retirement age from 60 to 62 for birth cohort 1949-1952. diff --git a/src/resources/builtins/parameters/sozialversicherungsbeitrag.ttsl b/src/resources/builtins/parameters/sozialversicherungsbeitrag.ttsl index 9fdcec67..cdbb81c9 100644 --- a/src/resources/builtins/parameters/sozialversicherungsbeitrag.ttsl +++ b/src/resources/builtins/parameters/sozialversicherungsbeitrag.ttsl @@ -24,7 +24,7 @@ package sozialversicherungsbeitrag * * access_different_date: jahresanfang */ -public const beitragssatz: Dict> { +public const beitragssatz: Dict> { from 1984-01-01 { gesetzlicheKrankenversicherung: { mean_allgemein: 0.134 @@ -1035,7 +1035,7 @@ public const mindestanteilBezugsgroeßeBeitragspflichtigeEinnahmeSelbst: Float { * Gleitzone (Midijob Grenze) und Minijob Grenze (bis 1999 unterschiedliche Grenzen) * Reference: Midijob § 20 (2) SGB IV, Minijob § 8 (1) Nr. 1 SGB IV */ -public const geringfuegigeEinkommensgrenzenMonatlich: Dict> { +public const geringfuegigeEinkommensgrenzenMonatlich: Dict> { from 1984-01-01 { minijob: { west: 199 diff --git a/src/resources/builtins/parameters/wohngeld.ttsl b/src/resources/builtins/parameters/wohngeld.ttsl index 925932cd..7c4f843e 100644 --- a/src/resources/builtins/parameters/wohngeld.ttsl +++ b/src/resources/builtins/parameters/wohngeld.ttsl @@ -888,7 +888,7 @@ public const freibetragKinder: Dict { * vorliegen. Dies ist aktuell nicht implementiert. § 17 Nr. 1 WoGG. (früher § 17 (2) * WoGG) */ -public const freibetragBehinderung: Dict | Int { +public const freibetragBehinderung: Dict or Int { from 1984-01-01 = { 0: 0, 1: 0, @@ -942,7 +942,7 @@ public const behinderungsgrad: Dict { * Die Werte sind nach Anzahl Personen - maximales Baujahr des Hauses (vor 2009) - * Mietstufe geordnet. Alle Werte in vollen Euro. */ -public const maxMiete: Dict>> { +public const maxMiete: Dict>> { # Reference: Art. 1 G. v. 04.08.1980 BGBl I S. 1159. # Bis 1985 nur drei Mietstufen, streng abhängig von der Größe der Gemeinde. Es wird "Wohnung mit Sammelheizung und mit Bad oder Duschraum" angenommen. from 1981-01-01 = { @@ -2262,7 +2262,7 @@ public const vermoegensfreibetragPerson: Float { * Reference: §12 (6) WoGG, Art. 1 G. v. 15.05.2020, BGBl I S. 1015. * per month */ -public const heizkostenentlastung: Dict { +public const heizkostenentlastung: Dict { from 2021-01-01 { 1: 14.4, 2: 18.6, @@ -2280,7 +2280,7 @@ public const heizkostenentlastung: Dict { * Reference: Art. 1 G. v. 08.12.2022 BGBl. I Nr. 48 S. 2160 * per month */ -public const dauerhafteHeizkostenkomponente: Dict { +public const dauerhafteHeizkostenkomponente: Dict { from 2023-01-01 { 1: 96, 2: 124, @@ -2298,7 +2298,7 @@ public const dauerhafteHeizkostenkomponente: Dict { * Reference: Art. 1 G. v. 08.12.2022 BGBl. I Nr. 48 S. 2160 * per month */ -public const klimakomponente: Dict { +public const klimakomponente: Dict { from 2023-01-01 = { 1: 19.20, 2: 24.80, From fa252f9cb2f2d4bb99079dc7d863c1d021a71195 Mon Sep 17 00:00:00 2001 From: alex-senger Date: Sat, 29 Jun 2024 15:38:33 +0200 Subject: [PATCH 097/183] feat: add arbeitslosenversicherung methods --- .../arbeitslosenversicherung.ttsl" | 127 ++++++++++++++++++ 1 file changed, 127 insertions(+) create mode 100644 "src/resources/builtins/sozialversicherungsBeitr\303\244ge/arbeitslosenversicherung.ttsl" diff --git "a/src/resources/builtins/sozialversicherungsBeitr\303\244ge/arbeitslosenversicherung.ttsl" "b/src/resources/builtins/sozialversicherungsBeitr\303\244ge/arbeitslosenversicherung.ttsl" new file mode 100644 index 00000000..717ebabf --- /dev/null +++ "b/src/resources/builtins/sozialversicherungsBeitr\303\244ge/arbeitslosenversicherung.ttsl" @@ -0,0 +1,127 @@ +package arbeitslosenversicherung + +from sozialversichernugsbeitrag import beitragssatz + +/** + * Sum of employee's social insurance contributions. + */ +public function sozialversicherungsBeitrag(): Float per month { + var pv = gesetzlichePflegeVersicherungsBeitrag() per month; + var kv = gesetzlicheKrankenVersicherungsBeitrag() per month; + var rv = gesetzlicheRentenVersicherungsBeitrag() per month; + var av = arbeitslosenversicherungsBeitrag() per month; + + return pv + kv + rv + av; +} + +/** + * Sum of employer's social insurance contributions. + */ +public function sozialversicherungsBeitragArbeitgeber(): Float per month { + var pv = gesetzlicherPflegeVersicherungsBeitragArbeitgeber() per month; + var kv = gesetzlicherKrankenVersicherungsBeitragArbeitgeber() per month; + var rv = gesetzlicherRentenVersicherungsBeitragArbeitgeber() per month; + var av = arbeitslosenversicherungsBeitragArbeitgeber() per month; + + return pv + kv + rv + av; +} + +/** + * Sum of employer's and employee's social insurance contributions. + */ +private function sozialversicherungsBeitragArbeitnehmerArbeitgeber(): Float per month { + return sozialversicherungsBeitrag() per month + sozialversicherungsBeitragArbeitgeber() per month; +} + +/** + * Employee's unemployment insurance contribution. + */ +public function beitrag(): Float per month { + to 2003-03-31 { + if (geringfügigBeschäftigt()) { + return 0; + } else { + return gesetzlicheRentenversicherungBetragBruttolohn() per month * beitragssatz[arbeitslosenversicherung]; + } + } + from 2003-04-01 { + if (geringfügigBeschäftigt()) { + return 0; + } + + if (inGleitzone()) { + return arbeitslosenversicherungBeitragArbeitnehmer() per month; + } + + return gesetzlicheRentenversicherungBetragBruttolohn() per month * beitragssatz[arbeitslosenversicherung]; + } +} + +/** + * Employer's unemployment insurance contribution until March 2003. + */ +public function beitragArbeitgeber(): Float per month { + to 2003-03-31 { + if (geringfügigBeschäftigt()) { + return 0; + } else { + return gesetzlicheRentenversicherungBetragBruttolohn() per month * beitragssatz[arbeitslosenversicherung]; + } + } + + from 2003-04-01 { + if (geringfügigBeschäftigt()) { + return 0; + } + + if (inGleitzone()) { + return arbeitslosenversicherungBeitragMidijobArbeitgeber() per month; + } + + return arbeitslosenversicherungRegulärBeschäftigt() per month; + } +} + +/** + * Sum of employee's and employer's unemployment insurance contribution + * for midijobs. + */ +private function midijobSummeArbeitgeberArbeitnehmer(): Float per month { + from 2003-04-01 { + return midijobBemessungsentgeld() per month * 2 * beitragssatz[arbeitslosenversicherung]; + } +} + +/** + * Employers' unemployment insurance contribution for Midijobs until September + * 2022. + */ +private function midijobArbeitgeberAnteilBruttolohn(bruttolohn per month): Float per month { + from 2003-04-01 to 2022-09-30 { + bruttolohn per month * beitragssatz[arbeitslosenversicherung]; + } +} + +/** + * Employer's unemployment insurance contribution since October 2022. + */ +private function midijobArbeitgeber(): Float per month { + from 2022-10-01 { + return midijobSummeArbeitgeberArbeitnehmer() per month - midijobArbeitnehmer() per month; + } +} + +/** + * Employees' unemployment insurance contribution for Midijobs until September + * 2022. + */ +private function midijobArbeitnehmer(): Float per month { + from 2003-04-01 to 2022-09-30 { + return midijobSummeArbeitgeberArbeitnehmer() per month - midijobArbeitgeber() per month; + } + + from 2022-10-01 { + # TODO + return _midijob_beitragspfl_einnahme_arbeitn_m * beitragssatz[arbeitslosenversicherung]; + } +} From 40d009d36c0301711a63d65500f3181731a8d765 Mon Sep 17 00:00:00 2001 From: alex-senger Date: Sat, 29 Jun 2024 17:13:45 +0200 Subject: [PATCH 098/183] feat: add beitragsbemessungsgrenzen --- .../beitragsbemessungsgrenzen.ttsl" | 29 +++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100644 "src/resources/builtins/sozialversicherungsBeitr\303\244ge/beitragsbemessungsgrenzen.ttsl" diff --git "a/src/resources/builtins/sozialversicherungsBeitr\303\244ge/beitragsbemessungsgrenzen.ttsl" "b/src/resources/builtins/sozialversicherungsBeitr\303\244ge/beitragsbemessungsgrenzen.ttsl" new file mode 100644 index 00000000..2e643f44 --- /dev/null +++ "b/src/resources/builtins/sozialversicherungsBeitr\303\244ge/beitragsbemessungsgrenzen.ttsl" @@ -0,0 +1,29 @@ +package beitragsbemessungsgrenzen + +from sozialversicherungsbeitrag import beitragsbemessungsgrenze, monatlicheBezugsgroeße + +public function gesetzlicheRentenversicherung(): Float per month { + params = beitragsbemessungsgrenze[ges_rentenv]; + if wohnort_ost() { + return params[ost]; + } else { + return params[west]; + } +} + +public function gesetzlicheKrankenversicherung(): Float per month { + params = beitragsbemessungsgrenze[ges_krankenv]; + if wohnort_ost() { + return params[ost]; + } else { + return params[west]; + } +} + +public function gesetzlicheKrankenversicherungBezugsgröße(): Float per month { + if wohnort_ost() { + return monatlicheBezugsgroeße[ost]; + } else { + return monatlicheBezugsgroeße[west]; + } +} \ No newline at end of file From 7a87562acbdc3a6d0ce6351260699cceec620229 Mon Sep 17 00:00:00 2001 From: alex-senger Date: Sat, 29 Jun 2024 17:55:52 +0200 Subject: [PATCH 099/183] feat: add einkommensgrenzen methods --- .../einkommensgrenzen.ttsl" | 229 ++++++++++++++++++ 1 file changed, 229 insertions(+) create mode 100644 "src/resources/builtins/sozialversicherungsBeitr\303\244ge/einkommensgrenzen.ttsl" diff --git "a/src/resources/builtins/sozialversicherungsBeitr\303\244ge/einkommensgrenzen.ttsl" "b/src/resources/builtins/sozialversicherungsBeitr\303\244ge/einkommensgrenzen.ttsl" new file mode 100644 index 00000000..1928f08b --- /dev/null +++ "b/src/resources/builtins/sozialversicherungsBeitr\303\244ge/einkommensgrenzen.ttsl" @@ -0,0 +1,229 @@ +package einkomensgrenzen + +from sozialversicherungsbeitrag import geringfuegigeEinkommensgrenzenMonatlich, mindestlohn, geringfuegigeEinkommensfaktor, geringfuegigeEinkommensdivisor, beitragssatz + +/** + * Select the income threshold depending on place of living. + */ +public function minijobGrenze(): Float per month { + to 1999-12-31 { + var west = geringfuegigeEinkommensgrenzenMonatlich[minijob][west] + var ost = geringfuegigeEinkommensgrenzenMonatlich[minijob][ost] + if wohnort_ost() { + return ost + } else { + return west + } + } + + from 2000-01-01 to 2022-09-30 { + return geringfuegigeEinkommensgrenzenMonatlich[minijob] + } + + /** + * Obtains marginal job threshold since 10/2022. Since then, it is calculated from + * the statutory minimum wage. + */ + from 2022-10-01 { + return mindestlohn * geringfuegigeEinkommensfaktor / geringfuegigeEinkommensdivisor + } +} + +/** + * Check if individual earns less than marginal employment threshold. + * Marginal employed pay no social insurance contributions. + * Legal reference: § 8 Abs. 1 Satz 1 and 2 SGB IV + */ +public function geringügigBeschäftigt(bruttolohn per month): Boolean { + return bruttolohn per month <= minijobGrenze() +} + +/** + * Check if individual's income is in midi-job range. + * Employed people with their wage in the range of gleitzone pay reduced social + * insurance contributions. + * Legal reference: § 20 Abs. 2 SGB IV + */ +public function inGleitzone(bruttolohn per month): Boolean { + from 2003-04-01 { + return (bruttolohn per month <= geringfuegigeEinkommensgrenzenMonatlich[midijob]) and (not geringügigBeschäftigt(bruttolohn per month)); + } +} + +public function midijobFaktorF(): Float { + /** + * Midijob Faktor F until December 2004. + * Legal reference: § 163 Abs. 10 SGB VI + */ + from 2003-04-01 to 2004-12-31 { + # First calculate the factor F from the formula in § 163 (10) SGB VI + # Therefore sum the contributions which are the same for employee and employer + var allg_sozialv_beitr = ( + beitragssatz[gesetzlicheRentenversicherung] + + beitragssatz[arbeitslosenversicherung] + ); + + allg_sozialv_beitr += beitragssatz[ges_pflegev]; + + # Then calculate specific shares + var an_anteil = allg_sozialv_beitr + gesetzlicheKrankenversicherungBeitragssatzJahresanfang(); + var ag_anteil = allg_sozialv_beitr + gesetzlicheKrankenversicherungBeitragssatzArbeitgeberJahresanfang(); + + # Sum over the shares which are specific for midijobs. + var pausch_mini = ( + pauschalabgabenGeringfuegigeBeschaeftigung[ges_krankenv] + + pauschalabgabenGeringfuegigeBeschaeftigung[ges_rentenv] + + pauschalabgabenGeringfuegigeBeschaeftigung[st] + ); + + # Now calculate final factor + return pausch_mini / (an_anteil + ag_anteil) + } + + /** + * Midijob Faktor F between 2005 and September 2025. + * Legal reference: § 163 Abs. 10 SGB VI + */ + from 2005-01-01 { + # First calculate the factor F from the formula in § 163 (10) SGB VI + # Therefore sum the contributions which are the same for employee and employer + var allg_sozialv_beitr = ( + beitragssatz[gesetzlicheRentenversicherung] + + beitragssatz[arbeitslosenversicherung] + ); + + allg_sozialv_beitr += beitragssatz[gesetzlichePflegeversicherung][standard] + + # Then calculate specific shares + var an_anteil = allg_sozialv_beitr + gesetzlicheKrankenversicherungBeitragssatzJahresanfang(); + var ag_anteil = allg_sozialv_beitr + gesetzlicheKrankenversicherungBeitragssatzArbeitgeberJahresanfang(); + + # Sum over the shares which are specific for midijobs. + var pausch_mini = ( + pauschalabgabenGeringfuegigeBeschaeftigung[ges_krankenv] + + pauschalabgabenGeringfuegigeBeschaeftigung[ges_rentenv] + + pauschalabgabenGeringfuegigeBeschaeftigung[st] + ); + + # Now calculate final factor + return pausch_mini / (an_anteil + ag_anteil) + } + + from 2022-10-01 { + # Calculate the Gesamtsozialversicherungsbeitragssatz by summing social + # insurance contributions for employer and employee and + # adding the mean Zusatzbeitrag + # First calculate the factor F from the formula in § 163 (10) SGB VI + # Therefore sum the contributions which are the same for employee and employer + var allg_sozialv_beitr = ( + beitragssatz[gesetzlicheRentenversicherung] + + beitragssatz[gesetzlichePflegeversicherung][standard] + + beitragssatz[arbeitslosenversicherung] + ); + + # Then calculate specific shares + var an_anteil = allg_sozialv_beitr + gesetzlicheKrankenversicherungBeitragssatzJahresanfang(); + var ag_anteil = allg_sozialv_beitr + gesetzlicheKrankenversicherungBeitragssatzArbeitgeberJahresanfang(); + + # Sum over the shares which are specific for midijobs. + # New formula only inludes the lump-sum contributions to health care + # and pension insurance + var pausch_mini = ( + pauschalabgabenGeringfuegigeBeschaeftigung[ges_krankenv] + pauschalabgabenGeringfuegigeBeschaeftigung[ges_rentenv] + ) + + # Now calculate final factor f + return pausch_mini / (an_anteil + ag_anteil) + } +} + +/** + * Income subject to social insurance contributions for midijob until September + * 2022. + * Bemessungsgeld (Gleitzonenentgelt) is the reference income for midijobs subject to + * social insurance contribution. + * Legal reference: § 163 Abs. 10 SGB VI + */ +public function midijobBemessungsgeld(bruttolohn per month): Float per month { + from 2003-04-01 { + # Now use the factor to calculate the overall bemessungsentgelt + var minijob_anteil = midijobFaktorF() * minijobGrenze() + var lohn_über_mini = bruttolohn per month - minijobGrenze() + var gewichtete_midijob_rate = ( + geringfuegigeEinkommensgrenzenMonatlich[midijob] + / ( + geringfuegigeEinkommensgrenzenMonatlich[midijob] + - minijobGrenze() + ) + ) - ( + minijobGrenze() + / ( + geringfuegigeEinkommensgrenzenMonatlich[midijob] + - minijobGrenze() + ) + * midijobFaktorF() + ) + + return minijob_anteil + lohn_über_mini * gewichtete_midijob_rate + } + + /** + * Total income subject to social insurance contributions for employers a and + * employees for midijob since October 2022. In the law, the considered income is + * referred to as "beitragspflichtige Einnahme". + * Beitragspflichtige Einnahme is the reference income for midijobs subject + * to employer and employee social insurance contribution. + * Legal reference: Changes in § 20 SGB IV from 01.10.2022 + */ + from 2022-10-01 { + var midijob_grenze = geringfuegigeEinkommensgrenzenMonatlich[midijob] + + var quotient1 = (midijob_grenze) / (midijob_grenze - minijobGrenze()) + var quotient2 = (minijobGrenze()) / (midijob_grenze - minijobGrenze()) + var einkommen_diff = bruttolohn per month - minijobGrenze() + + var faktor1 = midijobFaktorF * minijobGrenze() + var faktor2 = (quotient1 - quotient2 * midijobFaktorF) * einkommen_diff + return faktor1 + faktor2 + } +} + +/** + * Income subject to employee social insurance contributions for midijob since + * October 2022. + * Gesonderte Beitragspflichtige Einnahme is the reference income for midijobs subject + * to employee social insurance contribution. + * Legal reference: Changes in § 20 SGB IV from 01.10.2022 + */ +private function midijobBeitragspflichtigeEinnahmeArbeitnehmer(bruttolohn per month): Float per month { + var midijob_grenze = geringfuegigeEinkommensgrenzenMonatlich[midijob] + + var quotient = midijob_grenze / (midijob_grenze - minijobGrenze()) + var einkommen_diff = bruttolohn per month - minijobGrenze() + + return quotient * einkommen_diff +} + + +public function regulärBeschäftigt(bruttolohn per month): Boolean { + /** + * Regular employment check until March 2003. + * Employees earning more than the minijob threshold, are subject to all ordinary + * income and social insurance contribution regulations. In gettsim we call these + * regular employed. + */ + to 2003-03-31 { + return bruttolohn per month >= minijobGrenze() + } + + /** + * Regular employment check since April 2003. + * Employees earning more than the midijob threshold, are subject to all ordinary + * income and social insurance contribution regulations. In gettsim we call these + * regular employed. + */ + from 2003-04-01 { + return bruttolohn per month >= geringfuegigeEinkommensgrenzenMonatlich[midijob] + } +} From 83d08932c5f3fe5b1ad4317896510ec77bb6c748 Mon Sep 17 00:00:00 2001 From: alex-senger Date: Mon, 1 Jul 2024 13:18:32 +0200 Subject: [PATCH 100/183] fix: replace 'const' with 'constant' --- .../parameters/abgeltungssteuersatz.ttsl | 2 +- .../builtins/parameters/arbeitslosengeld.ttsl | 12 ++-- .../parameters/arbeitslosengeld2.ttsl | 28 ++++----- .../builtins/parameters/einkommenssteuer.ttsl | 4 +- .../parameters/einkommenssteuerAbzuege.ttsl | 46 +++++++------- .../builtins/parameters/elterngeld.ttsl | 28 ++++----- .../parameters/erwerbsminderungsrente.ttsl | 14 ++--- .../builtins/parameters/erziehungsgeld.ttsl | 16 ++--- .../builtins/parameters/gesetzlicheRente.ttsl | 60 +++++++++---------- .../parameters/grundsicherungImAlter.ttsl | 12 ++-- .../builtins/parameters/kindergeld.ttsl | 10 ++-- .../builtins/parameters/kinderzuschlag.ttsl | 14 ++--- .../builtins/parameters/lohnsteuer.ttsl | 2 +- .../parameters/solidaritaetszuschlag.ttsl | 2 +- .../sozialversicherungsbeitrag.ttsl | 20 +++---- .../builtins/parameters/unterhalt.ttsl | 4 +- .../parameters/unterhaltvorschuss.ttsl | 6 +- .../builtins/parameters/wohngeld.ttsl | 30 +++++----- 18 files changed, 155 insertions(+), 155 deletions(-) diff --git a/src/resources/builtins/parameters/abgeltungssteuersatz.ttsl b/src/resources/builtins/parameters/abgeltungssteuersatz.ttsl index 24b5ffdb..2ee30a03 100644 --- a/src/resources/builtins/parameters/abgeltungssteuersatz.ttsl +++ b/src/resources/builtins/parameters/abgeltungssteuersatz.ttsl @@ -6,7 +6,7 @@ package abgeltungssteuersatz * Constant for the Capital Income Tax Rate as defined in §32d (1) EStG. * Reference: Art. 1 G. v. 14.08.2007 */ -public const abgeltungssteuersatz: Float { +public constant abgeltungssteuersatz: Float { from 1984-01-01 = 0.0; from 2009-01-01 = 0.25; } diff --git a/src/resources/builtins/parameters/arbeitslosengeld.ttsl b/src/resources/builtins/parameters/arbeitslosengeld.ttsl index b559bef4..f30528a4 100644 --- a/src/resources/builtins/parameters/arbeitslosengeld.ttsl +++ b/src/resources/builtins/parameters/arbeitslosengeld.ttsl @@ -6,7 +6,7 @@ package arbeitslosengeld * Income which is not deducted from unemployment benefit. * § 155 SGB III, vorher § 141 (1) S. 1 */ -public const arbeitslosenGeldFreibetrag: Int { +public constant arbeitslosenGeldFreibetrag: Int { # Art. 1 G. v. 21.07.1999 BGBl. I S. 1648 from 1999-08-01 = 161; @@ -19,7 +19,7 @@ public const arbeitslosenGeldFreibetrag: Int { * § 153 (1) Nr. 1 SGB III. Wird angewendet auf das Bemessungsentgelt. ACHTUNG! Beim * Elterngeld gibt es eine ähnliche Größe. */ -public const sozialVersicherungsPauschale: Float { +public constant sozialVersicherungsPauschale: Float { from 1984-01-01 = 0.1727; from 1985-01-01 = 0.1745; from 1986-01-01 = 0.1775; @@ -60,7 +60,7 @@ public const sozialVersicherungsPauschale: Float { * §149 Nr. 2 SGB III, vorher § 129 (2) SGB III. Höhe des Arbeitslosengeldes im * Verhältnis zum letzten Nettoentgelt bei Personen ohne Kinder im Sinne des EStG. */ -public const satzOhneKinder: Float { +public constant satzOhneKinder: Float { # Reference: Art. 1 G. v. 24.03.1997 BGBl. I S. 594 from 1998-08-01 = 0.6; } @@ -70,7 +70,7 @@ public const satzOhneKinder: Float { * §149 Nr. 1 SGB III, vorher §129 Nr. 1 SGB III. Höhe des Arbeitslosengeldes im * Verhältnis zum letzten Nettoentgelt bei Personen mit Kindern im Sinne des EStG */ -public const satzMitKindern: Float { +public constant satzMitKindern: Float { # Reference: Art. 1 G. v. 24.03.1997 BGBl. I S. 594 from 1998-08-01 = 0.67; } @@ -80,7 +80,7 @@ public const satzMitKindern: Float { * §138 (3) SGB III, früher auch §102 (2) AFG. Grenze, ab der nicht mehr * Arbeitslosigkeit unterstellt wird. */ -public const stundengrenze: Int { +public constant stundengrenze: Int { from 1969-07-01 = 20; # Reference: Art. 1 G. v. 20.12.1985 BGBl I S. 2484 from 1986-01-01 = 19; @@ -97,7 +97,7 @@ public const stundengrenze: Int { * Dauer des Anspruchs auf ALG 1 richtet sich nach Alter und wie viele Monate * eine Person versicherungsplichtig in den letzten 5 Jahren war. */ -public const anspruchsdauer: Dict { +public constant anspruchsdauer: Dict { from 1997-03-24 = { nach_alter: { 0: 12 diff --git a/src/resources/builtins/parameters/arbeitslosengeld2.ttsl b/src/resources/builtins/parameters/arbeitslosengeld2.ttsl index df634602..7c706b98 100644 --- a/src/resources/builtins/parameters/arbeitslosengeld2.ttsl +++ b/src/resources/builtins/parameters/arbeitslosengeld2.ttsl @@ -9,7 +9,7 @@ package arbeitslosengeld2 * § 11b (2) SGB II (neugefasst durch B. v. 13.05.2011 BGBl. I S. 850. Artikel 2 * G. v. 24.03.2011 BGBl. I S. 453). */ -public const anrechnungsfreieEinkommensanteile: Dict>> { +public constant anrechnungsfreieEinkommensanteile: Dict>> { # Reference: Artikel 1. G. v. 24.12.2003 BGBl. I S. 2954. from 2005-01-01 = { 0: { @@ -112,7 +112,7 @@ public const anrechnungsfreieEinkommensanteile: Dict>> { +public constant anrechnungsfreieEinkommensanteileFallsKinder: Dict>> { # Reference: Artikel 1 G. v. 14.08.2005 BGBl. I S. 2407. from 2005-10-01 = { 3: { @@ -136,7 +136,7 @@ public const anrechnungsfreieEinkommensanteileFallsKinder: Dict { +public constant regelsatz: Int or Dict { from 2005-01-01 = { scalar: 338, reference: "Artikel 1 G. v. 24.12.2003 BGBl. I S. 2954.", @@ -311,7 +311,7 @@ public const regelsatz: Int or Dict { * 2005-2010 der Regelsatz für weitere Haushaltsmitglieder wurden als Anteil * des Standardsatzes bestimmt. */ -public const anteilRegelsatz: Dict { +public constant anteilRegelsatz: Dict { # Reference: Artikel 1 G. v. 24.12.2003 BGBl. I S. 2954. from 2005-01-01 = { zwei_erwachsene: 0.9, @@ -343,7 +343,7 @@ public const anteilRegelsatz: Dict { * § 21 (3) Nr. 1 SGB II. * reference_period: Month */ -public const mehrbedarfAnteil: Dict { +public constant mehrbedarfAnteil: Dict { # Reference: G. v. 24.12.2003 BGBl. I S. 2954. from 2005-01-01 = { min_1_kind: 0.12, @@ -359,7 +359,7 @@ public const mehrbedarfAnteil: Dict { * mehr auf und ist nicht mehr relevant, * da alle betroffenen Personen zu alt für ALG 2 sind. */ -public const vermögensGrundfreibetragObergrenze: Dict { +public constant vermögensGrundfreibetragObergrenze: Dict { # Reference: Artikel 1 G. v. 23.12.2002 BGBl. I S. 4607. from 2005-01-01 = { 1947: 33800, @@ -400,7 +400,7 @@ public const vermögensGrundfreibetragObergrenze: Dict { * von einem Jahr. Während der Karenzzeit ist ein Vermögen von 40.000 Euro für die * erste Person einer Bedarfsgemeinschaft und 15.000 Euro für jede weitere erlaubt. */ -public const schonvermoegenBuergergeld: Dict { +public constant schonvermoegenBuergergeld: Dict { # Reference: G. v. 20.12.2022 BGBl. I S. 2328. (Bürgergeld-Gesetz) from 2023-01-01 = { während_karenzzeit: 40000, @@ -412,7 +412,7 @@ public const schonvermoegenBuergergeld: Dict { * Vermögensfreibetrag für Erstausstattung * § 12 (2) Satz 1 Nr. 4 SGB II. */ -public const vermoegensfreibetragAusstattung: Int { +public constant vermoegensfreibetragAusstattung: Int { # Reference: Artikel 1 G. v. 24.12.2003 BGBl. I S. 2954. from 2005-01-01 = 750; @@ -424,7 +424,7 @@ public const vermoegensfreibetragAusstattung: Int { * Vermögensgrundfreibetrag je Kind * § 12 (2) Satz 1 Nr. 1 SGB II. */ -public const vermoegensfreibetragKind: Int { +public constant vermoegensfreibetragKind: Int { # Reference: Artikel 1 G. v. 24.12.2003 BGBl. I S. 2954. from 2005-01-01 = 4100; @@ -439,7 +439,7 @@ public const vermoegensfreibetragKind: Int { * Altersgrenzen für Vermögensfreibetrag * Vermögensfreibetrag ändert sich nach Geburtsjahr */ -public const vermoegensfreibetragAlter: Dict { +public constant vermoegensfreibetragAlter: Dict { 2005-01-01: { 1: 1948, 2: 1958, @@ -460,7 +460,7 @@ public const vermoegensfreibetragAlter: Dict { * .2016 BGBl. I S. 1858 entfallen. Wie entfallen? * § 3 Alg II-V. Seit 01.01.2008 in § 6 Alg II-V. */ -public const abzugfaehigePauschale: Dict { +public constant abzugfaehigePauschale: Dict { # Reference: V. v. 20.10.2004 BGBl. I S. 2622 from 2005-01-01 = { werbung: 15.33, @@ -482,7 +482,7 @@ public const abzugfaehigePauschale: Dict { * § 22 SGB II * unit: Euro / Quadratmeter */ -public const maxMieteProQuadratMeter: Int { +public constant maxMieteProQuadratMeter: Int { from 1984-01-01 = 10 } @@ -491,7 +491,7 @@ public const maxMieteProQuadratMeter: Int { * Eine Mietwohnung darf für einen Single 45 Quadratmeter (+15 für jede weitere * Person) groß sein. */ -public const berechtigteWohnflaecheMiete: Dict { +public constant berechtigteWohnflaecheMiete: Dict { from 1984-01-01 = { single: 45, je_weitere_person: 15 @@ -506,7 +506,7 @@ public const berechtigteWohnflaecheMiete: Dict { * gestiegen und wird ab 5 Personen im Haushalt um 20 Quadratmeter pro Person * angehoben. */ -public const berechtigteWohnflaecheEigentum: Dict { +public constant berechtigteWohnflaecheEigentum: Dict { from 1984-01-01 = { 1: 80, 2: 80, diff --git a/src/resources/builtins/parameters/einkommenssteuer.ttsl b/src/resources/builtins/parameters/einkommenssteuer.ttsl index f5fb7c60..8100a6ce 100644 --- a/src/resources/builtins/parameters/einkommenssteuer.ttsl +++ b/src/resources/builtins/parameters/einkommenssteuer.ttsl @@ -9,7 +9,7 @@ package einkommenssteuer * des Progressionsfaktors berechnet. Einzelheiten sind im docstring der Funktion * add_progressionsfaktor beschrieben. */ -public const einkommenssteuerTarif: Dict> { +public constant einkommenssteuerTarif: Dict> { # TODO: klren wie das mit deviation_from aussieht @@ -325,7 +325,7 @@ public const einkommenssteuerTarif: Dict> { * Diese Funktion ist hier ab 2002 angegeben. Vor 2002 das Steuersystem ist nicht * implementiert. */ -public const renteErtragsanteil: Dict> { +public constant renteErtragsanteil: Dict> { from 2002-01-01 = { 0: { lower_threshold: -inf, diff --git a/src/resources/builtins/parameters/einkommenssteuerAbzuege.ttsl b/src/resources/builtins/parameters/einkommenssteuerAbzuege.ttsl index 1aa78665..c166b100 100644 --- a/src/resources/builtins/parameters/einkommenssteuerAbzuege.ttsl +++ b/src/resources/builtins/parameters/einkommenssteuerAbzuege.ttsl @@ -9,7 +9,7 @@ pacakge einkommenssteuerAbzuege * veranlagte Paare. §32 (6) EStG, seit 2000. * Pro Jahr */ -public const kinderFreibetrag: Dict { +public constant kinderFreibetrag: Dict { # Reference: Art. 1 G. v. 23.12.1982 BGBl. I S. 1857. from 1983-01-01 = { saechlichesExistenzminimum: 110 @@ -140,7 +140,7 @@ public const kinderFreibetrag: Dict { * Steuerpflichtigen. Wird verdoppelt für gemeinsam veranlagte Ehegatten. Der gesamte * Zeitverlauf wurde bereits 2005 festgelegt. */ -public const vorsorge2004Vorwegabzug: Int { +public constant vorsorge2004Vorwegabzug: Int { from 1985-01-01 = 1534 from 1989-01-01 = 2045 from 1993-01-01 = 3068 @@ -160,7 +160,7 @@ public const vorsorge2004Vorwegabzug: Int { * § 9a Nr. 1a) EStG * This is the minimum amount deducted from any employment income. */ -public const werbungskostenpauschbetrag: Int { +public constant werbungskostenpauschbetrag: Int { from 1975-01-01 = 288 from 1990-01-01 = 1044 from 2004-01-01 = 920 @@ -179,7 +179,7 @@ public const werbungskostenpauschbetrag: Int { * Sonderausgaben-Pauschbetrag * § 10c EStG */ -public const sonderausgabenpauschbetrag: Int { +public constant sonderausgabenpauschbetrag: Int { from 1984-01-01 = 138 # Reference: Art. 1 G. v. 25.07.1988, BGBl. I S. 1093 @@ -194,7 +194,7 @@ public const sonderausgabenpauschbetrag: Int { * § 20 (9) EStG. Früher § 20 (4) EStG. Wert für Singles. Wird verdoppelt für * gemeinsam veranlagte. seit 2009. vor 2008 Sparerfreibetrag. */ -public const sparerpauschbetrag: Int { +public constant sparerpauschbetrag: Int { from 1975-01-01 = 153 from 1990-01-01 = 307 from 1993-01-01 = 3068 @@ -217,7 +217,7 @@ public const sparerpauschbetrag: Int { * § 20 (9) EStG. Früher § 20 (4) EStG. Wert für Singles. Wird verdoppelt für * gemeinsam veranlagte. seit 2009. vor 2008 Sparerfreibetrag. */ -public const sparerWerbungskostenPauschbetrag: Int { +public constant sparerWerbungskostenPauschbetrag: Int { from 1975-01-01 = 51 from 2009-01-01 = 0 } @@ -226,7 +226,7 @@ public const sparerWerbungskostenPauschbetrag: Int { * Allgemeine Vorsorgepauschale Grundhöchstbetrag, Grundtabelle * §10 (3) EStG bis 2004. */ -public const vorsorge2004Grundhoechstbetrag: Int { +public constant vorsorge2004Grundhoechstbetrag: Int { from 1985-01-01 = 1196 from 1992-01-01 = 1334 } @@ -238,7 +238,7 @@ public const vorsorge2004Grundhoechstbetrag: Int { * haben, maximal den gleichen Altersentlastungsbetrag. Ab 2005 hängt dieser Betrag, * den diese Steuerpflichtigen erhalten, vom Geburtsjahr ab. */ -public const altersentlastungsbetragMax: Int or Dict { +public constant altersentlastungsbetragMax: Int or Dict { from 1984-01-01 = 1534 from 1989-01-01 = 1902 from 2002-01-01 = 1908 @@ -291,7 +291,7 @@ public const altersentlastungsbetragMax: Int or Dict { * haben, die gleiche Altersentlastungsquote abgezogen. Ab 2005 hängt diese Quote, * den diese Steuerpflichtigen erhalten, vom Geburtsjahr ab. */ -public const altersentlastungQuote: Float or Dict { +public constant altersentlastungQuote: Float or Dict { from 1984-01-01 = 0.4 # Reference: Artikel 1 G. v. 05.07.2004 BGBl. I S. 1427. @@ -342,7 +342,7 @@ public const altersentlastungQuote: Float or Dict { * Lebensjahr vollendet hatte. * Reference: § 24a Art. 3 EStG */ -public const altersentlastungsbetragAltersgrenze: Int { +public constant altersentlastungsbetragAltersgrenze: Int { from 1984-01-01 = 64 } @@ -355,7 +355,7 @@ public const altersentlastungsbetragAltersgrenze: Int { * 2023 auf 100% gesetzt. * Reference: § 10 Abs. 1 Nr. 2 Buchst. a und b EStG */ -public const einfuehrungsfaktor: { +public constant einfuehrungsfaktor: { from 2005-01-01 = { 0: {lower_threshold: -inf, rate_linear: 0, intercept_at_lower_threshold: 0.6}, 1: {lower_threshold: 2005, upper_threshold: 2025, rate_linear: 0.02}, @@ -375,7 +375,7 @@ public const einfuehrungsfaktor: { * Entlastungsbetrag für Alleinerziehende * § 24b (1) EStG. vor 2004 "Haushaltsfreibetrag", § 32 (7) EStG */ -public const alleinerzFreibetrag: Int { +public constant alleinerzFreibetrag: Int { from 1984-01-01 = 2154 from 1986-01-01 = 2319 from 1989-01-01 = 2871 @@ -398,7 +398,7 @@ public const alleinerzFreibetrag: Int { * §24b (2) S. 2 EStG. Alleinerziehenden-Entlastungsbetrag, Zusatzbetrag pro Kind ab * dem 2. Kind. */ -public const alleinerzFreibetragZusatz: Int { +public constant alleinerzFreibetragZusatz: Int { # Reference: Art. 1 G. vs. 16.07.2015 BGBl. I S.1202 from 2015-01-01 = 240 } @@ -408,7 +408,7 @@ public const alleinerzFreibetragZusatz: Int { * §10 (3) S. 2 EStG (vor 2004). Der Vorwegabzug wird pauschal um einen Anteil * gekürzt bei abhängig Beschäftigten (vereinfacht). */ -public const vorsorge2004KuerzungVorwegabzug: Float { +public constant vorsorge2004KuerzungVorwegabzug: Float { from 1985-01-01 = 0.0935 from 1986-01-01 = 0.096 from 1987-01-01 = 0.0935 @@ -425,7 +425,7 @@ public const vorsorge2004KuerzungVorwegabzug: Float { * AL-V), der für sozialverspfl. Beschäftigte gilt. * §10 Abs. 4 S.1 EStG */ -public const vorsorgeSonstigeAufwendungenMax: Int { +public constant vorsorgeSonstigeAufwendungenMax: Int { # Reference: Art. 1 G. v. 05.07.2004 BGBl. I S.1427 from 2005-01-01 = 1500 @@ -437,7 +437,7 @@ public const vorsorgeSonstigeAufwendungenMax: Int { * Maximalbetrag der Altersvorsorgeaufwendungen, 2005er Rechtsstand * §10 (3) EStG, Anlage 2 SGB VI */ -public const vorsorgeAltersvorsorgeaufwendungenMax: Int { +public constant vorsorgeAltersvorsorgeaufwendungenMax: Int { # Art. 1 G. v. 05.07.2004 BGBl. I S.1427 from 2005-01-01 = 20000 @@ -475,7 +475,7 @@ public const vorsorgeAltersvorsorgeaufwendungenMax: Int { * Beschäftigten. * §10 (3) a) S.4 EStG */ -public const vorsorgeKrankenMinderung: Float { +public constant vorsorgeKrankenMinderung: Float { # Reference: Art. 1 G. v. 16.07.2009 BGBl. I S. 1959 from 2009-07-23 = 0.04 } @@ -484,7 +484,7 @@ public const vorsorgeKrankenMinderung: Float { * Behinderten-Pauschbetrag, in Abhängigkeit des Behinderungsgrads. * § 33b (3) EStG. */ -public const behindertenPauschbetrag: Dict { +public constant behindertenPauschbetrag: Dict { # Reference: G. v. 05.08.1974 BGBl. I S. 1769. from 1975-01-01 = { 0: 0, @@ -531,7 +531,7 @@ public const behindertenPauschbetrag: Dict { * anrechenbar ist * §10 (1) Nr. 5 EStG */ -public const kinderbetreuungskostenAbzAnteil: Float { +public constant kinderbetreuungskostenAbzAnteil: Float { # Reference: Art. 1 G. v. 01.11.2011 BGBl. I S.2131 from 2012-01-01 = 0.6666666 } @@ -540,7 +540,7 @@ public const kinderbetreuungskostenAbzAnteil: Float { * Maximal abziehbare Betreuungsaufwendungen pro Kind * §10 (1) Nr. 5 EStG */ -public const kinderbetreuungskostenAbzMaximum: Int { +public constant kinderbetreuungskostenAbzMaximum: Int { # Reference: Art. 1 G. v. 01.11.2011 BGBl. I S.2131 from 2012-01-01 = 4000 } @@ -549,7 +549,7 @@ public const kinderbetreuungskostenAbzMaximum: Int { * Anteil abgezogene Rentenversicherungsbeiträge * §10 (3) a) S.4 EStG */ -public const vorsorgepauschaleRentenversicherungsAnteil: Dict> { +public constant vorsorgepauschaleRentenversicherungsAnteil: Dict> { 2005-01-01 = { 0: { lower_threshold: -inf, @@ -600,7 +600,7 @@ public const vorsorgepauschaleRentenversicherungsAnteil: Dict { +public constant vorsorgepauschaleKvMax: Dict { # Reference: Art. 1 G. v. 16.07.2009 BGBl. I S. 1959 from 2009-07-23 = { steuerklasse_3: 3000, diff --git a/src/resources/builtins/parameters/elterngeld.ttsl b/src/resources/builtins/parameters/elterngeld.ttsl index a4626eab..4f6f14d2 100644 --- a/src/resources/builtins/parameters/elterngeld.ttsl +++ b/src/resources/builtins/parameters/elterngeld.ttsl @@ -6,7 +6,7 @@ package elterngeld * Faktor bei der ElG-Berechung, 2. Stufe * § 2 (1) BEEG */ -public const faktor: Float { +public constant faktor: Float { from 2007-01-01 = 0.67 } @@ -14,7 +14,7 @@ public const faktor: Float { * Höchstbetrag des Elterngeldes * § 2 (1) BEEG */ -public const hoechstbetrag: Int { +public constant hoechstbetrag: Int { from 2007-01-01 = 1800 } @@ -23,7 +23,7 @@ public const hoechstbetrag: Int { * § 2 (2) BEEG. Maßgeblich ist das durchschnittlich erzielte monatliche Einkommen * vor der Geburt */ -public const nettoeinkommenStufen: Dict { +public constant nettoeinkommenStufen: Dict { # Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 from 2007-01-01 = { 1: 1000, @@ -41,7 +41,7 @@ public const nettoeinkommenStufen: Dict { * Mindestbetrag des Elterngeldes * § 2 (5) BEEG */ -public const mindestbetrag: Int { +public constant mindestbetrag: Int { # Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 from 2007-01-01 = 300 } @@ -50,7 +50,7 @@ public const mindestbetrag: Int { * Korrektur des Prozentsatzes für hohe und niedrige Einkommen * § 2 (2) BEEG */ -public const prozentKorrektur: Float { +public constant prozentKorrektur: Float { # Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 from 2007-01-01 = 0.001 } @@ -59,7 +59,7 @@ public const prozentKorrektur: Float { * Minimaler Anteil des Elterngelds am vorherigen Nettoeinkommen * § 2 (2) BEEG */ -public const prozentMinimum: Float { +public constant prozentMinimum: Float { from 2007-01-01 = 0.67 # Reference: Art. 14 G. v. 09.12.2010 BGBl. I S. 1885 @@ -70,7 +70,7 @@ public const prozentMinimum: Float { * Einkommensschritte für die Korrektur * § 2 (2) BEEG */ -public const einkommensSchrittKorrektur: Int { +public constant einkommensSchrittKorrektur: Int { # Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 from 2007-01-01 = 2 } @@ -81,7 +81,7 @@ public const einkommensSchrittKorrektur: Int { * wird das Elterngeld um 10% (max. um 75€) erhöht. * Reference: § 2a BEEG */ -public const geschwisterbonusAltersgrenzenKinder: Dict { +public constant geschwisterbonusAltersgrenzenKinder: Dict { from 2007-01-01 = { 3: 2, 6: 3 @@ -92,7 +92,7 @@ public const geschwisterbonusAltersgrenzenKinder: Dict { * Geschwisterbonus als prozentualer Aufschlag * § 2a (1) BEEG. Früher § 2 (4) BEEG */ -public const geschwisterbonusAufschlag: Float { +public constant geschwisterbonusAufschlag: Float { # Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 from 2007-01-01 = 0.1 } @@ -101,7 +101,7 @@ public const geschwisterbonusAufschlag: Float { * Minimaler Geschwisterbonus als Euro-Betrag * § 2a (1) BEEG. Früher §2 (4) BEEG */ -public const geschwisterbonusMinimum: Int { +public constant geschwisterbonusMinimum: Int { # Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 from 2007-01-01 = 75 } @@ -111,7 +111,7 @@ public const geschwisterbonusMinimum: Int { * § 2a (4) BEEG, früher §2 (6) BEEG. * pro Monat */ -public const mehrlingbonus: Int { +public constant mehrlingbonus: Int { # Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 from 2007-01-01 = 300 } @@ -120,7 +120,7 @@ public const mehrlingbonus: Int { * Sozialversicherungspauschale zur Berechnung des Nettoeinkommens * §2f BEEG. Vor 2012 waren es die eigentlichen Pflichtbeiträge. */ -public const sozialversicherungspauschale: Float { +public constant sozialversicherungspauschale: Float { # Reference: Art. 1 G. v. 10.09.2012 BGBl. I S. 1878 from 2012-09-18 = 0.21 } @@ -129,7 +129,7 @@ public const sozialversicherungspauschale: Float { * Maximale Anzahl an Monaten, in denen ein Paar Elterngeld erhält * § 4 (3) BEEG */ -public const maxMonatePaar: Int { +public constant maxMonatePaar: Int { # Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 from 2007-01-01 = 14 } @@ -138,7 +138,7 @@ public const maxMonatePaar: Int { * Maximale Anzahl an Monaten, die jedes Elternteil Elterngeld erhält * § 4 (3) BEEG */ -public const maxMonateIndividuell: Int { +public constant maxMonateIndividuell: Int { # Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 from 2007-01-01 = 12 } diff --git a/src/resources/builtins/parameters/erwerbsminderungsrente.ttsl b/src/resources/builtins/parameters/erwerbsminderungsrente.ttsl index 42893173..2c1e5b3a 100644 --- a/src/resources/builtins/parameters/erwerbsminderungsrente.ttsl +++ b/src/resources/builtins/parameters/erwerbsminderungsrente.ttsl @@ -10,7 +10,7 @@ package Erwerbsminderungsrente * Reference: § 77 SGB VI Zugangsfaktor * pro Jahr */ -public const abschlagsfreieAltersgrenze: Dict { +public constant abschlagsfreieAltersgrenze: Dict { from 2001-01-01 = 63 from 2012-01-01 = 63.083333 from 2012-02-01 = 63.166666 @@ -39,7 +39,7 @@ public const abschlagsfreieAltersgrenze: Dict { * Reference: § 77 Abs. 4 SGB VI Zugangsfaktor * pro Jahr */ -public const regelaltersgrezeLangjaehrigeVersicherte: Dict { +public constant regelaltersgrezeLangjaehrigeVersicherte: Dict { from 2001-01-01 = 63 } @@ -50,7 +50,7 @@ public const regelaltersgrezeLangjaehrigeVersicherte: Dict { * Reference: § 264d SGB VI Zugangsfaktor * pro Jahr */ -public const wartezeitgrenzeLangjaehrigeVersicherteAbschlagsfrei: Dict { +public constant wartezeitgrenzeLangjaehrigeVersicherteAbschlagsfrei: Dict { from 2001-01-01 = 35 from 2024-01-01 = 40 } @@ -63,7 +63,7 @@ public const wartezeitgrenzeLangjaehrigeVersicherteAbschlagsfrei: Dict { +public constant zurechnungszeitgrenze: Dict { from 2001-01-01 = 62.916666 from 2001-02-01 = 62.833333 from 2001-03-01 = 62.75 @@ -122,7 +122,7 @@ public const zurechnungszeitgrenze: Dict { * sind bei 10.8% gedeckelt. * Reference: § 77 SGB VI Zugangsfaktor */ -public const minZugangsfaktor: Dict { +public constant minZugangsfaktor: Dict { from 2000-01-01 = 0.892 } @@ -133,7 +133,7 @@ public const minZugangsfaktor: Dict { * das Sicherungsziel der Rentenart im Verhältnis zu einer Altersrente. * Reference: § 67 SGB VI Rentenartfaktor */ -public const rentenartfaktor: Dict { +public constant rentenartfaktor: Dict { from 2001-01-01 = { teilw: 0.5, voll: 1.0 @@ -147,6 +147,6 @@ public const rentenartfaktor: Dict { * Lebensjahr bis zum Beginn der Rente * Reference: SGB VI § 72: Grundbewertung */ -public const altersgrenzeGrundbewertung: Dict { +public constant altersgrenzeGrundbewertung: Dict { from 2001-01-01 = 16 } diff --git a/src/resources/builtins/parameters/erziehungsgeld.ttsl b/src/resources/builtins/parameters/erziehungsgeld.ttsl index 1549dea2..327e7fb0 100644 --- a/src/resources/builtins/parameters/erziehungsgeld.ttsl +++ b/src/resources/builtins/parameters/erziehungsgeld.ttsl @@ -6,7 +6,7 @@ package erziehungsgeld * Einkommensgrenze für abzugsfreies Erziehungsgeld * Reference: Bundesgesetzblatt Jahrgang 2004 Teil I Nr. 6 (p.209) */ -public const erziehungsgeldEinkommensgrenze: Dict>> { +public constant erziehungsgeldEinkommensgrenze: Dict>> { from 2004-02-09 = { limit: { alleinerz: { @@ -35,7 +35,7 @@ public const erziehungsgeldEinkommensgrenze: Dict { +public constant erziehungsgeldAufschlagEinkommen: Dict { from 2004-02-09 = 3140 } @@ -43,7 +43,7 @@ public const erziehungsgeldAufschlagEinkommen: Dict { * Höhe des Erziehungsgeldes abhängig vom beantragtem Satz * Reference: Bundesgesetzblatt Jahrgang 2004 Teil I Nr. 6 § 5 (p.208) */ -public const erziehungsgeldSatz: Dict { +public constant erziehungsgeldSatz: Dict { from 2004-02-09 = { regelsatz: 300, budgetsatz: 450 @@ -58,7 +58,7 @@ public const erziehungsgeldSatz: Dict { * das Produkt entsprechend vom Erziehungsgeld Anspruch abgezogen * Reference: Bundesgesetzblatt Jahrgang 2004 Teil I Nr. 6 */ -public const abschlagFaktor: Float { +public constant abschlagFaktor: Float { from 2004-02-09 = 0.052 } @@ -67,7 +67,7 @@ public const abschlagFaktor: Float { * relevanten Einkommen zu berechnen * Reference: Bundesgesetzblatt Jahrgang 2004 Teil I Nr. 6 § 6 (p.209) */ -public const pauschalAbzugAufEinkommen: Float { +public constant pauschalAbzugAufEinkommen: Float { from 2004-02-09 = 0.76 } @@ -75,7 +75,7 @@ public const pauschalAbzugAufEinkommen: Float { * Grenze der wöchentlichen Arbeitsstunden bis zu der Erziehungsgeld ausgezahlt wird * Reference: Bundesgesetzblatt Jahrgang 2004 Teil I Nr. 6 § 15 (p.211) */ -public const arbeitsstundenWoechentlicheGrenze: Int { +public constant arbeitsstundenWoechentlicheGrenze: Int { from 2004-02-09 = 30 } @@ -83,7 +83,7 @@ public const arbeitsstundenWoechentlicheGrenze: Int { * Alter des Kindes in Monaten bis zu dem der Regelsatz bezogen werden kann. * Reference: Bundesgesetzblatt Jahrgang 2004 Teil I Nr. 6 */ -public const endAlterKindRegelsatz: Int { +public constant endAlterKindRegelsatz: Int { from 2004-01-01 = 24 } @@ -91,7 +91,7 @@ public const endAlterKindRegelsatz: Int { * Alter des Kindes in Monaten bis zu dem der Budgetsatz bezogen werden kann. * Reference: Bundesgesetzblatt Jahrgang 2004 Teil I Nr. 6 */ -public const endAlterKindBudgetsatz: Int { +public constant endAlterKindBudgetsatz: Int { from 2004-01-01 = 12 } diff --git a/src/resources/builtins/parameters/gesetzlicheRente.ttsl b/src/resources/builtins/parameters/gesetzlicheRente.ttsl index 2946b23b..59d9aa04 100644 --- a/src/resources/builtins/parameters/gesetzlicheRente.ttsl +++ b/src/resources/builtins/parameters/gesetzlicheRente.ttsl @@ -7,7 +7,7 @@ package gesetzlicheRente * Verhältnis von Rentnern zu Beitragszahlern modifiziert * Reference: §68 Abs. 4 S. 6 SGB VI */ -public const alpha: Float { +public constant alpha: Float { from 1984-01-01 = 0.0 from 2002-01-01 = 0.25 } @@ -16,7 +16,7 @@ public const alpha: Float { * Teil des Riesterfaktors in der Rentenanpassungsformel * Reference: §68 Abs. 5 SGB VI */ -public const altersVorsorgeAnteil: Float { +public constant altersVorsorgeAnteil: Float { from 1993-01-01 = 0.0 from 2002-01-01 = 0.5 from 2003-01-01 = 1.0 @@ -33,7 +33,7 @@ public const altersVorsorgeAnteil: Float { * Beschäftigten, der geringfügig Beschäftigten und der Bezieher von ALG. * statistik-rente.de/drv */ -public const beitragsvolumen: Dict { +public constant beitragsvolumen: Dict { from 1991-01-01 = 108688000 from 1992-01-01 = 117359000 from 1993-01-01 = 120559000 @@ -71,7 +71,7 @@ public const beitragsvolumen: Dict { * Multiplikation des Rentenwerts mit 45. statistik-rente.de/drv * Reference: § 154 Abs. 3 Satz 1 Nr. 2 SGB VI */ -public const eckrente: Float { +public constant eckrente: Float { from 1995-01-01 = 988.15 from 1996-01-01 = 992.72 from 1997-01-01 = 1009.1 @@ -102,7 +102,7 @@ public const eckrente: Float { * Durchschnittslohn * Durchschnittsbruttolohn aller Arbeitnehmer:innen in einem Jahr */ -public const durchschnittslohn: Float { +public constant durchschnittslohn: Float { from 2005-01-01 = 28468.23 from 2006-01-01 = 28673.22 from 2007-01-01 = 28978.19 @@ -122,7 +122,7 @@ public const durchschnittslohn: Float { * Durchschnittsentgelt aller Versicherten im Sinne der deutschen Sozialversicherung. * Dieses wird benötigt zur Berechnung der Entgeltpunkte. */ -public const beitragspflichtigesDurchschnittsentgelt: Int { +public constant beitragspflichtigesDurchschnittsentgelt: Int { from 2005-01-01 = 29202 from 2006-01-01 = 29494 from 2007-01-01 = 29951 @@ -167,7 +167,7 @@ public const beitragspflichtigesDurchschnittsentgelt: Int { * diesen Faktor erhöht. * Reference: §256a SGB VI and Anlage 10 SGB VI */ -public const umrechnungEntgeltpBeitrittsgebiet: Float { +public constant umrechnungEntgeltpBeitrittsgebiet: Float { from 1945-01-01 = 1.0000 from 1946-01-01 = 1.0000 from 1947-01-01 = 1.0000 @@ -255,7 +255,7 @@ public const umrechnungEntgeltpBeitrittsgebiet: Float { * Rentenvolumen * Gesamtvolumen der ausgezahlten Renten */ -public const gesamtesRentenvolumen: Int { +public constant gesamtesRentenvolumen: Int { from 1991-01-01 = 117912000 from 1992-01-01 = 130901000 from 1993-01-01 = 141180000 @@ -293,7 +293,7 @@ public const gesamtesRentenvolumen: Int { * einen Entgeltpunkt entspricht. * Reference: statistik-rente.de/drv, § 68 SGB VI */ -public const rentenwert: Dict { +public constant rentenwert: Dict { from 1992-01-01 = { west: 21.19, ost: 12.05 @@ -465,7 +465,7 @@ public const rentenwert: Dict { * Konstante zur Bestimmung des Höchstwerts der durchschnittlichen Entgeltpunkte und * des Effekts eines weiteren Monats an Grundrentenzeiten auf Höchstwert. */ -public const grundrenteHöchstwert: Dict { +public constant grundrenteHöchstwert: Dict { # Reference: § 76g Abs. 4 S. 3, 4 SGB VI from 2021-01-01 = { base: 0.0334, @@ -478,7 +478,7 @@ public const grundrenteHöchstwert: Dict { * Der Zugangsfaktor für die Grundrente ist auf 1 begrenzt. * Reference: § 77 Abs. 2 SGB VI */ -public const grundrenteZugangsfaktorMax: Int { +public constant grundrenteZugangsfaktorMax: Int { from 2021-01-01 = 1 } @@ -488,7 +488,7 @@ public const grundrenteZugangsfaktorMax: Int { * an Grundrentenzeiten ab der zusätzliche Monate an Grundrentenzeiten nicht * berücksichtigt werden */ -public const grundrenteZeiten: Dict { +public constant grundrenteZeiten: Dict { # Reference: § 76g Abs. 4 S. 5,6 / Abs. 1 S. 1 SGB VI from 2021-01-01 = { min: 396, @@ -502,7 +502,7 @@ public const grundrenteZeiten: Dict { * Einkommensanrechnung des Grundrentenzuschlags zu ermitteln * Reference: § 97a Abs. 4 S. 2, 4 SGB VI */ -public const grundrenteEinkommensanrechnungSingle: Dict> { +public constant grundrenteEinkommensanrechnungSingle: Dict> { # Reference: § 97a Abs. 4 S. 2, 4 SGB VI from 2021-01-01 = { 0: { @@ -528,7 +528,7 @@ public const grundrenteEinkommensanrechnungSingle: Dict * Einkommensanrechnung des Grundrentenzuschlags zu ermitteln * Reference: § 97a Abs. 4 S. 2, 4 SGB VI */ -public const grundrenteEinkommensanrechnungMarried: Dict> { +public constant grundrenteEinkommensanrechnungMarried: Dict> { # Reference: § 97a Abs. 4 S. 2, 4 SGB VI from 2021-01-01 = { 0: { @@ -553,7 +553,7 @@ public const grundrenteEinkommensanrechnungMarried: Dict { +public constant zugangsfaktorVeraenderungProJahr: Dict { # Reference: §77 Abs. 2 Nr. 2 SGB VI from 2001-01-01 = { vorzeitiger_renteneintritt: 0.036, @@ -580,7 +580,7 @@ public const zugangsfaktorVeraenderungProJahr: Dict { * höher oder niedriger, wenn keine Ausnahmeregelungen erfüllt sind. * Reference: § 35 Satz 2 SGB VI */ -public const regelaltersgrenze: Dict> { +public constant regelaltersgrenze: Dict> { from 1984-01-01 = { 0: { lower_threshold: -inf, @@ -609,7 +609,7 @@ public const regelaltersgrenze: Dict> { * geboren vor 1952 in Rente gehen konnten. * Reference: § 237a SGB VI */ -public const altersgrenzeFrauen: Dict> { +public constant altersgrenzeFrauen: Dict> { from 1980-01-01 = { 0: { lower_threshold: -inf, @@ -622,7 +622,7 @@ public const altersgrenzeFrauen: Dict> { rate_linear: 1, }, 2: { - upper_threshold: 1951.916666666, # constant 65 + upper_threshold: 1951.916666666, # 65 rate_linear: 0, }, 3: { @@ -651,7 +651,7 @@ public const altersgrenzeFrauen: Dict> { * (mit Abschlägen). * Reference: § 237a SGB VI */ -public const altersgrenzeFrauenVorzeitig: Dict> { +public constant altersgrenzeFrauenVorzeitig: Dict> { from 1980-01-01 = { 0: { lower_threshold: -inf, @@ -664,7 +664,7 @@ public const altersgrenzeFrauenVorzeitig: Dict> { rate_linear: 7, }, 2: { - upper_threshold: inf, # constant 67 + upper_threshold: inf, # 67 rate_linear: 0, }, } @@ -675,7 +675,7 @@ public const altersgrenzeFrauenVorzeitig: Dict> { * Kohorte, ab der Rente für Frauen abgeschafft. * Reference: § 237a SGB VI */ -public const firstBirthyearWithoutRenteFrauen: Int { +public constant firstBirthyearWithoutRenteFrauen: Int { from 1980-01-01 = 1952 } @@ -686,7 +686,7 @@ public const firstBirthyearWithoutRenteFrauen: Int { * Wert ist als Jahr zu interpretieren. * Reference: § 237a SGB VI */ -public const renteFrauenPflichtbeitrag: Int { +public constant renteFrauenPflichtbeitrag: Int { from 1950-01-01 = 10 } @@ -696,7 +696,7 @@ public const renteFrauenPflichtbeitrag: Int { * bezogen werden kann. * Reference: § 237 SGB VI */ -public const altersgrenzeArbeitslosigkeitAbschlagsfrei: Float or Dict> { +public constant altersgrenzeArbeitslosigkeitAbschlagsfrei: Float or Dict> { from 1980-01-01 = { 0: { scalar: 60.0, @@ -1305,7 +1305,7 @@ public const altersgrenzeArbeitslosigkeitAbschlagsfrei: Float or Dict>{ +public constant altersgrenzeArbeitslosigkeitVorzeitig: Float or Dict>{ from 1980-01-01 = 60.0 # Increase of early retirement age from 60 to 62 for birth cohort 1949-1952. @@ -1553,7 +1553,7 @@ public const altersgrenzeArbeitslosigkeitVorzeitig: Float or Dict> { +public constant altersgrenzeLangjährigVersicherteAbschlagsfrei: Dict> { from 1984-01-01 = { 0: { lower_threshold: -inf, @@ -1610,7 +1610,7 @@ public const altersgrenzeLangjährigVersicherteAbschlagsfrei: Dict> { +public constant altersgrenzeBesondersLangjährigVersicherte: Dict> { from 2012-01-01 = { 0: { lower_threshold: -inf, @@ -1671,7 +1671,7 @@ public const altersgrenzeBesondersLangjährigVersicherte: Dict { +public constant vermoegensfreibetrag: Dict { from 1984-01-01: { adult: 0, child: 0, @@ -29,7 +29,7 @@ public const vermoegensfreibetrag: Dict { * Anrechnungsfreie Anteile staatliche Rente wenn mindestens 33 Jahre * Grundrentenzeiten erreicht wurden. */ -public const gesetzlicheRenteAnrechnungsfrei: Dict> { +public constant gesetzlicheRenteAnrechnungsfrei: Dict> { from 1984-01-01: { 0: { lower_threshold: -inf, @@ -62,7 +62,7 @@ public const gesetzlicheRenteAnrechnungsfrei: Dict> { * Nur das Kapitaleinkommens, das über diesem Freibetrag liegt, wird auf die * Grundsicherung im Alter angerechnet. The reference is § 82 SGB XII Abs. 2. */ -public const kapitaleinkommensfreibetrag: Int { +public constant kapitaleinkommensfreibetrag: Int { from 1984-01-01 = 0 # Reference: § 43 SGB XII Abs. 2 @@ -75,7 +75,7 @@ public const kapitaleinkommensfreibetrag: Int { * zum Einkommen addiert wird. * Reference: § 82 SGB XII Abs. 3 */ -public const erwerbseinkommensfreibetrag: Float { +public constant erwerbseinkommensfreibetrag: Float { # Unclear how it was handled before 2005 from 1984-01-01 = 0 @@ -88,7 +88,7 @@ public const erwerbseinkommensfreibetrag: Float { * Einkommen addiert wird. * Reference: § 82 SGB XII Abs. 4 */ -public const privateRenteAnrechnungsfrei: Dict> { +public constant privateRenteAnrechnungsfrei: Dict> { from 1984-01-01: { # Unclear how it was handled before 2005, 0: { @@ -124,6 +124,6 @@ public const privateRenteAnrechnungsfrei: Dict> { * als Mehrbedarf anerkannt. * Reference: § 30 Abs. 1 SGB XII, https:#www.buzer.de/gesetz/3415/al0-3758.htm */ -public const mehrbedarfSchwerbehinderung: Float { +public constant mehrbedarfSchwerbehinderung: Float { from 2006-12-07 = 0.17 } diff --git a/src/resources/builtins/parameters/kindergeld.ttsl b/src/resources/builtins/parameters/kindergeld.ttsl index d431e1b6..72579993 100644 --- a/src/resources/builtins/parameters/kindergeld.ttsl +++ b/src/resources/builtins/parameters/kindergeld.ttsl @@ -7,7 +7,7 @@ package kindergeld * Bedingungen ein Anspruch auf Kindergeld bestehen. * Reference: § 32 Art. 2-4 EStG. */ -public const altersgrenze: Dict { +public constant altersgrenze: Dict { from 1984-01-01 = { mit_bedingungen: 27 ohne_bedingungen: 18 @@ -27,7 +27,7 @@ public const altersgrenze: Dict { * Für Werte vor 2002, siehe 'BMF - Datensammlung zur Steuerpolitik' * reference period: Month */ -public const kindergeld: Dict { +public constant kindergeld: Dict { from 1975-01-01 = { 1: 26 2: 36 @@ -205,7 +205,7 @@ public const kindergeld: Dict { * § 32 (4) EStG. Wurde 2012 durch eine Höchstgrenze der gearbeiteten Stunden ersetzt. * reference period: Year */ -public const einkommensgrenze: Int { +public constant einkommensgrenze: Int { from 1984-01-01 = 0 # Reference: Art. 1 G. v. 11.10.1995 BGBl. I S. 1250 @@ -232,7 +232,7 @@ public const einkommensgrenze: Int { * Bezug von Kindergeld * reference period: Week */ -public const stundengrenze: Int { +public constant stundengrenze: Int { # Reference: Art. 1 G. v. 01.11.2011 BGBl. I S. 2131 from 2012-01-01 = 20 } @@ -243,7 +243,7 @@ public const stundengrenze: Int { * 2020 bzw. Mai 2021 ausgezahlt, aber ist hier auf das volle Kalenderjahr angerechnet. * reference period: Year */ -public const kinderbonus: Dict { +public constant kinderbonus: Dict { from 1984-01-01 = 0 # Reference: Art. 1 Zweites Corona-Steuerhilfegesetz v. 29.06.2020 BGBl. I S. 1512 diff --git a/src/resources/builtins/parameters/kinderzuschlag.ttsl b/src/resources/builtins/parameters/kinderzuschlag.ttsl index 057bba89..1c16d217 100644 --- a/src/resources/builtins/parameters/kinderzuschlag.ttsl +++ b/src/resources/builtins/parameters/kinderzuschlag.ttsl @@ -4,7 +4,7 @@ package kidnerzuschlag * Maximale Höhe des Kinderzuschlags * Reference: § 6a (2) BKGG. Betrag pro Kind */ -const maximum: Int { +constant maximum: Int { # Reference: Art. 46 G. v. 24.12.2003 BGBl. I S. 2954. from 2005-01-01 = 140 @@ -38,7 +38,7 @@ const maximum: Int { * the maximum amount in the child supplement increases by 20 euros. * § 6a Abs. 2 Satz 4 BKGG */ -const kindersofortzuschl: Int { +constant kindersofortzuschl: Int { # Reference: § 6a Abs. 2 Satz 4 BKGG from 2022-07-01 = 20 @@ -52,7 +52,7 @@ const kindersofortzuschl: Int { * Mindesteinkommen für Paare * Reference: § 6a (1) Nr. 2 BKGG. */ -const min_eink_paare: Int { +constant min_eink_paare: Int { # Reference: kein expliziter Wert im Gesetz. from 2005-01-01 = 0 @@ -64,7 +64,7 @@ const min_eink_paare: Int { * Mindesteinkommen für Alleinerziehende * Reference: § 6a (1) Nr. 2 BKGG. */ -const min_eink_alleinerz: Int { +constant min_eink_alleinerz: Int { # Reference: kein expliziter Wert im Gesetz. from 2005-01-01 = 0 @@ -79,7 +79,7 @@ const min_eink_alleinerz: Int { * Eltern gemindert wird. Bis 07/2019 wurde das Einkommen nur in 10€-Schritten * berücksichtigt. */ -const entzugsrate_eltern: Float { +constant entzugsrate_eltern: Float { # Reference: Art. 46 G. v. 24.12.2003 BGBl. I. S. 2954. from 2005-01-01 = 0.7 @@ -96,7 +96,7 @@ const entzugsrate_eltern: Float { * Unterhaltsvorschuss. * Reference: § 6a (3) BKGG */ -const entzugsrate_kind: Float { +constant entzugsrate_kind: Float { # Reference: Art. 46 G. v. 24.12.2003 BGBl. I. S. 2954. from 2005-01-01 = 1 @@ -110,7 +110,7 @@ const entzugsrate_kind: Float { * Berechnet für jeweils zwei Jahre die Höhe der steuerfrei zu stellenden * Existenzminima (nicht identisch mit dem steuerlichen Grundfreibetrag). */ -const existenzminimum: Dict{ +constant existenzminimum: Dict{ # Reference: 5. Existenzminimumsbericht, Bundestag Drucksache 15/2462, Übersicht 3 from 2005-01-01 = { regelsatz: { diff --git a/src/resources/builtins/parameters/lohnsteuer.ttsl b/src/resources/builtins/parameters/lohnsteuer.ttsl index 3e6d7007..9890cf62 100644 --- a/src/resources/builtins/parameters/lohnsteuer.ttsl +++ b/src/resources/builtins/parameters/lohnsteuer.ttsl @@ -6,7 +6,7 @@ package lohnsteuer * Mindest- und Maximalsteuern festgelegt sind. * Referenz: § 39b Absatz 2 Satz 7 EStG */ -public const lohnsteuerEinkommensgrenzen: Dict { +public constant lohnsteuerEinkommensgrenzen: Dict { from 2002-01-01 { 0: 8946, 1: 27306, diff --git a/src/resources/builtins/parameters/solidaritaetszuschlag.ttsl b/src/resources/builtins/parameters/solidaritaetszuschlag.ttsl index e67d3960..328afa9b 100644 --- a/src/resources/builtins/parameters/solidaritaetszuschlag.ttsl +++ b/src/resources/builtins/parameters/solidaritaetszuschlag.ttsl @@ -5,7 +5,7 @@ package solidaritaetszuschlag * Ab 1995, der upper threshold im Intervall 1 ist nach der Formel * transition_threshold in soli_st.py berechnet. */ -public const solidaritaetszuschlag: Dict> { +public constant solidaritaetszuschlag: Dict> { # Reference: Artikel 1 G. v. 24.06.1991 BGBl. I S. 1318. from 1991-01-01 { 0: { diff --git a/src/resources/builtins/parameters/sozialversicherungsbeitrag.ttsl b/src/resources/builtins/parameters/sozialversicherungsbeitrag.ttsl index cdbb81c9..c6e682ce 100644 --- a/src/resources/builtins/parameters/sozialversicherungsbeitrag.ttsl +++ b/src/resources/builtins/parameters/sozialversicherungsbeitrag.ttsl @@ -24,7 +24,7 @@ package sozialversicherungsbeitrag * * access_different_date: jahresanfang */ -public const beitragssatz: Dict> { +public constant beitragssatz: Dict> { from 1984-01-01 { gesetzlicheKrankenversicherung: { mean_allgemein: 0.134 @@ -368,7 +368,7 @@ public const beitragssatz: Dict> { * Beitragssätze zu den gesetzlichen Sozialversicherungen * Die Beitragsbemessungsgrenze für Kranken- und Pflegeversicherung ist identisch. */ -public const beitragsbemessungsgrenze: Dict> { +public constant beitragsbemessungsgrenze: Dict> { from 1984-01-01 { ges_krankenv: { west: 1994 @@ -814,7 +814,7 @@ public const beitragsbemessungsgrenze: Dict> { * Monatliche Bezugsgröße * §18 SGB IV and https:#de.wikipedia.org/wiki/Bezugsgr%C3%B6%C3%9Fe */ -public const monatlicheBezugsgroeße: Dict { +public constant monatlicheBezugsgroeße: Dict { from 1984-01-01 { west: 1396 } @@ -1025,7 +1025,7 @@ public const monatlicheBezugsgroeße: Dict { * neunzigste Teil der monatlichen Bezugsgröße (1/90*30) * Reference: §240 SGB V Abs. 4 */ -public const mindestanteilBezugsgroeßeBeitragspflichtigeEinnahmeSelbst: Float { +public constant mindestanteilBezugsgroeßeBeitragspflichtigeEinnahmeSelbst: Float { from 1990-01-01 { scalar: 0.33333333 } @@ -1035,7 +1035,7 @@ public const mindestanteilBezugsgroeßeBeitragspflichtigeEinnahmeSelbst: Float { * Gleitzone (Midijob Grenze) und Minijob Grenze (bis 1999 unterschiedliche Grenzen) * Reference: Midijob § 20 (2) SGB IV, Minijob § 8 (1) Nr. 1 SGB IV */ -public const geringfuegigeEinkommensgrenzenMonatlich: Dict> { +public constant geringfuegigeEinkommensgrenzenMonatlich: Dict> { from 1984-01-01 { minijob: { west: 199 @@ -1203,7 +1203,7 @@ public const geringfuegigeEinkommensgrenzenMonatlich: Dict { +public constant pauschalabgabenGeringfuegigeBeschaeftigung: Dict { from 1984-01-01 { ges_krankenv: 0 ges_rentenv: 0 @@ -1259,7 +1259,7 @@ public const pauschalabgabenGeringfuegigeBeschaeftigung: Dict { * entrichten. * Reference: § 55 Abs. 3 SGB XI, KiBG Art. 1 */ -public const mindestalterBeitragszuschlagKinderlose: Int { +public constant mindestalterBeitragszuschlagKinderlose: Int { from 2005-01-01 = 23 } @@ -1267,7 +1267,7 @@ public const mindestalterBeitragszuschlagKinderlose: Int { * Allgemeiner gesetzlicher Mindestlohn pro Stunde * Reference: §1 (2) Mindestlohngesetz */ -public const mindestlohn: Float { +public constant mindestlohn: Float { from 2015-01-01 = 8.5 from 2017-01-01 = 8.84 from 2019-01-01 = 9.19 diff --git a/src/resources/builtins/parameters/unterhalt.ttsl b/src/resources/builtins/parameters/unterhalt.ttsl index 911e5cb9..5a93e8ae 100644 --- a/src/resources/builtins/parameters/unterhalt.ttsl +++ b/src/resources/builtins/parameters/unterhalt.ttsl @@ -5,7 +5,7 @@ package unterhalt * § 1612a BGB, § 1 Mindesunterhaltsverordnung. Mindestunterhalt für Kinder in * Abhängigkeit des Alters (unter 6, unter 12, bis 17 Jahre) */ -public const mindestunterhalt: Dict { +public constant mindestunterhalt: Dict { # Reference: V. v. 03.12.2015 BGBl. I S. 2188. from 2016-01-01 = { 6: 335, @@ -78,7 +78,7 @@ public const mindestunterhalt: Dict { * Elternteil das hälftige Kindergeld bei der Unterhaltsberechnung in Abzug bringen. * Reference: § 1612b BGB */ -public const abzugsrateKindergeld: Dict { +public constant abzugsrateKindergeld: Dict { from 2008-01-01 = { kind: 0.5, erwachsener: 1 diff --git a/src/resources/builtins/parameters/unterhaltvorschuss.ttsl b/src/resources/builtins/parameters/unterhaltvorschuss.ttsl index 1b014ea4..c8ac2694 100644 --- a/src/resources/builtins/parameters/unterhaltvorschuss.ttsl +++ b/src/resources/builtins/parameters/unterhaltvorschuss.ttsl @@ -5,7 +5,7 @@ package unterhaltvorschuss * `altersgrenze_mindesteinkommen` Jahren zu erhalten. * Reference: § 1 (1a) Nr. 2 Unterhaltsvorschussgesetz */ -public const mindesteinkommen: Int = { +public constant mindesteinkommen: Int = { # Reference: Art. 23 G. v. 14.08.2017 BGBl. I S. 3122. from 2017-01-01 = 600; } @@ -15,7 +15,7 @@ public const mindesteinkommen: Int = { * `mindesteinkommen` bezogen werden kann. * Reference: § 1 (1a) Nr. 2 Unterhaltsvorschussgesetz */ -public const altersgrenzeMindesteinkommen: Int = { +public constant altersgrenzeMindesteinkommen: Int = { # Reference: Art. 23 G. v. 14.08.2017 BGBl. I S. 3122. from 2017-01-01 = 12; } @@ -28,7 +28,7 @@ public const altersgrenzeMindesteinkommen: Int = { * bekommen, wenn das Elternteil ein Mindesteinkommen hat. * Reference: § 1 Abs. 1, 1a UhVorschG */ -public const altersgrenzen: Dict = { +public constant altersgrenzen: Dict = { # Reference: § 1 Abs. 1, 1a UhVorschG from 2017-01-01 = { 1: 6, diff --git a/src/resources/builtins/parameters/wohngeld.ttsl b/src/resources/builtins/parameters/wohngeld.ttsl index 7c4f843e..366268fa 100644 --- a/src/resources/builtins/parameters/wohngeld.ttsl +++ b/src/resources/builtins/parameters/wohngeld.ttsl @@ -4,7 +4,7 @@ package wohngeld * Faktor am Anfang der Wohngeldformel * Anlage 2 WoGG zu §19 Abs. 2 WoGG */ -public const faktorBerechnungsformel: Float { +public constant faktorBerechnungsformel: Float { from 1984-01-01 = 1 # Reference: Art. 1 G. v. 24.09 2008 BGBl. I S. 1856 @@ -20,7 +20,7 @@ public const faktorBerechnungsformel: Float { * Wohngeldverordnung (WoGV). * The keys from 1 to 12 below refer to the household size. */ -public const koeffizientenBerechnungsformel: Dict> { +public constant koeffizientenBerechnungsformel: Dict> { # Parameter aus Regressionsanalyse der Wohngeldtabellen from 1984-01-01 = { 1: { @@ -604,7 +604,7 @@ public const koeffizientenBerechnungsformel: Dict> { * der auf das Wohngeld für einen Haushalt mit 12 Personen angerechnet wird. * Reference: §19 Abs. 3 WoGG */ -public const bonusSehrGrosseHaushalte: Dict { +public constant bonusSehrGrosseHaushalte: Dict { # Reference: Art. 5 G. v. 22.12.1999 BGBl. I S. 2671 from 2001-01-01 = { max_anz_personen_normale_berechnung: 12, @@ -643,7 +643,7 @@ public const bonusSehrGrosseHaushalte: Dict { * Kriterien sind - entrichtete Steuern - entrichtete GKV- und GPV-Beiträge - * entrichtete GRV-Beiträge */ -public const abzugStufen: Dict { +public constant abzugStufen: Dict { from 1984-01-01 = { 0: 0.06, 1: 0.125, @@ -673,7 +673,7 @@ public const abzugStufen: Dict { * Minimalwert für Parameter M * WoGG - Anlage 3 (bis 2019 Anlage 2) (zu § 19 Abs. 2) */ -public const minMiete: Dict { +public constant minMiete: Dict { from 1984-01-01 = { 1: 0, 2: 0, @@ -756,7 +756,7 @@ public const minMiete: Dict { * Minimalwert für Parameter Y * WoGG - Anlage 3 (bis 2019 Anlage 2) (zu § 19 Abs. 2) */ -public const minEink: Dict { +public constant minEink: Dict { from 1984-01-01 = { 1: 0, 2: 0, @@ -855,7 +855,7 @@ public const minEink: Dict { * Monatlicher Freibetrag für Alleinerziehende und arbeitende Kinder * § 17 (4/5) WoGG */ -public const freibetragKinder: Dict { +public constant freibetragKinder: Dict { from 1984-01-01 = { alleinerz: 51, arbeitendes_kind: 0 @@ -888,7 +888,7 @@ public const freibetragKinder: Dict { * vorliegen. Dies ist aktuell nicht implementiert. § 17 Nr. 1 WoGG. (früher § 17 (2) * WoGG) */ -public const freibetragBehinderung: Dict or Int { +public constant freibetragBehinderung: Dict or Int { from 1984-01-01 = { 0: 0, 1: 0, @@ -928,7 +928,7 @@ public const freibetragBehinderung: Dict or Int { * Reference: § 17 Abs. 1 WoGG * in percent */ -public const behinderungsgrad: Dict { +public constant behinderungsgrad: Dict { from 1984-01-01 = { 1: 0, 2: 80 @@ -942,7 +942,7 @@ public const behinderungsgrad: Dict { * Die Werte sind nach Anzahl Personen - maximales Baujahr des Hauses (vor 2009) - * Mietstufe geordnet. Alle Werte in vollen Euro. */ -public const maxMiete: Dict>> { +public constant maxMiete: Dict>> { # Reference: Art. 1 G. v. 04.08.1980 BGBl I S. 1159. # Bis 1985 nur drei Mietstufen, streng abhängig von der Größe der Gemeinde. Es wird "Wohnung mit Sammelheizung und mit Bad oder Duschraum" angenommen. from 1981-01-01 = { @@ -2233,7 +2233,7 @@ public const maxMiete: Dict>> { * Wohngeld sein kann. Die genauen Werte regelt die Verwaltungsvorschrift vom April * 2009. Vorher war hohes Vermögen laut WoGG kein Ausschlussgrund. */ -public const vermoegensgrundfreibetrag: Float { +public constant vermoegensgrundfreibetrag: Float { # No wealth threshold in place. from 1970-01-01 = inf @@ -2246,7 +2246,7 @@ public const vermoegensgrundfreibetrag: Float { * Vermögensfreibetrag für jedes weitere Haushaltsmitglied * Wohngeld-Verwaltungsvorschift 21.37 */ -public const vermoegensfreibetragPerson: Float { +public constant vermoegensfreibetragPerson: Float { # No wealth threshold in place from 1970-01-01 = inf @@ -2262,7 +2262,7 @@ public const vermoegensfreibetragPerson: Float { * Reference: §12 (6) WoGG, Art. 1 G. v. 15.05.2020, BGBl I S. 1015. * per month */ -public const heizkostenentlastung: Dict { +public constant heizkostenentlastung: Dict { from 2021-01-01 { 1: 14.4, 2: 18.6, @@ -2280,7 +2280,7 @@ public const heizkostenentlastung: Dict { * Reference: Art. 1 G. v. 08.12.2022 BGBl. I Nr. 48 S. 2160 * per month */ -public const dauerhafteHeizkostenkomponente: Dict { +public constant dauerhafteHeizkostenkomponente: Dict { from 2023-01-01 { 1: 96, 2: 124, @@ -2298,7 +2298,7 @@ public const dauerhafteHeizkostenkomponente: Dict { * Reference: Art. 1 G. v. 08.12.2022 BGBl. I Nr. 48 S. 2160 * per month */ -public const klimakomponente: Dict { +public constant klimakomponente: Dict { from 2023-01-01 = { 1: 19.20, 2: 24.80, From 6658b4b164433b989a90de2326d6c50c3b5a7837 Mon Sep 17 00:00:00 2001 From: methr0 Date: Mon, 1 Jul 2024 13:40:41 +0200 Subject: [PATCH 101/183] add List and Dictionary Types --- .../ttsl-lang/src/language/typing/model.ts | 284 +++++++++++++++++- .../language/typing/safe-ds-type-factory.ts | 59 ++-- 2 files changed, 291 insertions(+), 52 deletions(-) diff --git a/packages/ttsl-lang/src/language/typing/model.ts b/packages/ttsl-lang/src/language/typing/model.ts index 9afa8770..bbef5a30 100644 --- a/packages/ttsl-lang/src/language/typing/model.ts +++ b/packages/ttsl-lang/src/language/typing/model.ts @@ -2,12 +2,16 @@ import { isEmpty } from '../../helpers/collections.js'; import { TslCallable, TslDeclaration, + TslDictionary, + TslList, TslParameter, TslResult, } from '../generated/ast.js'; import { Parameter } from '../helpers/nodeProperties.js'; -import { NullConstant } from '../partialEvaluation/model.js'; import { SafeDsServices } from '../safe-ds-module.js'; +import { SafeDsCoreTypes } from './safe-ds-core-types.js'; +import { SafeDsTypeChecker } from './safe-ds-type-checker.js'; +import { SafeDsTypeComputer } from './safe-ds-type-computer.js'; import { SafeDsTypeFactory } from './safe-ds-type-factory.js'; export type ParameterSubstitutions = Map; @@ -130,11 +134,7 @@ export class CallableType extends Type { } override withExplicitNullability(isExplicitlyNullable: boolean): Type { - if (!isExplicitlyNullable) { - return this; - } - - return this.factory.createUnionType(this, this.factory.createLiteralType(NullConstant)); + return this; } } @@ -213,11 +213,7 @@ export class NamedTupleType extends Type { } override withExplicitNullability(isExplicitlyNullable: boolean): Type { - if (!isExplicitlyNullable) { - return this; - } - - return this.factory.createUnionType(this, this.factory.createLiteralType(NullConstant)); + return this; } } @@ -258,6 +254,132 @@ export class NamedTupleEntry { } } +export class UnionType extends Type { + private readonly coreTypes: SafeDsCoreTypes; + private readonly factory: SafeDsTypeFactory; + private readonly typeChecker: SafeDsTypeChecker; + + readonly types: Type[]; + private _isExplicitlyNullable: boolean | undefined; + private _isFullySubstituted: boolean | undefined; + + constructor(services: SafeDsServices, types: Type[]) { + super(); + + this.coreTypes = services.types.CoreTypes; + this.factory = services.types.TypeFactory; + this.typeChecker = services.types.TypeChecker; + + this.types = types; + } + + override get isExplicitlyNullable(): boolean { + if (this._isExplicitlyNullable === undefined) { + this._isExplicitlyNullable = this.types.some((it) => it.isExplicitlyNullable); + } + + return this._isExplicitlyNullable; + } + + override get isFullySubstituted(): boolean { + if (this._isFullySubstituted === undefined) { + this._isFullySubstituted = this.types.every((it) => it.isFullySubstituted); + } + + return this._isFullySubstituted; + } + + override equals(other: unknown): boolean { + if (other === this) { + return true; + } else if (!(other instanceof UnionType)) { + return false; + } + + return this.types.length === other.types.length && this.types.every((type, i) => type.equals(other.types[i])); + } + + override toString(): string { + return `union<${this.types.join(', ')}>`; + } + + override simplify(): Type { + // Handle empty union types + if (isEmpty(this.types)) { + return this.coreTypes.Nothing; + } + + // Flatten nested unions + const newTypes = this.types.flatMap((type) => { + const unwrappedType = type.simplify(); + if (unwrappedType instanceof UnionType) { + return unwrappedType.types; + } else { + return unwrappedType; + } + }); + + // Merge literal types and remove types that are subtypes of others. We do this back-to-front to keep the first + // occurrence of duplicate types. It's also makes splicing easier. + for (let i = newTypes.length - 1; i >= 0; i--) { + const currentType = newTypes[i]!; + const currentTypeIsNothingOrNull = currentType.equals(this.coreTypes.NothingOrNull); + + for (let j = newTypes.length - 1; j >= 0; j--) { + if (i === j) { + continue; + } + + const otherType = newTypes[j]!; + + // Remove identical types + if (currentType.equals(otherType)) { + // Remove the current type + newTypes.splice(i, 1); + break; + } + + // Don't merge `Nothing?` into callable types, named tuple types or static types, since that would + // create another union type. + if ( + currentTypeIsNothingOrNull && + (otherType instanceof CallableType || + otherType instanceof NamedTupleType) + ) { + continue; + } + + + // Remove subtypes of other types + const candidateType = otherType.withExplicitNullability( + currentType.isExplicitlyNullable || otherType.isExplicitlyNullable, + ); + if (this.typeChecker.isSupertypeOf(candidateType, currentType)) { + // Replace the other type with the candidate type (updated nullability) + newTypes.splice(j, 1, candidateType); + // Remove the current type + newTypes.splice(i, 1); + break; + } + } + } + + if (newTypes.length === 1) { + return newTypes[0]!; + } else { + return this.factory.createUnionType(newTypes); + } + } + + override substituteTypeParameters(_substitutions: ParameterSubstitutions): Type { + return this; + } + + override withExplicitNullability(_isExplicitlyNullable: boolean): Type { + return this; + } +} + class UnknownTypeClass extends Type { override readonly isExplicitlyNullable = false; override readonly isFullySubstituted = true; @@ -283,4 +405,144 @@ class UnknownTypeClass extends Type { } } +export class DictionaryType extends Type { + private readonly factory: SafeDsTypeFactory; + override readonly isFullySubstituted = true; + private readonly typeComputer: SafeDsTypeComputer; + + override isExplicitlyNullable: boolean = false; + + constructor( + services: SafeDsServices, + readonly dictionary: TslDictionary + ) { + super(); + + this.factory = services.types.TypeFactory; + this.typeComputer = services.types.TypeComputer; + } + + /** + * Returns the type of the parameter at the given index. If the index is out of bounds, returns `undefined`. + */ + getKeyTypeByIndex(index: number): Type { + let entryAtIndex = this.dictionary.entries.at(index) + + return this.typeComputer.computeType(entryAtIndex?.key); + } + + getValueTypeByIndex(index: number): Type { + let entryAtIndex = this.dictionary.entries.at(index) + + return this.typeComputer.computeType(entryAtIndex?.value); + } + + override equals(other: unknown): boolean { + if (other === this) { + return true; + } else if (!(other instanceof DictionaryType)) { + return false; + } + + return ( + other.dictionary === this.dictionary + ); + } + + override toString(): string { + const entries = this.dictionary.entries + .map((it) => `{${it.key}:${it.value}}`) + .join(', '); + + return `[${entries}]`; + } + + override simplify(): DictionaryType { + return this.factory.createDictionaryType( + this.dictionary + ); + } + + override substituteTypeParameters(substitutions: ParameterSubstitutions): DictionaryType { + if (isEmpty(substitutions) || this.isFullySubstituted) { + return this; + } + + return this.factory.createDictionaryType( + this.dictionary + ); + } + + override withExplicitNullability(isExplicitlyNullable: boolean): Type { + return this; + } +} + +export class ListType extends Type { + private readonly factory: SafeDsTypeFactory; + override readonly isFullySubstituted = true; + private readonly typeComputer: SafeDsTypeComputer; + + override isExplicitlyNullable: boolean = false; + + constructor( + services: SafeDsServices, + readonly list: TslList + ) { + super(); + + this.factory = services.types.TypeFactory; + this.typeComputer = services.types.TypeComputer; + } + + /** + * Returns the type of the parameter at the given index. If the index is out of bounds, returns `undefined`. + */ + getValueTypeByIndex(index: number): Type { + let entryAtIndex = this.list.elements.at(index) + + return this.typeComputer.computeType(entryAtIndex); + } + + override equals(other: unknown): boolean { + if (other === this) { + return true; + } else if (!(other instanceof ListType)) { + return false; + } + + return ( + other.list === this.list + ); + } + + override toString(): string { + const entries = this.list.elements + .map((it) => `${it}`) + .join(', '); + + return `[${entries}]`; + } + + override simplify(): ListType { + return this.factory.createListType( + this.list + ); + } + + override substituteTypeParameters(substitutions: ParameterSubstitutions): ListType { + if (isEmpty(substitutions) || this.isFullySubstituted) { + return this; + } + + return this.factory.createListType( + this.list + ); + } + + override withExplicitNullability(isExplicitlyNullable: boolean): Type { + return this; + } +} + export const UnknownType = new UnknownTypeClass(); diff --git a/packages/ttsl-lang/src/language/typing/safe-ds-type-factory.ts b/packages/ttsl-lang/src/language/typing/safe-ds-type-factory.ts index 1d94496c..f7de1d70 100644 --- a/packages/ttsl-lang/src/language/typing/safe-ds-type-factory.ts +++ b/packages/ttsl-lang/src/language/typing/safe-ds-type-factory.ts @@ -1,29 +1,20 @@ import { SafeDsServices } from '../safe-ds-module.js'; import { CallableType, - ClassType, - EnumType, - EnumVariantType, - LiteralType, + DictionaryType, + ListType, NamedTupleEntry, NamedTupleType, - NamedType, - StaticType, Type, - TypeParameterSubstitutions, - TypeParameterType, UnionType, } from './model.js'; -import { Constant } from '../partialEvaluation/model.js'; import { - TslAbstractResult, TslCallable, - TslClass, TslDeclaration, - TslEnum, - TslEnumVariant, + TslDictionary, + TslList, TslParameter, - TslTypeParameter, + TslResult, } from '../generated/ast.js'; export class SafeDsTypeFactory { @@ -33,44 +24,30 @@ export class SafeDsTypeFactory { callable: TslCallable, parameter: TslParameter | undefined, inputType: NamedTupleType, - outputType: NamedTupleType, + outputType: NamedTupleType, ): CallableType { return new CallableType(this.services, callable, parameter, inputType, outputType); } - createClassType( - declaration: TslClass, - substitutions: TypeParameterSubstitutions, - isExplicitlyNullable: boolean, - ): ClassType { - return new ClassType(declaration, substitutions, isExplicitlyNullable); - } - - createEnumType(declaration: TslEnum, isExplicitlyNullable: boolean): EnumType { - return new EnumType(declaration, isExplicitlyNullable); - } - - createEnumVariantType(declaration: TslEnumVariant, isExplicitlyNullable: boolean): EnumVariantType { - return new EnumVariantType(declaration, isExplicitlyNullable); - } - - createLiteralType(...constants: Constant[]): LiteralType { - return new LiteralType(this.services, constants); - } - createNamedTupleType(...entries: NamedTupleEntry[]): NamedTupleType { return new NamedTupleType(this.services, entries); } - createStaticType(instanceType: NamedType): StaticType { - return new StaticType(this.services, instanceType); + createUnionType( + types: Type[] + ): UnionType { + return new UnionType(this.services, types) } - createTypeParameterType(declaration: TslTypeParameter, isExplicitlyNullable: boolean): TypeParameterType { - return new TypeParameterType(declaration, isExplicitlyNullable); + createDictionaryType( + dictionary: TslDictionary, + ): DictionaryType { + return new DictionaryType(this.services, dictionary); } - createUnionType(...types: Type[]): UnionType { - return new UnionType(this.services, types); + createListType( + list: TslList, + ): ListType { + return new ListType(this.services, list); } } From a4ef7c693c926d66d8944acb6c5cfc138c2842d4 Mon Sep 17 00:00:00 2001 From: methr0 Date: Mon, 1 Jul 2024 13:41:27 +0200 Subject: [PATCH 102/183] remove unnecessary Code in type computer --- .../language/typing/safe-ds-type-computer.ts | 1235 +---------------- .../src/language/validation/types.ts | 5 +- 2 files changed, 33 insertions(+), 1207 deletions(-) diff --git a/packages/ttsl-lang/src/language/typing/safe-ds-type-computer.ts b/packages/ttsl-lang/src/language/typing/safe-ds-type-computer.ts index f8dcfd58..41e698fc 100644 --- a/packages/ttsl-lang/src/language/typing/safe-ds-type-computer.ts +++ b/packages/ttsl-lang/src/language/typing/safe-ds-type-computer.ts @@ -1,134 +1,76 @@ -import { AstNode, AstNodeLocator, AstUtils, EMPTY_STREAM, Stream, stream, WorkspaceCache } from 'langium'; -import { isEmpty } from '../../helpers/collections.js'; +import { AstNode, AstNodeLocator, AstUtils, WorkspaceCache } from 'langium'; import { - isTslAnnotation, isTslArgument, isTslAssignee, isTslAssignment, - isTslAttribute, - isTslBlockLambda, isTslCall, - isTslCallable, isTslCallableType, - isTslClass, isTslDeclaration, - isTslEnum, - isTslEnumVariant, isTslExpression, - isTslExpressionLambda, isTslFunction, isTslIndexedAccess, isTslInfixOperation, - isTslLambda, isTslList, - isTslLiteralType, isTslDictionary, - isTslMemberAccess, - isTslMemberType, - isTslNamedType, - isTslNamedTypeDeclaration, isTslParameter, - isTslParenthesizedExpression, - isTslPipeline, isTslPrefixOperation, isTslReference, isTslResult, - isTslSchema, - isTslSegment, isTslTemplateString, isTslType, - isTslTypeArgument, isTslTypeCast, - isTslTypeParameter, - isTslUnionType, - isTslYield, - TslAbstractResult, TslAssignee, - type TslBlockLambda, TslCall, TslCallableType, - TslClass, TslDeclaration, TslExpression, - type TslExpressionLambda, TslFunction, TslIndexedAccess, TslInfixOperation, - TslLiteralType, - TslMemberAccess, - TslNamedType, TslParameter, TslPrefixOperation, TslReference, - TslSegment, TslType, - TslTypeArgument, - TslTypeParameter, TslResult, } from '../generated/ast.js'; import { - getArguments, - getAssignees, - getLiterals, getParameters, - getParentTypes, getResults, - getTypeArguments, - getTypeParameters, - streamBlockLambdaResults, - TypeParameter, } from '../helpers/nodeProperties.js'; -import { SafeDsNodeMapper } from '../helpers/safe-ds-node-mapper.js'; import { BooleanConstant, Constant, FloatConstant, IntConstant, - isConstant, NullConstant, StringConstant, } from '../partialEvaluation/model.js'; -import { SafeDsPartialEvaluator } from '../partialEvaluation/safe-ds-partial-evaluator.js'; import { SafeDsServices } from '../safe-ds-module.js'; import { CallableType, - ClassType, - EnumType, - EnumVariantType, - LiteralType, NamedTupleEntry, NamedTupleType, - NamedType, - StaticType, Type, - TypeParameterSubstitutions, - TypeParameterType, - UnionType, + DictionaryType, + ListType, UnknownType, } from './model.js'; import { SafeDsCoreTypes } from './safe-ds-core-types.js'; import type { SafeDsTypeChecker } from './safe-ds-type-checker.js'; -import { SafeDsClasses } from '../builtins/safe-ds-classes.js'; import { SafeDsTypeFactory } from './safe-ds-type-factory.js'; export class SafeDsTypeComputer { private readonly astNodeLocator: AstNodeLocator; - private readonly coreClasses: SafeDsClasses; private readonly coreTypes: SafeDsCoreTypes; private readonly factory: SafeDsTypeFactory; - private readonly nodeMapper: SafeDsNodeMapper; - private readonly partialEvaluator: SafeDsPartialEvaluator; private readonly typeChecker: SafeDsTypeChecker; private readonly nodeTypeCache: WorkspaceCache; constructor(services: SafeDsServices) { this.astNodeLocator = services.workspace.AstNodeLocator; - this.coreClasses = services.builtins.Classes; this.coreTypes = services.types.CoreTypes; this.factory = services.types.TypeFactory; - this.nodeMapper = services.helpers.NodeMapper; - this.partialEvaluator = services.evaluation.PartialEvaluator; this.typeChecker = services.types.TypeChecker; this.nodeTypeCache = new WorkspaceCache(services.shared); @@ -142,7 +84,7 @@ export class SafeDsTypeComputer { * Computes the type of the given node and applies the given substitutions for type parameters. The result gets * simplified as much as possible. */ - computeType(node: AstNode | undefined, substitutions: TypeParameterSubstitutions = NO_SUBSTITUTIONS): Type { + computeType(node: AstNode | undefined): Type { if (!node) { return UnknownType; } @@ -151,15 +93,7 @@ export class SafeDsTypeComputer { const unsubstitutedType = this.nodeTypeCache.get(this.getNodeId(node), () => this.doComputeType(node).simplify(), ); - if (isEmpty(substitutions)) { - return unsubstitutedType; - } - - // Substitute type parameters - const simplifiedSubstitutions = new Map( - [...substitutions].map(([typeParameter, type]) => [typeParameter, type.simplify()]), - ); - return unsubstitutedType.substituteTypeParameters(simplifiedSubstitutions); + return unsubstitutedType; } private getNodeId(node: AstNode) { @@ -177,8 +111,6 @@ export class SafeDsTypeComputer { return this.computeTypeOfExpression(node); } else if (isTslType(node)) { return this.computeTypeOfType(node); - } else if (isTslTypeArgument(node)) { - return this.computeTypeOfType(node.value); } /* c8 ignore start */ else { return UnknownType; } /* c8 ignore stop */ @@ -203,45 +135,18 @@ export class SafeDsTypeComputer { } private computeTypeOfDeclaration(node: TslDeclaration): Type { - if (isTslAnnotation(node)) { - const parameterEntries = getParameters(node).map( - (it) => new NamedTupleEntry(it, it.name, this.computeType(it.type)), - ); - - return this.factory.createCallableType( - node, - undefined, - this.factory.createNamedTupleType(...parameterEntries), - this.factory.createNamedTupleType(), - ); - } else if (isTslAttribute(node)) { - return this.computeType(node.type); - } else if (isTslClass(node)) { - return this.factory.createClassType(node, NO_SUBSTITUTIONS, false); - } else if (isTslEnum(node)) { - return this.factory.createEnumType(node, false); - } else if (isTslEnumVariant(node)) { - return this.factory.createEnumVariantType(node, false); - } else if (isTslFunction(node)) { + if (isTslFunction(node)) { return this.computeTypeOfCallableWithManifestTypes(node); } else if (isTslParameter(node)) { return this.computeTypeOfParameter(node); - } else if (isTslPipeline(node)) { - return UnknownType; } else if (isTslResult(node)) { return this.computeType(node.type); - } else if (isTslSchema(node)) { - return UnknownType; - } else if (isTslSegment(node)) { - return this.computeTypeOfCallableWithManifestTypes(node); - } else if (isTslTypeParameter(node)) { - return this.factory.createTypeParameterType(node, false); } /* c8 ignore start */ else { return UnknownType; } /* c8 ignore stop */ } - private computeTypeOfCallableWithManifestTypes(node: TslFunction | TslSegment | TslCallableType): Type { + private computeTypeOfCallableWithManifestTypes(node: TslFunction | TslCallableType): Type { const parameterEntries = getParameters(node).map( (it) => new NamedTupleEntry(it, it.name, this.computeType(it.type)), ); @@ -249,7 +154,7 @@ export class SafeDsTypeComputer { if(isTslFunction(node)){ resultEntries.with(0, new NamedTupleEntry(node.result, node.name, this.computeType(node.result?.type))) }else{ - resultEntries = getResults(node.resultList).map( + resultEntries = getResults(node).map( (it) => new NamedTupleEntry(it, it.name, this.computeType(it.type)), ); } @@ -265,56 +170,10 @@ export class SafeDsTypeComputer { private computeTypeOfParameter(node: TslParameter): Type { // Manifest type - if (node.type) { - const type = this.computeType(node.type); - return this.rememberParameterInCallableType(node, type); - } - - // Infer type from context - const contextType = this.computeTypeOfParameterContext(node); - if (!(contextType instanceof CallableType)) { - return UnknownType; - } - - const parameterPosition = node.$containerIndex ?? -1; - const type = contextType.getParameterTypeByIndex(parameterPosition); + const type = this.computeType(node.type); return this.rememberParameterInCallableType(node, type); } - private computeTypeOfParameterContext(node: TslParameter): Type { - const containingCallable = AstUtils.getContainerOfType(node, isTslCallable); - if (!isTslLambda(containingCallable)) { - return UnknownType; - } - - const containerOfLambda = containingCallable.$container; - - // Lambda passed as argument - if (isTslArgument(containerOfLambda)) { - const parameter = this.nodeMapper.argumentToParameter(containerOfLambda); - if (!parameter) { - return UnknownType; - } - return this.computeType(parameter?.type); - } - - // Lambda passed as default value - if (isTslParameter(containerOfLambda)) { - return this.computeType(containerOfLambda); - } - - // Yielded lambda - else if (isTslAssignment(containerOfLambda)) { - const firstAssignee = getAssignees(containerOfLambda)[0]; - if (!isTslYield(firstAssignee)) { - return UnknownType; - } - return this.computeType(firstAssignee.result?.ref); - } - - return UnknownType; - } - private rememberParameterInCallableType(node: TslParameter, type: Type) { if (type instanceof CallableType) { return this.factory.createCallableType(type.callable, node, type.inputType, type.outputType); @@ -329,12 +188,6 @@ export class SafeDsTypeComputer { return this.computeType(node.type); } - // Partial evaluation (definitely handles TslBoolean, TslFloat, TslInt, TslNull, and TslString) - const evaluatedNode = this.partialEvaluator.evaluate(node); - if (evaluatedNode instanceof Constant) { - return this.factory.createLiteralType(evaluatedNode); - } - // Terminal cases if (isTslList(node)) { const elementType = this.lowestCommonSupertype(node.elements.map((it) => this.computeType(it))); @@ -342,12 +195,6 @@ export class SafeDsTypeComputer { } else if (isTslDictionary(node)) { let keyType = this.lowestCommonSupertype(node.entries.map((it) => this.computeType(it.key))); - // Keeping literal types for keys is too strict: We would otherwise infer the key type of `{"a": 1, "b": 2}` - // as `Literal<"a", "b">`. But then we would be unable to pass an unknown `String` as the key in an indexed - // access. Where possible, we already validate the existence of keys in indexed accesses using the partial - // evaluator. - keyType = this.computeClassTypeForLiteralType(keyType); - const valueType = this.lowestCommonSupertype(node.entries.map((it) => this.computeType(it.value))); return this.coreTypes.Map(keyType, valueType); } else if (isTslTemplateString(node)) { @@ -357,12 +204,8 @@ export class SafeDsTypeComputer { // Recursive cases else if (isTslArgument(node)) { return this.computeType(node.value); - } else if (isTslBlockLambda(node)) { - return this.computeTypeOfBlockLambda(node); } else if (isTslCall(node)) { return this.computeTypeOfCall(node); - } else if (isTslExpressionLambda(node)) { - return this.computeTypeOfExpressionLambda(node); } else if (isTslIndexedAccess(node)) { return this.computeTypeOfIndexedAccess(node); } else if (isTslInfixOperation(node)) { @@ -402,10 +245,6 @@ export class SafeDsTypeComputer { default: return UnknownType; } - } else if (isTslMemberAccess(node)) { - return this.computeTypeOfMemberAccess(node); - } else if (isTslParenthesizedExpression(node)) { - return this.computeType(node.expression); } else if (isTslPrefixOperation(node)) { switch (node.operator) { case 'not': @@ -425,52 +264,17 @@ export class SafeDsTypeComputer { } /* c8 ignore stop */ } - private computeTypeOfBlockLambda(node: TslBlockLambda): Type { - const parameterEntries = getParameters(node).map( - (it) => new NamedTupleEntry(it, it.name, this.computeType(it)), - ); - const resultEntries = streamBlockLambdaResults(node) - .map((it) => new NamedTupleEntry(it, it.name, this.computeType(it))) - .toArray(); - - return this.factory.createCallableType( - node, - undefined, - this.factory.createNamedTupleType(...parameterEntries), - this.factory.createNamedTupleType(...resultEntries), - ); - } - private computeTypeOfCall(node: TslCall): Type { const receiverType = this.computeType(node.receiver); const nonNullableReceiverType = this.computeNonNullableType(receiverType); let result: Type = UnknownType; if (nonNullableReceiverType instanceof CallableType) { - if (!isTslAnnotation(nonNullableReceiverType.callable)) { - result = nonNullableReceiverType.outputType; - } - + result = nonNullableReceiverType.outputType; + // Substitute type parameters if (isTslFunction(nonNullableReceiverType.callable)) { - const substitutions = this.computeSubstitutionsForCall(node); - result = result.substituteTypeParameters(substitutions); - } - } else if (nonNullableReceiverType instanceof StaticType) { - const instanceType = nonNullableReceiverType.instanceType; - if (isTslCallable(instanceType.declaration)) { - result = instanceType; - } - - // Substitute type parameters - if (instanceType instanceof ClassType) { - const substitutions = this.computeSubstitutionsForCall(node); - - result = this.factory.createClassType( - instanceType.declaration, - substitutions, - instanceType.isExplicitlyNullable, - ); + result = receiverType } } @@ -478,42 +282,24 @@ export class SafeDsTypeComputer { return result.withExplicitNullability(receiverType.isExplicitlyNullable && node.isNullSafe); } - private computeTypeOfExpressionLambda(node: TslExpressionLambda): Type { - const parameterEntries = getParameters(node).map( - (it) => new NamedTupleEntry(it, it.name, this.computeType(it)), - ); - const resultEntries = [ - new NamedTupleEntry(undefined, 'result', this.computeType(node.result)), - ]; - - return this.factory.createCallableType( - node, - undefined, - this.factory.createNamedTupleType(...parameterEntries), - this.factory.createNamedTupleType(...resultEntries), - ); - } - private computeTypeOfIndexedAccess(node: TslIndexedAccess): Type { const receiverType = this.computeType(node.receiver); - if (!(receiverType instanceof ClassType) && !(receiverType instanceof TypeParameterType)) { + if (!(receiverType instanceof ListType) && !(receiverType instanceof DictionaryType)) { return UnknownType; } // Receiver is a list - const listType = this.computeMatchingSupertype(receiverType, this.coreClasses.List); - if (listType) { - return listType - .getTypeParameterTypeByIndex(0) - .withExplicitNullability(listType.isExplicitlyNullable && node.isNullSafe); + if (receiverType instanceof ListType) { + return receiverType + .getValueTypeByIndex(0) + .withExplicitNullability(receiverType.isExplicitlyNullable && node.isNullSafe); } - // Receiver is a map - const mapType = this.computeMatchingSupertype(receiverType, this.coreClasses.Map); - if (mapType) { - return mapType - .getTypeParameterTypeByIndex(1) - .withExplicitNullability(mapType.isExplicitlyNullable && node.isNullSafe); + // Receiver is a Dictionary + if (receiverType instanceof DictionaryType) { + return receiverType + .getValueTypeByIndex(1) + .withExplicitNullability(receiverType.isExplicitlyNullable && node.isNullSafe); } return UnknownType; @@ -537,43 +323,12 @@ export class SafeDsTypeComputer { const leftOperandType = this.computeType(node.leftOperand); if (leftOperandType.isExplicitlyNullable) { const rightOperandType = this.computeType(node.rightOperand); - return this.lowestCommonSupertype([leftOperandType.withExplicitNullability(false), rightOperandType]); + return rightOperandType; } else { return leftOperandType; } } - private computeTypeOfMemberAccess(node: TslMemberAccess) { - const memberType = this.computeType(node.member); - - // A member access of an enum variant without parameters always yields an instance, even if it is not in a call - if (memberType instanceof StaticType && !isTslCall(node.$container)) { - const instanceType = memberType.instanceType; - - if (instanceType instanceof EnumVariantType && isEmpty(getParameters(instanceType.declaration))) { - return instanceType; - } - } - - const receiverType = this.computeType(node.receiver); - let result: Type = memberType; - - // Substitute type parameters (must also work for inherited members) - if (receiverType instanceof ClassType) { - const classContainingMember = AstUtils.getContainerOfType(node.member?.target.ref, isTslClass); - const typeContainingMember = this.computeMatchingSupertype(receiverType, classContainingMember); - - if (typeContainingMember) { - result = result.substituteTypeParameters(typeContainingMember.substitutions); - } - } - - // Update nullability - return result.withExplicitNullability( - (receiverType.isExplicitlyNullable && node.isNullSafe) || result.isExplicitlyNullable, - ); - } - private computeTypeOfArithmeticPrefixOperation(node: TslPrefixOperation): Type { const operandType = this.computeType(node.operand); @@ -588,81 +343,17 @@ export class SafeDsTypeComputer { const target = node.target.ref; const instanceType = this.computeType(target); - if (isTslNamedTypeDeclaration(target) && instanceType instanceof NamedType) { - return this.factory.createStaticType(instanceType.withExplicitNullability(false)); - } else { - return instanceType; - } + return instanceType; } private computeTypeOfType(node: TslType): Type { if (isTslCallableType(node)) { return this.computeTypeOfCallableWithManifestTypes(node); - } else if (isTslLiteralType(node)) { - return this.computeTypeOfLiteralType(node); - } else if (isTslMemberType(node)) { - return this.computeType(node.member); - } else if (isTslNamedType(node)) { - return this.computeTypeOfNamedType(node); - } else if (isTslUnionType(node)) { - const typeArguments = getTypeArguments(node.typeArgumentList); - return this.factory.createUnionType( - ...typeArguments.map((typeArgument) => this.computeType(typeArgument.value)), - ); } /* c8 ignore start */ else { return UnknownType; } /* c8 ignore stop */ } - private computeTypeOfLiteralType(node: TslLiteralType): Type { - const constants = getLiterals(node).map((it) => this.partialEvaluator.evaluate(it)); - if (constants.every(isConstant)) { - return this.factory.createLiteralType(...constants); - } /* c8 ignore start */ else { - return UnknownType; - } /* c8 ignore stop */ - } - - private computeTypeOfNamedType(node: TslNamedType) { - const unparameterizedType = this.computeType(node.declaration?.ref).withExplicitNullability(node.isNullable); - if (!(unparameterizedType instanceof ClassType)) { - return unparameterizedType; - } - - const substitutions = this.computeTypeParameterSubstitutionsForNamedType(node, unparameterizedType.declaration); - return this.factory.createClassType(unparameterizedType.declaration, substitutions, node.isNullable); - } - - private computeTypeParameterSubstitutionsForNamedType( - node: TslNamedType, - clazz: TslClass, - ): TypeParameterSubstitutions { - const typeParameters = getTypeParameters(clazz); - if (isEmpty(typeParameters)) { - return NO_SUBSTITUTIONS; - } - - // Map type parameters to the first type argument that sets it - const typeArgumentsByTypeParameters = new Map(); - for (const typeArgument of getTypeArguments(node)) { - const typeParameter = this.nodeMapper.typeArgumentToTypeParameter(typeArgument); - if (typeParameter && !typeArgumentsByTypeParameters.has(typeParameter)) { - typeArgumentsByTypeParameters.set(typeParameter, typeArgument); - } - } - - // Compute substitutions (ordered by the position of the type parameters) - const result = new Map(); - - for (const typeParameter of typeParameters) { - const typeArgument = typeArgumentsByTypeParameters.get(typeParameter); - const type = this.computeType(typeArgument?.value ?? typeParameter.defaultValue); - result.set(typeParameter, type); - } - - return result; - } - // ----------------------------------------------------------------------------------------------------------------- // Various type conversions // ----------------------------------------------------------------------------------------------------------------- @@ -674,18 +365,6 @@ export class SafeDsTypeComputer { return type.withExplicitNullability(false).simplify(); } - /** - * Returns the lowest class type for the given literal type. If the given type is not a literal type, it is returned - * as is. - */ - computeClassTypeForLiteralType(type: Type): Type { - if (!(type instanceof LiteralType)) { - return type; - } - - return this.lowestCommonSupertype(type.constants.map((it) => this.computeClassTypeForConstant(it))); - } - /** * Returns the lowest class type for the given constant. */ @@ -705,307 +384,7 @@ export class SafeDsTypeComputer { } /* c8 ignore stop */ } - computeCallableTypeForStaticType(type: StaticType): Type { - const instanceType = type.instanceType; - if (instanceType instanceof ClassType) { - const declaration = instanceType.declaration; - if (!declaration.parameterList) { - return UnknownType; - } - - const parameterEntries = this.factory.createNamedTupleType( - ...getParameters(declaration).map((it) => new NamedTupleEntry(it, it.name, this.computeType(it))), - ); - const resultEntries = this.factory.createNamedTupleType( - new NamedTupleEntry(undefined, 'instance', instanceType), - ); - - return this.factory.createCallableType(declaration, undefined, parameterEntries, resultEntries); - } else if (instanceType instanceof EnumVariantType) { - const declaration = instanceType.declaration; - - const parameterEntries = this.factory.createNamedTupleType( - ...getParameters(declaration).map((it) => new NamedTupleEntry(it, it.name, this.computeType(it))), - ); - const resultEntries = this.factory.createNamedTupleType( - new NamedTupleEntry(undefined, 'instance', instanceType), - ); - - return this.factory.createCallableType(declaration, undefined, parameterEntries, resultEntries); - } else { - return UnknownType; - } - } - - // ----------------------------------------------------------------------------------------------------------------- - // Type parameter bounds - // ----------------------------------------------------------------------------------------------------------------- - - /** - * Returns the upper bound for the given input. If no upper bound is specified explicitly, the result is `Any?`. If - * invalid upper bounds are specified, but are invalid (e.g. because of an unresolved reference or a cycle), - * `$unknown` is returned. The result is simplified as much as possible. - */ - computeUpperBound(nodeOrType: TslTypeParameter | TypeParameterType, options: ComputeUpperBoundOptions = {}): Type { - let type: TypeParameterType; - if (nodeOrType instanceof TypeParameterType) { - type = nodeOrType; - } else { - type = this.computeType(nodeOrType) as TypeParameterType; - } - - const result = this.doComputeUpperBound(type, options); - return result.withExplicitNullability(result.isExplicitlyNullable || type.isExplicitlyNullable); - } - - private doComputeUpperBound(type: TypeParameterType, options: ComputeUpperBoundOptions): Type { - const upperBound = type.declaration.upperBound; - if (!upperBound) { - return this.coreTypes.AnyOrNull; - } - - const boundType = this.computeType(upperBound); - if (!(boundType instanceof NamedType)) { - return UnknownType; - } else if (options.stopAtTypeParameterType || !(boundType instanceof TypeParameterType)) { - return boundType; - } else { - return this.doComputeUpperBound(boundType, options); - } - } - - // ----------------------------------------------------------------------------------------------------------------- - // Type parameter substitutions - // ----------------------------------------------------------------------------------------------------------------- - - /** - * Computes substitutions for the type parameters of a callable in the context of a call. - * - * @param call The call to compute substitutions for. - * @returns The computed substitutions for the type parameters of the callable. - */ - computeSubstitutionsForCall(call: TslCall): TypeParameterSubstitutions { - const callable = this.nodeMapper.callToCallable(call); - const typeParameters = getTypeParameters(callable); - if (isEmpty(typeParameters)) { - return NO_SUBSTITUTIONS; - } - - const parameters = getParameters(callable); - const args = getArguments(call); - - const parametersToArguments = this.nodeMapper.parametersToArguments(parameters, args); - const parameterTypesToArgumentTypes: [Type, Type][] = parameters.map((parameter) => { - const argument = parametersToArguments.get(parameter); - return [this.computeType(parameter.type), this.computeType(argument?.value ?? parameter.defaultValue)]; - }); - - return this.computeTypeParameterSubstitutionsForArguments(typeParameters, parameterTypesToArgumentTypes); - } - - /** - * Computes substitutions for the type parameters of a callable in the context of overriding another callable. - * - * @param ownMemberType The type of the overriding callable. - * @param overriddenMemberType The type of the overridden callable. - */ - computeSubstitutionsForOverriding(ownMemberType: Type, overriddenMemberType: Type): TypeParameterSubstitutions { - if (!(ownMemberType instanceof CallableType) || !(overriddenMemberType instanceof CallableType)) { - return NO_SUBSTITUTIONS; - } - - const ownTypeParameters = getTypeParameters(ownMemberType.callable); - if (isEmpty(ownTypeParameters)) { - return NO_SUBSTITUTIONS; - } - - const ownParameterTypes = ownMemberType.inputType.entries.map((it) => it.type); - const overriddenParameterTypes = overriddenMemberType.inputType.entries.map((it) => it.type); - - const minimumParameterCount = Math.min(ownParameterTypes.length, overriddenParameterTypes.length); - const ownTypesToOverriddenTypes: [Type, Type][] = []; - - for (let i = 0; i < minimumParameterCount; i++) { - ownTypesToOverriddenTypes.push([ownParameterTypes[i]!, overriddenParameterTypes[i]!]); - } - - return this.computeTypeParameterSubstitutionsForArguments(ownTypeParameters, ownTypesToOverriddenTypes); - } - - /** - * Computes substitutions for the given type parameters in a list of parameter types based on the corresponding - * argument types. - * - * @param typeParameters The type parameters to compute substitutions for. - * @param parameterTypesToArgumentTypes Pairs of parameter types and the corresponding argument types. - * @returns The computed substitutions for the type parameters in the parameter types. - */ - private computeTypeParameterSubstitutionsForArguments( - typeParameters: TslTypeParameter[], - parameterTypesToArgumentTypes: [Type, Type][], - ): TypeParameterSubstitutions { - // Build initial state - const state: ComputeTypeParameterSubstitutionsForParametersState = { - substitutions: new Map(typeParameters.map((it) => [it, UnknownType])), - remainingVariances: new Map(typeParameters.map((it) => [it, 'bivariant'])), - }; - - // Compute substitutions - for (const [parameterType, argumentType] of parameterTypesToArgumentTypes) { - this.computeTypeParameterSubstitutionsForParameter(parameterType, argumentType, 'covariant', state); - } - - // Normalize substitutions - for (const [typeParameter, substitution] of state.substitutions) { - let newSubstitution = substitution; - - // Replace unknown types by default values or lower bound (Nothing) - if (newSubstitution === UnknownType) { - const defaultValueType = this.computeType(typeParameter.defaultValue); - if (defaultValueType === UnknownType) { - state.substitutions.set(typeParameter, this.coreTypes.Nothing); - continue; - } else { - newSubstitution = defaultValueType; - } - } - - // Clamp to upper bound - const upperBound = this.computeUpperBound(typeParameter, { - stopAtTypeParameterType: true, - }).substituteTypeParameters(state.substitutions); - - if (!this.typeChecker.isSubtypeOf(newSubstitution, upperBound)) { - newSubstitution = upperBound; - } - - state.substitutions.set(typeParameter, newSubstitution); - } - - return state.substitutions; - } - - private computeTypeParameterSubstitutionsForParameter( - parameterType: Type, - argumentType: Type, - currentVariance: Variance, - state: ComputeTypeParameterSubstitutionsForParametersState, - ) { - if (argumentType instanceof TypeParameterType && state.substitutions.has(argumentType.declaration)) { - // Can happen for lambdas without manifest parameter types. We gain no information here. - return; - } else if (parameterType instanceof CallableType && argumentType instanceof CallableType) { - // Compare parameters - const parameterTypeParameters = parameterType.inputType.entries; - const argumentTypeParameters = argumentType.inputType.entries; - const minParametersLength = Math.min(parameterTypeParameters.length, argumentTypeParameters.length); - for (let i = 0; i < minParametersLength; i++) { - const parameterEntry = parameterTypeParameters[i]!; - const argumentEntry = argumentTypeParameters[i]!; - this.computeTypeParameterSubstitutionsForParameter( - parameterEntry.type, - argumentEntry.type, - this.flippedVariance(currentVariance), - state, - ); - } - - // Compare results - const parameterTypeResults = parameterType.outputType.entries; - const argumentTypeResults = argumentType.outputType.entries; - const minResultsLength = Math.min(parameterTypeResults.length, argumentTypeResults.length); - for (let i = 0; i < minResultsLength; i++) { - const parameterEntry = parameterTypeResults[i]!; - const argumentEntry = argumentTypeResults[i]!; - this.computeTypeParameterSubstitutionsForParameter( - parameterEntry.type, - argumentEntry.type, - currentVariance, - state, - ); - } - } else if (parameterType instanceof CallableType && argumentType instanceof StaticType) { - if (currentVariance === 'covariant') { - const callableArgumentType = this.computeCallableTypeForStaticType(argumentType); - this.computeTypeParameterSubstitutionsForParameter( - parameterType, - callableArgumentType, - currentVariance, - state, - ); - } - } else if (parameterType instanceof ClassType && argumentType instanceof ClassType) { - let matchingParameterType: ClassType | undefined = parameterType; - let matchingArgumentType: ClassType | undefined = argumentType; - - if (currentVariance === 'covariant') { - matchingArgumentType = this.computeMatchingSupertype(argumentType, parameterType.declaration); - } else if (currentVariance === 'contravariant') { - matchingParameterType = this.computeMatchingSupertype(parameterType, argumentType.declaration); - } - - if (!matchingParameterType || !matchingArgumentType) { - /* c8 ignore next 2 */ - return; - } - - const parameterTypeParameters = getTypeParameters(parameterType.declaration); - for (const typeParameter of parameterTypeParameters) { - const argumentTypeSubstitutions = matchingParameterType.substitutions.get(typeParameter); - const parameterTypeSubstitutions = matchingArgumentType.substitutions.get(typeParameter); - if (!argumentTypeSubstitutions || !parameterTypeSubstitutions) { - /* c8 ignore next 2 */ - continue; - } - - if (TypeParameter.isCovariant(typeParameter)) { - this.computeTypeParameterSubstitutionsForParameter( - argumentTypeSubstitutions, - parameterTypeSubstitutions, - currentVariance, - state, - ); - } else if (TypeParameter.isContravariant(typeParameter)) { - this.computeTypeParameterSubstitutionsForParameter( - argumentTypeSubstitutions, - parameterTypeSubstitutions, - this.flippedVariance(currentVariance), - state, - ); - } - } - } else if (parameterType instanceof TypeParameterType) { - const currentSubstitution = state.substitutions.get(parameterType.declaration); - const remainingVariance = state.remainingVariances.get(parameterType.declaration); - if (!currentSubstitution) { - /* c8 ignore next 2 */ - return; - } - - if (remainingVariance === 'bivariant') { - state.substitutions.set(parameterType.declaration, argumentType); - state.remainingVariances.set(parameterType.declaration, currentVariance); - } else if (remainingVariance === 'covariant' && currentVariance === 'covariant') { - const lowestCommonSupertype = this.lowestCommonSupertype([currentSubstitution, argumentType]); - state.substitutions.set(parameterType.declaration, lowestCommonSupertype); - } else if (remainingVariance === 'contravariant' && currentVariance === 'contravariant') { - const highestCommonSubtype = this.highestCommonSubtype([currentSubstitution, argumentType]); - state.substitutions.set(parameterType.declaration, highestCommonSubtype); - } - } - } - - private flippedVariance(variance: Variance): Variance { - if (variance === 'covariant') { - return 'contravariant'; - } /* c8 ignore start */ else if (variance === 'contravariant') { - return 'covariant'; - } else { - return variance; - } /* c8 ignore stop */ - } - - // ----------------------------------------------------------------------------------------------------------------- +// ----------------------------------------------------------------------------------------------------------------- // Lowest common supertype // ----------------------------------------------------------------------------------------------------------------- @@ -1021,11 +400,8 @@ export class SafeDsTypeComputer { return simplifiedTypes[0]!; } - // Replace type parameter types by their upper bound - const replacedTypes = this.replaceTypeParameterTypesWithUpperBound(simplifiedTypes); - // Partition types by their kind - const partitionedTypes = this.partitionTypesLCS(replacedTypes); + const partitionedTypes = this.partitionTypesLCS(simplifiedTypes); // Includes unknown type if (partitionedTypes.containsUnknownType) { @@ -1033,31 +409,17 @@ export class SafeDsTypeComputer { } // The result must be nullable if any of the types is nullable - const isNullable = replacedTypes.some((it) => it.isExplicitlyNullable); + const isNullable = simplifiedTypes.some((it) => it.isExplicitlyNullable); // Includes unhandled type if (partitionedTypes.containsOtherType) { return this.Any(isNullable); } - // Class-based types - if (!isEmpty(partitionedTypes.classTypes)) { - if (!isEmpty(partitionedTypes.enumTypes) || !isEmpty(partitionedTypes.enumVariantTypes)) { - // Class types other than Any/Any? are never compatible to enum types/enum variant types - return this.Any(isNullable); - } else { - return this.lowestCommonSupertypeForClassBasedTypes(partitionedTypes.classTypes, isNullable); - } - } - - // Enum-based types - return this.lowestCommonSupertypeForEnumBasedTypes( - partitionedTypes.enumTypes, - partitionedTypes.enumVariantTypes, - isNullable, - ); + return UnknownType } + /** * Simplifies a list of types for the purpose of computing the lowest common supertype (LCS). */ @@ -1066,23 +428,9 @@ export class SafeDsTypeComputer { return types; } - const simplifiedType = this.factory.createUnionType(...types).simplify(); + const simplifiedType = this.factory.createUnionType(types).simplify(); - if (simplifiedType instanceof UnionType) { - return simplifiedType.types; - } else { - return [simplifiedType]; - } - } - - private replaceTypeParameterTypesWithUpperBound(simplifiedTypes: Type[]) { - return simplifiedTypes.map((it) => { - if (it instanceof TypeParameterType) { - return this.computeUpperBound(it); - } else { - return it; - } - }); + return [simplifiedType]; } /** @@ -1091,9 +439,6 @@ export class SafeDsTypeComputer { */ private partitionTypesLCS(types: Type[]): PartitionTypesLCSResult { const result: PartitionTypesLCSResult = { - classTypes: [], - enumTypes: [], - enumVariantTypes: [], containsUnknownType: false, containsOtherType: false, }; @@ -1101,20 +446,6 @@ export class SafeDsTypeComputer { for (const type of types) { if (type.equals(this.coreTypes.Nothing) || type.equals(this.coreTypes.NothingOrNull)) { // Drop Nothing/Nothing? types. They are compatible to everything with appropriate nullability. - } else if (type instanceof ClassType) { - result.classTypes.push(type); - } else if (type instanceof EnumType) { - result.enumTypes.push(type); - } else if (type instanceof EnumVariantType) { - result.enumVariantTypes.push(type); - } else if (type instanceof LiteralType) { - const classType = this.computeClassTypeForLiteralType(type); - if (classType instanceof ClassType) { - result.classTypes.push(classType); - } else { - /* c8 ignore next 2 */ - result.containsUnknownType = true; - } } else if (type === UnknownType) { result.containsUnknownType = true; } else { @@ -1127,452 +458,6 @@ export class SafeDsTypeComputer { return result; } - /** - * Returns the lowest common supertype for the given class-based types. - */ - private lowestCommonSupertypeForClassBasedTypes(classTypes: ClassType[], isNullable: boolean): Type { - if (isEmpty(classTypes)) { - /* c8 ignore next 2 */ - return this.Nothing(isNullable); - } - - // Find the class type that is compatible to all other types - const firstClassType = classTypes[0]!.withExplicitNullability(isNullable); - const candidates = [firstClassType, ...this.streamProperSupertypes(firstClassType)]; - let others = [...classTypes.slice(1)]; - - for (const candidate of candidates) { - if (this.isCommonSupertypeIgnoringTypeParameters(candidate, others)) { - // If the class has no type parameters, we are done - const typeParameters = getTypeParameters(candidate.declaration); - if (isEmpty(typeParameters)) { - return candidate; - } - - // Lift all types to a common class - others = others.map((it) => this.computeMatchingSupertype(it, candidate.declaration)!); - - // Check whether all substitutions of invariant type parameters are equal - if (!this.substitutionsForInvariantTypeParametersAreEqual(typeParameters, candidate, others)) { - continue; - } - - // Unify substitutions for type parameters - const substitutions = this.newTypeParameterSubstitutionsLCS(typeParameters, candidate, others); - return this.factory.createClassType(candidate.declaration, substitutions, isNullable); - } - } - /* c8 ignore next */ - return this.Any(isNullable); - } - - private substitutionsForInvariantTypeParametersAreEqual( - allTypeParameters: TslTypeParameter[], - candidate: ClassType, - others: ClassType[], - ): boolean { - return allTypeParameters.filter(TypeParameter.isInvariant).every((typeParameter) => { - const candidateSubstitution = candidate.substitutions.get(typeParameter); - return ( - candidateSubstitution && - others.every((other) => { - const otherSubstitution = other.substitutions.get(typeParameter); - return otherSubstitution && candidateSubstitution.equals(otherSubstitution); - }) - ); - }); - } - - private newTypeParameterSubstitutionsLCS( - typeParameters: TslTypeParameter[], - candidate: ClassType, - others: ClassType[], - ): TypeParameterSubstitutions { - const covariantUnifier = (types: Type[]) => - this.lowestCommonSupertype(types, { - skipTypeSimplification: true, - }); - const contravariantUnifier = (types: Type[]) => this.highestCommonSubtype(types); - - return this.newTypeParameterSubstitutions( - typeParameters, - candidate, - others, - covariantUnifier, - contravariantUnifier, - ); - } - - /** - * Returns the lowest common supertype for the given enum-based types. - */ - private lowestCommonSupertypeForEnumBasedTypes( - enumTypes: EnumType[], - enumVariantTypes: EnumVariantType[], - isNullable: boolean, - ): Type { - // Build candidates & other - const candidates: Type[] = []; - - if (!isEmpty(enumTypes)) { - candidates.push(enumTypes[0]!.withExplicitNullability(isNullable)); - } else if (!isEmpty(enumVariantTypes)) { - candidates.push(enumVariantTypes[0]!.withExplicitNullability(isNullable)); - - const containingEnum = AstUtils.getContainerOfType(enumVariantTypes[0]!.declaration, isTslEnum); - if (containingEnum) { - candidates.push(this.factory.createEnumType(containingEnum, isNullable)); - } - } else { - /* c8 ignore next 2 */ - return this.Nothing(isNullable); - } - - const others = [...enumTypes, ...enumVariantTypes]; - - // Check whether a candidate type is compatible to all other types - for (const candidate of candidates) { - if (this.isCommonSupertype(candidate, others)) { - return candidate; - } - } - - return this.Any(isNullable); - } - - private isCommonSupertypeIgnoringTypeParameters(candidate: Type, otherTypes: Type[]): boolean { - return otherTypes.every((it) => - this.typeChecker.isSupertypeOf(candidate, it, { - ignoreTypeParameters: true, - }), - ); - } - - private isCommonSupertype(candidate: Type, otherTypes: Type[]): boolean { - return otherTypes.every((it) => this.typeChecker.isSupertypeOf(candidate, it)); - } - - // ----------------------------------------------------------------------------------------------------------------- - // Highest common subtype - // ----------------------------------------------------------------------------------------------------------------- - /** - * Computes the highest common subtype for the given types. The result is simplified as much as possible. This - * function is only meant to be called from `lowestCommonSupertype`, since we make several assumptions about the - * input types, e.g. that they are already simplified. - */ - private highestCommonSubtype(types: Type[]): Type { - if (types.length === 0) { - /* c8 ignore next 2 */ - return this.Any(true); - } else if (types.length === 1) { - /* c8 ignore next 2 */ - return types[0]!; - } - - // Update nullability of all types - const isNullable = types.every((it) => it.isExplicitlyNullable); - const typesWithMatchingNullability = types.map((it) => it.withExplicitNullability(isNullable)); - - // One of the types is already a common subtype of all others after updating nullability - const commonSupertype = typesWithMatchingNullability.find((it) => this.isCommonSubtype(it, types)); - if (commonSupertype) { - return commonSupertype; - } - - // Partition types by their kind - const partitionedTypes = this.partitionTypesHCS(typesWithMatchingNullability); - - // Contains unhandled type - if (partitionedTypes.containsOtherType) { - return this.Nothing(isNullable); - } - - // Contains only class types - if (!isEmpty(partitionedTypes.classTypes) && isEmpty(partitionedTypes.literalTypes)) { - return this.highestCommonSubtypeForClassTypes(partitionedTypes.classTypes, isNullable); - } - - // Contains only literal types - if (!isEmpty(partitionedTypes.literalTypes) && isEmpty(partitionedTypes.classTypes)) { - return this.highestCommonSubtypeForLiteralTypes(partitionedTypes.literalTypes); - } - - // If a literal were a subtype of all other types, we would have already handled this when simplifying the types - // in `lowestCommonSupertype`. Since we instead got here, we can conclude that there is no common subtype other - // than `Nothing`/`Nothing?`. - return this.Nothing(isNullable); - } - - /** - * Partitions the given types by their kind. This function is only meant to be used when computing the highest - * common subtype (HCS). - */ - private partitionTypesHCS(types: Type[]): PartitionTypesHCSResult { - const result: PartitionTypesHCSResult = { - classTypes: [], - literalTypes: [], - containsOtherType: false, - }; - - for (const type of types) { - if (type instanceof ClassType) { - result.classTypes.push(type); - } else if (type instanceof LiteralType) { - result.literalTypes.push(type); - } else { - result.containsOtherType = true; - return result; - } - } - - return result; - } - - private highestCommonSubtypeForClassTypes(types: ClassType[], isNullable: boolean): Type { - if (isEmpty(types)) { - /* c8 ignore next 2 */ - return this.Any(isNullable); - } - - // Find the type that is compatible to all other types ignoring type parameters - const candidate = types.find((it) => this.isCommonSubtypeIgnoringTypeParameters(it, types)); - if (!candidate || candidate.equals(this.Nothing(isNullable))) { - return this.Nothing(isNullable); - } - - let others = types.filter((it) => it !== candidate); - - // If the class has no type parameters, the candidate must match as is - const typeParameters = getTypeParameters(candidate.declaration); - if (isEmpty(typeParameters)) { - if (this.isCommonSubtype(candidate, others)) { - /* c8 ignore next 2 */ - return candidate; - } else { - return this.Nothing(isNullable); - } - } - - // Bring all types down to a common class - others = this.bringTypesDownToCommonClass(candidate, others); - - // Check whether all substitutions of invariant type parameters are equal - if (!this.substitutionsForInvariantTypeParametersAreEqual(typeParameters, candidate, others)) { - return this.Nothing(isNullable); - } - - // Unify substitutions for type parameters - const newSubstitutions = this.newTypeParameterSubstitutionsHCS(typeParameters, candidate, others); - return this.factory.createClassType(candidate.declaration, newSubstitutions, isNullable); - } - - private bringTypesDownToCommonClass(candidate: ClassType, others: ClassType[]): ClassType[] { - const targetTemplate = this.createTargetTemplate(candidate); - const result: ClassType[] = []; - - for (const type of others) { - const matchingSubtype = this.computeMatchingSubtype(type, targetTemplate)!; - - // Apply substitutions of the candidate, if type parameter types are still free - for (const typeParameter of getTypeParameters(candidate.declaration)) { - if (!matchingSubtype.substitutions.has(typeParameter)) { - const substitution = candidate.substitutions.get(typeParameter); - if (substitution) { - matchingSubtype.substitutions.set(typeParameter, substitution); - } - } - } - - result.push(matchingSubtype); - } - - return result; - } - - /** - * Creates a class type with the same declaration and nullability as the given type. Type parameters, however, are - * substituted by their own type parameter type to observe how they flow through the class hierarchy. - */ - private createTargetTemplate(type: ClassType): ClassType { - const declaration = type.declaration; - const typeParameters = getTypeParameters(declaration); - const substitutions: TypeParameterSubstitutions = new Map(); - - for (const typeParameter of typeParameters) { - substitutions.set(typeParameter, this.factory.createTypeParameterType(typeParameter, false)); - } - - return this.factory.createClassType(declaration, substitutions, type.isExplicitlyNullable); - } - - private computeMatchingSubtype(type: ClassType, targetTemplate: ClassType): ClassType | undefined { - if (type.declaration === targetTemplate.declaration) { - return type; - } - - const superType = this.computeMatchingSupertype(targetTemplate, type.declaration); - if (!superType) { - /* c8 ignore next 2 */ - return undefined; - } - - // See where the type parameters ended up in the computed super type - const invertedTypeParameterMap = new Map(); - for (const [key, value] of superType.substitutions) { - if (value instanceof TypeParameterType) { - invertedTypeParameterMap.set(value.declaration, key); - } - } - - // Compute the new substitutions - const substitutions: TypeParameterSubstitutions = new Map(); - for (const typeParameter of getTypeParameters(targetTemplate.declaration)) { - const invertedTypeParameter = invertedTypeParameterMap.get(typeParameter); - if (!invertedTypeParameter) { - continue; - } - - const substitution = type.substitutions.get(invertedTypeParameter); - if (substitution) { - substitutions.set(typeParameter, substitution); - } - } - - return this.factory.createClassType( - targetTemplate.declaration, - substitutions, - targetTemplate.isExplicitlyNullable, - ); - } - - private newTypeParameterSubstitutionsHCS( - typeParameters: TslTypeParameter[], - candidate: ClassType, - others: ClassType[], - ): TypeParameterSubstitutions { - const covariantUnifier = (types: Type[]) => this.highestCommonSubtype(types); - const contravariantUnifier = (types: Type[]) => - this.lowestCommonSupertype(types, { - skipTypeSimplification: true, - }); - - return this.newTypeParameterSubstitutions( - typeParameters, - candidate, - others, - covariantUnifier, - contravariantUnifier, - ); - } - - private highestCommonSubtypeForLiteralTypes(types: LiteralType[]): Type { - if (isEmpty(types)) { - /* c8 ignore next 2 */ - return this.coreTypes.AnyOrNull; - } - - // Intersect constants - const [first, ...other] = types; - const constants = first!.constants.filter((constant1) => - other.every((type) => type.constants.some((constant2) => constant1.equals(constant2))), - ); - - return this.factory.createLiteralType(...constants).simplify(); - } - - private isCommonSubtypeIgnoringTypeParameters(candidate: Type, otherTypes: Type[]): boolean { - return otherTypes.every((it) => - this.typeChecker.isSubtypeOf(candidate, it, { - ignoreTypeParameters: true, - }), - ); - } - - private isCommonSubtype(candidate: Type, otherTypes: Type[]): boolean { - return otherTypes.every((it) => this.typeChecker.isSubtypeOf(candidate, it)); - } - - // ----------------------------------------------------------------------------------------------------------------- - // Supertypes - // ----------------------------------------------------------------------------------------------------------------- - - /** - * Walks through the supertypes of the given `type` (including the given `type`) and returns the first class type - * where the declaration matches the given `target`. If no such supertype exists, `undefined` is returned. Type - * parameters on parent types get substituted. - */ - computeMatchingSupertype( - type: ClassType | TypeParameterType | undefined, - target: TslClass | undefined, - ): ClassType | undefined { - // Handle undefined - if (!type || !target) { - return undefined; - } - - // Handle type parameter types - if (type instanceof TypeParameterType) { - const upperBound = this.computeUpperBound(type); - if (upperBound instanceof ClassType) { - return this.computeMatchingSupertype(upperBound, target); - } else { - /* c8 ignore next 2 */ - return undefined; - } - } - - // Handle class types - return stream([type], this.streamProperSupertypes(type)).find((it) => it.declaration === target); - } - - /** - * Returns a stream of all declared supertypes of the given type. Direct ancestors are returned first, followed by - * their ancestors and so on. The given type is never included in the stream. - * - * Compared to `ClassHierarchy.streamSuperTypes`, this method cannot be used to detect cycles in the inheritance - * hierarchy. However, it can handle type parameters on parent types and substitute them accordingly. - */ - streamProperSupertypes(type: ClassType | undefined): Stream { - if (!type) { - return EMPTY_STREAM; - } - - return stream(this.properSupertypesGenerator(type)); - } - - private *properSupertypesGenerator(type: ClassType): Generator { - // Compared to `ClassHierarchy.properSuperclassesGenerator`, we already include the given type in the list of - // visited elements, since this method here is not used to detect cycles. - const visited = new Set([type.declaration]); - let current = this.parentClassType(type); - - while (current && !visited.has(current.declaration)) { - yield current; - visited.add(current.declaration); - current = this.parentClassType(current); - } - - const Any = this.Any(type.isExplicitlyNullable); - if (Any instanceof ClassType && !visited.has(Any.declaration)) { - yield Any; - } - } - - /** - * Tries to evaluate the first parent type of the class to a `ClassType` and returns it if successful. Type - * parameters get substituted. If there is no parent type or the parent type is not a class, `undefined` is - * returned. - */ - private parentClassType(type: ClassType): ClassType | undefined { - const [firstParentTypeNode] = getParentTypes(type.declaration); - const firstParentType = this.computeType(firstParentTypeNode, type.substitutions); - - if (firstParentType instanceof ClassType) { - return firstParentType.withExplicitNullability(type.isExplicitlyNullable); - } - return undefined; - } - // ----------------------------------------------------------------------------------------------------------------- // Helpers // ----------------------------------------------------------------------------------------------------------------- @@ -1581,55 +466,8 @@ export class SafeDsTypeComputer { return isNullable ? this.coreTypes.AnyOrNull : this.coreTypes.Any; } - private Nothing(isNullable: boolean): Type { - return isNullable ? this.coreTypes.NothingOrNull : this.coreTypes.Nothing; - } - - private newTypeParameterSubstitutions( - typeParameters: TslTypeParameter[], - candidate: ClassType, - others: ClassType[], - covariantUnifier: (types: Type[]) => Type, - contravariantUnifier: (types: Type[]) => Type, - ): TypeParameterSubstitutions { - const substitutions: TypeParameterSubstitutions = new Map(); - - for (const typeParameter of typeParameters) { - const candidateSubstitution = candidate.substitutions.get(typeParameter) ?? UnknownType; - - if (TypeParameter.isCovariant(typeParameter)) { - const otherSubstitutions = others.map((it) => it.substitutions.get(typeParameter) ?? UnknownType); - substitutions.set(typeParameter, covariantUnifier([candidateSubstitution, ...otherSubstitutions])); - } else if (TypeParameter.isContravariant(typeParameter)) { - const otherSubstitutions = others.map((it) => it.substitutions.get(typeParameter) ?? UnknownType); - substitutions.set(typeParameter, contravariantUnifier([candidateSubstitution, ...otherSubstitutions])); - } else { - substitutions.set(typeParameter, candidateSubstitution); - } - } - - return substitutions; - } -} - -/** - * Options for {@link computeUpperBound}. - */ -interface ComputeUpperBoundOptions { - /** - * If `true`, the computation stops at type parameter types and returns them as is. Otherwise, it finds the bounds - * for the type parameter types recursively. - */ - stopAtTypeParameterType?: boolean; -} - -interface ComputeTypeParameterSubstitutionsForParametersState { - substitutions: TypeParameterSubstitutions; - remainingVariances: Map; } -type Variance = 'bivariant' | 'covariant' | 'contravariant' | 'invariant'; - /** * Options for {@link lowestCommonSupertype}. */ @@ -1641,17 +479,6 @@ interface LowestCommonSupertypeOptions { } interface PartitionTypesLCSResult { - classTypes: ClassType[]; - enumTypes: EnumType[]; - enumVariantTypes: EnumVariantType[]; containsUnknownType: boolean; containsOtherType: boolean; } - -interface PartitionTypesHCSResult { - classTypes: ClassType[]; - literalTypes: LiteralType[]; - containsOtherType: boolean; -} - -const NO_SUBSTITUTIONS: TypeParameterSubstitutions = new Map(); diff --git a/packages/ttsl-lang/src/language/validation/types.ts b/packages/ttsl-lang/src/language/validation/types.ts index eda0ad93..f15c9731 100644 --- a/packages/ttsl-lang/src/language/validation/types.ts +++ b/packages/ttsl-lang/src/language/validation/types.ts @@ -31,7 +31,6 @@ export const callArgumentTypesMustMatchParameterTypes = (services: SafeDsService const typeComputer = services.types.TypeComputer; return (node: TslCall, accept: ValidationAcceptor) => { - const substitutions = typeComputer.computeSubstitutionsForCall(node); for (const argument of getArguments(node)) { const parameter = nodeMapper.argumentToParameter(argument); @@ -39,8 +38,8 @@ export const callArgumentTypesMustMatchParameterTypes = (services: SafeDsService return; } - const argumentType = typeComputer.computeType(argument).substituteTypeParameters(substitutions); - const parameterType = typeComputer.computeType(parameter).substituteTypeParameters(substitutions); + const argumentType = typeComputer.computeType(argument); + const parameterType = typeComputer.computeType(parameter); if (!typeChecker.isSubtypeOf(argumentType, parameterType)) { accept('error', `Expected type '${parameterType}' but got '${argumentType}'.`, { From 7750e2eca560e551b0f6fcffcadab6465c819ead Mon Sep 17 00:00:00 2001 From: methr0 Date: Mon, 1 Jul 2024 14:15:25 +0200 Subject: [PATCH 103/183] remove unnecessary code from type-checker --- .../language/typing/safe-ds-type-checker.ts | 222 +----------------- 1 file changed, 9 insertions(+), 213 deletions(-) diff --git a/packages/ttsl-lang/src/language/typing/safe-ds-type-checker.ts b/packages/ttsl-lang/src/language/typing/safe-ds-type-checker.ts index 762a2728..5ad3a758 100644 --- a/packages/ttsl-lang/src/language/typing/safe-ds-type-checker.ts +++ b/packages/ttsl-lang/src/language/typing/safe-ds-type-checker.ts @@ -1,18 +1,13 @@ -import type { SafeDsClasses } from '../builtins/safe-ds-classes.js'; -import { isTslCallable, isTslClass, isTslEnum, TslDeclaration } from '../generated/ast.js'; -import { Enum, EnumVariant, getTypeParameters, Parameter, TypeParameter } from '../helpers/nodeProperties.js'; +import { isTslCallable, TslDeclaration } from '../generated/ast.js'; +import { Parameter } from '../helpers/nodeProperties.js'; import { Constant, NullConstant } from '../partialEvaluation/model.js'; import { SafeDsServices } from '../safe-ds-module.js'; import { CallableType, - ClassType, - EnumType, - EnumVariantType, - LiteralType, + DictionaryType, + ListType, NamedTupleType, - StaticType, Type, - TypeParameterType, UnionType, UnknownType, } from './model.js'; @@ -23,13 +18,11 @@ import { isEmpty } from '../../helpers/collections.js'; import { AstUtils } from 'langium'; export class SafeDsTypeChecker { - private readonly builtinClasses: SafeDsClasses; private readonly classHierarchy: SafeDsClassHierarchy; private readonly coreTypes: SafeDsCoreTypes; private readonly typeComputer: () => SafeDsTypeComputer; constructor(services: SafeDsServices) { - this.builtinClasses = services.builtins.Classes; this.classHierarchy = services.types.ClassHierarchy; this.coreTypes = services.types.CoreTypes; this.typeComputer = () => services.types.TypeComputer; @@ -56,38 +49,14 @@ export class SafeDsTypeChecker { return false; } - if (other instanceof TypeParameterType) { - if (type.isExplicitlyNullable && !other.isExplicitlyNullable) { - return false; - } - - // `T` can always be assigned to `T` or some type parameter it is bounded by - if (type instanceof TypeParameterType && this.typeParameterIsBoundedByTypeParameter(type, other)) { - return true; - } - - const otherLowerBound = this.coreTypes.Nothing.withExplicitNullability(other.isExplicitlyNullable); - return this.isSubtypeOf(type, otherLowerBound, options); - } else if (other instanceof UnionType) { + if (other instanceof UnionType) { return other.types.some((it) => this.isSubtypeOf(type, it, options)); } if (type instanceof CallableType) { return this.callableTypeIsSubtypeOf(type, other, options); - } else if (type instanceof ClassType) { - return this.classTypeIsSubtypeOf(type, other, options); - } else if (type instanceof EnumType) { - return this.enumTypeIsSubtypeOf(type, other); - } else if (type instanceof EnumVariantType) { - return this.enumVariantTypeIsSubtypeOf(type, other); - } else if (type instanceof LiteralType) { - return this.literalTypeIsSubtypeOf(type, other, options); } else if (type instanceof NamedTupleType) { return this.namedTupleTypeIsSubtypeOf(type, other, options); - } else if (type instanceof StaticType) { - return this.staticTypeIsSubtypeOf(type, other, options); - } else if (type instanceof TypeParameterType) { - return this.typeParameterTypeIsSubtypeOf(type, other, options); } else if (type instanceof UnionType) { return this.unionTypeIsSubtypeOf(type, other, options); } /* c8 ignore start */ else { @@ -95,24 +64,8 @@ export class SafeDsTypeChecker { } /* c8 ignore stop */ }; - private typeParameterIsBoundedByTypeParameter(type: TypeParameterType, other: TypeParameterType): boolean { - let current: Type = type; - - while (current instanceof TypeParameterType) { - if (current.declaration === other.declaration) { - return true; - } - - current = this.typeComputer().computeUpperBound(current, { stopAtTypeParameterType: true }); - } - - return false; - } - private callableTypeIsSubtypeOf(type: CallableType, other: Type, options: TypeCheckOptions): boolean { - if (other instanceof ClassType) { - return other.declaration === this.builtinClasses.Any; - } else if (other instanceof CallableType) { + if (other instanceof CallableType) { // Must accept at least as many parameters and produce at least as many results if (type.inputType.length < other.inputType.length || type.outputType.length < other.outputType.length) { return false; @@ -168,119 +121,12 @@ export class SafeDsTypeChecker { } } - private classTypeIsSubtypeOf(type: ClassType, other: Type, options: TypeCheckOptions): boolean { - if (type.isExplicitlyNullable && !other.isExplicitlyNullable) { - return false; - } else if (type.declaration === this.builtinClasses.Nothing) { - return true; - } - - if (other instanceof ClassType) { - if (!this.classHierarchy.isEqualToOrSubclassOf(type.declaration, other.declaration)) { - return false; - } - - // We are done already if we ignore type parameters or if the other type has no type parameters - const typeParameters = getTypeParameters(other.declaration); - if (options.ignoreTypeParameters || isEmpty(typeParameters)) { - return true; - } - - // Get the parent type that refers to the same class as `other` - const candidate = this.typeComputer().computeMatchingSupertype(type, other.declaration); - if (!candidate) { - /* c8 ignore next 2 */ - return false; - } - - // Check type parameters - return typeParameters.every((it) => { - const candidateType = candidate.substitutions.get(it) ?? UnknownType; - const otherType = other.substitutions.get(it) ?? UnknownType; - - if (TypeParameter.isInvariant(it)) { - return candidateType !== UnknownType && candidateType.equals(otherType); - } else if (TypeParameter.isCovariant(it)) { - return this.isSubtypeOf(candidateType, otherType, options); - } else { - return this.isSubtypeOf(otherType, candidateType, options); - } - }); - } else { - return false; - } - } - - private enumTypeIsSubtypeOf(type: EnumType, other: Type): boolean { - if (type.isExplicitlyNullable && !other.isExplicitlyNullable) { - return false; - } - - if (other instanceof ClassType) { - return other.declaration === this.builtinClasses.Any; - } else if (other instanceof EnumType) { - return type.declaration === other.declaration; - } else { - return false; - } - } - - private enumVariantTypeIsSubtypeOf(type: EnumVariantType, other: Type): boolean { - if (type.isExplicitlyNullable && !other.isExplicitlyNullable) { - return false; - } - - if (other instanceof ClassType) { - return other.declaration === this.builtinClasses.Any; - } else if (other instanceof EnumType) { - const containingEnum = AstUtils.getContainerOfType(type.declaration, isTslEnum); - return containingEnum === other.declaration; - } else if (other instanceof EnumVariantType) { - return type.declaration === other.declaration; - } else { - return false; - } - } - - private literalTypeIsSubtypeOf(type: LiteralType, other: Type, options: TypeCheckOptions): boolean { - if (type.isExplicitlyNullable && !other.isExplicitlyNullable) { - return false; - } else if (type.constants.length === 0) { - // Empty literal types are equivalent to `Nothing` and assignable to any type - return true; - } else if (type.constants.every((it) => it === NullConstant)) { - // Literal types containing only `null` are equivalent to `Nothing?` and assignable to any nullable type - return other.isExplicitlyNullable; - } - - if (other instanceof ClassType) { - if (other.equals(this.coreTypes.Any.withExplicitNullability(type.isExplicitlyNullable))) { - return true; - } - - return type.constants.every((constant) => this.constantIsSubtypeOfClassType(constant, other, options)); - } else if (other instanceof LiteralType) { - return type.constants.every((constant) => - other.constants.some((otherConstant) => constant.equals(otherConstant)), - ); - } else { - return false; - } - } - - private constantIsSubtypeOfClassType(constant: Constant, other: ClassType, options: TypeCheckOptions): boolean { - const classType = this.typeComputer().computeClassTypeForConstant(constant); - return this.isSubtypeOf(classType, other, options); - } - private namedTupleTypeIsSubtypeOf( type: NamedTupleType, other: Type, options: TypeCheckOptions, ): boolean { - if (other instanceof ClassType) { - return other.declaration === this.builtinClasses.Any; - } else if (other instanceof NamedTupleType) { + if (other instanceof NamedTupleType) { return ( type.length === other.length && type.entries.every((typeEntry, i) => { @@ -296,22 +142,6 @@ export class SafeDsTypeChecker { } } - private staticTypeIsSubtypeOf(type: StaticType, other: Type, options: TypeCheckOptions): boolean { - if (other instanceof CallableType) { - const callableType = this.typeComputer().computeCallableTypeForStaticType(type); - return this.isSubtypeOf(callableType, other, options); - } else if (other instanceof ClassType) { - return other.declaration === this.builtinClasses.Any; - } else { - return type.equals(other); - } - } - - private typeParameterTypeIsSubtypeOf(type: TypeParameterType, other: Type, options: TypeCheckOptions): boolean { - const upperBound = this.typeComputer().computeUpperBound(type); - return this.isSubtypeOf(upperBound, other, options); - } - private unionTypeIsSubtypeOf(type: UnionType, other: Type, options: TypeCheckOptions): boolean { return type.types.every((it) => this.isSubtypeOf(it, other, options)); } @@ -336,14 +166,6 @@ export class SafeDsTypeChecker { if (nonNullableReceiverType instanceof CallableType) { return true; - } else if (nonNullableReceiverType instanceof StaticType) { - const declaration = nonNullableReceiverType.instanceType.declaration; - if (isTslClass(declaration)) { - // Must have a constructor - return declaration.parameterList !== undefined; - } else { - return isTslCallable(declaration); - } } else { return false; } @@ -356,41 +178,15 @@ export class SafeDsTypeChecker { canBeNull = (type: Type): boolean => { if (type.isExplicitlyNullable) { return true; - } else if (type instanceof TypeParameterType) { - const upperBound = this.typeComputer().computeUpperBound(type); - return upperBound.isExplicitlyNullable; } else { return false; } }; - /** - * Checks whether {@link type} is allowed as the type of a constant parameter. - */ - canBeTypeOfConstantParameter = (type: Type): boolean => { - if (type instanceof ClassType) { - return [ - this.builtinClasses.Boolean, - this.builtinClasses.Float, - this.builtinClasses.Int, - this.builtinClasses.List, - this.builtinClasses.Map, - this.builtinClasses.Nothing, - this.builtinClasses.String, - ].includes(type.declaration); - } else if (type instanceof EnumType) { - return Enum.isConstant(type.declaration); - } else if (type instanceof EnumVariantType) { - return EnumVariant.isConstant(type.declaration); - } else { - return type instanceof LiteralType || type === UnknownType; - } - }; - /** * Checks whether {@link type} is some kind of list (with any element type). */ - isList(type: Type): type is ClassType | TypeParameterType { + isList(type: Type): type is ListType { const listOrNull = this.coreTypes.List(UnknownType).withExplicitNullability(true); return ( @@ -405,7 +201,7 @@ export class SafeDsTypeChecker { /** * Checks whether {@link type} is some kind of map (with any key/value types). */ - isMap(type: Type): type is ClassType | TypeParameterType { + isMap(type: Type): type is DictionaryType { const mapOrNull = this.coreTypes.Map(UnknownType, UnknownType).withExplicitNullability(true); return ( From c8c1609f87955c76dae169a38abb578ee7725ea9 Mon Sep 17 00:00:00 2001 From: methr0 Date: Mon, 1 Jul 2024 14:56:17 +0200 Subject: [PATCH 104/183] remove unnecessary code in partial evaluator --- .../src/language/grammar/ttsl.langium | 13 +++++- .../safe-ds-partial-evaluator.ts | 45 +++---------------- 2 files changed, 16 insertions(+), 42 deletions(-) diff --git a/packages/ttsl-lang/src/language/grammar/ttsl.langium b/packages/ttsl-lang/src/language/grammar/ttsl.langium index f6ba5f28..575cd50f 100644 --- a/packages/ttsl-lang/src/language/grammar/ttsl.langium +++ b/packages/ttsl-lang/src/language/grammar/ttsl.langium @@ -357,13 +357,13 @@ TslExpression returns TslExpression: ; interface TslAggregation extends TslExpression{ - function: string + function: TslString data: TslReference groupedBy: TslGroupedBy } TslAggregation returns TslAggregation: - 'aggregate' function=STRING 'of' data=TslReference groupedBy=TslGroupedBy + 'aggregate' function=TslString 'of' data=TslReference groupedBy=TslGroupedBy ; interface TslInfixOperation extends TslExpression { @@ -549,6 +549,7 @@ TslLiteral returns TslLiteral: TslBoolean | TslFloat | TslInt + | TslString | TslList | TslDictionary | TslNull @@ -583,6 +584,14 @@ TslInt returns TslInt: value=INT ; +interface TslString extends TslNumber { + value: string +} + +TslString returns TslString: + value=STRING +; + interface TslList extends TslLiteral { elements: TslExpression[] } diff --git a/packages/ttsl-lang/src/language/partialEvaluation/safe-ds-partial-evaluator.ts b/packages/ttsl-lang/src/language/partialEvaluation/safe-ds-partial-evaluator.ts index 0eb4de7f..a18a543e 100644 --- a/packages/ttsl-lang/src/language/partialEvaluation/safe-ds-partial-evaluator.ts +++ b/packages/ttsl-lang/src/language/partialEvaluation/safe-ds-partial-evaluator.ts @@ -4,15 +4,11 @@ import { isTslArgument, isTslAssignee, isTslAssignment, - isTslBlockLambda, isTslBoolean, isTslCall, isTslCallable, - isTslClass, isTslDeclaration, - isTslEnumVariant, isTslExpression, - isTslExpressionLambda, isTslFloat, isTslFunction, isTslIndexedAccess, @@ -23,12 +19,9 @@ import { isTslMemberAccess, isTslNull, isTslParameter, - isTslParenthesizedExpression, isTslPrefixOperation, isTslReference, isTslResult, - isTslSegment, - isTslString, isTslTemplateString, isTslTemplateStringEnd, isTslTemplateStringInner, @@ -54,8 +47,9 @@ import { isTslGroupedBy, isTslVisibility, isTslTimeunit, + isTslString, } from '../generated/ast.js'; -import { getAbstractResults, getArguments, getParameters } from '../helpers/nodeProperties.js'; +import { getArguments, getParameters } from '../helpers/nodeProperties.js'; import { SafeDsNodeMapper } from '../helpers/safe-ds-node-mapper.js'; import { SafeDsServices } from '../safe-ds-module.js'; import { @@ -180,18 +174,10 @@ export class SafeDsPartialEvaluator { substitutions: ParameterSubstitutions, visited: VisitedState[], ): EvaluatedNode { - if (isTslClass(node)) { - return new NamedCallable(node); - } else if (isTslEnumVariant(node)) { - return new EvaluatedEnumVariant(node, undefined); - } else if (isTslFunction(node)) { + if (isTslFunction(node)) { return new NamedCallable(node); } else if (isTslParameter(node)) { return substitutions.get(node) ?? UnknownEvaluatedNode; - } else if (isTslResult(node)) { - return this.evaluateWithRecursionCheck(this.nodeMapper.resultToYields(node).head(), substitutions, visited); - } else if (isTslSegment(node)) { - return new NamedCallable(node); } else { return UnknownEvaluatedNode; } @@ -218,10 +204,6 @@ export class SafeDsPartialEvaluator { return new StringConstant(node.value); } else if (isTslTemplateStringEnd(node)) { return new StringConstant(node.value); - } else if (isTslBlockLambda(node)) { - return new BlockLambdaClosure(node, substitutions); - } else if (isTslExpressionLambda(node)) { - return new ExpressionLambdaClosure(node, substitutions); } // Recursive cases @@ -239,8 +221,6 @@ export class SafeDsPartialEvaluator { return this.evaluateMap(node, substitutions, visited); } else if (isTslMemberAccess(node)) { return this.evaluateMemberAccess(node, substitutions, visited); - } else if (isTslParenthesizedExpression(node)) { - return this.evaluateWithRecursionCheck(node.expression, substitutions, visited); } else if (isTslPrefixOperation(node)) { return this.evaluatePrefixOperation(node, substitutions, visited); } else if (isTslReference(node)) { @@ -579,20 +559,7 @@ export class SafeDsPartialEvaluator { visited, ); - if (isTslExpressionLambda(callable)) { - return this.evaluateWithRecursionCheck(callable.result, parameterSubstitutionsAfterCall, visited); - } else if (isTslBlockLambda(callable) || isTslSegment(callable)) { - return new EvaluatedNamedTuple( - new Map( - getAbstractResults(callable).map((it) => [ - it, - this.evaluateWithRecursionCheck(it, parameterSubstitutionsAfterCall, visited), - ]), - ), - ); - } else { - return UnknownEvaluatedNode; - } + return UnknownEvaluatedNode; } private getParameterSubstitutionsAfterCall( @@ -666,8 +633,6 @@ export class SafeDsPartialEvaluator { const member = node.member?.target?.ref; if (!member) { return UnknownEvaluatedNode; - } else if (isTslEnumVariant(member)) { - return this.evaluateWithRecursionCheck(member, substitutions, visited); } const receiver = this.evaluateWithRecursionCheck(node.receiver, substitutions, visited); @@ -727,7 +692,7 @@ export class SafeDsPartialEvaluator { // 2. If the member cannot be resolved, we already show an error. // 3. If the enum variant has parameters that are not provided, we already show an error. const member = node.member?.target?.ref; - return !member || isTslEnumVariant(member); + return !member; } else if (isTslPrefixOperation(node)) { return node.operator === '-' && this.canBeValueOfConstantParameter(node.operand); } else if (isTslReference(node)) { From db9d4dac86d938fb171245b3f812f1a5b3468501 Mon Sep 17 00:00:00 2001 From: methr0 Date: Mon, 1 Jul 2024 14:58:36 +0200 Subject: [PATCH 105/183] remove class hierachy --- .../ttsl-lang/src/language/safe-ds-module.ts | 3 - .../scoping/safe-ds-scope-provider.ts | 3 - .../typing/safe-ds-class-hierarchy.ts | 109 ------------------ .../language/typing/safe-ds-type-checker.ts | 8 +- 4 files changed, 1 insertion(+), 122 deletions(-) delete mode 100644 packages/ttsl-lang/src/language/typing/safe-ds-class-hierarchy.ts diff --git a/packages/ttsl-lang/src/language/safe-ds-module.ts b/packages/ttsl-lang/src/language/safe-ds-module.ts index 11f8434b..01528a28 100644 --- a/packages/ttsl-lang/src/language/safe-ds-module.ts +++ b/packages/ttsl-lang/src/language/safe-ds-module.ts @@ -25,7 +25,6 @@ import { SafeDsSignatureHelpProvider } from './lsp/safe-ds-signature-help-provid import { SafeDsPartialEvaluator } from './partialEvaluation/safe-ds-partial-evaluator.js'; import { SafeDsScopeComputation } from './scoping/safe-ds-scope-computation.js'; import { SafeDsScopeProvider } from './scoping/safe-ds-scope-provider.js'; -import { SafeDsClassHierarchy } from './typing/safe-ds-class-hierarchy.js'; import { SafeDsCoreTypes } from './typing/safe-ds-core-types.js'; import { SafeDsTypeChecker } from './typing/safe-ds-type-checker.js'; import { SafeDsTypeComputer } from './typing/safe-ds-type-computer.js'; @@ -61,7 +60,6 @@ export type SafeDsAddedServices = { NodeInfoProvider: SafeDsNodeInfoProvider; }; types: { - ClassHierarchy: SafeDsClassHierarchy; CoreTypes: SafeDsCoreTypes; TypeChecker: SafeDsTypeChecker; TypeComputer: SafeDsTypeComputer; @@ -122,7 +120,6 @@ export const SafeDsModule: Module new SafeDsScopeProvider(services), }, types: { - ClassHierarchy: (services) => new SafeDsClassHierarchy(services), CoreTypes: (services) => new SafeDsCoreTypes(services), TypeChecker: (services) => new SafeDsTypeChecker(services), TypeComputer: (services) => new SafeDsTypeComputer(services), diff --git a/packages/ttsl-lang/src/language/scoping/safe-ds-scope-provider.ts b/packages/ttsl-lang/src/language/scoping/safe-ds-scope-provider.ts index ae257486..cd64575c 100644 --- a/packages/ttsl-lang/src/language/scoping/safe-ds-scope-provider.ts +++ b/packages/ttsl-lang/src/language/scoping/safe-ds-scope-provider.ts @@ -48,13 +48,11 @@ import { } from '../helpers/nodeProperties.js'; import { SafeDsNodeMapper } from '../helpers/safe-ds-node-mapper.js'; import { SafeDsServices } from '../safe-ds-module.js'; -import type { SafeDsClassHierarchy } from '../typing/safe-ds-class-hierarchy.js'; import { SafeDsTypeComputer } from '../typing/safe-ds-type-computer.js'; import { SafeDsPackageManager } from '../workspace/safe-ds-package-manager.js'; export class SafeDsScopeProvider extends DefaultScopeProvider { private readonly astReflection: AstReflection; - private readonly classHierarchy: SafeDsClassHierarchy; private readonly nodeMapper: SafeDsNodeMapper; private readonly packageManager: SafeDsPackageManager; private readonly typeComputer: SafeDsTypeComputer; @@ -65,7 +63,6 @@ export class SafeDsScopeProvider extends DefaultScopeProvider { super(services); this.astReflection = services.shared.AstReflection; - this.classHierarchy = services.types.ClassHierarchy; this.nodeMapper = services.helpers.NodeMapper; this.packageManager = services.workspace.PackageManager; this.typeComputer = services.types.TypeComputer; diff --git a/packages/ttsl-lang/src/language/typing/safe-ds-class-hierarchy.ts b/packages/ttsl-lang/src/language/typing/safe-ds-class-hierarchy.ts deleted file mode 100644 index 925944b0..00000000 --- a/packages/ttsl-lang/src/language/typing/safe-ds-class-hierarchy.ts +++ /dev/null @@ -1,109 +0,0 @@ -import { AstUtils, EMPTY_STREAM, stream, Stream } from 'langium'; -import { SafeDsClasses } from '../builtins/safe-ds-classes.js'; -import { isTslClass, isTslNamedType, TslClass, type TslClassMember } from '../generated/ast.js'; -import { getClassMembers, getParentTypes, isStatic } from '../helpers/nodeProperties.js'; -import { SafeDsServices } from '../safe-ds-module.js'; - -export class SafeDsClassHierarchy { - private readonly builtinClasses: SafeDsClasses; - - constructor(services: SafeDsServices) { - this.builtinClasses = services.builtins.Classes; - } - - /** - * Returns `true` if the given node is equal to or a subclass of the given other node. If one of the nodes is - * `undefined`, `false` is returned. - */ - isEqualToOrSubclassOf(node: TslClass | undefined, other: TslClass | undefined): boolean { - if (!node || !other) { - return false; - } - - // Nothing is a subclass of everything - if (node === this.builtinClasses.Nothing) { - return true; - } - - return node === other || this.streamProperSuperclasses(node).includes(other); - } - - /** - * Returns a stream of all superclasses of the given class. Direct ancestors are returned first, followed by their - * ancestors and so on. The class itself is not included in the stream unless there is a cycle in the inheritance - * hierarchy. - */ - streamProperSuperclasses(node: TslClass | undefined): Stream { - if (!node) { - return EMPTY_STREAM; - } - - return stream(this.properSuperclassesGenerator(node)); - } - - private *properSuperclassesGenerator(node: TslClass): Generator { - const visited = new Set(); - let current = this.parentClass(node); - while (current && !visited.has(current)) { - yield current; - visited.add(current); - current = this.parentClass(current); - } - - const anyClass = this.builtinClasses.Any; - if (anyClass && node !== anyClass && !visited.has(anyClass)) { - yield anyClass; - } - } - - streamSuperclassMembers(node: TslClass | undefined): Stream { - if (!node) { - return EMPTY_STREAM; - } - - return this.streamProperSuperclasses(node).flatMap(getClassMembers); - } - - /** - * Returns the parent class of the given class, or undefined if there is no parent class. Only the first parent - * type is considered, i.e. multiple inheritance is not supported. - */ - private parentClass(node: TslClass | undefined): TslClass | undefined { - const [firstParentType] = getParentTypes(node); - if (isTslNamedType(firstParentType)) { - const declaration = firstParentType.declaration?.ref; - if (isTslClass(declaration)) { - return declaration; - } - } - - return undefined; - } - - /** - * Returns the member that is overridden by the given member, or `undefined` if the member does not override - * anything. - */ - getOverriddenMember(node: TslClassMember | undefined): TslClassMember | undefined { - // Static members cannot override anything - if (!node || isStatic(node)) { - return undefined; - } - - // Don't consider members with the same name as a previous member - const containingClass = AstUtils.getContainerOfType(node, isTslClass); - if (!containingClass) { - return undefined; - } - const firstMemberWithSameName = getClassMembers(containingClass).find( - (it) => !isStatic(it) && it.name === node.name, - ); - if (firstMemberWithSameName !== node) { - return undefined; - } - - return this.streamSuperclassMembers(containingClass) - .filter((it) => !isStatic(it) && it.name === node.name) - .head(); - } -} diff --git a/packages/ttsl-lang/src/language/typing/safe-ds-type-checker.ts b/packages/ttsl-lang/src/language/typing/safe-ds-type-checker.ts index 5ad3a758..1dff7d06 100644 --- a/packages/ttsl-lang/src/language/typing/safe-ds-type-checker.ts +++ b/packages/ttsl-lang/src/language/typing/safe-ds-type-checker.ts @@ -1,6 +1,5 @@ -import { isTslCallable, TslDeclaration } from '../generated/ast.js'; +import { TslDeclaration } from '../generated/ast.js'; import { Parameter } from '../helpers/nodeProperties.js'; -import { Constant, NullConstant } from '../partialEvaluation/model.js'; import { SafeDsServices } from '../safe-ds-module.js'; import { CallableType, @@ -11,19 +10,14 @@ import { UnionType, UnknownType, } from './model.js'; -import { SafeDsClassHierarchy } from './safe-ds-class-hierarchy.js'; import { SafeDsCoreTypes } from './safe-ds-core-types.js'; import type { SafeDsTypeComputer } from './safe-ds-type-computer.js'; -import { isEmpty } from '../../helpers/collections.js'; -import { AstUtils } from 'langium'; export class SafeDsTypeChecker { - private readonly classHierarchy: SafeDsClassHierarchy; private readonly coreTypes: SafeDsCoreTypes; private readonly typeComputer: () => SafeDsTypeComputer; constructor(services: SafeDsServices) { - this.classHierarchy = services.types.ClassHierarchy; this.coreTypes = services.types.CoreTypes; this.typeComputer = () => services.types.TypeComputer; } From e6b39c03ddc6c06b330a6a67a606ae9980031d6b Mon Sep 17 00:00:00 2001 From: methr0 Date: Mon, 1 Jul 2024 15:28:29 +0200 Subject: [PATCH 106/183] remove unnecessary functions in model.ts --- .../flow/safe-ds-call-graph-computer.ts | 7 - .../src/language/partialEvaluation/model.ts | 128 +----------------- .../safe-ds-partial-evaluator.ts | 49 ++----- 3 files changed, 18 insertions(+), 166 deletions(-) diff --git a/packages/ttsl-lang/src/language/flow/safe-ds-call-graph-computer.ts b/packages/ttsl-lang/src/language/flow/safe-ds-call-graph-computer.ts index bdc082b6..035491a6 100644 --- a/packages/ttsl-lang/src/language/flow/safe-ds-call-graph-computer.ts +++ b/packages/ttsl-lang/src/language/flow/safe-ds-call-graph-computer.ts @@ -15,7 +15,6 @@ import type { SafeDsNodeMapper } from '../helpers/safe-ds-node-mapper.js'; import type { SafeDsServices } from '../safe-ds-module.js'; import { EvaluatedCallable, - EvaluatedEnumVariant, NamedCallable, ParameterSubstitutions, substitutionsAreEqual, @@ -215,12 +214,6 @@ export class SafeDsCallGraphComputer { const value = this.partialEvaluator.evaluate(expression, substitutions); if (value instanceof EvaluatedCallable) { return value; - } else if (value instanceof EvaluatedEnumVariant) { - if (!value.hasBeenInstantiated) { - return new NamedCallable(value.variant); - } - - return undefined; } // Fall back to getting the called parameter via the type computer diff --git a/packages/ttsl-lang/src/language/partialEvaluation/model.ts b/packages/ttsl-lang/src/language/partialEvaluation/model.ts index 78964daa..3dacfed3 100644 --- a/packages/ttsl-lang/src/language/partialEvaluation/model.ts +++ b/packages/ttsl-lang/src/language/partialEvaluation/model.ts @@ -1,20 +1,16 @@ import { stream } from 'langium'; import { - type TslAbstractResult, - type TslBlockLambda, - type TslBlockLambdaResult, + TslResult, type TslCallable, type TslDeclaration, - type TslEnumVariant, type TslExpression, - type TslExpressionLambda, type TslParameter, } from '../generated/ast.js'; -import { getParameters, streamBlockLambdaResults } from '../helpers/nodeProperties.js'; +import { getParameters } from '../helpers/nodeProperties.js'; import { escapeString } from '../grammar/safe-ds-value-converter.js'; export type ParameterSubstitutions = Map; -export type ResultSubstitutions = Map; +export type ResultSubstitutions = Map; /** * A node that has been partially evaluated. @@ -154,64 +150,6 @@ export abstract class EvaluatedCallable extends EvaluatedNode { override readonly isFullyEvaluated: boolean = false; } -export class BlockLambdaClosure extends EvaluatedCallable { - readonly results: TslBlockLambdaResult[]; - - constructor( - override readonly callable: TslBlockLambda, - override readonly substitutionsOnCreation: ParameterSubstitutions, - ) { - super(); - this.results = streamBlockLambdaResults(callable).toArray(); - } - - override equals(other: unknown): boolean { - if (other === this) { - return true; - } else if (!(other instanceof BlockLambdaClosure)) { - return false; - } - - return ( - this.callable === other.callable && - substitutionsAreEqual(this.substitutionsOnCreation, other.substitutionsOnCreation) - ); - } - - override toString(): string { - return `$blockLambdaClosure`; - } -} - -export class ExpressionLambdaClosure extends EvaluatedCallable { - readonly result: TslExpression; - - constructor( - override readonly callable: TslExpressionLambda, - override readonly substitutionsOnCreation: ParameterSubstitutions, - ) { - super(); - this.result = callable.result; - } - - override equals(other: unknown): boolean { - if (other === this) { - return true; - } else if (!(other instanceof ExpressionLambdaClosure)) { - return false; - } - - return ( - this.callable === other.callable && - substitutionsAreEqual(this.substitutionsOnCreation, other.substitutionsOnCreation) - ); - } - - override toString(): string { - return '$expressionLambdaClosure'; - } -} - export class NamedCallable extends EvaluatedCallable { override readonly isFullyEvaluated: boolean = false; override readonly substitutionsOnCreation: ParameterSubstitutions = new Map(); @@ -233,66 +171,6 @@ export class NamedCallable this.substitutions?.get(it)?.isFullyEvaluated ?? false, - ); - - /** - * Returns the substitution for the parameter with the given name. If the parameter is not specified, - * `UnknownEvaluatedNode` is returned. - * - * @param name The name of the parameter to look for. - */ - getParameterValueByName(name: string): EvaluatedNode { - if (!this.substitutions) { - return UnknownEvaluatedNode; - } - - const parameter = getParameters(this.variant).find((it) => it.name === name); - if (!parameter) { - return UnknownEvaluatedNode; - } - - return this.substitutions.get(parameter) ?? UnknownEvaluatedNode; - } - - override equals(other: unknown): boolean { - if (other === this) { - return true; - } else if (!(other instanceof EvaluatedEnumVariant)) { - return false; - } - - return ( - this.variant === other.variant && - this.hasBeenInstantiated === other.hasBeenInstantiated && - substitutionsAreEqual(this.substitutions, other.substitutions) - ); - } - - override toString(): string { - if (!this.substitutions) { - return this.variant.name; - } else { - const parameterValues = getParameters(this.variant) - .map((it) => `${it.name} = ${this.substitutions?.get(it) ?? UnknownEvaluatedNode}`) - .join(', '); - - return `${this.variant.name}(${parameterValues})`; - } - } -} - export class EvaluatedList extends EvaluatedNode { constructor(readonly elements: EvaluatedNode[]) { super(); diff --git a/packages/ttsl-lang/src/language/partialEvaluation/safe-ds-partial-evaluator.ts b/packages/ttsl-lang/src/language/partialEvaluation/safe-ds-partial-evaluator.ts index a18a543e..24ea991f 100644 --- a/packages/ttsl-lang/src/language/partialEvaluation/safe-ds-partial-evaluator.ts +++ b/packages/ttsl-lang/src/language/partialEvaluation/safe-ds-partial-evaluator.ts @@ -49,21 +49,18 @@ import { isTslTimeunit, isTslString, } from '../generated/ast.js'; -import { getArguments, getParameters } from '../helpers/nodeProperties.js'; +import { getArguments, getParameters, getResults } from '../helpers/nodeProperties.js'; import { SafeDsNodeMapper } from '../helpers/safe-ds-node-mapper.js'; import { SafeDsServices } from '../safe-ds-module.js'; import { - BlockLambdaClosure, BooleanConstant, Constant, EvaluatedCallable, - EvaluatedEnumVariant, EvaluatedList, EvaluatedMap, EvaluatedMapEntry, EvaluatedNamedTuple, EvaluatedNode, - ExpressionLambdaClosure, FloatConstant, IntConstant, isConstant, @@ -480,9 +477,7 @@ export class SafeDsPartialEvaluator { const receiver = this.evaluateWithRecursionCheck(node.receiver, substitutions, visited).unwrap(); const args = getArguments(node); - if (receiver instanceof EvaluatedEnumVariant) { - return this.evaluateEnumVariantCall(receiver, args, substitutions, visited); - } else if (receiver instanceof EvaluatedCallable) { + if (receiver instanceof EvaluatedCallable) { return this.evaluateCallableCall( receiver.callable, args, @@ -517,28 +512,6 @@ export class SafeDsPartialEvaluator { } /* c8 ignore stop */ } - private evaluateEnumVariantCall( - receiver: EvaluatedEnumVariant, - args: TslArgument[], - substitutions: Map, - visited: VisitedState[], - ) { - // The enum variant has already been instantiated - if (receiver.hasBeenInstantiated) { - return UnknownEvaluatedNode; - } - - const parameterSubstitutionsAfterCall = this.getParameterSubstitutionsAfterCall( - receiver.variant, - args, - NO_SUBSTITUTIONS, - substitutions, - visited, - ); - - return new EvaluatedEnumVariant(receiver.variant, parameterSubstitutionsAfterCall); - } - private evaluateCallableCall( callable: TslCallable | TslParameter, args: TslArgument[], @@ -558,8 +531,18 @@ export class SafeDsPartialEvaluator { substitutionsOnCall, visited, ); - - return UnknownEvaluatedNode; + if (isTslFunction(callable)) { + return new EvaluatedNamedTuple( + new Map( + getResults(callable).map((it) => [ + it, + this.evaluateWithRecursionCheck(it, parameterSubstitutionsAfterCall, visited), + ]), + ), + ); + } else { + return UnknownEvaluatedNode; + } } private getParameterSubstitutionsAfterCall( @@ -636,9 +619,7 @@ export class SafeDsPartialEvaluator { } const receiver = this.evaluateWithRecursionCheck(node.receiver, substitutions, visited); - if (receiver instanceof EvaluatedEnumVariant) { - return receiver.getParameterValueByName(member.name); - } else if (receiver instanceof EvaluatedNamedTuple) { + if (receiver instanceof EvaluatedNamedTuple) { return receiver.getResultValueByName(member.name); } else if (receiver.equals(NullConstant) && node.isNullSafe) { return NullConstant; From 5f7c4b72998d28383524f466c6604c480d6f2ec8 Mon Sep 17 00:00:00 2001 From: methr0 Date: Mon, 1 Jul 2024 17:12:53 +0200 Subject: [PATCH 107/183] update syntax description --- packages/ttsl-vscode/snippets/ttsl.json | 75 +------------------------ 1 file changed, 1 insertion(+), 74 deletions(-) diff --git a/packages/ttsl-vscode/snippets/ttsl.json b/packages/ttsl-vscode/snippets/ttsl.json index a6d1464f..d9ee72a2 100644 --- a/packages/ttsl-vscode/snippets/ttsl.json +++ b/packages/ttsl-vscode/snippets/ttsl.json @@ -4,84 +4,11 @@ "body": ["from $1 import $0"], "description": "Import of declarations from a package." }, - "Minimal Annotation": { - "prefix": ["minimal-annotation"], - "body": ["annotation ${0:MyAnnotation}"], - "description": "A minimal annotation." - }, - "Annotation": { - "prefix": ["annotation"], - "body": ["annotation ${1:MyAnnotation}${2:($3)} ${4:where {$0\\}}"], - "description": "An annotation." - }, - "Attribute": { - "prefix": ["attribute"], - "body": ["${1|static |}attr ${2:myAttribute}: $0"], - "description": "An attribute." - }, - "Minimal Class": { - "prefix": ["minimal-class"], - "body": ["class ${0:MyClass}"], - "description": "A minimal class." - }, - "Class": { - "prefix": ["class"], - "body": ["class ${1:MyClass}${2:<$3>}${4:($5)} ${6:sub $7} ${8:where {$9\\}} ${10:{$0\\}}"], - "description": "A class." - }, - "Enum": { - "prefix": ["enumeration"], - "body": ["enum ${1:MyEnum} {", " $0", "}"], - "description": "An enumeration." - }, - "Minimal Pure Function": { - "prefix": ["minimal-pure-function"], - "body": ["@Pure", "fun ${1:myFunction}($0)"], - "description": "A minimal pure function." - }, "Function": { "prefix": ["function"], "body": ["function ${1:myFunction}($2)${3:: $4}{", " $0", "}"], "description": "A function." }, - "Minimal Pure Method": { - "prefix": ["minimal-pure-method"], - "body": ["@Pure", "${1|static |}fun ${2:myMethod}($0)"], - "description": "A minimal pure method." - }, - "Method": { - "prefix": ["method"], - "body": [ - "${1|@Pure,@Impure([])|}", - "${2|static |}fun ${3:myMethod}${4:<$5>}($6) ${7:-> ($8)} ${9:where {$0\\}}" - ], - "description": "A method." - }, - "Schema": { - "prefix": ["schema"], - "body": ["schema ${1:MySchema} {", " $0", "}"], - "description": "A schema." - }, - "Pipeline": { - "prefix": ["pipeline"], - "body": ["pipeline ${1:myPipeline} {", " $0", "}"], - "description": "A pipeline." - }, - "Segment": { - "prefix": ["segment"], - "body": ["${1|internal ,private |}segment ${2:mySegment}($3) ${4:-> ($5)} {", " $0", "}"], - "description": "A segment." - }, - "Block Lambda": { - "prefix": ["block-lambda"], - "body": ["($1) -> {", " $0", "}"], - "description": "A lambda that executes a list of statements." - }, - "Expression Lambda": { - "prefix": ["expression-lambda"], - "body": ["($1) -> $0"], - "description": "A lambda that returns a single expression." - }, "Block Comment": { "prefix": ["block-comment"], "body": ["/*", " * $0", " */"], @@ -144,7 +71,7 @@ }, "TimeStamp": { "prefix": ["from-to"], - "body": ["from ${1:$2-$3-$4} to ${5 $6-$7-$8}"], + "body": ["from $1-$2-$3 to $4-$5-$6"], "description": "A Timestamp from one Date to another." }, "LocalVariable": { From e59d5d43e0dd3116d2d002bdc10c67bc1f167d3b Mon Sep 17 00:00:00 2001 From: methr0 Date: Mon, 1 Jul 2024 17:24:21 +0200 Subject: [PATCH 108/183] rename fileExtensions --- packages/ttsl-lang/src/helpers/resources.ts | 4 +- .../language/builtins/ttsl-ds-functions.ts | 2 +- .../generation/safe-ds-python-generator.ts | 6 +-- .../src/language/helpers/fileExtensions.ts | 52 +++---------------- .../ttsl-lang/tests/helpers/testResources.ts | 4 +- 5 files changed, 15 insertions(+), 53 deletions(-) diff --git a/packages/ttsl-lang/src/helpers/resources.ts b/packages/ttsl-lang/src/helpers/resources.ts index 85e70238..d43b6f7f 100644 --- a/packages/ttsl-lang/src/helpers/resources.ts +++ b/packages/ttsl-lang/src/helpers/resources.ts @@ -2,7 +2,7 @@ import { globSync } from 'glob'; import { URI } from 'langium'; import path from 'path'; import { fileURLToPath } from 'url'; -import { SAFE_DS_FILE_EXTENSIONS } from '../language/helpers/fileExtensions.js'; +import { TSL_FILE_EXTENSIONS } from '../language/helpers/fileExtensions.js'; let RESOURCES_PATH: string; try { @@ -52,7 +52,7 @@ export const uriToShortenedResourceName = (uri: URI, rootResourceName?: Resource * @return URIs of the discovered Safe-DS files. */ export const listSafeDsFiles = (rootResourceName: ResourceName): URI[] => { - const pattern = `**/*.{${SAFE_DS_FILE_EXTENSIONS.join(',')}}`; + const pattern = `**/*.{${TSL_FILE_EXTENSIONS.join(',')}}`; const cwd = resourceNameToUri(rootResourceName).fsPath; return globSync(pattern, { cwd, nodir: true }).map((it) => URI.file(path.join(cwd, it))); diff --git a/packages/ttsl-lang/src/language/builtins/ttsl-ds-functions.ts b/packages/ttsl-lang/src/language/builtins/ttsl-ds-functions.ts index b4df9a5f..22a564cc 100644 --- a/packages/ttsl-lang/src/language/builtins/ttsl-ds-functions.ts +++ b/packages/ttsl-lang/src/language/builtins/ttsl-ds-functions.ts @@ -7,7 +7,7 @@ import { SafeDsPartialEvaluator } from "../partialEvaluation/safe-ds-partial-eva import { SafeDsServices } from "../safe-ds-module.js"; import { SafeDsModuleMembers } from "./safe-ds-module-members.js"; -const CODE_GENERATION_URI = resourceNameToUri('builtins/safeds/lang/codeGeneration.sdsstub'); +const CODE_GENERATION_URI = resourceNameToUri('builtins/safeds/lang/codeGeneration.ttsl'); export class TTSLFunction extends SafeDsModuleMembers { private readonly nodeMapper: SafeDsNodeMapper; diff --git a/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts b/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts index fd23181a..100196b2 100644 --- a/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts +++ b/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts @@ -66,7 +66,7 @@ import { TslTimeunit, isTslExpression, } from '../generated/ast.js'; -import { isInStubFile, isStubFile } from '../helpers/fileExtensions.js'; +import { isInFile, isFile } from '../helpers/fileExtensions.js'; import { getArguments, getAssignees, @@ -295,7 +295,7 @@ export class SafeDsPythonGenerator { const node = document.parseResult.value; // Do not generate stub files - if (isStubFile(document) || !isTslModule(node)) { + if (isFile(document) || !isTslModule(node)) { return []; } @@ -1216,7 +1216,7 @@ export class SafeDsPythonGenerator { // Root Node is always a module. const currentModule = AstUtils.findRootNode(expression); const targetModule = AstUtils.findRootNode(declaration); - if (currentModule !== targetModule && !isInStubFile(targetModule)) { + if (currentModule !== targetModule && !isInFile(targetModule)) { return { importPath: `${this.getPythonModuleOrDefault(targetModule)}.${this.formatGeneratedFileName( this.getModuleFileBaseName(targetModule), diff --git a/packages/ttsl-lang/src/language/helpers/fileExtensions.ts b/packages/ttsl-lang/src/language/helpers/fileExtensions.ts index f4986c8f..dd061b0a 100644 --- a/packages/ttsl-lang/src/language/helpers/fileExtensions.ts +++ b/packages/ttsl-lang/src/language/helpers/fileExtensions.ts @@ -1,69 +1,31 @@ import { AstNode, AstUtils, LangiumDocument } from 'langium'; /** - * Marks the file as a pipeline file, which can be executed by our runtime component. * - * @see isInPipelineFile - * @see isPipelineFile + * @see isInFile + * @see isFile */ -export const PIPELINE_FILE_EXTENSION = 'Tslpipe'; - -/** - * Marks the file as a stub file, which describes an external API. - * - * @see isInStubFile - * @see isStubFile - */ -export const STUB_FILE_EXTENSION = 'Tslstub'; - -/** - * Marks the file as a test file, which disables some checks to simplify its use as input of test cases. This file - * type is only used by language developers. - * - * @see isInTestFile - * @see isTestFile - */ -export const TEST_FILE_EXTENSION = 'ttsl'; +export const FILE_EXTENSION = 'ttsl'; /** * All file extensions that are supported by the Safe-DS language. */ -export const SAFE_DS_FILE_EXTENSIONS = [PIPELINE_FILE_EXTENSION, STUB_FILE_EXTENSION, TEST_FILE_EXTENSION]; +export const TSL_FILE_EXTENSIONS = [FILE_EXTENSION]; /** * All file extensions that are supported by the Safe-DS language. */ -export type TslFileExtension = typeof PIPELINE_FILE_EXTENSION | typeof STUB_FILE_EXTENSION | typeof TEST_FILE_EXTENSION; - -/** - * Returns whether the object is contained in a pipeline file. - */ -export const isInPipelineFile = (node: AstNode) => isPipelineFile(AstUtils.getDocument(node)); +export type TslFileExtension = typeof FILE_EXTENSION; /** * Returns whether the object is contained in a stub file. */ -export const isInStubFile = (node: AstNode) => isStubFile(AstUtils.getDocument(node)); - -/** - * Returns whether the object is contained in a test file. - */ -export const isInTestFile = (node: AstNode) => isTestFile(AstUtils.getDocument(node)); - -/** - * Returns whether the resource represents a pipeline file. - */ -export const isPipelineFile = (document: LangiumDocument) => hasExtension(document, PIPELINE_FILE_EXTENSION); +export const isInFile = (node: AstNode) => isFile(AstUtils.getDocument(node)); /** * Returns whether the resource represents a stub file. */ -export const isStubFile = (document: LangiumDocument) => hasExtension(document, STUB_FILE_EXTENSION); - -/** - * Returns whether the resource represents a test file. - */ -export const isTestFile = (document: LangiumDocument) => hasExtension(document, TEST_FILE_EXTENSION); +export const isFile = (document: LangiumDocument) => hasExtension(document, FILE_EXTENSION); /** * Returns whether the resource represents a file with the given extension. diff --git a/packages/ttsl-lang/tests/helpers/testResources.ts b/packages/ttsl-lang/tests/helpers/testResources.ts index e4fe532e..05e0a20e 100644 --- a/packages/ttsl-lang/tests/helpers/testResources.ts +++ b/packages/ttsl-lang/tests/helpers/testResources.ts @@ -1,6 +1,6 @@ import path from 'path'; import { globSync } from 'glob'; -import { SAFE_DS_FILE_EXTENSIONS } from '../../src/language/helpers/fileExtensions.js'; +import { TSL_FILE_EXTENSIONS } from '../../src/language/helpers/fileExtensions.js'; import { BuildOptions, LangiumDocument, URI } from 'langium'; import { SafeDsServices } from '../../src/language/index.js'; import { groupBy } from '../../src/helpers/collections.js'; @@ -51,7 +51,7 @@ export const uriToShortenedTestResourceName = ( */ export const listTestSafeDsFiles = (rootTestResourceName: TestResourceName): URI[] => { const rootPath = testResourceNameToUri(rootTestResourceName).fsPath; - return listTestFilesWithExtensions(rootTestResourceName, SAFE_DS_FILE_EXTENSIONS).filter((uri) => + return listTestFilesWithExtensions(rootTestResourceName, TSL_FILE_EXTENSIONS).filter((uri) => isNotSkipped(path.relative(rootPath, uri.fsPath)), ); }; From 106113d70ad89b06dd34810d11290eb2cbf50b89 Mon Sep 17 00:00:00 2001 From: methr0 Date: Mon, 1 Jul 2024 17:46:39 +0200 Subject: [PATCH 109/183] update file names and test file extensions --- .github/linters/.markdown-link-check.json | 2 +- docs/README.md | 2 +- docs/development/call-graph-testing.md | 2 +- docs/development/formatting-testing.md | 4 +- docs/development/generation-testing.md | 2 +- docs/development/grammar-testing.md | 2 +- .../development/partial-evaluation-testing.md | 2 +- docs/development/scoping-testing.md | 2 +- docs/development/typing-testing.md | 2 +- docs/development/validation-testing.md | 2 +- docs/language/common/expressions.md | 2 +- docs/mkdocs.yml | 4 +- package-lock.json | 2 +- packages/ttsl-cli/README.md | 4 +- packages/ttsl-cli/package.json | 4 +- packages/ttsl-cli/src/cli/check.ts | 4 +- packages/ttsl-cli/src/cli/exitCode.ts | 4 +- packages/ttsl-cli/src/cli/format.ts | 6 +- packages/ttsl-cli/src/cli/generate.ts | 4 +- packages/ttsl-cli/src/cli/main.ts | 4 +- packages/ttsl-cli/src/helpers/documents.ts | 10 +- packages/ttsl-cli/tests/cli/main.test.ts | 26 +-- .../ttsl-cli/tests/helpers/documents.test.ts | 8 +- ...ns errors.sdstest => contains errors.ttsl} | 0 ...arnings.sdstest => contains warnings.ttsl} | 0 .../check/{correct.sdstest => correct.ttsl} | 0 .../check/{not safe-ds.txt => not ttsl.txt} | 0 ...ltins.sdstest => references builtins.ttsl} | 0 ...rs.sdstest => contains syntax errors.ttsl} | 0 .../format/{correct.sdstest => correct.ttsl} | 0 .../format/{not safe-ds.txt => not ttsl.txt} | 0 ...ns errors.sdstest => contains errors.ttsl} | 0 .../{correct.sdstest => correct.ttsl} | 0 .../{not safe-ds.txt => not ttsl.txt} | 0 ...ltins.sdstest => references builtins.ttsl} | 0 .../processPaths/{a.sdspipe => a.ttsl} | 0 .../processPaths/{b.sdsstub => b.ttsl} | 0 .../processPaths/{c.sdstest => c.ttsl} | 0 .../processPaths/nested/{a.sdspipe => a.ttsl} | 0 .../processPaths/nested/{b.sdsstub => b.ttsl} | 0 .../processPaths/nested/{c.sdstest => c.ttsl} | 0 packages/ttsl-lang/README.md | 2 +- packages/ttsl-lang/package.json | 2 +- packages/ttsl-lang/src/helpers/resources.ts | 8 +- .../src/language/builtins/fileFinder.ts | 6 +- .../src/language/builtins/packageNames.ts | 2 +- .../language/builtins/ttsl-ds-functions.ts | 18 +- ...dule-members.ts => ttsl-module-members.ts} | 6 +- ...t-provider.ts => ttsl-comment-provider.ts} | 2 +- ...ider.ts => ttsl-documentation-provider.ts} | 2 +- ...omputer.ts => ttsl-call-graph-computer.ts} | 18 +- ...-generator.ts => ttsl-python-generator.ts} | 16 +- ...e-converter.ts => ttsl-value-converter.ts} | 2 +- .../src/language/helpers/fileExtensions.ts | 4 +- .../src/language/helpers/idManager.ts | 2 +- ...-ds-node-mapper.ts => ttsl-node-mapper.ts} | 10 +- packages/ttsl-lang/src/language/index.ts | 4 +- ...der.ts => ttsl-call-hierarchy-provider.ts} | 18 +- ...er.ts => ttsl-document-symbol-provider.ts} | 10 +- ...safe-ds-formatter.ts => ttsl-formatter.ts} | 2 +- ...rovider.ts => ttsl-inlay-hint-provider.ts} | 16 +- ...provider.ts => ttsl-node-info-provider.ts} | 10 +- ...provider.ts => ttsl-node-kind-provider.ts} | 2 +- ...me-provider.ts => ttsl-rename-provider.ts} | 6 +- ...der.ts => ttsl-semantic-token-provider.ts} | 6 +- ...der.ts => ttsl-signature-help-provider.ts} | 16 +- packages/ttsl-lang/src/language/main.ts | 4 +- .../src/language/partialEvaluation/model.ts | 2 +- ...evaluator.ts => ttsl-partial-evaluator.ts} | 10 +- .../ttsl-lang/src/language/safe-ds-module.ts | 196 ------------------ ...mputation.ts => ttsl-scope-computation.ts} | 2 +- ...ope-provider.ts => ttsl-scope-provider.ts} | 22 +- .../ttsl-lang/src/language/ttsl-module.ts | 196 ++++++++++++++++++ .../ttsl-lang/src/language/typing/model.ts | 38 ++-- ...fe-ds-core-types.ts => ttsl-core-types.ts} | 10 +- ...s-type-checker.ts => ttsl-type-checker.ts} | 16 +- ...type-computer.ts => ttsl-type-computer.ts} | 18 +- ...s-type-factory.ts => ttsl-type-factory.ts} | 6 +- .../experimentalLanguageFeatures.ts | 4 +- .../src/language/validation/names.ts | 10 +- .../validation/other/argumentLists.ts | 8 +- .../other/declarations/parameters.ts | 6 +- .../other/declarations/placeholders.ts | 4 +- .../validation/other/expressions/calls.ts | 6 +- .../other/expressions/chainedExpressions.ts | 4 +- .../other/expressions/indexedAccess.ts | 4 +- .../other/expressions/infixOperations.ts | 4 +- .../src/language/validation/other/imports.ts | 6 +- .../other/statements/assignments.ts | 6 +- .../src/language/validation/style.ts | 12 +- ...safe-ds-validator.ts => ttsl-validator.ts} | 4 +- .../src/language/validation/types.ts | 22 +- ...nt-builder.ts => ttsl-document-builder.ts} | 2 +- ...age-manager.ts => ttsl-package-manager.ts} | 6 +- ...-provider.ts => ttsl-settings-provider.ts} | 6 +- ...e-manager.ts => ttsl-workspace-manager.ts} | 2 +- .../safeds/lang/annotationUsage.sdsstub | 2 +- .../safeds/lang/codeGeneration.sdsstub | 2 +- .../builtins/safeds/lang/coreClasses.sdsstub | 2 +- .../safeds/lang/ideIntegration.sdsstub | 2 +- .../builtins/safeds/lang/maturity.sdsstub | 2 +- .../builtins/safeds/lang/purity.sdsstub | 2 +- .../tests/helpers/nodeFinder.test.ts | 6 +- .../ttsl-lang/tests/helpers/nodeFinder.ts | 8 +- .../ttsl-lang/tests/helpers/resources.test.ts | 6 +- .../tests/helpers/testResources.test.ts | 26 +-- .../ttsl-lang/tests/helpers/testResources.ts | 18 +- .../builtins/builtinFilesCorrectness.test.ts | 4 +- .../safe-ds-comment-provider.test.ts | 6 +- .../safe-ds-documentation-provider.test.ts | 6 +- .../ttsl-lang/tests/language/flow/creator.ts | 8 +- .../tests/language/flow/model.test.ts | 4 +- .../flow/safe-ds-call-graph-computer.test.ts | 6 +- .../tests/language/generation/creator.ts | 8 +- .../safe-ds-python-generator.test.ts | 4 +- .../tests/language/grammar/creator.ts | 4 +- .../language/grammar/safe-ds-grammar.test.ts | 4 +- .../grammar/safe-ds-value-converter.test.ts | 6 +- .../argumentToParameter.test.ts | 6 +- .../assigneeToAssignedObject.test.ts | 6 +- .../callToCallable.test.ts | 6 +- .../callToParameterValue.test.ts | 8 +- .../parameterToReferences.test.ts | 6 +- .../parametersToArguments.test.ts | 8 +- .../placeholdersToReferences.test.ts | 6 +- .../resultToYields.test.ts | 6 +- .../typeArgumentToTypeParameter.test.ts | 6 +- .../tests/language/lsp/formatting/creator.ts | 8 +- .../lsp/formatting/safe-ds-formatter.test.ts | 4 +- .../safe-ds-call-hierarchy-provider.test.ts | 10 +- .../safe-ds-document-symbol-provider.test.ts | 6 +- .../lsp/safe-ds-inlay-hint-provider.test.ts | 6 +- .../lsp/safe-ds-rename-provider.test.ts | 6 +- .../safe-ds-semantic-token-provider.test.ts | 8 +- .../safe-ds-signature-help-provider.test.ts | 8 +- .../safe-ds-type-hierarchy-provider.test.ts | 8 +- .../canBeValueOfConstantParameter.test.ts | 8 +- .../language/partialEvaluation/creator.ts | 8 +- .../language/partialEvaluation/model.test.ts | 4 +- .../safe-ds-partial-evalutator.test.ts | 4 +- .../tests/language/purity/model.test.ts | 4 +- .../purity/safe-ds-purity-computer.test.ts | 6 +- .../tests/language/scoping/creator.ts | 8 +- .../tests/language/scoping/scoping.test.ts | 4 +- .../tests/language/typing/model.test.ts | 4 +- .../typing/safe-ds-class-hierarchy.test.ts | 6 +- .../canBeTypeOfConstantParameter.test.ts | 8 +- .../type checker/isSubOrSupertypeOf.test.ts | 8 +- .../computeClassTypeForLiteralType.test.ts | 4 +- .../type computer/computeUpperBound.test.ts | 4 +- .../language/typing/type computer/creator.ts | 8 +- .../safe-ds-type-computer.test.ts | 4 +- .../type computer/streamSupertypes.test.ts | 4 +- .../tests/language/validation/creator.ts | 8 +- .../validation/safe-ds-validator.test.ts | 4 +- .../workspace/safe-ds-package-manager.test.ts | 6 +- .../safe-ds-workspace-manager.test.ts | 6 +- .../callWithRunnerIntegration/gen_input.py | 36 ++-- .../gen_input.py | 24 +-- .../gen_context_same_package.py | 6 +- .../importsWithRunnerIntegration/gen_input.py | 18 +- .../gen_input.py | 18 +- .../gen_input.py | 12 +- ...ain no imports or own declarations.sdstest | 4 +- ... with imports and own declarations.sdstest | 6 +- ...with multiple imports of same name.sdstest | 4 +- ...n with qualified import with alias.sdstest | 10 +- .../main with qualified import.sdstest | 8 +- .../main with wildcard import.sdstest | 8 +- .../resource safeds package.sdstest | 8 +- ...ain no imports or own declarations.sdstest | 4 +- ... with imports and own declarations.sdstest | 6 +- ...with multiple imports of same name.sdstest | 4 +- ...n with qualified import with alias.sdstest | 10 +- .../main with qualified import.sdstest | 8 +- .../main with wildcard import.sdstest | 8 +- .../resource safeds package.sdstest | 8 +- ...ain no imports or own declarations.sdstest | 4 +- ... with imports and own declarations.sdstest | 6 +- ...with multiple imports of same name.sdstest | 4 +- ...n with qualified import with alias.sdstest | 10 +- .../main with qualified import.sdstest | 8 +- .../main with wildcard import.sdstest | 8 +- .../resource safeds package.sdstest | 8 +- ...ain no imports or own declarations.sdstest | 4 +- ... with imports and own declarations.sdstest | 6 +- ...with multiple imports of same name.sdstest | 4 +- ...n with qualified import with alias.sdstest | 10 +- .../main with qualified import.sdstest | 8 +- .../main with wildcard import.sdstest | 8 +- .../resource safeds package.sdstest | 8 +- ...ain no imports or own declarations.sdstest | 4 +- ... with imports and own declarations.sdstest | 6 +- ...with multiple imports of same name.sdstest | 4 +- ...n with qualified import with alias.sdstest | 10 +- .../main with qualified import.sdstest | 8 +- .../main with wildcard import.sdstest | 8 +- .../resource safeds package.sdstest | 8 +- ...ain no imports or own declarations.sdstest | 4 +- ... with imports and own declarations.sdstest | 6 +- ...with multiple imports of same name.sdstest | 4 +- ...n with qualified import with alias.sdstest | 10 +- .../main with qualified import.sdstest | 8 +- .../main with wildcard import.sdstest | 8 +- .../resource safeds package.sdstest | 8 +- ...ain no imports or own declarations.sdstest | 4 +- ... with imports and own declarations.sdstest | 6 +- ...with multiple imports of same name.sdstest | 4 +- ...n with qualified import with alias.sdstest | 10 +- .../main with qualified import.sdstest | 8 +- .../main with wildcard import.sdstest | 8 +- .../resource safeds package.sdstest | 8 +- ...ain no imports or own declarations.sdstest | 2 +- ... with imports and own declarations.sdstest | 4 +- ...with multiple imports of same name.sdstest | 2 +- ...n with qualified import with alias.sdstest | 6 +- .../main with qualified import.sdstest | 4 +- .../main with wildcard import.sdstest | 4 +- .../resource safeds package.sdstest | 8 +- ...ain no imports or own declarations.sdstest | 4 +- ... with imports and own declarations.sdstest | 6 +- ...with multiple imports of same name.sdstest | 4 +- ...n with qualified import with alias.sdstest | 10 +- .../main with qualified import.sdstest | 8 +- .../main with wildcard import.sdstest | 8 +- .../resource safeds package.sdstest | 8 +- ...ain no imports or own declarations.sdstest | 8 +- ... with imports and own declarations.sdstest | 10 +- ...with multiple imports of same name.sdstest | 4 +- ...n with qualified import with alias.sdstest | 14 +- .../main with qualified import.sdstest | 12 +- .../main with wildcard import.sdstest | 12 +- .../resource safeds package.sdstest | 16 +- .../annotations/pythonModule/error.sdstest | 2 +- .../pythonModule/no annotation.sdstest | 2 +- .../annotations/pythonModule/no error.sdstest | 4 +- .../identical to safe-ds name/main.sdstest | 8 +- .../no annotation.sdstest | 4 +- .../safeds lang any.sdstest | 2 +- .../names/core names/in safeds lang.sdstest | 2 +- .../duplicates/across files/safeds 1.sdstest | 2 +- .../duplicates/across files/safeds 2.sdstest | 2 +- .../pipe elsewhere.sdspipe | 4 +- .../pipe in safeds.sdspipe | 4 +- .../pipe in subpackage of safeds.sdspipe | 4 +- .../stub elsewhere.sdsstub | 4 +- .../stub in safeds.sdsstub | 4 +- .../stub in subpackage of safeds.sdsstub | 4 +- .../test elsewhere.sdstest | 4 +- .../test in safeds.sdstest | 4 +- .../test in subpackage of safeds.sdstest | 4 +- packages/ttsl-vscode/README.md | 4 +- packages/ttsl-vscode/package.json | 16 +- .../src/extension/commands/dumpDiagnostics.ts | 4 +- .../ttsl-vscode/src/extension/mainClient.ts | 8 +- packages/ttsl-vscode/src/extension/output.ts | 4 +- release.config.cjs | 4 +- 257 files changed, 1008 insertions(+), 1008 deletions(-) rename packages/ttsl-cli/tests/resources/check/{contains errors.sdstest => contains errors.ttsl} (100%) rename packages/ttsl-cli/tests/resources/check/{contains warnings.sdstest => contains warnings.ttsl} (100%) rename packages/ttsl-cli/tests/resources/check/{correct.sdstest => correct.ttsl} (100%) rename packages/ttsl-cli/tests/resources/check/{not safe-ds.txt => not ttsl.txt} (100%) rename packages/ttsl-cli/tests/resources/check/{references builtins.sdstest => references builtins.ttsl} (100%) rename packages/ttsl-cli/tests/resources/format/{contains syntax errors.sdstest => contains syntax errors.ttsl} (100%) rename packages/ttsl-cli/tests/resources/format/{correct.sdstest => correct.ttsl} (100%) rename packages/ttsl-cli/tests/resources/format/{not safe-ds.txt => not ttsl.txt} (100%) rename packages/ttsl-cli/tests/resources/generate/{contains errors.sdstest => contains errors.ttsl} (100%) rename packages/ttsl-cli/tests/resources/generate/{correct.sdstest => correct.ttsl} (100%) rename packages/ttsl-cli/tests/resources/generate/{not safe-ds.txt => not ttsl.txt} (100%) rename packages/ttsl-cli/tests/resources/generate/{references builtins.sdstest => references builtins.ttsl} (100%) rename packages/ttsl-cli/tests/resources/processPaths/{a.sdspipe => a.ttsl} (100%) rename packages/ttsl-cli/tests/resources/processPaths/{b.sdsstub => b.ttsl} (100%) rename packages/ttsl-cli/tests/resources/processPaths/{c.sdstest => c.ttsl} (100%) rename packages/ttsl-cli/tests/resources/processPaths/nested/{a.sdspipe => a.ttsl} (100%) rename packages/ttsl-cli/tests/resources/processPaths/nested/{b.sdsstub => b.ttsl} (100%) rename packages/ttsl-cli/tests/resources/processPaths/nested/{c.sdstest => c.ttsl} (100%) rename packages/ttsl-lang/src/language/builtins/{safe-ds-module-members.ts => ttsl-module-members.ts} (88%) rename packages/ttsl-lang/src/language/documentation/{safe-ds-comment-provider.ts => ttsl-comment-provider.ts} (93%) rename packages/ttsl-lang/src/language/documentation/{safe-ds-documentation-provider.ts => ttsl-documentation-provider.ts} (97%) rename packages/ttsl-lang/src/language/flow/{safe-ds-call-graph-computer.ts => ttsl-call-graph-computer.ts} (95%) rename packages/ttsl-lang/src/language/generation/{safe-ds-python-generator.ts => ttsl-python-generator.ts} (99%) rename packages/ttsl-lang/src/language/grammar/{safe-ds-value-converter.ts => ttsl-value-converter.ts} (98%) rename packages/ttsl-lang/src/language/helpers/{safe-ds-node-mapper.ts => ttsl-node-mapper.ts} (96%) rename packages/ttsl-lang/src/language/lsp/{safe-ds-call-hierarchy-provider.ts => ttsl-call-hierarchy-provider.ts} (91%) rename packages/ttsl-lang/src/language/lsp/{safe-ds-document-symbol-provider.ts => ttsl-document-symbol-provider.ts} (82%) rename packages/ttsl-lang/src/language/lsp/{safe-ds-formatter.ts => ttsl-formatter.ts} (99%) rename packages/ttsl-lang/src/language/lsp/{safe-ds-inlay-hint-provider.ts => ttsl-inlay-hint-provider.ts} (77%) rename packages/ttsl-lang/src/language/lsp/{safe-ds-node-info-provider.ts => ttsl-node-info-provider.ts} (66%) rename packages/ttsl-lang/src/language/lsp/{safe-ds-node-kind-provider.ts => ttsl-node-kind-provider.ts} (96%) rename packages/ttsl-lang/src/language/lsp/{safe-ds-rename-provider.ts => ttsl-rename-provider.ts} (96%) rename packages/ttsl-lang/src/language/lsp/{safe-ds-semantic-token-provider.ts => ttsl-semantic-token-provider.ts} (95%) rename packages/ttsl-lang/src/language/lsp/{safe-ds-signature-help-provider.ts => ttsl-signature-help-provider.ts} (87%) rename packages/ttsl-lang/src/language/partialEvaluation/{safe-ds-partial-evaluator.ts => ttsl-partial-evaluator.ts} (99%) delete mode 100644 packages/ttsl-lang/src/language/safe-ds-module.ts rename packages/ttsl-lang/src/language/scoping/{safe-ds-scope-computation.ts => ttsl-scope-computation.ts} (97%) rename packages/ttsl-lang/src/language/scoping/{safe-ds-scope-provider.ts => ttsl-scope-provider.ts} (94%) create mode 100644 packages/ttsl-lang/src/language/ttsl-module.ts rename packages/ttsl-lang/src/language/typing/{safe-ds-core-types.ts => ttsl-core-types.ts} (91%) rename packages/ttsl-lang/src/language/typing/{safe-ds-type-checker.ts => ttsl-type-checker.ts} (94%) rename packages/ttsl-lang/src/language/typing/{safe-ds-type-computer.ts => ttsl-type-computer.ts} (97%) rename packages/ttsl-lang/src/language/typing/{safe-ds-type-factory.ts => ttsl-type-factory.ts} (88%) rename packages/ttsl-lang/src/language/validation/{safe-ds-validator.ts => ttsl-validator.ts} (98%) rename packages/ttsl-lang/src/language/workspace/{safe-ds-document-builder.ts => ttsl-document-builder.ts} (80%) rename packages/ttsl-lang/src/language/workspace/{safe-ds-package-manager.ts => ttsl-package-manager.ts} (97%) rename packages/ttsl-lang/src/language/workspace/{safe-ds-settings-provider.ts => ttsl-settings-provider.ts} (90%) rename packages/ttsl-lang/src/language/workspace/{safe-ds-workspace-manager.ts => ttsl-workspace-manager.ts} (92%) diff --git a/.github/linters/.markdown-link-check.json b/.github/linters/.markdown-link-check.json index c180c151..8408a38a 100644 --- a/.github/linters/.markdown-link-check.json +++ b/.github/linters/.markdown-link-check.json @@ -7,7 +7,7 @@ "pattern": "^#" }, { - "pattern": "^https://github.com/Safe-DS/DSL/blob/main" + "pattern": "^https://github.com/TTSL/DSL/blob/main" } ] } diff --git a/docs/README.md b/docs/README.md index 29a42fec..1f4e7783 100644 --- a/docs/README.md +++ b/docs/README.md @@ -2,4 +2,4 @@ A domain-specific language (DSL) to simulate taxes and transfers. -This project is based on the [Safe-DS](https://github.com/Safe-DS/DSL) DSL for statically checked Data Science programs. +This project is based on the [TTSL](https://github.com/TTSL/DSL) DSL for statically checked Data Science programs. diff --git a/docs/development/call-graph-testing.md b/docs/development/call-graph-testing.md index 0e4098a8..9a47746c 100644 --- a/docs/development/call-graph-testing.md +++ b/docs/development/call-graph-testing.md @@ -12,7 +12,7 @@ graph test. If you want to skip a test, add the prefix `skip-` to the file name. -2. Add the Safe-DS code that you want to test to the file. +2. Add the TTSL code that you want to test to the file. 3. Surround calls or callables for which you want to compute a call graph with test markers, e.g. `»f()«`. Add a comment in the preceding line with the following format: ```ts diff --git a/docs/development/formatting-testing.md b/docs/development/formatting-testing.md index 3f78133c..dfb711d5 100644 --- a/docs/development/formatting-testing.md +++ b/docs/development/formatting-testing.md @@ -12,10 +12,10 @@ formatting test. If you want to skip a test, add the prefix `skip-` to the file name. -2. Add the original unformatted Safe-DS code to the top of the file. The code must be syntactically valid. +2. Add the original unformatted TTSL code to the top of the file. The code must be syntactically valid. 3. Add the following separator to the file: ```Tsl // ----------------------------------------------------------------------------- ``` -4. Add the expected formatted Safe-DS code to the file below the separator. +4. Add the expected formatted TTSL code to the file below the separator. 5. Run the tests. The test runner will automatically pick up the new test. diff --git a/docs/development/generation-testing.md b/docs/development/generation-testing.md index e098ec80..170353dd 100644 --- a/docs/development/generation-testing.md +++ b/docs/development/generation-testing.md @@ -18,7 +18,7 @@ generation test. folder will be loaded into the same workspace, so they can reference each other. Files in different folders are loaded into different workspaces, so they cannot reference each other. Generation will be triggered for all files in the folder. -3. Add the Safe-DS code that you want to test to the files. +3. Add the TTSL code that you want to test to the files. 4. If you want to run the program only up to a specific placeholder of a pipeline, surround **the name** of that placeholder with test markers, e.g. `val »a« = 1;`. You may only mark a single placeholder this way. Add a comment in the preceding line with the following format: diff --git a/docs/development/grammar-testing.md b/docs/development/grammar-testing.md index 4f681d6c..2a80ed85 100644 --- a/docs/development/grammar-testing.md +++ b/docs/development/grammar-testing.md @@ -33,7 +33,7 @@ test. By convention, the comment should be placed at the start of the file. -3. Add the Safe-DS code that you want to test to the file. +3. Add the TTSL code that you want to test to the file. 4. Run the tests. The test runner will automatically pick up the new test. [^1]: We do not differentiate whether the error originated in the lexer (error code `lexing-error`) or the actual parser (error code `parsing-error`). Both are treated as syntax errors. diff --git a/docs/development/partial-evaluation-testing.md b/docs/development/partial-evaluation-testing.md index 526a5f85..8aecdc1a 100644 --- a/docs/development/partial-evaluation-testing.md +++ b/docs/development/partial-evaluation-testing.md @@ -15,7 +15,7 @@ partial evaluation test. 2. Add files with the extension `.ttsl` **directly inside the folder**. All files in a folder will be loaded into the same workspace, so they can reference each other. Files in different folders are loaded into different workspaces, so they cannot reference each other. -3. Add the Safe-DS code that you want to test to the files. +3. Add the TTSL code that you want to test to the files. 4. Surround entire nodes whose value you want to check with test markers, e.g. `1 + 2`. 5. For each pair of test markers, add a test comment with one of the formats listed below. Test comments and test markers are mapped to each other by their position in the file, i.e. the first test comment corresponds to the first diff --git a/docs/development/scoping-testing.md b/docs/development/scoping-testing.md index db1701ef..b3bd4482 100644 --- a/docs/development/scoping-testing.md +++ b/docs/development/scoping-testing.md @@ -15,7 +15,7 @@ test. 2. Add files with the extension `.ttsl` **directly inside the folder**. All files in a folder will be loaded into the same workspace, so they can reference each other. Files in different folders are loaded into different workspaces, so they cannot reference each other. -3. Add the Safe-DS code that you want to test to the files. +3. Add the TTSL code that you want to test to the files. 4. Surround **the name** of any declaration that you want to reference with test markers, e.g. `class »C«`. Add a comment in the preceding line with the following format (replace `` with some unique identifier): ```ts diff --git a/docs/development/typing-testing.md b/docs/development/typing-testing.md index daef3682..57bb5f90 100644 --- a/docs/development/typing-testing.md +++ b/docs/development/typing-testing.md @@ -15,7 +15,7 @@ test. 2. Add files with the extension `.ttsl` **directly inside the folder**. All files in a folder will be loaded into the same workspace, so they can reference each other. Files in different folders are loaded into different workspaces, so they cannot reference each other. -3. Add the Safe-DS code that you want to test to the files. +3. Add the TTSL code that you want to test to the files. 4. Surround entire nodes whose type you want to check with test markers, e.g. `1 + 2`. For declarations, it is also possible to surround only their name, e.g. `class »C«`. 5. For each pair of test markers, add a test comment with one of the formats listed below. Test comments and test diff --git a/docs/development/validation-testing.md b/docs/development/validation-testing.md index d7c38d36..fec2efe9 100644 --- a/docs/development/validation-testing.md +++ b/docs/development/validation-testing.md @@ -15,7 +15,7 @@ validation test. 2. Add files with the extension `.ttsl`, `.Tslpipe`, or `.Tslstub` **directly inside the folder**. All files in a folder will be loaded into the same workspace, so they can reference each other. Files in different folders are loaded into different workspaces, so they cannot reference each other. -3. Add the Safe-DS code that you want to test to the files. +3. Add the TTSL code that you want to test to the files. 4. Specify the expected validation results using test comments (see [below](#format-of-test-comments)) and test markers (e.g. `fun »F«()`). The test comments are used to specify * the presence or absence of an issue, diff --git a/docs/language/common/expressions.md b/docs/language/common/expressions.md index 4f1f47ed..18981b5d 100644 --- a/docs/language/common/expressions.md +++ b/docs/language/common/expressions.md @@ -48,7 +48,7 @@ In order to interpolate text with other computed values, use [template strings]( ### Boolean Literals -To work with truthiness, Safe-DS has the two boolean literals `#!ttsl false` and `#!ttsl true`. +To work with truthiness, TTSL has the two boolean literals `#!ttsl false` and `#!ttsl true`. ### `#!ttsl null` Literal diff --git a/docs/mkdocs.yml b/docs/mkdocs.yml index 99b4515a..de29b596 100644 --- a/docs/mkdocs.yml +++ b/docs/mkdocs.yml @@ -40,8 +40,8 @@ nav: theme: name: material - logo: https://raw.githubusercontent.com/Safe-DS/.github/main/branding/safe-ds_logo_rounded.svg - favicon: https://raw.githubusercontent.com/Safe-DS/.github/main/branding/safe-ds_logo_rounded.svg + logo: https://raw.githubusercontent.com/TTSL/.github/main/branding/ttsl_logo_rounded.svg + favicon: https://raw.githubusercontent.com/TTSL/.github/main/branding/ttsl_logo_rounded.svg palette: # Palette toggle for light mode - scheme: default diff --git a/package-lock.json b/package-lock.json index 24160e85..bd0ea1b9 100644 --- a/package-lock.json +++ b/package-lock.json @@ -11602,7 +11602,7 @@ "true-myth": "^7.1.0" }, "bin": { - "safe-ds": "bin/cli.js" + "ttsl": "bin/cli.js" }, "devDependencies": { "@types/node": "^18.18.12", diff --git a/packages/ttsl-cli/README.md b/packages/ttsl-cli/README.md index 6c959344..69d0878b 100644 --- a/packages/ttsl-cli/README.md +++ b/packages/ttsl-cli/README.md @@ -1,4 +1,4 @@ -# Safe-DS CLI +# TTSL CLI ```txt Usage: cli [options] [command] @@ -8,7 +8,7 @@ Options: -h, --help display help for command Commands: - check [options] check Safe-DS code + check [options] check TTSL code generate [options] generate Python code help [command] display help for command ``` diff --git a/packages/ttsl-cli/package.json b/packages/ttsl-cli/package.json index 4865aa5d..ead727eb 100644 --- a/packages/ttsl-cli/package.json +++ b/packages/ttsl-cli/package.json @@ -14,7 +14,7 @@ "programming language", "static checking" ], - "homepage": "https://dsl.safeds.com", + "homepage": "https://dsl.TTSL.com", "bugs": { "url": "https://github.com/SEEDS-Group/TTSL/issues" }, @@ -25,7 +25,7 @@ }, "type": "module", "bin": { - "safe-ds": "./bin/cli.js" + "ttsl": "./bin/cli.js" }, "exports": null, "files": [ diff --git a/packages/ttsl-cli/src/cli/check.ts b/packages/ttsl-cli/src/cli/check.ts index 4d25f9e2..e3fed5db 100644 --- a/packages/ttsl-cli/src/cli/check.ts +++ b/packages/ttsl-cli/src/cli/check.ts @@ -1,4 +1,4 @@ -import { createSafeDsServices } from '@ttsl/lang'; +import { createTTSLServices } from '@ttsl/lang'; import { NodeFileSystem } from 'langium/node'; import { extractDocuments } from '../helpers/documents.js'; import { diagnosticToString, getDiagnostics } from '../helpers/diagnostics.js'; @@ -7,7 +7,7 @@ import chalk from 'chalk'; import { ExitCode } from './exitCode.js'; export const check = async (fsPaths: string[], options: CheckOptions): Promise => { - const services = (await createSafeDsServices(NodeFileSystem)).SafeDs; + const services = (await createTTSLServices(NodeFileSystem)).TTSL; let errorCount = 0; diff --git a/packages/ttsl-cli/src/cli/exitCode.ts b/packages/ttsl-cli/src/cli/exitCode.ts index a729f69c..889dd5a8 100644 --- a/packages/ttsl-cli/src/cli/exitCode.ts +++ b/packages/ttsl-cli/src/cli/exitCode.ts @@ -18,9 +18,9 @@ export enum ExitCode { NotAFileOrDirectory = 101, /** - * The given file does not have a Safe-DS extension. + * The given file does not have a TTSL extension. */ - FileWithoutSafeDsExtension = 102, + FileWithoutTTSLExtension = 102, /** * The given file has errors. diff --git a/packages/ttsl-cli/src/cli/format.ts b/packages/ttsl-cli/src/cli/format.ts index 181a752d..8fa39e6e 100644 --- a/packages/ttsl-cli/src/cli/format.ts +++ b/packages/ttsl-cli/src/cli/format.ts @@ -1,4 +1,4 @@ -import { createSafeDsServices } from '@ttsl/lang'; +import { createTTSLServices } from '@ttsl/lang'; import { NodeFileSystem } from 'langium/node'; import { extractDocuments } from '../helpers/documents.js'; import { exitIfDocumentHasSyntaxErrors } from '../helpers/diagnostics.js'; @@ -7,7 +7,7 @@ import { writeFile } from 'node:fs/promises'; import chalk from 'chalk'; export const format = async (fsPaths: string[]): Promise => { - const services = (await createSafeDsServices(NodeFileSystem)).SafeDs; + const services = (await createTTSLServices(NodeFileSystem)).TTSL; const documents = await extractDocuments(services, fsPaths); // Exit if any document has syntax errors before formatting code @@ -31,5 +31,5 @@ export const format = async (fsPaths: string[]): Promise => { await writeFile(document.uri.fsPath, editedDocument); } - console.log(chalk.green(`Safe-DS code formatted successfully.`)); + console.log(chalk.green(`TTSL code formatted successfully.`)); }; diff --git a/packages/ttsl-cli/src/cli/generate.ts b/packages/ttsl-cli/src/cli/generate.ts index 25ccdb0c..9a885483 100644 --- a/packages/ttsl-cli/src/cli/generate.ts +++ b/packages/ttsl-cli/src/cli/generate.ts @@ -1,4 +1,4 @@ -import { createSafeDsServices } from '@ttsl/lang'; +import { createTTSLServices } from '@ttsl/lang'; import chalk from 'chalk'; import { URI } from 'langium'; import { NodeFileSystem } from 'langium/node'; @@ -9,7 +9,7 @@ import { makeParentDirectoriesSync } from '../helpers/files.js'; import { exitIfDocumentHasErrors } from '../helpers/diagnostics.js'; export const generate = async (fsPaths: string[], options: GenerateOptions): Promise => { - const services = (await createSafeDsServices(NodeFileSystem)).SafeDs; + const services = (await createTTSLServices(NodeFileSystem)).TTSL; const documents = await extractDocuments(services, fsPaths); // Exit if any document has errors before generating code diff --git a/packages/ttsl-cli/src/cli/main.ts b/packages/ttsl-cli/src/cli/main.ts index 1a443f25..ae7cf55b 100644 --- a/packages/ttsl-cli/src/cli/main.ts +++ b/packages/ttsl-cli/src/cli/main.ts @@ -17,14 +17,14 @@ program .command('check') .argument('', `list of files or directories to check`) .option('-s, --strict', 'whether the program should fail on warnings', false) - .description('check Safe-DS code') + .description('check TTSL code') .action(check); // Format command program .command('format') .argument('', `list of files or directories to format`) - .description('format Safe-DS code') + .description('format TTSL code') .action(format); // Generate command diff --git a/packages/ttsl-cli/src/helpers/documents.ts b/packages/ttsl-cli/src/helpers/documents.ts index 10452730..6f53ba34 100644 --- a/packages/ttsl-cli/src/helpers/documents.ts +++ b/packages/ttsl-cli/src/helpers/documents.ts @@ -31,13 +31,13 @@ export const extractDocuments = async function ( }; /** - * Processes the given paths and returns the corresponding URIs. Files must have a Safe-DS extension. Directories are + * Processes the given paths and returns the corresponding URIs. Files must have a TTSL extension. Directories are * traversed recursively. * * @returns The URIs of the matched files. */ export const processPaths = (services: LangiumServices, fsPaths: string[]): Result => { - // Safe-DS file extensions + // TTSL file extensions const extensions = services.LanguageMetaData.fileExtensions; const pattern = `**/*{${extensions.join(',')}}`; @@ -55,11 +55,11 @@ export const processPaths = (services: LangiumServices, fsPaths: string[]): Resu // Path must be a file or directory const stat = fs.lstatSync(fsPath); if (stat.isFile()) { - // File must have a Safe-DS extension + // File must have a TTSL extension if (!extensions.includes(path.extname(fsPath))) { return Result.err({ - message: `File '${fsPath}' does not have a Safe-DS extension.`, - code: ExitCode.FileWithoutSafeDsExtension, + message: `File '${fsPath}' does not have a TTSL extension.`, + code: ExitCode.FileWithoutTTSLExtension, }); } diff --git a/packages/ttsl-cli/tests/cli/main.test.ts b/packages/ttsl-cli/tests/cli/main.test.ts index 1903baa1..407f5af2 100644 --- a/packages/ttsl-cli/tests/cli/main.test.ts +++ b/packages/ttsl-cli/tests/cli/main.test.ts @@ -6,7 +6,7 @@ import { ExitCode } from '../../src/cli/exitCode.js'; const projectRoot = new URL('../..', import.meta.url); -describe('safe-ds', () => { +describe('ttsl', () => { beforeAll(() => { execSync('npm run build:clean', { cwd: projectRoot }); }); @@ -87,9 +87,9 @@ describe('safe-ds', () => { }); it('should show an error if a file has the wrong extension', () => { - const process = spawnCheckProcess([], ['not safe-ds.txt']); - expect(process.stderr.toString()).toContain('does not have a Safe-DS extension'); - expect(process.status).toBe(ExitCode.FileWithoutSafeDsExtension); + const process = spawnCheckProcess([], ['not ttsl.txt']); + expect(process.stderr.toString()).toContain('does not have a TTSL extension'); + expect(process.status).toBe(ExitCode.FileWithoutTTSLExtension); }); }); @@ -122,7 +122,7 @@ describe('safe-ds', () => { it('should show not show errors in correct files', () => { const process = spawnFormatProcess([], ['correct.ttsl']); - expect(process.stdout.toString()).toContain('Safe-DS code formatted successfully.'); + expect(process.stdout.toString()).toContain('TTSL code formatted successfully.'); expect(process.status).toBe(ExitCode.Success); }); @@ -133,9 +133,9 @@ describe('safe-ds', () => { }); it('should show an error if a file has the wrong extension', () => { - const process = spawnFormatProcess([], ['not safe-ds.txt']); - expect(process.stderr.toString()).toContain('does not have a Safe-DS extension'); - expect(process.status).toBe(ExitCode.FileWithoutSafeDsExtension); + const process = spawnFormatProcess([], ['not ttsl.txt']); + expect(process.stderr.toString()).toContain('does not have a TTSL extension'); + expect(process.status).toBe(ExitCode.FileWithoutTTSLExtension); }); }); @@ -170,7 +170,7 @@ describe('safe-ds', () => { expect(process.status).toBe(ExitCode.Success); }); - it('should generate Python code (Safe-DS code references builtins)', () => { + it('should generate Python code (TTSL code references builtins)', () => { const process = spawnGenerateProcess([], ['references builtins.ttsl']); expect(process.stdout.toString()).toContain('Python code generated successfully.'); expect(process.status).toBe(ExitCode.Success); @@ -183,12 +183,12 @@ describe('safe-ds', () => { }); it('should show an error if the file has the wrong extension', () => { - const process = spawnGenerateProcess([], ['not safe-ds.txt']); - expect(process.stderr.toString()).toContain('does not have a Safe-DS extension'); - expect(process.status).toBe(ExitCode.FileWithoutSafeDsExtension); + const process = spawnGenerateProcess([], ['not ttsl.txt']); + expect(process.stderr.toString()).toContain('does not have a TTSL extension'); + expect(process.status).toBe(ExitCode.FileWithoutTTSLExtension); }); - it('should show an error if a Safe-DS file has errors', () => { + it('should show an error if a TTSL file has errors', () => { const process = spawnGenerateProcess([], ['.']); expect(process.stderr.toString()).toContain( "Could not resolve reference to TslNamedTypeDeclaration named 'Unresolved'", diff --git a/packages/ttsl-cli/tests/helpers/documents.test.ts b/packages/ttsl-cli/tests/helpers/documents.test.ts index d4b01851..e7886350 100644 --- a/packages/ttsl-cli/tests/helpers/documents.test.ts +++ b/packages/ttsl-cli/tests/helpers/documents.test.ts @@ -1,14 +1,14 @@ import { describe, expect, it } from 'vitest'; import { Result } from 'true-myth'; import { processPaths } from '../../src/helpers/documents.js'; -import { createSafeDsServices } from '@ttsl/lang'; +import { createTTSLServices } from '@ttsl/lang'; import { NodeFileSystem } from 'langium/node'; import { fileURLToPath } from 'url'; import path from 'node:path'; import { ExitCode } from '../../src/cli/exitCode.js'; describe('processPaths', async () => { - const services = (await createSafeDsServices(NodeFileSystem)).SafeDs; + const services = (await createTTSLServices(NodeFileSystem)).TTSL; const testResourcesRoot = new URL('../resources/processPaths/', import.meta.url); const tests: ProcessPathsTest[] = [ @@ -55,9 +55,9 @@ describe('processPaths', async () => { expected: Result.err(ExitCode.MissingPath), }, { - testName: 'not a Safe-DS file', + testName: 'not a TTSL file', paths: ['d.txt'], - expected: Result.err(ExitCode.FileWithoutSafeDsExtension), + expected: Result.err(ExitCode.FileWithoutTTSLExtension), }, ]; diff --git a/packages/ttsl-cli/tests/resources/check/contains errors.sdstest b/packages/ttsl-cli/tests/resources/check/contains errors.ttsl similarity index 100% rename from packages/ttsl-cli/tests/resources/check/contains errors.sdstest rename to packages/ttsl-cli/tests/resources/check/contains errors.ttsl diff --git a/packages/ttsl-cli/tests/resources/check/contains warnings.sdstest b/packages/ttsl-cli/tests/resources/check/contains warnings.ttsl similarity index 100% rename from packages/ttsl-cli/tests/resources/check/contains warnings.sdstest rename to packages/ttsl-cli/tests/resources/check/contains warnings.ttsl diff --git a/packages/ttsl-cli/tests/resources/check/correct.sdstest b/packages/ttsl-cli/tests/resources/check/correct.ttsl similarity index 100% rename from packages/ttsl-cli/tests/resources/check/correct.sdstest rename to packages/ttsl-cli/tests/resources/check/correct.ttsl diff --git a/packages/ttsl-cli/tests/resources/check/not safe-ds.txt b/packages/ttsl-cli/tests/resources/check/not ttsl.txt similarity index 100% rename from packages/ttsl-cli/tests/resources/check/not safe-ds.txt rename to packages/ttsl-cli/tests/resources/check/not ttsl.txt diff --git a/packages/ttsl-cli/tests/resources/check/references builtins.sdstest b/packages/ttsl-cli/tests/resources/check/references builtins.ttsl similarity index 100% rename from packages/ttsl-cli/tests/resources/check/references builtins.sdstest rename to packages/ttsl-cli/tests/resources/check/references builtins.ttsl diff --git a/packages/ttsl-cli/tests/resources/format/contains syntax errors.sdstest b/packages/ttsl-cli/tests/resources/format/contains syntax errors.ttsl similarity index 100% rename from packages/ttsl-cli/tests/resources/format/contains syntax errors.sdstest rename to packages/ttsl-cli/tests/resources/format/contains syntax errors.ttsl diff --git a/packages/ttsl-cli/tests/resources/format/correct.sdstest b/packages/ttsl-cli/tests/resources/format/correct.ttsl similarity index 100% rename from packages/ttsl-cli/tests/resources/format/correct.sdstest rename to packages/ttsl-cli/tests/resources/format/correct.ttsl diff --git a/packages/ttsl-cli/tests/resources/format/not safe-ds.txt b/packages/ttsl-cli/tests/resources/format/not ttsl.txt similarity index 100% rename from packages/ttsl-cli/tests/resources/format/not safe-ds.txt rename to packages/ttsl-cli/tests/resources/format/not ttsl.txt diff --git a/packages/ttsl-cli/tests/resources/generate/contains errors.sdstest b/packages/ttsl-cli/tests/resources/generate/contains errors.ttsl similarity index 100% rename from packages/ttsl-cli/tests/resources/generate/contains errors.sdstest rename to packages/ttsl-cli/tests/resources/generate/contains errors.ttsl diff --git a/packages/ttsl-cli/tests/resources/generate/correct.sdstest b/packages/ttsl-cli/tests/resources/generate/correct.ttsl similarity index 100% rename from packages/ttsl-cli/tests/resources/generate/correct.sdstest rename to packages/ttsl-cli/tests/resources/generate/correct.ttsl diff --git a/packages/ttsl-cli/tests/resources/generate/not safe-ds.txt b/packages/ttsl-cli/tests/resources/generate/not ttsl.txt similarity index 100% rename from packages/ttsl-cli/tests/resources/generate/not safe-ds.txt rename to packages/ttsl-cli/tests/resources/generate/not ttsl.txt diff --git a/packages/ttsl-cli/tests/resources/generate/references builtins.sdstest b/packages/ttsl-cli/tests/resources/generate/references builtins.ttsl similarity index 100% rename from packages/ttsl-cli/tests/resources/generate/references builtins.sdstest rename to packages/ttsl-cli/tests/resources/generate/references builtins.ttsl diff --git a/packages/ttsl-cli/tests/resources/processPaths/a.sdspipe b/packages/ttsl-cli/tests/resources/processPaths/a.ttsl similarity index 100% rename from packages/ttsl-cli/tests/resources/processPaths/a.sdspipe rename to packages/ttsl-cli/tests/resources/processPaths/a.ttsl diff --git a/packages/ttsl-cli/tests/resources/processPaths/b.sdsstub b/packages/ttsl-cli/tests/resources/processPaths/b.ttsl similarity index 100% rename from packages/ttsl-cli/tests/resources/processPaths/b.sdsstub rename to packages/ttsl-cli/tests/resources/processPaths/b.ttsl diff --git a/packages/ttsl-cli/tests/resources/processPaths/c.sdstest b/packages/ttsl-cli/tests/resources/processPaths/c.ttsl similarity index 100% rename from packages/ttsl-cli/tests/resources/processPaths/c.sdstest rename to packages/ttsl-cli/tests/resources/processPaths/c.ttsl diff --git a/packages/ttsl-cli/tests/resources/processPaths/nested/a.sdspipe b/packages/ttsl-cli/tests/resources/processPaths/nested/a.ttsl similarity index 100% rename from packages/ttsl-cli/tests/resources/processPaths/nested/a.sdspipe rename to packages/ttsl-cli/tests/resources/processPaths/nested/a.ttsl diff --git a/packages/ttsl-cli/tests/resources/processPaths/nested/b.sdsstub b/packages/ttsl-cli/tests/resources/processPaths/nested/b.ttsl similarity index 100% rename from packages/ttsl-cli/tests/resources/processPaths/nested/b.sdsstub rename to packages/ttsl-cli/tests/resources/processPaths/nested/b.ttsl diff --git a/packages/ttsl-cli/tests/resources/processPaths/nested/c.sdstest b/packages/ttsl-cli/tests/resources/processPaths/nested/c.ttsl similarity index 100% rename from packages/ttsl-cli/tests/resources/processPaths/nested/c.sdstest rename to packages/ttsl-cli/tests/resources/processPaths/nested/c.ttsl diff --git a/packages/ttsl-lang/README.md b/packages/ttsl-lang/README.md index 9b7a7a7d..2d0fe1c8 100644 --- a/packages/ttsl-lang/README.md +++ b/packages/ttsl-lang/README.md @@ -1 +1 @@ -# Safe-DS Language Server +# TTSL Language Server diff --git a/packages/ttsl-lang/package.json b/packages/ttsl-lang/package.json index 5c9c52d1..01a5f5c5 100644 --- a/packages/ttsl-lang/package.json +++ b/packages/ttsl-lang/package.json @@ -14,7 +14,7 @@ "programming language", "static checking" ], - "homepage": "https://dsl.safeds.com", + "homepage": "https://dsl.TTSL.com", "bugs": { "url": "https://github.com/SEEDS-Group/TTSL/issues" }, diff --git a/packages/ttsl-lang/src/helpers/resources.ts b/packages/ttsl-lang/src/helpers/resources.ts index d43b6f7f..f0373fb0 100644 --- a/packages/ttsl-lang/src/helpers/resources.ts +++ b/packages/ttsl-lang/src/helpers/resources.ts @@ -9,7 +9,7 @@ try { // For CJS (ttsl-vscode) RESOURCES_PATH = path.join(__dirname, '..', 'resources'); } /* c8 ignore start */ catch (e) { - // For ESM (safe-ds-cli) + // For ESM (ttsl-cli) RESOURCES_PATH = fileURLToPath(new URL('../resources', import.meta.url)); } /* c8 ignore stop */ @@ -46,12 +46,12 @@ export const uriToShortenedResourceName = (uri: URI, rootResourceName?: Resource }; /** - * Lists all Safe-DS files in the given root directory. + * Lists all TTSL files in the given root directory. * * @param rootResourceName The resource name of the root directory. - * @return URIs of the discovered Safe-DS files. + * @return URIs of the discovered TTSL files. */ -export const listSafeDsFiles = (rootResourceName: ResourceName): URI[] => { +export const listTTSLFiles = (rootResourceName: ResourceName): URI[] => { const pattern = `**/*.{${TSL_FILE_EXTENSIONS.join(',')}}`; const cwd = resourceNameToUri(rootResourceName).fsPath; diff --git a/packages/ttsl-lang/src/language/builtins/fileFinder.ts b/packages/ttsl-lang/src/language/builtins/fileFinder.ts index a66d4f58..26f9e400 100644 --- a/packages/ttsl-lang/src/language/builtins/fileFinder.ts +++ b/packages/ttsl-lang/src/language/builtins/fileFinder.ts @@ -1,11 +1,11 @@ import { URI } from 'langium'; -import { listSafeDsFiles } from '../../helpers/resources.js'; +import { listTTSLFiles } from '../../helpers/resources.js'; /** - * Lists all Safe-DS files in `src/resources/builtins`. + * Lists all TTSL files in `src/resources/builtins`. * * @return URIs of all discovered files. */ export const listBuiltinFiles = (): URI[] => { - return listSafeDsFiles('builtins'); + return listTTSLFiles('builtins'); }; diff --git a/packages/ttsl-lang/src/language/builtins/packageNames.ts b/packages/ttsl-lang/src/language/builtins/packageNames.ts index 4e225348..7be13a53 100644 --- a/packages/ttsl-lang/src/language/builtins/packageNames.ts +++ b/packages/ttsl-lang/src/language/builtins/packageNames.ts @@ -1,2 +1,2 @@ -export const BUILTINS_ROOT_PACKAGE = 'safeds'; +export const BUILTINS_ROOT_PACKAGE = 'TTSL'; export const BUILTINS_LANG_PACKAGE = `${BUILTINS_ROOT_PACKAGE}.lang`; diff --git a/packages/ttsl-lang/src/language/builtins/ttsl-ds-functions.ts b/packages/ttsl-lang/src/language/builtins/ttsl-ds-functions.ts index 22a564cc..2f8eccbc 100644 --- a/packages/ttsl-lang/src/language/builtins/ttsl-ds-functions.ts +++ b/packages/ttsl-lang/src/language/builtins/ttsl-ds-functions.ts @@ -1,19 +1,19 @@ import { URI } from "langium"; import { resourceNameToUri } from "../../helpers/resources.js"; import { TslFunction, TslModule, TslObject, isTslFunction } from "../generated/ast.js"; -import { SafeDsNodeMapper } from "../helpers/safe-ds-node-mapper.js"; +import { TTSLNodeMapper } from "../helpers/ttsl-node-mapper.js"; import { EvaluatedNode, StringConstant, UnknownEvaluatedNode } from "../partialEvaluation/model.js"; -import { SafeDsPartialEvaluator } from "../partialEvaluation/safe-ds-partial-evaluator.js"; -import { SafeDsServices } from "../safe-ds-module.js"; -import { SafeDsModuleMembers } from "./safe-ds-module-members.js"; +import { TTSLPartialEvaluator } from "../partialEvaluation/ttsl-partial-evaluator.js"; +import { TTSLServices } from "../ttsl-module.js"; +import { TTSLModuleMembers } from "./ttsl-module-members.js"; -const CODE_GENERATION_URI = resourceNameToUri('builtins/safeds/lang/codeGeneration.ttsl'); +const CODE_GENERATION_URI = resourceNameToUri('builtins/TTSL/lang/codeGeneration.ttsl'); -export class TTSLFunction extends SafeDsModuleMembers { - private readonly nodeMapper: SafeDsNodeMapper; - private readonly partialEvaluator: SafeDsPartialEvaluator; +export class TTSLFunction extends TTSLModuleMembers { + private readonly nodeMapper: TTSLNodeMapper; + private readonly partialEvaluator: TTSLPartialEvaluator; - constructor(services: SafeDsServices) { + constructor(services: TTSLServices) { super(services); this.nodeMapper = services.helpers.NodeMapper; diff --git a/packages/ttsl-lang/src/language/builtins/safe-ds-module-members.ts b/packages/ttsl-lang/src/language/builtins/ttsl-module-members.ts similarity index 88% rename from packages/ttsl-lang/src/language/builtins/safe-ds-module-members.ts rename to packages/ttsl-lang/src/language/builtins/ttsl-module-members.ts index 2bb95c8e..15f14852 100644 --- a/packages/ttsl-lang/src/language/builtins/safe-ds-module-members.ts +++ b/packages/ttsl-lang/src/language/builtins/ttsl-module-members.ts @@ -1,13 +1,13 @@ -import { SafeDsServices } from '../safe-ds-module.js'; +import { TTSLServices } from '../ttsl-module.js'; import { isTslModule, TslModuleMember } from '../generated/ast.js'; import { LangiumDocuments, URI, WorkspaceCache } from 'langium'; import { getModuleMembers } from '../helpers/nodeProperties.js'; -export abstract class SafeDsModuleMembers { +export abstract class TTSLModuleMembers { private readonly langiumDocuments: LangiumDocuments; private readonly cache: WorkspaceCache; - constructor(services: SafeDsServices) { + constructor(services: TTSLServices) { this.langiumDocuments = services.shared.workspace.LangiumDocuments; this.cache = new WorkspaceCache(services.shared); } diff --git a/packages/ttsl-lang/src/language/documentation/safe-ds-comment-provider.ts b/packages/ttsl-lang/src/language/documentation/ttsl-comment-provider.ts similarity index 93% rename from packages/ttsl-lang/src/language/documentation/safe-ds-comment-provider.ts rename to packages/ttsl-lang/src/language/documentation/ttsl-comment-provider.ts index da2cdb96..0abf3383 100644 --- a/packages/ttsl-lang/src/language/documentation/safe-ds-comment-provider.ts +++ b/packages/ttsl-lang/src/language/documentation/ttsl-comment-provider.ts @@ -7,7 +7,7 @@ import { isTslResult, } from '../generated/ast.js'; -export class SafeDsCommentProvider extends DefaultCommentProvider { +export class TTSLCommentProvider extends DefaultCommentProvider { override getComment(node: AstNode): string | undefined { /* c8 ignore start */ if (isAstNodeWithComment(node)) { return node.$comment; diff --git a/packages/ttsl-lang/src/language/documentation/safe-ds-documentation-provider.ts b/packages/ttsl-lang/src/language/documentation/ttsl-documentation-provider.ts similarity index 97% rename from packages/ttsl-lang/src/language/documentation/safe-ds-documentation-provider.ts rename to packages/ttsl-lang/src/language/documentation/ttsl-documentation-provider.ts index 9ac76c62..3fdc6263 100644 --- a/packages/ttsl-lang/src/language/documentation/safe-ds-documentation-provider.ts +++ b/packages/ttsl-lang/src/language/documentation/ttsl-documentation-provider.ts @@ -20,7 +20,7 @@ const PARAM_TAG = 'param'; const RESULT_TAG = 'result'; const TYPE_PARAM_TAG = 'typeParam'; -export class SafeDsDocumentationProvider extends JSDocDocumentationProvider { +export class TTSLDocumentationProvider extends JSDocDocumentationProvider { override getDocumentation(node: AstNode): string | undefined { if (isTslParameter(node) || isTslResult(node)) { const containingCallable = AstUtils.getContainerOfType(node, isTslCallable); diff --git a/packages/ttsl-lang/src/language/flow/safe-ds-call-graph-computer.ts b/packages/ttsl-lang/src/language/flow/ttsl-call-graph-computer.ts similarity index 95% rename from packages/ttsl-lang/src/language/flow/safe-ds-call-graph-computer.ts rename to packages/ttsl-lang/src/language/flow/ttsl-call-graph-computer.ts index 035491a6..052743c5 100644 --- a/packages/ttsl-lang/src/language/flow/safe-ds-call-graph-computer.ts +++ b/packages/ttsl-lang/src/language/flow/ttsl-call-graph-computer.ts @@ -11,8 +11,8 @@ import { TslFunction, TslParameter, } from '../generated/ast.js'; -import type { SafeDsNodeMapper } from '../helpers/safe-ds-node-mapper.js'; -import type { SafeDsServices } from '../safe-ds-module.js'; +import type { TTSLNodeMapper } from '../helpers/ttsl-node-mapper.js'; +import type { TTSLServices } from '../ttsl-module.js'; import { EvaluatedCallable, NamedCallable, @@ -22,16 +22,16 @@ import { } from '../partialEvaluation/model.js'; import { CallGraph } from './model.js'; import { getArguments, getParameters } from '../helpers/nodeProperties.js'; -import { SafeDsTypeComputer } from '../typing/safe-ds-type-computer.js'; +import { TTSLTypeComputer } from '../typing/ttsl-type-computer.js'; import { CallableType } from '../typing/model.js'; import { isEmpty } from '../../helpers/collections.js'; -import { SafeDsPartialEvaluator } from '../partialEvaluation/safe-ds-partial-evaluator.js'; +import { TTSLPartialEvaluator } from '../partialEvaluation/ttsl-partial-evaluator.js'; -export class SafeDsCallGraphComputer { +export class TTSLCallGraphComputer { private readonly astNodeLocator: AstNodeLocator; - private readonly nodeMapper: SafeDsNodeMapper; - private readonly partialEvaluator: SafeDsPartialEvaluator; - private readonly typeComputer: SafeDsTypeComputer; + private readonly nodeMapper: TTSLNodeMapper; + private readonly partialEvaluator: TTSLPartialEvaluator; + private readonly typeComputer: TTSLTypeComputer; /** * Stores the calls inside the node with the given ID. @@ -43,7 +43,7 @@ export class SafeDsCallGraphComputer { */ private readonly callGraphCache: WorkspaceCache; - constructor(services: SafeDsServices) { + constructor(services: TTSLServices) { this.astNodeLocator = services.workspace.AstNodeLocator; this.nodeMapper = services.helpers.NodeMapper; this.partialEvaluator = services.evaluation.PartialEvaluator; diff --git a/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts b/packages/ttsl-lang/src/language/generation/ttsl-python-generator.ts similarity index 99% rename from packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts rename to packages/ttsl-lang/src/language/generation/ttsl-python-generator.ts index 100196b2..cbacbf4f 100644 --- a/packages/ttsl-lang/src/language/generation/safe-ds-python-generator.ts +++ b/packages/ttsl-lang/src/language/generation/ttsl-python-generator.ts @@ -79,14 +79,14 @@ import { getStatements, Parameter, } from '../helpers/nodeProperties.js'; -import { SafeDsNodeMapper } from '../helpers/safe-ds-node-mapper.js'; -import { SafeDsPartialEvaluator } from '../partialEvaluation/safe-ds-partial-evaluator.js'; -import { SafeDsServices } from '../safe-ds-module.js'; +import { TTSLNodeMapper } from '../helpers/ttsl-node-mapper.js'; +import { TTSLPartialEvaluator } from '../partialEvaluation/ttsl-partial-evaluator.js'; +import { TTSLServices } from '../ttsl-module.js'; import { TTSLFunction } from '../builtins/ttsl-ds-functions.js'; export const CODEGEN_PREFIX = '__gen_'; -const RUNNER_PACKAGE = 'safeds_runner'; +const RUNNER_PACKAGE = 'TTSL_runner'; const PYTHON_INDENT = ' '; const SPACING = new CompositeGeneratorNode(NL, NL); @@ -280,12 +280,12 @@ const UTILITY_TIMEUNIT_YEAR: UtilityFunction = { typeVariables: [`${CODEGEN_PREFIX}T`], }; -export class SafeDsPythonGenerator { +export class TTSLPythonGenerator { private readonly builtinFunction: TTSLFunction; - private readonly nodeMapper: SafeDsNodeMapper; - private readonly partialEvaluator: SafeDsPartialEvaluator; + private readonly nodeMapper: TTSLNodeMapper; + private readonly partialEvaluator: TTSLPartialEvaluator; - constructor(services: SafeDsServices) { + constructor(services: TTSLServices) { this.builtinFunction = services.builtins.Functions; this.nodeMapper = services.helpers.NodeMapper; this.partialEvaluator = services.evaluation.PartialEvaluator; diff --git a/packages/ttsl-lang/src/language/grammar/safe-ds-value-converter.ts b/packages/ttsl-lang/src/language/grammar/ttsl-value-converter.ts similarity index 98% rename from packages/ttsl-lang/src/language/grammar/safe-ds-value-converter.ts rename to packages/ttsl-lang/src/language/grammar/ttsl-value-converter.ts index 6e769d68..60c8d5b7 100644 --- a/packages/ttsl-lang/src/language/grammar/safe-ds-value-converter.ts +++ b/packages/ttsl-lang/src/language/grammar/ttsl-value-converter.ts @@ -1,6 +1,6 @@ import { CstNode, DefaultValueConverter, GrammarAST, ValueConverter, ValueType } from 'langium'; -export class SafeDsValueConverter extends DefaultValueConverter { +export class TTSLValueConverter extends DefaultValueConverter { protected override runConverter(rule: GrammarAST.AbstractRule, input: string, cstNode: CstNode): ValueType { switch (rule.name.toUpperCase()) { case 'ID': diff --git a/packages/ttsl-lang/src/language/helpers/fileExtensions.ts b/packages/ttsl-lang/src/language/helpers/fileExtensions.ts index dd061b0a..05360850 100644 --- a/packages/ttsl-lang/src/language/helpers/fileExtensions.ts +++ b/packages/ttsl-lang/src/language/helpers/fileExtensions.ts @@ -8,12 +8,12 @@ import { AstNode, AstUtils, LangiumDocument } from 'langium'; export const FILE_EXTENSION = 'ttsl'; /** - * All file extensions that are supported by the Safe-DS language. + * All file extensions that are supported by the TTSL language. */ export const TSL_FILE_EXTENSIONS = [FILE_EXTENSION]; /** - * All file extensions that are supported by the Safe-DS language. + * All file extensions that are supported by the TTSL language. */ export type TslFileExtension = typeof FILE_EXTENSION; diff --git a/packages/ttsl-lang/src/language/helpers/idManager.ts b/packages/ttsl-lang/src/language/helpers/idManager.ts index b2bd2cf3..f1b0a396 100644 --- a/packages/ttsl-lang/src/language/helpers/idManager.ts +++ b/packages/ttsl-lang/src/language/helpers/idManager.ts @@ -1,5 +1,5 @@ /** - * Handles the mapping of objects, usually nodes of a Safe-DS AST, to their IDs. + * Handles the mapping of objects, usually nodes of a TTSL AST, to their IDs. */ export class IdManager { /** diff --git a/packages/ttsl-lang/src/language/helpers/safe-ds-node-mapper.ts b/packages/ttsl-lang/src/language/helpers/ttsl-node-mapper.ts similarity index 96% rename from packages/ttsl-lang/src/language/helpers/safe-ds-node-mapper.ts rename to packages/ttsl-lang/src/language/helpers/ttsl-node-mapper.ts index bf68d56f..9d7e14ba 100644 --- a/packages/ttsl-lang/src/language/helpers/safe-ds-node-mapper.ts +++ b/packages/ttsl-lang/src/language/helpers/ttsl-node-mapper.ts @@ -18,9 +18,9 @@ import { TslReference, TslResult, } from '../generated/ast.js'; -import { SafeDsServices } from '../safe-ds-module.js'; +import { TTSLServices } from '../ttsl-module.js'; import { CallableType } from '../typing/model.js'; -import { SafeDsTypeComputer } from '../typing/safe-ds-type-computer.js'; +import { TTSLTypeComputer } from '../typing/ttsl-type-computer.js'; import { Argument, getArguments, @@ -28,10 +28,10 @@ import { getResults, } from './nodeProperties.js'; -export class SafeDsNodeMapper { - private readonly typeComputer: () => SafeDsTypeComputer; +export class TTSLNodeMapper { + private readonly typeComputer: () => TTSLTypeComputer; - constructor(services: SafeDsServices) { + constructor(services: TTSLServices) { this.typeComputer = () => services.types.TypeComputer; } diff --git a/packages/ttsl-lang/src/language/index.ts b/packages/ttsl-lang/src/language/index.ts index 570c8b91..542d597f 100644 --- a/packages/ttsl-lang/src/language/index.ts +++ b/packages/ttsl-lang/src/language/index.ts @@ -1,6 +1,6 @@ // Services -export type { SafeDsServices } from './safe-ds-module.js'; -export { createSafeDsServices } from './safe-ds-module.js'; +export type { TTSLServices } from './ttsl-module.js'; +export { createTTSLServices } from './ttsl-module.js'; // Language Server export { startLanguageServer } from './main.js'; diff --git a/packages/ttsl-lang/src/language/lsp/safe-ds-call-hierarchy-provider.ts b/packages/ttsl-lang/src/language/lsp/ttsl-call-hierarchy-provider.ts similarity index 91% rename from packages/ttsl-lang/src/language/lsp/safe-ds-call-hierarchy-provider.ts rename to packages/ttsl-lang/src/language/lsp/ttsl-call-hierarchy-provider.ts index 9d9e9cc3..939c2cd0 100644 --- a/packages/ttsl-lang/src/language/lsp/safe-ds-call-hierarchy-provider.ts +++ b/packages/ttsl-lang/src/language/lsp/ttsl-call-hierarchy-provider.ts @@ -6,7 +6,7 @@ import type { SymbolKind, SymbolTag, } from 'vscode-languageserver'; -import type { SafeDsCallGraphComputer } from '../flow/safe-ds-call-graph-computer.js'; +import type { TTSLCallGraphComputer } from '../flow/ttsl-call-graph-computer.js'; import { isTslDeclaration, isTslParameter, @@ -14,18 +14,18 @@ import { type TslCallable, type TslDeclaration, } from '../generated/ast.js'; -import type { SafeDsNodeMapper } from '../helpers/safe-ds-node-mapper.js'; -import type { SafeDsServices } from '../safe-ds-module.js'; -import type { SafeDsNodeInfoProvider } from './safe-ds-node-info-provider.js'; +import type { TTSLNodeMapper } from '../helpers/ttsl-node-mapper.js'; +import type { TTSLServices } from '../ttsl-module.js'; +import type { TTSLNodeInfoProvider } from './ttsl-node-info-provider.js'; import { AbstractCallHierarchyProvider, NodeKindProvider } from 'langium/lsp'; -export class SafeDsCallHierarchyProvider extends AbstractCallHierarchyProvider { - private readonly callGraphComputer: SafeDsCallGraphComputer; - private readonly nodeInfoProvider: SafeDsNodeInfoProvider; +export class TTSLCallHierarchyProvider extends AbstractCallHierarchyProvider { + private readonly callGraphComputer: TTSLCallGraphComputer; + private readonly nodeInfoProvider: TTSLNodeInfoProvider; private readonly nodeKindProvider: NodeKindProvider; - private readonly nodeMapper: SafeDsNodeMapper; + private readonly nodeMapper: TTSLNodeMapper; - constructor(services: SafeDsServices) { + constructor(services: TTSLServices) { super(services); this.callGraphComputer = services.flow.CallGraphComputer; diff --git a/packages/ttsl-lang/src/language/lsp/safe-ds-document-symbol-provider.ts b/packages/ttsl-lang/src/language/lsp/ttsl-document-symbol-provider.ts similarity index 82% rename from packages/ttsl-lang/src/language/lsp/safe-ds-document-symbol-provider.ts rename to packages/ttsl-lang/src/language/lsp/ttsl-document-symbol-provider.ts index 4a5ee166..c1d9545e 100644 --- a/packages/ttsl-lang/src/language/lsp/safe-ds-document-symbol-provider.ts +++ b/packages/ttsl-lang/src/language/lsp/ttsl-document-symbol-provider.ts @@ -3,14 +3,14 @@ import type { DocumentSymbol } from 'vscode-languageserver'; import { isTslFunction, } from '../generated/ast.js'; -import type { SafeDsServices } from '../safe-ds-module.js'; -import type { SafeDsNodeInfoProvider } from './safe-ds-node-info-provider.js'; +import type { TTSLServices } from '../ttsl-module.js'; +import type { TTSLNodeInfoProvider } from './ttsl-node-info-provider.js'; import { DefaultDocumentSymbolProvider } from 'langium/lsp'; -export class SafeDsDocumentSymbolProvider extends DefaultDocumentSymbolProvider { - private readonly nodeInfoProvider: SafeDsNodeInfoProvider; +export class TTSLDocumentSymbolProvider extends DefaultDocumentSymbolProvider { + private readonly nodeInfoProvider: TTSLNodeInfoProvider; - constructor(services: SafeDsServices) { + constructor(services: TTSLServices) { super(services); this.nodeInfoProvider = services.lsp.NodeInfoProvider; diff --git a/packages/ttsl-lang/src/language/lsp/safe-ds-formatter.ts b/packages/ttsl-lang/src/language/lsp/ttsl-formatter.ts similarity index 99% rename from packages/ttsl-lang/src/language/lsp/safe-ds-formatter.ts rename to packages/ttsl-lang/src/language/lsp/ttsl-formatter.ts index 08d11179..7c27b75f 100644 --- a/packages/ttsl-lang/src/language/lsp/safe-ds-formatter.ts +++ b/packages/ttsl-lang/src/language/lsp/ttsl-formatter.ts @@ -20,7 +20,7 @@ const newLinesWithIndent = function (count: number, options?: FormattingActionOp }; }; -export class SafeDsFormatter extends AbstractFormatter { +export class TTSLFormatter extends AbstractFormatter { protected override format(node: AstNode): void { // ----------------------------------------------------------------------------- // Module diff --git a/packages/ttsl-lang/src/language/lsp/safe-ds-inlay-hint-provider.ts b/packages/ttsl-lang/src/language/lsp/ttsl-inlay-hint-provider.ts similarity index 77% rename from packages/ttsl-lang/src/language/lsp/safe-ds-inlay-hint-provider.ts rename to packages/ttsl-lang/src/language/lsp/ttsl-inlay-hint-provider.ts index 36b8aed8..414590e0 100644 --- a/packages/ttsl-lang/src/language/lsp/safe-ds-inlay-hint-provider.ts +++ b/packages/ttsl-lang/src/language/lsp/ttsl-inlay-hint-provider.ts @@ -1,19 +1,19 @@ import { AstNode, DocumentationProvider } from 'langium'; import { InlayHintKind, MarkupContent } from 'vscode-languageserver'; -import { createMarkupContent } from '../documentation/safe-ds-comment-provider.js'; +import { createMarkupContent } from '../documentation/ttsl-comment-provider.js'; import { isTslArgument, isTslPlaceholder } from '../generated/ast.js'; import { Argument } from '../helpers/nodeProperties.js'; -import { SafeDsNodeMapper } from '../helpers/safe-ds-node-mapper.js'; -import { SafeDsServices } from '../safe-ds-module.js'; -import { SafeDsTypeComputer } from '../typing/safe-ds-type-computer.js'; +import { TTSLNodeMapper } from '../helpers/ttsl-node-mapper.js'; +import { TTSLServices } from '../ttsl-module.js'; +import { TTSLTypeComputer } from '../typing/ttsl-type-computer.js'; import { AbstractInlayHintProvider, InlayHintAcceptor } from 'langium/lsp'; -export class SafeDsInlayHintProvider extends AbstractInlayHintProvider { +export class TTSLInlayHintProvider extends AbstractInlayHintProvider { private readonly documentationProvider: DocumentationProvider; - private readonly nodeMapper: SafeDsNodeMapper; - private readonly typeComputer: SafeDsTypeComputer; + private readonly nodeMapper: TTSLNodeMapper; + private readonly typeComputer: TTSLTypeComputer; - constructor(services: SafeDsServices) { + constructor(services: TTSLServices) { super(); this.documentationProvider = services.documentation.DocumentationProvider; diff --git a/packages/ttsl-lang/src/language/lsp/safe-ds-node-info-provider.ts b/packages/ttsl-lang/src/language/lsp/ttsl-node-info-provider.ts similarity index 66% rename from packages/ttsl-lang/src/language/lsp/safe-ds-node-info-provider.ts rename to packages/ttsl-lang/src/language/lsp/ttsl-node-info-provider.ts index 167cb6ea..be272de5 100644 --- a/packages/ttsl-lang/src/language/lsp/safe-ds-node-info-provider.ts +++ b/packages/ttsl-lang/src/language/lsp/ttsl-node-info-provider.ts @@ -1,12 +1,12 @@ import { AstNode } from 'langium'; import { isTslFunction } from '../generated/ast.js'; -import type { SafeDsServices } from '../safe-ds-module.js'; -import { SafeDsTypeComputer } from '../typing/safe-ds-type-computer.js'; +import type { TTSLServices } from '../ttsl-module.js'; +import { TTSLTypeComputer } from '../typing/ttsl-type-computer.js'; -export class SafeDsNodeInfoProvider { - private readonly typeComputer: SafeDsTypeComputer; +export class TTSLNodeInfoProvider { + private readonly typeComputer: TTSLTypeComputer; - constructor(services: SafeDsServices) { + constructor(services: TTSLServices) { this.typeComputer = services.types.TypeComputer; } diff --git a/packages/ttsl-lang/src/language/lsp/safe-ds-node-kind-provider.ts b/packages/ttsl-lang/src/language/lsp/ttsl-node-kind-provider.ts similarity index 96% rename from packages/ttsl-lang/src/language/lsp/safe-ds-node-kind-provider.ts rename to packages/ttsl-lang/src/language/lsp/ttsl-node-kind-provider.ts index c6dcca07..c68811ce 100644 --- a/packages/ttsl-lang/src/language/lsp/safe-ds-node-kind-provider.ts +++ b/packages/ttsl-lang/src/language/lsp/ttsl-node-kind-provider.ts @@ -9,7 +9,7 @@ import { } from '../generated/ast.js'; import { NodeKindProvider } from 'langium/lsp'; -export class SafeDsNodeKindProvider implements NodeKindProvider { +export class TTSLNodeKindProvider implements NodeKindProvider { getSymbolKind(nodeOrDescription: AstNode | AstNodeDescription): SymbolKind { // The WorkspaceSymbolProvider only passes descriptions, where the node might be undefined const type = this.getNodeType(nodeOrDescription); diff --git a/packages/ttsl-lang/src/language/lsp/safe-ds-rename-provider.ts b/packages/ttsl-lang/src/language/lsp/ttsl-rename-provider.ts similarity index 96% rename from packages/ttsl-lang/src/language/lsp/safe-ds-rename-provider.ts rename to packages/ttsl-lang/src/language/lsp/ttsl-rename-provider.ts index 3b75cc52..8238921f 100644 --- a/packages/ttsl-lang/src/language/lsp/safe-ds-rename-provider.ts +++ b/packages/ttsl-lang/src/language/lsp/ttsl-rename-provider.ts @@ -10,16 +10,16 @@ import { URI, } from 'langium'; import { Position, RenameParams, TextEdit, WorkspaceEdit } from 'vscode-languageserver'; -import { SafeDsServices } from '../safe-ds-module.js'; +import { TTSLServices } from '../ttsl-module.js'; import { isTslImportedDeclaration, isTslModule } from '../generated/ast.js'; import { getImportedDeclarations } from '../helpers/nodeProperties.js'; import { DefaultRenameProvider } from 'langium/lsp'; -export class SafeDsRenameProvider extends DefaultRenameProvider { +export class TTSLRenameProvider extends DefaultRenameProvider { private readonly astNodeLocator: AstNodeLocator; private readonly langiumDocuments: LangiumDocuments; - constructor(services: SafeDsServices) { + constructor(services: TTSLServices) { super(services); this.astNodeLocator = services.workspace.AstNodeLocator; diff --git a/packages/ttsl-lang/src/language/lsp/safe-ds-semantic-token-provider.ts b/packages/ttsl-lang/src/language/lsp/ttsl-semantic-token-provider.ts similarity index 95% rename from packages/ttsl-lang/src/language/lsp/safe-ds-semantic-token-provider.ts rename to packages/ttsl-lang/src/language/lsp/ttsl-semantic-token-provider.ts index 2e5e15ca..df567fca 100644 --- a/packages/ttsl-lang/src/language/lsp/safe-ds-semantic-token-provider.ts +++ b/packages/ttsl-lang/src/language/lsp/ttsl-semantic-token-provider.ts @@ -13,10 +13,10 @@ import { isTslReference, isTslResult, } from '../generated/ast.js'; -import { SafeDsServices } from '../safe-ds-module.js'; +import { TTSLServices } from '../ttsl-module.js'; -export class SafeDsSemanticTokenProvider extends AbstractSemanticTokenProvider { - constructor(services: SafeDsServices) { +export class TTSLSemanticTokenProvider extends AbstractSemanticTokenProvider { + constructor(services: TTSLServices) { super(services); } diff --git a/packages/ttsl-lang/src/language/lsp/safe-ds-signature-help-provider.ts b/packages/ttsl-lang/src/language/lsp/ttsl-signature-help-provider.ts similarity index 87% rename from packages/ttsl-lang/src/language/lsp/safe-ds-signature-help-provider.ts rename to packages/ttsl-lang/src/language/lsp/ttsl-signature-help-provider.ts index a8a627d8..30d8ff88 100644 --- a/packages/ttsl-lang/src/language/lsp/safe-ds-signature-help-provider.ts +++ b/packages/ttsl-lang/src/language/lsp/ttsl-signature-help-provider.ts @@ -14,21 +14,21 @@ import type { SignatureHelpOptions, SignatureHelpParams, } from 'vscode-languageserver'; -import { createMarkupContent } from '../documentation/safe-ds-comment-provider.js'; +import { createMarkupContent } from '../documentation/ttsl-comment-provider.js'; import { isTslAbstractCall, TslCallable, TslParameter } from '../generated/ast.js'; import { getParameters, Parameter } from '../helpers/nodeProperties.js'; -import { type SafeDsNodeMapper } from '../helpers/safe-ds-node-mapper.js'; -import type { SafeDsServices } from '../safe-ds-module.js'; -import { type SafeDsTypeComputer } from '../typing/safe-ds-type-computer.js'; +import { type TTSLNodeMapper } from '../helpers/ttsl-node-mapper.js'; +import type { TTSLServices } from '../ttsl-module.js'; +import { type TTSLTypeComputer } from '../typing/ttsl-type-computer.js'; import { CallableType } from '../typing/model.js'; import { SignatureHelpProvider } from 'langium/lsp'; -export class SafeDsSignatureHelpProvider implements SignatureHelpProvider { +export class TTSLSignatureHelpProvider implements SignatureHelpProvider { private readonly documentationProvider: DocumentationProvider; - private readonly nodeMapper: SafeDsNodeMapper; - private readonly typeComputer: SafeDsTypeComputer; + private readonly nodeMapper: TTSLNodeMapper; + private readonly typeComputer: TTSLTypeComputer; - constructor(services: SafeDsServices) { + constructor(services: TTSLServices) { this.documentationProvider = services.documentation.DocumentationProvider; this.nodeMapper = services.helpers.NodeMapper; this.typeComputer = services.types.TypeComputer; diff --git a/packages/ttsl-lang/src/language/main.ts b/packages/ttsl-lang/src/language/main.ts index 0ba9cb8c..21c389b3 100644 --- a/packages/ttsl-lang/src/language/main.ts +++ b/packages/ttsl-lang/src/language/main.ts @@ -1,7 +1,7 @@ import { NodeFileSystem } from 'langium/node'; import { startLanguageServer as doStartLanguageServer } from 'langium/lsp'; import { createConnection, ProposedFeatures } from 'vscode-languageserver/node.js'; -import { createSafeDsServices } from './safe-ds-module.js'; +import { createTTSLServices } from './ttsl-module.js'; /* c8 ignore start */ export const startLanguageServer = async () => { @@ -9,7 +9,7 @@ export const startLanguageServer = async () => { const connection = createConnection(ProposedFeatures.all); // Inject the shared services and language-specific services - const { shared } = await createSafeDsServices({ connection, ...NodeFileSystem }); + const { shared } = await createTTSLServices({ connection, ...NodeFileSystem }); // Start the language server with the shared services doStartLanguageServer(shared); diff --git a/packages/ttsl-lang/src/language/partialEvaluation/model.ts b/packages/ttsl-lang/src/language/partialEvaluation/model.ts index 3dacfed3..1da49900 100644 --- a/packages/ttsl-lang/src/language/partialEvaluation/model.ts +++ b/packages/ttsl-lang/src/language/partialEvaluation/model.ts @@ -7,7 +7,7 @@ import { type TslParameter, } from '../generated/ast.js'; import { getParameters } from '../helpers/nodeProperties.js'; -import { escapeString } from '../grammar/safe-ds-value-converter.js'; +import { escapeString } from '../grammar/ttsl-value-converter.js'; export type ParameterSubstitutions = Map; export type ResultSubstitutions = Map; diff --git a/packages/ttsl-lang/src/language/partialEvaluation/safe-ds-partial-evaluator.ts b/packages/ttsl-lang/src/language/partialEvaluation/ttsl-partial-evaluator.ts similarity index 99% rename from packages/ttsl-lang/src/language/partialEvaluation/safe-ds-partial-evaluator.ts rename to packages/ttsl-lang/src/language/partialEvaluation/ttsl-partial-evaluator.ts index 24ea991f..a5075ec6 100644 --- a/packages/ttsl-lang/src/language/partialEvaluation/safe-ds-partial-evaluator.ts +++ b/packages/ttsl-lang/src/language/partialEvaluation/ttsl-partial-evaluator.ts @@ -50,8 +50,8 @@ import { isTslString, } from '../generated/ast.js'; import { getArguments, getParameters, getResults } from '../helpers/nodeProperties.js'; -import { SafeDsNodeMapper } from '../helpers/safe-ds-node-mapper.js'; -import { SafeDsServices } from '../safe-ds-module.js'; +import { TTSLNodeMapper } from '../helpers/ttsl-node-mapper.js'; +import { TTSLServices } from '../ttsl-module.js'; import { BooleanConstant, Constant, @@ -73,13 +73,13 @@ import { UnknownEvaluatedNode, } from './model.js'; -export class SafeDsPartialEvaluator { +export class TTSLPartialEvaluator { private readonly astNodeLocator: AstNodeLocator; - private readonly nodeMapper: SafeDsNodeMapper; + private readonly nodeMapper: TTSLNodeMapper; private readonly cache: WorkspaceCache; - constructor(services: SafeDsServices) { + constructor(services: TTSLServices) { this.astNodeLocator = services.workspace.AstNodeLocator; this.nodeMapper = services.helpers.NodeMapper; diff --git a/packages/ttsl-lang/src/language/safe-ds-module.ts b/packages/ttsl-lang/src/language/safe-ds-module.ts deleted file mode 100644 index 01528a28..00000000 --- a/packages/ttsl-lang/src/language/safe-ds-module.ts +++ /dev/null @@ -1,196 +0,0 @@ -import { DeepPartial, inject, Module } from 'langium'; -import { - createDefaultModule, - createDefaultSharedModule, - DefaultSharedModuleContext, - LangiumServices, - LangiumSharedServices, - PartialLangiumServices, -} from 'langium/lsp'; -import { SafeDsCommentProvider } from './documentation/safe-ds-comment-provider.js'; -import { SafeDsDocumentationProvider } from './documentation/safe-ds-documentation-provider.js'; -import { SafeDsCallGraphComputer } from './flow/safe-ds-call-graph-computer.js'; -import { TTSLGeneratedModule, TTSLGeneratedSharedModule } from './generated/module.js'; -import { SafeDsPythonGenerator } from './generation/safe-ds-python-generator.js'; -import { SafeDsValueConverter } from './grammar/safe-ds-value-converter.js'; -import { SafeDsNodeMapper } from './helpers/safe-ds-node-mapper.js'; -import { SafeDsCallHierarchyProvider } from './lsp/safe-ds-call-hierarchy-provider.js'; -import { SafeDsDocumentSymbolProvider } from './lsp/safe-ds-document-symbol-provider.js'; -import { SafeDsFormatter } from './lsp/safe-ds-formatter.js'; -import { SafeDsInlayHintProvider } from './lsp/safe-ds-inlay-hint-provider.js'; -import { SafeDsNodeInfoProvider } from './lsp/safe-ds-node-info-provider.js'; -import { SafeDsNodeKindProvider } from './lsp/safe-ds-node-kind-provider.js'; -import { SafeDsSemanticTokenProvider } from './lsp/safe-ds-semantic-token-provider.js'; -import { SafeDsSignatureHelpProvider } from './lsp/safe-ds-signature-help-provider.js'; -import { SafeDsPartialEvaluator } from './partialEvaluation/safe-ds-partial-evaluator.js'; -import { SafeDsScopeComputation } from './scoping/safe-ds-scope-computation.js'; -import { SafeDsScopeProvider } from './scoping/safe-ds-scope-provider.js'; -import { SafeDsCoreTypes } from './typing/safe-ds-core-types.js'; -import { SafeDsTypeChecker } from './typing/safe-ds-type-checker.js'; -import { SafeDsTypeComputer } from './typing/safe-ds-type-computer.js'; -import { registerValidationChecks } from './validation/safe-ds-validator.js'; -import { SafeDsDocumentBuilder } from './workspace/safe-ds-document-builder.js'; -import { SafeDsPackageManager } from './workspace/safe-ds-package-manager.js'; -import { SafeDsWorkspaceManager } from './workspace/safe-ds-workspace-manager.js'; -import { SafeDsSettingsProvider } from './workspace/safe-ds-settings-provider.js'; -import { SafeDsRenameProvider } from './lsp/safe-ds-rename-provider.js'; -import { SafeDsTypeFactory } from './typing/safe-ds-type-factory.js'; -import { TTSLFunction } from './builtins/ttsl-ds-functions.js'; - -/** - * Declaration of custom services - add your own service classes here. - */ -export type SafeDsAddedServices = { - builtins: { - Functions: TTSLFunction; - }; - evaluation: { - PartialEvaluator: SafeDsPartialEvaluator; - }; - flow: { - CallGraphComputer: SafeDsCallGraphComputer; - }; - generation: { - PythonGenerator: SafeDsPythonGenerator; - }; - helpers: { - NodeMapper: SafeDsNodeMapper; - }; - lsp: { - NodeInfoProvider: SafeDsNodeInfoProvider; - }; - types: { - CoreTypes: SafeDsCoreTypes; - TypeChecker: SafeDsTypeChecker; - TypeComputer: SafeDsTypeComputer; - TypeFactory: SafeDsTypeFactory; - }; - workspace: { - PackageManager: SafeDsPackageManager; - SettingsProvider: SafeDsSettingsProvider; - }; -}; - -/** - * Union of Langium default services and your custom services - use this as constructor parameter - * of custom service classes. - */ -export type SafeDsServices = LangiumServices & SafeDsAddedServices; - -/** - * Dependency injection module that overrides Langium default services and contributes the - * declared custom services. The Langium defaults can be partially specified to override only - * selected services, while the custom services must be fully specified. - */ -export const SafeDsModule: Module = { - builtins: { - Functions: (services) => new TTSLFunction(services), - }, - documentation: { - CommentProvider: (services) => new SafeDsCommentProvider(services), - DocumentationProvider: (services) => new SafeDsDocumentationProvider(services), - }, - evaluation: { - PartialEvaluator: (services) => new SafeDsPartialEvaluator(services), - }, - flow: { - CallGraphComputer: (services) => new SafeDsCallGraphComputer(services), - }, - generation: { - PythonGenerator: (services) => new SafeDsPythonGenerator(services), - }, - helpers: { - NodeMapper: (services) => new SafeDsNodeMapper(services), - }, - lsp: { - CallHierarchyProvider: (services) => new SafeDsCallHierarchyProvider(services), - DocumentSymbolProvider: (services) => new SafeDsDocumentSymbolProvider(services), - Formatter: () => new SafeDsFormatter(), - InlayHintProvider: (services) => new SafeDsInlayHintProvider(services), - NodeInfoProvider: (services) => new SafeDsNodeInfoProvider(services), - RenameProvider: (services) => new SafeDsRenameProvider(services), - SemanticTokenProvider: (services) => new SafeDsSemanticTokenProvider(services), - SignatureHelp: (services) => new SafeDsSignatureHelpProvider(services), - }, - parser: { - ValueConverter: () => new SafeDsValueConverter(), - }, - references: { - ScopeComputation: (services) => new SafeDsScopeComputation(services), - ScopeProvider: (services) => new SafeDsScopeProvider(services), - }, - types: { - CoreTypes: (services) => new SafeDsCoreTypes(services), - TypeChecker: (services) => new SafeDsTypeChecker(services), - TypeComputer: (services) => new SafeDsTypeComputer(services), - TypeFactory: (services) => new SafeDsTypeFactory(services), - }, - workspace: { - PackageManager: (services) => new SafeDsPackageManager(services), - SettingsProvider: (services) => new SafeDsSettingsProvider(services), - }, -}; - -export type SafeDsSharedServices = LangiumSharedServices; - -export const SafeDsSharedModule: Module> = { - lsp: { - NodeKindProvider: () => new SafeDsNodeKindProvider(), - }, - workspace: { - DocumentBuilder: (services) => new SafeDsDocumentBuilder(services), - WorkspaceManager: (services) => new SafeDsWorkspaceManager(services), - }, -}; - -/** - * Create the full set of services required by Langium. - * - * First inject the shared services by merging two modules: - * - Langium default shared services - * - Services generated by langium-cli - * - * Then inject the language-specific services by merging three modules: - * - Langium default language-specific services - * - Services generated by langium-cli - * - Services specified in this file - * - * @param context Optional module context with the LSP connection. - * @param options Further options to configure the Safe-DS module. - * @return An object wrapping the shared services and the language-specific services. - */ -export const createSafeDsServices = async function ( - context: DefaultSharedModuleContext, - options?: ModuleOptions, -): Promise<{ - shared: LangiumSharedServices; - SafeDs: SafeDsServices; -}> { - const shared = inject(createDefaultSharedModule(context), TTSLGeneratedSharedModule, SafeDsSharedModule); - const SafeDs = inject(createDefaultModule({ shared }), TTSLGeneratedModule, SafeDsModule); - - shared.ServiceRegistry.register(SafeDs); - registerValidationChecks(SafeDs); - - // If we don't run inside a language server, initialize the configuration provider instantly - if (!context.connection) { - await shared.workspace.ConfigurationProvider.initialized({}); - } - - // Apply options - if (!options?.omitBuiltins) { - await shared.workspace.WorkspaceManager.initializeWorkspace([]); - } - - return { shared, SafeDs }; -}; - -/** - * Options to pass to the creation of Safe-DS services. - */ -export interface ModuleOptions { - /** - * By default, builtins are loaded into the workspace. If this option is set to true, builtins are omitted. - */ - omitBuiltins?: boolean; -} diff --git a/packages/ttsl-lang/src/language/scoping/safe-ds-scope-computation.ts b/packages/ttsl-lang/src/language/scoping/ttsl-scope-computation.ts similarity index 97% rename from packages/ttsl-lang/src/language/scoping/safe-ds-scope-computation.ts rename to packages/ttsl-lang/src/language/scoping/ttsl-scope-computation.ts index 5bbaa22e..8fbe39dd 100644 --- a/packages/ttsl-lang/src/language/scoping/safe-ds-scope-computation.ts +++ b/packages/ttsl-lang/src/language/scoping/ttsl-scope-computation.ts @@ -16,7 +16,7 @@ import { TslParameter, } from '../generated/ast.js'; -export class SafeDsScopeComputation extends DefaultScopeComputation { +export class TTSLScopeComputation extends DefaultScopeComputation { protected override exportNode(node: AstNode, exports: AstNodeDescription[], document: LangiumDocument): void { // Modules, pipelines, and private segments cannot be referenced from other documents if (isTslModule(node)) { diff --git a/packages/ttsl-lang/src/language/scoping/safe-ds-scope-provider.ts b/packages/ttsl-lang/src/language/scoping/ttsl-scope-provider.ts similarity index 94% rename from packages/ttsl-lang/src/language/scoping/safe-ds-scope-provider.ts rename to packages/ttsl-lang/src/language/scoping/ttsl-scope-provider.ts index cd64575c..b027eb05 100644 --- a/packages/ttsl-lang/src/language/scoping/safe-ds-scope-provider.ts +++ b/packages/ttsl-lang/src/language/scoping/ttsl-scope-provider.ts @@ -46,20 +46,20 @@ import { getResults, getStatements, } from '../helpers/nodeProperties.js'; -import { SafeDsNodeMapper } from '../helpers/safe-ds-node-mapper.js'; -import { SafeDsServices } from '../safe-ds-module.js'; -import { SafeDsTypeComputer } from '../typing/safe-ds-type-computer.js'; -import { SafeDsPackageManager } from '../workspace/safe-ds-package-manager.js'; +import { TTSLNodeMapper } from '../helpers/ttsl-node-mapper.js'; +import { TTSLServices } from '../ttsl-module.js'; +import { TTSLTypeComputer } from '../typing/ttsl-type-computer.js'; +import { TTSLPackageManager } from '../workspace/ttsl-package-manager.js'; -export class SafeDsScopeProvider extends DefaultScopeProvider { +export class TTSLScopeProvider extends DefaultScopeProvider { private readonly astReflection: AstReflection; - private readonly nodeMapper: SafeDsNodeMapper; - private readonly packageManager: SafeDsPackageManager; - private readonly typeComputer: SafeDsTypeComputer; + private readonly nodeMapper: TTSLNodeMapper; + private readonly packageManager: TTSLPackageManager; + private readonly typeComputer: TTSLTypeComputer; private readonly coreDeclarationCache: WorkspaceCache; - constructor(services: SafeDsServices) { + constructor(services: TTSLServices) { super(services); this.astReflection = services.shared.AstReflection; @@ -268,7 +268,7 @@ export class SafeDsScopeProvider extends DefaultScopeProvider { } private builtinDeclarations(referenceType: string): AstNodeDescription[] { - return this.packageManager.getDeclarationsInPackageOrSubpackage('safeds', { + return this.packageManager.getDeclarationsInPackageOrSubpackage('TTSL', { nodeType: referenceType, hideInternal: true, }); @@ -317,7 +317,7 @@ export class SafeDsScopeProvider extends DefaultScopeProvider { private coreDeclarations(referenceType: string, outerScope: Scope): Scope { const descriptions = this.coreDeclarationCache.get(referenceType, () => - this.packageManager.getDeclarationsInPackage('safeds.lang', { + this.packageManager.getDeclarationsInPackage('TTSL.lang', { nodeType: referenceType, hideInternal: true, }), diff --git a/packages/ttsl-lang/src/language/ttsl-module.ts b/packages/ttsl-lang/src/language/ttsl-module.ts new file mode 100644 index 00000000..876543d1 --- /dev/null +++ b/packages/ttsl-lang/src/language/ttsl-module.ts @@ -0,0 +1,196 @@ +import { DeepPartial, inject, Module } from 'langium'; +import { + createDefaultModule, + createDefaultSharedModule, + DefaultSharedModuleContext, + LangiumServices, + LangiumSharedServices, + PartialLangiumServices, +} from 'langium/lsp'; +import { TTSLCommentProvider } from './documentation/ttsl-comment-provider.js'; +import { TTSLDocumentationProvider } from './documentation/ttsl-documentation-provider.js'; +import { TTSLCallGraphComputer } from './flow/ttsl-call-graph-computer.js'; +import { TTSLGeneratedModule, TTSLGeneratedSharedModule } from './generated/module.js'; +import { TTSLPythonGenerator } from './generation/ttsl-python-generator.js'; +import { TTSLValueConverter } from './grammar/ttsl-value-converter.js'; +import { TTSLNodeMapper } from './helpers/ttsl-node-mapper.js'; +import { TTSLCallHierarchyProvider } from './lsp/ttsl-call-hierarchy-provider.js'; +import { TTSLDocumentSymbolProvider } from './lsp/ttsl-document-symbol-provider.js'; +import { TTSLFormatter } from './lsp/ttsl-formatter.js'; +import { TTSLInlayHintProvider } from './lsp/ttsl-inlay-hint-provider.js'; +import { TTSLNodeInfoProvider } from './lsp/ttsl-node-info-provider.js'; +import { TTSLNodeKindProvider } from './lsp/ttsl-node-kind-provider.js'; +import { TTSLSemanticTokenProvider } from './lsp/ttsl-semantic-token-provider.js'; +import { TTSLSignatureHelpProvider } from './lsp/ttsl-signature-help-provider.js'; +import { TTSLPartialEvaluator } from './partialEvaluation/ttsl-partial-evaluator.js'; +import { TTSLScopeComputation } from './scoping/ttsl-scope-computation.js'; +import { TTSLScopeProvider } from './scoping/ttsl-scope-provider.js'; +import { TTSLCoreTypes } from './typing/ttsl-core-types.js'; +import { TTSLTypeChecker } from './typing/ttsl-type-checker.js'; +import { TTSLTypeComputer } from './typing/ttsl-type-computer.js'; +import { registerValidationChecks } from './validation/ttsl-validator.js'; +import { TTSLDocumentBuilder } from './workspace/ttsl-document-builder.js'; +import { TTSLPackageManager } from './workspace/ttsl-package-manager.js'; +import { TTSLWorkspaceManager } from './workspace/ttsl-workspace-manager.js'; +import { TTSLSettingsProvider } from './workspace/ttsl-settings-provider.js'; +import { TTSLRenameProvider } from './lsp/ttsl-rename-provider.js'; +import { TTSLTypeFactory } from './typing/ttsl-type-factory.js'; +import { TTSLFunction } from './builtins/ttsl-ds-functions.js'; + +/** + * Declaration of custom services - add your own service classes here. + */ +export type TTSLAddedServices = { + builtins: { + Functions: TTSLFunction; + }; + evaluation: { + PartialEvaluator: TTSLPartialEvaluator; + }; + flow: { + CallGraphComputer: TTSLCallGraphComputer; + }; + generation: { + PythonGenerator: TTSLPythonGenerator; + }; + helpers: { + NodeMapper: TTSLNodeMapper; + }; + lsp: { + NodeInfoProvider: TTSLNodeInfoProvider; + }; + types: { + CoreTypes: TTSLCoreTypes; + TypeChecker: TTSLTypeChecker; + TypeComputer: TTSLTypeComputer; + TypeFactory: TTSLTypeFactory; + }; + workspace: { + PackageManager: TTSLPackageManager; + SettingsProvider: TTSLSettingsProvider; + }; +}; + +/** + * Union of Langium default services and your custom services - use this as constructor parameter + * of custom service classes. + */ +export type TTSLServices = LangiumServices & TTSLAddedServices; + +/** + * Dependency injection module that overrides Langium default services and contributes the + * declared custom services. The Langium defaults can be partially specified to override only + * selected services, while the custom services must be fully specified. + */ +export const TTSLModule: Module = { + builtins: { + Functions: (services) => new TTSLFunction(services), + }, + documentation: { + CommentProvider: (services) => new TTSLCommentProvider(services), + DocumentationProvider: (services) => new TTSLDocumentationProvider(services), + }, + evaluation: { + PartialEvaluator: (services) => new TTSLPartialEvaluator(services), + }, + flow: { + CallGraphComputer: (services) => new TTSLCallGraphComputer(services), + }, + generation: { + PythonGenerator: (services) => new TTSLPythonGenerator(services), + }, + helpers: { + NodeMapper: (services) => new TTSLNodeMapper(services), + }, + lsp: { + CallHierarchyProvider: (services) => new TTSLCallHierarchyProvider(services), + DocumentSymbolProvider: (services) => new TTSLDocumentSymbolProvider(services), + Formatter: () => new TTSLFormatter(), + InlayHintProvider: (services) => new TTSLInlayHintProvider(services), + NodeInfoProvider: (services) => new TTSLNodeInfoProvider(services), + RenameProvider: (services) => new TTSLRenameProvider(services), + SemanticTokenProvider: (services) => new TTSLSemanticTokenProvider(services), + SignatureHelp: (services) => new TTSLSignatureHelpProvider(services), + }, + parser: { + ValueConverter: () => new TTSLValueConverter(), + }, + references: { + ScopeComputation: (services) => new TTSLScopeComputation(services), + ScopeProvider: (services) => new TTSLScopeProvider(services), + }, + types: { + CoreTypes: (services) => new TTSLCoreTypes(services), + TypeChecker: (services) => new TTSLTypeChecker(services), + TypeComputer: (services) => new TTSLTypeComputer(services), + TypeFactory: (services) => new TTSLTypeFactory(services), + }, + workspace: { + PackageManager: (services) => new TTSLPackageManager(services), + SettingsProvider: (services) => new TTSLSettingsProvider(services), + }, +}; + +export type TTSLSharedServices = LangiumSharedServices; + +export const TTSLSharedModule: Module> = { + lsp: { + NodeKindProvider: () => new TTSLNodeKindProvider(), + }, + workspace: { + DocumentBuilder: (services) => new TTSLDocumentBuilder(services), + WorkspaceManager: (services) => new TTSLWorkspaceManager(services), + }, +}; + +/** + * Create the full set of services required by Langium. + * + * First inject the shared services by merging two modules: + * - Langium default shared services + * - Services generated by langium-cli + * + * Then inject the language-specific services by merging three modules: + * - Langium default language-specific services + * - Services generated by langium-cli + * - Services specified in this file + * + * @param context Optional module context with the LSP connection. + * @param options Further options to configure the TTSL module. + * @return An object wrapping the shared services and the language-specific services. + */ +export const createTTSLServices = async function ( + context: DefaultSharedModuleContext, + options?: ModuleOptions, +): Promise<{ + shared: LangiumSharedServices; + TTSL: TTSLServices; +}> { + const shared = inject(createDefaultSharedModule(context), TTSLGeneratedSharedModule, TTSLSharedModule); + const TTSL = inject(createDefaultModule({ shared }), TTSLGeneratedModule, TTSLModule); + + shared.ServiceRegistry.register(TTSL); + registerValidationChecks(TTSL); + + // If we don't run inside a language server, initialize the configuration provider instantly + if (!context.connection) { + await shared.workspace.ConfigurationProvider.initialized({}); + } + + // Apply options + if (!options?.omitBuiltins) { + await shared.workspace.WorkspaceManager.initializeWorkspace([]); + } + + return { shared, TTSL }; +}; + +/** + * Options to pass to the creation of TTSL services. + */ +export interface ModuleOptions { + /** + * By default, builtins are loaded into the workspace. If this option is set to true, builtins are omitted. + */ + omitBuiltins?: boolean; +} diff --git a/packages/ttsl-lang/src/language/typing/model.ts b/packages/ttsl-lang/src/language/typing/model.ts index bbef5a30..cc525cfd 100644 --- a/packages/ttsl-lang/src/language/typing/model.ts +++ b/packages/ttsl-lang/src/language/typing/model.ts @@ -8,11 +8,11 @@ import { TslResult, } from '../generated/ast.js'; import { Parameter } from '../helpers/nodeProperties.js'; -import { SafeDsServices } from '../safe-ds-module.js'; -import { SafeDsCoreTypes } from './safe-ds-core-types.js'; -import { SafeDsTypeChecker } from './safe-ds-type-checker.js'; -import { SafeDsTypeComputer } from './safe-ds-type-computer.js'; -import { SafeDsTypeFactory } from './safe-ds-type-factory.js'; +import { TTSLServices } from '../ttsl-module.js'; +import { TTSLCoreTypes } from './ttsl-core-types.js'; +import { TTSLTypeChecker } from './ttsl-type-checker.js'; +import { TTSLTypeComputer } from './ttsl-type-computer.js'; +import { TTSLTypeFactory } from './ttsl-type-factory.js'; export type ParameterSubstitutions = Map; @@ -61,12 +61,12 @@ export abstract class Type { } export class CallableType extends Type { - private readonly factory: SafeDsTypeFactory; + private readonly factory: TTSLTypeFactory; override isExplicitlyNullable: boolean = false; constructor( - services: SafeDsServices, + services: TTSLServices, readonly callable: TslCallable, readonly parameter: TslParameter | undefined, readonly inputType: NamedTupleType, @@ -139,13 +139,13 @@ export class CallableType extends Type { } export class NamedTupleType extends Type { - private readonly factory: SafeDsTypeFactory; + private readonly factory: TTSLTypeFactory; readonly entries: NamedTupleEntry[]; override readonly isExplicitlyNullable = false; private _isFullySubstituted: boolean | undefined; - constructor(services: SafeDsServices, entries: NamedTupleEntry[]) { + constructor(services: TTSLServices, entries: NamedTupleEntry[]) { super(); this.factory = services.types.TypeFactory; @@ -255,15 +255,15 @@ export class NamedTupleEntry { } export class UnionType extends Type { - private readonly coreTypes: SafeDsCoreTypes; - private readonly factory: SafeDsTypeFactory; - private readonly typeChecker: SafeDsTypeChecker; + private readonly coreTypes: TTSLCoreTypes; + private readonly factory: TTSLTypeFactory; + private readonly typeChecker: TTSLTypeChecker; readonly types: Type[]; private _isExplicitlyNullable: boolean | undefined; private _isFullySubstituted: boolean | undefined; - constructor(services: SafeDsServices, types: Type[]) { + constructor(services: TTSLServices, types: Type[]) { super(); this.coreTypes = services.types.CoreTypes; @@ -406,14 +406,14 @@ class UnknownTypeClass extends Type { } export class DictionaryType extends Type { - private readonly factory: SafeDsTypeFactory; + private readonly factory: TTSLTypeFactory; override readonly isFullySubstituted = true; - private readonly typeComputer: SafeDsTypeComputer; + private readonly typeComputer: TTSLTypeComputer; override isExplicitlyNullable: boolean = false; constructor( - services: SafeDsServices, + services: TTSLServices, readonly dictionary: TslDictionary ) { super(); @@ -479,14 +479,14 @@ export class DictionaryType extends Type { } export class ListType extends Type { - private readonly factory: SafeDsTypeFactory; + private readonly factory: TTSLTypeFactory; override readonly isFullySubstituted = true; - private readonly typeComputer: SafeDsTypeComputer; + private readonly typeComputer: TTSLTypeComputer; override isExplicitlyNullable: boolean = false; constructor( - services: SafeDsServices, + services: TTSLServices, readonly list: TslList ) { super(); diff --git a/packages/ttsl-lang/src/language/typing/safe-ds-core-types.ts b/packages/ttsl-lang/src/language/typing/ttsl-core-types.ts similarity index 91% rename from packages/ttsl-lang/src/language/typing/safe-ds-core-types.ts rename to packages/ttsl-lang/src/language/typing/ttsl-core-types.ts index 5cb5d597..a894ce56 100644 --- a/packages/ttsl-lang/src/language/typing/safe-ds-core-types.ts +++ b/packages/ttsl-lang/src/language/typing/ttsl-core-types.ts @@ -1,15 +1,15 @@ import { WorkspaceCache } from 'langium'; -import { SafeDsClasses } from '../builtins/safe-ds-classes.js'; +import { TTSLClasses } from '../builtins/ttsl-classes.js'; import { TslClass } from '../generated/ast.js'; -import { SafeDsServices } from '../safe-ds-module.js'; +import { TTSLServices } from '../ttsl-module.js'; import { ClassType, Type, TypeParameterSubstitutions, UnknownType } from './model.js'; import { getTypeParameters } from '../helpers/nodeProperties.js'; -export class SafeDsCoreTypes { - private readonly builtinClasses: SafeDsClasses; +export class TTSLCoreTypes { + private readonly builtinClasses: TTSLClasses; private readonly cache: WorkspaceCache; - constructor(services: SafeDsServices) { + constructor(services: TTSLServices) { this.builtinClasses = services.builtins.Classes; this.cache = new WorkspaceCache(services.shared); } diff --git a/packages/ttsl-lang/src/language/typing/safe-ds-type-checker.ts b/packages/ttsl-lang/src/language/typing/ttsl-type-checker.ts similarity index 94% rename from packages/ttsl-lang/src/language/typing/safe-ds-type-checker.ts rename to packages/ttsl-lang/src/language/typing/ttsl-type-checker.ts index 1dff7d06..f583215a 100644 --- a/packages/ttsl-lang/src/language/typing/safe-ds-type-checker.ts +++ b/packages/ttsl-lang/src/language/typing/ttsl-type-checker.ts @@ -1,6 +1,6 @@ import { TslDeclaration } from '../generated/ast.js'; import { Parameter } from '../helpers/nodeProperties.js'; -import { SafeDsServices } from '../safe-ds-module.js'; +import { TTSLServices } from '../ttsl-module.js'; import { CallableType, DictionaryType, @@ -10,14 +10,14 @@ import { UnionType, UnknownType, } from './model.js'; -import { SafeDsCoreTypes } from './safe-ds-core-types.js'; -import type { SafeDsTypeComputer } from './safe-ds-type-computer.js'; +import { TTSLCoreTypes } from './ttsl-core-types.js'; +import type { TTSLTypeComputer } from './ttsl-type-computer.js'; -export class SafeDsTypeChecker { - private readonly coreTypes: SafeDsCoreTypes; - private readonly typeComputer: () => SafeDsTypeComputer; +export class TTSLTypeChecker { + private readonly coreTypes: TTSLCoreTypes; + private readonly typeComputer: () => TTSLTypeComputer; - constructor(services: SafeDsServices) { + constructor(services: TTSLServices) { this.coreTypes = services.types.CoreTypes; this.typeComputer = () => services.types.TypeComputer; } @@ -209,7 +209,7 @@ export class SafeDsTypeChecker { } /** - * Options for {@link SafeDsTypeChecker.isSubtypeOf} and {@link SafeDsTypeChecker.isSupertypeOf}. + * Options for {@link TTSLTypeChecker.isSubtypeOf} and {@link TTSLTypeChecker.isSupertypeOf}. */ interface TypeCheckOptions { /** diff --git a/packages/ttsl-lang/src/language/typing/safe-ds-type-computer.ts b/packages/ttsl-lang/src/language/typing/ttsl-type-computer.ts similarity index 97% rename from packages/ttsl-lang/src/language/typing/safe-ds-type-computer.ts rename to packages/ttsl-lang/src/language/typing/ttsl-type-computer.ts index 41e698fc..ec3247cc 100644 --- a/packages/ttsl-lang/src/language/typing/safe-ds-type-computer.ts +++ b/packages/ttsl-lang/src/language/typing/ttsl-type-computer.ts @@ -45,7 +45,7 @@ import { NullConstant, StringConstant, } from '../partialEvaluation/model.js'; -import { SafeDsServices } from '../safe-ds-module.js'; +import { TTSLServices } from '../ttsl-module.js'; import { CallableType, NamedTupleEntry, @@ -55,19 +55,19 @@ import { ListType, UnknownType, } from './model.js'; -import { SafeDsCoreTypes } from './safe-ds-core-types.js'; -import type { SafeDsTypeChecker } from './safe-ds-type-checker.js'; -import { SafeDsTypeFactory } from './safe-ds-type-factory.js'; +import { TTSLCoreTypes } from './ttsl-core-types.js'; +import type { TTSLTypeChecker } from './ttsl-type-checker.js'; +import { TTSLTypeFactory } from './ttsl-type-factory.js'; -export class SafeDsTypeComputer { +export class TTSLTypeComputer { private readonly astNodeLocator: AstNodeLocator; - private readonly coreTypes: SafeDsCoreTypes; - private readonly factory: SafeDsTypeFactory; - private readonly typeChecker: SafeDsTypeChecker; + private readonly coreTypes: TTSLCoreTypes; + private readonly factory: TTSLTypeFactory; + private readonly typeChecker: TTSLTypeChecker; private readonly nodeTypeCache: WorkspaceCache; - constructor(services: SafeDsServices) { + constructor(services: TTSLServices) { this.astNodeLocator = services.workspace.AstNodeLocator; this.coreTypes = services.types.CoreTypes; this.factory = services.types.TypeFactory; diff --git a/packages/ttsl-lang/src/language/typing/safe-ds-type-factory.ts b/packages/ttsl-lang/src/language/typing/ttsl-type-factory.ts similarity index 88% rename from packages/ttsl-lang/src/language/typing/safe-ds-type-factory.ts rename to packages/ttsl-lang/src/language/typing/ttsl-type-factory.ts index f7de1d70..0b254fa4 100644 --- a/packages/ttsl-lang/src/language/typing/safe-ds-type-factory.ts +++ b/packages/ttsl-lang/src/language/typing/ttsl-type-factory.ts @@ -1,4 +1,4 @@ -import { SafeDsServices } from '../safe-ds-module.js'; +import { TTSLServices } from '../ttsl-module.js'; import { CallableType, DictionaryType, @@ -17,8 +17,8 @@ import { TslResult, } from '../generated/ast.js'; -export class SafeDsTypeFactory { - constructor(private readonly services: SafeDsServices) {} +export class TTSLTypeFactory { + constructor(private readonly services: TTSLServices) {} createCallableType( callable: TslCallable, diff --git a/packages/ttsl-lang/src/language/validation/experimentalLanguageFeatures.ts b/packages/ttsl-lang/src/language/validation/experimentalLanguageFeatures.ts index 56d99aad..fd1ffaa4 100644 --- a/packages/ttsl-lang/src/language/validation/experimentalLanguageFeatures.ts +++ b/packages/ttsl-lang/src/language/validation/experimentalLanguageFeatures.ts @@ -3,11 +3,11 @@ import { isTslDictionary, type TslDictionary, } from '../generated/ast.js'; -import { SafeDsServices } from '../safe-ds-module.js'; +import { TTSLServices } from '../ttsl-module.js'; export const CODE_EXPERIMENTAL_LANGUAGE_FEATURE = 'experimental/language-feature'; -export const mapsShouldBeUsedWithCaution = (services: SafeDsServices) => { +export const mapsShouldBeUsedWithCaution = (services: TTSLServices) => { const settingsProvider = services.workspace.SettingsProvider; return async (node: TslDictionary, accept: ValidationAcceptor) => { diff --git a/packages/ttsl-lang/src/language/validation/names.ts b/packages/ttsl-lang/src/language/validation/names.ts index 1a7809dd..dd048f60 100644 --- a/packages/ttsl-lang/src/language/validation/names.ts +++ b/packages/ttsl-lang/src/language/validation/names.ts @@ -13,7 +13,7 @@ import { TslPlaceholder, TslResult, } from '../generated/ast.js'; -import { CODEGEN_PREFIX } from '../generation/safe-ds-python-generator.js'; +import { CODEGEN_PREFIX } from '../generation/ttsl-python-generator.js'; import { getImportedDeclarations, getImports, @@ -22,7 +22,7 @@ import { getParameters, getResults, } from '../helpers/nodeProperties.js'; -import { SafeDsServices } from '../safe-ds-module.js'; +import { TTSLServices } from '../ttsl-module.js'; export const CODE_NAME_CODEGEN_PREFIX = 'name/codegen-prefix'; export const CODE_NAME_CORE_DECLARATION = 'name/core-declaration'; @@ -52,7 +52,7 @@ export const nameMustNotStartWithCodegenPrefix = (node: TslDeclaration, accept: // Core declaration // ----------------------------------------------------------------------------- -export const nameMustNotOccurOnCoreDeclaration = (services: SafeDsServices) => { +export const nameMustNotOccurOnCoreDeclaration = (services: TTSLServices) => { const packageManager = services.workspace.PackageManager; return (node: TslDeclaration, accept: ValidationAcceptor) => { @@ -82,7 +82,7 @@ export const nameMustNotOccurOnCoreDeclaration = (services: SafeDsServices) => { // Casing // ----------------------------------------------------------------------------- -export const nameShouldHaveCorrectCasing = (services: SafeDsServices) => { +export const nameShouldHaveCorrectCasing = (services: TTSLServices) => { const settingsProvider = services.workspace.SettingsProvider; return async (node: TslDeclaration, accept: ValidationAcceptor) => { @@ -149,7 +149,7 @@ export const callableTypeMustContainUniqueNames = (node: TslCallableType, accept namesMustBeUnique(getResults(node), (name) => `A result with name '${name}' exists already.`, accept); }; -export const moduleMemberMustHaveNameThatIsUniqueInPackage = (services: SafeDsServices) => { +export const moduleMemberMustHaveNameThatIsUniqueInPackage = (services: TTSLServices) => { const packageManager = services.workspace.PackageManager; const builtinUris = new Set(listBuiltinFiles().map((it) => it.toString())); diff --git a/packages/ttsl-lang/src/language/validation/other/argumentLists.ts b/packages/ttsl-lang/src/language/validation/other/argumentLists.ts index 5cb232f2..caab7fb8 100644 --- a/packages/ttsl-lang/src/language/validation/other/argumentLists.ts +++ b/packages/ttsl-lang/src/language/validation/other/argumentLists.ts @@ -3,7 +3,7 @@ import { duplicatesBy, isEmpty } from '../../../helpers/collections.js'; import { pluralize } from '../../../helpers/strings.js'; import { isTslCall, TslAbstractCall, TslArgumentList } from '../../generated/ast.js'; import { getArguments, getParameters, Parameter } from '../../helpers/nodeProperties.js'; -import { SafeDsServices } from '../../safe-ds-module.js'; +import { TTSLServices } from '../../ttsl-module.js'; export const CODE_ARGUMENT_LIST_DUPLICATE_PARAMETER = 'argument-list/duplicate-parameter'; export const CODE_ARGUMENT_LIST_MISSING_REQUIRED_PARAMETER = 'argument-list/missing-required-parameter'; @@ -27,7 +27,7 @@ export const argumentListMustNotHavePositionalArgumentsAfterNamedArguments = ( } }; -export const argumentListMustNotHaveTooManyArguments = (services: SafeDsServices) => { +export const argumentListMustNotHaveTooManyArguments = (services: TTSLServices) => { const nodeMapper = services.helpers.NodeMapper; return (node: TslAbstractCall, accept: ValidationAcceptor): void => { @@ -70,7 +70,7 @@ export const argumentListMustNotHaveTooManyArguments = (services: SafeDsServices }; }; -export const argumentListMustNotSetParameterMultipleTimes = (services: SafeDsServices) => { +export const argumentListMustNotSetParameterMultipleTimes = (services: TTSLServices) => { const nodeMapper = services.helpers.NodeMapper; const argumentToParameterOrUndefined = nodeMapper.argumentToParameter.bind(nodeMapper); @@ -92,7 +92,7 @@ export const argumentListMustNotSetParameterMultipleTimes = (services: SafeDsSer }; }; -export const argumentListMustSetAllRequiredParameters = (services: SafeDsServices) => { +export const argumentListMustSetAllRequiredParameters = (services: TTSLServices) => { const nodeMapper = services.helpers.NodeMapper; return (node: TslAbstractCall, accept: ValidationAcceptor): void => { diff --git a/packages/ttsl-lang/src/language/validation/other/declarations/parameters.ts b/packages/ttsl-lang/src/language/validation/other/declarations/parameters.ts index 083b628c..b61f45a1 100644 --- a/packages/ttsl-lang/src/language/validation/other/declarations/parameters.ts +++ b/packages/ttsl-lang/src/language/validation/other/declarations/parameters.ts @@ -1,12 +1,12 @@ import { AstUtils, ValidationAcceptor } from 'langium'; import { isTslCallable, TslParameter } from '../../../generated/ast.js'; import { Parameter } from '../../../helpers/nodeProperties.js'; -import { SafeDsServices } from '../../../safe-ds-module.js'; +import { TTSLServices } from '../../../ttsl-module.js'; export const CODE_PARAMETER_CONSTANT_DEFAULT_VALUE = 'parameter/constant-default-value'; export const CODE_PARAMETER_CONSTANT_TYPE = 'parameter/constant-type'; -export const constantParameterMustHaveConstantDefaultValue = (services: SafeDsServices) => { +export const constantParameterMustHaveConstantDefaultValue = (services: TTSLServices) => { const partialEvaluator = services.evaluation.PartialEvaluator; return (node: TslParameter, accept: ValidationAcceptor) => { @@ -24,7 +24,7 @@ export const constantParameterMustHaveConstantDefaultValue = (services: SafeDsSe }; }; -export const constantParameterMustHaveTypeThatCanBeEvaluatedToConstant = (services: SafeDsServices) => { +export const constantParameterMustHaveTypeThatCanBeEvaluatedToConstant = (services: TTSLServices) => { const typeChecker = services.types.TypeChecker; const typeComputer = services.types.TypeComputer; diff --git a/packages/ttsl-lang/src/language/validation/other/declarations/placeholders.ts b/packages/ttsl-lang/src/language/validation/other/declarations/placeholders.ts index ff55d0b2..e84ecdb2 100644 --- a/packages/ttsl-lang/src/language/validation/other/declarations/placeholders.ts +++ b/packages/ttsl-lang/src/language/validation/other/declarations/placeholders.ts @@ -8,7 +8,7 @@ import { TslPlaceholder, } from '../../../generated/ast.js'; import { AstUtils, ValidationAcceptor } from 'langium'; -import { SafeDsServices } from '../../../safe-ds-module.js'; +import { TTSLServices } from '../../../ttsl-module.js'; import { getStatements } from '../../../helpers/nodeProperties.js'; import { DiagnosticTag } from 'vscode-languageserver'; import { last } from '../../../../helpers/collections.js'; @@ -38,7 +38,7 @@ export const placeholdersMustNotBeAnAlias = (node: TslPlaceholder, accept: Valid }; export const placeholderShouldBeUsed = - (services: SafeDsServices) => (node: TslPlaceholder, accept: ValidationAcceptor) => { + (services: TTSLServices) => (node: TslPlaceholder, accept: ValidationAcceptor) => { const usages = services.helpers.NodeMapper.placeholderToReferences(node); if (!usages.isEmpty()) { return; diff --git a/packages/ttsl-lang/src/language/validation/other/expressions/calls.ts b/packages/ttsl-lang/src/language/validation/other/expressions/calls.ts index 43a998f9..45eff5d0 100644 --- a/packages/ttsl-lang/src/language/validation/other/expressions/calls.ts +++ b/packages/ttsl-lang/src/language/validation/other/expressions/calls.ts @@ -1,12 +1,12 @@ import { ValidationAcceptor } from 'langium'; import { type TslCall } from '../../../generated/ast.js'; import { getArguments, Parameter } from '../../../helpers/nodeProperties.js'; -import { SafeDsServices } from '../../../safe-ds-module.js'; +import { TTSLServices } from '../../../ttsl-module.js'; export const CODE_CALL_CONSTANT_ARGUMENT = 'call/constant-argument'; export const CODE_CALL_INFINITE_RECURSION = 'call/infinite-recursion'; -export const callArgumentMustBeConstantIfParameterIsConstant = (services: SafeDsServices) => { +export const callArgumentMustBeConstantIfParameterIsConstant = (services: TTSLServices) => { const nodeMapper = services.helpers.NodeMapper; const partialEvaluator = services.evaluation.PartialEvaluator; @@ -33,7 +33,7 @@ export const callArgumentMustBeConstantIfParameterIsConstant = (services: SafeDs }; }; -export const callMustNotBeRecursive = (services: SafeDsServices) => { +export const callMustNotBeRecursive = (services: TTSLServices) => { const callGraphComputer = services.flow.CallGraphComputer; return (node: TslCall, accept: ValidationAcceptor) => { diff --git a/packages/ttsl-lang/src/language/validation/other/expressions/chainedExpressions.ts b/packages/ttsl-lang/src/language/validation/other/expressions/chainedExpressions.ts index befba295..5d6dd530 100644 --- a/packages/ttsl-lang/src/language/validation/other/expressions/chainedExpressions.ts +++ b/packages/ttsl-lang/src/language/validation/other/expressions/chainedExpressions.ts @@ -1,11 +1,11 @@ -import { SafeDsServices } from '../../../safe-ds-module.js'; +import { TTSLServices } from '../../../ttsl-module.js'; import { isTslCall, isTslIndexedAccess, isTslMemberAccess, TslChainedExpression } from '../../../generated/ast.js'; import { ValidationAcceptor } from 'langium'; import { UnknownType } from '../../../typing/model.js'; export const CODE_CHAINED_EXPRESSION_MISSING_NULL_SAFETY = 'chained-expression/missing-null-safety'; -export const chainedExpressionsMustBeNullSafeIfReceiverIsNullable = (services: SafeDsServices) => { +export const chainedExpressionsMustBeNullSafeIfReceiverIsNullable = (services: TTSLServices) => { const typeChecker = services.types.TypeChecker; const typeComputer = services.types.TypeComputer; diff --git a/packages/ttsl-lang/src/language/validation/other/expressions/indexedAccess.ts b/packages/ttsl-lang/src/language/validation/other/expressions/indexedAccess.ts index 792e0abf..9dd2a957 100644 --- a/packages/ttsl-lang/src/language/validation/other/expressions/indexedAccess.ts +++ b/packages/ttsl-lang/src/language/validation/other/expressions/indexedAccess.ts @@ -1,11 +1,11 @@ import { TslIndexedAccess } from '../../../generated/ast.js'; import { ValidationAcceptor } from 'langium'; -import { SafeDsServices } from '../../../safe-ds-module.js'; +import { TTSLServices } from '../../../ttsl-module.js'; import { EvaluatedList, EvaluatedMap, IntConstant } from '../../../partialEvaluation/model.js'; export const CODE_INDEXED_ACCESS_INVALID_INDEX = 'indexed-access/invalid-index'; -export const indexedAccessIndexMustBeValid = (services: SafeDsServices) => { +export const indexedAccessIndexMustBeValid = (services: TTSLServices) => { const partialEvaluator = services.evaluation.PartialEvaluator; const typeChecker = services.types.TypeChecker; const typeComputer = services.types.TypeComputer; diff --git a/packages/ttsl-lang/src/language/validation/other/expressions/infixOperations.ts b/packages/ttsl-lang/src/language/validation/other/expressions/infixOperations.ts index abbe25b4..b03f0ef3 100644 --- a/packages/ttsl-lang/src/language/validation/other/expressions/infixOperations.ts +++ b/packages/ttsl-lang/src/language/validation/other/expressions/infixOperations.ts @@ -1,12 +1,12 @@ import { TslInfixOperation } from '../../../generated/ast.js'; import { ValidationAcceptor } from 'langium'; -import { SafeDsServices } from '../../../safe-ds-module.js'; +import { TTSLServices } from '../../../ttsl-module.js'; import { FloatConstant, IntConstant, NumberConstant } from '../../../partialEvaluation/model.js'; import { UnknownType } from '../../../typing/model.js'; export const CODE_INFIX_OPERATION_DIVISION_BY_ZERO = 'infix-operation/division-by-zero'; -export const divisionDivisorMustNotBeZero = (services: SafeDsServices) => { +export const divisionDivisorMustNotBeZero = (services: TTSLServices) => { const coreTypes = services.types.CoreTypes; const partialEvaluator = services.evaluation.PartialEvaluator; const typeChecker = services.types.TypeChecker; diff --git a/packages/ttsl-lang/src/language/validation/other/imports.ts b/packages/ttsl-lang/src/language/validation/other/imports.ts index 92bfdf0a..1beafa8a 100644 --- a/packages/ttsl-lang/src/language/validation/other/imports.ts +++ b/packages/ttsl-lang/src/language/validation/other/imports.ts @@ -1,13 +1,13 @@ import { ValidationAcceptor } from 'langium'; import { TslImport } from '../../generated/ast.js'; -import { SafeDsServices } from '../../safe-ds-module.js'; +import { TTSLServices } from '../../ttsl-module.js'; import { isEmpty } from '../../../helpers/collections.js'; export const CODE_IMPORT_MISSING_PACKAGE = 'import/missing-package'; export const CODE_IMPORT_EMPTY_PACKAGE = 'import/empty-package'; export const importPackageMustExist = - (services: SafeDsServices) => + (services: TTSLServices) => (node: TslImport, accept: ValidationAcceptor): void => { if (!services.workspace.PackageManager.hasPackage(node.package)) { accept('error', `The package '${node.package}' does not exist.`, { @@ -18,7 +18,7 @@ export const importPackageMustExist = }; export const importPackageShouldNotBeEmpty = - (services: SafeDsServices) => + (services: TTSLServices) => (node: TslImport, accept: ValidationAcceptor): void => { const declarationsInPackage = services.workspace.PackageManager.getDeclarationsInPackage(node.package); if (isEmpty(declarationsInPackage)) { diff --git a/packages/ttsl-lang/src/language/validation/other/statements/assignments.ts b/packages/ttsl-lang/src/language/validation/other/statements/assignments.ts index e6e3cbce..43a93534 100644 --- a/packages/ttsl-lang/src/language/validation/other/statements/assignments.ts +++ b/packages/ttsl-lang/src/language/validation/other/statements/assignments.ts @@ -1,6 +1,6 @@ import { isTslCall, TslAssignment} from '../../../generated/ast.js'; import { ValidationAcceptor } from 'langium'; -import { SafeDsServices } from '../../../safe-ds-module.js'; +import { TTSLServices } from '../../../ttsl-module.js'; import { getResults, getAssignees } from '../../../helpers/nodeProperties.js'; import { pluralize } from '../../../../helpers/strings.js'; @@ -8,7 +8,7 @@ export const CODE_ASSIGNMENT_IMPLICITLY_IGNORED_RESULT = 'assignment/implicitly- export const CODE_ASSIGMENT_NOTHING_ASSIGNED = 'assignment/nothing-assigned'; export const assignmentAssigneeMustGetValue = - (services: SafeDsServices) => + (services: TTSLServices) => (node: TslAssignment, accept: ValidationAcceptor): void => { for (const assignee of getAssignees(node)) { if (!services.helpers.NodeMapper.assigneeToAssignedObject(assignee)) { @@ -20,7 +20,7 @@ export const assignmentAssigneeMustGetValue = } }; -export const assignmentShouldNotImplicitlyIgnoreResult = (services: SafeDsServices) => { +export const assignmentShouldNotImplicitlyIgnoreResult = (services: TTSLServices) => { const nodeMapper = services.helpers.NodeMapper; return (node: TslAssignment, accept: ValidationAcceptor): void => { diff --git a/packages/ttsl-lang/src/language/validation/style.ts b/packages/ttsl-lang/src/language/validation/style.ts index 305e8043..816542e9 100644 --- a/packages/ttsl-lang/src/language/validation/style.ts +++ b/packages/ttsl-lang/src/language/validation/style.ts @@ -12,7 +12,7 @@ import { } from '../generated/ast.js'; import { getParameters} from '../helpers/nodeProperties.js'; import { NullConstant } from '../partialEvaluation/model.js'; -import { SafeDsServices } from '../safe-ds-module.js'; +import { TTSLServices } from '../ttsl-module.js'; import { UnknownType } from '../typing/model.js'; export const CODE_STYLE_UNNECESSARY_ARGUMENT_LIST = 'style/unnecessary-argument-list'; @@ -25,7 +25,7 @@ export const CODE_STYLE_UNNECESSARY_RESULT_LIST = 'style/unnecessary-result-list // Unnecessary argument lists // ----------------------------------------------------------------------------- -export const callArgumentListShouldBeNeeded = (services: SafeDsServices) => { +export const callArgumentListShouldBeNeeded = (services: TTSLServices) => { const settingsProvider = services.workspace.SettingsProvider; return async (node: TslCall, accept: ValidationAcceptor) => { @@ -59,7 +59,7 @@ export const callArgumentListShouldBeNeeded = (services: SafeDsServices) => { // Unnecessary elvis operator // ----------------------------------------------------------------------------- -export const elvisOperatorShouldBeNeeded = (services: SafeDsServices) => { +export const elvisOperatorShouldBeNeeded = (services: TTSLServices) => { const partialEvaluator = services.evaluation.PartialEvaluator; const settingsProvider = services.workspace.SettingsProvider; const typeChecker = services.types.TypeChecker; @@ -124,7 +124,7 @@ export const elvisOperatorShouldBeNeeded = (services: SafeDsServices) => { // Unnecessary import alias // ----------------------------------------------------------------------------- -export const importedDeclarationAliasShouldDifferFromDeclarationName = (services: SafeDsServices) => { +export const importedDeclarationAliasShouldDifferFromDeclarationName = (services: TTSLServices) => { const settingsProvider = services.workspace.SettingsProvider; return async (node: TslImportedDeclaration, accept: ValidationAcceptor) => { @@ -147,7 +147,7 @@ export const importedDeclarationAliasShouldDifferFromDeclarationName = (services // Unnecessary null safety // ----------------------------------------------------------------------------- -export const chainedExpressionNullSafetyShouldBeNeeded = (services: SafeDsServices) => { +export const chainedExpressionNullSafetyShouldBeNeeded = (services: TTSLServices) => { const settingsProvider = services.workspace.SettingsProvider; const typeChecker = services.types.TypeChecker; const typeComputer = services.types.TypeComputer; @@ -184,7 +184,7 @@ export const chainedExpressionNullSafetyShouldBeNeeded = (services: SafeDsServic // Unnecessary result lists // ----------------------------------------------------------------------------- -export const functionResultListShouldNotBeEmpty = (services: SafeDsServices) => { +export const functionResultListShouldNotBeEmpty = (services: TTSLServices) => { const settingsProvider = services.workspace.SettingsProvider; return async (node: TslFunction, accept: ValidationAcceptor) => { diff --git a/packages/ttsl-lang/src/language/validation/safe-ds-validator.ts b/packages/ttsl-lang/src/language/validation/ttsl-validator.ts similarity index 98% rename from packages/ttsl-lang/src/language/validation/safe-ds-validator.ts rename to packages/ttsl-lang/src/language/validation/ttsl-validator.ts index fbfa923b..ae371c13 100644 --- a/packages/ttsl-lang/src/language/validation/safe-ds-validator.ts +++ b/packages/ttsl-lang/src/language/validation/ttsl-validator.ts @@ -1,6 +1,6 @@ import { ValidationChecks } from 'langium'; import { TTSLAstType } from '../generated/ast.js'; -import type { SafeDsServices } from '../safe-ds-module.js'; +import type { TTSLServices } from '../ttsl-module.js'; import { mapsShouldBeUsedWithCaution, } from './experimentalLanguageFeatures.js'; @@ -71,7 +71,7 @@ import { groupByVariableMustBeAnID, groupedFunctionHasAggregation, groupedFuncti /** * Register custom validation checks. */ -export const registerValidationChecks = function (services: SafeDsServices) { +export const registerValidationChecks = function (services: TTSLServices) { const registry = services.validation.ValidationRegistry; const checks: ValidationChecks = { TslAssignee: [ diff --git a/packages/ttsl-lang/src/language/validation/types.ts b/packages/ttsl-lang/src/language/validation/types.ts index f15c9731..63eb9b91 100644 --- a/packages/ttsl-lang/src/language/validation/types.ts +++ b/packages/ttsl-lang/src/language/validation/types.ts @@ -14,7 +14,7 @@ import { isTslFunction, } from '../generated/ast.js'; import { getArguments } from '../helpers/nodeProperties.js'; -import { SafeDsServices } from '../safe-ds-module.js'; +import { TTSLServices } from '../ttsl-module.js'; import {NamedTupleType, UnknownType } from '../typing/model.js'; export const CODE_TYPE_CALLABLE_RECEIVER = 'type/callable-receiver'; @@ -25,7 +25,7 @@ export const CODE_TYPE_MISSING_TYPE_HINT = 'type/missing-type-hint'; // Type checking // ----------------------------------------------------------------------------- -export const callArgumentTypesMustMatchParameterTypes = (services: SafeDsServices) => { +export const callArgumentTypesMustMatchParameterTypes = (services: TTSLServices) => { const nodeMapper = services.helpers.NodeMapper; const typeChecker = services.types.TypeChecker; const typeComputer = services.types.TypeComputer; @@ -52,7 +52,7 @@ export const callArgumentTypesMustMatchParameterTypes = (services: SafeDsService }; }; -export const callReceiverMustBeCallable = (services: SafeDsServices) => { +export const callReceiverMustBeCallable = (services: TTSLServices) => { const nodeMapper = services.helpers.NodeMapper; return (node: TslCall, accept: ValidationAcceptor): void => { @@ -80,7 +80,7 @@ export const callReceiverMustBeCallable = (services: SafeDsServices) => { }; }; -export const indexedAccessReceiverMustBeListOrMap = (services: SafeDsServices) => { +export const indexedAccessReceiverMustBeListOrMap = (services: TTSLServices) => { const typeChecker = services.types.TypeChecker; const typeComputer = services.types.TypeComputer; @@ -100,7 +100,7 @@ export const indexedAccessReceiverMustBeListOrMap = (services: SafeDsServices) = }; }; -export const indexedAccessIndexMustHaveCorrectType = (services: SafeDsServices) => { +export const indexedAccessIndexMustHaveCorrectType = (services: TTSLServices) => { const coreTypes = services.types.CoreTypes; const typeChecker = services.types.TypeChecker; const typeComputer = services.types.TypeComputer; @@ -120,7 +120,7 @@ export const indexedAccessIndexMustHaveCorrectType = (services: SafeDsServices) }; }; -export const infixOperationOperandsMustHaveCorrectType = (services: SafeDsServices) => { +export const infixOperationOperandsMustHaveCorrectType = (services: TTSLServices) => { const coreTypes = services.types.CoreTypes; const typeChecker = services.types.TypeChecker; const typeComputer = services.types.TypeComputer; @@ -181,7 +181,7 @@ export const infixOperationOperandsMustHaveCorrectType = (services: SafeDsServic }; }; -export const listMustNotContainNamedTuples = (services: SafeDsServices) => { +export const listMustNotContainNamedTuples = (services: TTSLServices) => { const typeComputer = services.types.TypeComputer; return (node: TslList, accept: ValidationAcceptor): void => { @@ -197,7 +197,7 @@ export const listMustNotContainNamedTuples = (services: SafeDsServices) => { }; }; -export const mapMustNotContainNamedTuples = (services: SafeDsServices) => { +export const mapMustNotContainNamedTuples = (services: TTSLServices) => { const typeComputer = services.types.TypeComputer; return (node: TslDictionary, accept: ValidationAcceptor): void => { @@ -223,7 +223,7 @@ export const mapMustNotContainNamedTuples = (services: SafeDsServices) => { }; }; -export const parameterDefaultValueTypeMustMatchParameterType = (services: SafeDsServices) => { +export const parameterDefaultValueTypeMustMatchParameterType = (services: TTSLServices) => { const typeChecker = services.types.TypeChecker; const typeComputer = services.types.TypeComputer; @@ -246,7 +246,7 @@ export const parameterDefaultValueTypeMustMatchParameterType = (services: SafeDs }; }; -export const prefixOperationOperandMustHaveCorrectType = (services: SafeDsServices) => { +export const prefixOperationOperandMustHaveCorrectType = (services: TTSLServices) => { const coreTypes = services.types.CoreTypes; const typeChecker = services.types.TypeChecker; const typeComputer = services.types.TypeComputer; @@ -283,7 +283,7 @@ export const prefixOperationOperandMustHaveCorrectType = (services: SafeDsServic }; }; -export const typeCastExpressionMustHaveUnknownType = (services: SafeDsServices) => { +export const typeCastExpressionMustHaveUnknownType = (services: TTSLServices) => { const typeComputer = services.types.TypeComputer; return (node: TslTypeCast, accept: ValidationAcceptor): void => { diff --git a/packages/ttsl-lang/src/language/workspace/safe-ds-document-builder.ts b/packages/ttsl-lang/src/language/workspace/ttsl-document-builder.ts similarity index 80% rename from packages/ttsl-lang/src/language/workspace/safe-ds-document-builder.ts rename to packages/ttsl-lang/src/language/workspace/ttsl-document-builder.ts index ddef9fb9..8648a811 100644 --- a/packages/ttsl-lang/src/language/workspace/safe-ds-document-builder.ts +++ b/packages/ttsl-lang/src/language/workspace/ttsl-document-builder.ts @@ -1,6 +1,6 @@ import { BuildOptions, DefaultDocumentBuilder } from 'langium'; -export class SafeDsDocumentBuilder extends DefaultDocumentBuilder { +export class TTSLDocumentBuilder extends DefaultDocumentBuilder { override updateBuildOptions: BuildOptions = { validation: { categories: ['built-in', 'fast'], diff --git a/packages/ttsl-lang/src/language/workspace/safe-ds-package-manager.ts b/packages/ttsl-lang/src/language/workspace/ttsl-package-manager.ts similarity index 97% rename from packages/ttsl-lang/src/language/workspace/safe-ds-package-manager.ts rename to packages/ttsl-lang/src/language/workspace/ttsl-package-manager.ts index 8ed1f35d..465dfea7 100644 --- a/packages/ttsl-lang/src/language/workspace/safe-ds-package-manager.ts +++ b/packages/ttsl-lang/src/language/workspace/ttsl-package-manager.ts @@ -1,4 +1,4 @@ -import { SafeDsServices } from '../safe-ds-module.js'; +import { TTSLServices } from '../ttsl-module.js'; import { AstNode, AstNodeDescription, @@ -11,7 +11,7 @@ import { import { getPackageName, isPackagePrivate, isPrivate } from '../helpers/nodeProperties.js'; import { isTslDeclaration, isTslFunction } from '../generated/ast.js'; -export class SafeDsPackageManager { +export class TTSLPackageManager { private readonly astNodeLocator: AstNodeLocator; private readonly astReflection: AstReflection; private readonly indexManager: IndexManager; @@ -20,7 +20,7 @@ export class SafeDsPackageManager { private readonly packageNames: PackageNames; private readonly packageContents: PackageContents; - constructor(services: SafeDsServices) { + constructor(services: TTSLServices) { this.astNodeLocator = services.workspace.AstNodeLocator; this.astReflection = services.shared.AstReflection; this.indexManager = services.shared.workspace.IndexManager; diff --git a/packages/ttsl-lang/src/language/workspace/safe-ds-settings-provider.ts b/packages/ttsl-lang/src/language/workspace/ttsl-settings-provider.ts similarity index 90% rename from packages/ttsl-lang/src/language/workspace/safe-ds-settings-provider.ts rename to packages/ttsl-lang/src/language/workspace/ttsl-settings-provider.ts index 07651450..173e08d7 100644 --- a/packages/ttsl-lang/src/language/workspace/safe-ds-settings-provider.ts +++ b/packages/ttsl-lang/src/language/workspace/ttsl-settings-provider.ts @@ -1,11 +1,11 @@ import { ConfigurationProvider } from 'langium'; -import { SafeDsServices } from '../safe-ds-module.js'; +import { TTSLServices } from '../ttsl-module.js'; import { TTSLLanguageMetaData } from '../generated/module.js'; -export class SafeDsSettingsProvider { +export class TTSLSettingsProvider { private readonly configurationProvider: ConfigurationProvider; - constructor(services: SafeDsServices) { + constructor(services: TTSLServices) { this.configurationProvider = services.shared.workspace.ConfigurationProvider; } diff --git a/packages/ttsl-lang/src/language/workspace/safe-ds-workspace-manager.ts b/packages/ttsl-lang/src/language/workspace/ttsl-workspace-manager.ts similarity index 92% rename from packages/ttsl-lang/src/language/workspace/safe-ds-workspace-manager.ts rename to packages/ttsl-lang/src/language/workspace/ttsl-workspace-manager.ts index c13f9b04..111cc092 100644 --- a/packages/ttsl-lang/src/language/workspace/safe-ds-workspace-manager.ts +++ b/packages/ttsl-lang/src/language/workspace/ttsl-workspace-manager.ts @@ -3,7 +3,7 @@ import { WorkspaceFolder } from 'vscode-languageserver'; import { listBuiltinFiles } from '../builtins/fileFinder.js'; import { type LangiumSharedServices } from 'langium/lsp'; -export class SafeDsWorkspaceManager extends DefaultWorkspaceManager { +export class TTSLWorkspaceManager extends DefaultWorkspaceManager { private documentFactory: LangiumDocumentFactory; constructor(services: LangiumSharedServices) { diff --git a/packages/ttsl-lang/src/resources/builtins/safeds/lang/annotationUsage.sdsstub b/packages/ttsl-lang/src/resources/builtins/safeds/lang/annotationUsage.sdsstub index 41e33541..0845cd38 100644 --- a/packages/ttsl-lang/src/resources/builtins/safeds/lang/annotationUsage.sdsstub +++ b/packages/ttsl-lang/src/resources/builtins/safeds/lang/annotationUsage.sdsstub @@ -1,4 +1,4 @@ -package safeds.lang +package TTSL.lang /** * The annotation must target only the specified declaration types. By default, any declaration type can be targeted. diff --git a/packages/ttsl-lang/src/resources/builtins/safeds/lang/codeGeneration.sdsstub b/packages/ttsl-lang/src/resources/builtins/safeds/lang/codeGeneration.sdsstub index 6d43f54f..ec97770a 100644 --- a/packages/ttsl-lang/src/resources/builtins/safeds/lang/codeGeneration.sdsstub +++ b/packages/ttsl-lang/src/resources/builtins/safeds/lang/codeGeneration.sdsstub @@ -1,4 +1,4 @@ -package safeds.lang +package TTSL.lang /** * The specification of a corresponding function call in Python. By default, the function is called as specified in the diff --git a/packages/ttsl-lang/src/resources/builtins/safeds/lang/coreClasses.sdsstub b/packages/ttsl-lang/src/resources/builtins/safeds/lang/coreClasses.sdsstub index b0c0c3a4..7aed621c 100644 --- a/packages/ttsl-lang/src/resources/builtins/safeds/lang/coreClasses.sdsstub +++ b/packages/ttsl-lang/src/resources/builtins/safeds/lang/coreClasses.sdsstub @@ -1,4 +1,4 @@ -package safeds.lang +package TTSL.lang /** * The common superclass of all classes. diff --git a/packages/ttsl-lang/src/resources/builtins/safeds/lang/ideIntegration.sdsstub b/packages/ttsl-lang/src/resources/builtins/safeds/lang/ideIntegration.sdsstub index 9eed1615..b2fb5170 100644 --- a/packages/ttsl-lang/src/resources/builtins/safeds/lang/ideIntegration.sdsstub +++ b/packages/ttsl-lang/src/resources/builtins/safeds/lang/ideIntegration.sdsstub @@ -1,4 +1,4 @@ -package safeds.lang +package TTSL.lang /** * This parameter should only be used by expert users. diff --git a/packages/ttsl-lang/src/resources/builtins/safeds/lang/maturity.sdsstub b/packages/ttsl-lang/src/resources/builtins/safeds/lang/maturity.sdsstub index 509f20d6..ee8c2fce 100644 --- a/packages/ttsl-lang/src/resources/builtins/safeds/lang/maturity.sdsstub +++ b/packages/ttsl-lang/src/resources/builtins/safeds/lang/maturity.sdsstub @@ -1,4 +1,4 @@ -package safeds.lang +package TTSL.lang /** * The declaration should no longer be used. diff --git a/packages/ttsl-lang/src/resources/builtins/safeds/lang/purity.sdsstub b/packages/ttsl-lang/src/resources/builtins/safeds/lang/purity.sdsstub index 2c5ab95f..14578097 100644 --- a/packages/ttsl-lang/src/resources/builtins/safeds/lang/purity.sdsstub +++ b/packages/ttsl-lang/src/resources/builtins/safeds/lang/purity.sdsstub @@ -1,4 +1,4 @@ -package safeds.lang +package TTSL.lang /** * Indicates that the function has no side effects and always returns the same results given the same arguments. diff --git a/packages/ttsl-lang/tests/helpers/nodeFinder.test.ts b/packages/ttsl-lang/tests/helpers/nodeFinder.test.ts index 2bd9133a..7a7aa8e0 100644 --- a/packages/ttsl-lang/tests/helpers/nodeFinder.test.ts +++ b/packages/ttsl-lang/tests/helpers/nodeFinder.test.ts @@ -1,13 +1,13 @@ import { afterEach, describe, expect, it } from 'vitest'; import { getNodeByLocation, getNodeOfType } from './nodeFinder.js'; -import { createSafeDsServices } from '../../src/language/index.js'; +import { createTTSLServices } from '../../src/language/index.js'; import { EmptyFileSystem } from 'langium'; import { AssertionError } from 'assert'; import { clearDocuments, parseHelper } from 'langium/test'; import { isTslClass, isTslDeclaration, isTslEnum } from '../../src/language/generated/ast.js'; describe('getNodeByLocation', async () => { - const services = (await createSafeDsServices(EmptyFileSystem, { omitBuiltins: true })).SafeDs; + const services = (await createTTSLServices(EmptyFileSystem, { omitBuiltins: true })).TTSL; afterEach(async () => { await clearDocuments(services); @@ -57,7 +57,7 @@ describe('getNodeByLocation', async () => { }); describe('getNodeOfType', async () => { - const services = (await createSafeDsServices(EmptyFileSystem, { omitBuiltins: true })).SafeDs; + const services = (await createTTSLServices(EmptyFileSystem, { omitBuiltins: true })).TTSL; afterEach(async () => { await clearDocuments(services); diff --git a/packages/ttsl-lang/tests/helpers/nodeFinder.ts b/packages/ttsl-lang/tests/helpers/nodeFinder.ts index 06c908de..81f2e167 100644 --- a/packages/ttsl-lang/tests/helpers/nodeFinder.ts +++ b/packages/ttsl-lang/tests/helpers/nodeFinder.ts @@ -1,6 +1,6 @@ import { Location, Range } from 'vscode-languageserver'; import { isRangeEqual, parseHelper } from 'langium/test'; -import { SafeDsServices } from '../../src/language/index.js'; +import { TTSLServices } from '../../src/language/index.js'; import { AstNode, AstUtils, URI } from 'langium'; import { TslModule } from '../../src/language/generated/ast.js'; import { AssertionError } from 'assert'; @@ -14,7 +14,7 @@ import { locationToString } from '../../src/helpers/locations.js'; * @returns The node at the given location. * @throws AssertionError If no matching node was found. */ -export const getNodeByLocation = (services: SafeDsServices, location: Location): AstNode => { +export const getNodeByLocation = (services: TTSLServices, location: Location): AstNode => { const langiumDocuments = services.shared.workspace.LangiumDocuments; const uri = URI.parse(location.uri); @@ -47,7 +47,7 @@ export const getNodeByLocation = (services: SafeDsServices, location: Location): /** * Returns the range of the name of the given node or undefined if the node has no name. */ -const getNameRange = (services: SafeDsServices, node: AstNode): Range | undefined => { +const getNameRange = (services: TTSLServices, node: AstNode): Range | undefined => { return services.references.NameProvider.getNameNode(node)?.range; }; @@ -60,7 +60,7 @@ const getNameRange = (services: SafeDsServices, node: AstNode): Range | undefine * @param index The index of the node to find. */ export const getNodeOfType = async ( - services: SafeDsServices, + services: TTSLServices, code: string, predicate: (value: unknown) => value is T, index: number = 0, diff --git a/packages/ttsl-lang/tests/helpers/resources.test.ts b/packages/ttsl-lang/tests/helpers/resources.test.ts index 5f348953..8c194df5 100644 --- a/packages/ttsl-lang/tests/helpers/resources.test.ts +++ b/packages/ttsl-lang/tests/helpers/resources.test.ts @@ -3,15 +3,15 @@ import { resourceNameToUri, uriToShortenedResourceName } from '../../src/helpers describe('uriToShortenedResourceName', () => { it('should return the corresponding resource name if no root resource name is given', () => { - const resourceName = 'helpers/listSafeDsFiles'; + const resourceName = 'helpers/listTTSLFiles'; const actual = uriToShortenedResourceName(resourceNameToUri(resourceName)); expect(normalizeResourceName(actual)).toBe(normalizeResourceName(resourceName)); }); it('should return a shortened resource name if a root resource name is given', () => { - const resourceName = 'helpers/nested/listSafeDsFiles'; + const resourceName = 'helpers/nested/listTTSLFiles'; const actual = uriToShortenedResourceName(resourceNameToUri(resourceName), 'helpers/nested'); - expect(actual).toBe('listSafeDsFiles'); + expect(actual).toBe('listTTSLFiles'); }); }); diff --git a/packages/ttsl-lang/tests/helpers/testResources.test.ts b/packages/ttsl-lang/tests/helpers/testResources.test.ts index 38099123..33260e34 100644 --- a/packages/ttsl-lang/tests/helpers/testResources.test.ts +++ b/packages/ttsl-lang/tests/helpers/testResources.test.ts @@ -1,8 +1,8 @@ import { describe, expect, it } from 'vitest'; import { listTestFilesWithExtensions, - listTestSafeDsFiles, - listTestSafeDsFilesGroupedByParentDirectory, + listTestTTSLFiles, + listTestTTSLFilesGroupedByParentDirectory, ShortenedTestResourceName, TestResourceName, testResourceNameToUri, @@ -12,22 +12,22 @@ import { URI } from 'langium'; describe('uriToShortenedTestResourceName', () => { it('should return the corresponding resource name if no root resource name is given', () => { - const resourceName = 'helpers/listSafeDsFiles'; + const resourceName = 'helpers/listTTSLFiles'; const actual = uriToShortenedTestResourceName(testResourceNameToUri(resourceName)); expect(normalizeResourceName(actual)).toBe(normalizeResourceName(resourceName)); }); it('should return a shortened resource name if a root resource name is given', () => { - const resourceName = 'helpers/nested/listSafeDsFiles'; + const resourceName = 'helpers/nested/listTTSLFiles'; const actual = uriToShortenedTestResourceName(testResourceNameToUri(resourceName), 'helpers/nested'); - expect(actual).toBe('listSafeDsFiles'); + expect(actual).toBe('listTTSLFiles'); }); }); -describe('listTestSafeDsFiles', () => { - it('should return all Safe-DS files in a resource directory that are not skipped', () => { - const rootResourceName = 'helpers/listSafeDsFiles'; - const actual = listTestSafeDsFiles(rootResourceName); +describe('listTestTTSLFiles', () => { + it('should return all TTSL files in a resource directory that are not skipped', () => { + const rootResourceName = 'helpers/listTTSLFiles'; + const actual = listTestTTSLFiles(rootResourceName); const expected = [ 'pipeline file.Tslpipe', 'stub file.Tslstub', @@ -51,10 +51,10 @@ describe('listTestFilesWithExtensions', () => { }); }); -describe('listTestSafeDsFilesGroupedByParentDirectory', () => { - it('should return all Safe-DS files in a directory that are not skipped and group them by parent directory', () => { - const rootResourceName = 'helpers/listSafeDsFiles'; - const result = new Map(listTestSafeDsFilesGroupedByParentDirectory(rootResourceName)); +describe('listTestTTSLFilesGroupedByParentDirectory', () => { + it('should return all TTSL files in a directory that are not skipped and group them by parent directory', () => { + const rootResourceName = 'helpers/listTTSLFiles'; + const result = new Map(listTestTTSLFilesGroupedByParentDirectory(rootResourceName)); // Compare the keys, i.e. the parent directories const actualKeys = [...result.keys()]; diff --git a/packages/ttsl-lang/tests/helpers/testResources.ts b/packages/ttsl-lang/tests/helpers/testResources.ts index 05e0a20e..3a58c794 100644 --- a/packages/ttsl-lang/tests/helpers/testResources.ts +++ b/packages/ttsl-lang/tests/helpers/testResources.ts @@ -2,7 +2,7 @@ import path from 'path'; import { globSync } from 'glob'; import { TSL_FILE_EXTENSIONS } from '../../src/language/helpers/fileExtensions.js'; import { BuildOptions, LangiumDocument, URI } from 'langium'; -import { SafeDsServices } from '../../src/language/index.js'; +import { TTSLServices } from '../../src/language/index.js'; import { groupBy } from '../../src/helpers/collections.js'; import { fileURLToPath } from 'url'; @@ -44,12 +44,12 @@ export const uriToShortenedTestResourceName = ( }; /** - * Lists all Safe-DS files in the given root directory that are not skipped. + * Lists all TTSL files in the given root directory that are not skipped. * * @param rootTestResourceName The resource name of the root directory. - * @return URIs of the discovered Safe-DS files. + * @return URIs of the discovered TTSL files. */ -export const listTestSafeDsFiles = (rootTestResourceName: TestResourceName): URI[] => { +export const listTestTTSLFiles = (rootTestResourceName: TestResourceName): URI[] => { const rootPath = testResourceNameToUri(rootTestResourceName).fsPath; return listTestFilesWithExtensions(rootTestResourceName, TSL_FILE_EXTENSIONS).filter((uri) => isNotSkipped(path.relative(rootPath, uri.fsPath)), @@ -71,14 +71,14 @@ export const listTestFilesWithExtensions = (rootTestResourceName: TestResourceNa }; /** - * Lists all Safe-DS files in the given root directory that are not skipped. The result is grouped by the parent + * Lists all TTSL files in the given root directory that are not skipped. The result is grouped by the parent * directory. * * @param rootTestResourceName The resource name of the root directory. - * @return URIs of the discovered Safe-DS files grouped by the parent directory. + * @return URIs of the discovered TTSL files grouped by the parent directory. */ -export const listTestSafeDsFilesGroupedByParentDirectory = (rootTestResourceName: TestResourceName): [URI, URI[]][] => { - const uris = listTestSafeDsFiles(rootTestResourceName); +export const listTestTTSLFilesGroupedByParentDirectory = (rootTestResourceName: TestResourceName): [URI, URI[]][] => { + const uris = listTestTTSLFiles(rootTestResourceName); const groupedByParentDirectory = groupBy(uris, (p) => path.dirname(p.fsPath)); const result: [URI, URI[]][] = []; @@ -103,7 +103,7 @@ const isNotSkipped = (pathRelativeToResources: string) => { * @returns The loaded documents. */ export const loadDocuments = async ( - services: SafeDsServices, + services: TTSLServices, uris: URI[], options: BuildOptions = {}, ): Promise => { diff --git a/packages/ttsl-lang/tests/language/builtins/builtinFilesCorrectness.test.ts b/packages/ttsl-lang/tests/language/builtins/builtinFilesCorrectness.test.ts index 647c4715..163fa845 100644 --- a/packages/ttsl-lang/tests/language/builtins/builtinFilesCorrectness.test.ts +++ b/packages/ttsl-lang/tests/language/builtins/builtinFilesCorrectness.test.ts @@ -6,13 +6,13 @@ import { Diagnostic, DiagnosticSeverity } from 'vscode-languageserver'; import { isEmpty } from '../../../src/helpers/collections.js'; import { uriToShortenedResourceName } from '../../../src/helpers/resources.js'; import { listBuiltinFiles } from '../../../src/language/builtins/fileFinder.js'; -import { createSafeDsServices } from '../../../src/language/index.js'; +import { createTTSLServices } from '../../../src/language/index.js'; import { CODE_EXPERIMENTAL_LIBRARY_ELEMENT } from '../../../src/language/validation/builtins/experimental.js'; import { CODE_EXPERIMENTAL_LANGUAGE_FEATURE } from '../../../src/language/validation/experimentalLanguageFeatures.js'; import { locationToString } from '../../../src/helpers/locations.js'; import { loadDocuments } from '../../helpers/testResources.js'; -const services = (await createSafeDsServices(NodeFileSystem)).SafeDs; +const services = (await createTTSLServices(NodeFileSystem)).TTSL; const langiumDocuments = services.shared.workspace.LangiumDocuments; const builtinFiles = listBuiltinFiles(); diff --git a/packages/ttsl-lang/tests/language/documentation/safe-ds-comment-provider.test.ts b/packages/ttsl-lang/tests/language/documentation/safe-ds-comment-provider.test.ts index 7f27ad3e..45babf9c 100644 --- a/packages/ttsl-lang/tests/language/documentation/safe-ds-comment-provider.test.ts +++ b/packages/ttsl-lang/tests/language/documentation/safe-ds-comment-provider.test.ts @@ -12,14 +12,14 @@ import { isTslResult, isTslTypeParameter, } from '../../../src/language/generated/ast.js'; -import { createSafeDsServices } from '../../../src/language/index.js'; +import { createTTSLServices } from '../../../src/language/index.js'; import { getNodeOfType } from '../../helpers/nodeFinder.js'; -const services = (await createSafeDsServices(EmptyFileSystem, { omitBuiltins: true })).SafeDs; +const services = (await createTTSLServices(EmptyFileSystem, { omitBuiltins: true })).TTSL; const commentProvider = services.documentation.CommentProvider; const testComment = '/* test */'; -describe('SafeDsCommentProvider', () => { +describe('TTSLCommentProvider', () => { const testCases: CommentProviderTest[] = [ { testName: 'commented module member (without annotations)', diff --git a/packages/ttsl-lang/tests/language/documentation/safe-ds-documentation-provider.test.ts b/packages/ttsl-lang/tests/language/documentation/safe-ds-documentation-provider.test.ts index 72cf2298..ee9ac6ec 100644 --- a/packages/ttsl-lang/tests/language/documentation/safe-ds-documentation-provider.test.ts +++ b/packages/ttsl-lang/tests/language/documentation/safe-ds-documentation-provider.test.ts @@ -8,15 +8,15 @@ import { isTslResult, isTslTypeParameter, } from '../../../src/language/generated/ast.js'; -import { createSafeDsServices } from '../../../src/language/index.js'; +import { createTTSLServices } from '../../../src/language/index.js'; import { getNodeOfType } from '../../helpers/nodeFinder.js'; import { expandToString } from 'langium/generate'; -const services = (await createSafeDsServices(EmptyFileSystem, { omitBuiltins: true })).SafeDs; +const services = (await createTTSLServices(EmptyFileSystem, { omitBuiltins: true })).TTSL; const documentationProvider = services.documentation.DocumentationProvider; const testDocumentation = 'Lorem ipsum.'; -describe('SafeDsDocumentationProvider', () => { +describe('TTSLDocumentationProvider', () => { const testCases: DocumentationProviderTest[] = [ { testName: 'module member', diff --git a/packages/ttsl-lang/tests/language/flow/creator.ts b/packages/ttsl-lang/tests/language/flow/creator.ts index f6f36685..cc20b23d 100644 --- a/packages/ttsl-lang/tests/language/flow/creator.ts +++ b/packages/ttsl-lang/tests/language/flow/creator.ts @@ -1,17 +1,17 @@ -import { listTestSafeDsFiles, uriToShortenedTestResourceName } from '../../helpers/testResources.js'; +import { listTestTTSLFiles, uriToShortenedTestResourceName } from '../../helpers/testResources.js'; import { Location } from 'vscode-languageserver'; import { EmptyFileSystem, URI } from 'langium'; -import { createSafeDsServices } from '../../../src/language/index.js'; +import { createTTSLServices } from '../../../src/language/index.js'; import { TestDescription, TestDescriptionError } from '../../helpers/testDescription.js'; import fs from 'fs'; import { getSyntaxErrors, SyntaxErrorsInCodeError } from '../../helpers/diagnostics.js'; import { findTestChecks } from '../../helpers/testChecks.js'; -const services = (await createSafeDsServices(EmptyFileSystem, { omitBuiltins: true })).SafeDs; +const services = (await createTTSLServices(EmptyFileSystem, { omitBuiltins: true })).TTSL; const rootResourceName = 'call graph'; export const createCallGraphTests = (): Promise => { - const uris = listTestSafeDsFiles(rootResourceName); + const uris = listTestTTSLFiles(rootResourceName); const testCases = uris.map((it) => createCallGraphTest(it)); return Promise.all(testCases); diff --git a/packages/ttsl-lang/tests/language/flow/model.test.ts b/packages/ttsl-lang/tests/language/flow/model.test.ts index 75cc4872..91836ee9 100644 --- a/packages/ttsl-lang/tests/language/flow/model.test.ts +++ b/packages/ttsl-lang/tests/language/flow/model.test.ts @@ -1,11 +1,11 @@ import { describe, expect, it } from 'vitest'; import { CallGraph } from '../../../src/language/flow/model.js'; import { getNodeOfType } from '../../helpers/nodeFinder.js'; -import { createSafeDsServices } from '../../../src/language/index.js'; +import { createTTSLServices } from '../../../src/language/index.js'; import { EmptyFileSystem } from 'langium'; import { isTslModule, TslCallable } from '../../../src/language/generated/ast.js'; -const services = (await createSafeDsServices(EmptyFileSystem, { omitBuiltins: true })).SafeDs; +const services = (await createTTSLServices(EmptyFileSystem, { omitBuiltins: true })).TTSL; const code = ` fun f1() fun f2() diff --git a/packages/ttsl-lang/tests/language/flow/safe-ds-call-graph-computer.test.ts b/packages/ttsl-lang/tests/language/flow/safe-ds-call-graph-computer.test.ts index 8a500246..29b9e501 100644 --- a/packages/ttsl-lang/tests/language/flow/safe-ds-call-graph-computer.test.ts +++ b/packages/ttsl-lang/tests/language/flow/safe-ds-call-graph-computer.test.ts @@ -9,7 +9,7 @@ import { TslCall, TslCallable, } from '../../../src/language/generated/ast.js'; -import { createSafeDsServices } from '../../../src/language/index.js'; +import { createTTSLServices } from '../../../src/language/index.js'; import { createCallGraphTests } from './creator.js'; import { getNodeOfType } from '../../helpers/nodeFinder.js'; import { isRangeEqual } from 'langium/test'; @@ -17,10 +17,10 @@ import { locationToString } from '../../../src/helpers/locations.js'; import { AssertionError } from 'assert'; import { NodeFileSystem } from 'langium/node'; -const services = (await createSafeDsServices(NodeFileSystem)).SafeDs; +const services = (await createTTSLServices(NodeFileSystem)).TTSL; const callGraphComputer = services.flow.CallGraphComputer; -describe('SafeDsCallGraphComputer', () => { +describe('TTSLCallGraphComputer', () => { describe('getCallGraph', async () => { it.each(await createCallGraphTests())('$testName', async (test) => { // Test is invalid diff --git a/packages/ttsl-lang/tests/language/generation/creator.ts b/packages/ttsl-lang/tests/language/generation/creator.ts index bbb626a5..f324737b 100644 --- a/packages/ttsl-lang/tests/language/generation/creator.ts +++ b/packages/ttsl-lang/tests/language/generation/creator.ts @@ -1,6 +1,6 @@ import { listTestFilesWithExtensions, - listTestSafeDsFilesGroupedByParentDirectory, + listTestTTSLFilesGroupedByParentDirectory, loadDocuments, uriToShortenedTestResourceName, } from '../../helpers/testResources.js'; @@ -12,16 +12,16 @@ import { NodeFileSystem } from 'langium/node'; import { TestDescription, TestDescriptionError } from '../../helpers/testDescription.js'; import { locationToString } from '../../../src/helpers/locations.js'; import { URI } from 'langium'; -import { createSafeDsServices } from '../../../src/language/index.js'; +import { createTTSLServices } from '../../../src/language/index.js'; -const services = (await createSafeDsServices(NodeFileSystem)).SafeDs; +const services = (await createTTSLServices(NodeFileSystem)).TTSL; const langiumDocuments = services.shared.workspace.LangiumDocuments; const rootResourceName = 'generation'; const runnerIntegration = 'runner integration'; export const createGenerationTests = async (): Promise => { - const filesGroupedByParentDirectory = listTestSafeDsFilesGroupedByParentDirectory(rootResourceName); + const filesGroupedByParentDirectory = listTestTTSLFilesGroupedByParentDirectory(rootResourceName); const testCases = filesGroupedByParentDirectory.map((entry) => createGenerationTest(...entry)); return Promise.all(testCases); diff --git a/packages/ttsl-lang/tests/language/generation/safe-ds-python-generator.test.ts b/packages/ttsl-lang/tests/language/generation/safe-ds-python-generator.test.ts index 242c5f32..c5cad105 100644 --- a/packages/ttsl-lang/tests/language/generation/safe-ds-python-generator.test.ts +++ b/packages/ttsl-lang/tests/language/generation/safe-ds-python-generator.test.ts @@ -3,9 +3,9 @@ import { NodeFileSystem } from 'langium/node'; import { createGenerationTests } from './creator.js'; import { loadDocuments } from '../../helpers/testResources.js'; import { stream, URI } from 'langium'; -import { createSafeDsServices } from '../../../src/language/index.js'; +import { createTTSLServices } from '../../../src/language/index.js'; -const services = (await createSafeDsServices(NodeFileSystem)).SafeDs; +const services = (await createTTSLServices(NodeFileSystem)).TTSL; const langiumDocuments = services.shared.workspace.LangiumDocuments; const pythonGenerator = services.generation.PythonGenerator; diff --git a/packages/ttsl-lang/tests/language/grammar/creator.ts b/packages/ttsl-lang/tests/language/grammar/creator.ts index 15ec0a1f..532b4008 100644 --- a/packages/ttsl-lang/tests/language/grammar/creator.ts +++ b/packages/ttsl-lang/tests/language/grammar/creator.ts @@ -1,4 +1,4 @@ -import { listTestSafeDsFiles, uriToShortenedTestResourceName } from '../../helpers/testResources.js'; +import { listTestTTSLFiles, uriToShortenedTestResourceName } from '../../helpers/testResources.js'; import fs from 'fs'; import { findTestComments } from '../../helpers/testComments.js'; import { NoCommentsError } from '../../helpers/testChecks.js'; @@ -8,7 +8,7 @@ import { URI } from 'langium'; const rootResourceName = 'grammar'; export const createGrammarTests = (): GrammarTest[] => { - return listTestSafeDsFiles(rootResourceName).map(createGrammarTest); + return listTestTTSLFiles(rootResourceName).map(createGrammarTest); }; const createGrammarTest = (uri: URI): GrammarTest => { diff --git a/packages/ttsl-lang/tests/language/grammar/safe-ds-grammar.test.ts b/packages/ttsl-lang/tests/language/grammar/safe-ds-grammar.test.ts index 56d75603..21d9f964 100644 --- a/packages/ttsl-lang/tests/language/grammar/safe-ds-grammar.test.ts +++ b/packages/ttsl-lang/tests/language/grammar/safe-ds-grammar.test.ts @@ -1,11 +1,11 @@ import { describe, it } from 'vitest'; -import { createSafeDsServices } from '../../../src/language/index.js'; +import { createTTSLServices } from '../../../src/language/index.js'; import { AssertionError } from 'assert'; import { NodeFileSystem } from 'langium/node'; import { createGrammarTests } from './creator.js'; import { getSyntaxErrors } from '../../helpers/diagnostics.js'; -const services = (await createSafeDsServices(NodeFileSystem)).SafeDs; +const services = (await createTTSLServices(NodeFileSystem)).TTSL; describe('grammar', () => { it.each(createGrammarTests())('$testName', async (test) => { diff --git a/packages/ttsl-lang/tests/language/grammar/safe-ds-value-converter.test.ts b/packages/ttsl-lang/tests/language/grammar/safe-ds-value-converter.test.ts index d2320837..54712141 100644 --- a/packages/ttsl-lang/tests/language/grammar/safe-ds-value-converter.test.ts +++ b/packages/ttsl-lang/tests/language/grammar/safe-ds-value-converter.test.ts @@ -1,5 +1,5 @@ import { describe, expect, it } from 'vitest'; -import { createSafeDsServices } from '../../../src/language/index.js'; +import { createTTSLServices } from '../../../src/language/index.js'; import { EmptyFileSystem } from 'langium'; import { getNodeOfType } from '../../helpers/nodeFinder.js'; import { @@ -11,9 +11,9 @@ import { isTslTemplateStringInner, isTslTemplateStringStart, } from '../../../src/language/generated/ast.js'; -import { escapeString } from '../../../src/language/grammar/safe-ds-value-converter.js'; +import { escapeString } from '../../../src/language/grammar/ttsl-value-converter.js'; -const services = (await createSafeDsServices(EmptyFileSystem, { omitBuiltins: true })).SafeDs; +const services = (await createTTSLServices(EmptyFileSystem, { omitBuiltins: true })).TTSL; describe('runConverter', () => { describe('ID', () => { diff --git a/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/argumentToParameter.test.ts b/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/argumentToParameter.test.ts index 9d618c1f..95c37b1b 100644 --- a/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/argumentToParameter.test.ts +++ b/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/argumentToParameter.test.ts @@ -1,13 +1,13 @@ import { EmptyFileSystem } from 'langium'; import { describe, expect, it } from 'vitest'; import { isTslAbstractCall, TslArgument } from '../../../../src/language/generated/ast.js'; -import { createSafeDsServices, getArguments } from '../../../../src/language/index.js'; +import { createTTSLServices, getArguments } from '../../../../src/language/index.js'; import { getNodeOfType } from '../../../helpers/nodeFinder.js'; -const services = (await createSafeDsServices(EmptyFileSystem, { omitBuiltins: true })).SafeDs; +const services = (await createTTSLServices(EmptyFileSystem, { omitBuiltins: true })).TTSL; const nodeMapper = services.helpers.NodeMapper; -describe('SafeDsNodeMapper', () => { +describe('TTSLNodeMapper', () => { describe('argumentToParameter', () => { it('should return undefined if passed undefined', () => { expect(nodeMapper.argumentToParameter(undefined)?.$type).toBeUndefined(); diff --git a/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/assigneeToAssignedObject.test.ts b/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/assigneeToAssignedObject.test.ts index 4ab034a6..e4afdbea 100644 --- a/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/assigneeToAssignedObject.test.ts +++ b/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/assigneeToAssignedObject.test.ts @@ -8,12 +8,12 @@ import { } from '../../../../src/language/generated/ast.js'; import { getAssignees } from '../../../../src/language/helpers/nodeProperties.js'; import { getNodeOfType } from '../../../helpers/nodeFinder.js'; -import { createSafeDsServices } from '../../../../src/language/index.js'; +import { createTTSLServices } from '../../../../src/language/index.js'; -const services = (await createSafeDsServices(NodeFileSystem)).SafeDs; +const services = (await createTTSLServices(NodeFileSystem)).TTSL; const nodeMapper = services.helpers.NodeMapper; -describe('SafeDsNodeMapper', () => { +describe('TTSLNodeMapper', () => { describe('assigneeToAssignedObject', () => { it('should return undefined if passed undefined', async () => { expect(nodeMapper.assigneeToAssignedObject(undefined)?.$type).toBeUndefined(); diff --git a/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/callToCallable.test.ts b/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/callToCallable.test.ts index 9b532f0b..8afa4648 100644 --- a/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/callToCallable.test.ts +++ b/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/callToCallable.test.ts @@ -2,12 +2,12 @@ import { describe, expect, it } from 'vitest'; import { isTslAbstractCall } from '../../../../src/language/generated/ast.js'; import { getNodeOfType } from '../../../helpers/nodeFinder.js'; import { NodeFileSystem } from 'langium/node'; -import { createSafeDsServices } from '../../../../src/language/index.js'; +import { createTTSLServices } from '../../../../src/language/index.js'; -const services = (await createSafeDsServices(NodeFileSystem)).SafeDs; +const services = (await createTTSLServices(NodeFileSystem)).TTSL; const nodeMapper = services.helpers.NodeMapper; -describe('SafeDsNodeMapper', () => { +describe('TTSLNodeMapper', () => { describe('callToCallable', () => { it('should return undefined if passed undefined', () => { expect(nodeMapper.callToCallable(undefined)).toBeUndefined(); diff --git a/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/callToParameterValue.test.ts b/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/callToParameterValue.test.ts index 9667343b..2a97b592 100644 --- a/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/callToParameterValue.test.ts +++ b/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/callToParameterValue.test.ts @@ -7,11 +7,11 @@ import { TslParameter, TslPipeline, } from '../../../../src/language/generated/ast.js'; -import { createSafeDsServices, getModuleMembers, getParameters } from '../../../../src/language/index.js'; +import { createTTSLServices, getModuleMembers, getParameters } from '../../../../src/language/index.js'; import { Constant, IntConstant } from '../../../../src/language/partialEvaluation/model.js'; import { getNodeOfType } from '../../../helpers/nodeFinder.js'; -const services = (await createSafeDsServices(EmptyFileSystem, { omitBuiltins: true })).SafeDs; +const services = (await createTTSLServices(EmptyFileSystem, { omitBuiltins: true })).TTSL; const callGraphComputer = services.flow.CallGraphComputer; const nodeMapper = services.helpers.NodeMapper; const partialEvaluator = services.evaluation.PartialEvaluator; @@ -34,7 +34,7 @@ const call1 = callGraphComputer.getAllContainedCalls(myPipeline)[0]!; const call2 = callGraphComputer.getAllContainedCalls(myPipeline)[1]!; const call3 = callGraphComputer.getAllContainedCalls(myPipeline)[2]!; -describe('SafeDsNodeMapper', () => { +describe('TTSLNodeMapper', () => { const testCases: CallToParameterValueTest[] = [ { testName: 'undefined call, undefined parameter', @@ -143,7 +143,7 @@ describe('SafeDsNodeMapper', () => { }); /** - * A test case for {@link SafeDsNodeMapper.callToParameterValue}. + * A test case for {@link TTSLNodeMapper.callToParameterValue}. */ interface CallToParameterValueTest { /** diff --git a/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/parameterToReferences.test.ts b/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/parameterToReferences.test.ts index 87eda9b5..1c7c0b8f 100644 --- a/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/parameterToReferences.test.ts +++ b/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/parameterToReferences.test.ts @@ -1,13 +1,13 @@ import { EmptyFileSystem } from 'langium'; import { describe, expect, it } from 'vitest'; import { isTslParameter } from '../../../../src/language/generated/ast.js'; -import { createSafeDsServices } from '../../../../src/language/index.js'; +import { createTTSLServices } from '../../../../src/language/index.js'; import { getNodeOfType } from '../../../helpers/nodeFinder.js'; -const services = (await createSafeDsServices(EmptyFileSystem, { omitBuiltins: true })).SafeDs; +const services = (await createTTSLServices(EmptyFileSystem, { omitBuiltins: true })).TTSL; const nodeMapper = services.helpers.NodeMapper; -describe('SafeDsNodeMapper', () => { +describe('TTSLNodeMapper', () => { describe('parameterToReferences', () => { it('should return an empty list if passed undefined', async () => { expect(nodeMapper.parameterToReferences(undefined).toArray()).toStrictEqual([]); diff --git a/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/parametersToArguments.test.ts b/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/parametersToArguments.test.ts index 60289775..647c83b7 100644 --- a/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/parametersToArguments.test.ts +++ b/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/parametersToArguments.test.ts @@ -7,10 +7,10 @@ import { TslParameter, TslPipeline, } from '../../../../src/language/generated/ast.js'; -import { createSafeDsServices, getArguments, getModuleMembers, getParameters } from '../../../../src/language/index.js'; +import { createTTSLServices, getArguments, getModuleMembers, getParameters } from '../../../../src/language/index.js'; import { getNodeOfType } from '../../../helpers/nodeFinder.js'; -const services = (await createSafeDsServices(EmptyFileSystem, { omitBuiltins: true })).SafeDs; +const services = (await createTTSLServices(EmptyFileSystem, { omitBuiltins: true })).TTSL; const callGraphComputer = services.flow.CallGraphComputer; const nodeMapper = services.helpers.NodeMapper; @@ -31,7 +31,7 @@ const arg2 = getArguments(call1)[1]!; const arg3 = getArguments(call1)[2]!; const arg4 = getArguments(call1)[3]!; -describe('SafeDsNodeMapper', () => { +describe('TTSLNodeMapper', () => { const testCases: ParametersToArgumentsTest[] = [ { testName: 'both lists empty', @@ -86,7 +86,7 @@ describe('SafeDsNodeMapper', () => { }); /** - * A test case for {@link SafeDsNodeMapper.parametersToArguments}. + * A test case for {@link TTSLNodeMapper.parametersToArguments}. */ interface ParametersToArgumentsTest { /** diff --git a/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/placeholdersToReferences.test.ts b/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/placeholdersToReferences.test.ts index d5667e35..79f91cc3 100644 --- a/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/placeholdersToReferences.test.ts +++ b/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/placeholdersToReferences.test.ts @@ -1,13 +1,13 @@ import { EmptyFileSystem } from 'langium'; import { describe, expect, it } from 'vitest'; import { isTslPlaceholder } from '../../../../src/language/generated/ast.js'; -import { createSafeDsServices } from '../../../../src/language/index.js'; +import { createTTSLServices } from '../../../../src/language/index.js'; import { getNodeOfType } from '../../../helpers/nodeFinder.js'; -const services = (await createSafeDsServices(EmptyFileSystem, { omitBuiltins: true })).SafeDs; +const services = (await createTTSLServices(EmptyFileSystem, { omitBuiltins: true })).TTSL; const nodeMapper = services.helpers.NodeMapper; -describe('SafeDsNodeMapper', () => { +describe('TTSLNodeMapper', () => { describe('placeholderToReferences', () => { it('should return an empty list if passed undefined', async () => { expect(nodeMapper.placeholderToReferences(undefined).toArray()).toStrictEqual([]); diff --git a/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/resultToYields.test.ts b/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/resultToYields.test.ts index 6841084d..77a0a597 100644 --- a/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/resultToYields.test.ts +++ b/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/resultToYields.test.ts @@ -1,13 +1,13 @@ import { EmptyFileSystem } from 'langium'; import { describe, expect, it } from 'vitest'; import { isTslResult } from '../../../../src/language/generated/ast.js'; -import { createSafeDsServices } from '../../../../src/language/index.js'; +import { createTTSLServices } from '../../../../src/language/index.js'; import { getNodeOfType } from '../../../helpers/nodeFinder.js'; -const services = (await createSafeDsServices(EmptyFileSystem, { omitBuiltins: true })).SafeDs; +const services = (await createTTSLServices(EmptyFileSystem, { omitBuiltins: true })).TTSL; const nodeMapper = services.helpers.NodeMapper; -describe('SafeDsNodeMapper', () => { +describe('TTSLNodeMapper', () => { describe('resultToYields', () => { it('should return an empty list if passed undefined', async () => { expect(nodeMapper.resultToYields(undefined).toArray()).toStrictEqual([]); diff --git a/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/typeArgumentToTypeParameter.test.ts b/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/typeArgumentToTypeParameter.test.ts index 39929dad..08997737 100644 --- a/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/typeArgumentToTypeParameter.test.ts +++ b/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/typeArgumentToTypeParameter.test.ts @@ -2,13 +2,13 @@ import { EmptyFileSystem } from 'langium'; import { describe, expect, it } from 'vitest'; import { isTslNamedType, isTslUnionType, TslTypeArgument } from '../../../../src/language/generated/ast.js'; import { getTypeArguments } from '../../../../src/language/helpers/nodeProperties.js'; -import { createSafeDsServices } from '../../../../src/language/index.js'; +import { createTTSLServices } from '../../../../src/language/index.js'; import { getNodeOfType } from '../../../helpers/nodeFinder.js'; -const services = (await createSafeDsServices(EmptyFileSystem, { omitBuiltins: true })).SafeDs; +const services = (await createTTSLServices(EmptyFileSystem, { omitBuiltins: true })).TTSL; const nodeMapper = services.helpers.NodeMapper; -describe('SafeDsNodeMapper', () => { +describe('TTSLNodeMapper', () => { describe('typeArgumentToTypeParameter', () => { it('should return undefined if passed undefined', () => { expect(nodeMapper.typeArgumentToTypeParameter(undefined)?.$type).toBeUndefined(); diff --git a/packages/ttsl-lang/tests/language/lsp/formatting/creator.ts b/packages/ttsl-lang/tests/language/lsp/formatting/creator.ts index 09c67852..71cdf41d 100644 --- a/packages/ttsl-lang/tests/language/lsp/formatting/creator.ts +++ b/packages/ttsl-lang/tests/language/lsp/formatting/creator.ts @@ -2,17 +2,17 @@ import fs from 'fs'; import { EmptyFileSystem, URI } from 'langium'; import { Diagnostic } from 'vscode-languageserver'; import { normalizeLineBreaks } from '../../../../src/helpers/strings.js'; -import { createSafeDsServices } from '../../../../src/language/index.js'; +import { createTTSLServices } from '../../../../src/language/index.js'; import { getSyntaxErrors } from '../../../helpers/diagnostics.js'; import { TestDescription, TestDescriptionError } from '../../../helpers/testDescription.js'; -import { listTestSafeDsFiles, uriToShortenedTestResourceName } from '../../../helpers/testResources.js'; +import { listTestTTSLFiles, uriToShortenedTestResourceName } from '../../../helpers/testResources.js'; -const services = (await createSafeDsServices(EmptyFileSystem, { omitBuiltins: true })).SafeDs; +const services = (await createTTSLServices(EmptyFileSystem, { omitBuiltins: true })).TTSL; const rootResourceName = 'formatting'; const separator = '// -----------------------------------------------------------------------------'; export const createFormattingTests = async (): Promise => { - const testCases = listTestSafeDsFiles(rootResourceName).map(createFormattingTest); + const testCases = listTestTTSLFiles(rootResourceName).map(createFormattingTest); return Promise.all(testCases); }; diff --git a/packages/ttsl-lang/tests/language/lsp/formatting/safe-ds-formatter.test.ts b/packages/ttsl-lang/tests/language/lsp/formatting/safe-ds-formatter.test.ts index b2821f6c..53eb0ab8 100644 --- a/packages/ttsl-lang/tests/language/lsp/formatting/safe-ds-formatter.test.ts +++ b/packages/ttsl-lang/tests/language/lsp/formatting/safe-ds-formatter.test.ts @@ -1,10 +1,10 @@ -import { createSafeDsServices } from '../../../../src/language/index.js'; +import { createTTSLServices } from '../../../../src/language/index.js'; import { clearDocuments, expectFormatting } from 'langium/test'; import { afterEach, describe, it } from 'vitest'; import { EmptyFileSystem } from 'langium'; import { createFormattingTests } from './creator.js'; -const services = (await createSafeDsServices(EmptyFileSystem, { omitBuiltins: true })).SafeDs; +const services = (await createTTSLServices(EmptyFileSystem, { omitBuiltins: true })).TTSL; const formatterTests = createFormattingTests(); describe('formatter', async () => { diff --git a/packages/ttsl-lang/tests/language/lsp/safe-ds-call-hierarchy-provider.test.ts b/packages/ttsl-lang/tests/language/lsp/safe-ds-call-hierarchy-provider.test.ts index cc984157..7220c05b 100644 --- a/packages/ttsl-lang/tests/language/lsp/safe-ds-call-hierarchy-provider.test.ts +++ b/packages/ttsl-lang/tests/language/lsp/safe-ds-call-hierarchy-provider.test.ts @@ -3,13 +3,13 @@ import { parseHelper } from 'langium/test'; import { describe, expect, it } from 'vitest'; import { type CallHierarchyItem } from 'vscode-languageserver'; import { findTestRanges } from '../../helpers/testRanges.js'; -import { createSafeDsServices } from '../../../src/language/index.js'; +import { createTTSLServices } from '../../../src/language/index.js'; -const services = (await createSafeDsServices(NodeFileSystem)).SafeDs; +const services = (await createTTSLServices(NodeFileSystem)).TTSL; const callHierarchyProvider = services.lsp.CallHierarchyProvider!; const parse = parseHelper(services); -describe('SafeDsCallHierarchyProvider', async () => { +describe('TTSLCallHierarchyProvider', async () => { describe('incomingCalls', () => { const testCases: IncomingCallTest[] = [ { @@ -277,7 +277,7 @@ const getUniqueCallHierarchyItem = async (code: string): Promise { +describe('TTSLSemanticTokenProvider', async () => { const testCases: DocumentSymbolProviderTest[] = [ { testName: 'annotation declaration', diff --git a/packages/ttsl-lang/tests/language/lsp/safe-ds-inlay-hint-provider.test.ts b/packages/ttsl-lang/tests/language/lsp/safe-ds-inlay-hint-provider.test.ts index 79999d3f..bcf740ef 100644 --- a/packages/ttsl-lang/tests/language/lsp/safe-ds-inlay-hint-provider.test.ts +++ b/packages/ttsl-lang/tests/language/lsp/safe-ds-inlay-hint-provider.test.ts @@ -4,13 +4,13 @@ import { InlayHint, Position } from 'vscode-languageserver'; import { NodeFileSystem } from 'langium/node'; import { findTestChecks } from '../../helpers/testChecks.js'; import { URI } from 'langium'; -import { createSafeDsServices } from '../../../src/language/index.js'; +import { createTTSLServices } from '../../../src/language/index.js'; -const services = (await createSafeDsServices(NodeFileSystem)).SafeDs; +const services = (await createTTSLServices(NodeFileSystem)).TTSL; const inlayHintProvider = services.lsp.InlayHintProvider!; const parse = parseHelper(services); -describe('SafeDsInlayHintProvider', async () => { +describe('TTSLInlayHintProvider', async () => { const testCases: InlayHintProviderTest[] = [ { testName: 'resolved positional argument', diff --git a/packages/ttsl-lang/tests/language/lsp/safe-ds-rename-provider.test.ts b/packages/ttsl-lang/tests/language/lsp/safe-ds-rename-provider.test.ts index 749bd345..df6d2409 100644 --- a/packages/ttsl-lang/tests/language/lsp/safe-ds-rename-provider.test.ts +++ b/packages/ttsl-lang/tests/language/lsp/safe-ds-rename-provider.test.ts @@ -1,12 +1,12 @@ import { NodeFileSystem } from 'langium/node'; import { afterEach, describe, expect, it } from 'vitest'; -import { createSafeDsServices, getModuleMembers } from '../../../src/language/index.js'; +import { createTTSLServices, getModuleMembers } from '../../../src/language/index.js'; import { clearDocuments } from 'langium/test'; import { TslModule } from '../../../src/language/generated/ast.js'; import { URI } from 'langium'; import { TextDocument } from 'vscode-languageserver-textdocument'; -const services = (await createSafeDsServices(NodeFileSystem)).SafeDs; +const services = (await createTTSLServices(NodeFileSystem)).TTSL; const documentBuilder = services.shared.workspace.DocumentBuilder; const langiumDocuments = services.shared.workspace.LangiumDocuments; const langiumDocumentFactory = services.shared.workspace.LangiumDocumentFactory; @@ -16,7 +16,7 @@ const renameProvider = services.lsp.RenameProvider!; const resourceUri = 'file:///resource.Tslstub'; const mainUri = 'file:///main.Tslpipe'; -describe('SafeDsRenameProvider', async () => { +describe('TTSLRenameProvider', async () => { const testCases: RenameProviderTest[] = [ { testName: 'local reference', diff --git a/packages/ttsl-lang/tests/language/lsp/safe-ds-semantic-token-provider.test.ts b/packages/ttsl-lang/tests/language/lsp/safe-ds-semantic-token-provider.test.ts index a6314b60..425dbeb6 100644 --- a/packages/ttsl-lang/tests/language/lsp/safe-ds-semantic-token-provider.test.ts +++ b/packages/ttsl-lang/tests/language/lsp/safe-ds-semantic-token-provider.test.ts @@ -3,11 +3,11 @@ import { NodeFileSystem } from 'langium/node'; import { highlightHelper } from 'langium/test'; import { describe, it } from 'vitest'; import { SemanticTokenTypes } from 'vscode-languageserver'; -import { createSafeDsServices } from '../../../src/language/index.js'; +import { createTTSLServices } from '../../../src/language/index.js'; -const services = (await createSafeDsServices(NodeFileSystem)).SafeDs; +const services = (await createTTSLServices(NodeFileSystem)).TTSL; -describe('SafeDsSemanticTokenProvider', async () => { +describe('TTSLSemanticTokenProvider', async () => { it.each([ { testName: 'annotation call', @@ -118,7 +118,7 @@ describe('SafeDsSemanticTokenProvider', async () => { }, { testName: 'imported declaration', - code: 'from safeds.lang import <|Any|>', + code: 'from TTSL.lang import <|Any|>', expectedTokenTypes: [SemanticTokenTypes.class], }, { diff --git a/packages/ttsl-lang/tests/language/lsp/safe-ds-signature-help-provider.test.ts b/packages/ttsl-lang/tests/language/lsp/safe-ds-signature-help-provider.test.ts index 84fc2790..a38b5465 100644 --- a/packages/ttsl-lang/tests/language/lsp/safe-ds-signature-help-provider.test.ts +++ b/packages/ttsl-lang/tests/language/lsp/safe-ds-signature-help-provider.test.ts @@ -3,13 +3,13 @@ import { parseHelper } from 'langium/test'; import { SignatureHelp } from 'vscode-languageserver'; import { NodeFileSystem } from 'langium/node'; import { findTestRanges } from '../../helpers/testRanges.js'; -import { createSafeDsServices } from '../../../src/language/index.js'; +import { createTTSLServices } from '../../../src/language/index.js'; -const services = (await createSafeDsServices(NodeFileSystem)).SafeDs; +const services = (await createTTSLServices(NodeFileSystem)).TTSL; const signatureHelpProvider = services.lsp.SignatureHelp!; const parse = parseHelper(services); -describe('SafeDsSignatureHelpProvider', async () => { +describe('TTSLSignatureHelpProvider', async () => { it('should always select the first signature', async () => { const code = ` fun f(p: Int) @@ -176,7 +176,7 @@ describe('SafeDsSignatureHelpProvider', async () => { }, ], }, - // https://github.com/Safe-DS/DSL/issues/791 + // https://github.com/TTSL/DSL/issues/791 { testName: 'optional parameter', code: ` diff --git a/packages/ttsl-lang/tests/language/lsp/safe-ds-type-hierarchy-provider.test.ts b/packages/ttsl-lang/tests/language/lsp/safe-ds-type-hierarchy-provider.test.ts index 372fa035..30cd7fa3 100644 --- a/packages/ttsl-lang/tests/language/lsp/safe-ds-type-hierarchy-provider.test.ts +++ b/packages/ttsl-lang/tests/language/lsp/safe-ds-type-hierarchy-provider.test.ts @@ -3,13 +3,13 @@ import { parseHelper } from 'langium/test'; import { describe, expect, it } from 'vitest'; import { type TypeHierarchyItem } from 'vscode-languageserver'; import { findTestRanges } from '../../helpers/testRanges.js'; -import { createSafeDsServices } from '../../../src/language/index.js'; +import { createTTSLServices } from '../../../src/language/index.js'; -const services = (await createSafeDsServices(NodeFileSystem)).SafeDs; +const services = (await createTTSLServices(NodeFileSystem)).TTSL; const typeHierarchyProvider = services.lsp.TypeHierarchyProvider!; const parse = parseHelper(services); -describe('SafeDsTypeHierarchyProvider', async () => { +describe('TTSLTypeHierarchyProvider', async () => { describe('supertypes', () => { const testCases: TypeHierarchyProviderTest[] = [ { @@ -179,7 +179,7 @@ const getUniqueTypeHierarchyItem = async (code: string): Promise { +describe('TTSLTypeChecker', async () => { const testCases: CanBeValueOfConstantParameterTest[] = [ { code: 'true', @@ -168,7 +168,7 @@ describe('SafeDsTypeChecker', async () => { }); /** - * A test case for {@link SafeDsPartialEvaluator.canBeValueOfConstantParameter}. + * A test case for {@link TTSLPartialEvaluator.canBeValueOfConstantParameter}. */ interface CanBeValueOfConstantParameterTest { /** diff --git a/packages/ttsl-lang/tests/language/partialEvaluation/creator.ts b/packages/ttsl-lang/tests/language/partialEvaluation/creator.ts index 1a65ed26..2bf59522 100644 --- a/packages/ttsl-lang/tests/language/partialEvaluation/creator.ts +++ b/packages/ttsl-lang/tests/language/partialEvaluation/creator.ts @@ -1,20 +1,20 @@ import fs from 'fs'; import { EmptyFileSystem, URI } from 'langium'; import { Location } from 'vscode-languageserver'; -import { createSafeDsServices } from '../../../src/language/index.js'; +import { createTTSLServices } from '../../../src/language/index.js'; import { getSyntaxErrors, SyntaxErrorsInCodeError } from '../../helpers/diagnostics.js'; import { findTestChecks } from '../../helpers/testChecks.js'; import { TestDescription, TestDescriptionError } from '../../helpers/testDescription.js'; import { - listTestSafeDsFilesGroupedByParentDirectory, + listTestTTSLFilesGroupedByParentDirectory, uriToShortenedTestResourceName, } from '../../helpers/testResources.js'; -const services = (await createSafeDsServices(EmptyFileSystem, { omitBuiltins: true })).SafeDs; +const services = (await createTTSLServices(EmptyFileSystem, { omitBuiltins: true })).TTSL; const rootResourceName = 'partial evaluation'; export const createPartialEvaluationTests = (): Promise => { - const filesGroupedByParentDirectory = listTestSafeDsFilesGroupedByParentDirectory(rootResourceName); + const filesGroupedByParentDirectory = listTestTTSLFilesGroupedByParentDirectory(rootResourceName); const testCases = filesGroupedByParentDirectory.map((entry) => createPartialEvaluationTest(...entry)); return Promise.all(testCases); diff --git a/packages/ttsl-lang/tests/language/partialEvaluation/model.test.ts b/packages/ttsl-lang/tests/language/partialEvaluation/model.test.ts index 9ed42385..7c5c81dd 100644 --- a/packages/ttsl-lang/tests/language/partialEvaluation/model.test.ts +++ b/packages/ttsl-lang/tests/language/partialEvaluation/model.test.ts @@ -8,7 +8,7 @@ import { isTslSegment, type TslBlockLambdaResult, } from '../../../src/language/generated/ast.js'; -import { createSafeDsServices, getAbstractResults, getParameters } from '../../../src/language/index.js'; +import { createTTSLServices, getAbstractResults, getParameters } from '../../../src/language/index.js'; import { BlockLambdaClosure, BooleanConstant, @@ -30,7 +30,7 @@ import { import { getNodeOfType } from '../../helpers/nodeFinder.js'; import type { EqualsTest, ToStringTest } from '../../helpers/testDescription.js'; -const services = (await createSafeDsServices(EmptyFileSystem, { omitBuiltins: true })).SafeDs; +const services = (await createTTSLServices(EmptyFileSystem, { omitBuiltins: true })).TTSL; const code = ` enum MyEnum { MyEnumVariant1 diff --git a/packages/ttsl-lang/tests/language/partialEvaluation/safe-ds-partial-evalutator.test.ts b/packages/ttsl-lang/tests/language/partialEvaluation/safe-ds-partial-evalutator.test.ts index 27a6d3d4..c8a70afc 100644 --- a/packages/ttsl-lang/tests/language/partialEvaluation/safe-ds-partial-evalutator.test.ts +++ b/packages/ttsl-lang/tests/language/partialEvaluation/safe-ds-partial-evalutator.test.ts @@ -5,9 +5,9 @@ import { locationToString } from '../../../src/helpers/locations.js'; import { getNodeByLocation } from '../../helpers/nodeFinder.js'; import { loadDocuments } from '../../helpers/testResources.js'; import { createPartialEvaluationTests } from './creator.js'; -import { createSafeDsServices } from '../../../src/language/index.js'; +import { createTTSLServices } from '../../../src/language/index.js'; -const services = (await createSafeDsServices(NodeFileSystem)).SafeDs; +const services = (await createTTSLServices(NodeFileSystem)).TTSL; const partialEvaluator = services.evaluation.PartialEvaluator; describe('partial evaluation', async () => { diff --git a/packages/ttsl-lang/tests/language/purity/model.test.ts b/packages/ttsl-lang/tests/language/purity/model.test.ts index 5bb9a4d5..a8d6a7eb 100644 --- a/packages/ttsl-lang/tests/language/purity/model.test.ts +++ b/packages/ttsl-lang/tests/language/purity/model.test.ts @@ -12,9 +12,9 @@ import { } from '../../../src/language/purity/model.js'; import { getNodeOfType } from '../../helpers/nodeFinder.js'; import { type EqualsTest, ToStringTest } from '../../helpers/testDescription.js'; -import { createSafeDsServices } from '../../../src/language/index.js'; +import { createTTSLServices } from '../../../src/language/index.js'; -const services = (await createSafeDsServices(NodeFileSystem)).SafeDs; +const services = (await createTTSLServices(NodeFileSystem)).TTSL; const parameter = await getNodeOfType(services, 'fun f(p: Int)', isTslParameter); describe('purity model', async () => { diff --git a/packages/ttsl-lang/tests/language/purity/safe-ds-purity-computer.test.ts b/packages/ttsl-lang/tests/language/purity/safe-ds-purity-computer.test.ts index 4915df26..7667c059 100644 --- a/packages/ttsl-lang/tests/language/purity/safe-ds-purity-computer.test.ts +++ b/packages/ttsl-lang/tests/language/purity/safe-ds-purity-computer.test.ts @@ -2,12 +2,12 @@ import { describe, expect, it } from 'vitest'; import { NodeFileSystem } from 'langium/node'; import { isTslCall, isTslCallable, isTslExpression, isTslParameter } from '../../../src/language/generated/ast.js'; import { getNodeOfType } from '../../helpers/nodeFinder.js'; -import { createSafeDsServices } from '../../../src/language/index.js'; +import { createTTSLServices } from '../../../src/language/index.js'; -const services = (await createSafeDsServices(NodeFileSystem)).SafeDs; +const services = (await createTTSLServices(NodeFileSystem)).TTSL; const purityComputer = services.purity.PurityComputer; -describe('SafeDsPurityComputer', async () => { +describe('TTSLPurityComputer', async () => { describe('isPureCallable', () => { it.each([ { diff --git a/packages/ttsl-lang/tests/language/scoping/creator.ts b/packages/ttsl-lang/tests/language/scoping/creator.ts index 8219f6f1..14d446ef 100644 --- a/packages/ttsl-lang/tests/language/scoping/creator.ts +++ b/packages/ttsl-lang/tests/language/scoping/creator.ts @@ -1,20 +1,20 @@ import fs from 'fs'; import { EmptyFileSystem, URI } from 'langium'; import { Location } from 'vscode-languageserver'; -import { createSafeDsServices } from '../../../src/language/index.js'; +import { createTTSLServices } from '../../../src/language/index.js'; import { getSyntaxErrors, SyntaxErrorsInCodeError } from '../../helpers/diagnostics.js'; import { findTestChecks } from '../../helpers/testChecks.js'; import { TestDescription, TestDescriptionError } from '../../helpers/testDescription.js'; import { - listTestSafeDsFilesGroupedByParentDirectory, + listTestTTSLFilesGroupedByParentDirectory, uriToShortenedTestResourceName, } from '../../helpers/testResources.js'; -const services = (await createSafeDsServices(EmptyFileSystem, { omitBuiltins: true })).SafeDs; +const services = (await createTTSLServices(EmptyFileSystem, { omitBuiltins: true })).TTSL; const rootResourceName = 'scoping'; export const createScopingTests = (): Promise => { - const filesGroupedByParentDirectory = listTestSafeDsFilesGroupedByParentDirectory(rootResourceName); + const filesGroupedByParentDirectory = listTestTTSLFilesGroupedByParentDirectory(rootResourceName); const testCases = filesGroupedByParentDirectory.map((entry) => createScopingTest(...entry)); return Promise.all(testCases); diff --git a/packages/ttsl-lang/tests/language/scoping/scoping.test.ts b/packages/ttsl-lang/tests/language/scoping/scoping.test.ts index 3b945e75..3d968a6e 100644 --- a/packages/ttsl-lang/tests/language/scoping/scoping.test.ts +++ b/packages/ttsl-lang/tests/language/scoping/scoping.test.ts @@ -4,14 +4,14 @@ import { NodeFileSystem } from 'langium/node'; import { clearDocuments, isRangeEqual, validationHelper } from 'langium/test'; import { afterEach, beforeEach, describe, expect, it } from 'vitest'; import { Location } from 'vscode-languageserver'; -import { createSafeDsServices } from '../../../src/language/index.js'; +import { createTTSLServices } from '../../../src/language/index.js'; import { isLocationEqual, locationToString } from '../../../src/helpers/locations.js'; import { loadDocuments } from '../../helpers/testResources.js'; import { createScopingTests, ExpectedReference } from './creator.js'; import { getNodeOfType } from '../../helpers/nodeFinder.js'; import { isTslAnnotationCall, isTslNamedType, isTslReference } from '../../../src/language/generated/ast.js'; -const services = (await createSafeDsServices(NodeFileSystem)).SafeDs; +const services = (await createTTSLServices(NodeFileSystem)).TTSL; const builtinAnnotations = services.builtins.Annotations; const builtinEnums = services.builtins.Enums; const builtinClasses = services.builtins.Classes; diff --git a/packages/ttsl-lang/tests/language/typing/model.test.ts b/packages/ttsl-lang/tests/language/typing/model.test.ts index e409ce05..d9832ae1 100644 --- a/packages/ttsl-lang/tests/language/typing/model.test.ts +++ b/packages/ttsl-lang/tests/language/typing/model.test.ts @@ -1,7 +1,7 @@ import { NodeFileSystem } from 'langium/node'; import { describe, expect, it } from 'vitest'; import { isTslClass, isTslEnum, isTslEnumVariant, isTslFunction } from '../../../src/language/generated/ast.js'; -import { createSafeDsServices, getParameters, getResults, getTypeParameters } from '../../../src/language/index.js'; +import { createTTSLServices, getParameters, getResults, getTypeParameters } from '../../../src/language/index.js'; import { BooleanConstant, IntConstant, NullConstant } from '../../../src/language/partialEvaluation/model.js'; import { ClassType, @@ -17,7 +17,7 @@ import { getNodeOfType } from '../../helpers/nodeFinder.js'; import type { EqualsTest, ToStringTest } from '../../helpers/testDescription.js'; import { expectEqualTypes } from '../../helpers/testAssertions.js'; -const services = (await createSafeDsServices(NodeFileSystem)).SafeDs; +const services = (await createTTSLServices(NodeFileSystem)).TTSL; const coreTypes = services.types.CoreTypes; const factory = services.types.TypeFactory; diff --git a/packages/ttsl-lang/tests/language/typing/safe-ds-class-hierarchy.test.ts b/packages/ttsl-lang/tests/language/typing/safe-ds-class-hierarchy.test.ts index 43782d01..2491cc42 100644 --- a/packages/ttsl-lang/tests/language/typing/safe-ds-class-hierarchy.test.ts +++ b/packages/ttsl-lang/tests/language/typing/safe-ds-class-hierarchy.test.ts @@ -7,14 +7,14 @@ import { TslClass, type TslClassMember, } from '../../../src/language/generated/ast.js'; -import { createSafeDsServices, getClassMembers } from '../../../src/language/index.js'; +import { createTTSLServices, getClassMembers } from '../../../src/language/index.js'; import { getNodeOfType } from '../../helpers/nodeFinder.js'; -const services = (await createSafeDsServices(NodeFileSystem)).SafeDs; +const services = (await createTTSLServices(NodeFileSystem)).TTSL; const builtinClasses = services.builtins.Classes; const classHierarchy = services.types.ClassHierarchy; -describe('SafeDsClassHierarchy', async () => { +describe('TTSLClassHierarchy', async () => { describe('isEqualToOrSubclassOf', () => { const testCases = [ { diff --git a/packages/ttsl-lang/tests/language/typing/type checker/canBeTypeOfConstantParameter.test.ts b/packages/ttsl-lang/tests/language/typing/type checker/canBeTypeOfConstantParameter.test.ts index f6bd4d3c..61db44c0 100644 --- a/packages/ttsl-lang/tests/language/typing/type checker/canBeTypeOfConstantParameter.test.ts +++ b/packages/ttsl-lang/tests/language/typing/type checker/canBeTypeOfConstantParameter.test.ts @@ -1,11 +1,11 @@ import { NodeFileSystem } from 'langium/node'; import { describe, expect, it } from 'vitest'; import { isTslClass, isTslEnum, isTslModule } from '../../../../src/language/generated/ast.js'; -import { createSafeDsServices, getEnumVariants, getModuleMembers } from '../../../../src/language/index.js'; +import { createTTSLServices, getEnumVariants, getModuleMembers } from '../../../../src/language/index.js'; import { ClassType, EnumType, EnumVariantType, Type, UnknownType } from '../../../../src/language/typing/model.js'; import { getNodeOfType } from '../../../helpers/nodeFinder.js'; -const services = (await createSafeDsServices(NodeFileSystem)).SafeDs; +const services = (await createTTSLServices(NodeFileSystem)).TTSL; const coreTypes = services.types.CoreTypes; const factory = services.types.TypeFactory; const typeChecker = services.types.TypeChecker; @@ -37,7 +37,7 @@ const normalEnumType = typeComputer.computeType(normalEnum) as EnumType; const constantEnumVariantType = typeComputer.computeType(getEnumVariants(constantEnum)[1]) as EnumVariantType; const normalEnumVariantType = typeComputer.computeType(getEnumVariants(normalEnum)[1]) as EnumVariantType; -describe('SafeDsTypeChecker', async () => { +describe('TTSLTypeChecker', async () => { const testCases: CanBeTypeOfConstantParameterTest[] = [ { type: coreTypes.Any, @@ -113,7 +113,7 @@ describe('SafeDsTypeChecker', async () => { }); /** - * A test case for {@link SafeDsTypeChecker.canBeTypeOfConstantParameter}. + * A test case for {@link TTSLTypeChecker.canBeTypeOfConstantParameter}. */ interface CanBeTypeOfConstantParameterTest { /** diff --git a/packages/ttsl-lang/tests/language/typing/type checker/isSubOrSupertypeOf.test.ts b/packages/ttsl-lang/tests/language/typing/type checker/isSubOrSupertypeOf.test.ts index 340c93b3..0bb6a12c 100644 --- a/packages/ttsl-lang/tests/language/typing/type checker/isSubOrSupertypeOf.test.ts +++ b/packages/ttsl-lang/tests/language/typing/type checker/isSubOrSupertypeOf.test.ts @@ -10,7 +10,7 @@ import { TslDeclaration, } from '../../../../src/language/generated/ast.js'; import { - createSafeDsServices, + createTTSLServices, getClassMembers, getModuleMembers, getTypeParameters, @@ -34,7 +34,7 @@ import { import { getNodeOfType } from '../../../helpers/nodeFinder.js'; import { AstUtils } from 'langium'; -const services = (await createSafeDsServices(NodeFileSystem)).SafeDs; +const services = (await createTTSLServices(NodeFileSystem)).TTSL; const coreTypes = services.types.CoreTypes; const factory = services.types.TypeFactory; const typeChecker = services.types.TypeChecker; @@ -1212,7 +1212,7 @@ const typeParameterTypes = async (): Promise => { ]; }; -describe('SafeDsTypeChecker', async () => { +describe('TTSLTypeChecker', async () => { const testCases = (await Promise.all([basic(), classTypesWithTypeParameters(), typeParameterTypes()])).flat(); describe.each(testCases)('isSubtypeOf', ({ type1, type2, expected }) => { @@ -1236,7 +1236,7 @@ const computeTypeOfDeclarationWithName = (declarations }; /** - * A test case for {@link SafeDsTypeChecker.isSubtypeOf}. + * A test case for {@link TTSLTypeChecker.isSubtypeOf}. */ interface IsSubOrSupertypeOfTest { /** diff --git a/packages/ttsl-lang/tests/language/typing/type computer/computeClassTypeForLiteralType.test.ts b/packages/ttsl-lang/tests/language/typing/type computer/computeClassTypeForLiteralType.test.ts index eedecb29..d6cbe36d 100644 --- a/packages/ttsl-lang/tests/language/typing/type computer/computeClassTypeForLiteralType.test.ts +++ b/packages/ttsl-lang/tests/language/typing/type computer/computeClassTypeForLiteralType.test.ts @@ -9,9 +9,9 @@ import { } from '../../../../src/language/partialEvaluation/model.js'; import { LiteralType, Type } from '../../../../src/language/typing/model.js'; import { expectEqualTypes } from '../../../helpers/testAssertions.js'; -import { createSafeDsServices } from '../../../../src/language/index.js'; +import { createTTSLServices } from '../../../../src/language/index.js'; -const services = (await createSafeDsServices(NodeFileSystem)).SafeDs; +const services = (await createTTSLServices(NodeFileSystem)).TTSL; const coreTypes = services.types.CoreTypes; const factory = services.types.TypeFactory; const typeComputer = services.types.TypeComputer; diff --git a/packages/ttsl-lang/tests/language/typing/type computer/computeUpperBound.test.ts b/packages/ttsl-lang/tests/language/typing/type computer/computeUpperBound.test.ts index d4cd8235..b0204492 100644 --- a/packages/ttsl-lang/tests/language/typing/type computer/computeUpperBound.test.ts +++ b/packages/ttsl-lang/tests/language/typing/type computer/computeUpperBound.test.ts @@ -1,12 +1,12 @@ import { NodeFileSystem } from 'langium/node'; import { describe, it } from 'vitest'; import { isTslClass, isTslModule, TslTypeParameter } from '../../../../src/language/generated/ast.js'; -import { createSafeDsServices, getModuleMembers, getTypeParameters } from '../../../../src/language/index.js'; +import { createTTSLServices, getModuleMembers, getTypeParameters } from '../../../../src/language/index.js'; import { Type, UnknownType } from '../../../../src/language/typing/model.js'; import { getNodeOfType } from '../../../helpers/nodeFinder.js'; import { expectEqualTypes } from '../../../helpers/testAssertions.js'; -const services = (await createSafeDsServices(NodeFileSystem)).SafeDs; +const services = (await createTTSLServices(NodeFileSystem)).TTSL; const coreTypes = services.types.CoreTypes; const typeComputer = services.types.TypeComputer; diff --git a/packages/ttsl-lang/tests/language/typing/type computer/creator.ts b/packages/ttsl-lang/tests/language/typing/type computer/creator.ts index 4c11a558..62a9ff50 100644 --- a/packages/ttsl-lang/tests/language/typing/type computer/creator.ts +++ b/packages/ttsl-lang/tests/language/typing/type computer/creator.ts @@ -1,5 +1,5 @@ import { - listTestSafeDsFilesGroupedByParentDirectory, + listTestTTSLFilesGroupedByParentDirectory, uriToShortenedTestResourceName, } from '../../../helpers/testResources.js'; import fs from 'fs'; @@ -7,14 +7,14 @@ import { findTestChecks } from '../../../helpers/testChecks.js'; import { Location } from 'vscode-languageserver'; import { getSyntaxErrors, SyntaxErrorsInCodeError } from '../../../helpers/diagnostics.js'; import { EmptyFileSystem, URI } from 'langium'; -import { createSafeDsServices } from '../../../../src/language/index.js'; +import { createTTSLServices } from '../../../../src/language/index.js'; import { TestDescription, TestDescriptionError } from '../../../helpers/testDescription.js'; -const services = (await createSafeDsServices(EmptyFileSystem, { omitBuiltins: true })).SafeDs; +const services = (await createTTSLServices(EmptyFileSystem, { omitBuiltins: true })).TTSL; const rootResourceName = 'typing'; export const createTypingTests = (): Promise => { - const filesGroupedByParentDirectory = listTestSafeDsFilesGroupedByParentDirectory(rootResourceName); + const filesGroupedByParentDirectory = listTestTTSLFilesGroupedByParentDirectory(rootResourceName); const testCases = filesGroupedByParentDirectory.map((entry) => createTypingTest(...entry)); return Promise.all(testCases); diff --git a/packages/ttsl-lang/tests/language/typing/type computer/safe-ds-type-computer.test.ts b/packages/ttsl-lang/tests/language/typing/type computer/safe-ds-type-computer.test.ts index e69b125d..dee9b240 100644 --- a/packages/ttsl-lang/tests/language/typing/type computer/safe-ds-type-computer.test.ts +++ b/packages/ttsl-lang/tests/language/typing/type computer/safe-ds-type-computer.test.ts @@ -5,9 +5,9 @@ import { locationToString } from '../../../../src/helpers/locations.js'; import { createTypingTests } from './creator.js'; import { getNodeByLocation } from '../../../helpers/nodeFinder.js'; import { loadDocuments } from '../../../helpers/testResources.js'; -import { createSafeDsServices } from '../../../../src/language/index.js'; +import { createTTSLServices } from '../../../../src/language/index.js'; -const services = (await createSafeDsServices(NodeFileSystem)).SafeDs; +const services = (await createTTSLServices(NodeFileSystem)).TTSL; const typeComputer = services.types.TypeComputer; describe('typing', async () => { diff --git a/packages/ttsl-lang/tests/language/typing/type computer/streamSupertypes.test.ts b/packages/ttsl-lang/tests/language/typing/type computer/streamSupertypes.test.ts index 603a3eb4..99b0f96a 100644 --- a/packages/ttsl-lang/tests/language/typing/type computer/streamSupertypes.test.ts +++ b/packages/ttsl-lang/tests/language/typing/type computer/streamSupertypes.test.ts @@ -4,9 +4,9 @@ import { ClassType } from '../../../../src/language/typing/model.js'; import { isTslAttribute } from '../../../../src/language/generated/ast.js'; import { getNodeOfType } from '../../../helpers/nodeFinder.js'; import { AssertionError } from 'assert'; -import { createSafeDsServices } from '../../../../src/language/index.js'; +import { createTTSLServices } from '../../../../src/language/index.js'; -const services = (await createSafeDsServices(NodeFileSystem)).SafeDs; +const services = (await createTTSLServices(NodeFileSystem)).TTSL; const typeComputer = services.types.TypeComputer; describe('streamProperSupertypes', async () => { diff --git a/packages/ttsl-lang/tests/language/validation/creator.ts b/packages/ttsl-lang/tests/language/validation/creator.ts index 16ef0102..906e14bd 100644 --- a/packages/ttsl-lang/tests/language/validation/creator.ts +++ b/packages/ttsl-lang/tests/language/validation/creator.ts @@ -1,20 +1,20 @@ import { - listTestSafeDsFilesGroupedByParentDirectory, + listTestTTSLFilesGroupedByParentDirectory, uriToShortenedTestResourceName, } from '../../helpers/testResources.js'; import fs from 'fs'; import { findTestChecks } from '../../helpers/testChecks.js'; import { getSyntaxErrors, SyntaxErrorsInCodeError } from '../../helpers/diagnostics.js'; import { EmptyFileSystem, URI } from 'langium'; -import { createSafeDsServices } from '../../../src/language/index.js'; +import { createTTSLServices } from '../../../src/language/index.js'; import { Range } from 'vscode-languageserver'; import { TestDescription, TestDescriptionError } from '../../helpers/testDescription.js'; -const services = (await createSafeDsServices(EmptyFileSystem, { omitBuiltins: true })).SafeDs; +const services = (await createTTSLServices(EmptyFileSystem, { omitBuiltins: true })).TTSL; const rootResourceName = 'validation'; export const createValidationTests = (): Promise => { - const filesGroupedByParentDirectory = listTestSafeDsFilesGroupedByParentDirectory(rootResourceName); + const filesGroupedByParentDirectory = listTestTTSLFilesGroupedByParentDirectory(rootResourceName); const testCases = filesGroupedByParentDirectory.map((entry) => createValidationTest(...entry)); return Promise.all(testCases); diff --git a/packages/ttsl-lang/tests/language/validation/safe-ds-validator.test.ts b/packages/ttsl-lang/tests/language/validation/safe-ds-validator.test.ts index 9e847274..2da89346 100644 --- a/packages/ttsl-lang/tests/language/validation/safe-ds-validator.test.ts +++ b/packages/ttsl-lang/tests/language/validation/safe-ds-validator.test.ts @@ -6,9 +6,9 @@ import { Diagnostic, DiagnosticSeverity } from 'vscode-languageserver'; import { locationToString } from '../../../src/helpers/locations.js'; import { loadDocuments } from '../../helpers/testResources.js'; import { createValidationTests, ExpectedIssue } from './creator.js'; -import { createSafeDsServices } from '../../../src/language/index.js'; +import { createTTSLServices } from '../../../src/language/index.js'; -const services = (await createSafeDsServices(NodeFileSystem)).SafeDs; +const services = (await createTTSLServices(NodeFileSystem)).TTSL; const langiumDocuments = services.shared.workspace.LangiumDocuments; describe('validation', async () => { diff --git a/packages/ttsl-lang/tests/language/workspace/safe-ds-package-manager.test.ts b/packages/ttsl-lang/tests/language/workspace/safe-ds-package-manager.test.ts index 5668fe61..5a5d9f59 100644 --- a/packages/ttsl-lang/tests/language/workspace/safe-ds-package-manager.test.ts +++ b/packages/ttsl-lang/tests/language/workspace/safe-ds-package-manager.test.ts @@ -1,9 +1,9 @@ import { EmptyFileSystem } from 'langium'; import { clearDocuments, parseHelper } from 'langium/test'; import { afterAll, beforeAll, describe, expect, it } from 'vitest'; -import { createSafeDsServices } from '../../../src/language/index.js'; +import { createTTSLServices } from '../../../src/language/index.js'; -const services = (await createSafeDsServices(EmptyFileSystem, { omitBuiltins: true })).SafeDs; +const services = (await createTTSLServices(EmptyFileSystem, { omitBuiltins: true })).TTSL; const packageManager = services.workspace.PackageManager; const document1 = ` @@ -36,7 +36,7 @@ package myPackage2 class Class4 `; -describe('SafeDsPackageManager', () => { +describe('TTSLPackageManager', () => { beforeAll(async () => { await parseHelper(services)(document1); await parseHelper(services)(document2); diff --git a/packages/ttsl-lang/tests/language/workspace/safe-ds-workspace-manager.test.ts b/packages/ttsl-lang/tests/language/workspace/safe-ds-workspace-manager.test.ts index c66bd95f..0bef54a1 100644 --- a/packages/ttsl-lang/tests/language/workspace/safe-ds-workspace-manager.test.ts +++ b/packages/ttsl-lang/tests/language/workspace/safe-ds-workspace-manager.test.ts @@ -1,11 +1,11 @@ import { NodeFileSystem } from 'langium/node'; import { describe, expect, it } from 'vitest'; import { getLinkingErrors } from '../../helpers/diagnostics.js'; -import { createSafeDsServices } from '../../../src/language/index.js'; +import { createTTSLServices } from '../../../src/language/index.js'; -const services = (await createSafeDsServices(NodeFileSystem)).SafeDs; +const services = (await createTTSLServices(NodeFileSystem)).TTSL; -describe('SafeDsWorkspaceManager', () => { +describe('TTSLWorkspaceManager', () => { describe('loadAdditionalDocuments', () => { it.each(['Any', 'Boolean', 'Float', 'Int', 'Nothing', 'Number', 'String'])( 'should be possible to refer to %s', diff --git a/packages/ttsl-lang/tests/resources/generation/runner integration/expressions/call/generated/tests/generator/callWithRunnerIntegration/gen_input.py b/packages/ttsl-lang/tests/resources/generation/runner integration/expressions/call/generated/tests/generator/callWithRunnerIntegration/gen_input.py index d8d51c43..d5934f0c 100644 --- a/packages/ttsl-lang/tests/resources/generation/runner integration/expressions/call/generated/tests/generator/callWithRunnerIntegration/gen_input.py +++ b/packages/ttsl-lang/tests/resources/generation/runner integration/expressions/call/generated/tests/generator/callWithRunnerIntegration/gen_input.py @@ -1,6 +1,6 @@ # Imports ---------------------------------------------------------------------- -import safeds_runner +import TTSL_runner from typing import Any, Callable, TypeVar # Type variables --------------------------------------------------------------- @@ -21,37 +21,37 @@ def segment_a(a): # Pipelines -------------------------------------------------------------------- def test(): - f(safeds_runner.memoized_call("tests.generator.callWithRunnerIntegration.g", lambda *_ : g(1, param2=2), [1, 2], [])) - f(safeds_runner.memoized_call("tests.generator.callWithRunnerIntegration.g", lambda *_ : g(2, param2=1), [2, 1], [])) - f(safeds_runner.memoized_call("tests.generator.callWithRunnerIntegration.h", lambda *_ : h(1, param_2=2), [1, 2], [])) - f(safeds_runner.memoized_call("tests.generator.callWithRunnerIntegration.h", lambda *_ : h(2, param_2=1), [2, 1], [])) - f(safeds_runner.memoized_call("tests.generator.callWithRunnerIntegration.h", h, [2, 0], [])) + f(TTSL_runner.memoized_call("tests.generator.callWithRunnerIntegration.g", lambda *_ : g(1, param2=2), [1, 2], [])) + f(TTSL_runner.memoized_call("tests.generator.callWithRunnerIntegration.g", lambda *_ : g(2, param2=1), [2, 1], [])) + f(TTSL_runner.memoized_call("tests.generator.callWithRunnerIntegration.h", lambda *_ : h(1, param_2=2), [1, 2], [])) + f(TTSL_runner.memoized_call("tests.generator.callWithRunnerIntegration.h", lambda *_ : h(2, param_2=1), [2, 1], [])) + f(TTSL_runner.memoized_call("tests.generator.callWithRunnerIntegration.h", h, [2, 0], [])) 'abc'.i() 'abc'.j(123) k(456, 1.23) - __gen_null_safe_call(f, lambda: f(safeds_runner.memoized_call("tests.generator.callWithRunnerIntegration.g", lambda *_ : g(1, param2=2), [1, 2], []))) - __gen_null_safe_call(f, lambda: f(safeds_runner.memoized_call("tests.generator.callWithRunnerIntegration.g", lambda *_ : g(2, param2=1), [2, 1], []))) - __gen_null_safe_call(f, lambda: f(safeds_runner.memoized_call("tests.generator.callWithRunnerIntegration.h", lambda *_ : h(1, param_2=2), [1, 2], []))) - __gen_null_safe_call(f, lambda: f(safeds_runner.memoized_call("tests.generator.callWithRunnerIntegration.h", lambda *_ : h(2, param_2=1), [2, 1], []))) - __gen_null_safe_call(f, lambda: f(safeds_runner.memoized_call("tests.generator.callWithRunnerIntegration.h", h, [2, 0], []))) + __gen_null_safe_call(f, lambda: f(TTSL_runner.memoized_call("tests.generator.callWithRunnerIntegration.g", lambda *_ : g(1, param2=2), [1, 2], []))) + __gen_null_safe_call(f, lambda: f(TTSL_runner.memoized_call("tests.generator.callWithRunnerIntegration.g", lambda *_ : g(2, param2=1), [2, 1], []))) + __gen_null_safe_call(f, lambda: f(TTSL_runner.memoized_call("tests.generator.callWithRunnerIntegration.h", lambda *_ : h(1, param_2=2), [1, 2], []))) + __gen_null_safe_call(f, lambda: f(TTSL_runner.memoized_call("tests.generator.callWithRunnerIntegration.h", lambda *_ : h(2, param_2=1), [2, 1], []))) + __gen_null_safe_call(f, lambda: f(TTSL_runner.memoized_call("tests.generator.callWithRunnerIntegration.h", h, [2, 0], []))) __gen_null_safe_call(i, lambda: 'abc'.i()) __gen_null_safe_call(j, lambda: 'abc'.j(123)) __gen_null_safe_call(k, lambda: k(456, 1.23)) - f(safeds_runner.memoized_call("tests.generator.callWithRunnerIntegration.readFile", readFile, [], [safeds_runner.file_mtime('a.txt')])) + f(TTSL_runner.memoized_call("tests.generator.callWithRunnerIntegration.readFile", readFile, [], [TTSL_runner.file_mtime('a.txt')])) f(l(lambda a: segment_a(a))) f(l(lambda a: (3) * (segment_a(a)))) - f(l(lambda a: safeds_runner.memoized_call("tests.generator.callWithRunnerIntegration.m", m, [(3) * (segment_a(a))], []))) - f(l(lambda a: (3) * (safeds_runner.memoized_call("tests.generator.callWithRunnerIntegration.m", m, [safeds_runner.memoized_call("tests.generator.callWithRunnerIntegration.m", m, [(3) * (segment_a(a))], [])], [])))) + f(l(lambda a: TTSL_runner.memoized_call("tests.generator.callWithRunnerIntegration.m", m, [(3) * (segment_a(a))], []))) + f(l(lambda a: (3) * (TTSL_runner.memoized_call("tests.generator.callWithRunnerIntegration.m", m, [TTSL_runner.memoized_call("tests.generator.callWithRunnerIntegration.m", m, [(3) * (segment_a(a))], [])], [])))) def __gen_block_lambda_0(a): __gen_block_lambda_result_result = segment_a(a) return __gen_block_lambda_result_result f(l(__gen_block_lambda_0)) def __gen_block_lambda_1(a): - __gen_block_lambda_result_result = safeds_runner.memoized_call("tests.generator.callWithRunnerIntegration.m", m, [segment_a(a)], []) + __gen_block_lambda_result_result = TTSL_runner.memoized_call("tests.generator.callWithRunnerIntegration.m", m, [segment_a(a)], []) return __gen_block_lambda_result_result f(l(__gen_block_lambda_1)) - f(safeds_runner.memoized_call("tests.generator.callWithRunnerIntegration.l", l, [lambda a: (3) * (a)], [])) + f(TTSL_runner.memoized_call("tests.generator.callWithRunnerIntegration.l", l, [lambda a: (3) * (a)], [])) def __gen_block_lambda_2(a): - __gen_block_lambda_result_result = (3) * (safeds_runner.memoized_call("tests.generator.callWithRunnerIntegration.m", m, [a], [])) + __gen_block_lambda_result_result = (3) * (TTSL_runner.memoized_call("tests.generator.callWithRunnerIntegration.m", m, [a], [])) return __gen_block_lambda_result_result - f(safeds_runner.memoized_call("tests.generator.callWithRunnerIntegration.l", l, [__gen_block_lambda_2], [])) + f(TTSL_runner.memoized_call("tests.generator.callWithRunnerIntegration.l", l, [__gen_block_lambda_2], [])) diff --git a/packages/ttsl-lang/tests/resources/generation/runner integration/expressions/member access/generated/tests/generator/memberAccessWithRunnerIntegration/gen_input.py b/packages/ttsl-lang/tests/resources/generation/runner integration/expressions/member access/generated/tests/generator/memberAccessWithRunnerIntegration/gen_input.py index 11186b7a..01cb88b9 100644 --- a/packages/ttsl-lang/tests/resources/generation/runner integration/expressions/member access/generated/tests/generator/memberAccessWithRunnerIntegration/gen_input.py +++ b/packages/ttsl-lang/tests/resources/generation/runner integration/expressions/member access/generated/tests/generator/memberAccessWithRunnerIntegration/gen_input.py @@ -1,6 +1,6 @@ # Imports ---------------------------------------------------------------------- -import safeds_runner +import TTSL_runner from typing import Any, TypeVar # Type variables --------------------------------------------------------------- @@ -15,14 +15,14 @@ def __gen_null_safe_member_access(receiver: Any, member_name: str) -> __gen_T | # Pipelines -------------------------------------------------------------------- def test(): - f(safeds_runner.memoized_call("tests.generator.memberAccessWithRunnerIntegration.g", g, [], [])) - f(safeds_runner.memoized_call("tests.generator.memberAccessWithRunnerIntegration.h", h, [], [])[0]) - f(safeds_runner.memoized_call("tests.generator.memberAccessWithRunnerIntegration.h", h, [], [])[1]) - f(safeds_runner.memoized_call("tests.generator.memberAccessWithRunnerIntegration.C", C, [], []).a) - f(safeds_runner.memoized_call("tests.generator.memberAccessWithRunnerIntegration.C", C, [], []).c) - f(__gen_null_safe_member_access(safeds_runner.memoized_call("tests.generator.memberAccessWithRunnerIntegration.factory", factory, [], []), 'a')) - f(__gen_null_safe_member_access(safeds_runner.memoized_call("tests.generator.memberAccessWithRunnerIntegration.factory", factory, [], []), 'c')) - f(safeds_runner.memoized_call("tests.generator.memberAccessWithRunnerIntegration.C.i", lambda *_ : 1.i(safeds_runner.memoized_call("tests.generator.memberAccessWithRunnerIntegration.C", C, [], [])), [1], [])) - f(safeds_runner.memoized_call("tests.generator.memberAccessWithRunnerIntegration.C.j", C.j, [safeds_runner.memoized_call("tests.generator.memberAccessWithRunnerIntegration.C", C, [], []), 123], [])) - f(safeds_runner.memoized_call("tests.generator.memberAccessWithRunnerIntegration.C.k2", C.k2, [safeds_runner.memoized_call("tests.generator.memberAccessWithRunnerIntegration.C", C, [], []), 'abc'], [])) - f(safeds_runner.memoized_call("tests.generator.memberAccessWithRunnerIntegration.C.from_csv_file", C.from_csv_file, ['abc.csv'], [safeds_runner.file_mtime('abc.csv')])) + f(TTSL_runner.memoized_call("tests.generator.memberAccessWithRunnerIntegration.g", g, [], [])) + f(TTSL_runner.memoized_call("tests.generator.memberAccessWithRunnerIntegration.h", h, [], [])[0]) + f(TTSL_runner.memoized_call("tests.generator.memberAccessWithRunnerIntegration.h", h, [], [])[1]) + f(TTSL_runner.memoized_call("tests.generator.memberAccessWithRunnerIntegration.C", C, [], []).a) + f(TTSL_runner.memoized_call("tests.generator.memberAccessWithRunnerIntegration.C", C, [], []).c) + f(__gen_null_safe_member_access(TTSL_runner.memoized_call("tests.generator.memberAccessWithRunnerIntegration.factory", factory, [], []), 'a')) + f(__gen_null_safe_member_access(TTSL_runner.memoized_call("tests.generator.memberAccessWithRunnerIntegration.factory", factory, [], []), 'c')) + f(TTSL_runner.memoized_call("tests.generator.memberAccessWithRunnerIntegration.C.i", lambda *_ : 1.i(TTSL_runner.memoized_call("tests.generator.memberAccessWithRunnerIntegration.C", C, [], [])), [1], [])) + f(TTSL_runner.memoized_call("tests.generator.memberAccessWithRunnerIntegration.C.j", C.j, [TTSL_runner.memoized_call("tests.generator.memberAccessWithRunnerIntegration.C", C, [], []), 123], [])) + f(TTSL_runner.memoized_call("tests.generator.memberAccessWithRunnerIntegration.C.k2", C.k2, [TTSL_runner.memoized_call("tests.generator.memberAccessWithRunnerIntegration.C", C, [], []), 'abc'], [])) + f(TTSL_runner.memoized_call("tests.generator.memberAccessWithRunnerIntegration.C.from_csv_file", C.from_csv_file, ['abc.csv'], [TTSL_runner.file_mtime('abc.csv')])) diff --git a/packages/ttsl-lang/tests/resources/generation/runner integration/imports/general/generated/tests/generator/importsWithRunnerIntegration/gen_context_same_package.py b/packages/ttsl-lang/tests/resources/generation/runner integration/imports/general/generated/tests/generator/importsWithRunnerIntegration/gen_context_same_package.py index 58622ce6..36b5d886 100644 --- a/packages/ttsl-lang/tests/resources/generation/runner integration/imports/general/generated/tests/generator/importsWithRunnerIntegration/gen_context_same_package.py +++ b/packages/ttsl-lang/tests/resources/generation/runner integration/imports/general/generated/tests/generator/importsWithRunnerIntegration/gen_context_same_package.py @@ -1,13 +1,13 @@ # Imports ---------------------------------------------------------------------- -import safeds_runner +import TTSL_runner # Segments --------------------------------------------------------------------- def segment1InSamePackage(): - __gen_yield_result = safeds_runner.memoized_call("tests.generator.importsWithRunnerIntegration.impureFunction", impureFunction, [], []) + __gen_yield_result = TTSL_runner.memoized_call("tests.generator.importsWithRunnerIntegration.impureFunction", impureFunction, [], []) return __gen_yield_result def segment2InSamePackage(): - __gen_yield_result = safeds_runner.memoized_call("tests.generator.importsWithRunnerIntegration.impureFunction", impureFunction, [], []) + __gen_yield_result = TTSL_runner.memoized_call("tests.generator.importsWithRunnerIntegration.impureFunction", impureFunction, [], []) return __gen_yield_result diff --git a/packages/ttsl-lang/tests/resources/generation/runner integration/imports/general/generated/tests/generator/importsWithRunnerIntegration/gen_input.py b/packages/ttsl-lang/tests/resources/generation/runner integration/imports/general/generated/tests/generator/importsWithRunnerIntegration/gen_input.py index d5f37e74..1033a29a 100644 --- a/packages/ttsl-lang/tests/resources/generation/runner integration/imports/general/generated/tests/generator/importsWithRunnerIntegration/gen_input.py +++ b/packages/ttsl-lang/tests/resources/generation/runner integration/imports/general/generated/tests/generator/importsWithRunnerIntegration/gen_input.py @@ -1,6 +1,6 @@ # Imports ---------------------------------------------------------------------- -import safeds_runner +import TTSL_runner from special_location import function1InCompilationUnitWithPythonModule, function2InCompilationUnitWithPythonModule as h from tests.generator.differentPackageWithRunnerIntegration import function1InDifferentPackage, function2InDifferentPackage as g from tests.generator.importsWithRunnerIntegration.gen_context_same_package import segment1InSamePackage, segment2InSamePackage @@ -12,11 +12,11 @@ def test(): f(segment1InSamePackage()) f(segment2InSamePackage()) f(segment2InSamePackage()) - f(safeds_runner.memoized_call("tests.generator.differentPackageWithRunnerIntegration.function1InDifferentPackage", function1InDifferentPackage, [], [])) - f(safeds_runner.memoized_call("tests.generator.differentPackageWithRunnerIntegration.function1InDifferentPackage", function1InDifferentPackage, [], [])) - f(safeds_runner.memoized_call("tests.generator.differentPackageWithRunnerIntegration.function2InDifferentPackage", g, [], [])) - f(safeds_runner.memoized_call("tests.generator.differentPackageWithRunnerIntegration.function2InDifferentPackage", g, [], [])) - f(safeds_runner.memoized_call("special_location.function1InCompilationUnitWithPythonModule", function1InCompilationUnitWithPythonModule, [], [])) - f(safeds_runner.memoized_call("special_location.function1InCompilationUnitWithPythonModule", function1InCompilationUnitWithPythonModule, [], [])) - f(safeds_runner.memoized_call("special_location.function2InCompilationUnitWithPythonModule", h, [], [])) - f(safeds_runner.memoized_call("special_location.function2InCompilationUnitWithPythonModule", h, [], [])) + f(TTSL_runner.memoized_call("tests.generator.differentPackageWithRunnerIntegration.function1InDifferentPackage", function1InDifferentPackage, [], [])) + f(TTSL_runner.memoized_call("tests.generator.differentPackageWithRunnerIntegration.function1InDifferentPackage", function1InDifferentPackage, [], [])) + f(TTSL_runner.memoized_call("tests.generator.differentPackageWithRunnerIntegration.function2InDifferentPackage", g, [], [])) + f(TTSL_runner.memoized_call("tests.generator.differentPackageWithRunnerIntegration.function2InDifferentPackage", g, [], [])) + f(TTSL_runner.memoized_call("special_location.function1InCompilationUnitWithPythonModule", function1InCompilationUnitWithPythonModule, [], [])) + f(TTSL_runner.memoized_call("special_location.function1InCompilationUnitWithPythonModule", function1InCompilationUnitWithPythonModule, [], [])) + f(TTSL_runner.memoized_call("special_location.function2InCompilationUnitWithPythonModule", h, [], [])) + f(TTSL_runner.memoized_call("special_location.function2InCompilationUnitWithPythonModule", h, [], [])) diff --git a/packages/ttsl-lang/tests/resources/generation/runner integration/imports/wildcard/generated/tests/generator/wildcardWithRunnerIntegration/gen_input.py b/packages/ttsl-lang/tests/resources/generation/runner integration/imports/wildcard/generated/tests/generator/wildcardWithRunnerIntegration/gen_input.py index 2ab74b65..bc2595e7 100644 --- a/packages/ttsl-lang/tests/resources/generation/runner integration/imports/wildcard/generated/tests/generator/wildcardWithRunnerIntegration/gen_input.py +++ b/packages/ttsl-lang/tests/resources/generation/runner integration/imports/wildcard/generated/tests/generator/wildcardWithRunnerIntegration/gen_input.py @@ -1,17 +1,17 @@ # Imports ---------------------------------------------------------------------- -import safeds_runner +import TTSL_runner from special_location import function1InCompilationUnitWithPythonModule, function2InCompilationUnitWithPythonModule from tests.generator.differentPackageWildcardWithRunnerIntegration import function1InDifferentPackage, function2InDifferentPackage # Pipelines -------------------------------------------------------------------- def test(): - f(safeds_runner.memoized_call("tests.generator.differentPackageWildcardWithRunnerIntegration.function1InDifferentPackage", function1InDifferentPackage, [], [])) - f(safeds_runner.memoized_call("tests.generator.differentPackageWildcardWithRunnerIntegration.function1InDifferentPackage", function1InDifferentPackage, [], [])) - f(safeds_runner.memoized_call("tests.generator.differentPackageWildcardWithRunnerIntegration.function2InDifferentPackage", function2InDifferentPackage, [], [])) - f(safeds_runner.memoized_call("tests.generator.differentPackageWildcardWithRunnerIntegration.function2InDifferentPackage", function2InDifferentPackage, [], [])) - f(safeds_runner.memoized_call("special_location.function1InCompilationUnitWithPythonModule", function1InCompilationUnitWithPythonModule, [], [])) - f(safeds_runner.memoized_call("special_location.function1InCompilationUnitWithPythonModule", function1InCompilationUnitWithPythonModule, [], [])) - f(safeds_runner.memoized_call("special_location.function2InCompilationUnitWithPythonModule", function2InCompilationUnitWithPythonModule, [], [])) - f(safeds_runner.memoized_call("special_location.function2InCompilationUnitWithPythonModule", function2InCompilationUnitWithPythonModule, [], [])) + f(TTSL_runner.memoized_call("tests.generator.differentPackageWildcardWithRunnerIntegration.function1InDifferentPackage", function1InDifferentPackage, [], [])) + f(TTSL_runner.memoized_call("tests.generator.differentPackageWildcardWithRunnerIntegration.function1InDifferentPackage", function1InDifferentPackage, [], [])) + f(TTSL_runner.memoized_call("tests.generator.differentPackageWildcardWithRunnerIntegration.function2InDifferentPackage", function2InDifferentPackage, [], [])) + f(TTSL_runner.memoized_call("tests.generator.differentPackageWildcardWithRunnerIntegration.function2InDifferentPackage", function2InDifferentPackage, [], [])) + f(TTSL_runner.memoized_call("special_location.function1InCompilationUnitWithPythonModule", function1InCompilationUnitWithPythonModule, [], [])) + f(TTSL_runner.memoized_call("special_location.function1InCompilationUnitWithPythonModule", function1InCompilationUnitWithPythonModule, [], [])) + f(TTSL_runner.memoized_call("special_location.function2InCompilationUnitWithPythonModule", function2InCompilationUnitWithPythonModule, [], [])) + f(TTSL_runner.memoized_call("special_location.function2InCompilationUnitWithPythonModule", function2InCompilationUnitWithPythonModule, [], [])) diff --git a/packages/ttsl-lang/tests/resources/generation/runner integration/statements/assignment/generated/tests/generator/assignmentWithRunnerIntegration/gen_input.py b/packages/ttsl-lang/tests/resources/generation/runner integration/statements/assignment/generated/tests/generator/assignmentWithRunnerIntegration/gen_input.py index 4675cb26..24b0a14b 100644 --- a/packages/ttsl-lang/tests/resources/generation/runner integration/statements/assignment/generated/tests/generator/assignmentWithRunnerIntegration/gen_input.py +++ b/packages/ttsl-lang/tests/resources/generation/runner integration/statements/assignment/generated/tests/generator/assignmentWithRunnerIntegration/gen_input.py @@ -1,6 +1,6 @@ # Imports ---------------------------------------------------------------------- -import safeds_runner +import TTSL_runner # Segments --------------------------------------------------------------------- @@ -17,15 +17,15 @@ def testSegment(): def testPipeline(): g() a, _, _ = g() - safeds_runner.save_placeholder('a', a) + TTSL_runner.save_placeholder('a', a) x, _, _ = g() - safeds_runner.save_placeholder('x', x) + TTSL_runner.save_placeholder('x', x) f1(a) f1(x) l, m, n = g() - safeds_runner.save_placeholder('l', l) - safeds_runner.save_placeholder('m', m) - safeds_runner.save_placeholder('n', n) + TTSL_runner.save_placeholder('l', l) + TTSL_runner.save_placeholder('m', m) + TTSL_runner.save_placeholder('n', n) f1(l) f1(m) f1(n) diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main no imports or own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main no imports or own declarations.sdstest index bd7c452c..e901ee7b 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main no imports or own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main no imports or own declarations.sdstest @@ -6,8 +6,8 @@ package tests.scoping.annotationCalls.acrossFiles // $TEST$ references same_AnnotationInSamePackage @»AnnotationInSamePackage« -// $TEST$ references safeds_AnnotationInSafeDsPackage -@»AnnotationInSafeDsPackage« +// $TEST$ references TTSL_AnnotationInTTSLPackage +@»AnnotationInTTSLPackage« // $TEST$ unresolved @»AnnotationInAnotherPackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with imports and own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with imports and own declarations.sdstest index 26ce5d2b..6b9acfac 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with imports and own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with imports and own declarations.sdstest @@ -1,6 +1,6 @@ package tests.scoping.annotationCalls.acrossFiles -from safeds.scoping.annotationCalls.acrossFiles import MyAnnotation as MyOwnAnnotation +from TTSL.scoping.annotationCalls.acrossFiles import MyAnnotation as MyOwnAnnotation from tests.scoping.annotationCalls.acrossFiles.other import AnnotationInAnotherPackage, Annotation2InAnotherPackage // $TEST$ target own_MyOwnAnnotation @@ -12,8 +12,8 @@ annotation »MyOwnAnnotation« // $TEST$ references same_AnnotationInSamePackage @»AnnotationInSamePackage« -// $TEST$ references safeds_AnnotationInSafeDsPackage -@»AnnotationInSafeDsPackage« +// $TEST$ references TTSL_AnnotationInTTSLPackage +@»AnnotationInTTSLPackage« // $TEST$ references other_AnnotationInAnotherPackage @»AnnotationInAnotherPackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with multiple imports of same name.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with multiple imports of same name.sdstest index 6a480c88..93e73f08 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with multiple imports of same name.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with multiple imports of same name.sdstest @@ -1,10 +1,10 @@ package tests.scoping.annotationCalls.acrossFiles -from safeds.scoping.annotationCalls.acrossFiles import MyAnnotation +from TTSL.scoping.annotationCalls.acrossFiles import MyAnnotation from tests.scoping.annotationCalls.acrossFiles.other import MyAnnotation from tests.scoping.annotationCalls.acrossFiles import MyAnnotation pipeline myPipeline { - // $TEST$ references safeds_MyAnnotation + // $TEST$ references TTSL_MyAnnotation »MyAnnotation«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with qualified import with alias.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with qualified import with alias.sdstest index 1d3e552f..dfea21fa 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with qualified import with alias.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with qualified import with alias.sdstest @@ -1,7 +1,7 @@ package tests.scoping.annotationCalls.acrossFiles from tests.scoping.annotationCalls.acrossFiles import MyAnnotation as MyAnnotationInSamePackage -from safeds.scoping.annotationCalls.acrossFiles import MyAnnotation as MyAnnotationInSafeDsPackage +from TTSL.scoping.annotationCalls.acrossFiles import MyAnnotation as MyAnnotationInTTSLPackage from tests.scoping.annotationCalls.acrossFiles.other import MyAnnotation as MyAnnotationInAnotherPackage // $TEST$ references same_MyAnnotation @@ -11,8 +11,8 @@ from tests.scoping.annotationCalls.acrossFiles.other import MyAnnotation as MyAn // $TEST$ references same_AnnotationInSamePackage @»AnnotationInSamePackage« -// $TEST$ references safeds_AnnotationInSafeDsPackage -@»AnnotationInSafeDsPackage« +// $TEST$ references TTSL_AnnotationInTTSLPackage +@»AnnotationInTTSLPackage« // $TEST$ unresolved @»AnnotationInAnotherPackage« @@ -23,8 +23,8 @@ from tests.scoping.annotationCalls.acrossFiles.other import MyAnnotation as MyAn // $TEST$ references same_MyAnnotation @»MyAnnotationInSamePackage« -// $TEST$ references safeds_MyAnnotation -@»MyAnnotationInSafeDsPackage« +// $TEST$ references TTSL_MyAnnotation +@»MyAnnotationInTTSLPackage« // $TEST$ references other_MyAnnotation @»MyAnnotationInAnotherPackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with qualified import.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with qualified import.sdstest index d6c494b7..ada9880a 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with qualified import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with qualified import.sdstest @@ -1,16 +1,16 @@ package tests.scoping.annotationCalls.acrossFiles -from safeds.scoping.annotationCalls.acrossFiles import MyAnnotation +from TTSL.scoping.annotationCalls.acrossFiles import MyAnnotation from tests.scoping.annotationCalls.acrossFiles.other import AnnotationInAnotherPackage, Annotation2InAnotherPackage, NotAnAnnotation -// $TEST$ references safeds_MyAnnotation +// $TEST$ references TTSL_MyAnnotation @»MyAnnotation« // $TEST$ references same_AnnotationInSamePackage @»AnnotationInSamePackage« -// $TEST$ references safeds_AnnotationInSafeDsPackage -@»AnnotationInSafeDsPackage« +// $TEST$ references TTSL_AnnotationInTTSLPackage +@»AnnotationInTTSLPackage« // $TEST$ references other_AnnotationInAnotherPackage @»AnnotationInAnotherPackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with wildcard import.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with wildcard import.sdstest index a1e2db9b..8b90ccc8 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with wildcard import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with wildcard import.sdstest @@ -1,15 +1,15 @@ package tests.scoping.annotationCalls.acrossFiles -from safeds.scoping.annotationCalls.acrossFiles import * +from TTSL.scoping.annotationCalls.acrossFiles import * -// $TEST$ references safeds_MyAnnotation +// $TEST$ references TTSL_MyAnnotation @»MyAnnotation« // $TEST$ references same_AnnotationInSamePackage @»AnnotationInSamePackage« -// $TEST$ references safeds_AnnotationInSafeDsPackage -@»AnnotationInSafeDsPackage« +// $TEST$ references TTSL_AnnotationInTTSLPackage +@»AnnotationInTTSLPackage« // $TEST$ unresolved @»AnnotationInAnotherPackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/resource safeds package.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/resource safeds package.sdstest index ec8a3f21..d0f8568d 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/resource safeds package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/resource safeds package.sdstest @@ -1,7 +1,7 @@ -package safeds.scoping.annotationCalls.acrossFiles +package TTSL.scoping.annotationCalls.acrossFiles -// $TEST$ target safeds_MyAnnotation +// $TEST$ target TTSL_MyAnnotation annotation »MyAnnotation« -// $TEST$ target safeds_AnnotationInSafeDsPackage -annotation »AnnotationInSafeDsPackage« +// $TEST$ target TTSL_AnnotationInTTSLPackage +annotation »AnnotationInTTSLPackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main no imports or own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main no imports or own declarations.sdstest index 83bf6e2d..7286b411 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main no imports or own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main no imports or own declarations.sdstest @@ -7,8 +7,8 @@ segment mySegment( // $TEST$ references same_ClassInSamePackage p2: »ClassInSamePackage«, - // $TEST$ references safeds_ClassInSafeDsPackage - p3: »ClassInSafeDsPackage«, + // $TEST$ references TTSL_ClassInTTSLPackage + p3: »ClassInTTSLPackage«, // $TEST$ unresolved p4: »ClassInAnotherPackage«, diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with imports and own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with imports and own declarations.sdstest index 86ba33e0..3560c072 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with imports and own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with imports and own declarations.sdstest @@ -1,6 +1,6 @@ package tests.scoping.namedTypes.acrossFiles.toGlobalClasses -from safeds.scoping.namedTypes.acrossFiles.toGlobalClasses import MyClass as MyOwnClass +from TTSL.scoping.namedTypes.acrossFiles.toGlobalClasses import MyClass as MyOwnClass from tests.scoping.namedTypes.acrossFiles.toGlobalClasses.other import ClassInAnotherPackage, Class2InAnotherPackage // $TEST$ target own_MyOwnClass @@ -13,8 +13,8 @@ segment mySegment( // $TEST$ references same_ClassInSamePackage p2: »ClassInSamePackage«, - // $TEST$ references safeds_ClassInSafeDsPackage - p3: »ClassInSafeDsPackage«, + // $TEST$ references TTSL_ClassInTTSLPackage + p3: »ClassInTTSLPackage«, // $TEST$ references other_ClassInAnotherPackage p4: »ClassInAnotherPackage«, diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with multiple imports of same name.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with multiple imports of same name.sdstest index 2d9adf6d..84b50f4a 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with multiple imports of same name.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with multiple imports of same name.sdstest @@ -1,10 +1,10 @@ package tests.scoping.namedTypes.acrossFiles.toGlobalClasses -from safeds.scoping.namedTypes.acrossFiles.toGlobalClasses import MyClass +from TTSL.scoping.namedTypes.acrossFiles.toGlobalClasses import MyClass from tests.scoping.namedTypes.acrossFiles.toGlobalClasses.other import MyClass from tests.scoping.namedTypes.acrossFiles.toGlobalClasses import MyClass segment mySegment( - // $TEST$ references safeds_MyClass + // $TEST$ references TTSL_MyClass p: »MyClass«, ) {} diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with qualified import with alias.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with qualified import with alias.sdstest index 476df03c..1e94f08c 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with qualified import with alias.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with qualified import with alias.sdstest @@ -1,7 +1,7 @@ package tests.scoping.namedTypes.acrossFiles.toGlobalClasses from tests.scoping.namedTypes.acrossFiles.toGlobalClasses import MyClass as MyClassInSamePackage -from safeds.scoping.namedTypes.acrossFiles.toGlobalClasses import MyClass as MyClassInSafeDsPackage +from TTSL.scoping.namedTypes.acrossFiles.toGlobalClasses import MyClass as MyClassInTTSLPackage from tests.scoping.namedTypes.acrossFiles.toGlobalClasses.other import MyClass as MyClassInAnotherPackage segment mySegment( @@ -12,8 +12,8 @@ segment mySegment( // $TEST$ references same_ClassInSamePackage p2: »ClassInSamePackage«, - // $TEST$ references safeds_ClassInSafeDsPackage - p3: »ClassInSafeDsPackage«, + // $TEST$ references TTSL_ClassInTTSLPackage + p3: »ClassInTTSLPackage«, // $TEST$ unresolved p4: »ClassInAnotherPackage«, @@ -24,8 +24,8 @@ segment mySegment( // $TEST$ references same_MyClass p6: »MyClassInSamePackage«, - // $TEST$ references safeds_MyClass - p7: »MyClassInSafeDsPackage«, + // $TEST$ references TTSL_MyClass + p7: »MyClassInTTSLPackage«, // $TEST$ references other_MyClass p8: »MyClassInAnotherPackage«, diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with qualified import.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with qualified import.sdstest index c29a526f..195867e7 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with qualified import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with qualified import.sdstest @@ -1,17 +1,17 @@ package tests.scoping.namedTypes.acrossFiles.toGlobalClasses -from safeds.scoping.namedTypes.acrossFiles.toGlobalClasses import MyClass +from TTSL.scoping.namedTypes.acrossFiles.toGlobalClasses import MyClass from tests.scoping.namedTypes.acrossFiles.toGlobalClasses.other import ClassInAnotherPackage, Class2InAnotherPackage, notANamedTypeDeclaration segment mySegment( - // $TEST$ references safeds_MyClass + // $TEST$ references TTSL_MyClass p1: »MyClass«, // $TEST$ references same_ClassInSamePackage p2: »ClassInSamePackage«, - // $TEST$ references safeds_ClassInSafeDsPackage - p3: »ClassInSafeDsPackage«, + // $TEST$ references TTSL_ClassInTTSLPackage + p3: »ClassInTTSLPackage«, // $TEST$ references other_ClassInAnotherPackage p4: »ClassInAnotherPackage«, diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with wildcard import.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with wildcard import.sdstest index c68c481c..0c5438d4 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with wildcard import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with wildcard import.sdstest @@ -1,16 +1,16 @@ package tests.scoping.namedTypes.acrossFiles.toGlobalClasses -from safeds.scoping.namedTypes.acrossFiles.toGlobalClasses import * +from TTSL.scoping.namedTypes.acrossFiles.toGlobalClasses import * segment mySegment( - // $TEST$ references safeds_MyClass + // $TEST$ references TTSL_MyClass p1: »MyClass«, // $TEST$ references same_ClassInSamePackage p2: »ClassInSamePackage«, - // $TEST$ references safeds_ClassInSafeDsPackage - p3: »ClassInSafeDsPackage«, + // $TEST$ references TTSL_ClassInTTSLPackage + p3: »ClassInTTSLPackage«, // $TEST$ unresolved p4: »ClassInAnotherPackage«, diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/resource safeds package.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/resource safeds package.sdstest index a51a37c2..280f1346 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/resource safeds package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/resource safeds package.sdstest @@ -1,7 +1,7 @@ -package safeds.scoping.namedTypes.acrossFiles.toGlobalClasses +package TTSL.scoping.namedTypes.acrossFiles.toGlobalClasses -// $TEST$ target safeds_MyClass +// $TEST$ target TTSL_MyClass class »MyClass« -// $TEST$ target safeds_ClassInSafeDsPackage -class »ClassInSafeDsPackage« +// $TEST$ target TTSL_ClassInTTSLPackage +class »ClassInTTSLPackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main no imports or own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main no imports or own declarations.sdstest index 7f0a0cef..6455e2ea 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main no imports or own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main no imports or own declarations.sdstest @@ -7,8 +7,8 @@ segment mySegment( // $TEST$ references same_EnumInSamePackage p2: »EnumInSamePackage«, - // $TEST$ references safeds_EnumInSafeDsPackage - p3: »EnumInSafeDsPackage«, + // $TEST$ references TTSL_EnumInTTSLPackage + p3: »EnumInTTSLPackage«, // $TEST$ unresolved p4: »EnumInAnotherPackage«, diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with imports and own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with imports and own declarations.sdstest index e56ba80a..2c731e82 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with imports and own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with imports and own declarations.sdstest @@ -1,6 +1,6 @@ package tests.scoping.namedTypes.acrossFiles.toGlobalEnums -from safeds.scoping.namedTypes.acrossFiles.toGlobalEnums import MyEnum as MyOwnEnum +from TTSL.scoping.namedTypes.acrossFiles.toGlobalEnums import MyEnum as MyOwnEnum from tests.scoping.namedTypes.acrossFiles.toGlobalEnums.other import EnumInAnotherPackage, Enum2InAnotherPackage // $TEST$ target own_MyOwnEnum @@ -13,8 +13,8 @@ segment mySegment( // $TEST$ references same_EnumInSamePackage p2: »EnumInSamePackage«, - // $TEST$ references safeds_EnumInSafeDsPackage - p3: »EnumInSafeDsPackage«, + // $TEST$ references TTSL_EnumInTTSLPackage + p3: »EnumInTTSLPackage«, // $TEST$ references other_EnumInAnotherPackage p4: »EnumInAnotherPackage«, diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with multiple imports of same name.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with multiple imports of same name.sdstest index b13ad0d2..b0e451ed 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with multiple imports of same name.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with multiple imports of same name.sdstest @@ -1,10 +1,10 @@ package tests.scoping.namedTypes.acrossFiles.toGlobalEnums -from safeds.scoping.namedTypes.acrossFiles.toGlobalEnums import MyEnum +from TTSL.scoping.namedTypes.acrossFiles.toGlobalEnums import MyEnum from tests.scoping.namedTypes.acrossFiles.toGlobalEnums.other import MyEnum from tests.scoping.namedTypes.acrossFiles.toGlobalEnums import MyEnum segment mySegment( - // $TEST$ references safeds_MyEnum + // $TEST$ references TTSL_MyEnum p: »MyEnum«, ) {} diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with qualified import with alias.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with qualified import with alias.sdstest index fbd4b754..712f4925 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with qualified import with alias.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with qualified import with alias.sdstest @@ -1,7 +1,7 @@ package tests.scoping.namedTypes.acrossFiles.toGlobalEnums from tests.scoping.namedTypes.acrossFiles.toGlobalEnums import MyEnum as MyEnumInSamePackage -from safeds.scoping.namedTypes.acrossFiles.toGlobalEnums import MyEnum as MyEnumInSafeDsPackage +from TTSL.scoping.namedTypes.acrossFiles.toGlobalEnums import MyEnum as MyEnumInTTSLPackage from tests.scoping.namedTypes.acrossFiles.toGlobalEnums.other import MyEnum as MyEnumInAnotherPackage segment mySegment( @@ -12,8 +12,8 @@ segment mySegment( // $TEST$ references same_EnumInSamePackage p2: »EnumInSamePackage«, - // $TEST$ references safeds_EnumInSafeDsPackage - p3: »EnumInSafeDsPackage«, + // $TEST$ references TTSL_EnumInTTSLPackage + p3: »EnumInTTSLPackage«, // $TEST$ unresolved p4: »EnumInAnotherPackage«, @@ -25,8 +25,8 @@ segment mySegment( // $TEST$ references same_MyEnum p6: »MyEnumInSamePackage«, - // $TEST$ references safeds_MyEnum - p7: »MyEnumInSafeDsPackage«, + // $TEST$ references TTSL_MyEnum + p7: »MyEnumInTTSLPackage«, // $TEST$ references other_MyEnum p8: »MyEnumInAnotherPackage«, diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with qualified import.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with qualified import.sdstest index 155e02e5..c495cec5 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with qualified import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with qualified import.sdstest @@ -1,17 +1,17 @@ package tests.scoping.namedTypes.acrossFiles.toGlobalEnums -from safeds.scoping.namedTypes.acrossFiles.toGlobalEnums import MyEnum +from TTSL.scoping.namedTypes.acrossFiles.toGlobalEnums import MyEnum from tests.scoping.namedTypes.acrossFiles.toGlobalEnums.other import EnumInAnotherPackage, Enum2InAnotherPackage, notANamedTypeDeclaration segment mySegment( - // $TEST$ references safeds_MyEnum + // $TEST$ references TTSL_MyEnum p1: »MyEnum«, // $TEST$ references same_EnumInSamePackage p2: »EnumInSamePackage«, - // $TEST$ references safeds_EnumInSafeDsPackage - p3: »EnumInSafeDsPackage«, + // $TEST$ references TTSL_EnumInTTSLPackage + p3: »EnumInTTSLPackage«, // $TEST$ references other_EnumInAnotherPackage p4: »EnumInAnotherPackage«, diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with wildcard import.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with wildcard import.sdstest index a3970f20..5bd4318b 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with wildcard import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with wildcard import.sdstest @@ -1,16 +1,16 @@ package tests.scoping.namedTypes.acrossFiles.toGlobalEnums -from safeds.scoping.namedTypes.acrossFiles.toGlobalEnums import * +from TTSL.scoping.namedTypes.acrossFiles.toGlobalEnums import * segment mySegment( - // $TEST$ references safeds_MyEnum + // $TEST$ references TTSL_MyEnum p1: »MyEnum«, // $TEST$ references same_EnumInSamePackage p2: »EnumInSamePackage«, - // $TEST$ references safeds_EnumInSafeDsPackage - p3: »EnumInSafeDsPackage«, + // $TEST$ references TTSL_EnumInTTSLPackage + p3: »EnumInTTSLPackage«, // $TEST$ unresolved p4: »EnumInAnotherPackage«, diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/resource safeds package.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/resource safeds package.sdstest index 0c032246..21047373 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/resource safeds package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/resource safeds package.sdstest @@ -1,7 +1,7 @@ -package safeds.scoping.namedTypes.acrossFiles.toGlobalEnums +package TTSL.scoping.namedTypes.acrossFiles.toGlobalEnums -// $TEST$ target safeds_MyEnum +// $TEST$ target TTSL_MyEnum enum »MyEnum« -// $TEST$ target safeds_EnumInSafeDsPackage -enum »EnumInSafeDsPackage« +// $TEST$ target TTSL_EnumInTTSLPackage +enum »EnumInTTSLPackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main no imports or own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main no imports or own declarations.sdstest index 343ec013..f8f26d0f 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main no imports or own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main no imports or own declarations.sdstest @@ -7,8 +7,8 @@ pipeline myPipeline { // $TEST$ references same_AnnotationInSamePackage »AnnotationInSamePackage«; - // $TEST$ references safeds_AnnotationInSafeDsPackage - »AnnotationInSafeDsPackage«; + // $TEST$ references TTSL_AnnotationInTTSLPackage + »AnnotationInTTSLPackage«; // $TEST$ unresolved »AnnotationInAnotherPackage«; diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with imports and own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with imports and own declarations.sdstest index 795246ef..6091c8f0 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with imports and own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with imports and own declarations.sdstest @@ -1,6 +1,6 @@ package tests.scoping.references.acrossFiles.toAnnotations -from safeds.scoping.references.acrossFiles.toAnnotations import MyAnnotation as MyOwnAnnotation +from TTSL.scoping.references.acrossFiles.toAnnotations import MyAnnotation as MyOwnAnnotation from tests.scoping.references.acrossFiles.toAnnotations.other import AnnotationInAnotherPackage, Annotation2InAnotherPackage // $TEST$ target own_MyOwnAnnotation @@ -13,8 +13,8 @@ pipeline myPipeline { // $TEST$ references same_AnnotationInSamePackage »AnnotationInSamePackage«; - // $TEST$ references safeds_AnnotationInSafeDsPackage - »AnnotationInSafeDsPackage«; + // $TEST$ references TTSL_AnnotationInTTSLPackage + »AnnotationInTTSLPackage«; // $TEST$ references other_AnnotationInAnotherPackage »AnnotationInAnotherPackage«; diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with multiple imports of same name.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with multiple imports of same name.sdstest index 9c10eff5..3de2cf61 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with multiple imports of same name.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with multiple imports of same name.sdstest @@ -1,10 +1,10 @@ package tests.scoping.references.acrossFiles.toAnnotations -from safeds.scoping.references.acrossFiles.toAnnotations import MyAnnotation +from TTSL.scoping.references.acrossFiles.toAnnotations import MyAnnotation from tests.scoping.references.acrossFiles.toAnnotations.other import MyAnnotation from tests.scoping.references.acrossFiles.toAnnotations import MyAnnotation pipeline myPipeline { - // $TEST$ references safeds_MyAnnotation + // $TEST$ references TTSL_MyAnnotation »MyAnnotation«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with qualified import with alias.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with qualified import with alias.sdstest index 8e57d387..f2f0fd46 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with qualified import with alias.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with qualified import with alias.sdstest @@ -1,7 +1,7 @@ package tests.scoping.references.acrossFiles.toAnnotations from tests.scoping.references.acrossFiles.toAnnotations import MyAnnotation as MyAnnotationInSamePackage -from safeds.scoping.references.acrossFiles.toAnnotations import MyAnnotation as MyAnnotationInSafeDsPackage +from TTSL.scoping.references.acrossFiles.toAnnotations import MyAnnotation as MyAnnotationInTTSLPackage from tests.scoping.references.acrossFiles.toAnnotations.other import MyAnnotation as MyAnnotationInAnotherPackage pipeline myPipeline { @@ -12,8 +12,8 @@ pipeline myPipeline { // $TEST$ references same_AnnotationInSamePackage »AnnotationInSamePackage«; - // $TEST$ references safeds_AnnotationInSafeDsPackage - »AnnotationInSafeDsPackage«; + // $TEST$ references TTSL_AnnotationInTTSLPackage + »AnnotationInTTSLPackage«; // $TEST$ unresolved »AnnotationInAnotherPackage«; @@ -24,8 +24,8 @@ pipeline myPipeline { // $TEST$ references same_MyAnnotation »MyAnnotationInSamePackage«; - // $TEST$ references safeds_MyAnnotation - »MyAnnotationInSafeDsPackage«; + // $TEST$ references TTSL_MyAnnotation + »MyAnnotationInTTSLPackage«; // $TEST$ references other_MyAnnotation »MyAnnotationInAnotherPackage«; diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with qualified import.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with qualified import.sdstest index f2e10fd9..d0f802ae 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with qualified import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with qualified import.sdstest @@ -1,17 +1,17 @@ package tests.scoping.references.acrossFiles.toAnnotations -from safeds.scoping.references.acrossFiles.toAnnotations import MyAnnotation +from TTSL.scoping.references.acrossFiles.toAnnotations import MyAnnotation from tests.scoping.references.acrossFiles.toAnnotations.other import AnnotationInAnotherPackage, Annotation2InAnotherPackage pipeline myPipeline { - // $TEST$ references safeds_MyAnnotation + // $TEST$ references TTSL_MyAnnotation »MyAnnotation«; // $TEST$ references same_AnnotationInSamePackage »AnnotationInSamePackage«; - // $TEST$ references safeds_AnnotationInSafeDsPackage - »AnnotationInSafeDsPackage«; + // $TEST$ references TTSL_AnnotationInTTSLPackage + »AnnotationInTTSLPackage«; // $TEST$ references other_AnnotationInAnotherPackage »AnnotationInAnotherPackage«; diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with wildcard import.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with wildcard import.sdstest index db146974..ee918cd6 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with wildcard import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with wildcard import.sdstest @@ -1,16 +1,16 @@ package tests.scoping.references.acrossFiles.toAnnotations -from safeds.scoping.references.acrossFiles.toAnnotations import * +from TTSL.scoping.references.acrossFiles.toAnnotations import * pipeline myPipeline { - // $TEST$ references safeds_MyAnnotation + // $TEST$ references TTSL_MyAnnotation »MyAnnotation«; // $TEST$ references same_AnnotationInSamePackage »AnnotationInSamePackage«; - // $TEST$ references safeds_AnnotationInSafeDsPackage - »AnnotationInSafeDsPackage«; + // $TEST$ references TTSL_AnnotationInTTSLPackage + »AnnotationInTTSLPackage«; // $TEST$ unresolved »AnnotationInAnotherPackage«; diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/resource safeds package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/resource safeds package.sdstest index 3febd64f..ecd39de9 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/resource safeds package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/resource safeds package.sdstest @@ -1,7 +1,7 @@ -package safeds.scoping.references.acrossFiles.toAnnotations +package TTSL.scoping.references.acrossFiles.toAnnotations -// $TEST$ target safeds_MyAnnotation +// $TEST$ target TTSL_MyAnnotation annotation »MyAnnotation« -// $TEST$ target safeds_AnnotationInSafeDsPackage -annotation »AnnotationInSafeDsPackage« +// $TEST$ target TTSL_AnnotationInTTSLPackage +annotation »AnnotationInTTSLPackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main no imports or own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main no imports or own declarations.sdstest index 14832a0e..5821d49d 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main no imports or own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main no imports or own declarations.sdstest @@ -7,8 +7,8 @@ pipeline myPipeline { // $TEST$ references same_ClassInSamePackage »ClassInSamePackage«; - // $TEST$ references safeds_ClassInSafeDsPackage - »ClassInSafeDsPackage«; + // $TEST$ references TTSL_ClassInTTSLPackage + »ClassInTTSLPackage«; // $TEST$ unresolved »ClassInAnotherPackage«; diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with imports and own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with imports and own declarations.sdstest index 1f05fa8b..69f7b082 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with imports and own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with imports and own declarations.sdstest @@ -1,6 +1,6 @@ package tests.scoping.references.acrossFiles.toGlobalClasses -from safeds.scoping.references.acrossFiles.toGlobalClasses import MyClass as MyOwnClass +from TTSL.scoping.references.acrossFiles.toGlobalClasses import MyClass as MyOwnClass from tests.scoping.references.acrossFiles.toGlobalClasses.other import ClassInAnotherPackage, Class2InAnotherPackage // $TEST$ target own_MyOwnClass @@ -13,8 +13,8 @@ pipeline myPipeline { // $TEST$ references same_ClassInSamePackage »ClassInSamePackage«; - // $TEST$ references safeds_ClassInSafeDsPackage - »ClassInSafeDsPackage«; + // $TEST$ references TTSL_ClassInTTSLPackage + »ClassInTTSLPackage«; // $TEST$ references other_ClassInAnotherPackage »ClassInAnotherPackage«; diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with multiple imports of same name.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with multiple imports of same name.sdstest index 8b624512..bae67381 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with multiple imports of same name.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with multiple imports of same name.sdstest @@ -1,10 +1,10 @@ package tests.scoping.references.acrossFiles.toGlobalClasses -from safeds.scoping.references.acrossFiles.toGlobalClasses import MyClass +from TTSL.scoping.references.acrossFiles.toGlobalClasses import MyClass from tests.scoping.references.acrossFiles.toGlobalClasses.other import MyClass from tests.scoping.references.acrossFiles.toGlobalClasses import MyClass pipeline myPipeline { - // $TEST$ references safeds_MyClass + // $TEST$ references TTSL_MyClass »MyClass«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with qualified import with alias.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with qualified import with alias.sdstest index 2a7d6d90..8730fbab 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with qualified import with alias.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with qualified import with alias.sdstest @@ -1,7 +1,7 @@ package tests.scoping.references.acrossFiles.toGlobalClasses from tests.scoping.references.acrossFiles.toGlobalClasses import MyClass as MyClassInSamePackage -from safeds.scoping.references.acrossFiles.toGlobalClasses import MyClass as MyClassInSafeDsPackage +from TTSL.scoping.references.acrossFiles.toGlobalClasses import MyClass as MyClassInTTSLPackage from tests.scoping.references.acrossFiles.toGlobalClasses.other import MyClass as MyClassInAnotherPackage pipeline myPipeline { @@ -12,8 +12,8 @@ pipeline myPipeline { // $TEST$ references same_ClassInSamePackage »ClassInSamePackage«; - // $TEST$ references safeds_ClassInSafeDsPackage - »ClassInSafeDsPackage«; + // $TEST$ references TTSL_ClassInTTSLPackage + »ClassInTTSLPackage«; // $TEST$ unresolved »ClassInAnotherPackage«; @@ -24,8 +24,8 @@ pipeline myPipeline { // $TEST$ references same_MyClass »MyClassInSamePackage«; - // $TEST$ references safeds_MyClass - »MyClassInSafeDsPackage«; + // $TEST$ references TTSL_MyClass + »MyClassInTTSLPackage«; // $TEST$ references other_MyClass »MyClassInAnotherPackage«; diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with qualified import.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with qualified import.sdstest index 10bf0a70..af0bcb27 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with qualified import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with qualified import.sdstest @@ -1,17 +1,17 @@ package tests.scoping.references.acrossFiles.toGlobalClasses -from safeds.scoping.references.acrossFiles.toGlobalClasses import MyClass +from TTSL.scoping.references.acrossFiles.toGlobalClasses import MyClass from tests.scoping.references.acrossFiles.toGlobalClasses.other import ClassInAnotherPackage, Class2InAnotherPackage pipeline myPipeline { - // $TEST$ references safeds_MyClass + // $TEST$ references TTSL_MyClass »MyClass«; // $TEST$ references same_ClassInSamePackage »ClassInSamePackage«; - // $TEST$ references safeds_ClassInSafeDsPackage - »ClassInSafeDsPackage«; + // $TEST$ references TTSL_ClassInTTSLPackage + »ClassInTTSLPackage«; // $TEST$ references other_ClassInAnotherPackage »ClassInAnotherPackage«; diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with wildcard import.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with wildcard import.sdstest index 2e24c405..4553836f 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with wildcard import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with wildcard import.sdstest @@ -1,16 +1,16 @@ package tests.scoping.references.acrossFiles.toGlobalClasses -from safeds.scoping.references.acrossFiles.toGlobalClasses import * +from TTSL.scoping.references.acrossFiles.toGlobalClasses import * pipeline myPipeline { - // $TEST$ references safeds_MyClass + // $TEST$ references TTSL_MyClass »MyClass«; // $TEST$ references same_ClassInSamePackage »ClassInSamePackage«; - // $TEST$ references safeds_ClassInSafeDsPackage - »ClassInSafeDsPackage«; + // $TEST$ references TTSL_ClassInTTSLPackage + »ClassInTTSLPackage«; // $TEST$ unresolved »ClassInAnotherPackage«; diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/resource safeds package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/resource safeds package.sdstest index f9bbc9a9..a64b84e2 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/resource safeds package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/resource safeds package.sdstest @@ -1,7 +1,7 @@ -package safeds.scoping.references.acrossFiles.toGlobalClasses +package TTSL.scoping.references.acrossFiles.toGlobalClasses -// $TEST$ target safeds_MyClass +// $TEST$ target TTSL_MyClass class »MyClass« -// $TEST$ target safeds_ClassInSafeDsPackage -class »ClassInSafeDsPackage« +// $TEST$ target TTSL_ClassInTTSLPackage +class »ClassInTTSLPackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main no imports or own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main no imports or own declarations.sdstest index 0271f2e5..152119b8 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main no imports or own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main no imports or own declarations.sdstest @@ -7,8 +7,8 @@ pipeline myPipeline { // $TEST$ references same_EnumInSamePackage »EnumInSamePackage«; - // $TEST$ references safeds_EnumInSafeDsPackage - »EnumInSafeDsPackage«; + // $TEST$ references TTSL_EnumInTTSLPackage + »EnumInTTSLPackage«; // $TEST$ unresolved »EnumInAnotherPackage«; diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with imports and own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with imports and own declarations.sdstest index 5d3127fa..c19e5acf 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with imports and own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with imports and own declarations.sdstest @@ -1,6 +1,6 @@ package tests.scoping.references.acrossFiles.toGlobalEnums -from safeds.scoping.references.acrossFiles.toGlobalEnums import MyEnum as MyOwnEnum +from TTSL.scoping.references.acrossFiles.toGlobalEnums import MyEnum as MyOwnEnum from tests.scoping.references.acrossFiles.toGlobalEnums.other import EnumInAnotherPackage, Enum2InAnotherPackage // $TEST$ target own_MyOwnEnum @@ -13,8 +13,8 @@ pipeline myPipeline { // $TEST$ references same_EnumInSamePackage »EnumInSamePackage«; - // $TEST$ references safeds_EnumInSafeDsPackage - »EnumInSafeDsPackage«; + // $TEST$ references TTSL_EnumInTTSLPackage + »EnumInTTSLPackage«; // $TEST$ references other_EnumInAnotherPackage »EnumInAnotherPackage«; diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with multiple imports of same name.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with multiple imports of same name.sdstest index 6a8fe5b7..c4d43613 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with multiple imports of same name.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with multiple imports of same name.sdstest @@ -1,10 +1,10 @@ package tests.scoping.references.acrossFiles.toGlobalEnums -from safeds.scoping.references.acrossFiles.toGlobalEnums import MyEnum +from TTSL.scoping.references.acrossFiles.toGlobalEnums import MyEnum from tests.scoping.references.acrossFiles.toGlobalEnums.other import MyEnum from tests.scoping.references.acrossFiles.toGlobalEnums import MyEnum pipeline myPipeline { - // $TEST$ references safeds_MyEnum + // $TEST$ references TTSL_MyEnum »MyEnum«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with qualified import with alias.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with qualified import with alias.sdstest index 6139ad2f..8b206f37 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with qualified import with alias.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with qualified import with alias.sdstest @@ -1,7 +1,7 @@ package tests.scoping.references.acrossFiles.toGlobalEnums from tests.scoping.references.acrossFiles.toGlobalEnums import MyEnum as MyEnumInSamePackage -from safeds.scoping.references.acrossFiles.toGlobalEnums import MyEnum as MyEnumInSafeDsPackage +from TTSL.scoping.references.acrossFiles.toGlobalEnums import MyEnum as MyEnumInTTSLPackage from tests.scoping.references.acrossFiles.toGlobalEnums.other import MyEnum as MyEnumInAnotherPackage pipeline myPipeline { @@ -12,8 +12,8 @@ pipeline myPipeline { // $TEST$ references same_EnumInSamePackage »EnumInSamePackage«; - // $TEST$ references safeds_EnumInSafeDsPackage - »EnumInSafeDsPackage«; + // $TEST$ references TTSL_EnumInTTSLPackage + »EnumInTTSLPackage«; // $TEST$ unresolved »EnumInAnotherPackage«; @@ -25,8 +25,8 @@ pipeline myPipeline { // $TEST$ references same_MyEnum »MyEnumInSamePackage«; - // $TEST$ references safeds_MyEnum - »MyEnumInSafeDsPackage«; + // $TEST$ references TTSL_MyEnum + »MyEnumInTTSLPackage«; // $TEST$ references other_MyEnum »MyEnumInAnotherPackage«; diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with qualified import.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with qualified import.sdstest index c844cc99..a45d1358 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with qualified import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with qualified import.sdstest @@ -1,17 +1,17 @@ package tests.scoping.references.acrossFiles.toGlobalEnums -from safeds.scoping.references.acrossFiles.toGlobalEnums import MyEnum +from TTSL.scoping.references.acrossFiles.toGlobalEnums import MyEnum from tests.scoping.references.acrossFiles.toGlobalEnums.other import EnumInAnotherPackage, Enum2InAnotherPackage pipeline myPipeline { - // $TEST$ references safeds_MyEnum + // $TEST$ references TTSL_MyEnum »MyEnum«; // $TEST$ references same_EnumInSamePackage »EnumInSamePackage«; - // $TEST$ references safeds_EnumInSafeDsPackage - »EnumInSafeDsPackage«; + // $TEST$ references TTSL_EnumInTTSLPackage + »EnumInTTSLPackage«; // $TEST$ references other_EnumInAnotherPackage »EnumInAnotherPackage«; diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with wildcard import.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with wildcard import.sdstest index 391d353e..17d4aeb0 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with wildcard import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with wildcard import.sdstest @@ -1,16 +1,16 @@ package tests.scoping.references.acrossFiles.toGlobalEnums -from safeds.scoping.references.acrossFiles.toGlobalEnums import * +from TTSL.scoping.references.acrossFiles.toGlobalEnums import * pipeline myPipeline { - // $TEST$ references safeds_MyEnum + // $TEST$ references TTSL_MyEnum »MyEnum«; // $TEST$ references same_EnumInSamePackage »EnumInSamePackage«; - // $TEST$ references safeds_EnumInSafeDsPackage - »EnumInSafeDsPackage«; + // $TEST$ references TTSL_EnumInTTSLPackage + »EnumInTTSLPackage«; // $TEST$ unresolved »EnumInAnotherPackage«; diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/resource safeds package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/resource safeds package.sdstest index 44e595fc..ddd39233 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/resource safeds package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/resource safeds package.sdstest @@ -1,7 +1,7 @@ -package safeds.scoping.references.acrossFiles.toGlobalEnums +package TTSL.scoping.references.acrossFiles.toGlobalEnums -// $TEST$ target safeds_MyEnum +// $TEST$ target TTSL_MyEnum enum »MyEnum« -// $TEST$ target safeds_EnumInSafeDsPackage -enum »EnumInSafeDsPackage« +// $TEST$ target TTSL_EnumInTTSLPackage +enum »EnumInTTSLPackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main no imports or own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main no imports or own declarations.sdstest index aa95d66f..58248356 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main no imports or own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main no imports or own declarations.sdstest @@ -7,8 +7,8 @@ pipeline myPipeline { // $TEST$ references same_functionInSamePackage »functionInSamePackage«; - // $TEST$ references safeds_functionInSafeDsPackage - »functionInSafeDsPackage«; + // $TEST$ references TTSL_functionInTTSLPackage + »functionInTTSLPackage«; // $TEST$ unresolved »functionInAnotherPackage«; diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with imports and own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with imports and own declarations.sdstest index 822b94b9..c8a4f070 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with imports and own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with imports and own declarations.sdstest @@ -1,6 +1,6 @@ package tests.scoping.references.acrossFiles.toGlobalFunctions -from safeds.scoping.references.acrossFiles.toGlobalFunctions import myFunction as myOwnFunction +from TTSL.scoping.references.acrossFiles.toGlobalFunctions import myFunction as myOwnFunction from tests.scoping.references.acrossFiles.toGlobalFunctions.other import functionInAnotherPackage, function2InAnotherPackage // $TEST$ target own_myOwnFunction @@ -13,8 +13,8 @@ pipeline myPipeline { // $TEST$ references same_functionInSamePackage »functionInSamePackage«; - // $TEST$ references safeds_functionInSafeDsPackage - »functionInSafeDsPackage«; + // $TEST$ references TTSL_functionInTTSLPackage + »functionInTTSLPackage«; // $TEST$ references other_functionInAnotherPackage »functionInAnotherPackage«; diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with multiple imports of same name.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with multiple imports of same name.sdstest index d19d3dff..d4b849a8 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with multiple imports of same name.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with multiple imports of same name.sdstest @@ -1,10 +1,10 @@ package tests.scoping.references.acrossFiles.toGlobalFunctions -from safeds.scoping.references.acrossFiles.toGlobalFunctions import myFunction +from TTSL.scoping.references.acrossFiles.toGlobalFunctions import myFunction from tests.scoping.references.acrossFiles.toGlobalFunctions.other import myFunction from tests.scoping.references.acrossFiles.toGlobalFunctions import myFunction pipeline myPipeline { - // $TEST$ references safeds_myFunction + // $TEST$ references TTSL_myFunction »myFunction«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with qualified import with alias.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with qualified import with alias.sdstest index fd2a9cb9..4d511506 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with qualified import with alias.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with qualified import with alias.sdstest @@ -1,7 +1,7 @@ package tests.scoping.references.acrossFiles.toGlobalFunctions from tests.scoping.references.acrossFiles.toGlobalFunctions import myFunction as myFunctionInSamePackage -from safeds.scoping.references.acrossFiles.toGlobalFunctions import myFunction as myFunctionInSafeDsPackage +from TTSL.scoping.references.acrossFiles.toGlobalFunctions import myFunction as myFunctionInTTSLPackage from tests.scoping.references.acrossFiles.toGlobalFunctions.other import myFunction as myFunctionInAnotherPackage pipeline myPipeline { @@ -12,8 +12,8 @@ pipeline myPipeline { // $TEST$ references same_functionInSamePackage »functionInSamePackage«; - // $TEST$ references safeds_functionInSafeDsPackage - »functionInSafeDsPackage«; + // $TEST$ references TTSL_functionInTTSLPackage + »functionInTTSLPackage«; // $TEST$ unresolved »functionInAnotherPackage«; @@ -25,8 +25,8 @@ pipeline myPipeline { // $TEST$ references same_myFunction »myFunctionInSamePackage«; - // $TEST$ references safeds_myFunction - »myFunctionInSafeDsPackage«; + // $TEST$ references TTSL_myFunction + »myFunctionInTTSLPackage«; // $TEST$ references other_myFunction »myFunctionInAnotherPackage«; diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with qualified import.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with qualified import.sdstest index 056e08fc..6f2b90c7 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with qualified import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with qualified import.sdstest @@ -1,17 +1,17 @@ package tests.scoping.references.acrossFiles.toGlobalFunctions -from safeds.scoping.references.acrossFiles.toGlobalFunctions import myFunction +from TTSL.scoping.references.acrossFiles.toGlobalFunctions import myFunction from tests.scoping.references.acrossFiles.toGlobalFunctions.other import functionInAnotherPackage, function2InAnotherPackage pipeline myPipeline { - // $TEST$ references safeds_myFunction + // $TEST$ references TTSL_myFunction »myFunction«; // $TEST$ references same_functionInSamePackage »functionInSamePackage«; - // $TEST$ references safeds_functionInSafeDsPackage - »functionInSafeDsPackage«; + // $TEST$ references TTSL_functionInTTSLPackage + »functionInTTSLPackage«; // $TEST$ references other_functionInAnotherPackage »functionInAnotherPackage«; diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with wildcard import.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with wildcard import.sdstest index e152bdc8..30c120dc 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with wildcard import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with wildcard import.sdstest @@ -1,16 +1,16 @@ package tests.scoping.references.acrossFiles.toGlobalFunctions -from safeds.scoping.references.acrossFiles.toGlobalFunctions import * +from TTSL.scoping.references.acrossFiles.toGlobalFunctions import * pipeline myPipeline { - // $TEST$ references safeds_myFunction + // $TEST$ references TTSL_myFunction »myFunction«; // $TEST$ references same_functionInSamePackage »functionInSamePackage«; - // $TEST$ references safeds_functionInSafeDsPackage - »functionInSafeDsPackage«; + // $TEST$ references TTSL_functionInTTSLPackage + »functionInTTSLPackage«; // $TEST$ unresolved »functionInAnotherPackage«; diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/resource safeds package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/resource safeds package.sdstest index 42f3f9bd..bf222062 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/resource safeds package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/resource safeds package.sdstest @@ -1,7 +1,7 @@ -package safeds.scoping.references.acrossFiles.toGlobalFunctions +package TTSL.scoping.references.acrossFiles.toGlobalFunctions -// $TEST$ target safeds_myFunction +// $TEST$ target TTSL_myFunction fun »myFunction«() -// $TEST$ target safeds_functionInSafeDsPackage -fun »functionInSafeDsPackage«() +// $TEST$ target TTSL_functionInTTSLPackage +fun »functionInTTSLPackage«() diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main no imports or own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main no imports or own declarations.sdstest index 2a5d9174..465810e5 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main no imports or own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main no imports or own declarations.sdstest @@ -8,7 +8,7 @@ segment mySegment() { »pipelineInSamePackage«; // $TEST$ unresolved - »pipelineInSafeDsPackage«; + »pipelineInTTSLPackage«; // $TEST$ unresolved »pipelineInAnotherPackage«; diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with imports and own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with imports and own declarations.sdstest index 18d49714..9fe0f1b4 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with imports and own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with imports and own declarations.sdstest @@ -1,6 +1,6 @@ package tests.scoping.references.acrossFiles.toPipelines -from safeds.scoping.references.acrossFiles.toPipelines import myPipeline as myOwnPipeline +from TTSL.scoping.references.acrossFiles.toPipelines import myPipeline as myOwnPipeline from tests.scoping.references.acrossFiles.toPipelines.other import pipelineInAnotherPackage, pipeline2InAnotherPackage // $TEST$ target own_myOwnPipeline @@ -14,7 +14,7 @@ segment mySegment() { »pipelineInSamePackage«; // $TEST$ unresolved - »pipelineInSafeDsPackage«; + »pipelineInTTSLPackage«; // $TEST$ unresolved »pipelineInAnotherPackage«; diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with multiple imports of same name.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with multiple imports of same name.sdstest index 9720b43e..b9bd8012 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with multiple imports of same name.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with multiple imports of same name.sdstest @@ -1,6 +1,6 @@ package tests.scoping.references.acrossFiles.toPipelines -from safeds.scoping.references.acrossFiles.toPipelines import myPipeline +from TTSL.scoping.references.acrossFiles.toPipelines import myPipeline from tests.scoping.references.acrossFiles.toPipelines.other import myPipeline from tests.scoping.references.acrossFiles.toPipelines import myPipeline diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with qualified import with alias.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with qualified import with alias.sdstest index 9f3eb5e3..ef5098d0 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with qualified import with alias.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with qualified import with alias.sdstest @@ -1,7 +1,7 @@ package tests.scoping.references.acrossFiles.toPipelines from tests.scoping.references.acrossFiles.toPipelines import myPipeline as myPipelineInSamePackage -from safeds.scoping.references.acrossFiles.toPipelines import myPipeline as myPipelineInSafeDsPackage +from TTSL.scoping.references.acrossFiles.toPipelines import myPipeline as myPipelineInTTSLPackage from tests.scoping.references.acrossFiles.toPipelines.other import myPipeline as myPipelineInAnotherPackage segment mySegment() { @@ -13,7 +13,7 @@ segment mySegment() { »pipelineInSamePackage«; // $TEST$ unresolved - »pipelineInSafeDsPackage«; + »pipelineInTTSLPackage«; // $TEST$ unresolved »pipelineInAnotherPackage«; @@ -26,7 +26,7 @@ segment mySegment() { »myPipelineInSamePackage«; // $TEST$ unresolved - »myPipelineInSafeDsPackage«; + »myPipelineInTTSLPackage«; // $TEST$ unresolved »myPipelineInAnotherPackage«; diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with qualified import.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with qualified import.sdstest index 5b97bbc9..f3222394 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with qualified import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with qualified import.sdstest @@ -1,6 +1,6 @@ package tests.scoping.references.acrossFiles.toPipelines -from safeds.scoping.references.acrossFiles.toPipelines import myPipeline +from TTSL.scoping.references.acrossFiles.toPipelines import myPipeline from tests.scoping.references.acrossFiles.toPipelines.other import pipelineInAnotherPackage, pipeline2InAnotherPackage segment mySegment() { @@ -11,7 +11,7 @@ segment mySegment() { »pipelineInSamePackage«; // $TEST$ unresolved - »pipelineInSafeDsPackage«; + »pipelineInTTSLPackage«; // $TEST$ unresolved »pipelineInAnotherPackage«; diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with wildcard import.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with wildcard import.sdstest index 8747eb06..d9ca2ec2 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with wildcard import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with wildcard import.sdstest @@ -1,6 +1,6 @@ package tests.scoping.references.acrossFiles.toPipelines -from safeds.scoping.references.acrossFiles.toPipelines import * +from TTSL.scoping.references.acrossFiles.toPipelines import * segment mySegment() { // $TEST$ unresolved @@ -10,7 +10,7 @@ segment mySegment() { »pipelineInSamePackage«; // $TEST$ unresolved - »pipelineInSafeDsPackage«; + »pipelineInTTSLPackage«; // $TEST$ unresolved »pipelineInAnotherPackage«; diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/resource safeds package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/resource safeds package.sdstest index 9f66ceb0..757effe7 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/resource safeds package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/resource safeds package.sdstest @@ -1,7 +1,7 @@ -package safeds.scoping.references.acrossFiles.toPipelines +package TTSL.scoping.references.acrossFiles.toPipelines -// $TEST$ target safeds_myPipeline +// $TEST$ target TTSL_myPipeline pipeline »myPipeline« {} -// $TEST$ target safeds_pipelineInSafeDsPackage -pipeline »pipelineInSafeDsPackage« {} +// $TEST$ target TTSL_pipelineInTTSLPackage +pipeline »pipelineInTTSLPackage« {} diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main no imports or own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main no imports or own declarations.sdstest index 9d84b922..d960668d 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main no imports or own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main no imports or own declarations.sdstest @@ -7,8 +7,8 @@ pipeline myPipeline { // $TEST$ references same_SchemaInSamePackage »SchemaInSamePackage«; - // $TEST$ references safeds_SchemaInSafeDsPackage - »SchemaInSafeDsPackage«; + // $TEST$ references TTSL_SchemaInTTSLPackage + »SchemaInTTSLPackage«; // $TEST$ unresolved »SchemaInAnotherPackage«; diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with imports and own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with imports and own declarations.sdstest index 3aa40542..3e2f7d09 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with imports and own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with imports and own declarations.sdstest @@ -1,6 +1,6 @@ package tests.scoping.references.acrossFiles.toSchemas -from safeds.scoping.references.acrossFiles.toSchemas import MySchema as MyOwnSchema +from TTSL.scoping.references.acrossFiles.toSchemas import MySchema as MyOwnSchema from tests.scoping.references.acrossFiles.toSchemas.other import SchemaInAnotherPackage, Schema2InAnotherPackage // $TEST$ target own_MyOwnSchema @@ -13,8 +13,8 @@ pipeline myPipeline { // $TEST$ references same_SchemaInSamePackage »SchemaInSamePackage«; - // $TEST$ references safeds_SchemaInSafeDsPackage - »SchemaInSafeDsPackage«; + // $TEST$ references TTSL_SchemaInTTSLPackage + »SchemaInTTSLPackage«; // $TEST$ references other_SchemaInAnotherPackage »SchemaInAnotherPackage«; diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with multiple imports of same name.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with multiple imports of same name.sdstest index 1fb7f3e6..acd69095 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with multiple imports of same name.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with multiple imports of same name.sdstest @@ -1,10 +1,10 @@ package tests.scoping.references.acrossFiles.toSchemas -from safeds.scoping.references.acrossFiles.toSchemas import MySchema +from TTSL.scoping.references.acrossFiles.toSchemas import MySchema from tests.scoping.references.acrossFiles.toSchemas.other import MySchema from tests.scoping.references.acrossFiles.toSchemas import MySchema pipeline myPipeline { - // $TEST$ references safeds_MySchema + // $TEST$ references TTSL_MySchema »MySchema«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with qualified import with alias.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with qualified import with alias.sdstest index a4d0ffb9..6cbd4b4f 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with qualified import with alias.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with qualified import with alias.sdstest @@ -1,7 +1,7 @@ package tests.scoping.references.acrossFiles.toSchemas from tests.scoping.references.acrossFiles.toSchemas import MySchema as MySchemaInSamePackage -from safeds.scoping.references.acrossFiles.toSchemas import MySchema as MySchemaInSafeDsPackage +from TTSL.scoping.references.acrossFiles.toSchemas import MySchema as MySchemaInTTSLPackage from tests.scoping.references.acrossFiles.toSchemas.other import MySchema as MySchemaInAnotherPackage pipeline myPipeline { @@ -12,8 +12,8 @@ pipeline myPipeline { // $TEST$ references same_SchemaInSamePackage »SchemaInSamePackage«; - // $TEST$ references safeds_SchemaInSafeDsPackage - »SchemaInSafeDsPackage«; + // $TEST$ references TTSL_SchemaInTTSLPackage + »SchemaInTTSLPackage«; // $TEST$ unresolved »SchemaInAnotherPackage«; @@ -25,8 +25,8 @@ pipeline myPipeline { // $TEST$ references same_MySchema »MySchemaInSamePackage«; - // $TEST$ references safeds_MySchema - »MySchemaInSafeDsPackage«; + // $TEST$ references TTSL_MySchema + »MySchemaInTTSLPackage«; // $TEST$ references other_MySchema »MySchemaInAnotherPackage«; diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with qualified import.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with qualified import.sdstest index 49e62144..c0ef64ec 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with qualified import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with qualified import.sdstest @@ -1,17 +1,17 @@ package tests.scoping.references.acrossFiles.toSchemas -from safeds.scoping.references.acrossFiles.toSchemas import MySchema +from TTSL.scoping.references.acrossFiles.toSchemas import MySchema from tests.scoping.references.acrossFiles.toSchemas.other import SchemaInAnotherPackage, Schema2InAnotherPackage pipeline myPipeline { - // $TEST$ references safeds_MySchema + // $TEST$ references TTSL_MySchema »MySchema«; // $TEST$ references same_SchemaInSamePackage »SchemaInSamePackage«; - // $TEST$ references safeds_SchemaInSafeDsPackage - »SchemaInSafeDsPackage«; + // $TEST$ references TTSL_SchemaInTTSLPackage + »SchemaInTTSLPackage«; // $TEST$ references other_SchemaInAnotherPackage »SchemaInAnotherPackage«; diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with wildcard import.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with wildcard import.sdstest index c7beb819..9e4ad137 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with wildcard import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with wildcard import.sdstest @@ -1,16 +1,16 @@ package tests.scoping.references.acrossFiles.toSchemas -from safeds.scoping.references.acrossFiles.toSchemas import * +from TTSL.scoping.references.acrossFiles.toSchemas import * pipeline myPipeline { - // $TEST$ references safeds_MySchema + // $TEST$ references TTSL_MySchema »MySchema«; // $TEST$ references same_SchemaInSamePackage »SchemaInSamePackage«; - // $TEST$ references safeds_SchemaInSafeDsPackage - »SchemaInSafeDsPackage«; + // $TEST$ references TTSL_SchemaInTTSLPackage + »SchemaInTTSLPackage«; // $TEST$ unresolved »SchemaInAnotherPackage«; diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/resource safeds package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/resource safeds package.sdstest index f8f5a10c..d6dd4db1 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/resource safeds package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/resource safeds package.sdstest @@ -1,7 +1,7 @@ -package safeds.scoping.references.acrossFiles.toSchemas +package TTSL.scoping.references.acrossFiles.toSchemas -// $TEST$ target safeds_MySchema +// $TEST$ target TTSL_MySchema schema »MySchema« {} -// $TEST$ target safeds_SchemaInSafeDsPackage -schema »SchemaInSafeDsPackage« {} +// $TEST$ target TTSL_SchemaInTTSLPackage +schema »SchemaInTTSLPackage« {} diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main no imports or own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main no imports or own declarations.sdstest index 97e096ed..97fdea88 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main no imports or own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main no imports or own declarations.sdstest @@ -15,14 +15,14 @@ pipeline myPipeline { »privateSegmentInSamePackage«; - // $TEST$ references safeds_publicSegmentInSafeDsPackage - »publicSegmentInSafeDsPackage«; + // $TEST$ references TTSL_publicSegmentInTTSLPackage + »publicSegmentInTTSLPackage«; // $TEST$ unresolved - »internalSegmentInSafeDsPackage«; + »internalSegmentInTTSLPackage«; // $TEST$ unresolved - »privateSegmentInSafeDsPackage«; + »privateSegmentInTTSLPackage«; // $TEST$ unresolved diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with imports and own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with imports and own declarations.sdstest index f179230e..0edea8a1 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with imports and own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with imports and own declarations.sdstest @@ -1,6 +1,6 @@ package tests.scoping.references.acrossFiles.toSegments -from safeds.scoping.references.acrossFiles.toSegments import mySegment as myOwnSegment +from TTSL.scoping.references.acrossFiles.toSegments import mySegment as myOwnSegment from tests.scoping.references.acrossFiles.toSegments.other import publicSegmentInAnotherPackage, public2SegmentInAnotherPackage from tests.scoping.references.acrossFiles.toSegments.other import internalSegmentInAnotherPackage from tests.scoping.references.acrossFiles.toSegments.other import privateSegmentInAnotherPackage @@ -23,14 +23,14 @@ pipeline myPipeline { »privateSegmentInSamePackage«; - // $TEST$ references safeds_publicSegmentInSafeDsPackage - »publicSegmentInSafeDsPackage«; + // $TEST$ references TTSL_publicSegmentInTTSLPackage + »publicSegmentInTTSLPackage«; // $TEST$ unresolved - »internalSegmentInSafeDsPackage«; + »internalSegmentInTTSLPackage«; // $TEST$ unresolved - »privateSegmentInSafeDsPackage«; + »privateSegmentInTTSLPackage«; // $TEST$ references other_publicSegmentInAnotherPackage diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with multiple imports of same name.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with multiple imports of same name.sdstest index 3f6a60a0..cdf23c4d 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with multiple imports of same name.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with multiple imports of same name.sdstest @@ -1,10 +1,10 @@ package tests.scoping.references.acrossFiles.toSegments -from safeds.scoping.references.acrossFiles.toSegments import mySegment +from TTSL.scoping.references.acrossFiles.toSegments import mySegment from tests.scoping.references.acrossFiles.toSegments.other import mySegment from tests.scoping.references.acrossFiles.toSegments import mySegment pipeline myPipeline { - // $TEST$ references safeds_mySegment + // $TEST$ references TTSL_mySegment »mySegment«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with qualified import with alias.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with qualified import with alias.sdstest index a82b6d78..f8d07617 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with qualified import with alias.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with qualified import with alias.sdstest @@ -1,7 +1,7 @@ package tests.scoping.references.acrossFiles.toSegments from tests.scoping.references.acrossFiles.toSegments import mySegment as mySegmentInSamePackage -from safeds.scoping.references.acrossFiles.toSegments import mySegment as mySegmentInSafeDsPackage +from TTSL.scoping.references.acrossFiles.toSegments import mySegment as mySegmentInTTSLPackage from tests.scoping.references.acrossFiles.toSegments.other import mySegment as mySegmentInAnotherPackage pipeline myPipeline { @@ -19,14 +19,14 @@ pipeline myPipeline { »privateSegmentInSamePackage«; - // $TEST$ references safeds_publicSegmentInSafeDsPackage - »publicSegmentInSafeDsPackage«; + // $TEST$ references TTSL_publicSegmentInTTSLPackage + »publicSegmentInTTSLPackage«; // $TEST$ unresolved - »internalSegmentInSafeDsPackage«; + »internalSegmentInTTSLPackage«; // $TEST$ unresolved - »privateSegmentInSafeDsPackage«; + »privateSegmentInTTSLPackage«; // $TEST$ unresolved @@ -52,8 +52,8 @@ pipeline myPipeline { // $TEST$ references same_mySegment »mySegmentInSamePackage«; - // $TEST$ references safeds_mySegment - »mySegmentInSafeDsPackage«; + // $TEST$ references TTSL_mySegment + »mySegmentInTTSLPackage«; // $TEST$ references other_mySegment »mySegmentInAnotherPackage«; diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with qualified import.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with qualified import.sdstest index b0a350a4..50b8870f 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with qualified import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with qualified import.sdstest @@ -1,12 +1,12 @@ package tests.scoping.references.acrossFiles.toSegments -from safeds.scoping.references.acrossFiles.toSegments import mySegment +from TTSL.scoping.references.acrossFiles.toSegments import mySegment from tests.scoping.references.acrossFiles.toSegments.other import publicSegmentInAnotherPackage, public2SegmentInAnotherPackage from tests.scoping.references.acrossFiles.toSegments.other import internalSegmentInAnotherPackage from tests.scoping.references.acrossFiles.toSegments.other import privateSegmentInAnotherPackage pipeline myPipeline { - // $TEST$ references safeds_mySegment + // $TEST$ references TTSL_mySegment »mySegment«; @@ -20,14 +20,14 @@ pipeline myPipeline { »privateSegmentInSamePackage«; - // $TEST$ references safeds_publicSegmentInSafeDsPackage - »publicSegmentInSafeDsPackage«; + // $TEST$ references TTSL_publicSegmentInTTSLPackage + »publicSegmentInTTSLPackage«; // $TEST$ unresolved - »internalSegmentInSafeDsPackage«; + »internalSegmentInTTSLPackage«; // $TEST$ unresolved - »privateSegmentInSafeDsPackage«; + »privateSegmentInTTSLPackage«; // $TEST$ references other_publicSegmentInAnotherPackage diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with wildcard import.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with wildcard import.sdstest index 86caa307..654c4a5a 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with wildcard import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with wildcard import.sdstest @@ -1,9 +1,9 @@ package tests.scoping.references.acrossFiles.toSegments -from safeds.scoping.references.acrossFiles.toSegments import * +from TTSL.scoping.references.acrossFiles.toSegments import * pipeline myPipeline { - // $TEST$ references safeds_mySegment + // $TEST$ references TTSL_mySegment »mySegment«; @@ -17,14 +17,14 @@ pipeline myPipeline { »privateSegmentInSamePackage«; - // $TEST$ references safeds_publicSegmentInSafeDsPackage - »publicSegmentInSafeDsPackage«; + // $TEST$ references TTSL_publicSegmentInTTSLPackage + »publicSegmentInTTSLPackage«; // $TEST$ unresolved - »internalSegmentInSafeDsPackage«; + »internalSegmentInTTSLPackage«; // $TEST$ unresolved - »privateSegmentInSafeDsPackage«; + »privateSegmentInTTSLPackage«; // $TEST$ unresolved diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/resource safeds package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/resource safeds package.sdstest index 2f1e577e..c42d4cbe 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/resource safeds package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/resource safeds package.sdstest @@ -1,13 +1,13 @@ -package safeds.scoping.references.acrossFiles.toSegments +package TTSL.scoping.references.acrossFiles.toSegments -// $TEST$ target safeds_mySegment +// $TEST$ target TTSL_mySegment segment »mySegment«() {} -// $TEST$ target safeds_publicSegmentInSafeDsPackage -segment »publicSegmentInSafeDsPackage«() {} +// $TEST$ target TTSL_publicSegmentInTTSLPackage +segment »publicSegmentInTTSLPackage«() {} -// $TEST$ target safeds_internalSegmentInSafeDsPackage -internal segment »internalSegmentInSafeDsPackage«() {} +// $TEST$ target TTSL_internalSegmentInTTSLPackage +internal segment »internalSegmentInTTSLPackage«() {} -// $TEST$ target safeds_privateSegmentInSafeDsPackage -private segment »privateSegmentInSafeDsPackage«() {} +// $TEST$ target TTSL_privateSegmentInTTSLPackage +private segment »privateSegmentInTTSLPackage«() {} diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonModule/error.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonModule/error.sdstest index 97adb358..ae533409 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonModule/error.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonModule/error.sdstest @@ -1,4 +1,4 @@ -// $TEST$ info "The Python module is identical to the Safe-DS package, so the annotation call can be removed." +// $TEST$ info "The Python module is identical to the TTSL package, so the annotation call can be removed." @»PythonModule«("tests.validation.builtins.annotations.pythonModule") package tests.validation.builtins.annotations.pythonModule diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonModule/no annotation.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonModule/no annotation.sdstest index 057e3d85..ad60f338 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonModule/no annotation.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonModule/no annotation.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no info "The Python module is identical to the Safe-DS package, so the annotation call can be removed." +// $TEST$ no info "The Python module is identical to the TTSL package, so the annotation call can be removed." package tests.validation.builtins.annotations.pythonModule diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonModule/no error.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonModule/no error.sdstest index fa3f4fe9..751e6a1f 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonModule/no error.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonModule/no error.sdstest @@ -1,6 +1,6 @@ -// $TEST$ no info "The Python module is identical to the Safe-DS package, so the annotation call can be removed." +// $TEST$ no info "The Python module is identical to the TTSL package, so the annotation call can be removed." @»PythonModule«("tests.validation.builtins.annotations.pythonModule.other") -// $TEST$ no info "The Python module is identical to the Safe-DS package, so the annotation call can be removed." +// $TEST$ no info "The Python module is identical to the TTSL package, so the annotation call can be removed." @»PythonModule«("tests.validation.builtins.annotations.pythonModule") package tests.validation.builtins.annotations.pythonModule diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonName/identical to safe-ds name/main.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonName/identical to safe-ds name/main.sdstest index cae7182c..42ff9d28 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonName/identical to safe-ds name/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonName/identical to safe-ds name/main.sdstest @@ -1,11 +1,11 @@ -package tests.validation.builtins.annotations.pythonName.identicalToSafeDsName +package tests.validation.builtins.annotations.pythonName.identicalToTTSLName -// $TEST$ info "The Python name is identical to the Safe-DS name, so the annotation call can be removed." +// $TEST$ info "The Python name is identical to the TTSL name, so the annotation call can be removed." @»PythonName«("TestClass1") class TestClass1 -// $TEST$ no info "The Python name is identical to the Safe-DS name, so the annotation call can be removed." +// $TEST$ no info "The Python name is identical to the TTSL name, so the annotation call can be removed." @»PythonName«("Test_Class_2") -// $TEST$ no info "The Python name is identical to the Safe-DS name, so the annotation call can be removed." +// $TEST$ no info "The Python name is identical to the TTSL name, so the annotation call can be removed." @»PythonName«("TestClass2") class TestClass2 diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonName/identical to safe-ds name/no annotation.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonName/identical to safe-ds name/no annotation.sdstest index de231603..7fa20f30 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonName/identical to safe-ds name/no annotation.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonName/identical to safe-ds name/no annotation.sdstest @@ -1,4 +1,4 @@ -package tests.validation.builtins.annotations.pythonName.identicalToSafeDsName +package tests.validation.builtins.annotations.pythonName.identicalToTTSLName -// $TEST$ no info "The Python name is identical to the Safe-DS name, so the annotation call can be removed." +// $TEST$ no info "The Python name is identical to the TTSL name, so the annotation call can be removed." class TestClass3 diff --git a/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method should differ from overridden method/safeds lang any.sdstest b/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method should differ from overridden method/safeds lang any.sdstest index 891d2056..2ca1aae9 100644 --- a/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method should differ from overridden method/safeds lang any.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method should differ from overridden method/safeds lang any.sdstest @@ -1,4 +1,4 @@ -package safeds.lang +package TTSL.lang class Any { // $TEST$ no info "Overriding member is identical to overridden member and can be removed." diff --git a/packages/ttsl-lang/tests/resources/validation/names/core names/in safeds lang.sdstest b/packages/ttsl-lang/tests/resources/validation/names/core names/in safeds lang.sdstest index e3a02f0a..da71df08 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/core names/in safeds lang.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/core names/in safeds lang.sdstest @@ -1,4 +1,4 @@ -package safeds.lang +package TTSL.lang // $TEST$ no error "Names of core declarations must not be used for own declarations." annotation »Number« diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/safeds 1.sdstest b/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/safeds 1.sdstest index 605fa9d5..28cbd4b8 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/safeds 1.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/safeds 1.sdstest @@ -1,4 +1,4 @@ -package safeds.lang +package TTSL.lang /* * Declarations that only occur a second time in builtin files should be excluded, so we don't get errors while editing them. diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/safeds 2.sdstest b/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/safeds 2.sdstest index c0f4a34d..5ee81a98 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/safeds 2.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/safeds 2.sdstest @@ -1,4 +1,4 @@ -package safeds.lang.other +package TTSL.lang.other // $TEST$ error "Multiple builtin declarations have the name 'DuplicateAnnotation'." annotation »DuplicateAnnotation« diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/pipe elsewhere.sdspipe b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/pipe elsewhere.sdspipe index f193b218..80242d68 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/pipe elsewhere.sdspipe +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/pipe elsewhere.sdspipe @@ -1,3 +1,3 @@ -// $TEST$ no error "A pipeline file must not be in a 'safeds' package." +// $TEST$ no error "A pipeline file must not be in a 'TTSL' package." -package »tests.validation.other.modules.pipelineFilesMustNotBeInSafedsPackage« +package »tests.validation.other.modules.pipelineFilesMustNotBeInTTSLPackage« diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/pipe in safeds.sdspipe b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/pipe in safeds.sdspipe index 01bbbb02..8a14a9bc 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/pipe in safeds.sdspipe +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/pipe in safeds.sdspipe @@ -1,3 +1,3 @@ -// $TEST$ error "A pipeline file must not be in a 'safeds' package." +// $TEST$ error "A pipeline file must not be in a 'TTSL' package." -package »safeds« +package »TTSL« diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/pipe in subpackage of safeds.sdspipe b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/pipe in subpackage of safeds.sdspipe index 84d64908..e678a22a 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/pipe in subpackage of safeds.sdspipe +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/pipe in subpackage of safeds.sdspipe @@ -1,3 +1,3 @@ -// $TEST$ error "A pipeline file must not be in a 'safeds' package." +// $TEST$ error "A pipeline file must not be in a 'TTSL' package." -package »safeds.validation.other.modules.pipelineFilesMustNotBeInSafedsPackage« +package »TTSL.validation.other.modules.pipelineFilesMustNotBeInTTSLPackage« diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/stub elsewhere.sdsstub b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/stub elsewhere.sdsstub index f193b218..80242d68 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/stub elsewhere.sdsstub +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/stub elsewhere.sdsstub @@ -1,3 +1,3 @@ -// $TEST$ no error "A pipeline file must not be in a 'safeds' package." +// $TEST$ no error "A pipeline file must not be in a 'TTSL' package." -package »tests.validation.other.modules.pipelineFilesMustNotBeInSafedsPackage« +package »tests.validation.other.modules.pipelineFilesMustNotBeInTTSLPackage« diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/stub in safeds.sdsstub b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/stub in safeds.sdsstub index 07eecbb3..b0110830 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/stub in safeds.sdsstub +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/stub in safeds.sdsstub @@ -1,3 +1,3 @@ -// $TEST$ no error "A pipeline file must not be in a 'safeds' package." +// $TEST$ no error "A pipeline file must not be in a 'TTSL' package." -package »safeds« +package »TTSL« diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/stub in subpackage of safeds.sdsstub b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/stub in subpackage of safeds.sdsstub index 0724b7d8..609f3db4 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/stub in subpackage of safeds.sdsstub +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/stub in subpackage of safeds.sdsstub @@ -1,3 +1,3 @@ -// $TEST$ no error "A pipeline file must not be in a 'safeds' package." +// $TEST$ no error "A pipeline file must not be in a 'TTSL' package." -package »safeds.validation.other.modules.pipelineFilesMustNotBeInSafedsPackage« +package »TTSL.validation.other.modules.pipelineFilesMustNotBeInTTSLPackage« diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/test elsewhere.sdstest b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/test elsewhere.sdstest index f193b218..80242d68 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/test elsewhere.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/test elsewhere.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no error "A pipeline file must not be in a 'safeds' package." +// $TEST$ no error "A pipeline file must not be in a 'TTSL' package." -package »tests.validation.other.modules.pipelineFilesMustNotBeInSafedsPackage« +package »tests.validation.other.modules.pipelineFilesMustNotBeInTTSLPackage« diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/test in safeds.sdstest b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/test in safeds.sdstest index 07eecbb3..b0110830 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/test in safeds.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/test in safeds.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no error "A pipeline file must not be in a 'safeds' package." +// $TEST$ no error "A pipeline file must not be in a 'TTSL' package." -package »safeds« +package »TTSL« diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/test in subpackage of safeds.sdstest b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/test in subpackage of safeds.sdstest index 0724b7d8..609f3db4 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/test in subpackage of safeds.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/test in subpackage of safeds.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no error "A pipeline file must not be in a 'safeds' package." +// $TEST$ no error "A pipeline file must not be in a 'TTSL' package." -package »safeds.validation.other.modules.pipelineFilesMustNotBeInSafedsPackage« +package »TTSL.validation.other.modules.pipelineFilesMustNotBeInTTSLPackage« diff --git a/packages/ttsl-vscode/README.md b/packages/ttsl-vscode/README.md index 476b48ee..a57962c9 100644 --- a/packages/ttsl-vscode/README.md +++ b/packages/ttsl-vscode/README.md @@ -1,7 +1,7 @@ -# Safe-DS +# TTSL Safely develop Data Science programs with a statically checked domain specific language (DSL). ## Documentation -You can find the full documentation [here](https://dsl.safeds.com). +You can find the full documentation [here](https://dsl.TTSL.com). diff --git a/packages/ttsl-vscode/package.json b/packages/ttsl-vscode/package.json index cc83d095..b64dfe22 100644 --- a/packages/ttsl-vscode/package.json +++ b/packages/ttsl-vscode/package.json @@ -15,7 +15,7 @@ "programming language", "static checking" ], - "homepage": "https://dsl.safeds.com", + "homepage": "https://dsl.TTSL.com", "bugs": { "url": "https://github.com/SEEDS-Group/TTSL/issues" }, @@ -33,17 +33,17 @@ "galleryBanner": { "color": "#e9eded" }, - "icon": "img/safe-ds_logo_rounded_128x128.png", + "icon": "img/ttsl_logo_rounded_128x128.png", "qna": "https://github.com/SEEDS-Group/TTSL/discussions", "badges": [ { - "url": "https://github.com/Safe-DS/DSL/actions/workflows/main.yml/badge.svg", - "href": "https://github.com/Safe-DS/DSL/actions/workflows/main.yml", + "url": "https://github.com/TTSL/DSL/actions/workflows/main.yml/badge.svg", + "href": "https://github.com/TTSL/DSL/actions/workflows/main.yml", "description": "Main" }, { - "url": "https://codecov.io/gh/Safe-DS/DSL/branch/main/graph/badge.svg?token=ma0ytglhO1", - "href": "https://codecov.io/gh/Safe-DS/DSL", + "url": "https://codecov.io/gh/TTSL/DSL/branch/main/graph/badge.svg?token=ma0ytglhO1", + "href": "https://codecov.io/gh/TTSL/DSL", "description": "codecov" } ], @@ -59,8 +59,8 @@ ], "configuration": "./language-configuration.json", "icon": { - "light": "img/safe-ds_file_icon_light.svg", - "dark": "img/safe-ds_file_icon_dark.svg" + "light": "img/ttsl_file_icon_light.svg", + "dark": "img/ttsl_file_icon_dark.svg" } } ], diff --git a/packages/ttsl-vscode/src/extension/commands/dumpDiagnostics.ts b/packages/ttsl-vscode/src/extension/commands/dumpDiagnostics.ts index b39d89ae..6a56329e 100644 --- a/packages/ttsl-vscode/src/extension/commands/dumpDiagnostics.ts +++ b/packages/ttsl-vscode/src/extension/commands/dumpDiagnostics.ts @@ -6,8 +6,8 @@ export const dumpDiagnostics = (context: ExtensionContext) => async () => { if (!currentDocument) { vscode.window.showErrorMessage('No active document.'); return; - } else if (currentDocument.languageId !== 'safe-ds') { - vscode.window.showErrorMessage('The active document is not a Safe-DS document.'); + } else if (currentDocument.languageId !== 'ttsl') { + vscode.window.showErrorMessage('The active document is not a TTSL document.'); return; } diff --git a/packages/ttsl-vscode/src/extension/mainClient.ts b/packages/ttsl-vscode/src/extension/mainClient.ts index a546933e..e4f7c53b 100644 --- a/packages/ttsl-vscode/src/extension/mainClient.ts +++ b/packages/ttsl-vscode/src/extension/mainClient.ts @@ -2,7 +2,7 @@ import * as path from 'node:path'; import * as vscode from 'vscode'; import type { LanguageClientOptions, ServerOptions } from 'vscode-languageclient/node.js'; import { LanguageClient, TransportKind } from 'vscode-languageclient/node.js'; -import { getSafeDSOutputChannel, initializeLog } from './output.js'; +import { getTTSLOutputChannel, initializeLog } from './output.js'; import { dumpDiagnostics } from './commands/dumpDiagnostics.js'; import { openDiagnosticsDumps } from './commands/openDiagnosticsDumps.js'; @@ -47,16 +47,16 @@ const startLanguageClient = function (context: vscode.ExtensionContext): Languag // Options to control the language client const clientOptions: LanguageClientOptions = { - documentSelector: [{ scheme: 'file', language: 'safe-ds' }], + documentSelector: [{ scheme: 'file', language: 'ttsl' }], synchronize: { // Notify the server about file changes to files contained in the workspace fileEvents: fileSystemWatcher, }, - outputChannel: getSafeDSOutputChannel('[LanguageClient] '), + outputChannel: getTTSLOutputChannel('[LanguageClient] '), }; // Create the language client and start the client. - const result = new LanguageClient('safe-ds', 'Safe-DS', serverOptions, clientOptions); + const result = new LanguageClient('ttsl', 'TTSL', serverOptions, clientOptions); // Start the client. This will also launch the server result.start(); diff --git a/packages/ttsl-vscode/src/extension/output.ts b/packages/ttsl-vscode/src/extension/output.ts index b977f80b..d84b8ff4 100644 --- a/packages/ttsl-vscode/src/extension/output.ts +++ b/packages/ttsl-vscode/src/extension/output.ts @@ -83,7 +83,7 @@ class PrefixedOutputChannel implements vscode.LogOutputChannel { * Initialize the logging system once for the extension. */ export const initializeLog = function () { - logOutputChannel = vscode.window.createOutputChannel('Safe-DS', { log: true }); + logOutputChannel = vscode.window.createOutputChannel('TTSL', { log: true }); logOutputChannel.show(); }; @@ -92,7 +92,7 @@ export const initializeLog = function () { * * @param prefix Prefix to display, or undefined to not display any prefix */ -export const getSafeDSOutputChannel = function (prefix: string | undefined = undefined): vscode.LogOutputChannel { +export const getTTSLOutputChannel = function (prefix: string | undefined = undefined): vscode.LogOutputChannel { return new PrefixedOutputChannel(logOutputChannel!, !prefix ? '' : prefix); }; diff --git a/release.config.cjs b/release.config.cjs index 00fe6ef5..dad78a19 100644 --- a/release.config.cjs +++ b/release.config.cjs @@ -6,7 +6,7 @@ module.exports = { // We don't create a changelog for the CLI, because only few changes in the repo are related to it ['@semantic-release/changelog', { changelogFile: 'packages/ttsl-lang/CHANGELOG.md' }], ['@semantic-release/changelog', { changelogFile: 'packages/ttsl-vscode/CHANGELOG.md' }], - ['@semantic-release/npm', { pkgRoot: 'packages/safe-ds-cli' }], + ['@semantic-release/npm', { pkgRoot: 'packages/ttsl-cli' }], ['@semantic-release/npm', { pkgRoot: 'packages/ttsl-lang' }], [ '@semantic-release/exec', @@ -38,7 +38,7 @@ module.exports = { { assets: [ 'package-lock.json', - 'packages/safe-ds-cli/package.json', + 'packages/ttsl-cli/package.json', 'packages/ttsl-lang/CHANGELOG.md', 'packages/ttsl-lang/package.json', 'packages/ttsl-vscode/CHANGELOG.md', From f12b3f3f8efaf9a8e450a283a5ff6385f2fe1a6f Mon Sep 17 00:00:00 2001 From: methr0 Date: Tue, 2 Jul 2024 14:13:35 +0200 Subject: [PATCH 110/183] fix file generation --- .../ttsl-lang/src/language/generation/ttsl-python-generator.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/ttsl-lang/src/language/generation/ttsl-python-generator.ts b/packages/ttsl-lang/src/language/generation/ttsl-python-generator.ts index cbacbf4f..19cfe34f 100644 --- a/packages/ttsl-lang/src/language/generation/ttsl-python-generator.ts +++ b/packages/ttsl-lang/src/language/generation/ttsl-python-generator.ts @@ -295,7 +295,7 @@ export class TTSLPythonGenerator { const node = document.parseResult.value; // Do not generate stub files - if (isFile(document) || !isTslModule(node)) { + if (!isFile(document) || !isTslModule(node)) { return []; } From 8c4c5829eb8b77c0c1de4a0aa45f42080ebd2c31 Mon Sep 17 00:00:00 2001 From: methr0 Date: Thu, 11 Jul 2024 15:23:47 +0200 Subject: [PATCH 111/183] fix grammar tests --- .../grammar/safe-ds-value-converter.test.ts | 26 +++++++++---------- .../functions/good-annotation call.ttsl | 6 ----- 2 files changed, 13 insertions(+), 19 deletions(-) delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-annotation call.ttsl diff --git a/packages/ttsl-lang/tests/language/grammar/safe-ds-value-converter.test.ts b/packages/ttsl-lang/tests/language/grammar/safe-ds-value-converter.test.ts index 54712141..3e4d63b1 100644 --- a/packages/ttsl-lang/tests/language/grammar/safe-ds-value-converter.test.ts +++ b/packages/ttsl-lang/tests/language/grammar/safe-ds-value-converter.test.ts @@ -3,7 +3,7 @@ import { createTTSLServices } from '../../../src/language/index.js'; import { EmptyFileSystem } from 'langium'; import { getNodeOfType } from '../../helpers/nodeFinder.js'; import { - isTslClass, + isTslFunction, isTslInt, isTslModule, isTslString, @@ -28,18 +28,18 @@ describe('runConverter', () => { it('should remove backticks (declaration)', async () => { const code = ` - class \`MyClass\` + function \`MyFunction\` `; - const firstClass = await getNodeOfType(services, code, isTslClass); - expect(firstClass.name).toBe('MyClass'); + const firstFunction = await getNodeOfType(services, code, isTslFunction); + expect(firstFunction.name).toBe('MyFunction'); }); }); describe('INT', () => { it('should return a bigint', async () => { const code = ` - pipeline myPipeline { + function myFunction() { 123; } `; @@ -123,7 +123,7 @@ describe('runConverter', () => { describe('STRING', () => { it('should remove delimiters', async () => { const code = ` - pipeline myPipeline { + function myFunction() { "text"; } `; @@ -134,7 +134,7 @@ describe('runConverter', () => { it.each(escapeSequences)('should unescape $escaped', async ({ escaped, unescaped }) => { const code = ` - pipeline myPipeline { + function myFunction() { "${escaped}"; } `; @@ -147,7 +147,7 @@ describe('runConverter', () => { describe('TEMPLATE_STRING_START', () => { it('should remove delimiters', async () => { const code = ` - pipeline myPipeline { + function myFunction() { "start{{ 1 }}inner{{ 2 }}end"; } `; @@ -158,7 +158,7 @@ describe('runConverter', () => { it.each(escapeSequences)('should unescape $escaped', async ({ escaped, unescaped }) => { const code = ` - pipeline myPipeline { + function myFunction() { "${escaped}{{ 1 }}inner{{ 2 }}end"; } `; @@ -171,7 +171,7 @@ describe('runConverter', () => { describe('TEMPLATE_STRING_INNER', () => { it('should remove delimiters', async () => { const code = ` - pipeline myPipeline { + function myFunction() { "start{{ 1 }}inner{{ 2 }}end"; } `; @@ -182,7 +182,7 @@ describe('runConverter', () => { it.each(escapeSequences)('should unescape $escaped', async ({ escaped, unescaped }) => { const code = ` - pipeline myPipeline { + function myFunction() { "start{{ 1 }}${escaped}{{ 2 }}end"; } `; @@ -195,7 +195,7 @@ describe('runConverter', () => { describe('TEMPLATE_STRING_END', () => { it('should remove delimiters', async () => { const code = ` - pipeline myPipeline { + function myFunction() { "start{{ 1 }}inner{{ 2 }}end"; } `; @@ -206,7 +206,7 @@ describe('runConverter', () => { it.each(escapeSequences)('should unescape $escaped', async ({ escaped, unescaped }) => { const code = ` - pipeline myPipeline { + function myFunction() { "start{{ 1 }}inner{{ 2 }}${escaped}"; } `; diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-annotation call.ttsl b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-annotation call.ttsl deleted file mode 100644 index 7137f19d..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-annotation call.ttsl +++ /dev/null @@ -1,6 +0,0 @@ -// $TEST$ no_syntax_error - -package test - -@Annotation -function myFunction() {} From e7d615baf988234f0eecc3e658403b80c07940b8 Mon Sep 17 00:00:00 2001 From: methr0 Date: Tue, 16 Jul 2024 08:45:16 +0200 Subject: [PATCH 112/183] add types in grammar definition --- .../src/language/grammar/ttsl.langium | 70 ++++++++++++++----- 1 file changed, 54 insertions(+), 16 deletions(-) diff --git a/packages/ttsl-lang/src/language/grammar/ttsl.langium b/packages/ttsl-lang/src/language/grammar/ttsl.langium index 575cd50f..70757912 100644 --- a/packages/ttsl-lang/src/language/grammar/ttsl.langium +++ b/packages/ttsl-lang/src/language/grammar/ttsl.langium @@ -755,39 +755,77 @@ TslType returns TslType: ; TslPrimaryType returns TslType: - TslCallableType - | 'Int' - | 'Float' - | 'String' - | 'Boolean' + TslIntType + | TslFloatType + | TslStringType + | TslBooleanType | TslDictionaryType | TslListType ; -interface TslCallableType extends TslCallable, TslType { - resultList: TslResultList -} +interface TslIntType extends TslType {} -TslCallableType returns TslCallableType: - parameterList=TslParameterList - resultList=TslResultList +TslIntType returns TslIntType: + {TslIntType} "Int" +; + +interface TslFloatType extends TslType {} + +TslFloatType returns TslFloatType: + {TslFloatType} "Float" +; + +interface TslStringType extends TslType {} + +TslStringType returns TslStringType: + {TslStringType} "String" +; + +interface TslBooleanType extends TslType {} + +TslBooleanType returns TslBooleanType: + {TslBooleanType} "Boolean" ; interface TslDictionaryType extends TslType { - key: TslType - value: TslType + typeParameterList:TslTypeParameterList } TslDictionaryType returns TslDictionaryType: - 'Dict' '<' key=TslType ',' value=TslType '>' + 'Dict' typeParameterList=TslTypeParameterList ; interface TslListType extends TslType { - type: TslType + typeParameterList:TslTypeParameterList } TslListType returns TslListType: - 'List' '<' type=TslType '>' + 'List' typeParameterList=TslTypeParameterList +; + + +interface TslTypeParameterList extends TslObject { + typeParameters: TslTypeParameter[] +} + +TslTypeParameterList returns TslTypeParameterList: + {TslTypeParameterList} + '<' + ( + typeParameters+=TslTypeParameter + (',' typeParameters+=TslTypeParameter)* + ','? + )? + '>' +; + +interface TslTypeParameter extends TslNamedTypeDeclaration { + defaultValue?: TslType +} + +TslTypeParameter returns TslTypeParameter: + name=ID + ('=' defaultValue=TslType)? ; // ----------------------------------------------------------------------------- From 02392c36d15321a26825e2ae3a2a94a7a111a5f5 Mon Sep 17 00:00:00 2001 From: methr0 Date: Tue, 16 Jul 2024 08:47:26 +0200 Subject: [PATCH 113/183] update typechecker to new types --- .../src/language/typing/ttsl-type-checker.ts | 177 +----------------- 1 file changed, 7 insertions(+), 170 deletions(-) diff --git a/packages/ttsl-lang/src/language/typing/ttsl-type-checker.ts b/packages/ttsl-lang/src/language/typing/ttsl-type-checker.ts index f583215a..61e9c5f9 100644 --- a/packages/ttsl-lang/src/language/typing/ttsl-type-checker.ts +++ b/packages/ttsl-lang/src/language/typing/ttsl-type-checker.ts @@ -1,26 +1,13 @@ -import { TslDeclaration } from '../generated/ast.js'; -import { Parameter } from '../helpers/nodeProperties.js'; import { TTSLServices } from '../ttsl-module.js'; import { - CallableType, DictionaryType, ListType, - NamedTupleType, Type, - UnionType, - UnknownType, } from './model.js'; -import { TTSLCoreTypes } from './ttsl-core-types.js'; -import type { TTSLTypeComputer } from './ttsl-type-computer.js'; export class TTSLTypeChecker { - private readonly coreTypes: TTSLCoreTypes; - private readonly typeComputer: () => TTSLTypeComputer; - constructor(services: TTSLServices) { - this.coreTypes = services.types.CoreTypes; - this.typeComputer = () => services.types.TypeComputer; - } + constructor(services: TTSLServices) {} // ----------------------------------------------------------------------------------------------------------------- // General cases @@ -29,116 +16,20 @@ export class TTSLTypeChecker { /** * Checks whether {@link type} is a supertype of {@link other}. */ - isSupertypeOf = (type: Type, other: Type, options: TypeCheckOptions = {}): boolean => { - return this.isSubtypeOf(other, type, options); + isSupertypeOf = (type: Type, other: Type): boolean => { + return this.isSubtypeOf(other, type); }; /** * Checks whether {@link type} is a subtype of {@link other}. */ - isSubtypeOf = (type: Type, other: Type, options: TypeCheckOptions = {}): boolean => { - if (type.equals(this.coreTypes.Nothing) || other.equals(this.coreTypes.AnyOrNull)) { - return true; - } else if (type === UnknownType || other === UnknownType) { - return false; - } - - if (other instanceof UnionType) { - return other.types.some((it) => this.isSubtypeOf(type, it, options)); - } - - if (type instanceof CallableType) { - return this.callableTypeIsSubtypeOf(type, other, options); - } else if (type instanceof NamedTupleType) { - return this.namedTupleTypeIsSubtypeOf(type, other, options); - } else if (type instanceof UnionType) { - return this.unionTypeIsSubtypeOf(type, other, options); - } /* c8 ignore start */ else { - throw new Error(`Unexpected type: ${type.constructor.name}`); - } /* c8 ignore stop */ - }; - - private callableTypeIsSubtypeOf(type: CallableType, other: Type, options: TypeCheckOptions): boolean { - if (other instanceof CallableType) { - // Must accept at least as many parameters and produce at least as many results - if (type.inputType.length < other.inputType.length || type.outputType.length < other.outputType.length) { - return false; - } - - // Check expected parameters - for (let i = 0; i < other.inputType.length; i++) { - const typeEntry = type.inputType.entries[i]!; - const otherEntry = other.inputType.entries[i]!; - - // Names must match - if (typeEntry.name !== otherEntry.name) { - return false; - } - - // Optionality must match (all but required to optional is OK) - if (Parameter.isRequired(typeEntry.declaration) && Parameter.isOptional(otherEntry.declaration)) { - return false; - } - - // Types must be contravariant - if (!this.isSubtypeOf(otherEntry.type, typeEntry.type, options)) { - return false; - } - } - - // Additional parameters must be optional - for (let i = other.inputType.length; i < type.inputType.length; i++) { - const typeEntry = type.inputType.entries[i]!; - if (!Parameter.isOptional(typeEntry.declaration)) { - return false; - } - } - - // Check expected results - for (let i = 0; i < other.outputType.length; i++) { - const typeEntry = type.outputType.entries[i]!; - const otherEntry = other.outputType.entries[i]!; - - // Names must not match since we always fetch results by index - - // Types must be covariant - if (!this.isSubtypeOf(typeEntry.type, otherEntry.type, options)) { - return false; - } - } - - // Additional results are OK - + isSubtypeOf = (type: Type, other: Type): boolean => { + if (type === other) { return true; } else { return false; } - } - - private namedTupleTypeIsSubtypeOf( - type: NamedTupleType, - other: Type, - options: TypeCheckOptions, - ): boolean { - if (other instanceof NamedTupleType) { - return ( - type.length === other.length && - type.entries.every((typeEntry, i) => { - const otherEntry = other.entries[i]!; - // We deliberately ignore the declarations here - return ( - typeEntry.name === otherEntry.name && this.isSubtypeOf(typeEntry.type, otherEntry.type, options) - ); - }) - ); - } else { - return false; - } - } - - private unionTypeIsSubtypeOf(type: UnionType, other: Type, options: TypeCheckOptions): boolean { - return type.types.every((it) => this.isSubtypeOf(it, other, options)); - } + }; // ----------------------------------------------------------------------------------------------------------------- // Special cases @@ -148,21 +39,7 @@ export class TTSLTypeChecker { * Checks whether {@link type} is allowed as the type of the receiver of an indexed access. */ canBeAccessedByIndex = (type: Type): boolean => { - return this.isList(type) || this.isMap(type); - }; - - /** - * Checks whether {@link type} is allowed as the type of the receiver of a call. - */ - canBeCalled = (type: Type): boolean => { - // We must create the non-nullable version since calls can be null-safe - const nonNullableReceiverType = this.typeComputer().computeNonNullableType(type); - - if (nonNullableReceiverType instanceof CallableType) { - return true; - } else { - return false; - } + return type instanceof ListType || type instanceof DictionaryType; }; /** @@ -176,44 +53,4 @@ export class TTSLTypeChecker { return false; } }; - - /** - * Checks whether {@link type} is some kind of list (with any element type). - */ - isList(type: Type): type is ListType { - const listOrNull = this.coreTypes.List(UnknownType).withExplicitNullability(true); - - return ( - !type.equals(this.coreTypes.Nothing) && - !type.equals(this.coreTypes.NothingOrNull) && - this.isSubtypeOf(type, listOrNull, { - ignoreTypeParameters: true, - }) - ); - } - - /** - * Checks whether {@link type} is some kind of map (with any key/value types). - */ - isMap(type: Type): type is DictionaryType { - const mapOrNull = this.coreTypes.Map(UnknownType, UnknownType).withExplicitNullability(true); - - return ( - !type.equals(this.coreTypes.Nothing) && - !type.equals(this.coreTypes.NothingOrNull) && - this.isSubtypeOf(type, mapOrNull, { - ignoreTypeParameters: true, - }) - ); - } -} - -/** - * Options for {@link TTSLTypeChecker.isSubtypeOf} and {@link TTSLTypeChecker.isSupertypeOf}. - */ -interface TypeCheckOptions { - /** - * Whether to ignore type parameters when comparing class types. - */ - ignoreTypeParameters?: boolean; } From 762ad34683f362d7093fdc8fad14229f45eeb8c9 Mon Sep 17 00:00:00 2001 From: methr0 Date: Tue, 16 Jul 2024 08:50:05 +0200 Subject: [PATCH 114/183] update types in type validator --- .../ttsl-lang/src/language/validation/types.ts | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/packages/ttsl-lang/src/language/validation/types.ts b/packages/ttsl-lang/src/language/validation/types.ts index 63eb9b91..5c7bed24 100644 --- a/packages/ttsl-lang/src/language/validation/types.ts +++ b/packages/ttsl-lang/src/language/validation/types.ts @@ -15,7 +15,7 @@ import { } from '../generated/ast.js'; import { getArguments } from '../helpers/nodeProperties.js'; import { TTSLServices } from '../ttsl-module.js'; -import {NamedTupleType, UnknownType } from '../typing/model.js'; +import {DictionaryType, ListType, UnknownType } from '../typing/model.js'; export const CODE_TYPE_CALLABLE_RECEIVER = 'type/callable-receiver'; export const CODE_TYPE_MISMATCH = 'type/mismatch'; @@ -107,7 +107,7 @@ export const indexedAccessIndexMustHaveCorrectType = (services: TTSLServices) => return (node: TslIndexedAccess, accept: ValidationAcceptor): void => { const receiverType = typeComputer.computeType(node.receiver); - if (typeChecker.isList(receiverType)) { + if (receiverType instanceof ListType) { const indexType = typeComputer.computeType(node.index); if (!typeChecker.isSubtypeOf(indexType, coreTypes.Int)) { accept('error', `Expected type '${coreTypes.Int}' but got '${indexType}'.`, { @@ -187,7 +187,7 @@ export const listMustNotContainNamedTuples = (services: TTSLServices) => { return (node: TslList, accept: ValidationAcceptor): void => { for (const element of node.elements) { const elementType = typeComputer.computeType(element); - if (elementType instanceof NamedTupleType) { + if (elementType instanceof ListType) { accept('error', `Cannot add a value of type '${elementType}' to a list.`, { node: element, code: CODE_TYPE_MISMATCH, @@ -203,8 +203,8 @@ export const mapMustNotContainNamedTuples = (services: TTSLServices) => { return (node: TslDictionary, accept: ValidationAcceptor): void => { for (const entry of node.entries) { const keyType = typeComputer.computeType(entry.key); - if (keyType instanceof NamedTupleType) { - accept('error', `Cannot use a value of type '${keyType}' as a map key.`, { + if (keyType instanceof DictionaryType) { + accept('error', `Cannot use a value of type '${keyType}' as a Dictionary key.`, { node: entry, property: 'key', code: CODE_TYPE_MISMATCH, @@ -212,8 +212,8 @@ export const mapMustNotContainNamedTuples = (services: TTSLServices) => { } const valueKey = typeComputer.computeType(entry.value); - if (valueKey instanceof NamedTupleType) { - accept('error', `Cannot use a value of type '${valueKey}' as a map value.`, { + if (keyType instanceof DictionaryType) { + accept('error', `Cannot use a value of type '${valueKey}' as a Dictionary value.`, { node: entry, property: 'value', code: CODE_TYPE_MISMATCH, From f29ae3d3b31882fe171849c72c302c73557cbd03 Mon Sep 17 00:00:00 2001 From: methr0 Date: Tue, 16 Jul 2024 09:20:40 +0200 Subject: [PATCH 115/183] remove callable type in chainedExpression validation --- .../language/validation/other/expressions/chainedExpressions.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/ttsl-lang/src/language/validation/other/expressions/chainedExpressions.ts b/packages/ttsl-lang/src/language/validation/other/expressions/chainedExpressions.ts index 5d6dd530..7e62e3e0 100644 --- a/packages/ttsl-lang/src/language/validation/other/expressions/chainedExpressions.ts +++ b/packages/ttsl-lang/src/language/validation/other/expressions/chainedExpressions.ts @@ -19,7 +19,7 @@ export const chainedExpressionsMustBeNullSafeIfReceiverIsNullable = (services: T return; } - if (isTslCall(node) && typeChecker.canBeCalled(receiverType)) { + if (isTslCall(node)) { accept('error', 'The receiver can be null so a null-safe call must be used.', { node, code: CODE_CHAINED_EXPRESSION_MISSING_NULL_SAFETY, From d8e52c16a755c0d18ac6aea7f82448dfbf5fce6e Mon Sep 17 00:00:00 2001 From: methr0 Date: Tue, 16 Jul 2024 09:22:27 +0200 Subject: [PATCH 116/183] update Types in indexedAccess validation --- .../language/validation/other/expressions/indexedAccess.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/ttsl-lang/src/language/validation/other/expressions/indexedAccess.ts b/packages/ttsl-lang/src/language/validation/other/expressions/indexedAccess.ts index 9dd2a957..43320e5b 100644 --- a/packages/ttsl-lang/src/language/validation/other/expressions/indexedAccess.ts +++ b/packages/ttsl-lang/src/language/validation/other/expressions/indexedAccess.ts @@ -2,12 +2,12 @@ import { TslIndexedAccess } from '../../../generated/ast.js'; import { ValidationAcceptor } from 'langium'; import { TTSLServices } from '../../../ttsl-module.js'; import { EvaluatedList, EvaluatedMap, IntConstant } from '../../../partialEvaluation/model.js'; +import { ListType } from '../../../typing/model.js'; export const CODE_INDEXED_ACCESS_INVALID_INDEX = 'indexed-access/invalid-index'; export const indexedAccessIndexMustBeValid = (services: TTSLServices) => { const partialEvaluator = services.evaluation.PartialEvaluator; - const typeChecker = services.types.TypeChecker; const typeComputer = services.types.TypeComputer; return (node: TslIndexedAccess, accept: ValidationAcceptor): void => { @@ -46,7 +46,7 @@ export const indexedAccessIndexMustBeValid = (services: TTSLServices) => { } const receiverType = typeComputer.computeType(node.receiver); - if (typeChecker.isList(receiverType)) { + if (receiverType instanceof ListType) { if (indexValue.value < 0) { accept('error', `List index '${indexValue}' is out of bounds.`, { node, From 8d4e54812cc6a136d7ea7e408e4079bb59b42535 Mon Sep 17 00:00:00 2001 From: methr0 Date: Tue, 16 Jul 2024 09:23:02 +0200 Subject: [PATCH 117/183] remove CallableType and add TypeParameter function --- .../src/language/helpers/nodeProperties.ts | 40 ++++++++++++------- 1 file changed, 26 insertions(+), 14 deletions(-) diff --git a/packages/ttsl-lang/src/language/helpers/nodeProperties.ts b/packages/ttsl-lang/src/language/helpers/nodeProperties.ts index 827a717c..17ef6e78 100644 --- a/packages/ttsl-lang/src/language/helpers/nodeProperties.ts +++ b/packages/ttsl-lang/src/language/helpers/nodeProperties.ts @@ -3,15 +3,16 @@ import { isTslArgument, isTslArgumentList, isTslAssignment, - isTslCallable, - isTslCallableType, isTslDeclaration, + isTslDictionaryType, isTslFunction, + isTslListType, isTslModule, isTslModuleMember, isTslParameter, isTslPlaceholder, isTslQualifiedImport, + isTslTypeParameterList, TslAbstractCall, TslArgument, TslArgumentList, @@ -20,8 +21,11 @@ import { TslBlock, TslCallable, TslDeclaration, + TslDictionaryType, + TslFunction, TslImport, TslImportedDeclaration, + TslListType, TslModule, TslModuleMember, TslParameter, @@ -29,6 +33,8 @@ import { TslQualifiedImport, TslResult, TslStatement, + TslTypeParameter, + TslTypeParameterList, } from '../generated/ast.js'; // ------------------------------------------------------------------------------------------------- @@ -58,14 +64,6 @@ export namespace Parameter { if (!node) { return false; } - - const containingCallable = AstUtils.getContainerOfType(node, isTslCallable); - - // In those cases, the const modifier is not applicable - if (isTslCallableType(containingCallable)) { - return false; - } - return node.isConstant; }; @@ -82,14 +80,12 @@ export namespace Parameter { // Accessors for list elements // ------------------------------------------------------------------------------------------------- -export const getResults = (node: TslCallable | undefined): TslResult[] => { +export const getResults = (node: TslFunction | undefined): TslResult[] => { if (!node) { return []; } - if (isTslCallableType(node)) { - return node.resultList.results ?? []; - } else if (isTslFunction(node) && node.result) { + if (isTslFunction(node) && node.result) { return [node.result]; }/* c8 ignore start */ else { return []; @@ -163,3 +159,19 @@ export const getPlaceholderByName = (block: TslBlock, name: string | undefined): export const getStatements = (node: TslBlock | undefined): TslStatement[] => { return node?.statements ?? []; }; + +export const getTypeParameters = ( + node: TslTypeParameterList | TslDictionaryType | TslListType | undefined, +): TslTypeParameter[] => { + if (!node) { + return []; + } + + if (isTslTypeParameterList(node)) { + return node.typeParameters; + } else if (isTslDictionaryType(node) || isTslListType(node)) { + return getTypeParameters(node.typeParameterList); + } /* c8 ignore start */ else { + return []; + } /* c8 ignore stop */ +}; \ No newline at end of file From cf7fd6fa109ac6bf29de61059a5ee881e2d8e884 Mon Sep 17 00:00:00 2001 From: alex-senger Date: Wed, 17 Jul 2024 20:22:09 +0200 Subject: [PATCH 118/183] feat: add min and max methods --- src/resources/builtins/math.ttsl | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100644 src/resources/builtins/math.ttsl diff --git a/src/resources/builtins/math.ttsl b/src/resources/builtins/math.ttsl new file mode 100644 index 00000000..ba5a3df0 --- /dev/null +++ b/src/resources/builtins/math.ttsl @@ -0,0 +1,17 @@ +package math + +public function min(a: Float, b: Float): Float { + if(a < b) { + return a; + } else { + return b; + } +} + +public function max(a: Float, b: Float): Float { + if(a > b) { + return a; + } else { + return b; + } +} \ No newline at end of file From 634ac21725453937a494085b597a2dd34bffbc74 Mon Sep 17 00:00:00 2001 From: alex-senger Date: Wed, 17 Jul 2024 20:22:27 +0200 Subject: [PATCH 119/183] fix: umlaute --- .../arbeitslosenversicherung.ttsl" | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git "a/src/resources/builtins/sozialversicherungsBeitr\303\244ge/arbeitslosenversicherung.ttsl" "b/src/resources/builtins/sozialversicherungsBeitr\303\244ge/arbeitslosenversicherung.ttsl" index 717ebabf..0023c87e 100644 --- "a/src/resources/builtins/sozialversicherungsBeitr\303\244ge/arbeitslosenversicherung.ttsl" +++ "b/src/resources/builtins/sozialversicherungsBeitr\303\244ge/arbeitslosenversicherung.ttsl" @@ -38,14 +38,14 @@ private function sozialversicherungsBeitragArbeitnehmerArbeitgeber(): Float per */ public function beitrag(): Float per month { to 2003-03-31 { - if (geringfügigBeschäftigt()) { + if (geringfuegigBeschaeftigt()) { return 0; } else { return gesetzlicheRentenversicherungBetragBruttolohn() per month * beitragssatz[arbeitslosenversicherung]; } } from 2003-04-01 { - if (geringfügigBeschäftigt()) { + if (geringfuegigBeschaeftigt()) { return 0; } @@ -62,7 +62,7 @@ public function beitrag(): Float per month { */ public function beitragArbeitgeber(): Float per month { to 2003-03-31 { - if (geringfügigBeschäftigt()) { + if (geringfuegigBeschaeftigt()) { return 0; } else { return gesetzlicheRentenversicherungBetragBruttolohn() per month * beitragssatz[arbeitslosenversicherung]; @@ -70,7 +70,7 @@ public function beitragArbeitgeber(): Float per month { } from 2003-04-01 { - if (geringfügigBeschäftigt()) { + if (geringfuegigBeschaeftigt()) { return 0; } @@ -78,7 +78,7 @@ public function beitragArbeitgeber(): Float per month { return arbeitslosenversicherungBeitragMidijobArbeitgeber() per month; } - return arbeitslosenversicherungRegulärBeschäftigt() per month; + return arbeitslosenversicherungRegulaerBeschaeftigt() per month; } } From cef0beb1211aa71dac95b32dc97a79c183645174 Mon Sep 17 00:00:00 2001 From: alex-senger Date: Wed, 17 Jul 2024 20:22:46 +0200 Subject: [PATCH 120/183] feat: add gesetzliche Krankenversicherung --- .../gesetzlichekrankenversicherung.ttsl" | 277 ++++++++++++++++++ 1 file changed, 277 insertions(+) create mode 100644 "src/resources/builtins/sozialversicherungsBeitr\303\244ge/gesetzlichekrankenversicherung.ttsl" diff --git "a/src/resources/builtins/sozialversicherungsBeitr\303\244ge/gesetzlichekrankenversicherung.ttsl" "b/src/resources/builtins/sozialversicherungsBeitr\303\244ge/gesetzlichekrankenversicherung.ttsl" new file mode 100644 index 00000000..a71330fc --- /dev/null +++ "b/src/resources/builtins/sozialversicherungsBeitr\303\244ge/gesetzlichekrankenversicherung.ttsl" @@ -0,0 +1,277 @@ +package gesetzlicheKrankenversicherung + +from math import min, max + +/** + * Beitrag fuer die gesetzliche Krankenversicherung. + */ +public function beitrag( + selbststaendig: Boolean +): Float per month { + to 2003-03-31 { + if selbststaendig { + return beitragSelbststaendig() + beitragRente(); + } + if geringfuegigBeschaeftigt { + return 0 + beitragRente(); + } + return beitragRegulaerBeschaeftigt() + beitragRente(); + } + + from 2003-04-01 { + if selbststaendig { + return beitragSelbststaendig() + beitragRente(); + } + if geringfuegigBeschaeftigt { + return 0 + beitragRente(); + } + if inGleitzone { + return beitragMidijobArbeitnehmer() + beitragRente(); + } + return beitragRegulaerBeschaeftigt() + beitragRente(); + } +} + +/** + * Beitrag des Arbeitgebers fuer die gesetzliche Krankenversicherung. + */ +public function beitragArbeitgeber( + geringfuegigBeschaeftigt: Boolean, + selbststaendig: Boolean, + bruttolohn: Float +): Float per month { + to 2003-03-31 { + if selbststaendig { + return 0.0; + } else if geringfuegigBeschaeftigt { + return bruttolohn * sozialversicherungsBeitragsParameter["ag_abgaben_geringfuegig"]["gesetzlicheKrankenversicherung"]; + } else { + return bruttolohnMonatlich() * beitragssatzArbeitgeber(); + } + } + from 2003-04-01 { + if selbststaendig { + return 0.0; + } else if geringfuegigBeschaeftigt { + return bruttolohn * sozialversicherungsBeitragsParameter["ag_abgaben_geringfuegig"]["gesetzlicheKrankenversicherung"]; + } else if inGleitzone { + return beitragMidijobArbeitgeber(); + } else { + return bruttolohnMonatlich() * beitragssatzArbeitgeber(); + } + } +} + +/** + * Zusatzbeitragssatz basierend auf dem Sonderbeitrag bis Dezember 2014 und dem mittleren Zusatzbeitrag seit Januar 2015. + */ +public function zusatzbeitragssatz(): Float per year { + to 2014-12-31 { + return sozialversicherungsBeitragsParameter["beitr_satz"]["gesetzlicheKrankenversicherung"]["sonderbeitrag"]; + } + from 2015-01-01 { + return sozialversicherungsBeitragsParameter["beitr_satz"]["gesetzlicheKrankenversicherung"]["mean_zusatzbeitrag"]; + } +} + +/** + * Beitragssatz fuer die gesetzliche Krankenversicherung, inklusive kassenspezifischer und einheitlicher Zusatzbeitragssaetze. + */ +public function beitragssatz(): Float per month { + to 2005-06-30 { + return sozialversicherungsBeitragsParameter["beitr_satz"]["gesetzlicheKrankenversicherung"]["mean_allgemein"] / 2; + } + from 2005-07-01 to 2008-12-31 { + var meanAllgemein = sozialversicherungsBeitragsParameter["beitr_satz"]["gesetzlicheKrankenversicherung"]["mean_allgemein"]; + return meanAllgemein / 2 + zusatzbeitragssatz(); + } + from 2009-01-01 to 2018-12-31 { + var allgemein = sozialversicherungsBeitragsParameter["beitr_satz"]["gesetzlicheKrankenversicherung"]["allgemein"]; + return allgemein / 2 + zusatzbeitragssatz(); + } + from 2019-01-01 { + var allgemeinerBeitragssatz = sozialversicherungsBeitragsParameter["beitr_satz"]["gesetzlicheKrankenversicherung"]["allgemein"]; + return (allgemeinerBeitragssatz + zusatzbeitragssatz()) / 2; + } +} + +/** + * Beitragssatz fuer die gesetzliche Krankenversicherung am Jahresanfang, inklusive kassenspezifischer und einheitlicher Zusatzbeitragssaetze. + */ +public function beitragssatzJahresanfang(): Float per month { + to 2005-06-30 { + return sozialversicherungsBeitragsParameter["beitr_satz_jahresanfang"]["gesetzlicheKrankenversicherung"]["mean_allgemein"] / 2; + } + from 2005-07-01 to 2008-12-31 { + var meanAllgemein = sozialversicherungsBeitragsParameter["beitr_satz_jahresanfang"]["gesetzlicheKrankenversicherung"]["mean_allgemein"]; + return meanAllgemein / 2 + zusatzbeitragssatz(); + } + from 2009-01-01 to 2018-12-31 { + var allgemein = sozialversicherungsBeitragsParameter["beitr_satz_jahresanfang"]["gesetzlicheKrankenversicherung"]["allgemein"]; + return allgemein / 2 + zusatzbeitragssatz(); + } + from 2019-01-01 { + var allgemeinerBeitragssatz = sozialversicherungsBeitragsParameter["beitr_satz_jahresanfang"]["gesetzlicheKrankenversicherung"]["allgemein"]; + return (allgemeinerBeitragssatz() + zusatzbeitragssatz()) / 2; + } +} + +/** + * Beitragssatz des Arbeitgebers fuer die gesetzliche Krankenversicherung, inklusive kassenspezifischer und einheitlicher Zusatzbeitragssaetze. + */ +public function beitragssatzArbeitgeber(): Float per month { + to 2008-12-31 { + return sozialversicherungsBeitragsParameter["beitr_satz"]["gesetzlicheKrankenversicherung"]["mean_allgemein"] / 2; + } + from 2009-01-01 to 2018-12-31 { + return sozialversicherungsBeitragsParameter["beitr_satz"]["gesetzlicheKrankenversicherung"]["allgemein"] / 2; + } + from 2019-01-01 { + var allgemeinerBeitragssatz = sozialversicherungsBeitragsParameter["beitr_satz"]["gesetzlicheKrankenversicherung"]["allgemein"]; + var zusatzbeitragssatz = sozialversicherungsBeitragsParameter["beitr_satz"]["gesetzlicheKrankenversicherung"]["mean_zusatzbeitrag"]; + return (allgemeinerBeitragssatz + zusatzbeitragssatz) / 2; + } +} + +/** + * Beitragssatz des Arbeitgebers fuer die gesetzliche Krankenversicherung am Jahresanfang, inklusive kassenspezifischer und einheitlicher Zusatzbeitragssaetze. + */ +public function beitragssatzArbeitgeberJahresanfang(): Float per month { + to 2008-12-31 { + return sozialversicherungsBeitragsParameter["beitr_satz_jahresanfang"]["gesetzlicheKrankenversicherung"]["mean_allgemein"] / 2; + } + from 2009-01-01 to 2018-12-31 { + return sozialversicherungsBeitragsParameter["beitr_satz_jahresanfang"]["gesetzlicheKrankenversicherung"]["allgemein"] / 2; + } + from 2019-01-01 { + var allgemeinerBeitragssatz = sozialversicherungsBeitragsParameter["beitr_satz_jahresanfang"]["gesetzlicheKrankenversicherung"]["allgemein"]; + var zusatzbeitragssatz = sozialversicherungsBeitragsParameter["beitr_satz"]["gesetzlicheKrankenversicherung"]["mean_zusatzbeitrag"]; + return (allgemeinerBeitragssatz + zusatzbeitragssatz) / 2; + } +} + +/** + * Bruttolohn fuer regulaer Beschaeftigte, der der gesetzlichen Krankenversicherung unterliegt. + */ +public function bruttolohnRegulaerBeschaeftigt( + bruttolohn: Float +): Float per month { + if bruttolohn > beitragsbemessungsgrenze() { + return beitragsbemessungsgrenze(); + } else { + return bruttolohn; + } +} + +/** + * Bruttolohn, der der gesetzlichen Krankenversicherung unterliegt. + */ +public function bruttolohn( + regulaerBeschaeftigt: Boolean +): Float per month { + if regulaerBeschaeftigt { + return bruttolohnRegulaerBeschaeftigt(); + } else { + return 0.0; + } +} + +/** + * Beitrag fuer regulaer Beschaeftigte. + */ +public function beitragRegulaerBeschaeftigt(): Float per month { + return beitragssatz() * bruttolohn(); +} + +/** + * Bemessungsgrundlage fuer selbststaendiges Einkommen. + */ +public function bemessungsgrundlageSelbststaendig( + einkommenSelbststaendig: Float, + selbststaendig: Boolean, + inPrivaterKrankenversicherung: Boolean, +): Float per month { + if selbststaendig and not inPrivaterKrankenversicherung { + return min( + beitragsbemessungsgrenze(), + max( + bezugsgroesseSelbststaendig() * sozialversicherungsBeitragsParameter["mindestanteil_bezugsgroeße_beitragspflichtiges_einkommen_selbststaendig"], + einkommenSelbststaendig + ) + ); + } else { + return 0.0; + } +} + +/** + * Beitrag fuer selbststaendiges Einkommen. + */ +public function beitragSelbststaendig(): Float per month { + var params = sozialversicherungsBeitragsParameter["beitr_satz"]["gesetzlicheKrankenversicherung"]; + var ermaessigterBeitrag = params["ermaessigt"] if "ermaessigt" in params else params["mean_allgemein"]; + var zusatzbeitrag = params["mean_zusatzbeitrag"] if "mean_zusatzbeitrag" in params else 0.0; + var beitragssatzSelbststaendig = ermaessigterBeitrag + zusatzbeitrag; + return beitragssatzSelbststaendig * bemessungsgrundlageSelbststaendig(); +} + +/** + * Bemessungsgrundlage für Renteneinkommen. + */ +public function bemessungsgrundlageRente(): Float per month { + return min(summeGesetzlicheRentePrivateRente(), beitragsbemessungsgrenze()); +} + +/** + * Beitrag fuer Renteneinkommen. + */ +public function beitragRente(): Float per month { + return beitragssatz() * bemessungsgrundlageRente(); +} + +/** + * Beitrag für Midijobs. + */ +public function beitragMidijobSummeArbeitnehmerArbeitgeber(): Float per month { + from 2003-04-01 { + return (beitragssatz() + beitragssatzArbeitgeber()) * midijobBemessungsentgelt(); + } +} + +/** + * Arbeitgeberanteil für Midijobs. + */ +public function beitragMidijobArbeitgeber( + bruttolohn: Float +): Float per month { + from 2003-04-01 to 2022-09-30 { + if inGleitzone() { + return beitragssatzArbeitgeber() * bruttolohn; + } else { + return 0.0; + } + } + from 2022-10-01 { + if inGleitzone() { + return beitragMidijobSummeArbeitnehmerArbeitgeber() - beitragMidijobArbeitnehmer(); + } else { + return 0.0; + } + } +} + +/** + * Arbeitnehmeranteil für Midijobs. + */ +public function beitragMidijobArbeitnehmer(): Float per month { + from 2003-04-01 to 2022-09-30 { + return beitragMidijobSummeArbeitnehmerArbeitgeber() - beitragMidijobArbeitgeber(); + } + from 2022-10-01 { + if inGleitzone { + return beitragspflichtigesEinkommenArbeitnehmer() * beitragssatz(); + } else { + return 0.0; + } + } +} From 2a90a61a5d4335827f686f397b314b006ce5c938 Mon Sep 17 00:00:00 2001 From: alex-senger Date: Wed, 17 Jul 2024 20:55:30 +0200 Subject: [PATCH 121/183] =?UTF-8?q?umlaute=20and=20=C3=9F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../beitragsbemessungsgrenzen.ttsl" | 8 ++++---- .../einkommensgrenzen.ttsl" | 10 +++++----- .../gesetzlichekrankenversicherung.ttsl" | 10 +++++----- 3 files changed, 14 insertions(+), 14 deletions(-) diff --git "a/src/resources/builtins/sozialversicherungsBeitr\303\244ge/beitragsbemessungsgrenzen.ttsl" "b/src/resources/builtins/sozialversicherungsBeitr\303\244ge/beitragsbemessungsgrenzen.ttsl" index 2e643f44..4e8e986a 100644 --- "a/src/resources/builtins/sozialversicherungsBeitr\303\244ge/beitragsbemessungsgrenzen.ttsl" +++ "b/src/resources/builtins/sozialversicherungsBeitr\303\244ge/beitragsbemessungsgrenzen.ttsl" @@ -1,6 +1,6 @@ package beitragsbemessungsgrenzen -from sozialversicherungsbeitrag import beitragsbemessungsgrenze, monatlicheBezugsgroeße +from sozialversicherungsbeitrag import beitragsbemessungsgrenze, monatlicheBezugsgroesse public function gesetzlicheRentenversicherung(): Float per month { params = beitragsbemessungsgrenze[ges_rentenv]; @@ -20,10 +20,10 @@ public function gesetzlicheKrankenversicherung(): Float per month { } } -public function gesetzlicheKrankenversicherungBezugsgröße(): Float per month { +public function gesetzlicheKrankenversicherungBezugsgroesse(): Float per month { if wohnort_ost() { - return monatlicheBezugsgroeße[ost]; + return monatlicheBezugsgroesse[ost]; } else { - return monatlicheBezugsgroeße[west]; + return monatlicheBezugsgroesse[west]; } } \ No newline at end of file diff --git "a/src/resources/builtins/sozialversicherungsBeitr\303\244ge/einkommensgrenzen.ttsl" "b/src/resources/builtins/sozialversicherungsBeitr\303\244ge/einkommensgrenzen.ttsl" index 1928f08b..cf6686c9 100644 --- "a/src/resources/builtins/sozialversicherungsBeitr\303\244ge/einkommensgrenzen.ttsl" +++ "b/src/resources/builtins/sozialversicherungsBeitr\303\244ge/einkommensgrenzen.ttsl" @@ -34,7 +34,7 @@ public function minijobGrenze(): Float per month { * Marginal employed pay no social insurance contributions. * Legal reference: § 8 Abs. 1 Satz 1 and 2 SGB IV */ -public function geringügigBeschäftigt(bruttolohn per month): Boolean { +public function geringuegigBeschaeftigt(bruttolohn per month): Boolean { return bruttolohn per month <= minijobGrenze() } @@ -46,7 +46,7 @@ public function geringügigBeschäftigt(bruttolohn per month): Boolean { */ public function inGleitzone(bruttolohn per month): Boolean { from 2003-04-01 { - return (bruttolohn per month <= geringfuegigeEinkommensgrenzenMonatlich[midijob]) and (not geringügigBeschäftigt(bruttolohn per month)); + return (bruttolohn per month <= geringfuegigeEinkommensgrenzenMonatlich[midijob]) and (not geringuegigBeschaeftigt(bruttolohn per month)); } } @@ -149,7 +149,7 @@ public function midijobBemessungsgeld(bruttolohn per month): Float per month { from 2003-04-01 { # Now use the factor to calculate the overall bemessungsentgelt var minijob_anteil = midijobFaktorF() * minijobGrenze() - var lohn_über_mini = bruttolohn per month - minijobGrenze() + var lohn_ueber_mini = bruttolohn per month - minijobGrenze() var gewichtete_midijob_rate = ( geringfuegigeEinkommensgrenzenMonatlich[midijob] / ( @@ -165,7 +165,7 @@ public function midijobBemessungsgeld(bruttolohn per month): Float per month { * midijobFaktorF() ) - return minijob_anteil + lohn_über_mini * gewichtete_midijob_rate + return minijob_anteil + lohn_ueber_mini * gewichtete_midijob_rate } /** @@ -206,7 +206,7 @@ private function midijobBeitragspflichtigeEinnahmeArbeitnehmer(bruttolohn per mo } -public function regulärBeschäftigt(bruttolohn per month): Boolean { +public function regulaerBeschaeftigt(bruttolohn per month): Boolean { /** * Regular employment check until March 2003. * Employees earning more than the minijob threshold, are subject to all ordinary diff --git "a/src/resources/builtins/sozialversicherungsBeitr\303\244ge/gesetzlichekrankenversicherung.ttsl" "b/src/resources/builtins/sozialversicherungsBeitr\303\244ge/gesetzlichekrankenversicherung.ttsl" index a71330fc..42913cc3 100644 --- "a/src/resources/builtins/sozialversicherungsBeitr\303\244ge/gesetzlichekrankenversicherung.ttsl" +++ "b/src/resources/builtins/sozialversicherungsBeitr\303\244ge/gesetzlichekrankenversicherung.ttsl" @@ -195,7 +195,7 @@ public function bemessungsgrundlageSelbststaendig( return min( beitragsbemessungsgrenze(), max( - bezugsgroesseSelbststaendig() * sozialversicherungsBeitragsParameter["mindestanteil_bezugsgroeße_beitragspflichtiges_einkommen_selbststaendig"], + bezugsgroesseSelbststaendig() * sozialversicherungsBeitragsParameter["mindestanteil_bezugsgroesse_beitragspflichtiges_einkommen_selbststaendig"], einkommenSelbststaendig ) ); @@ -216,7 +216,7 @@ public function beitragSelbststaendig(): Float per month { } /** - * Bemessungsgrundlage für Renteneinkommen. + * Bemessungsgrundlage fuer Renteneinkommen. */ public function bemessungsgrundlageRente(): Float per month { return min(summeGesetzlicheRentePrivateRente(), beitragsbemessungsgrenze()); @@ -230,7 +230,7 @@ public function beitragRente(): Float per month { } /** - * Beitrag für Midijobs. + * Beitrag fuer Midijobs. */ public function beitragMidijobSummeArbeitnehmerArbeitgeber(): Float per month { from 2003-04-01 { @@ -239,7 +239,7 @@ public function beitragMidijobSummeArbeitnehmerArbeitgeber(): Float per month { } /** - * Arbeitgeberanteil für Midijobs. + * Arbeitgeberanteil fuer Midijobs. */ public function beitragMidijobArbeitgeber( bruttolohn: Float @@ -261,7 +261,7 @@ public function beitragMidijobArbeitgeber( } /** - * Arbeitnehmeranteil für Midijobs. + * Arbeitnehmeranteil fuer Midijobs. */ public function beitragMidijobArbeitnehmer(): Float per month { from 2003-04-01 to 2022-09-30 { From 457b957e785fbdccaeb986497e6c7aafd3944404 Mon Sep 17 00:00:00 2001 From: alex-senger Date: Thu, 18 Jul 2024 10:07:27 +0200 Subject: [PATCH 122/183] fix: imports --- .../gesetzlichekrankenversicherung.ttsl" | 31 ++++++++++--------- 1 file changed, 16 insertions(+), 15 deletions(-) diff --git "a/src/resources/builtins/sozialversicherungsBeitr\303\244ge/gesetzlichekrankenversicherung.ttsl" "b/src/resources/builtins/sozialversicherungsBeitr\303\244ge/gesetzlichekrankenversicherung.ttsl" index 42913cc3..d4545375 100644 --- "a/src/resources/builtins/sozialversicherungsBeitr\303\244ge/gesetzlichekrankenversicherung.ttsl" +++ "b/src/resources/builtins/sozialversicherungsBeitr\303\244ge/gesetzlichekrankenversicherung.ttsl" @@ -1,5 +1,6 @@ package gesetzlicheKrankenversicherung +from sozialversicherungsBeitragsParameter import pauschalabgabenGeringfuegigeBeschaeftigung, beitragssatz, mindestanteilBezugsgroesseBeitragspflichtigeEinnahmeSelbst from math import min, max /** @@ -44,7 +45,7 @@ public function beitragArbeitgeber( if selbststaendig { return 0.0; } else if geringfuegigBeschaeftigt { - return bruttolohn * sozialversicherungsBeitragsParameter["ag_abgaben_geringfuegig"]["gesetzlicheKrankenversicherung"]; + return bruttolohn * pauschalabgabenGeringfuegigeBeschaeftigung["ges_krankenv"]; } else { return bruttolohnMonatlich() * beitragssatzArbeitgeber(); } @@ -53,7 +54,7 @@ public function beitragArbeitgeber( if selbststaendig { return 0.0; } else if geringfuegigBeschaeftigt { - return bruttolohn * sozialversicherungsBeitragsParameter["ag_abgaben_geringfuegig"]["gesetzlicheKrankenversicherung"]; + return bruttolohn * pauschalabgabenGeringfuegigeBeschaeftigung["ges_krankenv"]; } else if inGleitzone { return beitragMidijobArbeitgeber(); } else { @@ -67,10 +68,10 @@ public function beitragArbeitgeber( */ public function zusatzbeitragssatz(): Float per year { to 2014-12-31 { - return sozialversicherungsBeitragsParameter["beitr_satz"]["gesetzlicheKrankenversicherung"]["sonderbeitrag"]; + return beitragssatz["gesetzlicheKrankenversicherung"]["sonderbeitrag"]; } from 2015-01-01 { - return sozialversicherungsBeitragsParameter["beitr_satz"]["gesetzlicheKrankenversicherung"]["mean_zusatzbeitrag"]; + return beitragssatz["gesetzlicheKrankenversicherung"]["mean_zusatzbeitrag"]; } } @@ -79,18 +80,18 @@ public function zusatzbeitragssatz(): Float per year { */ public function beitragssatz(): Float per month { to 2005-06-30 { - return sozialversicherungsBeitragsParameter["beitr_satz"]["gesetzlicheKrankenversicherung"]["mean_allgemein"] / 2; + return beitragssatz["gesetzlicheKrankenversicherung"]["mean_allgemein"] / 2; } from 2005-07-01 to 2008-12-31 { - var meanAllgemein = sozialversicherungsBeitragsParameter["beitr_satz"]["gesetzlicheKrankenversicherung"]["mean_allgemein"]; + var meanAllgemein = beitragssatz["gesetzlicheKrankenversicherung"]["mean_allgemein"]; return meanAllgemein / 2 + zusatzbeitragssatz(); } from 2009-01-01 to 2018-12-31 { - var allgemein = sozialversicherungsBeitragsParameter["beitr_satz"]["gesetzlicheKrankenversicherung"]["allgemein"]; + var allgemein = beitragssatz["gesetzlicheKrankenversicherung"]["allgemein"]; return allgemein / 2 + zusatzbeitragssatz(); } from 2019-01-01 { - var allgemeinerBeitragssatz = sozialversicherungsBeitragsParameter["beitr_satz"]["gesetzlicheKrankenversicherung"]["allgemein"]; + var allgemeinerBeitragssatz = beitragssatz["gesetzlicheKrankenversicherung"]["allgemein"]; return (allgemeinerBeitragssatz + zusatzbeitragssatz()) / 2; } } @@ -121,14 +122,14 @@ public function beitragssatzJahresanfang(): Float per month { */ public function beitragssatzArbeitgeber(): Float per month { to 2008-12-31 { - return sozialversicherungsBeitragsParameter["beitr_satz"]["gesetzlicheKrankenversicherung"]["mean_allgemein"] / 2; + return beitragssatz["gesetzlicheKrankenversicherung"]["mean_allgemein"] / 2; } from 2009-01-01 to 2018-12-31 { - return sozialversicherungsBeitragsParameter["beitr_satz"]["gesetzlicheKrankenversicherung"]["allgemein"] / 2; + return beitragssatz["gesetzlicheKrankenversicherung"]["allgemein"] / 2; } from 2019-01-01 { - var allgemeinerBeitragssatz = sozialversicherungsBeitragsParameter["beitr_satz"]["gesetzlicheKrankenversicherung"]["allgemein"]; - var zusatzbeitragssatz = sozialversicherungsBeitragsParameter["beitr_satz"]["gesetzlicheKrankenversicherung"]["mean_zusatzbeitrag"]; + var allgemeinerBeitragssatz = beitragssatz["gesetzlicheKrankenversicherung"]["allgemein"]; + var zusatzbeitragssatz = beitragssatz["gesetzlicheKrankenversicherung"]["mean_zusatzbeitrag"]; return (allgemeinerBeitragssatz + zusatzbeitragssatz) / 2; } } @@ -145,7 +146,7 @@ public function beitragssatzArbeitgeberJahresanfang(): Float per month { } from 2019-01-01 { var allgemeinerBeitragssatz = sozialversicherungsBeitragsParameter["beitr_satz_jahresanfang"]["gesetzlicheKrankenversicherung"]["allgemein"]; - var zusatzbeitragssatz = sozialversicherungsBeitragsParameter["beitr_satz"]["gesetzlicheKrankenversicherung"]["mean_zusatzbeitrag"]; + var zusatzbeitragssatz = beitragssatz["gesetzlicheKrankenversicherung"]["mean_zusatzbeitrag"]; return (allgemeinerBeitragssatz + zusatzbeitragssatz) / 2; } } @@ -195,7 +196,7 @@ public function bemessungsgrundlageSelbststaendig( return min( beitragsbemessungsgrenze(), max( - bezugsgroesseSelbststaendig() * sozialversicherungsBeitragsParameter["mindestanteil_bezugsgroesse_beitragspflichtiges_einkommen_selbststaendig"], + bezugsgroesseSelbststaendig() * mindestanteilBezugsgroesseBeitragspflichtigeEinnahmeSelbst, einkommenSelbststaendig ) ); @@ -208,7 +209,7 @@ public function bemessungsgrundlageSelbststaendig( * Beitrag fuer selbststaendiges Einkommen. */ public function beitragSelbststaendig(): Float per month { - var params = sozialversicherungsBeitragsParameter["beitr_satz"]["gesetzlicheKrankenversicherung"]; + var params = beitragssatz["gesetzlicheKrankenversicherung"]; var ermaessigterBeitrag = params["ermaessigt"] if "ermaessigt" in params else params["mean_allgemein"]; var zusatzbeitrag = params["mean_zusatzbeitrag"] if "mean_zusatzbeitrag" in params else 0.0; var beitragssatzSelbststaendig = ermaessigterBeitrag + zusatzbeitrag; From 7a77d30dcca645ec09e45449c63d5bec658c3f68 Mon Sep 17 00:00:00 2001 From: alex-senger Date: Thu, 18 Jul 2024 10:08:04 +0200 Subject: [PATCH 123/183] feat: add gesetzliche Pflegeversicherung --- .../gesetzlichepflegeversicherung.ttsl" | 192 ++++++++++++++++++ 1 file changed, 192 insertions(+) create mode 100644 "src/resources/builtins/sozialversicherungsBeitr\303\244ge/gesetzlichepflegeversicherung.ttsl" diff --git "a/src/resources/builtins/sozialversicherungsBeitr\303\244ge/gesetzlichepflegeversicherung.ttsl" "b/src/resources/builtins/sozialversicherungsBeitr\303\244ge/gesetzlichepflegeversicherung.ttsl" new file mode 100644 index 00000000..75f655a8 --- /dev/null +++ "b/src/resources/builtins/sozialversicherungsBeitr\303\244ge/gesetzlichepflegeversicherung.ttsl" @@ -0,0 +1,192 @@ +package gesetzlichePflegeversicherung + +from sozialversicherungsBeitragsParameter import beitragssatz, mindestalterBeitragszuschlagKinderlose + +/** + * Zusaetzlicher Beitrag fuer Kinderlose ab 2005. + */ +public function zusatzbeitragKinderlos( + hatKinder: Boolean, + alter: Int +): Boolean { + from 2005-01-01 { + var mindestalter = mindestalterBeitragszuschlagKinderlose; + return (not hatKinder) or alter >= mindestalter; + } +} + +/** + * Beitragssatz fuer die gesetzliche Pflegeversicherung. + */ +public function beitragssatz( + anzEigeneKinderBis24: Int +): Float per year { + from 1995-01-01 to 2004-12-31 { + return beitragssatz["ges_pflegev"]; + } + from 2005-01-01 to 2023-06-30 { + var out = beitragssatz["ges_pflegev"]["standard"]; + if zusatzbeitragKinderlos { + out += beitragssatz["ges_pflegev"]["zusatz_kinderlos"]; + } + return out; + } + from 2023-07-01 { + var out = beitragssatz["ges_pflegev"]["standard"]; + if zusatzbeitragKinderlos { + out += beitragssatz["ges_pflegev"]["zusatz_kinderlos"]; + } + if anzEigeneKinderBis24 >= 2 { + out -= beitragssatz["ges_pflegev"]["abschlag_kinder"] * min(anzEigeneKinderBis24 - 1, 4); + } + return out; + } +} + +/** + * Beitrag fuer die gesetzliche Pflegeversicherung bis Maerz 2003. + */ +public function beitrag( + selbststaendig: Boolean +): Float per month { + to 2003-03-31 { + if selbststaendig { + return beitragSelbststaendig() + beitragRente(); + } + if geringfuegigBeschaeftigt { + return 0 + beitragRente(); + } + return beitragRegulaerBeschaeftigt() + beitragRente(); + } + from 2003-04-01 { + if selbststaendig { + return beitragSelbststaendig() + beitragRente(); + } + if geringfuegigBeschaeftigt { + return 0 + beitragRente(); + } + if inGleitzone { + return beitragMidijobArbeitnehmer() + beitragRente(); + } + return beitragRegulaerBeschaeftigt() + beitragRente(); + } +} + +/** + * Beitrag fuer regulaer Beschaeftigte in der gesetzlichen Pflegeversicherung. + */ +public function beitragRegulaerBeschaeftigt(): Float per month { + var beitrRegulaerBeschaeftigt = gesetzlicheKrankenversicherung.bruttolohn() * beitragssatz(); + return beitrRegulaerBeschaeftigt; +} + +/** + * Beitrag des Arbeitgebers fuer die gesetzliche Pflegeversicherung bis Maerz 2003. + */ +public function beitragArbeitgeber( + selbststaendig: Boolean +): Float per month { + to 2003-03-31 { + if selbststaendig or geringfuegigBeschaeftigt { + return 0.0; + } else { + return bruttolohn * beitragssatz["ges_pflegev"]; + } + } + from 2003-04-01 { + if selbststaendig or geringfuegigBeschaeftigt { + return 0.0; + } else if inGleitzone { + return beitragMidijobArbeitgeber; + } else { + return bruttolohn * beitragssatz["ges_pflegev"]["standard"]; + } + } +} + +/** + * Beitragssatz fuer selbststaendige bis Maerz 2003. + */ +public function beitragSelbststaendig(): Float per month { + from 1995-01-01 to 2004-12-31 { + return bemessungsgrundlageSelbststaendig() * beitragssatz["ges_pflegev"] * 2; + } + from 2005-01-01 { + return bemessungsgrundlageSelbststaendig() * (beitragssatz() + beitragssatz["ges_pflegev"]["standard"]); + } +} + +/** + * Beitrag fuer Renteneinkommen in der gesetzlichen Pflegeversicherung. + */ +public function beitragRente(): Float per month { + to 2004-03-31 { + return bemessungsgrundlageRente() * beitragssatz(); + } + from 2004-04-01 to 2004-12-31 { + return bemessungsgrundlageRente() * (beitragssatz() * 2); + } + from 2005-01-01 { + return bemessungsgrundlageRente() * ( + beitragssatz() + beitragssatz["ges_pflegev"]["standard"] + ); + } +} + +/** + * Beitrag fuer Midijobs. + */ +public function beitragMidijobSummeArbeitnehmerArbeitgeber(): Float per month { + from 2003-04-01 to 2004-12-31 { + return midijobBemessungsentgelt() * (beitragssatz() + beitragssatz["ges_pflegev"]); + } + from 2005-01-01 { + return midijobBemessungsentgelt() * (beitragssatz() + beitragssatz["ges_pflegev"]["standard"]); + } +} + +/** + * Arbeitgeberanteil fuer Midijobs bis Dezember 2004. + */ +public function beitragMidijobArbeitgeber( + bruttolohn: Float +): Float per month { + to 2004-12-31 { + return bruttolohn * beitragssatz["ges_pflegev"]; + } + from 2005-01-01 to 2022-09-30 { + return bruttolohn * beitragssatz["ges_pflegev"]["standard"]; + } + from 2022-10-01 { + return beitragMidijobSummeArbeitnehmerArbeitgeber() - beitragMidijobArbeitnehmer(); + } +} + +/** + * Arbeitnehmeranteil fuer Midijobs in der gesetzlichen Pflegeversicherung. + */ +public function beitragMidijobArbeitnehmer( + anzEigeneKinderBis24: Int +): Float per month { + from 2003-04-01 to 2022-09-30 { + return beitragMidijobSummeArbeitnehmerArbeitgeber() - beitragMidijobArbeitgeber(); + } + from 2022-10-01 to 2023-06-30 { + var anBeitragMidijob = beitragspflichtigesEinkommenArbeitnehmer() * beitragssatz["ges_pflegev"]["standard"]; + if gesPflegevZusatzKinderlos { + anBeitragMidijob += midijobBemessungsentgelt() * beitragssatz["ges_pflegev"]["zusatz_kinderlos"]; + } + return anBeitragMidijob; + } + from 2023-07-01 { + var pflegevRate = beitragssatz["ges_pflegev"]["standard"]; + if anzEigeneKinderBis24 >= 2 { + pflegevRate -= beitragssatz["ges_pflegev"]["abschlag_kinder"] * min(anzEigeneKinderBis24 - 1, 4); + } + var anBeitragMidijob = beitragspflichtigesEinkommenArbeitnehmer() * pflegevRate; + if gesPflegevZusatzKinderlos { + anBeitragMidijob += midijobBemessungsentgelt() * beitragssatz["ges_pflegev"]["zusatz_kinderlos"]; + } + return anBeitragMidijob; + } +} \ No newline at end of file From bdf81ba63cdfe5b333226f7e8a2e60199021f081 Mon Sep 17 00:00:00 2001 From: methr0 Date: Mon, 22 Jul 2024 15:29:42 +0200 Subject: [PATCH 124/183] add TypeParameters --- packages/ttsl-lang/src/language/grammar/ttsl.langium | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/packages/ttsl-lang/src/language/grammar/ttsl.langium b/packages/ttsl-lang/src/language/grammar/ttsl.langium index 70757912..f3c15778 100644 --- a/packages/ttsl-lang/src/language/grammar/ttsl.langium +++ b/packages/ttsl-lang/src/language/grammar/ttsl.langium @@ -819,13 +819,12 @@ TslTypeParameterList returns TslTypeParameterList: '>' ; -interface TslTypeParameter extends TslNamedTypeDeclaration { - defaultValue?: TslType +interface TslTypeParameter extends TslType { + type: TslType } TslTypeParameter returns TslTypeParameter: - name=ID - ('=' defaultValue=TslType)? + type=TslType ; // ----------------------------------------------------------------------------- From c781dddf55eb158b4e6abc4be7fd6a4cb1c98dce Mon Sep 17 00:00:00 2001 From: methr0 Date: Mon, 22 Jul 2024 15:36:04 +0200 Subject: [PATCH 125/183] remove coreTypes and add new Types --- .../lsp/ttsl-signature-help-provider.ts | 7 +- .../ttsl-lang/src/language/ttsl-module.ts | 6 - .../ttsl-lang/src/language/typing/model.ts | 525 +++++------------- .../src/language/typing/ttsl-core-types.ts | 94 ---- .../src/language/typing/ttsl-type-checker.ts | 8 + .../src/language/typing/ttsl-type-computer.ts | 173 ++---- .../src/language/typing/ttsl-type-factory.ts | 53 -- .../src/language/validation/names.ts | 6 - .../other/expressions/infixOperations.ts | 7 +- .../validation/other/types/callableTypes.ts | 61 -- .../src/language/validation/style.ts | 2 +- .../src/language/validation/ttsl-validator.ts | 12 - .../src/language/validation/types.ts | 39 +- 13 files changed, 230 insertions(+), 763 deletions(-) delete mode 100644 packages/ttsl-lang/src/language/typing/ttsl-core-types.ts delete mode 100644 packages/ttsl-lang/src/language/typing/ttsl-type-factory.ts delete mode 100644 packages/ttsl-lang/src/language/validation/other/types/callableTypes.ts diff --git a/packages/ttsl-lang/src/language/lsp/ttsl-signature-help-provider.ts b/packages/ttsl-lang/src/language/lsp/ttsl-signature-help-provider.ts index 30d8ff88..bb61001f 100644 --- a/packages/ttsl-lang/src/language/lsp/ttsl-signature-help-provider.ts +++ b/packages/ttsl-lang/src/language/lsp/ttsl-signature-help-provider.ts @@ -20,7 +20,6 @@ import { getParameters, Parameter } from '../helpers/nodeProperties.js'; import { type TTSLNodeMapper } from '../helpers/ttsl-node-mapper.js'; import type { TTSLServices } from '../ttsl-module.js'; import { type TTSLTypeComputer } from '../typing/ttsl-type-computer.js'; -import { CallableType } from '../typing/model.js'; import { SignatureHelpProvider } from 'langium/lsp'; export class TTSLSignatureHelpProvider implements SignatureHelpProvider { @@ -90,11 +89,7 @@ export class TTSLSignatureHelpProvider implements SignatureHelpProvider { private getLabel(callable: TslCallable): string { const type = this.typeComputer.computeType(callable); - if (type instanceof CallableType && isNamed(callable)) { - return `${callable.name}${type}`; - } else { - return type.toString(); - } + return type.toString(); } private getParameterInformation = (parameter: TslParameter) => { diff --git a/packages/ttsl-lang/src/language/ttsl-module.ts b/packages/ttsl-lang/src/language/ttsl-module.ts index 876543d1..686d42fb 100644 --- a/packages/ttsl-lang/src/language/ttsl-module.ts +++ b/packages/ttsl-lang/src/language/ttsl-module.ts @@ -25,7 +25,6 @@ import { TTSLSignatureHelpProvider } from './lsp/ttsl-signature-help-provider.js import { TTSLPartialEvaluator } from './partialEvaluation/ttsl-partial-evaluator.js'; import { TTSLScopeComputation } from './scoping/ttsl-scope-computation.js'; import { TTSLScopeProvider } from './scoping/ttsl-scope-provider.js'; -import { TTSLCoreTypes } from './typing/ttsl-core-types.js'; import { TTSLTypeChecker } from './typing/ttsl-type-checker.js'; import { TTSLTypeComputer } from './typing/ttsl-type-computer.js'; import { registerValidationChecks } from './validation/ttsl-validator.js'; @@ -34,7 +33,6 @@ import { TTSLPackageManager } from './workspace/ttsl-package-manager.js'; import { TTSLWorkspaceManager } from './workspace/ttsl-workspace-manager.js'; import { TTSLSettingsProvider } from './workspace/ttsl-settings-provider.js'; import { TTSLRenameProvider } from './lsp/ttsl-rename-provider.js'; -import { TTSLTypeFactory } from './typing/ttsl-type-factory.js'; import { TTSLFunction } from './builtins/ttsl-ds-functions.js'; /** @@ -60,10 +58,8 @@ export type TTSLAddedServices = { NodeInfoProvider: TTSLNodeInfoProvider; }; types: { - CoreTypes: TTSLCoreTypes; TypeChecker: TTSLTypeChecker; TypeComputer: TTSLTypeComputer; - TypeFactory: TTSLTypeFactory; }; workspace: { PackageManager: TTSLPackageManager; @@ -120,10 +116,8 @@ export const TTSLModule: Module new TTSLScopeProvider(services), }, types: { - CoreTypes: (services) => new TTSLCoreTypes(services), TypeChecker: (services) => new TTSLTypeChecker(services), TypeComputer: (services) => new TTSLTypeComputer(services), - TypeFactory: (services) => new TTSLTypeFactory(services), }, workspace: { PackageManager: (services) => new TTSLPackageManager(services), diff --git a/packages/ttsl-lang/src/language/typing/model.ts b/packages/ttsl-lang/src/language/typing/model.ts index cc525cfd..89bcd4e2 100644 --- a/packages/ttsl-lang/src/language/typing/model.ts +++ b/packages/ttsl-lang/src/language/typing/model.ts @@ -1,20 +1,18 @@ +import { AstNode, stream } from 'langium'; import { isEmpty } from '../../helpers/collections.js'; import { - TslCallable, - TslDeclaration, - TslDictionary, - TslList, - TslParameter, - TslResult, + TslBooleanType, + TslDictionaryType, + TslFloatType, + TslIntType, + TslListType, + TslStringType, + TslType, + TslTypeParameter, } from '../generated/ast.js'; -import { Parameter } from '../helpers/nodeProperties.js'; -import { TTSLServices } from '../ttsl-module.js'; -import { TTSLCoreTypes } from './ttsl-core-types.js'; -import { TTSLTypeChecker } from './ttsl-type-checker.js'; -import { TTSLTypeComputer } from './ttsl-type-computer.js'; -import { TTSLTypeFactory } from './ttsl-type-factory.js'; +import { getTypeParameters } from '../helpers/nodeProperties.js'; -export type ParameterSubstitutions = Map; +export type TypeParameterSubstitutions =Type[]; /** * The type of an AST node. @@ -42,17 +40,10 @@ export abstract class Type { */ abstract toString(): string; - /** - * Returns an equivalent type that is simplified as much as possible. Types computed by - * {@link TypeComputer.computeType} are already simplified, so this method is mainly useful for types that are - * constructed or modified manually. - */ - abstract simplify(): Type; - /** * Returns a copy of this type with the given type parameters substituted. */ - abstract substituteTypeParameters(substitutions: ParameterSubstitutions): Type; + abstract substituteTypeParameters(substitutions: TypeParameterSubstitutions): Type; /** * Returns a copy of this type with the given nullability. @@ -60,489 +51,269 @@ export abstract class Type { abstract withExplicitNullability(isExplicitlyNullable: boolean): Type; } -export class CallableType extends Type { - private readonly factory: TTSLTypeFactory; - - override isExplicitlyNullable: boolean = false; - +export class AnyType extends Type { constructor( - services: TTSLServices, - readonly callable: TslCallable, - readonly parameter: TslParameter | undefined, - readonly inputType: NamedTupleType, - readonly outputType: NamedTupleType, + override readonly isExplicitlyNullable: boolean, ) { super(); - - this.factory = services.types.TypeFactory; } override get isFullySubstituted(): boolean { - return this.inputType.isFullySubstituted && this.outputType.isFullySubstituted; - } - - /** - * Returns the type of the parameter at the given index. If the index is out of bounds, returns `undefined`. - */ - getParameterTypeByIndex(index: number): Type { - return this.inputType.getTypeOfEntryByIndex(index); + return true; } override equals(other: unknown): boolean { if (other === this) { return true; - } else if (!(other instanceof CallableType)) { + } else { return false; } - - return ( - other.callable === this.callable && - other.parameter === this.parameter && - other.inputType.equals(this.inputType) && - other.outputType.equals(this.outputType) - ); } override toString(): string { - const inputTypeString = this.inputType.entries - .map((it) => `${it.name}${Parameter.isOptional(it.declaration) ? '?' : ''}: ${it.type}`) - .join(', '); + let result = 'Any'; + + if (this.isExplicitlyNullable) { + result += '?'; + } - return `(${inputTypeString}) -> ${this.outputType}`; + return result; } - override simplify(): CallableType { - return this.factory.createCallableType( - this.callable, - this.parameter, - this.factory.createNamedTupleType(...this.inputType.entries.map((it) => it.simplify())), - this.factory.createNamedTupleType(...this.outputType.entries.map((it) => it.simplify())), - ); + override substituteTypeParameters(substitutions: TypeParameterSubstitutions): AnyType { + return this; } - override substituteTypeParameters(substitutions: ParameterSubstitutions): CallableType { - if (isEmpty(substitutions) || this.isFullySubstituted) { + override withExplicitNullability(isExplicitlyNullable: boolean): AnyType { + if (this.isExplicitlyNullable === isExplicitlyNullable) { return this; } - return this.factory.createCallableType( - this.callable, - this.parameter, - this.inputType.substituteTypeParameters(substitutions), - this.outputType.substituteTypeParameters(substitutions), - ); - } - - override withExplicitNullability(isExplicitlyNullable: boolean): Type { - return this; + return new AnyType(isExplicitlyNullable); } } -export class NamedTupleType extends Type { - private readonly factory: TTSLTypeFactory; - - readonly entries: NamedTupleEntry[]; - override readonly isExplicitlyNullable = false; - private _isFullySubstituted: boolean | undefined; - - constructor(services: TTSLServices, entries: NamedTupleEntry[]) { - super(); - - this.factory = services.types.TypeFactory; - this.entries = entries; +export class IntType extends AnyType { + constructor( + override readonly isExplicitlyNullable: boolean, + ) { + super(isExplicitlyNullable); } - override get isFullySubstituted(): boolean { - if (this._isFullySubstituted === undefined) { - this._isFullySubstituted = this.entries.every((it) => it.type.isFullySubstituted); + override toString(): string { + let result = 'Int'; + + if (this.isExplicitlyNullable) { + result += '?'; } - return this._isFullySubstituted; + return result; } +} - /** - * The length of this tuple. - */ - get length(): number { - return this.entries.length; +export class FloatType extends AnyType { + constructor( + override readonly isExplicitlyNullable: boolean, + ) { + super(isExplicitlyNullable); } - /** - * Returns the type of the entry at the given index. If the index is out of bounds, returns `undefined`. - */ - getTypeOfEntryByIndex(index: number): Type { - return this.entries[index]?.type ?? UnknownType; - } + override toString(): string { + let result = 'Float'; - override equals(other: unknown): boolean { - if (other === this) { - return true; - } else if (!(other instanceof NamedTupleType)) { - return false; + if (this.isExplicitlyNullable) { + result += '?'; } - return ( - this.entries.length === other.entries.length && - this.entries.every((entry, i) => entry.equals(other.entries[i])) - ); + return result; } +} - override toString(): string { - return `(${this.entries.join(', ')})`; +export class StringType extends AnyType { + constructor( + override readonly isExplicitlyNullable: boolean, + ) { + super(isExplicitlyNullable); } - /** - * If this only has one entry, returns its type. Otherwise, returns this. - */ - override simplify(): Type { - if (this.entries.length === 1) { - return this.entries[0]!.type.simplify(); - } - - return this.factory.createNamedTupleType(...this.entries.map((it) => it.simplify())); - } + override toString(): string { + let result = 'String'; - override substituteTypeParameters(substitutions: ParameterSubstitutions): NamedTupleType { - if (isEmpty(substitutions) || this.isFullySubstituted) { - return this; + if (this.isExplicitlyNullable) { + result += '?'; } - return this.factory.createNamedTupleType( - ...this.entries.map((it) => it.substituteTypeParameters(substitutions)), - ); - } - - override withExplicitNullability(isExplicitlyNullable: boolean): Type { - return this; + return result; } } -export class NamedTupleEntry { +export class BooleanType extends AnyType { constructor( - readonly declaration: T | undefined, - readonly name: string, - readonly type: Type, - ) {} - - equals(other: unknown): boolean { - /* c8 ignore start */ - if (other === this) { - return true; - } else if (!(other instanceof NamedTupleEntry)) { - return false; - } - /* c8 ignore stop */ - - return this.declaration === other.declaration && this.name === other.name && this.type.equals(other.type); + override readonly isExplicitlyNullable: boolean, + ) { + super(isExplicitlyNullable); } - toString(): string { - return `${this.name}: ${this.type}`; - } + override toString(): string { + let result = 'Boolean'; - substituteTypeParameters(substitutions: ParameterSubstitutions): NamedTupleEntry { - if (isEmpty(substitutions) || this.type.isFullySubstituted) { - /* c8 ignore next 2 */ - return this; + if (this.isExplicitlyNullable) { + result += '?'; } - return new NamedTupleEntry(this.declaration, this.name, this.type.substituteTypeParameters(substitutions)); - } - - simplify(): NamedTupleEntry { - return new NamedTupleEntry(this.declaration, this.name, this.type.simplify()); + return result; } } -export class UnionType extends Type { - private readonly coreTypes: TTSLCoreTypes; - private readonly factory: TTSLTypeFactory; - private readonly typeChecker: TTSLTypeChecker; - - readonly types: Type[]; - private _isExplicitlyNullable: boolean | undefined; +export class DictionaryType extends AnyType { private _isFullySubstituted: boolean | undefined; - constructor(services: TTSLServices, types: Type[]) { - super(); - - this.coreTypes = services.types.CoreTypes; - this.factory = services.types.TypeFactory; - this.typeChecker = services.types.TypeChecker; - - this.types = types; - } - - override get isExplicitlyNullable(): boolean { - if (this._isExplicitlyNullable === undefined) { - this._isExplicitlyNullable = this.types.some((it) => it.isExplicitlyNullable); - } - - return this._isExplicitlyNullable; + constructor( + readonly substitutions: TypeParameterSubstitutions, + override readonly isExplicitlyNullable: boolean, + ) { + super(isExplicitlyNullable); } override get isFullySubstituted(): boolean { if (this._isFullySubstituted === undefined) { - this._isFullySubstituted = this.types.every((it) => it.isFullySubstituted); + this._isFullySubstituted = stream(this.substitutions.values()).every((it) => it.isFullySubstituted); } return this._isFullySubstituted; } - override equals(other: unknown): boolean { - if (other === this) { - return true; - } else if (!(other instanceof UnionType)) { - return false; - } - - return this.types.length === other.types.length && this.types.every((type, i) => type.equals(other.types[i])); + getTypeParameterTypeByIndex(index: number): Type { + return Array.from(this.substitutions.values())[index] ?? UnknownType; } override toString(): string { - return `union<${this.types.join(', ')}>`; - } + let result = 'Dictionary'; - override simplify(): Type { - // Handle empty union types - if (isEmpty(this.types)) { - return this.coreTypes.Nothing; + if (this.substitutions.length > 0) { + result += `<${Array.from(this.substitutions.values()) + .map((value) => value.toString()) + .join(', ')}>`; } - // Flatten nested unions - const newTypes = this.types.flatMap((type) => { - const unwrappedType = type.simplify(); - if (unwrappedType instanceof UnionType) { - return unwrappedType.types; - } else { - return unwrappedType; - } - }); - - // Merge literal types and remove types that are subtypes of others. We do this back-to-front to keep the first - // occurrence of duplicate types. It's also makes splicing easier. - for (let i = newTypes.length - 1; i >= 0; i--) { - const currentType = newTypes[i]!; - const currentTypeIsNothingOrNull = currentType.equals(this.coreTypes.NothingOrNull); - - for (let j = newTypes.length - 1; j >= 0; j--) { - if (i === j) { - continue; - } - - const otherType = newTypes[j]!; - - // Remove identical types - if (currentType.equals(otherType)) { - // Remove the current type - newTypes.splice(i, 1); - break; - } - - // Don't merge `Nothing?` into callable types, named tuple types or static types, since that would - // create another union type. - if ( - currentTypeIsNothingOrNull && - (otherType instanceof CallableType || - otherType instanceof NamedTupleType) - ) { - continue; - } - - - // Remove subtypes of other types - const candidateType = otherType.withExplicitNullability( - currentType.isExplicitlyNullable || otherType.isExplicitlyNullable, - ); - if (this.typeChecker.isSupertypeOf(candidateType, currentType)) { - // Replace the other type with the candidate type (updated nullability) - newTypes.splice(j, 1, candidateType); - // Remove the current type - newTypes.splice(i, 1); - break; - } - } + if (this.isExplicitlyNullable) { + result += '?'; } - if (newTypes.length === 1) { - return newTypes[0]!; - } else { - return this.factory.createUnionType(newTypes); - } - } - - override substituteTypeParameters(_substitutions: ParameterSubstitutions): Type { - return this; + return result; } - override withExplicitNullability(_isExplicitlyNullable: boolean): Type { - return this; - } -} - -class UnknownTypeClass extends Type { - override readonly isExplicitlyNullable = false; - override readonly isFullySubstituted = true; - - override equals(other: unknown): boolean { - return other instanceof UnknownTypeClass; - } + override substituteTypeParameters(substitutions: TypeParameterSubstitutions): DictionaryType { + if (isEmpty(substitutions) || this.isFullySubstituted) { + return this; + } - override toString(): string { - return '$unknown'; - } + const newSubstitutions = substitutions; - override simplify(): Type { - return this; + return new DictionaryType(newSubstitutions, this.isExplicitlyNullable); } - override substituteTypeParameters(_substitutions: ParameterSubstitutions): Type { - return this; - } + override withExplicitNullability(isExplicitlyNullable: boolean): DictionaryType { + if (this.isExplicitlyNullable === isExplicitlyNullable) { + return this; + } - override withExplicitNullability(_isExplicitlyNullable: boolean): Type { - return this; + return new DictionaryType(this.substitutions, isExplicitlyNullable); } } -export class DictionaryType extends Type { - private readonly factory: TTSLTypeFactory; - override readonly isFullySubstituted = true; - private readonly typeComputer: TTSLTypeComputer; - - override isExplicitlyNullable: boolean = false; +export class ListType extends AnyType{ + private _isFullySubstituted: boolean | undefined; constructor( - services: TTSLServices, - readonly dictionary: TslDictionary + readonly substitutions: TypeParameterSubstitutions, + override readonly isExplicitlyNullable: boolean, ) { - super(); - - this.factory = services.types.TypeFactory; - this.typeComputer = services.types.TypeComputer; + super(isExplicitlyNullable); } - /** - * Returns the type of the parameter at the given index. If the index is out of bounds, returns `undefined`. - */ - getKeyTypeByIndex(index: number): Type { - let entryAtIndex = this.dictionary.entries.at(index) - - return this.typeComputer.computeType(entryAtIndex?.key); - } + override get isFullySubstituted(): boolean { + if (this._isFullySubstituted === undefined) { + this._isFullySubstituted = stream(this.substitutions.values()).every((it) => it.isFullySubstituted); + } - getValueTypeByIndex(index: number): Type { - let entryAtIndex = this.dictionary.entries.at(index) - - return this.typeComputer.computeType(entryAtIndex?.value); + return this._isFullySubstituted; } - override equals(other: unknown): boolean { - if (other === this) { - return true; - } else if (!(other instanceof DictionaryType)) { - return false; - } - - return ( - other.dictionary === this.dictionary - ); + getTypeParameterTypeByIndex(index: number): Type { + return Array.from(this.substitutions.values())[index] ?? UnknownType; } override toString(): string { - const entries = this.dictionary.entries - .map((it) => `{${it.key}:${it.value}}`) - .join(', '); + let result = 'List'; - return `[${entries}]`; - } + if (this.substitutions.length > 0) { + result += `<${Array.from(this.substitutions.values()) + .map((value) => value.toString()) + .join(', ')}>`; + } - override simplify(): DictionaryType { - return this.factory.createDictionaryType( - this.dictionary - ); + if (this.isExplicitlyNullable) { + result += '?'; + } + + return result; } - override substituteTypeParameters(substitutions: ParameterSubstitutions): DictionaryType { + override substituteTypeParameters(substitutions: TypeParameterSubstitutions): ListType { if (isEmpty(substitutions) || this.isFullySubstituted) { return this; } - return this.factory.createDictionaryType( - this.dictionary - ); + const newSubstitutions = substitutions; + + return new ListType(newSubstitutions, this.isExplicitlyNullable); } - override withExplicitNullability(isExplicitlyNullable: boolean): Type { - return this; + override withExplicitNullability(isExplicitlyNullable: boolean): ListType { + if (this.isExplicitlyNullable === isExplicitlyNullable) { + return this; + } + + return new ListType(this.substitutions, isExplicitlyNullable); } } -export class ListType extends Type { - private readonly factory: TTSLTypeFactory; - override readonly isFullySubstituted = true; - private readonly typeComputer: TTSLTypeComputer; - - override isExplicitlyNullable: boolean = false; - +export class NothingType extends AnyType{ constructor( - services: TTSLServices, - readonly list: TslList + override readonly isExplicitlyNullable: boolean, ) { - super(); - - this.factory = services.types.TypeFactory; - this.typeComputer = services.types.TypeComputer; + super(isExplicitlyNullable); } - /** - * Returns the type of the parameter at the given index. If the index is out of bounds, returns `undefined`. - */ - getValueTypeByIndex(index: number): Type { - let entryAtIndex = this.list.elements.at(index) - - return this.typeComputer.computeType(entryAtIndex); - } + override toString(): string { + let result = 'Nothing'; - override equals(other: unknown): boolean { - if (other === this) { - return true; - } else if (!(other instanceof ListType)) { - return false; + if (this.isExplicitlyNullable) { + result += '?'; } - return ( - other.list === this.list - ); + return result; } +} - override toString(): string { - const entries = this.list.elements - .map((it) => `${it}`) - .join(', '); +class UnknownTypeClass extends AnyType { - return `[${entries}]`; + override equals(other: unknown): boolean { + return other instanceof UnknownTypeClass; } - override simplify(): ListType { - return this.factory.createListType( - this.list - ); + override toString(): string { + return '$unknown'; } - override substituteTypeParameters(substitutions: ParameterSubstitutions): ListType { - if (isEmpty(substitutions) || this.isFullySubstituted) { - return this; - } - - return this.factory.createListType( - this.list - ); + override substituteTypeParameters(_substitutions: TypeParameterSubstitutions): Type { + return this; } - override withExplicitNullability(isExplicitlyNullable: boolean): Type { + override withExplicitNullability(_isExplicitlyNullable: boolean): Type { return this; } } -export const UnknownType = new UnknownTypeClass(); +export const UnknownType = new UnknownTypeClass(false); diff --git a/packages/ttsl-lang/src/language/typing/ttsl-core-types.ts b/packages/ttsl-lang/src/language/typing/ttsl-core-types.ts deleted file mode 100644 index a894ce56..00000000 --- a/packages/ttsl-lang/src/language/typing/ttsl-core-types.ts +++ /dev/null @@ -1,94 +0,0 @@ -import { WorkspaceCache } from 'langium'; -import { TTSLClasses } from '../builtins/ttsl-classes.js'; -import { TslClass } from '../generated/ast.js'; -import { TTSLServices } from '../ttsl-module.js'; -import { ClassType, Type, TypeParameterSubstitutions, UnknownType } from './model.js'; -import { getTypeParameters } from '../helpers/nodeProperties.js'; - -export class TTSLCoreTypes { - private readonly builtinClasses: TTSLClasses; - private readonly cache: WorkspaceCache; - - constructor(services: TTSLServices) { - this.builtinClasses = services.builtins.Classes; - this.cache = new WorkspaceCache(services.shared); - } - - get Any(): Type { - return this.createCoreType(this.builtinClasses.Any, false); - } - - get AnyOrNull(): Type { - return this.createCoreType(this.builtinClasses.Any, true); - } - - get Boolean(): Type { - return this.createCoreType(this.builtinClasses.Boolean); - } - - get Float(): Type { - return this.createCoreType(this.builtinClasses.Float); - } - - get Int(): Type { - return this.createCoreType(this.builtinClasses.Int); - } - - List(elementType: Type): Type { - const list = this.builtinClasses.List; - const elementTypeParameter = getTypeParameters(list)[0]; - - if (!list || !elementTypeParameter) { - /* c8 ignore next 2 */ - return UnknownType; - } - - let substitutions = new Map([[elementTypeParameter, elementType]]); - return new ClassType(list, substitutions, false); - } - - Map(keyType: Type, valueType: Type): Type { - const map = this.builtinClasses.Map; - const keyTypeParameter = getTypeParameters(map)[0]; - const valueTypeParameter = getTypeParameters(map)[1]; - - if (!map || !keyTypeParameter || !valueTypeParameter) { - /* c8 ignore next 2 */ - return UnknownType; - } - - const substitutions = new Map([ - [keyTypeParameter, keyType], - [valueTypeParameter, valueType], - ]); - return new ClassType(map, substitutions, false); - } - - get Nothing(): Type { - return this.createCoreType(this.builtinClasses.Nothing, false); - } - - get NothingOrNull(): Type { - return this.createCoreType(this.builtinClasses.Nothing, true); - } - - get Number(): Type { - return this.createCoreType(this.builtinClasses.Number); - } - - get String(): Type { - return this.createCoreType(this.builtinClasses.String); - } - - private createCoreType(coreClass: TslClass | undefined, isNullable: boolean = false): Type { - if (!coreClass) { - /* c8 ignore next 2 */ - return UnknownType; - } - - const key = `${coreClass.name}~${isNullable}`; - return this.cache.get(key, () => new ClassType(coreClass, NO_SUBSTITUTIONS, isNullable)); - } -} - -const NO_SUBSTITUTIONS: TypeParameterSubstitutions = new Map(); diff --git a/packages/ttsl-lang/src/language/typing/ttsl-type-checker.ts b/packages/ttsl-lang/src/language/typing/ttsl-type-checker.ts index 61e9c5f9..3d723258 100644 --- a/packages/ttsl-lang/src/language/typing/ttsl-type-checker.ts +++ b/packages/ttsl-lang/src/language/typing/ttsl-type-checker.ts @@ -1,5 +1,6 @@ import { TTSLServices } from '../ttsl-module.js'; import { + AnyType, DictionaryType, ListType, Type, @@ -53,4 +54,11 @@ export class TTSLTypeChecker { return false; } }; + + /** + * Checks whether {@link type} is allowed as the type of a constant parameter. + */ + canBeTypeOfConstantParameter = (type: Type): boolean => { + return type instanceof AnyType + }; } diff --git a/packages/ttsl-lang/src/language/typing/ttsl-type-computer.ts b/packages/ttsl-lang/src/language/typing/ttsl-type-computer.ts index ec3247cc..3c5b2ec2 100644 --- a/packages/ttsl-lang/src/language/typing/ttsl-type-computer.ts +++ b/packages/ttsl-lang/src/language/typing/ttsl-type-computer.ts @@ -4,7 +4,6 @@ import { isTslAssignee, isTslAssignment, isTslCall, - isTslCallableType, isTslDeclaration, isTslExpression, isTslFunction, @@ -21,7 +20,6 @@ import { isTslTypeCast, TslAssignee, TslCall, - TslCallableType, TslDeclaration, TslExpression, TslFunction, @@ -31,46 +29,34 @@ import { TslPrefixOperation, TslReference, TslType, - TslResult, + isTslIntType, + isTslFloatType, + isTslStringType, + isTslBooleanType, } from '../generated/ast.js'; -import { - getParameters, - getResults, -} from '../helpers/nodeProperties.js'; -import { - BooleanConstant, - Constant, - FloatConstant, - IntConstant, - NullConstant, - StringConstant, -} from '../partialEvaluation/model.js'; import { TTSLServices } from '../ttsl-module.js'; import { - CallableType, - NamedTupleEntry, - NamedTupleType, Type, DictionaryType, ListType, UnknownType, + BooleanType, + IntType, + FloatType, + StringType, + NothingType, + AnyType, } from './model.js'; -import { TTSLCoreTypes } from './ttsl-core-types.js'; import type { TTSLTypeChecker } from './ttsl-type-checker.js'; -import { TTSLTypeFactory } from './ttsl-type-factory.js'; export class TTSLTypeComputer { private readonly astNodeLocator: AstNodeLocator; - private readonly coreTypes: TTSLCoreTypes; - private readonly factory: TTSLTypeFactory; private readonly typeChecker: TTSLTypeChecker; private readonly nodeTypeCache: WorkspaceCache; constructor(services: TTSLServices) { this.astNodeLocator = services.workspace.AstNodeLocator; - this.coreTypes = services.types.CoreTypes; - this.factory = services.types.TypeFactory; this.typeChecker = services.types.TypeChecker; this.nodeTypeCache = new WorkspaceCache(services.shared); @@ -91,7 +77,7 @@ export class TTSLTypeComputer { // Ignore type parameter substitutions for caching const unsubstitutedType = this.nodeTypeCache.get(this.getNodeId(node), () => - this.doComputeType(node).simplify(), + this.doComputeType(node), ); return unsubstitutedType; } @@ -125,9 +111,7 @@ export class TTSLTypeComputer { const assigneePosition = node.$containerIndex ?? -1; const expressionType = this.computeType(containingAssignment?.expression); - if (expressionType instanceof NamedTupleType) { - return expressionType.getTypeOfEntryByIndex(assigneePosition); - } else if (assigneePosition === 0) { + if (assigneePosition === 0) { return expressionType; } @@ -146,40 +130,18 @@ export class TTSLTypeComputer { } /* c8 ignore stop */ } - private computeTypeOfCallableWithManifestTypes(node: TslFunction | TslCallableType): Type { - const parameterEntries = getParameters(node).map( - (it) => new NamedTupleEntry(it, it.name, this.computeType(it.type)), - ); - let resultEntries: NamedTupleEntry[] = [] + private computeTypeOfCallableWithManifestTypes(node: TslFunction ): Type { if(isTslFunction(node)){ - resultEntries.with(0, new NamedTupleEntry(node.result, node.name, this.computeType(node.result?.type))) + return this.computeType(node.result?.type); }else{ - resultEntries = getResults(node).map( - (it) => new NamedTupleEntry(it, it.name, this.computeType(it.type)), - ); + return UnknownType; } - - - return this.factory.createCallableType( - node, - undefined, - this.factory.createNamedTupleType(...parameterEntries), - this.factory.createNamedTupleType(...resultEntries), - ); } private computeTypeOfParameter(node: TslParameter): Type { // Manifest type const type = this.computeType(node.type); - return this.rememberParameterInCallableType(node, type); - } - - private rememberParameterInCallableType(node: TslParameter, type: Type) { - if (type instanceof CallableType) { - return this.factory.createCallableType(type.callable, node, type.inputType, type.outputType); - } else { - return type; - } + return type; } private computeTypeOfExpression(node: TslExpression): Type { @@ -191,14 +153,14 @@ export class TTSLTypeComputer { // Terminal cases if (isTslList(node)) { const elementType = this.lowestCommonSupertype(node.elements.map((it) => this.computeType(it))); - return this.coreTypes.List(elementType); + return new ListType([elementType], false); } else if (isTslDictionary(node)) { let keyType = this.lowestCommonSupertype(node.entries.map((it) => this.computeType(it.key))); const valueType = this.lowestCommonSupertype(node.entries.map((it) => this.computeType(it.value))); - return this.coreTypes.Map(keyType, valueType); + return new DictionaryType([keyType, valueType], false); } else if (isTslTemplateString(node)) { - return this.coreTypes.String; + return new StringType(false); } // Recursive cases @@ -213,21 +175,21 @@ export class TTSLTypeComputer { // Boolean operators case 'or': case 'and': - return this.coreTypes.Boolean; + return new BooleanType(false); // Equality operators case '==': case '!=': case '===': case '!==': - return this.coreTypes.Boolean; + return new BooleanType(false); // Comparison operators case '<': case '<=': case '>=': case '>': - return this.coreTypes.Boolean; + return new BooleanType(false); // Arithmetic operators case '+': @@ -248,14 +210,14 @@ export class TTSLTypeComputer { } else if (isTslPrefixOperation(node)) { switch (node.operator) { case 'not': - return this.coreTypes.Boolean; + return new BooleanType(false); case '-': return this.computeTypeOfArithmeticPrefixOperation(node); // Unknown operator /* c8 ignore next 2 */ default: - return UnknownType; + return UnknownType; } } else if (isTslReference(node)) { return this.computeTypeOfReference(node); @@ -269,13 +231,8 @@ export class TTSLTypeComputer { const nonNullableReceiverType = this.computeNonNullableType(receiverType); let result: Type = UnknownType; - if (nonNullableReceiverType instanceof CallableType) { - result = nonNullableReceiverType.outputType; - - // Substitute type parameters - if (isTslFunction(nonNullableReceiverType.callable)) { - result = receiverType - } + if (isTslFunction(nonNullableReceiverType)) { + result = receiverType } // Update nullability @@ -291,14 +248,14 @@ export class TTSLTypeComputer { // Receiver is a list if (receiverType instanceof ListType) { return receiverType - .getValueTypeByIndex(0) + .getTypeParameterTypeByIndex(0) .withExplicitNullability(receiverType.isExplicitlyNullable && node.isNullSafe); } // Receiver is a Dictionary if (receiverType instanceof DictionaryType) { return receiverType - .getValueTypeByIndex(1) + .getTypeParameterTypeByIndex(1) .withExplicitNullability(receiverType.isExplicitlyNullable && node.isNullSafe); } @@ -310,12 +267,12 @@ export class TTSLTypeComputer { const rightOperandType = this.computeType(node.rightOperand); if ( - this.typeChecker.isSubtypeOf(leftOperandType, this.coreTypes.Int) && - this.typeChecker.isSubtypeOf(rightOperandType, this.coreTypes.Int) + this.typeChecker.isSubtypeOf(leftOperandType, new IntType(false)) && + this.typeChecker.isSubtypeOf(rightOperandType, new IntType(false)) ) { - return this.coreTypes.Int; + return new IntType(false); } else { - return this.coreTypes.Float; + return new FloatType(false); } } @@ -332,10 +289,10 @@ export class TTSLTypeComputer { private computeTypeOfArithmeticPrefixOperation(node: TslPrefixOperation): Type { const operandType = this.computeType(node.operand); - if (this.typeChecker.isSubtypeOf(operandType, this.coreTypes.Int)) { - return this.coreTypes.Int; + if (this.typeChecker.isSubtypeOf(operandType, new IntType(false))) { + return new IntType(false); } else { - return this.coreTypes.Float; + return new FloatType(false); } } @@ -347,8 +304,14 @@ export class TTSLTypeComputer { } private computeTypeOfType(node: TslType): Type { - if (isTslCallableType(node)) { - return this.computeTypeOfCallableWithManifestTypes(node); + if (isTslIntType(node)) { + return new IntType(false); + } else if (isTslFloatType(node)) { + return new FloatType(false); + } else if (isTslStringType(node)) { + return new StringType(false); + } else if (isTslBooleanType(node)) { + return new BooleanType(false); } /* c8 ignore start */ else { return UnknownType; } /* c8 ignore stop */ @@ -362,27 +325,9 @@ export class TTSLTypeComputer { * Returns the non-nullable type for the given type. The result is simplified as much as possible. */ computeNonNullableType(type: Type): Type { - return type.withExplicitNullability(false).simplify(); + return type.withExplicitNullability(false); } - /** - * Returns the lowest class type for the given constant. - */ - computeClassTypeForConstant(constant: Constant): Type { - if (constant instanceof BooleanConstant) { - return this.coreTypes.Boolean; - } else if (constant instanceof FloatConstant) { - return this.coreTypes.Float; - } else if (constant instanceof IntConstant) { - return this.coreTypes.Int; - } else if (constant === NullConstant) { - return this.coreTypes.NothingOrNull; - } else if (constant instanceof StringConstant) { - return this.coreTypes.String; - } /* c8 ignore start */ else { - throw new Error(`Unexpected constant type: ${constant.constructor.name}`); - } /* c8 ignore stop */ - } // ----------------------------------------------------------------------------------------------------------------- // Lowest common supertype @@ -392,24 +337,21 @@ export class TTSLTypeComputer { * Computes the lowest common supertype for the given types. The result is simplified as much as possible. */ private lowestCommonSupertype(types: Type[], options: LowestCommonSupertypeOptions = {}): Type { - // Simplify types - const simplifiedTypes = this.simplifyTypesLCS(types, options); - // A single type is its own lowest common supertype - if (simplifiedTypes.length === 1) { - return simplifiedTypes[0]!; + if (types.length === 1) { + return types[0]!; } // Partition types by their kind - const partitionedTypes = this.partitionTypesLCS(simplifiedTypes); + const partitionedTypes = this.partitionTypesLCS(types); // Includes unknown type if (partitionedTypes.containsUnknownType) { - return this.coreTypes.AnyOrNull; + return new AnyType(true); } // The result must be nullable if any of the types is nullable - const isNullable = simplifiedTypes.some((it) => it.isExplicitlyNullable); + const isNullable = types.some((it) => it.isExplicitlyNullable); // Includes unhandled type if (partitionedTypes.containsOtherType) { @@ -419,19 +361,6 @@ export class TTSLTypeComputer { return UnknownType } - - /** - * Simplifies a list of types for the purpose of computing the lowest common supertype (LCS). - */ - private simplifyTypesLCS(types: Type[], options: LowestCommonSupertypeOptions): Type[] { - if (options.skipTypeSimplification) { - return types; - } - - const simplifiedType = this.factory.createUnionType(types).simplify(); - - return [simplifiedType]; - } /** * Partitions the given types by their kind. This function assumes that union types have been removed. It is only @@ -444,7 +373,7 @@ export class TTSLTypeComputer { }; for (const type of types) { - if (type.equals(this.coreTypes.Nothing) || type.equals(this.coreTypes.NothingOrNull)) { + if (type.equals(new NothingType(false)) || type.equals(new NothingType(true))) { // Drop Nothing/Nothing? types. They are compatible to everything with appropriate nullability. } else if (type === UnknownType) { result.containsUnknownType = true; @@ -463,7 +392,7 @@ export class TTSLTypeComputer { // ----------------------------------------------------------------------------------------------------------------- private Any(isNullable: boolean): Type { - return isNullable ? this.coreTypes.AnyOrNull : this.coreTypes.Any; + return isNullable ? new AnyType(true) : new AnyType(false); } } diff --git a/packages/ttsl-lang/src/language/typing/ttsl-type-factory.ts b/packages/ttsl-lang/src/language/typing/ttsl-type-factory.ts deleted file mode 100644 index 0b254fa4..00000000 --- a/packages/ttsl-lang/src/language/typing/ttsl-type-factory.ts +++ /dev/null @@ -1,53 +0,0 @@ -import { TTSLServices } from '../ttsl-module.js'; -import { - CallableType, - DictionaryType, - ListType, - NamedTupleEntry, - NamedTupleType, - Type, - UnionType, -} from './model.js'; -import { - TslCallable, - TslDeclaration, - TslDictionary, - TslList, - TslParameter, - TslResult, -} from '../generated/ast.js'; - -export class TTSLTypeFactory { - constructor(private readonly services: TTSLServices) {} - - createCallableType( - callable: TslCallable, - parameter: TslParameter | undefined, - inputType: NamedTupleType, - outputType: NamedTupleType, - ): CallableType { - return new CallableType(this.services, callable, parameter, inputType, outputType); - } - - createNamedTupleType(...entries: NamedTupleEntry[]): NamedTupleType { - return new NamedTupleType(this.services, entries); - } - - createUnionType( - types: Type[] - ): UnionType { - return new UnionType(this.services, types) - } - - createDictionaryType( - dictionary: TslDictionary, - ): DictionaryType { - return new DictionaryType(this.services, dictionary); - } - - createListType( - list: TslList, - ): ListType { - return new ListType(this.services, list); - } -} diff --git a/packages/ttsl-lang/src/language/validation/names.ts b/packages/ttsl-lang/src/language/validation/names.ts index dd048f60..49648f4f 100644 --- a/packages/ttsl-lang/src/language/validation/names.ts +++ b/packages/ttsl-lang/src/language/validation/names.ts @@ -4,7 +4,6 @@ import { listBuiltinFiles } from '../builtins/fileFinder.js'; import { BUILTINS_LANG_PACKAGE, BUILTINS_ROOT_PACKAGE } from '../builtins/packageNames.js'; import { isTslQualifiedImport, - TslCallableType, TslDeclaration, TslFunction, TslImportedDeclaration, @@ -144,11 +143,6 @@ const acceptCasingWarning = ( // Uniqueness // ----------------------------------------------------------------------------- -export const callableTypeMustContainUniqueNames = (node: TslCallableType, accept: ValidationAcceptor): void => { - namesMustBeUnique(getParameters(node), (name) => `A parameter with name '${name}' exists already.`, accept); - namesMustBeUnique(getResults(node), (name) => `A result with name '${name}' exists already.`, accept); -}; - export const moduleMemberMustHaveNameThatIsUniqueInPackage = (services: TTSLServices) => { const packageManager = services.workspace.PackageManager; const builtinUris = new Set(listBuiltinFiles().map((it) => it.toString())); diff --git a/packages/ttsl-lang/src/language/validation/other/expressions/infixOperations.ts b/packages/ttsl-lang/src/language/validation/other/expressions/infixOperations.ts index b03f0ef3..f7dc28a8 100644 --- a/packages/ttsl-lang/src/language/validation/other/expressions/infixOperations.ts +++ b/packages/ttsl-lang/src/language/validation/other/expressions/infixOperations.ts @@ -2,12 +2,11 @@ import { TslInfixOperation } from '../../../generated/ast.js'; import { ValidationAcceptor } from 'langium'; import { TTSLServices } from '../../../ttsl-module.js'; import { FloatConstant, IntConstant, NumberConstant } from '../../../partialEvaluation/model.js'; -import { UnknownType } from '../../../typing/model.js'; +import { FloatType, IntType, UnknownType } from '../../../typing/model.js'; export const CODE_INFIX_OPERATION_DIVISION_BY_ZERO = 'infix-operation/division-by-zero'; export const divisionDivisorMustNotBeZero = (services: TTSLServices) => { - const coreTypes = services.types.CoreTypes; const partialEvaluator = services.evaluation.PartialEvaluator; const typeChecker = services.types.TypeChecker; const typeComputer = services.types.TypeComputer; @@ -24,8 +23,8 @@ export const divisionDivisorMustNotBeZero = (services: TTSLServices) => { const dividendType = typeComputer.computeType(node.leftOperand); if ( dividendType === UnknownType || - (!typeChecker.isSubtypeOf(dividendType, coreTypes.Float) && - !typeChecker.isSubtypeOf(dividendType, coreTypes.Int)) + (!typeChecker.isSubtypeOf(dividendType, new FloatType(false)) && + !typeChecker.isSubtypeOf(dividendType, new IntType(false))) ) { return; } diff --git a/packages/ttsl-lang/src/language/validation/other/types/callableTypes.ts b/packages/ttsl-lang/src/language/validation/other/types/callableTypes.ts deleted file mode 100644 index bd0baa31..00000000 --- a/packages/ttsl-lang/src/language/validation/other/types/callableTypes.ts +++ /dev/null @@ -1,61 +0,0 @@ -import { AstUtils, ValidationAcceptor } from 'langium'; -import { isTslCallableType, isTslParameter, TslCallableType } from '../../../generated/ast.js'; - -import { getParameters, Parameter } from '../../../helpers/nodeProperties.js'; - -export const CODE_CALLABLE_TYPE_CONST_MODIFIER = 'callable-type/const-modifier'; -export const CODE_CALLABLE_TYPE_CONTEXT = 'callable-type/context'; -export const CODE_CALLABLE_TYPE_NO_OPTIONAL_PARAMETERS = 'callable-type/no-optional-parameters'; - -export const callableTypeParameterMustNotHaveConstModifier = ( - node: TslCallableType, - accept: ValidationAcceptor, -): void => { - for (const parameter of getParameters(node)) { - if (parameter.isConstant) { - accept('error', 'The const modifier is not applicable to parameters of callable types.', { - node: parameter, - property: 'isConstant', - code: CODE_CALLABLE_TYPE_CONST_MODIFIER, - }); - } - } -}; - -export const callableTypeMustBeUsedInCorrectContext = (node: TslCallableType, accept: ValidationAcceptor): void => { - if (!contextIsCorrect(node)) { - accept('error', 'Callable types must only be used for parameters.', { - node, - code: CODE_CALLABLE_TYPE_CONTEXT, - }); - } -}; - -const contextIsCorrect = (node: TslCallableType): boolean => { - if (isTslParameter(node.$container)) { - return true; - } - - // Check whether we already show an error on a containing callable type - let containingCallableType = AstUtils.getContainerOfType(node.$container, isTslCallableType); - while (containingCallableType) { - if (!isTslParameter(containingCallableType.$container)) { - return true; // Container already has wrong context - } - containingCallableType = AstUtils.getContainerOfType(containingCallableType.$container, isTslCallableType); - } - - return false; -}; - -export const callableTypeMustNotHaveOptionalParameters = (node: TslCallableType, accept: ValidationAcceptor): void => { - for (const parameter of getParameters(node)) { - if (Parameter.isOptional(parameter)) { - accept('error', 'A callable type must not have optional parameters.', { - node: parameter, - property: 'defaultValue', - code: CODE_CALLABLE_TYPE_NO_OPTIONAL_PARAMETERS, - }); - } - } -}; diff --git a/packages/ttsl-lang/src/language/validation/style.ts b/packages/ttsl-lang/src/language/validation/style.ts index 816542e9..0991cf55 100644 --- a/packages/ttsl-lang/src/language/validation/style.ts +++ b/packages/ttsl-lang/src/language/validation/style.ts @@ -168,7 +168,7 @@ export const chainedExpressionNullSafetyShouldBeNeeded = (services: TTSLServices } if ( - (isTslCall(node) && typeChecker.canBeCalled(receiverType)) || + (isTslCall(node)) || (isTslIndexedAccess(node) && typeChecker.canBeAccessedByIndex(receiverType)) || isTslMemberAccess(node) ) { diff --git a/packages/ttsl-lang/src/language/validation/ttsl-validator.ts b/packages/ttsl-lang/src/language/validation/ttsl-validator.ts index ae371c13..66a2490e 100644 --- a/packages/ttsl-lang/src/language/validation/ttsl-validator.ts +++ b/packages/ttsl-lang/src/language/validation/ttsl-validator.ts @@ -5,7 +5,6 @@ import { mapsShouldBeUsedWithCaution, } from './experimentalLanguageFeatures.js'; import { - callableTypeMustContainUniqueNames, moduleMemberMustHaveNameThatIsUniqueInPackage, moduleMustContainUniqueNames, nameMustNotOccurOnCoreDeclaration, @@ -38,11 +37,6 @@ import { assignmentAssigneeMustGetValue, assignmentShouldNotImplicitlyIgnoreResult, } from './other/statements/assignments.js'; -import { - callableTypeMustBeUsedInCorrectContext, - callableTypeMustNotHaveOptionalParameters, - callableTypeParameterMustNotHaveConstModifier, -} from './other/types/callableTypes.js'; import { callArgumentListShouldBeNeeded, chainedExpressionNullSafetyShouldBeNeeded, @@ -100,12 +94,6 @@ export const registerValidationChecks = function (services: TTSLServices) { callMustNotBeRecursive(services), callReceiverMustBeCallable(services), ], - TslCallableType: [ - callableTypeMustBeUsedInCorrectContext, - callableTypeMustContainUniqueNames, - callableTypeMustNotHaveOptionalParameters, - callableTypeParameterMustNotHaveConstModifier, - ], TslChainedExpression: [ chainedExpressionsMustBeNullSafeIfReceiverIsNullable(services), chainedExpressionNullSafetyShouldBeNeeded(services), diff --git a/packages/ttsl-lang/src/language/validation/types.ts b/packages/ttsl-lang/src/language/validation/types.ts index 5c7bed24..1be10317 100644 --- a/packages/ttsl-lang/src/language/validation/types.ts +++ b/packages/ttsl-lang/src/language/validation/types.ts @@ -15,7 +15,7 @@ import { } from '../generated/ast.js'; import { getArguments } from '../helpers/nodeProperties.js'; import { TTSLServices } from '../ttsl-module.js'; -import {DictionaryType, ListType, UnknownType } from '../typing/model.js'; +import {BooleanType, DictionaryType, FloatType, IntType, ListType, UnknownType } from '../typing/model.js'; export const CODE_TYPE_CALLABLE_RECEIVER = 'type/callable-receiver'; export const CODE_TYPE_MISMATCH = 'type/mismatch'; @@ -101,7 +101,6 @@ export const indexedAccessReceiverMustBeListOrMap = (services: TTSLServices) => }; export const indexedAccessIndexMustHaveCorrectType = (services: TTSLServices) => { - const coreTypes = services.types.CoreTypes; const typeChecker = services.types.TypeChecker; const typeComputer = services.types.TypeComputer; @@ -109,8 +108,8 @@ export const indexedAccessIndexMustHaveCorrectType = (services: TTSLServices) => const receiverType = typeComputer.computeType(node.receiver); if (receiverType instanceof ListType) { const indexType = typeComputer.computeType(node.index); - if (!typeChecker.isSubtypeOf(indexType, coreTypes.Int)) { - accept('error', `Expected type '${coreTypes.Int}' but got '${indexType}'.`, { + if (!typeChecker.isSubtypeOf(indexType, new IntType(false))) { + accept('error', `Expected type 'Int' but got '${indexType}'.`, { node, property: 'index', code: CODE_TYPE_MISMATCH, @@ -121,7 +120,6 @@ export const indexedAccessIndexMustHaveCorrectType = (services: TTSLServices) => }; export const infixOperationOperandsMustHaveCorrectType = (services: TTSLServices) => { - const coreTypes = services.types.CoreTypes; const typeChecker = services.types.TypeChecker; const typeComputer = services.types.TypeComputer; @@ -131,14 +129,14 @@ export const infixOperationOperandsMustHaveCorrectType = (services: TTSLServices switch (node.operator) { case 'or': case 'and': - if (node.leftOperand && !typeChecker.isSubtypeOf(leftType, coreTypes.Boolean)) { - accept('error', `Expected type '${coreTypes.Boolean}' but got '${leftType}'.`, { + if (node.leftOperand && !typeChecker.isSubtypeOf(leftType, new BooleanType(false))) { + accept('error', `Expected type 'Boolean' but got '${leftType}'.`, { node: node.leftOperand, code: CODE_TYPE_MISMATCH, }); } - if (node.rightOperand && !typeChecker.isSubtypeOf(rightType, coreTypes.Boolean)) { - accept('error', `Expected type '${coreTypes.Boolean}' but got '${rightType}'.`, { + if (node.rightOperand && !typeChecker.isSubtypeOf(rightType, new BooleanType(false))) { + accept('error', `Expected type 'Boolean' but got '${rightType}'.`, { node: node.rightOperand, code: CODE_TYPE_MISMATCH, }); @@ -154,22 +152,22 @@ export const infixOperationOperandsMustHaveCorrectType = (services: TTSLServices case '/': if ( node.leftOperand && - !typeChecker.isSubtypeOf(leftType, coreTypes.Float) && - !typeChecker.isSubtypeOf(leftType, coreTypes.Int) + !typeChecker.isSubtypeOf(leftType, new FloatType(false)) && + !typeChecker.isSubtypeOf(leftType, new IntType(false)) ) { - accept('error', `Expected type '${coreTypes.Float}' or '${coreTypes.Int}' but got '${leftType}'.`, { + accept('error', `Expected type 'Float' or 'Int' but got '${leftType}'.`, { node: node.leftOperand, code: CODE_TYPE_MISMATCH, }); } if ( node.rightOperand && - !typeChecker.isSubtypeOf(rightType, coreTypes.Float) && - !typeChecker.isSubtypeOf(rightType, coreTypes.Int) + !typeChecker.isSubtypeOf(rightType, new FloatType(false)) && + !typeChecker.isSubtypeOf(rightType, new IntType(false)) ) { accept( 'error', - `Expected type '${coreTypes.Float}' or '${coreTypes.Int}' but got '${rightType}'.`, + `Expected type 'Float' or 'Int' but got '${rightType}'.`, { node: node.rightOperand, code: CODE_TYPE_MISMATCH, @@ -247,7 +245,6 @@ export const parameterDefaultValueTypeMustMatchParameterType = (services: TTSLSe }; export const prefixOperationOperandMustHaveCorrectType = (services: TTSLServices) => { - const coreTypes = services.types.CoreTypes; const typeChecker = services.types.TypeChecker; const typeComputer = services.types.TypeComputer; @@ -255,8 +252,8 @@ export const prefixOperationOperandMustHaveCorrectType = (services: TTSLServices const operandType = typeComputer.computeType(node.operand); switch (node.operator) { case 'not': - if (!typeChecker.isSubtypeOf(operandType, coreTypes.Boolean)) { - accept('error', `Expected type '${coreTypes.Boolean}' but got '${operandType}'.`, { + if (!typeChecker.isSubtypeOf(operandType, new BooleanType(false))) { + accept('error', `Expected type 'Boolean' but got '${operandType}'.`, { node, property: 'operand', code: CODE_TYPE_MISMATCH, @@ -265,12 +262,12 @@ export const prefixOperationOperandMustHaveCorrectType = (services: TTSLServices return; case '-': if ( - !typeChecker.isSubtypeOf(operandType, coreTypes.Float) && - !typeChecker.isSubtypeOf(operandType, coreTypes.Int) + !typeChecker.isSubtypeOf(operandType, new FloatType(false)) && + !typeChecker.isSubtypeOf(operandType, new IntType(false)) ) { accept( 'error', - `Expected type '${coreTypes.Float}' or '${coreTypes.Int}' but got '${operandType}'.`, + `Expected type 'Float' or 'Int' but got '${operandType}'.`, { node, property: 'operand', From 544c7397ac24547d65f868a584f09b5d1ad0f567 Mon Sep 17 00:00:00 2001 From: methr0 Date: Mon, 22 Jul 2024 15:37:01 +0200 Subject: [PATCH 126/183] add len and key/value functions for list and dictionary --- .../generation/ttsl-python-generator.ts | 83 ++++++++++++++++--- .../generation/utilityFunctions/input.ttsl | 7 ++ 2 files changed, 79 insertions(+), 11 deletions(-) create mode 100644 packages/ttsl-lang/tests/resources/generation/utilityFunctions/input.ttsl diff --git a/packages/ttsl-lang/src/language/generation/ttsl-python-generator.ts b/packages/ttsl-lang/src/language/generation/ttsl-python-generator.ts index 19cfe34f..7ddb1c7a 100644 --- a/packages/ttsl-lang/src/language/generation/ttsl-python-generator.ts +++ b/packages/ttsl-lang/src/language/generation/ttsl-python-generator.ts @@ -65,6 +65,7 @@ import { isTslBlock, TslTimeunit, isTslExpression, + isTslString, } from '../generated/ast.js'; import { isInFile, isFile } from '../helpers/fileExtensions.js'; import { @@ -280,6 +281,36 @@ const UTILITY_TIMEUNIT_YEAR: UtilityFunction = { typeVariables: [`${CODEGEN_PREFIX}T`], }; +const UTILITY_LEN_FUNCTION: UtilityFunction = { + name: `${CODEGEN_PREFIX}len`, + code: expandToNode`def ${CODEGEN_PREFIX}len(list):` + .appendNewLine() + .indent(indentingNode => + indentingNode.append(`return len(list)`)), + imports: [{ importPath: 'typing', declarationName: 'Any' }], + typeVariables: [`${CODEGEN_PREFIX}T`], +}; + +const UTILITY_KEYS_FUNCTION: UtilityFunction = { + name: `${CODEGEN_PREFIX}keys`, + code: expandToNode`def ${CODEGEN_PREFIX}keys(dict):` + .appendNewLine() + .indent(indentingNode => + indentingNode.append(`return list(dict.keys())`)), + imports: [{ importPath: 'typing', declarationName: 'Any' }], + typeVariables: [`${CODEGEN_PREFIX}T`], +}; + +const UTILITY_VALUES_FUNCTION: UtilityFunction = { + name: `${CODEGEN_PREFIX}values`, + code: expandToNode`def ${CODEGEN_PREFIX}values(dict):` + .appendNewLine() + .indent(indentingNode => + indentingNode.append(`return list(dict.values())`)), + imports: [{ importPath: 'typing', declarationName: 'Any' }], + typeVariables: [`${CODEGEN_PREFIX}T`], +}; + export class TTSLPythonGenerator { private readonly builtinFunction: TTSLFunction; private readonly nodeMapper: TTSLNodeMapper; @@ -846,8 +877,8 @@ export class TTSLPythonGenerator { assignment: TslAssignment, frame: GenerationInfoFrame, ): CompositeGeneratorNode { - const requiredAssignees = isTslCall(assignment.expression) - ? getResults(this.nodeMapper.callToCallable(assignment.expression)).length + const requiredAssignees = isTslFunction(assignment.expression) + ? getResults(assignment.expression).length : /* c8 ignore next */ 1; const assignees = getAssignees(assignment); @@ -927,19 +958,49 @@ export class TTSLPythonGenerator { const sortedArgs = this.sortArguments(getArguments(expression)); const receiver = this.generateExpression(expression.receiver, frame); let call: CompositeGeneratorNode | undefined = undefined; + + if (isTslString(receiver)){ + + if(sortedArgs[0]){ + let arg = sortedArgs[0]; + if(receiver.value == "len"){ + if(isTslReference(arg.value)){ + frame.addUtility(UTILITY_LEN_FUNCTION); + return expandTracedToNode(expression)`${traceToNode( + expression, + 'receiver', + )(UTILITY_LEN_FUNCTION.name)}(${arg.value.target.ref?.name})`; + } + } else if(receiver.value == "keys"){ + if(isTslReference(arg.value)){ + frame.addUtility(UTILITY_KEYS_FUNCTION); + return expandTracedToNode(expression)`${traceToNode( + expression, + 'receiver', + )(UTILITY_KEYS_FUNCTION.name)}(${arg.value.target.ref?.name})`; + } + } else if(receiver.value == "values"){ + if(isTslReference(arg.value)){ + frame.addUtility(UTILITY_VALUES_FUNCTION); + return expandTracedToNode(expression)`${traceToNode( + expression, + 'receiver', + )(UTILITY_VALUES_FUNCTION.name)}(${arg.value.target.ref?.name})`; + } + } + } + } // Memoize constructor or function call if (isTslFunction(callable)) { - if (isTslFunction(callable)) { - const pythonCall = this.builtinFunction.getPythonCall(callable); - if (pythonCall) { - let thisParam: CompositeGeneratorNode | undefined = undefined; - if (isTslMemberAccess(expression.receiver)) { - thisParam = this.generateExpression(expression.receiver.receiver, frame); - } - const argumentsMap = this.getArgumentsMap(getArguments(expression), frame); - call = this.generatePythonCall(expression, pythonCall, argumentsMap, frame, thisParam); + const pythonCall = this.builtinFunction.getPythonCall(callable); + if (pythonCall) { + let thisParam: CompositeGeneratorNode | undefined = undefined; + if (isTslMemberAccess(expression.receiver)) { + thisParam = this.generateExpression(expression.receiver.receiver, frame); } + const argumentsMap = this.getArgumentsMap(getArguments(expression), frame); + call = this.generatePythonCall(expression, pythonCall, argumentsMap, frame, thisParam); } } diff --git a/packages/ttsl-lang/tests/resources/generation/utilityFunctions/input.ttsl b/packages/ttsl-lang/tests/resources/generation/utilityFunctions/input.ttsl new file mode 100644 index 00000000..205733ec --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/utilityFunctions/input.ttsl @@ -0,0 +1,7 @@ +package tests.generator.utilityFunction + +constant testList: List = [1, 2, 3] + +function testFunction(){ + var x = len(testList); +} From dc80bbfc804cda2a3c99d3d880551aa3fa637528 Mon Sep 17 00:00:00 2001 From: methr0 Date: Mon, 22 Jul 2024 15:37:42 +0200 Subject: [PATCH 127/183] add new types to formatter --- .../src/language/lsp/ttsl-formatter.ts | 68 ++++++++++++------- 1 file changed, 43 insertions(+), 25 deletions(-) diff --git a/packages/ttsl-lang/src/language/lsp/ttsl-formatter.ts b/packages/ttsl-lang/src/language/lsp/ttsl-formatter.ts index 7c27b75f..befd62bf 100644 --- a/packages/ttsl-lang/src/language/lsp/ttsl-formatter.ts +++ b/packages/ttsl-lang/src/language/lsp/ttsl-formatter.ts @@ -1,5 +1,4 @@ import { AstNode, CstNode, CstUtils, isAstNode } from 'langium'; -import { last } from '../../helpers/collections.js'; import * as ast from '../generated/ast.js'; import { AbstractFormatter, Formatting, FormattingAction, FormattingActionOptions } from 'langium/lsp'; import indent = Formatting.indent; @@ -110,8 +109,18 @@ export class TTSLFormatter extends AbstractFormatter { // ----------------------------------------------------------------------------- else if (ast.isTslMemberType(node)) { this.formatTslMemberType(node); - } else if (ast.isTslCallableType(node)) { - this.formatTslCallableType(node); + } else if (ast.isTslIntType(node)) { + this.formatTslIntType(node); + } else if (ast.isTslFloatType(node)) { + this.formatTslFloatType(node); + } else if (ast.isTslStringType(node)) { + this.formatTslStringType(node); + } else if (ast.isTslBooleanType(node)) { + this.formatTslBooleanType(node); + } else if (ast.isTslListType(node)) { + this.formatTslListType(node); + } else if (ast.isTslDictionaryType(node)) { + this.formatTslDictionaryType(node); } } @@ -224,8 +233,7 @@ export class TTSLFormatter extends AbstractFormatter { const parameters = node.parameters ?? []; if ( - parameters.length >= 3 || - parameters.some((it) => this.isComplexType(it.type)) + parameters.length >= 3 ) { formatter.nodes(...parameters).prepend(indent()); formatter.keywords(',').prepend(noSpace()); @@ -258,8 +266,7 @@ export class TTSLFormatter extends AbstractFormatter { const results = node.results ?? []; if ( - results.length >= 3 || - results.some((it) => this.isComplexType(it.type)) + results.length >= 3 ) { formatter.nodes(...results).prepend(indent()); formatter.keywords(',').prepend(noSpace()); @@ -479,29 +486,40 @@ export class TTSLFormatter extends AbstractFormatter { formatter.keyword('.').surround(noSpace()); } - private formatTslCallableType(node: ast.TslCallableType) { + private formatTslIntType(node: ast.TslIntType) { const formatter = this.getNodeFormatter(node); - formatter.keyword('->').surround(oneSpace()); + formatter.keyword('Int').surround(oneSpace()); } - /** - * Returns whether the type is considered complex and requires special formatting like placing the associated - * parameter on its own line. - * - * @param node The type to check. - */ - private isComplexType(node: ast.TslType | undefined): boolean { - if (!node) { - return false; - } + private formatTslFloatType(node: ast.TslFloatType) { + const formatter = this.getNodeFormatter(node); - if (ast.isTslCallableType(node)) { - return true; - } else { - /* c8 ignore next 2 */ - return false; - } + formatter.keyword('Float').surround(oneSpace()); + } + + private formatTslStringType(node: ast.TslStringType) { + const formatter = this.getNodeFormatter(node); + + formatter.keyword('String').surround(oneSpace()); + } + + private formatTslBooleanType(node: ast.TslBooleanType) { + const formatter = this.getNodeFormatter(node); + + formatter.keyword('Boolean').surround(oneSpace()); + } + + private formatTslListType(node: ast.TslListType) { + const formatter = this.getNodeFormatter(node); + + formatter.keyword('List<').prepend(oneSpace()); + } + + private formatTslDictionaryType(node: ast.TslDictionaryType) { + const formatter = this.getNodeFormatter(node); + + formatter.keyword('Dictionary<').prepend(oneSpace()); } // ----------------------------------------------------------------------------- From 3b0301da10e2510b62a514ed9cf4d127aa8cf562 Mon Sep 17 00:00:00 2001 From: methr0 Date: Mon, 22 Jul 2024 15:39:29 +0200 Subject: [PATCH 128/183] update handling of calls/allables --- .../language/flow/ttsl-call-graph-computer.ts | 20 +------------------ .../src/language/helpers/ttsl-node-mapper.ts | 15 +++++++------- .../language/scoping/ttsl-scope-provider.ts | 6 +++--- .../other/statements/assignments.ts | 7 +++---- 4 files changed, 14 insertions(+), 34 deletions(-) diff --git a/packages/ttsl-lang/src/language/flow/ttsl-call-graph-computer.ts b/packages/ttsl-lang/src/language/flow/ttsl-call-graph-computer.ts index 052743c5..9dd9af5f 100644 --- a/packages/ttsl-lang/src/language/flow/ttsl-call-graph-computer.ts +++ b/packages/ttsl-lang/src/language/flow/ttsl-call-graph-computer.ts @@ -1,7 +1,6 @@ import { AstNode, type AstNodeLocator, AstUtils, stream, WorkspaceCache } from 'langium'; import { isTslCall, - isTslCallable, isTslFunction, isTslParameter, TslArgument, @@ -15,7 +14,6 @@ import type { TTSLNodeMapper } from '../helpers/ttsl-node-mapper.js'; import type { TTSLServices } from '../ttsl-module.js'; import { EvaluatedCallable, - NamedCallable, ParameterSubstitutions, substitutionsAreEqual, UnknownEvaluatedNode, @@ -23,7 +21,6 @@ import { import { CallGraph } from './model.js'; import { getArguments, getParameters } from '../helpers/nodeProperties.js'; import { TTSLTypeComputer } from '../typing/ttsl-type-computer.js'; -import { CallableType } from '../typing/model.js'; import { isEmpty } from '../../helpers/collections.js'; import { TTSLPartialEvaluator } from '../partialEvaluation/ttsl-partial-evaluator.js'; @@ -212,25 +209,10 @@ export class TTSLCallGraphComputer { // First try to get the callable via the partial evaluator const value = this.partialEvaluator.evaluate(expression, substitutions); - if (value instanceof EvaluatedCallable) { + if (value instanceof EvaluatedCallable) { return value; } - // Fall back to getting the called parameter via the type computer - const type = this.typeComputer.computeType(expression); - const nonNullType = this.typeComputer.computeNonNullableType(type); - if (!(nonNullType instanceof CallableType)) { - return undefined; - } - - const parameterOrCallable = nonNullType.parameter ?? nonNullType.callable; - if (isTslParameter(parameterOrCallable)) { - return new NamedCallable(parameterOrCallable); - } else if (isTslFunction(parameterOrCallable)) { - // Needed for instance methods - return new NamedCallable(parameterOrCallable); - } - return undefined; } diff --git a/packages/ttsl-lang/src/language/helpers/ttsl-node-mapper.ts b/packages/ttsl-lang/src/language/helpers/ttsl-node-mapper.ts index 9d7e14ba..ab27bede 100644 --- a/packages/ttsl-lang/src/language/helpers/ttsl-node-mapper.ts +++ b/packages/ttsl-lang/src/language/helpers/ttsl-node-mapper.ts @@ -5,9 +5,9 @@ import { isTslBlock, isTslCall, isTslCallable, + isTslFunction, isTslParameter, isTslReference, - isTslType, TslAbstractCall, TslArgument, TslAssignee, @@ -19,7 +19,6 @@ import { TslResult, } from '../generated/ast.js'; import { TTSLServices } from '../ttsl-module.js'; -import { CallableType } from '../typing/model.js'; import { TTSLTypeComputer } from '../typing/ttsl-type-computer.js'; import { Argument, @@ -90,7 +89,7 @@ export class TTSLNodeMapper { const expression = containingAssignment.expression; // If the RHS is not a call, the first assignee gets the entire RHS - if (!isTslCall(expression)) { + if (!isTslFunction(expression)) { if (assigneePosition === 0) { return expression; } else { @@ -98,10 +97,8 @@ export class TTSLNodeMapper { } } - const callable = this.callToCallable(expression); - // Otherwise, the assignee gets the result at the same position - const abstractResults = getResults(callable); + const abstractResults = getResults(expression); return abstractResults[assigneePosition]; } @@ -120,8 +117,10 @@ export class TTSLNodeMapper { const receiverType = this.typeComputer().computeType(node.receiver); const nonNullableReceiverType = this.typeComputer().computeNonNullableType(receiverType); - if (nonNullableReceiverType instanceof CallableType) { - return nonNullableReceiverType.callable; + if(isTslReference(node.receiver)){ + if(isTslCallable(node.receiver.target.ref)){ + return node.receiver.target.ref + } } } diff --git a/packages/ttsl-lang/src/language/scoping/ttsl-scope-provider.ts b/packages/ttsl-lang/src/language/scoping/ttsl-scope-provider.ts index b027eb05..532aad8a 100644 --- a/packages/ttsl-lang/src/language/scoping/ttsl-scope-provider.ts +++ b/packages/ttsl-lang/src/language/scoping/ttsl-scope-provider.ts @@ -16,6 +16,7 @@ import { isTslBlock, isTslCall, isTslCallable, + isTslFunction, isTslImportedDeclaration, isTslMemberAccess, isTslModule, @@ -118,9 +119,8 @@ export class TTSLScopeProvider extends DefaultScopeProvider { private getScopeForMemberAccessMember(node: TslMemberAccess): Scope { // Call results let resultScope = EMPTY_SCOPE; - if (isTslCall(node.receiver)) { - const callable = this.nodeMapper.callToCallable(node.receiver); - const results = getResults(callable); + if (isTslFunction(node.receiver)) { + const results = getResults(node.receiver); if (results.length > 1) { return this.createScopeForNodes(results); diff --git a/packages/ttsl-lang/src/language/validation/other/statements/assignments.ts b/packages/ttsl-lang/src/language/validation/other/statements/assignments.ts index 43a93534..dd0897c3 100644 --- a/packages/ttsl-lang/src/language/validation/other/statements/assignments.ts +++ b/packages/ttsl-lang/src/language/validation/other/statements/assignments.ts @@ -1,4 +1,4 @@ -import { isTslCall, TslAssignment} from '../../../generated/ast.js'; +import { isTslCall, isTslFunction, TslAssignment} from '../../../generated/ast.js'; import { ValidationAcceptor } from 'langium'; import { TTSLServices } from '../../../ttsl-module.js'; import { getResults, getAssignees } from '../../../helpers/nodeProperties.js'; @@ -25,13 +25,12 @@ export const assignmentShouldNotImplicitlyIgnoreResult = (services: TTSLServices return (node: TslAssignment, accept: ValidationAcceptor): void => { const expression = node.expression; - if (!isTslCall(expression)) { + if (!isTslFunction(expression)) { return; } const assignees = getAssignees(node); - const callable = nodeMapper.callToCallable(expression); - const results = getResults(callable); + const results = getResults(expression); if (results.length > assignees.length) { const kind = pluralize(results.length - assignees.length, 'result'); From 37542cfff62e354dc139526e4f7983ea69afad40 Mon Sep 17 00:00:00 2001 From: alex-senger Date: Tue, 23 Jul 2024 11:08:11 +0200 Subject: [PATCH 129/183] feat: add gesetzliche Rentenversicherung --- .../gesetzlicherentenversicherung.ttsl" | 99 +++++++++++++++++++ 1 file changed, 99 insertions(+) create mode 100644 "src/resources/builtins/sozialversicherungsBeitr\303\244ge/gesetzlicherentenversicherung.ttsl" diff --git "a/src/resources/builtins/sozialversicherungsBeitr\303\244ge/gesetzlicherentenversicherung.ttsl" "b/src/resources/builtins/sozialversicherungsBeitr\303\244ge/gesetzlicherentenversicherung.ttsl" new file mode 100644 index 00000000..25253582 --- /dev/null +++ "b/src/resources/builtins/sozialversicherungsBeitr\303\244ge/gesetzlicherentenversicherung.ttsl" @@ -0,0 +1,99 @@ +package gesetzlicheRentenversicherung + +from sozialversicherungsBeitragsParameter import beitragssatz, pauschalabgabenGeringfuegigeBeschaeftigung + +from math import min + +/** + * Beitrag für die gesetzliche Rentenversicherung. + */ +public function beitrag(): Float per month { + to 2003-03-31 { + var beitrRegularJob = bruttolohn() * beitragssatz["ges_rentenv"]; + if geringfuegigBeschaeftigt() { + return 0.0; + } else { + return beitrRegularJob(); + } + } + from 2003-04-01 { + var beitrRegularJob = bruttolohn() * beitragssatz["ges_rentenv"]; + if geringfuegigBeschaeftigt() { + return 0.0; + } else if inGleitzone() { + return beitrMidijobArbeitnehmer(); + } else { + return beitrRegularJob(); + } + } +} + +/** + * Arbeitgeberanteil für die gesetzliche Rentenversicherung bis März 2003. + */ +public function beitragArbeitgeber( + bruttolohn: Float +): Float per month { + to 2003-03-31 { + var beitrRegularJob = bruttolohn * beitragssatz["ges_rentenv"]; + if geringfuegigBeschaeftigt() { + return bruttolohn * pauschalabgabenGeringfuegigeBeschaeftigung["ges_rentenv"]; + } else { + return beitrRegularJob(); + } + } + from 2003-04-01 { + var beitrRegularJob = bruttolohn * beitragssatz["ges_rentenv"]; + if geringfuegigBeschaeftigt() { + return bruttolohn * pauschalabgabenGeringfuegigeBeschaeftigung["ges_rentenv"]; + } else if inGleitzone { + return beitrMidijobArbeitgeber(); + } else { + return beitrRegularJob(); + } + } +} + +/** + * Summe der Arbeitgeber- und Arbeitnehmerbeiträge zur Rentenversicherung für Midijobs. + */ +public function beitragMidijobSummeArbeitnehmerArbeitgeber(): Float per month { + from 2003-04-01 { + return midijobBemessungsentgelt() * 2 * beitragssatz["ges_rentenv"]; + } +} + +/** + * Arbeitgeberanteil für Midijobs. + */ +public function beitragMidijobArbeitgeber( + bruttolohn: Float +): Float per month { + to 2022-09-30 { + return bruttolohn * beitragssatz["ges_rentenv"]; + } + from 2022-10-01 { + return beitragMidijobSummeArbeitnehmerArbeitgeber() - beitragMidijobArbeitnehmer(); + } +} + +/** + * Arbeitnehmeranteil für Midijobs in der gesetzlichen Rentenversicherung. + */ +public function beitragMidijobArbeitnehmer(): Float per month { + to 2022-09-30 { + return beitragMidijobSummeArbeitnehmerArbeitgeber() - beitragMidijobArbeitgeber(); + } + from 2022-10-01 { + return beitragspflichtigesEinkommenArbeitnehmer * beitragssatz["ges_rentenv"]; + } +} + +/** + * Berechnung des Bruttolohns, der der Rentenversicherung unterliegt. + */ +public function beitragBruttolohn( + bruttolohn: Float +): Float per month { + return min(bruttolohn, beitragsbemessungsgrenze()); +} \ No newline at end of file From d19d74d57f469f4bd095f41992aad2450b692eaf Mon Sep 17 00:00:00 2001 From: methr0 Date: Tue, 23 Jul 2024 13:22:14 +0200 Subject: [PATCH 130/183] remove purity tests --- .../tests/language/purity/model.test.ts | 128 --- .../purity/safe-ds-purity-computer.test.ts | 795 ------------------ 2 files changed, 923 deletions(-) delete mode 100644 packages/ttsl-lang/tests/language/purity/model.test.ts delete mode 100644 packages/ttsl-lang/tests/language/purity/safe-ds-purity-computer.test.ts diff --git a/packages/ttsl-lang/tests/language/purity/model.test.ts b/packages/ttsl-lang/tests/language/purity/model.test.ts deleted file mode 100644 index a8d6a7eb..00000000 --- a/packages/ttsl-lang/tests/language/purity/model.test.ts +++ /dev/null @@ -1,128 +0,0 @@ -import { NodeFileSystem } from 'langium/node'; -import { describe, expect, it } from 'vitest'; -import { isTslParameter } from '../../../src/language/generated/ast.js'; -import { - EndlessRecursion, - FileRead, - FileWrite, - type ImpurityReason, - OtherImpurityReason, - PotentiallyImpureParameterCall, - UnknownCallableCall, -} from '../../../src/language/purity/model.js'; -import { getNodeOfType } from '../../helpers/nodeFinder.js'; -import { type EqualsTest, ToStringTest } from '../../helpers/testDescription.js'; -import { createTTSLServices } from '../../../src/language/index.js'; - -const services = (await createTTSLServices(NodeFileSystem)).TTSL; -const parameter = await getNodeOfType(services, 'fun f(p: Int)', isTslParameter); - -describe('purity model', async () => { - const equalsTests: EqualsTest[] = [ - { - value: () => new FileRead(undefined), - unequalValueOfSameType: () => new FileRead('test.txt'), - valueOfOtherType: () => new FileWrite(undefined), - }, - { - value: () => new FileWrite('test.txt'), - unequalValueOfSameType: () => new FileWrite(undefined), - valueOfOtherType: () => new FileRead('test.txt'), - }, - { - value: () => new PotentiallyImpureParameterCall(undefined), - unequalValueOfSameType: () => new PotentiallyImpureParameterCall(parameter), - valueOfOtherType: () => new FileRead('test.txt'), - }, - { - value: () => UnknownCallableCall, - valueOfOtherType: () => EndlessRecursion, - }, - { - value: () => EndlessRecursion, - valueOfOtherType: () => OtherImpurityReason, - }, - { - value: () => OtherImpurityReason, - valueOfOtherType: () => new FileRead('test.txt'), - }, - ]; - - describe.each(equalsTests)('equals', ({ value, unequalValueOfSameType, valueOfOtherType }) => { - it(`should return true if both types are the same instance (${value().constructor.name})`, () => { - const typeInstance = value(); - expect(typeInstance.equals(typeInstance)).toBeTruthy(); - }); - - it(`should return true if both types have the same values (${value().constructor.name})`, () => { - expect(value().equals(value())).toBeTruthy(); - }); - - if (unequalValueOfSameType) { - it(`should return false if both types have different values (${value().constructor.name})`, () => { - expect(value().equals(unequalValueOfSameType())).toBeFalsy(); - }); - } - - if (valueOfOtherType) { - it(`should return false if the other type is an instance of another class (${ - value().constructor.name - })`, () => { - expect(value().equals(valueOfOtherType())).toBeFalsy(); - }); - } - }); - - const toStringTests: ToStringTest[] = [ - { - value: new FileRead(undefined), - expectedString: 'File read from ?', - }, - { - value: new FileRead('test.txt'), - expectedString: 'File read from "test.txt"', - }, - { - value: new FileRead(parameter), - expectedString: 'File read from f.p', - }, - { - value: new FileWrite(undefined), - expectedString: 'File write to ?', - }, - { - value: new FileWrite('test.txt'), - expectedString: 'File write to "test.txt"', - }, - { - value: new FileWrite(parameter), - expectedString: 'File write to f.p', - }, - { - value: new PotentiallyImpureParameterCall(undefined), - expectedString: 'Potentially impure call of ?', - }, - { - value: new PotentiallyImpureParameterCall(parameter), - expectedString: 'Potentially impure call of f.p', - }, - { - value: UnknownCallableCall, - expectedString: 'Unknown callable call', - }, - { - value: EndlessRecursion, - expectedString: 'Endless recursion', - }, - { - value: OtherImpurityReason, - expectedString: 'Other', - }, - ]; - - describe.each(toStringTests)('toString', ({ value, expectedString }) => { - it(`should return the expected string representation (${value.constructor.name} -- ${value})`, () => { - expect(value.toString()).toStrictEqual(expectedString); - }); - }); -}); diff --git a/packages/ttsl-lang/tests/language/purity/safe-ds-purity-computer.test.ts b/packages/ttsl-lang/tests/language/purity/safe-ds-purity-computer.test.ts deleted file mode 100644 index 7667c059..00000000 --- a/packages/ttsl-lang/tests/language/purity/safe-ds-purity-computer.test.ts +++ /dev/null @@ -1,795 +0,0 @@ -import { describe, expect, it } from 'vitest'; -import { NodeFileSystem } from 'langium/node'; -import { isTslCall, isTslCallable, isTslExpression, isTslParameter } from '../../../src/language/generated/ast.js'; -import { getNodeOfType } from '../../helpers/nodeFinder.js'; -import { createTTSLServices } from '../../../src/language/index.js'; - -const services = (await createTTSLServices(NodeFileSystem)).TTSL; -const purityComputer = services.purity.PurityComputer; - -describe('TTSLPurityComputer', async () => { - describe('isPureCallable', () => { - it.each([ - { - testName: 'pure function', - code: ` - package test - - @Pure - fun f() - `, - expected: true, - }, - { - testName: 'impure function with reasons', - code: ` - package test - - @Impure([]) - fun f() - `, - expected: true, - }, - { - testName: 'impure function with reasons', - code: ` - package test - - @Impure([ImpurityReason.Other]) - fun f() - `, - expected: false, - }, - { - testName: 'endless recursion', - code: ` - package test - - segment a() { - a(); - } - `, - expected: false, - }, - { - testName: 'unknown callable', - code: ` - package test - - segment a() { - unresolved(); - } - `, - expected: false, - }, - { - testName: 'potentially impure parameter call', - code: ` - package test - - segment mySegment(param: () -> ()) { - param(); - } - `, - expected: false, - }, - { - testName: 'pure parameter call', - code: ` - package test - - class MyClass(param: () -> (result: Int), value: Int = param()) - `, - expected: true, - }, - ])('should return whether a callable is pure ($testName)', async ({ code, expected }) => { - const callable = await getNodeOfType(services, code, isTslCallable); - expect(purityComputer.isPureCallable(callable)).toBe(expected); - }); - }); - - describe('isPureExpression', () => { - it.each([ - { - testName: 'call of pure function', - code: ` - package test - - pipeline myPipeline { - f(); - } - - @Pure - fun f() - `, - expected: true, - }, - { - testName: 'call of impure function without reasons', - code: ` - package test - - pipeline myPipeline { - f(); - } - - @Impure([]) - fun f() - `, - expected: true, - }, - { - testName: 'call of impure function with reasons', - code: ` - package test - - pipeline myPipeline { - f(); - } - - @Impure([ImpurityReason.Other]) - fun f() - `, - expected: false, - }, - { - testName: 'lambda', - code: ` - package test - - pipeline myPipeline { - () -> f(); - } - - @Impure([ImpurityReason.Other]) - fun f() - `, - expected: true, - }, - { - testName: 'endless recursion', - code: ` - package test - - segment a() { - a(); - } - `, - expected: false, - }, - { - testName: 'unknown callable', - code: ` - package test - - segment a() { - unresolved(); - } - `, - expected: false, - }, - { - testName: 'potentially impure parameter call', - code: ` - package test - - segment mySegment(param: () -> ()) { - param(); - } - `, - expected: false, - }, - { - testName: 'pure parameter call', - code: ` - package test - - class MyClass(param: () -> (result: Int), value: Int = param()) - `, - expected: true, - }, - ])('should return whether an expression is pure ($testName)', async ({ code, expected }) => { - const expression = await getNodeOfType(services, code, isTslExpression); - expect(purityComputer.isPureExpression(expression)).toBe(expected); - }); - }); - - describe('isPureExpression', () => { - it.each([ - { - testName: 'annotation parameter', - code: ` - package test - - annotation MyAnnotation(f: () -> ()) - `, - expected: true, - }, - { - testName: 'class parameter', - code: ` - package test - - class MyClass(f: () -> ()) - `, - expected: true, - }, - { - testName: 'enum variant parameter', - code: ` - package test - - enum MyEnum { - MyEnumVariant(f: () -> ()) - } - `, - expected: true, - }, - { - testName: 'pure function parameter', - code: ` - package test - - @Pure - fun myFunction(f: () -> ()) - `, - expected: true, - }, - { - testName: 'impure function parameter', - code: ` - package test - - @Impure([ImpurityReason.PotentiallyImpureParameterCall("f")]) - fun myFunction(f: () -> ()) - `, - expected: false, - }, - { - testName: 'callable type parameter', - code: ` - package test - - segment mySegment() -> (result: (f: () -> ()) -> ()) - `, - expected: false, - }, - { - testName: 'segment parameter', - code: ` - package test - - segment mySegment(f: () -> ()) - `, - expected: false, - }, - { - testName: 'block lambda parameter', - code: ` - package test - - pipeline myPipeline { - (f: () -> ()) {}; - } - `, - expected: false, - }, - { - testName: 'expression lambda parameter', - code: ` - package test - - pipeline myPipeline { - (f: () -> ()) -> 1; - } - `, - expected: false, - }, - ])('should return whether a parameter is pure ($testName)', async ({ code, expected }) => { - const parameter = await getNodeOfType(services, code, isTslParameter); - expect(purityComputer.isPureParameter(parameter)).toBe(expected); - }); - }); - - describe('callableHasSideEffects', () => { - it.each([ - { - testName: 'pure function', - code: ` - package test - - @Pure - fun f() - `, - expected: false, - }, - { - testName: 'impure function without reasons', - code: ` - package test - - @Impure([]) - fun f() - `, - expected: false, - }, - { - testName: 'impure function with reasons but no side effects', - code: ` - package test - - @Impure([ImpurityReason.FileReadFromConstantPath("file.txt")]) - fun f() - `, - expected: false, - }, - { - testName: 'impure function with reasons and side effects', - code: ` - package test - - @Impure([ImpurityReason.Other]) - fun f() - `, - expected: true, - }, - { - testName: 'endless recursion', - code: ` - package test - - segment a() { - a(); - } - `, - expected: true, - }, - { - testName: 'unknown callable', - code: ` - package test - - segment a() { - unresolved(); - } - `, - expected: true, - }, - { - testName: 'potentially impure parameter call', - code: ` - package test - - segment mySegment(param: () -> ()) { - param(); - } - `, - expected: true, - }, - { - testName: 'pure parameter call', - code: ` - package test - - class MyClass(param: () -> (result: Int), value: Int = param()) - `, - expected: false, - }, - ])('should return whether a callable has side effects ($testName)', async ({ code, expected }) => { - const callable = await getNodeOfType(services, code, isTslCallable); - expect(purityComputer.callableHasSideEffects(callable)).toBe(expected); - }); - }); - - describe('expressionHasSideEffects', () => { - it.each([ - { - testName: 'call of pure function', - code: ` - package test - - pipeline myPipeline { - f(); - } - - @Pure - fun f() - `, - expected: false, - }, - { - testName: 'call of impure function without reasons', - code: ` - package test - - pipeline myPipeline { - f(); - } - - @Impure([]) - fun f() - `, - expected: false, - }, - { - testName: 'call of impure function with reasons but no side effects', - code: ` - package test - - pipeline myPipeline { - f(); - } - - @Impure([ImpurityReason.FileReadFromConstantPath("file.txt")]) - fun f() - `, - expected: false, - }, - { - testName: 'call of impure function with reasons and side effects', - code: ` - package test - - pipeline myPipeline { - f(); - } - - @Impure([ImpurityReason.Other]) - fun f() - `, - expected: true, - }, - { - testName: 'lambda', - code: ` - package test - - pipeline myPipeline { - () -> f(); - } - - @Impure([ImpurityReason.Other]) - fun f() - `, - expected: false, - }, - { - testName: 'endless recursion', - code: ` - package test - - segment a() { - a(); - } - `, - expected: true, - }, - { - testName: 'unknown callable', - code: ` - package test - - segment a() { - unresolved(); - } - `, - expected: true, - }, - { - testName: 'potentially impure parameter call', - code: ` - package test - - segment mySegment(param: () -> ()) { - param(); - } - `, - expected: true, - }, - { - testName: 'pure parameter call', - code: ` - package test - - class MyClass(param: () -> (result: Int), value: Int = param()) - `, - expected: false, - }, - ])('should return whether an expression has side effects ($testName)', async ({ code, expected }) => { - const expression = await getNodeOfType(services, code, isTslExpression); - expect(purityComputer.expressionHasSideEffects(expression)).toBe(expected); - }); - }); - - describe('getImpurityReasonsForCallable', () => { - it.each([ - { - testName: 'pure function', - code: ` - package test - - @Pure - fun f() - `, - expected: [], - }, - { - testName: 'impure function without reasons', - code: ` - package test - - @Impure([]) - fun f() - `, - expected: [], - }, - { - testName: 'impure function with reasons (all valid)', - code: ` - package test - - @Impure([ - ImpurityReason.FileReadFromConstantPath("file.txt"), - ImpurityReason.FileReadFromParameterizedPath("p"), - ImpurityReason.FileWriteToConstantPath("file.txt"), - ImpurityReason.FileWriteToParameterizedPath("p"), - ImpurityReason.PotentiallyImpureParameterCall("g"), - ImpurityReason.Other - ]) - fun f(g: () -> (), p: String) - `, - expected: [ - 'File read from "file.txt"', - 'File read from test.f.p', - 'File write to "file.txt"', - 'File write to test.f.p', - 'Potentially impure call of test.f.g', - 'Other', - ], - }, - { - testName: 'impure function with reasons (all invalid)', - code: ` - package test - - @Impure([ - ImpurityReason.FileReadFromConstantPath(1), - ImpurityReason.FileReadFromParameterizedPath(1), - ImpurityReason.FileReadFromParameterizedPath("p"), - ImpurityReason.FileWriteToConstantPath(1), - ImpurityReason.FileWriteToParameterizedPath(1), - ImpurityReason.FileWriteToParameterizedPath("p"), - ImpurityReason.PotentiallyImpureParameterCall(1), - ImpurityReason.PotentiallyImpureParameterCall("g"), - ]) - fun f() - `, - expected: [ - 'File read from ?', - 'File read from ?', - 'File read from ?', - 'File write to ?', - 'File write to ?', - 'File write to ?', - 'Potentially impure call of ?', - 'Potentially impure call of ?', - ], - }, - { - testName: 'propagated', - code: ` - package test - - segment mySegment() { - f(); - g(); - } - - @Impure([ImpurityReason.Other]) - fun f() - - @Impure([ImpurityReason.FileReadFromConstantPath("file.txt")]) - fun g() - `, - expected: ['Other', 'File read from "file.txt"'], - }, - { - testName: 'endless recursion', - code: ` - package test - - segment a() { - a(); - } - `, - expected: ['Endless recursion'], - }, - { - testName: 'unknown callable', - code: ` - package test - - segment a() { - unresolved(); - } - `, - expected: ['Unknown callable call'], - }, - { - testName: 'potentially impure parameter call', - code: ` - package test - - segment mySegment(param: () -> ()) { - param(); - } - `, - expected: ['Potentially impure call of test.mySegment.param'], - }, - { - testName: 'pure parameter call', - code: ` - package test - - class MyClass(param: () -> (result: Int), value: Int = param()) - `, - expected: [], - }, - ])('should return the impurity reasons of a callable ($testName)', async ({ code, expected }) => { - const callable = await getNodeOfType(services, code, isTslCallable); - const actual = purityComputer.getImpurityReasonsForCallable(callable).map((reason) => reason.toString()); - expect(actual).toStrictEqual(expected); - }); - }); - - describe('getImpurityReasonsForExpression', () => { - it.each([ - { - testName: 'call of pure function', - code: ` - package test - - pipeline myPipeline { - f(); - } - - @Pure - fun f() - `, - expected: [], - }, - { - testName: 'call of impure function without reasons', - code: ` - package test - - pipeline myPipeline { - f(); - } - - @Impure([]) - fun f() - `, - expected: [], - }, - { - testName: 'call of impure function with reasons but no side effects', - code: ` - package test - - pipeline myPipeline { - f(); - } - - @Impure([ImpurityReason.FileReadFromConstantPath("file.txt")]) - fun f() - `, - expected: ['File read from "file.txt"'], - }, - { - testName: 'call of impure function with reasons and side effects', - code: ` - package test - - pipeline myPipeline { - f(); - } - - @Impure([ImpurityReason.Other]) - fun f() - `, - expected: ['Other'], - }, - { - testName: 'lambda', - code: ` - package test - - pipeline myPipeline { - () -> f(); - } - - @Impure([ImpurityReason.Other]) - fun f() - `, - expected: [], - }, - { - testName: 'endless recursion', - code: ` - package test - - segment a() { - a(); - } - `, - expected: ['Endless recursion'], - }, - { - testName: 'unknown callable', - code: ` - package test - - segment a() { - unresolved(); - } - `, - expected: ['Unknown callable call'], - }, - { - testName: 'potentially impure parameter call', - code: ` - package test - - segment mySegment(param: () -> ()) { - param(); - } - `, - expected: ['Potentially impure call of test.mySegment.param'], - }, - { - testName: 'pure parameter call', - code: ` - package test - - class MyClass(param: () -> (result: Int), value: Int = param()) - `, - expected: [], - }, - ])('should return the impurity reasons of an expression ($testName)', async ({ code, expected }) => { - const expression = await getNodeOfType(services, code, isTslExpression); - const actual = purityComputer - .getImpurityReasonsForExpression(expression) - .map((reason) => reason.toString()); - expect(actual).toStrictEqual(expected); - }); - - /* - * This code caused a stack overflow error in a prior implementation of the purity computer: - * 1. "f()" calls the parameter "f". - * 2. For called parameters, we check whether they must be pure. Otherwise, we add an impurity reason. - * 3. This requires the computation of the impurity reasons of the containing callable "myFunction". - * 4. This requires visiting all calls inside "myFunction". - * 5. This includes the call of "f()". - * 6. We compute the impurity reasons of "f()" and are back at the start. - */ - it('should return the impurity reasons of a parameter call in a function', async () => { - const call = await getNodeOfType( - services, - ` - package test - - @Pure fun default() -> result: Any - - @Pure fun myFunction( - f: () -> (result: Any) = default, - g: Any = f() - ) - `, - isTslCall, - ); - - expect(() => purityComputer.getImpurityReasonsForExpression(call)).not.toThrow(); - }); - }); -}); From 9ab9d8965a5ad2ec4e718874d66542d7f48fea35 Mon Sep 17 00:00:00 2001 From: methr0 Date: Tue, 23 Jul 2024 13:22:44 +0200 Subject: [PATCH 131/183] remove partial evaluation tests --- .../canBeValueOfConstantParameter.test.ts | 183 ------ .../language/partialEvaluation/model.test.ts | 622 ------------------ .../safe-ds-partial-evalutator.test.ts | 63 -- 3 files changed, 868 deletions(-) delete mode 100644 packages/ttsl-lang/tests/language/partialEvaluation/canBeValueOfConstantParameter.test.ts delete mode 100644 packages/ttsl-lang/tests/language/partialEvaluation/model.test.ts delete mode 100644 packages/ttsl-lang/tests/language/partialEvaluation/safe-ds-partial-evalutator.test.ts diff --git a/packages/ttsl-lang/tests/language/partialEvaluation/canBeValueOfConstantParameter.test.ts b/packages/ttsl-lang/tests/language/partialEvaluation/canBeValueOfConstantParameter.test.ts deleted file mode 100644 index 3516769a..00000000 --- a/packages/ttsl-lang/tests/language/partialEvaluation/canBeValueOfConstantParameter.test.ts +++ /dev/null @@ -1,183 +0,0 @@ -import { NodeFileSystem } from 'langium/node'; -import { describe, expect, it } from 'vitest'; -import { isTslExpression } from '../../../src/language/generated/ast.js'; -import { getNodeOfType } from '../../helpers/nodeFinder.js'; -import { createTTSLServices } from '../../../src/language/index.js'; - -const services = (await createTTSLServices(NodeFileSystem)).TTSL; -const partialEvaluator = services.evaluation.PartialEvaluator; - -describe('TTSLTypeChecker', async () => { - const testCases: CanBeValueOfConstantParameterTest[] = [ - { - code: 'true', - expected: true, - }, - { - code: 'false', - expected: true, - }, - { - code: '1.5', - expected: true, - }, - { - code: '1', - expected: true, - }, - { - code: 'null', - expected: true, - }, - { - code: '"text"', - expected: true, - }, - { - code: 'unresolved()', - expected: true, - }, - { - code: 'MyClass()', - expected: false, - }, - { - code: 'MyEnum.EnumVariantWithoutParameters()', - expected: true, - }, - { - code: 'MyEnum.NormalEnumVariantWithParameters()', - expected: true, - }, - { - code: 'MyEnum.ConstantEnumVariantWithParameters()', - expected: true, - }, - { - code: 'MyEnum.NormalEnumVariantWithParameters(1)', - expected: true, - }, - { - code: 'MyEnum.ConstantEnumVariantWithParameters(1)', - expected: true, - }, - { - code: 'MyEnum.NormalEnumVariantWithParameters([1][0])', - expected: false, - }, - { - code: 'MyEnum.ConstantEnumVariantWithParameters([1][0])', - expected: false, - }, - { - code: '[]', - expected: true, - }, - { - code: '[1]', - expected: true, - }, - { - code: '[1, MyClass()]', - expected: false, - }, - { - code: '{}', - expected: true, - }, - { - code: '{ "key": 1 }', - expected: true, - }, - { - code: '{ "key": MyClass() }', - expected: false, - }, - { - code: '{ MyClass(): 1 }', - expected: false, - }, - { - code: 'Unresolved.a', - expected: true, - }, - { - code: 'MyEnum.Unresolved', - expected: true, - }, - { - code: 'MyClass.a', - expected: false, - }, - { - code: 'MyEnum.EnumVariantWithoutParameters', - expected: true, - }, - { - code: 'MyEnum.NormalEnumVariantWithParameters', - expected: true, - }, - { - code: 'MyEnum.ConstantEnumVariantWithParameters', - expected: true, - }, - { - code: '-1', - expected: true, - }, - { - code: '-[1][0]', - expected: false, - }, - { - code: 'Unresolved', - expected: true, - }, - { - code: 'MyClass', - expected: false, - }, - { - code: '[1][0]', - expected: false, - }, - ]; - - describe.each(testCases)('canBeValueOfConstantParameter', ({ code, expected }) => { - it(code, async () => { - const codeWithContext = ` - class MyClass() { - static attr a: Int - } - - enum MyEnum { - EnumVariantWithoutParameters - NormalEnumVariantWithParameters(param: Int) - ConstantEnumVariantWithParameters(const param: Int) - } - - pipeline myPipeline { - ${code}; - } - `; - - const expression = await getNodeOfType(services, codeWithContext, isTslExpression); - expect(partialEvaluator.canBeValueOfConstantParameter(expression)).toBe(expected); - }); - }); -}); - -/** - * A test case for {@link TTSLPartialEvaluator.canBeValueOfConstantParameter}. - */ -interface CanBeValueOfConstantParameterTest { - /** - * The code containing the expression to test. - */ - code: string; - - /** - * Whether {@link node} is expected to be usable as the value of a constant parameter. - */ - expected: boolean; -} diff --git a/packages/ttsl-lang/tests/language/partialEvaluation/model.test.ts b/packages/ttsl-lang/tests/language/partialEvaluation/model.test.ts deleted file mode 100644 index 7c5c81dd..00000000 --- a/packages/ttsl-lang/tests/language/partialEvaluation/model.test.ts +++ /dev/null @@ -1,622 +0,0 @@ -import { EmptyFileSystem } from 'langium'; -import { describe, expect, it } from 'vitest'; -import { - isTslBlockLambda, - isTslEnumVariant, - isTslExpressionLambda, - isTslResult, - isTslSegment, - type TslBlockLambdaResult, -} from '../../../src/language/generated/ast.js'; -import { createTTSLServices, getAbstractResults, getParameters } from '../../../src/language/index.js'; -import { - BlockLambdaClosure, - BooleanConstant, - Constant, - EvaluatedEnumVariant, - EvaluatedList, - EvaluatedMap, - EvaluatedMapEntry, - EvaluatedNamedTuple, - EvaluatedNode, - ExpressionLambdaClosure, - FloatConstant, - IntConstant, - NamedCallable, - NullConstant, - StringConstant, - UnknownEvaluatedNode, -} from '../../../src/language/partialEvaluation/model.js'; -import { getNodeOfType } from '../../helpers/nodeFinder.js'; -import type { EqualsTest, ToStringTest } from '../../helpers/testDescription.js'; - -const services = (await createTTSLServices(EmptyFileSystem, { omitBuiltins: true })).TTSL; -const code = ` -enum MyEnum { - MyEnumVariant1 - MyEnumVariant2(p: Int) -} -segment mySegment() -> (result1: Int, result2: Int) { - () -> 1; - () -> 2; - - (() { yield a; })().a; - MyEnum; -} - -segment mySegment2() {} -`; -const enumVariantWithoutParameters = await getNodeOfType(services, code, isTslEnumVariant, 0); -const enumVariantWithParameters = await getNodeOfType(services, code, isTslEnumVariant, 1); -const enumVariantParameter = getParameters(enumVariantWithParameters)[0]!; - -const result1 = await getNodeOfType(services, code, isTslResult, 0); -const result2 = await getNodeOfType(services, code, isTslResult, 0); - -const expressionLambda1 = await getNodeOfType(services, code, isTslExpressionLambda, 0); -const expressionLambda2 = await getNodeOfType(services, code, isTslExpressionLambda, 1); - -const blockLambda1 = await getNodeOfType(services, code, isTslBlockLambda, 0); -const blockLambdaResult1 = getAbstractResults(blockLambda1)[0]! as TslBlockLambdaResult; - -const segment1 = await getNodeOfType(services, code, isTslSegment, 0); -const segment2 = await getNodeOfType(services, code, isTslSegment, 1); - -describe('partial evaluation model', async () => { - const equalsTests: EqualsTest[] = [ - { - value: () => new BooleanConstant(true), - unequalValueOfSameType: () => new BooleanConstant(false), - valueOfOtherType: () => NullConstant, - }, - { - value: () => new FloatConstant(1.0), - unequalValueOfSameType: () => new FloatConstant(2.0), - valueOfOtherType: () => NullConstant, - }, - { - value: () => new IntConstant(1n), - unequalValueOfSameType: () => new IntConstant(2n), - valueOfOtherType: () => NullConstant, - }, - { - value: () => NullConstant, - valueOfOtherType: () => new StringConstant('foo'), - }, - { - value: () => new StringConstant('foo'), - unequalValueOfSameType: () => new StringConstant('bar'), - valueOfOtherType: () => NullConstant, - }, - { - value: () => new BlockLambdaClosure(blockLambda1, new Map([[enumVariantParameter, NullConstant]])), - unequalValueOfSameType: () => new BlockLambdaClosure(blockLambda1, new Map()), - valueOfOtherType: () => NullConstant, - }, - { - value: () => - new ExpressionLambdaClosure(expressionLambda1, new Map([[enumVariantParameter, NullConstant]])), - unequalValueOfSameType: () => new ExpressionLambdaClosure(expressionLambda2, new Map()), - valueOfOtherType: () => NullConstant, - }, - { - value: () => new NamedCallable(segment1), - unequalValueOfSameType: () => new NamedCallable(segment2), - valueOfOtherType: () => NullConstant, - }, - { - value: () => - new EvaluatedEnumVariant(enumVariantWithParameters, new Map([[enumVariantParameter, NullConstant]])), - unequalValueOfSameType: () => new EvaluatedEnumVariant(enumVariantWithoutParameters, new Map()), - valueOfOtherType: () => NullConstant, - }, - { - value: () => new EvaluatedList([new IntConstant(1n)]), - unequalValueOfSameType: () => new EvaluatedList([new IntConstant(2n)]), - valueOfOtherType: () => NullConstant, - }, - { - value: () => new EvaluatedMap([new EvaluatedMapEntry(NullConstant, NullConstant)]), - unequalValueOfSameType: () => new EvaluatedMap([new EvaluatedMapEntry(NullConstant, new IntConstant(1n))]), - valueOfOtherType: () => NullConstant, - }, - { - value: () => new EvaluatedMapEntry(NullConstant, NullConstant), - unequalValueOfSameType: () => new EvaluatedMapEntry(UnknownEvaluatedNode, NullConstant), - valueOfOtherType: () => NullConstant, - }, - { - value: () => new EvaluatedNamedTuple(new Map([[result1, NullConstant]])), - unequalValueOfSameType: () => new EvaluatedNamedTuple(new Map()), - valueOfOtherType: () => NullConstant, - }, - { - value: () => UnknownEvaluatedNode, - valueOfOtherType: () => NullConstant, - }, - ]; - - describe.each(equalsTests)('equals', ({ value, unequalValueOfSameType, valueOfOtherType }) => { - it(`should return true if both nodes are the same instance (${value().constructor.name})`, () => { - const nodeInstance = value(); - expect(nodeInstance.equals(nodeInstance)).toBeTruthy(); - }); - - it(`should return true if both nodes have the same values (${value().constructor.name})`, () => { - expect(value().equals(value())).toBeTruthy(); - }); - - if (unequalValueOfSameType) { - it(`should return false if both nodes have different values (${value().constructor.name})`, () => { - expect(value().equals(unequalValueOfSameType())).toBeFalsy(); - }); - } - - if (valueOfOtherType) { - it(`should return false if the other node is an instance of another class (${ - value().constructor.name - })`, () => { - expect(value().equals(valueOfOtherType())).toBeFalsy(); - }); - } - }); - - const toStringTests: ToStringTest[] = [ - { - value: new BooleanConstant(true), - expectedString: 'true', - }, - { - value: new FloatConstant(1.5), - expectedString: '1.5', - }, - { - value: new IntConstant(1n), - expectedString: '1', - }, - { - value: NullConstant, - expectedString: 'null', - }, - { - value: new StringConstant('foo'), - expectedString: '"foo"', - }, - { - value: new BlockLambdaClosure(blockLambda1, new Map()), - expectedString: '$blockLambdaClosure', - }, - { - value: new ExpressionLambdaClosure(expressionLambda1, new Map()), - expectedString: '$expressionLambdaClosure', - }, - { - value: new NamedCallable(segment1), - expectedString: 'mySegment', - }, - { - value: new EvaluatedEnumVariant(enumVariantWithoutParameters, undefined), - expectedString: 'MyEnumVariant1', - }, - { - value: new EvaluatedEnumVariant(enumVariantWithParameters, undefined), - expectedString: 'MyEnumVariant2', - }, - { - value: new EvaluatedEnumVariant( - enumVariantWithParameters, - new Map([[enumVariantParameter, UnknownEvaluatedNode]]), - ), - expectedString: 'MyEnumVariant2(p = ?)', - }, - { - value: new EvaluatedEnumVariant(enumVariantWithParameters, new Map([[enumVariantParameter, NullConstant]])), - expectedString: 'MyEnumVariant2(p = null)', - }, - { - value: new EvaluatedList([]), - expectedString: '[]', - }, - { - value: new EvaluatedList([NullConstant]), - expectedString: '[null]', - }, - { - value: new EvaluatedMap([]), - expectedString: '{}', - }, - { - value: new EvaluatedMap([new EvaluatedMapEntry(NullConstant, NullConstant)]), - expectedString: '{null: null}', - }, - { - value: new EvaluatedMapEntry(NullConstant, NullConstant), - expectedString: 'null: null', - }, - { - value: new EvaluatedNamedTuple(new Map()), - expectedString: '()', - }, - { - value: new EvaluatedNamedTuple(new Map([[result1, NullConstant]])), - expectedString: '(result1 = null)', - }, - { - value: new EvaluatedNamedTuple(new Map([[result1, UnknownEvaluatedNode]])), - expectedString: '(result1 = ?)', - }, - { - value: UnknownEvaluatedNode, - expectedString: '?', - }, - ]; - - describe.each(toStringTests)('toString', ({ value, expectedString }) => { - it(`should return the expected string representation (${value.constructor.name} -- ${value})`, () => { - expect(value.toString()).toStrictEqual(expectedString); - }); - }); - - const isFullyEvaluatedTests: IsFullyEvaluatedTest[] = [ - { - node: new BooleanConstant(true), - expectedValue: true, - }, - { - node: new FloatConstant(1.0), - expectedValue: true, - }, - { - node: new IntConstant(1n), - expectedValue: true, - }, - { - node: NullConstant, - expectedValue: true, - }, - { - node: new StringConstant('foo'), - expectedValue: true, - }, - { - node: new BlockLambdaClosure(blockLambda1, new Map()), - expectedValue: false, - }, - { - node: new ExpressionLambdaClosure(expressionLambda1, new Map()), - expectedValue: false, - }, - { - node: new NamedCallable(segment1), - expectedValue: false, - }, - { - node: new EvaluatedEnumVariant(enumVariantWithoutParameters, undefined), - expectedValue: true, - }, - { - node: new EvaluatedEnumVariant(enumVariantWithParameters, undefined), - expectedValue: false, - }, - { - node: new EvaluatedEnumVariant( - enumVariantWithParameters, - new Map([[enumVariantParameter, UnknownEvaluatedNode]]), - ), - expectedValue: false, - }, - { - node: new EvaluatedEnumVariant(enumVariantWithParameters, new Map([[enumVariantParameter, NullConstant]])), - expectedValue: true, - }, - { - node: new EvaluatedList([NullConstant]), - expectedValue: true, - }, - { - node: new EvaluatedList([UnknownEvaluatedNode]), - expectedValue: false, - }, - { - node: new EvaluatedMap([new EvaluatedMapEntry(NullConstant, NullConstant)]), - expectedValue: true, - }, - { - node: new EvaluatedMap([new EvaluatedMapEntry(UnknownEvaluatedNode, NullConstant)]), - expectedValue: false, - }, - { - node: new EvaluatedMap([new EvaluatedMapEntry(NullConstant, UnknownEvaluatedNode)]), - expectedValue: false, - }, - { - node: new EvaluatedMapEntry(NullConstant, NullConstant), - expectedValue: true, - }, - { - node: new EvaluatedMapEntry(UnknownEvaluatedNode, NullConstant), - expectedValue: false, - }, - { - node: new EvaluatedMapEntry(NullConstant, UnknownEvaluatedNode), - expectedValue: false, - }, - { - node: new EvaluatedNamedTuple(new Map()), - expectedValue: true, - }, - { - node: new EvaluatedNamedTuple(new Map([[result1, NullConstant]])), - expectedValue: true, - }, - { - node: new EvaluatedNamedTuple(new Map([[result1, UnknownEvaluatedNode]])), - expectedValue: false, - }, - { - node: UnknownEvaluatedNode, - expectedValue: false, - }, - ]; - describe.each(isFullyEvaluatedTests)('isFullyEvaluated', ({ node, expectedValue }) => { - it(`should return the expected value (${node.constructor.name} -- ${node})`, () => { - expect(node.isFullyEvaluated).toStrictEqual(expectedValue); - }); - }); - - const toInterpolationStringTests: ToStringTest[] = [ - { value: new BooleanConstant(true), expectedString: 'true' }, - { value: new FloatConstant(1.5), expectedString: '1.5' }, - { value: new IntConstant(1n), expectedString: '1' }, - { value: NullConstant, expectedString: 'null' }, - { value: new StringConstant('foo'), expectedString: 'foo' }, - ]; - - describe.each(toInterpolationStringTests)('toInterpolationString', ({ value, expectedString }) => { - it(`should return the expected string representation (${value.constructor.name} -- ${value})`, () => { - expect(value.toInterpolationString()).toStrictEqual(expectedString); - }); - }); - - describe('EvaluatedEnumVariant', () => { - describe('isFullyEvaluated', () => { - it.each([ - { - variant: new EvaluatedEnumVariant(enumVariantWithoutParameters, undefined), - expectedValue: true, - }, - { - variant: new EvaluatedEnumVariant(enumVariantWithParameters, undefined), - expectedValue: false, - }, - { - variant: new EvaluatedEnumVariant( - enumVariantWithParameters, - new Map([[enumVariantParameter, NullConstant]]), - ), - expectedValue: true, - }, - { - variant: new EvaluatedEnumVariant( - enumVariantWithParameters, - new Map([[enumVariantParameter, UnknownEvaluatedNode]]), - ), - expectedValue: false, - }, - ])('should return the expected value (%#)', ({ variant, expectedValue }) => { - expect(variant.isFullyEvaluated).toStrictEqual(expectedValue); - }); - }); - - describe('getParameterValueByName', () => { - it.each([ - { - variant: new EvaluatedEnumVariant(enumVariantWithParameters, undefined), - name: 'p', - expectedValue: UnknownEvaluatedNode, - }, - { - variant: new EvaluatedEnumVariant( - enumVariantWithParameters, - new Map([[enumVariantParameter, NullConstant]]), - ), - name: 'q', - expectedValue: UnknownEvaluatedNode, - }, - { - variant: new EvaluatedEnumVariant( - enumVariantWithParameters, - new Map([[enumVariantParameter, NullConstant]]), - ), - name: 'p', - expectedValue: NullConstant, - }, - ])('should return the element at the given index (%#)', ({ variant, name, expectedValue }) => { - expect(variant.getParameterValueByName(name)).toStrictEqual(expectedValue); - }); - }); - }); - - describe('EvaluatedList', () => { - describe('isFullyEvaluated', () => { - it.each([ - { - list: new EvaluatedList([]), - expectedValue: true, - }, - { - list: new EvaluatedList([NullConstant]), - expectedValue: true, - }, - { - list: new EvaluatedList([UnknownEvaluatedNode]), - expectedValue: false, - }, - ])('should return the expected value (%#)', ({ list, expectedValue }) => { - expect(list.isFullyEvaluated).toStrictEqual(expectedValue); - }); - }); - - describe('getElementByIndex', () => { - it.each([ - { - list: new EvaluatedList([]), - index: 0, - expectedValue: UnknownEvaluatedNode, - }, - { - list: new EvaluatedList([new IntConstant(1n)]), - index: 0, - expectedValue: new IntConstant(1n), - }, - ])('should return the element at the given index (%#)', ({ list, index, expectedValue }) => { - expect(list.getElementByIndex(index)).toStrictEqual(expectedValue); - }); - }); - }); - - describe('EvaluatedMap', () => { - describe('isFullyEvaluated', () => { - it.each([ - { - map: new EvaluatedMap([]), - expectedValue: true, - }, - { - map: new EvaluatedMap([new EvaluatedMapEntry(NullConstant, NullConstant)]), - expectedValue: true, - }, - { - map: new EvaluatedMap([new EvaluatedMapEntry(UnknownEvaluatedNode, NullConstant)]), - expectedValue: false, - }, - { - map: new EvaluatedMap([new EvaluatedMapEntry(NullConstant, UnknownEvaluatedNode)]), - expectedValue: false, - }, - ])('should return the expected value (%#)', ({ map, expectedValue }) => { - expect(map.isFullyEvaluated).toStrictEqual(expectedValue); - }); - }); - - describe('getLastValueForKey', () => { - it.each([ - { - map: new EvaluatedMap([]), - key: NullConstant, - expectedValue: UnknownEvaluatedNode, - }, - { - map: new EvaluatedMap([new EvaluatedMapEntry(NullConstant, NullConstant)]), - key: NullConstant, - expectedValue: NullConstant, - }, - { - map: new EvaluatedMap([ - new EvaluatedMapEntry(NullConstant, NullConstant), - new EvaluatedMapEntry(NullConstant, new IntConstant(1n)), - ]), - key: NullConstant, - expectedValue: new IntConstant(1n), - }, - ])('should return the last value for the given key (%#)', ({ map, key, expectedValue }) => { - expect(map.getLastValueForKey(key)).toStrictEqual(expectedValue); - }); - }); - }); - - describe('EvaluatedNamedTuple', () => { - describe('isFullyEvaluated', () => { - it.each([ - { - tuple: new EvaluatedNamedTuple(new Map()), - expectedValue: true, - }, - { - tuple: new EvaluatedNamedTuple(new Map([[result1, NullConstant]])), - expectedValue: true, - }, - { - tuple: new EvaluatedNamedTuple(new Map([[result1, UnknownEvaluatedNode]])), - expectedValue: false, - }, - ])('should return the expected value (%#)', ({ tuple, expectedValue }) => { - expect(tuple.isFullyEvaluated).toStrictEqual(expectedValue); - }); - }); - - describe('getResultValueByName', () => { - it.each([ - { - tuple: new EvaluatedNamedTuple(new Map([[blockLambdaResult1, NullConstant]])), - name: 'a', - expectedValue: NullConstant, - }, - { - tuple: new EvaluatedNamedTuple(new Map([[result1, NullConstant]])), - name: 'b', - expectedValue: UnknownEvaluatedNode, - }, - ])( - 'should return the substitution for the target of the given reference', - ({ tuple, name, expectedValue }) => { - expect(tuple.getResultValueByName(name)).toStrictEqual(expectedValue); - }, - ); - }); - - describe('getResultValueByIndex', () => { - it.each([ - { - tuple: new EvaluatedNamedTuple(new Map()), - index: 0, - expectedValue: UnknownEvaluatedNode, - }, - { - tuple: new EvaluatedNamedTuple(new Map([[result1, NullConstant]])), - index: 0, - expectedValue: NullConstant, - }, - ])('should return the substitution at the given index', ({ tuple, index, expectedValue }) => { - expect(tuple.getResultValueByIndex(index)).toStrictEqual(expectedValue); - }); - }); - - describe('unwrap', () => { - it('should return the single substitution if the tuple contains exactly one substitution', () => { - const tuple = new EvaluatedNamedTuple(new Map([[result1, NullConstant]])); - expect(tuple.unwrap()).toStrictEqual(NullConstant); - }); - - it('should return the tuple if it contains no substitutions', () => { - const tuple = new EvaluatedNamedTuple(new Map([])); - expect(tuple.unwrap()).toStrictEqual(tuple); - }); - - it('should return the tuple if it contains more than one substitution', () => { - const tuple = new EvaluatedNamedTuple( - new Map([ - [result1, NullConstant], - [result2, NullConstant], - ]), - ); - expect(tuple.unwrap()).toStrictEqual(tuple); - }); - }); - }); -}); - -/** - * Tests for {@link EvaluatedNode.isFullyEvaluated}. - */ -interface IsFullyEvaluatedTest { - /** - * The node to test. - */ - node: EvaluatedNode; - - /** - * Whether the node is fully evaluated. - */ - expectedValue: boolean; -} diff --git a/packages/ttsl-lang/tests/language/partialEvaluation/safe-ds-partial-evalutator.test.ts b/packages/ttsl-lang/tests/language/partialEvaluation/safe-ds-partial-evalutator.test.ts deleted file mode 100644 index c8a70afc..00000000 --- a/packages/ttsl-lang/tests/language/partialEvaluation/safe-ds-partial-evalutator.test.ts +++ /dev/null @@ -1,63 +0,0 @@ -import { AssertionError } from 'assert'; -import { NodeFileSystem } from 'langium/node'; -import { describe, it } from 'vitest'; -import { locationToString } from '../../../src/helpers/locations.js'; -import { getNodeByLocation } from '../../helpers/nodeFinder.js'; -import { loadDocuments } from '../../helpers/testResources.js'; -import { createPartialEvaluationTests } from './creator.js'; -import { createTTSLServices } from '../../../src/language/index.js'; - -const services = (await createTTSLServices(NodeFileSystem)).TTSL; -const partialEvaluator = services.evaluation.PartialEvaluator; - -describe('partial evaluation', async () => { - it.each(await createPartialEvaluationTests())('$testName', async (test) => { - // Test is invalid - if (test.error) { - throw test.error; - } - - // Load all documents - await loadDocuments(services, test.uris); - - // Ensure that partially evaluating nodes in the same equivalence class yields the same result - for (const equivalenceClassAssertion of test.equivalenceClassAssertions) { - if (equivalenceClassAssertion.locations.length > 1) { - const firstLocation = equivalenceClassAssertion.locations[0]!; - const firstNode = getNodeByLocation(services, firstLocation); - const firstValue = partialEvaluator.evaluate(firstNode); - - for (const currentLocation of equivalenceClassAssertion.locations.slice(1)) { - const currentNode = getNodeByLocation(services, currentLocation); - const currentValue = partialEvaluator.evaluate(currentNode); - - if (!currentValue.equals(firstValue)) { - throw new AssertionError({ - message: `Two nodes in the same equivalence class are simplified differently.\n Current location: ${locationToString( - currentLocation, - )}\n First location: ${locationToString(firstLocation)}`, - actual: currentValue.toString(), - expected: firstValue.toString(), - }); - } - } - } - } - - // Ensure the serializing the result of partially evaluating a node yields the expected value - for (const serializationAssertion of test.serializationAssertions) { - const node = getNodeByLocation(services, serializationAssertion.location); - const actualValue = partialEvaluator.evaluate(node); - - if (actualValue.toString() !== serializationAssertion.expectedValue) { - throw new AssertionError({ - message: `A node has the wrong serialized simplification.\n Location: ${locationToString( - serializationAssertion.location, - )}`, - actual: actualValue.toString(), - expected: serializationAssertion.expectedValue, - }); - } - } - }); -}); From b1eb3eb7021285f6506f9cfb220ebd7e4af80205 Mon Sep 17 00:00:00 2001 From: methr0 Date: Tue, 23 Jul 2024 13:23:47 +0200 Subject: [PATCH 132/183] remove old Types in tests --- .../language/lsp/ttsl-node-kind-provider.ts | 6 + .../ttsl-lang/src/language/typing/model.ts | 13 +- .../tests/helpers/nodeFinder.test.ts | 34 +- .../builtins/builtinFilesCorrectness.test.ts | 2 - .../safe-ds-comment-provider.test.ts | 150 +- .../safe-ds-documentation-provider.test.ts | 51 +- .../flow/safe-ds-call-graph-computer.test.ts | 6 - .../assigneeToAssignedObject.test.ts | 118 +- .../callToParameterValue.test.ts | 19 +- .../parametersToArguments.test.ts | 111 -- .../resultToYields.test.ts | 48 - .../typeArgumentToTypeParameter.test.ts | 134 -- .../safe-ds-document-symbol-provider.test.ts | 177 +-- .../language/partialEvaluation/creator.ts | 173 --- .../tests/language/scoping/scoping.test.ts | 41 +- .../tests/language/typing/model.test.ts | 508 +------ .../typing/safe-ds-class-hierarchy.test.ts | 432 ------ .../canBeTypeOfConstantParameter.test.ts | 75 +- .../type checker/isSubOrSupertypeOf.test.ts | 1256 ----------------- .../computeClassTypeForLiteralType.test.ts | 109 -- .../type computer/computeUpperBound.test.ts | 76 - .../type computer/streamSupertypes.test.ts | 143 -- 22 files changed, 150 insertions(+), 3532 deletions(-) delete mode 100644 packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/parametersToArguments.test.ts delete mode 100644 packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/resultToYields.test.ts delete mode 100644 packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/typeArgumentToTypeParameter.test.ts delete mode 100644 packages/ttsl-lang/tests/language/partialEvaluation/creator.ts delete mode 100644 packages/ttsl-lang/tests/language/typing/safe-ds-class-hierarchy.test.ts delete mode 100644 packages/ttsl-lang/tests/language/typing/type checker/isSubOrSupertypeOf.test.ts delete mode 100644 packages/ttsl-lang/tests/language/typing/type computer/computeClassTypeForLiteralType.test.ts delete mode 100644 packages/ttsl-lang/tests/language/typing/type computer/computeUpperBound.test.ts delete mode 100644 packages/ttsl-lang/tests/language/typing/type computer/streamSupertypes.test.ts diff --git a/packages/ttsl-lang/src/language/lsp/ttsl-node-kind-provider.ts b/packages/ttsl-lang/src/language/lsp/ttsl-node-kind-provider.ts index c68811ce..cb607b6a 100644 --- a/packages/ttsl-lang/src/language/lsp/ttsl-node-kind-provider.ts +++ b/packages/ttsl-lang/src/language/lsp/ttsl-node-kind-provider.ts @@ -1,6 +1,8 @@ import { AstNode, AstNodeDescription, isAstNode } from 'langium'; import { CompletionItemKind, SymbolKind } from 'vscode-languageserver'; import { + TslConstant, + TslData, TslFunction, TslModule, TslParameter, @@ -16,6 +18,10 @@ export class TTSLNodeKindProvider implements NodeKindProvider { switch (type) { case TslFunction: return SymbolKind.Function; + case TslConstant: + return SymbolKind.Constant; + case TslData: + return SymbolKind.Data; case TslModule: return SymbolKind.Package; /* c8 ignore next 2 */ diff --git a/packages/ttsl-lang/src/language/typing/model.ts b/packages/ttsl-lang/src/language/typing/model.ts index 89bcd4e2..28aeca7d 100644 --- a/packages/ttsl-lang/src/language/typing/model.ts +++ b/packages/ttsl-lang/src/language/typing/model.ts @@ -1,16 +1,5 @@ -import { AstNode, stream } from 'langium'; +import { stream } from 'langium'; import { isEmpty } from '../../helpers/collections.js'; -import { - TslBooleanType, - TslDictionaryType, - TslFloatType, - TslIntType, - TslListType, - TslStringType, - TslType, - TslTypeParameter, -} from '../generated/ast.js'; -import { getTypeParameters } from '../helpers/nodeProperties.js'; export type TypeParameterSubstitutions =Type[]; diff --git a/packages/ttsl-lang/tests/helpers/nodeFinder.test.ts b/packages/ttsl-lang/tests/helpers/nodeFinder.test.ts index 7a7aa8e0..7df1ed0f 100644 --- a/packages/ttsl-lang/tests/helpers/nodeFinder.test.ts +++ b/packages/ttsl-lang/tests/helpers/nodeFinder.test.ts @@ -4,7 +4,7 @@ import { createTTSLServices } from '../../src/language/index.js'; import { EmptyFileSystem } from 'langium'; import { AssertionError } from 'assert'; import { clearDocuments, parseHelper } from 'langium/test'; -import { isTslClass, isTslDeclaration, isTslEnum } from '../../src/language/generated/ast.js'; +import { isTslConstant, isTslDeclaration, isTslFunction } from '../../src/language/generated/ast.js'; describe('getNodeByLocation', async () => { const services = (await createTTSLServices(EmptyFileSystem, { omitBuiltins: true })).TTSL; @@ -23,7 +23,7 @@ describe('getNodeByLocation', async () => { }); it('should throw if no node is found', async () => { - const document = await parseHelper(services)(`class C`); + const document = await parseHelper(services)(`function F() {}`); expect(() => { getNodeByLocation(services, { @@ -34,25 +34,25 @@ describe('getNodeByLocation', async () => { }); it('should return the node that fills the range completely', async () => { - const document = await parseHelper(services)(`class C`); + const document = await parseHelper(services)(`function F() {}`); expect( getNodeByLocation(services, { uri: document.uri.toString(), - range: { start: { line: 0, character: 0 }, end: { line: 0, character: 7 } }, + range: { start: { line: 0, character: 0 }, end: { line: 0, character: 15 } }, }), - ).to.satisfy(isTslClass); + ).to.satisfy(isTslFunction); }); it('should return the node whose name fills the range completely', async () => { - const document = await parseHelper(services)(`class C`); + const document = await parseHelper(services)(`function F() {}`); expect( getNodeByLocation(services, { uri: document.uri.toString(), - range: { start: { line: 0, character: 6 }, end: { line: 0, character: 7 } }, + range: { start: { line: 0, character: 6 }, end: { line: 0, character: 15 } }, }), - ).to.satisfy(isTslClass); + ).to.satisfy(isTslFunction); }); }); @@ -66,31 +66,31 @@ describe('getNodeOfType', async () => { it('should throw if no node is found', async () => { const code = ''; expect(async () => { - await getNodeOfType(services, code, isTslClass); + await getNodeOfType(services, code, isTslFunction); }).rejects.toThrowErrorMatchingSnapshot(); }); it('should throw if not enough nodes are found', async () => { - const code = `class C`; + const code = `function F() {}`; expect(async () => { - await getNodeOfType(services, code, isTslClass, 1); + await getNodeOfType(services, code, isTslFunction, 1); }).rejects.toThrowErrorMatchingSnapshot(); }); it('should return the first matching node if no index is set', async () => { - const code = 'class C'; - const node = await getNodeOfType(services, code, isTslClass); - expect(node).to.satisfy(isTslClass); + const code = 'function F() {}'; + const node = await getNodeOfType(services, code, isTslFunction); + expect(node).to.satisfy(isTslFunction); }); it('should return the nth matching node if an index is set', async () => { const code = ` package p - class C - enum D + function F() {} + constant C: Int = 0; `; const node = await getNodeOfType(services, code, isTslDeclaration, 2); - expect(node).to.satisfy(isTslEnum); + expect(node).to.satisfy(isTslConstant); }); }); diff --git a/packages/ttsl-lang/tests/language/builtins/builtinFilesCorrectness.test.ts b/packages/ttsl-lang/tests/language/builtins/builtinFilesCorrectness.test.ts index 163fa845..358bf866 100644 --- a/packages/ttsl-lang/tests/language/builtins/builtinFilesCorrectness.test.ts +++ b/packages/ttsl-lang/tests/language/builtins/builtinFilesCorrectness.test.ts @@ -7,7 +7,6 @@ import { isEmpty } from '../../../src/helpers/collections.js'; import { uriToShortenedResourceName } from '../../../src/helpers/resources.js'; import { listBuiltinFiles } from '../../../src/language/builtins/fileFinder.js'; import { createTTSLServices } from '../../../src/language/index.js'; -import { CODE_EXPERIMENTAL_LIBRARY_ELEMENT } from '../../../src/language/validation/builtins/experimental.js'; import { CODE_EXPERIMENTAL_LANGUAGE_FEATURE } from '../../../src/language/validation/experimentalLanguageFeatures.js'; import { locationToString } from '../../../src/helpers/locations.js'; import { loadDocuments } from '../../helpers/testResources.js'; @@ -18,7 +17,6 @@ const builtinFiles = listBuiltinFiles(); const ignoredWarnings: (number | string | undefined)[] = [ CODE_EXPERIMENTAL_LANGUAGE_FEATURE, - CODE_EXPERIMENTAL_LIBRARY_ELEMENT, ]; describe('builtin files', () => { diff --git a/packages/ttsl-lang/tests/language/documentation/safe-ds-comment-provider.test.ts b/packages/ttsl-lang/tests/language/documentation/safe-ds-comment-provider.test.ts index 45babf9c..4abfe355 100644 --- a/packages/ttsl-lang/tests/language/documentation/safe-ds-comment-provider.test.ts +++ b/packages/ttsl-lang/tests/language/documentation/safe-ds-comment-provider.test.ts @@ -2,11 +2,9 @@ import { AssertionError } from 'assert'; import { AstNode, EmptyFileSystem } from 'langium'; import { describe, expect, it } from 'vitest'; import { - isTslAnnotation, - isTslAttribute, - isTslBlockLambdaResult, - isTslEnumVariant, isTslExpressionStatement, + isTslFunction, + isTslLocalVariable, isTslParameter, isTslPlaceholder, isTslResult, @@ -22,22 +20,12 @@ const testComment = '/* test */'; describe('TTSLCommentProvider', () => { const testCases: CommentProviderTest[] = [ { - testName: 'commented module member (without annotations)', + testName: 'commented module member (missing package)', code: ` ${testComment} - annotation MyAnnotation + function F(){} `, - predicate: isTslAnnotation, - expectedComment: testComment, - }, - { - testName: 'commented module member (with annotations, missing package)', - code: ` - ${testComment} - @Test - annotation MyAnnotation - `, - predicate: isTslAnnotation, + predicate: isTslFunction, expectedComment: undefined, }, { @@ -46,115 +34,44 @@ describe('TTSLCommentProvider', () => { package test ${testComment} - @Test - annotation MyAnnotation + function F(){} `, - predicate: isTslAnnotation, + predicate: isTslFunction, expectedComment: testComment, }, { testName: 'uncommented module member', code: ` - annotation MyAnnotation + function F(){} `, - predicate: isTslAnnotation, + predicate: isTslFunction, expectedComment: undefined, }, { - testName: 'commented class member (without annotations)', + testName: 'commented function member', code: ` - class MyClass { + function F() { ${testComment} - attr a: Int + var a: Int = 0; } `, - predicate: isTslAttribute, - expectedComment: testComment, - }, - { - testName: 'commented class member (with annotations)', - code: ` - class MyClass { - ${testComment} - @Test - attr a: Int - } - `, - predicate: isTslAttribute, + predicate: isTslLocalVariable, expectedComment: testComment, }, { testName: 'uncommented class member', code: ` - class MyClass { - attr a: Int - } - `, - predicate: isTslAttribute, - expectedComment: undefined, - }, - { - testName: 'commented enum variant (without annotations)', - code: ` - enum MyEnum { - ${testComment} - MyEnumVariant - } - `, - predicate: isTslEnumVariant, - expectedComment: testComment, - }, - { - testName: 'commented enum variant (with annotations)', - code: ` - enum MyEnum { - ${testComment} - @Test - MyEnumVariant - } - `, - predicate: isTslEnumVariant, - expectedComment: testComment, - }, - { - testName: 'uncommented enum variant', - code: ` - enum MyEnum { - MyEnumVariant - } - `, - predicate: isTslEnumVariant, - expectedComment: undefined, - }, - { - testName: 'commented block lambda result', - code: ` - pipeline myPipeline { - () { - ${testComment} - yield r = 1; - } - } - `, - predicate: isTslBlockLambdaResult, - expectedComment: undefined, - }, - { - testName: 'uncommented block lambda result', - code: ` - pipeline myPipeline { - () { - yield r = 1; - } + function F() { + var a: Int = 0; } `, - predicate: isTslBlockLambdaResult, + predicate: isTslLocalVariable, expectedComment: undefined, }, { testName: 'commented parameter', code: ` - segment mySegment(${testComment} p: Int) {} + function F(${testComment} p: Int) {} `, predicate: isTslParameter, expectedComment: undefined, @@ -162,36 +79,15 @@ describe('TTSLCommentProvider', () => { { testName: 'uncommented parameter', code: ` - segment mySegment(p: Int) {} + function F(p: Int) {} `, predicate: isTslParameter, expectedComment: undefined, }, - { - testName: 'commented placeholder', - code: ` - segment mySegment() { - ${testComment} - val p = 1; - } - `, - predicate: isTslPlaceholder, - expectedComment: undefined, - }, - { - testName: 'uncommented placeholder', - code: ` - segment mySegment(p: Int) { - val p = 1; - } - `, - predicate: isTslPlaceholder, - expectedComment: undefined, - }, { testName: 'commented result', code: ` - segment mySegment() -> (${testComment} r: Int) {} + function F(): ${testComment} Int {} `, predicate: isTslResult, expectedComment: undefined, @@ -199,7 +95,7 @@ describe('TTSLCommentProvider', () => { { testName: 'uncommented result', code: ` - segment mySegment() -> (r: Int) {} + segment mySegment(): Int {} `, predicate: isTslResult, expectedComment: undefined, @@ -207,7 +103,7 @@ describe('TTSLCommentProvider', () => { { testName: 'commented type parameter', code: ` - class MyClass<${testComment} T> + constant c: List<${testComment} T> = [0, 1]; `, predicate: isTslTypeParameter, expectedComment: undefined, @@ -215,7 +111,7 @@ describe('TTSLCommentProvider', () => { { testName: 'uncommented type parameter', code: ` - class MyClass + constant c: List = [0, 1]; `, predicate: isTslTypeParameter, expectedComment: undefined, @@ -223,7 +119,7 @@ describe('TTSLCommentProvider', () => { { testName: 'commented not-a-declaration', code: ` - segment mySegment(p: Int) { + function F(p: Int) { ${testComment} f(); } diff --git a/packages/ttsl-lang/tests/language/documentation/safe-ds-documentation-provider.test.ts b/packages/ttsl-lang/tests/language/documentation/safe-ds-documentation-provider.test.ts index ee9ac6ec..944b4351 100644 --- a/packages/ttsl-lang/tests/language/documentation/safe-ds-documentation-provider.test.ts +++ b/packages/ttsl-lang/tests/language/documentation/safe-ds-documentation-provider.test.ts @@ -2,7 +2,7 @@ import { AstNode, EmptyFileSystem } from 'langium'; import { describe, expect, it } from 'vitest'; import { normalizeLineBreaks } from '../../../src/helpers/strings.js'; import { - isTslAnnotation, + isTslConstant, isTslFunction, isTslParameter, isTslResult, @@ -24,9 +24,9 @@ describe('TTSLDocumentationProvider', () => { /** * ${testDocumentation} */ - annotation MyAnnotation + function F() {} `, - predicate: isTslAnnotation, + predicate: isTslFunction, expectedDocumentation: testDocumentation, }, { @@ -35,7 +35,7 @@ describe('TTSLDocumentationProvider', () => { /** * @param param ${testDocumentation} */ - fun myFunction(param: String) + function myFunction(param: String) {} `, predicate: isTslParameter, expectedDocumentation: testDocumentation, @@ -47,7 +47,7 @@ describe('TTSLDocumentationProvider', () => { * @param param ${testDocumentation} * @param param bla */ - fun myFunction(param: String) + function myFunction(param: String) {} `, predicate: isTslParameter, expectedDocumentation: testDocumentation, @@ -58,7 +58,7 @@ describe('TTSLDocumentationProvider', () => { /** * @param param ${testDocumentation} */ - fun myFunction(param2: String) + function myFunction(param2: String) {} `, predicate: isTslParameter, expectedDocumentation: undefined, @@ -66,7 +66,7 @@ describe('TTSLDocumentationProvider', () => { { testName: 'parameter (no documentation on containing callable)', code: ` - fun myFunction(p: Int) + function myFunction(p: Int) {} `, predicate: isTslParameter, expectedDocumentation: undefined, @@ -77,7 +77,7 @@ describe('TTSLDocumentationProvider', () => { /** * @result res ${testDocumentation} */ - fun myFunction() -> (res: String) + function myFunction(): res: String {} `, predicate: isTslResult, expectedDocumentation: testDocumentation, @@ -86,10 +86,10 @@ describe('TTSLDocumentationProvider', () => { testName: 'documented result (duplicate)', code: ` /** - * @result res ${testDocumentation} - * @result res bla + * @result ${testDocumentation} + * @result bla */ - fun myFunction() -> (res: String) + function myFunction(): String {} `, predicate: isTslResult, expectedDocumentation: testDocumentation, @@ -98,9 +98,9 @@ describe('TTSLDocumentationProvider', () => { testName: 'undocumented result', code: ` /** - * @result res ${testDocumentation} + * @result ${testDocumentation} */ - fun myFunction() -> (res2: String) + function myFunction(): String {} `, predicate: isTslResult, expectedDocumentation: undefined, @@ -108,7 +108,7 @@ describe('TTSLDocumentationProvider', () => { { testName: 'result (no documentation on containing callable)', code: ` - fun myFunction() -> r: Int + function myFunction(): Int {} `, predicate: isTslResult, expectedDocumentation: undefined, @@ -120,7 +120,7 @@ describe('TTSLDocumentationProvider', () => { * @typeParam T * ${testDocumentation} */ - class MyClass + constant c: List = [0, 1, 2]; `, predicate: isTslTypeParameter, expectedDocumentation: testDocumentation, @@ -132,7 +132,7 @@ describe('TTSLDocumentationProvider', () => { * @typeParam T ${testDocumentation} * @typeParam T bla */ - class MyClass + constant c: List = [0, 1, 2]; `, predicate: isTslTypeParameter, expectedDocumentation: testDocumentation, @@ -144,15 +144,7 @@ describe('TTSLDocumentationProvider', () => { * @typeParam T * ${testDocumentation} */ - class MyClass - `, - predicate: isTslTypeParameter, - expectedDocumentation: undefined, - }, - { - testName: 'type parameter (no documentation on containing callable)', - code: ` - fun myFunction() + constant c: List = [0, 1, 2]; `, predicate: isTslTypeParameter, expectedDocumentation: undefined, @@ -165,10 +157,9 @@ describe('TTSLDocumentationProvider', () => { * * @param param ${testDocumentation} * @result result ${testDocumentation} - * @typeParam T ${testDocumentation} * @since 1.0.0 */ - fun myFunction(param: String) -> result: String + function myFunction(param: String): String {} `, predicate: isTslFunction, expectedDocumentation: expandToString` @@ -178,8 +169,6 @@ describe('TTSLDocumentationProvider', () => { **@result** *result* — Lorem ipsum. - **@typeParam** *T* — Lorem ipsum. - **@since** — 1.0.0 `, }, @@ -197,9 +186,9 @@ describe('TTSLDocumentationProvider', () => { /** * {@link myFunction2} */ - fun myFunction1() + function myFunction1(){} - fun myFunction2() + function myFunction2(){} `; const node = await getNodeOfType(services, code, isTslFunction); expect(documentationProvider.getDocumentation(node)).toMatch(/\[myFunction2\]\(.*\)/u); diff --git a/packages/ttsl-lang/tests/language/flow/safe-ds-call-graph-computer.test.ts b/packages/ttsl-lang/tests/language/flow/safe-ds-call-graph-computer.test.ts index 29b9e501..be5aec17 100644 --- a/packages/ttsl-lang/tests/language/flow/safe-ds-call-graph-computer.test.ts +++ b/packages/ttsl-lang/tests/language/flow/safe-ds-call-graph-computer.test.ts @@ -1,10 +1,8 @@ import { describe, expect, it } from 'vitest'; import { AstUtils, isNamed } from 'langium'; import { - isTslBlockLambda, isTslCall, isTslCallable, - isTslExpressionLambda, isTslModule, TslCall, TslCallable, @@ -62,10 +60,6 @@ const getActualCallables = (node: TslCall | TslCallable): string[] => { .map((callable) => { if (callable && isNamed(callable)) { return callable.name; - } else if (isTslBlockLambda(callable)) { - return '$blockLambda'; - } else if (isTslExpressionLambda(callable)) { - return '$expressionLambda'; } else { return 'undefined'; } diff --git a/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/assigneeToAssignedObject.test.ts b/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/assigneeToAssignedObject.test.ts index e4afdbea..5d54893d 100644 --- a/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/assigneeToAssignedObject.test.ts +++ b/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/assigneeToAssignedObject.test.ts @@ -1,9 +1,9 @@ import { NodeFileSystem } from 'langium/node'; import { describe, expect, it } from 'vitest'; import { - isTslAbstractResult, isTslAssignment, isTslPlaceholder, + isTslResult, TslAssignee, } from '../../../../src/language/generated/ast.js'; import { getAssignees } from '../../../../src/language/helpers/nodeProperties.js'; @@ -23,18 +23,18 @@ describe('TTSLNodeMapper', () => { { name: 'no value', code: ` - fun f() + function f(){} - segment mySegment() { - val a = f(); + function myFunction() { + var a = f(); }; `, }, { name: 'only one value', code: ` - segment mySegment() { - _, val a = 1; + function myFunction() { + var a = 1; }; `, }, @@ -42,8 +42,8 @@ describe('TTSLNodeMapper', () => { { name: 'unresolved receiver of call', code: ` - segment mySegment() { - val a = unresolved(); + function myFunction() { + var a = unresolved(); }; `, }, @@ -54,8 +54,8 @@ describe('TTSLNodeMapper', () => { it('should return the entire RHS of an assignment if it is not a call (constant)', async () => { const code = ` - segment mySegment() { - val a = 1; + function myFunction() { + var a = 1; }; `; @@ -63,35 +63,9 @@ describe('TTSLNodeMapper', () => { expect(nodeMapper.assigneeToAssignedObject(placeholder)?.$type).toBe('TslInt'); }); - it('should return the entire RHS of an assignment if it is a call of a class', async () => { - const code = ` - class C - segment mySegment() { - val a = C(); - }; - `; - - const placeholder = await getNodeOfType(services, code, isTslPlaceholder); - expect(nodeMapper.assigneeToAssignedObject(placeholder)?.$type).toBe('TslCall'); - }); - - it('should return the entire RHS of an assignment if it is a call of an enum variant', async () => { - const code = ` - enum E { - V - } - segment mySegment() { - val a = E.V(); - }; - `; - - const placeholder = await getNodeOfType(services, code, isTslPlaceholder); - expect(nodeMapper.assigneeToAssignedObject(placeholder)?.$type).toBe('TslCall'); - }); - it('should return the entire RHS of an assignment if it is not a call (unresolved reference)', async () => { const code = ` - segment mySegment() { + function myFunction() { val a = unresolved; }; `; @@ -101,74 +75,20 @@ describe('TTSLNodeMapper', () => { }); it.each([ - { - name: 'block lambda', - code: ` - segment mySegment() { - val f = () { - yield r1 = 1; - yield r2 = 2; - }; - - val a, val b = f(); - }; - `, - expected: ['r1', 'r2'], - index: 3, - }, - { - name: 'callable type', - code: ` - segment mySegment(f: () -> (r1: Int, r2: Int)) { - val a, val b = f(); - }; - `, - expected: ['r1', 'r2'], - }, - { - name: 'expression lambda', - code: ` - segment mySegment() { - val f = () -> 1; - - val a, val b = f(); - }; - `, - expected: ['1', undefined], - index: 1, - }, { name: 'function (one result)', code: ` - fun f() -> (r1: Int) + function f(): Int { + var r1: Int = 0; + return r1; + } - segment mySegment() { - val a = f(); + function myFunction() { + var a = f(); }; `, expected: ['r1'], - }, - { - name: 'function (multiple results)', - code: ` - fun f() -> (r1: Int, r2: Int) - - segment mySegment() { - val a, val b = f(); - }; - `, - expected: ['r1', 'r2'], - }, - { - name: 'segment', - code: ` - segment s() -> (r1: Int, r2: Int) - - segment mySegment() { - val a, val b = s(); - }; - `, - expected: ['r1', 'r2'], + index: undefined }, ])( 'should return the corresponding result if the RHS is a call of a $name', @@ -183,7 +103,7 @@ describe('TTSLNodeMapper', () => { const assignedObject = nodeMapper.assigneeToAssignedObject(node); if (!assignedObject) { return undefined; - } else if (isTslAbstractResult(assignedObject)) { + } else if (isTslResult(assignedObject)) { return assignedObject.name; } else { return assignedObject.$cstNode?.text; diff --git a/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/callToParameterValue.test.ts b/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/callToParameterValue.test.ts index 2a97b592..cf0b070f 100644 --- a/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/callToParameterValue.test.ts +++ b/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/callToParameterValue.test.ts @@ -5,7 +5,6 @@ import { TslAbstractCall, TslFunction, TslParameter, - TslPipeline, } from '../../../../src/language/generated/ast.js'; import { createTTSLServices, getModuleMembers, getParameters } from '../../../../src/language/index.js'; import { Constant, IntConstant } from '../../../../src/language/partialEvaluation/model.js'; @@ -17,22 +16,22 @@ const nodeMapper = services.helpers.NodeMapper; const partialEvaluator = services.evaluation.PartialEvaluator; const code = ` - fun myFunction(p1: String, p2: String = 0) + function myFunction1(p1: String, p2: String = 0){} - pipeline myPipeline { + function myFunction2() { myFunction(1, 2); myFunction(); unresolved(); } `; const module = await getNodeOfType(services, code, isTslModule); -const myFunction = getModuleMembers(module)[0] as TslFunction; -const p1 = getParameters(myFunction)[0]!; -const p2 = getParameters(myFunction)[1]!; -const myPipeline = module?.members[1] as TslPipeline; -const call1 = callGraphComputer.getAllContainedCalls(myPipeline)[0]!; -const call2 = callGraphComputer.getAllContainedCalls(myPipeline)[1]!; -const call3 = callGraphComputer.getAllContainedCalls(myPipeline)[2]!; +const myFunction1 = getModuleMembers(module)[0] as TslFunction; +const p1 = getParameters(myFunction1)[0]!; +const p2 = getParameters(myFunction1)[1]!; +const myFunciton2 = module?.members[1] as TslFunction; +const call1 = callGraphComputer.getAllContainedCalls(myFunciton2)[0]!; +const call2 = callGraphComputer.getAllContainedCalls(myFunciton2)[1]!; +const call3 = callGraphComputer.getAllContainedCalls(myFunciton2)[2]!; describe('TTSLNodeMapper', () => { const testCases: CallToParameterValueTest[] = [ diff --git a/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/parametersToArguments.test.ts b/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/parametersToArguments.test.ts deleted file mode 100644 index 647c83b7..00000000 --- a/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/parametersToArguments.test.ts +++ /dev/null @@ -1,111 +0,0 @@ -import { EmptyFileSystem } from 'langium'; -import { describe, expect, it } from 'vitest'; -import { - isTslModule, - TslArgument, - TslFunction, - TslParameter, - TslPipeline, -} from '../../../../src/language/generated/ast.js'; -import { createTTSLServices, getArguments, getModuleMembers, getParameters } from '../../../../src/language/index.js'; -import { getNodeOfType } from '../../../helpers/nodeFinder.js'; - -const services = (await createTTSLServices(EmptyFileSystem, { omitBuiltins: true })).TTSL; -const callGraphComputer = services.flow.CallGraphComputer; -const nodeMapper = services.helpers.NodeMapper; - -const code = ` - fun myFunction(p1: String, p2: String) - - pipeline myPipeline { - myFunction(1, 2, p1 = 3, p3 = 4); - } -`; -const module = await getNodeOfType(services, code, isTslModule); -const myFunction = getModuleMembers(module)[0] as TslFunction; -const p1 = getParameters(myFunction)[0]!; -const myPipeline = module?.members[1] as TslPipeline; -const call1 = callGraphComputer.getAllContainedCalls(myPipeline)[0]!; -const arg1 = getArguments(call1)[0]!; -const arg2 = getArguments(call1)[1]!; -const arg3 = getArguments(call1)[2]!; -const arg4 = getArguments(call1)[3]!; - -describe('TTSLNodeMapper', () => { - const testCases: ParametersToArgumentsTest[] = [ - { - testName: 'both lists empty', - parameters: [], - args: [], - expectedResult: [], - }, - { - testName: 'parameters empty', - parameters: [], - args: [arg1], - expectedResult: [], - }, - { - testName: 'arguments empty', - parameters: [p1], - args: [], - expectedResult: [], - }, - { - testName: 'one parameter, one argument', - parameters: [p1], - args: [arg1], - expectedResult: [[p1, arg1]], - }, - { - testName: 'unresolved argument', - parameters: [p1], - args: [arg4], - expectedResult: [], - }, - { - testName: 'parameter index out of bounds', - parameters: [p1], - args: [arg2], - expectedResult: [], - }, - { - testName: 'assigned twice', - parameters: [p1], - args: [arg1, arg3], - expectedResult: [[p1, arg1]], - }, - ]; - - describe.each(testCases)('parametersToArguments', ({ testName, parameters, args, expectedResult }) => { - it(testName, () => { - const actualResult = [...nodeMapper.parametersToArguments(parameters, args)]; - expect(actualResult).toStrictEqual(expectedResult); - }); - }); -}); - -/** - * A test case for {@link TTSLNodeMapper.parametersToArguments}. - */ -interface ParametersToArgumentsTest { - /** - * A short description of the test case. - */ - testName: string; - - /** - * The parameter to test. - */ - parameters: TslParameter[]; - - /** - * The arguments to test. - */ - args: TslArgument[]; - - /** - * The expected result. - */ - expectedResult: [TslParameter, TslArgument][]; -} diff --git a/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/resultToYields.test.ts b/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/resultToYields.test.ts deleted file mode 100644 index 77a0a597..00000000 --- a/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/resultToYields.test.ts +++ /dev/null @@ -1,48 +0,0 @@ -import { EmptyFileSystem } from 'langium'; -import { describe, expect, it } from 'vitest'; -import { isTslResult } from '../../../../src/language/generated/ast.js'; -import { createTTSLServices } from '../../../../src/language/index.js'; -import { getNodeOfType } from '../../../helpers/nodeFinder.js'; - -const services = (await createTTSLServices(EmptyFileSystem, { omitBuiltins: true })).TTSL; -const nodeMapper = services.helpers.NodeMapper; - -describe('TTSLNodeMapper', () => { - describe('resultToYields', () => { - it('should return an empty list if passed undefined', async () => { - expect(nodeMapper.resultToYields(undefined).toArray()).toStrictEqual([]); - }); - - it('should return an empty list if result is not in a segment', async () => { - const code = `fun myFunction() -> r1: Int`; - - const result = await getNodeOfType(services, code, isTslResult); - expect(nodeMapper.resultToYields(result).toArray()).toStrictEqual([]); - }); - - it('should return all yields that refer to a result', async () => { - const code = ` - segment mySegment() -> r1: Int { - yield r1 = 1; - yield r1 = 2; - } - `; - - const result = await getNodeOfType(services, code, isTslResult); - expect(nodeMapper.resultToYields(result).toArray()).toHaveLength(2); - }); - - it('should not return yields that refer to another result', async () => { - const code = ` - segment mySegment() -> (r1: Int, r2: Int) { - yield r1 = 1; - yield r2 = 2; - yield r2 = 3; - } - `; - - const result = await getNodeOfType(services, code, isTslResult); - expect(nodeMapper.resultToYields(result).toArray()).toHaveLength(1); - }); - }); -}); diff --git a/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/typeArgumentToTypeParameter.test.ts b/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/typeArgumentToTypeParameter.test.ts deleted file mode 100644 index 08997737..00000000 --- a/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/typeArgumentToTypeParameter.test.ts +++ /dev/null @@ -1,134 +0,0 @@ -import { EmptyFileSystem } from 'langium'; -import { describe, expect, it } from 'vitest'; -import { isTslNamedType, isTslUnionType, TslTypeArgument } from '../../../../src/language/generated/ast.js'; -import { getTypeArguments } from '../../../../src/language/helpers/nodeProperties.js'; -import { createTTSLServices } from '../../../../src/language/index.js'; -import { getNodeOfType } from '../../../helpers/nodeFinder.js'; - -const services = (await createTTSLServices(EmptyFileSystem, { omitBuiltins: true })).TTSL; -const nodeMapper = services.helpers.NodeMapper; - -describe('TTSLNodeMapper', () => { - describe('typeArgumentToTypeParameter', () => { - it('should return undefined if passed undefined', () => { - expect(nodeMapper.typeArgumentToTypeParameter(undefined)?.$type).toBeUndefined(); - }); - - describe('named type argument', () => { - it('should return undefined if the named type is unresolved', async () => { - const code = ` - class C - - segment mySegment(p: Unresolved) {} - `; - - const namedType = await getNodeOfType(services, code, isTslNamedType); - const parameterNames = getTypeArguments(namedType.typeArgumentList).map(typeParameterNameOrNull); - expect(parameterNames).toStrictEqual([undefined]); - }); - - it('should return undefined if the type parameter is unresolved', async () => { - const code = ` - class C - - segment mySegment(p: C) {} - `; - - const namedType = await getNodeOfType(services, code, isTslNamedType); - const parameterNames = getTypeArguments(namedType.typeArgumentList).map(typeParameterNameOrNull); - expect(parameterNames).toStrictEqual([undefined]); - }); - - it('should return the resolved type parameter', async () => { - const code = ` - class C - - segment mySegment(p: C) {} - `; - - const namedType = await getNodeOfType(services, code, isTslNamedType); - const parameterNames = getTypeArguments(namedType.typeArgumentList).map(typeParameterNameOrNull); - expect(parameterNames).toStrictEqual(['T2', 'T3', 'T1']); - }); - }); - - describe('positional argument', () => { - it('should return undefined if the named type is unresolved', async () => { - const code = ` - class C - - segment mySegment(p: Unresolved) {} - `; - - const namedType = await getNodeOfType(services, code, isTslNamedType); - const parameterNames = getTypeArguments(namedType.typeArgumentList).map(typeParameterNameOrNull); - expect(parameterNames).toStrictEqual([undefined]); - }); - - it('should return the type parameter at the same index if all prior type arguments are positional', async () => { - const code = ` - class C - - segment mySegment(p: C) {} - `; - - const namedType = await getNodeOfType(services, code, isTslNamedType, 0); - const parameterNames = getTypeArguments(namedType.typeArgumentList).map(typeParameterNameOrNull); - expect(parameterNames).toStrictEqual(['T1', 'T2', 'T3']); - }); - - it('should return undefined if a prior type argument is named', async () => { - const code = ` - class C - - segment mySegment(p: C) {} - `; - - const namedType = await getNodeOfType(services, code, isTslNamedType); - const parameterNames = getTypeArguments(namedType.typeArgumentList).map(typeParameterNameOrNull); - expect(parameterNames).toStrictEqual(['T2', undefined, undefined]); - }); - - it('should return undefined if type argument is out of bounds', async () => { - const code = ` - class C - - segment mySegment(p: C) {} - `; - - const namedType = await getNodeOfType(services, code, isTslNamedType); - const parameterNames = getTypeArguments(namedType.typeArgumentList).map(typeParameterNameOrNull); - expect(parameterNames).toStrictEqual(['T1', 'T2', undefined]); - }); - - it('should return undefined for type arguments of union type', async () => { - const code = ` - class C - - segment mySegment(p: union) {} - `; - - const unionType = await getNodeOfType(services, code, isTslUnionType); - const parameterNames = getTypeArguments(unionType.typeArgumentList).map(typeParameterNameOrNull); - expect(parameterNames).toStrictEqual([undefined, undefined]); - }); - - it('should return undefined for type arguments of union type inside a named type', async () => { - const code = ` - class C - - segment mySegment(p: C>) {} - `; - - const unionType = await getNodeOfType(services, code, isTslUnionType); - const parameterNames = getTypeArguments(unionType.typeArgumentList).map(typeParameterNameOrNull); - expect(parameterNames).toStrictEqual([undefined, undefined]); - }); - }); - - const typeParameterNameOrNull = (node: TslTypeArgument): string | undefined => { - const typeParameter = nodeMapper.typeArgumentToTypeParameter(node); - return typeParameter?.name ?? undefined; - }; - }); -}); diff --git a/packages/ttsl-lang/tests/language/lsp/safe-ds-document-symbol-provider.test.ts b/packages/ttsl-lang/tests/language/lsp/safe-ds-document-symbol-provider.test.ts index 99e51278..58c71fe1 100644 --- a/packages/ttsl-lang/tests/language/lsp/safe-ds-document-symbol-provider.test.ts +++ b/packages/ttsl-lang/tests/language/lsp/safe-ds-document-symbol-provider.test.ts @@ -10,113 +10,35 @@ const symbolProvider = services.lsp.DocumentSymbolProvider!; describe('TTSLSemanticTokenProvider', async () => { const testCases: DocumentSymbolProviderTest[] = [ { - testName: 'annotation declaration', - code: 'annotation A(p: Int)', - expectedSymbols: [ - { - name: 'A', - kind: SymbolKind.Interface, - }, - ], - }, - { - testName: 'attribute declaration', - code: ` - class C { - attr a: Int - static attr b: (p: Int) -> r: Int - } - `, - expectedSymbols: [ - { - name: 'C', - kind: SymbolKind.Class, - children: [ - { - name: 'a', - kind: SymbolKind.Property, - detail: ': Int', - }, - { - name: 'b', - kind: SymbolKind.Property, - detail: ': (p: Int) -> (r: Int)', - }, - ], - }, - ], - }, - { - testName: 'class declaration', - code: 'class C(p: Int)', - expectedSymbols: [ - { - name: 'C', - kind: SymbolKind.Class, - }, - ], - }, - { - testName: 'enum declaration', - code: 'enum E', + testName: 'function declaration', + code: 'function F(p: Int): Int {}', expectedSymbols: [ { - name: 'E', - kind: SymbolKind.Enum, + name: 'F', + detail: 'Int', + kind: SymbolKind.Function, }, ], }, { - testName: 'enum variant declaration', - code: ` - enum E { - V(p: Int) - } - `, + testName: 'constant declaration', + code: 'constant c: Int = 0', expectedSymbols: [ { - name: 'E', - kind: SymbolKind.Enum, - children: [ - { - name: 'V', - kind: SymbolKind.EnumMember, - }, - ], + name: 'c', + kind: SymbolKind.Constant, }, ], }, { - testName: 'function declaration', + testName: 'data declaration', code: ` - class C { - fun f(p: Int) -> r: Int - static fun g(p: Int) -> r: Int - } - - fun f(p: Int) -> r: Int + data d: Int `, expectedSymbols: [ { - name: 'C', - kind: SymbolKind.Class, - children: [ - { - name: 'f', - kind: SymbolKind.Method, - detail: '(p: Int) -> (r: Int)', - }, - { - name: 'g', - kind: SymbolKind.Method, - detail: '(p: Int) -> (r: Int)', - }, - ], - }, - { - name: 'f', - kind: SymbolKind.Function, - detail: '(p: Int) -> (r: Int)', + name: 'd', + kind: SymbolKind.Data }, ], }, @@ -130,79 +52,6 @@ describe('TTSLSemanticTokenProvider', async () => { }, ], }, - { - testName: 'pipeline declaration', - code: ` - pipeline p { - val a = 1; - - (q: Int) { - yield r = 1; - }; - } - `, - expectedSymbols: [ - { - name: 'p', - kind: SymbolKind.Function, - }, - ], - }, - { - testName: 'schema declaration', - code: ` - schema S { - "a": Int - } - `, - expectedSymbols: [ - { - name: 'S', - kind: SymbolKind.Struct, - }, - ], - }, - { - testName: 'segment declaration', - code: ` - segment s(p: Int) -> r: Int { - val a = 1; - - (p: Int) { - yield r = 1; - }; - } - `, - expectedSymbols: [ - { - name: 's', - kind: SymbolKind.Function, - detail: '(p: Int) -> (r: Int)', - }, - ], - }, - { - testName: 'deprecated declaration', - code: ` - package test - - @Deprecated - class C - `, - expectedSymbols: [ - { - name: 'test', - kind: SymbolKind.Package, - children: [ - { - name: 'C', - kind: SymbolKind.Class, - tags: [SymbolTag.Deprecated], - }, - ], - }, - ], - }, ]; it.each(testCases)('should assign the correct symbols ($testName)', async ({ code, expectedSymbols }) => { diff --git a/packages/ttsl-lang/tests/language/partialEvaluation/creator.ts b/packages/ttsl-lang/tests/language/partialEvaluation/creator.ts deleted file mode 100644 index 2bf59522..00000000 --- a/packages/ttsl-lang/tests/language/partialEvaluation/creator.ts +++ /dev/null @@ -1,173 +0,0 @@ -import fs from 'fs'; -import { EmptyFileSystem, URI } from 'langium'; -import { Location } from 'vscode-languageserver'; -import { createTTSLServices } from '../../../src/language/index.js'; -import { getSyntaxErrors, SyntaxErrorsInCodeError } from '../../helpers/diagnostics.js'; -import { findTestChecks } from '../../helpers/testChecks.js'; -import { TestDescription, TestDescriptionError } from '../../helpers/testDescription.js'; -import { - listTestTTSLFilesGroupedByParentDirectory, - uriToShortenedTestResourceName, -} from '../../helpers/testResources.js'; - -const services = (await createTTSLServices(EmptyFileSystem, { omitBuiltins: true })).TTSL; -const rootResourceName = 'partial evaluation'; - -export const createPartialEvaluationTests = (): Promise => { - const filesGroupedByParentDirectory = listTestTTSLFilesGroupedByParentDirectory(rootResourceName); - const testCases = filesGroupedByParentDirectory.map((entry) => createPartialEvaluationTest(...entry)); - - return Promise.all(testCases); -}; - -const createPartialEvaluationTest = async (parentDirectory: URI, uris: URI[]): Promise => { - const groupIdToLocations: Map = new Map(); - const serializationAssertions: SerializationAssertion[] = []; - - for (const uri of uris) { - const code = fs.readFileSync(uri.fsPath).toString(); - - // File must not contain any syntax errors - const syntaxErrors = await getSyntaxErrors(services, code); - if (syntaxErrors.length > 0) { - return invalidTest('FILE', new SyntaxErrorsInCodeError(syntaxErrors, uri)); - } - - const checksResult = findTestChecks(code, uri, { failIfFewerRangesThanComments: true }); - - // Something went wrong when finding test checks - if (checksResult.isErr) { - return invalidTest('FILE', checksResult.error); - } - - for (const check of checksResult.value) { - // Partially evaluating a set of nodes should yield the same result - const equivalenceClassMatch = /equivalence_class (?.*)/gu.exec(check.comment); - if (equivalenceClassMatch) { - const id = equivalenceClassMatch.groups!.id!; - const priorLocationsInEquivalenceClass = groupIdToLocations.get(id) ?? []; - priorLocationsInEquivalenceClass.push(check.location!); - groupIdToLocations.set(id, priorLocationsInEquivalenceClass); - continue; - } - - // Partially evaluating a node and serializing the result should yield the expected value. - const serializationMatch = /serialization (?.*)/gu.exec(check.comment); - if (serializationMatch) { - const expectedValue = serializationMatch.groups!.expectedValue!; - serializationAssertions.push({ - location: check.location!, - expectedValue, - }); - continue; - } - - return invalidTest('FILE', new InvalidCommentError(check.comment, uri)); - } - } - - // Check that all equivalence classes have at least two locations - for (const [id, locations] of groupIdToLocations) { - if (locations.length < 2) { - return invalidTest('SUITE', new SingletonEquivalenceClassError(id, parentDirectory)); - } - } - - const shortenedResourceName = uriToShortenedTestResourceName(parentDirectory, rootResourceName); - return { - testName: `[${shortenedResourceName}]`, - uris, - equivalenceClassAssertions: [...groupIdToLocations.values()].map((locations) => ({ locations })), - serializationAssertions, - }; -}; - -/** - * Report a test that has errors. - * - * @param level Whether a test file or a test suite is invalid. - * @param error The error that occurred. - */ -const invalidTest = (level: 'FILE' | 'SUITE', error: TestDescriptionError): PartialEvaluationTest => { - const shortenedResourceName = uriToShortenedTestResourceName(error.uri, rootResourceName); - const testName = `INVALID TEST ${level} [${shortenedResourceName}]`; - return { - testName, - uris: [], - equivalenceClassAssertions: [], - serializationAssertions: [], - error, - }; -}; - -/** - * A description of a partial evaluation test. - */ -interface PartialEvaluationTest extends TestDescription { - /** - * The URIs of the files that should be loaded into the workspace. - */ - uris: URI[]; - - /** - * Partially evaluating nodes in the same equivalence class should yield the same result. - */ - equivalenceClassAssertions: EquivalenceClassAssertion[]; - - /** - * Partially evaluating a node and serializing the result should yield the expected value. - */ - serializationAssertions: SerializationAssertion[]; -} - -/** - * Partially evaluating a set of nodes should yield the same result. - */ -interface EquivalenceClassAssertion { - /** - * The locations of the nodes to partially evaluate. - */ - locations: Location[]; -} - -/** - * Partially evaluating a node and serializing the result should yield the expected value. - */ -interface SerializationAssertion { - /** - * The location of the node to partially evaluate. - */ - location: Location; - - /** - * The expected serialized evaluation of the node. - */ - expectedValue: string; -} - -/** - * A test comment did not match the expected format. - */ -class InvalidCommentError extends TestDescriptionError { - constructor( - readonly comment: string, - uri: URI, - ) { - super( - `Invalid test comment (valid values are 'constant equivalence_class ', 'constant serialization ', and 'not constant'): ${comment}`, - uri, - ); - } -} - -/** - * An equivalence class test contains only a single location. - */ -class SingletonEquivalenceClassError extends TestDescriptionError { - constructor( - readonly id: string, - uri: URI, - ) { - super(`Equivalence class '${id}' only contains a single location. Such an assertion always succeeds.`, uri); - } -} diff --git a/packages/ttsl-lang/tests/language/scoping/scoping.test.ts b/packages/ttsl-lang/tests/language/scoping/scoping.test.ts index 3d968a6e..5d4991ba 100644 --- a/packages/ttsl-lang/tests/language/scoping/scoping.test.ts +++ b/packages/ttsl-lang/tests/language/scoping/scoping.test.ts @@ -8,13 +8,8 @@ import { createTTSLServices } from '../../../src/language/index.js'; import { isLocationEqual, locationToString } from '../../../src/helpers/locations.js'; import { loadDocuments } from '../../helpers/testResources.js'; import { createScopingTests, ExpectedReference } from './creator.js'; -import { getNodeOfType } from '../../helpers/nodeFinder.js'; -import { isTslAnnotationCall, isTslNamedType, isTslReference } from '../../../src/language/generated/ast.js'; const services = (await createTTSLServices(NodeFileSystem)).TTSL; -const builtinAnnotations = services.builtins.Annotations; -const builtinEnums = services.builtins.Enums; -const builtinClasses = services.builtins.Classes; const langiumDocuments = services.shared.workspace.LangiumDocuments; describe('scoping', async () => { @@ -75,41 +70,9 @@ describe('scoping', async () => { } }); - it('should not replace core declarations (annotation call)', async () => { - const code = ` - annotation PythonName(name: String) - - @PythonName(name: String) - segment mySegment() {} - `; - const annotationCall = await getNodeOfType(services, code, isTslAnnotationCall); - expectSameDocument(annotationCall.annotation?.ref, builtinAnnotations.PythonName); - }); - - it('should not replace core declarations (named type)', async () => { - const code = ` - class Any - - segment mySegment(p: Any) {} - `; - const namedType = await getNodeOfType(services, code, isTslNamedType); - expectSameDocument(namedType.declaration?.ref, builtinClasses.Any); - }); - - it('should not replace core declarations (reference)', async () => { - const code = ` - enum AnnotationTarget - - @Target([AnnotationTarget.Annotation]) - annotation MyAnnotation - `; - const reference = await getNodeOfType(services, code, isTslReference); - expectSameDocument(reference.target?.ref, builtinEnums.AnnotationTarget); - }); - it('should resolve members on literals', async () => { const code = ` - pipeline myPipeline { + function MyFunction() { 1.toString(); } `; @@ -118,7 +81,7 @@ describe('scoping', async () => { it('should resolve members on literal types', async () => { const code = ` - segment mySegment(p: literal<"">) { + function MyFunction(p: String) { p.toString(); } `; diff --git a/packages/ttsl-lang/tests/language/typing/model.test.ts b/packages/ttsl-lang/tests/language/typing/model.test.ts index d9832ae1..bbe2fb0e 100644 --- a/packages/ttsl-lang/tests/language/typing/model.test.ts +++ b/packages/ttsl-lang/tests/language/typing/model.test.ts @@ -1,130 +1,24 @@ -import { NodeFileSystem } from 'langium/node'; import { describe, expect, it } from 'vitest'; -import { isTslClass, isTslEnum, isTslEnumVariant, isTslFunction } from '../../../src/language/generated/ast.js'; -import { createTTSLServices, getParameters, getResults, getTypeParameters } from '../../../src/language/index.js'; -import { BooleanConstant, IntConstant, NullConstant } from '../../../src/language/partialEvaluation/model.js'; import { - ClassType, - EnumType, - EnumVariantType, - NamedTupleEntry, + BooleanType, + DictionaryType, + IntType, + ListType, + StringType, Type, TypeParameterSubstitutions, - TypeParameterType, UnknownType, } from '../../../src/language/typing/model.js'; -import { getNodeOfType } from '../../helpers/nodeFinder.js'; import type { EqualsTest, ToStringTest } from '../../helpers/testDescription.js'; import { expectEqualTypes } from '../../helpers/testAssertions.js'; -const services = (await createTTSLServices(NodeFileSystem)).TTSL; -const coreTypes = services.types.CoreTypes; -const factory = services.types.TypeFactory; - -const code = ` - fun f1(p1, p2: Int = 0) -> r - fun f2(), - - class C1 - class C2 - - enum MyEnum1 { - MyEnumVariant1 - MyEnumVariant2 - } - enum MyEnum2 {} -`; -const callable1 = await getNodeOfType(services, code, isTslFunction, 0); -const parameter1 = getParameters(callable1)[0]!; -const parameter2 = getParameters(callable1)[1]!; -const result = callable1.result!; -const callable2 = await getNodeOfType(services, code, isTslFunction, 1); -const class1 = await getNodeOfType(services, code, isTslClass, 0); -const class2 = await getNodeOfType(services, code, isTslClass, 1); -const typeParameter1 = getTypeParameters(class2)[0]!; -const typeParameter2 = getTypeParameters(class2)[1]!; -const enum1 = await getNodeOfType(services, code, isTslEnum, 0); -const enum2 = await getNodeOfType(services, code, isTslEnum, 1); -const enumVariant1 = await getNodeOfType(services, code, isTslEnumVariant, 0); -const enumVariant2 = await getNodeOfType(services, code, isTslEnumVariant, 1); - describe('type model', async () => { const equalsTests: EqualsTest[] = [ { - value: () => - factory.createCallableType( - callable1, - undefined, - factory.createNamedTupleType(new NamedTupleEntry(parameter1, 'p1', UnknownType)), - factory.createNamedTupleType(), - ), - unequalValueOfSameType: () => - factory.createCallableType( - callable2, - undefined, - factory.createNamedTupleType(), - factory.createNamedTupleType(), - ), - valueOfOtherType: () => UnknownType, - }, - { - value: () => factory.createLiteralType(new BooleanConstant(true)), - unequalValueOfSameType: () => factory.createLiteralType(new IntConstant(1n)), - valueOfOtherType: () => UnknownType, - }, - { - value: () => factory.createNamedTupleType(new NamedTupleEntry(parameter1, 'p1', UnknownType)), - unequalValueOfSameType: () => factory.createNamedTupleType(), - valueOfOtherType: () => UnknownType, - }, - { - value: () => new ClassType(class1, new Map(), true), - unequalValueOfSameType: () => new ClassType(class2, new Map(), true), - valueOfOtherType: () => UnknownType, - }, - { - value: () => new ClassType(class1, new Map(), false), - unequalValueOfSameType: () => new ClassType(class1, new Map(), true), - }, - { - value: () => new ClassType(class2, new Map([[typeParameter1, UnknownType]]), true), - unequalValueOfSameType: () => - new ClassType(class2, new Map([[typeParameter1, factory.createUnionType()]]), true), - }, - { - value: () => new ClassType(class2, new Map(), true), - unequalValueOfSameType: () => - new ClassType(class2, new Map([[typeParameter1, factory.createUnionType()]]), true), - }, - { - value: () => new EnumType(enum1, true), - unequalValueOfSameType: () => new EnumType(enum2, true), + value: () => new BooleanType(true), + unequalValueOfSameType: () => new BooleanType(false), valueOfOtherType: () => UnknownType, }, - { - value: () => new EnumVariantType(enumVariant1, true), - unequalValueOfSameType: () => new EnumVariantType(enumVariant2, true), - valueOfOtherType: () => UnknownType, - }, - { - value: () => new TypeParameterType(typeParameter1, true), - unequalValueOfSameType: () => new TypeParameterType(typeParameter2, true), - valueOfOtherType: () => UnknownType, - }, - { - value: () => factory.createStaticType(new ClassType(class1, new Map(), false)), - unequalValueOfSameType: () => factory.createStaticType(new ClassType(class2, new Map(), false)), - valueOfOtherType: () => UnknownType, - }, - { - value: () => factory.createUnionType(UnknownType), - unequalValueOfSameType: () => factory.createUnionType(), - valueOfOtherType: () => UnknownType, - }, - { - value: () => UnknownType, - valueOfOtherType: () => factory.createUnionType(), - }, ]; describe.each(equalsTests)('equals', ({ value, unequalValueOfSameType, valueOfOtherType }) => { it(`should return true if both types are the same instance (${value().constructor.name})`, () => { @@ -153,78 +47,16 @@ describe('type model', async () => { const toStringTests: ToStringTest[] = [ { - value: factory.createCallableType( - callable1, - undefined, - factory.createNamedTupleType(new NamedTupleEntry(parameter1, 'p1', UnknownType)), - factory.createNamedTupleType(), - ), - expectedString: '(p1: $unknown) -> ()', - }, - { - value: factory.createCallableType( - callable1, - undefined, - factory.createNamedTupleType(new NamedTupleEntry(parameter2, 'p2', UnknownType)), - factory.createNamedTupleType(), - ), - expectedString: '(p2?: $unknown) -> ()', - }, - { - value: factory.createLiteralType(new BooleanConstant(true)), - expectedString: 'literal', - }, - { - value: factory.createNamedTupleType(new NamedTupleEntry(parameter1, 'p1', UnknownType)), - expectedString: '(p1: $unknown)', - }, - { - value: new ClassType(class1, new Map(), false), - expectedString: 'C1', - }, - { - value: new ClassType(class1, new Map(), true), - expectedString: 'C1?', - }, - { - value: new ClassType(class2, new Map([[typeParameter1, factory.createUnionType()]]), true), - expectedString: 'C2>?', - }, - { - value: new EnumType(enum1, false), - expectedString: 'MyEnum1', - }, - { - value: new EnumType(enum1, true), - expectedString: 'MyEnum1?', - }, - { - value: new EnumVariantType(enumVariant1, false), - expectedString: 'MyEnum1.MyEnumVariant1', - }, - { - value: new EnumVariantType(enumVariant1, true), - expectedString: 'MyEnum1.MyEnumVariant1?', - }, - { - value: new TypeParameterType(typeParameter1, false), - expectedString: 'K', - }, - { - value: new TypeParameterType(typeParameter1, true), - expectedString: 'K?', - }, - { - value: factory.createStaticType(new ClassType(class1, new Map(), false)), - expectedString: '$type', + value: UnknownType, + expectedString: '$unknown', }, { - value: factory.createUnionType(UnknownType), - expectedString: 'union<$unknown>', + value: new BooleanType(false), + expectedString: 'Boolean', }, { - value: UnknownType, - expectedString: '$unknown', + value: new IntType(true), + expectedString: 'Int?', }, ]; describe.each(toStringTests)('toString', ({ value, expectedString }) => { @@ -233,104 +65,18 @@ describe('type model', async () => { }); }); - const substitutions1 = new Map([[typeParameter1, factory.createLiteralType(new IntConstant(1n))]]); + const substitutions1 = [new IntType(false)]; + const booleanType = new BooleanType(false) const substituteTypeParametersTest: SubstituteTypeParametersTest[] = [ { - type: factory.createCallableType( - callable1, - undefined, - factory.createNamedTupleType( - new NamedTupleEntry(parameter1, 'p1', new TypeParameterType(typeParameter1, false)), - ), - factory.createNamedTupleType( - new NamedTupleEntry(result, 'r', new TypeParameterType(typeParameter1, false)), - ), - ), - substitutions: substitutions1, - expectedType: factory.createCallableType( - callable1, - undefined, - factory.createNamedTupleType( - new NamedTupleEntry(parameter1, 'p1', factory.createLiteralType(new IntConstant(1n))), - ), - factory.createNamedTupleType( - new NamedTupleEntry(result, 'r', factory.createLiteralType(new IntConstant(1n))), - ), - ), - }, - { - type: factory.createLiteralType(new BooleanConstant(true)), + type: new ListType([], false), substitutions: substitutions1, - expectedType: factory.createLiteralType(new BooleanConstant(true)), + expectedType: new ListType([new IntType(false)], false), }, { - type: factory.createNamedTupleType( - new NamedTupleEntry(parameter1, 'p1', new TypeParameterType(typeParameter1, false)), - ), + type: booleanType, substitutions: substitutions1, - expectedType: factory.createNamedTupleType( - new NamedTupleEntry(parameter1, 'p1', factory.createLiteralType(new IntConstant(1n))), - ), - }, - { - type: new ClassType( - class1, - new Map([[typeParameter2, new TypeParameterType(typeParameter1, false)]]), - false, - ), - substitutions: substitutions1, - expectedType: new ClassType( - class1, - new Map([[typeParameter2, factory.createLiteralType(new IntConstant(1n))]]), - false, - ), - }, - { - type: new EnumType(enum1, false), - substitutions: substitutions1, - expectedType: new EnumType(enum1, false), - }, - { - type: new EnumVariantType(enumVariant1, false), - substitutions: substitutions1, - expectedType: new EnumVariantType(enumVariant1, false), - }, - { - type: new TypeParameterType(typeParameter1, false), - substitutions: substitutions1, - expectedType: factory.createLiteralType(new IntConstant(1n)), - }, - { - type: new TypeParameterType(typeParameter1, true), - substitutions: substitutions1, - expectedType: factory.createLiteralType(new IntConstant(1n), NullConstant), - }, - { - type: new TypeParameterType(typeParameter2, false), - substitutions: substitutions1, - expectedType: new TypeParameterType(typeParameter2, false), - }, - { - type: factory.createStaticType( - new ClassType(class1, new Map([[typeParameter1, new TypeParameterType(typeParameter2, false)]]), false), - ), - substitutions: substitutions1, - expectedType: factory.createStaticType( - new ClassType(class1, new Map([[typeParameter1, new TypeParameterType(typeParameter2, false)]]), false), - ), - }, - { - type: factory.createUnionType( - new ClassType(class1, new Map([[typeParameter2, new TypeParameterType(typeParameter1, false)]]), false), - ), - substitutions: substitutions1, - expectedType: factory.createUnionType( - new ClassType( - class1, - new Map([[typeParameter2, factory.createLiteralType(new IntConstant(1n))]]), - false, - ), - ), + expectedType: booleanType, }, { type: UnknownType, @@ -345,160 +91,21 @@ describe('type model', async () => { }); it(`should not change if no substitutions are passed (${type.constructor.name} -- ${type})`, () => { - const actual = type.substituteTypeParameters(new Map()); + const actual = type.substituteTypeParameters([]); expectEqualTypes(actual, type); }); }); const withExplicitNullabilityTests: WithExplicitNullabilityTest[] = [ { - type: factory.createCallableType( - callable1, - undefined, - factory.createNamedTupleType(), - factory.createNamedTupleType(), - ), - isNullable: true, - expectedType: factory.createUnionType( - factory.createCallableType( - callable1, - undefined, - factory.createNamedTupleType(), - factory.createNamedTupleType(), - ), - factory.createLiteralType(NullConstant), - ), - }, - { - type: factory.createCallableType( - callable1, - undefined, - factory.createNamedTupleType(), - factory.createNamedTupleType(), - ), - isNullable: false, - expectedType: factory.createCallableType( - callable1, - undefined, - factory.createNamedTupleType(), - factory.createNamedTupleType(), - ), - }, - { - type: factory.createLiteralType(new BooleanConstant(true)), - isNullable: true, - expectedType: factory.createLiteralType(new BooleanConstant(true), NullConstant), - }, - { - type: factory.createLiteralType(new BooleanConstant(true), NullConstant), - isNullable: false, - expectedType: factory.createLiteralType(new BooleanConstant(true)), - }, - { - type: factory.createLiteralType(new BooleanConstant(true), NullConstant), - isNullable: true, - expectedType: factory.createLiteralType(new BooleanConstant(true), NullConstant), - }, - { - type: factory.createLiteralType(new BooleanConstant(true)), - isNullable: false, - expectedType: factory.createLiteralType(new BooleanConstant(true)), - }, - { - type: factory.createNamedTupleType(), - isNullable: true, - expectedType: factory.createUnionType( - factory.createNamedTupleType(), - factory.createLiteralType(NullConstant), - ), - }, - { - type: factory.createNamedTupleType(), - isNullable: false, - expectedType: factory.createNamedTupleType(), - }, - { - type: new ClassType(class1, new Map(), false), - isNullable: true, - expectedType: new ClassType(class1, new Map(), true), - }, - { - type: new ClassType(class1, new Map(), true), - isNullable: false, - expectedType: new ClassType(class1, new Map(), false), - }, - { - type: new EnumType(enum1, false), - isNullable: true, - expectedType: new EnumType(enum1, true), - }, - { - type: new EnumType(enum1, true), - isNullable: false, - expectedType: new EnumType(enum1, false), - }, - { - type: new EnumVariantType(enumVariant1, false), - isNullable: true, - expectedType: new EnumVariantType(enumVariant1, true), - }, - { - type: new EnumVariantType(enumVariant1, true), - isNullable: false, - expectedType: new EnumVariantType(enumVariant1, false), - }, - { - type: factory.createStaticType(new ClassType(class1, new Map(), false)), - isNullable: true, - expectedType: factory.createUnionType( - factory.createStaticType(new ClassType(class1, new Map(), false)), - factory.createLiteralType(NullConstant), - ), - }, - { - type: factory.createStaticType(new ClassType(class1, new Map(), false)), - isNullable: false, - expectedType: factory.createStaticType(new ClassType(class1, new Map(), false)), - }, - { - type: new TypeParameterType(typeParameter1, false), + type: new IntType(false), isNullable: true, - expectedType: new TypeParameterType(typeParameter1, true), + expectedType: new IntType(true), }, { - type: new TypeParameterType(typeParameter1, true), + type: new IntType(true), isNullable: false, - expectedType: new TypeParameterType(typeParameter1, false), - }, - { - type: factory.createUnionType(), - isNullable: true, - expectedType: coreTypes.NothingOrNull, - }, - { - type: factory.createUnionType(), - isNullable: false, - expectedType: coreTypes.Nothing, - }, - { - type: factory.createUnionType(new ClassType(class1, new Map(), false)), - isNullable: true, - expectedType: factory.createUnionType(new ClassType(class1, new Map(), true)), - }, - { - type: factory.createUnionType(new ClassType(class1, new Map(), false)), - isNullable: false, - expectedType: factory.createUnionType(new ClassType(class1, new Map(), false)), - }, - { - type: factory.createUnionType(new ClassType(class1, new Map(), true)), - isNullable: true, - expectedType: factory.createUnionType(new ClassType(class1, new Map(), true)), - }, - { - type: factory.createUnionType(new ClassType(class1, new Map(), true)), - isNullable: false, - expectedType: factory.createUnionType(new ClassType(class1, new Map(), false)), + expectedType: new IntType(false), }, { type: UnknownType, @@ -518,50 +125,18 @@ describe('type model', async () => { }); }); - describe('CallableType', () => { - describe('getParameterTypeByIndex', () => { - it.each([ - { - type: factory.createCallableType( - callable1, - undefined, - factory.createNamedTupleType(), - factory.createNamedTupleType(), - ), - index: 0, - expectedType: UnknownType, - }, - { - type: factory.createCallableType( - callable1, - undefined, - factory.createNamedTupleType( - new NamedTupleEntry(parameter1, 'p1', new ClassType(class1, new Map(), false)), - ), - factory.createNamedTupleType(), - ), - index: 0, - expectedType: new ClassType(class1, new Map(), false), - }, - ])('should return the type of the parameter at the given index (%#)', ({ type, index, expectedType }) => { - const actual = type.getParameterTypeByIndex(index); - expectEqualTypes(actual, expectedType); - }); - }); - }); - - describe('ClassType', () => { + describe('ListAndDictionaryType', () => { describe('getTypeParameterTypeByIndex', () => { it.each([ { - type: new ClassType(class1, new Map(), false), + type: new ListType([UnknownType], false), index: 0, expectedType: UnknownType, }, { - type: new ClassType(class2, new Map([[typeParameter1, factory.createUnionType()]]), false), - index: 0, - expectedType: factory.createUnionType(), + type: new DictionaryType([new IntType(false), new StringType(false)], false), + index: 1, + expectedType: new StringType(false), }, ])('should return the type of the parameter at the given index (%#)', ({ type, index, expectedType }) => { const actual = type.getTypeParameterTypeByIndex(index); @@ -569,30 +144,7 @@ describe('type model', async () => { }); }); }); - - describe('NamedTupleType', () => { - describe('getTypeOfEntryByIndex', () => { - it.each([ - { - type: factory.createNamedTupleType(), - index: 0, - expectedType: UnknownType, - }, - { - type: factory.createNamedTupleType( - new NamedTupleEntry(parameter1, 'p1', new ClassType(class1, new Map(), false)), - ), - index: 0, - expectedType: new ClassType(class1, new Map(), false), - }, - ])('should return the entry at the given index (%#)', ({ type, index, expectedType }) => { - const actual = type.getTypeOfEntryByIndex(index); - expectEqualTypes(actual, expectedType); - }); - }); - }); -}); - +}) /** * Tests for {@link Type.substituteTypeParameters}. */ diff --git a/packages/ttsl-lang/tests/language/typing/safe-ds-class-hierarchy.test.ts b/packages/ttsl-lang/tests/language/typing/safe-ds-class-hierarchy.test.ts deleted file mode 100644 index 2491cc42..00000000 --- a/packages/ttsl-lang/tests/language/typing/safe-ds-class-hierarchy.test.ts +++ /dev/null @@ -1,432 +0,0 @@ -import { NodeFileSystem } from 'langium/node'; -import { describe, expect, it } from 'vitest'; -import { - isTslAttribute, - isTslClass, - isTslFunction, - TslClass, - type TslClassMember, -} from '../../../src/language/generated/ast.js'; -import { createTTSLServices, getClassMembers } from '../../../src/language/index.js'; -import { getNodeOfType } from '../../helpers/nodeFinder.js'; - -const services = (await createTTSLServices(NodeFileSystem)).TTSL; -const builtinClasses = services.builtins.Classes; -const classHierarchy = services.types.ClassHierarchy; - -describe('TTSLClassHierarchy', async () => { - describe('isEqualToOrSubclassOf', () => { - const testCases = [ - { - testName: 'should return false if node is undefined', - node: () => undefined, - other: () => builtinClasses.Any, - expected: false, - }, - { - testName: 'should return false if other is undefined', - node: () => builtinClasses.Nothing, - other: () => undefined, - expected: false, - }, - { - testName: 'should return false if node and other are undefined', - node: () => undefined, - other: () => undefined, - expected: false, - }, - { - testName: 'should return true if node is Nothing', - node: () => builtinClasses.Nothing, - other: () => builtinClasses.Any, - expected: true, - }, - { - testName: 'should return true if node and other are equal', - node: () => builtinClasses.Any, - other: () => builtinClasses.Any, - expected: true, - }, - { - testName: 'should return true if node is a subclass of other', - node: () => builtinClasses.Int, - other: () => builtinClasses.Any, - expected: true, - }, - ]; - - it.each(testCases)('$testName', async ({ node, other, expected }) => { - expect(classHierarchy.isEqualToOrSubclassOf(node(), other())).toStrictEqual(expected); - }); - }); - - describe('streamProperSuperclasses', () => { - const properSuperclassesNames = (node: TslClass | undefined) => - classHierarchy - .streamProperSuperclasses(node) - .map((clazz) => clazz.name) - .toArray(); - - it('should return an empty stream if passed undefined', () => { - expect(properSuperclassesNames(undefined)).toStrictEqual([]); - }); - - const testCases = [ - { - testName: 'should return "Any" if the class has no parent types', - code: ` - class A - `, - expected: ['Any'], - }, - { - testName: 'should return "Any" if the first parent type is not a class', - code: ` - class A sub E - enum E - `, - expected: ['Any'], - }, - { - testName: 'should return the superclasses of a class (no cycle, implicit any)', - code: ` - class A sub B - class B - `, - expected: ['B', 'Any'], - }, - { - testName: 'should return the superclasses of a class (no cycle, explicit any)', - code: ` - class A sub Any - `, - expected: ['Any'], - }, - { - testName: 'should return the superclasses of a class (cycle)', - code: ` - class A sub B - class B sub C - class C sub A - `, - expected: ['B', 'C', 'A', 'Any'], - }, - { - testName: 'should only consider the first parent type', - code: ` - class A sub B, C - class B - class C - `, - expected: ['B', 'Any'], - }, - ]; - - it.each(testCases)('$testName', async ({ code, expected }) => { - const firstClass = await getNodeOfType(services, code, isTslClass); - expect(properSuperclassesNames(firstClass)).toStrictEqual(expected); - }); - }); - - describe('streamSuperclassMembers', () => { - const superclassMemberNames = (node: TslClass | undefined) => - classHierarchy - .streamSuperclassMembers(node) - .map((member) => member.name) - .toArray(); - - it('should return an empty stream if passed undefined', () => { - expect(superclassMemberNames(undefined)).toStrictEqual([]); - }); - - const testCases = [ - { - testName: 'should return the members of the parent type', - code: ` - class A { - attr a: Int - fun f() - } - - class B sub A - `, - index: 1, - expected: ['a', 'f'], - }, - { - testName: 'should only consider members of the first parent type', - code: ` - class A { - attr a: Int - fun f() - } - - class B { - attr b: Int - fun g() - } - - class C sub A, B - `, - index: 2, - expected: ['a', 'f'], - }, - { - testName: 'should return members of all superclasses', - code: ` - class A { - attr a: Int - fun f() - } - - class B sub A { - attr b: Int - fun g() - } - - class C sub B - `, - index: 2, - expected: ['b', 'g', 'a', 'f'], - }, - ]; - - it.each(testCases)('$testName', async ({ code, index, expected }) => { - const firstClass = await getNodeOfType(services, code, isTslClass, index); - const anyMembers = getClassMembers(builtinClasses.Any).map((member) => member.name); - expect(superclassMemberNames(firstClass)).toStrictEqual(expected.concat(anyMembers)); - }); - }); - - describe('getOverriddenMember', () => { - const isUndefined = (result: unknown) => result === undefined; - - const testCases: GetOverriddenMemberTest[] = [ - { - testName: 'global function', - code: ` - fun f() - `, - memberPredicate: isTslFunction, - index: 0, - expectedResultPredicate: isUndefined, - }, - { - testName: 'attribute, no superclass', - code: ` - class A { - attr a: Int - } - `, - memberPredicate: isTslAttribute, - index: 0, - expectedResultPredicate: isUndefined, - }, - { - testName: 'method, no superclass', - code: ` - class A { - fun f() - } - `, - memberPredicate: isTslFunction, - index: 0, - expectedResultPredicate: isUndefined, - }, - { - testName: 'attribute, superclass, no match', - code: ` - class A sub B { - attr a: Int - } - - class B { - attr b: Int - } - `, - memberPredicate: isTslAttribute, - index: 0, - expectedResultPredicate: isUndefined, - }, - { - testName: 'method, superclass, no match', - code: ` - class A sub B { - fun f() - } - - class B { - fun g() - } - `, - memberPredicate: isTslFunction, - index: 0, - expectedResultPredicate: isUndefined, - }, - { - testName: 'static attribute', - code: ` - class A sub B { - static attr a: Int - } - - class B { - static attr a: Int - } - `, - memberPredicate: isTslAttribute, - index: 0, - expectedResultPredicate: isUndefined, - }, - { - testName: 'static method', - code: ` - class A sub B { - static fun f() - } - - class B { - static fun f() - } - `, - memberPredicate: isTslFunction, - index: 0, - expectedResultPredicate: isUndefined, - }, - { - testName: 'attribute, superclass, match but static', - code: ` - class A sub B { - attr a: Int - } - - class B { - static attr a: Int - } - `, - memberPredicate: isTslAttribute, - index: 0, - expectedResultPredicate: isUndefined, - }, - { - testName: 'method, superclass, match but static', - code: ` - class A sub B { - fun f() - } - - class B { - static fun f() - } - `, - memberPredicate: isTslFunction, - index: 0, - expectedResultPredicate: isUndefined, - }, - { - testName: 'attribute, superclass, match', - code: ` - class A sub B { - attr a: Int - } - - class B { - attr a: Int - } - `, - memberPredicate: isTslAttribute, - index: 0, - expectedResultPredicate: isTslAttribute, - }, - { - testName: 'method, superclass, match', - code: ` - class A sub B { - fun f() - } - - class B { - fun f() - } - `, - memberPredicate: isTslFunction, - index: 0, - expectedResultPredicate: isTslFunction, - }, - { - testName: 'attribute, previous member with same name', - code: ` - class A sub B { - attr a: Int - attr a: Int - } - - class B { - attr a: Int - } - `, - memberPredicate: isTslAttribute, - index: 1, - expectedResultPredicate: isUndefined, - }, - { - testName: 'method, previous member with same name', - code: ` - class A sub B { - fun f() - fun f() - } - - class B { - fun f() - } - `, - memberPredicate: isTslFunction, - index: 1, - expectedResultPredicate: isUndefined, - }, - ]; - - it.each(testCases)( - 'should return the overridden member or undefined ($testName)', - async ({ code, memberPredicate, index, expectedResultPredicate }) => { - const member = await getNodeOfType(services, code, memberPredicate, index); - expect(classHierarchy.getOverriddenMember(member)).toSatisfy(expectedResultPredicate); - }, - ); - - it('should return undefined if passed undefined', () => { - expect(classHierarchy.getOverriddenMember(undefined)).toBeUndefined(); - }); - }); -}); - -/** - * A test case for {@link ClassHierarchy.getOverriddenMember}. - */ -interface GetOverriddenMemberTest { - /** - * A short description of the test case. - */ - testName: string; - - /** - * The code to parse. - */ - code: string; - - /** - * A predicate that matches the member that should be used as input. - */ - memberPredicate: (value: unknown) => value is TslClassMember; - - /** - * The index of the member to use as input. - */ - index: number; - - /** - * A predicate that matches the expected result. - */ - expectedResultPredicate: (value: unknown) => boolean; -} diff --git a/packages/ttsl-lang/tests/language/typing/type checker/canBeTypeOfConstantParameter.test.ts b/packages/ttsl-lang/tests/language/typing/type checker/canBeTypeOfConstantParameter.test.ts index 61db44c0..2825fdd6 100644 --- a/packages/ttsl-lang/tests/language/typing/type checker/canBeTypeOfConstantParameter.test.ts +++ b/packages/ttsl-lang/tests/language/typing/type checker/canBeTypeOfConstantParameter.test.ts @@ -1,98 +1,43 @@ import { NodeFileSystem } from 'langium/node'; import { describe, expect, it } from 'vitest'; -import { isTslClass, isTslEnum, isTslModule } from '../../../../src/language/generated/ast.js'; -import { createTTSLServices, getEnumVariants, getModuleMembers } from '../../../../src/language/index.js'; -import { ClassType, EnumType, EnumVariantType, Type, UnknownType } from '../../../../src/language/typing/model.js'; -import { getNodeOfType } from '../../../helpers/nodeFinder.js'; +import { createTTSLServices } from '../../../../src/language/index.js'; +import { AnyType, BooleanType, DictionaryType, FloatType, IntType, ListType, NothingType, StringType, Type, UnknownType } from '../../../../src/language/typing/model.js'; const services = (await createTTSLServices(NodeFileSystem)).TTSL; -const coreTypes = services.types.CoreTypes; -const factory = services.types.TypeFactory; const typeChecker = services.types.TypeChecker; -const typeComputer = services.types.TypeComputer; - -const code = ` - class MyClass - - enum ConstantEnum { - Variant1 - Variant2(const param: Int) - } - - enum NormalEnum { - Variant1 - Variant2(param: Int) - } -`; -const module = await getNodeOfType(services, code, isTslModule); -const classes = getModuleMembers(module).filter(isTslClass); -const myClassType = typeComputer.computeType(classes[0]) as ClassType; - -const enums = getModuleMembers(module).filter(isTslEnum); -const constantEnum = enums[0]; -const normalEnum = enums[1]; -const constantEnumType = typeComputer.computeType(constantEnum) as EnumType; -const normalEnumType = typeComputer.computeType(normalEnum) as EnumType; - -const constantEnumVariantType = typeComputer.computeType(getEnumVariants(constantEnum)[1]) as EnumVariantType; -const normalEnumVariantType = typeComputer.computeType(getEnumVariants(normalEnum)[1]) as EnumVariantType; describe('TTSLTypeChecker', async () => { const testCases: CanBeTypeOfConstantParameterTest[] = [ { - type: coreTypes.Any, + type: new AnyType(false), expected: false, }, { - type: coreTypes.Boolean, - expected: true, - }, - { - type: coreTypes.Float, + type: new BooleanType(false), expected: true, }, { - type: coreTypes.Int, + type: new FloatType(false), expected: true, }, { - type: coreTypes.List(coreTypes.Int), + type: new IntType(false), expected: true, }, { - type: coreTypes.Map(coreTypes.String, coreTypes.Int), + type: new ListType([new IntType(false)], false), expected: true, }, { - type: coreTypes.Nothing, + type: new DictionaryType([new StringType(false), new IntType(false)], false), expected: true, }, { - type: coreTypes.String, + type: new NothingType(false), expected: true, }, { - type: myClassType, - expected: false, - }, - { - type: constantEnumType, - expected: true, - }, - { - type: normalEnumType, - expected: false, - }, - { - type: constantEnumVariantType, - expected: true, - }, - { - type: normalEnumVariantType, - expected: false, - }, - { - type: factory.createLiteralType(), + type: new StringType(false), expected: true, }, { diff --git a/packages/ttsl-lang/tests/language/typing/type checker/isSubOrSupertypeOf.test.ts b/packages/ttsl-lang/tests/language/typing/type checker/isSubOrSupertypeOf.test.ts deleted file mode 100644 index 0bb6a12c..00000000 --- a/packages/ttsl-lang/tests/language/typing/type checker/isSubOrSupertypeOf.test.ts +++ /dev/null @@ -1,1256 +0,0 @@ -import { NodeFileSystem } from 'langium/node'; -import { describe, expect, it } from 'vitest'; -import { - isTslAttribute, - isTslClass, - isTslEnum, - isTslEnumVariant, - isTslFunction, - isTslModule, - TslDeclaration, -} from '../../../../src/language/generated/ast.js'; -import { - createTTSLServices, - getClassMembers, - getModuleMembers, - getTypeParameters, -} from '../../../../src/language/index.js'; - -import { - BooleanConstant, - FloatConstant, - IntConstant, - NullConstant, - StringConstant, -} from '../../../../src/language/partialEvaluation/model.js'; -import { - ClassType, - EnumType, - EnumVariantType, - NamedTupleEntry, - Type, - UnknownType, -} from '../../../../src/language/typing/model.js'; -import { getNodeOfType } from '../../../helpers/nodeFinder.js'; -import { AstUtils } from 'langium'; - -const services = (await createTTSLServices(NodeFileSystem)).TTSL; -const coreTypes = services.types.CoreTypes; -const factory = services.types.TypeFactory; -const typeChecker = services.types.TypeChecker; -const typeComputer = services.types.TypeComputer; - -const basic = async (): Promise => { - const code = ` - fun func1() -> () - fun func2(p: Int = 0) -> () - fun func3(p: Int) -> () - fun func4(r: Int) -> () - fun func5(p: Any) -> () - fun func6(p: String) -> () - fun func7() -> (r: Int) - fun func8() -> (s: Int) - fun func9() -> (r: Any) - fun func10() -> (r: String) - fun func11() -> (r: Class1) - fun func12() -> (r: Enum1) - - class Class1(p: Int) - class Class2() sub Class1 - class Class3 - - class Class4 - - enum Enum1 { - Variant1(p: Int) - Variant2 - } - enum Enum2 - `; - const module = await getNodeOfType(services, code, isTslModule); - const functions = getModuleMembers(module).filter(isTslFunction); - const callableType1 = typeComputer.computeType(functions[0]); - const callableType2 = typeComputer.computeType(functions[1]); - const callableType3 = typeComputer.computeType(functions[2]); - const callableType4 = typeComputer.computeType(functions[3]); - const callableType5 = typeComputer.computeType(functions[4]); - const callableType6 = typeComputer.computeType(functions[5]); - const callableType7 = typeComputer.computeType(functions[6]); - const callableType8 = typeComputer.computeType(functions[7]); - const callableType9 = typeComputer.computeType(functions[8]); - const callableType10 = typeComputer.computeType(functions[9]); - const callableType11 = typeComputer.computeType(functions[10]); - const callableType12 = typeComputer.computeType(functions[11]); - - const classes = getModuleMembers(module).filter(isTslClass); - const class1 = classes[0]; - const class2 = classes[1]; - const class3 = classes[2]; - const classType1 = typeComputer.computeType(class1) as ClassType; - const classType2 = typeComputer.computeType(class2) as ClassType; - const classType3 = typeComputer.computeType(class3) as ClassType; - - const enums = getModuleMembers(module).filter(isTslEnum); - const enum1 = enums[0]; - const enum2 = enums[1]; - const enumType1 = typeComputer.computeType(enum1) as EnumType; - const enumType2 = typeComputer.computeType(enum2) as EnumType; - - const enumVariants = AstUtils.streamAllContents(module).filter(isTslEnumVariant).toArray(); - const enumVariant1 = enumVariants[0]; - const enumVariant2 = enumVariants[1]; - const enumVariantType1 = typeComputer.computeType(enumVariant1) as EnumVariantType; - const enumVariantType2 = typeComputer.computeType(enumVariant2) as EnumVariantType; - - return [ - // Callable type to callable type - { - type1: callableType1, - type2: callableType1, - expected: true, - }, - { - type1: callableType2, - type2: callableType1, - expected: true, - }, - { - type1: callableType1, - type2: callableType2, - expected: false, - }, - { - type1: callableType2, - type2: callableType3, - expected: true, - }, - { - type1: callableType3, - type2: callableType2, - expected: false, - }, - { - type1: callableType3, - type2: callableType1, - expected: false, - }, - { - type1: callableType3, - type2: callableType4, - expected: false, - }, - { - type1: callableType3, - type2: callableType5, - expected: false, - }, - { - type1: callableType5, - type2: callableType3, - expected: true, - }, - { - type1: callableType6, - type2: callableType3, - expected: false, - }, - { - type1: callableType7, - type2: callableType1, - expected: true, - }, - { - type1: callableType1, - type2: callableType7, - expected: false, - }, - { - type1: callableType8, - type2: callableType7, - expected: true, - }, - { - type1: callableType9, - type2: callableType7, - expected: false, - }, - { - type1: callableType7, - type2: callableType9, - expected: true, - }, - { - type1: callableType10, - type2: callableType7, - expected: false, - }, - // Callable type to class type - { - type1: callableType1, - type2: coreTypes.Any, - expected: true, - }, - { - type1: callableType1, - type2: coreTypes.AnyOrNull, - expected: true, - }, - // Callable type to other - { - type1: callableType1, - type2: enumType1, - expected: false, - }, - // Class type to class type - { - type1: classType1, - type2: classType1, - expected: true, - }, - { - type1: classType2, - type2: classType1, - expected: true, - }, - { - type1: classType1, - type2: classType3, - expected: false, - }, - { - type1: classType1, - type2: coreTypes.Any, - expected: true, - }, - { - type1: classType2.withExplicitNullability(true), - type2: classType1, - expected: false, - }, - { - type1: classType2.withExplicitNullability(true), - type2: classType1.withExplicitNullability(true), - expected: true, - }, - // Class type to union type - { - type1: classType1, - type2: factory.createUnionType(classType1), - expected: true, - }, - { - type1: classType1, - type2: factory.createUnionType(classType3), - expected: false, - }, - // Class type to other - { - type1: classType1, - type2: enumType1, - expected: false, - }, - // Enum type to class type - { - type1: enumType1, - type2: classType1, - expected: false, - }, - { - type1: enumType1, - type2: coreTypes.Any, - expected: true, - }, - { - type1: enumType1.withExplicitNullability(true), - type2: coreTypes.Any, - expected: false, - }, - { - type1: enumType1.withExplicitNullability(true), - type2: coreTypes.AnyOrNull, - expected: true, - }, - // Enum type to enum type - { - type1: enumType1, - type2: enumType1, - expected: true, - }, - { - type1: enumType1, - type2: enumType2, - expected: false, - }, - { - type1: enumType1.withExplicitNullability(true), - type2: enumType1, - expected: false, - }, - { - type1: enumType1.withExplicitNullability(true), - type2: enumType1.withExplicitNullability(true), - expected: true, - }, - // Enum type to union type - { - type1: enumType1, - type2: factory.createUnionType(enumType1), - expected: true, - }, - { - type1: enumType1, - type2: factory.createUnionType(enumType2), - expected: false, - }, - // Enum type to other - { - type1: enumType1, - type2: factory.createLiteralType(), - expected: false, - }, - // Enum variant type to class type - { - type1: enumVariantType1, - type2: classType1, - expected: false, - }, - { - type1: enumVariantType1, - type2: coreTypes.Any, - expected: true, - }, - { - type1: enumVariantType1.withExplicitNullability(true), - type2: coreTypes.Any, - expected: false, - }, - { - type1: enumVariantType1.withExplicitNullability(true), - type2: coreTypes.AnyOrNull, - expected: true, - }, - // Enum variant type to enum type - { - type1: enumVariantType1, - type2: enumType1, - expected: true, - }, - { - type1: enumVariantType1, - type2: enumType2, - expected: false, - }, - { - type1: enumVariantType1.withExplicitNullability(true), - type2: enumType1, - expected: false, - }, - { - type1: enumVariantType1.withExplicitNullability(true), - type2: enumType1.withExplicitNullability(true), - expected: true, - }, - // Enum variant type to enum variant type - { - type1: enumVariantType1, - type2: enumVariantType1, - expected: true, - }, - { - type1: enumVariantType1, - type2: enumVariantType2, - expected: false, - }, - { - type1: enumVariantType1.withExplicitNullability(true), - type2: enumVariantType1, - expected: false, - }, - { - type1: enumVariantType1.withExplicitNullability(true), - type2: enumVariantType1.withExplicitNullability(true), - expected: true, - }, - // Enum variant type to union type - { - type1: enumVariantType1, - type2: factory.createUnionType(enumType1), - expected: true, - }, - { - type1: enumVariantType1, - type2: factory.createUnionType(enumType2), - expected: false, - }, - // Enum variant type to other - { - type1: enumVariantType1, - type2: factory.createLiteralType(), - expected: false, - }, - // Literal type to class type - { - type1: factory.createLiteralType(), - type2: classType1, - expected: true, - }, - { - type1: factory.createLiteralType(new BooleanConstant(true)), - type2: coreTypes.Boolean, - expected: true, - }, - { - type1: factory.createLiteralType(new FloatConstant(1.5)), - type2: coreTypes.Float, - expected: true, - }, - { - type1: factory.createLiteralType(new IntConstant(1n)), - type2: coreTypes.Int, - expected: true, - }, - { - type1: factory.createLiteralType(NullConstant), - type2: coreTypes.NothingOrNull, - expected: true, - }, - { - type1: factory.createLiteralType(new StringConstant('')), - type2: coreTypes.String, - expected: true, - }, - { - type1: factory.createLiteralType(new IntConstant(1n)), - type2: coreTypes.Any, - expected: true, - }, - { - type1: factory.createLiteralType(new IntConstant(1n)), - type2: coreTypes.String, - expected: false, - }, - { - type1: factory.createLiteralType(new IntConstant(1n), NullConstant), - type2: coreTypes.Int.withExplicitNullability(true), - expected: true, - }, - { - type1: factory.createLiteralType(new IntConstant(1n), NullConstant), - type2: coreTypes.Int, - expected: false, - }, - { - type1: factory.createLiteralType(new IntConstant(1n), new StringConstant('')), - type2: coreTypes.Int, - expected: false, - }, - { - type1: factory.createLiteralType(new IntConstant(1n), new StringConstant('')), - type2: coreTypes.String, - expected: false, - }, - { - type1: factory.createLiteralType(new IntConstant(1n), new StringConstant('')), - type2: coreTypes.Any, - expected: true, - }, - { - type1: factory.createLiteralType(new IntConstant(1n), new StringConstant(''), NullConstant), - type2: coreTypes.AnyOrNull, - expected: true, - }, - // Literal type to literal type - { - type1: factory.createLiteralType(), - type2: factory.createLiteralType(), - expected: true, - }, - { - type1: factory.createLiteralType(new BooleanConstant(true)), - type2: factory.createLiteralType(new BooleanConstant(true)), - expected: true, - }, - { - type1: factory.createLiteralType(new BooleanConstant(true)), - type2: factory.createLiteralType(new BooleanConstant(false)), - expected: false, - }, - { - type1: factory.createLiteralType(new BooleanConstant(true)), - type2: factory.createLiteralType(new FloatConstant(1.5)), - expected: false, - }, - { - type1: factory.createLiteralType(new BooleanConstant(true), NullConstant), - type2: factory.createLiteralType(new BooleanConstant(true), NullConstant), - expected: true, - }, - { - type1: factory.createLiteralType(new BooleanConstant(true), NullConstant), - type2: factory.createLiteralType(new BooleanConstant(true)), - expected: false, - }, - // Literal type to union type - { - type1: factory.createLiteralType(new IntConstant(1n)), - type2: factory.createUnionType(coreTypes.Any), - expected: true, - }, - { - type1: factory.createLiteralType(new IntConstant(1n)), - type2: factory.createUnionType(coreTypes.String), - expected: false, - }, - // Literal type to other - { - type1: factory.createLiteralType(), // Empty literal type - type2: enumType1, - expected: true, - }, - { - type1: factory.createLiteralType(NullConstant), - type2: enumType1, - expected: false, - }, - { - type1: factory.createLiteralType(NullConstant), - type2: enumType1.withExplicitNullability(true), - expected: true, - }, - { - type1: factory.createLiteralType(NullConstant, NullConstant), - type2: enumType1.withExplicitNullability(true), - expected: true, - }, - { - type1: factory.createLiteralType(new IntConstant(1n)), - type2: enumType1, - expected: false, - }, - // Named tuple type to class type - { - type1: factory.createNamedTupleType(), - type2: classType1, - expected: false, - }, - { - type1: factory.createNamedTupleType(), - type2: coreTypes.Any, - expected: true, - }, - { - type1: factory.createNamedTupleType(), - type2: coreTypes.AnyOrNull, - expected: true, - }, - // Named tuple type to named tuple type - { - type1: factory.createNamedTupleType(), - type2: factory.createNamedTupleType(), - expected: true, - }, - { - type1: factory.createNamedTupleType(new NamedTupleEntry(undefined, 'a', coreTypes.Int)), - type2: factory.createNamedTupleType(new NamedTupleEntry(undefined, 'a', coreTypes.Int)), - expected: true, - }, - { - type1: factory.createNamedTupleType(new NamedTupleEntry(class1, 'a', coreTypes.Int)), - type2: factory.createNamedTupleType(new NamedTupleEntry(class2, 'a', coreTypes.Int)), - expected: true, - }, - { - type1: factory.createNamedTupleType(new NamedTupleEntry(undefined, 'a', coreTypes.Int)), - type2: factory.createNamedTupleType(new NamedTupleEntry(undefined, 'a', coreTypes.Any)), - expected: true, - }, - { - type1: factory.createNamedTupleType(new NamedTupleEntry(undefined, 'a', coreTypes.Any)), - type2: factory.createNamedTupleType(new NamedTupleEntry(undefined, 'a', coreTypes.Int)), - expected: false, - }, - { - type1: factory.createNamedTupleType(new NamedTupleEntry(undefined, 'a', coreTypes.Int)), - type2: factory.createNamedTupleType(new NamedTupleEntry(undefined, 'b', coreTypes.Int)), - expected: false, - }, - // Named tuple type to other - { - type1: factory.createNamedTupleType(), - type2: enumType1, - expected: false, - }, - // Static type to callable type - { - type1: factory.createStaticType(classType1), - type2: callableType1, - expected: false, - }, - { - type1: factory.createStaticType(classType1), - type2: callableType3, - expected: true, - }, - { - type1: factory.createStaticType(classType2), - type2: callableType11, - expected: true, - }, - { - type1: factory.createStaticType(classType3), - type2: callableType1, - expected: false, - }, - { - type1: factory.createStaticType(enumType1), - type2: callableType1, - expected: false, - }, - { - type1: factory.createStaticType(enumVariantType1), - type2: callableType1, - expected: false, - }, - { - type1: factory.createStaticType(enumVariantType1), - type2: callableType3, - expected: true, - }, - { - type1: factory.createStaticType(enumVariantType2), - type2: callableType12, - expected: true, - }, - // Static type to class type - { - type1: factory.createStaticType(classType1), - type2: classType1, - expected: false, - }, - { - type1: factory.createStaticType(classType1), - type2: coreTypes.Any, - expected: true, - }, - { - type1: factory.createStaticType(classType1), - type2: coreTypes.AnyOrNull, - expected: true, - }, - // Static type to static type - { - type1: factory.createStaticType(classType1), - type2: factory.createStaticType(classType1), - expected: true, - }, - { - type1: factory.createStaticType(classType1), - type2: factory.createStaticType(classType2), - expected: false, - }, - // Static type to other - { - type1: factory.createStaticType(classType1), - type2: enumType1, - expected: false, - }, - // Union type to X - { - type1: factory.createUnionType(), - type2: classType1, - expected: true, - }, - { - type1: factory.createUnionType(classType1), - type2: classType1, - expected: true, - }, - { - type1: factory.createUnionType(classType1, classType2), - type2: classType1, - expected: true, - }, - { - type1: factory.createUnionType(classType1, classType3), - type2: classType1, - expected: false, - }, - { - type1: factory.createUnionType(classType1.withExplicitNullability(true)), - type2: classType1, - expected: false, - }, - { - type1: factory.createUnionType(classType1.withExplicitNullability(true)), - type2: classType1.withExplicitNullability(true), - expected: true, - }, - // Unknown to X - { - type1: UnknownType, - type2: UnknownType, - expected: false, - }, - { - type1: coreTypes.Nothing, - type2: UnknownType, - expected: true, - }, - { - type1: UnknownType, - type2: coreTypes.AnyOrNull, - expected: true, - }, - ]; -}; - -const classTypesWithTypeParameters = async (): Promise => { - const code = ` - class TestClass { - attr any: MyAny - - attr baseClassInvariantAny: BaseClassInvariant - attr baseClassCovariantAny: BaseClassCovariant - attr baseClassContravariantAny: BaseClassContravariant - - attr baseClassInvariantNumber: BaseClassInvariant - attr baseClassCovariantNumber: BaseClassCovariant - attr baseClassContravariantNumber: BaseClassContravariant - - attr baseClassInvariantInt: BaseClassInvariant - attr baseClassCovariantInt: BaseClassCovariant - attr baseClassContravariantInt: BaseClassContravariant - - attr subclassParameterizedInvariantAny: SubclassParameterizedInvariant - attr subclassParameterizedCovariantAny: SubclassParameterizedCovariant - attr subclassParameterizedContravariantAny: SubclassParameterizedContravariant - - attr subclassParameterizedInvariantNumber: SubclassParameterizedInvariant - attr subclassParameterizedCovariantNumber: SubclassParameterizedCovariant - attr subclassParameterizedContravariantNumber: SubclassParameterizedContravariant - - attr subclassParameterizedInvariantInt: SubclassParameterizedInvariant - attr subclassParameterizedCovariantInt: SubclassParameterizedCovariant - attr subclassParameterizedContravariantInt: SubclassParameterizedContravariant - - attr subclassFixedInvariant: SubclassFixedInvariant - attr subclassFixedCovariant: SubclassFixedCovariant - attr subclassFixedContravariant: SubclassFixedContravariant - } - - class MyAny - class MyNumber sub MyAny - class MyInt sub MyNumber - - class BaseClassInvariant sub MyAny - class BaseClassCovariant sub MyAny - class BaseClassContravariant sub MyAny - - class SubclassParameterizedInvariant sub BaseClassInvariant - class SubclassParameterizedCovariant sub BaseClassCovariant - class SubclassParameterizedContravariant sub BaseClassContravariant - - class SubclassFixedInvariant sub BaseClassInvariant - class SubclassFixedCovariant sub BaseClassCovariant - class SubclassFixedContravariant sub BaseClassContravariant - `; - const module = await getNodeOfType(services, code, isTslModule); - const classes = getModuleMembers(module).filter(isTslClass); - const attributes = getClassMembers(classes[0]).filter(isTslAttribute); - - const computeTypeOfAttributeWithName = computeTypeOfDeclarationWithName(attributes); - - const any = computeTypeOfAttributeWithName('any'); - - const baseClassInvariantAny = computeTypeOfAttributeWithName('baseClassInvariantAny'); - const baseClassCovariantAny = computeTypeOfAttributeWithName('baseClassCovariantAny'); - const baseClassContravariantAny = computeTypeOfAttributeWithName('baseClassContravariantAny'); - - const baseClassInvariantNumber = computeTypeOfAttributeWithName('baseClassInvariantNumber'); - const baseClassCovariantNumber = computeTypeOfAttributeWithName('baseClassCovariantNumber'); - const baseClassContravariantNumber = computeTypeOfAttributeWithName('baseClassContravariantNumber'); - - const baseClassInvariantInt = computeTypeOfAttributeWithName('baseClassInvariantInt'); - const baseClassCovariantInt = computeTypeOfAttributeWithName('baseClassCovariantInt'); - const baseClassContravariantInt = computeTypeOfAttributeWithName('baseClassContravariantInt'); - - const subclassParameterizedInvariantAny = computeTypeOfAttributeWithName('subclassParameterizedInvariantAny'); - const subclassParameterizedCovariantAny = computeTypeOfAttributeWithName('subclassParameterizedCovariantAny'); - const subclassParameterizedContravariantAny = computeTypeOfAttributeWithName( - 'subclassParameterizedContravariantAny', - ); - - const subclassParameterizedInvariantNumber = computeTypeOfAttributeWithName('subclassParameterizedInvariantNumber'); - const subclassParameterizedCovariantNumber = computeTypeOfAttributeWithName('subclassParameterizedCovariantNumber'); - const subclassParameterizedContravariantNumber = computeTypeOfAttributeWithName( - 'subclassParameterizedContravariantNumber', - ); - - const subclassParameterizedInvariantInt = computeTypeOfAttributeWithName('subclassParameterizedInvariantInt'); - const subclassParameterizedCovariantInt = computeTypeOfAttributeWithName('subclassParameterizedCovariantInt'); - const subclassParameterizedContravariantInt = computeTypeOfAttributeWithName( - 'subclassParameterizedContravariantInt', - ); - - const subclassFixedInvariant = computeTypeOfAttributeWithName('subclassFixedInvariant'); - const subclassFixedCovariant = computeTypeOfAttributeWithName('subclassFixedCovariant'); - const subclassFixedContravariant = computeTypeOfAttributeWithName('subclassFixedContravariant'); - - return [ - // Compare to MyAny - { - type1: baseClassInvariantAny, - type2: any, - expected: true, - }, - { - type1: subclassParameterizedCovariantAny, - type2: any, - expected: true, - }, - { - type1: subclassFixedContravariant, - type2: any, - expected: true, - }, - - // Compare to BaseClassInvariant - { - type1: subclassParameterizedInvariantAny, - type2: baseClassInvariantAny, - expected: true, - }, - { - type1: subclassParameterizedInvariantNumber, - type2: baseClassInvariantAny, - expected: false, - }, - { - type1: subclassParameterizedInvariantInt, - type2: baseClassInvariantAny, - expected: false, - }, - { - type1: subclassFixedInvariant, - type2: baseClassInvariantAny, - expected: false, - }, - - // Compare to BaseClassCovariant - { - type1: subclassParameterizedCovariantAny, - type2: baseClassCovariantAny, - expected: true, - }, - { - type1: subclassParameterizedCovariantNumber, - type2: baseClassCovariantAny, - expected: true, - }, - { - type1: subclassParameterizedCovariantInt, - type2: baseClassCovariantAny, - expected: true, - }, - { - type1: subclassFixedCovariant, - type2: baseClassCovariantAny, - expected: true, - }, - - // Compare to BaseClassContravariant - { - type1: subclassParameterizedContravariantAny, - type2: baseClassContravariantAny, - expected: true, - }, - { - type1: subclassParameterizedContravariantNumber, - type2: baseClassContravariantAny, - expected: false, - }, - { - type1: subclassParameterizedContravariantInt, - type2: baseClassContravariantAny, - expected: false, - }, - { - type1: subclassFixedContravariant, - type2: baseClassContravariantAny, - expected: false, - }, - - // Compare to BaseClassInvariant - { - type1: subclassParameterizedInvariantAny, - type2: baseClassInvariantNumber, - expected: false, - }, - { - type1: subclassParameterizedInvariantNumber, - type2: baseClassInvariantNumber, - expected: true, - }, - { - type1: subclassParameterizedInvariantInt, - type2: baseClassInvariantNumber, - expected: false, - }, - { - type1: subclassFixedInvariant, - type2: baseClassInvariantNumber, - expected: true, - }, - - // Compare to BaseClassCovariant - { - type1: subclassParameterizedCovariantAny, - type2: baseClassCovariantNumber, - expected: false, - }, - { - type1: subclassParameterizedCovariantNumber, - type2: baseClassCovariantNumber, - expected: true, - }, - { - type1: subclassParameterizedCovariantInt, - type2: baseClassCovariantNumber, - expected: true, - }, - { - type1: subclassFixedCovariant, - type2: baseClassCovariantNumber, - expected: true, - }, - - // Compare to BaseClassContravariant - { - type1: subclassParameterizedContravariantAny, - type2: baseClassContravariantNumber, - expected: true, - }, - { - type1: subclassParameterizedContravariantNumber, - type2: baseClassContravariantNumber, - expected: true, - }, - { - type1: subclassParameterizedContravariantInt, - type2: baseClassContravariantNumber, - expected: false, - }, - { - type1: subclassFixedContravariant, - type2: baseClassContravariantNumber, - expected: true, - }, - - // Compare to BaseClassInvariant - { - type1: subclassParameterizedInvariantAny, - type2: baseClassInvariantInt, - expected: false, - }, - { - type1: subclassParameterizedInvariantNumber, - type2: baseClassInvariantInt, - expected: false, - }, - { - type1: subclassParameterizedInvariantInt, - type2: baseClassInvariantInt, - expected: true, - }, - { - type1: subclassFixedInvariant, - type2: baseClassInvariantInt, - expected: false, - }, - - // Compare to BaseClassCovariant - { - type1: subclassParameterizedCovariantAny, - type2: baseClassCovariantInt, - expected: false, - }, - { - type1: subclassParameterizedCovariantNumber, - type2: baseClassCovariantInt, - expected: false, - }, - { - type1: subclassParameterizedCovariantInt, - type2: baseClassCovariantInt, - expected: true, - }, - { - type1: subclassFixedCovariant, - type2: baseClassCovariantInt, - expected: false, - }, - - // Compare to BaseClassContravariant - { - type1: subclassParameterizedContravariantAny, - type2: baseClassContravariantInt, - expected: true, - }, - { - type1: subclassParameterizedContravariantNumber, - type2: baseClassContravariantInt, - expected: true, - }, - { - type1: subclassParameterizedContravariantInt, - type2: baseClassContravariantInt, - expected: true, - }, - { - type1: subclassFixedContravariant, - type2: baseClassContravariantInt, - expected: true, - }, - ]; -}; - -const typeParameterTypes = async (): Promise => { - const code = ` - class TestClass< - Unbounded, - UpperBound sub Number, - IndirectUpperBound sub UpperBound, - Unresolved sub Unknown, - > - `; - const module = await getNodeOfType(services, code, isTslModule); - const classes = getModuleMembers(module).filter(isTslClass); - const typeParameters = getTypeParameters(classes[0]); - - const computeTypeOfTypeParameterWithName = computeTypeOfDeclarationWithName(typeParameters); - - const unbounded = computeTypeOfTypeParameterWithName('Unbounded'); - const upperBound = computeTypeOfTypeParameterWithName('UpperBound'); - const indirectUpperBound = computeTypeOfTypeParameterWithName('IndirectUpperBound'); - const unresolved = computeTypeOfTypeParameterWithName('Unresolved'); - - return [ - // Compare to Unbounded - { - type1: unbounded, - type2: unbounded, - expected: true, - }, - { - type1: upperBound, - type2: unbounded, - expected: false, - }, - { - type1: indirectUpperBound, - type2: unbounded, - expected: false, - }, - { - type1: unresolved, - type2: unbounded, - expected: false, - }, - { - type1: coreTypes.AnyOrNull, - type2: unbounded, - expected: false, - }, - { - type1: coreTypes.Nothing, - type2: unbounded, - expected: true, - }, - { - type1: coreTypes.NothingOrNull, - type2: unbounded, - expected: false, - }, - - // Compare to UpperBound - { - type1: unbounded, - type2: upperBound, - expected: false, - }, - { - type1: upperBound, - type2: upperBound, - expected: true, - }, - { - type1: indirectUpperBound, - type2: upperBound, - expected: true, - }, - { - type1: unresolved, - type2: upperBound, - expected: false, - }, - { - type1: coreTypes.AnyOrNull, - type2: upperBound, - expected: false, - }, - { - type1: coreTypes.Number, - type2: upperBound, - expected: false, - }, - { - type1: coreTypes.Number.withExplicitNullability(true), - type2: upperBound, - expected: false, - }, - { - type1: coreTypes.Number.withExplicitNullability(true), - type2: upperBound.withExplicitNullability(true), - expected: false, - }, - { - type1: coreTypes.Nothing, - type2: upperBound, - expected: true, - }, - - // Compare to IndirectUpperBound - { - type1: indirectUpperBound, - type2: indirectUpperBound, - expected: true, - }, - { - type1: indirectUpperBound, - type2: upperBound, - expected: true, - }, - { - type1: coreTypes.AnyOrNull, - type2: indirectUpperBound, - expected: false, - }, - { - type1: coreTypes.Nothing, - type2: indirectUpperBound, - expected: true, - }, - - // Compare to Unresolved - { - type1: upperBound, - type2: unresolved, - expected: false, - }, - { - type1: coreTypes.AnyOrNull, - type2: unresolved, - expected: false, - }, - { - type1: coreTypes.Nothing, - type2: unresolved, - expected: true, - }, - - // Compare to some other type - { - type1: unbounded, - type2: coreTypes.Any, - expected: false, - }, - { - type1: unbounded, - type2: coreTypes.AnyOrNull, - expected: true, - }, - { - type1: unbounded.withExplicitNullability(true), - type2: coreTypes.Any, - expected: false, - }, - { - type1: unbounded.withExplicitNullability(true), - type2: coreTypes.AnyOrNull, - expected: true, - }, - { - type1: upperBound, - type2: coreTypes.Any, - expected: true, - }, - { - type1: upperBound.withExplicitNullability(true), - type2: coreTypes.AnyOrNull, - expected: true, - }, - { - type1: upperBound, - type2: coreTypes.Number, - expected: true, - }, - { - type1: upperBound.withExplicitNullability(true), - type2: coreTypes.Any, - expected: false, - }, - { - type1: upperBound.withExplicitNullability(true), - type2: coreTypes.AnyOrNull, - expected: true, - }, - { - type1: upperBound.withExplicitNullability(true), - type2: coreTypes.Number, - expected: false, - }, - ]; -}; - -describe('TTSLTypeChecker', async () => { - const testCases = (await Promise.all([basic(), classTypesWithTypeParameters(), typeParameterTypes()])).flat(); - - describe.each(testCases)('isSubtypeOf', ({ type1, type2, expected }) => { - it(`should check whether ${type1} a subtype of ${type2}`, () => { - expect(typeChecker.isSubtypeOf(type1, type2)).toBe(expected); - }); - }); - - describe.each(testCases)('isSupertypeOf', ({ type2, type1, expected }) => { - it(`should check whether ${type2} a supertype of ${type1}`, () => { - expect(typeChecker.isSupertypeOf(type2, type1)).toBe(expected); - }); - }); -}); - -const computeTypeOfDeclarationWithName = (declarations: T[]) => { - return (name: string): Type => { - const result = declarations.find((declaration) => declaration.name === name); - return typeComputer.computeType(result); - }; -}; - -/** - * A test case for {@link TTSLTypeChecker.isSubtypeOf}. - */ -interface IsSubOrSupertypeOfTest { - /** - * The first type to check. - */ - type1: Type; - - /** - * The second type to check. - */ - type2: Type; - - /** - * Whether {@link type1} is expected to be assignable to {@link type2}. - */ - expected: boolean; -} diff --git a/packages/ttsl-lang/tests/language/typing/type computer/computeClassTypeForLiteralType.test.ts b/packages/ttsl-lang/tests/language/typing/type computer/computeClassTypeForLiteralType.test.ts deleted file mode 100644 index d6cbe36d..00000000 --- a/packages/ttsl-lang/tests/language/typing/type computer/computeClassTypeForLiteralType.test.ts +++ /dev/null @@ -1,109 +0,0 @@ -import { NodeFileSystem } from 'langium/node'; -import { describe, it } from 'vitest'; -import { - BooleanConstant, - FloatConstant, - IntConstant, - NullConstant, - StringConstant, -} from '../../../../src/language/partialEvaluation/model.js'; -import { LiteralType, Type } from '../../../../src/language/typing/model.js'; -import { expectEqualTypes } from '../../../helpers/testAssertions.js'; -import { createTTSLServices } from '../../../../src/language/index.js'; - -const services = (await createTTSLServices(NodeFileSystem)).TTSL; -const coreTypes = services.types.CoreTypes; -const factory = services.types.TypeFactory; -const typeComputer = services.types.TypeComputer; - -const tests: ComputeClassTypeForLiteralTypeTest[] = [ - // Base cases - { - literalType: factory.createLiteralType(), - expected: coreTypes.Nothing, - }, - { - literalType: factory.createLiteralType(new BooleanConstant(false)), - expected: coreTypes.Boolean, - }, - { - literalType: factory.createLiteralType(new FloatConstant(1.5)), - expected: coreTypes.Float, - }, - { - literalType: factory.createLiteralType(new IntConstant(1n)), - expected: coreTypes.Int, - }, - { - literalType: factory.createLiteralType(NullConstant), - expected: coreTypes.NothingOrNull, - }, - { - literalType: factory.createLiteralType(new StringConstant('')), - expected: coreTypes.String, - }, - // Nullable types - { - literalType: factory.createLiteralType(new BooleanConstant(false), NullConstant), - expected: coreTypes.Boolean.withExplicitNullability(true), - }, - { - literalType: factory.createLiteralType(new FloatConstant(1.5), NullConstant), - expected: coreTypes.Float.withExplicitNullability(true), - }, - { - literalType: factory.createLiteralType(new IntConstant(1n), NullConstant), - expected: coreTypes.Int.withExplicitNullability(true), - }, - { - literalType: factory.createLiteralType(new StringConstant(''), NullConstant), - expected: coreTypes.String.withExplicitNullability(true), - }, - // Other combinations - { - literalType: factory.createLiteralType(new BooleanConstant(false), new FloatConstant(1.5)), - expected: coreTypes.Any, - }, - { - literalType: factory.createLiteralType(new FloatConstant(1.5), new IntConstant(1n)), - expected: coreTypes.Number, - }, - { - literalType: factory.createLiteralType(new IntConstant(1n), new StringConstant('')), - expected: coreTypes.Any, - }, - { - literalType: factory.createLiteralType(new BooleanConstant(false), new FloatConstant(1.5), NullConstant), - expected: coreTypes.AnyOrNull, - }, - { - literalType: factory.createLiteralType(new FloatConstant(1.5), new IntConstant(1n), NullConstant), - expected: coreTypes.Number.withExplicitNullability(true), - }, - { - literalType: factory.createLiteralType(new IntConstant(1n), new StringConstant(''), NullConstant), - expected: coreTypes.AnyOrNull, - }, -]; - -describe.each(tests)('computeClassTypeForLiteralType', ({ literalType, expected }) => { - it(`should return the class type for a literal type (${literalType})`, () => { - const actual = typeComputer.computeClassTypeForLiteralType(literalType); - expectEqualTypes(actual, expected); - }); -}); - -/** - * A test case for {@link computeClassTypeForLiteralType}. - */ -interface ComputeClassTypeForLiteralTypeTest { - /** - * The literal type to compute the class type for. - */ - literalType: LiteralType; - - /** - * The expected type. - */ - expected: Type; -} diff --git a/packages/ttsl-lang/tests/language/typing/type computer/computeUpperBound.test.ts b/packages/ttsl-lang/tests/language/typing/type computer/computeUpperBound.test.ts deleted file mode 100644 index b0204492..00000000 --- a/packages/ttsl-lang/tests/language/typing/type computer/computeUpperBound.test.ts +++ /dev/null @@ -1,76 +0,0 @@ -import { NodeFileSystem } from 'langium/node'; -import { describe, it } from 'vitest'; -import { isTslClass, isTslModule, TslTypeParameter } from '../../../../src/language/generated/ast.js'; -import { createTTSLServices, getModuleMembers, getTypeParameters } from '../../../../src/language/index.js'; -import { Type, UnknownType } from '../../../../src/language/typing/model.js'; -import { getNodeOfType } from '../../../helpers/nodeFinder.js'; -import { expectEqualTypes } from '../../../helpers/testAssertions.js'; - -const services = (await createTTSLServices(NodeFileSystem)).TTSL; -const coreTypes = services.types.CoreTypes; -const typeComputer = services.types.TypeComputer; - -const code = ` - class MyClass< - Unbounded, - LegalDirectBounds sub Number, - LegalIndirectBounds sub LegalDirectBounds, - UnnamedBounds sub literal<2>, - UnresolvedBounds sub unknown, - > -`; -const module = await getNodeOfType(services, code, isTslModule); - -const classes = getModuleMembers(module).filter(isTslClass); -const typeParameters = getTypeParameters(classes[0]); - -const unbounded = typeParameters[0]!; -const legalDirectBounds = typeParameters[1]!; -const legalIndirectBounds = typeParameters[2]!; -const unnamedBounds = typeParameters[3]!; -const unresolvedBounds = typeParameters[4]!; - -const computeUpperBoundTests: ComputeUpperBoundTest[] = [ - { - typeParameter: unbounded, - expected: coreTypes.AnyOrNull, - }, - { - typeParameter: legalDirectBounds, - expected: coreTypes.Number, - }, - { - typeParameter: legalIndirectBounds, - expected: coreTypes.Number, - }, - { - typeParameter: unnamedBounds, - expected: UnknownType, - }, - { - typeParameter: unresolvedBounds, - expected: UnknownType, - }, -]; - -describe.each(computeUpperBoundTests)('computeUpperBound', ({ typeParameter, expected }) => { - it(`should return the upper bound (${typeParameter.name})`, () => { - const actual = typeComputer.computeUpperBound(typeParameter); - expectEqualTypes(actual, expected); - }); -}); - -/** - * A test case for {@link TypeComputer.computeUpperBound}. - */ -interface ComputeUpperBoundTest { - /** - * The type parameter to get the bound for. - */ - typeParameter: TslTypeParameter; - - /** - * The expected bound - */ - expected: Type; -} diff --git a/packages/ttsl-lang/tests/language/typing/type computer/streamSupertypes.test.ts b/packages/ttsl-lang/tests/language/typing/type computer/streamSupertypes.test.ts deleted file mode 100644 index 99b0f96a..00000000 --- a/packages/ttsl-lang/tests/language/typing/type computer/streamSupertypes.test.ts +++ /dev/null @@ -1,143 +0,0 @@ -import { NodeFileSystem } from 'langium/node'; -import { describe, expect, it } from 'vitest'; -import { ClassType } from '../../../../src/language/typing/model.js'; -import { isTslAttribute } from '../../../../src/language/generated/ast.js'; -import { getNodeOfType } from '../../../helpers/nodeFinder.js'; -import { AssertionError } from 'assert'; -import { createTTSLServices } from '../../../../src/language/index.js'; - -const services = (await createTTSLServices(NodeFileSystem)).TTSL; -const typeComputer = services.types.TypeComputer; - -describe('streamProperSupertypes', async () => { - const properSupertypesAsStrings = (type: ClassType | undefined) => - typeComputer - .streamProperSupertypes(type) - .map((clazz) => clazz.toString()) - .toArray(); - - it('should return an empty stream if passed undefined', () => { - expect(properSupertypesAsStrings(undefined)).toStrictEqual([]); - }); - - const testCases = [ - { - testName: 'should return "Any" if the class has no parent types', - code: ` - class Test { - attr a: A - } - - class A - `, - expected: ['Any'], - }, - { - testName: 'should return "Any" if the first parent type is not a class', - code: ` - class Test { - attr a: A - } - - class A sub E - enum E - `, - expected: ['Any'], - }, - { - testName: 'should return the superclasses of a class (no cycle, parameterized parent type, implicit any)', - code: ` - class Test { - attr a: A - } - - class A sub B - class B - `, - expected: ['B', 'Any'], - }, - { - testName: 'should return the superclasses of a class (no cycle, fixed parent type, implicit any)', - code: ` - class Test { - attr a: A - } - - class A sub B - class B - `, - expected: ['B', 'Any'], - }, - { - testName: 'should return the superclasses of a class (no cycle, explicit any)', - code: ` - class Test { - attr a: A - } - - class A sub Any - `, - expected: ['Any'], - }, - { - testName: 'should return the superclasses of a class (cycle)', - code: ` - class Test { - attr a: A - } - - class A sub B - class B sub C - class C sub A - `, - expected: ['B', 'C', 'Any'], - }, - { - testName: 'should only consider the first parent type', - code: ` - class Test { - attr a: A - } - - class A sub B, C - class B - class C - `, - expected: ['B', 'Any'], - }, - { - testName: 'should disregard the nullability of the parent type', - code: ` - class Test { - attr a: A - } - - class A sub B? - class B - `, - expected: ['B', 'Any'], - }, - { - testName: 'should consider the nullability of the start type', - code: ` - class Test { - attr a: A? - } - - class A sub B - class B - `, - expected: ['B?', 'Any?'], - }, - ]; - - it.each(testCases)('$testName', async ({ code, expected }) => { - const firstAttribute = await getNodeOfType(services, code, isTslAttribute); - const type = typeComputer.computeType(firstAttribute); - if (!(type instanceof ClassType)) { - throw new AssertionError({ message: 'Expected type to be an instance of ClassType.', actual: type }); - } - - expect(properSupertypesAsStrings(type)).toStrictEqual(expected); - }); -}); From 3163d267456731121eacac99e5c273e7f3b02993 Mon Sep 17 00:00:00 2001 From: alex-senger Date: Tue, 23 Jul 2024 13:48:20 +0200 Subject: [PATCH 133/183] feat: add einkommenssteuer --- .../builtins/steuern/einkommenssteuer.ttsl | 84 +++++++++++++++++++ 1 file changed, 84 insertions(+) create mode 100644 src/resources/builtins/steuern/einkommenssteuer.ttsl diff --git a/src/resources/builtins/steuern/einkommenssteuer.ttsl b/src/resources/builtins/steuern/einkommenssteuer.ttsl new file mode 100644 index 00000000..cac3bfc9 --- /dev/null +++ b/src/resources/builtins/steuern/einkommenssteuer.ttsl @@ -0,0 +1,84 @@ +package einkommenssteuer + +/** + * Berechnung der Einkommenssteuer ohne Kinderfreibetrag auf Steuernummer-Ebene. + */ +public function einkommenssteuerOhneKinderfreibetrag(): Float per year { + var zuVerstEinkProPerson = zuVersteuerndesEinkommenOhneKinderfreibetrag() / anzahlPersonen(); + var einkommensteuer = anzahlPersonen() * einkommensteuerTarif(zuVerstEinkProPerson, einkommensteuerParameter); + return einkommensteuer; +} + +/** + * Berechnung der Einkommenssteuer mit Kinderfreibetrag auf Steuernummer-Ebene ab 2002. + * TODO + */ +public function einkommenssteuerMitKinderfreibetrag(): Float per year { + from 2002-01-01 { + var zuVerstEinkProPerson = zuVersteuerndesEinkommenMitKinderfreibetrag() / anzahlPersonen(); + var einkommensteuer = anzahlPersonen() * einkommensteuerTarif(zuVerstEinkProPerson, einkommensteuerParameter); + return einkommensteuer; + } +} + +/** + * Berechnung des Einkommensteuertarifs. + * TODO + */ +private function einkommensteuerTarif( + einkommen: Float, + einkommensteuerParameter: Map +): Float { + return piecewisePolynomial( + x=einkommen, + thresholds=einkommensteuerParameter["eink_st_tarif"]["thresholds"], + rates=einkommensteuerParameter["eink_st_tarif"]["rates"], + intercepts_at_lower_thresholds=einkommensteuerParameter["eink_st_tarif"]["intercepts_at_lower_thresholds"] + ); +} + +/** + * Einkommenssteuer auf Steuernummer-Ebene, die Kindergeld oder Kinderfreibetrag berücksichtigt. + */ +public function einkommenssteuer(): Float per year { + to 1996-12-31 { + einkommenssteuerMitKinderfreibetrag() + } + from 1997-01-01 { + if kinderfreibetragGuenstiger() { + return einkommenssteuerMitKinderfreibetrag() + relativesKindergeld(); + } else { + return einkommenssteuerOhneKinderfreibetrag(); + } + } +} + +/** + * Bestimmung, ob der Kinderfreibetrag günstiger ist als das Kindergeld. + */ +public function kinderfreibetragGuenstiger(): Boolean { + var differenzbetrag = einkommenssteuerOhneKinderfreibetrag() - einkommenssteuerMitKinderfreibetrag(); + return differenzbetrag > relativesKindergeld(); +} + +/** + * Kindergeld relevant für die Einkommenssteuer ohne Staffelung ab 2023. + */ +public function relativesKindergeldOhneStaffelung(): Float per month { + to 2022-12-31 { + var anzahlAnsprueche = anzahlAnsprueche1() + anzahlAnsprueche2(); + if anzahlAnsprueche == 0 { + return 0.0; + } + var sumKindergeld = 0.0; + for(var i = 1; i < anzahlAnsprueche; i = i + 1) { + var kindergeldKey = min(i, max(kindergeldParameter["kindergeld"].keys())); + sumKindergeld += kindergeldParameter["kindergeld"][kindergeldKey]; + } + return sumKindergeld / 2; + } + from 2023-01-01 { + var anzahlAnsprueche = anzahlAnsprueche1 + anzahlAnsprueche2; + return kindergeldParameter["kindergeld"] * anzahlAnsprueche / 2; + } +} \ No newline at end of file From f1fc165b599984a38c16d6cbfa19cbf3ddcb2f72 Mon Sep 17 00:00:00 2001 From: alex-senger Date: Tue, 23 Jul 2024 13:48:30 +0200 Subject: [PATCH 134/183] feat: add abgeltungssteuer --- .../builtins/steuern/abgeltungssteuer.ttsl | 25 +++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 src/resources/builtins/steuern/abgeltungssteuer.ttsl diff --git a/src/resources/builtins/steuern/abgeltungssteuer.ttsl b/src/resources/builtins/steuern/abgeltungssteuer.ttsl new file mode 100644 index 00000000..bf86e9b8 --- /dev/null +++ b/src/resources/builtins/steuern/abgeltungssteuer.ttsl @@ -0,0 +1,25 @@ +package abgeltungssteuer + +from abgeltungssteuersatz import abgeltungssteuersatz +from einkommenssteuerAbzuege import sparerpauschbetrag, sparerWerbungskostenPauschbetrag +from math import max + +/** + * Berechnung der Abgeltungssteuer auf Steuernummer-Ebene. + */ +public function abgeltungssteuer(): Float per year { + from 2009-01-01 { + return abgeltungssteuersatz * zuVersteuerndeKapitalertraege(); + } +} + +/** + * Berechnung des zu versteuernden Einkommens auf Steuernummer-Ebene. + */ +public function zuVersteuerndeKapitalertraege(): Float per year { + var abzug = anzahlPersonen() * ( + sparerpauschbetrag + + sparerWerbungskostenPauschbetrag + ); + return max(kapitalertraegeBrutto() - abzug, 0.0); +} \ No newline at end of file From f6653889fd1d8bd66fcebfa9936a4898d44a7a63 Mon Sep 17 00:00:00 2001 From: methr0 Date: Tue, 30 Jul 2024 10:28:35 +0200 Subject: [PATCH 135/183] remove anything related to member Accesses --- .../generation/ttsl-python-generator.ts | 101 ++++++---------- .../src/language/grammar/ttsl.langium | 9 -- .../src/language/lsp/ttsl-formatter.ts | 9 -- .../ttsl-partial-evaluator.ts | 33 ------ .../language/scoping/ttsl-scope-provider.ts | 26 +---- .../other/expressions/chainedExpressions.ts | 7 +- .../other/expressions/references.ts | 4 - .../src/language/validation/style.ts | 4 +- .../src/language/validation/types.ts | 4 - .../gen_input.py | 28 ----- .../gen_input.py.map | 1 - .../gen_input_test.py | 4 - .../expressions/member access/input.sdstest | 41 ------- .../of call results/main.sdstest | 31 ----- .../of enum variant parameters/main.sdstest | 16 --- .../of enum variants/main.sdstest | 14 --- .../member accesses/on null/main.sdstest | 9 -- .../on other receivers/main.sdstest | 8 -- .../member accesses/unresolved/main.sdstest | 13 --- .../on type parameters/main.sdstest | 27 ----- .../to class members/hiding/main.sdstest | 43 ------- .../to class members/inheritance/main.sdstest | 84 -------------- .../instance attributes/main.sdstest | 108 ------------------ .../instance methods/main.sdstest | 108 ------------------ .../nested classes/main.sdstest | 89 --------------- .../nested enums/main.sdstest | 90 --------------- .../to class members/overriding/main.sdstest | 25 ---- .../static attributes/main.sdstest | 85 -------------- .../static methods/main.sdstest | 89 --------------- .../to enum variants/main.sdstest | 33 ------ .../main.sdstest | 45 -------- .../call with nullable receiver/main.sdstest | 33 ------ .../main.sdstest | 27 ----- .../to results/of block lambdas/main.sdstest | 20 ---- .../main.sdstest | 23 ---- .../to results/of callable types/main.sdstest | 15 --- .../main.sdstest | 22 ---- .../to results/of functions/main.sdstest | 15 --- .../main.sdstest | 22 ---- .../to results/of segments/main.sdstest | 15 --- .../main.sdstest | 76 ------------ .../to enum variants/main.sdstest | 28 ----- .../to nested classes/main.sdstest | 13 --- .../to nested enums/main.sdstest | 13 --- .../member accesses/to other/main.sdstest | 45 -------- .../member accesses/unresolved/main.sdstest | 11 -- .../missing null safety/main.sdstest | 51 --------- .../main.sdstest | 50 -------- .../unnecessary null safety/main.sdstest | 51 --------- 49 files changed, 39 insertions(+), 1679 deletions(-) delete mode 100644 packages/ttsl-lang/tests/resources/generation/runner integration/expressions/member access/generated/tests/generator/memberAccessWithRunnerIntegration/gen_input.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/runner integration/expressions/member access/generated/tests/generator/memberAccessWithRunnerIntegration/gen_input.py.map delete mode 100644 packages/ttsl-lang/tests/resources/generation/runner integration/expressions/member access/generated/tests/generator/memberAccessWithRunnerIntegration/gen_input_test.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/runner integration/expressions/member access/input.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/of call results/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/of enum variant parameters/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/of enum variants/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/on null/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/on other receivers/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/unresolved/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/scoping/member accesses/on type parameters/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/hiding/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/inheritance/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/instance attributes/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/instance methods/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/nested classes/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/nested enums/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/overriding/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/static attributes/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/static methods/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/scoping/member accesses/to enum variants/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/scoping/member accesses/to parameter of enum variants/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/scoping/member accesses/to results/call with nullable receiver/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of block lambdas (matching member)/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of block lambdas/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of callable types (matching member)/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of callable types/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of functions (matching member)/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of functions/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of segments (matching member)/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of segments/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/member accesses/on class with type parameters/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/member accesses/to enum variants/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/member accesses/to nested classes/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/member accesses/to nested enums/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/member accesses/to other/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/member accesses/unresolved/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/validation/other/expressions/member accesses/enum variant must be instantiated/main.sdstest diff --git a/packages/ttsl-lang/src/language/generation/ttsl-python-generator.ts b/packages/ttsl-lang/src/language/generation/ttsl-python-generator.ts index 7ddb1c7a..eb8ccffa 100644 --- a/packages/ttsl-lang/src/language/generation/ttsl-python-generator.ts +++ b/packages/ttsl-lang/src/language/generation/ttsl-python-generator.ts @@ -24,7 +24,6 @@ import { isTslInfixOperation, isTslList, isTslDictionary, - isTslMemberAccess, isTslModule, isTslPlaceholder, isTslPrefixOperation, @@ -191,37 +190,37 @@ const UTILITY_CONSTANTS: UtilityFunction = { indentation: PYTHON_INDENT }).appendNewLine() .append('def getValue(self, date = None):').appendNewLine() - .indent(indentingNode => - indentingNode.append( + .indent(indentingNode1 => + indentingNode1.append( 'keys = sorted(self.dict.keys())' ).appendNewLine().append( 'if(keys[0] == "empty"):' - ).appendNewLine().indent(indentingNode => - indentingNode.append( + ).appendNewLine().indent(indentingNode2 => + indentingNode2.append( 'return self.dict["empty"]' )).appendNewLine() .append( 'for index, key in enumerate(keys):' ).appendNewLine() - .indent(indentingNode => - indentingNode.append( + .indent(indentingNode2 => + indentingNode2.append( 'if key[0] == "s":' ).appendNewLine() - .indent(indentingNode => - indentingNode.append( + .indent(indentingNode3 => + indentingNode3.append( 'if key.replace("s", "") <= date:' ).appendNewLine() - .indent(indentingNode => - indentingNode.append( + .indent(indentingNode4 => + indentingNode4.append( 'result = self.dict[key]' ))).appendNewLine() .append('if key[0] == "e":').appendNewLine() - .indent(indentingNode => - indentingNode.append( + .indent(indentingNode3 => + indentingNode3.append( 'if date <= keys[len(keys)-1-index].replace("e", ""):' ).appendNewLine() - .indent(indentingNode => - indentingNode.append( + .indent(indentingNode4 => + indentingNode4.append( 'result = self.dict[keys[len(keys)-1-index]]' ).appendNewLine()))) .append('return result'))), @@ -459,7 +458,7 @@ export class TTSLPythonGenerator { .map((constant) => this.generateConstant(constant, importSet, utilitySet, typeVariableSet, generateOptions), ); - const data = getModuleMembers(module) + const datas = getModuleMembers(module) .filter(isTslData) .map((data) => this.generateData(data, importSet, utilitySet, typeVariableSet, generateOptions), @@ -510,14 +509,14 @@ export class TTSLPythonGenerator { output.append(joinToNode(constants, (constant) => constant, { separator: SPACING })); output.appendNewLine(); } - if (data.length > 0) { + if (datas.length > 0) { output.appendNewLineIf( imports.length > 0 || typeVariableSet.size > 0 || utilitySet.size > 0 || functions.length > 0 || constants.length > 0, ); output.append('# Data --------------------------------------------------------------------'); output.appendNewLine(); output.appendNewLine(); - output.append(joinToNode(data, (data) => data, { separator: SPACING })); + output.append(joinToNode(datas, (data) => data, { separator: SPACING })); output.appendNewLine(); } return output; @@ -543,13 +542,12 @@ export class TTSLPythonGenerator { 'name', )(this.getPythonNameOrDefault(funct))}(${this.generateFunctionParameter(funct, infoFrame)}${this.generateParameters(funct.parameterList, infoFrame)}):` .appendNewLine() - .indent({ indentedChildren: [this.generateFunctionBlock(funct.body, infoFrame, undefined, funct.timeunit)], indentation: PYTHON_INDENT }); + .indent({ indentedChildren: [this.generateFunctionBlock(funct.body, infoFrame, funct.timeunit)], indentation: PYTHON_INDENT }); } private generateFunctionBlock( block: TslFunctionBlock, frame: GenerationInfoFrame, - generateLambda: boolean = false, timeunit: TslTimeunit | undefined, ): CompositeGeneratorNode { const targetPlaceholder = getPlaceholderByName(block, frame.targetPlaceholder); @@ -561,16 +559,16 @@ export class TTSLPythonGenerator { if (isTslExpression(block.returnValue)){ if(timeunit){ resultBlock.append(`if timeunit != None:`) - if (timeunit?.timeunit == 'day'){ + if (timeunit?.timeunit === 'day'){ frame.addUtility(UTILITY_TIMEUNIT_DAY); resultBlock.appendNewLine().indent([`result = ${UTILITY_TIMEUNIT_DAY.name}(${this.generateExpression(block.returnValue, frame).contents}, timeunit)`]).appendNewLine() - } else if (timeunit?.timeunit == 'week'){ + } else if (timeunit?.timeunit === 'week'){ frame.addUtility(UTILITY_TIMEUNIT_WEEK); resultBlock.appendNewLine().indent([`result = ${UTILITY_TIMEUNIT_WEEK.name}(${this.generateExpression(block.returnValue, frame).contents}, timeunit)`]).appendNewLine() - } else if (timeunit?.timeunit == 'month'){ + } else if (timeunit?.timeunit === 'month'){ frame.addUtility(UTILITY_TIMEUNIT_MONTH); resultBlock.appendNewLine().indent([`result = ${UTILITY_TIMEUNIT_MONTH.name}(${this.generateExpression(block.returnValue, frame).contents}, timeunit)`]).appendNewLine() - } else if (timeunit?.timeunit == 'year'){ + } else if (timeunit?.timeunit === 'year'){ frame.addUtility(UTILITY_TIMEUNIT_YEAR); resultBlock.appendNewLine().indent([`result = ${UTILITY_TIMEUNIT_YEAR.name}(${this.generateExpression(block.returnValue, frame).contents}, timeunit)`]).appendNewLine() } @@ -609,18 +607,18 @@ export class TTSLPythonGenerator { ); infoFrame.addUtility(UTILITY_CONSTANTS); - if(constant.value != null){ + if(constant.value){ return expandTracedToNode(constant)`${this.getPythonNameOrDefault(constant)} = ${traceToNode( constant )(UTILITY_CONSTANTS.name)}({"empty": ${this.generateExpression(constant.value, infoFrame)}})` - } else if (constant.timespanValueEntries != null){ + } else if (constant.timespanValueEntries){ return expandTracedToNode(constant)`${constant.name}Dict = {${joinTracedToNode(constant, 'timespanValueEntries')( constant.timespanValueEntries, (entry) => expandTracedToNode(entry)`${traceToNode( entry, 'timespan', - )(this.generateDateString(entry.timespan, infoFrame))}: ${traceToNode( + )(this.generateDateString(entry.timespan))}: ${traceToNode( entry, 'value', )(this.generateExpression(entry.value, infoFrame))}`, @@ -636,11 +634,10 @@ export class TTSLPythonGenerator { private generateDateString( timespan: TslTimespan, - frame: GenerationInfoFrame, ): CompositeGeneratorNode | undefined { - if(timespan.start != null){ + if(timespan.start){ return expandToNode`s${timespan.start.date.toUTCString()}` // add 's' to mark that it's the start of the timespan - } else if (timespan.end != null){ + } else if (timespan.end){ return expandToNode`e${timespan.end.date.toUTCString()}` // add 'e' to mark that it's the end of the timespan } else { /* c8 ignore next 2 */ @@ -655,15 +652,6 @@ export class TTSLPythonGenerator { typeVariableSet: Set, generateOptions: GenerateOptions, ): CompositeGeneratorNode{ - const infoFrame = new GenerationInfoFrame( - importSet, - utilitySet, - typeVariableSet, - true, - generateOptions.targetPlaceholder, - generateOptions.disableRunnerIntegration, - ); - return expandToNode`${data.name} = ${data.type}()` } @@ -716,7 +704,7 @@ export class TTSLPythonGenerator { ? `${localValue.declarationName} as ${localValue.alias}` : localValue.declarationName!, ) || []; - if(key == ''){ + if(key === ''){ declaredImports.push(`import ${[...new Set(importedDecls)].join(', ')}`); }else{ declaredImports.push(`from ${key} import ${[...new Set(importedDecls)].join(', ')}`); @@ -737,7 +725,6 @@ export class TTSLPythonGenerator { private generateBlock( block: TslBlock, frame: GenerationInfoFrame, - generateLambda: boolean = false, ): CompositeGeneratorNode { const targetPlaceholder = getPlaceholderByName(block, frame.targetPlaceholder); let statements = getStatements(block); @@ -826,21 +813,21 @@ export class TTSLPythonGenerator { } else if (isTslTimespanStatement(statement)) { var start = '' var end = '' - if (statement.timespan.start != null){ + if (statement.timespan.start){ start = statement.timespan.start.date.toUTCString() + ' <=' } - if (statement.timespan.end != null){ + if (statement.timespan.end){ end = '< ' + statement.timespan.end.date.toUTCString() } - if (statement.timespan.start == null && statement.timespan.end == null){ + if (!statement.timespan.start && !statement.timespan.end){ throw new Error(`Timespan has neither a start nor an end value`); } return expandTracedToNode(statement)`if ${start} date ${end}: - ${this.generateFunctionBlock(statement.block, frame, false, undefined)}`; + ${this.generateFunctionBlock(statement.block, frame, undefined)}`; } else if (isTslConditionalStatement(statement)) { let elseBlock = new CompositeGeneratorNode if (isTslBlock(statement.elseBlock)){ - let generatedBlock = this.generateBlock((statement.elseBlock), frame, false) + let generatedBlock = this.generateBlock((statement.elseBlock), frame) elseBlock = expandTracedToNode(statement.elseBlock)`else:`.appendNewLine().indent(indentingNode => indentingNode.append(`${generatedBlock}`)) } @@ -963,7 +950,7 @@ export class TTSLPythonGenerator { if(sortedArgs[0]){ let arg = sortedArgs[0]; - if(receiver.value == "len"){ + if(receiver.value === "len"){ if(isTslReference(arg.value)){ frame.addUtility(UTILITY_LEN_FUNCTION); return expandTracedToNode(expression)`${traceToNode( @@ -971,7 +958,7 @@ export class TTSLPythonGenerator { 'receiver', )(UTILITY_LEN_FUNCTION.name)}(${arg.value.target.ref?.name})`; } - } else if(receiver.value == "keys"){ + } else if(receiver.value === "keys"){ if(isTslReference(arg.value)){ frame.addUtility(UTILITY_KEYS_FUNCTION); return expandTracedToNode(expression)`${traceToNode( @@ -979,7 +966,7 @@ export class TTSLPythonGenerator { 'receiver', )(UTILITY_KEYS_FUNCTION.name)}(${arg.value.target.ref?.name})`; } - } else if(receiver.value == "values"){ + } else if(receiver.value === "values"){ if(isTslReference(arg.value)){ frame.addUtility(UTILITY_VALUES_FUNCTION); return expandTracedToNode(expression)`${traceToNode( @@ -996,9 +983,6 @@ export class TTSLPythonGenerator { const pythonCall = this.builtinFunction.getPythonCall(callable); if (pythonCall) { let thisParam: CompositeGeneratorNode | undefined = undefined; - if (isTslMemberAccess(expression.receiver)) { - thisParam = this.generateExpression(expression.receiver.receiver, frame); - } const argumentsMap = this.getArgumentsMap(getArguments(expression), frame); call = this.generatePythonCall(expression, pythonCall, argumentsMap, frame, thisParam); } @@ -1071,19 +1055,6 @@ export class TTSLPythonGenerator { frame, )}[${this.generateExpression(expression.index, frame)}]`; } - } else if (isTslMemberAccess(expression)) { - const member = expression.member?.target.ref!; - const receiver = this.generateExpression(expression.receiver, frame); - const memberExpression = this.generateExpression(expression.member!, frame); - if (expression.isNullSafe) { - frame.addUtility(UTILITY_NULL_SAFE_MEMBER_ACCESS); - return expandTracedToNode(expression)`${traceToNode( - expression, - 'isNullSafe', - )(UTILITY_NULL_SAFE_MEMBER_ACCESS.name)}(${receiver}, '${memberExpression}')`; - } else { - return expandTracedToNode(expression)`${receiver}.${memberExpression}`; - } } else if (isTslPrefixOperation(expression)) { const operand = this.generateExpression(expression.operand, frame); switch (expression.operator) { diff --git a/packages/ttsl-lang/src/language/grammar/ttsl.langium b/packages/ttsl-lang/src/language/grammar/ttsl.langium index f3c15778..0daa3ef5 100644 --- a/packages/ttsl-lang/src/language/grammar/ttsl.langium +++ b/packages/ttsl-lang/src/language/grammar/ttsl.langium @@ -492,10 +492,6 @@ interface TslIndexedAccess extends TslChainedExpression { index: TslExpression } -interface TslMemberAccess extends TslChainedExpression { - member?: TslReference -} - TslChainedExpression returns TslExpression: TslPrimaryExpression ( @@ -506,11 +502,6 @@ TslChainedExpression returns TslExpression: | {TslIndexedAccess.receiver=current} (isNullSafe?='?')? '[' index=TslExpression ']' - - | {TslMemberAccess.receiver=current} - (isNullSafe?='?')? - '.' - member=TslReference )* ; diff --git a/packages/ttsl-lang/src/language/lsp/ttsl-formatter.ts b/packages/ttsl-lang/src/language/lsp/ttsl-formatter.ts index befd62bf..5183703b 100644 --- a/packages/ttsl-lang/src/language/lsp/ttsl-formatter.ts +++ b/packages/ttsl-lang/src/language/lsp/ttsl-formatter.ts @@ -86,8 +86,6 @@ export class TTSLFormatter extends AbstractFormatter { this.formatTslArgument(node); } else if (ast.isTslIndexedAccess(node)) { this.formatTslIndexedAccess(node); - } else if (ast.isTslMemberAccess(node)) { - this.formatTslMemberAccess(node); } else if (ast.isTslList(node)) { this.formatTslList(node); } else if (ast.isTslDictionary(node)) { @@ -386,13 +384,6 @@ export class TTSLFormatter extends AbstractFormatter { formatter.keyword(']').prepend(noSpace()); } - private formatTslMemberAccess(node: ast.TslMemberAccess) { - const formatter = this.getNodeFormatter(node); - - formatter.keyword('?').surround(noSpace()); - formatter.keyword('.').surround(noSpace()); - } - private formatTslList(node: ast.TslList) { const formatter = this.getNodeFormatter(node); diff --git a/packages/ttsl-lang/src/language/partialEvaluation/ttsl-partial-evaluator.ts b/packages/ttsl-lang/src/language/partialEvaluation/ttsl-partial-evaluator.ts index a5075ec6..f1454e21 100644 --- a/packages/ttsl-lang/src/language/partialEvaluation/ttsl-partial-evaluator.ts +++ b/packages/ttsl-lang/src/language/partialEvaluation/ttsl-partial-evaluator.ts @@ -16,12 +16,10 @@ import { isTslInt, isTslList, isTslDictionary, - isTslMemberAccess, isTslNull, isTslParameter, isTslPrefixOperation, isTslReference, - isTslResult, isTslTemplateString, isTslTemplateStringEnd, isTslTemplateStringInner, @@ -37,7 +35,6 @@ import { type TslInfixOperation, type TslList, type TslDictionary, - type TslMemberAccess, type TslParameter, type TslPrefixOperation, type TslTemplateString, @@ -216,8 +213,6 @@ export class TTSLPartialEvaluator { return this.evaluateList(node, substitutions, visited); } else if (isTslDictionary(node)) { return this.evaluateMap(node, substitutions, visited); - } else if (isTslMemberAccess(node)) { - return this.evaluateMemberAccess(node, substitutions, visited); } else if (isTslPrefixOperation(node)) { return this.evaluatePrefixOperation(node, substitutions, visited); } else if (isTslReference(node)) { @@ -608,26 +603,6 @@ export class TTSLPartialEvaluator { return UnknownEvaluatedNode; } - private evaluateMemberAccess( - node: TslMemberAccess, - substitutions: ParameterSubstitutions, - visited: VisitedState[], - ): EvaluatedNode { - const member = node.member?.target?.ref; - if (!member) { - return UnknownEvaluatedNode; - } - - const receiver = this.evaluateWithRecursionCheck(node.receiver, substitutions, visited); - if (receiver instanceof EvaluatedNamedTuple) { - return receiver.getResultValueByName(member.name); - } else if (receiver.equals(NullConstant) && node.isNullSafe) { - return NullConstant; - } - - return UnknownEvaluatedNode; - } - // ----------------------------------------------------------------------------------------------------------------- // Parameter substitutions // ----------------------------------------------------------------------------------------------------------------- @@ -666,14 +641,6 @@ export class TTSLPartialEvaluator { return node.entries.every( (it) => this.canBeValueOfConstantParameter(it.key) && this.canBeValueOfConstantParameter(it.value), ); - } else if (isTslMemberAccess(node)) { - // 1. We cannot allow all member accesses, since we might also access an attribute that has type 'Int', for - // example. Thus, type checking does not always show an error, even though we already restrict the - // possible types of constant parameters. - // 2. If the member cannot be resolved, we already show an error. - // 3. If the enum variant has parameters that are not provided, we already show an error. - const member = node.member?.target?.ref; - return !member; } else if (isTslPrefixOperation(node)) { return node.operator === '-' && this.canBeValueOfConstantParameter(node.operand); } else if (isTslReference(node)) { diff --git a/packages/ttsl-lang/src/language/scoping/ttsl-scope-provider.ts b/packages/ttsl-lang/src/language/scoping/ttsl-scope-provider.ts index 532aad8a..acaff1d7 100644 --- a/packages/ttsl-lang/src/language/scoping/ttsl-scope-provider.ts +++ b/packages/ttsl-lang/src/language/scoping/ttsl-scope-provider.ts @@ -18,7 +18,6 @@ import { isTslCallable, isTslFunction, isTslImportedDeclaration, - isTslMemberAccess, isTslModule, isTslNamedTypeDeclaration, isTslParameter, @@ -31,7 +30,6 @@ import { type TslCallable, TslDeclaration, TslImportedDeclaration, - TslMemberAccess, type TslParameter, TslPlaceholder, TslReference, @@ -79,11 +77,7 @@ export class TTSLScopeProvider extends DefaultScopeProvider { } else if (isTslImportedDeclaration(node) && context.property === 'declaration') { return this.getScopeForImportedDeclarationDeclaration(node); } else if (isTslReference(node) && context.property === 'target') { - if (isTslMemberAccess(node.$container) && node.$containerProperty === 'member') { - return this.getScopeForMemberAccessMember(node.$container); - } else { - return this.getScopeForReferenceTarget(node, context); - } + return this.getScopeForReferenceTarget(node, context); } else { return super.getScope(context); } @@ -116,24 +110,6 @@ export class TTSLScopeProvider extends DefaultScopeProvider { return this.createScope(declarationsInPackage); } - private getScopeForMemberAccessMember(node: TslMemberAccess): Scope { - // Call results - let resultScope = EMPTY_SCOPE; - if (isTslFunction(node.receiver)) { - const results = getResults(node.receiver); - - if (results.length > 1) { - return this.createScopeForNodes(results); - } else { - // If there is only one result, it can be accessed by name but members of the result with the same name - // take precedence. - resultScope = this.createScopeForNodes(results); - } - } - - return resultScope; - } - private getScopeForReferenceTarget(node: TslReference, context: ReferenceInfo): Scope { // Declarations in other files let currentScope = this.getGlobalScope(TslDeclaration, context); diff --git a/packages/ttsl-lang/src/language/validation/other/expressions/chainedExpressions.ts b/packages/ttsl-lang/src/language/validation/other/expressions/chainedExpressions.ts index 7e62e3e0..7d3834c0 100644 --- a/packages/ttsl-lang/src/language/validation/other/expressions/chainedExpressions.ts +++ b/packages/ttsl-lang/src/language/validation/other/expressions/chainedExpressions.ts @@ -1,5 +1,5 @@ import { TTSLServices } from '../../../ttsl-module.js'; -import { isTslCall, isTslIndexedAccess, isTslMemberAccess, TslChainedExpression } from '../../../generated/ast.js'; +import { isTslCall, isTslIndexedAccess, TslChainedExpression } from '../../../generated/ast.js'; import { ValidationAcceptor } from 'langium'; import { UnknownType } from '../../../typing/model.js'; @@ -29,11 +29,6 @@ export const chainedExpressionsMustBeNullSafeIfReceiverIsNullable = (services: T node, code: CODE_CHAINED_EXPRESSION_MISSING_NULL_SAFETY, }); - } else if (isTslMemberAccess(node)) { - accept('error', 'The receiver can be null so a null-safe member access must be used.', { - node, - code: CODE_CHAINED_EXPRESSION_MISSING_NULL_SAFETY, - }); } }; }; diff --git a/packages/ttsl-lang/src/language/validation/other/expressions/references.ts b/packages/ttsl-lang/src/language/validation/other/expressions/references.ts index 68b90b01..ffb4cc40 100644 --- a/packages/ttsl-lang/src/language/validation/other/expressions/references.ts +++ b/packages/ttsl-lang/src/language/validation/other/expressions/references.ts @@ -1,7 +1,6 @@ import { isTslCall, isTslFunction, - isTslMemberAccess, TslReference, } from '../../../generated/ast.js'; import { AstNode, ValidationAcceptor } from 'langium'; @@ -16,9 +15,6 @@ export const referenceMustNotBeFunctionPointer = (node: TslReference, accept: Va // Get the containing member access if the node is on its right side let nodeOrContainer: AstNode | undefined = node; - if (isTslMemberAccess(node.$container) && node.$containerProperty === 'member') { - nodeOrContainer = nodeOrContainer.$container; - } if (!isTslCall(nodeOrContainer?.$container)) { accept( diff --git a/packages/ttsl-lang/src/language/validation/style.ts b/packages/ttsl-lang/src/language/validation/style.ts index 0991cf55..d22061bd 100644 --- a/packages/ttsl-lang/src/language/validation/style.ts +++ b/packages/ttsl-lang/src/language/validation/style.ts @@ -3,7 +3,6 @@ import { isEmpty } from '../../helpers/collections.js'; import { isTslCall, isTslIndexedAccess, - isTslMemberAccess, TslCall, TslChainedExpression, TslFunction, @@ -169,8 +168,7 @@ export const chainedExpressionNullSafetyShouldBeNeeded = (services: TTSLServices if ( (isTslCall(node)) || - (isTslIndexedAccess(node) && typeChecker.canBeAccessedByIndex(receiverType)) || - isTslMemberAccess(node) + (isTslIndexedAccess(node) && typeChecker.canBeAccessedByIndex(receiverType)) ) { accept('info', 'The receiver is never null, so null-safety is unnecessary.', { node, diff --git a/packages/ttsl-lang/src/language/validation/types.ts b/packages/ttsl-lang/src/language/validation/types.ts index 1be10317..c83f73a7 100644 --- a/packages/ttsl-lang/src/language/validation/types.ts +++ b/packages/ttsl-lang/src/language/validation/types.ts @@ -1,6 +1,5 @@ import { AstNode, ValidationAcceptor } from 'langium'; import { - isTslMemberAccess, isTslReference, TslCall, TslIndexedAccess, @@ -57,9 +56,6 @@ export const callReceiverMustBeCallable = (services: TTSLServices) => { return (node: TslCall, accept: ValidationAcceptor): void => { let receiver: AstNode | undefined = node.receiver; - if (isTslMemberAccess(receiver)) { - receiver = receiver.member; - } if (isTslReference(receiver)) { const target = receiver.target.ref; diff --git a/packages/ttsl-lang/tests/resources/generation/runner integration/expressions/member access/generated/tests/generator/memberAccessWithRunnerIntegration/gen_input.py b/packages/ttsl-lang/tests/resources/generation/runner integration/expressions/member access/generated/tests/generator/memberAccessWithRunnerIntegration/gen_input.py deleted file mode 100644 index 01cb88b9..00000000 --- a/packages/ttsl-lang/tests/resources/generation/runner integration/expressions/member access/generated/tests/generator/memberAccessWithRunnerIntegration/gen_input.py +++ /dev/null @@ -1,28 +0,0 @@ -# Imports ---------------------------------------------------------------------- - -import TTSL_runner -from typing import Any, TypeVar - -# Type variables --------------------------------------------------------------- - -__gen_T = TypeVar("__gen_T") - -# Utils ------------------------------------------------------------------------ - -def __gen_null_safe_member_access(receiver: Any, member_name: str) -> __gen_T | None: - return getattr(receiver, member_name) if receiver is not None else None - -# Pipelines -------------------------------------------------------------------- - -def test(): - f(TTSL_runner.memoized_call("tests.generator.memberAccessWithRunnerIntegration.g", g, [], [])) - f(TTSL_runner.memoized_call("tests.generator.memberAccessWithRunnerIntegration.h", h, [], [])[0]) - f(TTSL_runner.memoized_call("tests.generator.memberAccessWithRunnerIntegration.h", h, [], [])[1]) - f(TTSL_runner.memoized_call("tests.generator.memberAccessWithRunnerIntegration.C", C, [], []).a) - f(TTSL_runner.memoized_call("tests.generator.memberAccessWithRunnerIntegration.C", C, [], []).c) - f(__gen_null_safe_member_access(TTSL_runner.memoized_call("tests.generator.memberAccessWithRunnerIntegration.factory", factory, [], []), 'a')) - f(__gen_null_safe_member_access(TTSL_runner.memoized_call("tests.generator.memberAccessWithRunnerIntegration.factory", factory, [], []), 'c')) - f(TTSL_runner.memoized_call("tests.generator.memberAccessWithRunnerIntegration.C.i", lambda *_ : 1.i(TTSL_runner.memoized_call("tests.generator.memberAccessWithRunnerIntegration.C", C, [], [])), [1], [])) - f(TTSL_runner.memoized_call("tests.generator.memberAccessWithRunnerIntegration.C.j", C.j, [TTSL_runner.memoized_call("tests.generator.memberAccessWithRunnerIntegration.C", C, [], []), 123], [])) - f(TTSL_runner.memoized_call("tests.generator.memberAccessWithRunnerIntegration.C.k2", C.k2, [TTSL_runner.memoized_call("tests.generator.memberAccessWithRunnerIntegration.C", C, [], []), 'abc'], [])) - f(TTSL_runner.memoized_call("tests.generator.memberAccessWithRunnerIntegration.C.from_csv_file", C.from_csv_file, ['abc.csv'], [TTSL_runner.file_mtime('abc.csv')])) diff --git a/packages/ttsl-lang/tests/resources/generation/runner integration/expressions/member access/generated/tests/generator/memberAccessWithRunnerIntegration/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/runner integration/expressions/member access/generated/tests/generator/memberAccessWithRunnerIntegration/gen_input.py.map deleted file mode 100644 index 54186000..00000000 --- a/packages/ttsl-lang/tests/resources/generation/runner integration/expressions/member access/generated/tests/generator/memberAccessWithRunnerIntegration/gen_input.py.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"sources":["input.ttsl"],"names":["test","f","g","h","result1","result2","c","a","b","factory","j","k","from_csv_file"],"mappings":"AAAA;;;;;;;;;;;;;;;;AA4BA,IAASA,IAAI;IACTC,CAAC,CAAC,mFAAAC,CAAC;IACHD,CAAC,CAAC,mFAAAE,CAAC,UAAGC,CAAO;IACbH,CAAC,CAAC,mFAAAE,CAAC,UAAGE,CAAO;IACbJ,CAAC,CAAC,mFAAAK,CAAC,UAAGC,CAAC;IACPN,CAAC,CAAC,mFAAAK,CAAC,UAAGE,CAAC;IACPP,CAAC,CAAU,6BAAC,CAAV,yFAAAQ,OAAO,YAAIF,CAAC;IACdN,CAAC,CAAU,6BAAC,CAAV,yFAAAQ,OAAO,YAAID,CAAC;IACdP,CAAC,CAAC,iGAAM,CAAC,GAAP,mFAAAK,CAAC,aAAK,CAAC;IACTL,CAAC,CAAC,qFAAAK,CAAC,CAAGI,CAAC,GAAL,mFAAAJ,CAAC,WAAK,GAAG;IACXL,CAAC,CAAC,sFAAAK,CAAC,CAAGK,EAAC,GAAL,mFAAAL,CAAC,WAAK,KAAK;IACbL,CAAC,CAAC,iGAAAK,CAAC,CAACM,aAAa,GAAC,SAAS,IAAT,yBAAA,SAAS","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/runner integration/expressions/member access/generated/tests/generator/memberAccessWithRunnerIntegration/gen_input_test.py b/packages/ttsl-lang/tests/resources/generation/runner integration/expressions/member access/generated/tests/generator/memberAccessWithRunnerIntegration/gen_input_test.py deleted file mode 100644 index 824f70b1..00000000 --- a/packages/ttsl-lang/tests/resources/generation/runner integration/expressions/member access/generated/tests/generator/memberAccessWithRunnerIntegration/gen_input_test.py +++ /dev/null @@ -1,4 +0,0 @@ -from .gen_input import test - -if __name__ == '__main__': - test() diff --git a/packages/ttsl-lang/tests/resources/generation/runner integration/expressions/member access/input.sdstest b/packages/ttsl-lang/tests/resources/generation/runner integration/expressions/member access/input.sdstest deleted file mode 100644 index 27404f55..00000000 --- a/packages/ttsl-lang/tests/resources/generation/runner integration/expressions/member access/input.sdstest +++ /dev/null @@ -1,41 +0,0 @@ -package tests.generator.memberAccessWithRunnerIntegration - -@Impure([ImpurityReason.Other]) fun f(param: Any?) - -@Pure fun g() -> result: Boolean - -@Pure fun h() -> (result1: Boolean, result2: Boolean) - -class C() { - attr a: Int - @PythonName("c") attr b: Int - - @Pure - @PythonCall("$param.i($this)") - fun i(param: Any?) -> result: Boolean - - @Pure - fun j(param: Any?) -> result: Boolean - - @Pure - @PythonName("k2") fun k(param: Any?) -> result: Boolean - - @Impure([ImpurityReason.FileReadFromParameterizedPath("name")]) - static fun from_csv_file(name: String) -> c: C -} - -@Pure fun factory() -> instance: C? - -pipeline test { - f(g().result); - f(h().result1); - f(h().result2); - f(C().a); - f(C().b); - f(factory()?.a); - f(factory()?.b); - f(C().i(1)); - f(C().j(123)); - f(C().k("abc")); - f(C.from_csv_file("abc.csv")); -} diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/of call results/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/of call results/main.sdstest deleted file mode 100644 index 28a065d8..00000000 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/of call results/main.sdstest +++ /dev/null @@ -1,31 +0,0 @@ -package tests.partialValidation.recursiveCases.memberAccesses.ofCallResults - -segment mySegment(p: Int, q: Int = 2) -> (r: Int, s: Int) { - yield r = p; - yield s = q; -} - -pipeline test { - val blockLambda = (p: Int, q: Int = 2) { - yield r = p; - yield s = q; - }; - - // $TEST$ serialization 1 - »mySegment(1).r«; - - // $TEST$ serialization 2 - »mySegment(1).s«; - - // $TEST$ serialization ? - »mySegment(1).unresolved«; - - // $TEST$ serialization 1 - »blockLambda(1).r«; - - // $TEST$ serialization 2 - »blockLambda(1).s«; - - // $TEST$ serialization ? - »blockLambda(1).unresolved«; -} diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/of enum variant parameters/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/of enum variant parameters/main.sdstest deleted file mode 100644 index d99bebee..00000000 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/of enum variant parameters/main.sdstest +++ /dev/null @@ -1,16 +0,0 @@ -package tests.partialValidation.recursiveCases.memberAccesses.ofEnumVariantParameter - -enum MyEnum { - MyEnumVariantWithParameters(p: Int, q: Int = 2) -} - -pipeline test { - // $TEST$ serialization 1 - »MyEnum.MyEnumVariantWithParameters(1).p«; - - // $TEST$ serialization 2 - »MyEnum.MyEnumVariantWithParameters(1).q«; - - // $TEST$ serialization ? - »MyEnum.MyEnumVariantWithParameters(1).unresolved«; -} diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/of enum variants/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/of enum variants/main.sdstest deleted file mode 100644 index e95c58d3..00000000 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/of enum variants/main.sdstest +++ /dev/null @@ -1,14 +0,0 @@ -package tests.partialValidation.recursiveCases.memberAccesses.ofEnumVariants - -enum MyEnum { - MyEnumVariantWithoutParameters - MyEnumVariantWithParameters(p: Int, q: Int = 3) -} - -pipeline test { - // $TEST$ serialization MyEnumVariantWithoutParameters - »MyEnum.MyEnumVariantWithoutParameters«; - - // $TEST$ serialization MyEnumVariantWithParameters - »MyEnum.MyEnumVariantWithParameters«; -} diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/on null/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/on null/main.sdstest deleted file mode 100644 index 85aa824e..00000000 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/on null/main.sdstest +++ /dev/null @@ -1,9 +0,0 @@ -package tests.partialValidation.recursiveCases.memberAccesses.onNull - -pipeline test { - // $TEST$ serialization ? - »null.toString«; - - // $TEST$ serialization null - »null?.toString«; -} diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/on other receivers/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/on other receivers/main.sdstest deleted file mode 100644 index 583ff6fc..00000000 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/on other receivers/main.sdstest +++ /dev/null @@ -1,8 +0,0 @@ -package tests.partialValidation.recursiveCases.memberAccesses.onOtherReceivers - -@Pure fun f() -> result: Int - -pipeline test { - // $TEST$ serialization ? - »f().result«; -} diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/unresolved/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/unresolved/main.sdstest deleted file mode 100644 index c5bf09ca..00000000 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/member accesses/unresolved/main.sdstest +++ /dev/null @@ -1,13 +0,0 @@ -package tests.partialValidation.recursiveCases.memberAccesses.unresolved - -enum MyEnum { - MyEnumVariant -} - -pipeline test { - // $TEST$ serialization ? - »unresolved.MyEnumVariant«; - - // $TEST$ serialization ? - »MyEnum.unresolved«; -} diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/on type parameters/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/on type parameters/main.sdstest deleted file mode 100644 index 4883da99..00000000 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/on type parameters/main.sdstest +++ /dev/null @@ -1,27 +0,0 @@ -package tests.scoping.memberAccesses.onTypeParameters - -class C { - // $TEST$ target attribute - attr »a«: Int -} - -class MyClass( - unbounded: Unbounded, - upperBound: UpperBound, - - // $TEST$ unresolved - p1: Any = unbounded.»a«, - // $TEST$ references attribute - p2: Any = upperBound.»a«, -) { - attr unbounded: Unbounded - attr upperBound: UpperBound -} - -segment mySegment(instance: MyClass) { - // $TEST$ references attribute - instance.unbounded.»a«; - - // $TEST$ references attribute - instance.upperBound.»a«; -} diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/hiding/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/hiding/main.sdstest deleted file mode 100644 index 8f4afe94..00000000 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/hiding/main.sdstest +++ /dev/null @@ -1,43 +0,0 @@ -package tests.scoping.memberAccesses.toClassMembers.hiding - -class MySuperClass { - // $TEST$ target MySuperClass_myStaticAttribute - static attr »myStaticAttribute«: Int - - // $TEST$ target MySuperClass_myNestedClass - class »MyNestedClass« - - // $TEST$ target MySuperClass_myNestedEnum - enum »MyNestedEnum« - - // $TEST$ target MySuperClass_myStaticMethod - static fun »myStaticMethod1«() -} - -class MyClass sub MySuperClass { - // $TEST$ target MyClass_myStaticAttribute - static attr »myStaticAttribute«: Int - - // $TEST$ target MyClass_myNestedClass - class »MyNestedClass« - - // $TEST$ target MyClass_myNestedEnum - enum »MyNestedEnum« - - // $TEST$ target MyClass_myStaticMethod - static fun »myStaticMethod1«() -} - -pipeline myPipeline { - // $TEST$ references MyClass_myStaticAttribute - MyClass.»myStaticAttribute«; - - // $TEST$ references MyClass_myNestedClass - MyClass.»MyNestedClass«; - - // $TEST$ references MyClass_myNestedEnum - MyClass.»MyNestedEnum«; - - // $TEST$ references MyClass_myStaticMethod - MyClass.»myStaticMethod1«(); -} diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/inheritance/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/inheritance/main.sdstest deleted file mode 100644 index ae51019d..00000000 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/inheritance/main.sdstest +++ /dev/null @@ -1,84 +0,0 @@ -package tests.scoping.memberAccesses.toClassMembers.inheritance - -class MySuperClass1 { - // $TEST$ target MySuperClass1_myInstanceAttribute - attr »myInstanceAttribute1«: Int - - // $TEST$ target MySuperClass1_myInstanceMethod - fun »myInstanceMethod1«() - - - // $TEST$ target MySuperClass1_myStaticAttribute - static attr »myStaticAttribute1«: Int - - // $TEST$ target MySuperClass1_myNestedClass - class »MyNestedClass1« - - // $TEST$ target MySuperClass1_myNestedEnum - enum »MyNestedEnum1« - - // $TEST$ target MySuperClass1_myStaticMethod - static fun »myStaticMethod1«() -} - -class MySuperClass2 { - // $TEST$ target MySuperClass2_myInstanceAttribute - attr »myInstanceAttribute2«: Int - - // $TEST$ target MySuperClass2_myInstanceMethod - fun »myInstanceMethod2«() - - - // $TEST$ target MySuperClass2_myStaticAttribute - static attr »myStaticAttribute2«: Int - - // $TEST$ target MySuperClass2_myNestedClass - class »MyNestedClass2« - - // $TEST$ target MySuperClass2_myNestedEnum - enum »MyNestedEnum2« - - // $TEST$ target MySuperClass2_myStaticMethod - static fun »myStaticMethod2«() -} - -class MyClass() sub MySuperClass1, MySuperClass2 - -pipeline myPipeline { - // $TEST$ references MySuperClass1_myInstanceAttribute - MyClass().»myInstanceAttribute1«; - - // $TEST$ references MySuperClass1_myInstanceMethod - MyClass().»myInstanceMethod1«(); - - // $TEST$ references MySuperClass1_myStaticAttribute - MyClass.»myStaticAttribute1«; - - // $TEST$ references MySuperClass1_myNestedClass - MyClass.»MyNestedClass1«; - - // $TEST$ references MySuperClass1_myNestedEnum - MyClass.»MyNestedEnum1«; - - // $TEST$ references MySuperClass1_myStaticMethod - MyClass.»myStaticMethod1«(); - - - // $TEST$ unresolved - MyClass().»myInstanceAttribute2«; - - // $TEST$ unresolved - MyClass().»myInstanceMethod2«(); - - // $TEST$ unresolved - MyClass.»myStaticAttribute2«; - - // $TEST$ unresolved - MyClass.»MyNestedClass2«; - - // $TEST$ unresolved - MyClass.»MyNestedEnum2«; - - // $TEST$ unresolved - MyClass.»myStaticMethod2«(); -} diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/instance attributes/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/instance attributes/main.sdstest deleted file mode 100644 index 4a5ddbcb..00000000 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/instance attributes/main.sdstest +++ /dev/null @@ -1,108 +0,0 @@ -package tests.scoping.memberAccesses.toClassMembers.instanceAttributes - -class MyClass { - // $TEST$ target myInstanceAttribute - attr »myInstanceAttribute«: Int - - - // $TEST$ target redeclaredAsInstanceAttribute - attr »redeclaredAsInstanceAttribute«: Int - attr redeclaredAsInstanceAttribute: Int - - // $TEST$ target redeclaredAsStaticAttribute - attr »redeclaredAsStaticAttribute«: Int - static attr redeclaredAsStaticAttribute: Int - - // $TEST$ target redeclaredAsNestedClass - attr »redeclaredAsNestedClass«: Int - class redeclaredAsNestedClass - - // $TEST$ target redeclaredAsNestedEnum - attr »redeclaredAsNestedEnum«: Int - enum redeclaredAsNestedEnum - - // $TEST$ target redeclaredAsInstanceMethod - attr »redeclaredAsInstanceMethod«: Int - fun redeclaredAsInstanceMethod() - - // $TEST$ target redeclaredAsStaticMethod - attr »redeclaredAsStaticMethod«: Int - static fun redeclaredAsStaticMethod() - - - // $TEST$ target declaredPreviouslyAsStaticAttribute - static attr declaredPreviouslyAsStaticAttribute: Int - attr »declaredPreviouslyAsStaticAttribute«: Int - - // $TEST$ target declaredPreviouslyAsNestedClass - class declaredPreviouslyAsNestedClass - attr »declaredPreviouslyAsNestedClass«: Int - - // $TEST$ target declaredPreviouslyAsNestedEnum - class declaredPreviouslyAsNestedEnum - attr »declaredPreviouslyAsNestedEnum«: Int - - // $TEST$ target declaredPreviouslyAsStaticMethod - static fun declaredPreviouslyAsStaticMethod() - attr »declaredPreviouslyAsStaticMethod«: Int -} - -class AnotherClass - -fun nullableMyClass() -> result: MyClass? - -pipeline myPipeline { - // $TEST$ references myInstanceAttribute - val myClass = MyClass(); - myClass.»myInstanceAttribute«; - - - // $TEST$ references redeclaredAsInstanceAttribute - MyClass().»redeclaredAsInstanceAttribute«; - - // $TEST$ references redeclaredAsStaticAttribute - MyClass().»redeclaredAsStaticAttribute«; - - // $TEST$ references redeclaredAsNestedClass - MyClass().»redeclaredAsNestedClass«; - - // $TEST$ references redeclaredAsNestedEnum - MyClass().»redeclaredAsNestedEnum«; - - // $TEST$ references redeclaredAsInstanceMethod - MyClass().»redeclaredAsInstanceMethod«; - - // $TEST$ references redeclaredAsStaticMethod - MyClass().»redeclaredAsStaticMethod«; - - // $TEST$ references declaredPreviouslyAsStaticAttribute - MyClass().»declaredPreviouslyAsStaticAttribute«; - - // $TEST$ references declaredPreviouslyAsNestedClass - MyClass().»declaredPreviouslyAsNestedClass«; - - // $TEST$ references declaredPreviouslyAsNestedEnum - MyClass().»declaredPreviouslyAsNestedEnum«; - - // $TEST$ references declaredPreviouslyAsStaticMethod - MyClass().»declaredPreviouslyAsStaticMethod«; - - // $TEST$ references myInstanceAttribute - nullableMyClass().»myInstanceAttribute«; - - // $TEST$ references myInstanceAttribute - nullableMyClass()?.»myInstanceAttribute«; - - - // $TEST$ unresolved - MyClass.»myInstanceAttribute«; - - // $TEST$ unresolved - AnotherClass().»myInstanceAttribute«; - - // $TEST$ unresolved - unresolved.»myInstanceAttribute«; - - // $TEST$ unresolved - MyClass.»unresolved«; -} diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/instance methods/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/instance methods/main.sdstest deleted file mode 100644 index 109f228e..00000000 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/instance methods/main.sdstest +++ /dev/null @@ -1,108 +0,0 @@ -package tests.scoping.memberAccesses.toClassMembers.instanceMethods - -class MyClass { - // $TEST$ target myInstanceMethod - fun »myInstanceMethod«() - - - // $TEST$ target redeclaredAsInstanceAttribute - fun »redeclaredAsInstanceAttribute«() - attr redeclaredAsInstanceAttribute: Int - - // $TEST$ target redeclaredAsStaticAttribute - fun »redeclaredAsStaticAttribute«() - static attr redeclaredAsStaticAttribute: Int - - // $TEST$ target redeclaredAsNestedClass - fun »redeclaredAsNestedClass«() - class redeclaredAsNestedClass - - // $TEST$ target redeclaredAsNestedEnum - fun »redeclaredAsNestedEnum«() - enum redeclaredAsNestedEnum - - // $TEST$ target redeclaredAsInstanceMethod - fun »redeclaredAsInstanceMethod«() - fun redeclaredAsInstanceMethod() - - // $TEST$ target redeclaredAsStaticMethod - fun »redeclaredAsStaticMethod«() - static fun redeclaredAsStaticMethod() - - - // $TEST$ target declaredPreviouslyAsStaticAttribute - static attr declaredPreviouslyAsStaticAttribute: Int - fun »declaredPreviouslyAsStaticAttribute«() - - // $TEST$ target declaredPreviouslyAsNestedClass - class declaredPreviouslyAsNestedClass - fun »declaredPreviouslyAsNestedClass«() - - // $TEST$ target declaredPreviouslyAsNestedEnum - class declaredPreviouslyAsNestedEnum - fun »declaredPreviouslyAsNestedEnum«() - - // $TEST$ target declaredPreviouslyAsStaticMethod - static fun declaredPreviouslyAsStaticMethod() - fun »declaredPreviouslyAsStaticMethod«() -} - -class AnotherClass - -fun nullableMyClass() -> result: MyClass? - -pipeline myPipeline { - // $TEST$ references myInstanceMethod - val myClass = MyClass(); - myClass.»myInstanceMethod«(); - - - // $TEST$ references redeclaredAsInstanceAttribute - MyClass().»redeclaredAsInstanceAttribute«(); - - // $TEST$ references redeclaredAsStaticAttribute - MyClass().»redeclaredAsStaticAttribute«(); - - // $TEST$ references redeclaredAsNestedClass - MyClass().»redeclaredAsNestedClass«(); - - // $TEST$ references redeclaredAsNestedEnum - MyClass().»redeclaredAsNestedEnum«(); - - // $TEST$ references redeclaredAsInstanceMethod - MyClass().»redeclaredAsInstanceMethod«(); - - // $TEST$ references redeclaredAsStaticMethod - MyClass().»redeclaredAsStaticMethod«(); - - // $TEST$ references declaredPreviouslyAsStaticAttribute - MyClass().»declaredPreviouslyAsStaticAttribute«(); - - // $TEST$ references declaredPreviouslyAsNestedClass - MyClass().»declaredPreviouslyAsNestedClass«(); - - // $TEST$ references declaredPreviouslyAsNestedEnum - MyClass().»declaredPreviouslyAsNestedEnum«(); - - // $TEST$ references declaredPreviouslyAsStaticMethod - MyClass().»declaredPreviouslyAsStaticMethod«(); - - // $TEST$ references myInstanceMethod - nullableMyClass().»myInstanceMethod«; - - // $TEST$ references myInstanceMethod - nullableMyClass()?.»myInstanceMethod«(); - - - // $TEST$ unresolved - MyClass.»myInstanceMethod«; - - // $TEST$ unresolved - AnotherClass().»myInstanceMethod«; - - // $TEST$ unresolved - unresolved.»myInstanceMethod«; - - // $TEST$ unresolved - MyClass.»unresolved«; -} diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/nested classes/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/nested classes/main.sdstest deleted file mode 100644 index deba1851..00000000 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/nested classes/main.sdstest +++ /dev/null @@ -1,89 +0,0 @@ -package tests.scoping.memberAccesses.toClassMembers.nestedClasses - -class MyClass { - // $TEST$ target myNestedClass - class »MyNestedClass« - - - // $TEST$ target redeclaredAsInstanceAttribute - class »RedeclaredAsInstanceAttribute« - attr RedeclaredAsInstanceAttribute: Int - - // $TEST$ target redeclaredAsStaticAttribute - class »RedeclaredAsStaticAttribute« - static attr RedeclaredAsStaticAttribute: Int - - // $TEST$ target redeclaredAsNestedClass - class »RedeclaredAsNestedClass« - class RedeclaredAsNestedClass - - // $TEST$ target redeclaredAsNestedEnum - class »RedeclaredAsNestedEnum« - enum RedeclaredAsNestedEnum - - // $TEST$ target redeclaredAsInstanceMethod - class »RedeclaredAsInstanceMethod« - fun RedeclaredAsInstanceMethod() - - // $TEST$ target redeclaredAsStaticMethod - class »RedeclaredAsStaticMethod« - static fun RedeclaredAsStaticMethod() - - - // $TEST$ target declaredPreviouslyAsInstanceAttribute - attr DeclaredPreviouslyAsInstanceAttribute: Int - class »DeclaredPreviouslyAsInstanceAttribute« - - // $TEST$ target declaredPreviouslyAsInstanceMethod - fun DeclaredPreviouslyAsInstanceMethod() - class »DeclaredPreviouslyAsInstanceMethod« -} - -class MyNestedClass -class AnotherClass - -pipeline myPipeline { - // $TEST$ references myNestedClass - MyClass.»MyNestedClass«; - - - // $TEST$ references redeclaredAsInstanceAttribute - MyClass.»RedeclaredAsInstanceAttribute«; - - // $TEST$ references redeclaredAsStaticAttribute - MyClass.»RedeclaredAsStaticAttribute«; - - // $TEST$ references redeclaredAsNestedClass - MyClass.»RedeclaredAsNestedClass«; - - // $TEST$ references redeclaredAsNestedEnum - MyClass.»RedeclaredAsNestedEnum«; - - // $TEST$ references redeclaredAsInstanceMethod - MyClass.»RedeclaredAsInstanceMethod«; - - // $TEST$ references redeclaredAsStaticMethod - MyClass.»RedeclaredAsStaticMethod«; - - // $TEST$ references declaredPreviouslyAsInstanceAttribute - MyClass.»DeclaredPreviouslyAsInstanceAttribute«; - - // $TEST$ references declaredPreviouslyAsInstanceMethod - MyClass.»DeclaredPreviouslyAsInstanceMethod«; - - - // $TEST$ unresolved - MyClass().»MyNestedClass«; - - // $TEST$ unresolved - MyClass.»AnotherClass«; - - // $TEST$ unresolved - AnotherClass.»MyNestedClass«; - - // $TEST$ unresolved - unresolved.»MyNestedClass«; - - // $TEST$ unresolved - MyClass.»unresolved«; -} diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/nested enums/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/nested enums/main.sdstest deleted file mode 100644 index 8829f39c..00000000 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/nested enums/main.sdstest +++ /dev/null @@ -1,90 +0,0 @@ -package tests.scoping.memberAccesses.toClassMembers.nestedEnums - -class MyClass { - // $TEST$ target myNestedEnum - enum »MyNestedEnum« - - - // $TEST$ target redeclaredAsInstanceAttribute - enum »RedeclaredAsInstanceAttribute« - attr RedeclaredAsInstanceAttribute: Int - - // $TEST$ target redeclaredAsStaticAttribute - enum »RedeclaredAsStaticAttribute« - static attr RedeclaredAsStaticAttribute: Int - - // $TEST$ target redeclaredAsNestedClass - enum »RedeclaredAsNestedClass« - class RedeclaredAsNestedClass - - // $TEST$ target redeclaredAsNestedEnum - enum »RedeclaredAsNestedEnum« - enum RedeclaredAsNestedEnum - - // $TEST$ target redeclaredAsInstanceMethod - enum »RedeclaredAsInstanceMethod« - fun RedeclaredAsInstanceMethod() - - // $TEST$ target redeclaredAsStaticMethod - enum »RedeclaredAsStaticMethod« - static fun RedeclaredAsStaticMethod() - - - // $TEST$ target declaredPreviouslyAsInstanceAttribute - attr DeclaredPreviouslyAsInstanceAttribute: Int - enum »DeclaredPreviouslyAsInstanceAttribute« - - // $TEST$ target declaredPreviouslyAsInstanceMethod - fun DeclaredPreviouslyAsInstanceMethod() - enum »DeclaredPreviouslyAsInstanceMethod« -} - -enum MyNestedEnum -class AnotherClass -enum AnotherEnum - -pipeline myPipeline { - // $TEST$ references myNestedEnum - MyClass.»MyNestedEnum«; - - - // $TEST$ references redeclaredAsInstanceAttribute - MyClass.»RedeclaredAsInstanceAttribute«; - - // $TEST$ references redeclaredAsStaticAttribute - MyClass.»RedeclaredAsStaticAttribute«; - - // $TEST$ references redeclaredAsNestedClass - MyClass.»RedeclaredAsNestedClass«; - - // $TEST$ references redeclaredAsNestedEnum - MyClass.»RedeclaredAsNestedEnum«; - - // $TEST$ references redeclaredAsInstanceMethod - MyClass.»RedeclaredAsInstanceMethod«; - - // $TEST$ references redeclaredAsStaticMethod - MyClass.»RedeclaredAsStaticMethod«; - - // $TEST$ references declaredPreviouslyAsInstanceAttribute - MyClass.»DeclaredPreviouslyAsInstanceAttribute«; - - // $TEST$ references declaredPreviouslyAsInstanceMethod - MyClass.»DeclaredPreviouslyAsInstanceMethod«; - - - // $TEST$ unresolved - MyClass().»MyNestedEnum«; - - // $TEST$ unresolved - MyClass.»AnotherEnum«; - - // $TEST$ unresolved - AnotherClass.»MyNestedEnum«; - - // $TEST$ unresolved - unresolved.»MyNestedEnum«; - - // $TEST$ unresolved - MyClass.»unresolved«; -} diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/overriding/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/overriding/main.sdstest deleted file mode 100644 index 67073732..00000000 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/overriding/main.sdstest +++ /dev/null @@ -1,25 +0,0 @@ -package tests.scoping.memberAccesses.toClassMembers.overriding - -class MySuperClass { - // $TEST$ target MySuperClass_myInstanceAttribute - attr »myInstanceAttribute«: Int - - // $TEST$ target MySuperClass_myInstanceMethod - fun »myInstanceMethod1«() -} - -class MyClass() sub MySuperClass { - // $TEST$ target MyClass_myInstanceAttribute - attr »myInstanceAttribute«: Int - - // $TEST$ target MyClass_myInstanceMethod - fun »myInstanceMethod1«() -} - -pipeline myPipeline { - // $TEST$ references MyClass_myInstanceAttribute - MyClass().»myInstanceAttribute«; - - // $TEST$ references MyClass_myInstanceMethod - MyClass().»myInstanceMethod1«(); -} diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/static attributes/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/static attributes/main.sdstest deleted file mode 100644 index 0c9d77c5..00000000 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/static attributes/main.sdstest +++ /dev/null @@ -1,85 +0,0 @@ -package tests.scoping.memberAccesses.toClassMembers.staticAttributes - -class MyClass() { - // $TEST$ target myStaticAttribute - static attr »myStaticAttribute«: Int - - - // $TEST$ target redeclaredAsInstanceAttribute - static attr »redeclaredAsInstanceAttribute«: Int - attr redeclaredAsInstanceAttribute: Int - - // $TEST$ target redeclaredAsStaticAttribute - static attr »redeclaredAsStaticAttribute«: Int - static attr redeclaredAsStaticAttribute: Int - - // $TEST$ target redeclaredAsNestedClass - static attr »redeclaredAsNestedClass«: Int - class redeclaredAsNestedClass - - // $TEST$ target redeclaredAsNestedEnum - static attr »redeclaredAsNestedEnum«: Int - enum redeclaredAsNestedEnum - - // $TEST$ target redeclaredAsInstanceMethod - static attr »redeclaredAsInstanceMethod«: Int - fun redeclaredAsInstanceMethod() - - // $TEST$ target redeclaredAsStaticMethod - static attr »redeclaredAsStaticMethod«: Int - static fun redeclaredAsStaticMethod() - - - // $TEST$ target declaredPreviouslyAsInstanceAttribute - attr declaredPreviouslyAsInstanceAttribute: Int - static attr »declaredPreviouslyAsInstanceAttribute«: Int - - // $TEST$ target declaredPreviouslyAsInstanceMethod - fun declaredPreviouslyAsInstanceMethod() - static attr »declaredPreviouslyAsInstanceMethod«: Int -} - -class AnotherClass - -pipeline myPipeline { - // $TEST$ references myStaticAttribute - MyClass.»myStaticAttribute«; - - - // $TEST$ references redeclaredAsInstanceAttribute - MyClass.»redeclaredAsInstanceAttribute«; - - // $TEST$ references redeclaredAsStaticAttribute - MyClass.»redeclaredAsStaticAttribute«; - - // $TEST$ references redeclaredAsNestedClass - MyClass.»redeclaredAsNestedClass«; - - // $TEST$ references redeclaredAsNestedEnum - MyClass.»redeclaredAsNestedEnum«; - - // $TEST$ references redeclaredAsInstanceMethod - MyClass.»redeclaredAsInstanceMethod«; - - // $TEST$ references redeclaredAsStaticMethod - MyClass.»redeclaredAsStaticMethod«; - - // $TEST$ references declaredPreviouslyAsInstanceAttribute - MyClass.»declaredPreviouslyAsInstanceAttribute«; - - // $TEST$ references declaredPreviouslyAsInstanceMethod - MyClass.»declaredPreviouslyAsInstanceMethod«; - - - // $TEST$ unresolved - MyClass().»myStaticAttribute«; - - // $TEST$ unresolved - AnotherClass.»myStaticAttribute«; - - // $TEST$ unresolved - unresolved.»myStaticAttribute«; - - // $TEST$ unresolved - MyClass.»unresolved«; -} diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/static methods/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/static methods/main.sdstest deleted file mode 100644 index 7467d7dc..00000000 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to class members/static methods/main.sdstest +++ /dev/null @@ -1,89 +0,0 @@ -package tests.scoping.memberAccesses.toClassMembers.staticMethods - -class MyClass { - // $TEST$ target myStaticMethod - static fun »myStaticMethod«() - - - // $TEST$ target redeclaredAsInstanceAttribute - static fun »redeclaredAsInstanceAttribute«() - attr redeclaredAsInstanceAttribute: Int - - // $TEST$ target redeclaredAsStaticAttribute - static fun »redeclaredAsStaticAttribute«() - static attr redeclaredAsStaticAttribute: Int - - // $TEST$ target redeclaredAsNestedClass - static fun »redeclaredAsNestedClass«() - class redeclaredAsNestedClass - - // $TEST$ target redeclaredAsNestedEnum - static fun »redeclaredAsNestedEnum«() - enum redeclaredAsNestedEnum - - // $TEST$ target redeclaredAsInstanceMethod - static fun »redeclaredAsInstanceMethod«() - fun redeclaredAsInstanceMethod() - - // $TEST$ target redeclaredAsStaticMethod - static fun »redeclaredAsStaticMethod«() - static fun redeclaredAsStaticMethod() - - - // $TEST$ target declaredPreviouslyAsInstanceAttribute - attr declaredPreviouslyAsInstanceAttribute: Int - static fun »declaredPreviouslyAsInstanceAttribute«() - - // $TEST$ target declaredPreviouslyAsInstanceMethod - fun declaredPreviouslyAsInstanceMethod() - static fun »declaredPreviouslyAsInstanceMethod«() -} - -class AnotherClass -fun anotherFunction() - -pipeline myPipeline { - // $TEST$ references myStaticMethod - MyClass.»myStaticMethod«; - - - // $TEST$ references redeclaredAsInstanceAttribute - MyClass.»redeclaredAsInstanceAttribute«; - - // $TEST$ references redeclaredAsStaticAttribute - MyClass.»redeclaredAsStaticAttribute«; - - // $TEST$ references redeclaredAsNestedClass - MyClass.»redeclaredAsNestedClass«; - - // $TEST$ references redeclaredAsNestedEnum - MyClass.»redeclaredAsNestedEnum«; - - // $TEST$ references redeclaredAsInstanceMethod - MyClass.»redeclaredAsInstanceMethod«; - - // $TEST$ references redeclaredAsStaticMethod - MyClass.»redeclaredAsStaticMethod«; - - // $TEST$ references declaredPreviouslyAsInstanceAttribute - MyClass.»declaredPreviouslyAsInstanceAttribute«; - - // $TEST$ references declaredPreviouslyAsInstanceMethod - MyClass.»declaredPreviouslyAsInstanceMethod«; - - - // $TEST$ unresolved - MyClass().»myStaticMethod«; - - // $TEST$ unresolved - MyClass.»anotherFunction«; - - // $TEST$ unresolved - AnotherClass.»myStaticMethod«; - - // $TEST$ unresolved - unresolved.»myStaticMethod«; - - // $TEST$ unresolved - MyClass.»unresolved«; -} diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to enum variants/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to enum variants/main.sdstest deleted file mode 100644 index 3f913c06..00000000 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to enum variants/main.sdstest +++ /dev/null @@ -1,33 +0,0 @@ -package tests.scoping.memberAccesses.toEnumVariants - -enum MyEnum { - // $TEST$ target myEnumVariant - »MyEnumVariant« - - // $TEST$ target redeclaredEnumVariant - »RedeclaredEnumVariant« - RedeclaredEnumVariant -} - -enum AnotherEnum - -pipeline myPipeline { - // $TEST$ references myEnumVariant - MyEnum.»MyEnumVariant«; - - // $TEST$ references redeclaredEnumVariant - MyEnum.»RedeclaredEnumVariant«; - - - // $TEST$ unresolved - AnotherEnum().»MyEnumVariant«; - - // $TEST$ unresolved - AnotherEnum.»MyEnumVariant«; - - // $TEST$ unresolved - unresolved.»MyEnumVariant«; - - // $TEST$ unresolved - MyEnum.»unresolved«; -} diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to parameter of enum variants/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to parameter of enum variants/main.sdstest deleted file mode 100644 index 2ba689a1..00000000 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to parameter of enum variants/main.sdstest +++ /dev/null @@ -1,45 +0,0 @@ -package tests.scoping.memberAccesses.toParametersOfEnumVariants - -enum MyEnum { - MyEnumVariant( - // $TEST$ target param - »param«: Int, - - // $TEST$ target redeclared - »redeclared«: Int, - redeclared: Int, - ) - - MyOtherEnumVariant -} - -enum MyOtherEnum { - MyEnumVariant -} - -pipeline myPipeline { - // $TEST$ references param - MyEnum.MyEnumVariant().»param«; - - // $TEST$ references redeclared - MyEnum.MyEnumVariant().»redeclared«; - - - // $TEST$ unresolved - MyOtherEnum.MyEnumVariant.»param«; - - // $TEST$ unresolved - MyEnum.MyOtherEnumVariant().»param«; - - // $TEST$ unresolved - MyOtherEnum.MyEnumVariant().»param«; - - // $TEST$ unresolved - MyEnum.MyEnumVariant().»unresolved«; - - // $TEST$ unresolved - MyEnum.unresolved().»param«; - - // $TEST$ unresolved - unresolved.MyEnumVariant().»param«; -} diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/call with nullable receiver/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/call with nullable receiver/main.sdstest deleted file mode 100644 index 85517938..00000000 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/call with nullable receiver/main.sdstest +++ /dev/null @@ -1,33 +0,0 @@ -package tests.scoping.memberAccesses.toResults.callWithNullableReceiver - -class MyClass { - // $TEST$ target functionWithOneResult_singleResult - fun functionWithOneResult() -> »singleResult«: Int - - // $TEST$ target functionWithTwoResults_result1 - fun functionWithTwoResults() -> (»result1«: Int, result2: Int) -} - -segment mySegment( - myClassOrNull: MyClass? -) { - // $TEST$ references functionWithOneResult_singleResult - myClassOrNull?.functionWithOneResult().»singleResult«; - - // $TEST$ references functionWithTwoResults_result1 - myClassOrNull?.functionWithTwoResults().»result1«; - - - // $TEST$ references functionWithOneResult_singleResult - myClassOrNull?.functionWithOneResult?().»singleResult«; - - // $TEST$ references functionWithTwoResults_result1 - myClassOrNull?.functionWithTwoResults?().»result1«; - - - // $TEST$ references functionWithOneResult_singleResult - myClassOrNull?.functionWithOneResult?()?.»singleResult«; - - // $TEST$ references functionWithTwoResults_result1 - myClassOrNull?.functionWithTwoResults?()?.»result1«; -} diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of block lambdas (matching member)/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of block lambdas (matching member)/main.sdstest deleted file mode 100644 index b197f34b..00000000 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of block lambdas (matching member)/main.sdstest +++ /dev/null @@ -1,27 +0,0 @@ -package tests.scoping.memberAccesses.toResults.ofBlockLambdas.matchingMember - -class MyClass() { - // $TEST$ target MyClass_result - attr »result«: Int -} - -enum MyEnum { - // $TEST$ target MyEnum_result - MyEnumVariant(»result«: Int) -} - -pipeline myPipeline { - val f1 = () { - yield result = MyClass(); - }; - - val f2 = () { - yield result = MyEnum.MyEnumVariant(0); - }; - - // $TEST$ references MyClass_result - f1().»result«; - - // $TEST$ references MyEnum_result - f2().»result«; -} diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of block lambdas/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of block lambdas/main.sdstest deleted file mode 100644 index 208ee9b3..00000000 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of block lambdas/main.sdstest +++ /dev/null @@ -1,20 +0,0 @@ -package tests.scoping.memberAccesses.toResults.ofBlockLambdas - -pipeline myPipeline { - val lambdaWithOneResult = () { - // $TEST$ target lambdaWithOneResult_singleResult - yield »singleResult« = 1; - }; - val lambdaWithTwoResults = () { - // $TEST$ target lambdaWithTwoResults_result1 - yield »result1« = 1; - yield result1 = 1; - yield result2 = 1; - }; - - // $TEST$ references lambdaWithOneResult_singleResult - lambdaWithOneResult().»singleResult«; - - // $TEST$ references lambdaWithTwoResults_result1 - lambdaWithTwoResults().»result1«; -} diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of callable types (matching member)/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of callable types (matching member)/main.sdstest deleted file mode 100644 index a7cc1c82..00000000 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of callable types (matching member)/main.sdstest +++ /dev/null @@ -1,23 +0,0 @@ -package tests.scoping.memberAccesses.toResults.ofCallableTypes.matchingMember - -class MyClass() { - // $TEST$ target MyClass_result - attr »result«: Int -} - -enum MyEnum { - // $TEST$ target MyEnum_result - MyEnumVariant(»result«: Int) -} - -segment mySegment( - f1: () -> result: MyClass, - f2: () -> result: MyEnum.MyEnumVariant, -) { - - // $TEST$ references MyClass_result - f1().»result«; - - // $TEST$ references MyEnum_result - f2().»result«; -} diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of callable types/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of callable types/main.sdstest deleted file mode 100644 index 1e4d3c66..00000000 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of callable types/main.sdstest +++ /dev/null @@ -1,15 +0,0 @@ -package tests.scoping.memberAccesses.toResults.ofCallableTypes - -segment mySegment( - // $TEST$ target callableWithOneResult_singleResult - callableWithOneResult: () -> »singleResult«: Int, - - // $TEST$ target callableWithTwoResults_result1 - callableWithTwoResults: () -> (»result1«: Int, result2: Int), -) { - // $TEST$ references callableWithOneResult_singleResult - callableWithOneResult().»singleResult«; - - // $TEST$ references callableWithTwoResults_result1 - callableWithTwoResults().»result1«; -} diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of functions (matching member)/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of functions (matching member)/main.sdstest deleted file mode 100644 index 263e0eec..00000000 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of functions (matching member)/main.sdstest +++ /dev/null @@ -1,22 +0,0 @@ -package tests.scoping.memberAccesses.toResults.ofFunctions.matchingMember - -class MyClass() { - // $TEST$ target MyClass_result - attr »result«: Int -} - -enum MyEnum { - // $TEST$ target MyEnum_result - MyEnumVariant(»result«: Int) -} - -fun f1() -> result: MyClass -fun f2() -> result: MyEnum.MyEnumVariant - -pipeline myPipeline { - // $TEST$ references MyClass_result - f1().»result«; - - // $TEST$ references MyEnum_result - f2().»result«; -} diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of functions/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of functions/main.sdstest deleted file mode 100644 index eeba6f3f..00000000 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of functions/main.sdstest +++ /dev/null @@ -1,15 +0,0 @@ -package tests.scoping.memberAccesses.toResults.ofFunctions - -// $TEST$ target functionWithOneResult_singleResult -fun functionWithOneResult() -> »singleResult«: Int - -// $TEST$ target functionWithTwoResults_result1 -fun functionWithTwoResults() -> (»result1«: Int, result2: Int) - -pipeline myPipeline { - // $TEST$ references functionWithOneResult_singleResult - functionWithOneResult().»singleResult«; - - // $TEST$ references functionWithTwoResults_result1 - functionWithTwoResults().»result1«; -} diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of segments (matching member)/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of segments (matching member)/main.sdstest deleted file mode 100644 index 79463aae..00000000 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of segments (matching member)/main.sdstest +++ /dev/null @@ -1,22 +0,0 @@ -package tests.scoping.memberAccesses.toResults.ofSegments.matchingMember - -class MyClass() { - // $TEST$ target MyClass_result - attr »result«: Int -} - -enum MyEnum { - // $TEST$ target MyEnum_result - MyEnumVariant(»result«: Int) -} - -segment s1() -> result: MyClass {} -segment s2() -> result: MyEnum.MyEnumVariant {} - -pipeline myPipeline { - // $TEST$ references MyClass_result - s1().»result«; - - // $TEST$ references MyEnum_result - s2().»result«; -} diff --git a/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of segments/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of segments/main.sdstest deleted file mode 100644 index ca1dbcaa..00000000 --- a/packages/ttsl-lang/tests/resources/scoping/member accesses/to results/of segments/main.sdstest +++ /dev/null @@ -1,15 +0,0 @@ -package tests.scoping.memberAccesses.toResults.ofSegments - -// $TEST$ target segmentWithOneResult_singleResult -segment segmentWithOneResult() -> »singleResult«: Int {} - -// $TEST$ target segmentWithTwoResults_result1 -segment segmentWithTwoResults() -> (»result1«: Int, result2: Int) {} - -pipeline myPipeline { - // $TEST$ references segmentWithOneResult_singleResult - segmentWithOneResult().»singleResult«; - - // $TEST$ references segmentWithTwoResults_result1 - segmentWithTwoResults().»result1«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/on class with type parameters/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/on class with type parameters/main.sdstest deleted file mode 100644 index 219a7319..00000000 --- a/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/on class with type parameters/main.sdstest +++ /dev/null @@ -1,76 +0,0 @@ -package tests.typing.expressions.memberAccesses.onClassWithTypeParameters - -class C { - attr nonNullableMember: T - attr nullableMember: T? - @Pure fun method() -> r: T -} - -class D sub C - -@Pure fun nullableC() -> result: C? -@Pure fun nullableD() -> result: D? - -// Accessing own members -segment mySegment1(p: C) { - // $TEST$ serialization Int - »p.nonNullableMember«; - // $TEST$ serialization Int? - »p.nullableMember«; - // $TEST$ serialization () -> (r: Int) - »p.method«; - - // $TEST$ serialization Int - »p?.nonNullableMember«; - // $TEST$ serialization Int? - »p?.nullableMember«; - // $TEST$ serialization () -> (r: Int) - »p?.method«; - - - // $TEST$ serialization Int - »nullableC().nonNullableMember«; - // $TEST$ serialization Int? - »nullableC().nullableMember«; - // $TEST$ serialization () -> (r: Int) - »nullableC().method«; - - // $TEST$ serialization Int? - »nullableC()?.nonNullableMember«; - // $TEST$ serialization Int? - »nullableC()?.nullableMember«; - // $TEST$ serialization union<() -> (r: Int), Nothing?> - »nullableC()?.method«; -} - -// Accessing inherited members -segment mySegment2(p: D) { - // $TEST$ serialization Int - »p.nonNullableMember«; - // $TEST$ serialization Int? - »p.nullableMember«; - // $TEST$ serialization () -> (r: Int) - »p.method«; - - // $TEST$ serialization Int - »p?.nonNullableMember«; - // $TEST$ serialization Int? - »p?.nullableMember«; - // $TEST$ serialization () -> (r: Int) - »p?.method«; - - - // $TEST$ serialization Int - »nullableD().nonNullableMember«; - // $TEST$ serialization Int? - »nullableD().nullableMember«; - // $TEST$ serialization () -> (r: Int) - »nullableD().method«; - - // $TEST$ serialization Int? - »nullableD()?.nonNullableMember«; - // $TEST$ serialization Int? - »nullableD()?.nullableMember«; - // $TEST$ serialization union<() -> (r: Int), Nothing?> - »nullableD()?.method«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/to enum variants/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/to enum variants/main.sdstest deleted file mode 100644 index d970d712..00000000 --- a/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/to enum variants/main.sdstest +++ /dev/null @@ -1,28 +0,0 @@ -package tests.typing.expressions.references.toEnumVariants - -enum MyEnum { - MyEnumVariantWithoutParameterList - MyEnumVariantWithoutParameters() - MyEnumVariantWithParameters(p: Int) -} - -pipeline myPipeline { - // $TEST$ serialization MyEnum.MyEnumVariantWithoutParameterList - »MyEnum.MyEnumVariantWithoutParameterList«; - - // $TEST$ serialization MyEnum.MyEnumVariantWithoutParameters - »MyEnum.MyEnumVariantWithoutParameters«; - - // $TEST$ serialization $type - »MyEnum.MyEnumVariantWithParameters«; - - - // $TEST$ serialization MyEnum.MyEnumVariantWithoutParameterList - »MyEnum?.MyEnumVariantWithoutParameterList«; - - // $TEST$ serialization MyEnum.MyEnumVariantWithoutParameters - »MyEnum?.MyEnumVariantWithoutParameters«; - - // $TEST$ serialization $type - »MyEnum?.MyEnumVariantWithParameters«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/to nested classes/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/to nested classes/main.sdstest deleted file mode 100644 index 9c9ae1ed..00000000 --- a/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/to nested classes/main.sdstest +++ /dev/null @@ -1,13 +0,0 @@ -package tests.typing.expressions.memberAccesses.toNestedClasses - -class MyClass { - class MyNestedClass -} - -pipeline myPipeline { - // $TEST$ serialization $type - »MyClass.MyNestedClass«; - - // $TEST$ serialization $type - »MyClass?.MyNestedClass«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/to nested enums/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/to nested enums/main.sdstest deleted file mode 100644 index 66e3c74b..00000000 --- a/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/to nested enums/main.sdstest +++ /dev/null @@ -1,13 +0,0 @@ -package tests.typing.expressions.memberAccesses.toNestedEnums - -class MyClass { - enum MyNestedEnum -} - -pipeline myPipeline { - // $TEST$ serialization $type - »MyClass.MyNestedEnum«; - - // $TEST$ serialization $type - »MyClass?.MyNestedEnum«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/to other/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/to other/main.sdstest deleted file mode 100644 index f77c4900..00000000 --- a/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/to other/main.sdstest +++ /dev/null @@ -1,45 +0,0 @@ -package tests.typing.expressions.memberAccesses.toOther - -class C() { - // $TEST$ equivalence_class nonNullableMember - attr »nonNullableMember«: Int - - // $TEST$ equivalence_class nullableMember - attr »nullableMember«: Any? - - // $TEST$ equivalence_class method - @Pure fun »method«() -> r: Int -} - -fun nullableC() -> result: C? - -pipeline myPipeline { - // $TEST$ equivalence_class nonNullableMember - »C().nonNullableMember«; - // $TEST$ equivalence_class nullableMember - »C().nullableMember«; - // $TEST$ equivalence_class method - »C().method«; - - // $TEST$ equivalence_class nonNullableMember - »C()?.nonNullableMember«; - // $TEST$ equivalence_class nullableMember - »C()?.nullableMember«; - // $TEST$ equivalence_class method - »C()?.method«; - - - // $TEST$ equivalence_class nonNullableMember - »nullableC().nonNullableMember«; - // $TEST$ equivalence_class nullableMember - »nullableC().nullableMember«; - // $TEST$ equivalence_class method - »nullableC().method«; - - // $TEST$ serialization Int? - »nullableC()?.nonNullableMember«; - // $TEST$ equivalence_class nullableMember - »nullableC()?.nullableMember«; - // $TEST$ serialization union<() -> (r: Int), Nothing?> - »nullableC()?.method«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/unresolved/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/unresolved/main.sdstest deleted file mode 100644 index 9cef6afd..00000000 --- a/packages/ttsl-lang/tests/resources/typing/expressions/member accesses/unresolved/main.sdstest +++ /dev/null @@ -1,11 +0,0 @@ -package tests.typing.expressions.memberAccesses.unresolved - -class C - -pipeline myPipeline { - // $TEST$ serialization $unknown - »C.unresolved«; - - // $TEST$ serialization $unknown - »C?.unresolved«; -} diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/chained expression/missing null safety/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/chained expression/missing null safety/main.sdstest index 8f3b9ca3..2bd87988 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/chained expression/missing null safety/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/chained expression/missing null safety/main.sdstest @@ -107,54 +107,3 @@ class IndexedAccess?, NonNullable sub List>( // $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." p4: Any? = »nonNullable?[0]«, ) - -segment memberAccess( - myClass: MyClass, - myClassOrNull: MyClass?, -) { - // $TEST$ no error "The receiver can be null so a null-safe member access must be used." - »1.a«; - - // $TEST$ error "The receiver can be null so a null-safe member access must be used." - »null.a«; - - // $TEST$ no error "The receiver can be null so a null-safe member access must be used." - »myClass.a«; - - // $TEST$ error "The receiver can be null so a null-safe member access must be used." - »myClassOrNull.a«; - - // $TEST$ no error "The receiver can be null so a null-safe member access must be used." - »unresolved.a«; - - - // $TEST$ no error "The receiver can be null so a null-safe member access must be used." - »1?.a«; - - // $TEST$ no error "The receiver can be null so a null-safe member access must be used." - »null?.a«; - - // $TEST$ no error "The receiver can be null so a null-safe member access must be used." - »myClass?.a«; - - // $TEST$ no error "The receiver can be null so a null-safe member access must be used." - »myClassOrNull?.a«; - - // $TEST$ no error "The receiver can be null so a null-safe member access must be used." - »unresolved?.a«; -} - -class MemberAccess( - nullable: Nullable, - nonNullable: NonNullable, - - // $TEST$ error "The receiver can be null so a null-safe member access must be used." - p1: Any? = »nullable.a«, - // $TEST$ no error "The receiver can be null so a null-safe member access must be used." - p2: Any? = »nonNullable.a«, - - // $TEST$ no error "The receiver can be null so a null-safe member access must be used." - p3: Any? = »nullable?.a«, - // $TEST$ no error "The receiver can be null so a null-safe member access must be used." - p4: Any? = »nonNullable?.a«, -) diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/member accesses/enum variant must be instantiated/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/member accesses/enum variant must be instantiated/main.sdstest deleted file mode 100644 index 48e97648..00000000 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/member accesses/enum variant must be instantiated/main.sdstest +++ /dev/null @@ -1,50 +0,0 @@ -package tests.validation.other.expressions.memberAccesses.enumVariantMustBeInstantiated - -enum MyEnum { - EnumVariantWithoutParameterList - EnumVariantWithEmptyParameterList() - EnumVariantWithoutRequiredParameters(a: Int = 0) - EnumVariantWithRequiredParameters(b: Int) -} - -pipeline test { - // $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." - MyEnum.»EnumVariantWithoutParameterList«; - // $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." - MyEnum.»EnumVariantWithoutParameterList«(); - // $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." - val alias1 = MyEnum.EnumVariantWithoutParameterList; - »alias1«; - - // $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." - MyEnum.»EnumVariantWithEmptyParameterList«; - // $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." - MyEnum.»EnumVariantWithEmptyParameterList«(); - // $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." - val alias2 = MyEnum.EnumVariantWithEmptyParameterList; - »alias2«; - - // $TEST$ error "The enum variant 'EnumVariantWithoutRequiredParameters' has parameters, so an argument list must be added." - MyEnum.»EnumVariantWithoutRequiredParameters«; - // $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." - MyEnum.»EnumVariantWithoutRequiredParameters«(); - // $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." - val alias3 = MyEnum.EnumVariantWithoutRequiredParameters; - »alias3«; - - // $TEST$ error "The enum variant 'EnumVariantWithRequiredParameters' has parameters, so an argument list must be added." - MyEnum.»EnumVariantWithRequiredParameters«; - // $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." - MyEnum.»EnumVariantWithRequiredParameters«(); - // $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." - val alias4 = MyEnum.EnumVariantWithRequiredParameters; - »alias4«; - - // $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." - MyEnum.»Unresolved«; - // $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." - MyEnum.»Unresolved«(); - // $TEST$ no error r"The enum variant '\w*' has parameters, so an argument list must be added\." - val alias5 = MyEnum.Unresolved; - »alias5«; -} diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary null safety/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary null safety/main.sdstest index a2bf48ff..a05bdf54 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary null safety/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary null safety/main.sdstest @@ -107,54 +107,3 @@ class IndexedAccess?, NonNullable sub List>( // $TEST$ info "The receiver is never null, so null-safety is unnecessary." p4: Any? = »nonNullable?[0]«, ) - -segment memberAccess( - myClass: MyClass, - myClassOrNull: MyClass?, -) { - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." - »1.a«; - - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." - »null.a«; - - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." - »myClass.a«; - - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." - »myClassOrNull.a«; - - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." - »unresolved.a«; - - - // $TEST$ info "The receiver is never null, so null-safety is unnecessary." - »1?.a«; - - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." - »null?.a«; - - // $TEST$ info "The receiver is never null, so null-safety is unnecessary." - »myClass?.a«; - - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." - »myClassOrNull?.a«; - - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." - »unresolved?.a«; -} - -class MemberAccess( - nullable: Nullable, - nonNullable: NonNullable, - - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." - p1: Any? = »nullable.a«, - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." - p2: Any? = »nonNullable.a«, - - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." - p3: Any? = »nullable?.a«, - // $TEST$ info "The receiver is never null, so null-safety is unnecessary." - p4: Any? = »nonNullable?.a«, -) From 59530adc0ecb0b64714ff7ff0dd39e1d90615b66 Mon Sep 17 00:00:00 2001 From: methr0 Date: Tue, 30 Jul 2024 14:24:45 +0200 Subject: [PATCH 136/183] remove unneccessary imports --- .../ttsl-lang/src/language/scoping/ttsl-scope-computation.ts | 4 +--- .../ttsl-lang/src/language/scoping/ttsl-scope-provider.ts | 5 ----- 2 files changed, 1 insertion(+), 8 deletions(-) diff --git a/packages/ttsl-lang/src/language/scoping/ttsl-scope-computation.ts b/packages/ttsl-lang/src/language/scoping/ttsl-scope-computation.ts index 8fbe39dd..549bcd42 100644 --- a/packages/ttsl-lang/src/language/scoping/ttsl-scope-computation.ts +++ b/packages/ttsl-lang/src/language/scoping/ttsl-scope-computation.ts @@ -10,10 +10,7 @@ import { isTslDeclaration, isTslFunction, isTslModule, - isTslParameter, - isTslParameterList, TslFunction, - TslParameter, } from '../generated/ast.js'; export class TTSLScopeComputation extends DefaultScopeComputation { @@ -50,6 +47,7 @@ export class TTSLScopeComputation extends DefaultScopeComputation { this.addToScopesIfKeyIsDefined(scopes, node.parameterList, description); this.addToScopesIfKeyIsDefined(scopes, node.body, description); + this.addToScopesIfKeyIsDefined(scopes, node.result, description); const containingDeclaration = AstUtils.getContainerOfType(node.$container, isTslDeclaration); if (isTslModule(containingDeclaration)) { diff --git a/packages/ttsl-lang/src/language/scoping/ttsl-scope-provider.ts b/packages/ttsl-lang/src/language/scoping/ttsl-scope-provider.ts index acaff1d7..5bce4e24 100644 --- a/packages/ttsl-lang/src/language/scoping/ttsl-scope-provider.ts +++ b/packages/ttsl-lang/src/language/scoping/ttsl-scope-provider.ts @@ -14,9 +14,7 @@ import { isTslArgument, isTslAssignment, isTslBlock, - isTslCall, isTslCallable, - isTslFunction, isTslImportedDeclaration, isTslModule, isTslNamedTypeDeclaration, @@ -42,7 +40,6 @@ import { getImports, getPackageName, getParameters, - getResults, getStatements, } from '../helpers/nodeProperties.js'; import { TTSLNodeMapper } from '../helpers/ttsl-node-mapper.js'; @@ -54,7 +51,6 @@ export class TTSLScopeProvider extends DefaultScopeProvider { private readonly astReflection: AstReflection; private readonly nodeMapper: TTSLNodeMapper; private readonly packageManager: TTSLPackageManager; - private readonly typeComputer: TTSLTypeComputer; private readonly coreDeclarationCache: WorkspaceCache; @@ -64,7 +60,6 @@ export class TTSLScopeProvider extends DefaultScopeProvider { this.astReflection = services.shared.AstReflection; this.nodeMapper = services.helpers.NodeMapper; this.packageManager = services.workspace.PackageManager; - this.typeComputer = services.types.TypeComputer; this.coreDeclarationCache = new WorkspaceCache(services.shared); } From acc0f6f1ebe817536bb5c0fc20c94c564c4e9f4b Mon Sep 17 00:00:00 2001 From: methr0 Date: Thu, 1 Aug 2024 15:14:35 +0200 Subject: [PATCH 137/183] remove uneccessary validations --- packages/ttsl-lang/src/language/validation/names.ts | 5 ++++- .../validation/other/declarations/placeholders.ts | 10 ---------- 2 files changed, 4 insertions(+), 11 deletions(-) diff --git a/packages/ttsl-lang/src/language/validation/names.ts b/packages/ttsl-lang/src/language/validation/names.ts index 49648f4f..4b47a14b 100644 --- a/packages/ttsl-lang/src/language/validation/names.ts +++ b/packages/ttsl-lang/src/language/validation/names.ts @@ -109,7 +109,10 @@ export const nameShouldHaveCorrectCasing = (services: TTSLServices) => { case TslPlaceholder: return nameShouldBeLowerCamelCase(node, 'placeholders', accept); case TslResult: - return nameShouldBeLowerCamelCase(node, 'results', accept); + if(node.name){ + return nameShouldBeLowerCamelCase(node, 'results', accept); + } + } /* c8 ignore next */ }; diff --git a/packages/ttsl-lang/src/language/validation/other/declarations/placeholders.ts b/packages/ttsl-lang/src/language/validation/other/declarations/placeholders.ts index e84ecdb2..f1be2499 100644 --- a/packages/ttsl-lang/src/language/validation/other/declarations/placeholders.ts +++ b/packages/ttsl-lang/src/language/validation/other/declarations/placeholders.ts @@ -13,7 +13,6 @@ import { getStatements } from '../../../helpers/nodeProperties.js'; import { DiagnosticTag } from 'vscode-languageserver'; import { last } from '../../../../helpers/collections.js'; -export const CODE_PLACEHOLDER_ALIAS = 'placeholder/alias'; export const CODE_PLACEHOLDER_UNUSED = 'placeholder/unused'; export const placeholdersMustNotBeAnAlias = (node: TslPlaceholder, accept: ValidationAcceptor): void => { @@ -26,15 +25,6 @@ export const placeholdersMustNotBeAnAlias = (node: TslPlaceholder, accept: Valid if (!isTslReference(rhs)) { return; } - - const referenceTarget = rhs.target.ref; - if (isTslParameter(referenceTarget) || isTslPlaceholder(referenceTarget)) { - accept('error', 'Aliases are not allowed to provide a cleaner graphical view.', { - node, - property: 'name', - code: CODE_PLACEHOLDER_ALIAS, - }); - } }; export const placeholderShouldBeUsed = From adba984ea4919cff8a2ac595945937dd7674c695 Mon Sep 17 00:00:00 2001 From: methr0 Date: Thu, 1 Aug 2024 15:15:47 +0200 Subject: [PATCH 138/183] add type compution for literals --- .../src/language/typing/ttsl-type-computer.ts | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/packages/ttsl-lang/src/language/typing/ttsl-type-computer.ts b/packages/ttsl-lang/src/language/typing/ttsl-type-computer.ts index 3c5b2ec2..ba700b02 100644 --- a/packages/ttsl-lang/src/language/typing/ttsl-type-computer.ts +++ b/packages/ttsl-lang/src/language/typing/ttsl-type-computer.ts @@ -33,6 +33,10 @@ import { isTslFloatType, isTslStringType, isTslBooleanType, + isTslInt, + isTslFloat, + isTslBoolean, + isTslString, } from '../generated/ast.js'; import { TTSLServices } from '../ttsl-module.js'; import { @@ -161,6 +165,14 @@ export class TTSLTypeComputer { return new DictionaryType([keyType, valueType], false); } else if (isTslTemplateString(node)) { return new StringType(false); + } else if(isTslInt(node)){ + return new IntType(false); + } else if(isTslFloat(node)){ + return new FloatType(false); + } else if(isTslBoolean(node)){ + return new BooleanType(false); + } else if(isTslString(node) || isTslTemplateString(node)){ + return new StringType(false); } // Recursive cases From ba9da659075b062146e8cf26c2d7738ef9f3a628 Mon Sep 17 00:00:00 2001 From: methr0 Date: Thu, 1 Aug 2024 15:20:43 +0200 Subject: [PATCH 139/183] fix grammar bugs --- .../src/language/grammar/ttsl.langium | 20 +++++++++++-------- 1 file changed, 12 insertions(+), 8 deletions(-) diff --git a/packages/ttsl-lang/src/language/grammar/ttsl.langium b/packages/ttsl-lang/src/language/grammar/ttsl.langium index 0daa3ef5..d8b2bca8 100644 --- a/packages/ttsl-lang/src/language/grammar/ttsl.langium +++ b/packages/ttsl-lang/src/language/grammar/ttsl.langium @@ -18,6 +18,7 @@ interface TslDeclaration extends TslObject { interface TslLocalVariable extends TslDeclaration { groupedBy?: TslGroupedBy value?: TslExpression + ^type?: TslType } // ----------------------------------------------------------------------------- @@ -197,7 +198,6 @@ TslParameterList returns TslParameterList: interface TslParameter extends TslLocalVariable { isConstant: boolean - ^type: TslType defaultValue?: TslExpression } @@ -212,17 +212,13 @@ interface TslResultList extends TslObject { results: TslResult[] } -TslResultList returns TslResultList: - {TslResultList} ':' results+=TslResult - | {TslResultList} ':' '(' (results+=TslResult (',' results+=TslResult)* ','? )? ')' -; interface TslResult extends TslDeclaration { ^type?: TslType } TslResult returns TslResult: - (name=ID)? + (name=ID )? ':' ^type=TslType ; @@ -250,7 +246,6 @@ TslFunctionBlock returns TslFunctionBlock: {TslFunctionBlock} '{' ( timespanStatement+=TslTimespanStatement | statements+=TslStatement)* - ('return' returnValue=TslExpression)? '}' ; @@ -259,6 +254,7 @@ TslStatement returns TslStatement: | TslExpressionStatement | TslConditionalStatement | TslLoop + | TslReturnStatement ; interface TslAssignment extends TslStatement { @@ -283,7 +279,7 @@ interface TslAssignee extends TslObject {} interface TslPlaceholder extends TslAssignee, TslLocalVariable {} TslAssignee returns TslAssignee: - {TslPlaceholder} 'var' name=ID (groupedBy=TslGroupedBy)? + {TslPlaceholder} 'var' name=ID (':' ^type=TslType)? (groupedBy=TslGroupedBy)? ; interface TslExpressionStatement extends TslStatement { @@ -346,6 +342,14 @@ TslForeachLoop returns TslForeachLoop: block=TslBlock ; +interface TslReturnStatement extends TslStatement{ + result: TslExpression +} + +TslReturnStatement returns TslReturnStatement: + 'return' result=TslExpression ';' +; + // ----------------------------------------------------------------------------- // Expressions // ----------------------------------------------------------------------------- From dddde3303bac66f1157e43108b0a8d22956bc7e0 Mon Sep 17 00:00:00 2001 From: methr0 Date: Thu, 1 Aug 2024 15:21:07 +0200 Subject: [PATCH 140/183] fix inlay hint for placeholder --- .../src/language/lsp/ttsl-inlay-hint-provider.ts | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/packages/ttsl-lang/src/language/lsp/ttsl-inlay-hint-provider.ts b/packages/ttsl-lang/src/language/lsp/ttsl-inlay-hint-provider.ts index 414590e0..a030e017 100644 --- a/packages/ttsl-lang/src/language/lsp/ttsl-inlay-hint-provider.ts +++ b/packages/ttsl-lang/src/language/lsp/ttsl-inlay-hint-provider.ts @@ -42,13 +42,15 @@ export class TTSLInlayHintProvider extends AbstractInlayHintProvider { } else if (isTslPlaceholder(node)) { const type = this.typeComputer.computeType(node); let tooltip: MarkupContent | undefined = undefined; + if(!node.type){ + acceptor({ + position: cstNode.range.end, + label: `: ${type}`, + kind: InlayHintKind.Type, + tooltip, + }); + } - acceptor({ - position: cstNode.range.end, - label: `: ${type}`, - kind: InlayHintKind.Type, - tooltip, - }); } } } From e6023d48c4512832bfbc5fd58d8439d717453df5 Mon Sep 17 00:00:00 2001 From: methr0 Date: Thu, 1 Aug 2024 15:22:44 +0200 Subject: [PATCH 141/183] fix autocompletion --- packages/ttsl-vscode/snippets/ttsl.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/ttsl-vscode/snippets/ttsl.json b/packages/ttsl-vscode/snippets/ttsl.json index d9ee72a2..6e27696f 100644 --- a/packages/ttsl-vscode/snippets/ttsl.json +++ b/packages/ttsl-vscode/snippets/ttsl.json @@ -26,7 +26,7 @@ }, "Data": { "prefix": ["data"], - "body": ["data ${1:myDatat}${2:: $3}"], + "body": ["data ${1:myData}${2:: $3}"], "description": "A Data." }, "Aggregation": { From 8b9ef125d4f09dcd0ff7a36b59ac03503a26a891 Mon Sep 17 00:00:00 2001 From: alex-senger Date: Mon, 19 Aug 2024 18:52:16 +0200 Subject: [PATCH 142/183] feat: lohnsteuer --- .../builtins/steuern/lohnsteuer.ttsl | 204 ++++++++++++++++++ 1 file changed, 204 insertions(+) create mode 100644 src/resources/builtins/steuern/lohnsteuer.ttsl diff --git a/src/resources/builtins/steuern/lohnsteuer.ttsl b/src/resources/builtins/steuern/lohnsteuer.ttsl new file mode 100644 index 00000000..e0ba9101 --- /dev/null +++ b/src/resources/builtins/steuern/lohnsteuer.ttsl @@ -0,0 +1,204 @@ +package lohnsteuer + +from einkommenssteuerAbzuege import alleinerzFreibetrag, werbungskostenpauschale, sonderausgabenpauschbetrag, einkommenssteuerTarif, vorsorgepauschaleMindestanteil, vorsorgepauschaleKvMax +from sozialversicherungsbeitrag import beitragssatz +from einkommenssteuer import einkommenssteuer +from math import max + +/** + * Calculate tax base for Lohnsteuer (withholding tax on earnings). + */ +public function einkommen(bruttolohn: Float): Float per year { + entlastung_freibetrag_alleinerz = (steuerklasse() == 2) * alleinerzFreibetrag + + if(steuerklasse == 6) { + werbungskosten = 0 + sonderausgaben = 0 + } else { + werbungskosten = werbungskostenpauschale + sonderausgaben = sonderausgabenpauschbetrag["single"] + } + + # Zu versteuerndes Einkommen / tax base for Lohnsteuer. + out = max( + 12 * bruttolohn_m + - werbungskosten + - sonderausgaben + - entlastung_freibetrag_alleinerz + - vorsorgepauschale() per year, + 0.0 + ) + + return out +} + +/** + * Berechnung der Lohnsteuer für die Steuerklassen 5 und 6, basierend auf dem zu versteuernden Einkommen. + */ +private function berechneLohnsteuerKlasse5_6Basis( + einkommen: Float, + einkommensteuerParameter: Map +): Float { + return max( + 2 * ( + einkommensteuer(einkommen * 1.25) - einkommensteuer(einkommen * 0.75)), + einkommen * einkommenssteuerTarif[0][1] + ); +} + +/** + * Berechnung der Vorsorgepauschale für die Krankenversicherung (Option B), differenziert nach den + * zeitlichen Validitäten. + */ +public function vorsorgeKrankenversicherungOptionB( + bruttolohn: Float +): Float per year { + to 2018-12-31 { + return bruttolohn * 12 * ( + beitragssatz["gesetzlicheKrankenversicherung"]["ermaessigt"] / 2 + + krankenversicherungZusatzbeitragssatz() / 100 + + pflegeversicherungBeitragssatz() + ); + } + + from 2019-01-01 { + return bruttolohn * 12 * ( + beitragssatz["gesetzlicheKrankenversicherung"]["ermaessigt"] / 2 + + krankenversicherungZusatzbeitragssatz() / 2 / 100 + + pflegeversicherungBeitragssatz() + ); + } +} + +/** + * Berechnung der Vorsorgepauschale für die Krankenversicherung (Option A). + */ +public function vorsorgeKrankenversicherungOptionA( + bruttolohn: Float per year, + steuerklasse: Int +): Float per year { + var basisPauschale = vorsorgepauschaleMindestanteil * bruttolohn; + + var maxPauschale; + if steuerklasse == 3 { + maxPauschale = vorsorgepauschaleKvMax["steuerklasse3"]; + } else { + maxPauschale = vorsorgepauschaleKvMax["steuerklasseNicht3"]; + } + + return min(maxPauschale, basisPauschale); +} + +/** + * Berechnung der Vorsorgepauschale für die Lohnsteuer ab dem Jahr 2010. + */ +public function vorsorgePauschale( + bruttolohn: Float per month, + wohnortOst: Boolean +): Float per year { + from 2005-01-01 { + return 0.0; + } + + from 2010-01-01 { + if (wohnortOst) { + bruttolohnRente = min( + bruttolohn * 12, + beitragsbemessungsgrenzeOstRente["ges_rentenv"]["ost"] * 12 + ); + } else { + bruttolohnRente = min( + bruttolohn * 12, + beitragsbemessungsgrenzeWestRente["ges_rentenv"]["west"]] * 12 + ); + } + + Float vorsorgeRente = bruttolohnRente + * beitragssatz["ges_rentenv"] + * vorsorgepauschaleRentenversicherungAnteil; + + Float vorsorgeKrankenversicherung = max(krankenversicherungOptionA(), krankenversicherungOptionB()); + + return vorsorgeRente + vorsorgeKrankenversicherung; + } +} + +/** + * Berechnung des Kinderfreibetrags für die Lohnsteuer und den Solidaritätszuschlag. + */ +public function kinderfreibetragFuerLohnsteuerSoli( + steuerklasse: Int +): Float per year { + Float kinderfreibetragBasis = kinderfreibetrag["SaechlichesExistenzminimum"] + + kinderfreibetragBeitrag["ErziehungAusbildung"]; + + if steuerklasse == 1 or steuerklasse == 2 or steuerklasse == 3} { + return kinderfreibetragBasis * 2 * kinderfreibetragAnsprueche(); + } else if steuerklasse == 4 { + return kinderfreibetragBasis * kinderfreibetragAnsprueche(); + } else { + return 0.0; + } +} + +private function lohnsteuer_m( + einkommen: Float per month, + steuerklasse: Int, + ): Float per month { + var lohnsteuerBasistarif = einkommensteuer.tarif(einkommen)); + var lohnsteuerSplittingtarif = 2 * einkommensteuer.tarif(einkommen) / 2); + var lohnsteuerKlasse5_6Basis = berechneLohnsteuerKlasse5_6Basis(einkommen)); + + var grenze1 = einkommensgrenzen[0]; + var grenze2 = einkommensgrenzen[1]; + var grenze3 = einkommensgrenzen[2]; + + var lohnsteuerGrenze1 = berechneLohnsteuerKlasse5_6Basis(grenze1); + var maxLohnsteuer = lohnsteuerGrenze1 + + (einkommen - grenze1) * tarif["rates"][0][3]; + + var lohnsteuerGrenze2 = lohnsteuerKlasse5_6BasisBerechnung(grenze2); + var lohnsteuerZwischenGrenze2_3 = (grenze3 - grenze2) * tarif["rates"][0][3]; + var lohnsteuerKlasse5_6Tmp = lohnsteuerGrenze2 + lohnsteuerZwischenGrenze2_3; + + var lohnsteuerKlasse5_6; + if einkommen) < grenze1 { + lohnsteuerKlasse5_6 = lohnsteuerKlasse5_6Basis; + } elif grenze1 <= einkommen < grenze2 { + lohnsteuerKlasse5_6 = min(maxLohnsteuer, lohnsteuerKlasse5_6BasisBerechnung(einkommen))); + } elif grenze2 <= einkommen) < grenze3 { + lohnsteuerKlasse5_6 = lohnsteuerGrenze2 + + (einkommen) - grenze2) * tarif["rates"][0][3]; + } else { + lohnsteuerKlasse5_6 = lohnsteuerKlasse5_6Tmp + + (einkommen) - grenze3) * tarif["rates"][0][4]; + } + + var lohnsteuer; + if steuerklasse == 1 or steuerklasse == 2 or steuerklasse == 4} { + lohnsteuer = lohnsteuerBasistarif; + } elif steuerklasse == 3 { + lohnsteuer = lohnsteuerSplittingtarif; + } else { + lohnsteuer = lohnsteuerKlasse5_6; + } + + return max(lohnsteuer / 12, 0.0); +} + +public lohnsteuer(): Float per month { + return lohnsteuer_m(); +} + +/** + * Berechnet die Lohnsteuer unter Berücksichtigung des Kinderfreibetrags. + * Diese Berechnung wird hauptsächlich für die Berechnung des Solidaritätszuschlags + * auf die Lohnsteuer verwendet. + */ +public function lohnsteuerMitKinderfreibetrag( + steuerklasse: Int +): Float per month { + Float angepasstesEinkommen = max(lohnSteuerEinkommen() - kinderfreibetragFürSoli(), 0.0); + + return lohnsteuerBerechnung(angepasstesEinkommen, steuerklasse); +} From a8a667a3d3e8064926ea363a5e4cd6f0f7a2b42c Mon Sep 17 00:00:00 2001 From: alex-senger Date: Mon, 19 Aug 2024 19:04:01 +0200 Subject: [PATCH 143/183] feat: solisteuer --- .../steuern/solidarit\303\244tssteuer.ttsl" | 27 +++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 "src/resources/builtins/steuern/solidarit\303\244tssteuer.ttsl" diff --git "a/src/resources/builtins/steuern/solidarit\303\244tssteuer.ttsl" "b/src/resources/builtins/steuern/solidarit\303\244tssteuer.ttsl" new file mode 100644 index 00000000..74a3424b --- /dev/null +++ "b/src/resources/builtins/steuern/solidarit\303\244tssteuer.ttsl" @@ -0,0 +1,27 @@ +package solidaritätssteuer + +public function solidaritätsSteuer(): Float per year { + to 2008-12-31 { + Float einkommensteuerProPerson = einkommensteuerMitKinderfreibetrag() / anzahlPersonen(); + return anzahlPersonen * solisteuerTarif(einkommensteuerProPerson); + } + + from 2009-01-01{ + Float einkommensteuerProPerson = einkommensteuerMitKinderfreibetrag() / anzahlPersonen(); + + return anzahlPersonen() * solisteuerTarif(einkommensteuerProPerson) + solisteuer["rates"][0, -1] * abgeltungssteuer() per year; + } +} + +/** + * Berechnet den Solidaritätszuschlag auf die Lohnsteuer. + */ +public function soliStLohnsteuerBerechnung( + lohnsteuerMitKinderfreibetrag: Float per month +): Float per month { + return solisteuerTarif(lohnsteuerMitKinderfreibetrag * 12) / 12; +} + +public function solisteuerTarif(): Float per year { + # TODO: Piecewise polynomial function +} From ab7fb7de149840b3140edbfd487caef37c935afd Mon Sep 17 00:00:00 2001 From: methr0 Date: Tue, 20 Aug 2024 18:30:27 +0200 Subject: [PATCH 144/183] grammar und generation tests klappen soweit abgesehen von paar scoping und typing errors --- .../tests/resources/check/correct.ttsl | 2 +- .../tests/resources/format/correct.ttsl | 2 +- .../tests/resources/generate/correct.ttsl | 2 +- .../documentation/ttsl-comment-provider.ts | 2 +- .../generation/ttsl-python-generator.ts | 220 +++++++++--------- .../src/language/grammar/ttsl.langium | 58 +++-- .../src/language/lsp/ttsl-formatter.ts | 10 +- .../ttsl-partial-evaluator.ts | 3 + .../scoping/ttsl-scope-computation.ts | 55 +++++ .../language/scoping/ttsl-scope-provider.ts | 6 +- .../ttsl-lang/src/language/typing/model.ts | 48 +++- .../src/language/typing/ttsl-type-computer.ts | 18 +- .../src/language/validation/style.ts | 3 +- .../src/language/validation/types.ts | 26 +-- .../tests/helpers/nodeFinder.test.ts | 2 +- .../tests/helpers/testChecks.test.ts | 16 +- .../tests/helpers/testComments.test.ts | 8 +- .../ttsl-lang/tests/helpers/testComments.ts | 4 +- .../tests/helpers/testResources.test.ts | 14 +- .../safe-ds-comment-provider.test.ts | 16 +- .../argumentToParameter.test.ts | 10 +- .../callToCallable.test.ts | 32 +-- .../parameterToReferences.test.ts | 34 +-- .../placeholdersToReferences.test.ts | 4 +- .../safe-ds-call-hierarchy-provider.test.ts | 6 +- .../lsp/safe-ds-inlay-hint-provider.test.ts | 30 +-- .../safe-ds-signature-help-provider.test.ts | 20 +- .../tests/language/scoping/scoping.test.ts | 9 - .../canBeTypeOfConstantParameter.test.ts | 2 +- .../call graph/annotation call.sdstest | 4 +- .../argument/block lambda.sdstest | 4 +- .../callable does not get called.sdstest | 4 +- .../argument/expression lambda.sdstest | 4 +- .../argument/function.sdstest | 4 +- .../argument/segment.sdstest | 4 +- .../block lambda call/basic.sdstest | 4 +- .../function call in nested lambda.sdstest | 4 +- .../body/function call.sdstest | 4 +- .../default value/call.sdstest | 4 +- .../default value/callable.sdstest | 4 +- .../default value/previous parameter.sdstest | 4 +- .../block lambda call/null safe.sdstest | 4 +- .../call graph/callable type call.sdstest | 2 +- .../call graph/callable/block lambda.sdstest | 4 +- .../call graph/callable/class.sdstest | 2 +- .../call graph/callable/enum variant.sdstest | 2 +- .../callable/expression lambda.sdstest | 4 +- .../call graph/callable/function.sdstest | 2 +- .../call graph/callable/segment.sdstest | 2 +- .../class call/argument/call.sdstest | 4 +- .../class call/argument/callable.sdstest | 4 +- .../class call/argument/other.sdstest | 4 +- .../call graph/class call/basic.sdstest | 4 +- .../class call/default value/call.sdstest | 4 +- .../class call/default value/callable.sdstest | 4 +- .../default value/previous parameter.sdstest | 4 +- .../call graph/class call/null safe.sdstest | 4 +- .../block lambda passed as argument.sdstest | 4 +- .../closure/block lambda returned.sdstest | 4 +- ...pression lambda passed as argument.sdstest | 4 +- .../expression lambda returned.sdstest | 4 +- ...ault value handling in entry point.sdstest | 2 +- .../enum variant call/argument/call.sdstest | 4 +- .../argument/callable.sdstest | 4 +- .../enum variant call/argument/other.sdstest | 4 +- .../enum variant call/basic.sdstest | 4 +- .../enum variant call/called twice.sdstest | 4 +- .../default value/call.sdstest | 4 +- .../default value/callable.sdstest | 4 +- .../default value/previous parameter.sdstest | 4 +- .../enum variant call/null safe.sdstest | 4 +- .../argument/block lambda.sdstest | 4 +- .../callable does not get called.sdstest | 4 +- .../argument/expression lambda.sdstest | 4 +- .../argument/function.sdstest | 4 +- .../argument/segment.sdstest | 4 +- .../expression lambda call/basic.sdstest | 4 +- .../function call in nested lambda.sdstest | 4 +- .../body/function call.sdstest | 4 +- .../default value/call.sdstest | 4 +- .../default value/callable.sdstest | 4 +- .../default value/previous parameter.sdstest | 4 +- .../expression lambda call/null safe.sdstest | 4 +- .../function call/argument/call.sdstest | 4 +- .../function call/argument/callable.sdstest | 4 +- .../function call/argument/other.sdstest | 4 +- .../call graph/function call/basic.sdstest | 4 +- .../function call/default value/call.sdstest | 4 +- .../default value/callable.sdstest | 4 +- .../default value/previous parameter.sdstest | 4 +- .../function call/instance method.sdstest | 4 +- .../function call/null safe.sdstest | 8 +- .../function call/static method.sdstest | 4 +- .../call graph/recursion/direct.sdstest | 6 +- .../recursion/not recursive.sdstest | 2 +- ...tive via function pointer argument.sdstest | 2 +- .../transitive via lambda argument.sdstest | 2 +- .../call graph/recursion/transitive.sdstest | 6 +- .../argument/block lambda.sdstest | 4 +- .../callable does not get called.sdstest | 4 +- .../argument/expression lambda.sdstest | 4 +- .../segment call/argument/function.sdstest | 4 +- .../segment call/argument/segment.sdstest | 4 +- .../call graph/segment call/basic.sdstest | 4 +- .../function call in nested lambda.sdstest | 4 +- .../segment call/body/function call.sdstest | 4 +- .../segment call/default value/call.sdstest | 4 +- .../default value/callable.sdstest | 4 +- .../default value/previous parameter.sdstest | 4 +- .../call graph/segment call/null safe.sdstest | 4 +- .../call graph/unresolved callable.sdstest | 4 +- .../comments/before declarations.sdstest | 6 +- .../comments/before imports.sdstest | 6 +- .../before module annotations.sdstest | 6 +- .../comments/before module name.sdstest | 6 +- .../complex argument list.sdstest | 2 +- .../empty argument list.sdstest | 2 +- .../long argument list.sdstest | 2 +- .../multiple arguments.sdstest | 2 +- .../annotation calls/named argument.sdstest | 2 +- .../annotation calls/no argument list.sdstest | 2 +- .../positional argument.sdstest | 2 +- .../annotations/annotation call.sdstest | 2 +- .../annotations/no parameter list.sdstest | 2 +- .../annotations/with constraint list.sdstest | 2 +- .../annotations/with parameter list.sdstest | 2 +- .../classes/annotation call.sdstest | 2 +- .../classes/attributes/annotated.sdstest | 2 +- .../classes/attributes/no type.sdstest | 2 +- .../classes/attributes/static.sdstest | 2 +- .../classes/attributes/with type.sdstest | 2 +- .../declarations/classes/empty body.sdstest | 2 +- .../declarations/classes/full body.sdstest | 2 +- .../methods/annotated instance method.sdstest | 2 +- .../methods/annotated static method.sdstest | 2 +- .../classes/methods/instance method.sdstest | 2 +- .../classes/methods/static method.sdstest | 2 +- .../declarations/classes/minimal.sdstest | 2 +- .../classes/multiple parent types.sdstest | 2 +- .../annotated nested class.sdstest | 2 +- .../nested classes/nested-class.sdstest | 2 +- .../annotated nested enum.sdstest | 2 +- .../classes/nested enums/nested enum.sdstest | 2 +- .../classes/one parent type.sdstest | 2 +- .../classes/with constraint list.sdstest | 2 +- .../classes/with parameter list.sdstest | 2 +- .../classes/with type parameter list.sdstest | 2 +- .../greater than constraint.sdstest | 2 +- .../greater than or equal constraint.sdstest | 2 +- .../constraints/less than constraint.sdstest | 2 +- .../less than or equal constraint.sdstest | 2 +- .../constraints/multiple constraints.sdstest | 2 +- .../enums/annotation call.sdstest | 2 +- .../declarations/enums/empty body.sdstest | 2 +- .../declarations/enums/full body.sdstest | 2 +- .../declarations/enums/no body.sdstest | 2 +- .../enums/variants in body.sdstest | 2 +- .../enums/variants/annotation call.sdstest | 2 +- .../enums/variants/no parameter list.sdstest | 2 +- .../variants/with constraint list.sdstest | 2 +- .../variants/with parameter list.sdstest | 2 +- .../functions/annotation call.sdstest | 2 +- .../functions/with constraint list.sdstest | 2 +- .../functions/with result list.sdstest | 2 +- .../with type parameter list.sdstest | 2 +- .../parameters/complex parameter list.sdstest | 2 +- .../parameters/empty parameter list.sdstest | 2 +- .../parameters/long parameter list.sdstest | 2 +- .../parameters/multiple parameters.sdstest | 2 +- ...ith const typed optional parameter.sdstest | 2 +- ...ith const typed required parameter.sdstest | 2 +- ...h const untyped optional parameter.sdstest | 2 +- ...h const untyped required parameter.sdstest | 2 +- .../with typed optional parameter.sdstest | 2 +- .../with typed required parameter.sdstest | 2 +- .../with untyped optional parameter.sdstest | 2 +- .../with untyped required parameter.sdstest | 2 +- .../pipelines/annotation call.sdstest | 4 +- .../declarations/pipelines/empty body.sdstest | 4 +- .../pipelines/statements in body.sdstest | 4 +- .../results/complex result list.sdstest | 2 +- .../results/long result list.sdstest | 2 +- .../results/multiple results.sdstest | 2 +- .../results/no results (explicit).sdstest | 2 +- .../one typed result (in parentheses).sdstest | 2 +- .../one typed result (no parentheses).sdstest | 2 +- ...ne untyped result (no parentheses).sdstest | 2 +- ... untyped result (with parentheses).sdstest | 2 +- .../segments/annotation call.sdstest | 2 +- ...ernal segment with annotation call.sdstest | 2 +- .../segments/internal segment.sdstest | 2 +- .../declarations/segments/minimal.sdstest | 2 +- ...ivate segment with annotation call.sdstest | 2 +- .../segments/private segment.sdstest | 2 +- .../segments/statements in body.sdstest | 2 +- .../segments/with constraint list.sdstest | 2 +- .../segments/with result list.sdstest | 2 +- ...travariant optional type parameter.sdstest | 2 +- ...travariant required type parameter.sdstest | 2 +- ...ype parameter with annotation call.sdstest | 2 +- ... covariant optional type parameter.sdstest | 2 +- ... covariant required type parameter.sdstest | 2 +- ...ype parameter with annotation call.sdstest | 2 +- ... invariant optional type parameter.sdstest | 2 +- ... invariant required type parameter.sdstest | 2 +- ...ype parameter with annotation call.sdstest | 2 +- .../long type parameter list.sdstest | 2 +- .../multiple type parameters.sdstest | 2 +- ...travariant optional type parameter.sdstest | 2 +- ...travariant required type parameter.sdstest | 2 +- ...ype parameter with annotation call.sdstest | 2 +- ... covariant optional type parameter.sdstest | 2 +- ... covariant required type parameter.sdstest | 2 +- ...ype parameter with annotation call.sdstest | 2 +- ... invariant optional type parameter.sdstest | 2 +- ... invariant required type parameter.sdstest | 2 +- ...ype parameter with annotation call.sdstest | 2 +- .../arithmetic operators/addition.sdstest | 6 +- .../complex example.sdstest | 6 +- .../arithmetic operators/division.sdstest | 6 +- .../multiplication.sdstest | 6 +- .../arithmetic operators/negation.sdstest | 6 +- .../arithmetic operators/subtraction.sdstest | 6 +- .../block lambdas/filled body.sdstest | 6 +- .../expressions/block lambdas/minimal.sdstest | 6 +- .../calls/complex argument list.sdstest | 2 +- .../calls/long argument list.sdstest | 2 +- ...xed positional and named arguments.sdstest | 6 +- .../expressions/calls/named argument.sdstest | 6 +- .../expressions/calls/no arguments.sdstest | 6 +- .../expressions/calls/null safe.sdstest | 6 +- .../calls/positional argument.sdstest | 6 +- .../greater than or equal.sdstest | 6 +- .../comparison operators/greater than.sdstest | 6 +- .../less than or equal.sdstest | 6 +- .../comparison operators/less than.sdstest | 6 +- .../complex chained expression.sdstest | 6 +- .../expressions/elvis operator.sdstest | 6 +- .../equality operators/equal.sdstest | 6 +- .../equality operators/identical.sdstest | 6 +- .../equality operators/not equal.sdstest | 6 +- .../equality operators/not identical.sdstest | 6 +- .../expression lambdas/minimal.sdstest | 6 +- .../indexed accesses/literal index.sdstest | 6 +- .../indexed accesses/null safe.sdstest | 6 +- .../indexed accesses/reference index.sdstest | 6 +- .../expressions/lists/complex element.sdstest | 6 +- .../lists/nested multiple elements.sdstest | 6 +- .../lists/nested one element.sdstest | 6 +- .../lists/one level multiple elements.sdstest | 6 +- .../lists/one level one element.sdstest | 6 +- .../expressions/literals/false.sdstest | 6 +- .../literals/float/basic example.sdstest | 6 +- ...ientific notation with lowercase e.sdstest | 6 +- ...ientific notation with uppercase e.sdstest | 6 +- .../literals/int/leading zero.sdstest | 6 +- .../literals/int/multiple digits.sdstest | 6 +- .../literals/int/one digit.sdstest | 6 +- .../expressions/literals/null.sdstest | 6 +- .../literals/string/basic content.sdstest | 6 +- ...sing template expression delimiter.sdstest | 6 +- .../curly braces separated by space.sdstest | 6 +- .../expressions/literals/string/empty.sdstest | 6 +- .../string/escaped curly brace.sdstest | 6 +- .../literals/string/multiple lines.sdstest | 6 +- .../string/newline escape sequence.sdstest | 6 +- .../string/single curly brace.sdstest | 6 +- .../literals/string/single quote.sdstest | 6 +- .../string/unicode escape sequence.sdstest | 6 +- .../expressions/literals/true.sdstest | 6 +- .../complex example.sdstest | 6 +- .../logical operations/conjunction.sdstest | 6 +- .../logical operations/disjunction.sdstest | 6 +- .../logical operations/negation.sdstest | 6 +- .../expressions/maps/complex key.sdstest | 6 +- .../expressions/maps/complex value.sdstest | 6 +- .../maps/nested multiple elements.sdstest | 6 +- .../maps/nested one element.sdstest | 6 +- .../maps/one level multiple elements.sdstest | 6 +- .../maps/one level one element.sdstest | 6 +- .../member accesses/not null safe.sdstest | 6 +- .../member accesses/null safe.sdstest | 6 +- .../parenthesized expressions/nested.sdstest | 6 +- .../one level.sdstest | 6 +- .../formatting/expressions/reference.sdstest | 6 +- .../empty template expression.sdstest | 6 +- ...plate string with basic expression.sdstest | 6 +- ...mplate string with two expressions.sdstest | 6 +- .../formatting/expressions/type cast.sdstest | 6 +- .../annotation call and declaration.sdstest | 2 +- ...on call and import and declaration.sdstest | 2 +- .../annotation call and import.sdstest | 2 +- ...l and package name and declaration.sdstest | 2 +- ...ge name and import and declaration.sdstest | 2 +- ...n call and package name and import.sdstest | 2 +- .../annotation call and package name.sdstest | 2 +- .../modules/annotation call.sdstest | 2 +- .../annotation calls and declarations.sdstest | 2 +- ...calls and imports and declarations.sdstest | 2 +- .../annotation calls and imports.sdstest | 2 +- ... and package name and declarations.sdstest | 2 +- ... name and imports and declarations.sdstest | 2 +- ...calls and package name and imports.sdstest | 2 +- .../annotation calls and package name.sdstest | 2 +- .../modules/annotation calls.sdstest | 2 +- .../formatting/modules/declaration.sdstest | 2 +- .../formatting/modules/declarations.sdstest | 2 +- .../formatting/modules/empty.sdstest | 6 +- .../resources/formatting/modules/full.sdstest | 2 +- .../modules/import and declaration.sdstest | 2 +- .../formatting/modules/import.sdstest | 2 +- .../modules/imports and declarations.sdstest | 2 +- .../formatting/modules/imports.sdstest | 2 +- .../package name and declaration.sdstest | 2 +- .../package name and declarations.sdstest | 2 +- ...ge name and import and declaration.sdstest | 2 +- .../modules/package name and import.sdstest | 2 +- ... name and imports and declarations.sdstest | 2 +- .../modules/package name and imports.sdstest | 2 +- .../formatting/modules/package name.sdstest | 2 +- .../formatting/schema/annotation call.sdstest | 2 +- .../formatting/schema/empty schema.sdstest | 2 +- .../formatting/schema/one column.sdstest | 2 +- .../formatting/schema/two columns.sdstest | 2 +- .../assignments/in block lambda.sdstest | 6 +- .../assignments/in pipeline.sdstest | 6 +- .../statements/assignments/in segment.sdstest | 2 +- .../in block lambda.sdstest | 6 +- .../expression statements/in pipeline.sdstest | 6 +- .../expression statements/in segment.sdstest | 2 +- .../in block lambda.sdstest | 6 +- .../flexible new lines/in pipeline.sdstest | 6 +- .../flexible new lines/in segment.sdstest | 2 +- ... list of annotation call (complex).sdstest | 2 +- ...ent list of annotation call (long).sdstest | 2 +- .../argument list of annotation call.sdstest | 2 +- .../argument list of call (complex).sdstest | 2 +- .../argument list of call (long).sdstest | 2 +- .../argument list of call.sdstest | 2 +- ...list of assignment in block lambda.sdstest | 2 +- .../assignee list of assignment.sdstest | 2 +- .../column list of schema.sdstest | 2 +- .../constraint list of annotation.sdstest | 2 +- .../constraint list of class.sdstest | 2 +- .../constraint list of enum variant.sdstest | 2 +- .../constraint list of function.sdstest | 2 +- .../elements of list (complex).sdstest | 6 +- .../trailing commas/elements of list.sdstest | 6 +- .../entries of map (complex).sdstest | 6 +- .../entries of map (multiple entries).sdstest | 6 +- ...entries of map (one literal entry).sdstest | 6 +- ...claration list in qualified import.sdstest | 2 +- .../literal list of literal type.sdstest | 2 +- ...meter list of annotation (complex).sdstest | 2 +- ...arameter list of annotation (long).sdstest | 2 +- ...st of annotation (with annotation).sdstest | 2 +- .../parameter list of annotation.sdstest | 2 +- ...ter list of block lambda (complex).sdstest | 2 +- ...ameter list of block lambda (long).sdstest | 2 +- ... of block lambda (with annotation).sdstest | 2 +- .../parameter list of block lambda.sdstest | 2 +- ...er list of callable type (complex).sdstest | 2 +- ...meter list of callable type (long).sdstest | 2 +- ...of callable type (with annotation).sdstest | 2 +- .../parameter list of callable type.sdstest | 2 +- .../parameter list of class (complex).sdstest | 2 +- .../parameter list of class (long).sdstest | 2 +- ...er list of class (with annotation).sdstest | 2 +- .../parameter list of class.sdstest | 2 +- ...ter list of enum variant (complex).sdstest | 2 +- ...ameter list of enum variant (long).sdstest | 2 +- ... of enum variant (with annotation).sdstest | 2 +- .../parameter list of enum variant.sdstest | 2 +- ...ist of expression lambda (complex).sdstest | 2 +- ...r list of expression lambda (long).sdstest | 2 +- ...xpression lambda (with annotation).sdstest | 2 +- ...arameter list of expression lambda.sdstest | 2 +- ...rameter list of function (complex).sdstest | 2 +- .../parameter list of function (long).sdstest | 2 +- ...list of function (with annotation).sdstest | 2 +- .../parameter list of function.sdstest | 2 +- ...arameter list of segment (complex).sdstest | 2 +- .../parameter list of segment (long).sdstest | 2 +- ... list of segment (with annotation).sdstest | 2 +- .../parameter list of segment.sdstest | 2 +- .../parent type list of class.sdstest | 2 +- ...lt list of callable type (complex).sdstest | 2 +- ...esult list of callable type (long).sdstest | 2 +- ...of callable type (with annotation).sdstest | 2 +- .../result list of callable type.sdstest | 2 +- .../result list of function (complex).sdstest | 2 +- .../result list of function (long).sdstest | 2 +- ...list of function (with annotation).sdstest | 2 +- .../result list of function.sdstest | 2 +- .../result list of segment (complex).sdstest | 2 +- .../result list of segment (long).sdstest | 2 +- ... list of segment (with annotation).sdstest | 2 +- .../result list of segment.sdstest | 2 +- .../type argument list of named type.sdstest | 2 +- .../type argument list of union type.sdstest | 2 +- ...ype parameter list of class (long).sdstest | 2 +- ...er list of class (with annotation).sdstest | 2 +- .../type parameter list of class.sdstest | 2 +- ... parameter list of function (long).sdstest | 2 +- ...list of function (with annotation).sdstest | 2 +- .../type parameter list of function.sdstest | 2 +- .../types/callable types/minimal.sdstest | 2 +- .../types/literal types/empty.sdstest | 2 +- .../types/literal types/with literals.sdstest | 2 +- .../member types/long complex chain.sdstest | 2 +- ...allable) and member (not nullable).sdstest | 2 +- ...r (callable) and member (nullable).sdstest | 2 +- ...literal) and member (not nullable).sdstest | 2 +- ...er (literal) and member (nullable).sdstest | 2 +- ...ullable) and member (not nullable).sdstest | 2 +- ...ot nullable) and member (nullable).sdstest | 2 +- ...ullable) and member (not nullable).sdstest | 2 +- ...d, nullable) and member (nullable).sdstest | 2 +- ... (union) and member (not nullable).sdstest | 2 +- ...iver (union) and member (nullable).sdstest | 2 +- ...no type arguments and not nullable.sdstest | 2 +- .../no type arguments and nullable.sdstest | 2 +- .../type argument and nullable.sdstest | 2 +- .../type arguments and not nullable.sdstest | 2 +- .../types/union types/empty.sdstest | 2 +- .../types/union types/nested.sdstest | 2 +- .../union types/with type arguments.sdstest | 2 +- .../tests/generator/const/gen_input_test.py | 4 - .../generator/{const => const1}/gen_input.py | 0 .../{const => const1}/gen_input.py.map | 0 .../declarations/constant/input.ttsl | 4 +- .../tests/generator/datas/gen_input.py | 3 - .../tests/generator/datas/gen_input.py.map | 2 +- .../tests/generator/datas/gen_input_test.py | 4 - .../generator/emptyFunction/gen_input_test.py | 2 +- .../generator/emptyPipeline/gen_input.py | 4 - .../generator/emptyPipeline/gen_input.py.map | 1 - .../declarations/empty pipeline/input.sdstest | 3 - .../tests/generator/emptySegment/gen_input.py | 4 - .../generator/emptySegment/gen_input.py.map | 1 - .../declarations/empty segment/input.sdstest | 3 - .../functionWithParameter}/gen_input_test.py | 0 .../functionWithReturnValue/gen_input.py.map | 2 +- .../gen_input_test.py | 0 .../function with return Value/input.ttsl | 2 +- .../parameterWithPythonName/gen_input.py | 7 - .../parameterWithPythonName/gen_input.py.map | 1 - .../parameter with python name/input.sdstest | 9 - .../pipelineWithPythonName/gen_input.py | 4 - .../pipelineWithPythonName/gen_input.py.map | 1 - .../gen_input_test_pipeline.py | 4 - .../pipeline with python name/input.sdstest | 8 - .../segmentWithPythonName/gen_input.py | 4 - .../segmentWithPythonName/gen_input.py.map | 1 - .../segment with python name/input.sdstest | 8 - .../tests/generator/twoPipelines/gen_input.py | 7 - .../generator/twoPipelines/gen_input.py.map | 1 - .../generator/twoPipelines/gen_input_test1.py | 4 - .../generator/twoPipelines/gen_input_test2.py | 4 - .../declarations/two pipelines/input.sdstest | 11 - .../tests/generator/twoSegments/gen_input.py | 7 - .../generator/twoSegments/gen_input.py.map | 1 - .../declarations/two segments/input.sdstest | 11 - .../tests/generator/aggregation/gen_input.py | 7 - .../generator/aggregation/gen_input.py.map | 2 +- .../generator/aggregation/gen_input_test.py | 4 - .../aggregation/gen_input_testFunction.py | 4 + .../generator/blockLambdaResult/gen_input.py | 21 -- .../blockLambdaResult/gen_input.py.map | 1 - .../block lambda result/input.sdstest | 26 --- .../tests/generator/blockLambda/gen_input.py | 23 -- .../generator/blockLambda/gen_input.py.map | 1 - .../expressions/block lambda/input.sdstest | 25 -- .../tests/generator/call/gen_input.py | 31 ++- .../tests/generator/call/gen_input.py.map | 2 +- .../tests/generator/call/gen_input_f.py | 4 + .../tests/generator/call/gen_input_g.py | 4 + .../tests/generator/call/gen_input_h.py | 4 + .../tests/generator/call/gen_input_i.py | 4 + .../generation/expressions/call/input.sdstest | 45 ---- .../generation/expressions/call/input.ttsl | 29 +++ .../tests/generator/const/gen_input.py | 11 + .../tests/generator/const/gen_input.py.map | 1 + .../tests/generator/const/gen_input_f.py | 4 + .../tests/generator/const}/gen_input_test.py | 0 .../tests/generator/constant/gen_input.py | 8 - .../tests/generator/constant/gen_input.py.map | 1 - .../expressions/constant/input.sdstest | 11 - .../expressions/constant/input.ttsl | 10 + .../generator/enumVariantCall/gen_input.py | 9 - .../enumVariantCall/gen_input.py.map | 1 - .../enum variant call/input.sdstest | 17 -- .../generator/expressionLambda/gen_input.py | 5 - .../expressionLambda/gen_input.py.map | 1 - .../expressionLambda/gen_input_test.py | 4 - .../expression lambda/input.sdstest | 8 - .../generator/indexedAccess/gen_input.py | 18 -- .../generator/indexedAccess/gen_input.py.map | 1 - .../expressions/indexed access/input.sdstest | 8 - .../expressions/indexed access/input.ttsl | 6 + .../generator/infixOperation/gen_input.py | 15 +- .../generator/infixOperation/gen_input.py.map | 2 +- .../generator/infixOperation/gen_input_f.py | 4 + .../generator/infixOperation/gen_input_g.py | 4 + .../generator/infixOperation/gen_input_h.py | 4 + .../generator/infixOperation/gen_input_i.py | 4 + .../{input.sdstest => input.ttsl} | 10 +- .../tests/generator/lists/gen_input.py | 12 +- .../tests/generator/lists/gen_input.py.map | 2 +- .../tests/generator/lists/gen_input_h.py | 4 + .../expressions/lists/input.sdstest | 11 - .../generation/expressions/lists/input.ttsl | 9 + .../tests/generator/literals/gen_input.py | 18 +- .../tests/generator/literals/gen_input.py.map | 2 +- .../expressions/literals/input.sdstest | 14 -- .../expressions/literals/input.ttsl | 12 + .../tests/generator/maps/gen_input.py | 8 - .../tests/generator/maps/gen_input.py.map | 1 - .../tests/generator/maps/gen_input_test.py | 4 - .../generation/expressions/maps/input.sdstest | 19 -- .../generation/expressions/maps/input.ttsl | 19 ++ .../tests/generator/memberAccess/gen_input.py | 27 --- .../generator/memberAccess/gen_input.py.map | 1 - .../generator/memberAccess/gen_input_test.py | 4 - .../expressions/member access/input.sdstest | 41 ---- .../parenthesizedExpression/gen_input.py | 9 +- .../parenthesizedExpression/gen_input.py.map | 2 +- .../parenthesizedExpression/gen_input_f.py | 4 + .../parenthesizedExpression/gen_input_g.py | 4 + .../parenthesized expression/input.sdstest | 9 - .../parenthesized expression/input.ttsl | 9 + .../generator/prefixOperation/gen_input.py | 12 +- .../prefixOperation/gen_input.py.map | 2 +- .../generator/prefixOperation/gen_input_f.py | 4 + .../generator/prefixOperation/gen_input_g.py | 4 + .../generator/prefixOperation/gen_input_h.py | 4 + .../prefix operation/input.sdstest | 12 - .../expressions/prefix operation/input.ttsl | 12 + .../tests/generator/reference/gen_input.py | 11 +- .../generator/reference/gen_input.py.map | 2 +- .../reference/gen_input_explainModel.py | 4 + .../tests/generator/reference/gen_input_f.py | 4 + .../expressions/reference/input.sdstest | 11 - .../expressions/reference/input.ttsl | 9 + .../tests/generator/sideEffects/gen_input.py | 15 -- .../generator/sideEffects/gen_input.py.map | 1 - .../generator/sideEffects/gen_input_test.py | 4 - .../expressions/side effects/input.sdstest | 16 -- .../generator/templateString/gen_input.py | 4 - .../generator/templateString/gen_input.py.map | 1 - .../templateString/gen_input_test.py | 4 - .../expressions/template string/input.sdstest | 12 - .../general/context different package.sdsstub | 4 - .../general/context different package.ttsl | 4 + ...context package with python module.sdsstub | 6 - .../context package with python module.ttsl | 4 + .../general/context same package.sdstest | 11 - .../imports/general/context same package.ttsl | 11 + .../imports/gen_context_same_package.py | 9 - .../imports/gen_context_same_package.py.map | 1 - .../tests/generator/imports/gen_input.py | 21 -- .../tests/generator/imports/gen_input.py.map | 1 - .../tests/generator/imports/gen_input_test.py | 4 - .../general/{input.sdstest => input.ttsl} | 4 +- .../context different package.sdsstub | 4 +- ...context package with python module.sdsstub | 6 +- .../tests/generator/wildcard/gen_input.py | 16 -- .../tests/generator/wildcard/gen_input.py.map | 1 - .../generator/wildcard/gen_input_test.py | 4 - .../generation/imports/wildcard/input.sdstest | 4 +- .../tests/generator/timeunit/gen_input.py.map | 2 +- .../generator/timeunit/gen_input_daytest.py | 4 + .../generator/timeunit/gen_input_monthtest.py | 4 + .../generator/timeunit/gen_input_weektest.py | 4 + .../generator/timeunit/gen_input_yeartest.py | 4 + .../generation/modifier/timeunit/input.ttsl | 8 +- .../gen_input.py | 10 - .../gen_input.py.map | 1 - .../gen_input_testPipeline.py | 4 - .../input.sdstest | 24 -- .../gen_input.py | 7 - .../gen_input.py.map | 1 - .../gen_input_testPipeline.py | 4 - .../input.sdstest | 15 -- .../partialImpureDependency/gen_input.py | 18 -- .../partialImpureDependency/gen_input.py.map | 1 - .../gen_input_testPipeline.py | 4 - .../partial/impure dependency/input.sdstest | 39 ---- .../partialPureDependency/gen_input.py | 28 --- .../partialPureDependency/gen_input.py.map | 1 - .../gen_input_testPipeline.py | 4 - .../partial/pure dependency/input.sdstest | 82 ------- .../partialRedundantImpurity/gen_input.py | 5 - .../partialRedundantImpurity/gen_input.py.map | 1 - .../gen_input_testPipeline.py | 4 - .../partial/redundant impurity/input.sdstest | 38 --- .../generated/special_module/gen_input.py | 4 - .../generated/special_module/gen_input.py.map | 1 - .../generation/python module/input.sdstest | 9 - .../callWithRunnerIntegration/gen_input.py | 57 ----- .../gen_input.py.map | 1 - .../gen_input_test.py | 4 - .../expressions/call/input.sdstest | 68 ------ .../general/context different package.sdsstub | 4 - ...context package with python module.sdsstub | 6 - .../general/context same package.sdstest | 11 - .../gen_context_same_package.py | 13 -- .../gen_context_same_package.py.map | 1 - .../importsWithRunnerIntegration/gen_input.py | 22 -- .../gen_input.py.map | 1 - .../gen_input_test.py | 4 - .../imports/general/input.sdstest | 25 -- .../context different package.sdsstub | 4 - ...context package with python module.sdsstub | 6 - .../gen_input.py | 17 -- .../gen_input.py.map | 1 - .../gen_input_test.py | 4 - .../imports/wildcard/input.sdstest | 18 -- .../gen_input.py | 39 ---- .../gen_input.py.map | 1 - .../gen_input_testPipeline.py | 4 - .../statements/assignment/input.sdstest | 34 --- .../statements/Loops/forLoop/input.ttsl | 9 + .../tests/generator/forEachLoop/gen_input.py | 37 +++ .../generator/forEachLoop/gen_input.py.map | 1 + .../forEachLoop/gen_input_myFunction.py | 4 + .../statements/Loops/foreachLoop/input.ttsl | 11 + .../tests/generator/whileLoop/gen_input.py | 7 + .../generator/whileLoop/gen_input.py.map | 1 + .../whileLoop/gen_input_myFunction.py | 4 + .../statements/Loops/whileLoop/input.ttsl | 8 + .../tests/generator/assignment/gen_input.py | 35 +-- .../generator/assignment/gen_input.py.map | 2 +- .../tests/generator/assignment/gen_input_f.py | 4 + .../tests/generator/assignment/gen_input_g.py | 4 + .../assignment/gen_input_testFunction.py | 4 + .../assignment/gen_input_testPipeline.py | 4 - .../statements/assignment/input.sdstest | 34 --- .../statements/assignment/input.ttsl | 8 + .../conditionalStatement/gen_input.py | 8 +- .../conditionalStatement/gen_input.py.map | 2 +- .../conditionalStatement}/gen_input_test.py | 0 .../gen_input_testPipeline.py | 4 - .../conditional statement/input.ttsl | 4 +- .../expressionStatement/gen_input.py | 15 +- .../expressionStatement/gen_input.py.map | 2 +- .../expressionStatement/gen_input_f.py | 4 + .../expressionStatement}/gen_input_test.py | 0 .../gen_input_testPipeline.py | 4 - .../expression statement/input.sdstest | 17 -- .../expression statement/input.ttsl | 8 + .../generator/utilityFunction/gen_input.py | 48 ++++ .../utilityFunction/gen_input.py.map | 1 + .../utilityFunction/gen_input_testFunction.py | 4 + .../generation/utilityFunctions/input.ttsl | 3 + .../bad-unclosed argument list.sdstest | 3 - .../good-empty argument list.sdstest | 3 - .../good-multiple arguments.sdstest | 3 - .../good-named argument.sdstest | 3 - .../good-no argument list.sdstest | 3 - .../good-positional argument.sdstest | 3 - .../bad-unclosed constraint list.sdstest | 3 - .../bad-unclosed parameter list.sdstest | 3 - .../annotations/good-annotation call.sdstest | 6 - .../good-no parameter list.sdstest | 3 - .../good-with constraint list.sdstest | 3 - .../good-with parameter list.sdstest | 3 - .../classes/attributes/good-annotated.sdstest | 5 - .../classes/attributes/good-no type.sdstest | 5 - .../classes/attributes/good-static.sdstest | 5 - .../classes/attributes/good-with type.sdstest | 5 - .../bad-empty parent type list.sdstest | 3 - .../classes/bad-unclosed body.sdstest | 3 - .../bad-unclosed constraint list.sdstest | 3 - .../bad-unclosed parameter list.sdstest | 3 - .../bad-unclosed type parameter list.sdstest | 3 - .../classes/good-annotation call.sdstest | 6 - .../classes/good-empty body.sdstest | 3 - .../declarations/classes/good-minimal.sdstest | 3 - .../good-multiple parent types.sdstest | 3 - .../classes/good-one parent type.sdstest | 3 - .../classes/good-with constraint list.sdstest | 3 - .../classes/good-with parameter list.sdstest | 3 - .../good-with type parameter list.sdstest | 3 - .../good-annotated instance method.sdstest | 6 - .../good-annotated static method.sdstest | 6 - .../methods/good-instance method.sdstest | 5 - .../methods/good-static method.sdstest | 5 - .../good-annotated nested class.sdstest | 6 - .../nested classes/good-nested-class.sdstest | 5 - .../good-annotated nested enum.sdstest | 8 - .../nested enums/good-nested enum.sdstest | 7 - .../constants/bad-missing name.ttsl | 2 +- .../constants/bad-missing type.ttsl | 2 +- .../constants/bad-missing value.ttsl | 2 +- .../constants/good-with type and value.ttsl | 2 +- .../constraints/bad-missing comma.sdstest | 6 - .../constraints/good-empty.sdstest | 3 - .../good-greater than constraint.sdstest | 5 - ...-greater than or equals constraint.sdstest | 5 - .../good-less than constraint.sdstest | 5 - ...ood-less than or equals constraint.sdstest | 5 - .../good-multiple constraints.sdstest | 6 - .../declarations/data/bad-missing name.ttsl | 2 +- .../declarations/data/bad-missing type.ttsl | 2 +- .../data/good-with type and name.ttsl | 2 +- .../enums/bad-unclosed body.sdstest | 3 - .../enums/good-annotation call.sdstest | 6 - .../enums/good-empty body.sdstest | 3 - .../declarations/enums/good-no body.sdstest | 3 - .../enums/good-variants in body.sdstest | 5 - .../bad-unclosed constraint list.sdstest | 5 - .../bad-unclosed parameter list.sdstest | 5 - .../variants/good-annotation call.sdstest | 6 - .../variants/good-no parameter list.sdstest | 5 - .../good-with constraint list.sdstest | 5 - .../variants/good-with parameter list.sdstest | 5 - .../functions/bad-missing functionbody.ttsl | 2 +- .../functions/bad-missing parameter list.ttsl | 2 +- .../functions/bad-missing parameter type.ttsl | 2 +- .../bad-unclosed parameter list.ttsl | 2 +- .../functions/bad-unclosed result list.ttsl | 2 +- .../functions/good-with parameter list.ttsl | 2 +- .../functions/good-with result list.ttsl | 2 +- .../good-with type parameter list.ttsl | 2 +- .../bad-const before annotation.sdstest | 3 - .../bad-double const modifier.sdstest | 3 - .../parameters/bad-missing comma.sdstest | 3 - .../parameters/bad-missing comma.ttsl | 3 + .../parameters/bad-missing type.ttsl | 3 + .../good-annotated parameter.sdstest | 3 - ...ood-const typed optional parameter.sdstest | 3 - ...ood-const typed required parameter.sdstest | 3 - ...d-const untyped optional parameter.sdstest | 3 - ...d-const untyped required parameter.sdstest | 3 - .../parameters/good-empty.sdstest | 3 - .../declarations/parameters/good-empty.ttsl | 3 + .../good-multiple parameters.sdstest | 13 -- .../good-typed optional parameter.sdstest | 3 - .../good-typed optional parameter.ttsl | 3 + .../good-typed required parameter.sdstest | 3 - .../good-typed required parameter.ttsl | 3 + .../good-untyped optional parameter.sdstest | 3 - .../good-untyped required parameter.sdstest | 3 - .../pipelines/bad-missing body.sdstest | 3 - .../pipelines/bad-unclosed body.sdstest | 3 - .../pipelines/good-annotation call.sdstest | 6 - .../pipelines/good-empty body.sdstest | 3 - .../pipelines/good-statements in body.sdstest | 5 - .../results/bad-missing comma.sdstest | 3 - .../results/bad-multiple results.ttsl | 3 + .../results/good-annotated result.sdstest | 3 - .../declarations/results/good-empty.sdstest | 3 - .../declarations/results/good-empty.ttsl | 3 + .../results/good-multiple results.sdstest | 7 - .../results/good-named result.ttsl | 3 + .../results/good-nameless result.ttsl | 3 + ...-one typed result (in parentheses).sdstest | 3 - ...-one typed result (no parentheses).sdstest | 3 - ...ne untyped result (no parentheses).sdstest | 3 - ... untyped result (with parentheses).sdstest | 3 - .../segments/bad-missing body.sdstest | 3 - .../bad-missing parameter list.sdstest | 3 - ... visibilities (internal, internal).sdstest | 3 - ...o visibilities (internal, private).sdstest | 3 - ...o visibilities (private, internal).sdstest | 3 - ...wo visibilities (private, private).sdstest | 3 - .../segments/bad-unclosed body.sdstest | 3 - .../bad-unclosed parameter list.sdstest | 3 - .../segments/bad-unclosed result list.sdstest | 3 - .../segments/good-annotation call.sdstest | 6 - .../segments/good-internal segment.sdstest | 3 - .../segments/good-private segment.sdstest | 3 - .../segments/good-statements in body.sdstest | 5 - .../good-with constraint list.sdstest | 3 - .../good-with parameter list and body.sdstest | 3 - .../segments/good-with result list.sdstest | 3 - .../type parameters/bad-missing comma.sdstest | 3 - .../good-annotated type parameter.sdstest | 3 - ...travariant optional type parameter.sdstest | 3 - ...travariant required type parameter.sdstest | 3 - ... covariant optional type parameter.sdstest | 3 - ... covariant required type parameter.sdstest | 3 - ... invariant optional type parameter.sdstest | 3 - ... invariant required type parameter.sdstest | 3 - .../type parameters/good-empty.sdstest | 3 - .../good-multiple type parameters.sdstest | 3 - ...travariant optional type parameter.sdstest | 3 - ...travariant required type parameter.sdstest | 3 - ... covariant optional type parameter.sdstest | 3 - ... covariant required type parameter.sdstest | 3 - ... invariant optional type parameter.sdstest | 3 - ... invariant required type parameter.sdstest | 3 - ...bad-addition without left operator.sdstest | 5 - .../bad-addition without left operator.ttsl | 5 + ...ad-addition without right operator.sdstest | 5 - .../bad-addition without right operator.ttsl | 5 + ...bad-division without left operator.sdstest | 5 - .../bad-division without left operator.ttsl | 5 + ...ad-division without right operator.sdstest | 5 - .../bad-division without right operator.ttsl | 5 + ...ltiplication without left operator.sdstest | 5 - ...-multiplication without left operator.ttsl | 5 + ...tiplication without right operator.sdstest | 5 - ...multiplication without right operator.ttsl | 5 + .../bad-negation without operator.sdstest | 5 - .../bad-negation without operator.ttsl | 5 + ...subtraction without right operator.sdstest | 5 - ...ad-subtraction without right operator.ttsl | 5 + .../good-addition.sdstest | 5 - .../arithmetic operators/good-addition.ttsl | 5 + .../good-complex example.sdstest | 5 - .../good-complex example.ttsl | 5 + .../good-division.sdstest | 5 - .../arithmetic operators/good-division.ttsl | 5 + .../good-multiplication.sdstest | 5 - .../good-multiplication.ttsl | 5 + .../good-negation.sdstest | 5 - .../arithmetic operators/good-negation.ttsl | 5 + .../good-subtraction.sdstest | 5 - .../good-subtraction.ttsl | 5 + .../block lambdas/bad-unclosed body.sdstest | 5 - .../bad-unclosed parameter list.sdstest | 5 - .../block lambdas/good-filled body.sdstest | 7 - .../good-with parameter list and body.sdstest | 5 - .../calls/bad-unclosed argument list.sdstest | 5 - .../calls/bad-unclosed argument list.ttsl | 5 + ...xed positional and named arguments.sdstest | 5 - ...-mixed positional and named arguments.ttsl | 5 + .../calls/good-named argument.sdstest | 5 - .../calls/good-named argument.ttsl | 5 + .../calls/good-no arguments.sdstest | 5 - .../expressions/calls/good-no arguments.ttsl | 5 + .../expressions/calls/good-null safe.sdstest | 5 - .../expressions/calls/good-null safe.ttsl | 5 + .../calls/good-positional argument.sdstest | 5 - .../calls/good-positional argument.ttsl | 5 + ...han or equal without left operator.sdstest | 5 - ...r than or equal without left operator.ttsl | 5 + ...an or equal without right operator.sdstest | 5 - ... than or equal without right operator.ttsl | 5 + ...greater than without left operator.sdstest | 5 - ...ad-greater than without left operator.ttsl | 5 + ...reater than without right operator.sdstest | 5 - ...d-greater than without right operator.ttsl | 5 + ...han or equal without left operator.sdstest | 5 - ...s than or equal without left operator.ttsl | 5 + ...an or equal without right operator.sdstest | 5 - ... than or equal without right operator.ttsl | 5 + ...ad-less than without left operator.sdstest | 5 - .../bad-less than without left operator.ttsl | 5 + ...d-less than without right operator.sdstest | 5 - .../bad-less than without right operator.ttsl | 5 + .../good-greater than or equal.sdstest | 5 - .../good-greater than or equal.ttsl | 5 + .../good-greater than.sdstest | 5 - .../good-greater than.ttsl | 5 + .../good-less than or equal.sdstest | 5 - .../good-less than or equal.ttsl | 5 + .../good-less than.sdstest | 5 - .../comparison operators/good-less than.ttsl | 5 + .../bad-without left operand.sdstest | 5 - .../bad-without left operand.ttsl | 5 + .../bad-without right operand.sdstest | 5 - .../bad-without right operand.ttsl | 5 + .../elvis operators/good-basic.sdstest | 5 - .../elvis operators/good-basic.ttsl | 5 + .../elvis operators/good-chained.sdstest | 5 - .../elvis operators/good-chained.ttsl | 5 + .../bad-equal without left operator.sdstest | 5 - .../bad-equal without left operator.ttsl | 5 + .../bad-equal without right operator.sdstest | 5 - .../bad-equal without right operator.ttsl | 5 + ...ad-identical without left operator.sdstest | 5 - .../bad-identical without left operator.ttsl | 5 + ...d-identical without right operator.sdstest | 5 - .../bad-identical without right operator.ttsl | 5 + ...ad-not equal without left operator.sdstest | 5 - .../bad-not equal without left operator.ttsl | 5 + ...d-not equal without right operator.sdstest | 5 - .../bad-not equal without right operator.ttsl | 5 + ...ot identical without left operator.sdstest | 5 - ...d-not identical without left operator.ttsl | 5 + ...t identical without right operator.sdstest | 5 - ...-not identical without right operator.ttsl | 5 + .../equality operators/good-equal.sdstest | 5 - .../equality operators/good-equal.ttsl | 5 + .../equality operators/good-identical.sdstest | 5 - .../equality operators/good-identical.ttsl | 5 + .../equality operators/good-not equal.sdstest | 5 - .../equality operators/good-not equal.ttsl | 5 + .../good-not identical.sdstest | 5 - .../good-not identical.ttsl | 5 + .../bad-missing body.sdstest | 5 - .../bad-unclosed parameter list.sdstest | 5 - ...with parameter list and expression.sdstest | 5 - .../good-complex chained expression.sdstest | 5 - .../expressions/good-reference.sdstest | 5 - .../grammar/expressions/good-reference.ttsl | 5 + .../indexed accesses/bad-no index.sdstest | 5 - .../indexed accesses/bad-no index.ttsl | 5 + .../bad-unclosed square bracket.sdstest | 5 - .../bad-unclosed square bracket.ttsl | 5 + .../good-literal index.sdstest | 5 - .../indexed accesses/good-literal index.ttsl | 5 + .../indexed accesses/good-null safe.sdstest | 5 - .../indexed accesses/good-null safe.ttsl | 5 + .../good-reference index.sdstest | 5 - .../good-reference index.ttsl | 5 + .../lists/bad-unclosed square bracket.sdstest | 5 - .../lists/bad-unclosed square bracket.ttsl | 5 + .../good-nested multiple elements.sdstest | 5 - .../lists/good-nested multiple elements.ttsl | 5 + .../lists/good-nested one element.sdstest | 5 - .../lists/good-nested one element.ttsl | 5 + .../good-one level multiple elements.sdstest | 5 - .../good-one level multiple elements.ttsl | 5 + .../lists/good-one level one element.sdstest | 5 - .../lists/good-one level one element.ttsl | 5 + .../float/bad-no digits before dot.sdstest | 5 - .../float/bad-no digits before dot.ttsl | 5 + ...xample.sdstest => good-basic example.ttsl} | 4 +- ...ientific notation with lowercase e.sdstest | 8 - ...-scientific notation with lowercase e.ttsl | 8 + ...ientific notation with uppercase e.sdstest | 8 - ...-scientific notation with uppercase e.ttsl | 8 + .../expressions/literals/good-false.sdstest | 5 - .../expressions/literals/good-false.ttsl | 5 + .../expressions/literals/good-null.sdstest | 5 - .../expressions/literals/good-null.ttsl | 5 + .../expressions/literals/good-true.sdstest | 5 - .../expressions/literals/good-true.ttsl | 5 + .../literals/int/good-leading zero.sdstest | 5 - .../literals/int/good-leading zero.ttsl | 5 + .../literals/int/good-multiple digits.sdstest | 5 - .../literals/int/good-multiple digits.ttsl | 5 + .../literals/int/good-one digit.sdstest | 5 - .../literals/int/good-one digit.ttsl | 5 + .../bad-single quotes as delimiters.sdstest | 5 - .../bad-single quotes as delimiters.ttsl | 5 + .../string/bad-unclosed quote.sdstest | 5 - .../literals/string/bad-unclosed quote.ttsl | 5 + .../string/good-basic content.sdstest | 5 - .../literals/string/good-basic content.ttsl | 5 + ...sing template expression delimiter.sdstest | 5 - ...closing template expression delimiter.ttsl | 5 + ...od-curly braces separated by space.sdstest | 5 - .../good-curly braces separated by space.ttsl | 5 + .../literals/string/good-empty.sdstest | 5 - .../literals/string/good-empty.ttsl | 5 + .../string/good-escaped curly brace.sdstest | 5 - .../string/good-escaped curly brace.ttsl | 5 + ...lines.sdstest => good-multiple lines.ttsl} | 4 +- .../good-newline escape sequence.sdstest | 5 - .../string/good-newline escape sequence.ttsl | 5 + .../string/good-single curly brace.sdstest | 5 - .../string/good-single curly brace.ttsl | 5 + .../literals/string/good-single quote.sdstest | 5 - .../literals/string/good-single quote.ttsl | 5 + .../good-unicode escape sequence.sdstest | 5 - .../string/good-unicode escape sequence.ttsl | 5 + ...-conjunction without left operator.sdstest | 5 - ...bad-conjunction without left operator.ttsl | 5 + ...conjunction without right operator.sdstest | 5 - ...ad-conjunction without right operator.ttsl | 5 + ...-disjunction without left operator.sdstest | 5 - ...bad-disjunction without left operator.ttsl | 5 + ...disjunction without right operator.sdstest | 5 - ...ad-disjunction without right operator.ttsl | 5 + .../bad-negation without operator.sdstest | 5 - .../bad-negation without operator.ttsl | 5 + .../good-complex example.sdstest | 5 - .../good-complex example.ttsl | 5 + .../good-conjunction.sdstest | 5 - .../logical operations/good-conjunction.ttsl | 5 + .../good-disjunction.sdstest | 5 - .../logical operations/good-disjunction.ttsl | 5 + .../logical operations/good-negation.sdstest | 5 - .../logical operations/good-negation.ttsl | 5 + .../expressions/maps/bad-no colon.sdstest | 5 - .../expressions/maps/bad-no colon.ttsl | 5 + .../expressions/maps/bad-no key.sdstest | 5 - .../grammar/expressions/maps/bad-no key.ttsl | 5 + .../expressions/maps/bad-no value.sdstest | 5 - .../expressions/maps/bad-no value.ttsl | 5 + .../maps/bad-unclosed curly brace.sdstest | 5 - .../maps/bad-unclosed curly brace.ttsl | 5 + ...est => good-nested multiple elements.ttsl} | 4 +- ...t.sdstest => good-nested one element.ttsl} | 4 +- .../good-one level multiple elements.sdstest | 5 - .../good-one level multiple elements.ttsl | 5 + .../maps/good-one level one element.sdstest | 5 - .../maps/good-one level one element.ttsl | 5 + .../member accesses/bad-no receiver.sdstest | 5 - .../member accesses/good-not nullable.sdstest | 5 - .../member accesses/good-nullable.sdstest | 5 - .../bad-unclosed parenthesis.sdstest | 5 - .../good-nested.sdstest | 5 - .../good-one level.sdstest | 5 - ...ate string with invalid expression.sdstest | 5 - ...mplate string with invalid expression.ttsl | 5 + .../bad-unclosed template expression.sdstest | 5 - .../bad-unclosed template expression.ttsl | 5 + .../good-empty template expression.sdstest | 5 - .../good-empty template expression.ttsl | 5 + ...plate string with basic expression.sdstest | 5 - ...template string with basic expression.ttsl | 5 + .../type casts/bad-without expression.sdstest | 5 - .../type casts/bad-without type.sdstest | 5 - .../expressions/type casts/good-basic.sdstest | 5 - .../type casts/good-chained.sdstest | 5 - .../keywords as names/bad-unescaped _.sdstest | 3 - .../bad-unescaped and.sdstest | 3 - .../keywords as names/bad-unescaped and.ttsl | 3 + .../bad-unescaped annotation.sdstest | 3 - .../bad-unescaped as.sdstest | 3 - .../keywords as names/bad-unescaped as.ttsl | 3 + .../bad-unescaped attr.sdstest | 3 - .../bad-unescaped class.sdstest | 3 - .../bad-unescaped const.sdstest | 3 - .../bad-unescaped constant.ttsl | 3 + .../bad-unescaped enum.sdstest | 3 - .../bad-unescaped false.sdstest | 3 - .../bad-unescaped false.ttsl | 3 + .../bad-unescaped fun.sdstest | 3 - .../bad-unescaped function.ttsl | 3 + .../bad-unescaped import.sdstest | 3 - .../bad-unescaped import.ttsl | 3 + .../bad-unescaped in.sdstest | 3 - .../bad-unescaped internal.sdstest | 3 - .../bad-unescaped literal.sdstest | 3 - .../bad-unescaped not.sdstest | 3 - .../keywords as names/bad-unescaped not.ttsl | 3 + .../bad-unescaped null.sdstest | 3 - .../keywords as names/bad-unescaped null.ttsl | 3 + .../bad-unescaped or.sdstest | 3 - .../keywords as names/bad-unescaped or.ttsl | 3 + .../bad-unescaped out.sdstest | 3 - .../bad-unescaped package.sdstest | 3 - .../bad-unescaped package.ttsl | 3 + .../bad-unescaped pipeline.sdstest | 3 - .../bad-unescaped private.sdstest | 3 - .../bad-unescaped private.ttsl | 3 + .../bad-unescaped schema.sdstest | 3 - .../bad-unescaped segment.sdstest | 3 - .../bad-unescaped static.sdstest | 3 - .../bad-unescaped sub.sdstest | 3 - .../bad-unescaped true.sdstest | 3 - .../keywords as names/bad-unescaped true.ttsl | 3 + .../bad-unescaped union.sdstest | 3 - .../bad-unescaped val.sdstest | 3 - .../keywords as names/bad-unescaped var.ttsl | 3 + .../bad-unescaped where.sdstest | 3 - .../bad-unescaped yield.sdstest | 3 - .../good-escapedKeywords.sdstest | 31 --- .../good-escapedKeywords.ttsl | 16 ++ .../good-escapedNonKeyword.sdstest | 3 - .../good-escapedNonKeyword.ttsl | 3 + ...-annotation call after declaration.sdstest | 5 - .../bad-annotation call after import.sdstest | 5 - ...annotation call after package name.sdstest | 5 - ...ll between package name and import.sdstest | 7 - ...dstest => bad-duplicate package name.ttsl} | 2 +- .../bad-import after declaration.sdstest | 5 - .../modules/bad-import after declaration.ttsl | 5 + ...t => bad-import without declarations.ttsl} | 2 +- .../bad-import without package.sdstest | 3 - .../modules/bad-import without package.ttsl | 3 + ...bad-package name after declaration.sdstest | 5 - .../bad-package name after declaration.ttsl | 5 + ...est => bad-package name after import.ttsl} | 2 +- ...od-annotation call and declaration.sdstest | 5 - ...on call and import and declaration.sdstest | 7 - .../good-annotation call and import.sdstest | 5 - ...l and package name and declaration.sdstest | 7 - ...ge name and import and declaration.sdstest | 9 - ...n call and package name and import.sdstest | 7 - ...d-annotation call and package name.sdstest | 5 - .../modules/good-annotation call.sdstest | 3 - ...-annotation calls and declarations.sdstest | 7 - ...calls and imports and declarations.sdstest | 12 - .../good-annotation calls and imports.sdstest | 9 - ... and package name and declarations.sdstest | 9 - ... name and imports and declarations.sdstest | 14 -- ...calls and package name and imports.sdstest | 11 - ...-annotation calls and package name.sdstest | 6 - .../modules/good-annotation calls.sdstest | 4 - .../grammar/modules/good-declaration.sdstest | 3 - .../grammar/modules/good-declaration.ttsl | 3 + .../grammar/modules/good-declarations.sdstest | 4 - .../grammar/modules/good-declarations.ttsl | 4 + .../grammar/modules/good-empty.sdstest | 1 - .../resources/grammar/modules/good-empty.ttsl | 1 + .../good-import and declaration.sdstest | 5 - .../modules/good-import and declaration.ttsl | 5 + .../grammar/modules/good-import.sdstest | 3 - .../grammar/modules/good-import.ttsl | 3 + .../good-imports and declarations.sdstest | 9 - .../good-imports and declarations.ttsl | 9 + .../grammar/modules/good-imports.sdstest | 6 - .../grammar/modules/good-imports.ttsl | 6 + .../good-package name and declaration.sdstest | 5 - .../good-package name and declaration.ttsl | 5 + ...good-package name and declarations.sdstest | 6 - .../good-package name and declarations.ttsl | 6 + ...ge name and import and declaration.sdstest | 7 - ...ckage name and import and declaration.ttsl | 8 + .../good-package name and import.sdstest | 5 - .../modules/good-package name and import.ttsl | 5 + ... name and imports and declarations.sdstest | 11 - ...age name and imports and declarations.ttsl | 12 + .../good-package name and imports.sdstest | 8 - .../good-package name and imports.ttsl | 8 + .../grammar/modules/good-package name.sdstest | 3 - .../grammar/modules/good-package name.ttsl | 3 + .../schema/bad-no name (colon).sdstest | 5 - .../schema/bad-no name (no colon).sdstest | 5 - .../schema/bad-no type (colon).sdstest | 5 - .../schema/bad-no type (no colon).sdstest | 5 - .../schema/bad-switched name and type.sdstest | 5 - .../schema/bad-unclosed curly brace.sdstest | 3 - .../schema/good-annotation call.sdstest | 6 - .../grammar/schema/good-empty schema.sdstest | 3 - .../grammar/schema/good-one column.sdstest | 5 - .../grammar/schema/good-two columns.sdstest | 6 - ...-in block lambda without assignees.sdstest | 7 - ...in block lambda without expression.sdstest | 7 - ...-in block lambda without semicolon.sdstest | 7 - .../bad-in function without assignees.ttsl | 5 + .../bad-in function without expression.ttsl | 5 + .../bad-in pipeline without assignees.sdstest | 5 - ...bad-in pipeline without expression.sdstest | 5 - .../bad-in pipeline without semicolon.sdstest | 5 - .../bad-in segment without assignees.sdstest | 5 - .../bad-in segment without expression.sdstest | 5 - .../bad-in segment without semicolon.sdstest | 5 - .../assignments/good-in block lambda.sdstest | 8 - .../assignments/good-in function.ttsl | 5 + .../assignments/good-in pipeline.sdstest | 6 - .../assignments/good-in segment.sdstest | 6 - ...ad-empty statement in block lambda.sdstest | 7 - .../bad-empty statement in pipeline.sdstest | 5 - .../bad-empty statement in pipeline.ttsl | 5 + .../bad-empty statement in segment.sdstest | 5 - .../bad-with else missing elseblock.ttsl | 2 +- .../bad-without else missing block.ttsl | 2 +- .../bad-without else missing condition.ttsl | 2 +- .../good-with else false.ttsl | 2 +- .../good-with else true.ttsl | 2 +- .../good-without else.ttsl | 2 +- ...-in block lambda without semicolon.sdstest | 7 - .../bad-in function without semicolon.ttsl | 5 + .../bad-in pipeline without semicolon.sdstest | 5 - .../bad-in segment without semicolon.sdstest | 5 - .../good-in block lambda.sdstest | 7 - .../good-in function.ttsl | 5 + .../good-in pipeline.sdstest | 5 - .../good-in segment.sdstest | 5 - .../loops/for loops/bad-missing body.ttsl | 5 + .../for loops/bad-missing condition.ttsl | 7 + .../for loops/bad-missing semicolon.ttsl | 7 + .../loops/for loops/good-in function.ttsl | 7 + .../loops/foreach loops/bad-missing body.ttsl | 5 + .../foreach loops/bad-missing element.ttsl | 7 + .../loops/foreach loops/bad-missing list.ttsl | 7 + .../foreach loops/good- in function.ttsl | 7 + .../loops/while loops/bad-missing body.ttsl | 5 + .../while loops/bad-missing condition.ttsl | 7 + .../loops/while loops/good-in function.ttsl | 7 + ...d-argument list of annotation call.sdstest | 3 - .../good-argument list of call.sdstest | 5 - .../good-argument list of call.ttsl | 5 + ...list of assignment in block lambda.sdstest | 7 - .../good-assignee list of assignment.sdstest | 5 - .../good-column list of schema.sdstest | 6 - ...good-constraint list of annotation.sdstest | 6 - .../good-constraint list of class.sdstest | 6 - ...od-constraint list of enum variant.sdstest | 8 - .../good-constraint list of function.sdstest | 6 - .../good-elements of list.sdstest | 5 - .../good-elements of list.ttsl | 5 + .../good-entries of map.sdstest | 5 - .../trailing commas/good-entries of map.ttsl | 5 + ...claration list of qualified import.sdstest | 4 - ... declaration list of qualified import.ttsl | 3 + .../good-literal list of literal type.sdstest | 5 - .../good-parameter list of annotation.sdstest | 6 - ...ood-parameter list of block lambda.sdstest | 5 - ...od-parameter list of callable type.sdstest | 5 - .../good-parameter list of class.sdstest | 3 - ...ood-parameter list of enum variant.sdstest | 8 - ...arameter list of expression lambda.sdstest | 5 - .../good-parameter list of function.sdstest | 6 - .../good-parameter list of function.ttsl | 6 + .../good-parameter list of segment.sdstest | 6 - .../good-parent type list of class.sdstest | 3 - .../good-result list of callable type.sdstest | 5 - .../good-result list of function.sdstest | 6 - .../good-result list of segment.sdstest | 6 - ...d-type argument list of named type.sdstest | 5 - ...d-type argument list of union type.sdstest | 5 - .../good-type parameter list of class.sdstest | 3 - ...od-type parameter list of function.sdstest | 3 - .../callable types/bad-missing arrow.sdstest | 5 - .../bad-missing parameter list.sdstest | 5 - .../bad-missing result list.sdstest | 5 - .../bad-unclosed parameter list.sdstest | 5 - .../bad-unclosed result list.sdstest | 5 - ...od-with parameter and result lists.sdstest | 5 - .../resources/grammar/types/good-Boolean.ttsl | 5 + .../grammar/types/good-Dictionary.ttsl | 5 + .../resources/grammar/types/good-Float.ttsl | 5 + .../resources/grammar/types/good-Int.ttsl | 5 + .../resources/grammar/types/good-List.ttsl | 5 + .../resources/grammar/types/good-String.ttsl | 5 + .../types/literal types/bad-nested.sdstest | 5 - .../literal types/bad-no literal list.sdstest | 5 - .../bad-unclosed angle bracket.sdstest | 5 - .../types/literal types/good-empty.sdstest | 5 - .../good-with list literal.sdstest | 5 - .../literal types/good-with literals.sdstest | 5 - .../good-with map literal.sdstest | 5 - .../bad-callable type as member.sdstest | 5 - .../bad-literal type as member.sdstest | 5 - .../member types/bad-missing member.sdstest | 5 - .../member types/bad-missing receiver.sdstest | 5 - .../bad-unclosed angle bracket.sdstest | 5 - .../bad-union type as member.sdstest | 5 - .../good-long complex chain.sdstest | 5 - ...allable) and member (not nullable).sdstest | 5 - ...r (callable) and member (nullable).sdstest | 5 - ...literal) and member (not nullable).sdstest | 5 - ...er (literal) and member (nullable).sdstest | 5 - ...ullable) and member (not nullable).sdstest | 5 - ...ot nullable) and member (nullable).sdstest | 5 - ...ullable) and member (not nullable).sdstest | 5 - ...d, nullable) and member (nullable).sdstest | 5 - ... (union) and member (not nullable).sdstest | 5 - ...iver (union) and member (nullable).sdstest | 5 - .../bad-unclosed angle bracket.sdstest | 5 - ...no type arguments and not nullable.sdstest | 5 - ...ood-no type arguments and nullable.sdstest | 5 - .../good-type argument and nullable.sdstest | 5 - ...od-type arguments and not nullable.sdstest | 5 - .../bad-unclosed angle bracket.sdstest | 5 - .../types/union types/good-empty.sdstest | 5 - .../types/union types/good-nested.sdstest | 5 - .../good-with type arguments.sdstest | 5 - .../listSafeDsFiles/nested/test file.sdstest | 0 .../listSafeDsFiles/not a safe-ds file.txt | 0 .../listSafeDsFiles/pipeline file.sdspipe | 0 .../skip pipeline file.sdspipe | 0 .../listSafeDsFiles/skip stub file.sdsstub | 0 .../listSafeDsFiles/skip test file.sdstest | 0 .../helpers/listSafeDsFiles/stub file.sdsstub | 0 .../helpers/listSafeDsFiles/test file.sdstest | 0 .../function file.ttsl} | 0 .../nested/function file.ttsl} | 0 .../nested/not a ttsl file.txt} | 0 .../nested/skip function file.tts} | 0 .../not a ttsl file.txt} | 0 .../skip function file.ttsl} | 0 .../base cases/block lambdas/main.sdstest | 4 +- .../base cases/boolean literals/main.sdstest | 6 +- .../base cases/classes/main.sdstest | 2 +- .../base cases/enum variants/main.sdstest | 2 +- .../expression lambdas/main.sdstest | 4 +- .../base cases/float literals/main.sdstest | 6 +- .../base cases/functions/main.sdstest | 2 +- .../base cases/int literals/main.sdstest | 4 +- .../base cases/null literals/main.sdstest | 4 +- .../base cases/segments/main.sdstest | 2 +- .../main.sdstest | 6 +- .../invalid nodes/main.sdstest | 2 +- .../recursive cases/arguments/main.sdstest | 6 +- .../block lambda results/main.sdstest | 10 +- .../assignees/placeholders/main.sdstest | 10 +- .../assignees/wildcards/main.sdstest | 10 +- .../assignees/yields/main.sdstest | 8 +- .../calls/of block lambdas/closure.sdstest | 4 +- .../calls/of block lambdas/main.sdstest | 4 +- ...ameter value used as default value.sdstest | 4 +- .../calls/of classes/main.sdstest | 4 +- .../calls/of enum variants/main.sdstest | 20 +- .../of expression lambdas/closure.sdstest | 4 +- .../calls/of expression lambdas/main.sdstest | 4 +- ...ameter value used as default value.sdstest | 4 +- .../calls/of functions/main.sdstest | 4 +- .../calls/of segments/main.sdstest | 4 +- ...ameter value used as default value.sdstest | 4 +- .../calls/of unknown parameter/main.sdstest | 2 +- .../calls/on null/main.sdstest | 4 +- .../calls/recursion/main.sdstest | 2 +- .../calls/unresolved/main.sdstest | 6 +- .../indexed access/on lists/main.sdstest | 16 +- .../indexed access/on maps/main.sdstest | 16 +- .../indexed access/on null/main.sdstest | 6 +- .../indexed access/on other/main.sdstest | 6 +- .../infix operations/and/main.sdstest | 18 +- .../and/short circuiting.sdstest | 14 +- .../infix operations/divided by/main.sdstest | 24 +- .../infix operations/elvis/main.sdstest | 14 +- .../elvis/short circuiting.sdstest | 14 +- .../infix operations/equals/main.sdstest | 10 +- .../greater than or equals/main.sdstest | 26 +-- .../greater than/main.sdstest | 26 +-- .../identical to/main.sdstest | 10 +- .../less than or equals/main.sdstest | 26 +-- .../infix operations/less than/main.sdstest | 26 +-- .../infix operations/minus/main.sdstest | 18 +- .../infix operations/not equals/main.sdstest | 10 +- .../not identical to/main.sdstest | 10 +- .../infix operations/or/main.sdstest | 18 +- .../or/short circuiting.sdstest | 14 +- .../infix operations/plus/main.sdstest | 18 +- .../infix operations/times/main.sdstest | 18 +- .../recursive cases/lists/main.sdstest | 6 +- .../recursive cases/maps/main.sdstest | 6 +- .../recursive cases/parameters/main.sdstest | 8 +- .../parenthesized expressions/main.sdstest | 10 +- .../prefix operations/minus/main.sdstest | 10 +- .../prefix operations/not/main.sdstest | 10 +- .../recursive cases/references/main.sdstest | 6 +- .../recursive cases/results/main.sdstest | 8 +- .../template strings/main.sdstest | 8 +- .../recursive cases/type casts/main.sdstest | 6 +- ...ain no imports or own declarations.sdstest | 12 +- ... with imports and own declarations.sdstest | 16 +- ...with multiple imports of same name.sdstest | 4 +- ...n with qualified import with alias.sdstest | 18 +- .../main with qualified import.sdstest | 16 +- .../main with wildcard import.sdstest | 12 +- .../resource other package.sdstest | 8 +- .../resource safeds package.sdstest | 4 +- .../resource same package.sdstest | 4 +- .../resource without package.sdstest | 4 +- .../on annotation/main.sdstest | 12 +- .../on attribute/main.sdstest | 12 +- .../annotation calls/on class/main.sdstest | 12 +- .../on enum variant/main.sdstest | 12 +- .../annotation calls/on enum/main.sdstest | 12 +- .../annotation calls/on function/main.sdstest | 12 +- .../annotation calls/on module/main.sdstest | 8 +- .../on parameter/main.sdstest | 18 +- .../annotation calls/on pipeline/main.sdstest | 14 +- .../annotation calls/on result/main.sdstest | 12 +- .../annotation calls/on segment/main.sdstest | 12 +- .../on type parameter/main.sdstest | 12 +- .../to parameter/main.sdstest | 14 +- .../main.sdstest | 4 +- .../unresolved/main.sdstest | 6 +- .../to parameter of annotation/main.sdstest | 20 +- .../to parameter of block lambda/main.sdstest | 14 +- .../main.sdstest | 18 +- .../to parameter of class/main.sdstest | 20 +- .../to parameter of enum variant/main.sdstest | 20 +- .../main.sdstest | 14 +- .../to parameter of function/main.sdstest | 20 +- .../to parameter of segment/main.sdstest | 20 +- .../main.sdstest | 4 +- .../of calls/unresolved/main.sdstest | 6 +- .../with nullable receiver/main.sdstest | 18 +- .../to annotations/main.sdstest | 16 +- .../resource first package.sdstest | 4 +- .../resource second package.sdstest | 8 +- .../to global classes/main.sdstest | 16 +- .../resource first package.sdstest | 4 +- .../resource second package.sdstest | 8 +- .../to global enums/main.sdstest | 16 +- .../resource first package.sdstest | 4 +- .../resource second package.sdstest | 8 +- .../to global functions/main.sdstest | 16 +- .../resource first package.sdstest | 4 +- .../resource second package.sdstest | 8 +- .../to nested declaration/main.sdstest | 16 +- .../resource first package.sdstest | 4 +- .../resource second package.sdstest | 8 +- .../to pipelines/main.sdstest | 16 +- .../resource first package.sdstest | 4 +- .../resource second package.sdstest | 8 +- .../to schemas/main.sdstest | 16 +- .../to schemas/resource first package.sdstest | 4 +- .../resource second package.sdstest | 8 +- .../to segments/main.sdstest | 26 +-- .../resource first package.sdstest | 4 +- .../to segments/resource same package.sdstest | 6 +- .../resource second package.sdstest | 12 +- .../unresolved/main.sdstest | 2 +- ...ain no imports or own declarations.sdstest | 10 +- ... with imports and own declarations.sdstest | 14 +- ...with multiple imports of same name.sdstest | 2 +- ...n with qualified import with alias.sdstest | 16 +- .../main with qualified import.sdstest | 14 +- .../main with wildcard import.sdstest | 10 +- .../resource other package.sdstest | 8 +- .../resource safeds package.sdstest | 4 +- .../resource same package.sdstest | 4 +- .../resource without package.sdstest | 4 +- ...ain no imports or own declarations.sdstest | 10 +- ... with imports and own declarations.sdstest | 14 +- ...with multiple imports of same name.sdstest | 2 +- ...n with qualified import with alias.sdstest | 16 +- .../main with qualified import.sdstest | 14 +- .../main with wildcard import.sdstest | 10 +- .../resource other package.sdstest | 8 +- .../resource safeds package.sdstest | 4 +- .../resource same package.sdstest | 4 +- .../resource without package.sdstest | 4 +- .../main.sdstest | 60 ++--- .../main.sdstest | 22 +- .../main.sdstest | 22 +- .../to global classes/main.sdstest | 10 +- .../in same file/to global enums/main.sdstest | 10 +- .../to nested classes/main.sdstest | 14 +- .../in same file/to nested enums/main.sdstest | 14 +- .../main.sdstest | 2 +- .../main.sdstest | 10 +- .../in global classes/main.sdstest | 30 +-- .../in global functions/main.sdstest | 28 +-- .../in methods/main.sdstest | 56 ++--- .../in nested classes/main.sdstest | 62 ++--- .../in annotation/main.sdstest | 12 +- .../main.sdstest | 14 +- .../in global class/main.sdstest | 12 +- .../in global function/main.sdstest | 12 +- .../parameter bounds/in method/main.sdstest | 22 +- .../in nested class/main.sdstest | 22 +- .../parameter bounds/in segment/main.sdstest | 12 +- ...ain no imports or own declarations.sdstest | 12 +- ... with imports and own declarations.sdstest | 16 +- ...with multiple imports of same name.sdstest | 4 +- ...n with qualified import with alias.sdstest | 18 +- .../main with qualified import.sdstest | 14 +- .../main with wildcard import.sdstest | 12 +- .../resource other package.sdstest | 6 +- .../resource safeds package.sdstest | 4 +- .../resource same package.sdstest | 4 +- .../resource without package.sdstest | 4 +- ...ain no imports or own declarations.sdstest | 12 +- ... with imports and own declarations.sdstest | 16 +- ...with multiple imports of same name.sdstest | 4 +- ...n with qualified import with alias.sdstest | 18 +- .../main with qualified import.sdstest | 14 +- .../main with wildcard import.sdstest | 12 +- .../resource other package.sdstest | 6 +- .../resource safeds package.sdstest | 4 +- .../resource same package.sdstest | 4 +- .../resource without package.sdstest | 4 +- ...ain no imports or own declarations.sdstest | 12 +- ... with imports and own declarations.sdstest | 16 +- ...with multiple imports of same name.sdstest | 4 +- ...n with qualified import with alias.sdstest | 18 +- .../main with qualified import.sdstest | 14 +- .../main with wildcard import.sdstest | 12 +- .../resource other package.sdstest | 6 +- .../resource safeds package.sdstest | 4 +- .../resource same package.sdstest | 4 +- .../resource without package.sdstest | 4 +- ...ain no imports or own declarations.sdstest | 12 +- ... with imports and own declarations.sdstest | 16 +- ...with multiple imports of same name.sdstest | 4 +- ...n with qualified import with alias.sdstest | 18 +- .../main with qualified import.sdstest | 14 +- .../main with wildcard import.sdstest | 12 +- .../resource other package.sdstest | 6 +- .../resource safeds package.sdstest | 4 +- .../resource same package.sdstest | 4 +- .../resource without package.sdstest | 4 +- ...ain no imports or own declarations.sdstest | 10 +- ... with imports and own declarations.sdstest | 14 +- ...with multiple imports of same name.sdstest | 2 +- ...n with qualified import with alias.sdstest | 16 +- .../main with qualified import.sdstest | 12 +- .../main with wildcard import.sdstest | 10 +- .../resource other package.sdstest | 6 +- .../resource safeds package.sdstest | 4 +- .../resource same package.sdstest | 4 +- .../resource without package.sdstest | 4 +- ...ain no imports or own declarations.sdstest | 12 +- ... with imports and own declarations.sdstest | 16 +- ...with multiple imports of same name.sdstest | 4 +- ...n with qualified import with alias.sdstest | 18 +- .../main with qualified import.sdstest | 14 +- .../main with wildcard import.sdstest | 12 +- .../to schemas/resource other package.sdstest | 6 +- .../resource safeds package.sdstest | 4 +- .../to schemas/resource same package.sdstest | 4 +- .../resource without package.sdstest | 4 +- ...ain no imports or own declarations.sdstest | 28 +-- ... with imports and own declarations.sdstest | 32 +-- ...with multiple imports of same name.sdstest | 4 +- ...n with qualified import with alias.sdstest | 34 +-- .../main with qualified import.sdstest | 30 +-- .../main with wildcard import.sdstest | 28 +-- .../resource other package.sdstest | 10 +- .../resource safeds package.sdstest | 8 +- .../to segments/resource same package.sdstest | 8 +- .../resource without package.sdstest | 8 +- .../in same file/to annotations/main.sdstest | 8 +- .../from outside/main.sdstest | 4 +- .../of containing block lambda/main.sdstest | 4 +- .../to class members/main.sdstest | 14 +- .../in same file/to constants/main.ttsl | 8 +- .../to containing declarations/main.sdstest | 60 ++--- .../to enum variants/main.sdstest | 4 +- .../in same file/to functions/main.ttsl | 8 +- .../to global classes/main.sdstest | 10 +- .../in same file/to global enums/main.sdstest | 10 +- .../to global functions/main.sdstest | 10 +- .../in same file/to modules/main.sdstest | 4 +- .../main.sdstest | 64 ++--- .../to parameters/from outside/main.sdstest | 16 +- .../from parameter bound/main.sdstest | 24 +- .../of containing block lambda/main.sdstest | 44 ++-- .../main.sdstest | 38 +-- .../of containing segment/main.sdstest | 24 +- .../in same file/to pipelines/main.sdstest | 8 +- .../to placeholders/from outside/main.sdstest | 10 +- .../of containing block lambda/main.sdstest | 74 +++--- .../of containing function/main.ttsl | 8 +- .../of containing pipeline/main.sdstest | 36 +-- .../of containing segment/main.sdstest | 34 +-- .../to redeclared module member/main.sdstest | 8 +- .../to results/from outside/main.sdstest | 6 +- .../of containing segment/main.sdstest | 2 +- .../in same file/to schemas/main.sdstest | 8 +- .../in same file/to segments/main.sdstest | 24 +- .../to type parameters/main.sdstest | 4 +- .../references/unresolved/main.sdstest | 2 +- .../main.sdstest | 2 +- .../main.sdstest | 26 +-- .../main.sdstest | 4 +- .../main.sdstest | 4 +- .../type arguments/to unresolved/main.sdstest | 4 +- .../scoping/yields/in pipeline/main.sdstest | 10 +- .../scoping/yields/in segment/main.sdstest | 16 +- .../block lambda results/main.sdstest | 23 -- .../assignees/placeholders/main.sdstest | 21 -- .../typing/assignees/placeholders/main.ttsl | 7 + .../typing/assignees/yields/main.sdstest | 21 -- .../declarations/annotations/main.sdstest | 10 - .../declarations/attributes/main.sdstest | 17 -- .../typing/declarations/classes/main.sdstest | 7 - .../declarations/enum variants/main.sdstest | 9 - .../typing/declarations/enums/main.sdstest | 7 - .../declarations/functions/main.sdstest | 16 -- .../typing/declarations/functions/main.ttsl | 13 ++ .../parameters/of annotations/main.sdstest | 8 - .../that are isolated/main.sdstest | 6 - .../that are passed as arguments/main.sdstest | 26 --- .../main.sdstest | 17 -- .../that are yielded/main.sdstest | 17 -- .../with manifest types/main.sdstest | 7 - .../parameters/of callable types/main.sdstest | 8 - .../parameters/of classes/main.sdstest | 8 - .../parameters/of enum variants/main.sdstest | 10 - .../that are isolated/main.sdstest | 6 - .../that are passed as arguments/main.sdstest | 26 --- .../main.sdstest | 17 -- .../that are yielded/main.sdstest | 17 -- .../with manifest types/main.sdstest | 7 - .../parameters/of functions/main.sdstest | 6 +- .../parameters/of segments/main.sdstest | 8 - .../declarations/pipelines/main.sdstest | 4 - .../typing/declarations/results/main.sdstest | 14 -- .../typing/declarations/results/main.ttsl | 4 + .../typing/declarations/segments/main.sdstest | 16 -- .../declarations/type parameters/main.sdstest | 5 - .../typing/expressions/arguments/main.sdstest | 40 ---- .../that are isolated/main.sdstest | 15 -- .../that are passed as arguments/main.sdstest | 46 ---- .../main.sdstest | 37 --- .../that are yielded/main.sdstest | 24 -- .../with manifest types/main.sdstest | 14 -- .../calls/of annotations/main.sdstest | 11 - .../calls/of block lambdas/main.sdstest | 25 -- .../calls/of callable types/main.sdstest | 18 -- .../expressions/calls/of classes/main.sdstest | 17 -- .../calls/of enum variants/main.sdstest | 82 ------- .../calls/of expression lambdas/main.sdstest | 9 - .../calls/of functions/main.sdstest | 18 -- .../expressions/calls/of functions/main.ttsl | 11 + .../calls/of non-callable/main.sdstest | 11 - .../calls/of non-callable/main.ttsl | 11 + .../calls/of nullable receiver/main.sdstest | 20 -- .../calls/of segments/main.sdstest | 21 -- .../clamp to upper bound/main.sdstest | 19 -- .../deep nesting/main.sdstest | 40 ---- .../default value of parameter/main.sdstest | 13 -- .../main.sdstest | 19 -- .../differing variance/main.sdstest | 58 ----- .../multiple contravariant/main.sdstest | 44 ---- .../multiple covariant/main.sdstest | 52 ----- .../single contravariant/main.sdstest | 16 -- .../single covariant/main.sdstest | 14 -- .../unresolved/{main.sdstest => main.ttsl} | 6 +- .../that are isolated/main.sdstest | 11 - .../that are passed as arguments/main.sdstest | 29 --- .../main.sdstest | 16 -- .../that are yielded/main.sdstest | 16 -- .../with manifest types/main.sdstest | 6 - .../indexed accesses/on lists/main.sdstest | 85 ------- .../indexed accesses/on lists/main.ttsl | 28 +++ .../indexed accesses/on maps/main.sdstest | 85 ------- .../indexed accesses/on maps/main.ttsl | 29 +++ .../indexed accesses/on other/main.sdstest | 16 -- .../on unresolved/{main.sdstest => main.ttsl} | 6 +- .../typing/expressions/lists/main.sdstest | 22 -- .../typing/expressions/lists/main.ttsl | 22 ++ .../typing/expressions/literals/main.sdstest | 19 -- .../typing/expressions/literals/main.ttsl | 19 ++ .../typing/expressions/maps/main.sdstest | 25 -- .../typing/expressions/maps/main.ttsl | 25 ++ .../operations/arithmetic/main.sdstest | 154 ------------ .../operations/arithmetic/main.ttsl | 142 +++++++++++ .../operations/comparison/main.sdstest | 21 -- .../operations/comparison/main.ttsl | 21 ++ .../elvis/non nullable left operand.sdstest | 32 --- .../elvis/non nullable left operand.ttsl | 32 +++ .../elvis/nullable left operand.sdstest | 19 -- .../elvis/nullable left operand.ttsl | 19 ++ .../operations/equality/main.sdstest | 22 -- .../expressions/operations/equality/main.ttsl | 22 ++ .../operations/logical/main.sdstest | 17 -- .../expressions/operations/logical/main.ttsl | 17 ++ .../parenthesized expressions/main.sdstest | 23 -- .../references/to global classes/main.sdstest | 8 - .../references/to global enums/main.sdstest | 8 - .../references/to other/main.sdstest | 13 -- .../expressions/references/to other/main.ttsl | 13 ++ .../unresolved/{main.sdstest => main.ttsl} | 4 +- .../expressions/template strings/main.sdstest | 9 - .../expressions/template strings/main.ttsl | 9 + .../expressions/type casts/main.sdstest | 14 -- ...op if class has no type parameters.sdstest | 14 -- .../class type and class type/main.sdstest | 42 ---- .../with type parameters.sdstest | 122 ---------- .../class type and enum type/main.sdstest | 34 --- .../class type and enum variant/main.sdstest | 36 --- .../class type and literal type/main.sdstest | 70 ------ .../main.sdstest | 50 ---- .../enum type and enum type/main.sdstest | 32 --- .../main.sdstest | 38 --- .../main.sdstest | 52 ----- .../main.sdstest | 49 ---- .../main.sdstest | 45 ---- .../incompatible types/main.sdstest | 56 ----- .../main.sdstest | 18 -- .../simplification/main.sdstest | 21 -- .../main.sdstest | 26 --- .../unhandled type/main.sdstest | 33 --- .../unknown type/main.sdstest | 15 -- .../class type and class type/main.sdstest | 34 --- .../with type parameters.sdstest | 96 -------- .../class type and literal type/main.sdstest | 50 ---- .../main.sdstest | 25 -- .../enum type and enum type/main.sdstest | 24 -- .../main.sdstest | 29 --- .../main.sdstest | 37 --- .../main.sdstest | 38 --- .../main.sdstest | 32 --- .../incompatible types/main.sdstest | 39 ---- .../main.sdstest | 9 - .../main.sdstest | 25 -- .../main.sdstest | 18 -- .../simplification/main.sdstest | 20 -- .../main.sdstest | 39 ---- .../main.sdstest | 37 --- .../unhandled type/main.sdstest | 24 -- .../unknown type/main.sdstest | 9 - .../main.sdstest | 18 -- .../main.sdstest | 12 - .../main.sdstest | 126 ---------- .../main.sdstest | 6 - .../main.sdstest | 6 - .../main.sdstest | 9 - .../typing/simplification/unwrap/main.sdstest | 46 ---- .../typing/types/callable types/main.sdstest | 16 -- .../typing/types/literal types/main.sdstest | 10 - .../tests/resources/typing/types/main.ttsl | 35 +++ .../typing/types/member types/main.sdstest | 36 --- .../typing/types/named types/main.sdstest | 23 -- .../named types/with type parameters.sdstest | 36 --- .../typing/types/type arguments/main.sdstest | 20 -- .../typing/types/union types/main.sdstest | 7 - .../deprecated/assigned result/main.sdstest | 24 +- .../deprecated/called annotation/main.sdstest | 8 +- .../corresponding parameter/main.sdstest | 14 +- .../main.sdstest | 40 ++-- .../from named type/main.sdstest | 14 +- .../from reference/main.sdstest | 38 +-- .../experimental/assigned result/main.sdstest | 24 +- .../called annotation/main.sdstest | 8 +- .../corresponding parameter/main.sdstest | 14 +- .../from named type/main.sdstest | 14 +- .../from reference/main.sdstest | 38 +-- .../main.sdstest | 40 ++-- .../annotations/pythonCall/main.sdstest | 18 +- .../annotations/pythonModule/error.sdstest | 2 +- .../pythonModule/no annotation.sdstest | 2 +- .../annotations/pythonModule/no error.sdstest | 4 +- .../identical to safe-ds name/main.sdstest | 6 +- .../no annotation.sdstest | 2 +- .../main.sdstest | 14 +- .../annotations/repeatable/main.sdstest | 14 +- .../target/duplicate target/main.sdstest | 30 +-- .../no target annotation.sdstest | 2 +- .../target/wrong target/main.sdstest | 100 ++++---- .../constraint lists/main.sdstest | 2 +- .../literal types/main.sdstest | 2 +- .../maps/main.sdstest | 6 +- .../union types/main.sdstest | 8 +- .../inheritance/must be acyclic/main.sdstest | 16 +- .../class with parent types.sdstest | 20 +- .../class without parent types.sdstest | 2 +- .../class with parent types.sdstest | 20 +- .../class with parent types.sdstest | 12 +- .../class without parent types.sdstest | 2 +- .../main.sdstest | 32 +-- .../type parameters.sdstest | 20 +- .../main.sdstest | 32 +-- .../purity.sdstest | 8 +- .../safeds lang any.sdstest | 2 +- .../type parameters.sdstest | 18 +- .../names/casing/annotations.sdstest | 10 +- .../names/casing/attributes.sdstest | 10 +- .../names/casing/block lambda results.sdstest | 12 +- .../validation/names/casing/classes.sdstest | 10 +- .../names/casing/enum variants.sdstest | 10 +- .../validation/names/casing/enums.sdstest | 10 +- .../validation/names/casing/functions.sdstest | 10 +- .../names/casing/no package name.sdstest | 2 +- .../package name leading underscore.sdstest | 2 +- .../package name lowercase escaped.sdstest | 2 +- .../casing/package name lowercase.sdstest | 2 +- .../casing/package name snake case.sdstest | 2 +- .../casing/package name uppercase.sdstest | 2 +- .../names/casing/parameters.sdstest | 10 +- .../validation/names/casing/pipelines.sdstest | 10 +- .../names/casing/placeholders.sdstest | 12 +- .../validation/names/casing/results.sdstest | 10 +- .../validation/names/casing/schemas.sdstest | 10 +- .../validation/names/casing/segments.sdstest | 10 +- .../names/casing/type parameters.sdstest | 10 +- .../names/codegen prefix/annotations.sdstest | 4 +- .../names/codegen prefix/attributes.sdstest | 4 +- .../block lambda results.sdstest | 6 +- .../names/codegen prefix/classes.sdstest | 4 +- .../codegen prefix/enum variants.sdstest | 4 +- .../names/codegen prefix/enums.sdstest | 4 +- .../names/codegen prefix/functions.sdstest | 4 +- .../codegen prefix/no package name.sdstest | 2 +- .../package name with codegen prefix.sdstest | 2 +- ...ackage name without codegen prefix.sdstest | 2 +- .../names/codegen prefix/parameters.sdstest | 4 +- .../names/codegen prefix/pipelines.sdstest | 4 +- .../names/codegen prefix/placeholders.sdstest | 6 +- .../names/codegen prefix/results.sdstest | 4 +- .../names/codegen prefix/schemas.sdstest | 4 +- .../names/codegen prefix/segments.sdstest | 4 +- .../codegen prefix/type parameters.sdstest | 4 +- .../names/core names/in safeds lang.sdstest | 2 +- .../validation/names/core names/main.sdstest | 4 +- .../duplicates/across files/main.sdstest | 72 +++--- .../across files/other package.sdstest | 18 +- .../duplicates/across files/safeds 1.sdstest | 20 +- .../duplicates/across files/safeds 2.sdstest | 18 +- .../across files/same package.sdstest | 18 +- .../duplicates/in annotation/main.sdstest | 6 +- .../duplicates/in block lambda/main.sdstest | 40 ++-- .../duplicates/in callable type/main.sdstest | 16 +- .../names/duplicates/in class/main.sdstest | 172 +++++++------- .../duplicates/in enum variant/main.sdstest | 6 +- .../names/duplicates/in enum/main.sdstest | 6 +- .../in expression lambda/main.sdstest | 6 +- .../names/duplicates/in function/main.sdstest | 30 +-- .../duplicates/in pipeline file/main.sdspipe | 70 +++--- .../names/duplicates/in pipeline/main.sdstest | 6 +- .../names/duplicates/in schema/main.sdstest | 6 +- .../names/duplicates/in segment/main.sdstest | 36 +-- .../duplicates/in stub file/main.sdsstub | 70 +++--- .../duplicates/in test file/main.sdstest | 70 +++--- .../duplicate parameter/main.sdstest | 114 ++++----- ...rgument list is missing altogether.sdstest | 2 +- .../missing required parameter/main.sdstest | 132 +++++------ .../main.sdstest | 54 ++--- .../too many arguments/main.sdstest | 132 +++++------ .../missing argument list/main.sdstest | 20 +- .../main.sdstest | 14 +- .../main.sdstest | 6 +- .../main.sdstest | 6 +- .../main.sdstest | 62 ++--- .../main.sdstest | 34 +-- .../parameter must be const/main.sdstest | 56 ++--- .../main.sdstest | 32 +-- .../main.sdstest | 72 +++--- .../main.sdstest | 114 ++++----- .../parameters/const modifier/error.sdstest | 8 +- .../const modifier/no error.sdstest | 4 +- .../main.sdstest | 12 +- .../no type.sdstest | 2 +- .../main.sdstest | 96 ++++---- .../placeholders/alias/main.sdstest | 32 +-- .../placeholders/unused/main.sdstest | 28 +-- .../segments/duplicate yield/main.sdstest | 14 +- .../segments/unassigned result/main.sdstest | 12 +- .../segments/unused parameter/main.sdstest | 24 +- .../declarations/segments/unused/main.sdstest | 14 +- .../segments/unused/same package.sdstest | 2 +- .../main.sdstest | 28 +-- .../insufficient context/main.sdstest | 36 +-- .../main.sdstest | 18 +- .../main.sdstest | 38 +-- .../contravariant type parameter.sdstest | 74 +++--- .../covariant type parameter.sdstest | 74 +++--- .../invariant type parameter.sdstest | 74 +++--- .../usage of class type parameters.sdstest | 24 +- .../invariant.sdstest | 2 +- .../variance only on classes/variant.sdstest | 8 +- .../annotation calls.sdstest | 16 +- .../const parameters.sdstest | 12 +- .../normal parameters.sdstest | 8 +- .../calls/recursion/direct.sdstest | 6 +- .../calls/recursion/not recursive.sdstest | 2 +- ...tive via function pointer argument.sdstest | 2 +- .../transitive via lambda argument.sdstest | 2 +- .../calls/recursion/transitive.sdstest | 6 +- .../missing null safety/main.sdstest | 54 ++--- .../list index out of bounds/main.sdstest | 36 +-- .../map key does not exist/main.sdstest | 22 +- .../division by zero/main.sdstest | 32 +-- .../assigned to typed parameter.sdstest | 104 ++++----- .../assigned to unresolved parameter.sdstest | 12 +- .../assigned to untyped parameter.sdstest | 104 ++++----- .../lambdas/context/invalid context.sdstest | 12 +- .../references/function pointer/main.sdstest | 50 ++-- .../static class reference/main.sdstest | 32 +-- .../static enum reference/main.sdstest | 20 +- .../references/target/main.sdstest | 8 +- .../missing template expression/main.sdstest | 10 +- .../other/imports/main with issues.sdstest | 12 +- .../other/imports/main without issues.sdstest | 4 +- .../main.sdspipe | 24 +- .../declarations in stub files/main.sdsstub | 24 +- ...ng is allowed (no pipeline errors).sdstest | 24 +- ...ything is allowed (no stub errors).sdstest | 24 +- .../pipeline file (empty).sdspipe | 2 +- .../pipeline file (only annotations).sdspipe | 2 +- .../pipeline file (only imports).sdspipe | 2 +- ...le (with declarations and package).sdspipe | 4 +- ...(with declarations but no package).sdspipe | 4 +- .../stub file (empty).sdsstub | 2 +- .../stub file (only annotations).sdsstub | 2 +- .../stub file (only imports).sdsstub | 2 +- ...le (with declarations and package).sdsstub | 4 +- ...(with declarations but no package).sdsstub | 4 +- .../pipe elsewhere.sdspipe | 2 +- .../pipe in safeds.sdspipe | 2 +- .../pipe in subpackage of safeds.sdspipe | 2 +- .../stub elsewhere.sdsstub | 2 +- .../stub in safeds.sdsstub | 2 +- .../stub in subpackage of safeds.sdsstub | 2 +- .../test elsewhere.sdstest | 2 +- .../test in safeds.sdstest | 2 +- .../test in subpackage of safeds.sdstest | 2 +- .../assignments/has no effect/main.sdstest | 16 +- .../implicitly ignore result/main.sdstest | 36 +-- .../assignments/nothing assigned/main.sdstest | 96 ++++---- .../yield forbidden in pipeline/main.sdstest | 6 +- .../has no effect/main.sdstest | 36 +-- .../types/callable types/context/main.sdstest | 30 +-- .../callable types/context/nested.sdstest | 6 +- .../optional.sdstest | 2 +- .../required.sdstest | 2 +- .../duplicate literals/empty list.sdstest | 2 +- .../duplicate literals/main.sdstest | 8 +- .../must have literals/main.sdstest | 6 +- .../main.sdstest | 2 +- .../main.sdstest | 2 +- .../duplicate type parameter/main.sdstest | 20 +- .../main.sdstest | 12 +- .../too many type arguments/main.sdstest | 12 +- .../types/union types/context/main.sdstest | 28 +-- .../types/union types/context/nested.sdstest | 6 +- .../duplicate types/empty list.sdstest | 2 +- .../union types/duplicate types/main.sdstest | 8 +- .../union types/must have types/main.sdstest | 6 +- .../duplicate impurity reason/main.sdstest | 30 +-- .../no impure annotation.sdstest | 2 +- .../arguments.sdstest | 76 +++--- .../default values.sdstest | 64 ++--- .../invalid parameter name/main.sdstest | 20 +- .../main.sdstest | 22 +- .../no purity annotation.sdstest | 2 +- .../purity/no impurity reasons/main.sdstest | 12 +- .../purity/not specified/main.sdstest | 6 +- .../main.sdstest | 10 +- .../purity/pure and impure/main.sdstest | 8 +- .../main.sdstest | 20 +- .../main.sdstest | 34 +-- .../style/unnecessary assignment/main.sdstest | 16 +- .../unnecessary body in class/main.sdstest | 6 +- .../unnecessary body in enum/main.sdstest | 4 +- .../info.sdstest | 2 +- .../no info.sdstest | 2 +- .../main.sdstest | 4 +- .../main.sdstest | 4 +- .../main.sdstest | 4 +- .../main.sdstest | 4 +- .../main.sdstest | 4 +- .../unnecessary elvis operator/main.sdstest | 42 ++-- .../unnecessary import alias/main.sdstest | 6 +- .../unnecessary null safety/main.sdstest | 54 ++--- .../main.sdstest | 4 +- .../main.sdstest | 4 +- .../main.sdstest | 4 +- .../main.sdstest | 4 +- .../main.sdstest | 16 +- .../main.sdstest | 4 +- .../main.sdstest | 4 +- .../style/unnecessary union type/main.sdstest | 6 +- .../types/checking/arguments/main.sdstest | 10 +- .../arguments/with type parameters.sdstest | 40 ++-- .../types/checking/call receiver/main.sdstest | 60 ++--- .../main.sdstest | 6 +- .../checking/default values/main.sdstest | 8 +- .../with type parameters.sdstest | 36 +-- .../indexed access on list/main.sdstest | 20 +- .../indexed access on map/main.sdstest | 26 +-- .../indexed access receiver/main.sdstest | 22 +- .../checking/infix operations/main.sdstest | 196 ++++++++-------- .../types/checking/lists/main.sdstest | 6 +- .../types/checking/maps/main.sdstest | 12 +- .../checking/prefix operations/main.sdstest | 20 +- .../types/checking/type casts/main.sdstest | 6 +- .../main.sdstest | 40 ++-- .../main.sdstest | 26 +-- .../types/checking/yields/main.sdstest | 6 +- ...rgument list is missing altogether.sdstest | 2 +- .../main.sdstest | 22 +- .../missing type argument list/main.sdstest | 16 +- .../missing for attribute/main.sdstest | 4 +- .../missing for parameter/main.sdstest | 34 +-- .../missing for result/main.sdstest | 16 +- .../ttsl-vscode/language-configuration.json | 2 +- packages/ttsl-vscode/snippets/ttsl.json | 5 + .../ttsl-vscode/syntaxes/ttsl.tmLanguage.json | 2 +- 1947 files changed, 7191 insertions(+), 12050 deletions(-) delete mode 100644 packages/ttsl-lang/tests/resources/generation/declarations/constant/generated/tests/generator/const/gen_input_test.py rename packages/ttsl-lang/tests/resources/generation/declarations/constant/generated/tests/generator/{const => const1}/gen_input.py (100%) rename packages/ttsl-lang/tests/resources/generation/declarations/constant/generated/tests/generator/{const => const1}/gen_input.py.map (100%) delete mode 100644 packages/ttsl-lang/tests/resources/generation/declarations/data/generated/tests/generator/datas/gen_input_test.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/declarations/empty pipeline/generated/tests/generator/emptyPipeline/gen_input.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/declarations/empty pipeline/generated/tests/generator/emptyPipeline/gen_input.py.map delete mode 100644 packages/ttsl-lang/tests/resources/generation/declarations/empty pipeline/input.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/generation/declarations/empty segment/generated/tests/generator/emptySegment/gen_input.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/declarations/empty segment/generated/tests/generator/emptySegment/gen_input.py.map delete mode 100644 packages/ttsl-lang/tests/resources/generation/declarations/empty segment/input.sdstest rename packages/ttsl-lang/tests/resources/generation/declarations/{empty pipeline/generated/tests/generator/emptyPipeline => function with parameter/generated/tests/generator/functionWithParameter}/gen_input_test.py (100%) rename packages/ttsl-lang/tests/resources/generation/{expressions/block lambda result/generated/tests/generator/blockLambdaResult => declarations/function with return Value/generated/tests/generator/functionWithReturnValue}/gen_input_test.py (100%) delete mode 100644 packages/ttsl-lang/tests/resources/generation/declarations/parameter with python name/generated/tests/generator/parameterWithPythonName/gen_input.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/declarations/parameter with python name/generated/tests/generator/parameterWithPythonName/gen_input.py.map delete mode 100644 packages/ttsl-lang/tests/resources/generation/declarations/parameter with python name/input.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/generation/declarations/pipeline with python name/generated/tests/generator/pipelineWithPythonName/gen_input.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/declarations/pipeline with python name/generated/tests/generator/pipelineWithPythonName/gen_input.py.map delete mode 100644 packages/ttsl-lang/tests/resources/generation/declarations/pipeline with python name/generated/tests/generator/pipelineWithPythonName/gen_input_test_pipeline.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/declarations/pipeline with python name/input.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/generation/declarations/segment with python name/generated/tests/generator/segmentWithPythonName/gen_input.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/declarations/segment with python name/generated/tests/generator/segmentWithPythonName/gen_input.py.map delete mode 100644 packages/ttsl-lang/tests/resources/generation/declarations/segment with python name/input.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/generation/declarations/two pipelines/generated/tests/generator/twoPipelines/gen_input.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/declarations/two pipelines/generated/tests/generator/twoPipelines/gen_input.py.map delete mode 100644 packages/ttsl-lang/tests/resources/generation/declarations/two pipelines/generated/tests/generator/twoPipelines/gen_input_test1.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/declarations/two pipelines/generated/tests/generator/twoPipelines/gen_input_test2.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/declarations/two pipelines/input.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/generation/declarations/two segments/generated/tests/generator/twoSegments/gen_input.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/declarations/two segments/generated/tests/generator/twoSegments/gen_input.py.map delete mode 100644 packages/ttsl-lang/tests/resources/generation/declarations/two segments/input.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/aggregation/generated/tests/generator/aggregation/gen_input_test.py create mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/aggregation/generated/tests/generator/aggregation/gen_input_testFunction.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/block lambda result/generated/tests/generator/blockLambdaResult/gen_input.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/block lambda result/generated/tests/generator/blockLambdaResult/gen_input.py.map delete mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/block lambda result/input.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/block lambda/generated/tests/generator/blockLambda/gen_input.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/block lambda/generated/tests/generator/blockLambda/gen_input.py.map delete mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/block lambda/input.sdstest create mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/call/generated/tests/generator/call/gen_input_f.py create mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/call/generated/tests/generator/call/gen_input_g.py create mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/call/generated/tests/generator/call/gen_input_h.py create mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/call/generated/tests/generator/call/gen_input_i.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/call/input.sdstest create mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/call/input.ttsl create mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/constant/generated/tests/generator/const/gen_input.py create mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/constant/generated/tests/generator/const/gen_input.py.map create mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/constant/generated/tests/generator/const/gen_input_f.py rename packages/ttsl-lang/tests/resources/generation/expressions/{block lambda/generated/tests/generator/blockLambda => constant/generated/tests/generator/const}/gen_input_test.py (100%) delete mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/constant/generated/tests/generator/constant/gen_input.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/constant/generated/tests/generator/constant/gen_input.py.map delete mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/constant/input.sdstest create mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/constant/input.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/enum variant call/generated/tests/generator/enumVariantCall/gen_input.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/enum variant call/generated/tests/generator/enumVariantCall/gen_input.py.map delete mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/enum variant call/input.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/expression lambda/generated/tests/generator/expressionLambda/gen_input.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/expression lambda/generated/tests/generator/expressionLambda/gen_input.py.map delete mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/expression lambda/generated/tests/generator/expressionLambda/gen_input_test.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/expression lambda/input.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/indexed access/generated/tests/generator/indexedAccess/gen_input.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/indexed access/generated/tests/generator/indexedAccess/gen_input.py.map delete mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/indexed access/input.sdstest create mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/indexed access/input.ttsl create mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/infix operation/generated/tests/generator/infixOperation/gen_input_f.py create mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/infix operation/generated/tests/generator/infixOperation/gen_input_g.py create mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/infix operation/generated/tests/generator/infixOperation/gen_input_h.py create mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/infix operation/generated/tests/generator/infixOperation/gen_input_i.py rename packages/ttsl-lang/tests/resources/generation/expressions/infix operation/{input.sdstest => input.ttsl} (67%) create mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/lists/generated/tests/generator/lists/gen_input_h.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/lists/input.sdstest create mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/lists/input.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/literals/input.sdstest create mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/literals/input.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/maps/generated/tests/generator/maps/gen_input.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/maps/generated/tests/generator/maps/gen_input.py.map delete mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/maps/generated/tests/generator/maps/gen_input_test.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/maps/input.sdstest create mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/maps/input.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/member access/generated/tests/generator/memberAccess/gen_input.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/member access/generated/tests/generator/memberAccess/gen_input.py.map delete mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/member access/generated/tests/generator/memberAccess/gen_input_test.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/member access/input.sdstest create mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/parenthesized expression/generated/tests/generator/parenthesizedExpression/gen_input_f.py create mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/parenthesized expression/generated/tests/generator/parenthesizedExpression/gen_input_g.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/parenthesized expression/input.sdstest create mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/parenthesized expression/input.ttsl create mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/prefix operation/generated/tests/generator/prefixOperation/gen_input_f.py create mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/prefix operation/generated/tests/generator/prefixOperation/gen_input_g.py create mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/prefix operation/generated/tests/generator/prefixOperation/gen_input_h.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/prefix operation/input.sdstest create mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/prefix operation/input.ttsl create mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/reference/generated/tests/generator/reference/gen_input_explainModel.py create mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/reference/generated/tests/generator/reference/gen_input_f.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/reference/input.sdstest create mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/reference/input.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/side effects/generated/tests/generator/sideEffects/gen_input.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/side effects/generated/tests/generator/sideEffects/gen_input.py.map delete mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/side effects/generated/tests/generator/sideEffects/gen_input_test.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/side effects/input.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/template string/generated/tests/generator/templateString/gen_input.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/template string/generated/tests/generator/templateString/gen_input.py.map delete mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/template string/generated/tests/generator/templateString/gen_input_test.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/template string/input.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/generation/imports/general/context different package.sdsstub create mode 100644 packages/ttsl-lang/tests/resources/generation/imports/general/context different package.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/generation/imports/general/context package with python module.sdsstub create mode 100644 packages/ttsl-lang/tests/resources/generation/imports/general/context package with python module.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/generation/imports/general/context same package.sdstest create mode 100644 packages/ttsl-lang/tests/resources/generation/imports/general/context same package.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_context_same_package.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_context_same_package.py.map delete mode 100644 packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_input.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_input.py.map delete mode 100644 packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_input_test.py rename packages/ttsl-lang/tests/resources/generation/imports/general/{input.sdstest => input.ttsl} (91%) delete mode 100644 packages/ttsl-lang/tests/resources/generation/imports/wildcard/generated/tests/generator/wildcard/gen_input.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/imports/wildcard/generated/tests/generator/wildcard/gen_input.py.map delete mode 100644 packages/ttsl-lang/tests/resources/generation/imports/wildcard/generated/tests/generator/wildcard/gen_input_test.py create mode 100644 packages/ttsl-lang/tests/resources/generation/modifier/timeunit/generated/tests/generator/timeunit/gen_input_daytest.py create mode 100644 packages/ttsl-lang/tests/resources/generation/modifier/timeunit/generated/tests/generator/timeunit/gen_input_monthtest.py create mode 100644 packages/ttsl-lang/tests/resources/generation/modifier/timeunit/generated/tests/generator/timeunit/gen_input_weektest.py create mode 100644 packages/ttsl-lang/tests/resources/generation/modifier/timeunit/generated/tests/generator/timeunit/gen_input_yeartest.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/partial/impure dependency file constant/generated/tests/generator/partialImpureDependencyFileConstant/gen_input.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/partial/impure dependency file constant/generated/tests/generator/partialImpureDependencyFileConstant/gen_input.py.map delete mode 100644 packages/ttsl-lang/tests/resources/generation/partial/impure dependency file constant/generated/tests/generator/partialImpureDependencyFileConstant/gen_input_testPipeline.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/partial/impure dependency file constant/input.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/generation/partial/impure dependency file parameter/generated/tests/generator/partialImpureDependencyFileParameter/gen_input.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/partial/impure dependency file parameter/generated/tests/generator/partialImpureDependencyFileParameter/gen_input.py.map delete mode 100644 packages/ttsl-lang/tests/resources/generation/partial/impure dependency file parameter/generated/tests/generator/partialImpureDependencyFileParameter/gen_input_testPipeline.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/partial/impure dependency file parameter/input.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/generation/partial/impure dependency/generated/tests/generator/partialImpureDependency/gen_input.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/partial/impure dependency/generated/tests/generator/partialImpureDependency/gen_input.py.map delete mode 100644 packages/ttsl-lang/tests/resources/generation/partial/impure dependency/generated/tests/generator/partialImpureDependency/gen_input_testPipeline.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/partial/impure dependency/input.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/generation/partial/pure dependency/generated/tests/generator/partialPureDependency/gen_input.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/partial/pure dependency/generated/tests/generator/partialPureDependency/gen_input.py.map delete mode 100644 packages/ttsl-lang/tests/resources/generation/partial/pure dependency/generated/tests/generator/partialPureDependency/gen_input_testPipeline.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/partial/pure dependency/input.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/generation/partial/redundant impurity/generated/tests/generator/partialRedundantImpurity/gen_input.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/partial/redundant impurity/generated/tests/generator/partialRedundantImpurity/gen_input.py.map delete mode 100644 packages/ttsl-lang/tests/resources/generation/partial/redundant impurity/generated/tests/generator/partialRedundantImpurity/gen_input_testPipeline.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/partial/redundant impurity/input.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/generation/python module/generated/special_module/gen_input.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/python module/generated/special_module/gen_input.py.map delete mode 100644 packages/ttsl-lang/tests/resources/generation/python module/input.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/generation/runner integration/expressions/call/generated/tests/generator/callWithRunnerIntegration/gen_input.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/runner integration/expressions/call/generated/tests/generator/callWithRunnerIntegration/gen_input.py.map delete mode 100644 packages/ttsl-lang/tests/resources/generation/runner integration/expressions/call/generated/tests/generator/callWithRunnerIntegration/gen_input_test.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/runner integration/expressions/call/input.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/generation/runner integration/imports/general/context different package.sdsstub delete mode 100644 packages/ttsl-lang/tests/resources/generation/runner integration/imports/general/context package with python module.sdsstub delete mode 100644 packages/ttsl-lang/tests/resources/generation/runner integration/imports/general/context same package.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/generation/runner integration/imports/general/generated/tests/generator/importsWithRunnerIntegration/gen_context_same_package.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/runner integration/imports/general/generated/tests/generator/importsWithRunnerIntegration/gen_context_same_package.py.map delete mode 100644 packages/ttsl-lang/tests/resources/generation/runner integration/imports/general/generated/tests/generator/importsWithRunnerIntegration/gen_input.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/runner integration/imports/general/generated/tests/generator/importsWithRunnerIntegration/gen_input.py.map delete mode 100644 packages/ttsl-lang/tests/resources/generation/runner integration/imports/general/generated/tests/generator/importsWithRunnerIntegration/gen_input_test.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/runner integration/imports/general/input.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/generation/runner integration/imports/wildcard/context different package.sdsstub delete mode 100644 packages/ttsl-lang/tests/resources/generation/runner integration/imports/wildcard/context package with python module.sdsstub delete mode 100644 packages/ttsl-lang/tests/resources/generation/runner integration/imports/wildcard/generated/tests/generator/wildcardWithRunnerIntegration/gen_input.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/runner integration/imports/wildcard/generated/tests/generator/wildcardWithRunnerIntegration/gen_input.py.map delete mode 100644 packages/ttsl-lang/tests/resources/generation/runner integration/imports/wildcard/generated/tests/generator/wildcardWithRunnerIntegration/gen_input_test.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/runner integration/imports/wildcard/input.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/generation/runner integration/statements/assignment/generated/tests/generator/assignmentWithRunnerIntegration/gen_input.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/runner integration/statements/assignment/generated/tests/generator/assignmentWithRunnerIntegration/gen_input.py.map delete mode 100644 packages/ttsl-lang/tests/resources/generation/runner integration/statements/assignment/generated/tests/generator/assignmentWithRunnerIntegration/gen_input_testPipeline.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/runner integration/statements/assignment/input.sdstest create mode 100644 packages/ttsl-lang/tests/resources/generation/statements/Loops/forLoop/input.ttsl create mode 100644 packages/ttsl-lang/tests/resources/generation/statements/Loops/foreachLoop/generated/tests/generator/forEachLoop/gen_input.py create mode 100644 packages/ttsl-lang/tests/resources/generation/statements/Loops/foreachLoop/generated/tests/generator/forEachLoop/gen_input.py.map create mode 100644 packages/ttsl-lang/tests/resources/generation/statements/Loops/foreachLoop/generated/tests/generator/forEachLoop/gen_input_myFunction.py create mode 100644 packages/ttsl-lang/tests/resources/generation/statements/Loops/foreachLoop/input.ttsl create mode 100644 packages/ttsl-lang/tests/resources/generation/statements/Loops/whileLoop/generated/tests/generator/whileLoop/gen_input.py create mode 100644 packages/ttsl-lang/tests/resources/generation/statements/Loops/whileLoop/generated/tests/generator/whileLoop/gen_input.py.map create mode 100644 packages/ttsl-lang/tests/resources/generation/statements/Loops/whileLoop/generated/tests/generator/whileLoop/gen_input_myFunction.py create mode 100644 packages/ttsl-lang/tests/resources/generation/statements/Loops/whileLoop/input.ttsl create mode 100644 packages/ttsl-lang/tests/resources/generation/statements/assignment/generated/tests/generator/assignment/gen_input_f.py create mode 100644 packages/ttsl-lang/tests/resources/generation/statements/assignment/generated/tests/generator/assignment/gen_input_g.py create mode 100644 packages/ttsl-lang/tests/resources/generation/statements/assignment/generated/tests/generator/assignment/gen_input_testFunction.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/statements/assignment/generated/tests/generator/assignment/gen_input_testPipeline.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/statements/assignment/input.sdstest create mode 100644 packages/ttsl-lang/tests/resources/generation/statements/assignment/input.ttsl rename packages/ttsl-lang/tests/resources/generation/{expressions/constant/generated/tests/generator/constant => statements/conditional statement/generated/tests/generator/conditionalStatement}/gen_input_test.py (100%) delete mode 100644 packages/ttsl-lang/tests/resources/generation/statements/conditional statement/generated/tests/generator/conditionalStatement/gen_input_testPipeline.py create mode 100644 packages/ttsl-lang/tests/resources/generation/statements/expression statement/generated/tests/generator/expressionStatement/gen_input_f.py rename packages/ttsl-lang/tests/resources/generation/{expressions/enum variant call/generated/tests/generator/enumVariantCall => statements/expression statement/generated/tests/generator/expressionStatement}/gen_input_test.py (100%) delete mode 100644 packages/ttsl-lang/tests/resources/generation/statements/expression statement/generated/tests/generator/expressionStatement/gen_input_testPipeline.py delete mode 100644 packages/ttsl-lang/tests/resources/generation/statements/expression statement/input.sdstest create mode 100644 packages/ttsl-lang/tests/resources/generation/statements/expression statement/input.ttsl create mode 100644 packages/ttsl-lang/tests/resources/generation/utilityFunctions/generated/tests/generator/utilityFunction/gen_input.py create mode 100644 packages/ttsl-lang/tests/resources/generation/utilityFunctions/generated/tests/generator/utilityFunction/gen_input.py.map create mode 100644 packages/ttsl-lang/tests/resources/generation/utilityFunctions/generated/tests/generator/utilityFunction/gen_input_testFunction.py delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/bad-unclosed argument list.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-empty argument list.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-multiple arguments.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-named argument.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-no argument list.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-positional argument.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/annotations/bad-unclosed constraint list.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/annotations/bad-unclosed parameter list.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/annotations/good-annotation call.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/annotations/good-no parameter list.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/annotations/good-with constraint list.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/annotations/good-with parameter list.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/classes/attributes/good-annotated.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/classes/attributes/good-no type.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/classes/attributes/good-static.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/classes/attributes/good-with type.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-empty parent type list.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-unclosed body.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-unclosed constraint list.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-unclosed parameter list.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-unclosed type parameter list.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-annotation call.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-empty body.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-minimal.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-multiple parent types.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-one parent type.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-with constraint list.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-with parameter list.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-with type parameter list.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/classes/methods/good-annotated instance method.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/classes/methods/good-annotated static method.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/classes/methods/good-instance method.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/classes/methods/good-static method.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/classes/nested classes/good-annotated nested class.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/classes/nested classes/good-nested-class.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/classes/nested enums/good-annotated nested enum.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/classes/nested enums/good-nested enum.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/constraints/bad-missing comma.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-empty.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-greater than constraint.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-greater than or equals constraint.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-less than constraint.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-less than or equals constraint.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-multiple constraints.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/enums/bad-unclosed body.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/enums/good-annotation call.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/enums/good-empty body.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/enums/good-no body.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/enums/good-variants in body.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/bad-unclosed constraint list.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/bad-unclosed parameter list.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/good-annotation call.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/good-no parameter list.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/good-with constraint list.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/good-with parameter list.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/parameters/bad-const before annotation.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/parameters/bad-double const modifier.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/parameters/bad-missing comma.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/parameters/bad-missing comma.ttsl create mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/parameters/bad-missing type.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-annotated parameter.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-const typed optional parameter.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-const typed required parameter.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-const untyped optional parameter.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-const untyped required parameter.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-empty.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-empty.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-multiple parameters.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-typed optional parameter.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-typed optional parameter.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-typed required parameter.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-typed required parameter.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-untyped optional parameter.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-untyped required parameter.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/bad-missing body.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/bad-unclosed body.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/good-annotation call.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/good-empty body.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/good-statements in body.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/results/bad-missing comma.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/results/bad-multiple results.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/results/good-annotated result.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/results/good-empty.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/results/good-empty.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/results/good-multiple results.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/results/good-named result.ttsl create mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/results/good-nameless result.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/results/good-one typed result (in parentheses).sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/results/good-one typed result (no parentheses).sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/results/good-one untyped result (no parentheses).sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/results/good-one untyped result (with parentheses).sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-missing body.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-missing parameter list.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-two visibilities (internal, internal).sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-two visibilities (internal, private).sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-two visibilities (private, internal).sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-two visibilities (private, private).sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-unclosed body.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-unclosed parameter list.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-unclosed result list.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-annotation call.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-internal segment.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-private segment.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-statements in body.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-with constraint list.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-with parameter list and body.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-with result list.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/bad-missing comma.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-annotated type parameter.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded contravariant optional type parameter.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded contravariant required type parameter.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded covariant optional type parameter.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded covariant required type parameter.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded invariant optional type parameter.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded invariant required type parameter.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-empty.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-multiple type parameters.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded contravariant optional type parameter.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded contravariant required type parameter.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded covariant optional type parameter.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded covariant required type parameter.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded invariant optional type parameter.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded invariant required type parameter.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-addition without left operator.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-addition without left operator.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-addition without right operator.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-addition without right operator.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-division without left operator.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-division without left operator.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-division without right operator.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-division without right operator.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-multiplication without left operator.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-multiplication without left operator.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-multiplication without right operator.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-multiplication without right operator.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-negation without operator.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-negation without operator.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-subtraction without right operator.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-subtraction without right operator.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-addition.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-addition.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-complex example.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-complex example.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-division.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-division.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-multiplication.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-multiplication.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-negation.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-negation.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-subtraction.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-subtraction.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/block lambdas/bad-unclosed body.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/block lambdas/bad-unclosed parameter list.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/block lambdas/good-filled body.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/block lambdas/good-with parameter list and body.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/calls/bad-unclosed argument list.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/calls/bad-unclosed argument list.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-mixed positional and named arguments.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-mixed positional and named arguments.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-named argument.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-named argument.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-no arguments.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-no arguments.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-null safe.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-null safe.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-positional argument.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-positional argument.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than or equal without left operator.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than or equal without left operator.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than or equal without right operator.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than or equal without right operator.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than without left operator.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than without left operator.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than without right operator.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than without right operator.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than or equal without left operator.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than or equal without left operator.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than or equal without right operator.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than or equal without right operator.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than without left operator.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than without left operator.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than without right operator.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than without right operator.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-greater than or equal.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-greater than or equal.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-greater than.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-greater than.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-less than or equal.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-less than or equal.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-less than.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-less than.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/bad-without left operand.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/bad-without left operand.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/bad-without right operand.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/bad-without right operand.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/good-basic.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/good-basic.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/good-chained.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/good-chained.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-equal without left operator.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-equal without left operator.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-equal without right operator.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-equal without right operator.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-identical without left operator.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-identical without left operator.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-identical without right operator.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-identical without right operator.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not equal without left operator.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not equal without left operator.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not equal without right operator.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not equal without right operator.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not identical without left operator.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not identical without left operator.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not identical without right operator.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not identical without right operator.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-equal.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-equal.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-identical.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-identical.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-not equal.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-not equal.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-not identical.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-not identical.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/expression lambdas/bad-missing body.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/expression lambdas/bad-unclosed parameter list.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/expression lambdas/good-with parameter list and expression.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/good-complex chained expression.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/good-reference.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/good-reference.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/bad-no index.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/bad-no index.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/bad-unclosed square bracket.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/bad-unclosed square bracket.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/good-literal index.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/good-literal index.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/good-null safe.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/good-null safe.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/good-reference index.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/good-reference index.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/lists/bad-unclosed square bracket.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/lists/bad-unclosed square bracket.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-nested multiple elements.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-nested multiple elements.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-nested one element.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-nested one element.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-one level multiple elements.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-one level multiple elements.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-one level one element.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-one level one element.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/bad-no digits before dot.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/bad-no digits before dot.ttsl rename packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/{good-basic example.sdstest => good-basic example.ttsl} (66%) delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/good-scientific notation with lowercase e.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/good-scientific notation with lowercase e.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/good-scientific notation with uppercase e.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/good-scientific notation with uppercase e.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/literals/good-false.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/literals/good-false.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/literals/good-null.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/literals/good-null.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/literals/good-true.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/literals/good-true.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/literals/int/good-leading zero.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/literals/int/good-leading zero.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/literals/int/good-multiple digits.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/literals/int/good-multiple digits.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/literals/int/good-one digit.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/literals/int/good-one digit.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/bad-single quotes as delimiters.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/bad-single quotes as delimiters.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/bad-unclosed quote.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/bad-unclosed quote.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-basic content.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-basic content.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-closing template expression delimiter.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-closing template expression delimiter.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-curly braces separated by space.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-curly braces separated by space.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-empty.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-empty.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-escaped curly brace.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-escaped curly brace.ttsl rename packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/{good-multiple lines.sdstest => good-multiple lines.ttsl} (53%) delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-newline escape sequence.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-newline escape sequence.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-single curly brace.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-single curly brace.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-single quote.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-single quote.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-unicode escape sequence.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-unicode escape sequence.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-conjunction without left operator.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-conjunction without left operator.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-conjunction without right operator.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-conjunction without right operator.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-disjunction without left operator.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-disjunction without left operator.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-disjunction without right operator.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-disjunction without right operator.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-negation without operator.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-negation without operator.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-complex example.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-complex example.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-conjunction.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-conjunction.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-disjunction.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-disjunction.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-negation.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-negation.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-no colon.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-no colon.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-no key.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-no key.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-no value.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-no value.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-unclosed curly brace.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-unclosed curly brace.ttsl rename packages/ttsl-lang/tests/resources/grammar/expressions/maps/{good-nested multiple elements.sdstest => good-nested multiple elements.ttsl} (62%) rename packages/ttsl-lang/tests/resources/grammar/expressions/maps/{good-nested one element.sdstest => good-nested one element.ttsl} (55%) delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-one level multiple elements.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-one level multiple elements.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-one level one element.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-one level one element.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/member accesses/bad-no receiver.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/member accesses/good-not nullable.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/member accesses/good-nullable.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/parenthesized expressions/bad-unclosed parenthesis.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/parenthesized expressions/good-nested.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/parenthesized expressions/good-one level.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/template strings/bad-template string with invalid expression.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/template strings/bad-template string with invalid expression.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/template strings/bad-unclosed template expression.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/template strings/bad-unclosed template expression.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/template strings/good-empty template expression.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/template strings/good-empty template expression.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/template strings/good-template string with basic expression.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/template strings/good-template string with basic expression.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/type casts/bad-without expression.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/type casts/bad-without type.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/type casts/good-basic.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/expressions/type casts/good-chained.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped _.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped and.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped and.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped annotation.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped as.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped as.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped attr.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped class.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped const.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped constant.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped enum.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped false.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped false.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped fun.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped function.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped import.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped import.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped in.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped internal.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped literal.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped not.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped not.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped null.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped null.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped or.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped or.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped out.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped package.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped package.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped pipeline.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped private.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped private.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped schema.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped segment.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped static.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped sub.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped true.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped true.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped union.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped val.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped var.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped where.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped yield.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/keywords as names/good-escapedKeywords.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/keywords as names/good-escapedKeywords.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/keywords as names/good-escapedNonKeyword.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/keywords as names/good-escapedNonKeyword.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/modules/bad-annotation call after declaration.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/modules/bad-annotation call after import.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/modules/bad-annotation call after package name.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/modules/bad-annotation call between package name and import.sdstest rename packages/ttsl-lang/tests/resources/grammar/modules/{bad-duplicate package name.sdstest => bad-duplicate package name.ttsl} (54%) delete mode 100644 packages/ttsl-lang/tests/resources/grammar/modules/bad-import after declaration.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/modules/bad-import after declaration.ttsl rename packages/ttsl-lang/tests/resources/grammar/modules/{bad-import without declarations.sdstest => bad-import without declarations.ttsl} (50%) delete mode 100644 packages/ttsl-lang/tests/resources/grammar/modules/bad-import without package.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/modules/bad-import without package.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/modules/bad-package name after declaration.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/modules/bad-package name after declaration.ttsl rename packages/ttsl-lang/tests/resources/grammar/modules/{bad-package name after import.sdstest => bad-package name after import.ttsl} (69%) delete mode 100644 packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and declaration.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and import and declaration.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and import.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and package name and declaration.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and package name and import and declaration.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and package name and import.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and package name.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and declarations.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and imports and declarations.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and imports.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and package name and declarations.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and package name and imports and declarations.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and package name and imports.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and package name.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/modules/good-declaration.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/modules/good-declaration.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/modules/good-declarations.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/modules/good-declarations.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/modules/good-empty.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/modules/good-empty.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/modules/good-import and declaration.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/modules/good-import and declaration.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/modules/good-import.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/modules/good-import.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/modules/good-imports and declarations.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/modules/good-imports and declarations.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/modules/good-imports.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/modules/good-imports.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/modules/good-package name and declaration.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/modules/good-package name and declaration.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/modules/good-package name and declarations.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/modules/good-package name and declarations.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/modules/good-package name and import and declaration.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/modules/good-package name and import and declaration.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/modules/good-package name and import.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/modules/good-package name and import.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/modules/good-package name and imports and declarations.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/modules/good-package name and imports and declarations.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/modules/good-package name and imports.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/modules/good-package name and imports.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/modules/good-package name.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/modules/good-package name.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/schema/bad-no name (colon).sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/schema/bad-no name (no colon).sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/schema/bad-no type (colon).sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/schema/bad-no type (no colon).sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/schema/bad-switched name and type.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/schema/bad-unclosed curly brace.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/schema/good-annotation call.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/schema/good-empty schema.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/schema/good-one column.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/schema/good-two columns.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in block lambda without assignees.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in block lambda without expression.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in block lambda without semicolon.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in function without assignees.ttsl create mode 100644 packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in function without expression.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in pipeline without assignees.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in pipeline without expression.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in pipeline without semicolon.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in segment without assignees.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in segment without expression.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in segment without semicolon.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/statements/assignments/good-in block lambda.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/statements/assignments/good-in function.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/statements/assignments/good-in pipeline.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/statements/assignments/good-in segment.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/statements/bad-empty statement in block lambda.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/statements/bad-empty statement in pipeline.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/statements/bad-empty statement in pipeline.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/statements/bad-empty statement in segment.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/statements/expression statements/bad-in block lambda without semicolon.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/statements/expression statements/bad-in function without semicolon.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/statements/expression statements/bad-in pipeline without semicolon.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/statements/expression statements/bad-in segment without semicolon.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/statements/expression statements/good-in block lambda.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/statements/expression statements/good-in function.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/statements/expression statements/good-in pipeline.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/statements/expression statements/good-in segment.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/statements/loops/for loops/bad-missing body.ttsl create mode 100644 packages/ttsl-lang/tests/resources/grammar/statements/loops/for loops/bad-missing condition.ttsl create mode 100644 packages/ttsl-lang/tests/resources/grammar/statements/loops/for loops/bad-missing semicolon.ttsl create mode 100644 packages/ttsl-lang/tests/resources/grammar/statements/loops/for loops/good-in function.ttsl create mode 100644 packages/ttsl-lang/tests/resources/grammar/statements/loops/foreach loops/bad-missing body.ttsl create mode 100644 packages/ttsl-lang/tests/resources/grammar/statements/loops/foreach loops/bad-missing element.ttsl create mode 100644 packages/ttsl-lang/tests/resources/grammar/statements/loops/foreach loops/bad-missing list.ttsl create mode 100644 packages/ttsl-lang/tests/resources/grammar/statements/loops/foreach loops/good- in function.ttsl create mode 100644 packages/ttsl-lang/tests/resources/grammar/statements/loops/while loops/bad-missing body.ttsl create mode 100644 packages/ttsl-lang/tests/resources/grammar/statements/loops/while loops/bad-missing condition.ttsl create mode 100644 packages/ttsl-lang/tests/resources/grammar/statements/loops/while loops/good-in function.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/trailing commas/good-argument list of annotation call.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/trailing commas/good-argument list of call.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/trailing commas/good-argument list of call.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/trailing commas/good-assignee list of assignment in block lambda.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/trailing commas/good-assignee list of assignment.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/trailing commas/good-column list of schema.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/trailing commas/good-constraint list of annotation.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/trailing commas/good-constraint list of class.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/trailing commas/good-constraint list of enum variant.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/trailing commas/good-constraint list of function.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/trailing commas/good-elements of list.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/trailing commas/good-elements of list.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/trailing commas/good-entries of map.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/trailing commas/good-entries of map.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/trailing commas/good-imported declaration list of qualified import.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/trailing commas/good-imported declaration list of qualified import.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/trailing commas/good-literal list of literal type.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of annotation.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of block lambda.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of callable type.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of class.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of enum variant.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of expression lambda.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of function.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of function.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of segment.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parent type list of class.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/trailing commas/good-result list of callable type.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/trailing commas/good-result list of function.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/trailing commas/good-result list of segment.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/trailing commas/good-type argument list of named type.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/trailing commas/good-type argument list of union type.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/trailing commas/good-type parameter list of class.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/trailing commas/good-type parameter list of function.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-missing arrow.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-missing parameter list.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-missing result list.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-unclosed parameter list.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-unclosed result list.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/types/callable types/good-with parameter and result lists.sdstest create mode 100644 packages/ttsl-lang/tests/resources/grammar/types/good-Boolean.ttsl create mode 100644 packages/ttsl-lang/tests/resources/grammar/types/good-Dictionary.ttsl create mode 100644 packages/ttsl-lang/tests/resources/grammar/types/good-Float.ttsl create mode 100644 packages/ttsl-lang/tests/resources/grammar/types/good-Int.ttsl create mode 100644 packages/ttsl-lang/tests/resources/grammar/types/good-List.ttsl create mode 100644 packages/ttsl-lang/tests/resources/grammar/types/good-String.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/grammar/types/literal types/bad-nested.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/types/literal types/bad-no literal list.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/types/literal types/bad-unclosed angle bracket.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/types/literal types/good-empty.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/types/literal types/good-with list literal.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/types/literal types/good-with literals.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/types/literal types/good-with map literal.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/types/member types/bad-callable type as member.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/types/member types/bad-literal type as member.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/types/member types/bad-missing member.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/types/member types/bad-missing receiver.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/types/member types/bad-unclosed angle bracket.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/types/member types/bad-union type as member.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/types/member types/good-long complex chain.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (callable) and member (not nullable).sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (callable) and member (nullable).sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (literal) and member (not nullable).sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (literal) and member (nullable).sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (named, not nullable) and member (not nullable).sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (named, not nullable) and member (nullable).sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (named, nullable) and member (not nullable).sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (named, nullable) and member (nullable).sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (union) and member (not nullable).sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (union) and member (nullable).sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/types/named types/bad-unclosed angle bracket.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/types/named types/good-no type arguments and not nullable.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/types/named types/good-no type arguments and nullable.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/types/named types/good-type argument and nullable.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/types/named types/good-type arguments and not nullable.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/types/union types/bad-unclosed angle bracket.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/types/union types/good-empty.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/types/union types/good-nested.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/grammar/types/union types/good-with type arguments.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/helpers/listSafeDsFiles/nested/test file.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/helpers/listSafeDsFiles/not a safe-ds file.txt delete mode 100644 packages/ttsl-lang/tests/resources/helpers/listSafeDsFiles/pipeline file.sdspipe delete mode 100644 packages/ttsl-lang/tests/resources/helpers/listSafeDsFiles/skip pipeline file.sdspipe delete mode 100644 packages/ttsl-lang/tests/resources/helpers/listSafeDsFiles/skip stub file.sdsstub delete mode 100644 packages/ttsl-lang/tests/resources/helpers/listSafeDsFiles/skip test file.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/helpers/listSafeDsFiles/stub file.sdsstub delete mode 100644 packages/ttsl-lang/tests/resources/helpers/listSafeDsFiles/test file.sdstest rename packages/ttsl-lang/tests/resources/helpers/{listSafeDsFiles/nested/not a safe-ds file.txt => listTTSLFiles/function file.ttsl} (100%) rename packages/ttsl-lang/tests/resources/helpers/{listSafeDsFiles/nested/pipeline file.sdspipe => listTTSLFiles/nested/function file.ttsl} (100%) rename packages/ttsl-lang/tests/resources/helpers/{listSafeDsFiles/nested/skip pipeline file.sdspipe => listTTSLFiles/nested/not a ttsl file.txt} (100%) rename packages/ttsl-lang/tests/resources/helpers/{listSafeDsFiles/nested/skip stub file.sdsstub => listTTSLFiles/nested/skip function file.tts} (100%) rename packages/ttsl-lang/tests/resources/helpers/{listSafeDsFiles/nested/skip test file.sdstest => listTTSLFiles/not a ttsl file.txt} (100%) rename packages/ttsl-lang/tests/resources/helpers/{listSafeDsFiles/nested/stub file.sdsstub => listTTSLFiles/skip function file.ttsl} (100%) delete mode 100644 packages/ttsl-lang/tests/resources/typing/assignees/block lambda results/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/assignees/placeholders/main.sdstest create mode 100644 packages/ttsl-lang/tests/resources/typing/assignees/placeholders/main.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/typing/assignees/yields/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/declarations/annotations/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/declarations/attributes/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/declarations/classes/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/declarations/enum variants/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/declarations/enums/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/declarations/functions/main.sdstest create mode 100644 packages/ttsl-lang/tests/resources/typing/declarations/functions/main.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/typing/declarations/parameters/of annotations/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/that are isolated/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/that are passed as arguments/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/that are passed as default values/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/that are yielded/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/with manifest types/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/declarations/parameters/of callable types/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/declarations/parameters/of classes/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/declarations/parameters/of enum variants/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/that are isolated/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/that are passed as arguments/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/that are passed as default values/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/that are yielded/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/with manifest types/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/declarations/parameters/of segments/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/declarations/pipelines/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/declarations/results/main.sdstest create mode 100644 packages/ttsl-lang/tests/resources/typing/declarations/results/main.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/typing/declarations/segments/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/declarations/type parameters/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/arguments/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/that are isolated/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/that are passed as arguments/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/that are passed as default values/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/that are yielded/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/with manifest types/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/calls/of annotations/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/calls/of block lambdas/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/calls/of callable types/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/calls/of classes/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/calls/of enum variants/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/calls/of expression lambdas/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/calls/of functions/main.sdstest create mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/calls/of functions/main.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/calls/of non-callable/main.sdstest create mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/calls/of non-callable/main.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/calls/of nullable receiver/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/calls/of segments/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/clamp to upper bound/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/deep nesting/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/default value of parameter/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/default value of type parameter/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/differing variance/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/multiple contravariant/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/multiple covariant/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/single contravariant/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/single covariant/main.sdstest rename packages/ttsl-lang/tests/resources/typing/expressions/calls/unresolved/{main.sdstest => main.ttsl} (51%) delete mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/that are isolated/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/that are passed as arguments/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/that are passed as default values/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/that are yielded/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/with manifest types/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on lists/main.sdstest create mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on lists/main.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on maps/main.sdstest create mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on maps/main.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on other/main.sdstest rename packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on unresolved/{main.sdstest => main.ttsl} (54%) delete mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/lists/main.sdstest create mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/lists/main.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/literals/main.sdstest create mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/literals/main.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/maps/main.sdstest create mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/maps/main.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/operations/arithmetic/main.sdstest create mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/operations/arithmetic/main.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/operations/comparison/main.sdstest create mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/operations/comparison/main.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/operations/elvis/non nullable left operand.sdstest create mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/operations/elvis/non nullable left operand.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/operations/elvis/nullable left operand.sdstest create mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/operations/elvis/nullable left operand.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/operations/equality/main.sdstest create mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/operations/equality/main.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/operations/logical/main.sdstest create mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/operations/logical/main.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/parenthesized expressions/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/references/to global classes/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/references/to global enums/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/references/to other/main.sdstest create mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/references/to other/main.ttsl rename packages/ttsl-lang/tests/resources/typing/expressions/references/unresolved/{main.sdstest => main.ttsl} (56%) delete mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/template strings/main.sdstest create mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/template strings/main.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/typing/expressions/type casts/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and class type/cannot stop if class has no type parameters.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and class type/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and class type/with type parameters.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and enum type/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and enum variant/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and literal type/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and type parameter type/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/highest common subtype/enum type and enum type/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/highest common subtype/enum type and enum variant type/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/highest common subtype/enum type and type parameter type/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/highest common subtype/enum variant type and enum variant type/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/highest common subtype/enum variant type and type parameter type/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/highest common subtype/incompatible types/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/highest common subtype/literal type and literal type/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/highest common subtype/simplification/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/highest common subtype/type parameter type and type parameter type/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/highest common subtype/unhandled type/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/highest common subtype/unknown type/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/lowest common supertype/class type and class type/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/lowest common supertype/class type and class type/with type parameters.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/lowest common supertype/class type and literal type/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/lowest common supertype/class type and type parameter type/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum type and enum type/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum type and enum variant type/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum type and type parameter type/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum variant type and enum variant type/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum variant type and type parameter type/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/lowest common supertype/incompatible types/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/lowest common supertype/literal type and literal type/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/lowest common supertype/literal type and type parameter type/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/lowest common supertype/no types after simplification/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/lowest common supertype/simplification/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/lowest common supertype/singular type after simplification/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/lowest common supertype/type parameter type and type parameter type/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/lowest common supertype/unhandled type/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/lowest common supertype/unknown type/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/simplification/merge literal types in union types/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/simplification/remove duplicate constants from literal types/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/simplification/remove unneeded entries from union types/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/simplification/replace empty literal types with Nothing/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/simplification/replace empty union types with Nothing/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/simplification/replace literals types that allow only null with NothingOrNull/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/simplification/unwrap/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/types/callable types/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/types/literal types/main.sdstest create mode 100644 packages/ttsl-lang/tests/resources/typing/types/main.ttsl delete mode 100644 packages/ttsl-lang/tests/resources/typing/types/member types/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/types/named types/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/types/named types/with type parameters.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/types/type arguments/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/typing/types/union types/main.sdstest diff --git a/packages/ttsl-cli/tests/resources/check/correct.ttsl b/packages/ttsl-cli/tests/resources/check/correct.ttsl index 3e742739..46fc0ac4 100644 --- a/packages/ttsl-cli/tests/resources/check/correct.ttsl +++ b/packages/ttsl-cli/tests/resources/check/correct.ttsl @@ -1,3 +1,3 @@ package test -pipeline myPipeline {} +function myFunction () {} diff --git a/packages/ttsl-cli/tests/resources/format/correct.ttsl b/packages/ttsl-cli/tests/resources/format/correct.ttsl index 3e742739..930a58da 100644 --- a/packages/ttsl-cli/tests/resources/format/correct.ttsl +++ b/packages/ttsl-cli/tests/resources/format/correct.ttsl @@ -1,3 +1,3 @@ package test -pipeline myPipeline {} +function myFunction() {} diff --git a/packages/ttsl-cli/tests/resources/generate/correct.ttsl b/packages/ttsl-cli/tests/resources/generate/correct.ttsl index 3e742739..46fc0ac4 100644 --- a/packages/ttsl-cli/tests/resources/generate/correct.ttsl +++ b/packages/ttsl-cli/tests/resources/generate/correct.ttsl @@ -1,3 +1,3 @@ package test -pipeline myPipeline {} +function myFunction () {} diff --git a/packages/ttsl-lang/src/language/documentation/ttsl-comment-provider.ts b/packages/ttsl-lang/src/language/documentation/ttsl-comment-provider.ts index 0abf3383..4a4b513c 100644 --- a/packages/ttsl-lang/src/language/documentation/ttsl-comment-provider.ts +++ b/packages/ttsl-lang/src/language/documentation/ttsl-comment-provider.ts @@ -9,7 +9,7 @@ import { export class TTSLCommentProvider extends DefaultCommentProvider { override getComment(node: AstNode): string | undefined { - /* c8 ignore start */ if (isAstNodeWithComment(node)) { + /* c8 ignore start */ if (isAstNodeWithComment(node)) { return node.$comment; } /* c8 ignore stop */ else if ( !isTslDeclaration(node) || diff --git a/packages/ttsl-lang/src/language/generation/ttsl-python-generator.ts b/packages/ttsl-lang/src/language/generation/ttsl-python-generator.ts index eb8ccffa..664a5e30 100644 --- a/packages/ttsl-lang/src/language/generation/ttsl-python-generator.ts +++ b/packages/ttsl-lang/src/language/generation/ttsl-python-generator.ts @@ -65,6 +65,17 @@ import { TslTimeunit, isTslExpression, isTslString, + isTslParenthesizedExpression, + isTslResult, + isTslReturnStatement, + isTslLiteral, + isTslInt, + isTslDate, + isTslNull, + isTslBoolean, + isTslFloat, + isTslTimeunit, + isTslPredefinedFunction, } from '../generated/ast.js'; import { isInFile, isFile } from '../helpers/fileExtensions.js'; import { @@ -83,6 +94,7 @@ import { TTSLNodeMapper } from '../helpers/ttsl-node-mapper.js'; import { TTSLPartialEvaluator } from '../partialEvaluation/ttsl-partial-evaluator.js'; import { TTSLServices } from '../ttsl-module.js'; import { TTSLFunction } from '../builtins/ttsl-ds-functions.js'; +import { Console } from 'console'; export const CODEGEN_PREFIX = '__gen_'; @@ -345,7 +357,22 @@ export class TTSLPythonGenerator { ); } generatedFiles.set(pythonOutputPath, text); - + for (const funct of getModuleMembers(node).filter(isTslFunction)) { + const entryPointFilename = `${path.join( + parentDirectoryPath, + `${this.formatGeneratedFileName(name)}_${this.getPythonNameOrDefault(funct)}`, + )}.py`; + const entryPointContent = expandTracedToNode(funct)`from .${this.formatGeneratedFileName( + name, + )} import ${this.getPythonNameOrDefault( + funct, + )}\n\nif __name__ == '__main__':\n${PYTHON_INDENT}${this.getPythonNameOrDefault( + funct, + )}()`.appendNewLine(); + const generatedPipelineEntry = toStringAndTrace(entryPointContent); + generatedFiles.set(entryPointFilename, generatedPipelineEntry.text); + } + return Array.from(generatedFiles.entries()).map(([fsPath, content]) => TextDocument.create(URI.file(fsPath).toString(), 'py', 0, content), ); @@ -458,11 +485,6 @@ export class TTSLPythonGenerator { .map((constant) => this.generateConstant(constant, importSet, utilitySet, typeVariableSet, generateOptions), ); - const datas = getModuleMembers(module) - .filter(isTslData) - .map((data) => - this.generateData(data, importSet, utilitySet, typeVariableSet, generateOptions), - ); const imports = this.generateImports(Array.from(importSet.values())); const output = new CompositeGeneratorNode(); output.trace(module); @@ -509,16 +531,6 @@ export class TTSLPythonGenerator { output.append(joinToNode(constants, (constant) => constant, { separator: SPACING })); output.appendNewLine(); } - if (datas.length > 0) { - output.appendNewLineIf( - imports.length > 0 || typeVariableSet.size > 0 || utilitySet.size > 0 || functions.length > 0 || constants.length > 0, - ); - output.append('# Data --------------------------------------------------------------------'); - output.appendNewLine(); - output.appendNewLine(); - output.append(joinToNode(datas, (data) => data, { separator: SPACING })); - output.appendNewLine(); - } return output; } @@ -555,34 +567,37 @@ export class TTSLPythonGenerator { if (targetPlaceholder) { statements = this.getStatementsNeededForPartialExecution(targetPlaceholder, statements); } - let resultBlock = new CompositeGeneratorNode() - if (isTslExpression(block.returnValue)){ - if(timeunit){ + let resultBlock = new CompositeGeneratorNode(); + let returnStatement = statements.filter(isTslReturnStatement).at(0); + let restStatements = statements.filter(stmt => !isTslReturnStatement(stmt)) + + if (returnStatement){ + if(isTslTimeunit(timeunit)){ resultBlock.append(`if timeunit != None:`) if (timeunit?.timeunit === 'day'){ frame.addUtility(UTILITY_TIMEUNIT_DAY); - resultBlock.appendNewLine().indent([`result = ${UTILITY_TIMEUNIT_DAY.name}(${this.generateExpression(block.returnValue, frame).contents}, timeunit)`]).appendNewLine() + resultBlock.appendNewLine().indent([`result = ${UTILITY_TIMEUNIT_DAY.name}(${this.generateExpression(returnStatement.result, frame).contents}, timeunit)`]).appendNewLine() } else if (timeunit?.timeunit === 'week'){ frame.addUtility(UTILITY_TIMEUNIT_WEEK); - resultBlock.appendNewLine().indent([`result = ${UTILITY_TIMEUNIT_WEEK.name}(${this.generateExpression(block.returnValue, frame).contents}, timeunit)`]).appendNewLine() + resultBlock.appendNewLine().indent([`result = ${UTILITY_TIMEUNIT_WEEK.name}(${this.generateExpression(returnStatement.result, frame).contents}, timeunit)`]).appendNewLine() } else if (timeunit?.timeunit === 'month'){ frame.addUtility(UTILITY_TIMEUNIT_MONTH); - resultBlock.appendNewLine().indent([`result = ${UTILITY_TIMEUNIT_MONTH.name}(${this.generateExpression(block.returnValue, frame).contents}, timeunit)`]).appendNewLine() + resultBlock.appendNewLine().indent([`result = ${UTILITY_TIMEUNIT_MONTH.name}(${this.generateExpression(returnStatement.result, frame).contents}, timeunit)`]).appendNewLine() } else if (timeunit?.timeunit === 'year'){ frame.addUtility(UTILITY_TIMEUNIT_YEAR); - resultBlock.appendNewLine().indent([`result = ${UTILITY_TIMEUNIT_YEAR.name}(${this.generateExpression(block.returnValue, frame).contents}, timeunit)`]).appendNewLine() + resultBlock.appendNewLine().indent([`result = ${UTILITY_TIMEUNIT_YEAR.name}(${this.generateExpression(returnStatement.result, frame).contents}, timeunit)`]).appendNewLine() } resultBlock.append(`return result`) }else{ - resultBlock.append(`return ${this.generateExpression(block.returnValue, frame).contents}`) + resultBlock.append(`return ${this.generateExpression(returnStatement.result, frame).contents}`) } - } else if (statements.length === 0) { + } else if (restStatements.length === 0) { return traceToNode(block)('pass'); } return joinTracedToNode(block, 'statements')( - statements, + restStatements, (stmt) => this.generateStatement(stmt, frame), { separator: NL, @@ -645,16 +660,6 @@ export class TTSLPythonGenerator { } } - private generateData( - data: TslData, - importSet: Map, - utilitySet: Set, - typeVariableSet: Set, - generateOptions: GenerateOptions, - ): CompositeGeneratorNode{ - return expandToNode`${data.name} = ${data.type}()` - } - private generateParameters( parameters: TslParameterList | undefined, frame: GenerationInfoFrame, @@ -798,9 +803,6 @@ export class TTSLPythonGenerator { ): CompositeGeneratorNode { const code: CompositeGeneratorNode[] = []; if (isTslAssignment(statement)) { - if (statement.expression) { - code.push(this.generateExpression(statement.expression, frame)); - } code.push(this.generateAssignment(statement, frame)); return joinTracedToNode(statement)(code, (stmt) => stmt, { separator: NL, @@ -828,17 +830,17 @@ export class TTSLPythonGenerator { let elseBlock = new CompositeGeneratorNode if (isTslBlock(statement.elseBlock)){ let generatedBlock = this.generateBlock((statement.elseBlock), frame) - elseBlock = expandTracedToNode(statement.elseBlock)`else:`.appendNewLine().indent(indentingNode => - indentingNode.append(`${generatedBlock}`)) + elseBlock.append(`else:`).appendNewLine().indent(indentingNode => + indentingNode.append(generatedBlock)) } - return expandTracedToNode(statement)`if ${this.generateExpression((statement.expression), frame)}:` + return expandTracedToNode(statement)`if (${this.generateExpression((statement.expression), frame)}):` .appendNewLine().indent(indentingNode => - indentingNode.append(`${this.generateBlock((statement.ifBlock), frame)}`)) + indentingNode.append(this.generateBlock((statement.ifBlock), frame))) .appendNewLine().append(elseBlock); } else if (isTslLoop(statement)) { if (isTslWhileLoop(statement)){ - return expandTracedToNode(statement)`while ${this.generateExpression((statement.condition), frame)}: - ${this.generateBlock((statement.block), frame)}`; + return expandTracedToNode(statement)`while ${this.generateExpression((statement.condition), frame)}:`.appendNewLine().indent(indentingNode => + indentingNode.append(this.generateBlock((statement.block), frame))); } else if (isTslForLoop(statement)){ let firstParameter, thirdParameter = new CompositeGeneratorNode if (statement.definitionStatement){ @@ -848,14 +850,15 @@ export class TTSLPythonGenerator { thirdParameter = this.generateStatement((statement.iteration), frame) } return expandTracedToNode(statement)`${firstParameter} - while ${this.generateExpression((statement.condition), frame)}: - ${this.generateBlock((statement.block), frame), thirdParameter - }`; + while ${this.generateExpression((statement.condition), frame)}:`.appendNewLine().indent(indentingNode => + indentingNode.append(this.generateBlock((statement.block), frame))).append(`${thirdParameter}`); } else if (isTslForeachLoop(statement)){ - return expandTracedToNode(statement)`for ${statement.element} in ${statement.list}: - ${this.generateBlock((statement.block), frame)}`; + return expandTracedToNode(statement)`for ${statement.element} in ${statement.list}:`.appendNewLine().indent(indentingNode => + indentingNode.append(this.generateBlock((statement.block), frame))); + } + }else if (isTslReturnStatement(statement)){ + return expandTracedToNode(statement)`return ${this.generateExpression(statement.result, frame)}`; } - } /* c8 ignore next 2 */ throw new Error(`Unknown TslStatement: ${statement}`); } @@ -912,71 +915,46 @@ export class TTSLPythonGenerator { return expandTracedToNode(expression)` }${this.formatStringSingleLine(expression.value)}`; } } - - - // Handled after constant expressions: EnumVariant, List, Dictionary + + // Handled after constant expressions: List, Dictionary if (isTslTemplateString(expression)) { return expandTracedToNode(expression)`f'${joinTracedToNode(expression, 'expressions')( expression.expressions, (expr) => this.generateExpression(expr, frame), { separator: '' }, )}'`; - } else if (isTslDictionary(expression)) { - return expandTracedToNode(expression)`{${joinTracedToNode(expression, 'entries')( - expression.entries, - (entry) => - expandTracedToNode(entry)`${traceToNode( - entry, - 'key', - )(this.generateExpression(entry.key, frame))}: ${traceToNode( - entry, - 'value', - )(this.generateExpression(entry.value, frame))}`, - { separator: ', ' }, - )}}`; - } else if (isTslList(expression)) { - return expandTracedToNode(expression)`[${joinTracedToNode(expression, 'elements')( - expression.elements, - (value) => this.generateExpression(value, frame), - { separator: ', ' }, - )}]`; + } else if (isTslLiteral(expression)) { + if (isTslDictionary(expression)) { + return expandTracedToNode(expression)`{${joinTracedToNode(expression, 'entries')( + expression.entries, + (entry) => + expandTracedToNode(entry)`${traceToNode( + entry, + 'key', + )(this.generateExpression(entry.key, frame))}: ${traceToNode( + entry, + 'value', + )(this.generateExpression(entry.value, frame))}`, + { separator: ', ' }, + )}}`; + } else if (isTslList(expression)) { + return expandTracedToNode(expression)`[${joinTracedToNode(expression, 'elements')( + expression.elements, + (value) => this.generateExpression(value, frame), + { separator: ', ' }, + )}]`; + } else if (isTslInt(expression) || isTslFloat(expression) || isTslBoolean(expression)){ + return expandTracedToNode(expression)`${expression.value}` + } else if (isTslString(expression)){ + return expandTracedToNode(expression)`"${expression.value}"` + } else if (isTslNull(expression)){ + return expandTracedToNode(expression)`None` + } } else if (isTslCall(expression)) { const callable = this.nodeMapper.callToCallable(expression); const sortedArgs = this.sortArguments(getArguments(expression)); const receiver = this.generateExpression(expression.receiver, frame); let call: CompositeGeneratorNode | undefined = undefined; - - if (isTslString(receiver)){ - - if(sortedArgs[0]){ - let arg = sortedArgs[0]; - if(receiver.value === "len"){ - if(isTslReference(arg.value)){ - frame.addUtility(UTILITY_LEN_FUNCTION); - return expandTracedToNode(expression)`${traceToNode( - expression, - 'receiver', - )(UTILITY_LEN_FUNCTION.name)}(${arg.value.target.ref?.name})`; - } - } else if(receiver.value === "keys"){ - if(isTslReference(arg.value)){ - frame.addUtility(UTILITY_KEYS_FUNCTION); - return expandTracedToNode(expression)`${traceToNode( - expression, - 'receiver', - )(UTILITY_KEYS_FUNCTION.name)}(${arg.value.target.ref?.name})`; - } - } else if(receiver.value === "values"){ - if(isTslReference(arg.value)){ - frame.addUtility(UTILITY_VALUES_FUNCTION); - return expandTracedToNode(expression)`${traceToNode( - expression, - 'receiver', - )(UTILITY_VALUES_FUNCTION.name)}(${arg.value.target.ref?.name})`; - } - } - } - } // Memoize constructor or function call if (isTslFunction(callable)) { @@ -1001,6 +979,34 @@ export class TTSLPythonGenerator { } else { return call; } + + + } else if (isTslPredefinedFunction(expression)){ + if(expression.name === 'len'){ + if(isTslReference(expression.object)){ + frame.addUtility(UTILITY_LEN_FUNCTION); + return expandTracedToNode(expression)`${traceToNode( + expression, + 'object', + )(UTILITY_LEN_FUNCTION.name)}(${expression.object.target.ref?.name})`; + } + } else if(expression.name === "keys"){ + if(isTslReference(expression.object)){ + frame.addUtility(UTILITY_KEYS_FUNCTION); + return expandTracedToNode(expression)`${traceToNode( + expression, + 'object', + )(UTILITY_KEYS_FUNCTION.name)}(${expression.object.target.ref?.name})`; + } + } else if(expression.name === "values"){ + if(isTslReference(expression.object)){ + frame.addUtility(UTILITY_VALUES_FUNCTION); + return expandTracedToNode(expression)`${traceToNode( + expression, + 'object', + )(UTILITY_VALUES_FUNCTION.name)}(${expression.object.target.ref?.name})`; + } + } } else if (isTslInfixOperation(expression)) { const leftOperand = this.generateExpression(expression.leftOperand, frame); const rightOperand = this.generateExpression(expression.rightOperand, frame); @@ -1055,6 +1061,8 @@ export class TTSLPythonGenerator { frame, )}[${this.generateExpression(expression.index, frame)}]`; } + } else if (isTslParenthesizedExpression(expression)) { + return expandTracedToNode(expression)`${this.generateExpression(expression.expression, frame)}`; } else if (isTslPrefixOperation(expression)) { const operand = this.generateExpression(expression.operand, frame); switch (expression.operator) { @@ -1074,7 +1082,7 @@ export class TTSLPythonGenerator { frame.addUtility(UTILITY_AGGREGATION); return expandTracedToNode(expression)`${traceToNode( expression - )(UTILITY_AGGREGATION.name)}(${'dataframe'}, ${expression.data.target.ref?.name}, ${expression.groupedBy.id.target.ref?.name}, '${expression.function}')`; + )(UTILITY_AGGREGATION.name)}(${'dataframe'}, ${expression.data.target.ref?.name}, ${expression.groupedBy.id.target.ref?.name}, '${expression.function.value}')`; } /* c8 ignore next 2 */ throw new Error(`Unknown expression type: ${expression.$type}`); diff --git a/packages/ttsl-lang/src/language/grammar/ttsl.langium b/packages/ttsl-lang/src/language/grammar/ttsl.langium index d8b2bca8..48235c6a 100644 --- a/packages/ttsl-lang/src/language/grammar/ttsl.langium +++ b/packages/ttsl-lang/src/language/grammar/ttsl.langium @@ -21,6 +21,10 @@ interface TslLocalVariable extends TslDeclaration { ^type?: TslType } +TslLocalVariable returns TslLocalVariable: + name=ID +; + // ----------------------------------------------------------------------------- // Module // ----------------------------------------------------------------------------- @@ -239,7 +243,6 @@ TslBlock returns TslBlock: interface TslFunctionBlock extends TslBlock{ timespanStatement: TslTimespanStatement[] - returnValue?: TslExpression } TslFunctionBlock returns TslFunctionBlock: @@ -263,7 +266,7 @@ interface TslAssignment extends TslStatement { } TslAssignment returns TslAssignment: - assigneeList=TslAssigneeList '=' expression=TslExpression ';' + assigneeList=TslAssigneeList '=' expression=TslExpression ';'? ; interface TslAssigneeList extends TslObject { @@ -280,6 +283,7 @@ interface TslPlaceholder extends TslAssignee, TslLocalVariable {} TslAssignee returns TslAssignee: {TslPlaceholder} 'var' name=ID (':' ^type=TslType)? (groupedBy=TslGroupedBy)? + | TslReference ; interface TslExpressionStatement extends TslStatement { @@ -326,19 +330,19 @@ interface TslForLoop extends TslLoop{ } TslForLoop returns TslForLoop: - 'for''(' (definitionStatement=TslStatement)? - ';' condition=TslExpression - ';' (iteration=TslStatement)? + 'for''(' (definitionStatement=TslAssignment| ';') + condition=TslExpression + ';' (iteration=TslAssignment)? ')' block=TslBlock ; interface TslForeachLoop extends TslLoop{ - element: string + element: TslLocalVariable list: TslExpression } TslForeachLoop returns TslForeachLoop: - 'foreach''(' element=STRING 'in' list=TslExpression ')' + 'foreach''(' element=TslLocalVariable 'in' list=TslExpression ')' block=TslBlock ; @@ -536,6 +540,8 @@ TslCallArgument returns TslArgument: TslPrimaryExpression returns TslExpression: TslLiteral | TslReference + | TslParenthesizedExpression + | TslPredefinedFunction ; interface TslLiteral extends TslExpression {} @@ -626,6 +632,23 @@ TslDate returns TslDate: date=DATE ; +interface TslParenthesizedExpression extends TslExpression { + expression:TslExpression +} + +TslParenthesizedExpression returns TslParenthesizedExpression: + '(' expression=TslExpression ')' +; + +interface TslPredefinedFunction extends TslExpression { + name: string + object: TslReference +} + +TslPredefinedFunction returns TslPredefinedFunction: + name = ('len' | 'keys' | 'values') '(' object = TslReference ')' +; + interface TslReference extends TslExpression { target: @TslDeclaration } @@ -737,16 +760,13 @@ TslTimespanValueEntry returns TslTimespanValueEntry: // Types // ----------------------------------------------------------------------------- -interface TslType extends TslObject {} - -interface TslNamedTypeDeclaration extends TslDeclaration {} - -interface TslMemberType extends TslType { - receiver: TslType +interface TslType extends TslObject { + isNullable: boolean } + TslType returns TslType: - TslPrimaryType + TslPrimaryType (isNullable?='?')? ; TslPrimaryType returns TslType: @@ -756,6 +776,7 @@ TslPrimaryType returns TslType: | TslBooleanType | TslDictionaryType | TslListType + | TslAnyType ; interface TslIntType extends TslType {} @@ -822,6 +843,13 @@ TslTypeParameter returns TslTypeParameter: type=TslType ; +interface TslAnyType extends TslType {} + +TslAnyType returns TslAnyType: + {TslAnyType} 'Any' +; + + // ----------------------------------------------------------------------------- // Terminals // ----------------------------------------------------------------------------- @@ -853,6 +881,6 @@ terminal TEMPLATE_STRING_INNER returns string: TEMPLATE_EXPRESSION_END STRING_TE terminal TEMPLATE_STRING_END returns string: TEMPLATE_EXPRESSION_END STRING_TEXT* STRING_END; hidden terminal ML_COMMENT: /\/\*[\s\S]*?\*\//; -hidden terminal SL_COMMENT: /\/\/[^\n\r]*/; +hidden terminal SL_COMMENT: /\#[^\n\r]*/; hidden terminal TEST_MARKER: /[»«]/; hidden terminal WS: /\s+/; diff --git a/packages/ttsl-lang/src/language/lsp/ttsl-formatter.ts b/packages/ttsl-lang/src/language/lsp/ttsl-formatter.ts index 5183703b..00bdd1c6 100644 --- a/packages/ttsl-lang/src/language/lsp/ttsl-formatter.ts +++ b/packages/ttsl-lang/src/language/lsp/ttsl-formatter.ts @@ -105,9 +105,7 @@ export class TTSLFormatter extends AbstractFormatter { // ----------------------------------------------------------------------------- // Types // ----------------------------------------------------------------------------- - else if (ast.isTslMemberType(node)) { - this.formatTslMemberType(node); - } else if (ast.isTslIntType(node)) { + else if (ast.isTslIntType(node)) { this.formatTslIntType(node); } else if (ast.isTslFloatType(node)) { this.formatTslFloatType(node); @@ -471,12 +469,6 @@ export class TTSLFormatter extends AbstractFormatter { // Types // ----------------------------------------------------------------------------- - private formatTslMemberType(node: ast.TslMemberType) { - const formatter = this.getNodeFormatter(node); - - formatter.keyword('.').surround(noSpace()); - } - private formatTslIntType(node: ast.TslIntType) { const formatter = this.getNodeFormatter(node); diff --git a/packages/ttsl-lang/src/language/partialEvaluation/ttsl-partial-evaluator.ts b/packages/ttsl-lang/src/language/partialEvaluation/ttsl-partial-evaluator.ts index f1454e21..97f48e37 100644 --- a/packages/ttsl-lang/src/language/partialEvaluation/ttsl-partial-evaluator.ts +++ b/packages/ttsl-lang/src/language/partialEvaluation/ttsl-partial-evaluator.ts @@ -45,6 +45,7 @@ import { isTslVisibility, isTslTimeunit, isTslString, + isTslParenthesizedExpression, } from '../generated/ast.js'; import { getArguments, getParameters, getResults } from '../helpers/nodeProperties.js'; import { TTSLNodeMapper } from '../helpers/ttsl-node-mapper.js'; @@ -223,6 +224,8 @@ export class TTSLPartialEvaluator { return this.evaluateWithRecursionCheck(node.expression, substitutions, visited); } else if (isTslAggregation(node)) { return this.evaluateAggregation(node, substitutions, visited); + } else if (isTslParenthesizedExpression(node)) { + return this.evaluateWithRecursionCheck(node, substitutions, visited); } /* c8 ignore start */ else { throw new Error(`Unexpected expression type: ${node.$type}`); } /* c8 ignore stop */ diff --git a/packages/ttsl-lang/src/language/scoping/ttsl-scope-computation.ts b/packages/ttsl-lang/src/language/scoping/ttsl-scope-computation.ts index 549bcd42..41b6daa7 100644 --- a/packages/ttsl-lang/src/language/scoping/ttsl-scope-computation.ts +++ b/packages/ttsl-lang/src/language/scoping/ttsl-scope-computation.ts @@ -7,10 +7,17 @@ import { PrecomputedScopes, } from 'langium'; import { + isTslConditionalStatement, isTslDeclaration, + isTslForeachLoop, + isTslForLoop, isTslFunction, + isTslLoop, isTslModule, + isTslWhileLoop, + TslConditionalStatement, TslFunction, + TslLoop, } from '../generated/ast.js'; export class TTSLScopeComputation extends DefaultScopeComputation { @@ -32,6 +39,10 @@ export class TTSLScopeComputation extends DefaultScopeComputation { protected override processNode(node: AstNode, document: LangiumDocument, scopes: PrecomputedScopes): void { if (isTslFunction(node)) { this.processTslFunction(node, document, scopes); + } else if (isTslLoop(node)){ + this.processTslLoop(node, document, scopes) + } else if (isTslConditionalStatement(node)){ + this.processTslConditionalStatement(node, document, scopes) } else { super.processNode(node, document, scopes); } @@ -55,6 +66,50 @@ export class TTSLScopeComputation extends DefaultScopeComputation { } } + private processTslLoop(node: TslLoop, document: LangiumDocument, scopes: PrecomputedScopes): void { + const name = this.nameProvider.getName(node); + if (!name) { + return; + } + + const description = this.descriptions.createDescription(node, name, document); + + this.addToScopesIfKeyIsDefined(scopes, node.block, description); + + if (isTslForLoop(node)){ + this.addToScopesIfKeyIsDefined(scopes, node.definitionStatement, description); + this.addToScopesIfKeyIsDefined(scopes, node.condition, description); + this.addToScopesIfKeyIsDefined(scopes, node.iteration, description); + } else if(isTslWhileLoop(node)){ + this.addToScopesIfKeyIsDefined(scopes, node.condition, description); + } else if(isTslForeachLoop(node)){ + this.addToScopesIfKeyIsDefined(scopes, node.element, description); + this.addToScopesIfKeyIsDefined(scopes, node.list, description); + } + + const containingDeclaration = AstUtils.getContainerOfType(node.$container, isTslDeclaration); + if (isTslModule(containingDeclaration)) { + this.addToScopesIfKeyIsDefined(scopes, containingDeclaration, description); + } + } + + private processTslConditionalStatement(node: TslConditionalStatement, document: LangiumDocument, scopes: PrecomputedScopes): void { + const name = this.nameProvider.getName(node); + if (!name) { + return; + } + + const description = this.descriptions.createDescription(node, name, document); + + this.addToScopesIfKeyIsDefined(scopes, node.ifBlock, description); + this.addToScopesIfKeyIsDefined(scopes, node.elseBlock, description); + + const containingDeclaration = AstUtils.getContainerOfType(node.$container, isTslDeclaration); + if (isTslModule(containingDeclaration)) { + this.addToScopesIfKeyIsDefined(scopes, containingDeclaration, description); + } + } + /** * Adds the key/value pair to the scopes if the key is defined. * diff --git a/packages/ttsl-lang/src/language/scoping/ttsl-scope-provider.ts b/packages/ttsl-lang/src/language/scoping/ttsl-scope-provider.ts index 5bce4e24..f61f95a9 100644 --- a/packages/ttsl-lang/src/language/scoping/ttsl-scope-provider.ts +++ b/packages/ttsl-lang/src/language/scoping/ttsl-scope-provider.ts @@ -15,9 +15,9 @@ import { isTslAssignment, isTslBlock, isTslCallable, + isTslDeclaration, isTslImportedDeclaration, isTslModule, - isTslNamedTypeDeclaration, isTslParameter, isTslPlaceholder, isTslQualifiedImport, @@ -129,10 +129,10 @@ export class TTSLScopeProvider extends DefaultScopeProvider { let start: AstNode | undefined; // Only containing classes, enums, and enum variants can be referenced - let current = AstUtils.getContainerOfType(start, isTslNamedTypeDeclaration); + let current = AstUtils.getContainerOfType(start, isTslDeclaration); while (current) { result.push(current); - current = AstUtils.getContainerOfType(current.$container, isTslNamedTypeDeclaration); + current = AstUtils.getContainerOfType(current.$container, isTslDeclaration); } return this.createScopeForNodes(result, outerScope); diff --git a/packages/ttsl-lang/src/language/typing/model.ts b/packages/ttsl-lang/src/language/typing/model.ts index 28aeca7d..0710eaad 100644 --- a/packages/ttsl-lang/src/language/typing/model.ts +++ b/packages/ttsl-lang/src/language/typing/model.ts @@ -98,6 +98,14 @@ export class IntType extends AnyType { return result; } + + override withExplicitNullability(isExplicitlyNullable: boolean): IntType { + if (this.isExplicitlyNullable === isExplicitlyNullable) { + return this; + } + + return new IntType(isExplicitlyNullable); + } } export class FloatType extends AnyType { @@ -116,6 +124,14 @@ export class FloatType extends AnyType { return result; } + + override withExplicitNullability(isExplicitlyNullable: boolean): FloatType { + if (this.isExplicitlyNullable === isExplicitlyNullable) { + return this; + } + + return new FloatType(isExplicitlyNullable); + } } export class StringType extends AnyType { @@ -134,6 +150,14 @@ export class StringType extends AnyType { return result; } + + override withExplicitNullability(isExplicitlyNullable: boolean): StringType { + if (this.isExplicitlyNullable === isExplicitlyNullable) { + return this; + } + + return new StringType(isExplicitlyNullable); + } } export class BooleanType extends AnyType { @@ -152,6 +176,14 @@ export class BooleanType extends AnyType { return result; } + + override withExplicitNullability(isExplicitlyNullable: boolean): BooleanType { + if (this.isExplicitlyNullable === isExplicitlyNullable) { + return this; + } + + return new BooleanType(isExplicitlyNullable); + } } export class DictionaryType extends AnyType { @@ -165,8 +197,10 @@ export class DictionaryType extends AnyType { } override get isFullySubstituted(): boolean { - if (this._isFullySubstituted === undefined) { + if (this._isFullySubstituted === undefined && !isEmpty(this.substitutions)) { this._isFullySubstituted = stream(this.substitutions.values()).every((it) => it.isFullySubstituted); + } else { + this._isFullySubstituted = false } return this._isFullySubstituted; @@ -222,8 +256,10 @@ export class ListType extends AnyType{ } override get isFullySubstituted(): boolean { - if (this._isFullySubstituted === undefined) { + if (this._isFullySubstituted === undefined && !isEmpty(this.substitutions)) { this._isFullySubstituted = stream(this.substitutions.values()).every((it) => it.isFullySubstituted); + } else { + this._isFullySubstituted = false } return this._isFullySubstituted; @@ -284,6 +320,14 @@ export class NothingType extends AnyType{ return result; } + + override withExplicitNullability(isExplicitlyNullable: boolean): NothingType { + if (this.isExplicitlyNullable === isExplicitlyNullable) { + return this; + } + + return new NothingType(isExplicitlyNullable); + } } class UnknownTypeClass extends AnyType { diff --git a/packages/ttsl-lang/src/language/typing/ttsl-type-computer.ts b/packages/ttsl-lang/src/language/typing/ttsl-type-computer.ts index ba700b02..83984038 100644 --- a/packages/ttsl-lang/src/language/typing/ttsl-type-computer.ts +++ b/packages/ttsl-lang/src/language/typing/ttsl-type-computer.ts @@ -37,6 +37,7 @@ import { isTslFloat, isTslBoolean, isTslString, + isTslAnyType, } from '../generated/ast.js'; import { TTSLServices } from '../ttsl-module.js'; import { @@ -136,7 +137,7 @@ export class TTSLTypeComputer { private computeTypeOfCallableWithManifestTypes(node: TslFunction ): Type { if(isTslFunction(node)){ - return this.computeType(node.result?.type); + return this.computeType(node.result); }else{ return UnknownType; } @@ -240,12 +241,7 @@ export class TTSLTypeComputer { private computeTypeOfCall(node: TslCall): Type { const receiverType = this.computeType(node.receiver); - const nonNullableReceiverType = this.computeNonNullableType(receiverType); - let result: Type = UnknownType; - - if (isTslFunction(nonNullableReceiverType)) { - result = receiverType - } + let result = receiverType // Update nullability return result.withExplicitNullability(receiverType.isExplicitlyNullable && node.isNullSafe); @@ -279,8 +275,8 @@ export class TTSLTypeComputer { const rightOperandType = this.computeType(node.rightOperand); if ( - this.typeChecker.isSubtypeOf(leftOperandType, new IntType(false)) && - this.typeChecker.isSubtypeOf(rightOperandType, new IntType(false)) + leftOperandType instanceof IntType && + rightOperandType instanceof IntType ) { return new IntType(false); } else { @@ -301,7 +297,7 @@ export class TTSLTypeComputer { private computeTypeOfArithmeticPrefixOperation(node: TslPrefixOperation): Type { const operandType = this.computeType(node.operand); - if (this.typeChecker.isSubtypeOf(operandType, new IntType(false))) { + if (operandType instanceof IntType) { return new IntType(false); } else { return new FloatType(false); @@ -324,6 +320,8 @@ export class TTSLTypeComputer { return new StringType(false); } else if (isTslBooleanType(node)) { return new BooleanType(false); + } else if (isTslAnyType(node)) { + return new AnyType(false); } /* c8 ignore start */ else { return UnknownType; } /* c8 ignore stop */ diff --git a/packages/ttsl-lang/src/language/validation/style.ts b/packages/ttsl-lang/src/language/validation/style.ts index d22061bd..14426926 100644 --- a/packages/ttsl-lang/src/language/validation/style.ts +++ b/packages/ttsl-lang/src/language/validation/style.ts @@ -3,6 +3,7 @@ import { isEmpty } from '../../helpers/collections.js'; import { isTslCall, isTslIndexedAccess, + isTslReturnStatement, TslCall, TslChainedExpression, TslFunction, @@ -191,7 +192,7 @@ export const functionResultListShouldNotBeEmpty = (services: TTSLServices) => { return; } - if (node.result && node.body.returnValue == undefined) { + if (node.result && node.body.statements.filter(isTslReturnStatement).at(0) == undefined) { accept('info', 'This result list can be removed.', { node, property: 'result', diff --git a/packages/ttsl-lang/src/language/validation/types.ts b/packages/ttsl-lang/src/language/validation/types.ts index c83f73a7..731a71ea 100644 --- a/packages/ttsl-lang/src/language/validation/types.ts +++ b/packages/ttsl-lang/src/language/validation/types.ts @@ -14,7 +14,7 @@ import { } from '../generated/ast.js'; import { getArguments } from '../helpers/nodeProperties.js'; import { TTSLServices } from '../ttsl-module.js'; -import {BooleanType, DictionaryType, FloatType, IntType, ListType, UnknownType } from '../typing/model.js'; +import {AnyType, BooleanType, DictionaryType, FloatType, IntType, ListType, UnknownType } from '../typing/model.js'; export const CODE_TYPE_CALLABLE_RECEIVER = 'type/callable-receiver'; export const CODE_TYPE_MISMATCH = 'type/mismatch'; @@ -40,7 +40,7 @@ export const callArgumentTypesMustMatchParameterTypes = (services: TTSLServices) const argumentType = typeComputer.computeType(argument); const parameterType = typeComputer.computeType(parameter); - if (!typeChecker.isSubtypeOf(argumentType, parameterType)) { + if (!(argumentType.toString == parameterType.toString || parameterType instanceof AnyType)) { accept('error', `Expected type '${parameterType}' but got '${argumentType}'.`, { node: argument, property: 'value', @@ -104,7 +104,7 @@ export const indexedAccessIndexMustHaveCorrectType = (services: TTSLServices) => const receiverType = typeComputer.computeType(node.receiver); if (receiverType instanceof ListType) { const indexType = typeComputer.computeType(node.index); - if (!typeChecker.isSubtypeOf(indexType, new IntType(false))) { + if (indexType instanceof IntType) { accept('error', `Expected type 'Int' but got '${indexType}'.`, { node, property: 'index', @@ -125,13 +125,13 @@ export const infixOperationOperandsMustHaveCorrectType = (services: TTSLServices switch (node.operator) { case 'or': case 'and': - if (node.leftOperand && !typeChecker.isSubtypeOf(leftType, new BooleanType(false))) { + if (node.leftOperand && !(leftType instanceof BooleanType)) { accept('error', `Expected type 'Boolean' but got '${leftType}'.`, { node: node.leftOperand, code: CODE_TYPE_MISMATCH, }); } - if (node.rightOperand && !typeChecker.isSubtypeOf(rightType, new BooleanType(false))) { + if (node.rightOperand && !(rightType instanceof BooleanType)) { accept('error', `Expected type 'Boolean' but got '${rightType}'.`, { node: node.rightOperand, code: CODE_TYPE_MISMATCH, @@ -148,8 +148,8 @@ export const infixOperationOperandsMustHaveCorrectType = (services: TTSLServices case '/': if ( node.leftOperand && - !typeChecker.isSubtypeOf(leftType, new FloatType(false)) && - !typeChecker.isSubtypeOf(leftType, new IntType(false)) + !(leftType instanceof FloatType) && + !(leftType instanceof IntType) ) { accept('error', `Expected type 'Float' or 'Int' but got '${leftType}'.`, { node: node.leftOperand, @@ -158,8 +158,8 @@ export const infixOperationOperandsMustHaveCorrectType = (services: TTSLServices } if ( node.rightOperand && - !typeChecker.isSubtypeOf(rightType, new FloatType(false)) && - !typeChecker.isSubtypeOf(rightType, new IntType(false)) + !(leftType instanceof FloatType) && + !(leftType instanceof IntType) ) { accept( 'error', @@ -230,7 +230,7 @@ export const parameterDefaultValueTypeMustMatchParameterType = (services: TTSLSe const defaultValueType = typeComputer.computeType(defaultValue); const parameterType = typeComputer.computeType(node); - if (!typeChecker.isSubtypeOf(defaultValueType, parameterType)) { + if (!(defaultValueType.toString == parameterType.toString)) { accept('error', `Expected type '${parameterType}' but got '${defaultValueType}'.`, { node, property: 'defaultValue', @@ -248,7 +248,7 @@ export const prefixOperationOperandMustHaveCorrectType = (services: TTSLServices const operandType = typeComputer.computeType(node.operand); switch (node.operator) { case 'not': - if (!typeChecker.isSubtypeOf(operandType, new BooleanType(false))) { + if (!(operandType instanceof BooleanType)) { accept('error', `Expected type 'Boolean' but got '${operandType}'.`, { node, property: 'operand', @@ -258,8 +258,8 @@ export const prefixOperationOperandMustHaveCorrectType = (services: TTSLServices return; case '-': if ( - !typeChecker.isSubtypeOf(operandType, new FloatType(false)) && - !typeChecker.isSubtypeOf(operandType, new IntType(false)) + !(operandType instanceof FloatType) && + !(operandType instanceof IntType) ) { accept( 'error', diff --git a/packages/ttsl-lang/tests/helpers/nodeFinder.test.ts b/packages/ttsl-lang/tests/helpers/nodeFinder.test.ts index 7df1ed0f..b2fb538b 100644 --- a/packages/ttsl-lang/tests/helpers/nodeFinder.test.ts +++ b/packages/ttsl-lang/tests/helpers/nodeFinder.test.ts @@ -50,7 +50,7 @@ describe('getNodeByLocation', async () => { expect( getNodeByLocation(services, { uri: document.uri.toString(), - range: { start: { line: 0, character: 6 }, end: { line: 0, character: 15 } }, + range: { start: { line: 0, character: 0 }, end: { line: 0, character: 15 } }, }), ).to.satisfy(isTslFunction); }); diff --git a/packages/ttsl-lang/tests/helpers/testChecks.test.ts b/packages/ttsl-lang/tests/helpers/testChecks.test.ts index f3a55f6b..21fead35 100644 --- a/packages/ttsl-lang/tests/helpers/testChecks.test.ts +++ b/packages/ttsl-lang/tests/helpers/testChecks.test.ts @@ -21,7 +21,7 @@ describe('findTestChecks', () => { }, { program: ` -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error `, expected: [ { @@ -32,7 +32,7 @@ describe('findTestChecks', () => { }, { program: ` -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error ${OPEN}${CLOSE} `, expected: [ @@ -48,9 +48,9 @@ ${OPEN}${CLOSE} }, { program: ` -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error ${OPEN}${CLOSE} -// $TEST$ syntax_error +# $TEST$ syntax_error ${OPEN}${CLOSE} `, expected: [ @@ -83,7 +83,7 @@ ${OPEN}${CLOSE} it('should report closing test markers without matching opening test marker', () => { const result = findTestChecks( ` - // $TEST$ no_syntax_error + # $TEST$ no_syntax_error ${OPEN}\n${CLOSE}${CLOSE} `, URI.parse(uri), @@ -98,7 +98,7 @@ ${OPEN}${CLOSE} it('should report opening test markers without matching closing test marker', () => { const result = findTestChecks( ` - // $TEST$ no_syntax_error + # $TEST$ no_syntax_error ${OPEN}\n${OPEN}${OPEN}${CLOSE} `, URI.parse(uri), @@ -113,7 +113,7 @@ ${OPEN}${CLOSE} it('should report if more ranges than comments are found', () => { const result = findTestChecks( ` - // $TEST$ no_syntax_error + # $TEST$ no_syntax_error ${OPEN}\n${CLOSE}${OPEN}\n${CLOSE} `, URI.parse(uri), @@ -137,7 +137,7 @@ ${OPEN}${CLOSE} it('should report if fewer ranges than comments are found if corresponding check is enabled', () => { const result = findTestChecks( ` - // $TEST$ no_syntax_error + # $TEST$ no_syntax_error `, URI.parse(uri), { failIfFewerRangesThanComments: true }, diff --git a/packages/ttsl-lang/tests/helpers/testComments.test.ts b/packages/ttsl-lang/tests/helpers/testComments.test.ts index 467fc4db..d4186aad 100644 --- a/packages/ttsl-lang/tests/helpers/testComments.test.ts +++ b/packages/ttsl-lang/tests/helpers/testComments.test.ts @@ -9,14 +9,14 @@ describe('findTestComments', () => { id: 'empty program', }, { - program: `// $TEST$ no_syntax_error`, + program: `# $TEST$ no_syntax_error`, expected: ['no_syntax_error'], id: 'single comment', }, { - program: `// $TEST$ no_syntax_error - // $TEST$ syntax_error - // another comment`, + program: `# $TEST$ no_syntax_error + # $TEST$ syntax_error + # another comment`, expected: ['no_syntax_error', 'syntax_error'], id: 'multiple comments', }, diff --git a/packages/ttsl-lang/tests/helpers/testComments.ts b/packages/ttsl-lang/tests/helpers/testComments.ts index 723518a8..5e9b603f 100644 --- a/packages/ttsl-lang/tests/helpers/testComments.ts +++ b/packages/ttsl-lang/tests/helpers/testComments.ts @@ -1,7 +1,7 @@ -const pattern = /\/\/\s*\$TEST\$(?[^\n]*)/gu; +const pattern = /#\s*\$TEST\$(?[^\n]*)/gu; /** - * Finds all test comments (`// $TEST$ ...`) in the given program. + * Finds all test comments (`# $TEST$ ...`) in the given program. * * @param program The program with test comments. * @return The list of test comments. diff --git a/packages/ttsl-lang/tests/helpers/testResources.test.ts b/packages/ttsl-lang/tests/helpers/testResources.test.ts index 33260e34..4d5a3b45 100644 --- a/packages/ttsl-lang/tests/helpers/testResources.test.ts +++ b/packages/ttsl-lang/tests/helpers/testResources.test.ts @@ -29,12 +29,8 @@ describe('listTestTTSLFiles', () => { const rootResourceName = 'helpers/listTTSLFiles'; const actual = listTestTTSLFiles(rootResourceName); const expected = [ - 'pipeline file.Tslpipe', - 'stub file.Tslstub', - 'test file.ttsl', - 'nested/pipeline file.Tslpipe', - 'nested/stub file.Tslstub', - 'nested/test file.ttsl', + 'function file.ttsl', + 'nested/function file.ttsl', ]; expectFileListsToMatch(rootResourceName, actual, expected); @@ -65,7 +61,7 @@ describe('listTestTTSLFilesGroupedByParentDirectory', () => { const actualValuesDirectlyInRoot = [...result.entries()].find( ([key]) => uriToShortenedTestResourceName(key, rootResourceName) === '', )!; - const expectedValuesDirectlyInRoot = ['pipeline file.Tslpipe', 'stub file.Tslstub', 'test file.ttsl']; + const expectedValuesDirectlyInRoot = ['function file.ttsl']; expectFileListsToMatch(rootResourceName, actualValuesDirectlyInRoot[1], expectedValuesDirectlyInRoot); // Compare the values, i.e. the files, in the nested directory @@ -73,9 +69,7 @@ describe('listTestTTSLFilesGroupedByParentDirectory', () => { ([key]) => uriToShortenedTestResourceName(key, rootResourceName) === 'nested', )!; const expectedValuesInNested = [ - 'nested/pipeline file.Tslpipe', - 'nested/stub file.Tslstub', - 'nested/test file.ttsl', + 'nested/function file.ttsl', ]; expectFileListsToMatch(rootResourceName, actualValuesInNested[1], expectedValuesInNested); }); diff --git a/packages/ttsl-lang/tests/language/documentation/safe-ds-comment-provider.test.ts b/packages/ttsl-lang/tests/language/documentation/safe-ds-comment-provider.test.ts index 4abfe355..4930f834 100644 --- a/packages/ttsl-lang/tests/language/documentation/safe-ds-comment-provider.test.ts +++ b/packages/ttsl-lang/tests/language/documentation/safe-ds-comment-provider.test.ts @@ -6,7 +6,6 @@ import { isTslFunction, isTslLocalVariable, isTslParameter, - isTslPlaceholder, isTslResult, isTslTypeParameter, } from '../../../src/language/generated/ast.js'; @@ -26,7 +25,7 @@ describe('TTSLCommentProvider', () => { function F(){} `, predicate: isTslFunction, - expectedComment: undefined, + expectedComment: testComment, }, { testName: 'commented module member (with annotations, with package)', @@ -56,10 +55,10 @@ describe('TTSLCommentProvider', () => { } `, predicate: isTslLocalVariable, - expectedComment: testComment, + expectedComment: undefined, }, { - testName: 'uncommented class member', + testName: 'uncommented function member', code: ` function F() { var a: Int = 0; @@ -95,7 +94,7 @@ describe('TTSLCommentProvider', () => { { testName: 'uncommented result', code: ` - segment mySegment(): Int {} + function F(): Int {} `, predicate: isTslResult, expectedComment: undefined, @@ -103,7 +102,7 @@ describe('TTSLCommentProvider', () => { { testName: 'commented type parameter', code: ` - constant c: List<${testComment} T> = [0, 1]; + constant c: List<${testComment} Int> = [0, 1]; `, predicate: isTslTypeParameter, expectedComment: undefined, @@ -111,7 +110,7 @@ describe('TTSLCommentProvider', () => { { testName: 'uncommented type parameter', code: ` - constant c: List = [0, 1]; + constant c: List = [0, 1]; `, predicate: isTslTypeParameter, expectedComment: undefined, @@ -130,7 +129,7 @@ describe('TTSLCommentProvider', () => { { testName: 'uncommented not-a-declaration', code: ` - segment mySegment(p: Int) { + function F(p: Int) { f(); } `, @@ -145,6 +144,7 @@ describe('TTSLCommentProvider', () => { throw new AssertionError({ message: 'Node not found.' }); } + console.log(node.$type + ': ' + commentProvider.getComment(node) + '\n'); expect(commentProvider.getComment(node)).toStrictEqual(expectedComment); }); }); diff --git a/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/argumentToParameter.test.ts b/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/argumentToParameter.test.ts index 95c37b1b..c9f8116e 100644 --- a/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/argumentToParameter.test.ts +++ b/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/argumentToParameter.test.ts @@ -18,7 +18,7 @@ describe('TTSLNodeMapper', () => { const code = ` fun f(p: Int) {} - pipeline myPipeline { + function myFunction () { f(unresolved = 1); } `; @@ -32,7 +32,7 @@ describe('TTSLNodeMapper', () => { const code = ` fun f(p1: Int, p2: Int, p3: Int) {} - pipeline myPipeline { + function myFunction () { f(p2 = 1, p3 = 1, p1 = 1); } `; @@ -48,7 +48,7 @@ describe('TTSLNodeMapper', () => { const code = ` fun f(p1: Int = 0, p2: Int, p3: Int) {} - pipeline myPipeline { + function myFunction () { f(1, 2, 3); } `; @@ -62,7 +62,7 @@ describe('TTSLNodeMapper', () => { const code = ` fun f(p1: Int = 0, p2: Int, p3: Int) {} - pipeline myPipeline { + function myFunction () { f(p2 = 1, 2, 3); } `; @@ -76,7 +76,7 @@ describe('TTSLNodeMapper', () => { const code = ` fun f(p1: Int, p2: Int) {} - pipeline myPipeline { + function myFunction () { f(1, 2, 3); } `; diff --git a/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/callToCallable.test.ts b/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/callToCallable.test.ts index 8afa4648..b7387090 100644 --- a/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/callToCallable.test.ts +++ b/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/callToCallable.test.ts @@ -21,7 +21,7 @@ describe('TTSLNodeMapper', () => { it('should return undefined if receiver is unresolved', async () => { const code = ` @unresolved - pipeline myPipeline {} + function myFunction () {} `; const call = await getNodeOfType(services, code, isTslAbstractCall); @@ -48,7 +48,7 @@ describe('TTSLNodeMapper', () => { describe('calls', () => { it('should return undefined if receiver is unresolved', async () => { const code = ` - pipeline myPipeline { + function myFunction () { unresolved(); } `; @@ -61,7 +61,7 @@ describe('TTSLNodeMapper', () => { const code = ` enum MyEnum - pipeline myPipeline { + function myFunction () { MyEnum(); } `; @@ -74,7 +74,7 @@ describe('TTSLNodeMapper', () => { const code = ` annotation MyAnnotation - pipeline myPipeline { + function myFunction () { MyAnnotation(); } `; @@ -87,7 +87,7 @@ describe('TTSLNodeMapper', () => { const code = ` annotation MyAnnotation - pipeline myPipeline { + function myFunction () { val alias = MyAnnotation; alias(); } @@ -99,7 +99,7 @@ describe('TTSLNodeMapper', () => { it('should return the called block lambda (aliased)', async () => { const code = ` - pipeline myPipeline { + function myFunction () { val alias = () {}; alias(); } @@ -136,7 +136,7 @@ describe('TTSLNodeMapper', () => { const code = ` class MyClass - pipeline myPipeline { + function myFunction () { MyClass(); } `; @@ -149,7 +149,7 @@ describe('TTSLNodeMapper', () => { const code = ` class MyClass - pipeline myPipeline { + function myFunction () { val alias = MyClass; alias(); } @@ -165,7 +165,7 @@ describe('TTSLNodeMapper', () => { MyEnumVariant } - pipeline myPipeline { + function myFunction () { MyEnum.MyEnumVariant(); } `; @@ -180,7 +180,7 @@ describe('TTSLNodeMapper', () => { MyEnumVariant } - pipeline myPipeline { + function myFunction () { val alias = MyEnum.MyEnumVariant; alias(); } @@ -196,7 +196,7 @@ describe('TTSLNodeMapper', () => { MyEnumVariant(p: Int) } - pipeline myPipeline { + function myFunction () { val alias = MyEnum.MyEnumVariant; alias(1); } @@ -208,7 +208,7 @@ describe('TTSLNodeMapper', () => { it('should return the called expression lambda (aliased)', async () => { const code = ` - pipeline myPipeline { + function myFunction () { val alias = () -> 0; alias() } @@ -222,7 +222,7 @@ describe('TTSLNodeMapper', () => { const code = ` fun myFunction() - pipeline myPipeline { + function myFunction () { myFunction(); } `; @@ -235,7 +235,7 @@ describe('TTSLNodeMapper', () => { const code = ` fun myFunction() - pipeline myPipeline { + function myFunction () { val alias = myFunction; alias(); } @@ -249,7 +249,7 @@ describe('TTSLNodeMapper', () => { const code = ` segment mySegment() {} - pipeline myPipeline { + function myFunction () { mySegment(); } `; @@ -262,7 +262,7 @@ describe('TTSLNodeMapper', () => { const code = ` segment mySegment() {} - pipeline myPipeline { + function myFunction () { val alias = mySegment; alias(); } diff --git a/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/parameterToReferences.test.ts b/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/parameterToReferences.test.ts index 1c7c0b8f..dcc6c452 100644 --- a/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/parameterToReferences.test.ts +++ b/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/parameterToReferences.test.ts @@ -15,7 +15,7 @@ describe('TTSLNodeMapper', () => { it('should return references in default values', async () => { const code = ` - fun myFunction(p1: Int, p2: Int = p1) + function myFunction(p1: Int, p2: Int = p1) {} `; const parameter = await getNodeOfType(services, code, isTslParameter); @@ -24,7 +24,7 @@ describe('TTSLNodeMapper', () => { it('should return references directly in body', async () => { const code = ` - segment mySegment(p1: Int) { + function myFunction(p1: Int) { p1; p1; }; @@ -34,44 +34,18 @@ describe('TTSLNodeMapper', () => { expect(nodeMapper.parameterToReferences(parameter).toArray()).toHaveLength(2); }); - it('should return references nested in body', async () => { - const code = ` - segment mySegment(p1: Int) { - () { - p1; - }; - () -> p1; - }; - `; - - const parameter = await getNodeOfType(services, code, isTslParameter); - expect(nodeMapper.parameterToReferences(parameter).toArray()).toHaveLength(2); - }); - it('should return references in own parameter list', async () => { const code = ` - segment mySegment(p1: Int, p2: Int = p1) {}; + function myFunction(p1: Int, p2: Int = p1) {}; `; const parameter = await getNodeOfType(services, code, isTslParameter); expect(nodeMapper.parameterToReferences(parameter).toArray()).toHaveLength(1); }); - it('should return references in nested parameter list', async () => { - const code = ` - segment mySegment(p1: Int) { - (p2: Int = p1) {}; - (p2: Int = p1) -> 1; - }; - `; - - const parameter = await getNodeOfType(services, code, isTslParameter); - expect(nodeMapper.parameterToReferences(parameter).toArray()).toHaveLength(2); - }); - it('should not return references to other parameters', async () => { const code = ` - segment mySegment(p1: Int, p2: Int) { + function myFunction(p1: Int, p2: Int) { p1; p2; }; diff --git a/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/placeholdersToReferences.test.ts b/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/placeholdersToReferences.test.ts index 79f91cc3..fbc6b725 100644 --- a/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/placeholdersToReferences.test.ts +++ b/packages/ttsl-lang/tests/language/helpers/safe-ds-node-mapper/placeholdersToReferences.test.ts @@ -27,7 +27,7 @@ describe('TTSLNodeMapper', () => { it('should return references directly in body', async () => { const code = ` - pipeline myPipeline { + function myFunction () { val a1 = 1; a1; @@ -73,7 +73,7 @@ describe('TTSLNodeMapper', () => { it('should not return references to other placeholders', async () => { const code = ` - pipeline myPipeline { + function myFunction () { val a1 = 1; val a2 = 2; diff --git a/packages/ttsl-lang/tests/language/lsp/safe-ds-call-hierarchy-provider.test.ts b/packages/ttsl-lang/tests/language/lsp/safe-ds-call-hierarchy-provider.test.ts index 7220c05b..f5f6ff21 100644 --- a/packages/ttsl-lang/tests/language/lsp/safe-ds-call-hierarchy-provider.test.ts +++ b/packages/ttsl-lang/tests/language/lsp/safe-ds-call-hierarchy-provider.test.ts @@ -23,7 +23,7 @@ describe('TTSLCallHierarchyProvider', async () => { class »«C() class D() - pipeline myPipeline { + function myFunction () { C(); D(); } @@ -41,7 +41,7 @@ describe('TTSLCallHierarchyProvider', async () => { class »«C() class D() - pipeline myPipeline { + function myFunction () { C(); () -> C(); () { C() }; @@ -61,7 +61,7 @@ describe('TTSLCallHierarchyProvider', async () => { class »«C() class D() - pipeline myPipeline { + function myFunction () { C(); C(); D(); diff --git a/packages/ttsl-lang/tests/language/lsp/safe-ds-inlay-hint-provider.test.ts b/packages/ttsl-lang/tests/language/lsp/safe-ds-inlay-hint-provider.test.ts index bcf740ef..776b1967 100644 --- a/packages/ttsl-lang/tests/language/lsp/safe-ds-inlay-hint-provider.test.ts +++ b/packages/ttsl-lang/tests/language/lsp/safe-ds-inlay-hint-provider.test.ts @@ -17,8 +17,8 @@ describe('TTSLInlayHintProvider', async () => { code: ` fun f(p: Int) - pipeline myPipeline { - // $TEST$ before "p = " + function myFunction () { + # $TEST$ before "p = " f(»«1); } `, @@ -28,7 +28,7 @@ describe('TTSLInlayHintProvider', async () => { code: ` fun f() - pipeline myPipeline { + function myFunction () { f(1); } `, @@ -38,7 +38,7 @@ describe('TTSLInlayHintProvider', async () => { code: ` fun f(p: Int) - pipeline myPipeline { + function myFunction () { f(p = 1); } `, @@ -46,9 +46,9 @@ describe('TTSLInlayHintProvider', async () => { { testName: 'block lambda result', code: ` - pipeline myPipeline { + function myFunction () { () { - // $TEST$ after ": literal<1>" + # $TEST$ after ": literal<1>" yield r»« = 1; }; } @@ -57,8 +57,8 @@ describe('TTSLInlayHintProvider', async () => { { testName: 'placeholder', code: ` - pipeline myPipeline { - // $TEST$ after ": literal<1>" + function myFunction () { + # $TEST$ after ": literal<1>" val x»« = 1; } `, @@ -66,7 +66,7 @@ describe('TTSLInlayHintProvider', async () => { { testName: 'wildcard', code: ` - pipeline myPipeline { + function myFunction () { _ = 1; } `, @@ -75,7 +75,7 @@ describe('TTSLInlayHintProvider', async () => { testName: 'yield', code: ` segment s() -> r: Int { - // $TEST$ after ": literal<1>" + # $TEST$ after ": literal<1>" yield r»« = 1; } `, @@ -95,7 +95,7 @@ describe('TTSLInlayHintProvider', async () => { */ fun f(p: Int) - pipeline myPipeline { + function myFunction () { f(1); } `; @@ -114,7 +114,7 @@ describe('TTSLInlayHintProvider', async () => { */ class C() - pipeline myPipeline { + function myFunction () { val a = C(); } `, @@ -129,7 +129,7 @@ describe('TTSLInlayHintProvider', async () => { fun f() -> e: E - pipeline myPipeline { + function myFunction () { val a = f(); } `, @@ -144,7 +144,7 @@ describe('TTSLInlayHintProvider', async () => { V } - pipeline myPipeline { + function myFunction () { val a = E.V; } `, @@ -188,7 +188,7 @@ const getActualSimpleInlayHints = async (code: string): Promise { - const testChecks = findTestChecks(code, URI.file('file:///test.ttsl'), { failIfFewerRangesThanComments: true }); + const testChecks = findTestChecks(code, URI.file('file:#/test.ttsl'), { failIfFewerRangesThanComments: true }); if (testChecks.isErr) { throw new Error(testChecks.error.message); } diff --git a/packages/ttsl-lang/tests/language/lsp/safe-ds-signature-help-provider.test.ts b/packages/ttsl-lang/tests/language/lsp/safe-ds-signature-help-provider.test.ts index a38b5465..221e5e89 100644 --- a/packages/ttsl-lang/tests/language/lsp/safe-ds-signature-help-provider.test.ts +++ b/packages/ttsl-lang/tests/language/lsp/safe-ds-signature-help-provider.test.ts @@ -14,7 +14,7 @@ describe('TTSLSignatureHelpProvider', async () => { const code = ` fun f(p: Int) - pipeline myPipeline { + function myFunction () { f(»«); } `; @@ -29,7 +29,7 @@ describe('TTSLSignatureHelpProvider', async () => { code: ` fun f(p: Int) - pipeline myPipeline { + function myFunction () { f(»«); } `, @@ -40,7 +40,7 @@ describe('TTSLSignatureHelpProvider', async () => { code: ` fun f(p: Int) - pipeline myPipeline { + function myFunction () { f(»«, ); } `, @@ -51,7 +51,7 @@ describe('TTSLSignatureHelpProvider', async () => { code: ` fun f(p: Int) - pipeline myPipeline { + function myFunction () { f(1, »«); } `, @@ -71,7 +71,7 @@ describe('TTSLSignatureHelpProvider', async () => { { testName: 'unresolved callable', code: ` - pipeline myPipeline { + function myFunction () { f(»«); } `, @@ -86,7 +86,7 @@ describe('TTSLSignatureHelpProvider', async () => { annotation A(p: Int) @A(»«) - pipeline myPipeline {} + function myFunction () {} `, expectedSignature: [ { @@ -111,7 +111,7 @@ describe('TTSLSignatureHelpProvider', async () => { */ class C(p: Int) - pipeline myPipeline { + function myFunction () { C(»«); } `, @@ -138,7 +138,7 @@ describe('TTSLSignatureHelpProvider', async () => { */ fun f(p: Int) - pipeline myPipeline { + function myFunction () { f(»«); } `, @@ -160,7 +160,7 @@ describe('TTSLSignatureHelpProvider', async () => { { testName: 'call (lambda)', code: ` - pipeline myPipeline { + function myFunction () { ((p: Int) {})(»«); } `, @@ -182,7 +182,7 @@ describe('TTSLSignatureHelpProvider', async () => { code: ` fun f(p: Int = 0) - pipeline myPipeline { + function myFunction () { f(»«); } `, diff --git a/packages/ttsl-lang/tests/language/scoping/scoping.test.ts b/packages/ttsl-lang/tests/language/scoping/scoping.test.ts index 5d4991ba..2a5fde3b 100644 --- a/packages/ttsl-lang/tests/language/scoping/scoping.test.ts +++ b/packages/ttsl-lang/tests/language/scoping/scoping.test.ts @@ -70,15 +70,6 @@ describe('scoping', async () => { } }); - it('should resolve members on literals', async () => { - const code = ` - function MyFunction() { - 1.toString(); - } - `; - await expectNoLinkingErrors(code); - }); - it('should resolve members on literal types', async () => { const code = ` function MyFunction(p: String) { diff --git a/packages/ttsl-lang/tests/language/typing/type checker/canBeTypeOfConstantParameter.test.ts b/packages/ttsl-lang/tests/language/typing/type checker/canBeTypeOfConstantParameter.test.ts index 2825fdd6..9d77115d 100644 --- a/packages/ttsl-lang/tests/language/typing/type checker/canBeTypeOfConstantParameter.test.ts +++ b/packages/ttsl-lang/tests/language/typing/type checker/canBeTypeOfConstantParameter.test.ts @@ -10,7 +10,7 @@ describe('TTSLTypeChecker', async () => { const testCases: CanBeTypeOfConstantParameterTest[] = [ { type: new AnyType(false), - expected: false, + expected: true, }, { type: new BooleanType(false), diff --git a/packages/ttsl-lang/tests/resources/call graph/annotation call.sdstest b/packages/ttsl-lang/tests/resources/call graph/annotation call.sdstest index cd5e95f0..146e5ce8 100644 --- a/packages/ttsl-lang/tests/resources/call graph/annotation call.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/annotation call.sdstest @@ -2,7 +2,7 @@ package tests.callGraph.annotationCall annotation MyAnnotation -pipeline myPipeline { - // $TEST$ ["undefined"] +function myFunction () { + # $TEST$ ["undefined"] »MyAnnotation()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/block lambda.sdstest b/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/block lambda.sdstest index 4d4aff34..c854dad0 100644 --- a/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/block lambda.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/block lambda.sdstest @@ -2,12 +2,12 @@ package tests.callGraph.blockLambdaCall.argument.blockLambda @Pure fun f() -pipeline myPipeline { +function myFunction () { val lambda = (param1: (param: () -> ()) -> ()) { param1(f); }; - // $TEST$ ["$blockLambda", "$blockLambda", "f"] + # $TEST$ ["$blockLambda", "$blockLambda", "f"] »lambda((param) { param(); })«; diff --git a/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/callable does not get called.sdstest b/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/callable does not get called.sdstest index f792a880..21b0ad63 100644 --- a/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/callable does not get called.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/callable does not get called.sdstest @@ -2,9 +2,9 @@ package tests.callGraph.blockLambdaCall.argument.callableDoesNotGetCalled @Pure fun f() -pipeline myPipeline { +function myFunction () { val lambda = (param: () -> ()) {}; - // $TEST$ ["$blockLambda"] + # $TEST$ ["$blockLambda"] »lambda(f)«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/expression lambda.sdstest b/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/expression lambda.sdstest index b57b5698..bd7562ce 100644 --- a/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/expression lambda.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/expression lambda.sdstest @@ -2,11 +2,11 @@ package tests.callGraph.blockLambdaCall.argument.expressionLambda @Pure fun f() -pipeline myPipeline { +function myFunction () { val lambda = (param1: (param: () -> ()) -> ()) { param1(f); }; - // $TEST$ ["$blockLambda", "$expressionLambda", "f"] + # $TEST$ ["$blockLambda", "$expressionLambda", "f"] »lambda((param) -> param())«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/function.sdstest b/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/function.sdstest index cd871f01..29b15f41 100644 --- a/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/function.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/function.sdstest @@ -2,11 +2,11 @@ package tests.callGraph.blockLambdaCall.argument.function @Pure fun f() -pipeline myPipeline { +function myFunction () { val lambda = (param: () -> ()) { param(); }; - // $TEST$ ["$blockLambda", "f"] + # $TEST$ ["$blockLambda", "f"] »lambda(f)«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/segment.sdstest b/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/segment.sdstest index 846cf3ec..f05ac5bf 100644 --- a/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/segment.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/segment.sdstest @@ -2,12 +2,12 @@ package tests.callGraph.blockLambdaCall.argument.`segment` @Pure fun f() -pipeline myPipeline { +function myFunction () { val lambda = (param1: (param: () -> ()) -> ()) { param1(f); }; - // $TEST$ ["$blockLambda", "mySegment", "f"] + # $TEST$ ["$blockLambda", "mySegment", "f"] »lambda(mySegment)«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/block lambda call/basic.sdstest b/packages/ttsl-lang/tests/resources/call graph/block lambda call/basic.sdstest index 748803de..5ca27c5d 100644 --- a/packages/ttsl-lang/tests/resources/call graph/block lambda call/basic.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/block lambda call/basic.sdstest @@ -1,8 +1,8 @@ package tests.callGraph.blockLambdaCall.basic -pipeline myPipeline { +function myFunction () { val lambda = () {}; - // $TEST$ ["$blockLambda"] + # $TEST$ ["$blockLambda"] »lambda()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/block lambda call/body/function call in nested lambda.sdstest b/packages/ttsl-lang/tests/resources/call graph/block lambda call/body/function call in nested lambda.sdstest index 8c151f05..447206a3 100644 --- a/packages/ttsl-lang/tests/resources/call graph/block lambda call/body/function call in nested lambda.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/block lambda call/body/function call in nested lambda.sdstest @@ -2,9 +2,9 @@ package tests.callGraph.blockLambdaCall.body.functionCallInNestedLambda @Pure fun f() -pipeline myPipeline { +function myFunction () { val lambda = () { () -> f(); }; - // $TEST$ ["$blockLambda"] + # $TEST$ ["$blockLambda"] »lambda()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/block lambda call/body/function call.sdstest b/packages/ttsl-lang/tests/resources/call graph/block lambda call/body/function call.sdstest index 0b7b9583..383279b0 100644 --- a/packages/ttsl-lang/tests/resources/call graph/block lambda call/body/function call.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/block lambda call/body/function call.sdstest @@ -2,9 +2,9 @@ package tests.callGraph.blockLambdaCall.body.functionCall @Pure fun f() -pipeline myPipeline { +function myFunction () { val lambda = () { f(); }; - // $TEST$ ["$blockLambda", "f"] + # $TEST$ ["$blockLambda", "f"] »lambda()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/block lambda call/default value/call.sdstest b/packages/ttsl-lang/tests/resources/call graph/block lambda call/default value/call.sdstest index 1db677a7..0b2e06c0 100644 --- a/packages/ttsl-lang/tests/resources/call graph/block lambda call/default value/call.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/block lambda call/default value/call.sdstest @@ -2,11 +2,11 @@ package tests.callGraph.blockLambdaCall.defaultValue.call @Pure fun default() -> r: Any -pipeline myPipeline { +function myFunction () { val lambda = ( f: Any = default() ) {}; - // $TEST$ ["$blockLambda", "default"] + # $TEST$ ["$blockLambda", "default"] »lambda()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/block lambda call/default value/callable.sdstest b/packages/ttsl-lang/tests/resources/call graph/block lambda call/default value/callable.sdstest index 6bcb97e8..4a8c5c7a 100644 --- a/packages/ttsl-lang/tests/resources/call graph/block lambda call/default value/callable.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/block lambda call/default value/callable.sdstest @@ -2,13 +2,13 @@ package tests.callGraph.blockLambdaCall.defaultValue.callable @Pure fun default() -pipeline myPipeline { +function myFunction () { val lambda = ( f: () -> () = default ) { f(); }; - // $TEST$ ["$blockLambda", "default"] + # $TEST$ ["$blockLambda", "default"] »lambda()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/block lambda call/default value/previous parameter.sdstest b/packages/ttsl-lang/tests/resources/call graph/block lambda call/default value/previous parameter.sdstest index 91200b0c..b9348fcd 100644 --- a/packages/ttsl-lang/tests/resources/call graph/block lambda call/default value/previous parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/block lambda call/default value/previous parameter.sdstest @@ -2,12 +2,12 @@ package tests.callGraph.blockLambdaCall.defaultValue.previousParameter @Pure fun default() -> result: Any -pipeline myPipeline { +function myFunction () { val lambda = ( f: () -> (result: Any) = default, g: Any = f() ) {}; - // $TEST$ ["$blockLambda", "default"] + # $TEST$ ["$blockLambda", "default"] »lambda()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/block lambda call/null safe.sdstest b/packages/ttsl-lang/tests/resources/call graph/block lambda call/null safe.sdstest index 40999c36..77cdbf94 100644 --- a/packages/ttsl-lang/tests/resources/call graph/block lambda call/null safe.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/block lambda call/null safe.sdstest @@ -1,8 +1,8 @@ package tests.callGraph.blockLambdaCall.nullSafe -pipeline myPipeline { +function myFunction () { val lambda = () {}; - // $TEST$ ["$blockLambda"] + # $TEST$ ["$blockLambda"] »lambda?()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/callable type call.sdstest b/packages/ttsl-lang/tests/resources/call graph/callable type call.sdstest index 1ca18602..307c650b 100644 --- a/packages/ttsl-lang/tests/resources/call graph/callable type call.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/callable type call.sdstest @@ -1,6 +1,6 @@ package tests.callGraph.callableTypeCall segment mySegment(param: () -> ()) { - // $TEST$ ["param"] + # $TEST$ ["param"] »param()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/callable/block lambda.sdstest b/packages/ttsl-lang/tests/resources/call graph/callable/block lambda.sdstest index 891b0266..5210199c 100644 --- a/packages/ttsl-lang/tests/resources/call graph/callable/block lambda.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/callable/block lambda.sdstest @@ -3,7 +3,7 @@ package tests.callGraph.callable.blockLambda @Pure fun f() -> r: Any @Pure fun g() -> r: Any -pipeline myPipeline { - // $TEST$ ["$blockLambda", "f", "g"] +function myFunction () { + # $TEST$ ["$blockLambda", "f", "g"] »(param: Any = f()) { g(); }«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/callable/class.sdstest b/packages/ttsl-lang/tests/resources/call graph/callable/class.sdstest index 68ec2646..2ec64d4e 100644 --- a/packages/ttsl-lang/tests/resources/call graph/callable/class.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/callable/class.sdstest @@ -3,5 +3,5 @@ package tests.callGraph.callable.`class` @Pure fun f() -> r: Any @Pure fun g() -// $TEST$ ["MyClass", "f", "g"] +# $TEST$ ["MyClass", "f", "g"] »class MyClass(param1: Any = f(), param2: () -> () = g)« diff --git a/packages/ttsl-lang/tests/resources/call graph/callable/enum variant.sdstest b/packages/ttsl-lang/tests/resources/call graph/callable/enum variant.sdstest index 8fda813f..fbdd0f18 100644 --- a/packages/ttsl-lang/tests/resources/call graph/callable/enum variant.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/callable/enum variant.sdstest @@ -3,7 +3,7 @@ package tests.callGraph.callable.enumVariant @Pure fun f() -> r: Any @Pure fun g() -// $TEST$ ["MyEnumVariant", "f", "g"] +# $TEST$ ["MyEnumVariant", "f", "g"] enum MyEnum { »MyEnumVariant(param1: Any = f(), param2: () -> () = g)« } diff --git a/packages/ttsl-lang/tests/resources/call graph/callable/expression lambda.sdstest b/packages/ttsl-lang/tests/resources/call graph/callable/expression lambda.sdstest index 1b6af2fd..0dfcf312 100644 --- a/packages/ttsl-lang/tests/resources/call graph/callable/expression lambda.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/callable/expression lambda.sdstest @@ -3,7 +3,7 @@ package tests.callGraph.callable.expressionLambda @Pure fun f() -> r: Any @Pure fun g() -> r: Any -pipeline myPipeline { - // $TEST$ ["$expressionLambda", "f", "g"] +function myFunction () { + # $TEST$ ["$expressionLambda", "f", "g"] »(param: Any = f()) -> g()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/callable/function.sdstest b/packages/ttsl-lang/tests/resources/call graph/callable/function.sdstest index 8d8659fe..756f8b3c 100644 --- a/packages/ttsl-lang/tests/resources/call graph/callable/function.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/callable/function.sdstest @@ -3,5 +3,5 @@ package tests.callGraph.callable.function @Pure fun f() -> r: Any @Pure fun g() -// $TEST$ ["myFunction", "f", "g"] +# $TEST$ ["myFunction", "f", "g"] @Pure »fun myFunction(param1: Any = f(), param2: () -> () = g)« diff --git a/packages/ttsl-lang/tests/resources/call graph/callable/segment.sdstest b/packages/ttsl-lang/tests/resources/call graph/callable/segment.sdstest index 47286ed2..a50d3858 100644 --- a/packages/ttsl-lang/tests/resources/call graph/callable/segment.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/callable/segment.sdstest @@ -3,7 +3,7 @@ package tests.callGraph.callable.`segment` @Pure fun f() -> r: Any @Pure fun g() -> r: Any -// $TEST$ ["mySegment", "f", "g"] +# $TEST$ ["mySegment", "f", "g"] »segment mySegment(param: Any = f()) { g(); }« diff --git a/packages/ttsl-lang/tests/resources/call graph/class call/argument/call.sdstest b/packages/ttsl-lang/tests/resources/call graph/class call/argument/call.sdstest index 90de9e57..c7e482b5 100644 --- a/packages/ttsl-lang/tests/resources/call graph/class call/argument/call.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/class call/argument/call.sdstest @@ -7,7 +7,7 @@ class MyClass( f: Any = Default() ) -pipeline myPipeline { - // $TEST$ ["MyClass"] +function myFunction () { + # $TEST$ ["MyClass"] »MyClass(Passed())«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/class call/argument/callable.sdstest b/packages/ttsl-lang/tests/resources/call graph/class call/argument/callable.sdstest index 90b51076..bd567855 100644 --- a/packages/ttsl-lang/tests/resources/call graph/class call/argument/callable.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/class call/argument/callable.sdstest @@ -7,7 +7,7 @@ class MyClass( f: () -> () = Default ) -pipeline myPipeline { - // $TEST$ ["MyClass", "Passed"] +function myFunction () { + # $TEST$ ["MyClass", "Passed"] »MyClass(Passed)«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/class call/argument/other.sdstest b/packages/ttsl-lang/tests/resources/call graph/class call/argument/other.sdstest index 1d4f722f..1dbb72c3 100644 --- a/packages/ttsl-lang/tests/resources/call graph/class call/argument/other.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/class call/argument/other.sdstest @@ -7,7 +7,7 @@ class MyClass( f: Any = Default() ) -pipeline myPipeline { - // $TEST$ ["MyClass"] +function myFunction () { + # $TEST$ ["MyClass"] »MyClass(1)«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/class call/basic.sdstest b/packages/ttsl-lang/tests/resources/call graph/class call/basic.sdstest index 4f987788..e07ff838 100644 --- a/packages/ttsl-lang/tests/resources/call graph/class call/basic.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/class call/basic.sdstest @@ -2,7 +2,7 @@ package tests.callGraph.classCall.basic class MyClass() -pipeline myPipeline { - // $TEST$ ["MyClass"] +function myFunction () { + # $TEST$ ["MyClass"] »MyClass()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/class call/default value/call.sdstest b/packages/ttsl-lang/tests/resources/call graph/class call/default value/call.sdstest index 01780506..448690e5 100644 --- a/packages/ttsl-lang/tests/resources/call graph/class call/default value/call.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/class call/default value/call.sdstest @@ -7,7 +7,7 @@ class MyClass( f: Any = Default() ) -pipeline myPipeline { - // $TEST$ ["MyClass", "Default"] +function myFunction () { + # $TEST$ ["MyClass", "Default"] »MyClass()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/class call/default value/callable.sdstest b/packages/ttsl-lang/tests/resources/call graph/class call/default value/callable.sdstest index a32058d8..8d07f566 100644 --- a/packages/ttsl-lang/tests/resources/call graph/class call/default value/callable.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/class call/default value/callable.sdstest @@ -7,7 +7,7 @@ class MyClass( f: () -> () = Default ) -pipeline myPipeline { - // $TEST$ ["MyClass", "Default"] +function myFunction () { + # $TEST$ ["MyClass", "Default"] »MyClass()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/class call/default value/previous parameter.sdstest b/packages/ttsl-lang/tests/resources/call graph/class call/default value/previous parameter.sdstest index 3b944e28..7885648a 100644 --- a/packages/ttsl-lang/tests/resources/call graph/class call/default value/previous parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/class call/default value/previous parameter.sdstest @@ -7,7 +7,7 @@ class MyClass( g: Any = f() ) -pipeline myPipeline { - // $TEST$ ["MyClass", "default", "default"] +function myFunction () { + # $TEST$ ["MyClass", "default", "default"] »MyClass()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/class call/null safe.sdstest b/packages/ttsl-lang/tests/resources/call graph/class call/null safe.sdstest index 820cc675..c2f93934 100644 --- a/packages/ttsl-lang/tests/resources/call graph/class call/null safe.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/class call/null safe.sdstest @@ -2,7 +2,7 @@ package tests.callGraph.classCall.nullSafe class MyClass() -pipeline myPipeline { - // $TEST$ ["MyClass"] +function myFunction () { + # $TEST$ ["MyClass"] »MyClass?()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/closure/block lambda passed as argument.sdstest b/packages/ttsl-lang/tests/resources/call graph/closure/block lambda passed as argument.sdstest index 225fb80e..da08fecf 100644 --- a/packages/ttsl-lang/tests/resources/call graph/closure/block lambda passed as argument.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/closure/block lambda passed as argument.sdstest @@ -12,7 +12,7 @@ segment mySegment2(param2: () -> ()) { param2(); } -pipeline myPipeline { - // $TEST$ ["mySegment1", "mySegment2", "$blockLambda", "$blockLambda", "f"] +function myFunction () { + # $TEST$ ["mySegment1", "mySegment2", "$blockLambda", "$blockLambda", "f"] »mySegment1(() { f(); })«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/closure/block lambda returned.sdstest b/packages/ttsl-lang/tests/resources/call graph/closure/block lambda returned.sdstest index 07f2d53a..89fa2e96 100644 --- a/packages/ttsl-lang/tests/resources/call graph/closure/block lambda returned.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/closure/block lambda returned.sdstest @@ -2,7 +2,7 @@ package tests.callGraph.closure.blockLambdaReturned @Pure fun f() -pipeline myPipeline { +function myFunction () { val lambda = (param: () -> ()) { yield f = () { param(); @@ -10,6 +10,6 @@ pipeline myPipeline { }; val closure = lambda(f); - // $TEST$ ["$blockLambda", "f"] + # $TEST$ ["$blockLambda", "f"] »closure()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/closure/expression lambda passed as argument.sdstest b/packages/ttsl-lang/tests/resources/call graph/closure/expression lambda passed as argument.sdstest index 14a793f9..81412831 100644 --- a/packages/ttsl-lang/tests/resources/call graph/closure/expression lambda passed as argument.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/closure/expression lambda passed as argument.sdstest @@ -10,7 +10,7 @@ segment mySegment2(param2: () -> ()) { param2(); } -pipeline myPipeline { - // $TEST$ ["mySegment1", "mySegment2", "$expressionLambda", "$expressionLambda", "f"] +function myFunction () { + # $TEST$ ["mySegment1", "mySegment2", "$expressionLambda", "$expressionLambda", "f"] »mySegment1(() -> f())«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/closure/expression lambda returned.sdstest b/packages/ttsl-lang/tests/resources/call graph/closure/expression lambda returned.sdstest index d8156494..29da84cd 100644 --- a/packages/ttsl-lang/tests/resources/call graph/closure/expression lambda returned.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/closure/expression lambda returned.sdstest @@ -2,12 +2,12 @@ package tests.callGraph.closure.expressionLambdaReturned @Pure fun f() -pipeline myPipeline { +function myFunction () { val lambda = (param: () -> ()) -> () -> param(); val closure = lambda(f); - // $TEST$ ["$expressionLambda", "f"] + # $TEST$ ["$expressionLambda", "f"] »closure()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/default value handling in entry point.sdstest b/packages/ttsl-lang/tests/resources/call graph/default value handling in entry point.sdstest index 1aadbec4..883d1b18 100644 --- a/packages/ttsl-lang/tests/resources/call graph/default value handling in entry point.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/default value handling in entry point.sdstest @@ -7,6 +7,6 @@ package tests.callGraph.defaultValueHandlingInEntryPoint @Pure fun default() -> r: Any segment mySegment(param: () -> () = default) { - // $TEST$ ["param"] + # $TEST$ ["param"] »param()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/enum variant call/argument/call.sdstest b/packages/ttsl-lang/tests/resources/call graph/enum variant call/argument/call.sdstest index 11d19c1d..30ac130e 100644 --- a/packages/ttsl-lang/tests/resources/call graph/enum variant call/argument/call.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/enum variant call/argument/call.sdstest @@ -9,7 +9,7 @@ enum MyEnum { ) } -pipeline myPipeline { - // $TEST$ ["MyVariant"] +function myFunction () { + # $TEST$ ["MyVariant"] »MyEnum.MyVariant(passed())«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/enum variant call/argument/callable.sdstest b/packages/ttsl-lang/tests/resources/call graph/enum variant call/argument/callable.sdstest index c2846b01..37dc1622 100644 --- a/packages/ttsl-lang/tests/resources/call graph/enum variant call/argument/callable.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/enum variant call/argument/callable.sdstest @@ -9,7 +9,7 @@ enum MyEnum { ) } -pipeline myPipeline { - // $TEST$ ["MyVariant", "passed"] +function myFunction () { + # $TEST$ ["MyVariant", "passed"] »MyEnum.MyVariant(passed)«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/enum variant call/argument/other.sdstest b/packages/ttsl-lang/tests/resources/call graph/enum variant call/argument/other.sdstest index 6b1082e5..598345da 100644 --- a/packages/ttsl-lang/tests/resources/call graph/enum variant call/argument/other.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/enum variant call/argument/other.sdstest @@ -9,7 +9,7 @@ enum MyEnum { ) } -pipeline myPipeline { - // $TEST$ ["MyVariant"] +function myFunction () { + # $TEST$ ["MyVariant"] »MyEnum.MyVariant(1)«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/enum variant call/basic.sdstest b/packages/ttsl-lang/tests/resources/call graph/enum variant call/basic.sdstest index 6ccdec78..9d017299 100644 --- a/packages/ttsl-lang/tests/resources/call graph/enum variant call/basic.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/enum variant call/basic.sdstest @@ -4,7 +4,7 @@ enum MyEnum { MyVariant } -pipeline myPipeline { - // $TEST$ ["MyVariant"] +function myFunction () { + # $TEST$ ["MyVariant"] »MyEnum.MyVariant()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/enum variant call/called twice.sdstest b/packages/ttsl-lang/tests/resources/call graph/enum variant call/called twice.sdstest index 8c521fd4..52fe8d5e 100644 --- a/packages/ttsl-lang/tests/resources/call graph/enum variant call/called twice.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/enum variant call/called twice.sdstest @@ -4,7 +4,7 @@ enum MyEnum { MyVariant } -pipeline myPipeline { - // $TEST$ ["undefined"] +function myFunction () { + # $TEST$ ["undefined"] »MyEnum.MyVariant()()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/enum variant call/default value/call.sdstest b/packages/ttsl-lang/tests/resources/call graph/enum variant call/default value/call.sdstest index 12e4a7e0..29154572 100644 --- a/packages/ttsl-lang/tests/resources/call graph/enum variant call/default value/call.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/enum variant call/default value/call.sdstest @@ -9,7 +9,7 @@ enum MyEnum { ) } -pipeline myPipeline { - // $TEST$ ["MyVariant", "default"] +function myFunction () { + # $TEST$ ["MyVariant", "default"] »MyEnum.MyVariant()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/enum variant call/default value/callable.sdstest b/packages/ttsl-lang/tests/resources/call graph/enum variant call/default value/callable.sdstest index 90aebe9d..1d821f9a 100644 --- a/packages/ttsl-lang/tests/resources/call graph/enum variant call/default value/callable.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/enum variant call/default value/callable.sdstest @@ -9,7 +9,7 @@ enum MyEnum { ) } -pipeline myPipeline { - // $TEST$ ["MyVariant", "default"] +function myFunction () { + # $TEST$ ["MyVariant", "default"] »MyEnum.MyVariant()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/enum variant call/default value/previous parameter.sdstest b/packages/ttsl-lang/tests/resources/call graph/enum variant call/default value/previous parameter.sdstest index 4dde1013..42ac7035 100644 --- a/packages/ttsl-lang/tests/resources/call graph/enum variant call/default value/previous parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/enum variant call/default value/previous parameter.sdstest @@ -9,7 +9,7 @@ enum MyEnum { ) } -pipeline myPipeline { - // $TEST$ ["MyVariant", "default", "default"] +function myFunction () { + # $TEST$ ["MyVariant", "default", "default"] »MyEnum.MyVariant()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/enum variant call/null safe.sdstest b/packages/ttsl-lang/tests/resources/call graph/enum variant call/null safe.sdstest index 57794cb0..8dc14274 100644 --- a/packages/ttsl-lang/tests/resources/call graph/enum variant call/null safe.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/enum variant call/null safe.sdstest @@ -4,7 +4,7 @@ enum MyEnum { MyVariant } -pipeline myPipeline { - // $TEST$ ["MyVariant"] +function myFunction () { + # $TEST$ ["MyVariant"] »MyEnum.MyVariant?()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/block lambda.sdstest b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/block lambda.sdstest index 76018d4a..dbde7cd1 100644 --- a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/block lambda.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/block lambda.sdstest @@ -2,11 +2,11 @@ package tests.callGraph.expressionLambdaCall.argument.blockLambda @Pure fun f() -pipeline myPipeline { +function myFunction () { val lambda = (param1: (param: () -> ()) -> ()) -> param1(f); - // $TEST$ ["$expressionLambda", "$blockLambda", "f"] + # $TEST$ ["$expressionLambda", "$blockLambda", "f"] »lambda((param) { param(); })«; diff --git a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/callable does not get called.sdstest b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/callable does not get called.sdstest index 64aef28f..02b0549f 100644 --- a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/callable does not get called.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/callable does not get called.sdstest @@ -2,9 +2,9 @@ package tests.callGraph.expressionLambdaCall.argument.callableDoesNotGetCalled @Pure fun f() -pipeline myPipeline { +function myFunction () { val lambda = (param: () -> ()) -> 1; - // $TEST$ ["$expressionLambda"] + # $TEST$ ["$expressionLambda"] »lambda(f)«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/expression lambda.sdstest b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/expression lambda.sdstest index 0a29cff1..83b90c3b 100644 --- a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/expression lambda.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/expression lambda.sdstest @@ -2,10 +2,10 @@ package tests.callGraph.expressionLambdaCall.argument.expressionLambda @Pure fun f() -pipeline myPipeline { +function myFunction () { val lambda = (param1: (param: () -> ()) -> ()) -> param1(f); - // $TEST$ ["$expressionLambda", "$expressionLambda", "f"] + # $TEST$ ["$expressionLambda", "$expressionLambda", "f"] »lambda((param) -> param())«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/function.sdstest b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/function.sdstest index b98eca57..bdcc9e63 100644 --- a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/function.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/function.sdstest @@ -2,10 +2,10 @@ package tests.callGraph.expressionLambdaCall.argument.function @Pure fun f() -pipeline myPipeline { +function myFunction () { val lambda = (param: () -> ()) -> param(); - // $TEST$ ["$expressionLambda", "f"] + # $TEST$ ["$expressionLambda", "f"] »lambda(f)«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/segment.sdstest b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/segment.sdstest index 4346e3b0..04b7a24d 100644 --- a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/segment.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/segment.sdstest @@ -2,11 +2,11 @@ package tests.callGraph.expressionLambdaCall.argument.`segment` @Pure fun f() -pipeline myPipeline { +function myFunction () { val lambda = (param1: (param: () -> ()) -> ()) -> param1(f); - // $TEST$ ["$expressionLambda", "mySegment", "f"] + # $TEST$ ["$expressionLambda", "mySegment", "f"] »lambda(mySegment)«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/basic.sdstest b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/basic.sdstest index a9049d41..c6cad9b4 100644 --- a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/basic.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/basic.sdstest @@ -1,8 +1,8 @@ package tests.callGraph.expressionLambdaCall.basic -pipeline myPipeline { +function myFunction () { val lambda = () -> 1; - // $TEST$ ["$expressionLambda"] + # $TEST$ ["$expressionLambda"] »lambda()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/body/function call in nested lambda.sdstest b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/body/function call in nested lambda.sdstest index 53ade196..2858ac2d 100644 --- a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/body/function call in nested lambda.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/body/function call in nested lambda.sdstest @@ -2,9 +2,9 @@ package tests.callGraph.expressionLambdaCall.body.functionCallInNestedLambda @Pure fun f() -pipeline myPipeline { +function myFunction () { val lambda = () -> () -> f(); - // $TEST$ ["$expressionLambda"] + # $TEST$ ["$expressionLambda"] »lambda()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/body/function call.sdstest b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/body/function call.sdstest index 02efa731..b8c54561 100644 --- a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/body/function call.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/body/function call.sdstest @@ -2,9 +2,9 @@ package tests.callGraph.expressionLambdaCall.body.functionCall @Pure fun f() -pipeline myPipeline { +function myFunction () { val lambda = () -> f(); - // $TEST$ ["$expressionLambda", "f"] + # $TEST$ ["$expressionLambda", "f"] »lambda()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/default value/call.sdstest b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/default value/call.sdstest index 4cfffd24..d9500563 100644 --- a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/default value/call.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/default value/call.sdstest @@ -2,11 +2,11 @@ package tests.callGraph.expressionLambdaCall.defaultValue.call @Pure fun default() -> r: Any -pipeline myPipeline { +function myFunction () { val lambda = ( f: Any = default() ) -> 1; - // $TEST$ ["$expressionLambda", "default"] + # $TEST$ ["$expressionLambda", "default"] »lambda()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/default value/callable.sdstest b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/default value/callable.sdstest index a2172d75..18d64ea1 100644 --- a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/default value/callable.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/default value/callable.sdstest @@ -2,11 +2,11 @@ package tests.callGraph.expressionLambdaCall.defaultValue.callable @Pure fun default() -pipeline myPipeline { +function myFunction () { val lambda = ( f: () -> () = default ) -> f(); - // $TEST$ ["$expressionLambda", "default"] + # $TEST$ ["$expressionLambda", "default"] »lambda()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/default value/previous parameter.sdstest b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/default value/previous parameter.sdstest index 95f6740c..445d9b5e 100644 --- a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/default value/previous parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/default value/previous parameter.sdstest @@ -2,12 +2,12 @@ package tests.callGraph.expressionLambdaCall.defaultValue.previousParameter @Pure fun default() -> result: Any -pipeline myPipeline { +function myFunction () { val lambda = ( f: () -> (result: Any) = default, g: Any = f() ) -> 1; - // $TEST$ ["$expressionLambda", "default"] + # $TEST$ ["$expressionLambda", "default"] »lambda()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/null safe.sdstest b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/null safe.sdstest index 96354110..c9cc7018 100644 --- a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/null safe.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/null safe.sdstest @@ -1,8 +1,8 @@ package tests.callGraph.expressionLambdaCall.nullSafe -pipeline myPipeline { +function myFunction () { val lambda = () -> 1; - // $TEST$ ["$expressionLambda"] + # $TEST$ ["$expressionLambda"] »lambda?()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/function call/argument/call.sdstest b/packages/ttsl-lang/tests/resources/call graph/function call/argument/call.sdstest index 2316706e..892157b1 100644 --- a/packages/ttsl-lang/tests/resources/call graph/function call/argument/call.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/function call/argument/call.sdstest @@ -7,7 +7,7 @@ package tests.callGraph.functionCall.argument.call f: Any = default() ) -pipeline myPipeline { - // $TEST$ ["myFunction"] +function myFunction () { + # $TEST$ ["myFunction"] »myFunction(passed())«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/function call/argument/callable.sdstest b/packages/ttsl-lang/tests/resources/call graph/function call/argument/callable.sdstest index 11e86680..c0543c0a 100644 --- a/packages/ttsl-lang/tests/resources/call graph/function call/argument/callable.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/function call/argument/callable.sdstest @@ -7,7 +7,7 @@ package tests.callGraph.functionCall.argument.callable f: () -> () = default ) -pipeline myPipeline { - // $TEST$ ["myFunction", "passed"] +function myFunction () { + # $TEST$ ["myFunction", "passed"] »myFunction(passed)«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/function call/argument/other.sdstest b/packages/ttsl-lang/tests/resources/call graph/function call/argument/other.sdstest index adf0c5ed..93c34e13 100644 --- a/packages/ttsl-lang/tests/resources/call graph/function call/argument/other.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/function call/argument/other.sdstest @@ -7,7 +7,7 @@ package tests.callGraph.functionCall.argument.other f: Any = default() ) -pipeline myPipeline { - // $TEST$ ["myFunction"] +function myFunction () { + # $TEST$ ["myFunction"] »myFunction(1)«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/function call/basic.sdstest b/packages/ttsl-lang/tests/resources/call graph/function call/basic.sdstest index 7ede6cbc..440d384c 100644 --- a/packages/ttsl-lang/tests/resources/call graph/function call/basic.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/function call/basic.sdstest @@ -2,7 +2,7 @@ package tests.callGraph.functionCall.basic @Pure fun myFunction() -pipeline myPipeline { - // $TEST$ ["myFunction"] +function myFunction () { + # $TEST$ ["myFunction"] »myFunction()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/function call/default value/call.sdstest b/packages/ttsl-lang/tests/resources/call graph/function call/default value/call.sdstest index e7524ff0..8712eb2d 100644 --- a/packages/ttsl-lang/tests/resources/call graph/function call/default value/call.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/function call/default value/call.sdstest @@ -7,7 +7,7 @@ package tests.callGraph.functionCall.defaultValue.call f: Any = default() ) -pipeline myPipeline { - // $TEST$ ["myFunction", "default"] +function myFunction () { + # $TEST$ ["myFunction", "default"] »myFunction()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/function call/default value/callable.sdstest b/packages/ttsl-lang/tests/resources/call graph/function call/default value/callable.sdstest index a5152dd4..c2eb0553 100644 --- a/packages/ttsl-lang/tests/resources/call graph/function call/default value/callable.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/function call/default value/callable.sdstest @@ -7,7 +7,7 @@ package tests.callGraph.functionCall.defaultValue.callable f: () -> () = default ) -pipeline myPipeline { - // $TEST$ ["myFunction", "default"] +function myFunction () { + # $TEST$ ["myFunction", "default"] »myFunction()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/function call/default value/previous parameter.sdstest b/packages/ttsl-lang/tests/resources/call graph/function call/default value/previous parameter.sdstest index 8f7a602c..9237fb44 100644 --- a/packages/ttsl-lang/tests/resources/call graph/function call/default value/previous parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/function call/default value/previous parameter.sdstest @@ -7,7 +7,7 @@ package tests.callGraph.functionCall.defaultValue.previousParameter g: Any = f() ) -pipeline myPipeline { - // $TEST$ ["myFunction", "default", "default"] +function myFunction () { + # $TEST$ ["myFunction", "default", "default"] »myFunction()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/function call/instance method.sdstest b/packages/ttsl-lang/tests/resources/call graph/function call/instance method.sdstest index 74ed9f83..acdf7303 100644 --- a/packages/ttsl-lang/tests/resources/call graph/function call/instance method.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/function call/instance method.sdstest @@ -4,7 +4,7 @@ class MyClass { @Pure fun myFunction() } -pipeline myPipeline { - // $TEST$ ["myFunction"] +function myFunction () { + # $TEST$ ["myFunction"] »MyClass().myFunction()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/function call/null safe.sdstest b/packages/ttsl-lang/tests/resources/call graph/function call/null safe.sdstest index c2d4effb..37b40dbf 100644 --- a/packages/ttsl-lang/tests/resources/call graph/function call/null safe.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/function call/null safe.sdstest @@ -11,15 +11,15 @@ segment mySegment( myClass: MyClass, myClassOrNull: MyClass? ) { - // $TEST$ ["myFunction"] + # $TEST$ ["myFunction"] »myFunction?()«; - // $TEST$ ["myStaticMethod"] + # $TEST$ ["myStaticMethod"] »MyClass.myStaticMethod?()«; - // $TEST$ ["myInstanceMethod"] + # $TEST$ ["myInstanceMethod"] »myClass.myInstanceMethod?()«; - // $TEST$ ["myInstanceMethod"] + # $TEST$ ["myInstanceMethod"] »myClassOrNull?.myInstanceMethod?()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/function call/static method.sdstest b/packages/ttsl-lang/tests/resources/call graph/function call/static method.sdstest index 092b5f9d..c8698ab6 100644 --- a/packages/ttsl-lang/tests/resources/call graph/function call/static method.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/function call/static method.sdstest @@ -4,7 +4,7 @@ class MyClass { @Pure static fun myFunction() } -pipeline myPipeline { - // $TEST$ ["myFunction"] +function myFunction () { + # $TEST$ ["myFunction"] »MyClass.myFunction()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/recursion/direct.sdstest b/packages/ttsl-lang/tests/resources/call graph/recursion/direct.sdstest index 7cb6cc27..f871442b 100644 --- a/packages/ttsl-lang/tests/resources/call graph/recursion/direct.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/recursion/direct.sdstest @@ -1,16 +1,16 @@ package tests.callGraph.recursion.direct segment s1() { - // $TEST$ ["s2", "s3", "s2"] + # $TEST$ ["s2", "s3", "s2"] »s2()«; } segment s2() { - // $TEST$ ["s3", "s2", "s3"] + # $TEST$ ["s3", "s2", "s3"] »s3()«; } segment s3() { - // $TEST$ ["s2", "s3", "s2"] + # $TEST$ ["s2", "s3", "s2"] »s2()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/recursion/not recursive.sdstest b/packages/ttsl-lang/tests/resources/call graph/recursion/not recursive.sdstest index 00a9c424..9264d97c 100644 --- a/packages/ttsl-lang/tests/resources/call graph/recursion/not recursive.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/recursion/not recursive.sdstest @@ -6,7 +6,7 @@ package tests.callGraph.recursion.notRecursive */ segment s1() { - // $TEST$ ["s2", "$expressionLambda", "s2", "$blockLambda"] + # $TEST$ ["s2", "$expressionLambda", "s2", "$blockLambda"] »s2(() -> s2())«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/recursion/transitive via function pointer argument.sdstest b/packages/ttsl-lang/tests/resources/call graph/recursion/transitive via function pointer argument.sdstest index 1bb89500..53aff241 100644 --- a/packages/ttsl-lang/tests/resources/call graph/recursion/transitive via function pointer argument.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/recursion/transitive via function pointer argument.sdstest @@ -1,7 +1,7 @@ package tests.callGraph.recursion.transitiveViaFunctionPointerArgument segment s1() { - // $TEST$ ["s2", "s1", "s2"] + # $TEST$ ["s2", "s1", "s2"] »s2(s1)«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/recursion/transitive via lambda argument.sdstest b/packages/ttsl-lang/tests/resources/call graph/recursion/transitive via lambda argument.sdstest index 041103cf..204e3794 100644 --- a/packages/ttsl-lang/tests/resources/call graph/recursion/transitive via lambda argument.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/recursion/transitive via lambda argument.sdstest @@ -1,7 +1,7 @@ package tests.callGraph.recursion.transitiveViaLambdaArgument segment s1() { - // $TEST$ ["s2", "$expressionLambda", "s1", "s2"] + # $TEST$ ["s2", "$expressionLambda", "s1", "s2"] »s2(() -> s1())«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/recursion/transitive.sdstest b/packages/ttsl-lang/tests/resources/call graph/recursion/transitive.sdstest index 4348ff90..d862cc1c 100644 --- a/packages/ttsl-lang/tests/resources/call graph/recursion/transitive.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/recursion/transitive.sdstest @@ -1,16 +1,16 @@ package tests.callGraph.recursion.transitive segment s1() { - // $TEST$ ["s2", "s3", "s1", "s2"] + # $TEST$ ["s2", "s3", "s1", "s2"] »s2()«; } segment s2() { - // $TEST$ ["s3", "s1", "s2", "s3"] + # $TEST$ ["s3", "s1", "s2", "s3"] »s3()«; } segment s3() { - // $TEST$ ["s1", "s2", "s3", "s1"] + # $TEST$ ["s1", "s2", "s3", "s1"] »s1()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/segment call/argument/block lambda.sdstest b/packages/ttsl-lang/tests/resources/call graph/segment call/argument/block lambda.sdstest index 0964a736..ba73fecc 100644 --- a/packages/ttsl-lang/tests/resources/call graph/segment call/argument/block lambda.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/segment call/argument/block lambda.sdstest @@ -6,8 +6,8 @@ segment mySegment(param1: (param: () -> ()) -> ()) { param1(f); } -pipeline myPipeline { - // $TEST$ ["mySegment", "$blockLambda", "f"] +function myFunction () { + # $TEST$ ["mySegment", "$blockLambda", "f"] »mySegment((param) { param(); })«; diff --git a/packages/ttsl-lang/tests/resources/call graph/segment call/argument/callable does not get called.sdstest b/packages/ttsl-lang/tests/resources/call graph/segment call/argument/callable does not get called.sdstest index dc071201..70448cd8 100644 --- a/packages/ttsl-lang/tests/resources/call graph/segment call/argument/callable does not get called.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/segment call/argument/callable does not get called.sdstest @@ -4,7 +4,7 @@ package tests.callGraph.segmentCall.argument.callableDoesNotGetCalled segment mySegment(param: () -> ()) {} -pipeline myPipeline { - // $TEST$ ["mySegment"] +function myFunction () { + # $TEST$ ["mySegment"] »mySegment(f)«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/segment call/argument/expression lambda.sdstest b/packages/ttsl-lang/tests/resources/call graph/segment call/argument/expression lambda.sdstest index d98db885..af745c67 100644 --- a/packages/ttsl-lang/tests/resources/call graph/segment call/argument/expression lambda.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/segment call/argument/expression lambda.sdstest @@ -6,7 +6,7 @@ segment mySegment(param1: (param: () -> ()) -> ()) { param1(f); } -pipeline myPipeline { - // $TEST$ ["mySegment", "$expressionLambda", "f"] +function myFunction () { + # $TEST$ ["mySegment", "$expressionLambda", "f"] »mySegment((param) -> param())«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/segment call/argument/function.sdstest b/packages/ttsl-lang/tests/resources/call graph/segment call/argument/function.sdstest index 636eb15c..9aa3bbce 100644 --- a/packages/ttsl-lang/tests/resources/call graph/segment call/argument/function.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/segment call/argument/function.sdstest @@ -6,7 +6,7 @@ segment mySegment(param: () -> ()) { param(); } -pipeline myPipeline { - // $TEST$ ["mySegment", "f"] +function myFunction () { + # $TEST$ ["mySegment", "f"] »mySegment(f)«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/segment call/argument/segment.sdstest b/packages/ttsl-lang/tests/resources/call graph/segment call/argument/segment.sdstest index 7ce228e8..41279ac8 100644 --- a/packages/ttsl-lang/tests/resources/call graph/segment call/argument/segment.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/segment call/argument/segment.sdstest @@ -10,7 +10,7 @@ segment mySegment2(param: () -> ()) { param(); } -pipeline myPipeline { - // $TEST$ ["mySegment1", "mySegment2", "f"] +function myFunction () { + # $TEST$ ["mySegment1", "mySegment2", "f"] »mySegment1(mySegment2)«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/segment call/basic.sdstest b/packages/ttsl-lang/tests/resources/call graph/segment call/basic.sdstest index 6efed0c9..ff514f4f 100644 --- a/packages/ttsl-lang/tests/resources/call graph/segment call/basic.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/segment call/basic.sdstest @@ -2,7 +2,7 @@ package tests.callGraph.segmentCall.basic segment mySegment() {} -pipeline myPipeline { - // $TEST$ ["mySegment"] +function myFunction () { + # $TEST$ ["mySegment"] »mySegment()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/segment call/body/function call in nested lambda.sdstest b/packages/ttsl-lang/tests/resources/call graph/segment call/body/function call in nested lambda.sdstest index 7b3b98d5..329aabcc 100644 --- a/packages/ttsl-lang/tests/resources/call graph/segment call/body/function call in nested lambda.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/segment call/body/function call in nested lambda.sdstest @@ -6,7 +6,7 @@ segment mySegment() { () -> f(); } -pipeline myPipeline { - // $TEST$ ["mySegment"] +function myFunction () { + # $TEST$ ["mySegment"] »mySegment()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/segment call/body/function call.sdstest b/packages/ttsl-lang/tests/resources/call graph/segment call/body/function call.sdstest index cd2f7a3e..803f9a5c 100644 --- a/packages/ttsl-lang/tests/resources/call graph/segment call/body/function call.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/segment call/body/function call.sdstest @@ -6,7 +6,7 @@ segment mySegment() { f(); } -pipeline myPipeline { - // $TEST$ ["mySegment", "f"] +function myFunction () { + # $TEST$ ["mySegment", "f"] »mySegment()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/segment call/default value/call.sdstest b/packages/ttsl-lang/tests/resources/call graph/segment call/default value/call.sdstest index f6e337bd..102a8d1b 100644 --- a/packages/ttsl-lang/tests/resources/call graph/segment call/default value/call.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/segment call/default value/call.sdstest @@ -6,7 +6,7 @@ segment mySegment( f: Any = default() ) {} -pipeline myPipeline { - // $TEST$ ["mySegment", "default"] +function myFunction () { + # $TEST$ ["mySegment", "default"] »mySegment()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/segment call/default value/callable.sdstest b/packages/ttsl-lang/tests/resources/call graph/segment call/default value/callable.sdstest index 0b4af441..91a808be 100644 --- a/packages/ttsl-lang/tests/resources/call graph/segment call/default value/callable.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/segment call/default value/callable.sdstest @@ -8,7 +8,7 @@ segment mySegment( f(); } -pipeline myPipeline { - // $TEST$ ["mySegment", "default"] +function myFunction () { + # $TEST$ ["mySegment", "default"] »mySegment()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/segment call/default value/previous parameter.sdstest b/packages/ttsl-lang/tests/resources/call graph/segment call/default value/previous parameter.sdstest index f64ce4c2..bb7ff368 100644 --- a/packages/ttsl-lang/tests/resources/call graph/segment call/default value/previous parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/segment call/default value/previous parameter.sdstest @@ -7,7 +7,7 @@ segment mySegment( g: Any = f() ) {} -pipeline myPipeline { - // $TEST$ ["mySegment", "default"] +function myFunction () { + # $TEST$ ["mySegment", "default"] »mySegment()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/segment call/null safe.sdstest b/packages/ttsl-lang/tests/resources/call graph/segment call/null safe.sdstest index ae3ea8b2..dcd3134b 100644 --- a/packages/ttsl-lang/tests/resources/call graph/segment call/null safe.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/segment call/null safe.sdstest @@ -2,7 +2,7 @@ package tests.callGraph.segmentCall.nullSafe segment mySegment() {} -pipeline myPipeline { - // $TEST$ ["mySegment"] +function myFunction () { + # $TEST$ ["mySegment"] »mySegment?()«; } diff --git a/packages/ttsl-lang/tests/resources/call graph/unresolved callable.sdstest b/packages/ttsl-lang/tests/resources/call graph/unresolved callable.sdstest index d3157370..6b999760 100644 --- a/packages/ttsl-lang/tests/resources/call graph/unresolved callable.sdstest +++ b/packages/ttsl-lang/tests/resources/call graph/unresolved callable.sdstest @@ -1,6 +1,6 @@ package tests.callGraph.unresolvedCallable -pipeline myPipeline { - // $TEST$ ["undefined"] +function myFunction () { + # $TEST$ ["undefined"] »unresolved()«; } diff --git a/packages/ttsl-lang/tests/resources/formatting/comments/before declarations.sdstest b/packages/ttsl-lang/tests/resources/formatting/comments/before declarations.sdstest index 48f6b481..4e175997 100644 --- a/packages/ttsl-lang/tests/resources/formatting/comments/before declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/comments/before declarations.sdstest @@ -1,8 +1,8 @@ -// test +# test class C -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -// test +# test class C diff --git a/packages/ttsl-lang/tests/resources/formatting/comments/before imports.sdstest b/packages/ttsl-lang/tests/resources/formatting/comments/before imports.sdstest index f6f45ae1..503e2f07 100644 --- a/packages/ttsl-lang/tests/resources/formatting/comments/before imports.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/comments/before imports.sdstest @@ -1,8 +1,8 @@ -// test +# test from test import MyClass -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -// test +# test from test import MyClass diff --git a/packages/ttsl-lang/tests/resources/formatting/comments/before module annotations.sdstest b/packages/ttsl-lang/tests/resources/formatting/comments/before module annotations.sdstest index df48ef4d..818506af 100644 --- a/packages/ttsl-lang/tests/resources/formatting/comments/before module annotations.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/comments/before module annotations.sdstest @@ -1,8 +1,8 @@ -// test +# test @Annotation -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -// test +# test @Annotation diff --git a/packages/ttsl-lang/tests/resources/formatting/comments/before module name.sdstest b/packages/ttsl-lang/tests/resources/formatting/comments/before module name.sdstest index 375fe08f..a3d39c1d 100644 --- a/packages/ttsl-lang/tests/resources/formatting/comments/before module name.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/comments/before module name.sdstest @@ -1,8 +1,8 @@ -// test +# test package test -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -// test +# test package test diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/annotation calls/complex argument list.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/annotation calls/complex argument list.sdstest index f4a31456..89efbc2f 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/annotation calls/complex argument list.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/annotation calls/complex argument list.sdstest @@ -1,6 +1,6 @@ @A( f() , 2 ) -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- @A( f(), diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/annotation calls/empty argument list.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/annotation calls/empty argument list.sdstest index 0b066997..0588fa27 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/annotation calls/empty argument list.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/annotation calls/empty argument list.sdstest @@ -1,5 +1,5 @@ @ Annotation ( ) -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- @Annotation() diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/annotation calls/long argument list.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/annotation calls/long argument list.sdstest index a6d92ecd..820f335d 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/annotation calls/long argument list.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/annotation calls/long argument list.sdstest @@ -1,6 +1,6 @@ @A( 1 , 2 , 3 , 4 ) -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- @A( 1, diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/annotation calls/multiple arguments.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/annotation calls/multiple arguments.sdstest index 1806ee09..50d8a2e1 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/annotation calls/multiple arguments.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/annotation calls/multiple arguments.sdstest @@ -1,5 +1,5 @@ @ Annotation ( 1 , a = 2 ) -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- @Annotation(1, a = 2) diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/annotation calls/named argument.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/annotation calls/named argument.sdstest index f04f337b..e65fe47e 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/annotation calls/named argument.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/annotation calls/named argument.sdstest @@ -1,5 +1,5 @@ @ Annotation ( b = 2 ) -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- @Annotation(b = 2) diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/annotation calls/no argument list.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/annotation calls/no argument list.sdstest index 8c92de68..12851621 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/annotation calls/no argument list.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/annotation calls/no argument list.sdstest @@ -1,5 +1,5 @@ @ Annotation -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- @Annotation diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/annotation calls/positional argument.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/annotation calls/positional argument.sdstest index f747c346..f9a91343 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/annotation calls/positional argument.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/annotation calls/positional argument.sdstest @@ -1,5 +1,5 @@ @ Annotation ( 1 ) -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- @Annotation(1) diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/annotations/annotation call.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/annotations/annotation call.sdstest index a385b814..6888114e 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/annotations/annotation call.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/annotations/annotation call.sdstest @@ -4,7 +4,7 @@ package test annotation MyAnnotation -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- package test diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/annotations/no parameter list.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/annotations/no parameter list.sdstest index 0de8ec59..493e9f56 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/annotations/no parameter list.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/annotations/no parameter list.sdstest @@ -1,5 +1,5 @@ annotation MyAnnotation -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- annotation MyAnnotation diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/annotations/with constraint list.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/annotations/with constraint list.sdstest index 215490b9..a0ebb8d3 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/annotations/with constraint list.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/annotations/with constraint list.sdstest @@ -1,6 +1,6 @@ annotation MyAnnotation where { } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- annotation MyAnnotation where {} diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/annotations/with parameter list.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/annotations/with parameter list.sdstest index 394e945c..739639d1 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/annotations/with parameter list.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/annotations/with parameter list.sdstest @@ -1,5 +1,5 @@ annotation MyAnnotation ( ) -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- annotation MyAnnotation() diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/classes/annotation call.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/classes/annotation call.sdstest index 692ab466..d72638c4 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/classes/annotation call.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/classes/annotation call.sdstest @@ -2,7 +2,7 @@ package test @Annotation class MyClass -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- package test diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/classes/attributes/annotated.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/classes/attributes/annotated.sdstest index af1e2dad..8cccbad4 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/classes/attributes/annotated.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/classes/attributes/annotated.sdstest @@ -2,7 +2,7 @@ class MyClass { @Annotation attr a } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- class MyClass { @Annotation diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/classes/attributes/no type.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/classes/attributes/no type.sdstest index 6a01b457..3229769d 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/classes/attributes/no type.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/classes/attributes/no type.sdstest @@ -2,7 +2,7 @@ class MyClass { attr a } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- class MyClass { attr a diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/classes/attributes/static.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/classes/attributes/static.sdstest index c5b44b3d..5ade48c1 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/classes/attributes/static.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/classes/attributes/static.sdstest @@ -2,7 +2,7 @@ class MyClass { static attr a : Int } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- class MyClass { static attr a: Int diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/classes/attributes/with type.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/classes/attributes/with type.sdstest index 7e5a6ec5..211ed8fc 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/classes/attributes/with type.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/classes/attributes/with type.sdstest @@ -2,7 +2,7 @@ class MyClass { attr a : Int } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- class MyClass { attr a: Int diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/classes/empty body.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/classes/empty body.sdstest index aa877320..6c3a2875 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/classes/empty body.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/classes/empty body.sdstest @@ -1,5 +1,5 @@ class MyClass { } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- class MyClass {} diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/classes/full body.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/classes/full body.sdstest index 1b1ce720..27359614 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/classes/full body.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/classes/full body.sdstest @@ -38,7 +38,7 @@ class MyClass { } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- class MyClass { @Annotation diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/classes/methods/annotated instance method.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/classes/methods/annotated instance method.sdstest index 07b3866a..741fa69a 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/classes/methods/annotated instance method.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/classes/methods/annotated instance method.sdstest @@ -3,7 +3,7 @@ class MyClass { } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- class MyClass { @MyAnnotation diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/classes/methods/annotated static method.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/classes/methods/annotated static method.sdstest index 0542fac1..18671949 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/classes/methods/annotated static method.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/classes/methods/annotated static method.sdstest @@ -2,7 +2,7 @@ class MyClass { @MyAnnotation static fun myFunction ( ) } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- class MyClass { @MyAnnotation diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/classes/methods/instance method.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/classes/methods/instance method.sdstest index adcf1639..e39d72d8 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/classes/methods/instance method.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/classes/methods/instance method.sdstest @@ -2,7 +2,7 @@ class MyClass { fun myFunction ( ) } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- class MyClass { fun myFunction() diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/classes/methods/static method.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/classes/methods/static method.sdstest index f5122301..018c3750 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/classes/methods/static method.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/classes/methods/static method.sdstest @@ -2,7 +2,7 @@ class MyClass { static fun myFunction ( ) } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- class MyClass { static fun myFunction() diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/classes/minimal.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/classes/minimal.sdstest index 99f3e184..a34484d2 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/classes/minimal.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/classes/minimal.sdstest @@ -1,5 +1,5 @@ class MyClass -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- class MyClass diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/classes/multiple parent types.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/classes/multiple parent types.sdstest index cf14b00b..26549971 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/classes/multiple parent types.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/classes/multiple parent types.sdstest @@ -1,5 +1,5 @@ class MyClass sub Int , Number -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- class MyClass sub Int, Number diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/classes/nested classes/annotated nested class.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/classes/nested classes/annotated nested class.sdstest index 07e6f58a..399af1e8 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/classes/nested classes/annotated nested class.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/classes/nested classes/annotated nested class.sdstest @@ -2,7 +2,7 @@ class MyOuterClass { @MyAnnotation class MyClass } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- class MyOuterClass { @MyAnnotation diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/classes/nested classes/nested-class.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/classes/nested classes/nested-class.sdstest index 60326304..9e4ef6ee 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/classes/nested classes/nested-class.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/classes/nested classes/nested-class.sdstest @@ -2,7 +2,7 @@ class MyOuterClass { class MyClass } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- class MyOuterClass { class MyClass diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/classes/nested enums/annotated nested enum.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/classes/nested enums/annotated nested enum.sdstest index f7a85053..8c600c6c 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/classes/nested enums/annotated nested enum.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/classes/nested enums/annotated nested enum.sdstest @@ -2,7 +2,7 @@ class MyOuterClass { @MyAnnotation enum MyEnum { MyEnumVariant } } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- class MyOuterClass { @MyAnnotation diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/classes/nested enums/nested enum.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/classes/nested enums/nested enum.sdstest index dcb3d73e..aeef5c7c 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/classes/nested enums/nested enum.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/classes/nested enums/nested enum.sdstest @@ -2,7 +2,7 @@ class MyOuterClass { enum MyEnum { MyEnumVariant } } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- class MyOuterClass { enum MyEnum { diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/classes/one parent type.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/classes/one parent type.sdstest index edea5b0d..3a7087df 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/classes/one parent type.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/classes/one parent type.sdstest @@ -1,5 +1,5 @@ class MyClass sub Int -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- class MyClass sub Int diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/classes/with constraint list.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/classes/with constraint list.sdstest index bf9ecf91..c7f23119 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/classes/with constraint list.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/classes/with constraint list.sdstest @@ -1,6 +1,6 @@ class MyClass where { } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- class MyClass where {} diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/classes/with parameter list.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/classes/with parameter list.sdstest index a26e2fce..85738b61 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/classes/with parameter list.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/classes/with parameter list.sdstest @@ -1,5 +1,5 @@ class MyClass ( ) -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- class MyClass() diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/classes/with type parameter list.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/classes/with type parameter list.sdstest index ddd2f5d9..529e9929 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/classes/with type parameter list.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/classes/with type parameter list.sdstest @@ -1,5 +1,5 @@ class MyClass < > -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- class MyClass<> diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/constraints/greater than constraint.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/constraints/greater than constraint.sdstest index 20f9e558..90f0a9b9 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/constraints/greater than constraint.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/constraints/greater than constraint.sdstest @@ -1,6 +1,6 @@ annotation MyAnnotation where { p > 0 } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- annotation MyAnnotation where { p > 0 diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/constraints/greater than or equal constraint.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/constraints/greater than or equal constraint.sdstest index 5a51d5c8..e5e6e6f9 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/constraints/greater than or equal constraint.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/constraints/greater than or equal constraint.sdstest @@ -1,6 +1,6 @@ annotation MyAnnotation where { p >= 0 } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- annotation MyAnnotation where { p >= 0 diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/constraints/less than constraint.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/constraints/less than constraint.sdstest index aa2e4735..f03738bb 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/constraints/less than constraint.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/constraints/less than constraint.sdstest @@ -1,6 +1,6 @@ annotation MyAnnotation where { p < 0 } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- annotation MyAnnotation where { p < 0 diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/constraints/less than or equal constraint.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/constraints/less than or equal constraint.sdstest index 130c0d70..f1a44e72 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/constraints/less than or equal constraint.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/constraints/less than or equal constraint.sdstest @@ -1,6 +1,6 @@ annotation MyAnnotation where { p <= 0 } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- annotation MyAnnotation where { p <= 0 diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/constraints/multiple constraints.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/constraints/multiple constraints.sdstest index f5414c71..a1f4f4d9 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/constraints/multiple constraints.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/constraints/multiple constraints.sdstest @@ -1,6 +1,6 @@ annotation MyAnnotation where { p < 0 , q > 1 } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- annotation MyAnnotation where { p < 0, diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/enums/annotation call.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/enums/annotation call.sdstest index 2dc1c917..99759737 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/enums/annotation call.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/enums/annotation call.sdstest @@ -2,7 +2,7 @@ package test @Annotation enum MyEnum -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- package test diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/enums/empty body.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/enums/empty body.sdstest index 660dfbc9..95e37382 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/enums/empty body.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/enums/empty body.sdstest @@ -1,5 +1,5 @@ enum MyEnum { } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- enum MyEnum {} diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/enums/full body.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/enums/full body.sdstest index 0140234f..2bc5fe09 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/enums/full body.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/enums/full body.sdstest @@ -14,7 +14,7 @@ enum MyEnum { } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- enum MyEnum { @Annotation diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/enums/no body.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/enums/no body.sdstest index a3465e9c..56faf4aa 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/enums/no body.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/enums/no body.sdstest @@ -1,5 +1,5 @@ enum MyEnum -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- enum MyEnum diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/enums/variants in body.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/enums/variants in body.sdstest index c285ed2f..12bb2f29 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/enums/variants in body.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/enums/variants in body.sdstest @@ -2,7 +2,7 @@ enum MyEnum { MyEnumVariant } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- enum MyEnum { MyEnumVariant diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/enums/variants/annotation call.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/enums/variants/annotation call.sdstest index 6b066b79..23ff0aa9 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/enums/variants/annotation call.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/enums/variants/annotation call.sdstest @@ -2,7 +2,7 @@ enum MyEnum { @Annotation MyEnumVariant } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- enum MyEnum { @Annotation diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/enums/variants/no parameter list.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/enums/variants/no parameter list.sdstest index d55b4c60..d8a32893 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/enums/variants/no parameter list.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/enums/variants/no parameter list.sdstest @@ -2,7 +2,7 @@ enum MyEnum { MyEnumVariant } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- enum MyEnum { MyEnumVariant diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/enums/variants/with constraint list.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/enums/variants/with constraint list.sdstest index da0c8494..a9f2a646 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/enums/variants/with constraint list.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/enums/variants/with constraint list.sdstest @@ -3,7 +3,7 @@ enum MyEnum { } } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- enum MyEnum { MyEnumVariant where {} diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/enums/variants/with parameter list.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/enums/variants/with parameter list.sdstest index e51c49f7..5abfb74a 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/enums/variants/with parameter list.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/enums/variants/with parameter list.sdstest @@ -2,7 +2,7 @@ enum MyEnum { MyEnumVariant ( ) } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- enum MyEnum { MyEnumVariant() diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/functions/annotation call.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/functions/annotation call.sdstest index a71836c3..0d5283f1 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/functions/annotation call.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/functions/annotation call.sdstest @@ -2,7 +2,7 @@ package test @Annotation fun myFunction ( ) -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- package test diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/functions/with constraint list.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/functions/with constraint list.sdstest index a2d6bee0..d360bfaa 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/functions/with constraint list.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/functions/with constraint list.sdstest @@ -1,5 +1,5 @@ fun myFunction ( ) where { } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- fun myFunction() where {} diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/functions/with result list.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/functions/with result list.sdstest index dd682801..33138119 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/functions/with result list.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/functions/with result list.sdstest @@ -1,5 +1,5 @@ fun myFunction ( ) -> ( ) -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- fun myFunction() -> () diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/functions/with type parameter list.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/functions/with type parameter list.sdstest index 0d045ebf..6131a231 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/functions/with type parameter list.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/functions/with type parameter list.sdstest @@ -1,5 +1,5 @@ fun myFunction < > ( ) -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- fun myFunction<>() diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/parameters/complex parameter list.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/parameters/complex parameter list.sdstest index 9023c5ec..32e4a473 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/parameters/complex parameter list.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/parameters/complex parameter list.sdstest @@ -1,6 +1,6 @@ class C( a: A.B , b: Int ) -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- class C( a: A.B, diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/parameters/empty parameter list.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/parameters/empty parameter list.sdstest index b51e9d23..9cf7dc80 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/parameters/empty parameter list.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/parameters/empty parameter list.sdstest @@ -1,5 +1,5 @@ class MyClass( ) -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- class MyClass() diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/parameters/long parameter list.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/parameters/long parameter list.sdstest index e34baf9e..b11d57b5 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/parameters/long parameter list.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/parameters/long parameter list.sdstest @@ -1,6 +1,6 @@ class C( a: Int , b: Int , c: Int , d: Int ) -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- class C( a: Int, diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/parameters/multiple parameters.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/parameters/multiple parameters.sdstest index 5bef799a..194fb25c 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/parameters/multiple parameters.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/parameters/multiple parameters.sdstest @@ -17,7 +17,7 @@ class MyClass( const d2 : Int = 2 ) -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- class MyClass( @Annotation diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/parameters/with const typed optional parameter.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/parameters/with const typed optional parameter.sdstest index d99bf4f8..36a6bf4e 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/parameters/with const typed optional parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/parameters/with const typed optional parameter.sdstest @@ -1,5 +1,5 @@ class MyClass( const a : Int = 1 ) -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- class MyClass(const a: Int = 1) diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/parameters/with const typed required parameter.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/parameters/with const typed required parameter.sdstest index 8e274653..7e358be7 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/parameters/with const typed required parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/parameters/with const typed required parameter.sdstest @@ -1,5 +1,5 @@ class MyClass( const a : Int ) -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- class MyClass(const a: Int) diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/parameters/with const untyped optional parameter.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/parameters/with const untyped optional parameter.sdstest index 649d3728..21981dfd 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/parameters/with const untyped optional parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/parameters/with const untyped optional parameter.sdstest @@ -1,5 +1,5 @@ class MyClass( const a = 1 ) -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- class MyClass(const a = 1) diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/parameters/with const untyped required parameter.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/parameters/with const untyped required parameter.sdstest index 834682fc..9cd0a5b2 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/parameters/with const untyped required parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/parameters/with const untyped required parameter.sdstest @@ -1,5 +1,5 @@ class MyClass( const a ) -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- class MyClass(const a) diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/parameters/with typed optional parameter.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/parameters/with typed optional parameter.sdstest index 4fe81850..e7d52e3a 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/parameters/with typed optional parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/parameters/with typed optional parameter.sdstest @@ -1,5 +1,5 @@ class MyClass( a : Int = 1 ) -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- class MyClass(a: Int = 1) diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/parameters/with typed required parameter.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/parameters/with typed required parameter.sdstest index d5e1bf04..92e5d2b9 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/parameters/with typed required parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/parameters/with typed required parameter.sdstest @@ -1,5 +1,5 @@ class MyClass( a : Int ) -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- class MyClass(a: Int) diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/parameters/with untyped optional parameter.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/parameters/with untyped optional parameter.sdstest index fd62282f..c09fe3fe 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/parameters/with untyped optional parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/parameters/with untyped optional parameter.sdstest @@ -1,5 +1,5 @@ class MyClass( a = 1 ) -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- class MyClass(a = 1) diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/parameters/with untyped required parameter.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/parameters/with untyped required parameter.sdstest index 611bf36f..724feb42 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/parameters/with untyped required parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/parameters/with untyped required parameter.sdstest @@ -1,5 +1,5 @@ class MyClass( a ) -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- class MyClass(a) diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/pipelines/annotation call.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/pipelines/annotation call.sdstest index 285b2429..36739c16 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/pipelines/annotation call.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/pipelines/annotation call.sdstest @@ -2,9 +2,9 @@ package test @Annotation pipeline myPipeline { } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- package test @Annotation -pipeline myPipeline {} +function myFunction () {} diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/pipelines/empty body.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/pipelines/empty body.sdstest index 57fb66ca..95a46a06 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/pipelines/empty body.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/pipelines/empty body.sdstest @@ -1,5 +1,5 @@ pipeline myPipeline { } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline {} +function myFunction () {} diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/pipelines/statements in body.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/pipelines/statements in body.sdstest index 6970f53f..334d1524 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/pipelines/statements in body.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/pipelines/statements in body.sdstest @@ -2,8 +2,8 @@ pipeline myPipeline { val a = 1 ; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { val a = 1; } diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/results/complex result list.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/results/complex result list.sdstest index 312c5ea4..7068eb2d 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/results/complex result list.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/results/complex result list.sdstest @@ -1,6 +1,6 @@ segment s() -> ( x: A.B , y: Int ) {} -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- segment s() -> ( x: A.B, diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/results/long result list.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/results/long result list.sdstest index 97d846e5..3b820f81 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/results/long result list.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/results/long result list.sdstest @@ -1,6 +1,6 @@ segment s() -> ( x: Int , y: Int , a: Int , b: Int ) {} -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- segment s() -> ( x: Int, diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/results/multiple results.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/results/multiple results.sdstest index 9755df46..4fca06f1 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/results/multiple results.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/results/multiple results.sdstest @@ -9,7 +9,7 @@ segment mySegment ( ) -> ( d : Int ) { } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- segment mySegment() -> ( @Annotation diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/results/no results (explicit).sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/results/no results (explicit).sdstest index dee2ed60..5c5ae1d2 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/results/no results (explicit).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/results/no results (explicit).sdstest @@ -1,5 +1,5 @@ segment mySegment ( ) -> ( ) { } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- segment mySegment() -> () {} diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/results/one typed result (in parentheses).sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/results/one typed result (in parentheses).sdstest index 39e77c00..6b682ef5 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/results/one typed result (in parentheses).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/results/one typed result (in parentheses).sdstest @@ -1,5 +1,5 @@ segment mySegment ( ) -> ( a : Int ) { } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- segment mySegment() -> (a: Int) {} diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/results/one typed result (no parentheses).sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/results/one typed result (no parentheses).sdstest index 82099ddc..2b14804f 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/results/one typed result (no parentheses).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/results/one typed result (no parentheses).sdstest @@ -1,5 +1,5 @@ segment mySegment ( ) -> a : Int { } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- segment mySegment() -> a: Int {} diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/results/one untyped result (no parentheses).sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/results/one untyped result (no parentheses).sdstest index 44f98d7a..4a02fe68 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/results/one untyped result (no parentheses).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/results/one untyped result (no parentheses).sdstest @@ -1,5 +1,5 @@ segment mySegment ( ) -> a { } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- segment mySegment() -> a {} diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/results/one untyped result (with parentheses).sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/results/one untyped result (with parentheses).sdstest index 59ca26b2..16d9afd4 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/results/one untyped result (with parentheses).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/results/one untyped result (with parentheses).sdstest @@ -1,5 +1,5 @@ segment mySegment ( ) -> ( a ) { } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- segment mySegment() -> (a) {} diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/segments/annotation call.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/segments/annotation call.sdstest index 6af46de1..9ff56c99 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/segments/annotation call.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/segments/annotation call.sdstest @@ -2,7 +2,7 @@ package test @Annotation segment mySegment ( ) { } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- package test diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/segments/internal segment with annotation call.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/segments/internal segment with annotation call.sdstest index 9f8b3c0d..79f5e20a 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/segments/internal segment with annotation call.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/segments/internal segment with annotation call.sdstest @@ -2,7 +2,7 @@ package test @Annotation internal segment mySegment ( ) { } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- package test diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/segments/internal segment.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/segments/internal segment.sdstest index 09ff8895..e20b5983 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/segments/internal segment.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/segments/internal segment.sdstest @@ -1,5 +1,5 @@ internal segment mySegment ( ) { } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- internal segment mySegment() {} diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/segments/minimal.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/segments/minimal.sdstest index edf48702..9f581d6a 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/segments/minimal.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/segments/minimal.sdstest @@ -1,5 +1,5 @@ segment mySegment ( ) { } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- segment mySegment() {} diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/segments/private segment with annotation call.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/segments/private segment with annotation call.sdstest index e8abab52..370eb874 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/segments/private segment with annotation call.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/segments/private segment with annotation call.sdstest @@ -2,7 +2,7 @@ package test @Annotation private segment mySegment ( ) { } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- package test diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/segments/private segment.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/segments/private segment.sdstest index 077937c9..17fa9726 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/segments/private segment.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/segments/private segment.sdstest @@ -1,5 +1,5 @@ private segment mySegment ( ) { } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- private segment mySegment() {} diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/segments/statements in body.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/segments/statements in body.sdstest index c1ccc34a..ccd77bdb 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/segments/statements in body.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/segments/statements in body.sdstest @@ -2,7 +2,7 @@ private segment mySegment ( ) { val a = 1; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- private segment mySegment() { val a = 1; diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/segments/with constraint list.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/segments/with constraint list.sdstest index fc6c2ad7..44c176a7 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/segments/with constraint list.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/segments/with constraint list.sdstest @@ -1,5 +1,5 @@ segment mySegment ( ) where { } { } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- segment mySegment() where {} {} diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/segments/with result list.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/segments/with result list.sdstest index dee2ed60..5c5ae1d2 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/segments/with result list.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/segments/with result list.sdstest @@ -1,5 +1,5 @@ segment mySegment ( ) -> ( ) { } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- segment mySegment() -> () {} diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/bounded contravariant optional type parameter.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/bounded contravariant optional type parameter.sdstest index 1116629c..e4ea0a8e 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/bounded contravariant optional type parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/bounded contravariant optional type parameter.sdstest @@ -1,5 +1,5 @@ fun myFunction< in T sub Int = Int >() -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- fun myFunction() diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/bounded contravariant required type parameter.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/bounded contravariant required type parameter.sdstest index 149652aa..90a3949b 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/bounded contravariant required type parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/bounded contravariant required type parameter.sdstest @@ -1,5 +1,5 @@ fun myFunction< in T sub Int >() -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- fun myFunction() diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/bounded contravariant type parameter with annotation call.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/bounded contravariant type parameter with annotation call.sdstest index 30d42769..0ba6c115 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/bounded contravariant type parameter with annotation call.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/bounded contravariant type parameter with annotation call.sdstest @@ -1,6 +1,6 @@ fun myFunction< @Annotation in T sub Int > ( ) -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- fun myFunction< @Annotation diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/bounded covariant optional type parameter.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/bounded covariant optional type parameter.sdstest index b094ae5e..915a0ab9 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/bounded covariant optional type parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/bounded covariant optional type parameter.sdstest @@ -1,5 +1,5 @@ fun myFunction< out T sub Int = Int >() -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- fun myFunction() diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/bounded covariant required type parameter.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/bounded covariant required type parameter.sdstest index 21fd2562..58d9b38a 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/bounded covariant required type parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/bounded covariant required type parameter.sdstest @@ -1,5 +1,5 @@ fun myFunction< out T sub Int >() -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- fun myFunction() diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/bounded covariant type parameter with annotation call.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/bounded covariant type parameter with annotation call.sdstest index dad5d360..92789e12 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/bounded covariant type parameter with annotation call.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/bounded covariant type parameter with annotation call.sdstest @@ -1,6 +1,6 @@ fun myFunction< @Annotation out T sub Int > ( ) -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- fun myFunction< @Annotation diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/bounded invariant optional type parameter.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/bounded invariant optional type parameter.sdstest index ad13a827..46713ccf 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/bounded invariant optional type parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/bounded invariant optional type parameter.sdstest @@ -1,5 +1,5 @@ fun myFunction< T sub Int = Int >() -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- fun myFunction() diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/bounded invariant required type parameter.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/bounded invariant required type parameter.sdstest index 5693a20b..6e443338 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/bounded invariant required type parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/bounded invariant required type parameter.sdstest @@ -1,5 +1,5 @@ fun myFunction< T sub Int >() -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- fun myFunction() diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/bounded invariant type parameter with annotation call.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/bounded invariant type parameter with annotation call.sdstest index 9935c027..3e27f439 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/bounded invariant type parameter with annotation call.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/bounded invariant type parameter with annotation call.sdstest @@ -1,6 +1,6 @@ fun myFunction< @Annotation T sub Int >() -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- fun myFunction< @Annotation diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/long type parameter list.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/long type parameter list.sdstest index 72648532..af75a430 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/long type parameter list.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/long type parameter list.sdstest @@ -1,6 +1,6 @@ fun f< K , V , X , Y >() -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- fun f< K, diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/multiple type parameters.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/multiple type parameters.sdstest index 8d20955b..df54ba50 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/multiple type parameters.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/multiple type parameters.sdstest @@ -1,6 +1,6 @@ fun myFunction< @Annotation T , in S , out U >() -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- fun myFunction< @Annotation diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/unbounded contravariant optional type parameter.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/unbounded contravariant optional type parameter.sdstest index 2bfeaf86..3ead8de8 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/unbounded contravariant optional type parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/unbounded contravariant optional type parameter.sdstest @@ -1,5 +1,5 @@ fun myFunction< in T = Int >() -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- fun myFunction() diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/unbounded contravariant required type parameter.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/unbounded contravariant required type parameter.sdstest index ad1ebf8f..321dd9d6 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/unbounded contravariant required type parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/unbounded contravariant required type parameter.sdstest @@ -1,5 +1,5 @@ fun myFunction< in T >() -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- fun myFunction() diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/unbounded contravariant type parameter with annotation call.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/unbounded contravariant type parameter with annotation call.sdstest index b1de65f6..166d440a 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/unbounded contravariant type parameter with annotation call.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/unbounded contravariant type parameter with annotation call.sdstest @@ -1,6 +1,6 @@ fun myFunction< @Annotation in T > ( ) -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- fun myFunction< @Annotation diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/unbounded covariant optional type parameter.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/unbounded covariant optional type parameter.sdstest index 7e364ba9..81084839 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/unbounded covariant optional type parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/unbounded covariant optional type parameter.sdstest @@ -1,5 +1,5 @@ fun myFunction< out T = Int >() -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- fun myFunction() diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/unbounded covariant required type parameter.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/unbounded covariant required type parameter.sdstest index 22802a60..2ffe845e 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/unbounded covariant required type parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/unbounded covariant required type parameter.sdstest @@ -1,5 +1,5 @@ fun myFunction< out T >() -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- fun myFunction() diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/unbounded covariant type parameter with annotation call.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/unbounded covariant type parameter with annotation call.sdstest index 93cc8d2c..dc736491 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/unbounded covariant type parameter with annotation call.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/unbounded covariant type parameter with annotation call.sdstest @@ -1,6 +1,6 @@ fun myFunction< @Annotation out T > ( ) -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- fun myFunction< @Annotation diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/unbounded invariant optional type parameter.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/unbounded invariant optional type parameter.sdstest index 650755f6..7da95f71 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/unbounded invariant optional type parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/unbounded invariant optional type parameter.sdstest @@ -1,5 +1,5 @@ fun myFunction< T = Int >() -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- fun myFunction() diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/unbounded invariant required type parameter.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/unbounded invariant required type parameter.sdstest index 0ebc5513..c09b972e 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/unbounded invariant required type parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/unbounded invariant required type parameter.sdstest @@ -1,5 +1,5 @@ fun myFunction< T >() -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- fun myFunction() diff --git a/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/unbounded invariant type parameter with annotation call.sdstest b/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/unbounded invariant type parameter with annotation call.sdstest index 1d98b0b9..db192437 100644 --- a/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/unbounded invariant type parameter with annotation call.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/declarations/type parameters/unbounded invariant type parameter with annotation call.sdstest @@ -1,6 +1,6 @@ fun myFunction< @Annotation T >() -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- fun myFunction< @Annotation diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/arithmetic operators/addition.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/arithmetic operators/addition.sdstest index 7e411eca..f7d3c2df 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/arithmetic operators/addition.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/arithmetic operators/addition.sdstest @@ -1,9 +1,9 @@ -pipeline myPipeline { +function myFunction () { 1 + 2; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { 1 + 2; } diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/arithmetic operators/complex example.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/arithmetic operators/complex example.sdstest index 0ca04048..e0593b67 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/arithmetic operators/complex example.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/arithmetic operators/complex example.sdstest @@ -1,9 +1,9 @@ -pipeline myPipeline { +function myFunction () { ( 1 + 2 ) * - 3 / ( 1 - 4 ) + 5; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { (1 + 2) * -3 / (1 - 4) + 5; } diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/arithmetic operators/division.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/arithmetic operators/division.sdstest index a53dbe7e..d0f62c93 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/arithmetic operators/division.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/arithmetic operators/division.sdstest @@ -1,9 +1,9 @@ -pipeline myPipeline { +function myFunction () { 1 / 2; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { 1 / 2; } diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/arithmetic operators/multiplication.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/arithmetic operators/multiplication.sdstest index 021a2ed1..504d8bea 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/arithmetic operators/multiplication.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/arithmetic operators/multiplication.sdstest @@ -1,9 +1,9 @@ -pipeline myPipeline { +function myFunction () { 1 * 2; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { 1 * 2; } diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/arithmetic operators/negation.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/arithmetic operators/negation.sdstest index ef14ab5c..432ff27f 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/arithmetic operators/negation.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/arithmetic operators/negation.sdstest @@ -1,9 +1,9 @@ -pipeline myPipeline { +function myFunction () { - 1; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { -1; } diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/arithmetic operators/subtraction.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/arithmetic operators/subtraction.sdstest index 57f2c8b7..e61f5870 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/arithmetic operators/subtraction.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/arithmetic operators/subtraction.sdstest @@ -1,9 +1,9 @@ -pipeline myPipeline { +function myFunction () { 1 - 2; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { 1 - 2; } diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/block lambdas/filled body.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/block lambdas/filled body.sdstest index 640c812c..5fbf8f61 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/block lambdas/filled body.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/block lambdas/filled body.sdstest @@ -1,12 +1,12 @@ -pipeline myPipeline { +function myFunction () { ( ) { val a = 1 ; }; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { () { val a = 1; }; diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/block lambdas/minimal.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/block lambdas/minimal.sdstest index 2e0c08ff..8c54343e 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/block lambdas/minimal.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/block lambdas/minimal.sdstest @@ -1,9 +1,9 @@ -pipeline myPipeline { +function myFunction () { ( ) { }; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { () {}; } diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/calls/complex argument list.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/calls/complex argument list.sdstest index d34dfe56..5abc32e5 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/calls/complex argument list.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/calls/complex argument list.sdstest @@ -2,7 +2,7 @@ pipeline p { f( f() , 2 ); } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- pipeline p { f( diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/calls/long argument list.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/calls/long argument list.sdstest index 38b8c4b9..3fcb5dd3 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/calls/long argument list.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/calls/long argument list.sdstest @@ -2,7 +2,7 @@ pipeline p { f( 1 , 2 , 3 , 4 ); } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- pipeline p { f( diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/calls/mixed positional and named arguments.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/calls/mixed positional and named arguments.sdstest index 9c51ecc9..21818e42 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/calls/mixed positional and named arguments.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/calls/mixed positional and named arguments.sdstest @@ -1,9 +1,9 @@ -pipeline myPipeline { +function myFunction () { f ( 1 , b = 2 ); } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { f(1, b = 2); } diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/calls/named argument.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/calls/named argument.sdstest index 3e727f76..4ab50e42 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/calls/named argument.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/calls/named argument.sdstest @@ -1,9 +1,9 @@ -pipeline myPipeline { +function myFunction () { f ( b = 2 ); } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { f(b = 2); } diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/calls/no arguments.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/calls/no arguments.sdstest index a8f90d69..42ff417f 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/calls/no arguments.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/calls/no arguments.sdstest @@ -1,9 +1,9 @@ -pipeline myPipeline { +function myFunction () { f ( ); } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { f(); } diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/calls/null safe.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/calls/null safe.sdstest index c12da29a..6eecbbe4 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/calls/null safe.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/calls/null safe.sdstest @@ -1,9 +1,9 @@ -pipeline myPipeline { +function myFunction () { f ? ( ); } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { f?(); } diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/calls/positional argument.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/calls/positional argument.sdstest index c4234d45..62e0b1cb 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/calls/positional argument.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/calls/positional argument.sdstest @@ -1,9 +1,9 @@ -pipeline myPipeline { +function myFunction () { f ( 1 ); } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { f(1); } diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/comparison operators/greater than or equal.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/comparison operators/greater than or equal.sdstest index 5f952a88..1ae1745e 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/comparison operators/greater than or equal.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/comparison operators/greater than or equal.sdstest @@ -1,9 +1,9 @@ -pipeline myPipeline { +function myFunction () { 1 >= 2; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { 1 >= 2; } diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/comparison operators/greater than.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/comparison operators/greater than.sdstest index acb064df..bc74c667 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/comparison operators/greater than.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/comparison operators/greater than.sdstest @@ -1,9 +1,9 @@ -pipeline myPipeline { +function myFunction () { 1 > 2; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { 1 > 2; } diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/comparison operators/less than or equal.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/comparison operators/less than or equal.sdstest index 8ddfe3d2..28f03763 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/comparison operators/less than or equal.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/comparison operators/less than or equal.sdstest @@ -1,9 +1,9 @@ -pipeline myPipeline { +function myFunction () { 1 <= 2; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { 1 <= 2; } diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/comparison operators/less than.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/comparison operators/less than.sdstest index 2445c4b4..7d5d326d 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/comparison operators/less than.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/comparison operators/less than.sdstest @@ -1,9 +1,9 @@ -pipeline myPipeline { +function myFunction () { 1 < 2; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { 1 < 2; } diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/complex chained expression.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/complex chained expression.sdstest index a1ade93e..33cc0cea 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/complex chained expression.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/complex chained expression.sdstest @@ -1,9 +1,9 @@ -pipeline myPipeline { +function myFunction () { a . member ? . f ( ) [ 1 ]; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { a.member?.f()[1]; } diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/elvis operator.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/elvis operator.sdstest index d0a7c751..af80f330 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/elvis operator.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/elvis operator.sdstest @@ -1,9 +1,9 @@ -pipeline myPipeline { +function myFunction () { 1 ?: 2; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { 1 ?: 2; } diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/equality operators/equal.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/equality operators/equal.sdstest index 23abb29b..dd434ce9 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/equality operators/equal.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/equality operators/equal.sdstest @@ -1,9 +1,9 @@ -pipeline myPipeline { +function myFunction () { 1 == 2; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { 1 == 2; } diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/equality operators/identical.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/equality operators/identical.sdstest index f6514e25..1bebf223 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/equality operators/identical.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/equality operators/identical.sdstest @@ -1,9 +1,9 @@ -pipeline myPipeline { +function myFunction () { 1 === 2; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { 1 === 2; } diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/equality operators/not equal.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/equality operators/not equal.sdstest index 2b3c90e0..d74cb09a 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/equality operators/not equal.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/equality operators/not equal.sdstest @@ -1,9 +1,9 @@ -pipeline myPipeline { +function myFunction () { 1 != 2; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { 1 != 2; } diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/equality operators/not identical.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/equality operators/not identical.sdstest index 286e6029..1d9336a4 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/equality operators/not identical.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/equality operators/not identical.sdstest @@ -1,9 +1,9 @@ -pipeline myPipeline { +function myFunction () { 1 !== 2; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { 1 !== 2; } diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/expression lambdas/minimal.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/expression lambdas/minimal.sdstest index 527e3e39..5c7e8237 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/expression lambdas/minimal.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/expression lambdas/minimal.sdstest @@ -1,9 +1,9 @@ -pipeline myPipeline { +function myFunction () { ( ) -> 1; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { () -> 1; } diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/indexed accesses/literal index.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/indexed accesses/literal index.sdstest index 04025cfb..204979b0 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/indexed accesses/literal index.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/indexed accesses/literal index.sdstest @@ -1,9 +1,9 @@ -pipeline test { +function test () { a [ 1 ]; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline test { +function test () { a[1]; } diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/indexed accesses/null safe.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/indexed accesses/null safe.sdstest index aa4c367b..33163795 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/indexed accesses/null safe.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/indexed accesses/null safe.sdstest @@ -1,9 +1,9 @@ -pipeline test { +function test () { a ? [ 1 ]; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline test { +function test () { a?[1]; } diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/indexed accesses/reference index.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/indexed accesses/reference index.sdstest index 37f9b140..b8486662 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/indexed accesses/reference index.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/indexed accesses/reference index.sdstest @@ -1,9 +1,9 @@ -pipeline test { +function test () { a [ b ]; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline test { +function test () { a[b]; } diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/lists/complex element.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/lists/complex element.sdstest index 2d2beaf4..42dafe44 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/lists/complex element.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/lists/complex element.sdstest @@ -1,10 +1,10 @@ -pipeline myPipeline { +function myFunction () { [ f ( ) ]; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { [ f() ]; diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/lists/nested multiple elements.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/lists/nested multiple elements.sdstest index c7bb5e17..52340c15 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/lists/nested multiple elements.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/lists/nested multiple elements.sdstest @@ -1,10 +1,10 @@ -pipeline myPipeline { +function myFunction () { [ [ 1 , 2 ] ]; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { [ [1, 2] ]; diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/lists/nested one element.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/lists/nested one element.sdstest index 109b9e56..cdcd0812 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/lists/nested one element.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/lists/nested one element.sdstest @@ -1,10 +1,10 @@ -pipeline myPipeline { +function myFunction () { [ [ 1 + 2 ] ]; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { [ [1 + 2] ]; diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/lists/one level multiple elements.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/lists/one level multiple elements.sdstest index d389dcd6..9681186d 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/lists/one level multiple elements.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/lists/one level multiple elements.sdstest @@ -1,9 +1,9 @@ -pipeline myPipeline { +function myFunction () { [ 1 , 2 ]; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { [1, 2]; } diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/lists/one level one element.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/lists/one level one element.sdstest index 9efcff74..e2f56812 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/lists/one level one element.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/lists/one level one element.sdstest @@ -1,9 +1,9 @@ -pipeline myPipeline { +function myFunction () { [ 1 ]; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { [1]; } diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/literals/false.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/literals/false.sdstest index 8c6cf3fd..cb5eca8f 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/literals/false.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/literals/false.sdstest @@ -1,9 +1,9 @@ -pipeline myPipeline { +function myFunction () { false; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { false; } diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/literals/float/basic example.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/literals/float/basic example.sdstest index 1419b498..046f4705 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/literals/float/basic example.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/literals/float/basic example.sdstest @@ -1,4 +1,4 @@ -pipeline myPipeline { +function myFunction () { 1.2; 1e10; 1e+10; @@ -10,9 +10,9 @@ pipeline myPipeline { 1.2E2; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { 1.2; 1e10; 1e+10; diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/literals/float/scientific notation with lowercase e.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/literals/float/scientific notation with lowercase e.sdstest index 186fb383..a1e1cd16 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/literals/float/scientific notation with lowercase e.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/literals/float/scientific notation with lowercase e.sdstest @@ -1,13 +1,13 @@ -pipeline myPipeline { +function myFunction () { 1e10; 1e+10; 1e-10; 1.2e2; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { 1e10; 1e+10; 1e-10; diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/literals/float/scientific notation with uppercase e.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/literals/float/scientific notation with uppercase e.sdstest index 879a2538..9c2a3187 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/literals/float/scientific notation with uppercase e.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/literals/float/scientific notation with uppercase e.sdstest @@ -1,13 +1,13 @@ -pipeline myPipeline { +function myFunction () { 1E10; 1E+10; 1E-10; 1.2E2; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { 1E10; 1E+10; 1E-10; diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/literals/int/leading zero.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/literals/int/leading zero.sdstest index f057e896..438a93e7 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/literals/int/leading zero.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/literals/int/leading zero.sdstest @@ -1,9 +1,9 @@ -pipeline myPipeline { +function myFunction () { 01; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { 01; } diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/literals/int/multiple digits.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/literals/int/multiple digits.sdstest index a68739c2..da1be4dd 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/literals/int/multiple digits.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/literals/int/multiple digits.sdstest @@ -1,9 +1,9 @@ -pipeline myPipeline { +function myFunction () { 1234567890; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { 1234567890; } diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/literals/int/one digit.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/literals/int/one digit.sdstest index 497f4c12..4bbc36fb 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/literals/int/one digit.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/literals/int/one digit.sdstest @@ -1,9 +1,9 @@ -pipeline myPipeline { +function myFunction () { 1; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { 1; } diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/literals/null.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/literals/null.sdstest index 3407a6af..8cfa6eb2 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/literals/null.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/literals/null.sdstest @@ -1,9 +1,9 @@ -pipeline myPipeline { +function myFunction () { null; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { null; } diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/literals/string/basic content.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/literals/string/basic content.sdstest index 94a0a5fe..4216e32a 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/literals/string/basic content.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/literals/string/basic content.sdstest @@ -1,9 +1,9 @@ -pipeline myPipeline { +function myFunction () { "myString"; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { "myString"; } diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/literals/string/closing template expression delimiter.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/literals/string/closing template expression delimiter.sdstest index fa870d84..025c1c45 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/literals/string/closing template expression delimiter.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/literals/string/closing template expression delimiter.sdstest @@ -1,9 +1,9 @@ -pipeline myPipeline { +function myFunction () { "}}"; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { "}}"; } diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/literals/string/curly braces separated by space.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/literals/string/curly braces separated by space.sdstest index ee0f4f4b..7cc68483 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/literals/string/curly braces separated by space.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/literals/string/curly braces separated by space.sdstest @@ -1,9 +1,9 @@ -pipeline myPipeline { +function myFunction () { "{ {"; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { "{ {"; } diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/literals/string/empty.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/literals/string/empty.sdstest index eb036b80..6592f082 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/literals/string/empty.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/literals/string/empty.sdstest @@ -1,9 +1,9 @@ -pipeline myPipeline { +function myFunction () { ""; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { ""; } diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/literals/string/escaped curly brace.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/literals/string/escaped curly brace.sdstest index 235321a0..adc899bd 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/literals/string/escaped curly brace.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/literals/string/escaped curly brace.sdstest @@ -1,9 +1,9 @@ -pipeline myPipeline { +function myFunction () { "\{{"; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { "\{{"; } diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/literals/string/multiple lines.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/literals/string/multiple lines.sdstest index 070e3bfe..cdd3bdcc 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/literals/string/multiple lines.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/literals/string/multiple lines.sdstest @@ -1,4 +1,4 @@ -pipeline myPipeline { +function myFunction () { " multi line @@ -6,9 +6,9 @@ pipeline myPipeline { "; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { " multi line diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/literals/string/newline escape sequence.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/literals/string/newline escape sequence.sdstest index abb63986..0c541d16 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/literals/string/newline escape sequence.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/literals/string/newline escape sequence.sdstest @@ -1,9 +1,9 @@ -pipeline myPipeline { +function myFunction () { "\n"; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { "\n"; } diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/literals/string/single curly brace.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/literals/string/single curly brace.sdstest index 4e3a0fa3..5047f525 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/literals/string/single curly brace.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/literals/string/single curly brace.sdstest @@ -1,9 +1,9 @@ -pipeline myPipeline { +function myFunction () { "{"; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { "{"; } diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/literals/string/single quote.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/literals/string/single quote.sdstest index 710cd6a0..679e3580 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/literals/string/single quote.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/literals/string/single quote.sdstest @@ -1,9 +1,9 @@ -pipeline myPipeline { +function myFunction () { "'"; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { "'"; } diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/literals/string/unicode escape sequence.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/literals/string/unicode escape sequence.sdstest index 3aa4313b..684a56bf 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/literals/string/unicode escape sequence.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/literals/string/unicode escape sequence.sdstest @@ -1,9 +1,9 @@ -pipeline myPipeline { +function myFunction () { "\u000c"; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { "\u000c"; } diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/literals/true.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/literals/true.sdstest index b9138ad5..dd77d9c3 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/literals/true.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/literals/true.sdstest @@ -1,9 +1,9 @@ -pipeline myPipeline { +function myFunction () { true; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { true; } diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/logical operations/complex example.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/logical operations/complex example.sdstest index cc04409e..f5f7147c 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/logical operations/complex example.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/logical operations/complex example.sdstest @@ -1,9 +1,9 @@ -pipeline myPipeline { +function myFunction () { not true and false or true; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { not true and false or true; } diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/logical operations/conjunction.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/logical operations/conjunction.sdstest index 69d9a9eb..3f943a02 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/logical operations/conjunction.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/logical operations/conjunction.sdstest @@ -1,9 +1,9 @@ -pipeline myPipeline { +function myFunction () { false and true; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { false and true; } diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/logical operations/disjunction.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/logical operations/disjunction.sdstest index 84ecb655..b53b5e5f 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/logical operations/disjunction.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/logical operations/disjunction.sdstest @@ -1,9 +1,9 @@ -pipeline myPipeline { +function myFunction () { true or true; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { true or true; } diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/logical operations/negation.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/logical operations/negation.sdstest index 41a736c3..5244f703 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/logical operations/negation.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/logical operations/negation.sdstest @@ -1,9 +1,9 @@ -pipeline myPipeline { +function myFunction () { not true; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { not true; } diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/maps/complex key.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/maps/complex key.sdstest index f53264f3..bb0fcf30 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/maps/complex key.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/maps/complex key.sdstest @@ -1,10 +1,10 @@ -pipeline myPipeline { +function myFunction () { { f ( ) : 1 }; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { { f(): 1 }; diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/maps/complex value.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/maps/complex value.sdstest index 14cea3ff..f8c5e1a6 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/maps/complex value.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/maps/complex value.sdstest @@ -1,10 +1,10 @@ -pipeline myPipeline { +function myFunction () { { 1 : f ( ) }; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { { 1: f() }; diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/maps/nested multiple elements.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/maps/nested multiple elements.sdstest index 01597436..f7a672d0 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/maps/nested multiple elements.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/maps/nested multiple elements.sdstest @@ -1,11 +1,11 @@ -pipeline myPipeline { +function myFunction () { { 1 : { 2 : "three" , 4 : "five" } }; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { { 1: { 2: "three", diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/maps/nested one element.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/maps/nested one element.sdstest index ad8a6936..a63d5404 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/maps/nested one element.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/maps/nested one element.sdstest @@ -1,10 +1,10 @@ -pipeline myPipeline { +function myFunction () { { 1 : { 2 : "three" } }; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { { 1: {2: "three"} }; diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/maps/one level multiple elements.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/maps/one level multiple elements.sdstest index bb90ecbd..c3febd9d 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/maps/one level multiple elements.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/maps/one level multiple elements.sdstest @@ -1,10 +1,10 @@ -pipeline myPipeline { +function myFunction () { { 1 : "one" , 2 : "two" }; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { { 1: "one", 2: "two" diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/maps/one level one element.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/maps/one level one element.sdstest index 98656664..966b70bb 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/maps/one level one element.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/maps/one level one element.sdstest @@ -1,9 +1,9 @@ -pipeline myPipeline { +function myFunction () { { 1 : "one" }; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { {1: "one"}; } diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/member accesses/not null safe.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/member accesses/not null safe.sdstest index e2a09dbd..8a4df0de 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/member accesses/not null safe.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/member accesses/not null safe.sdstest @@ -1,9 +1,9 @@ -pipeline myPipeline { +function myFunction () { a . member; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { a.member; } diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/member accesses/null safe.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/member accesses/null safe.sdstest index a7a86ad1..8becfea8 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/member accesses/null safe.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/member accesses/null safe.sdstest @@ -1,9 +1,9 @@ -pipeline myPipeline { +function myFunction () { a ? . member; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { a?.member; } diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/parenthesized expressions/nested.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/parenthesized expressions/nested.sdstest index 87550654..ab9f05bf 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/parenthesized expressions/nested.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/parenthesized expressions/nested.sdstest @@ -1,9 +1,9 @@ -pipeline myPipeline { +function myFunction () { ( ( 1 + 2 ) ); } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { ((1 + 2)); } diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/parenthesized expressions/one level.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/parenthesized expressions/one level.sdstest index c277e146..5ff8fa67 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/parenthesized expressions/one level.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/parenthesized expressions/one level.sdstest @@ -1,9 +1,9 @@ -pipeline myPipeline { +function myFunction () { ( 1 + 2 ); } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { (1 + 2); } diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/reference.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/reference.sdstest index 62fad2d6..eef559ae 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/reference.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/reference.sdstest @@ -1,9 +1,9 @@ -pipeline myPipeline { +function myFunction () { a; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { a; } diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/template strings/empty template expression.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/template strings/empty template expression.sdstest index ca55879d..40592ac4 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/template strings/empty template expression.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/template strings/empty template expression.sdstest @@ -1,9 +1,9 @@ -pipeline myPipeline { +function myFunction () { "{{ }}"; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { "{{ }}"; } diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/template strings/template string with basic expression.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/template strings/template string with basic expression.sdstest index d8f58815..8be4ec98 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/template strings/template string with basic expression.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/template strings/template string with basic expression.sdstest @@ -1,9 +1,9 @@ -pipeline myPipeline { +function myFunction () { "{{ 1 }}"; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { "{{ 1 }}"; } diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/template strings/template string with two expressions.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/template strings/template string with two expressions.sdstest index 36fba2cf..d65d84cc 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/template strings/template string with two expressions.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/template strings/template string with two expressions.sdstest @@ -1,9 +1,9 @@ -pipeline myPipeline { +function myFunction () { "{{ 1 }} {{ 2 }}"; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { "{{ 1 }} {{ 2 }}"; } diff --git a/packages/ttsl-lang/tests/resources/formatting/expressions/type cast.sdstest b/packages/ttsl-lang/tests/resources/formatting/expressions/type cast.sdstest index 3bd395fb..c06890ec 100644 --- a/packages/ttsl-lang/tests/resources/formatting/expressions/type cast.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/expressions/type cast.sdstest @@ -1,9 +1,9 @@ -pipeline myPipeline { +function myFunction () { 1 as Int; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { 1 as Int; } diff --git a/packages/ttsl-lang/tests/resources/formatting/modules/annotation call and declaration.sdstest b/packages/ttsl-lang/tests/resources/formatting/modules/annotation call and declaration.sdstest index a9aafef7..6e74f2b5 100644 --- a/packages/ttsl-lang/tests/resources/formatting/modules/annotation call and declaration.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/modules/annotation call and declaration.sdstest @@ -4,7 +4,7 @@ class C -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- @Annotation1 diff --git a/packages/ttsl-lang/tests/resources/formatting/modules/annotation call and import and declaration.sdstest b/packages/ttsl-lang/tests/resources/formatting/modules/annotation call and import and declaration.sdstest index 068c3494..a19b4e5b 100644 --- a/packages/ttsl-lang/tests/resources/formatting/modules/annotation call and import and declaration.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/modules/annotation call and import and declaration.sdstest @@ -7,7 +7,7 @@ from myPackage . mySubpackage import MyClass class C -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- @Annotation1 diff --git a/packages/ttsl-lang/tests/resources/formatting/modules/annotation call and import.sdstest b/packages/ttsl-lang/tests/resources/formatting/modules/annotation call and import.sdstest index 601de9f4..0c63964e 100644 --- a/packages/ttsl-lang/tests/resources/formatting/modules/annotation call and import.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/modules/annotation call and import.sdstest @@ -4,7 +4,7 @@ from myPackage . mySubpackage import MyClass -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- @Annotation1 diff --git a/packages/ttsl-lang/tests/resources/formatting/modules/annotation call and package name and declaration.sdstest b/packages/ttsl-lang/tests/resources/formatting/modules/annotation call and package name and declaration.sdstest index b3473cf4..b6ce5d56 100644 --- a/packages/ttsl-lang/tests/resources/formatting/modules/annotation call and package name and declaration.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/modules/annotation call and package name and declaration.sdstest @@ -7,7 +7,7 @@ package myPackage class C -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- @Annotation1 diff --git a/packages/ttsl-lang/tests/resources/formatting/modules/annotation call and package name and import and declaration.sdstest b/packages/ttsl-lang/tests/resources/formatting/modules/annotation call and package name and import and declaration.sdstest index 632aa80a..bc868c4c 100644 --- a/packages/ttsl-lang/tests/resources/formatting/modules/annotation call and package name and import and declaration.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/modules/annotation call and package name and import and declaration.sdstest @@ -10,7 +10,7 @@ from myPackage . mySubpackage import MyClass class C -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- @Annotation1 diff --git a/packages/ttsl-lang/tests/resources/formatting/modules/annotation call and package name and import.sdstest b/packages/ttsl-lang/tests/resources/formatting/modules/annotation call and package name and import.sdstest index bef34ffc..e588ed01 100644 --- a/packages/ttsl-lang/tests/resources/formatting/modules/annotation call and package name and import.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/modules/annotation call and package name and import.sdstest @@ -7,7 +7,7 @@ package myPackage from myPackage . mySubpackage import MyClass -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- @Annotation1 diff --git a/packages/ttsl-lang/tests/resources/formatting/modules/annotation call and package name.sdstest b/packages/ttsl-lang/tests/resources/formatting/modules/annotation call and package name.sdstest index c2e552b6..f3de3935 100644 --- a/packages/ttsl-lang/tests/resources/formatting/modules/annotation call and package name.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/modules/annotation call and package name.sdstest @@ -4,7 +4,7 @@ package myPackage -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- @Annotation1 diff --git a/packages/ttsl-lang/tests/resources/formatting/modules/annotation call.sdstest b/packages/ttsl-lang/tests/resources/formatting/modules/annotation call.sdstest index ba2bf936..a491fe24 100644 --- a/packages/ttsl-lang/tests/resources/formatting/modules/annotation call.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/modules/annotation call.sdstest @@ -1,6 +1,6 @@ @Annotation1 -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- @Annotation1 diff --git a/packages/ttsl-lang/tests/resources/formatting/modules/annotation calls and declarations.sdstest b/packages/ttsl-lang/tests/resources/formatting/modules/annotation calls and declarations.sdstest index 4cf4f408..c7914654 100644 --- a/packages/ttsl-lang/tests/resources/formatting/modules/annotation calls and declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/modules/annotation calls and declarations.sdstest @@ -9,7 +9,7 @@ class C class D -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- @Annotation1 @Annotation2 diff --git a/packages/ttsl-lang/tests/resources/formatting/modules/annotation calls and imports and declarations.sdstest b/packages/ttsl-lang/tests/resources/formatting/modules/annotation calls and imports and declarations.sdstest index 8a3cd6c2..6d66bf6a 100644 --- a/packages/ttsl-lang/tests/resources/formatting/modules/annotation calls and imports and declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/modules/annotation calls and imports and declarations.sdstest @@ -18,7 +18,7 @@ class C class D -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- @Annotation1 @Annotation2 diff --git a/packages/ttsl-lang/tests/resources/formatting/modules/annotation calls and imports.sdstest b/packages/ttsl-lang/tests/resources/formatting/modules/annotation calls and imports.sdstest index d0520afa..6d0b13e3 100644 --- a/packages/ttsl-lang/tests/resources/formatting/modules/annotation calls and imports.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/modules/annotation calls and imports.sdstest @@ -12,7 +12,7 @@ from myPackage . mySubpackage import * from myPackage . mySubpackage import MyClass , MyClass as Class -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- @Annotation1 @Annotation2 diff --git a/packages/ttsl-lang/tests/resources/formatting/modules/annotation calls and package name and declarations.sdstest b/packages/ttsl-lang/tests/resources/formatting/modules/annotation calls and package name and declarations.sdstest index fa0f1b5b..fbaef583 100644 --- a/packages/ttsl-lang/tests/resources/formatting/modules/annotation calls and package name and declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/modules/annotation calls and package name and declarations.sdstest @@ -12,7 +12,7 @@ class C class D -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- @Annotation1 @Annotation2 diff --git a/packages/ttsl-lang/tests/resources/formatting/modules/annotation calls and package name and imports and declarations.sdstest b/packages/ttsl-lang/tests/resources/formatting/modules/annotation calls and package name and imports and declarations.sdstest index 6da3c081..042d3aaf 100644 --- a/packages/ttsl-lang/tests/resources/formatting/modules/annotation calls and package name and imports and declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/modules/annotation calls and package name and imports and declarations.sdstest @@ -21,7 +21,7 @@ class C class D -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- @Annotation1 @Annotation2 diff --git a/packages/ttsl-lang/tests/resources/formatting/modules/annotation calls and package name and imports.sdstest b/packages/ttsl-lang/tests/resources/formatting/modules/annotation calls and package name and imports.sdstest index 1aec5b7f..9091db32 100644 --- a/packages/ttsl-lang/tests/resources/formatting/modules/annotation calls and package name and imports.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/modules/annotation calls and package name and imports.sdstest @@ -15,7 +15,7 @@ from myPackage . mySubpackage import * from myPackage . mySubpackage import MyClass , MyClass as Class -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- @Annotation1 @Annotation2 diff --git a/packages/ttsl-lang/tests/resources/formatting/modules/annotation calls and package name.sdstest b/packages/ttsl-lang/tests/resources/formatting/modules/annotation calls and package name.sdstest index d06688d3..7ced3e0c 100644 --- a/packages/ttsl-lang/tests/resources/formatting/modules/annotation calls and package name.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/modules/annotation calls and package name.sdstest @@ -6,7 +6,7 @@ package myPackage -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- @Annotation1 @Annotation2 diff --git a/packages/ttsl-lang/tests/resources/formatting/modules/annotation calls.sdstest b/packages/ttsl-lang/tests/resources/formatting/modules/annotation calls.sdstest index 875e804b..67f7d065 100644 --- a/packages/ttsl-lang/tests/resources/formatting/modules/annotation calls.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/modules/annotation calls.sdstest @@ -3,7 +3,7 @@ @Annotation2 -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- @Annotation1 @Annotation2 diff --git a/packages/ttsl-lang/tests/resources/formatting/modules/declaration.sdstest b/packages/ttsl-lang/tests/resources/formatting/modules/declaration.sdstest index d0cb6c93..48702a7e 100644 --- a/packages/ttsl-lang/tests/resources/formatting/modules/declaration.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/modules/declaration.sdstest @@ -1,6 +1,6 @@ class C -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- class C diff --git a/packages/ttsl-lang/tests/resources/formatting/modules/declarations.sdstest b/packages/ttsl-lang/tests/resources/formatting/modules/declarations.sdstest index b35b30a3..c0e4f1e8 100644 --- a/packages/ttsl-lang/tests/resources/formatting/modules/declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/modules/declarations.sdstest @@ -4,7 +4,7 @@ class C class D -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- class C diff --git a/packages/ttsl-lang/tests/resources/formatting/modules/empty.sdstest b/packages/ttsl-lang/tests/resources/formatting/modules/empty.sdstest index 2acf4e33..3f0f4d4b 100644 --- a/packages/ttsl-lang/tests/resources/formatting/modules/empty.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/modules/empty.sdstest @@ -1,5 +1,5 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error diff --git a/packages/ttsl-lang/tests/resources/formatting/modules/full.sdstest b/packages/ttsl-lang/tests/resources/formatting/modules/full.sdstest index 12289064..a335c898 100644 --- a/packages/ttsl-lang/tests/resources/formatting/modules/full.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/modules/full.sdstest @@ -64,7 +64,7 @@ segment s() {} schema S {} -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- @Annotation1 @Annotation2 diff --git a/packages/ttsl-lang/tests/resources/formatting/modules/import and declaration.sdstest b/packages/ttsl-lang/tests/resources/formatting/modules/import and declaration.sdstest index 1162a351..9136371d 100644 --- a/packages/ttsl-lang/tests/resources/formatting/modules/import and declaration.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/modules/import and declaration.sdstest @@ -4,7 +4,7 @@ from myPackage . mySubpackage import MyClass class C -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- from myPackage.mySubpackage import MyClass diff --git a/packages/ttsl-lang/tests/resources/formatting/modules/import.sdstest b/packages/ttsl-lang/tests/resources/formatting/modules/import.sdstest index 5fc63e34..06f12e6c 100644 --- a/packages/ttsl-lang/tests/resources/formatting/modules/import.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/modules/import.sdstest @@ -1,6 +1,6 @@ from myPackage . mySubpackage import MyClass -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- from myPackage.mySubpackage import MyClass diff --git a/packages/ttsl-lang/tests/resources/formatting/modules/imports and declarations.sdstest b/packages/ttsl-lang/tests/resources/formatting/modules/imports and declarations.sdstest index 36875e4f..5b042580 100644 --- a/packages/ttsl-lang/tests/resources/formatting/modules/imports and declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/modules/imports and declarations.sdstest @@ -13,7 +13,7 @@ class C class D -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- from myPackage.mySubpackage import MyClass from myPackage.mySubpackage import MyClass as Class diff --git a/packages/ttsl-lang/tests/resources/formatting/modules/imports.sdstest b/packages/ttsl-lang/tests/resources/formatting/modules/imports.sdstest index 83b142d0..cbb45737 100644 --- a/packages/ttsl-lang/tests/resources/formatting/modules/imports.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/modules/imports.sdstest @@ -7,7 +7,7 @@ from myPackage . mySubpackage import * from myPackage . mySubpackage import MyClass , MyClass as Class -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- from myPackage.mySubpackage import MyClass from myPackage.mySubpackage import MyClass as Class diff --git a/packages/ttsl-lang/tests/resources/formatting/modules/package name and declaration.sdstest b/packages/ttsl-lang/tests/resources/formatting/modules/package name and declaration.sdstest index 66fccfb4..be018dff 100644 --- a/packages/ttsl-lang/tests/resources/formatting/modules/package name and declaration.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/modules/package name and declaration.sdstest @@ -4,7 +4,7 @@ package myPackage class C -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- package myPackage diff --git a/packages/ttsl-lang/tests/resources/formatting/modules/package name and declarations.sdstest b/packages/ttsl-lang/tests/resources/formatting/modules/package name and declarations.sdstest index b12ede61..d2bf5aaf 100644 --- a/packages/ttsl-lang/tests/resources/formatting/modules/package name and declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/modules/package name and declarations.sdstest @@ -7,7 +7,7 @@ class C class D -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- package myPackage diff --git a/packages/ttsl-lang/tests/resources/formatting/modules/package name and import and declaration.sdstest b/packages/ttsl-lang/tests/resources/formatting/modules/package name and import and declaration.sdstest index 6364241a..3a28317f 100644 --- a/packages/ttsl-lang/tests/resources/formatting/modules/package name and import and declaration.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/modules/package name and import and declaration.sdstest @@ -7,7 +7,7 @@ from myPackage . mySubpackage import MyClass class C -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- package myPackage diff --git a/packages/ttsl-lang/tests/resources/formatting/modules/package name and import.sdstest b/packages/ttsl-lang/tests/resources/formatting/modules/package name and import.sdstest index 7649fff6..63c0bb6d 100644 --- a/packages/ttsl-lang/tests/resources/formatting/modules/package name and import.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/modules/package name and import.sdstest @@ -4,7 +4,7 @@ package myPackage from myPackage . mySubpackage import MyClass -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- package myPackage diff --git a/packages/ttsl-lang/tests/resources/formatting/modules/package name and imports and declarations.sdstest b/packages/ttsl-lang/tests/resources/formatting/modules/package name and imports and declarations.sdstest index 77f480f8..11985f05 100644 --- a/packages/ttsl-lang/tests/resources/formatting/modules/package name and imports and declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/modules/package name and imports and declarations.sdstest @@ -15,7 +15,7 @@ class C class D -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- package myPackage diff --git a/packages/ttsl-lang/tests/resources/formatting/modules/package name and imports.sdstest b/packages/ttsl-lang/tests/resources/formatting/modules/package name and imports.sdstest index 426fd93f..ab8fd7fb 100644 --- a/packages/ttsl-lang/tests/resources/formatting/modules/package name and imports.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/modules/package name and imports.sdstest @@ -10,7 +10,7 @@ from myPackage . mySubpackage import * from myPackage . mySubpackage import MyClass , MyClass as Class -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- package myPackage diff --git a/packages/ttsl-lang/tests/resources/formatting/modules/package name.sdstest b/packages/ttsl-lang/tests/resources/formatting/modules/package name.sdstest index b2f23bf3..ca942cec 100644 --- a/packages/ttsl-lang/tests/resources/formatting/modules/package name.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/modules/package name.sdstest @@ -1,6 +1,6 @@ package myPackage -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- package myPackage diff --git a/packages/ttsl-lang/tests/resources/formatting/schema/annotation call.sdstest b/packages/ttsl-lang/tests/resources/formatting/schema/annotation call.sdstest index 0870a555..2bae8347 100644 --- a/packages/ttsl-lang/tests/resources/formatting/schema/annotation call.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/schema/annotation call.sdstest @@ -2,7 +2,7 @@ package test @Annotation schema MySchema { } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- package test diff --git a/packages/ttsl-lang/tests/resources/formatting/schema/empty schema.sdstest b/packages/ttsl-lang/tests/resources/formatting/schema/empty schema.sdstest index 5a0689a3..249aab07 100644 --- a/packages/ttsl-lang/tests/resources/formatting/schema/empty schema.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/schema/empty schema.sdstest @@ -1,5 +1,5 @@ schema MySchema { } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- schema MySchema {} diff --git a/packages/ttsl-lang/tests/resources/formatting/schema/one column.sdstest b/packages/ttsl-lang/tests/resources/formatting/schema/one column.sdstest index fb9a45b6..981d6016 100644 --- a/packages/ttsl-lang/tests/resources/formatting/schema/one column.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/schema/one column.sdstest @@ -2,7 +2,7 @@ schema MySchema { "column1" : Int } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- schema MySchema { "column1": Int diff --git a/packages/ttsl-lang/tests/resources/formatting/schema/two columns.sdstest b/packages/ttsl-lang/tests/resources/formatting/schema/two columns.sdstest index ff79b067..0c579bd6 100644 --- a/packages/ttsl-lang/tests/resources/formatting/schema/two columns.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/schema/two columns.sdstest @@ -5,7 +5,7 @@ schema MySchema { "column2" : String } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- schema MySchema { "column1": Int, diff --git a/packages/ttsl-lang/tests/resources/formatting/statements/assignments/in block lambda.sdstest b/packages/ttsl-lang/tests/resources/formatting/statements/assignments/in block lambda.sdstest index 6c131b15..38b081db 100644 --- a/packages/ttsl-lang/tests/resources/formatting/statements/assignments/in block lambda.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/statements/assignments/in block lambda.sdstest @@ -1,13 +1,13 @@ -pipeline myPipeline { +function myFunction () { () { val a = 0 ; val a , _ , yield b = call() ; }; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { () { val a = 0; val a, _, yield b = call(); diff --git a/packages/ttsl-lang/tests/resources/formatting/statements/assignments/in pipeline.sdstest b/packages/ttsl-lang/tests/resources/formatting/statements/assignments/in pipeline.sdstest index c0fcc609..26982684 100644 --- a/packages/ttsl-lang/tests/resources/formatting/statements/assignments/in pipeline.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/statements/assignments/in pipeline.sdstest @@ -1,11 +1,11 @@ -pipeline myPipeline { +function myFunction () { val a = 0 ; val a , _ , yield b = call() ; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { val a = 0; val a, _, yield b = call(); } diff --git a/packages/ttsl-lang/tests/resources/formatting/statements/assignments/in segment.sdstest b/packages/ttsl-lang/tests/resources/formatting/statements/assignments/in segment.sdstest index 10cf1440..3b747e75 100644 --- a/packages/ttsl-lang/tests/resources/formatting/statements/assignments/in segment.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/statements/assignments/in segment.sdstest @@ -3,7 +3,7 @@ segment mySegment() { val a , _ , yield b = call() ; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- segment mySegment() { val a = 0; diff --git a/packages/ttsl-lang/tests/resources/formatting/statements/expression statements/in block lambda.sdstest b/packages/ttsl-lang/tests/resources/formatting/statements/expression statements/in block lambda.sdstest index 625725d3..fd3595b0 100644 --- a/packages/ttsl-lang/tests/resources/formatting/statements/expression statements/in block lambda.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/statements/expression statements/in block lambda.sdstest @@ -1,12 +1,12 @@ -pipeline myPipeline { +function myFunction () { () { call() ; }; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { () { call(); }; diff --git a/packages/ttsl-lang/tests/resources/formatting/statements/expression statements/in pipeline.sdstest b/packages/ttsl-lang/tests/resources/formatting/statements/expression statements/in pipeline.sdstest index 3163f817..86d4b775 100644 --- a/packages/ttsl-lang/tests/resources/formatting/statements/expression statements/in pipeline.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/statements/expression statements/in pipeline.sdstest @@ -1,9 +1,9 @@ -pipeline myPipeline { +function myFunction () { call() ; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { call(); } diff --git a/packages/ttsl-lang/tests/resources/formatting/statements/expression statements/in segment.sdstest b/packages/ttsl-lang/tests/resources/formatting/statements/expression statements/in segment.sdstest index 1e362798..afba57ee 100644 --- a/packages/ttsl-lang/tests/resources/formatting/statements/expression statements/in segment.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/statements/expression statements/in segment.sdstest @@ -2,7 +2,7 @@ segment mySegment() { call() ; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- segment mySegment() { call(); diff --git a/packages/ttsl-lang/tests/resources/formatting/statements/flexible new lines/in block lambda.sdstest b/packages/ttsl-lang/tests/resources/formatting/statements/flexible new lines/in block lambda.sdstest index 650daa99..b6c21e14 100644 --- a/packages/ttsl-lang/tests/resources/formatting/statements/flexible new lines/in block lambda.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/statements/flexible new lines/in block lambda.sdstest @@ -1,4 +1,4 @@ -pipeline myPipeline { +function myFunction () { () { val a = 0 ; @@ -8,9 +8,9 @@ pipeline myPipeline { }; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { () { val a = 0; diff --git a/packages/ttsl-lang/tests/resources/formatting/statements/flexible new lines/in pipeline.sdstest b/packages/ttsl-lang/tests/resources/formatting/statements/flexible new lines/in pipeline.sdstest index 8b738454..db3db546 100644 --- a/packages/ttsl-lang/tests/resources/formatting/statements/flexible new lines/in pipeline.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/statements/flexible new lines/in pipeline.sdstest @@ -1,4 +1,4 @@ -pipeline myPipeline { +function myFunction () { val a = 0 ; @@ -6,9 +6,9 @@ pipeline myPipeline { } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { val a = 0; diff --git a/packages/ttsl-lang/tests/resources/formatting/statements/flexible new lines/in segment.sdstest b/packages/ttsl-lang/tests/resources/formatting/statements/flexible new lines/in segment.sdstest index 76bd75c7..f5ccac22 100644 --- a/packages/ttsl-lang/tests/resources/formatting/statements/flexible new lines/in segment.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/statements/flexible new lines/in segment.sdstest @@ -6,7 +6,7 @@ segment mySegment() { } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- segment mySegment() { diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/argument list of annotation call (complex).sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/argument list of annotation call (complex).sdstest index ac01c901..15ca3694 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/argument list of annotation call (complex).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/argument list of annotation call (complex).sdstest @@ -1,6 +1,6 @@ @A(f() , 2 , ) -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- @A( f(), diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/argument list of annotation call (long).sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/argument list of annotation call (long).sdstest index f64182ff..7b347a69 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/argument list of annotation call (long).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/argument list of annotation call (long).sdstest @@ -1,6 +1,6 @@ @A(1 , 2 , 3 , 4 , ) -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- @A( 1, diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/argument list of annotation call.sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/argument list of annotation call.sdstest index de6693cd..e3b630ad 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/argument list of annotation call.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/argument list of annotation call.sdstest @@ -1,5 +1,5 @@ @A(1 , 2 , ) -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- @A(1, 2,) diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/argument list of call (complex).sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/argument list of call (complex).sdstest index 3e03439f..fa625a50 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/argument list of call (complex).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/argument list of call (complex).sdstest @@ -2,7 +2,7 @@ pipeline p { f(f() , 2 , ); } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- pipeline p { f( diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/argument list of call (long).sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/argument list of call (long).sdstest index dcb67ee4..1b12d6fe 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/argument list of call (long).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/argument list of call (long).sdstest @@ -2,7 +2,7 @@ pipeline p { f(1 , 2 , 3 , 4 , ); } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- pipeline p { f( diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/argument list of call.sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/argument list of call.sdstest index c7a0b405..5352b181 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/argument list of call.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/argument list of call.sdstest @@ -2,7 +2,7 @@ pipeline p { f(1 , 2 , ); } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- pipeline p { f(1, 2,); diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/assignee list of assignment in block lambda.sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/assignee list of assignment in block lambda.sdstest index 06d54094..eb086227 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/assignee list of assignment in block lambda.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/assignee list of assignment in block lambda.sdstest @@ -4,7 +4,7 @@ pipeline p { }; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- pipeline p { () { diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/assignee list of assignment.sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/assignee list of assignment.sdstest index 8a96454f..46b9abe9 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/assignee list of assignment.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/assignee list of assignment.sdstest @@ -2,7 +2,7 @@ pipeline p { val a , val b , = f(); } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- pipeline p { val a, val b, = f(); diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/column list of schema.sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/column list of schema.sdstest index a1e22dc9..9ce6336c 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/column list of schema.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/column list of schema.sdstest @@ -3,7 +3,7 @@ schema MySchemaWithTrailingComma { "column2" : String , } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- schema MySchemaWithTrailingComma { "column1": Int, diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/constraint list of annotation.sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/constraint list of annotation.sdstest index c1cdddce..a94442a5 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/constraint list of annotation.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/constraint list of annotation.sdstest @@ -3,7 +3,7 @@ annotation A where { q > 1 , } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- annotation A where { p < 0, diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/constraint list of class.sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/constraint list of class.sdstest index 985fc61f..1d514dd8 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/constraint list of class.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/constraint list of class.sdstest @@ -3,7 +3,7 @@ class C where { q > 1 , } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- class C where { p < 0, diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/constraint list of enum variant.sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/constraint list of enum variant.sdstest index b44b943c..4e7d613f 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/constraint list of enum variant.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/constraint list of enum variant.sdstest @@ -5,7 +5,7 @@ enum E { } } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- enum E { A where { diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/constraint list of function.sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/constraint list of function.sdstest index e5ec138e..707af3f2 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/constraint list of function.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/constraint list of function.sdstest @@ -3,7 +3,7 @@ fun f() where { q > 1 , } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- fun f() where { p < 0, diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/elements of list (complex).sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/elements of list (complex).sdstest index 451b281f..e6138461 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/elements of list (complex).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/elements of list (complex).sdstest @@ -1,10 +1,10 @@ -pipeline myPipeline { +function myFunction () { [ f ( ) , 2 , ]; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { [ f(), 2, diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/elements of list.sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/elements of list.sdstest index e8d34cb0..cd2fd709 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/elements of list.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/elements of list.sdstest @@ -1,9 +1,9 @@ -pipeline myPipeline { +function myFunction () { [ 1 , 2 , ]; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { [1, 2,]; } diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/entries of map (complex).sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/entries of map (complex).sdstest index b639efd4..fc101138 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/entries of map (complex).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/entries of map (complex).sdstest @@ -1,10 +1,10 @@ -pipeline myPipeline { +function myFunction () { { 1 : { } , }; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { { 1: {}, }; diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/entries of map (multiple entries).sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/entries of map (multiple entries).sdstest index 2bb09e05..acb0ac50 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/entries of map (multiple entries).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/entries of map (multiple entries).sdstest @@ -1,10 +1,10 @@ -pipeline myPipeline { +function myFunction () { { 1 : "one" , 2 : "two" , }; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { { 1: "one", 2: "two", diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/entries of map (one literal entry).sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/entries of map (one literal entry).sdstest index 629a1617..8478a9f7 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/entries of map (one literal entry).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/entries of map (one literal entry).sdstest @@ -1,9 +1,9 @@ -pipeline myPipeline { +function myFunction () { { 1 : "one" , }; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- -pipeline myPipeline { +function myFunction () { {1: "one",}; } diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/imported declaration list in qualified import.sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/imported declaration list in qualified import.sdstest index 8abd49c5..7a239ce6 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/imported declaration list in qualified import.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/imported declaration list in qualified import.sdstest @@ -1,5 +1,5 @@ from myPackage . mySubpackage import MyClass , MyClass as Class , -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- from myPackage.mySubpackage import MyClass, MyClass as Class, diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/literal list of literal type.sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/literal list of literal type.sdstest index ccdfc1aa..b9a54c6b 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/literal list of literal type.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/literal list of literal type.sdstest @@ -2,7 +2,7 @@ segment s( f: literal<1.0 , null , > ) {} -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- segment s( f: literal<1.0, null,> diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of annotation (complex).sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of annotation (complex).sdstest index 6dccd04e..04c5dfcb 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of annotation (complex).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of annotation (complex).sdstest @@ -1,6 +1,6 @@ annotation A(a: A.B , b: Int , ) -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- annotation A( a: A.B, diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of annotation (long).sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of annotation (long).sdstest index ed2c59cb..9990754a 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of annotation (long).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of annotation (long).sdstest @@ -1,6 +1,6 @@ annotation A(a: Int , b: Int , c: Int , d: Int , ) -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- annotation A( a: Int, diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of annotation (with annotation).sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of annotation (with annotation).sdstest index ecf5740c..624d7a95 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of annotation (with annotation).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of annotation (with annotation).sdstest @@ -1,6 +1,6 @@ annotation A(@Annotation a: Int , b: Int , ) -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- annotation A( @Annotation diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of annotation.sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of annotation.sdstest index b1a4ece0..de92d14a 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of annotation.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of annotation.sdstest @@ -1,5 +1,5 @@ annotation A(a: Int , b: Int , ) -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- annotation A(a: Int, b: Int,) diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of block lambda (complex).sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of block lambda (complex).sdstest index 6866a86d..b307912f 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of block lambda (complex).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of block lambda (complex).sdstest @@ -2,7 +2,7 @@ pipeline p { (a: A.B , b: Int , ){}; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- pipeline p { ( diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of block lambda (long).sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of block lambda (long).sdstest index 84eee043..3ddda087 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of block lambda (long).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of block lambda (long).sdstest @@ -2,7 +2,7 @@ pipeline p { (a: Int , b: Int , c: Int , d: Int , ) {}; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- pipeline p { ( diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of block lambda (with annotation).sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of block lambda (with annotation).sdstest index 66f19f9f..fdb57edf 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of block lambda (with annotation).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of block lambda (with annotation).sdstest @@ -2,7 +2,7 @@ pipeline p { (@Annotation a: Int , b: Int , ) {}; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- pipeline p { ( diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of block lambda.sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of block lambda.sdstest index bdfa9324..1d39e556 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of block lambda.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of block lambda.sdstest @@ -2,7 +2,7 @@ pipeline p { (first , second , ) {}; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- pipeline p { (first, second,) {}; diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of callable type (complex).sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of callable type (complex).sdstest index 428c48c1..b36de9aa 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of callable type (complex).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of callable type (complex).sdstest @@ -2,7 +2,7 @@ segment s( f: (a: A.B , b: Int , ) -> () ) {} -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- segment s( f: ( diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of callable type (long).sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of callable type (long).sdstest index 33494378..f138327d 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of callable type (long).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of callable type (long).sdstest @@ -2,7 +2,7 @@ segment s( f: (a: Int , b: Int , c: Int , d: Int , ) -> () ) {} -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- segment s( f: ( diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of callable type (with annotation).sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of callable type (with annotation).sdstest index 68af1106..98c31f7f 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of callable type (with annotation).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of callable type (with annotation).sdstest @@ -2,7 +2,7 @@ segment s( f: (@Annotation a: Int , b: Int , ) -> () ) {} -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- segment s( f: ( diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of callable type.sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of callable type.sdstest index d546c229..4943a38b 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of callable type.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of callable type.sdstest @@ -2,7 +2,7 @@ segment s( f: (x: Int , y: Int , ) -> () ) {} -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- segment s( f: (x: Int, y: Int,) -> () diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of class (complex).sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of class (complex).sdstest index 507457eb..7da41030 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of class (complex).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of class (complex).sdstest @@ -1,6 +1,6 @@ class C(a: A.B , b: Int , ) -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- class C( a: A.B, diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of class (long).sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of class (long).sdstest index 184a9a2b..c30d2589 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of class (long).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of class (long).sdstest @@ -1,6 +1,6 @@ class C(a: Int , b: Int , c: Int , d: Int , ) -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- class C( a: Int, diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of class (with annotation).sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of class (with annotation).sdstest index 5bdb796c..f6fe119a 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of class (with annotation).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of class (with annotation).sdstest @@ -1,6 +1,6 @@ class C(@Annotation a: Int , b: Int , ) -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- class C( @Annotation diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of class.sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of class.sdstest index 42908183..8cc187de 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of class.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of class.sdstest @@ -1,5 +1,5 @@ class C(a: Int , b: Int , ) -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- class C(a: Int, b: Int,) diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of enum variant (complex).sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of enum variant (complex).sdstest index bcae9764..0e439779 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of enum variant (complex).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of enum variant (complex).sdstest @@ -2,7 +2,7 @@ enum E { A(a: A.B , b: Int , ) } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- enum E { A( diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of enum variant (long).sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of enum variant (long).sdstest index b313a955..778963de 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of enum variant (long).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of enum variant (long).sdstest @@ -2,7 +2,7 @@ enum E { A(a: Int , b: Int , c: Int , d: Int , ) } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- enum E { A( diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of enum variant (with annotation).sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of enum variant (with annotation).sdstest index 58496e85..d7b2dde2 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of enum variant (with annotation).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of enum variant (with annotation).sdstest @@ -2,7 +2,7 @@ enum E { A(@Annotation a: Int , b: Int , ) } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- enum E { A( diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of enum variant.sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of enum variant.sdstest index c09fd65b..b1fbe6c7 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of enum variant.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of enum variant.sdstest @@ -2,7 +2,7 @@ enum E { A(a: Int , b: Int , ) } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- enum E { A(a: Int, b: Int,) diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of expression lambda (complex).sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of expression lambda (complex).sdstest index 7c7a05e8..cec98de0 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of expression lambda (complex).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of expression lambda (complex).sdstest @@ -2,7 +2,7 @@ pipeline p { (a: A.B , b: Int , ) -> 1; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- pipeline p { ( diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of expression lambda (long).sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of expression lambda (long).sdstest index 9eb0b697..7b72dfae 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of expression lambda (long).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of expression lambda (long).sdstest @@ -2,7 +2,7 @@ pipeline p { (a: Int , b: Int , c: Int , d: Int , ) -> 1; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- pipeline p { ( diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of expression lambda (with annotation).sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of expression lambda (with annotation).sdstest index c296f492..25c4bd92 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of expression lambda (with annotation).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of expression lambda (with annotation).sdstest @@ -2,7 +2,7 @@ pipeline p { (@Annotation a: Int , b: Int , ) -> 1; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- pipeline p { ( diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of expression lambda.sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of expression lambda.sdstest index a6d19261..e3973bf0 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of expression lambda.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of expression lambda.sdstest @@ -2,7 +2,7 @@ pipeline p { (first , second , ) -> 1; } -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- pipeline p { (first, second,) -> 1; diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of function (complex).sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of function (complex).sdstest index 86dc4df2..ef51e8e8 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of function (complex).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of function (complex).sdstest @@ -1,6 +1,6 @@ fun f(a: A.B , b: Int , ) -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- fun f( a: A.B, diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of function (long).sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of function (long).sdstest index c51b2d7c..cda94428 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of function (long).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of function (long).sdstest @@ -1,6 +1,6 @@ fun f(a: Int , b: Int , c: Int , d: Int , ) -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- fun f( a: Int, diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of function (with annotation).sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of function (with annotation).sdstest index e5711472..2b2a8af4 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of function (with annotation).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of function (with annotation).sdstest @@ -1,6 +1,6 @@ fun f(@Annotation a: Int , b: Int , ) -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- fun f( @Annotation diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of function.sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of function.sdstest index be4f8e33..1eb8b221 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of function.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of function.sdstest @@ -1,5 +1,5 @@ fun f(a: Int , b: Int , ) -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- fun f(a: Int, b: Int,) diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of segment (complex).sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of segment (complex).sdstest index c1789019..7b19be52 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of segment (complex).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of segment (complex).sdstest @@ -1,6 +1,6 @@ segment s(a: A.B , b: Int , ) {} -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- segment s( a: A.B, diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of segment (long).sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of segment (long).sdstest index 49407f81..e35e2849 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of segment (long).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of segment (long).sdstest @@ -1,6 +1,6 @@ segment s(a: Int , b: Int , c: Int , d: Int , ) {} -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- segment s( a: Int, diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of segment (with annotation).sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of segment (with annotation).sdstest index 562e8831..faff412e 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of segment (with annotation).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of segment (with annotation).sdstest @@ -1,6 +1,6 @@ segment s(@Annotation a: Int , b: Int , ) {} -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- segment s( @Annotation diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of segment.sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of segment.sdstest index d54279f2..af88783e 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of segment.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parameter list of segment.sdstest @@ -1,5 +1,5 @@ segment s(a: Int , b: Int , ) {} -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- segment s(a: Int, b: Int,) {} diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parent type list of class.sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parent type list of class.sdstest index 548bce99..b10a40e7 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/parent type list of class.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/parent type list of class.sdstest @@ -1,5 +1,5 @@ class C sub D , E , {} -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- class C sub D, E, {} diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/result list of callable type (complex).sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/result list of callable type (complex).sdstest index bf97ef7d..0ad335de 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/result list of callable type (complex).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/result list of callable type (complex).sdstest @@ -2,7 +2,7 @@ segment s( f: () -> (x: A.B , y: Int , ) ) {} -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- segment s( f: () -> ( diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/result list of callable type (long).sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/result list of callable type (long).sdstest index 5d6ac81a..f2994645 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/result list of callable type (long).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/result list of callable type (long).sdstest @@ -2,7 +2,7 @@ segment s( f: () -> (x: Int , y: Int , a: Int , b: Int , ) ) {} -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- segment s( f: () -> ( diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/result list of callable type (with annotation).sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/result list of callable type (with annotation).sdstest index ce274a10..422321fb 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/result list of callable type (with annotation).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/result list of callable type (with annotation).sdstest @@ -2,7 +2,7 @@ segment s( f: () -> (@Annotation x: Int , y: Int , ) ) {} -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- segment s( f: () -> ( diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/result list of callable type.sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/result list of callable type.sdstest index c0f2822e..6f5ea361 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/result list of callable type.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/result list of callable type.sdstest @@ -2,7 +2,7 @@ segment s( f: () -> (x: Int , y: Int , ) ) {} -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- segment s( f: () -> (x: Int, y: Int,) diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/result list of function (complex).sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/result list of function (complex).sdstest index e3df3a4a..efc28a46 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/result list of function (complex).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/result list of function (complex).sdstest @@ -1,6 +1,6 @@ fun f() -> (x: A.B , y: Int , ) -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- fun f() -> ( x: A.B, diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/result list of function (long).sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/result list of function (long).sdstest index aad0f52a..299757cc 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/result list of function (long).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/result list of function (long).sdstest @@ -1,6 +1,6 @@ fun f() -> (x: Int , y: Int , a: Int , b: Int , ) -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- fun f() -> ( x: Int, diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/result list of function (with annotation).sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/result list of function (with annotation).sdstest index a7922ce4..4f66aae5 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/result list of function (with annotation).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/result list of function (with annotation).sdstest @@ -1,6 +1,6 @@ fun f() -> (@Annotation x: Int , y: Int , ) -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- fun f() -> ( @Annotation diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/result list of function.sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/result list of function.sdstest index 4f38d6dc..487cc746 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/result list of function.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/result list of function.sdstest @@ -1,5 +1,5 @@ fun f() -> (first: Int , second: Int , ) -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- fun f() -> (first: Int, second: Int,) diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/result list of segment (complex).sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/result list of segment (complex).sdstest index b0d72246..1ec699a5 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/result list of segment (complex).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/result list of segment (complex).sdstest @@ -1,6 +1,6 @@ segment s() -> (x: A.B , y: Int , ) {} -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- segment s() -> ( x: A.B, diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/result list of segment (long).sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/result list of segment (long).sdstest index 4ff55165..2cba16ed 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/result list of segment (long).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/result list of segment (long).sdstest @@ -1,6 +1,6 @@ segment s() -> (x: Int , y: Int , a: Int , b: Int , ) {} -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- segment s() -> ( x: Int, diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/result list of segment (with annotation).sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/result list of segment (with annotation).sdstest index e35e5c8f..5a0a4214 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/result list of segment (with annotation).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/result list of segment (with annotation).sdstest @@ -1,6 +1,6 @@ segment s() -> (@Annotation x: Int , y: Int , ) {} -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- segment s() -> ( @Annotation diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/result list of segment.sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/result list of segment.sdstest index 2f92b8c2..29358546 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/result list of segment.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/result list of segment.sdstest @@ -1,5 +1,5 @@ segment s() -> (first: Int , second: Int , ) {} -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- segment s() -> (first: Int, second: Int,) {} diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/type argument list of named type.sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/type argument list of named type.sdstest index bb34ddc3..46c4095a 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/type argument list of named type.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/type argument list of named type.sdstest @@ -2,7 +2,7 @@ segment s( f: Type ) {} -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- segment s( f: Type diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/type argument list of union type.sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/type argument list of union type.sdstest index 75b5f27c..f977c9f6 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/type argument list of union type.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/type argument list of union type.sdstest @@ -2,7 +2,7 @@ segment s( f: union ) {} -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- segment s( f: union diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/type parameter list of class (long).sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/type parameter list of class (long).sdstest index 0de4c727..f5e81214 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/type parameter list of class (long).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/type parameter list of class (long).sdstest @@ -1,6 +1,6 @@ class C -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- class C< K, diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/type parameter list of class (with annotation).sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/type parameter list of class (with annotation).sdstest index 44e9b2db..54505629 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/type parameter list of class (with annotation).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/type parameter list of class (with annotation).sdstest @@ -1,6 +1,6 @@ class C<@Annotation K , V , > -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- class C< @Annotation diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/type parameter list of class.sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/type parameter list of class.sdstest index a82487c6..5104df1f 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/type parameter list of class.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/type parameter list of class.sdstest @@ -1,5 +1,5 @@ class C -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- class C diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/type parameter list of function (long).sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/type parameter list of function (long).sdstest index 019809b1..2d00cb42 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/type parameter list of function (long).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/type parameter list of function (long).sdstest @@ -1,6 +1,6 @@ fun f() -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- fun f< K, diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/type parameter list of function (with annotation).sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/type parameter list of function (with annotation).sdstest index 83d95a2d..a9c7f48c 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/type parameter list of function (with annotation).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/type parameter list of function (with annotation).sdstest @@ -1,6 +1,6 @@ fun f<@Annotation K , V , >() -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- fun f< @Annotation diff --git a/packages/ttsl-lang/tests/resources/formatting/trailing commas/type parameter list of function.sdstest b/packages/ttsl-lang/tests/resources/formatting/trailing commas/type parameter list of function.sdstest index 1120f512..178c1681 100644 --- a/packages/ttsl-lang/tests/resources/formatting/trailing commas/type parameter list of function.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/trailing commas/type parameter list of function.sdstest @@ -1,5 +1,5 @@ fun f() -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- fun f() diff --git a/packages/ttsl-lang/tests/resources/formatting/types/callable types/minimal.sdstest b/packages/ttsl-lang/tests/resources/formatting/types/callable types/minimal.sdstest index cf40016d..b4fbba4a 100644 --- a/packages/ttsl-lang/tests/resources/formatting/types/callable types/minimal.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/types/callable types/minimal.sdstest @@ -2,7 +2,7 @@ segment mySegment( f: ( ) -> ( ) ) {} -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- segment mySegment( f: () -> () diff --git a/packages/ttsl-lang/tests/resources/formatting/types/literal types/empty.sdstest b/packages/ttsl-lang/tests/resources/formatting/types/literal types/empty.sdstest index 0451a59e..9cbad5f8 100644 --- a/packages/ttsl-lang/tests/resources/formatting/types/literal types/empty.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/types/literal types/empty.sdstest @@ -1,5 +1,5 @@ segment mySegment(x: literal < >) {} -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- segment mySegment(x: literal<>) {} diff --git a/packages/ttsl-lang/tests/resources/formatting/types/literal types/with literals.sdstest b/packages/ttsl-lang/tests/resources/formatting/types/literal types/with literals.sdstest index ea0e9205..c09ee669 100644 --- a/packages/ttsl-lang/tests/resources/formatting/types/literal types/with literals.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/types/literal types/with literals.sdstest @@ -2,7 +2,7 @@ segment mySegment( x: literal < 1.0 , null > ) {} -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- segment mySegment( x: literal<1.0, null> diff --git a/packages/ttsl-lang/tests/resources/formatting/types/member types/long complex chain.sdstest b/packages/ttsl-lang/tests/resources/formatting/types/member types/long complex chain.sdstest index 755bcf1d..cc6f8579 100644 --- a/packages/ttsl-lang/tests/resources/formatting/types/member types/long complex chain.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/types/member types/long complex chain.sdstest @@ -2,7 +2,7 @@ segment mySegment( x: union < > . MiddleClass < C , D > ? . InnerClass ) {} -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- segment mySegment( x: union<>.MiddleClass?.InnerClass diff --git a/packages/ttsl-lang/tests/resources/formatting/types/member types/receiver (callable) and member (not nullable).sdstest b/packages/ttsl-lang/tests/resources/formatting/types/member types/receiver (callable) and member (not nullable).sdstest index cabc8647..16a9b764 100644 --- a/packages/ttsl-lang/tests/resources/formatting/types/member types/receiver (callable) and member (not nullable).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/types/member types/receiver (callable) and member (not nullable).sdstest @@ -2,7 +2,7 @@ segment mySegment( x: ( ) -> ( ) . InnerClass ) {} -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- segment mySegment( x: () -> ().InnerClass diff --git a/packages/ttsl-lang/tests/resources/formatting/types/member types/receiver (callable) and member (nullable).sdstest b/packages/ttsl-lang/tests/resources/formatting/types/member types/receiver (callable) and member (nullable).sdstest index ee3526f1..c461ecc4 100644 --- a/packages/ttsl-lang/tests/resources/formatting/types/member types/receiver (callable) and member (nullable).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/types/member types/receiver (callable) and member (nullable).sdstest @@ -2,7 +2,7 @@ segment mySegment( x: ( ) -> ( ) . InnerClass ? ) {} -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- segment mySegment( x: () -> ().InnerClass? diff --git a/packages/ttsl-lang/tests/resources/formatting/types/member types/receiver (literal) and member (not nullable).sdstest b/packages/ttsl-lang/tests/resources/formatting/types/member types/receiver (literal) and member (not nullable).sdstest index d484c6e0..af696613 100644 --- a/packages/ttsl-lang/tests/resources/formatting/types/member types/receiver (literal) and member (not nullable).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/types/member types/receiver (literal) and member (not nullable).sdstest @@ -2,7 +2,7 @@ segment mySegment( x: literal < > . InnerClass ) {} -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- segment mySegment( x: literal<>.InnerClass diff --git a/packages/ttsl-lang/tests/resources/formatting/types/member types/receiver (literal) and member (nullable).sdstest b/packages/ttsl-lang/tests/resources/formatting/types/member types/receiver (literal) and member (nullable).sdstest index dcbe565d..d2bb4740 100644 --- a/packages/ttsl-lang/tests/resources/formatting/types/member types/receiver (literal) and member (nullable).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/types/member types/receiver (literal) and member (nullable).sdstest @@ -2,7 +2,7 @@ segment mySegment( x: literal < > . InnerClass ? ) {} -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- segment mySegment( x: literal<>.InnerClass? diff --git a/packages/ttsl-lang/tests/resources/formatting/types/member types/receiver (named, not nullable) and member (not nullable).sdstest b/packages/ttsl-lang/tests/resources/formatting/types/member types/receiver (named, not nullable) and member (not nullable).sdstest index 0533da55..322d2c10 100644 --- a/packages/ttsl-lang/tests/resources/formatting/types/member types/receiver (named, not nullable) and member (not nullable).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/types/member types/receiver (named, not nullable) and member (not nullable).sdstest @@ -2,7 +2,7 @@ segment mySegment( x: OuterClass . InnerClass ) {} -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- segment mySegment( x: OuterClass.InnerClass diff --git a/packages/ttsl-lang/tests/resources/formatting/types/member types/receiver (named, not nullable) and member (nullable).sdstest b/packages/ttsl-lang/tests/resources/formatting/types/member types/receiver (named, not nullable) and member (nullable).sdstest index c5bcfcda..2e2c9472 100644 --- a/packages/ttsl-lang/tests/resources/formatting/types/member types/receiver (named, not nullable) and member (nullable).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/types/member types/receiver (named, not nullable) and member (nullable).sdstest @@ -2,7 +2,7 @@ segment mySegment( x: OuterClass . InnerClass ? ) {} -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- segment mySegment( x: OuterClass.InnerClass? diff --git a/packages/ttsl-lang/tests/resources/formatting/types/member types/receiver (named, nullable) and member (not nullable).sdstest b/packages/ttsl-lang/tests/resources/formatting/types/member types/receiver (named, nullable) and member (not nullable).sdstest index d00fe49e..95e80aa7 100644 --- a/packages/ttsl-lang/tests/resources/formatting/types/member types/receiver (named, nullable) and member (not nullable).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/types/member types/receiver (named, nullable) and member (not nullable).sdstest @@ -2,7 +2,7 @@ segment mySegment( x: OuterClass ? . InnerClass ) {} -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- segment mySegment( x: OuterClass?.InnerClass diff --git a/packages/ttsl-lang/tests/resources/formatting/types/member types/receiver (named, nullable) and member (nullable).sdstest b/packages/ttsl-lang/tests/resources/formatting/types/member types/receiver (named, nullable) and member (nullable).sdstest index c5bcfcda..2e2c9472 100644 --- a/packages/ttsl-lang/tests/resources/formatting/types/member types/receiver (named, nullable) and member (nullable).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/types/member types/receiver (named, nullable) and member (nullable).sdstest @@ -2,7 +2,7 @@ segment mySegment( x: OuterClass . InnerClass ? ) {} -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- segment mySegment( x: OuterClass.InnerClass? diff --git a/packages/ttsl-lang/tests/resources/formatting/types/member types/receiver (union) and member (not nullable).sdstest b/packages/ttsl-lang/tests/resources/formatting/types/member types/receiver (union) and member (not nullable).sdstest index 8d71c4f5..d4ed700c 100644 --- a/packages/ttsl-lang/tests/resources/formatting/types/member types/receiver (union) and member (not nullable).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/types/member types/receiver (union) and member (not nullable).sdstest @@ -2,7 +2,7 @@ segment mySegment( x: union < > . InnerClass ) {} -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- segment mySegment( x: union<>.InnerClass diff --git a/packages/ttsl-lang/tests/resources/formatting/types/member types/receiver (union) and member (nullable).sdstest b/packages/ttsl-lang/tests/resources/formatting/types/member types/receiver (union) and member (nullable).sdstest index 9c91c4b4..1fb0f0e7 100644 --- a/packages/ttsl-lang/tests/resources/formatting/types/member types/receiver (union) and member (nullable).sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/types/member types/receiver (union) and member (nullable).sdstest @@ -2,7 +2,7 @@ segment mySegment( x: union < > . InnerClass ? ) {} -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- segment mySegment( x: union<>.InnerClass? diff --git a/packages/ttsl-lang/tests/resources/formatting/types/named types/no type arguments and not nullable.sdstest b/packages/ttsl-lang/tests/resources/formatting/types/named types/no type arguments and not nullable.sdstest index b67a6f34..a9a6c114 100644 --- a/packages/ttsl-lang/tests/resources/formatting/types/named types/no type arguments and not nullable.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/types/named types/no type arguments and not nullable.sdstest @@ -1,5 +1,5 @@ segment mySegment(x: Int) {} -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- segment mySegment(x: Int) {} diff --git a/packages/ttsl-lang/tests/resources/formatting/types/named types/no type arguments and nullable.sdstest b/packages/ttsl-lang/tests/resources/formatting/types/named types/no type arguments and nullable.sdstest index aeb31677..e8dc1f7e 100644 --- a/packages/ttsl-lang/tests/resources/formatting/types/named types/no type arguments and nullable.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/types/named types/no type arguments and nullable.sdstest @@ -1,5 +1,5 @@ segment mySegment(x: Int ?) {} -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- segment mySegment(x: Int?) {} diff --git a/packages/ttsl-lang/tests/resources/formatting/types/named types/type argument and nullable.sdstest b/packages/ttsl-lang/tests/resources/formatting/types/named types/type argument and nullable.sdstest index 531b410c..745a65f1 100644 --- a/packages/ttsl-lang/tests/resources/formatting/types/named types/type argument and nullable.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/types/named types/type argument and nullable.sdstest @@ -2,7 +2,7 @@ segment mySegment( x: Int < Number , T = Number > ? ) {} -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- segment mySegment( x: Int? diff --git a/packages/ttsl-lang/tests/resources/formatting/types/named types/type arguments and not nullable.sdstest b/packages/ttsl-lang/tests/resources/formatting/types/named types/type arguments and not nullable.sdstest index 441a1009..43ecfe33 100644 --- a/packages/ttsl-lang/tests/resources/formatting/types/named types/type arguments and not nullable.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/types/named types/type arguments and not nullable.sdstest @@ -2,7 +2,7 @@ segment mySegment( x: Int < Number , T = Number> ) {} -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- segment mySegment( x: Int diff --git a/packages/ttsl-lang/tests/resources/formatting/types/union types/empty.sdstest b/packages/ttsl-lang/tests/resources/formatting/types/union types/empty.sdstest index c8bdf7bb..bc18124c 100644 --- a/packages/ttsl-lang/tests/resources/formatting/types/union types/empty.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/types/union types/empty.sdstest @@ -1,5 +1,5 @@ segment mySegment(x: union < >) {} -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- segment mySegment(x: union<>) {} diff --git a/packages/ttsl-lang/tests/resources/formatting/types/union types/nested.sdstest b/packages/ttsl-lang/tests/resources/formatting/types/union types/nested.sdstest index 850c44b6..37402392 100644 --- a/packages/ttsl-lang/tests/resources/formatting/types/union types/nested.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/types/union types/nested.sdstest @@ -2,7 +2,7 @@ segment mySegment( x: union < union < > > ) {} -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- segment mySegment( x: union> diff --git a/packages/ttsl-lang/tests/resources/formatting/types/union types/with type arguments.sdstest b/packages/ttsl-lang/tests/resources/formatting/types/union types/with type arguments.sdstest index d9a68fa6..290668d6 100644 --- a/packages/ttsl-lang/tests/resources/formatting/types/union types/with type arguments.sdstest +++ b/packages/ttsl-lang/tests/resources/formatting/types/union types/with type arguments.sdstest @@ -2,7 +2,7 @@ segment mySegment( x: union < Int , String > ) {} -// ----------------------------------------------------------------------------- +# ----------------------------------------------------------------------------- segment mySegment( x: union diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/constant/generated/tests/generator/const/gen_input_test.py b/packages/ttsl-lang/tests/resources/generation/declarations/constant/generated/tests/generator/const/gen_input_test.py deleted file mode 100644 index 77949bf1..00000000 --- a/packages/ttsl-lang/tests/resources/generation/declarations/constant/generated/tests/generator/const/gen_input_test.py +++ /dev/null @@ -1,4 +0,0 @@ -from .gen_input import test - -if __name__ == '__main__': - print(test) diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/constant/generated/tests/generator/const/gen_input.py b/packages/ttsl-lang/tests/resources/generation/declarations/constant/generated/tests/generator/const1/gen_input.py similarity index 100% rename from packages/ttsl-lang/tests/resources/generation/declarations/constant/generated/tests/generator/const/gen_input.py rename to packages/ttsl-lang/tests/resources/generation/declarations/constant/generated/tests/generator/const1/gen_input.py diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/constant/generated/tests/generator/const/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/declarations/constant/generated/tests/generator/const1/gen_input.py.map similarity index 100% rename from packages/ttsl-lang/tests/resources/generation/declarations/constant/generated/tests/generator/const/gen_input.py.map rename to packages/ttsl-lang/tests/resources/generation/declarations/constant/generated/tests/generator/const1/gen_input.py.map diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/constant/input.ttsl b/packages/ttsl-lang/tests/resources/generation/declarations/constant/input.ttsl index 3475818d..0b90027a 100644 --- a/packages/ttsl-lang/tests/resources/generation/declarations/constant/input.ttsl +++ b/packages/ttsl-lang/tests/resources/generation/declarations/constant/input.ttsl @@ -1,3 +1,3 @@ -package tests.generator.const // kann nicht constant heißen weil sonst als keyword gelesen wird +package tests.generator.const1 # kann nicht constant heißen weil sonst als keyword gelesen wird -constant test: Int = 1 +constant test: Int = 1 \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/data/generated/tests/generator/datas/gen_input.py b/packages/ttsl-lang/tests/resources/generation/declarations/data/generated/tests/generator/datas/gen_input.py index 6a9e60f7..e69de29b 100644 --- a/packages/ttsl-lang/tests/resources/generation/declarations/data/generated/tests/generator/datas/gen_input.py +++ b/packages/ttsl-lang/tests/resources/generation/declarations/data/generated/tests/generator/datas/gen_input.py @@ -1,3 +0,0 @@ -# Data -------------------------------------------------------------------- - -test = int() \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/data/generated/tests/generator/datas/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/declarations/data/generated/tests/generator/datas/gen_input.py.map index f2c47116..09590dea 100644 --- a/packages/ttsl-lang/tests/resources/generation/declarations/data/generated/tests/generator/datas/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/declarations/data/generated/tests/generator/datas/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.ttsl"],"names":[],"mappings":"AAAA","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":[],"names":[],"mappings":"","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/data/generated/tests/generator/datas/gen_input_test.py b/packages/ttsl-lang/tests/resources/generation/declarations/data/generated/tests/generator/datas/gen_input_test.py deleted file mode 100644 index 77949bf1..00000000 --- a/packages/ttsl-lang/tests/resources/generation/declarations/data/generated/tests/generator/datas/gen_input_test.py +++ /dev/null @@ -1,4 +0,0 @@ -from .gen_input import test - -if __name__ == '__main__': - print(test) diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/empty function/generated/tests/generator/emptyFunction/gen_input_test.py b/packages/ttsl-lang/tests/resources/generation/declarations/empty function/generated/tests/generator/emptyFunction/gen_input_test.py index af29cac4..824f70b1 100644 --- a/packages/ttsl-lang/tests/resources/generation/declarations/empty function/generated/tests/generator/emptyFunction/gen_input_test.py +++ b/packages/ttsl-lang/tests/resources/generation/declarations/empty function/generated/tests/generator/emptyFunction/gen_input_test.py @@ -1,4 +1,4 @@ from .gen_input import test if __name__ == '__main__': - test(None, None, None) + test() diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/empty pipeline/generated/tests/generator/emptyPipeline/gen_input.py b/packages/ttsl-lang/tests/resources/generation/declarations/empty pipeline/generated/tests/generator/emptyPipeline/gen_input.py deleted file mode 100644 index a9018501..00000000 --- a/packages/ttsl-lang/tests/resources/generation/declarations/empty pipeline/generated/tests/generator/emptyPipeline/gen_input.py +++ /dev/null @@ -1,4 +0,0 @@ -# Pipelines -------------------------------------------------------------------- - -def test(): - pass diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/empty pipeline/generated/tests/generator/emptyPipeline/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/declarations/empty pipeline/generated/tests/generator/emptyPipeline/gen_input.py.map deleted file mode 100644 index 684798b7..00000000 --- a/packages/ttsl-lang/tests/resources/generation/declarations/empty pipeline/generated/tests/generator/emptyPipeline/gen_input.py.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"sources":["input.ttsl"],"names":["test"],"mappings":"AAAA;;AAEA,IAASA,IAAI;IAAC,IAAE","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/empty pipeline/input.sdstest b/packages/ttsl-lang/tests/resources/generation/declarations/empty pipeline/input.sdstest deleted file mode 100644 index bae28156..00000000 --- a/packages/ttsl-lang/tests/resources/generation/declarations/empty pipeline/input.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -package tests.generator.emptyPipeline - -pipeline test {} diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/empty segment/generated/tests/generator/emptySegment/gen_input.py b/packages/ttsl-lang/tests/resources/generation/declarations/empty segment/generated/tests/generator/emptySegment/gen_input.py deleted file mode 100644 index 7b01f8ac..00000000 --- a/packages/ttsl-lang/tests/resources/generation/declarations/empty segment/generated/tests/generator/emptySegment/gen_input.py +++ /dev/null @@ -1,4 +0,0 @@ -# Segments --------------------------------------------------------------------- - -def test(): - pass diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/empty segment/generated/tests/generator/emptySegment/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/declarations/empty segment/generated/tests/generator/emptySegment/gen_input.py.map deleted file mode 100644 index a0aaca09..00000000 --- a/packages/ttsl-lang/tests/resources/generation/declarations/empty segment/generated/tests/generator/emptySegment/gen_input.py.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"sources":["input.ttsl"],"names":["test"],"mappings":"AAAA;;AAEA,IAAQA,IAAI;IAAG,IAAE","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/empty segment/input.sdstest b/packages/ttsl-lang/tests/resources/generation/declarations/empty segment/input.sdstest deleted file mode 100644 index 266c388a..00000000 --- a/packages/ttsl-lang/tests/resources/generation/declarations/empty segment/input.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -package tests.generator.emptySegment - -segment test() {} diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/empty pipeline/generated/tests/generator/emptyPipeline/gen_input_test.py b/packages/ttsl-lang/tests/resources/generation/declarations/function with parameter/generated/tests/generator/functionWithParameter/gen_input_test.py similarity index 100% rename from packages/ttsl-lang/tests/resources/generation/declarations/empty pipeline/generated/tests/generator/emptyPipeline/gen_input_test.py rename to packages/ttsl-lang/tests/resources/generation/declarations/function with parameter/generated/tests/generator/functionWithParameter/gen_input_test.py diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/function with return Value/generated/tests/generator/functionWithReturnValue/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/declarations/function with return Value/generated/tests/generator/functionWithReturnValue/gen_input.py.map index 4bfc54f8..20bd68ba 100644 --- a/packages/ttsl-lang/tests/resources/generation/declarations/function with return Value/generated/tests/generator/functionWithReturnValue/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/declarations/function with return Value/generated/tests/generator/functionWithReturnValue/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.ttsl"],"names":["test"],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAEA,IAASA,IAAI;;;;;;AAIb,IAAA,+BAAkBA,IAAI","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["test"],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAEA,IAASA,IAAI;AACT;;;;;AAGJ,IAAA,+BAAkBA,IAAI","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/block lambda result/generated/tests/generator/blockLambdaResult/gen_input_test.py b/packages/ttsl-lang/tests/resources/generation/declarations/function with return Value/generated/tests/generator/functionWithReturnValue/gen_input_test.py similarity index 100% rename from packages/ttsl-lang/tests/resources/generation/expressions/block lambda result/generated/tests/generator/blockLambdaResult/gen_input_test.py rename to packages/ttsl-lang/tests/resources/generation/declarations/function with return Value/generated/tests/generator/functionWithReturnValue/gen_input_test.py diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/function with return Value/input.ttsl b/packages/ttsl-lang/tests/resources/generation/declarations/function with return Value/input.ttsl index b75d1a8a..cbb3bcb1 100644 --- a/packages/ttsl-lang/tests/resources/generation/declarations/function with return Value/input.ttsl +++ b/packages/ttsl-lang/tests/resources/generation/declarations/function with return Value/input.ttsl @@ -1,7 +1,7 @@ package tests.generator.functionWithReturnValue function test(): Int { - return 1 + return 1; } constant x: Int = test() \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/parameter with python name/generated/tests/generator/parameterWithPythonName/gen_input.py b/packages/ttsl-lang/tests/resources/generation/declarations/parameter with python name/generated/tests/generator/parameterWithPythonName/gen_input.py deleted file mode 100644 index f48810d8..00000000 --- a/packages/ttsl-lang/tests/resources/generation/declarations/parameter with python name/generated/tests/generator/parameterWithPythonName/gen_input.py +++ /dev/null @@ -1,7 +0,0 @@ -# Segments --------------------------------------------------------------------- - -def test(param1, param_2, param_3=0): - f1(lambda a, b, c=0: 1) - def __gen_block_lambda_0(a, b, c=0): - pass - f2(__gen_block_lambda_0) diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/parameter with python name/generated/tests/generator/parameterWithPythonName/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/declarations/parameter with python name/generated/tests/generator/parameterWithPythonName/gen_input.py.map deleted file mode 100644 index 33900acf..00000000 --- a/packages/ttsl-lang/tests/resources/generation/declarations/parameter with python name/generated/tests/generator/parameterWithPythonName/gen_input.py.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"sources":["input.ttsl"],"names":["test","param1","param2","param3","f1","a","b","c","f2"],"mappings":"AAAA;;AAKA,IAAQA,IAAI,CAACC,MAAM,EAA8BC,OAAM,EAA8BC,OAAM,CAAQ,CAAC;IAChGC,EAAE,CAAC,OAACC,CAAC,EAAOC,CAAC,EAAOC,CAAC,CAAQ,CAAC,EAAK,CAAC;IACjC,yBAACF,CAAC,EAAOC,CAAC,EAAOC,CAAC,CAAQ,CAAC;QAAE,IAAE;IAAlCC,EAAE,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/parameter with python name/input.sdstest b/packages/ttsl-lang/tests/resources/generation/declarations/parameter with python name/input.sdstest deleted file mode 100644 index b1687275..00000000 --- a/packages/ttsl-lang/tests/resources/generation/declarations/parameter with python name/input.sdstest +++ /dev/null @@ -1,9 +0,0 @@ -package tests.generator.parameterWithPythonName - -@Impure([ImpurityReason.Other]) fun f1(param: (a: Int, b: Int, c: Int) -> r: Int) -@Impure([ImpurityReason.Other]) fun f2(param: (a: Int, b: Int, c: Int) -> ()) - -segment test(param1: Int, @PythonName("param_2") param2: Int, @PythonName("param_3") param3: Int = 0) { - f1((a: Int, b: Int, c: Int = 0) -> 1); - f2((a: Int, b: Int, c: Int = 0) {}); -} diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/pipeline with python name/generated/tests/generator/pipelineWithPythonName/gen_input.py b/packages/ttsl-lang/tests/resources/generation/declarations/pipeline with python name/generated/tests/generator/pipelineWithPythonName/gen_input.py deleted file mode 100644 index 209629e8..00000000 --- a/packages/ttsl-lang/tests/resources/generation/declarations/pipeline with python name/generated/tests/generator/pipelineWithPythonName/gen_input.py +++ /dev/null @@ -1,4 +0,0 @@ -# Pipelines -------------------------------------------------------------------- - -def test_pipeline(): - f() diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/pipeline with python name/generated/tests/generator/pipelineWithPythonName/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/declarations/pipeline with python name/generated/tests/generator/pipelineWithPythonName/gen_input.py.map deleted file mode 100644 index 0480f3c9..00000000 --- a/packages/ttsl-lang/tests/resources/generation/declarations/pipeline with python name/generated/tests/generator/pipelineWithPythonName/gen_input.py.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"sources":["input.ttsl"],"names":["testpipeline","f"],"mappings":"AAAA;;AAKA,IAASA,aAAY;IACjBC,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/pipeline with python name/generated/tests/generator/pipelineWithPythonName/gen_input_test_pipeline.py b/packages/ttsl-lang/tests/resources/generation/declarations/pipeline with python name/generated/tests/generator/pipelineWithPythonName/gen_input_test_pipeline.py deleted file mode 100644 index e9895a77..00000000 --- a/packages/ttsl-lang/tests/resources/generation/declarations/pipeline with python name/generated/tests/generator/pipelineWithPythonName/gen_input_test_pipeline.py +++ /dev/null @@ -1,4 +0,0 @@ -from .gen_input import test_pipeline - -if __name__ == '__main__': - test_pipeline() diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/pipeline with python name/input.sdstest b/packages/ttsl-lang/tests/resources/generation/declarations/pipeline with python name/input.sdstest deleted file mode 100644 index 0b0ac9b6..00000000 --- a/packages/ttsl-lang/tests/resources/generation/declarations/pipeline with python name/input.sdstest +++ /dev/null @@ -1,8 +0,0 @@ -package tests.generator.pipelineWithPythonName - -@Impure([ImpurityReason.Other]) fun f() - -@PythonName("test_pipeline") -pipeline testPipeline { - f(); -} diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/segment with python name/generated/tests/generator/segmentWithPythonName/gen_input.py b/packages/ttsl-lang/tests/resources/generation/declarations/segment with python name/generated/tests/generator/segmentWithPythonName/gen_input.py deleted file mode 100644 index bd35ce79..00000000 --- a/packages/ttsl-lang/tests/resources/generation/declarations/segment with python name/generated/tests/generator/segmentWithPythonName/gen_input.py +++ /dev/null @@ -1,4 +0,0 @@ -# Segments --------------------------------------------------------------------- - -def test_segment(): - f() diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/segment with python name/generated/tests/generator/segmentWithPythonName/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/declarations/segment with python name/generated/tests/generator/segmentWithPythonName/gen_input.py.map deleted file mode 100644 index 54e89f45..00000000 --- a/packages/ttsl-lang/tests/resources/generation/declarations/segment with python name/generated/tests/generator/segmentWithPythonName/gen_input.py.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"sources":["input.ttsl"],"names":["testsegment","f"],"mappings":"AAAA;;AAKA,IAAQA,YAAW;IACfC,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/segment with python name/input.sdstest b/packages/ttsl-lang/tests/resources/generation/declarations/segment with python name/input.sdstest deleted file mode 100644 index 99dd0f1b..00000000 --- a/packages/ttsl-lang/tests/resources/generation/declarations/segment with python name/input.sdstest +++ /dev/null @@ -1,8 +0,0 @@ -package tests.generator.segmentWithPythonName - -@Impure([ImpurityReason.Other]) fun f() - -@PythonName("test_segment") -segment testSegment() { - f(); -} diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/two pipelines/generated/tests/generator/twoPipelines/gen_input.py b/packages/ttsl-lang/tests/resources/generation/declarations/two pipelines/generated/tests/generator/twoPipelines/gen_input.py deleted file mode 100644 index a8efe6dd..00000000 --- a/packages/ttsl-lang/tests/resources/generation/declarations/two pipelines/generated/tests/generator/twoPipelines/gen_input.py +++ /dev/null @@ -1,7 +0,0 @@ -# Pipelines -------------------------------------------------------------------- - -def test1(): - f() - -def test2(): - f() diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/two pipelines/generated/tests/generator/twoPipelines/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/declarations/two pipelines/generated/tests/generator/twoPipelines/gen_input.py.map deleted file mode 100644 index 5f3b35a8..00000000 --- a/packages/ttsl-lang/tests/resources/generation/declarations/two pipelines/generated/tests/generator/twoPipelines/gen_input.py.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"sources":["input.ttsl"],"names":["test1","f","test2"],"mappings":"AAAA;;AAIA,IAASA,KAAK;IACVC,CAAC;;AAGL,IAASC,KAAK;IACVD,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/two pipelines/generated/tests/generator/twoPipelines/gen_input_test1.py b/packages/ttsl-lang/tests/resources/generation/declarations/two pipelines/generated/tests/generator/twoPipelines/gen_input_test1.py deleted file mode 100644 index 1104e6b8..00000000 --- a/packages/ttsl-lang/tests/resources/generation/declarations/two pipelines/generated/tests/generator/twoPipelines/gen_input_test1.py +++ /dev/null @@ -1,4 +0,0 @@ -from .gen_input import test1 - -if __name__ == '__main__': - test1() diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/two pipelines/generated/tests/generator/twoPipelines/gen_input_test2.py b/packages/ttsl-lang/tests/resources/generation/declarations/two pipelines/generated/tests/generator/twoPipelines/gen_input_test2.py deleted file mode 100644 index b50d0bb8..00000000 --- a/packages/ttsl-lang/tests/resources/generation/declarations/two pipelines/generated/tests/generator/twoPipelines/gen_input_test2.py +++ /dev/null @@ -1,4 +0,0 @@ -from .gen_input import test2 - -if __name__ == '__main__': - test2() diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/two pipelines/input.sdstest b/packages/ttsl-lang/tests/resources/generation/declarations/two pipelines/input.sdstest deleted file mode 100644 index 7f254117..00000000 --- a/packages/ttsl-lang/tests/resources/generation/declarations/two pipelines/input.sdstest +++ /dev/null @@ -1,11 +0,0 @@ -package tests.generator.twoPipelines - -@Impure([ImpurityReason.Other]) fun f() - -pipeline test1 { - f(); -} - -pipeline test2 { - f(); -} diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/two segments/generated/tests/generator/twoSegments/gen_input.py b/packages/ttsl-lang/tests/resources/generation/declarations/two segments/generated/tests/generator/twoSegments/gen_input.py deleted file mode 100644 index fa5aeb3f..00000000 --- a/packages/ttsl-lang/tests/resources/generation/declarations/two segments/generated/tests/generator/twoSegments/gen_input.py +++ /dev/null @@ -1,7 +0,0 @@ -# Segments --------------------------------------------------------------------- - -def test1(a, b=0): - f() - -def test2(a, c): - f() diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/two segments/generated/tests/generator/twoSegments/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/declarations/two segments/generated/tests/generator/twoSegments/gen_input.py.map deleted file mode 100644 index 94c870fe..00000000 --- a/packages/ttsl-lang/tests/resources/generation/declarations/two segments/generated/tests/generator/twoSegments/gen_input.py.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"sources":["input.ttsl"],"names":["test1","a","b","f","test2","c"],"mappings":"AAAA;;AAIA,IAAQA,KAAK,CAACC,CAAC,EAAOC,CAAC,CAAQ,CAAC;IAC5BC,CAAC;;AAGL,IAAQC,KAAK,CAACH,CAAC,EAAOI,CAAC;IACnBF,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/two segments/input.sdstest b/packages/ttsl-lang/tests/resources/generation/declarations/two segments/input.sdstest deleted file mode 100644 index 3b61d994..00000000 --- a/packages/ttsl-lang/tests/resources/generation/declarations/two segments/input.sdstest +++ /dev/null @@ -1,11 +0,0 @@ -package tests.generator.twoSegments - -@Impure([ImpurityReason.Other]) fun f() - -segment test1(a: Int, b: Int = 0) { - f(); -} - -segment test2(a: Int, c: Int) { - f(); -} diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/generated/tests/generator/aggregation/gen_input.py b/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/generated/tests/generator/aggregation/gen_input.py index 59178a7a..a99c0ba2 100644 --- a/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/generated/tests/generator/aggregation/gen_input.py +++ b/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/generated/tests/generator/aggregation/gen_input.py @@ -19,10 +19,3 @@ def __gen_aggregation(dataFrame: pd, data, id, function: str) -> pd | None: def testFunction(timeunit = None, groupedBy = None, date = None): __gen_aggregation(dataframe, testData, testID, 'sum') - - -# Data -------------------------------------------------------------------- - -testData = int() - -testID = int() \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/generated/tests/generator/aggregation/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/generated/tests/generator/aggregation/gen_input.py.map index bdee83c8..13adf387 100644 --- a/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/generated/tests/generator/aggregation/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/generated/tests/generator/aggregation/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.ttsl"],"names":["testfunction"],"mappings":"AAAA;;AAKA,IAASA,YAAY;IAAoB","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["testfunction"],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;AAKA,IAASA,YAAY;IACjB","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/generated/tests/generator/aggregation/gen_input_test.py b/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/generated/tests/generator/aggregation/gen_input_test.py deleted file mode 100644 index af29cac4..00000000 --- a/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/generated/tests/generator/aggregation/gen_input_test.py +++ /dev/null @@ -1,4 +0,0 @@ -from .gen_input import test - -if __name__ == '__main__': - test(None, None, None) diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/generated/tests/generator/aggregation/gen_input_testFunction.py b/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/generated/tests/generator/aggregation/gen_input_testFunction.py new file mode 100644 index 00000000..a31fb68d --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/expressions/aggregation/generated/tests/generator/aggregation/gen_input_testFunction.py @@ -0,0 +1,4 @@ +from .gen_input import testFunction + +if __name__ == '__main__': + testFunction() diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/block lambda result/generated/tests/generator/blockLambdaResult/gen_input.py b/packages/ttsl-lang/tests/resources/generation/expressions/block lambda result/generated/tests/generator/blockLambdaResult/gen_input.py deleted file mode 100644 index ebd90a46..00000000 --- a/packages/ttsl-lang/tests/resources/generation/expressions/block lambda result/generated/tests/generator/blockLambdaResult/gen_input.py +++ /dev/null @@ -1,21 +0,0 @@ -# Segments --------------------------------------------------------------------- - -def f1(l): - h(l(1, 2)) - -def f2(l): - h(l(1, 2)[1]) - h(l(1, 2)[0]) - -# Pipelines -------------------------------------------------------------------- - -def test(): - def __gen_block_lambda_0(a, b): - __gen_block_lambda_result_d = g() - return __gen_block_lambda_result_d - f1(__gen_block_lambda_0) - def __gen_block_lambda_1(a, b): - __gen_block_lambda_result_d = g() - __gen_block_lambda_result_e = g() - return __gen_block_lambda_result_d, __gen_block_lambda_result_e - f2(__gen_block_lambda_1) diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/block lambda result/generated/tests/generator/blockLambdaResult/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/expressions/block lambda result/generated/tests/generator/blockLambdaResult/gen_input.py.map deleted file mode 100644 index 3ebd268f..00000000 --- a/packages/ttsl-lang/tests/resources/generation/expressions/block lambda result/generated/tests/generator/blockLambdaResult/gen_input.py.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"sources":["input.ttsl"],"names":["f1","l","h","f2","e1","d1","test","a","b","d","g","e"],"mappings":"AAAA;;AAMA,IAAQA,EAAE,CAACC,CAAC;IACRC,CAAC,CAACD,CAAC,CAAC,CAAC,EAAE,CAAC;;AAGZ,IAAQE,EAAE,CAACF,CAAC;IACRC,CAAC,CAACD,CAAC,CAAC,CAAC,EAAE,CAAC,EAAEG,CAAE;IACZF,CAAC,CAACD,CAAC,CAAC,CAAC,EAAE,CAAC,EAAEI,CAAE;;;;AAGhB,IAASC,IAAI;IAEN,yBAACC,CAAC,EAAOC,CAAC;QACT,0BAAMC,CAAC,GAAGC,CAAC;QADZ,OACC,0BAAMD,CAAC;IADXT,EAAE,CAAC;IAGA,yBAACO,CAAC,EAAOC,CAAC;QACT,0BAAMC,CAAC,GAAGC,CAAC;QACX,0BAAMC,CAAC,GAAGD,CAAC;QAFZ,OACC,0BAAMD,CAAC,EACP,0BAAME,CAAC;IAFXR,EAAE,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/block lambda result/input.sdstest b/packages/ttsl-lang/tests/resources/generation/expressions/block lambda result/input.sdstest deleted file mode 100644 index 3cd1ae3b..00000000 --- a/packages/ttsl-lang/tests/resources/generation/expressions/block lambda result/input.sdstest +++ /dev/null @@ -1,26 +0,0 @@ -package tests.generator.blockLambdaResult - -@Pure fun g() -> a: Int - -@Impure([ImpurityReason.Other]) fun h(a: Int) - -segment f1(l: (a: Int, b: Int) -> d: Int) { - h(l(1, 2).d); -} - -segment f2(l: (a: Int, b: Int) -> (d1: Int, e1: Int)) { - h(l(1, 2).e1); - h(l(1, 2).d1); -} - -pipeline test { - - f1((a: Int, b: Int) { - yield d = g(); - }); - f2((a: Int, b: Int) { - yield d = g(); - yield e = g(); - }); - -} diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/block lambda/generated/tests/generator/blockLambda/gen_input.py b/packages/ttsl-lang/tests/resources/generation/expressions/block lambda/generated/tests/generator/blockLambda/gen_input.py deleted file mode 100644 index 9036f3ce..00000000 --- a/packages/ttsl-lang/tests/resources/generation/expressions/block lambda/generated/tests/generator/blockLambda/gen_input.py +++ /dev/null @@ -1,23 +0,0 @@ -# Pipelines -------------------------------------------------------------------- - -def test(): - def __gen_block_lambda_0(a, b=2): - __gen_block_lambda_result_d = g() - return __gen_block_lambda_result_d - f1(__gen_block_lambda_0) - def __gen_block_lambda_1(a, b): - __gen_block_lambda_result_d = g() - return __gen_block_lambda_result_d - f1(__gen_block_lambda_1) - def __gen_block_lambda_2(): - pass - f2(__gen_block_lambda_2) - def __gen_block_lambda_3(a, b=2): - __gen_block_lambda_result_d = g() - return __gen_block_lambda_result_d - g2(f3(__gen_block_lambda_3)) - def __gen_block_lambda_4(a, b=2): - __gen_block_lambda_result_d = g() - return __gen_block_lambda_result_d - c = f3(__gen_block_lambda_4) - g2(c) diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/block lambda/generated/tests/generator/blockLambda/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/expressions/block lambda/generated/tests/generator/blockLambda/gen_input.py.map deleted file mode 100644 index 1e279783..00000000 --- a/packages/ttsl-lang/tests/resources/generation/expressions/block lambda/generated/tests/generator/blockLambda/gen_input.py.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"sources":["input.ttsl"],"names":["test","a","b","d","g","f1","f2","g2","f3","c"],"mappings":"AAAA;;AASA,IAASA,IAAI;IACN,yBAACC,CAAC,EAAOC,CAAC,CAAQ,CAAC;QAClB,0BAAMC,CAAC,GAAGC,CAAC;QADZ,OACC,0BAAMD,CAAC;IADXE,EAAE,CAAC;IAGA,yBAACJ,CAAC,EAAOC,CAAC;QACT,0BAAMC,CAAC,GAAGC,CAAC;QADZ,OACC,0BAAMD,CAAC;IADXE,EAAE,CAAC;IAGA;QAAG,IAAE;IAARC,EAAE,CAAC;IACG,yBAACL,CAAC,EAAOC,CAAC,CAAQ,CAAC;QACrB,0BAAMC,CAAC,GAAGC,CAAC;QADT,OACF,0BAAMD,CAAC;IADXI,EAAE,CAACC,EAAE,CAAC;IAGK,yBAACP,CAAC,EAAOC,CAAC,CAAQ,CAAC;QAC1B,0BAAMC,CAAC,GAAGC,CAAC;QADJ,OACP,0BAAMD,CAAC;IADX,IAAQK,EAAE,CAAC;IAGXD,EAAE,CAACE,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/block lambda/input.sdstest b/packages/ttsl-lang/tests/resources/generation/expressions/block lambda/input.sdstest deleted file mode 100644 index 409e78c8..00000000 --- a/packages/ttsl-lang/tests/resources/generation/expressions/block lambda/input.sdstest +++ /dev/null @@ -1,25 +0,0 @@ -package tests.generator.blockLambda - -@Impure([ImpurityReason.Other]) fun f1(param: (a: Int, b: Int) -> r: Int) -@Impure([ImpurityReason.Other]) fun f2(param: () -> ()) -@Pure fun f3(param: (a: Int, b: Int) -> r: Int) -> a: Int - -@Pure fun g() -> a: Int -@Impure([ImpurityReason.Other]) fun g2(param: Int) - -pipeline test { - f1((a: Int, b: Int = 2) { - yield d = g(); - }); - f1((a: Int, b: Int) { - yield d = g(); - }); - f2(() {}); - g2(f3((a: Int, b: Int = 2) { - yield d = g(); - })); - val c = f3((a: Int, b: Int = 2) { - yield d = g(); - }); - g2(c); -} diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/call/generated/tests/generator/call/gen_input.py b/packages/ttsl-lang/tests/resources/generation/expressions/call/generated/tests/generator/call/gen_input.py index a1a0b2bd..9d09ecf3 100644 --- a/packages/ttsl-lang/tests/resources/generation/expressions/call/generated/tests/generator/call/gen_input.py +++ b/packages/ttsl-lang/tests/resources/generation/expressions/call/generated/tests/generator/call/gen_input.py @@ -11,22 +11,31 @@ def __gen_null_safe_call(receiver: Any, callable: Callable[[], __gen_T]) -> __gen_T | None: return callable() if receiver is not None else None -# Pipelines -------------------------------------------------------------------- +# Functions -------------------------------------------------------------------- + +def f(param): + pass + +def g(param1, param2=0): + pass + +def h(param1, param2=0): + pass + +def i(param): + pass def test(): f(g(1, param2=2)) f(g(2, param2=1)) - f(h(1, param_2=2)) - f(h(2, param_2=1)) + f(h(1, param2=2)) + f(h(2, param2=1)) f(h(2)) - 'abc'.i() - 'abc'.j(123) - k(456, 1.23) + i("abc") __gen_null_safe_call(f, lambda: f(g(1, param2=2))) __gen_null_safe_call(f, lambda: f(g(2, param2=1))) - __gen_null_safe_call(f, lambda: f(h(1, param_2=2))) - __gen_null_safe_call(f, lambda: f(h(2, param_2=1))) + __gen_null_safe_call(f, lambda: f(h(1, param2=2))) + __gen_null_safe_call(f, lambda: f(h(2, param2=1))) __gen_null_safe_call(f, lambda: f(h(2))) - __gen_null_safe_call(i, lambda: 'abc'.i()) - __gen_null_safe_call(j, lambda: 'abc'.j(123)) - __gen_null_safe_call(k, lambda: k(456, 1.23)) + __gen_null_safe_call(i, lambda: i("abc")) + diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/call/generated/tests/generator/call/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/expressions/call/generated/tests/generator/call/gen_input.py.map index 05070f44..5faae5ef 100644 --- a/packages/ttsl-lang/tests/resources/generation/expressions/call/generated/tests/generator/call/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/expressions/call/generated/tests/generator/call/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.ttsl"],"names":["test","f","g","param2","h","i","j","k"],"mappings":"AAAA;;;;;;;;;;;;;;;AA0BA,IAASA,IAAI;IACTC,CAAC,CAAEC,CAAC,CAAC,CAAC,EArBNC,MAAM,CAqBE,CAAC;IACTF,CAAC,CAAEC,CAAC,CAAsB,CAAC,EAtB3BC,MAAM,CAsBQ,CAAC;IACfF,CAAC,CAAEG,CAAC,CAAC,CAAC,EAlBiBD,OAAM,CAkBrB,CAAC;IACTF,CAAC,CAAEG,CAAC,CAAsB,CAAC,EAnBJD,OAAM,CAmBf,CAAC;IACfF,CAAC,CAAEG,CAAC,CAAU,CAAC;IACb,KAAK;IACL,KAAK,GAAE,GAAG;IACZ,EAAQ,GAAG,EAAT,IAAI;IAEL,oBAAC,CAAFH,CAAC,UAADA,CAAC,CAAGC,CAAC,CAAC,CAAC,EA9BPC,MAAM,CA8BG,CAAC;IACT,oBAAC,CAAFF,CAAC,UAADA,CAAC,CAAGC,CAAC,CAAsB,CAAC,EA/B5BC,MAAM,CA+BS,CAAC;IACf,oBAAC,CAAFF,CAAC,UAADA,CAAC,CAAGG,CAAC,CAAC,CAAC,EA3BgBD,OAAM,CA2BpB,CAAC;IACT,oBAAC,CAAFF,CAAC,UAADA,CAAC,CAAGG,CAAC,CAAsB,CAAC,EA5BLD,OAAM,CA4Bd,CAAC;IACf,oBAAC,CAAFF,CAAC,UAADA,CAAC,CAAGG,CAAC,CAAU,CAAC;IACf,oBAAC,CAAFC,CAAC,UAAE,KAAK;IACP,oBAAC,CAAFC,CAAC,UAAE,KAAK,GAAE,GAAG;IACZ,oBAAC,CAAFC,CAAC,UAAD,EAAS,GAAG,EAAT,IAAI","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["f","param","g","param1","param2","h","i","test"],"mappings":"AAAA;;;;;;;;;;;;;;;AAEA,IAASA,CAAC,CAACC,KAAK;IAAW,IAAE;;AAE7B,IAASC,CAAC,CACNC,MAAM,EACNC,MAAM,CAAQ,CAAC;IACR,IAAE;;AAEb,IAASC,CAAC,CAACF,MAAM,EAAOC,MAAM,CAAQ,CAAC;IAC5B,IAAE;;AAEb,IAASE,CAAC,CAACL,KAAK;IAAW,IAAE;;AAE7B,IAASM,IAAI;IACTP,CAAC,CAAEE,CAAC,CAAC,CAAC,EATNE,MAAM,CASE,CAAC;IACTJ,CAAC,CAAEE,CAAC,CAAsB,CAAC,EAV3BE,MAAM,CAUQ,CAAC;IACfJ,CAAC,CAAEK,CAAC,CAAC,CAAC,EARcD,MAAM,CAQlB,CAAC;IACTJ,CAAC,CAAEK,CAAC,CAAsB,CAAC,EATPD,MAAM,CASZ,CAAC;IACfJ,CAAC,CAAEK,CAAC,CAAU,CAAC;IACfC,CAAC,CAAC,KAAK;IAEN,oBAAC,CAAFN,CAAC,UAADA,CAAC,CAAGE,CAAC,CAAC,CAAC,EAhBPE,MAAM,CAgBG,CAAC;IACT,oBAAC,CAAFJ,CAAC,UAADA,CAAC,CAAGE,CAAC,CAAsB,CAAC,EAjB5BE,MAAM,CAiBS,CAAC;IACf,oBAAC,CAAFJ,CAAC,UAADA,CAAC,CAAGK,CAAC,CAAC,CAAC,EAfaD,MAAM,CAejB,CAAC;IACT,oBAAC,CAAFJ,CAAC,UAADA,CAAC,CAAGK,CAAC,CAAsB,CAAC,EAhBRD,MAAM,CAgBX,CAAC;IACf,oBAAC,CAAFJ,CAAC,UAADA,CAAC,CAAGK,CAAC,CAAU,CAAC;IACf,oBAAC,CAAFC,CAAC,UAADA,CAAC,CAAE,KAAK","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/call/generated/tests/generator/call/gen_input_f.py b/packages/ttsl-lang/tests/resources/generation/expressions/call/generated/tests/generator/call/gen_input_f.py new file mode 100644 index 00000000..3c6273bd --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/expressions/call/generated/tests/generator/call/gen_input_f.py @@ -0,0 +1,4 @@ +from .gen_input import f + +if __name__ == '__main__': + f() diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/call/generated/tests/generator/call/gen_input_g.py b/packages/ttsl-lang/tests/resources/generation/expressions/call/generated/tests/generator/call/gen_input_g.py new file mode 100644 index 00000000..0e7a09fa --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/expressions/call/generated/tests/generator/call/gen_input_g.py @@ -0,0 +1,4 @@ +from .gen_input import g + +if __name__ == '__main__': + g() diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/call/generated/tests/generator/call/gen_input_h.py b/packages/ttsl-lang/tests/resources/generation/expressions/call/generated/tests/generator/call/gen_input_h.py new file mode 100644 index 00000000..7b31e42d --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/expressions/call/generated/tests/generator/call/gen_input_h.py @@ -0,0 +1,4 @@ +from .gen_input import h + +if __name__ == '__main__': + h() diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/call/generated/tests/generator/call/gen_input_i.py b/packages/ttsl-lang/tests/resources/generation/expressions/call/generated/tests/generator/call/gen_input_i.py new file mode 100644 index 00000000..a52c25bd --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/expressions/call/generated/tests/generator/call/gen_input_i.py @@ -0,0 +1,4 @@ +from .gen_input import i + +if __name__ == '__main__': + i() diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/call/input.sdstest b/packages/ttsl-lang/tests/resources/generation/expressions/call/input.sdstest deleted file mode 100644 index 8d61c895..00000000 --- a/packages/ttsl-lang/tests/resources/generation/expressions/call/input.sdstest +++ /dev/null @@ -1,45 +0,0 @@ -package tests.generator.call - -@Impure([ImpurityReason.Other]) fun f(param: Any?) - -@Pure fun g( - param1: Int, - param2: Int = 0 -) -> result: Boolean - -@Pure fun h( - @PythonName("param_1") param1: Int, - @PythonName("param_2") param2: Int = 0 -) -> result: Boolean - -@Impure([ImpurityReason.Other]) -@PythonCall("$param.i()") -fun i(param: Any?) - -@Impure([ImpurityReason.Other]) -@PythonCall("$param.j($param2)") -fun j(param: Any?, param2: Any?) - -@Impure([ImpurityReason.Other]) -@PythonCall("k($param2, $param)") -fun k(param: Any?, param2: Any?) - -pipeline test { - f((g(1, 2))); - f((g(param2 = 1, param1 = 2))); - f((h(1, 2))); - f((h(param2 = 1, param1 = 2))); - f((h(param1 = 2))); - i("abc"); - j("abc", 123); - k(1.23, 456); - - f?((g(1, 2))); - f?((g(param2 = 1, param1 = 2))); - f?((h(1, 2))); - f?((h(param2 = 1, param1 = 2))); - f?((h(param1 = 2))); - i?("abc"); - j?("abc", 123); - k?(1.23, 456); -} diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/call/input.ttsl b/packages/ttsl-lang/tests/resources/generation/expressions/call/input.ttsl new file mode 100644 index 00000000..a33bca5e --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/expressions/call/input.ttsl @@ -0,0 +1,29 @@ +package tests.generator.call + +function f(param: Boolean?){} + +function g( + param1: Int, + param2: Int = 0 +): Boolean {} + +function h(param1: Int, param2: Int = 0 +): Boolean {} + +function i(param: String?) {} + +function test () { + f((g(1, 2))); + f((g(param2 = 1, param1 = 2))); + f((h(1, 2))); + f((h(param2 = 1, param1 = 2))); + f((h(param1 = 2))); + i("abc"); + + f?((g(1, 2))); + f?((g(param2 = 1, param1 = 2))); + f?((h(1, 2))); + f?((h(param2 = 1, param1 = 2))); + f?((h(param1 = 2))); + i?("abc"); +} diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/constant/generated/tests/generator/const/gen_input.py b/packages/ttsl-lang/tests/resources/generation/expressions/constant/generated/tests/generator/const/gen_input.py new file mode 100644 index 00000000..261f4bf4 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/expressions/constant/generated/tests/generator/const/gen_input.py @@ -0,0 +1,11 @@ +# Functions -------------------------------------------------------------------- + +def f(param): + pass + +def test(): + f((1) < (2)) + f((1) - (1)) + f((1) + (1)) + f(None) + diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/constant/generated/tests/generator/const/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/expressions/constant/generated/tests/generator/const/gen_input.py.map new file mode 100644 index 00000000..e21842ee --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/expressions/constant/generated/tests/generator/const/gen_input.py.map @@ -0,0 +1 @@ +{"version":3,"sources":["input.ttsl"],"names":["f","param","test","null"],"mappings":"AAAA;;AAEA,IAASA,CAAC,CAACC,KAAK;IAAO,IAAE;;AAEzB,IAASC,IAAI;IACTF,CAAC,CAAC,CAAA,CAAC,EAAC,CAAC,EAAC,CAAC;IACPA,CAAC,CAAC,CAAA,CAAG,EAAC,CAAC,EAAC,CAAG;IACXA,CAAC,CAAC,CAAA,CAAC,EAAC,CAAC,EAAC,CAAC;IACPA,CAAC,CAACG,IAAI","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/constant/generated/tests/generator/const/gen_input_f.py b/packages/ttsl-lang/tests/resources/generation/expressions/constant/generated/tests/generator/const/gen_input_f.py new file mode 100644 index 00000000..3c6273bd --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/expressions/constant/generated/tests/generator/const/gen_input_f.py @@ -0,0 +1,4 @@ +from .gen_input import f + +if __name__ == '__main__': + f() diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/block lambda/generated/tests/generator/blockLambda/gen_input_test.py b/packages/ttsl-lang/tests/resources/generation/expressions/constant/generated/tests/generator/const/gen_input_test.py similarity index 100% rename from packages/ttsl-lang/tests/resources/generation/expressions/block lambda/generated/tests/generator/blockLambda/gen_input_test.py rename to packages/ttsl-lang/tests/resources/generation/expressions/constant/generated/tests/generator/const/gen_input_test.py diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/constant/generated/tests/generator/constant/gen_input.py b/packages/ttsl-lang/tests/resources/generation/expressions/constant/generated/tests/generator/constant/gen_input.py deleted file mode 100644 index 6f2601b0..00000000 --- a/packages/ttsl-lang/tests/resources/generation/expressions/constant/generated/tests/generator/constant/gen_input.py +++ /dev/null @@ -1,8 +0,0 @@ -# Pipelines -------------------------------------------------------------------- - -def test(): - f(True) - f(0.0) - f(2) - f(None) - f('person: me') diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/constant/generated/tests/generator/constant/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/expressions/constant/generated/tests/generator/constant/gen_input.py.map deleted file mode 100644 index 84416565..00000000 --- a/packages/ttsl-lang/tests/resources/generation/expressions/constant/generated/tests/generator/constant/gen_input.py.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"sources":["input.ttsl"],"names":["test","f","null"],"mappings":"AAAA;;AAIA,IAASA,IAAI;IACTC,CAAC,CAAC;IACFA,CAAC,CAAC;IACFA,CAAC,CAAC;IACFA,CAAC,CAACC,IAAI;IACND,CAAC,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/constant/input.sdstest b/packages/ttsl-lang/tests/resources/generation/expressions/constant/input.sdstest deleted file mode 100644 index 14c63600..00000000 --- a/packages/ttsl-lang/tests/resources/generation/expressions/constant/input.sdstest +++ /dev/null @@ -1,11 +0,0 @@ -package tests.generator.constant - -@Impure([ImpurityReason.Other]) fun f(param: Any?) - -pipeline test { - f(1 < 2); - f(1.0 - 1.0); - f(1 + 1); - f(null); - f("person: {{ "me" }}"); -} diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/constant/input.ttsl b/packages/ttsl-lang/tests/resources/generation/expressions/constant/input.ttsl new file mode 100644 index 00000000..5b5ba8ba --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/expressions/constant/input.ttsl @@ -0,0 +1,10 @@ +package tests.generator.const + +function f(param: Any?){} + +function test () { + f(1 < 2); + f(1.0 - 1.0); + f(1 + 1); + f(null); +} diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/enum variant call/generated/tests/generator/enumVariantCall/gen_input.py b/packages/ttsl-lang/tests/resources/generation/expressions/enum variant call/generated/tests/generator/enumVariantCall/gen_input.py deleted file mode 100644 index 60d9dfc4..00000000 --- a/packages/ttsl-lang/tests/resources/generation/expressions/enum variant call/generated/tests/generator/enumVariantCall/gen_input.py +++ /dev/null @@ -1,9 +0,0 @@ -# Pipelines -------------------------------------------------------------------- - -def test(): - f(MyEnum.Variant1()) - f(MyEnum.Variant1()) - f(MyEnum.Variant1()) - f(MyEnum.Variant1()) - f(MyEnum.Variant2(1)) - f(MyEnum.Variant2(1)) diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/enum variant call/generated/tests/generator/enumVariantCall/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/expressions/enum variant call/generated/tests/generator/enumVariantCall/gen_input.py.map deleted file mode 100644 index 6ce0b8a5..00000000 --- a/packages/ttsl-lang/tests/resources/generation/expressions/enum variant call/generated/tests/generator/enumVariantCall/gen_input.py.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"sources":["input.ttsl"],"names":["test","f","myenum","variant1","variant2"],"mappings":"AAAA;;AASA,IAASA,IAAI;IACVC,CAAC,CAACC,MAAM,CAACC,QAAQ;IACjBF,CAAC,CAACC,MAAM,CAAEC,QAAQ;IAClBF,CAAC,CAACC,MAAM,CAACC,QAAQ;IACjBF,CAAC,CAACC,MAAM,CAAEC,QAAQ;IAClBF,CAAC,CAACC,MAAM,CAACE,QAAQ,CAAC,CAAC;IACnBH,CAAC,CAACC,MAAM,CAAEE,QAAQ,CAAC,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/enum variant call/input.sdstest b/packages/ttsl-lang/tests/resources/generation/expressions/enum variant call/input.sdstest deleted file mode 100644 index b7c8a359..00000000 --- a/packages/ttsl-lang/tests/resources/generation/expressions/enum variant call/input.sdstest +++ /dev/null @@ -1,17 +0,0 @@ -package tests.generator.enumVariantCall - -@Impure([ImpurityReason.Other]) fun f(p: Any) - -enum MyEnum { - Variant1 - Variant2(counter: Int) -} - -pipeline test { - f(MyEnum.Variant1); - f(MyEnum?.Variant1); - f(MyEnum.Variant1()); - f(MyEnum?.Variant1()); - f(MyEnum.Variant2(1)); - f(MyEnum?.Variant2(1)); -} diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/expression lambda/generated/tests/generator/expressionLambda/gen_input.py b/packages/ttsl-lang/tests/resources/generation/expressions/expression lambda/generated/tests/generator/expressionLambda/gen_input.py deleted file mode 100644 index ad30c61c..00000000 --- a/packages/ttsl-lang/tests/resources/generation/expressions/expression lambda/generated/tests/generator/expressionLambda/gen_input.py +++ /dev/null @@ -1,5 +0,0 @@ -# Pipelines -------------------------------------------------------------------- - -def test(): - f(lambda a, b=2: 1) - f(lambda a, b: 1) diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/expression lambda/generated/tests/generator/expressionLambda/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/expressions/expression lambda/generated/tests/generator/expressionLambda/gen_input.py.map deleted file mode 100644 index 3131f969..00000000 --- a/packages/ttsl-lang/tests/resources/generation/expressions/expression lambda/generated/tests/generator/expressionLambda/gen_input.py.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"sources":["input.ttsl"],"names":["test","f","a","b"],"mappings":"AAAA;;AAIA,IAASA,IAAI;IACTC,CAAC,CAAC,OAACC,CAAC,EAAEC,CAAC,CAAG,CAAC,EAAK,CAAC;IACjBF,CAAC,CAAC,OAACC,CAAC,EAAEC,CAAC,EAAK,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/expression lambda/generated/tests/generator/expressionLambda/gen_input_test.py b/packages/ttsl-lang/tests/resources/generation/expressions/expression lambda/generated/tests/generator/expressionLambda/gen_input_test.py deleted file mode 100644 index 824f70b1..00000000 --- a/packages/ttsl-lang/tests/resources/generation/expressions/expression lambda/generated/tests/generator/expressionLambda/gen_input_test.py +++ /dev/null @@ -1,4 +0,0 @@ -from .gen_input import test - -if __name__ == '__main__': - test() diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/expression lambda/input.sdstest b/packages/ttsl-lang/tests/resources/generation/expressions/expression lambda/input.sdstest deleted file mode 100644 index 9991d59a..00000000 --- a/packages/ttsl-lang/tests/resources/generation/expressions/expression lambda/input.sdstest +++ /dev/null @@ -1,8 +0,0 @@ -package tests.generator.expressionLambda - -@Impure([ImpurityReason.Other]) fun f(param: (a: Int, b: Int) -> r: Int) - -pipeline test { - f((a, b = 2) -> 1); - f((a, b) -> 1); -} diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/indexed access/generated/tests/generator/indexedAccess/gen_input.py b/packages/ttsl-lang/tests/resources/generation/expressions/indexed access/generated/tests/generator/indexedAccess/gen_input.py deleted file mode 100644 index 5f45abe2..00000000 --- a/packages/ttsl-lang/tests/resources/generation/expressions/indexed access/generated/tests/generator/indexedAccess/gen_input.py +++ /dev/null @@ -1,18 +0,0 @@ -# Imports ---------------------------------------------------------------------- - -from typing import Any, TypeVar - -# Type variables --------------------------------------------------------------- - -__gen_T = TypeVar("__gen_T") - -# Utils ------------------------------------------------------------------------ - -def __gen_null_safe_indexed_access(receiver: Any, index: Any) -> __gen_T | None: - return receiver[index] if receiver is not None else None - -# Segments --------------------------------------------------------------------- - -def test(param1, param2): - f(param1[0]) - f(__gen_null_safe_indexed_access(param2, 0)) diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/indexed access/generated/tests/generator/indexedAccess/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/expressions/indexed access/generated/tests/generator/indexedAccess/gen_input.py.map deleted file mode 100644 index b7ef7248..00000000 --- a/packages/ttsl-lang/tests/resources/generation/expressions/indexed access/generated/tests/generator/indexedAccess/gen_input.py.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"sources":["input.ttsl"],"names":["test","param1","param2","f"],"mappings":"AAAA;;;;;;;;;;;;;;;AAIA,IAAQA,IAAI,CAACC,MAAM,EAAaC,MAAM;IAClCC,CAAC,CAACF,MAAM,CAAC,CAAC;IACVE,CAAC,CAAO,8BAAC,CAAPD,MAAM,EAAE,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/indexed access/input.sdstest b/packages/ttsl-lang/tests/resources/generation/expressions/indexed access/input.sdstest deleted file mode 100644 index b4ea97aa..00000000 --- a/packages/ttsl-lang/tests/resources/generation/expressions/indexed access/input.sdstest +++ /dev/null @@ -1,8 +0,0 @@ -package tests.generator.indexedAccess - -@Impure([ImpurityReason.Other]) fun f(param: Any?) - -segment test(param1: List, param2: List?) { - f(param1[0]); - f(param2?[0]); -} diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/indexed access/input.ttsl b/packages/ttsl-lang/tests/resources/generation/expressions/indexed access/input.ttsl new file mode 100644 index 00000000..24528c73 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/expressions/indexed access/input.ttsl @@ -0,0 +1,6 @@ +package tests.generator.indexedAccess + +function test(param1: List, param2: List?) { + var x = param1[0]; + var y = param2?[0]; +} diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/infix operation/generated/tests/generator/infixOperation/gen_input.py b/packages/ttsl-lang/tests/resources/generation/expressions/infix operation/generated/tests/generator/infixOperation/gen_input.py index fab49649..c13302ef 100644 --- a/packages/ttsl-lang/tests/resources/generation/expressions/infix operation/generated/tests/generator/infixOperation/gen_input.py +++ b/packages/ttsl-lang/tests/resources/generation/expressions/infix operation/generated/tests/generator/infixOperation/gen_input.py @@ -17,7 +17,19 @@ def __gen_eager_and(left_operand: bool, right_operand: bool) -> bool: def __gen_eager_elvis(left_operand: __gen_T, right_operand: __gen_T) -> __gen_T: return left_operand if left_operand is not None else right_operand -# Pipelines -------------------------------------------------------------------- +# Functions -------------------------------------------------------------------- + +def f(param): + pass + +def g(): + pass + +def h(): + pass + +def i(): + pass def test(): f(__gen_eager_or(g(), g())) @@ -35,3 +47,4 @@ def test(): f((h()) * (h())) f((h()) / (h())) f(__gen_eager_elvis(i(), i())) + diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/infix operation/generated/tests/generator/infixOperation/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/expressions/infix operation/generated/tests/generator/infixOperation/gen_input.py.map index 7910ca30..731200ff 100644 --- a/packages/ttsl-lang/tests/resources/generation/expressions/infix operation/generated/tests/generator/infixOperation/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/expressions/infix operation/generated/tests/generator/infixOperation/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.ttsl"],"names":["test","f","or","g","and","h","i"],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;AAUA,IAASA,IAAI;IACTC,CAAC,CAAKC,cAAE,CAANC,CAAC,IAAMA,CAAC;IACVF,CAAC,CAAKG,eAAG,CAAPD,CAAC,IAAOA,CAAC;IAEXF,CAAC,CAAC,CAAAI,CAAC,IAAG,EAAE,EAACA,CAAC;IACVJ,CAAC,CAAC,CAAAI,CAAC,IAAG,EAAE,EAACA,CAAC;IACVJ,CAAC,CAAC,CAAAI,CAAC,IAAG,EAAG,EAACA,CAAC;IACXJ,CAAC,CAAC,CAAAI,CAAC,IAAG,QAAIA,CAAC;IAEXJ,CAAC,CAAC,CAAAI,CAAC,IAAG,CAAC,EAACA,CAAC;IACTJ,CAAC,CAAC,CAAAI,CAAC,IAAG,EAAE,EAACA,CAAC;IACVJ,CAAC,CAAC,CAAAI,CAAC,IAAG,EAAE,EAACA,CAAC;IACVJ,CAAC,CAAC,CAAAI,CAAC,IAAG,CAAC,EAACA,CAAC;IAETJ,CAAC,CAAC,CAAAI,CAAC,IAAG,CAAC,EAACA,CAAC;IACTJ,CAAC,CAAC,CAAAI,CAAC,IAAG,CAAC,EAACA,CAAC;IACTJ,CAAC,CAAC,CAAAI,CAAC,IAAG,CAAC,EAACA,CAAC;IACTJ,CAAC,CAAC,CAAAI,CAAC,IAAG,CAAC,EAACA,CAAC;IAETJ,CAAC,CAAK,iBAAE,CAANK,CAAC,IAAMA,CAAC","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["f","param","g","h","i","test","or","and"],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;AAEA,IAASA,CAAC,CAACC,KAAK;IAAO,IAAE;;AAEzB,IAASC,CAAC;IAAW,IAAE;;AAEvB,IAASC,CAAC;IAAO,IAAE;;AAEnB,IAASC,CAAC;IAAQ,IAAE;;AAEpB,IAASC,IAAI;IACTL,CAAC,CAAKM,cAAE,CAANJ,CAAC,IAAMA,CAAC;IACVF,CAAC,CAAKO,eAAG,CAAPL,CAAC,IAAOA,CAAC;IAEXF,CAAC,CAAC,CAAAG,CAAC,IAAG,EAAE,EAACA,CAAC;IACVH,CAAC,CAAC,CAAAG,CAAC,IAAG,EAAE,EAACA,CAAC;IACVH,CAAC,CAAC,CAAAG,CAAC,IAAG,EAAG,EAACA,CAAC;IACXH,CAAC,CAAC,CAAAG,CAAC,IAAG,QAAIA,CAAC;IAEXH,CAAC,CAAC,CAAAG,CAAC,IAAG,CAAC,EAACA,CAAC;IACTH,CAAC,CAAC,CAAAG,CAAC,IAAG,EAAE,EAACA,CAAC;IACVH,CAAC,CAAC,CAAAG,CAAC,IAAG,EAAE,EAACA,CAAC;IACVH,CAAC,CAAC,CAAAG,CAAC,IAAG,CAAC,EAACA,CAAC;IAETH,CAAC,CAAC,CAAAG,CAAC,IAAG,CAAC,EAACA,CAAC;IACTH,CAAC,CAAC,CAAAG,CAAC,IAAG,CAAC,EAACA,CAAC;IACTH,CAAC,CAAC,CAAAG,CAAC,IAAG,CAAC,EAACA,CAAC;IACTH,CAAC,CAAC,CAAAG,CAAC,IAAG,CAAC,EAACA,CAAC;IAETH,CAAC,CAAK,iBAAE,CAANI,CAAC,IAAMA,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/infix operation/generated/tests/generator/infixOperation/gen_input_f.py b/packages/ttsl-lang/tests/resources/generation/expressions/infix operation/generated/tests/generator/infixOperation/gen_input_f.py new file mode 100644 index 00000000..3c6273bd --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/expressions/infix operation/generated/tests/generator/infixOperation/gen_input_f.py @@ -0,0 +1,4 @@ +from .gen_input import f + +if __name__ == '__main__': + f() diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/infix operation/generated/tests/generator/infixOperation/gen_input_g.py b/packages/ttsl-lang/tests/resources/generation/expressions/infix operation/generated/tests/generator/infixOperation/gen_input_g.py new file mode 100644 index 00000000..0e7a09fa --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/expressions/infix operation/generated/tests/generator/infixOperation/gen_input_g.py @@ -0,0 +1,4 @@ +from .gen_input import g + +if __name__ == '__main__': + g() diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/infix operation/generated/tests/generator/infixOperation/gen_input_h.py b/packages/ttsl-lang/tests/resources/generation/expressions/infix operation/generated/tests/generator/infixOperation/gen_input_h.py new file mode 100644 index 00000000..7b31e42d --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/expressions/infix operation/generated/tests/generator/infixOperation/gen_input_h.py @@ -0,0 +1,4 @@ +from .gen_input import h + +if __name__ == '__main__': + h() diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/infix operation/generated/tests/generator/infixOperation/gen_input_i.py b/packages/ttsl-lang/tests/resources/generation/expressions/infix operation/generated/tests/generator/infixOperation/gen_input_i.py new file mode 100644 index 00000000..a52c25bd --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/expressions/infix operation/generated/tests/generator/infixOperation/gen_input_i.py @@ -0,0 +1,4 @@ +from .gen_input import i + +if __name__ == '__main__': + i() diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/infix operation/input.sdstest b/packages/ttsl-lang/tests/resources/generation/expressions/infix operation/input.ttsl similarity index 67% rename from packages/ttsl-lang/tests/resources/generation/expressions/infix operation/input.sdstest rename to packages/ttsl-lang/tests/resources/generation/expressions/infix operation/input.ttsl index cd554cc9..b7424415 100644 --- a/packages/ttsl-lang/tests/resources/generation/expressions/infix operation/input.sdstest +++ b/packages/ttsl-lang/tests/resources/generation/expressions/infix operation/input.ttsl @@ -1,14 +1,14 @@ package tests.generator.infixOperation -@Impure([ImpurityReason.Other]) fun f(param: Any?) +function f(param: Any?){} -@Pure fun g() -> result: Boolean +function g(): Boolean{} -@Pure fun h() -> result: Int +function h(): Int{} -@Pure fun i() -> result: Int? +function i(): Int?{} -pipeline test { +function test () { f(g() or g()); f(g() and g()); diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/lists/generated/tests/generator/lists/gen_input.py b/packages/ttsl-lang/tests/resources/generation/expressions/lists/generated/tests/generator/lists/gen_input.py index d5faf3b2..79d13e80 100644 --- a/packages/ttsl-lang/tests/resources/generation/expressions/lists/generated/tests/generator/lists/gen_input.py +++ b/packages/ttsl-lang/tests/resources/generation/expressions/lists/generated/tests/generator/lists/gen_input.py @@ -1,6 +1,10 @@ -# Pipelines -------------------------------------------------------------------- +# Functions -------------------------------------------------------------------- + +def h(): + pass def test(): - f([]) - f([1, 2, 3]) - f([1, h(), (h()) + (5)]) + [] + [1, 2, 3] + [1, h(), (h()) + (5)] + diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/lists/generated/tests/generator/lists/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/expressions/lists/generated/tests/generator/lists/gen_input.py.map index 5ef3b43e..deb83844 100644 --- a/packages/ttsl-lang/tests/resources/generation/expressions/lists/generated/tests/generator/lists/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/expressions/lists/generated/tests/generator/lists/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.ttsl"],"names":["test","f","h"],"mappings":"AAAA;;AAMA,IAASA,IAAI;IACTC,CAAC,CAAC,EAAE;IACJA,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC;IACVA,CAAC,CAAC,CAAC,CAAC,EAAEC,CAAC,IAAI,CAAAA,CAAC,IAAG,CAAC,EAAC,CAAC","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["h","test"],"mappings":"AAAA;;AAEA,IAASA,CAAC;IAAO,IAAE;;AAEnB,IAASC,IAAI;IACT,EAAE;IACF,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC;IACR,CAAC,CAAC,EAAED,CAAC,IAAI,CAAAA,CAAC,IAAG,CAAC,EAAC,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/lists/generated/tests/generator/lists/gen_input_h.py b/packages/ttsl-lang/tests/resources/generation/expressions/lists/generated/tests/generator/lists/gen_input_h.py new file mode 100644 index 00000000..7b31e42d --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/expressions/lists/generated/tests/generator/lists/gen_input_h.py @@ -0,0 +1,4 @@ +from .gen_input import h + +if __name__ == '__main__': + h() diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/lists/input.sdstest b/packages/ttsl-lang/tests/resources/generation/expressions/lists/input.sdstest deleted file mode 100644 index eee59624..00000000 --- a/packages/ttsl-lang/tests/resources/generation/expressions/lists/input.sdstest +++ /dev/null @@ -1,11 +0,0 @@ -package tests.generator.lists - -@Impure([ImpurityReason.Other]) fun f(param: List) - -@Pure fun h() -> result: Int - -pipeline test { - f([]); - f([1, 2, 3]); - f([1, h(), h() + 5]); -} diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/lists/input.ttsl b/packages/ttsl-lang/tests/resources/generation/expressions/lists/input.ttsl new file mode 100644 index 00000000..7e60e687 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/expressions/lists/input.ttsl @@ -0,0 +1,9 @@ +package tests.generator.lists + +function h(): Int{} + +function test () { + []; + [1, 2, 3]; + [1, h(), h() + 5]; +} diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/literals/generated/tests/generator/literals/gen_input.py b/packages/ttsl-lang/tests/resources/generation/expressions/literals/generated/tests/generator/literals/gen_input.py index 71832fd6..326ceb4c 100644 --- a/packages/ttsl-lang/tests/resources/generation/expressions/literals/generated/tests/generator/literals/gen_input.py +++ b/packages/ttsl-lang/tests/resources/generation/expressions/literals/generated/tests/generator/literals/gen_input.py @@ -1,10 +1,12 @@ -# Pipelines -------------------------------------------------------------------- +# Functions -------------------------------------------------------------------- def test(): - f(True) - f(False) - f(1.0) - f(1) - f(None) - f('') - f('multi\nline') + true + false + 1 + 1 + None + "" + "multi +line" + diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/literals/generated/tests/generator/literals/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/expressions/literals/generated/tests/generator/literals/gen_input.py.map index b4c2d5a0..c36a1e66 100644 --- a/packages/ttsl-lang/tests/resources/generation/expressions/literals/generated/tests/generator/literals/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/expressions/literals/generated/tests/generator/literals/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.ttsl"],"names":["test","f","true","false","null"],"mappings":"AAAA;;AAIA,IAASA,IAAI;IACTC,CAAC,CAACC,IAAI;IACND,CAAC,CAACE,KAAK;IACPF,CAAC,CAAC,GAAG;IACLA,CAAC,CAAC,CAAC;IACHA,CAAC,CAACG,IAAI;IACNH,CAAC,CAAC,EAAE;IACJA,CAAC,CAAC","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["test","true","false","null"],"mappings":"AAAA;;AAEA,IAASA,IAAI;IACTC,IAAI;IACJC,KAAK;IACL,CAAG;IACH,CAAC;IACDC,IAAI;IACJ,EAAE;IACF","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/literals/input.sdstest b/packages/ttsl-lang/tests/resources/generation/expressions/literals/input.sdstest deleted file mode 100644 index 33625ee4..00000000 --- a/packages/ttsl-lang/tests/resources/generation/expressions/literals/input.sdstest +++ /dev/null @@ -1,14 +0,0 @@ -package tests.generator.literals - -@Impure([ImpurityReason.Other]) fun f(param: Any?) - -pipeline test { - f(true); - f(false); - f(1.0); - f(1); - f(null); - f(""); - f("multi -line"); -} diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/literals/input.ttsl b/packages/ttsl-lang/tests/resources/generation/expressions/literals/input.ttsl new file mode 100644 index 00000000..8ccf8f48 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/expressions/literals/input.ttsl @@ -0,0 +1,12 @@ +package tests.generator.literals + +function test () { + true; + false; + 1.0; + 1; + null; + ""; + "multi +line"; +} diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/maps/generated/tests/generator/maps/gen_input.py b/packages/ttsl-lang/tests/resources/generation/expressions/maps/generated/tests/generator/maps/gen_input.py deleted file mode 100644 index 45bfa941..00000000 --- a/packages/ttsl-lang/tests/resources/generation/expressions/maps/generated/tests/generator/maps/gen_input.py +++ /dev/null @@ -1,8 +0,0 @@ -# Pipelines -------------------------------------------------------------------- - -def test(): - g1({}) - g2({'a': 1.2, 'b': 1.0}) - g2({h2(): -0.5, 'b': h1()}) - g3({1.2: 'a', 1.0: 'b'}) - g3({5.6: 'c', h1(): h2()}) diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/maps/generated/tests/generator/maps/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/expressions/maps/generated/tests/generator/maps/gen_input.py.map deleted file mode 100644 index 9a167ee3..00000000 --- a/packages/ttsl-lang/tests/resources/generation/expressions/maps/generated/tests/generator/maps/gen_input.py.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"sources":["input.ttsl"],"names":["test","g1","g2","h2","h1","g3"],"mappings":"AAAA;;AAYA,IAASA,IAAI;IACTC,EAAE,CAAC,EAAE;IACLC,EAAE,CAAC,CAAC,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG;IACtBA,EAAE,CAAC,CAACC,EAAE,IAAI,IAAI,EAAE,GAAG,EAAEC,EAAE;IACvBC,EAAE,CAAC,CAAC,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG;IACtBA,EAAE,CAAC,CAAC,GAAG,EAAE,GAAG,EAAED,EAAE,IAAID,EAAE","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/maps/generated/tests/generator/maps/gen_input_test.py b/packages/ttsl-lang/tests/resources/generation/expressions/maps/generated/tests/generator/maps/gen_input_test.py deleted file mode 100644 index 824f70b1..00000000 --- a/packages/ttsl-lang/tests/resources/generation/expressions/maps/generated/tests/generator/maps/gen_input_test.py +++ /dev/null @@ -1,4 +0,0 @@ -from .gen_input import test - -if __name__ == '__main__': - test() diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/maps/input.sdstest b/packages/ttsl-lang/tests/resources/generation/expressions/maps/input.sdstest deleted file mode 100644 index 29c194c7..00000000 --- a/packages/ttsl-lang/tests/resources/generation/expressions/maps/input.sdstest +++ /dev/null @@ -1,19 +0,0 @@ -package tests.generator.maps - -@Impure([ImpurityReason.Other]) fun g1(param: Map) - -@Impure([ImpurityReason.Other]) fun g2(param: Map) - -@Impure([ImpurityReason.Other]) fun g3(param: Map) - -@Pure fun h1() -> result: Float - -@Pure fun h2() -> result: String - -pipeline test { - g1({}); - g2({"a": 1.2, "b": 1.0}); - g2({h2(): -0.5, "b": h1()}); - g3({1.2: "a", 1.0: "b"}); - g3({5.6: "c", h1(): h2()}); -} diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/maps/input.ttsl b/packages/ttsl-lang/tests/resources/generation/expressions/maps/input.ttsl new file mode 100644 index 00000000..ac15bac0 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/expressions/maps/input.ttsl @@ -0,0 +1,19 @@ +package tests.generator.maps + +function g1(param: Dict){} + +function g2(param: Dict){} + +function g3(param: Dict){} + +function h1(): Float {} + +function h2(): String{} + +function test () { + g1({}); + g2({"a": 1.2, "b": 1.0}); + g2({h2(): -0.5, "b": h1()}); + g3({1.2: "a", 1.0: "b"}); + g3({5.6: "c", h1(): h2()}); +} diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/member access/generated/tests/generator/memberAccess/gen_input.py b/packages/ttsl-lang/tests/resources/generation/expressions/member access/generated/tests/generator/memberAccess/gen_input.py deleted file mode 100644 index 9d5e0b28..00000000 --- a/packages/ttsl-lang/tests/resources/generation/expressions/member access/generated/tests/generator/memberAccess/gen_input.py +++ /dev/null @@ -1,27 +0,0 @@ -# Imports ---------------------------------------------------------------------- - -from typing import Any, TypeVar - -# Type variables --------------------------------------------------------------- - -__gen_T = TypeVar("__gen_T") - -# Utils ------------------------------------------------------------------------ - -def __gen_null_safe_member_access(receiver: Any, member_name: str) -> __gen_T | None: - return getattr(receiver, member_name) if receiver is not None else None - -# Pipelines -------------------------------------------------------------------- - -def test(): - f(g()) - f(h()[0]) - f(h()[1]) - f(C().a) - f(C().c) - f(__gen_null_safe_member_access(factory(), 'a')) - f(__gen_null_safe_member_access(factory(), 'c')) - f(1.i(C())) - f(C().j(123)) - f(C().k2('abc')) - f(C.from_csv_file('abc.csv')) diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/member access/generated/tests/generator/memberAccess/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/expressions/member access/generated/tests/generator/memberAccess/gen_input.py.map deleted file mode 100644 index 66696844..00000000 --- a/packages/ttsl-lang/tests/resources/generation/expressions/member access/generated/tests/generator/memberAccess/gen_input.py.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"sources":["input.ttsl"],"names":["test","f","g","h","result1","result2","c","a","b","factory","j","k","from_csv_file"],"mappings":"AAAA;;;;;;;;;;;;;;;AA4BA,IAASA,IAAI;IACTC,CAAC,CAACC,CAAC;IACHD,CAAC,CAACE,CAAC,GAAGC,CAAO;IACbH,CAAC,CAACE,CAAC,GAAGE,CAAO;IACbJ,CAAC,CAACK,CAAC,GAAGC,CAAC;IACPN,CAAC,CAACK,CAAC,GAAGE,CAAC;IACPP,CAAC,CAAU,6BAAC,CAAVQ,OAAO,KAAIF,CAAC;IACdN,CAAC,CAAU,6BAAC,CAAVQ,OAAO,KAAID,CAAC;IACdP,CAAC,CAAO,CAAC,GAAPK,CAAC;IACHL,CAAC,CAACK,CAAC,GAAGI,CAAC,CAAC,GAAG;IACXT,CAAC,CAACK,CAAC,GAAGK,EAAC,CAAC,KAAK;IACbV,CAAC,CAACK,CAAC,CAACM,aAAa,CAAC,SAAS","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/member access/generated/tests/generator/memberAccess/gen_input_test.py b/packages/ttsl-lang/tests/resources/generation/expressions/member access/generated/tests/generator/memberAccess/gen_input_test.py deleted file mode 100644 index 824f70b1..00000000 --- a/packages/ttsl-lang/tests/resources/generation/expressions/member access/generated/tests/generator/memberAccess/gen_input_test.py +++ /dev/null @@ -1,4 +0,0 @@ -from .gen_input import test - -if __name__ == '__main__': - test() diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/member access/input.sdstest b/packages/ttsl-lang/tests/resources/generation/expressions/member access/input.sdstest deleted file mode 100644 index f97e9b24..00000000 --- a/packages/ttsl-lang/tests/resources/generation/expressions/member access/input.sdstest +++ /dev/null @@ -1,41 +0,0 @@ -package tests.generator.memberAccess - -@Impure([ImpurityReason.Other]) fun f(param: Any?) - -@Pure fun g() -> result: Boolean - -@Pure fun h() -> (result1: Boolean, result2: Boolean) - -class C() { - attr a: Int - @PythonName("c") attr b: Int - - @Pure - @PythonCall("$param.i($this)") - fun i(param: Any?) -> result: Boolean - - @Pure - fun j(param: Any?) -> result: Boolean - - @Pure - @PythonName("k2") fun k(param: Any?) -> result: Boolean - - @Impure([ImpurityReason.FileReadFromParameterizedPath("name")]) - static fun from_csv_file(name: String) -> c: C -} - -@Pure fun factory() -> instance: C? - -pipeline test { - f(g().result); - f(h().result1); - f(h().result2); - f(C().a); - f(C().b); - f(factory()?.a); - f(factory()?.b); - f(C().i(1)); - f(C().j(123)); - f(C().k("abc")); - f(C.from_csv_file("abc.csv")); -} diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/parenthesized expression/generated/tests/generator/parenthesizedExpression/gen_input.py b/packages/ttsl-lang/tests/resources/generation/expressions/parenthesized expression/generated/tests/generator/parenthesizedExpression/gen_input.py index 00162f3c..7f3d4dc0 100644 --- a/packages/ttsl-lang/tests/resources/generation/expressions/parenthesized expression/generated/tests/generator/parenthesizedExpression/gen_input.py +++ b/packages/ttsl-lang/tests/resources/generation/expressions/parenthesized expression/generated/tests/generator/parenthesizedExpression/gen_input.py @@ -1,4 +1,11 @@ -# Pipelines -------------------------------------------------------------------- +# Functions -------------------------------------------------------------------- + +def f(param): + pass + +def g(): + pass def test(): f(g()) + diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/parenthesized expression/generated/tests/generator/parenthesizedExpression/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/expressions/parenthesized expression/generated/tests/generator/parenthesizedExpression/gen_input.py.map index cd948ab4..f1123f8d 100644 --- a/packages/ttsl-lang/tests/resources/generation/expressions/parenthesized expression/generated/tests/generator/parenthesizedExpression/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/expressions/parenthesized expression/generated/tests/generator/parenthesizedExpression/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.ttsl"],"names":["test","f","g"],"mappings":"AAAA;;AAMA,IAASA,IAAI;IACTC,CAAC,CAAEC,CAAC","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["f","param","g","test"],"mappings":"AAAA;;AAEA,IAASA,CAAC,CAACC,KAAK;IAAO,IAAE;;AAEzB,IAASC,CAAC;IAAW,IAAE;;AAEvB,IAASC,IAAI;IACTH,CAAC,CAAEE,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/parenthesized expression/generated/tests/generator/parenthesizedExpression/gen_input_f.py b/packages/ttsl-lang/tests/resources/generation/expressions/parenthesized expression/generated/tests/generator/parenthesizedExpression/gen_input_f.py new file mode 100644 index 00000000..3c6273bd --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/expressions/parenthesized expression/generated/tests/generator/parenthesizedExpression/gen_input_f.py @@ -0,0 +1,4 @@ +from .gen_input import f + +if __name__ == '__main__': + f() diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/parenthesized expression/generated/tests/generator/parenthesizedExpression/gen_input_g.py b/packages/ttsl-lang/tests/resources/generation/expressions/parenthesized expression/generated/tests/generator/parenthesizedExpression/gen_input_g.py new file mode 100644 index 00000000..0e7a09fa --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/expressions/parenthesized expression/generated/tests/generator/parenthesizedExpression/gen_input_g.py @@ -0,0 +1,4 @@ +from .gen_input import g + +if __name__ == '__main__': + g() diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/parenthesized expression/input.sdstest b/packages/ttsl-lang/tests/resources/generation/expressions/parenthesized expression/input.sdstest deleted file mode 100644 index 06fceb84..00000000 --- a/packages/ttsl-lang/tests/resources/generation/expressions/parenthesized expression/input.sdstest +++ /dev/null @@ -1,9 +0,0 @@ -package tests.generator.parenthesizedExpression - -@Impure([ImpurityReason.Other]) fun f(param: Any?) - -@Pure fun g() -> result: Boolean - -pipeline test { - f((g())); -} diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/parenthesized expression/input.ttsl b/packages/ttsl-lang/tests/resources/generation/expressions/parenthesized expression/input.ttsl new file mode 100644 index 00000000..0aceaff2 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/expressions/parenthesized expression/input.ttsl @@ -0,0 +1,9 @@ +package tests.generator.parenthesizedExpression + +function f(param: Any?){} + +function g(): Boolean{} + +function test () { + f((g())); +} diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/prefix operation/generated/tests/generator/prefixOperation/gen_input.py b/packages/ttsl-lang/tests/resources/generation/expressions/prefix operation/generated/tests/generator/prefixOperation/gen_input.py index 138c6bf3..e30ce0af 100644 --- a/packages/ttsl-lang/tests/resources/generation/expressions/prefix operation/generated/tests/generator/prefixOperation/gen_input.py +++ b/packages/ttsl-lang/tests/resources/generation/expressions/prefix operation/generated/tests/generator/prefixOperation/gen_input.py @@ -1,5 +1,15 @@ -# Pipelines -------------------------------------------------------------------- +# Functions -------------------------------------------------------------------- + +def f(param): + pass + +def g(): + pass + +def h(): + pass def test(): f(not (g())) f(-(h())) + diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/prefix operation/generated/tests/generator/prefixOperation/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/expressions/prefix operation/generated/tests/generator/prefixOperation/gen_input.py.map index c108e1a3..209f515e 100644 --- a/packages/ttsl-lang/tests/resources/generation/expressions/prefix operation/generated/tests/generator/prefixOperation/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/expressions/prefix operation/generated/tests/generator/prefixOperation/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.ttsl"],"names":["test","f","not","g","h"],"mappings":"AAAA;;AAQA,IAASA,IAAI;IACTC,CAAC,CAACC,GAAG,EAACC,CAAC;IACPF,CAAC,CAAC,CAAC,CAAAG,CAAC","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["f","param","g","h","test","not"],"mappings":"AAAA;;AAEA,IAASA,CAAC,CAACC,KAAK;IAAO,IAAE;;AAEzB,IAASC,CAAC;IAAW,IAAE;;AAEvB,IAASC,CAAC;IAAO,IAAE;;AAEnB,IAASC,IAAI;IACTJ,CAAC,CAACK,GAAG,EAACH,CAAC;IACPF,CAAC,CAAC,CAAC,CAAAG,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/prefix operation/generated/tests/generator/prefixOperation/gen_input_f.py b/packages/ttsl-lang/tests/resources/generation/expressions/prefix operation/generated/tests/generator/prefixOperation/gen_input_f.py new file mode 100644 index 00000000..3c6273bd --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/expressions/prefix operation/generated/tests/generator/prefixOperation/gen_input_f.py @@ -0,0 +1,4 @@ +from .gen_input import f + +if __name__ == '__main__': + f() diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/prefix operation/generated/tests/generator/prefixOperation/gen_input_g.py b/packages/ttsl-lang/tests/resources/generation/expressions/prefix operation/generated/tests/generator/prefixOperation/gen_input_g.py new file mode 100644 index 00000000..0e7a09fa --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/expressions/prefix operation/generated/tests/generator/prefixOperation/gen_input_g.py @@ -0,0 +1,4 @@ +from .gen_input import g + +if __name__ == '__main__': + g() diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/prefix operation/generated/tests/generator/prefixOperation/gen_input_h.py b/packages/ttsl-lang/tests/resources/generation/expressions/prefix operation/generated/tests/generator/prefixOperation/gen_input_h.py new file mode 100644 index 00000000..7b31e42d --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/expressions/prefix operation/generated/tests/generator/prefixOperation/gen_input_h.py @@ -0,0 +1,4 @@ +from .gen_input import h + +if __name__ == '__main__': + h() diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/prefix operation/input.sdstest b/packages/ttsl-lang/tests/resources/generation/expressions/prefix operation/input.sdstest deleted file mode 100644 index ff38d2a7..00000000 --- a/packages/ttsl-lang/tests/resources/generation/expressions/prefix operation/input.sdstest +++ /dev/null @@ -1,12 +0,0 @@ -package tests.generator.prefixOperation - -@Impure([ImpurityReason.Other]) fun f(param: Any?) - -@Pure fun g() -> result: Boolean - -@Pure fun h() -> result: Int - -pipeline test { - f(not g()); - f(-h()); -} diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/prefix operation/input.ttsl b/packages/ttsl-lang/tests/resources/generation/expressions/prefix operation/input.ttsl new file mode 100644 index 00000000..46ca9427 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/expressions/prefix operation/input.ttsl @@ -0,0 +1,12 @@ +package tests.generator.prefixOperation + +function f(param: Any?){} + +function g(): Boolean{} + +function h(): Int{} + +function test () { + f(not g()); + f(-h()); +} diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/reference/generated/tests/generator/reference/gen_input.py b/packages/ttsl-lang/tests/resources/generation/expressions/reference/generated/tests/generator/reference/gen_input.py index 149d8bb6..b27e4ec3 100644 --- a/packages/ttsl-lang/tests/resources/generation/expressions/reference/generated/tests/generator/reference/gen_input.py +++ b/packages/ttsl-lang/tests/resources/generation/expressions/reference/generated/tests/generator/reference/gen_input.py @@ -1,4 +1,11 @@ -# Pipelines -------------------------------------------------------------------- +# Functions -------------------------------------------------------------------- + +def f(param): + pass + +def explainModel(): + pass def test(): - f(explain_model()) + f(explainModel()) + diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/reference/generated/tests/generator/reference/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/expressions/reference/generated/tests/generator/reference/gen_input.py.map index 136f1521..34edf6b3 100644 --- a/packages/ttsl-lang/tests/resources/generation/expressions/reference/generated/tests/generator/reference/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/expressions/reference/generated/tests/generator/reference/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.ttsl"],"names":["test","f","explainmodel"],"mappings":"AAAA;;AAQA,IAASA,IAAI;IACTC,CAAC,CAACC,aAAY","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["f","param","explainmodel","test"],"mappings":"AAAA;;AAEA,IAASA,CAAC,CAACC,KAAK;IAAO,IAAE;;AAEzB,IAASC,YAAY;IAAO,IAAE;;AAE9B,IAASC,IAAI;IACTH,CAAC,CAACE,YAAY","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/reference/generated/tests/generator/reference/gen_input_explainModel.py b/packages/ttsl-lang/tests/resources/generation/expressions/reference/generated/tests/generator/reference/gen_input_explainModel.py new file mode 100644 index 00000000..641a65e9 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/expressions/reference/generated/tests/generator/reference/gen_input_explainModel.py @@ -0,0 +1,4 @@ +from .gen_input import explainModel + +if __name__ == '__main__': + explainModel() diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/reference/generated/tests/generator/reference/gen_input_f.py b/packages/ttsl-lang/tests/resources/generation/expressions/reference/generated/tests/generator/reference/gen_input_f.py new file mode 100644 index 00000000..3c6273bd --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/expressions/reference/generated/tests/generator/reference/gen_input_f.py @@ -0,0 +1,4 @@ +from .gen_input import f + +if __name__ == '__main__': + f() diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/reference/input.sdstest b/packages/ttsl-lang/tests/resources/generation/expressions/reference/input.sdstest deleted file mode 100644 index b248defc..00000000 --- a/packages/ttsl-lang/tests/resources/generation/expressions/reference/input.sdstest +++ /dev/null @@ -1,11 +0,0 @@ -package tests.generator.reference - -@Impure([ImpurityReason.Other]) fun f(param: Any?) - -@Pure -@PythonName("explain_model") -fun explainModel() -> result: Int - -pipeline test { - f(explainModel()); -} diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/reference/input.ttsl b/packages/ttsl-lang/tests/resources/generation/expressions/reference/input.ttsl new file mode 100644 index 00000000..3f12bfb8 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/expressions/reference/input.ttsl @@ -0,0 +1,9 @@ +package tests.generator.reference + +function f(param: Any?){} + +function explainModel(): Int{} + +function test () { + f(explainModel()); +} diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/side effects/generated/tests/generator/sideEffects/gen_input.py b/packages/ttsl-lang/tests/resources/generation/expressions/side effects/generated/tests/generator/sideEffects/gen_input.py deleted file mode 100644 index 506c0982..00000000 --- a/packages/ttsl-lang/tests/resources/generation/expressions/side effects/generated/tests/generator/sideEffects/gen_input.py +++ /dev/null @@ -1,15 +0,0 @@ -# Segments --------------------------------------------------------------------- - -def mySegment(param): - f() - __gen_yield_result = param - return __gen_yield_result - -# Pipelines -------------------------------------------------------------------- - -def test(): - mySegment(True) - mySegment(0.0) - mySegment(2) - mySegment(None) - mySegment('person: me') diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/side effects/generated/tests/generator/sideEffects/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/expressions/side effects/generated/tests/generator/sideEffects/gen_input.py.map deleted file mode 100644 index 96db5dbd..00000000 --- a/packages/ttsl-lang/tests/resources/generation/expressions/side effects/generated/tests/generator/sideEffects/gen_input.py.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"sources":["input.ttsl"],"names":["mysegment","param","f","result","test","null"],"mappings":"AAAA;;AAIA,IAAQA,SAAS,CAACC,KAAK;IACnBC,CAAC;IACD,YAAMC,MAAM,GAAGF,KAAK;IAFO,OAAG;;;;AAKlC,IAASG,IAAI;IACTJ,SAAS,CAAC;IACVA,SAAS,CAAC;IACVA,SAAS,CAAC;IACVA,SAAS,CAACK,IAAI;IACdL,SAAS,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/side effects/generated/tests/generator/sideEffects/gen_input_test.py b/packages/ttsl-lang/tests/resources/generation/expressions/side effects/generated/tests/generator/sideEffects/gen_input_test.py deleted file mode 100644 index 824f70b1..00000000 --- a/packages/ttsl-lang/tests/resources/generation/expressions/side effects/generated/tests/generator/sideEffects/gen_input_test.py +++ /dev/null @@ -1,4 +0,0 @@ -from .gen_input import test - -if __name__ == '__main__': - test() diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/side effects/input.sdstest b/packages/ttsl-lang/tests/resources/generation/expressions/side effects/input.sdstest deleted file mode 100644 index df48228a..00000000 --- a/packages/ttsl-lang/tests/resources/generation/expressions/side effects/input.sdstest +++ /dev/null @@ -1,16 +0,0 @@ -package tests.generator.sideEffects - -@Impure([ImpurityReason.Other]) fun f() - -segment mySegment(param: Any?) -> result: Any? { - f(); - yield result = param; -} - -pipeline test { - mySegment(1 < 2); - mySegment(1.0 - 1.0); - mySegment(1 + 1); - mySegment(null); - mySegment("person: {{ "me" }}"); -} diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/template string/generated/tests/generator/templateString/gen_input.py b/packages/ttsl-lang/tests/resources/generation/expressions/template string/generated/tests/generator/templateString/gen_input.py deleted file mode 100644 index 7756f36a..00000000 --- a/packages/ttsl-lang/tests/resources/generation/expressions/template string/generated/tests/generator/templateString/gen_input.py +++ /dev/null @@ -1,4 +0,0 @@ -# Pipelines -------------------------------------------------------------------- - -def test(): - f(f'start\n{ g() }\ninner { g() }\nend') diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/template string/generated/tests/generator/templateString/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/expressions/template string/generated/tests/generator/templateString/gen_input.py.map deleted file mode 100644 index 2e67c496..00000000 --- a/packages/ttsl-lang/tests/resources/generation/expressions/template string/generated/tests/generator/templateString/gen_input.py.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"sources":["input.ttsl"],"names":["test","f","g"],"mappings":"AAAA;;AAMA,IAASA,IAAI;IACTC,CAAC,CAAC,EAAA,SACHC,CAAC,EAAG,YACEA,CAAC,EAAG","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/template string/generated/tests/generator/templateString/gen_input_test.py b/packages/ttsl-lang/tests/resources/generation/expressions/template string/generated/tests/generator/templateString/gen_input_test.py deleted file mode 100644 index 824f70b1..00000000 --- a/packages/ttsl-lang/tests/resources/generation/expressions/template string/generated/tests/generator/templateString/gen_input_test.py +++ /dev/null @@ -1,4 +0,0 @@ -from .gen_input import test - -if __name__ == '__main__': - test() diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/template string/input.sdstest b/packages/ttsl-lang/tests/resources/generation/expressions/template string/input.sdstest deleted file mode 100644 index 2e864542..00000000 --- a/packages/ttsl-lang/tests/resources/generation/expressions/template string/input.sdstest +++ /dev/null @@ -1,12 +0,0 @@ -package tests.generator.templateString - -@Impure([ImpurityReason.Other]) fun f(param: Any?) - -@Pure fun g() -> result: Int - -pipeline test { - f("start -{{ g() }} -inner {{ g() }} -end"); -} diff --git a/packages/ttsl-lang/tests/resources/generation/imports/general/context different package.sdsstub b/packages/ttsl-lang/tests/resources/generation/imports/general/context different package.sdsstub deleted file mode 100644 index 2d711c90..00000000 --- a/packages/ttsl-lang/tests/resources/generation/imports/general/context different package.sdsstub +++ /dev/null @@ -1,4 +0,0 @@ -package tests.generator.differentPackage - -@Pure fun function1InDifferentPackage() -> result: Int -@Pure fun function2InDifferentPackage() -> result: Int diff --git a/packages/ttsl-lang/tests/resources/generation/imports/general/context different package.ttsl b/packages/ttsl-lang/tests/resources/generation/imports/general/context different package.ttsl new file mode 100644 index 00000000..b7174e2e --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/imports/general/context different package.ttsl @@ -0,0 +1,4 @@ +package tests.generator.differentPackage + +function function1InDifferentPackage(): Int {} +function function2InDifferentPackage(): Int {} diff --git a/packages/ttsl-lang/tests/resources/generation/imports/general/context package with python module.sdsstub b/packages/ttsl-lang/tests/resources/generation/imports/general/context package with python module.sdsstub deleted file mode 100644 index a880f9e5..00000000 --- a/packages/ttsl-lang/tests/resources/generation/imports/general/context package with python module.sdsstub +++ /dev/null @@ -1,6 +0,0 @@ -@PythonModule("special_location") - -package tests.generator.withPythonModule - -@Pure fun function1InCompilationUnitWithPythonModule() -> result: Int -@Pure fun function2InCompilationUnitWithPythonModule() -> result: Int diff --git a/packages/ttsl-lang/tests/resources/generation/imports/general/context package with python module.ttsl b/packages/ttsl-lang/tests/resources/generation/imports/general/context package with python module.ttsl new file mode 100644 index 00000000..512cf2f1 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/imports/general/context package with python module.ttsl @@ -0,0 +1,4 @@ +package tests.generator.withPythonModule + +function function1InCompilationUnitWithPythonModule(): Int {} +function function2InCompilationUnitWithPythonModule(): Int{} diff --git a/packages/ttsl-lang/tests/resources/generation/imports/general/context same package.sdstest b/packages/ttsl-lang/tests/resources/generation/imports/general/context same package.sdstest deleted file mode 100644 index e41b4f8f..00000000 --- a/packages/ttsl-lang/tests/resources/generation/imports/general/context same package.sdstest +++ /dev/null @@ -1,11 +0,0 @@ -package tests.generator.imports - -@Pure fun impureFunction() -> result: Int - -segment segment1InSamePackage() -> result: Int { - yield result = impureFunction(); -} - -segment segment2InSamePackage() -> result: Int { - yield result = impureFunction(); -} diff --git a/packages/ttsl-lang/tests/resources/generation/imports/general/context same package.ttsl b/packages/ttsl-lang/tests/resources/generation/imports/general/context same package.ttsl new file mode 100644 index 00000000..2104ea84 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/imports/general/context same package.ttsl @@ -0,0 +1,11 @@ +package tests.generator.imports + +function impureFunction(): Int{} + +function function1InSamePackage(): Int { + return impureFunction(); +} + +function function2InSamePackage(): Int { + return impureFunction(); +} diff --git a/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_context_same_package.py b/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_context_same_package.py deleted file mode 100644 index 3d520946..00000000 --- a/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_context_same_package.py +++ /dev/null @@ -1,9 +0,0 @@ -# Segments --------------------------------------------------------------------- - -def segment1InSamePackage(): - __gen_yield_result = impureFunction() - return __gen_yield_result - -def segment2InSamePackage(): - __gen_yield_result = impureFunction() - return __gen_yield_result diff --git a/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_context_same_package.py.map b/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_context_same_package.py.map deleted file mode 100644 index 8ee50011..00000000 --- a/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_context_same_package.py.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"sources":["context same package.ttsl"],"names":["segment1insamepackage","result","impurefunction","segment2insamepackage"],"mappings":"AAAA;;AAIA,IAAQA,qBAAqB;IACzB,YAAMC,MAAM,GAAGC,cAAc;IADD,OAAG;;AAInC,IAAQC,qBAAqB;IACzB,YAAMF,MAAM,GAAGC,cAAc;IADD,OAAG","file":"gen_context_same_package.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_input.py b/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_input.py deleted file mode 100644 index 8fd2d0cc..00000000 --- a/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_input.py +++ /dev/null @@ -1,21 +0,0 @@ -# Imports ---------------------------------------------------------------------- - -from special_location import function1InCompilationUnitWithPythonModule, function2InCompilationUnitWithPythonModule as h -from tests.generator.differentPackage import function1InDifferentPackage, function2InDifferentPackage as g -from tests.generator.imports.gen_context_same_package import segment1InSamePackage, segment2InSamePackage - -# Pipelines -------------------------------------------------------------------- - -def test(): - f(segment1InSamePackage()) - f(segment1InSamePackage()) - f(segment2InSamePackage()) - f(segment2InSamePackage()) - f(function1InDifferentPackage()) - f(function1InDifferentPackage()) - f(g()) - f(g()) - f(function1InCompilationUnitWithPythonModule()) - f(function1InCompilationUnitWithPythonModule()) - f(h()) - f(h()) diff --git a/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_input.py.map deleted file mode 100644 index 185b5027..00000000 --- a/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_input.py.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"sources":["input.ttsl"],"names":["test","f","segment1insamepackage","segment2insamepackage","function1indifferentpackage","g","function1incompilationunitwithpythonmodule","h"],"mappings":"AAAA;;;;;;;;AASA,IAASA,IAAI;IACTC,CAAC,CAACC,qBAAqB;IACvBD,CAAC,CAACC,qBAAqB;IACvBD,CAAC,CAACE,qBAAqB;IACvBF,CAAC,CAACE,qBAAqB;IAEvBF,CAAC,CAACG,2BAA2B;IAC7BH,CAAC,CAACG,2BAA2B;IAC7BH,CAAC,CAACI,CAAC;IACHJ,CAAC,CAACI,CAAC;IAEHJ,CAAC,CAACK,0CAA0C;IAC5CL,CAAC,CAACK,0CAA0C;IAC5CL,CAAC,CAACM,CAAC;IACHN,CAAC,CAACM,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_input_test.py b/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_input_test.py deleted file mode 100644 index 824f70b1..00000000 --- a/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_input_test.py +++ /dev/null @@ -1,4 +0,0 @@ -from .gen_input import test - -if __name__ == '__main__': - test() diff --git a/packages/ttsl-lang/tests/resources/generation/imports/general/input.sdstest b/packages/ttsl-lang/tests/resources/generation/imports/general/input.ttsl similarity index 91% rename from packages/ttsl-lang/tests/resources/generation/imports/general/input.sdstest rename to packages/ttsl-lang/tests/resources/generation/imports/general/input.ttsl index e7176f72..739ca838 100644 --- a/packages/ttsl-lang/tests/resources/generation/imports/general/input.sdstest +++ b/packages/ttsl-lang/tests/resources/generation/imports/general/input.ttsl @@ -5,9 +5,9 @@ from tests.generator.differentPackage import function2InDifferentPackage as g from tests.generator.withPythonModule import function1InCompilationUnitWithPythonModule from tests.generator.withPythonModule import function2InCompilationUnitWithPythonModule as h -@Impure([ImpurityReason.Other]) fun f(param: Any?) +function f(param: Any?){} -pipeline test { +function test () { f(segment1InSamePackage()); f(segment1InSamePackage()); f(segment2InSamePackage()); diff --git a/packages/ttsl-lang/tests/resources/generation/imports/wildcard/context different package.sdsstub b/packages/ttsl-lang/tests/resources/generation/imports/wildcard/context different package.sdsstub index 0e9b2b8a..aae61710 100644 --- a/packages/ttsl-lang/tests/resources/generation/imports/wildcard/context different package.sdsstub +++ b/packages/ttsl-lang/tests/resources/generation/imports/wildcard/context different package.sdsstub @@ -1,4 +1,4 @@ package tests.generator.differentPackageWildcard -@Pure fun function1InDifferentPackage() -> result: Int -@Pure fun function2InDifferentPackage() -> result: Int +function function1InDifferentPackage() : Int {} +function function2InDifferentPackage() : Int {} diff --git a/packages/ttsl-lang/tests/resources/generation/imports/wildcard/context package with python module.sdsstub b/packages/ttsl-lang/tests/resources/generation/imports/wildcard/context package with python module.sdsstub index c92720c0..235cae3d 100644 --- a/packages/ttsl-lang/tests/resources/generation/imports/wildcard/context package with python module.sdsstub +++ b/packages/ttsl-lang/tests/resources/generation/imports/wildcard/context package with python module.sdsstub @@ -1,6 +1,4 @@ -@PythonModule("special_location") - package tests.generator.withPythonModuleWildcard -@Pure fun function1InCompilationUnitWithPythonModule() -> result: Int -@Pure fun function2InCompilationUnitWithPythonModule() -> result: Int +function function1InCompilationUnitWithPythonModule(): Int {} +function function2InCompilationUnitWithPythonModule(): Int {} diff --git a/packages/ttsl-lang/tests/resources/generation/imports/wildcard/generated/tests/generator/wildcard/gen_input.py b/packages/ttsl-lang/tests/resources/generation/imports/wildcard/generated/tests/generator/wildcard/gen_input.py deleted file mode 100644 index 4283f3f5..00000000 --- a/packages/ttsl-lang/tests/resources/generation/imports/wildcard/generated/tests/generator/wildcard/gen_input.py +++ /dev/null @@ -1,16 +0,0 @@ -# Imports ---------------------------------------------------------------------- - -from special_location import function1InCompilationUnitWithPythonModule, function2InCompilationUnitWithPythonModule -from tests.generator.differentPackageWildcard import function1InDifferentPackage, function2InDifferentPackage - -# Pipelines -------------------------------------------------------------------- - -def test(): - f(function1InDifferentPackage()) - f(function1InDifferentPackage()) - f(function2InDifferentPackage()) - f(function2InDifferentPackage()) - f(function1InCompilationUnitWithPythonModule()) - f(function1InCompilationUnitWithPythonModule()) - f(function2InCompilationUnitWithPythonModule()) - f(function2InCompilationUnitWithPythonModule()) diff --git a/packages/ttsl-lang/tests/resources/generation/imports/wildcard/generated/tests/generator/wildcard/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/imports/wildcard/generated/tests/generator/wildcard/gen_input.py.map deleted file mode 100644 index 3f670bf1..00000000 --- a/packages/ttsl-lang/tests/resources/generation/imports/wildcard/generated/tests/generator/wildcard/gen_input.py.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"sources":["input.ttsl"],"names":["test","f","function1indifferentpackage","function2indifferentpackage","function1incompilationunitwithpythonmodule","function2incompilationunitwithpythonmodule"],"mappings":"AAAA;;;;;;;AAOA,IAASA,IAAI;IACTC,CAAC,CAACC,2BAA2B;IAC7BD,CAAC,CAACC,2BAA2B;IAC7BD,CAAC,CAACE,2BAA2B;IAC7BF,CAAC,CAACE,2BAA2B;IAE7BF,CAAC,CAACG,0CAA0C;IAC5CH,CAAC,CAACG,0CAA0C;IAC5CH,CAAC,CAACI,0CAA0C;IAC5CJ,CAAC,CAACI,0CAA0C","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/imports/wildcard/generated/tests/generator/wildcard/gen_input_test.py b/packages/ttsl-lang/tests/resources/generation/imports/wildcard/generated/tests/generator/wildcard/gen_input_test.py deleted file mode 100644 index 824f70b1..00000000 --- a/packages/ttsl-lang/tests/resources/generation/imports/wildcard/generated/tests/generator/wildcard/gen_input_test.py +++ /dev/null @@ -1,4 +0,0 @@ -from .gen_input import test - -if __name__ == '__main__': - test() diff --git a/packages/ttsl-lang/tests/resources/generation/imports/wildcard/input.sdstest b/packages/ttsl-lang/tests/resources/generation/imports/wildcard/input.sdstest index 4a045551..8864c25c 100644 --- a/packages/ttsl-lang/tests/resources/generation/imports/wildcard/input.sdstest +++ b/packages/ttsl-lang/tests/resources/generation/imports/wildcard/input.sdstest @@ -3,9 +3,9 @@ package tests.generator.wildcard from tests.generator.differentPackageWildcard import * from tests.generator.withPythonModuleWildcard import * -@Impure([ImpurityReason.Other]) fun f(param: Any?) +function f(param: Any?){} -pipeline test { +function test () { f(function1InDifferentPackage()); f(function1InDifferentPackage()); f(function2InDifferentPackage()); diff --git a/packages/ttsl-lang/tests/resources/generation/modifier/timeunit/generated/tests/generator/timeunit/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/modifier/timeunit/generated/tests/generator/timeunit/gen_input.py.map index 4e145371..e1926f15 100644 --- a/packages/ttsl-lang/tests/resources/generation/modifier/timeunit/generated/tests/generator/timeunit/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/modifier/timeunit/generated/tests/generator/timeunit/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.ttsl"],"names":["daytest","weektest","monthtest","yeartest"],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAEA,IAAiBA,OAAO;;;;;;AAIxB,IAAkBC,QAAQ;;;;;;AAI1B,IAAmBC,SAAS;;;;;;AAI5B,IAAkBC,QAAQ","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["daytest","weektest","monthtest","yeartest"],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAEA,IAAiBA,OAAO;AACpB;;;;;AAGJ,IAAkBC,QAAQ;AACtB;;;;;AAGJ,IAAmBC,SAAS;AACxB;;;;;AAGJ,IAAkBC,QAAQ;AACtB","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/modifier/timeunit/generated/tests/generator/timeunit/gen_input_daytest.py b/packages/ttsl-lang/tests/resources/generation/modifier/timeunit/generated/tests/generator/timeunit/gen_input_daytest.py new file mode 100644 index 00000000..9128caa3 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/modifier/timeunit/generated/tests/generator/timeunit/gen_input_daytest.py @@ -0,0 +1,4 @@ +from .gen_input import daytest + +if __name__ == '__main__': + daytest() diff --git a/packages/ttsl-lang/tests/resources/generation/modifier/timeunit/generated/tests/generator/timeunit/gen_input_monthtest.py b/packages/ttsl-lang/tests/resources/generation/modifier/timeunit/generated/tests/generator/timeunit/gen_input_monthtest.py new file mode 100644 index 00000000..71dfd977 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/modifier/timeunit/generated/tests/generator/timeunit/gen_input_monthtest.py @@ -0,0 +1,4 @@ +from .gen_input import monthtest + +if __name__ == '__main__': + monthtest() diff --git a/packages/ttsl-lang/tests/resources/generation/modifier/timeunit/generated/tests/generator/timeunit/gen_input_weektest.py b/packages/ttsl-lang/tests/resources/generation/modifier/timeunit/generated/tests/generator/timeunit/gen_input_weektest.py new file mode 100644 index 00000000..b5d9fab9 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/modifier/timeunit/generated/tests/generator/timeunit/gen_input_weektest.py @@ -0,0 +1,4 @@ +from .gen_input import weektest + +if __name__ == '__main__': + weektest() diff --git a/packages/ttsl-lang/tests/resources/generation/modifier/timeunit/generated/tests/generator/timeunit/gen_input_yeartest.py b/packages/ttsl-lang/tests/resources/generation/modifier/timeunit/generated/tests/generator/timeunit/gen_input_yeartest.py new file mode 100644 index 00000000..9e68244d --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/modifier/timeunit/generated/tests/generator/timeunit/gen_input_yeartest.py @@ -0,0 +1,4 @@ +from .gen_input import yeartest + +if __name__ == '__main__': + yeartest() diff --git a/packages/ttsl-lang/tests/resources/generation/modifier/timeunit/input.ttsl b/packages/ttsl-lang/tests/resources/generation/modifier/timeunit/input.ttsl index 2d82469a..2076d076 100644 --- a/packages/ttsl-lang/tests/resources/generation/modifier/timeunit/input.ttsl +++ b/packages/ttsl-lang/tests/resources/generation/modifier/timeunit/input.ttsl @@ -1,17 +1,17 @@ package tests.generator.timeunit function per day daytest (): Int { - return 100 + return 100; } function per week weektest (): Int { - return 100 + return 100; } function per month monthtest (): Int { - return 100 + return 100; } function per year yeartest (): Int { - return 100 + return 100; } \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/partial/impure dependency file constant/generated/tests/generator/partialImpureDependencyFileConstant/gen_input.py b/packages/ttsl-lang/tests/resources/generation/partial/impure dependency file constant/generated/tests/generator/partialImpureDependencyFileConstant/gen_input.py deleted file mode 100644 index d5d704c0..00000000 --- a/packages/ttsl-lang/tests/resources/generation/partial/impure dependency file constant/generated/tests/generator/partialImpureDependencyFileConstant/gen_input.py +++ /dev/null @@ -1,10 +0,0 @@ -# Pipelines -------------------------------------------------------------------- - -def testPipeline(): - impureFileWrite = iFileWriteA() - impureFileWrite2 = iFileWriteA() - impureFileReadAgain = iFileReadA() - impureFileWriteB = iFileWriteB() - impureFileWrite2B = iFileWriteB() - impureFileReadAgainB = iFileReadB() - result = (impureFileReadAgain) + (impureFileReadAgainB) diff --git a/packages/ttsl-lang/tests/resources/generation/partial/impure dependency file constant/generated/tests/generator/partialImpureDependencyFileConstant/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/partial/impure dependency file constant/generated/tests/generator/partialImpureDependencyFileConstant/gen_input.py.map deleted file mode 100644 index e7dec750..00000000 --- a/packages/ttsl-lang/tests/resources/generation/partial/impure dependency file constant/generated/tests/generator/partialImpureDependencyFileConstant/gen_input.py.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"sources":["input.ttsl"],"names":["testpipeline","ifilewritea","ifilereada","ifilewriteb","ifilereadb","impurefilereadagain","impurefilereadagainb"],"mappings":"AAAA;;AAUA,IAASA,YAAY;IAEjB,kBAAsBC,WAAW;IACjC,mBAAuBA,WAAW;IAClC,sBAA0BC,UAAU;IAGpC,mBAAuBC,WAAW;IAClC,oBAAwBA,WAAW;IACnC,uBAA2BC,UAAU;IAGrC,SAAe,CAAAC,mBAAmB,EAAC,CAAC,EAACC,oBAAoB","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/partial/impure dependency file constant/generated/tests/generator/partialImpureDependencyFileConstant/gen_input_testPipeline.py b/packages/ttsl-lang/tests/resources/generation/partial/impure dependency file constant/generated/tests/generator/partialImpureDependencyFileConstant/gen_input_testPipeline.py deleted file mode 100644 index 09ca7590..00000000 --- a/packages/ttsl-lang/tests/resources/generation/partial/impure dependency file constant/generated/tests/generator/partialImpureDependencyFileConstant/gen_input_testPipeline.py +++ /dev/null @@ -1,4 +0,0 @@ -from .gen_input import testPipeline - -if __name__ == '__main__': - testPipeline() diff --git a/packages/ttsl-lang/tests/resources/generation/partial/impure dependency file constant/input.sdstest b/packages/ttsl-lang/tests/resources/generation/partial/impure dependency file constant/input.sdstest deleted file mode 100644 index b7b0a73f..00000000 --- a/packages/ttsl-lang/tests/resources/generation/partial/impure dependency file constant/input.sdstest +++ /dev/null @@ -1,24 +0,0 @@ -package tests.generator.partialImpureDependencyFileConstant - -@Impure([ImpurityReason.FileReadFromConstantPath("a.txt")]) fun iFileReadA() -> q: Int - -@Impure([ImpurityReason.FileWriteToConstantPath("a.txt")]) fun iFileWriteA() -> q: Int - -@Impure([ImpurityReason.FileReadFromConstantPath("b.txt")]) fun iFileReadB() -> q: Int - -@Impure([ImpurityReason.FileWriteToConstantPath("b.txt")]) fun iFileWriteB() -> q: Int - -pipeline testPipeline { - val impureFileRead = iFileReadA(); // Should not be generated - cannot affect result - val impureFileWrite = iFileWriteA(); - val impureFileWrite2 = iFileWriteA(); - val impureFileReadAgain = iFileReadA(); - - val impureFileReadB = iFileReadB(); // Should not be generated - cannot affect result, independent from previous file - val impureFileWriteB = iFileWriteB(); - val impureFileWrite2B = iFileWriteB(); - val impureFileReadAgainB = iFileReadB(); - - // $TEST$ run_until - val »result« = impureFileReadAgain + impureFileReadAgainB; -} diff --git a/packages/ttsl-lang/tests/resources/generation/partial/impure dependency file parameter/generated/tests/generator/partialImpureDependencyFileParameter/gen_input.py b/packages/ttsl-lang/tests/resources/generation/partial/impure dependency file parameter/generated/tests/generator/partialImpureDependencyFileParameter/gen_input.py deleted file mode 100644 index 725220e4..00000000 --- a/packages/ttsl-lang/tests/resources/generation/partial/impure dependency file parameter/generated/tests/generator/partialImpureDependencyFileParameter/gen_input.py +++ /dev/null @@ -1,7 +0,0 @@ -# Pipelines -------------------------------------------------------------------- - -def testPipeline(): - impureFileWrite = iFileWrite('b.txt') - impureFileWrite2 = iFileWrite('c.txt') - impureFileReadAgain = iFileRead('d.txt') - result = (impureFileReadAgain) + (2) diff --git a/packages/ttsl-lang/tests/resources/generation/partial/impure dependency file parameter/generated/tests/generator/partialImpureDependencyFileParameter/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/partial/impure dependency file parameter/generated/tests/generator/partialImpureDependencyFileParameter/gen_input.py.map deleted file mode 100644 index 62ef76a7..00000000 --- a/packages/ttsl-lang/tests/resources/generation/partial/impure dependency file parameter/generated/tests/generator/partialImpureDependencyFileParameter/gen_input.py.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"sources":["input.ttsl"],"names":["testpipeline","ifilewrite","ifileread","impurefilereadagain"],"mappings":"AAAA;;AAMA,IAASA,YAAY;IAEjB,kBAAsBC,UAAU,CAAC,OAAO;IACxC,mBAAuBA,UAAU,CAAC,OAAO;IACzC,sBAA0BC,SAAS,CAAC,OAAO;IAG3C,SAAe,CAAAC,mBAAmB,EAAC,CAAC,EAAC,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/partial/impure dependency file parameter/generated/tests/generator/partialImpureDependencyFileParameter/gen_input_testPipeline.py b/packages/ttsl-lang/tests/resources/generation/partial/impure dependency file parameter/generated/tests/generator/partialImpureDependencyFileParameter/gen_input_testPipeline.py deleted file mode 100644 index 09ca7590..00000000 --- a/packages/ttsl-lang/tests/resources/generation/partial/impure dependency file parameter/generated/tests/generator/partialImpureDependencyFileParameter/gen_input_testPipeline.py +++ /dev/null @@ -1,4 +0,0 @@ -from .gen_input import testPipeline - -if __name__ == '__main__': - testPipeline() diff --git a/packages/ttsl-lang/tests/resources/generation/partial/impure dependency file parameter/input.sdstest b/packages/ttsl-lang/tests/resources/generation/partial/impure dependency file parameter/input.sdstest deleted file mode 100644 index 37b3816a..00000000 --- a/packages/ttsl-lang/tests/resources/generation/partial/impure dependency file parameter/input.sdstest +++ /dev/null @@ -1,15 +0,0 @@ -package tests.generator.partialImpureDependencyFileParameter - -@Impure([ImpurityReason.FileReadFromParameterizedPath("path")]) fun iFileRead(path: String) -> q: Int - -@Impure([ImpurityReason.FileWriteToParameterizedPath("path")]) fun iFileWrite(path: String) -> q: Int - -pipeline testPipeline { - val impureFileRead = iFileRead("a.txt"); // Should not be generated - cannot affect result - val impureFileWrite = iFileWrite("b.txt"); - val impureFileWrite2 = iFileWrite("c.txt"); - val impureFileReadAgain = iFileRead("d.txt"); - - // $TEST$ run_until - val »result« = impureFileReadAgain + 2; -} diff --git a/packages/ttsl-lang/tests/resources/generation/partial/impure dependency/generated/tests/generator/partialImpureDependency/gen_input.py b/packages/ttsl-lang/tests/resources/generation/partial/impure dependency/generated/tests/generator/partialImpureDependency/gen_input.py deleted file mode 100644 index 83774fb0..00000000 --- a/packages/ttsl-lang/tests/resources/generation/partial/impure dependency/generated/tests/generator/partialImpureDependency/gen_input.py +++ /dev/null @@ -1,18 +0,0 @@ -# Pipelines -------------------------------------------------------------------- - -def testPipeline(): - i1(1) - impureFileWrite = iFileWrite() - impureFileWrite2 = iFileWrite() - pureValueForImpure2 = noPartialEvalInt(2) - pureValueForImpure3 = 3 - def __gen_block_lambda_0(): - i1(1) - __gen_block_lambda_result_r = 1 - return __gen_block_lambda_result_r - fp(__gen_block_lambda_0) - i1(1) - impureA1 = i1(pureValueForImpure2) - impureA2 = i1(noPartialEvalInt(3)) - i1(4) - result = i1(impureA2) diff --git a/packages/ttsl-lang/tests/resources/generation/partial/impure dependency/generated/tests/generator/partialImpureDependency/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/partial/impure dependency/generated/tests/generator/partialImpureDependency/gen_input.py.map deleted file mode 100644 index 5dd9271d..00000000 --- a/packages/ttsl-lang/tests/resources/generation/partial/impure dependency/generated/tests/generator/partialImpureDependency/gen_input.py.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"sources":["input.ttsl"],"names":["testpipeline","i1","ifilewrite","nopartialevalint","r","fp","purevalueforimpure2","purevalueforimpure3","impurea2"],"mappings":"AAAA;;AAeA,IAASA,YAAY;IACjBC,EAAE,CAAC,CAAC;IAGJ,kBAAsBC,UAAU;IAChC,mBAAuBA,UAAU;IAEjC,sBAA0BC,gBAAgB,CAAC,CAAC;IAC5C,sBAA0B,CAAC;IAExB;QACCF,EAAE,CAAC,CAAC;QACJ,0BAAMG,CAAC,GAAG,CAAC;QAFZ,OAEC,0BAAMA,CAAC;IAFXC,EAAE,CAAC;IAIHJ,EAAE,CAAC,CAAC;IACJ,WAAeA,EAAE,CAACK,mBAAmB;IACrC,WAAeL,EAAE,CAACE,gBAAgB,CAACI,CAAmB;IACtDN,EAAE,CAAC,CAAC;IAGJ,SAAeA,EAAE,CAACO,QAAQ","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/partial/impure dependency/generated/tests/generator/partialImpureDependency/gen_input_testPipeline.py b/packages/ttsl-lang/tests/resources/generation/partial/impure dependency/generated/tests/generator/partialImpureDependency/gen_input_testPipeline.py deleted file mode 100644 index 09ca7590..00000000 --- a/packages/ttsl-lang/tests/resources/generation/partial/impure dependency/generated/tests/generator/partialImpureDependency/gen_input_testPipeline.py +++ /dev/null @@ -1,4 +0,0 @@ -from .gen_input import testPipeline - -if __name__ == '__main__': - testPipeline() diff --git a/packages/ttsl-lang/tests/resources/generation/partial/impure dependency/input.sdstest b/packages/ttsl-lang/tests/resources/generation/partial/impure dependency/input.sdstest deleted file mode 100644 index 8843682b..00000000 --- a/packages/ttsl-lang/tests/resources/generation/partial/impure dependency/input.sdstest +++ /dev/null @@ -1,39 +0,0 @@ -package tests.generator.partialImpureDependency - -@Impure([ - ImpurityReason.PotentiallyImpureParameterCall("param"), -]) -fun fp(param: () -> r: Int) -> q: Int - -@Pure fun noPartialEvalInt(param: Int) -> q: Int - -@Impure([ImpurityReason.Other]) fun i1(param: Any?) -> q: Int - -@Impure([ImpurityReason.FileReadFromConstantPath("a.txt")]) fun iFileRead() -> q: Int - -@Impure([ImpurityReason.FileWriteToConstantPath("a.txt")]) fun iFileWrite() -> q: Int - -pipeline testPipeline { - i1(1); - - val impureFileRead = iFileRead(); // Should not be generated - cannot affect result - val impureFileWrite = iFileWrite(); - val impureFileWrite2 = iFileWrite(); - - val pureValueForImpure2 = noPartialEvalInt(2); - val pureValueForImpure3 = 3; - - fp(() { - i1(1); - yield r = 1; - }); - i1(1); - val impureA1 = i1(pureValueForImpure2); - val impureA2 = i1(noPartialEvalInt(pureValueForImpure3)); - i1(4); - - // $TEST$ run_until - val »result« = i1(impureA2); - i1(4); // Should not be generated - impure cannot affect result after result is already calculated - val someImpureValue = i1(4); // Should not be generated - impure cannot affect result after result is already calculated -} diff --git a/packages/ttsl-lang/tests/resources/generation/partial/pure dependency/generated/tests/generator/partialPureDependency/gen_input.py b/packages/ttsl-lang/tests/resources/generation/partial/pure dependency/generated/tests/generator/partialPureDependency/gen_input.py deleted file mode 100644 index 081abea7..00000000 --- a/packages/ttsl-lang/tests/resources/generation/partial/pure dependency/generated/tests/generator/partialPureDependency/gen_input.py +++ /dev/null @@ -1,28 +0,0 @@ -# Pipelines -------------------------------------------------------------------- - -def testPipeline(): - lFalse = False - lDouble = -1.0 - lInt = 1 - lNull = None - lStrMulti = 'multi\nline' - boolean1 = True - value1 = g(True, -1.0, 1, None, 'multi\nline') - def __gen_block_lambda_0(): - i = 1 - i2 = 3 - j = 6 - j2 = 4 - __gen_block_lambda_result_z = 7 - return __gen_block_lambda_result_z - o = (f(__gen_block_lambda_0)) + (f(lambda : 2)) - mapKey = 'key' - mapValue = 'value' - mapResult = g2({'key': 'value'}) - listV1 = 1 - listV3 = noPartialEvalInt(1) - list = [1] - list3 = [listV3] - listValue = list3[0] - listResult = g3(list) - result = (((-(o)) + (1)) + (value1)) + (((mapResult) * (listResult)) / (g4(listValue))) diff --git a/packages/ttsl-lang/tests/resources/generation/partial/pure dependency/generated/tests/generator/partialPureDependency/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/partial/pure dependency/generated/tests/generator/partialPureDependency/gen_input.py.map deleted file mode 100644 index 98140f46..00000000 --- a/packages/ttsl-lang/tests/resources/generation/partial/pure dependency/generated/tests/generator/partialPureDependency/gen_input.py.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"sources":["input.ttsl"],"names":["testpipeline","false","null","g","boolean1","ldouble","lint","lnull","lstrmulti","z","f","g2","mapkey","mapvalue","nopartialevalint","listv1","listv3","list3","g3","list","o","value1","mapresult","listresult","g4","listvalue"],"mappings":"AAAA;;AAcA,IAASA,YAAY;IACjB,SAAaC,KAAK;IAGlB,UAAc,IAAI;IAGlB,OAAW,CAAC;IAGZ,QAAYC,IAAI;IAGhB,YAAgB;IAIhB,WAAe;IAGf,SAAaC,CAAC,CAACC,IAAQ,EAAEC,IAAO,EAAEC,CAAI,EAAEC,IAAK,EAAEC,aAAS;IAG9C;QACN,IAAQ,CAAC;QACT,KAAS,CAAC;QACV,IAAQ;QACR,KAAS;QACT,0BAAMC,CAAC,GAAG;QALJ,OAKN,0BAAMA,CAAC;IALX,IAAQ,CAAAC,CAAC,CAAC,uBAMP,CAAC,EAACA,CAAC,CAAC,SAAM,CAAC;IAcd,SAAa,KAAK;IAClB,WAAe,OAAO;IACtB,YAAgBC,EAAE,CAAC,CAACC,KAAM,EAAEC,OAAQ;IAMpC,SAAa,CAAC;IAEd,SAAaC,gBAAgB,CAACC,CAAM;IAEpC,OAAW,CAACA,CAAM;IAElB,QAAY,CAACC,MAAM;IACnB,YAAgBC,KAAK,CAAC,CAAC;IAEvB,aAAiBC,EAAE,CAACC,IAAI;IAIxB,SAAe,CAAO,CAAP,CAAA,CAAC,CAAAC,CAAC,GAAC,CAAC,EAAC,CAAC,GAAC,CAAC,EAACC,MAAM,GAAC,CAAC,EAAwB,CAAvB,CAAAC,SAAS,EAAC,CAAC,EAACC,UAAU,GAAC,CAAC,EAACC,EAAE,CAACC,SAAS","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/partial/pure dependency/generated/tests/generator/partialPureDependency/gen_input_testPipeline.py b/packages/ttsl-lang/tests/resources/generation/partial/pure dependency/generated/tests/generator/partialPureDependency/gen_input_testPipeline.py deleted file mode 100644 index 09ca7590..00000000 --- a/packages/ttsl-lang/tests/resources/generation/partial/pure dependency/generated/tests/generator/partialPureDependency/gen_input_testPipeline.py +++ /dev/null @@ -1,4 +0,0 @@ -from .gen_input import testPipeline - -if __name__ == '__main__': - testPipeline() diff --git a/packages/ttsl-lang/tests/resources/generation/partial/pure dependency/input.sdstest b/packages/ttsl-lang/tests/resources/generation/partial/pure dependency/input.sdstest deleted file mode 100644 index 64a9cf85..00000000 --- a/packages/ttsl-lang/tests/resources/generation/partial/pure dependency/input.sdstest +++ /dev/null @@ -1,82 +0,0 @@ -package tests.generator.partialPureDependency - -@Pure fun f(param: () -> r: Int) -> q: Int - -@Pure fun g(h: Boolean, i: Float, j: Int, k: Any?, l: String) -> q: Int - -@Pure fun g2(param: Map) -> q: Int - -@Pure fun g3(param: List) -> q: Int - -@Pure fun noPartialEvalInt(param: Int) -> q: Int - -@Pure fun g4(param: Any?) -> q: Int - -pipeline testPipeline { - val lFalse = false; - val lTrue = true; // Should not be generated - - val lDouble = -1.0; - val lDouble2 = 1.0; // Should not be generated - - val lInt = 1; - val lInt2 = -1; // Should not be generated - - val lNull = null; - val lNull2 = null; // Should not be generated - - val lStrMulti = "multi -line"; - val lStr = ""; // Should not be generated - - val boolean1 = not lFalse; - val boolean2 = not lTrue; // Should not be generated - - val value1 = g(boolean1, lDouble, lInt, lNull, lStrMulti); - val value2 = g(boolean2, lDouble2, lInt2, lNull2, lStr); // Should not be generated - - val o = f(() { - val i = 1; - val i2 = 3; - val j = i + 5; - val j2 = i2 + i; - yield z = j + i; - }) + f(() -> 2); - - // Should not be generated - val o2 = f(() { - val i = 1; - val i2 = 3; - val j = i + 5; - val j2 = i2 + i; - yield z = j + i; - }) + f(() -> 2); - - 1; // Should not be generated - _ = 1; // Should not be generated - - val mapKey = "key"; - val mapValue = "value"; - val mapResult = g2({mapKey: mapValue}); - - val mapKey2 = "key"; // Should not be generated - val mapValue2 = "value"; // Should not be generated - val mapResult2 = g2({mapKey2: mapValue2}); // Should not be generated - - val listV1 = 1; - val listV2 = 2; // Should not be generated - val listV3 = noPartialEvalInt(listV1); - - val list = [listV1]; - val list2 = [listV2]; // Should not be generated - val list3 = [listV3]; - val listValue = list3[0]; - - val listResult = g3(list); - val listResult2 = g3(list2); // Should not be generated - - // $TEST$ run_until - val »result« = -o + 1 + value1 + mapResult * listResult / g4(listValue); - - val lDouble3 = 1.0; // Should not be generated - pure cannot affect result after result is already calculated -} diff --git a/packages/ttsl-lang/tests/resources/generation/partial/redundant impurity/generated/tests/generator/partialRedundantImpurity/gen_input.py b/packages/ttsl-lang/tests/resources/generation/partial/redundant impurity/generated/tests/generator/partialRedundantImpurity/gen_input.py deleted file mode 100644 index a6b84a0c..00000000 --- a/packages/ttsl-lang/tests/resources/generation/partial/redundant impurity/generated/tests/generator/partialRedundantImpurity/gen_input.py +++ /dev/null @@ -1,5 +0,0 @@ -# Pipelines -------------------------------------------------------------------- - -def testPipeline(): - pureValue = noPartialEvalInt(2) - result = (pureValue) - (1) diff --git a/packages/ttsl-lang/tests/resources/generation/partial/redundant impurity/generated/tests/generator/partialRedundantImpurity/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/partial/redundant impurity/generated/tests/generator/partialRedundantImpurity/gen_input.py.map deleted file mode 100644 index 373d097f..00000000 --- a/packages/ttsl-lang/tests/resources/generation/partial/redundant impurity/generated/tests/generator/partialRedundantImpurity/gen_input.py.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"sources":["input.ttsl"],"names":["testpipeline","nopartialevalint","purevalue"],"mappings":"AAAA;;AAeA,IAASA,YAAY;IAMjB,YAAgBC,gBAAgB,CAAC,CAAC;IAalC,SAAe,CAAAC,SAAS,EAAC,CAAC,EAAC,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/partial/redundant impurity/generated/tests/generator/partialRedundantImpurity/gen_input_testPipeline.py b/packages/ttsl-lang/tests/resources/generation/partial/redundant impurity/generated/tests/generator/partialRedundantImpurity/gen_input_testPipeline.py deleted file mode 100644 index 09ca7590..00000000 --- a/packages/ttsl-lang/tests/resources/generation/partial/redundant impurity/generated/tests/generator/partialRedundantImpurity/gen_input_testPipeline.py +++ /dev/null @@ -1,4 +0,0 @@ -from .gen_input import testPipeline - -if __name__ == '__main__': - testPipeline() diff --git a/packages/ttsl-lang/tests/resources/generation/partial/redundant impurity/input.sdstest b/packages/ttsl-lang/tests/resources/generation/partial/redundant impurity/input.sdstest deleted file mode 100644 index 16cce682..00000000 --- a/packages/ttsl-lang/tests/resources/generation/partial/redundant impurity/input.sdstest +++ /dev/null @@ -1,38 +0,0 @@ -package tests.generator.partialRedundantImpurity - -@Impure([ - ImpurityReason.PotentiallyImpureParameterCall("param"), -]) -fun fp(param: () -> r: Int) -> q: Int - -@Pure fun noPartialEvalInt(param: Int) -> q: Int - -@Impure([ImpurityReason.Other]) fun i1(param: Any?) -> q: Int - -@Impure([ImpurityReason.FileReadFromConstantPath("a.txt")]) fun iFileRead() -> q: Int - -@Impure([ImpurityReason.FileWriteToConstantPath("a.txt")]) fun iFileWrite() -> q: Int - -pipeline testPipeline { - val impureFileRead = iFileRead(); // Should not be generated - cannot affect result - val impureFileWrite = iFileWrite(); // Should not be generated - cannot affect result - val impureFileWrite2 = iFileWrite(); // Should not be generated - cannot affect result - val impureFileReadAgain = iFileRead(); // Should not be generated - cannot affect result - - val pureValue = noPartialEvalInt(2); - val pureValueForImpure3 = 3; // Should not be generated - cannot affect result - - fp(() { - i1(1); - yield r = 1; - }); // Should not be generated - cannot affect result - i1(1); // Should not be generated - cannot affect result - val impureA1 = i1(pureValue); // Should not be generated - cannot affect result - val impureA2 = i1(noPartialEvalInt(pureValueForImpure3)); // Should not be generated - cannot affect result - i1(4); // Should not be generated - impure can not have effects on future statements as they are pure - - // $TEST$ run_until - val »result« = pureValue - 1; - i1(4); // Should not be generated - impure cannot affect result after result is already calculated - val someImpureValue = i1(4); // Should not be generated - impure cannot affect result after result is already calculated -} diff --git a/packages/ttsl-lang/tests/resources/generation/python module/generated/special_module/gen_input.py b/packages/ttsl-lang/tests/resources/generation/python module/generated/special_module/gen_input.py deleted file mode 100644 index eab6391b..00000000 --- a/packages/ttsl-lang/tests/resources/generation/python module/generated/special_module/gen_input.py +++ /dev/null @@ -1,4 +0,0 @@ -# Segments --------------------------------------------------------------------- - -def test(): - f() diff --git a/packages/ttsl-lang/tests/resources/generation/python module/generated/special_module/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/python module/generated/special_module/gen_input.py.map deleted file mode 100644 index 33a03492..00000000 --- a/packages/ttsl-lang/tests/resources/generation/python module/generated/special_module/gen_input.py.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"sources":["input.ttsl"],"names":["test","f"],"mappings":"AAAA;;AAMA,IAAQA,IAAI;IACRC,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/python module/input.sdstest b/packages/ttsl-lang/tests/resources/generation/python module/input.sdstest deleted file mode 100644 index 9d1cea8e..00000000 --- a/packages/ttsl-lang/tests/resources/generation/python module/input.sdstest +++ /dev/null @@ -1,9 +0,0 @@ -@PythonModule("special_module") - -package tests.generator.pythonModule - -@Impure([ImpurityReason.Other]) fun f() - -segment test() { - f(); -} diff --git a/packages/ttsl-lang/tests/resources/generation/runner integration/expressions/call/generated/tests/generator/callWithRunnerIntegration/gen_input.py b/packages/ttsl-lang/tests/resources/generation/runner integration/expressions/call/generated/tests/generator/callWithRunnerIntegration/gen_input.py deleted file mode 100644 index d5934f0c..00000000 --- a/packages/ttsl-lang/tests/resources/generation/runner integration/expressions/call/generated/tests/generator/callWithRunnerIntegration/gen_input.py +++ /dev/null @@ -1,57 +0,0 @@ -# Imports ---------------------------------------------------------------------- - -import TTSL_runner -from typing import Any, Callable, TypeVar - -# Type variables --------------------------------------------------------------- - -__gen_T = TypeVar("__gen_T") - -# Utils ------------------------------------------------------------------------ - -def __gen_null_safe_call(receiver: Any, callable: Callable[[], __gen_T]) -> __gen_T | None: - return callable() if receiver is not None else None - -# Segments --------------------------------------------------------------------- - -def segment_a(a): - __gen_yield_result = (a) * (2) - return __gen_yield_result - -# Pipelines -------------------------------------------------------------------- - -def test(): - f(TTSL_runner.memoized_call("tests.generator.callWithRunnerIntegration.g", lambda *_ : g(1, param2=2), [1, 2], [])) - f(TTSL_runner.memoized_call("tests.generator.callWithRunnerIntegration.g", lambda *_ : g(2, param2=1), [2, 1], [])) - f(TTSL_runner.memoized_call("tests.generator.callWithRunnerIntegration.h", lambda *_ : h(1, param_2=2), [1, 2], [])) - f(TTSL_runner.memoized_call("tests.generator.callWithRunnerIntegration.h", lambda *_ : h(2, param_2=1), [2, 1], [])) - f(TTSL_runner.memoized_call("tests.generator.callWithRunnerIntegration.h", h, [2, 0], [])) - 'abc'.i() - 'abc'.j(123) - k(456, 1.23) - __gen_null_safe_call(f, lambda: f(TTSL_runner.memoized_call("tests.generator.callWithRunnerIntegration.g", lambda *_ : g(1, param2=2), [1, 2], []))) - __gen_null_safe_call(f, lambda: f(TTSL_runner.memoized_call("tests.generator.callWithRunnerIntegration.g", lambda *_ : g(2, param2=1), [2, 1], []))) - __gen_null_safe_call(f, lambda: f(TTSL_runner.memoized_call("tests.generator.callWithRunnerIntegration.h", lambda *_ : h(1, param_2=2), [1, 2], []))) - __gen_null_safe_call(f, lambda: f(TTSL_runner.memoized_call("tests.generator.callWithRunnerIntegration.h", lambda *_ : h(2, param_2=1), [2, 1], []))) - __gen_null_safe_call(f, lambda: f(TTSL_runner.memoized_call("tests.generator.callWithRunnerIntegration.h", h, [2, 0], []))) - __gen_null_safe_call(i, lambda: 'abc'.i()) - __gen_null_safe_call(j, lambda: 'abc'.j(123)) - __gen_null_safe_call(k, lambda: k(456, 1.23)) - f(TTSL_runner.memoized_call("tests.generator.callWithRunnerIntegration.readFile", readFile, [], [TTSL_runner.file_mtime('a.txt')])) - f(l(lambda a: segment_a(a))) - f(l(lambda a: (3) * (segment_a(a)))) - f(l(lambda a: TTSL_runner.memoized_call("tests.generator.callWithRunnerIntegration.m", m, [(3) * (segment_a(a))], []))) - f(l(lambda a: (3) * (TTSL_runner.memoized_call("tests.generator.callWithRunnerIntegration.m", m, [TTSL_runner.memoized_call("tests.generator.callWithRunnerIntegration.m", m, [(3) * (segment_a(a))], [])], [])))) - def __gen_block_lambda_0(a): - __gen_block_lambda_result_result = segment_a(a) - return __gen_block_lambda_result_result - f(l(__gen_block_lambda_0)) - def __gen_block_lambda_1(a): - __gen_block_lambda_result_result = TTSL_runner.memoized_call("tests.generator.callWithRunnerIntegration.m", m, [segment_a(a)], []) - return __gen_block_lambda_result_result - f(l(__gen_block_lambda_1)) - f(TTSL_runner.memoized_call("tests.generator.callWithRunnerIntegration.l", l, [lambda a: (3) * (a)], [])) - def __gen_block_lambda_2(a): - __gen_block_lambda_result_result = (3) * (TTSL_runner.memoized_call("tests.generator.callWithRunnerIntegration.m", m, [a], [])) - return __gen_block_lambda_result_result - f(TTSL_runner.memoized_call("tests.generator.callWithRunnerIntegration.l", l, [__gen_block_lambda_2], [])) diff --git a/packages/ttsl-lang/tests/resources/generation/runner integration/expressions/call/generated/tests/generator/callWithRunnerIntegration/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/runner integration/expressions/call/generated/tests/generator/callWithRunnerIntegration/gen_input.py.map deleted file mode 100644 index 974ca873..00000000 --- a/packages/ttsl-lang/tests/resources/generation/runner integration/expressions/call/generated/tests/generator/callWithRunnerIntegration/gen_input.py.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"sources":["input.ttsl"],"names":["segment_a","a","result","test","f","g","param2","h","i","j","k","readfile","l","m"],"mappings":"AAAA;;;;;;;;;;;;;;;;AAiEA,IAAQA,SAAS,CAACC,CAAC;IACf,YAAMC,MAAM,GAAG,CAAAD,CAAC,EAAC,CAAC,EAAC,CAAC;IADE,OAAG;;;;AA9B7B,IAASE,IAAI;IACTC,CAAC,CAAE,uFAAAC,CAAC,CAAC,CAAC,EA9BNC,MAAM,CA8BE,CAAC,IAAJ,CAAC,EAAE,CAAC;IACTF,CAAC,CAAE,uFAAAC,CAAC,CAAsB,CAAC,EA/B3BC,MAAM,CA+BQ,CAAC,IAAW,CAAC,EAAb,CAAC;IACfF,CAAC,CAAE,uFAAAG,CAAC,CAAC,CAAC,EA3BiBD,OAAM,CA2BrB,CAAC,IAAJ,CAAC,EAAE,CAAC;IACTF,CAAC,CAAE,uFAAAG,CAAC,CAAsB,CAAC,EA5BJD,OAAM,CA4Bf,CAAC,IAAW,CAAC,EAAb,CAAC;IACfF,CAAC,CAAE,2EAAAG,CAAC,GAAU,CAAC,EA7BsB,CAAC;IA8BpC,KAAK;IACL,KAAK,GAAE,GAAG;IACZ,EAAQ,GAAG,EAAT,IAAI;IAEL,oBAAC,CAAFH,CAAC,UAADA,CAAC,CAAG,uFAAAC,CAAC,CAAC,CAAC,EAvCPC,MAAM,CAuCG,CAAC,IAAJ,CAAC,EAAE,CAAC;IACT,oBAAC,CAAFF,CAAC,UAADA,CAAC,CAAG,uFAAAC,CAAC,CAAsB,CAAC,EAxC5BC,MAAM,CAwCS,CAAC,IAAW,CAAC,EAAb,CAAC;IACf,oBAAC,CAAFF,CAAC,UAADA,CAAC,CAAG,uFAAAG,CAAC,CAAC,CAAC,EApCgBD,OAAM,CAoCpB,CAAC,IAAJ,CAAC,EAAE,CAAC;IACT,oBAAC,CAAFF,CAAC,UAADA,CAAC,CAAG,uFAAAG,CAAC,CAAsB,CAAC,EArCLD,OAAM,CAqCd,CAAC,IAAW,CAAC,EAAb,CAAC;IACf,oBAAC,CAAFF,CAAC,UAADA,CAAC,CAAG,2EAAAG,CAAC,GAAU,CAAC,EAtCqB,CAAC;IAuCrC,oBAAC,CAAFC,CAAC,UAAE,KAAK;IACP,oBAAC,CAAFC,CAAC,UAAE,KAAK,GAAE,GAAG;IACZ,oBAAC,CAAFC,CAAC,UAAD,EAAS,GAAG,EAAT,IAAI;IAEPN,CAAC,CAAC,kFAAAO,QAAQ,OAAR,iCAAU;IACZP,CAAC,CAACQ,CAAC,CAAC,OAACX,CAAC,EAAKD,SAAS,CAACC,CAAC;IACtBG,CAAC,CAACQ,CAAC,CAAC,OAACX,CAAC,EAAK,CAAA,CAAC,EAAC,CAAC,EAACD,SAAS,CAACC,CAAC;IAC1BG,CAAC,CAACQ,CAAC,CAAC,OAACX,CAAC,EAAK,2EAAAY,CAAC,GAAC,CAAA,CAAC,EAAC,CAAC,EAACb,SAAS,CAACC,CAAC;IAC5BG,CAAC,CAACQ,CAAC,CAAC,OAACX,CAAC,EAAK,CAAA,CAAC,EAAC,CAAC,EAAC,2EAAAY,CAAC,GAAC,2EAAAA,CAAC,GAAC,CAAA,CAAC,EAAC,CAAC,EAACb,SAAS,CAACC,CAAC;IAC9B,yBAACA,CAAC;QAAG,0BAAMC,MAAM,GAAGF,SAAS,CAACC,CAAC;QAA/B,OAAK,0BAAMC,MAAM;IAArBE,CAAC,CAACQ,CAAC,CAAC;IACA,yBAACX,CAAC;QAAG,0BAAMC,MAAM,GAAG,2EAAAW,CAAC,GAACb,SAAS,CAACC,CAAC;QAAjC,OAAK,0BAAMC,MAAM;IAArBE,CAAC,CAACQ,CAAC,CAAC;IACJR,CAAC,CAAC,2EAAAQ,CAAC,GAAC,OAACX,CAAC,EAAK,CAAA,CAAC,EAAC,CAAC,EAACA,CAAC;IACZ,yBAACA,CAAC;QAAG,0BAAMC,MAAM,GAAG,CAAA,CAAC,EAAC,CAAC,EAAC,2EAAAW,CAAC,GAACZ,CAAC;QAA3B,OAAK,0BAAMC,MAAM;IAArBE,CAAC,CAAC,2EAAAQ,CAAC,GAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/runner integration/expressions/call/generated/tests/generator/callWithRunnerIntegration/gen_input_test.py b/packages/ttsl-lang/tests/resources/generation/runner integration/expressions/call/generated/tests/generator/callWithRunnerIntegration/gen_input_test.py deleted file mode 100644 index 824f70b1..00000000 --- a/packages/ttsl-lang/tests/resources/generation/runner integration/expressions/call/generated/tests/generator/callWithRunnerIntegration/gen_input_test.py +++ /dev/null @@ -1,4 +0,0 @@ -from .gen_input import test - -if __name__ == '__main__': - test() diff --git a/packages/ttsl-lang/tests/resources/generation/runner integration/expressions/call/input.sdstest b/packages/ttsl-lang/tests/resources/generation/runner integration/expressions/call/input.sdstest deleted file mode 100644 index 8bd19d79..00000000 --- a/packages/ttsl-lang/tests/resources/generation/runner integration/expressions/call/input.sdstest +++ /dev/null @@ -1,68 +0,0 @@ -package tests.generator.callWithRunnerIntegration - -@Impure([ImpurityReason.Other]) fun f(param: Any?) - -@Pure fun g( - param1: Int, - param2: Int = 0 -) -> result: Boolean - -@Pure fun h( - @PythonName("param_1") param1: Int, - @PythonName("param_2") param2: Int = 0 -) -> result: Boolean - -@Impure([ImpurityReason.Other]) -@PythonCall("$param.i()") -fun i(param: Any?) - -@Impure([ImpurityReason.Other]) -@PythonCall("$param.j($param2)") -fun j(param: Any?, param2: Any?) - -@Impure([ImpurityReason.Other]) -@PythonCall("k($param2, $param)") -fun k(param: Any?, param2: Any?) - -@Pure -fun l(param: (a: Int) -> result: Int) -> result: Int - -@Pure -fun m(param: Int) -> result: Int - -@Impure([ImpurityReason.FileReadFromConstantPath("a.txt")]) -fun readFile() -> content: String - -pipeline test { - f((g(1, 2))); - f((g(param2 = 1, param1 = 2))); - f((h(1, 2))); - f((h(param2 = 1, param1 = 2))); - f((h(param1 = 2))); - i("abc"); - j("abc", 123); - k(1.23, 456); - - f?((g(1, 2))); - f?((g(param2 = 1, param1 = 2))); - f?((h(1, 2))); - f?((h(param2 = 1, param1 = 2))); - f?((h(param1 = 2))); - i?("abc"); - j?("abc", 123); - k?(1.23, 456); - - f(readFile()); - f(l((a) -> segment_a(a))); - f(l((a) -> 3 * segment_a(a))); - f(l((a) -> m(3 * segment_a(a)))); - f(l((a) -> 3 * m(m(3 * segment_a(a))))); - f(l((a) {yield result = segment_a(a); })); - f(l((a) {yield result = m(segment_a(a)); })); - f(l((a) -> 3 * a)); - f(l((a) {yield result = 3 * m(a); })); -} - -segment segment_a(a: Int) -> result: Int { - yield result = a * 2; -} diff --git a/packages/ttsl-lang/tests/resources/generation/runner integration/imports/general/context different package.sdsstub b/packages/ttsl-lang/tests/resources/generation/runner integration/imports/general/context different package.sdsstub deleted file mode 100644 index 45cb07d0..00000000 --- a/packages/ttsl-lang/tests/resources/generation/runner integration/imports/general/context different package.sdsstub +++ /dev/null @@ -1,4 +0,0 @@ -package tests.generator.differentPackageWithRunnerIntegration - -@Pure fun function1InDifferentPackage() -> result: Int -@Pure fun function2InDifferentPackage() -> result: Int diff --git a/packages/ttsl-lang/tests/resources/generation/runner integration/imports/general/context package with python module.sdsstub b/packages/ttsl-lang/tests/resources/generation/runner integration/imports/general/context package with python module.sdsstub deleted file mode 100644 index c745a790..00000000 --- a/packages/ttsl-lang/tests/resources/generation/runner integration/imports/general/context package with python module.sdsstub +++ /dev/null @@ -1,6 +0,0 @@ -@PythonModule("special_location") - -package tests.generator.withPythonModuleWithRunnerIntegration - -@Pure fun function1InCompilationUnitWithPythonModule() -> result: Int -@Pure fun function2InCompilationUnitWithPythonModule() -> result: Int diff --git a/packages/ttsl-lang/tests/resources/generation/runner integration/imports/general/context same package.sdstest b/packages/ttsl-lang/tests/resources/generation/runner integration/imports/general/context same package.sdstest deleted file mode 100644 index 30c167d5..00000000 --- a/packages/ttsl-lang/tests/resources/generation/runner integration/imports/general/context same package.sdstest +++ /dev/null @@ -1,11 +0,0 @@ -package tests.generator.importsWithRunnerIntegration - -@Pure fun impureFunction() -> result: Int - -segment segment1InSamePackage() -> result: Int { - yield result = impureFunction(); -} - -segment segment2InSamePackage() -> result: Int { - yield result = impureFunction(); -} diff --git a/packages/ttsl-lang/tests/resources/generation/runner integration/imports/general/generated/tests/generator/importsWithRunnerIntegration/gen_context_same_package.py b/packages/ttsl-lang/tests/resources/generation/runner integration/imports/general/generated/tests/generator/importsWithRunnerIntegration/gen_context_same_package.py deleted file mode 100644 index 36b5d886..00000000 --- a/packages/ttsl-lang/tests/resources/generation/runner integration/imports/general/generated/tests/generator/importsWithRunnerIntegration/gen_context_same_package.py +++ /dev/null @@ -1,13 +0,0 @@ -# Imports ---------------------------------------------------------------------- - -import TTSL_runner - -# Segments --------------------------------------------------------------------- - -def segment1InSamePackage(): - __gen_yield_result = TTSL_runner.memoized_call("tests.generator.importsWithRunnerIntegration.impureFunction", impureFunction, [], []) - return __gen_yield_result - -def segment2InSamePackage(): - __gen_yield_result = TTSL_runner.memoized_call("tests.generator.importsWithRunnerIntegration.impureFunction", impureFunction, [], []) - return __gen_yield_result diff --git a/packages/ttsl-lang/tests/resources/generation/runner integration/imports/general/generated/tests/generator/importsWithRunnerIntegration/gen_context_same_package.py.map b/packages/ttsl-lang/tests/resources/generation/runner integration/imports/general/generated/tests/generator/importsWithRunnerIntegration/gen_context_same_package.py.map deleted file mode 100644 index f11ab0cb..00000000 --- a/packages/ttsl-lang/tests/resources/generation/runner integration/imports/general/generated/tests/generator/importsWithRunnerIntegration/gen_context_same_package.py.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"sources":["context same package.ttsl"],"names":["segment1insamepackage","result","impurefunction","segment2insamepackage"],"mappings":"AAAA;;;;;;AAIA,IAAQA,qBAAqB;IACzB,YAAMC,MAAM,GAAG,2FAAAC,cAAc;IADD,OAAG;;AAInC,IAAQC,qBAAqB;IACzB,YAAMF,MAAM,GAAG,2FAAAC,cAAc;IADD,OAAG","file":"gen_context_same_package.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/runner integration/imports/general/generated/tests/generator/importsWithRunnerIntegration/gen_input.py b/packages/ttsl-lang/tests/resources/generation/runner integration/imports/general/generated/tests/generator/importsWithRunnerIntegration/gen_input.py deleted file mode 100644 index 1033a29a..00000000 --- a/packages/ttsl-lang/tests/resources/generation/runner integration/imports/general/generated/tests/generator/importsWithRunnerIntegration/gen_input.py +++ /dev/null @@ -1,22 +0,0 @@ -# Imports ---------------------------------------------------------------------- - -import TTSL_runner -from special_location import function1InCompilationUnitWithPythonModule, function2InCompilationUnitWithPythonModule as h -from tests.generator.differentPackageWithRunnerIntegration import function1InDifferentPackage, function2InDifferentPackage as g -from tests.generator.importsWithRunnerIntegration.gen_context_same_package import segment1InSamePackage, segment2InSamePackage - -# Pipelines -------------------------------------------------------------------- - -def test(): - f(segment1InSamePackage()) - f(segment1InSamePackage()) - f(segment2InSamePackage()) - f(segment2InSamePackage()) - f(TTSL_runner.memoized_call("tests.generator.differentPackageWithRunnerIntegration.function1InDifferentPackage", function1InDifferentPackage, [], [])) - f(TTSL_runner.memoized_call("tests.generator.differentPackageWithRunnerIntegration.function1InDifferentPackage", function1InDifferentPackage, [], [])) - f(TTSL_runner.memoized_call("tests.generator.differentPackageWithRunnerIntegration.function2InDifferentPackage", g, [], [])) - f(TTSL_runner.memoized_call("tests.generator.differentPackageWithRunnerIntegration.function2InDifferentPackage", g, [], [])) - f(TTSL_runner.memoized_call("special_location.function1InCompilationUnitWithPythonModule", function1InCompilationUnitWithPythonModule, [], [])) - f(TTSL_runner.memoized_call("special_location.function1InCompilationUnitWithPythonModule", function1InCompilationUnitWithPythonModule, [], [])) - f(TTSL_runner.memoized_call("special_location.function2InCompilationUnitWithPythonModule", h, [], [])) - f(TTSL_runner.memoized_call("special_location.function2InCompilationUnitWithPythonModule", h, [], [])) diff --git a/packages/ttsl-lang/tests/resources/generation/runner integration/imports/general/generated/tests/generator/importsWithRunnerIntegration/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/runner integration/imports/general/generated/tests/generator/importsWithRunnerIntegration/gen_input.py.map deleted file mode 100644 index af8c402d..00000000 --- a/packages/ttsl-lang/tests/resources/generation/runner integration/imports/general/generated/tests/generator/importsWithRunnerIntegration/gen_input.py.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"sources":["input.ttsl"],"names":["test","f","segment1insamepackage","segment2insamepackage","function1indifferentpackage","g","function1incompilationunitwithpythonmodule","h"],"mappings":"AAAA;;;;;;;;;AASA,IAASA,IAAI;IACTC,CAAC,CAACC,qBAAqB;IACvBD,CAAC,CAACC,qBAAqB;IACvBD,CAAC,CAACE,qBAAqB;IACvBF,CAAC,CAACE,qBAAqB;IAEvBF,CAAC,CAAC,iHAAAG,2BAA2B;IAC7BH,CAAC,CAAC,iHAAAG,2BAA2B;IAC7BH,CAAC,CAAC,iHAAAI,CAAC;IACHJ,CAAC,CAAC,iHAAAI,CAAC;IAEHJ,CAAC,CAAC,2FAAAK,0CAA0C;IAC5CL,CAAC,CAAC,2FAAAK,0CAA0C;IAC5CL,CAAC,CAAC,2FAAAM,CAAC;IACHN,CAAC,CAAC,2FAAAM,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/runner integration/imports/general/generated/tests/generator/importsWithRunnerIntegration/gen_input_test.py b/packages/ttsl-lang/tests/resources/generation/runner integration/imports/general/generated/tests/generator/importsWithRunnerIntegration/gen_input_test.py deleted file mode 100644 index 824f70b1..00000000 --- a/packages/ttsl-lang/tests/resources/generation/runner integration/imports/general/generated/tests/generator/importsWithRunnerIntegration/gen_input_test.py +++ /dev/null @@ -1,4 +0,0 @@ -from .gen_input import test - -if __name__ == '__main__': - test() diff --git a/packages/ttsl-lang/tests/resources/generation/runner integration/imports/general/input.sdstest b/packages/ttsl-lang/tests/resources/generation/runner integration/imports/general/input.sdstest deleted file mode 100644 index abe663aa..00000000 --- a/packages/ttsl-lang/tests/resources/generation/runner integration/imports/general/input.sdstest +++ /dev/null @@ -1,25 +0,0 @@ -package tests.generator.importsWithRunnerIntegration - -from tests.generator.differentPackageWithRunnerIntegration import function1InDifferentPackage -from tests.generator.differentPackageWithRunnerIntegration import function2InDifferentPackage as g -from tests.generator.withPythonModuleWithRunnerIntegration import function1InCompilationUnitWithPythonModule -from tests.generator.withPythonModuleWithRunnerIntegration import function2InCompilationUnitWithPythonModule as h - -@Impure([ImpurityReason.Other]) fun f(param: Any?) - -pipeline test { - f(segment1InSamePackage()); - f(segment1InSamePackage()); - f(segment2InSamePackage()); - f(segment2InSamePackage()); - - f(function1InDifferentPackage()); - f(function1InDifferentPackage()); - f(g()); - f(g()); - - f(function1InCompilationUnitWithPythonModule()); - f(function1InCompilationUnitWithPythonModule()); - f(h()); - f(h()); -} diff --git a/packages/ttsl-lang/tests/resources/generation/runner integration/imports/wildcard/context different package.sdsstub b/packages/ttsl-lang/tests/resources/generation/runner integration/imports/wildcard/context different package.sdsstub deleted file mode 100644 index 0a1dee63..00000000 --- a/packages/ttsl-lang/tests/resources/generation/runner integration/imports/wildcard/context different package.sdsstub +++ /dev/null @@ -1,4 +0,0 @@ -package tests.generator.differentPackageWildcardWithRunnerIntegration - -@Pure fun function1InDifferentPackage() -> result: Int -@Pure fun function2InDifferentPackage() -> result: Int diff --git a/packages/ttsl-lang/tests/resources/generation/runner integration/imports/wildcard/context package with python module.sdsstub b/packages/ttsl-lang/tests/resources/generation/runner integration/imports/wildcard/context package with python module.sdsstub deleted file mode 100644 index 6cbdd53e..00000000 --- a/packages/ttsl-lang/tests/resources/generation/runner integration/imports/wildcard/context package with python module.sdsstub +++ /dev/null @@ -1,6 +0,0 @@ -@PythonModule("special_location") - -package tests.generator.withPythonModuleWildcardWithRunnerIntegration - -@Pure fun function1InCompilationUnitWithPythonModule() -> result: Int -@Pure fun function2InCompilationUnitWithPythonModule() -> result: Int diff --git a/packages/ttsl-lang/tests/resources/generation/runner integration/imports/wildcard/generated/tests/generator/wildcardWithRunnerIntegration/gen_input.py b/packages/ttsl-lang/tests/resources/generation/runner integration/imports/wildcard/generated/tests/generator/wildcardWithRunnerIntegration/gen_input.py deleted file mode 100644 index bc2595e7..00000000 --- a/packages/ttsl-lang/tests/resources/generation/runner integration/imports/wildcard/generated/tests/generator/wildcardWithRunnerIntegration/gen_input.py +++ /dev/null @@ -1,17 +0,0 @@ -# Imports ---------------------------------------------------------------------- - -import TTSL_runner -from special_location import function1InCompilationUnitWithPythonModule, function2InCompilationUnitWithPythonModule -from tests.generator.differentPackageWildcardWithRunnerIntegration import function1InDifferentPackage, function2InDifferentPackage - -# Pipelines -------------------------------------------------------------------- - -def test(): - f(TTSL_runner.memoized_call("tests.generator.differentPackageWildcardWithRunnerIntegration.function1InDifferentPackage", function1InDifferentPackage, [], [])) - f(TTSL_runner.memoized_call("tests.generator.differentPackageWildcardWithRunnerIntegration.function1InDifferentPackage", function1InDifferentPackage, [], [])) - f(TTSL_runner.memoized_call("tests.generator.differentPackageWildcardWithRunnerIntegration.function2InDifferentPackage", function2InDifferentPackage, [], [])) - f(TTSL_runner.memoized_call("tests.generator.differentPackageWildcardWithRunnerIntegration.function2InDifferentPackage", function2InDifferentPackage, [], [])) - f(TTSL_runner.memoized_call("special_location.function1InCompilationUnitWithPythonModule", function1InCompilationUnitWithPythonModule, [], [])) - f(TTSL_runner.memoized_call("special_location.function1InCompilationUnitWithPythonModule", function1InCompilationUnitWithPythonModule, [], [])) - f(TTSL_runner.memoized_call("special_location.function2InCompilationUnitWithPythonModule", function2InCompilationUnitWithPythonModule, [], [])) - f(TTSL_runner.memoized_call("special_location.function2InCompilationUnitWithPythonModule", function2InCompilationUnitWithPythonModule, [], [])) diff --git a/packages/ttsl-lang/tests/resources/generation/runner integration/imports/wildcard/generated/tests/generator/wildcardWithRunnerIntegration/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/runner integration/imports/wildcard/generated/tests/generator/wildcardWithRunnerIntegration/gen_input.py.map deleted file mode 100644 index 5401fc79..00000000 --- a/packages/ttsl-lang/tests/resources/generation/runner integration/imports/wildcard/generated/tests/generator/wildcardWithRunnerIntegration/gen_input.py.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"sources":["input.ttsl"],"names":["test","f","function1indifferentpackage","function2indifferentpackage","function1incompilationunitwithpythonmodule","function2incompilationunitwithpythonmodule"],"mappings":"AAAA;;;;;;;;AAOA,IAASA,IAAI;IACTC,CAAC,CAAC,yHAAAC,2BAA2B;IAC7BD,CAAC,CAAC,yHAAAC,2BAA2B;IAC7BD,CAAC,CAAC,yHAAAE,2BAA2B;IAC7BF,CAAC,CAAC,yHAAAE,2BAA2B;IAE7BF,CAAC,CAAC,2FAAAG,0CAA0C;IAC5CH,CAAC,CAAC,2FAAAG,0CAA0C;IAC5CH,CAAC,CAAC,2FAAAI,0CAA0C;IAC5CJ,CAAC,CAAC,2FAAAI,0CAA0C","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/runner integration/imports/wildcard/generated/tests/generator/wildcardWithRunnerIntegration/gen_input_test.py b/packages/ttsl-lang/tests/resources/generation/runner integration/imports/wildcard/generated/tests/generator/wildcardWithRunnerIntegration/gen_input_test.py deleted file mode 100644 index 824f70b1..00000000 --- a/packages/ttsl-lang/tests/resources/generation/runner integration/imports/wildcard/generated/tests/generator/wildcardWithRunnerIntegration/gen_input_test.py +++ /dev/null @@ -1,4 +0,0 @@ -from .gen_input import test - -if __name__ == '__main__': - test() diff --git a/packages/ttsl-lang/tests/resources/generation/runner integration/imports/wildcard/input.sdstest b/packages/ttsl-lang/tests/resources/generation/runner integration/imports/wildcard/input.sdstest deleted file mode 100644 index e20e4043..00000000 --- a/packages/ttsl-lang/tests/resources/generation/runner integration/imports/wildcard/input.sdstest +++ /dev/null @@ -1,18 +0,0 @@ -package tests.generator.wildcardWithRunnerIntegration - -from tests.generator.differentPackageWildcardWithRunnerIntegration import * -from tests.generator.withPythonModuleWildcardWithRunnerIntegration import * - -@Impure([ImpurityReason.Other]) fun f(param: Any?) - -pipeline test { - f(function1InDifferentPackage()); - f(function1InDifferentPackage()); - f(function2InDifferentPackage()); - f(function2InDifferentPackage()); - - f(function1InCompilationUnitWithPythonModule()); - f(function1InCompilationUnitWithPythonModule()); - f(function2InCompilationUnitWithPythonModule()); - f(function2InCompilationUnitWithPythonModule()); -} diff --git a/packages/ttsl-lang/tests/resources/generation/runner integration/statements/assignment/generated/tests/generator/assignmentWithRunnerIntegration/gen_input.py b/packages/ttsl-lang/tests/resources/generation/runner integration/statements/assignment/generated/tests/generator/assignmentWithRunnerIntegration/gen_input.py deleted file mode 100644 index 24b0a14b..00000000 --- a/packages/ttsl-lang/tests/resources/generation/runner integration/statements/assignment/generated/tests/generator/assignmentWithRunnerIntegration/gen_input.py +++ /dev/null @@ -1,39 +0,0 @@ -# Imports ---------------------------------------------------------------------- - -import TTSL_runner - -# Segments --------------------------------------------------------------------- - -def testSegment(): - g() - a, _, __gen_yield_c = g() - x, _, _ = g() - f1(a) - f1(x) - return __gen_yield_c - -# Pipelines -------------------------------------------------------------------- - -def testPipeline(): - g() - a, _, _ = g() - TTSL_runner.save_placeholder('a', a) - x, _, _ = g() - TTSL_runner.save_placeholder('x', x) - f1(a) - f1(x) - l, m, n = g() - TTSL_runner.save_placeholder('l', l) - TTSL_runner.save_placeholder('m', m) - TTSL_runner.save_placeholder('n', n) - f1(l) - f1(m) - f1(n) - def __gen_block_lambda_0(): - g() - a, _, __gen_block_lambda_result_c = g() - x, _, _ = g() - f1(a) - f1(x) - return __gen_block_lambda_result_c - f2(__gen_block_lambda_0) diff --git a/packages/ttsl-lang/tests/resources/generation/runner integration/statements/assignment/generated/tests/generator/assignmentWithRunnerIntegration/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/runner integration/statements/assignment/generated/tests/generator/assignmentWithRunnerIntegration/gen_input.py.map deleted file mode 100644 index 54aa39d2..00000000 --- a/packages/ttsl-lang/tests/resources/generation/runner integration/statements/assignment/generated/tests/generator/assignmentWithRunnerIntegration/gen_input.py.map +++ /dev/null @@ -1 +0,0 @@ -{"version":3,"sources":["input.ttsl"],"names":["testsegment","g","_","c","f1","a","x","testpipeline","l","m","n","f2"],"mappings":"AAAA;;;;;;AA2BA,IAAQA,WAAW;IACLC,CAAC;IACX,GAAOC,CAAC,EAAE,YAAMC,CAAC,GAAGF,CAAC;IACrB,UAAQA,CAAC;IACTG,EAAE,CAACC,CAAC;IACJD,EAAE,CAACE,CAAC;IALc,OAAG;;;;AApBzB,IAASC,YAAY;IACPN,CAAC;IACX,GAAOC,CAAC,EAAEA,CAAC,GAAGD,CAAC;IAAf;IACA,UAAQA,CAAC;IAAT;IACAG,EAAE,CAACC,CAAC;IACJD,EAAE,CAACE,CAAC;IACJ,GAAO,GAAO,IAAQL,CAAC;IAAvB;IAAO;IAAO;IACdG,EAAE,CAACI,CAAC;IACJJ,EAAE,CAACK,CAAC;IACJL,EAAE,CAACM,CAAC;IAED;QACWT,CAAC;QACX,GAAOC,CAAC,EAAE,0BAAMC,CAAC,GAAGF,CAAC;QACrB,UAAQA,CAAC;QACTG,EAAE,CAACC,CAAC;QACJD,EAAE,CAACE,CAAC;QALL,OAEW,0BAAMH,CAAC;IAFrBQ,EAAE,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/runner integration/statements/assignment/generated/tests/generator/assignmentWithRunnerIntegration/gen_input_testPipeline.py b/packages/ttsl-lang/tests/resources/generation/runner integration/statements/assignment/generated/tests/generator/assignmentWithRunnerIntegration/gen_input_testPipeline.py deleted file mode 100644 index 09ca7590..00000000 --- a/packages/ttsl-lang/tests/resources/generation/runner integration/statements/assignment/generated/tests/generator/assignmentWithRunnerIntegration/gen_input_testPipeline.py +++ /dev/null @@ -1,4 +0,0 @@ -from .gen_input import testPipeline - -if __name__ == '__main__': - testPipeline() diff --git a/packages/ttsl-lang/tests/resources/generation/runner integration/statements/assignment/input.sdstest b/packages/ttsl-lang/tests/resources/generation/runner integration/statements/assignment/input.sdstest deleted file mode 100644 index 7f95cfc6..00000000 --- a/packages/ttsl-lang/tests/resources/generation/runner integration/statements/assignment/input.sdstest +++ /dev/null @@ -1,34 +0,0 @@ -package tests.generator.assignmentWithRunnerIntegration - -@Impure([ImpurityReason.Other]) fun f1(param: Any?) -@Impure([ImpurityReason.PotentiallyImpureParameterCall("param")]) fun f2(param: () -> r: Int?) - -@Impure([ImpurityReason.Other]) fun g() -> (a: Int, b: Int, c: Int) - -pipeline testPipeline { - _, _ ,_ = g(); - val a, _, _ = g(); - val x = g(); - f1(a); - f1(x); - val l, val m, val n = g(); - f1(l); - f1(m); - f1(n); - - f2(() { - _, _ ,_ = g(); - val a, _, yield c = g(); - val x = g(); - f1(a); - f1(x); - }); -} - -segment testSegment() -> c: Int { - _, _ ,_ = g(); - val a, _, yield c = g(); - val x = g(); - f1(a); - f1(x); -} diff --git a/packages/ttsl-lang/tests/resources/generation/statements/Loops/forLoop/input.ttsl b/packages/ttsl-lang/tests/resources/generation/statements/Loops/forLoop/input.ttsl new file mode 100644 index 00000000..c0a37126 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/statements/Loops/forLoop/input.ttsl @@ -0,0 +1,9 @@ +package tests.generator.forLoop + +function myFunction () { + var x = 0; + for(var i = 0; i <= 10; i = i+1){ + } + return x; +} + diff --git a/packages/ttsl-lang/tests/resources/generation/statements/Loops/foreachLoop/generated/tests/generator/forEachLoop/gen_input.py b/packages/ttsl-lang/tests/resources/generation/statements/Loops/foreachLoop/generated/tests/generator/forEachLoop/gen_input.py new file mode 100644 index 00000000..d6d3c25c --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/statements/Loops/foreachLoop/generated/tests/generator/forEachLoop/gen_input.py @@ -0,0 +1,37 @@ +# Imports ---------------------------------------------------------------------- + +from typing import Any, TypeVar + +# Type variables --------------------------------------------------------------- + +__gen_T = TypeVar("__gen_T") + +# Utils ------------------------------------------------------------------------ + +class __gen_ClassConstants(): + def __init__(self, dictionary: dict): + self.dict = dictionary + def getValue(self, date = None): + keys = sorted(self.dict.keys()) + if(keys[0] == "empty"): + return self.dict["empty"] + for index, key in enumerate(keys): + if key[0] == "s": + if key.replace("s", "") <= date: + result = self.dict[key] + if key[0] == "e": + if date <= keys[len(keys)-1-index].replace("e", ""): + result = self.dict[keys[len(keys)-1-index]] + return result + +# Functions -------------------------------------------------------------------- + +def myFunction(): + x = 0 + for elm in list: + x = x + elm + return x + +# Constants -------------------------------------------------------------------- + +list = __gen_ClassConstants({"empty": [1, 2, 3]}) diff --git a/packages/ttsl-lang/tests/resources/generation/statements/Loops/foreachLoop/generated/tests/generator/forEachLoop/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/statements/Loops/foreachLoop/generated/tests/generator/forEachLoop/gen_input.py.map new file mode 100644 index 00000000..5ca7b3ef --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/statements/Loops/foreachLoop/generated/tests/generator/forEachLoop/gen_input.py.map @@ -0,0 +1 @@ +{"version":3,"sources":["input.ttsl"],"names":["myfunction"],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAIA,IAASA,UAAU;IACf,IAAQ,CAAC;IACT;oBAAoB;;;;;AAJxB,OAAA,+BAA2B,CAAC,CAAC,EAAC,CAAC,EAAC,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/statements/Loops/foreachLoop/generated/tests/generator/forEachLoop/gen_input_myFunction.py b/packages/ttsl-lang/tests/resources/generation/statements/Loops/foreachLoop/generated/tests/generator/forEachLoop/gen_input_myFunction.py new file mode 100644 index 00000000..1e39903c --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/statements/Loops/foreachLoop/generated/tests/generator/forEachLoop/gen_input_myFunction.py @@ -0,0 +1,4 @@ +from .gen_input import myFunction + +if __name__ == '__main__': + myFunction() diff --git a/packages/ttsl-lang/tests/resources/generation/statements/Loops/foreachLoop/input.ttsl b/packages/ttsl-lang/tests/resources/generation/statements/Loops/foreachLoop/input.ttsl new file mode 100644 index 00000000..f5cac2ab --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/statements/Loops/foreachLoop/input.ttsl @@ -0,0 +1,11 @@ +package tests.generator.forEachLoop + +constant list: List = [1,2,3] + +function myFunction (): Int { + var x = 0; + foreach(elm in list){ + x = x + elm; + } + return x; +} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/statements/Loops/whileLoop/generated/tests/generator/whileLoop/gen_input.py b/packages/ttsl-lang/tests/resources/generation/statements/Loops/whileLoop/generated/tests/generator/whileLoop/gen_input.py new file mode 100644 index 00000000..d8016a84 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/statements/Loops/whileLoop/generated/tests/generator/whileLoop/gen_input.py @@ -0,0 +1,7 @@ + +# Functions -------------------------------------------------------------------- + +def myFunction(): + i = 0 + while (i) == (0): + i = 1 diff --git a/packages/ttsl-lang/tests/resources/generation/statements/Loops/whileLoop/generated/tests/generator/whileLoop/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/statements/Loops/whileLoop/generated/tests/generator/whileLoop/gen_input.py.map new file mode 100644 index 00000000..4c551223 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/statements/Loops/whileLoop/generated/tests/generator/whileLoop/gen_input.py.map @@ -0,0 +1 @@ +{"version":3,"sources":["input.ttsl"],"names":["myfunction","i"],"mappings":"AAAA;;AAEA,IAASA,UAAU;IACf,IAAa,CAAC;IACd,MAAM,CAAAC,CAAC,EAAC,EAAE,EAAC,CAAC;QAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/statements/Loops/whileLoop/generated/tests/generator/whileLoop/gen_input_myFunction.py b/packages/ttsl-lang/tests/resources/generation/statements/Loops/whileLoop/generated/tests/generator/whileLoop/gen_input_myFunction.py new file mode 100644 index 00000000..1e39903c --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/statements/Loops/whileLoop/generated/tests/generator/whileLoop/gen_input_myFunction.py @@ -0,0 +1,4 @@ +from .gen_input import myFunction + +if __name__ == '__main__': + myFunction() diff --git a/packages/ttsl-lang/tests/resources/generation/statements/Loops/whileLoop/input.ttsl b/packages/ttsl-lang/tests/resources/generation/statements/Loops/whileLoop/input.ttsl new file mode 100644 index 00000000..8af77b0b --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/statements/Loops/whileLoop/input.ttsl @@ -0,0 +1,8 @@ +package tests.generator.whileLoop + +function myFunction () { + var i: Int = 0; + while(i == 0){ + i = 1; + } +} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/statements/assignment/generated/tests/generator/assignment/gen_input.py b/packages/ttsl-lang/tests/resources/generation/statements/assignment/generated/tests/generator/assignment/gen_input.py index fcb3062b..d3edd0c4 100644 --- a/packages/ttsl-lang/tests/resources/generation/statements/assignment/generated/tests/generator/assignment/gen_input.py +++ b/packages/ttsl-lang/tests/resources/generation/statements/assignment/generated/tests/generator/assignment/gen_input.py @@ -1,30 +1,11 @@ -# Segments --------------------------------------------------------------------- +# Functions -------------------------------------------------------------------- -def testSegment(): - g() - a, _, __gen_yield_c = g() - x, _, _ = g() - f1(a) - f1(x) - return __gen_yield_c +def f(): + pass -# Pipelines -------------------------------------------------------------------- +def g(x): + pass + +def testFunction(): + a = f() -def testPipeline(): - g() - a, _, _ = g() - x, _, _ = g() - f1(a) - f1(x) - l, m, n = g() - f1(l) - f1(m) - f1(n) - def __gen_block_lambda_0(): - g() - a, _, __gen_block_lambda_result_c = g() - x, _, _ = g() - f1(a) - f1(x) - return __gen_block_lambda_result_c - f2(__gen_block_lambda_0) diff --git a/packages/ttsl-lang/tests/resources/generation/statements/assignment/generated/tests/generator/assignment/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/statements/assignment/generated/tests/generator/assignment/gen_input.py.map index 20879674..20568ba6 100644 --- a/packages/ttsl-lang/tests/resources/generation/statements/assignment/generated/tests/generator/assignment/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/statements/assignment/generated/tests/generator/assignment/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.ttsl"],"names":["testsegment","g","_","c","f1","a","x","testpipeline","l","m","n","f2"],"mappings":"AAAA;;AA2BA,IAAQA,WAAW;IACLC,CAAC;IACX,GAAOC,CAAC,EAAE,YAAMC,CAAC,GAAGF,CAAC;IACrB,UAAQA,CAAC;IACTG,EAAE,CAACC,CAAC;IACJD,EAAE,CAACE,CAAC;IALc,OAAG;;;;AApBzB,IAASC,YAAY;IACPN,CAAC;IACX,GAAOC,CAAC,EAAEA,CAAC,GAAGD,CAAC;IACf,UAAQA,CAAC;IACTG,EAAE,CAACC,CAAC;IACJD,EAAE,CAACE,CAAC;IACJ,GAAO,GAAO,IAAQL,CAAC;IACvBG,EAAE,CAACI,CAAC;IACJJ,EAAE,CAACK,CAAC;IACJL,EAAE,CAACM,CAAC;IAED;QACWT,CAAC;QACX,GAAOC,CAAC,EAAE,0BAAMC,CAAC,GAAGF,CAAC;QACrB,UAAQA,CAAC;QACTG,EAAE,CAACC,CAAC;QACJD,EAAE,CAACE,CAAC;QALL,OAEW,0BAAMH,CAAC;IAFrBQ,EAAE,CAAC","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["f","g","x","testfunction"],"mappings":"AAAA;;AAEA,IAASA,CAAC;IAAQ,IAAE;;AACpB,IAASC,CAAC,CAACC,CAAC;IAAM,IAAE;;AAEpB,IAASC,YAAY;IACjB,IAAQH,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/statements/assignment/generated/tests/generator/assignment/gen_input_f.py b/packages/ttsl-lang/tests/resources/generation/statements/assignment/generated/tests/generator/assignment/gen_input_f.py new file mode 100644 index 00000000..3c6273bd --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/statements/assignment/generated/tests/generator/assignment/gen_input_f.py @@ -0,0 +1,4 @@ +from .gen_input import f + +if __name__ == '__main__': + f() diff --git a/packages/ttsl-lang/tests/resources/generation/statements/assignment/generated/tests/generator/assignment/gen_input_g.py b/packages/ttsl-lang/tests/resources/generation/statements/assignment/generated/tests/generator/assignment/gen_input_g.py new file mode 100644 index 00000000..0e7a09fa --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/statements/assignment/generated/tests/generator/assignment/gen_input_g.py @@ -0,0 +1,4 @@ +from .gen_input import g + +if __name__ == '__main__': + g() diff --git a/packages/ttsl-lang/tests/resources/generation/statements/assignment/generated/tests/generator/assignment/gen_input_testFunction.py b/packages/ttsl-lang/tests/resources/generation/statements/assignment/generated/tests/generator/assignment/gen_input_testFunction.py new file mode 100644 index 00000000..a31fb68d --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/statements/assignment/generated/tests/generator/assignment/gen_input_testFunction.py @@ -0,0 +1,4 @@ +from .gen_input import testFunction + +if __name__ == '__main__': + testFunction() diff --git a/packages/ttsl-lang/tests/resources/generation/statements/assignment/generated/tests/generator/assignment/gen_input_testPipeline.py b/packages/ttsl-lang/tests/resources/generation/statements/assignment/generated/tests/generator/assignment/gen_input_testPipeline.py deleted file mode 100644 index 09ca7590..00000000 --- a/packages/ttsl-lang/tests/resources/generation/statements/assignment/generated/tests/generator/assignment/gen_input_testPipeline.py +++ /dev/null @@ -1,4 +0,0 @@ -from .gen_input import testPipeline - -if __name__ == '__main__': - testPipeline() diff --git a/packages/ttsl-lang/tests/resources/generation/statements/assignment/input.sdstest b/packages/ttsl-lang/tests/resources/generation/statements/assignment/input.sdstest deleted file mode 100644 index 1bcb70ae..00000000 --- a/packages/ttsl-lang/tests/resources/generation/statements/assignment/input.sdstest +++ /dev/null @@ -1,34 +0,0 @@ -package tests.generator.assignment - -@Impure([ImpurityReason.Other]) fun f1(param: Any?) -@Impure([ImpurityReason.PotentiallyImpureParameterCall("param")]) fun f2(param: () -> r: Int?) - -@Impure([ImpurityReason.Other]) fun g() -> (a: Int, b: Int, c: Int) - -pipeline testPipeline { - _, _ ,_ = g(); - val a, _, _ = g(); - val x = g(); - f1(a); - f1(x); - val l, val m, val n = g(); - f1(l); - f1(m); - f1(n); - - f2(() { - _, _ ,_ = g(); - val a, _, yield c = g(); - val x = g(); - f1(a); - f1(x); - }); -} - -segment testSegment() -> c: Int { - _, _ ,_ = g(); - val a, _, yield c = g(); - val x = g(); - f1(a); - f1(x); -} diff --git a/packages/ttsl-lang/tests/resources/generation/statements/assignment/input.ttsl b/packages/ttsl-lang/tests/resources/generation/statements/assignment/input.ttsl new file mode 100644 index 00000000..67959e4f --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/statements/assignment/input.ttsl @@ -0,0 +1,8 @@ +package tests.generator.assignment + +function f(): Int {} +function g(x: Int){} + +function testFunction() { + var a = f(); +} diff --git a/packages/ttsl-lang/tests/resources/generation/statements/conditional statement/generated/tests/generator/conditionalStatement/gen_input.py b/packages/ttsl-lang/tests/resources/generation/statements/conditional statement/generated/tests/generator/conditionalStatement/gen_input.py index dbcb8df5..004abb05 100644 --- a/packages/ttsl-lang/tests/resources/generation/statements/conditional statement/generated/tests/generator/conditionalStatement/gen_input.py +++ b/packages/ttsl-lang/tests/resources/generation/statements/conditional statement/generated/tests/generator/conditionalStatement/gen_input.py @@ -1,7 +1,7 @@ -# Pipelines --------------------------------------------------------------------- +# Functions -------------------------------------------------------------------- def test(): - if 1 == 0: - pass + if ((1) == (0)): + 1 else: - pass + 2 diff --git a/packages/ttsl-lang/tests/resources/generation/statements/conditional statement/generated/tests/generator/conditionalStatement/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/statements/conditional statement/generated/tests/generator/conditionalStatement/gen_input.py.map index 450b4723..d9dd1404 100644 --- a/packages/ttsl-lang/tests/resources/generation/statements/conditional statement/generated/tests/generator/conditionalStatement/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/statements/conditional statement/generated/tests/generator/conditionalStatement/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.ttsl"],"names":["test"],"mappings":"AAAA;;AAEA,IAASA,IAAI;IACT,GAAG","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["test"],"mappings":"AAAA;;AAEA,IAASA,IAAI;IACT,IAAI,CAAA,CAAC,EAAC,EAAE,EAAC,CAAC;QACN,CAAC;;QAED,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/constant/generated/tests/generator/constant/gen_input_test.py b/packages/ttsl-lang/tests/resources/generation/statements/conditional statement/generated/tests/generator/conditionalStatement/gen_input_test.py similarity index 100% rename from packages/ttsl-lang/tests/resources/generation/expressions/constant/generated/tests/generator/constant/gen_input_test.py rename to packages/ttsl-lang/tests/resources/generation/statements/conditional statement/generated/tests/generator/conditionalStatement/gen_input_test.py diff --git a/packages/ttsl-lang/tests/resources/generation/statements/conditional statement/generated/tests/generator/conditionalStatement/gen_input_testPipeline.py b/packages/ttsl-lang/tests/resources/generation/statements/conditional statement/generated/tests/generator/conditionalStatement/gen_input_testPipeline.py deleted file mode 100644 index af29cac4..00000000 --- a/packages/ttsl-lang/tests/resources/generation/statements/conditional statement/generated/tests/generator/conditionalStatement/gen_input_testPipeline.py +++ /dev/null @@ -1,4 +0,0 @@ -from .gen_input import test - -if __name__ == '__main__': - test(None, None, None) diff --git a/packages/ttsl-lang/tests/resources/generation/statements/conditional statement/input.ttsl b/packages/ttsl-lang/tests/resources/generation/statements/conditional statement/input.ttsl index d08d4639..63c2b0a8 100644 --- a/packages/ttsl-lang/tests/resources/generation/statements/conditional statement/input.ttsl +++ b/packages/ttsl-lang/tests/resources/generation/statements/conditional statement/input.ttsl @@ -1,7 +1,7 @@ package tests.generator.conditionalStatement -pipeline test { - if(1 == 0){ +function test () { + if( 1 == 0){ 1; }else{ 2; diff --git a/packages/ttsl-lang/tests/resources/generation/statements/expression statement/generated/tests/generator/expressionStatement/gen_input.py b/packages/ttsl-lang/tests/resources/generation/statements/expression statement/generated/tests/generator/expressionStatement/gen_input.py index 6c765f1b..9b23f18f 100644 --- a/packages/ttsl-lang/tests/resources/generation/statements/expression statement/generated/tests/generator/expressionStatement/gen_input.py +++ b/packages/ttsl-lang/tests/resources/generation/statements/expression statement/generated/tests/generator/expressionStatement/gen_input.py @@ -1,12 +1,9 @@ -# Segments --------------------------------------------------------------------- +# Functions -------------------------------------------------------------------- -def testSegment(): - g() +def f(): + pass -# Pipelines -------------------------------------------------------------------- +def test(): + f() + 1 -def testPipeline(): - g() - def __gen_block_lambda_0(): - g() - f(__gen_block_lambda_0) diff --git a/packages/ttsl-lang/tests/resources/generation/statements/expression statement/generated/tests/generator/expressionStatement/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/statements/expression statement/generated/tests/generator/expressionStatement/gen_input.py.map index ee062285..7c5101ac 100644 --- a/packages/ttsl-lang/tests/resources/generation/statements/expression statement/generated/tests/generator/expressionStatement/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/statements/expression statement/generated/tests/generator/expressionStatement/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.ttsl"],"names":["testsegment","g","testpipeline","f"],"mappings":"AAAA;;AAcA,IAAQA,WAAW;IACfC,CAAC;;;;AATL,IAASC,YAAY;IACjBD,CAAC;IAEC;QACEA,CAAC;IADLE,CAAC,CAAC","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["f","test"],"mappings":"AAAA;;AAEA,IAASA,CAAC;IAAE,IAAE;;AAEd,IAASC,IAAI;IACTD,CAAC;IACD,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/statements/expression statement/generated/tests/generator/expressionStatement/gen_input_f.py b/packages/ttsl-lang/tests/resources/generation/statements/expression statement/generated/tests/generator/expressionStatement/gen_input_f.py new file mode 100644 index 00000000..3c6273bd --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/statements/expression statement/generated/tests/generator/expressionStatement/gen_input_f.py @@ -0,0 +1,4 @@ +from .gen_input import f + +if __name__ == '__main__': + f() diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/enum variant call/generated/tests/generator/enumVariantCall/gen_input_test.py b/packages/ttsl-lang/tests/resources/generation/statements/expression statement/generated/tests/generator/expressionStatement/gen_input_test.py similarity index 100% rename from packages/ttsl-lang/tests/resources/generation/expressions/enum variant call/generated/tests/generator/enumVariantCall/gen_input_test.py rename to packages/ttsl-lang/tests/resources/generation/statements/expression statement/generated/tests/generator/expressionStatement/gen_input_test.py diff --git a/packages/ttsl-lang/tests/resources/generation/statements/expression statement/generated/tests/generator/expressionStatement/gen_input_testPipeline.py b/packages/ttsl-lang/tests/resources/generation/statements/expression statement/generated/tests/generator/expressionStatement/gen_input_testPipeline.py deleted file mode 100644 index 09ca7590..00000000 --- a/packages/ttsl-lang/tests/resources/generation/statements/expression statement/generated/tests/generator/expressionStatement/gen_input_testPipeline.py +++ /dev/null @@ -1,4 +0,0 @@ -from .gen_input import testPipeline - -if __name__ == '__main__': - testPipeline() diff --git a/packages/ttsl-lang/tests/resources/generation/statements/expression statement/input.sdstest b/packages/ttsl-lang/tests/resources/generation/statements/expression statement/input.sdstest deleted file mode 100644 index de3d018b..00000000 --- a/packages/ttsl-lang/tests/resources/generation/statements/expression statement/input.sdstest +++ /dev/null @@ -1,17 +0,0 @@ -package tests.generator.expressionStatement - -@Impure([ImpurityReason.PotentiallyImpureParameterCall("param")]) fun f(param: () -> ()) - -@Impure([ImpurityReason.Other]) fun g() -> result: Int - -pipeline testPipeline { - g(); - - f(() { - g(); - }); -} - -segment testSegment() { - g(); -} diff --git a/packages/ttsl-lang/tests/resources/generation/statements/expression statement/input.ttsl b/packages/ttsl-lang/tests/resources/generation/statements/expression statement/input.ttsl new file mode 100644 index 00000000..1e236eb5 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/statements/expression statement/input.ttsl @@ -0,0 +1,8 @@ +package tests.generator.expressionStatement + +function f(){} + +function test(){ + f(); + 1; +} diff --git a/packages/ttsl-lang/tests/resources/generation/utilityFunctions/generated/tests/generator/utilityFunction/gen_input.py b/packages/ttsl-lang/tests/resources/generation/utilityFunctions/generated/tests/generator/utilityFunction/gen_input.py new file mode 100644 index 00000000..1b0010dd --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/utilityFunctions/generated/tests/generator/utilityFunction/gen_input.py @@ -0,0 +1,48 @@ +# Imports ---------------------------------------------------------------------- + +from typing import Any, TypeVar + +# Type variables --------------------------------------------------------------- + +__gen_T = TypeVar("__gen_T") + +# Utils ------------------------------------------------------------------------ + +def __gen_len(list): + return len(list) + +def __gen_keys(dict): + return list(dict.keys()) + +def __gen_values(dict): + return list(dict.values()) + +class __gen_ClassConstants(): + def __init__(self, dictionary: dict): + self.dict = dictionary + def getValue(self, date = None): + keys = sorted(self.dict.keys()) + if(keys[0] == "empty"): + return self.dict["empty"] + for index, key in enumerate(keys): + if key[0] == "s": + if key.replace("s", "") <= date: + result = self.dict[key] + if key[0] == "e": + if date <= keys[len(keys)-1-index].replace("e", ""): + result = self.dict[keys[len(keys)-1-index]] + return result + +# Functions -------------------------------------------------------------------- + +def testFunction(): + x = __gen_len(testList) + y = __gen_keys(testDict) + z = __gen_values(testDict) + + +# Constants -------------------------------------------------------------------- + +testList = __gen_ClassConstants({"empty": [1, 2, 3]}) + +testDict = __gen_ClassConstants({"empty": {"a": 1, "b": 2, "c": 3}}) \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/utilityFunctions/generated/tests/generator/utilityFunction/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/utilityFunctions/generated/tests/generator/utilityFunction/gen_input.py.map new file mode 100644 index 00000000..fc4ef51b --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/utilityFunctions/generated/tests/generator/utilityFunction/gen_input.py.map @@ -0,0 +1 @@ +{"version":3,"sources":["input.ttsl"],"names":["testfunction","testlist","testdict"],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAKA,IAASA,YAAY;IACjB,IAAYC,SAAQ;IACpB,IAAaC,UAAQ;IACrB,IAAeA,YAAQ;;;;;AAN3B,WAAA,+BAA+B,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC;;AACvC,WAAA,+BAAuC,CAAC,GAAG,EAAE,CAAC,EAAE,GAAG,EAAE,CAAC,EAAE,GAAG,EAAE,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/utilityFunctions/generated/tests/generator/utilityFunction/gen_input_testFunction.py b/packages/ttsl-lang/tests/resources/generation/utilityFunctions/generated/tests/generator/utilityFunction/gen_input_testFunction.py new file mode 100644 index 00000000..a31fb68d --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/utilityFunctions/generated/tests/generator/utilityFunction/gen_input_testFunction.py @@ -0,0 +1,4 @@ +from .gen_input import testFunction + +if __name__ == '__main__': + testFunction() diff --git a/packages/ttsl-lang/tests/resources/generation/utilityFunctions/input.ttsl b/packages/ttsl-lang/tests/resources/generation/utilityFunctions/input.ttsl index 205733ec..0660d5c8 100644 --- a/packages/ttsl-lang/tests/resources/generation/utilityFunctions/input.ttsl +++ b/packages/ttsl-lang/tests/resources/generation/utilityFunctions/input.ttsl @@ -1,7 +1,10 @@ package tests.generator.utilityFunction constant testList: List = [1, 2, 3] +constant testDict: Dict = {"a": 1, "b": 2, "c": 3} function testFunction(){ var x = len(testList); + var y = keys(testDict); + var z = values(testDict); } diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/bad-unclosed argument list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/bad-unclosed argument list.sdstest deleted file mode 100644 index 8e537c4c..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/bad-unclosed argument list.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -@Annotation( diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-empty argument list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-empty argument list.sdstest deleted file mode 100644 index af0cf406..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-empty argument list.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -@Annotation() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-multiple arguments.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-multiple arguments.sdstest deleted file mode 100644 index 7c510cf6..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-multiple arguments.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -@Annotation(1, a = 2) diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-named argument.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-named argument.sdstest deleted file mode 100644 index ba199336..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-named argument.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -@Annotation(b = 2) diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-no argument list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-no argument list.sdstest deleted file mode 100644 index b0f0c598..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-no argument list.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -@Annotation diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-positional argument.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-positional argument.sdstest deleted file mode 100644 index 319c6983..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/annotation calls/good-positional argument.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -@Annotation(1) diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/bad-unclosed constraint list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/bad-unclosed constraint list.sdstest deleted file mode 100644 index 4116a938..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/bad-unclosed constraint list.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -annotation MyAnnotation where { diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/bad-unclosed parameter list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/bad-unclosed parameter list.sdstest deleted file mode 100644 index ec0beccf..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/bad-unclosed parameter list.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -annotation MyAnnotation( diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/good-annotation call.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/good-annotation call.sdstest deleted file mode 100644 index d867f6cb..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/good-annotation call.sdstest +++ /dev/null @@ -1,6 +0,0 @@ -// $TEST$ no_syntax_error - -package test - -@Annotation -annotation MyAnnotation diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/good-no parameter list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/good-no parameter list.sdstest deleted file mode 100644 index a4a5a34d..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/good-no parameter list.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -annotation MyAnnotation diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/good-with constraint list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/good-with constraint list.sdstest deleted file mode 100644 index 19cb167c..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/good-with constraint list.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -annotation MyAnnotation where {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/good-with parameter list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/good-with parameter list.sdstest deleted file mode 100644 index 54d35f27..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/annotations/good-with parameter list.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -annotation MyAnnotation() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/attributes/good-annotated.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/attributes/good-annotated.sdstest deleted file mode 100644 index 11ebf0fc..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/attributes/good-annotated.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -class MyClass { - @Annotation attr a -} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/attributes/good-no type.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/attributes/good-no type.sdstest deleted file mode 100644 index 1b683279..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/attributes/good-no type.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -class MyClass { - attr a -} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/attributes/good-static.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/attributes/good-static.sdstest deleted file mode 100644 index c256ad51..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/attributes/good-static.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -class MyClass { - static attr a: Int -} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/attributes/good-with type.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/attributes/good-with type.sdstest deleted file mode 100644 index 8c5eaa37..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/attributes/good-with type.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -class MyClass { - attr a: Int -} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-empty parent type list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-empty parent type list.sdstest deleted file mode 100644 index a4bb256c..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-empty parent type list.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -class MyClass sub diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-unclosed body.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-unclosed body.sdstest deleted file mode 100644 index 87b9a8c4..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-unclosed body.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -class MyClass { diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-unclosed constraint list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-unclosed constraint list.sdstest deleted file mode 100644 index bb2ac2a4..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-unclosed constraint list.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -class MyClass where { diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-unclosed parameter list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-unclosed parameter list.sdstest deleted file mode 100644 index 63fd5d81..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-unclosed parameter list.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -class MyClass( diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-unclosed type parameter list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-unclosed type parameter list.sdstest deleted file mode 100644 index a86d4586..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/bad-unclosed type parameter list.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -class MyClass< diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-annotation call.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-annotation call.sdstest deleted file mode 100644 index c86c9b5b..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-annotation call.sdstest +++ /dev/null @@ -1,6 +0,0 @@ -// $TEST$ no_syntax_error - -package test - -@Annotation -class MyClass diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-empty body.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-empty body.sdstest deleted file mode 100644 index 4576be59..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-empty body.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -class MyClass {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-minimal.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-minimal.sdstest deleted file mode 100644 index 0b2a1003..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-minimal.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -class MyClass diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-multiple parent types.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-multiple parent types.sdstest deleted file mode 100644 index 0c1a8460..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-multiple parent types.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -class MyClass sub Int, Number diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-one parent type.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-one parent type.sdstest deleted file mode 100644 index 1231a1b7..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-one parent type.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -class MyClass sub Int diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-with constraint list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-with constraint list.sdstest deleted file mode 100644 index 982a5c1a..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-with constraint list.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -class MyClass where {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-with parameter list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-with parameter list.sdstest deleted file mode 100644 index fe748608..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-with parameter list.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -class MyClass() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-with type parameter list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-with type parameter list.sdstest deleted file mode 100644 index a06a2893..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/good-with type parameter list.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -class MyClass<> diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/methods/good-annotated instance method.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/methods/good-annotated instance method.sdstest deleted file mode 100644 index 72695918..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/methods/good-annotated instance method.sdstest +++ /dev/null @@ -1,6 +0,0 @@ -// $TEST$ no_syntax_error - -class MyClass { - @MyAnnotation - fun myFunction() -} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/methods/good-annotated static method.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/methods/good-annotated static method.sdstest deleted file mode 100644 index 4eb3f7d5..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/methods/good-annotated static method.sdstest +++ /dev/null @@ -1,6 +0,0 @@ -// $TEST$ no_syntax_error - -class MyClass { - @MyAnnotation - static fun myFunction() -} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/methods/good-instance method.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/methods/good-instance method.sdstest deleted file mode 100644 index 0a0ea9b6..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/methods/good-instance method.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -class MyClass { - fun myFunction() -} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/methods/good-static method.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/methods/good-static method.sdstest deleted file mode 100644 index cd54cd70..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/methods/good-static method.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -class MyClass { - static fun myFunction() -} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/nested classes/good-annotated nested class.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/nested classes/good-annotated nested class.sdstest deleted file mode 100644 index 20f74916..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/nested classes/good-annotated nested class.sdstest +++ /dev/null @@ -1,6 +0,0 @@ -// $TEST$ no_syntax_error - -class MyOuterClass { - @MyAnnotation - class MyClass -} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/nested classes/good-nested-class.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/nested classes/good-nested-class.sdstest deleted file mode 100644 index f090b40b..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/nested classes/good-nested-class.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -class MyOuterClass { - class MyClass -} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/nested enums/good-annotated nested enum.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/nested enums/good-annotated nested enum.sdstest deleted file mode 100644 index 76b8b7a8..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/nested enums/good-annotated nested enum.sdstest +++ /dev/null @@ -1,8 +0,0 @@ -// $TEST$ no_syntax_error - -class MyOuterClass { - @MyAnnotation - enum MyEnum { - MyEnumVariant - } -} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/nested enums/good-nested enum.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/classes/nested enums/good-nested enum.sdstest deleted file mode 100644 index d86fe01c..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/classes/nested enums/good-nested enum.sdstest +++ /dev/null @@ -1,7 +0,0 @@ -// $TEST$ no_syntax_error - -class MyOuterClass { - enum MyEnum { - MyEnumVariant - } -} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing name.ttsl b/packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing name.ttsl index 53e2553c..cdae50b5 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing name.ttsl +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing name.ttsl @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error constant : Int = 1; diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing type.ttsl b/packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing type.ttsl index e19c771e..fc06cf31 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing type.ttsl +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing type.ttsl @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error constant value: = 1 diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing value.ttsl b/packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing value.ttsl index 80e9be97..b1697d48 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing value.ttsl +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/constants/bad-missing value.ttsl @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error constant value: Int = diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/constants/good-with type and value.ttsl b/packages/ttsl-lang/tests/resources/grammar/declarations/constants/good-with type and value.ttsl index d85ef74f..7ff51d5c 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/constants/good-with type and value.ttsl +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/constants/good-with type and value.ttsl @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error constant value: Int = 1; diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/bad-missing comma.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/bad-missing comma.sdstest deleted file mode 100644 index 9eee0a23..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/bad-missing comma.sdstest +++ /dev/null @@ -1,6 +0,0 @@ -// $TEST$ syntax_error - -annotation MyAnnotation where { - p < 0 - q > 0 -} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-empty.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-empty.sdstest deleted file mode 100644 index 19cb167c..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-empty.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -annotation MyAnnotation where {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-greater than constraint.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-greater than constraint.sdstest deleted file mode 100644 index 1c940e1d..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-greater than constraint.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -annotation MyAnnotation where { - p > 0 -} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-greater than or equals constraint.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-greater than or equals constraint.sdstest deleted file mode 100644 index 8bde0690..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-greater than or equals constraint.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -annotation MyAnnotation where { - p >= 0 -} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-less than constraint.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-less than constraint.sdstest deleted file mode 100644 index 7665e1f6..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-less than constraint.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -annotation MyAnnotation where { - p < 0 -} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-less than or equals constraint.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-less than or equals constraint.sdstest deleted file mode 100644 index 9c206305..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-less than or equals constraint.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -annotation MyAnnotation where { - p <= 0 -} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-multiple constraints.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-multiple constraints.sdstest deleted file mode 100644 index c20fe5b6..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/constraints/good-multiple constraints.sdstest +++ /dev/null @@ -1,6 +0,0 @@ -// $TEST$ no_syntax_error - -annotation MyAnnotation where { - p < 0, - q > 0 -} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/data/bad-missing name.ttsl b/packages/ttsl-lang/tests/resources/grammar/declarations/data/bad-missing name.ttsl index cc484719..36f7a7de 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/data/bad-missing name.ttsl +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/data/bad-missing name.ttsl @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error data : Int; diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/data/bad-missing type.ttsl b/packages/ttsl-lang/tests/resources/grammar/declarations/data/bad-missing type.ttsl index fbd5e717..3c4cc803 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/data/bad-missing type.ttsl +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/data/bad-missing type.ttsl @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error data Data1: diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/data/good-with type and name.ttsl b/packages/ttsl-lang/tests/resources/grammar/declarations/data/good-with type and name.ttsl index 6d064ba9..55bfd115 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/data/good-with type and name.ttsl +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/data/good-with type and name.ttsl @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error data Data1: Int; \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/bad-unclosed body.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/enums/bad-unclosed body.sdstest deleted file mode 100644 index f80c9cee..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/bad-unclosed body.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -enum MyEnum { diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/good-annotation call.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/enums/good-annotation call.sdstest deleted file mode 100644 index f4e602fe..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/good-annotation call.sdstest +++ /dev/null @@ -1,6 +0,0 @@ -// $TEST$ no_syntax_error - -package test - -@Annotation -enum MyEnum diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/good-empty body.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/enums/good-empty body.sdstest deleted file mode 100644 index 44b08ebc..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/good-empty body.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -enum MyEnum {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/good-no body.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/enums/good-no body.sdstest deleted file mode 100644 index a5b34a99..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/good-no body.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -enum MyEnum diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/good-variants in body.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/enums/good-variants in body.sdstest deleted file mode 100644 index b12562bc..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/good-variants in body.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -enum MyEnum { - MyEnumVariant -} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/bad-unclosed constraint list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/bad-unclosed constraint list.sdstest deleted file mode 100644 index 69c43974..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/bad-unclosed constraint list.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -enum MyEnum { - MyEnumVariant where { -} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/bad-unclosed parameter list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/bad-unclosed parameter list.sdstest deleted file mode 100644 index 3dea580f..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/bad-unclosed parameter list.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -enum MyEnum { - MyEnumVariant( -} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/good-annotation call.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/good-annotation call.sdstest deleted file mode 100644 index 05a3e6a0..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/good-annotation call.sdstest +++ /dev/null @@ -1,6 +0,0 @@ -// $TEST$ no_syntax_error - -enum MyEnum { - @Annotation - MyEnumVariant -} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/good-no parameter list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/good-no parameter list.sdstest deleted file mode 100644 index b12562bc..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/good-no parameter list.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -enum MyEnum { - MyEnumVariant -} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/good-with constraint list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/good-with constraint list.sdstest deleted file mode 100644 index bf2fdb55..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/good-with constraint list.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -enum MyEnum { - MyEnumVariant where {} -} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/good-with parameter list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/good-with parameter list.sdstest deleted file mode 100644 index 9ff00fb6..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/enums/variants/good-with parameter list.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -enum MyEnum { - MyEnumVariant() -} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing functionbody.ttsl b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing functionbody.ttsl index ee789e47..d21ab74a 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing functionbody.ttsl +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing functionbody.ttsl @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error function myFunction() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing parameter list.ttsl b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing parameter list.ttsl index 184ce723..62bfce7a 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing parameter list.ttsl +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing parameter list.ttsl @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error function myFunction {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing parameter type.ttsl b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing parameter type.ttsl index 63971670..e586966d 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing parameter type.ttsl +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-missing parameter type.ttsl @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error function myFunction(x:) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed parameter list.ttsl b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed parameter list.ttsl index 138f26e2..a9a0a694 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed parameter list.ttsl +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed parameter list.ttsl @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error function myFunction( {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed result list.ttsl b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed result list.ttsl index 506f5495..417dd4f7 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed result list.ttsl +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/bad-unclosed result list.ttsl @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error function myFunction(): {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with parameter list.ttsl b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with parameter list.ttsl index 472e9a0b..4cb76642 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with parameter list.ttsl +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with parameter list.ttsl @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error function myFunction() {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with result list.ttsl b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with result list.ttsl index f8e478fc..8c0f9b30 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with result list.ttsl +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with result list.ttsl @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error function myFunction(): Int {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with type parameter list.ttsl b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with type parameter list.ttsl index a3ea0554..1f552456 100644 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with type parameter list.ttsl +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/functions/good-with type parameter list.ttsl @@ -1,3 +1,3 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error function myFunction(x: Int) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/bad-const before annotation.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/bad-const before annotation.sdstest deleted file mode 100644 index 1b5fd298..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/bad-const before annotation.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -class MyClass(const @Annotation a) diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/bad-double const modifier.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/bad-double const modifier.sdstest deleted file mode 100644 index 8b210905..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/bad-double const modifier.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -class MyClass(const const a: String) diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/bad-missing comma.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/bad-missing comma.sdstest deleted file mode 100644 index cf90d6e5..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/bad-missing comma.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -class MyClass(a b) diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/bad-missing comma.ttsl b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/bad-missing comma.ttsl new file mode 100644 index 00000000..1f984ed4 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/bad-missing comma.ttsl @@ -0,0 +1,3 @@ +# $TEST$ syntax_error + +function myFunction(a b) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/bad-missing type.ttsl b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/bad-missing type.ttsl new file mode 100644 index 00000000..1f2fa60f --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/bad-missing type.ttsl @@ -0,0 +1,3 @@ +# $TEST$ syntax_error + +function myFunction(a = 1) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-annotated parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-annotated parameter.sdstest deleted file mode 100644 index c71b43ca..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-annotated parameter.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -class MyClass(@Annotation a: Int) diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-const typed optional parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-const typed optional parameter.sdstest deleted file mode 100644 index 7a9b687c..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-const typed optional parameter.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -class MyClass(const a: Int = 1) diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-const typed required parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-const typed required parameter.sdstest deleted file mode 100644 index 7de3e265..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-const typed required parameter.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -class MyClass(const a: Int) diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-const untyped optional parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-const untyped optional parameter.sdstest deleted file mode 100644 index acda4390..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-const untyped optional parameter.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -class MyClass(const a = 1) diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-const untyped required parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-const untyped required parameter.sdstest deleted file mode 100644 index 5bc30a4a..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-const untyped required parameter.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -class MyClass(const a) diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-empty.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-empty.sdstest deleted file mode 100644 index fe748608..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-empty.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -class MyClass() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-empty.ttsl b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-empty.ttsl new file mode 100644 index 00000000..4cb76642 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-empty.ttsl @@ -0,0 +1,3 @@ +# $TEST$ no_syntax_error + +function myFunction() {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-multiple parameters.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-multiple parameters.sdstest deleted file mode 100644 index 93b84c6e..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-multiple parameters.sdstest +++ /dev/null @@ -1,13 +0,0 @@ -// $TEST$ no_syntax_error - -class MyClass( - @Annotation a1, - b1 = 0, - c1: Int, - d1: Int = 2, - - @Annotation const a2, - const b2 = 0, - const c2: Int, - const d2: Int = 2 -) diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-typed optional parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-typed optional parameter.sdstest deleted file mode 100644 index 076ed97d..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-typed optional parameter.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -class MyClass(a: Int = 1) diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-typed optional parameter.ttsl b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-typed optional parameter.ttsl new file mode 100644 index 00000000..154efc43 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-typed optional parameter.ttsl @@ -0,0 +1,3 @@ +# $TEST$ no_syntax_error + +function myFunction(a: Int = 1){} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-typed required parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-typed required parameter.sdstest deleted file mode 100644 index 3785d50c..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-typed required parameter.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -class MyClass(a: Int) diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-typed required parameter.ttsl b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-typed required parameter.ttsl new file mode 100644 index 00000000..564fbd28 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-typed required parameter.ttsl @@ -0,0 +1,3 @@ +# $TEST$ no_syntax_error + +function myFunction(a: Int) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-untyped optional parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-untyped optional parameter.sdstest deleted file mode 100644 index 9a29e763..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-untyped optional parameter.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -class MyClass(a = 1) diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-untyped required parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-untyped required parameter.sdstest deleted file mode 100644 index d02baee9..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/parameters/good-untyped required parameter.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -class MyClass(a) diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/bad-missing body.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/bad-missing body.sdstest deleted file mode 100644 index 87b1fa7e..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/bad-missing body.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/bad-unclosed body.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/bad-unclosed body.sdstest deleted file mode 100644 index 9710c4c7..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/bad-unclosed body.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/good-annotation call.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/good-annotation call.sdstest deleted file mode 100644 index b6c69990..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/good-annotation call.sdstest +++ /dev/null @@ -1,6 +0,0 @@ -// $TEST$ no_syntax_error - -package test - -@Annotation -pipeline myPipeline {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/good-empty body.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/good-empty body.sdstest deleted file mode 100644 index e65f1eb9..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/good-empty body.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/good-statements in body.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/good-statements in body.sdstest deleted file mode 100644 index 53561750..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/pipelines/good-statements in body.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - val a = 1; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/results/bad-missing comma.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/results/bad-missing comma.sdstest deleted file mode 100644 index fb9dc5e0..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/results/bad-missing comma.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -segment mySegment() -> (a b) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/results/bad-multiple results.ttsl b/packages/ttsl-lang/tests/resources/grammar/declarations/results/bad-multiple results.ttsl new file mode 100644 index 00000000..ea000f68 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/results/bad-multiple results.ttsl @@ -0,0 +1,3 @@ +# $TEST$ syntax_error + +function myFunction(): Int, Float {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-annotated result.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-annotated result.sdstest deleted file mode 100644 index 00dbc182..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-annotated result.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -segment mySegment() -> (@Annotation a: Int) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-empty.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-empty.sdstest deleted file mode 100644 index 8a30512c..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-empty.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -segment mySegment() -> () {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-empty.ttsl b/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-empty.ttsl new file mode 100644 index 00000000..4cb76642 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-empty.ttsl @@ -0,0 +1,3 @@ +# $TEST$ no_syntax_error + +function myFunction() {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-multiple results.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-multiple results.sdstest deleted file mode 100644 index 13bcfdb4..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-multiple results.sdstest +++ /dev/null @@ -1,7 +0,0 @@ -// $TEST$ no_syntax_error - -segment mySegment() -> ( - @Annotation a, - b, - c: Int -) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-named result.ttsl b/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-named result.ttsl new file mode 100644 index 00000000..15fab840 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-named result.ttsl @@ -0,0 +1,3 @@ +# $TEST$ no_syntax_error + +function myFunction()a: Int {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-nameless result.ttsl b/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-nameless result.ttsl new file mode 100644 index 00000000..8c0f9b30 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-nameless result.ttsl @@ -0,0 +1,3 @@ +# $TEST$ no_syntax_error + +function myFunction(): Int {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-one typed result (in parentheses).sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-one typed result (in parentheses).sdstest deleted file mode 100644 index 9a380212..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-one typed result (in parentheses).sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -segment mySegment() -> (a: Int) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-one typed result (no parentheses).sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-one typed result (no parentheses).sdstest deleted file mode 100644 index 13940ca8..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-one typed result (no parentheses).sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -segment mySegment() -> a: Int {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-one untyped result (no parentheses).sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-one untyped result (no parentheses).sdstest deleted file mode 100644 index f001e7a3..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-one untyped result (no parentheses).sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -segment mySegment() -> a {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-one untyped result (with parentheses).sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-one untyped result (with parentheses).sdstest deleted file mode 100644 index dfc4ac34..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/results/good-one untyped result (with parentheses).sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -segment mySegment() -> (a) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-missing body.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-missing body.sdstest deleted file mode 100644 index e37a29d5..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-missing body.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -segment mySegment() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-missing parameter list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-missing parameter list.sdstest deleted file mode 100644 index c10c4ad1..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-missing parameter list.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -segment mySegment {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-two visibilities (internal, internal).sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-two visibilities (internal, internal).sdstest deleted file mode 100644 index 619f22a7..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-two visibilities (internal, internal).sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -internal internal segment mySegment() {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-two visibilities (internal, private).sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-two visibilities (internal, private).sdstest deleted file mode 100644 index 27047c8d..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-two visibilities (internal, private).sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -internal private segment mySegment() {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-two visibilities (private, internal).sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-two visibilities (private, internal).sdstest deleted file mode 100644 index 797a58dc..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-two visibilities (private, internal).sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -private internal segment mySegment() {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-two visibilities (private, private).sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-two visibilities (private, private).sdstest deleted file mode 100644 index 0c0f7303..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-two visibilities (private, private).sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -private private segment mySegment() {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-unclosed body.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-unclosed body.sdstest deleted file mode 100644 index 1ba29b8f..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-unclosed body.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -segment mySegment() { diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-unclosed parameter list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-unclosed parameter list.sdstest deleted file mode 100644 index 4312edd1..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-unclosed parameter list.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -segment mySegment( {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-unclosed result list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-unclosed result list.sdstest deleted file mode 100644 index e1884342..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/bad-unclosed result list.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -segment mySegment() -> ( {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-annotation call.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-annotation call.sdstest deleted file mode 100644 index 9d5ef909..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-annotation call.sdstest +++ /dev/null @@ -1,6 +0,0 @@ -// $TEST$ no_syntax_error - -package test - -@Annotation -segment mySegment() {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-internal segment.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-internal segment.sdstest deleted file mode 100644 index 974c3aa4..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-internal segment.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -internal segment mySegment() {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-private segment.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-private segment.sdstest deleted file mode 100644 index de021652..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-private segment.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -private segment mySegment() {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-statements in body.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-statements in body.sdstest deleted file mode 100644 index 0fcc81aa..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-statements in body.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -private segment mySegment() { - val a = 1; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-with constraint list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-with constraint list.sdstest deleted file mode 100644 index 028dd843..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-with constraint list.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -segment mySegment() where {} {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-with parameter list and body.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-with parameter list and body.sdstest deleted file mode 100644 index 538c2b17..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-with parameter list and body.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -segment mySegment() {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-with result list.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-with result list.sdstest deleted file mode 100644 index 8a30512c..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/segments/good-with result list.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -segment mySegment() -> () {} diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/bad-missing comma.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/bad-missing comma.sdstest deleted file mode 100644 index 58d8c50b..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/bad-missing comma.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -fun myFunction() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-annotated type parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-annotated type parameter.sdstest deleted file mode 100644 index 40967e52..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-annotated type parameter.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -fun myFunction<@Annotation T>() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded contravariant optional type parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded contravariant optional type parameter.sdstest deleted file mode 100644 index 243f6366..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded contravariant optional type parameter.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -fun myFunction() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded contravariant required type parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded contravariant required type parameter.sdstest deleted file mode 100644 index 68af9baf..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded contravariant required type parameter.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -fun myFunction() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded covariant optional type parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded covariant optional type parameter.sdstest deleted file mode 100644 index 0e364d12..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded covariant optional type parameter.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -fun myFunction() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded covariant required type parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded covariant required type parameter.sdstest deleted file mode 100644 index 613f0926..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded covariant required type parameter.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -fun myFunction() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded invariant optional type parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded invariant optional type parameter.sdstest deleted file mode 100644 index 93a5eb3d..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded invariant optional type parameter.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -fun myFunction() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded invariant required type parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded invariant required type parameter.sdstest deleted file mode 100644 index e7ce3182..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-bounded invariant required type parameter.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -fun myFunction() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-empty.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-empty.sdstest deleted file mode 100644 index 912dae7a..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-empty.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -fun myFunction<>() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-multiple type parameters.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-multiple type parameters.sdstest deleted file mode 100644 index 5ea557ce..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-multiple type parameters.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -fun myFunction<@Annotation T, in S, out U>() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded contravariant optional type parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded contravariant optional type parameter.sdstest deleted file mode 100644 index 88d30d82..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded contravariant optional type parameter.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -fun myFunction() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded contravariant required type parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded contravariant required type parameter.sdstest deleted file mode 100644 index 180c50e9..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded contravariant required type parameter.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -fun myFunction() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded covariant optional type parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded covariant optional type parameter.sdstest deleted file mode 100644 index 1be49dfd..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded covariant optional type parameter.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -fun myFunction() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded covariant required type parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded covariant required type parameter.sdstest deleted file mode 100644 index c7d1c7e6..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded covariant required type parameter.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -fun myFunction() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded invariant optional type parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded invariant optional type parameter.sdstest deleted file mode 100644 index ab7a2938..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded invariant optional type parameter.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -fun myFunction() diff --git a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded invariant required type parameter.sdstest b/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded invariant required type parameter.sdstest deleted file mode 100644 index 0bda9471..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/declarations/type parameters/good-unbounded invariant required type parameter.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -fun myFunction() diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-addition without left operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-addition without left operator.sdstest deleted file mode 100644 index 93c549ea..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-addition without left operator.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - + 2; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-addition without left operator.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-addition without left operator.ttsl new file mode 100644 index 00000000..32f4b442 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-addition without left operator.ttsl @@ -0,0 +1,5 @@ +# $TEST$ syntax_error + +function myFunction() { + + 2; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-addition without right operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-addition without right operator.sdstest deleted file mode 100644 index 8b6e73af..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-addition without right operator.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - 1 +; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-addition without right operator.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-addition without right operator.ttsl new file mode 100644 index 00000000..c8fcb72a --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-addition without right operator.ttsl @@ -0,0 +1,5 @@ +# $TEST$ syntax_error + +function myFunction() { + 1 +; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-division without left operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-division without left operator.sdstest deleted file mode 100644 index 57a90363..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-division without left operator.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - / 2; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-division without left operator.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-division without left operator.ttsl new file mode 100644 index 00000000..4fc61cfe --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-division without left operator.ttsl @@ -0,0 +1,5 @@ +# $TEST$ syntax_error + +function myFunction() { + / 2; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-division without right operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-division without right operator.sdstest deleted file mode 100644 index 38081c76..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-division without right operator.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - 1 /; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-division without right operator.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-division without right operator.ttsl new file mode 100644 index 00000000..e9e1ea9c --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-division without right operator.ttsl @@ -0,0 +1,5 @@ +# $TEST$ syntax_error + +function myFunction() { + 1 /; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-multiplication without left operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-multiplication without left operator.sdstest deleted file mode 100644 index 60a5900f..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-multiplication without left operator.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - * 2; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-multiplication without left operator.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-multiplication without left operator.ttsl new file mode 100644 index 00000000..d6e7922e --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-multiplication without left operator.ttsl @@ -0,0 +1,5 @@ +# $TEST$ syntax_error + +function myFunction() { + * 2; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-multiplication without right operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-multiplication without right operator.sdstest deleted file mode 100644 index b62d52f6..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-multiplication without right operator.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - 1 *; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-multiplication without right operator.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-multiplication without right operator.ttsl new file mode 100644 index 00000000..20268dbb --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-multiplication without right operator.ttsl @@ -0,0 +1,5 @@ +# $TEST$ syntax_error + +function myFunction() { + 1 *; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-negation without operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-negation without operator.sdstest deleted file mode 100644 index 854267fb..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-negation without operator.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - -; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-negation without operator.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-negation without operator.ttsl new file mode 100644 index 00000000..e153f1fd --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-negation without operator.ttsl @@ -0,0 +1,5 @@ +# $TEST$ syntax_error + +function myFunction() { + -; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-subtraction without right operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-subtraction without right operator.sdstest deleted file mode 100644 index 9dd3c100..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-subtraction without right operator.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - 1 -; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-subtraction without right operator.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-subtraction without right operator.ttsl new file mode 100644 index 00000000..822f4573 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/bad-subtraction without right operator.ttsl @@ -0,0 +1,5 @@ +# $TEST$ syntax_error + +function myFunction() { + 1 -; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-addition.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-addition.sdstest deleted file mode 100644 index f273ef1e..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-addition.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - 1 + 2; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-addition.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-addition.ttsl new file mode 100644 index 00000000..f274268c --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-addition.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function myFunction() { + 1 + 2; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-complex example.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-complex example.sdstest deleted file mode 100644 index 313f34cb..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-complex example.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - (1 + 2) * -3 / (1 - 4) + 5; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-complex example.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-complex example.ttsl new file mode 100644 index 00000000..e58c3390 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-complex example.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function myFunction() { + (1 + 2) * -3 / (1 - 4) + 5; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-division.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-division.sdstest deleted file mode 100644 index ef34e2fd..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-division.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - 1 / 2; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-division.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-division.ttsl new file mode 100644 index 00000000..56aa40f0 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-division.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function myFunction() { + 1 / 2; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-multiplication.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-multiplication.sdstest deleted file mode 100644 index e7b1bfb6..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-multiplication.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - 1 * 2; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-multiplication.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-multiplication.ttsl new file mode 100644 index 00000000..cf502d01 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-multiplication.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function myFunction() { + 1 * 2; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-negation.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-negation.sdstest deleted file mode 100644 index 1974fcb1..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-negation.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - -1; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-negation.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-negation.ttsl new file mode 100644 index 00000000..3e361872 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-negation.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function myFunction() { + -1; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-subtraction.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-subtraction.sdstest deleted file mode 100644 index 7e5f9271..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-subtraction.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - 1 - 2; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-subtraction.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-subtraction.ttsl new file mode 100644 index 00000000..be2dbd3c --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/arithmetic operators/good-subtraction.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function myFunction(){ + 1 - 2; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/block lambdas/bad-unclosed body.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/block lambdas/bad-unclosed body.sdstest deleted file mode 100644 index 53e199fd..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/block lambdas/bad-unclosed body.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - () {; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/block lambdas/bad-unclosed parameter list.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/block lambdas/bad-unclosed parameter list.sdstest deleted file mode 100644 index dd9e7ec5..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/block lambdas/bad-unclosed parameter list.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - ( {}; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/block lambdas/good-filled body.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/block lambdas/good-filled body.sdstest deleted file mode 100644 index de33ac71..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/block lambdas/good-filled body.sdstest +++ /dev/null @@ -1,7 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - () { - val a = 1; - }; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/block lambdas/good-with parameter list and body.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/block lambdas/good-with parameter list and body.sdstest deleted file mode 100644 index 8d1b84da..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/block lambdas/good-with parameter list and body.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - () {}; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/calls/bad-unclosed argument list.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/calls/bad-unclosed argument list.sdstest deleted file mode 100644 index 181da152..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/calls/bad-unclosed argument list.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - f(; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/calls/bad-unclosed argument list.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/calls/bad-unclosed argument list.ttsl new file mode 100644 index 00000000..6102e4ee --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/calls/bad-unclosed argument list.ttsl @@ -0,0 +1,5 @@ +# $TEST$ syntax_error + +function myFunction() { + f(; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-mixed positional and named arguments.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-mixed positional and named arguments.sdstest deleted file mode 100644 index 5d992779..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-mixed positional and named arguments.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - f(1, b = 2); -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-mixed positional and named arguments.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-mixed positional and named arguments.ttsl new file mode 100644 index 00000000..775c2895 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-mixed positional and named arguments.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function myFunction() { + f(1, b = 2); +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-named argument.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-named argument.sdstest deleted file mode 100644 index f0e4ce7b..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-named argument.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - f(b = 2); -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-named argument.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-named argument.ttsl new file mode 100644 index 00000000..2b20758e --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-named argument.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function myFunction() { + f(b = 2); +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-no arguments.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-no arguments.sdstest deleted file mode 100644 index 6cd2261b..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-no arguments.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - f(); -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-no arguments.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-no arguments.ttsl new file mode 100644 index 00000000..873e8f10 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-no arguments.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function myFunction() { + f(); +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-null safe.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-null safe.sdstest deleted file mode 100644 index 48ef60ec..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-null safe.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - f?(1); -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-null safe.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-null safe.ttsl new file mode 100644 index 00000000..907a4c97 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-null safe.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function myFunction() { + f?(1); +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-positional argument.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-positional argument.sdstest deleted file mode 100644 index 67090259..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-positional argument.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - f(1); -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-positional argument.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-positional argument.ttsl new file mode 100644 index 00000000..311693f8 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/calls/good-positional argument.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function myFunction() { + f(1); +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than or equal without left operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than or equal without left operator.sdstest deleted file mode 100644 index 0f192c49..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than or equal without left operator.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - >= 2; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than or equal without left operator.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than or equal without left operator.ttsl new file mode 100644 index 00000000..c39930f1 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than or equal without left operator.ttsl @@ -0,0 +1,5 @@ +# $TEST$ syntax_error + +function myFunction() { + >= 2; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than or equal without right operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than or equal without right operator.sdstest deleted file mode 100644 index 5985c39b..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than or equal without right operator.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - 1 >=; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than or equal without right operator.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than or equal without right operator.ttsl new file mode 100644 index 00000000..fee4089c --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than or equal without right operator.ttsl @@ -0,0 +1,5 @@ +# $TEST$ syntax_error + +function myFunction () { + 1 >=; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than without left operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than without left operator.sdstest deleted file mode 100644 index 0a66c978..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than without left operator.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - > 2; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than without left operator.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than without left operator.ttsl new file mode 100644 index 00000000..d9fe6e56 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than without left operator.ttsl @@ -0,0 +1,5 @@ +# $TEST$ syntax_error + +function myFunction () { + > 2; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than without right operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than without right operator.sdstest deleted file mode 100644 index bb733c94..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than without right operator.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - 1 >; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than without right operator.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than without right operator.ttsl new file mode 100644 index 00000000..e9ae7229 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-greater than without right operator.ttsl @@ -0,0 +1,5 @@ +# $TEST$ syntax_error + +function myFunction () { + 1 >; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than or equal without left operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than or equal without left operator.sdstest deleted file mode 100644 index 7e6d0416..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than or equal without left operator.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - <= 2; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than or equal without left operator.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than or equal without left operator.ttsl new file mode 100644 index 00000000..4d1d3395 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than or equal without left operator.ttsl @@ -0,0 +1,5 @@ +# $TEST$ syntax_error + +function myFunction () { + <= 2; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than or equal without right operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than or equal without right operator.sdstest deleted file mode 100644 index 1beda50d..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than or equal without right operator.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - 1 <=; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than or equal without right operator.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than or equal without right operator.ttsl new file mode 100644 index 00000000..f44a196f --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than or equal without right operator.ttsl @@ -0,0 +1,5 @@ +# $TEST$ syntax_error + +function myFunction () { + 1 <=; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than without left operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than without left operator.sdstest deleted file mode 100644 index 4fe72792..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than without left operator.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - < 2; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than without left operator.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than without left operator.ttsl new file mode 100644 index 00000000..9a7bc89e --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than without left operator.ttsl @@ -0,0 +1,5 @@ +# $TEST$ syntax_error + +function myFunction () { + < 2; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than without right operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than without right operator.sdstest deleted file mode 100644 index da8a9126..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than without right operator.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - 1 <; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than without right operator.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than without right operator.ttsl new file mode 100644 index 00000000..da10cf03 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/bad-less than without right operator.ttsl @@ -0,0 +1,5 @@ +# $TEST$ syntax_error + +function myFunction () { + 1 <; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-greater than or equal.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-greater than or equal.sdstest deleted file mode 100644 index b307ff91..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-greater than or equal.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - 1 >= 2; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-greater than or equal.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-greater than or equal.ttsl new file mode 100644 index 00000000..68444552 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-greater than or equal.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function myFunction () { + 1 >= 2; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-greater than.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-greater than.sdstest deleted file mode 100644 index 72d16eac..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-greater than.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - 1 > 2; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-greater than.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-greater than.ttsl new file mode 100644 index 00000000..43362a0f --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-greater than.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function myFunction () { + 1 > 2; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-less than or equal.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-less than or equal.sdstest deleted file mode 100644 index 27e5caf2..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-less than or equal.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - 1 <= 2; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-less than or equal.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-less than or equal.ttsl new file mode 100644 index 00000000..fe3e1ab7 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-less than or equal.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function myFunction () { + 1 <= 2; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-less than.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-less than.sdstest deleted file mode 100644 index fc782e89..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-less than.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - 1 < 2; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-less than.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-less than.ttsl new file mode 100644 index 00000000..3b2e5250 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/comparison operators/good-less than.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function myFunction () { + 1 < 2; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/bad-without left operand.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/bad-without left operand.sdstest deleted file mode 100644 index f698fb17..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/bad-without left operand.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - ?: Int; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/bad-without left operand.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/bad-without left operand.ttsl new file mode 100644 index 00000000..d43a7601 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/bad-without left operand.ttsl @@ -0,0 +1,5 @@ +# $TEST$ syntax_error + +function myFunction () { + ?: Int; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/bad-without right operand.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/bad-without right operand.sdstest deleted file mode 100644 index 2c3bf116..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/bad-without right operand.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - 1 ?:; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/bad-without right operand.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/bad-without right operand.ttsl new file mode 100644 index 00000000..a35963fb --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/bad-without right operand.ttsl @@ -0,0 +1,5 @@ +# $TEST$ syntax_error + +function myFunction () { + 1 ?:; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/good-basic.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/good-basic.sdstest deleted file mode 100644 index 5aaea6c8..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/good-basic.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - null ?: 1; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/good-basic.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/good-basic.ttsl new file mode 100644 index 00000000..db76e143 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/good-basic.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function myFunction () { + null ?: 1; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/good-chained.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/good-chained.sdstest deleted file mode 100644 index 9b6a1240..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/good-chained.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - null ?: null ?: 1; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/good-chained.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/good-chained.ttsl new file mode 100644 index 00000000..579daec8 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/elvis operators/good-chained.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function myFunction () { + null ?: null ?: 1; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-equal without left operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-equal without left operator.sdstest deleted file mode 100644 index 6f529e44..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-equal without left operator.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - == 2; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-equal without left operator.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-equal without left operator.ttsl new file mode 100644 index 00000000..caec4f0e --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-equal without left operator.ttsl @@ -0,0 +1,5 @@ +# $TEST$ syntax_error + +function myFunction () { + == 2; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-equal without right operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-equal without right operator.sdstest deleted file mode 100644 index 37613704..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-equal without right operator.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - 1 ==; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-equal without right operator.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-equal without right operator.ttsl new file mode 100644 index 00000000..25ea625c --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-equal without right operator.ttsl @@ -0,0 +1,5 @@ +# $TEST$ syntax_error + +function myFunction () { + 1 ==; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-identical without left operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-identical without left operator.sdstest deleted file mode 100644 index 7c15456a..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-identical without left operator.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - === 2; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-identical without left operator.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-identical without left operator.ttsl new file mode 100644 index 00000000..67fe37a2 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-identical without left operator.ttsl @@ -0,0 +1,5 @@ +# $TEST$ syntax_error + +function myFunction () { + === 2; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-identical without right operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-identical without right operator.sdstest deleted file mode 100644 index 333baa79..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-identical without right operator.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - 1 ===; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-identical without right operator.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-identical without right operator.ttsl new file mode 100644 index 00000000..2937da0f --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-identical without right operator.ttsl @@ -0,0 +1,5 @@ +# $TEST$ syntax_error + +function myFunction () { + 1 ===; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not equal without left operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not equal without left operator.sdstest deleted file mode 100644 index c75d3f48..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not equal without left operator.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - != 2; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not equal without left operator.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not equal without left operator.ttsl new file mode 100644 index 00000000..d7fe43c2 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not equal without left operator.ttsl @@ -0,0 +1,5 @@ +# $TEST$ syntax_error + +function myFunction () { + != 2; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not equal without right operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not equal without right operator.sdstest deleted file mode 100644 index 6fbeacce..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not equal without right operator.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - 1 !=; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not equal without right operator.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not equal without right operator.ttsl new file mode 100644 index 00000000..2e034926 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not equal without right operator.ttsl @@ -0,0 +1,5 @@ +# $TEST$ syntax_error + +function myFunction () { + 1 !=; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not identical without left operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not identical without left operator.sdstest deleted file mode 100644 index 2e92a031..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not identical without left operator.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - 1 !==; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not identical without left operator.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not identical without left operator.ttsl new file mode 100644 index 00000000..38bf0cdc --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not identical without left operator.ttsl @@ -0,0 +1,5 @@ +# $TEST$ syntax_error + +function myFunction () { + 1 !==; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not identical without right operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not identical without right operator.sdstest deleted file mode 100644 index 2e92a031..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not identical without right operator.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - 1 !==; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not identical without right operator.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not identical without right operator.ttsl new file mode 100644 index 00000000..38bf0cdc --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/bad-not identical without right operator.ttsl @@ -0,0 +1,5 @@ +# $TEST$ syntax_error + +function myFunction () { + 1 !==; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-equal.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-equal.sdstest deleted file mode 100644 index ab608294..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-equal.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - 1 == 2; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-equal.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-equal.ttsl new file mode 100644 index 00000000..a3b2597f --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-equal.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function myFunction () { + 1 == 2; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-identical.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-identical.sdstest deleted file mode 100644 index cc17d2bf..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-identical.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - 1 === 2; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-identical.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-identical.ttsl new file mode 100644 index 00000000..ce50f3c3 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-identical.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function myFunction () { + 1 === 2; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-not equal.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-not equal.sdstest deleted file mode 100644 index 66b7ffeb..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-not equal.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - 1 != 2; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-not equal.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-not equal.ttsl new file mode 100644 index 00000000..acbcc131 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-not equal.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function myFunction () { + 1 != 2; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-not identical.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-not identical.sdstest deleted file mode 100644 index 1f897170..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-not identical.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - 1 !== 2; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-not identical.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-not identical.ttsl new file mode 100644 index 00000000..7fd53052 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/equality operators/good-not identical.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function myFunction () { + 1 !== 2; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/expression lambdas/bad-missing body.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/expression lambdas/bad-missing body.sdstest deleted file mode 100644 index 0ab44dbd..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/expression lambdas/bad-missing body.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - () ->; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/expression lambdas/bad-unclosed parameter list.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/expression lambdas/bad-unclosed parameter list.sdstest deleted file mode 100644 index 9568407b..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/expression lambdas/bad-unclosed parameter list.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - ( -> 1; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/expression lambdas/good-with parameter list and expression.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/expression lambdas/good-with parameter list and expression.sdstest deleted file mode 100644 index 77b37f42..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/expression lambdas/good-with parameter list and expression.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - () -> 1; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/good-complex chained expression.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/good-complex chained expression.sdstest deleted file mode 100644 index d9277deb..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/good-complex chained expression.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - a.member?.f()[1]; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/good-reference.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/good-reference.sdstest deleted file mode 100644 index 36197610..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/good-reference.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - a; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/good-reference.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/good-reference.ttsl new file mode 100644 index 00000000..4d2fe5ea --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/good-reference.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function myFunction() { + a; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/bad-no index.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/bad-no index.sdstest deleted file mode 100644 index 9dac005b..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/bad-no index.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -pipeline test { - a[]; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/bad-no index.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/bad-no index.ttsl new file mode 100644 index 00000000..c277635a --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/bad-no index.ttsl @@ -0,0 +1,5 @@ +# $TEST$ syntax_error + +function test () { + a[]; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/bad-unclosed square bracket.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/bad-unclosed square bracket.sdstest deleted file mode 100644 index 7248c7b5..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/bad-unclosed square bracket.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -pipeline test { - a[1; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/bad-unclosed square bracket.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/bad-unclosed square bracket.ttsl new file mode 100644 index 00000000..9f30f80d --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/bad-unclosed square bracket.ttsl @@ -0,0 +1,5 @@ +# $TEST$ syntax_error + +function test () { + a[1; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/good-literal index.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/good-literal index.sdstest deleted file mode 100644 index ff4ae34b..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/good-literal index.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline test { - a[1]; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/good-literal index.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/good-literal index.ttsl new file mode 100644 index 00000000..f623f510 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/good-literal index.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function test () { + a[1]; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/good-null safe.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/good-null safe.sdstest deleted file mode 100644 index 7327f075..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/good-null safe.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline test { - a?[1]; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/good-null safe.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/good-null safe.ttsl new file mode 100644 index 00000000..6128754d --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/good-null safe.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function test () { + a?[1]; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/good-reference index.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/good-reference index.sdstest deleted file mode 100644 index 6dafc20c..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/good-reference index.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline test { - a[b]; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/good-reference index.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/good-reference index.ttsl new file mode 100644 index 00000000..1177ce0d --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/indexed accesses/good-reference index.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function test () { + a[b]; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/lists/bad-unclosed square bracket.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/lists/bad-unclosed square bracket.sdstest deleted file mode 100644 index 2a991668..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/lists/bad-unclosed square bracket.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - [1; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/lists/bad-unclosed square bracket.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/lists/bad-unclosed square bracket.ttsl new file mode 100644 index 00000000..67224281 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/lists/bad-unclosed square bracket.ttsl @@ -0,0 +1,5 @@ +# $TEST$ syntax_error + +function myFunction () { + [1; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-nested multiple elements.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-nested multiple elements.sdstest deleted file mode 100644 index 0676978c..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-nested multiple elements.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - [[1, 2]]; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-nested multiple elements.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-nested multiple elements.ttsl new file mode 100644 index 00000000..bd11628b --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-nested multiple elements.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function myFunction () { + [[1, 2]]; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-nested one element.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-nested one element.sdstest deleted file mode 100644 index 9edb2c2f..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-nested one element.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - [[1 + 2]]; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-nested one element.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-nested one element.ttsl new file mode 100644 index 00000000..25fffeff --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-nested one element.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function myFunction () { + [[1 + 2]]; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-one level multiple elements.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-one level multiple elements.sdstest deleted file mode 100644 index 5327782b..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-one level multiple elements.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - [1, 2]; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-one level multiple elements.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-one level multiple elements.ttsl new file mode 100644 index 00000000..4eb7e0a8 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-one level multiple elements.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function myFunction () { + [1, 2]; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-one level one element.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-one level one element.sdstest deleted file mode 100644 index 2f0593a4..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-one level one element.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - [1 + 2]; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-one level one element.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-one level one element.ttsl new file mode 100644 index 00000000..30dcb6a1 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/lists/good-one level one element.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function myFunction () { + [1 + 2]; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/bad-no digits before dot.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/bad-no digits before dot.sdstest deleted file mode 100644 index ae5accd1..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/bad-no digits before dot.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - .2; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/bad-no digits before dot.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/bad-no digits before dot.ttsl new file mode 100644 index 00000000..c2a78193 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/bad-no digits before dot.ttsl @@ -0,0 +1,5 @@ +# $TEST$ syntax_error + +function myFunction () { + .2; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/good-basic example.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/good-basic example.ttsl similarity index 66% rename from packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/good-basic example.sdstest rename to packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/good-basic example.ttsl index 0a1139ef..17c0df96 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/good-basic example.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/good-basic example.ttsl @@ -1,6 +1,6 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error -pipeline myPipeline { +function myFunction () { 1.2; 1e10; diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/good-scientific notation with lowercase e.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/good-scientific notation with lowercase e.sdstest deleted file mode 100644 index 487983bc..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/good-scientific notation with lowercase e.sdstest +++ /dev/null @@ -1,8 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - 1e10; - 1e+10; - 1e-10; - 1.2e2; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/good-scientific notation with lowercase e.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/good-scientific notation with lowercase e.ttsl new file mode 100644 index 00000000..816e0b49 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/good-scientific notation with lowercase e.ttsl @@ -0,0 +1,8 @@ +# $TEST$ no_syntax_error + +function myFunction () { + 1e10; + 1e+10; + 1e-10; + 1.2e2; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/good-scientific notation with uppercase e.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/good-scientific notation with uppercase e.sdstest deleted file mode 100644 index 351d43ce..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/good-scientific notation with uppercase e.sdstest +++ /dev/null @@ -1,8 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - 1E10; - 1E+10; - 1E-10; - 1.2E2; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/good-scientific notation with uppercase e.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/good-scientific notation with uppercase e.ttsl new file mode 100644 index 00000000..6789d000 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/float/good-scientific notation with uppercase e.ttsl @@ -0,0 +1,8 @@ +# $TEST$ no_syntax_error + +function myFunction () { + 1E10; + 1E+10; + 1E-10; + 1.2E2; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/good-false.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/good-false.sdstest deleted file mode 100644 index efe0d586..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/good-false.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - false; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/good-false.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/good-false.ttsl new file mode 100644 index 00000000..eb21b470 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/good-false.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function myFunction () { + false; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/good-null.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/good-null.sdstest deleted file mode 100644 index f5ff60a7..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/good-null.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - null; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/good-null.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/good-null.ttsl new file mode 100644 index 00000000..574adb0d --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/good-null.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function myFunction () { + null; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/good-true.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/good-true.sdstest deleted file mode 100644 index 58d43666..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/good-true.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - true; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/good-true.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/good-true.ttsl new file mode 100644 index 00000000..dfd149ce --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/good-true.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function myFunction () { + true; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/int/good-leading zero.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/int/good-leading zero.sdstest deleted file mode 100644 index c37f760a..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/int/good-leading zero.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - 01; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/int/good-leading zero.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/int/good-leading zero.ttsl new file mode 100644 index 00000000..3ab88aaa --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/int/good-leading zero.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function myFunction () { + 01; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/int/good-multiple digits.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/int/good-multiple digits.sdstest deleted file mode 100644 index 509aab5b..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/int/good-multiple digits.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - 1234567890; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/int/good-multiple digits.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/int/good-multiple digits.ttsl new file mode 100644 index 00000000..a482c1d0 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/int/good-multiple digits.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function myFunction () { + 1234567890; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/int/good-one digit.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/int/good-one digit.sdstest deleted file mode 100644 index 9c748058..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/int/good-one digit.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - 1; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/int/good-one digit.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/int/good-one digit.ttsl new file mode 100644 index 00000000..54954803 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/int/good-one digit.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function myFunction () { + 1; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/bad-single quotes as delimiters.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/bad-single quotes as delimiters.sdstest deleted file mode 100644 index 8b4551d6..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/bad-single quotes as delimiters.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - ''; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/bad-single quotes as delimiters.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/bad-single quotes as delimiters.ttsl new file mode 100644 index 00000000..19e1043d --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/bad-single quotes as delimiters.ttsl @@ -0,0 +1,5 @@ +# $TEST$ syntax_error + +function myFunction () { + ''; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/bad-unclosed quote.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/bad-unclosed quote.sdstest deleted file mode 100644 index 36f8d414..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/bad-unclosed quote.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - "; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/bad-unclosed quote.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/bad-unclosed quote.ttsl new file mode 100644 index 00000000..b01653ee --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/bad-unclosed quote.ttsl @@ -0,0 +1,5 @@ +# $TEST$ syntax_error + +function myFunction () { + "; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-basic content.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-basic content.sdstest deleted file mode 100644 index 79cefed4..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-basic content.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - "myString"; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-basic content.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-basic content.ttsl new file mode 100644 index 00000000..8ea3579b --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-basic content.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function myFunction () { + "myString"; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-closing template expression delimiter.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-closing template expression delimiter.sdstest deleted file mode 100644 index 7f7c2dca..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-closing template expression delimiter.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - "}}"; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-closing template expression delimiter.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-closing template expression delimiter.ttsl new file mode 100644 index 00000000..5d06fd4b --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-closing template expression delimiter.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function myFunction () { + "}}"; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-curly braces separated by space.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-curly braces separated by space.sdstest deleted file mode 100644 index f12997d1..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-curly braces separated by space.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - "{ {"; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-curly braces separated by space.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-curly braces separated by space.ttsl new file mode 100644 index 00000000..9a219c6b --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-curly braces separated by space.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function myFunction () { + "{ {"; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-empty.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-empty.sdstest deleted file mode 100644 index dafae1fe..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-empty.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - ""; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-empty.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-empty.ttsl new file mode 100644 index 00000000..9416f329 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-empty.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function myFunction () { + ""; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-escaped curly brace.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-escaped curly brace.sdstest deleted file mode 100644 index cd8f0e48..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-escaped curly brace.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - "\{{"; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-escaped curly brace.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-escaped curly brace.ttsl new file mode 100644 index 00000000..a84f590e --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-escaped curly brace.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function myFunction () { + "\{{"; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-multiple lines.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-multiple lines.ttsl similarity index 53% rename from packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-multiple lines.sdstest rename to packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-multiple lines.ttsl index 64768bc4..94962a24 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-multiple lines.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-multiple lines.ttsl @@ -1,6 +1,6 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error -pipeline myPipeline { +function myFunction () { " multi line diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-newline escape sequence.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-newline escape sequence.sdstest deleted file mode 100644 index 7104ee86..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-newline escape sequence.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - "\n"; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-newline escape sequence.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-newline escape sequence.ttsl new file mode 100644 index 00000000..b390f126 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-newline escape sequence.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function myFunction () { + "\n"; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-single curly brace.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-single curly brace.sdstest deleted file mode 100644 index f9e7f60d..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-single curly brace.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - "{"; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-single curly brace.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-single curly brace.ttsl new file mode 100644 index 00000000..24feaeec --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-single curly brace.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function myFunction () { + "{"; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-single quote.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-single quote.sdstest deleted file mode 100644 index ac7a4af3..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-single quote.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - "'"; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-single quote.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-single quote.ttsl new file mode 100644 index 00000000..a4522c3e --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-single quote.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function myFunction () { + "'"; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-unicode escape sequence.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-unicode escape sequence.sdstest deleted file mode 100644 index f808b694..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-unicode escape sequence.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - "\u000c"; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-unicode escape sequence.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-unicode escape sequence.ttsl new file mode 100644 index 00000000..b31aff96 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/literals/string/good-unicode escape sequence.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function myFunction () { + "\u000c"; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-conjunction without left operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-conjunction without left operator.sdstest deleted file mode 100644 index c8e3415b..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-conjunction without left operator.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - and true; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-conjunction without left operator.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-conjunction without left operator.ttsl new file mode 100644 index 00000000..6393e567 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-conjunction without left operator.ttsl @@ -0,0 +1,5 @@ +# $TEST$ syntax_error + +function myFunction () { + and true; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-conjunction without right operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-conjunction without right operator.sdstest deleted file mode 100644 index 3da7f5c0..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-conjunction without right operator.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - false and; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-conjunction without right operator.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-conjunction without right operator.ttsl new file mode 100644 index 00000000..0939a6bc --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-conjunction without right operator.ttsl @@ -0,0 +1,5 @@ +# $TEST$ syntax_error + +function myFunction () { + false and; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-disjunction without left operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-disjunction without left operator.sdstest deleted file mode 100644 index 677b31b4..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-disjunction without left operator.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - or true; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-disjunction without left operator.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-disjunction without left operator.ttsl new file mode 100644 index 00000000..44bcc676 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-disjunction without left operator.ttsl @@ -0,0 +1,5 @@ +# $TEST$ syntax_error + +function myFunction () { + or true; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-disjunction without right operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-disjunction without right operator.sdstest deleted file mode 100644 index 13971f94..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-disjunction without right operator.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - true or; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-disjunction without right operator.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-disjunction without right operator.ttsl new file mode 100644 index 00000000..86082ba1 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-disjunction without right operator.ttsl @@ -0,0 +1,5 @@ +# $TEST$ syntax_error + +function myFunction () { + true or; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-negation without operator.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-negation without operator.sdstest deleted file mode 100644 index 854267fb..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-negation without operator.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - -; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-negation without operator.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-negation without operator.ttsl new file mode 100644 index 00000000..d5a2fa5f --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/bad-negation without operator.ttsl @@ -0,0 +1,5 @@ +# $TEST$ syntax_error + +function myFunction () { + -; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-complex example.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-complex example.sdstest deleted file mode 100644 index 0a12be46..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-complex example.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - not true and false or true; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-complex example.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-complex example.ttsl new file mode 100644 index 00000000..18e73dbf --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-complex example.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function myFunction () { + not true and false or true; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-conjunction.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-conjunction.sdstest deleted file mode 100644 index 89fea66f..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-conjunction.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - false and true; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-conjunction.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-conjunction.ttsl new file mode 100644 index 00000000..f00b99ad --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-conjunction.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function myFunction () { + false and true; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-disjunction.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-disjunction.sdstest deleted file mode 100644 index 271891b9..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-disjunction.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - true or true; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-disjunction.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-disjunction.ttsl new file mode 100644 index 00000000..147e5c7d --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-disjunction.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function myFunction () { + true or true; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-negation.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-negation.sdstest deleted file mode 100644 index 30790c5d..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-negation.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - not true; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-negation.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-negation.ttsl new file mode 100644 index 00000000..518a167e --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/logical operations/good-negation.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function myFunction () { + not true; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-no colon.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-no colon.sdstest deleted file mode 100644 index 62ec6038..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-no colon.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - {1 "one"}; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-no colon.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-no colon.ttsl new file mode 100644 index 00000000..cfdd4325 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-no colon.ttsl @@ -0,0 +1,5 @@ +# $TEST$ syntax_error + +function myFunction () { + {1 "one"}; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-no key.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-no key.sdstest deleted file mode 100644 index 74ffc56e..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-no key.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - {: "one"}; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-no key.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-no key.ttsl new file mode 100644 index 00000000..61460f37 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-no key.ttsl @@ -0,0 +1,5 @@ +# $TEST$ syntax_error + +function myFunction () { + {: "one"}; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-no value.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-no value.sdstest deleted file mode 100644 index 3b6dbb19..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-no value.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - {1: }; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-no value.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-no value.ttsl new file mode 100644 index 00000000..b2b506ef --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-no value.ttsl @@ -0,0 +1,5 @@ +# $TEST$ syntax_error + +function myFunction () { + {1: }; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-unclosed curly brace.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-unclosed curly brace.sdstest deleted file mode 100644 index d87b4d94..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-unclosed curly brace.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - {1: "one"; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-unclosed curly brace.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-unclosed curly brace.ttsl new file mode 100644 index 00000000..af286087 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/maps/bad-unclosed curly brace.ttsl @@ -0,0 +1,5 @@ +# $TEST$ syntax_error + +function myFunction () { + {1: "one"; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-nested multiple elements.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-nested multiple elements.ttsl similarity index 62% rename from packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-nested multiple elements.sdstest rename to packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-nested multiple elements.ttsl index e53c86eb..928472df 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-nested multiple elements.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-nested multiple elements.ttsl @@ -1,6 +1,6 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error -pipeline myPipeline { +function myFunction () { { 1: { 2: "three", diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-nested one element.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-nested one element.ttsl similarity index 55% rename from packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-nested one element.sdstest rename to packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-nested one element.ttsl index 81c26373..d5f972f7 100644 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-nested one element.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-nested one element.ttsl @@ -1,6 +1,6 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error -pipeline myPipeline { +function myFunction () { { 1: { 2: "three" diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-one level multiple elements.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-one level multiple elements.sdstest deleted file mode 100644 index cb179d9b..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-one level multiple elements.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - {1: "one", 2: "two"}; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-one level multiple elements.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-one level multiple elements.ttsl new file mode 100644 index 00000000..cfba5736 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-one level multiple elements.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function myFunction () { + {1: "one", 2: "two"}; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-one level one element.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-one level one element.sdstest deleted file mode 100644 index 32922ba0..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-one level one element.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - {1: "one"}; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-one level one element.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-one level one element.ttsl new file mode 100644 index 00000000..1b5b2ce5 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/maps/good-one level one element.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function myFunction () { + {1: "one"}; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/member accesses/bad-no receiver.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/member accesses/bad-no receiver.sdstest deleted file mode 100644 index f21bdfb4..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/member accesses/bad-no receiver.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - .member; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/member accesses/good-not nullable.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/member accesses/good-not nullable.sdstest deleted file mode 100644 index 0143e79a..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/member accesses/good-not nullable.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - a.member; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/member accesses/good-nullable.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/member accesses/good-nullable.sdstest deleted file mode 100644 index 1a9b8c15..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/member accesses/good-nullable.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - a?.member; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/parenthesized expressions/bad-unclosed parenthesis.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/parenthesized expressions/bad-unclosed parenthesis.sdstest deleted file mode 100644 index 96a1dce5..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/parenthesized expressions/bad-unclosed parenthesis.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - (1; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/parenthesized expressions/good-nested.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/parenthesized expressions/good-nested.sdstest deleted file mode 100644 index 5b210c27..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/parenthesized expressions/good-nested.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - ((1 + 2)); -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/parenthesized expressions/good-one level.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/parenthesized expressions/good-one level.sdstest deleted file mode 100644 index 631db9b5..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/parenthesized expressions/good-one level.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - (1 + 2); -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/template strings/bad-template string with invalid expression.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/template strings/bad-template string with invalid expression.sdstest deleted file mode 100644 index a34d0a56..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/template strings/bad-template string with invalid expression.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - "{{ ??? }}"; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/template strings/bad-template string with invalid expression.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/template strings/bad-template string with invalid expression.ttsl new file mode 100644 index 00000000..ca3ac3ce --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/template strings/bad-template string with invalid expression.ttsl @@ -0,0 +1,5 @@ +# $TEST$ syntax_error + +function myFunction () { + "{{ ??? }}"; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/template strings/bad-unclosed template expression.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/template strings/bad-unclosed template expression.sdstest deleted file mode 100644 index 6c4e7f08..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/template strings/bad-unclosed template expression.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - "{{"; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/template strings/bad-unclosed template expression.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/template strings/bad-unclosed template expression.ttsl new file mode 100644 index 00000000..749868ac --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/template strings/bad-unclosed template expression.ttsl @@ -0,0 +1,5 @@ +# $TEST$ syntax_error + +function myFunction () { + "{{"; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/template strings/good-empty template expression.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/template strings/good-empty template expression.sdstest deleted file mode 100644 index 064cfd44..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/template strings/good-empty template expression.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - "{{ }}"; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/template strings/good-empty template expression.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/template strings/good-empty template expression.ttsl new file mode 100644 index 00000000..42392d2c --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/template strings/good-empty template expression.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function myFunction () { + "{{ }}"; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/template strings/good-template string with basic expression.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/template strings/good-template string with basic expression.sdstest deleted file mode 100644 index fc8d3666..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/template strings/good-template string with basic expression.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - "{{ 1 }}"; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/template strings/good-template string with basic expression.ttsl b/packages/ttsl-lang/tests/resources/grammar/expressions/template strings/good-template string with basic expression.ttsl new file mode 100644 index 00000000..832c4427 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/expressions/template strings/good-template string with basic expression.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function myFunction () { + "{{ 1 }}"; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/type casts/bad-without expression.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/type casts/bad-without expression.sdstest deleted file mode 100644 index f7461212..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/type casts/bad-without expression.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - as Int; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/type casts/bad-without type.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/type casts/bad-without type.sdstest deleted file mode 100644 index 604895a0..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/type casts/bad-without type.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - 1 as; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/type casts/good-basic.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/type casts/good-basic.sdstest deleted file mode 100644 index 7c845dd8..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/type casts/good-basic.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - 1 as Int; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/expressions/type casts/good-chained.sdstest b/packages/ttsl-lang/tests/resources/grammar/expressions/type casts/good-chained.sdstest deleted file mode 100644 index ca2f5a76..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/expressions/type casts/good-chained.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - 1 as Int as String; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped _.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped _.sdstest deleted file mode 100644 index 84288017..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped _.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -class _ diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped and.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped and.sdstest deleted file mode 100644 index 085b54b3..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped and.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -class and diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped and.ttsl b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped and.ttsl new file mode 100644 index 00000000..9f2804fd --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped and.ttsl @@ -0,0 +1,3 @@ +# $TEST$ syntax_error + +function and (){} diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped annotation.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped annotation.sdstest deleted file mode 100644 index 89340ecc..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped annotation.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -class annotation diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped as.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped as.sdstest deleted file mode 100644 index 89c7cfad..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped as.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -class as diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped as.ttsl b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped as.ttsl new file mode 100644 index 00000000..597265fc --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped as.ttsl @@ -0,0 +1,3 @@ +# $TEST$ syntax_error + +function as (){} diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped attr.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped attr.sdstest deleted file mode 100644 index 95b2ac0b..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped attr.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -class attr diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped class.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped class.sdstest deleted file mode 100644 index 84293707..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped class.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -class class diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped const.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped const.sdstest deleted file mode 100644 index b310364a..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped const.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -class const diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped constant.ttsl b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped constant.ttsl new file mode 100644 index 00000000..4e87eb21 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped constant.ttsl @@ -0,0 +1,3 @@ +# $TEST$ syntax_error + +function constant (){} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped enum.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped enum.sdstest deleted file mode 100644 index 5fd6ae41..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped enum.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -class enum diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped false.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped false.sdstest deleted file mode 100644 index 9a8c9b3f..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped false.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -class false diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped false.ttsl b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped false.ttsl new file mode 100644 index 00000000..326c079f --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped false.ttsl @@ -0,0 +1,3 @@ +# $TEST$ syntax_error + +function false (){} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped fun.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped fun.sdstest deleted file mode 100644 index edea3480..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped fun.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -class fun diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped function.ttsl b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped function.ttsl new file mode 100644 index 00000000..98a163f8 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped function.ttsl @@ -0,0 +1,3 @@ +# $TEST$ syntax_error + +function function (){} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped import.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped import.sdstest deleted file mode 100644 index e7c5c26c..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped import.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -class import diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped import.ttsl b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped import.ttsl new file mode 100644 index 00000000..b93b7819 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped import.ttsl @@ -0,0 +1,3 @@ +# $TEST$ syntax_error + +function import (){} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped in.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped in.sdstest deleted file mode 100644 index fb6e6099..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped in.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -class in diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped internal.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped internal.sdstest deleted file mode 100644 index 68b05ffe..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped internal.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -class internal diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped literal.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped literal.sdstest deleted file mode 100644 index 8578433b..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped literal.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -class literal diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped not.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped not.sdstest deleted file mode 100644 index 0a99c29f..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped not.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -class not diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped not.ttsl b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped not.ttsl new file mode 100644 index 00000000..6bb9be15 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped not.ttsl @@ -0,0 +1,3 @@ +# $TEST$ syntax_error + +function not (){} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped null.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped null.sdstest deleted file mode 100644 index 40d2934f..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped null.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -class null diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped null.ttsl b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped null.ttsl new file mode 100644 index 00000000..d8323b28 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped null.ttsl @@ -0,0 +1,3 @@ +# $TEST$ syntax_error + +function null (){} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped or.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped or.sdstest deleted file mode 100644 index 2e8b7582..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped or.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -class or diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped or.ttsl b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped or.ttsl new file mode 100644 index 00000000..e8284b55 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped or.ttsl @@ -0,0 +1,3 @@ +# $TEST$ syntax_error + +function or (){} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped out.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped out.sdstest deleted file mode 100644 index cda025c1..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped out.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -class out diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped package.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped package.sdstest deleted file mode 100644 index 65ef3c09..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped package.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -class package diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped package.ttsl b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped package.ttsl new file mode 100644 index 00000000..70cb2b6a --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped package.ttsl @@ -0,0 +1,3 @@ +# $TEST$ syntax_error + +function package (){} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped pipeline.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped pipeline.sdstest deleted file mode 100644 index e28d5204..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped pipeline.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -class pipeline diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped private.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped private.sdstest deleted file mode 100644 index f701b4bc..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped private.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -class private diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped private.ttsl b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped private.ttsl new file mode 100644 index 00000000..bfc514d4 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped private.ttsl @@ -0,0 +1,3 @@ +# $TEST$ syntax_error + +function private (){} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped schema.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped schema.sdstest deleted file mode 100644 index bc788c52..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped schema.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -class schema diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped segment.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped segment.sdstest deleted file mode 100644 index 5327bb38..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped segment.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -class segment diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped static.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped static.sdstest deleted file mode 100644 index 4084a2ce..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped static.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -class static diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped sub.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped sub.sdstest deleted file mode 100644 index 0cc3a750..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped sub.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -class sub diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped true.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped true.sdstest deleted file mode 100644 index 810fbb1b..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped true.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -class true diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped true.ttsl b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped true.ttsl new file mode 100644 index 00000000..7c6d0719 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped true.ttsl @@ -0,0 +1,3 @@ +# $TEST$ syntax_error + +function true (){} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped union.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped union.sdstest deleted file mode 100644 index 156a14b8..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped union.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -class union diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped val.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped val.sdstest deleted file mode 100644 index c0d3d780..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped val.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -class val diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped var.ttsl b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped var.ttsl new file mode 100644 index 00000000..767b6df6 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped var.ttsl @@ -0,0 +1,3 @@ +# $TEST$ syntax_error + +function var (){} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped where.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped where.sdstest deleted file mode 100644 index 4a5a8cf7..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped where.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -class where diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped yield.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped yield.sdstest deleted file mode 100644 index 965b87c3..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/bad-unescaped yield.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -class yield diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/good-escapedKeywords.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/good-escapedKeywords.sdstest deleted file mode 100644 index b44cdb5f..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/good-escapedKeywords.sdstest +++ /dev/null @@ -1,31 +0,0 @@ -// $TEST$ no_syntax_error - -class `_` -class `and` -class `annotation` -class `as` -class `attr` -class `class` -class `const` -class `enum` -class `false` -class `fun` -class `import` -class `in` -class `internal` -class `not` -class `null` -class `or` -class `out` -class `package` -class `pipeline` -class `private` -class `schema` -class `static` -class `segment` -class `sub` -class `true` -class `union` -class `val` -class `where` -class `yield` diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/good-escapedKeywords.ttsl b/packages/ttsl-lang/tests/resources/grammar/keywords as names/good-escapedKeywords.ttsl new file mode 100644 index 00000000..521b89cd --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/good-escapedKeywords.ttsl @@ -0,0 +1,16 @@ +# $TEST$ no_syntax_error + +function `_` () {} +function `and` () {} +function `as` () {} +function `const` () {} +function `false` () {} +function `function` () {} +function `import` () {} +function `not` () {} +function `null` () {} +function `or` () {} +function `package` () {} +function `private` () {} +function `true` () {} +function `var` () {} diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/good-escapedNonKeyword.sdstest b/packages/ttsl-lang/tests/resources/grammar/keywords as names/good-escapedNonKeyword.sdstest deleted file mode 100644 index 2a9df26c..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/keywords as names/good-escapedNonKeyword.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -class `Bla` diff --git a/packages/ttsl-lang/tests/resources/grammar/keywords as names/good-escapedNonKeyword.ttsl b/packages/ttsl-lang/tests/resources/grammar/keywords as names/good-escapedNonKeyword.ttsl new file mode 100644 index 00000000..f01987c4 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/keywords as names/good-escapedNonKeyword.ttsl @@ -0,0 +1,3 @@ +# $TEST$ no_syntax_error + +function `Bla` () {} diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/bad-annotation call after declaration.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/bad-annotation call after declaration.sdstest deleted file mode 100644 index 32b6ba5f..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/modules/bad-annotation call after declaration.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -class C - -@Annotation1 diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/bad-annotation call after import.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/bad-annotation call after import.sdstest deleted file mode 100644 index 69fd2c16..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/modules/bad-annotation call after import.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -from myPackage import MyClass - -@Annotation1 diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/bad-annotation call after package name.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/bad-annotation call after package name.sdstest deleted file mode 100644 index c0f18f3a..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/modules/bad-annotation call after package name.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -package test - -@Annotation1 diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/bad-annotation call between package name and import.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/bad-annotation call between package name and import.sdstest deleted file mode 100644 index d0692375..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/modules/bad-annotation call between package name and import.sdstest +++ /dev/null @@ -1,7 +0,0 @@ -// $TEST$ syntax_error - -package test - -@Annotation1 - -from myPackage import MyClass diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/bad-duplicate package name.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/bad-duplicate package name.ttsl similarity index 54% rename from packages/ttsl-lang/tests/resources/grammar/modules/bad-duplicate package name.sdstest rename to packages/ttsl-lang/tests/resources/grammar/modules/bad-duplicate package name.ttsl index 6c3bb4d6..5fb58823 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/bad-duplicate package name.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/bad-duplicate package name.ttsl @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error package test diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/bad-import after declaration.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/bad-import after declaration.sdstest deleted file mode 100644 index 37d05a95..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/modules/bad-import after declaration.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -class C - -from myPackage import MyClass diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/bad-import after declaration.ttsl b/packages/ttsl-lang/tests/resources/grammar/modules/bad-import after declaration.ttsl new file mode 100644 index 00000000..26c3eeaf --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/modules/bad-import after declaration.ttsl @@ -0,0 +1,5 @@ +# $TEST$ syntax_error + +function F() {} + +from myPackage import MyFunction diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/bad-import without declarations.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/bad-import without declarations.ttsl similarity index 50% rename from packages/ttsl-lang/tests/resources/grammar/modules/bad-import without declarations.sdstest rename to packages/ttsl-lang/tests/resources/grammar/modules/bad-import without declarations.ttsl index 8e5e68c4..562cc7b4 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/bad-import without declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/bad-import without declarations.ttsl @@ -1,3 +1,3 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error from myPackage import diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/bad-import without package.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/bad-import without package.sdstest deleted file mode 100644 index e81a3ffe..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/modules/bad-import without package.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -from import MyClass diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/bad-import without package.ttsl b/packages/ttsl-lang/tests/resources/grammar/modules/bad-import without package.ttsl new file mode 100644 index 00000000..1895f31f --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/modules/bad-import without package.ttsl @@ -0,0 +1,3 @@ +# $TEST$ syntax_error + +from import MyFunction diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/bad-package name after declaration.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/bad-package name after declaration.sdstest deleted file mode 100644 index 0050a51d..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/modules/bad-package name after declaration.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -class C - -package test diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/bad-package name after declaration.ttsl b/packages/ttsl-lang/tests/resources/grammar/modules/bad-package name after declaration.ttsl new file mode 100644 index 00000000..3a10618f --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/modules/bad-package name after declaration.ttsl @@ -0,0 +1,5 @@ +# $TEST$ syntax_error + +function f() {} + +package test diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/bad-package name after import.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/bad-package name after import.ttsl similarity index 69% rename from packages/ttsl-lang/tests/resources/grammar/modules/bad-package name after import.sdstest rename to packages/ttsl-lang/tests/resources/grammar/modules/bad-package name after import.ttsl index fb1df5eb..a8fd8c07 100644 --- a/packages/ttsl-lang/tests/resources/grammar/modules/bad-package name after import.sdstest +++ b/packages/ttsl-lang/tests/resources/grammar/modules/bad-package name after import.ttsl @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error from myPackage import someDeclaration diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and declaration.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and declaration.sdstest deleted file mode 100644 index 4ad22173..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and declaration.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -@Annotation1 - -class C diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and import and declaration.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and import and declaration.sdstest deleted file mode 100644 index 23513163..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and import and declaration.sdstest +++ /dev/null @@ -1,7 +0,0 @@ -// $TEST$ no_syntax_error - -@Annotation1 - -from myPackage import MyClass - -class C diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and import.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and import.sdstest deleted file mode 100644 index 9412b051..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and import.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -@Annotation1 - -from myPackage import MyClass diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and package name and declaration.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and package name and declaration.sdstest deleted file mode 100644 index bcdd8aca..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and package name and declaration.sdstest +++ /dev/null @@ -1,7 +0,0 @@ -// $TEST$ no_syntax_error - -@Annotation1 - -package myPackage - -class C diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and package name and import and declaration.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and package name and import and declaration.sdstest deleted file mode 100644 index 417eab28..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and package name and import and declaration.sdstest +++ /dev/null @@ -1,9 +0,0 @@ -// $TEST$ no_syntax_error - -@Annotation1 - -package myPackage - -from myPackage import MyClass - -class C diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and package name and import.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and package name and import.sdstest deleted file mode 100644 index 6e382d8d..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and package name and import.sdstest +++ /dev/null @@ -1,7 +0,0 @@ -// $TEST$ no_syntax_error - -@Annotation1 - -package myPackage - -from myPackage import MyClass diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and package name.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and package name.sdstest deleted file mode 100644 index bebb420a..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call and package name.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -@Annotation1 - -package myPackage diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call.sdstest deleted file mode 100644 index d99e5e6a..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation call.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -@Annotation1 diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and declarations.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and declarations.sdstest deleted file mode 100644 index 527c03d0..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and declarations.sdstest +++ /dev/null @@ -1,7 +0,0 @@ -// $TEST$ no_syntax_error - -@Annotation1 -@Annotation2 - -class C -class D diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and imports and declarations.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and imports and declarations.sdstest deleted file mode 100644 index 1405718a..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and imports and declarations.sdstest +++ /dev/null @@ -1,12 +0,0 @@ -// $TEST$ no_syntax_error - -@Annotation1 -@Annotation2 - -from myPackage import MyClass -from myPackage import MyClass as Class -from myPackage import * -from myPackage import MyClass, MyClass as Class - -class C -class D diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and imports.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and imports.sdstest deleted file mode 100644 index 091c3ceb..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and imports.sdstest +++ /dev/null @@ -1,9 +0,0 @@ -// $TEST$ no_syntax_error - -@Annotation1 -@Annotation2 - -from myPackage import MyClass -from myPackage import MyClass as Class -from myPackage import * -from myPackage import MyClass, MyClass as Class diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and package name and declarations.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and package name and declarations.sdstest deleted file mode 100644 index 670d85b1..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and package name and declarations.sdstest +++ /dev/null @@ -1,9 +0,0 @@ -// $TEST$ no_syntax_error - -@Annotation1 -@Annotation2 - -package myPackage - -class C -class D diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and package name and imports and declarations.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and package name and imports and declarations.sdstest deleted file mode 100644 index cef48d9c..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and package name and imports and declarations.sdstest +++ /dev/null @@ -1,14 +0,0 @@ -// $TEST$ no_syntax_error - -@Annotation1 -@Annotation2 - -package myPackage - -from myPackage import MyClass -from myPackage import MyClass as Class -from myPackage import * -from myPackage import MyClass, MyClass as Class - -class C -class D diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and package name and imports.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and package name and imports.sdstest deleted file mode 100644 index c35fd05c..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and package name and imports.sdstest +++ /dev/null @@ -1,11 +0,0 @@ -// $TEST$ no_syntax_error - -@Annotation1 -@Annotation2 - -package myPackage - -from myPackage import MyClass -from myPackage import MyClass as Class -from myPackage import * -from myPackage import MyClass, MyClass as Class diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and package name.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and package name.sdstest deleted file mode 100644 index 777ab87a..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls and package name.sdstest +++ /dev/null @@ -1,6 +0,0 @@ -// $TEST$ no_syntax_error - -@Annotation1 -@Annotation2 - -package myPackage diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls.sdstest deleted file mode 100644 index 2c41fba2..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-annotation calls.sdstest +++ /dev/null @@ -1,4 +0,0 @@ -// $TEST$ no_syntax_error - -@Annotation1 -@Annotation2 diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-declaration.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-declaration.sdstest deleted file mode 100644 index 04c83e5f..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-declaration.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -class C diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-declaration.ttsl b/packages/ttsl-lang/tests/resources/grammar/modules/good-declaration.ttsl new file mode 100644 index 00000000..06ee402d --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-declaration.ttsl @@ -0,0 +1,3 @@ +# $TEST$ no_syntax_error + +function f() {} diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-declarations.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-declarations.sdstest deleted file mode 100644 index e64324dd..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-declarations.sdstest +++ /dev/null @@ -1,4 +0,0 @@ -// $TEST$ no_syntax_error - -class C -class D diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-declarations.ttsl b/packages/ttsl-lang/tests/resources/grammar/modules/good-declarations.ttsl new file mode 100644 index 00000000..4c9fbf61 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-declarations.ttsl @@ -0,0 +1,4 @@ +# $TEST$ no_syntax_error + +function f() {} +function g() {} diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-empty.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-empty.sdstest deleted file mode 100644 index 665cb888..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-empty.sdstest +++ /dev/null @@ -1 +0,0 @@ -// $TEST$ no_syntax_error diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-empty.ttsl b/packages/ttsl-lang/tests/resources/grammar/modules/good-empty.ttsl new file mode 100644 index 00000000..4fdd9ba3 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-empty.ttsl @@ -0,0 +1 @@ +# $TEST$ no_syntax_error diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-import and declaration.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-import and declaration.sdstest deleted file mode 100644 index ba1a0a17..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-import and declaration.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -from myPackage import MyClass - -class C diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-import and declaration.ttsl b/packages/ttsl-lang/tests/resources/grammar/modules/good-import and declaration.ttsl new file mode 100644 index 00000000..6a22cbc0 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-import and declaration.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +from myPackage import MyFunction + +function f() {} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-import.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-import.sdstest deleted file mode 100644 index 4cd7febc..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-import.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -from myPackage import MyClass diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-import.ttsl b/packages/ttsl-lang/tests/resources/grammar/modules/good-import.ttsl new file mode 100644 index 00000000..ae307ff5 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-import.ttsl @@ -0,0 +1,3 @@ +# $TEST$ no_syntax_error + +from myPackage import MyFunction diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-imports and declarations.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-imports and declarations.sdstest deleted file mode 100644 index c999e0d4..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-imports and declarations.sdstest +++ /dev/null @@ -1,9 +0,0 @@ -// $TEST$ no_syntax_error - -from myPackage import MyClass -from myPackage import MyClass as Class -from myPackage import * -from myPackage import MyClass, MyClass as Class - -class C -class D diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-imports and declarations.ttsl b/packages/ttsl-lang/tests/resources/grammar/modules/good-imports and declarations.ttsl new file mode 100644 index 00000000..6127c78d --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-imports and declarations.ttsl @@ -0,0 +1,9 @@ +# $TEST$ no_syntax_error + +from myPackage import MyFunction +from myPackage import MyFunction as Function +from myPackage import * +from myPackage import MyFunction, MyFunction as Function + +function f() {} +function g() {} diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-imports.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-imports.sdstest deleted file mode 100644 index 117cdede..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-imports.sdstest +++ /dev/null @@ -1,6 +0,0 @@ -// $TEST$ no_syntax_error - -from myPackage import MyClass -from myPackage import MyClass as Class -from myPackage import * -from myPackage import MyClass, MyClass as Class diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-imports.ttsl b/packages/ttsl-lang/tests/resources/grammar/modules/good-imports.ttsl new file mode 100644 index 00000000..60475afc --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-imports.ttsl @@ -0,0 +1,6 @@ +# $TEST$ no_syntax_error + +from myPackage import MyFunction +from myPackage import MyFunction as Function +from myPackage import * +from myPackage import MyFunction, MyFunction as Function diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and declaration.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and declaration.sdstest deleted file mode 100644 index 467c84b6..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and declaration.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -package myPackage - -class C diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and declaration.ttsl b/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and declaration.ttsl new file mode 100644 index 00000000..5ff0ad5c --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and declaration.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +package myPackage + +function f() {} diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and declarations.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and declarations.sdstest deleted file mode 100644 index 5d53478e..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and declarations.sdstest +++ /dev/null @@ -1,6 +0,0 @@ -// $TEST$ no_syntax_error - -package myPackage - -class C -class D diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and declarations.ttsl b/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and declarations.ttsl new file mode 100644 index 00000000..d55fb535 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and declarations.ttsl @@ -0,0 +1,6 @@ +# $TEST$ no_syntax_error + +package myPackage + +function f() {} +function g() {} diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and import and declaration.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and import and declaration.sdstest deleted file mode 100644 index a15f84d0..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and import and declaration.sdstest +++ /dev/null @@ -1,7 +0,0 @@ -// $TEST$ no_syntax_error - -package myPackage - -from myPackage import MyClass - -class C diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and import and declaration.ttsl b/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and import and declaration.ttsl new file mode 100644 index 00000000..8f650d8f --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and import and declaration.ttsl @@ -0,0 +1,8 @@ +# $TEST$ no_syntax_error + +package myPackage + +from myPackage import MyFunction + +function f() {} + diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and import.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and import.sdstest deleted file mode 100644 index 1e641a95..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and import.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -package myPackage - -from myPackage import MyClass diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and import.ttsl b/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and import.ttsl new file mode 100644 index 00000000..aa8ffae3 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and import.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +package myPackage + +from myPackage import MyFunction diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and imports and declarations.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and imports and declarations.sdstest deleted file mode 100644 index 32276074..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and imports and declarations.sdstest +++ /dev/null @@ -1,11 +0,0 @@ -// $TEST$ no_syntax_error - -package myPackage - -from myPackage import MyClass -from myPackage import MyClass as Class -from myPackage import * -from myPackage import MyClass, MyClass as Class - -class C -class D diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and imports and declarations.ttsl b/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and imports and declarations.ttsl new file mode 100644 index 00000000..670bd188 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and imports and declarations.ttsl @@ -0,0 +1,12 @@ +# $TEST$ no_syntax_error + +package myPackage + +from myPackage import MyFunction +from myPackage import MyFunction as Function +from myPackage import * +from myPackage import MyFunction, MyFunction as Function + +function f() {} +function g() {} + diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and imports.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and imports.sdstest deleted file mode 100644 index 2e7a19d8..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and imports.sdstest +++ /dev/null @@ -1,8 +0,0 @@ -// $TEST$ no_syntax_error - -package myPackage - -from myPackage import MyClass -from myPackage import MyClass as Class -from myPackage import * -from myPackage import MyClass, MyClass as Class diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and imports.ttsl b/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and imports.ttsl new file mode 100644 index 00000000..2506de1c --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-package name and imports.ttsl @@ -0,0 +1,8 @@ +# $TEST$ no_syntax_error + +package myPackage + +from myPackage import MyFunction +from myPackage import MyFunction as Function +from myPackage import * +from myPackage import MyFunction, MyFunction as Function diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-package name.sdstest b/packages/ttsl-lang/tests/resources/grammar/modules/good-package name.sdstest deleted file mode 100644 index 6cf287b7..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/modules/good-package name.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -package myPackage diff --git a/packages/ttsl-lang/tests/resources/grammar/modules/good-package name.ttsl b/packages/ttsl-lang/tests/resources/grammar/modules/good-package name.ttsl new file mode 100644 index 00000000..9cbefbb4 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/modules/good-package name.ttsl @@ -0,0 +1,3 @@ +# $TEST$ no_syntax_error + +package myPackage diff --git a/packages/ttsl-lang/tests/resources/grammar/schema/bad-no name (colon).sdstest b/packages/ttsl-lang/tests/resources/grammar/schema/bad-no name (colon).sdstest deleted file mode 100644 index 7e8ad729..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/schema/bad-no name (colon).sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -schema MySchema { - : Int -} diff --git a/packages/ttsl-lang/tests/resources/grammar/schema/bad-no name (no colon).sdstest b/packages/ttsl-lang/tests/resources/grammar/schema/bad-no name (no colon).sdstest deleted file mode 100644 index b9972ace..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/schema/bad-no name (no colon).sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -schema MySchema { - Int -} diff --git a/packages/ttsl-lang/tests/resources/grammar/schema/bad-no type (colon).sdstest b/packages/ttsl-lang/tests/resources/grammar/schema/bad-no type (colon).sdstest deleted file mode 100644 index 0da371cb..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/schema/bad-no type (colon).sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -schema MySchema { - "column1" : -} diff --git a/packages/ttsl-lang/tests/resources/grammar/schema/bad-no type (no colon).sdstest b/packages/ttsl-lang/tests/resources/grammar/schema/bad-no type (no colon).sdstest deleted file mode 100644 index 8a3589f9..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/schema/bad-no type (no colon).sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -schema MySchema { - "column1" -} diff --git a/packages/ttsl-lang/tests/resources/grammar/schema/bad-switched name and type.sdstest b/packages/ttsl-lang/tests/resources/grammar/schema/bad-switched name and type.sdstest deleted file mode 100644 index 35432749..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/schema/bad-switched name and type.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -schema MySchema { - Int: "column1" -} diff --git a/packages/ttsl-lang/tests/resources/grammar/schema/bad-unclosed curly brace.sdstest b/packages/ttsl-lang/tests/resources/grammar/schema/bad-unclosed curly brace.sdstest deleted file mode 100644 index 344b89da..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/schema/bad-unclosed curly brace.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ syntax_error - -schema MySchema { diff --git a/packages/ttsl-lang/tests/resources/grammar/schema/good-annotation call.sdstest b/packages/ttsl-lang/tests/resources/grammar/schema/good-annotation call.sdstest deleted file mode 100644 index 6d802b73..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/schema/good-annotation call.sdstest +++ /dev/null @@ -1,6 +0,0 @@ -// $TEST$ no_syntax_error - -package test - -@Annotation -schema MySchema {} diff --git a/packages/ttsl-lang/tests/resources/grammar/schema/good-empty schema.sdstest b/packages/ttsl-lang/tests/resources/grammar/schema/good-empty schema.sdstest deleted file mode 100644 index f1e64b43..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/schema/good-empty schema.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -schema MySchema {} diff --git a/packages/ttsl-lang/tests/resources/grammar/schema/good-one column.sdstest b/packages/ttsl-lang/tests/resources/grammar/schema/good-one column.sdstest deleted file mode 100644 index bea79ca3..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/schema/good-one column.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -schema MySchema { - "column1": Int -} diff --git a/packages/ttsl-lang/tests/resources/grammar/schema/good-two columns.sdstest b/packages/ttsl-lang/tests/resources/grammar/schema/good-two columns.sdstest deleted file mode 100644 index 5cd16453..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/schema/good-two columns.sdstest +++ /dev/null @@ -1,6 +0,0 @@ -// $TEST$ no_syntax_error - -schema MySchema { - "column1": Int, - "column2": String -} diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in block lambda without assignees.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in block lambda without assignees.sdstest deleted file mode 100644 index 670cdb28..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in block lambda without assignees.sdstest +++ /dev/null @@ -1,7 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - () { - = 0; - }; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in block lambda without expression.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in block lambda without expression.sdstest deleted file mode 100644 index 6d5ea11a..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in block lambda without expression.sdstest +++ /dev/null @@ -1,7 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - () { - val a =; - }; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in block lambda without semicolon.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in block lambda without semicolon.sdstest deleted file mode 100644 index 910fdb29..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in block lambda without semicolon.sdstest +++ /dev/null @@ -1,7 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - () { - val a = 0 - }; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in function without assignees.ttsl b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in function without assignees.ttsl new file mode 100644 index 00000000..4d041f32 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in function without assignees.ttsl @@ -0,0 +1,5 @@ +# $TEST$ syntax_error + +function myFunction () { + = 0; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in function without expression.ttsl b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in function without expression.ttsl new file mode 100644 index 00000000..b5b24e0b --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in function without expression.ttsl @@ -0,0 +1,5 @@ +# $TEST$ syntax_error + +function myFunction () { + var a =; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in pipeline without assignees.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in pipeline without assignees.sdstest deleted file mode 100644 index 673d19d5..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in pipeline without assignees.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - = 0; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in pipeline without expression.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in pipeline without expression.sdstest deleted file mode 100644 index 5bc01e5b..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in pipeline without expression.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - val a =; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in pipeline without semicolon.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in pipeline without semicolon.sdstest deleted file mode 100644 index 1a5bd5ec..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in pipeline without semicolon.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - val a = 0 -} diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in segment without assignees.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in segment without assignees.sdstest deleted file mode 100644 index 886632c6..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in segment without assignees.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -segment mySegment() { - = 0; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in segment without expression.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in segment without expression.sdstest deleted file mode 100644 index 0d7b52fd..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in segment without expression.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -segment mySegment() { - val a =; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in segment without semicolon.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in segment without semicolon.sdstest deleted file mode 100644 index 350dbd7d..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/bad-in segment without semicolon.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -segment mySegment() { - val a = 0 -} diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/good-in block lambda.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/good-in block lambda.sdstest deleted file mode 100644 index 7f4f5a00..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/good-in block lambda.sdstest +++ /dev/null @@ -1,8 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - () { - val a = 0; - val a, _, yield b = call(); - }; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/good-in function.ttsl b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/good-in function.ttsl new file mode 100644 index 00000000..1cf45afb --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/good-in function.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function myFunction () { + var a = 0; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/good-in pipeline.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/good-in pipeline.sdstest deleted file mode 100644 index 547464b3..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/good-in pipeline.sdstest +++ /dev/null @@ -1,6 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - val a = 0; - val a, _, yield b = call(); -} diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/good-in segment.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/assignments/good-in segment.sdstest deleted file mode 100644 index 334f15ef..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/statements/assignments/good-in segment.sdstest +++ /dev/null @@ -1,6 +0,0 @@ -// $TEST$ no_syntax_error - -segment mySegment() { - val a = 0; - val a, _, yield b = call(); -} diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/bad-empty statement in block lambda.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/bad-empty statement in block lambda.sdstest deleted file mode 100644 index 47540d3b..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/statements/bad-empty statement in block lambda.sdstest +++ /dev/null @@ -1,7 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - () { - ; - }; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/bad-empty statement in pipeline.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/bad-empty statement in pipeline.sdstest deleted file mode 100644 index b49c045c..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/statements/bad-empty statement in pipeline.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - ; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/bad-empty statement in pipeline.ttsl b/packages/ttsl-lang/tests/resources/grammar/statements/bad-empty statement in pipeline.ttsl new file mode 100644 index 00000000..367367f7 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/statements/bad-empty statement in pipeline.ttsl @@ -0,0 +1,5 @@ +# $TEST$ syntax_error + +function myFunction () { + ; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/bad-empty statement in segment.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/bad-empty statement in segment.sdstest deleted file mode 100644 index ab3a700b..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/statements/bad-empty statement in segment.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -segment mySegment() { - ; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-with else missing elseblock.ttsl b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-with else missing elseblock.ttsl index 240cdeb9..e0e58feb 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-with else missing elseblock.ttsl +++ b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-with else missing elseblock.ttsl @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error function myFunction() { if (true){} diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-without else missing block.ttsl b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-without else missing block.ttsl index f239f557..f58f1257 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-without else missing block.ttsl +++ b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-without else missing block.ttsl @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error function myFunction() { if (true) diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-without else missing condition.ttsl b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-without else missing condition.ttsl index 460d45de..b46f14f6 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-without else missing condition.ttsl +++ b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/bad-without else missing condition.ttsl @@ -1,4 +1,4 @@ -// $TEST$ syntax_error +# $TEST$ syntax_error function myFunction() { if (){} diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-with else false.ttsl b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-with else false.ttsl index 444d8dd5..ca1dc4e6 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-with else false.ttsl +++ b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-with else false.ttsl @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error function myFunction() { if (false){} diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-with else true.ttsl b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-with else true.ttsl index 1fb4d176..bfcd6981 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-with else true.ttsl +++ b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-with else true.ttsl @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error function myFunction() { if (true){} diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-without else.ttsl b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-without else.ttsl index 604998d8..5836cb7b 100644 --- a/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-without else.ttsl +++ b/packages/ttsl-lang/tests/resources/grammar/statements/conditional statements/good-without else.ttsl @@ -1,4 +1,4 @@ -// $TEST$ no_syntax_error +# $TEST$ no_syntax_error function myFunction() { if (true){} diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/bad-in block lambda without semicolon.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/bad-in block lambda without semicolon.sdstest deleted file mode 100644 index 6493c7e3..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/bad-in block lambda without semicolon.sdstest +++ /dev/null @@ -1,7 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - () { - call() - }; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/bad-in function without semicolon.ttsl b/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/bad-in function without semicolon.ttsl new file mode 100644 index 00000000..b640b4e0 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/bad-in function without semicolon.ttsl @@ -0,0 +1,5 @@ +# $TEST$ syntax_error + +function myFunction () { + call() +} diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/bad-in pipeline without semicolon.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/bad-in pipeline without semicolon.sdstest deleted file mode 100644 index bcf2dbd2..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/bad-in pipeline without semicolon.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -pipeline myPipeline { - call() -} diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/bad-in segment without semicolon.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/bad-in segment without semicolon.sdstest deleted file mode 100644 index 8e9345f9..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/bad-in segment without semicolon.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -segment mySegment() { - call() -} diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/good-in block lambda.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/good-in block lambda.sdstest deleted file mode 100644 index 63f8f138..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/good-in block lambda.sdstest +++ /dev/null @@ -1,7 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - () { - call(); - }; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/good-in function.ttsl b/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/good-in function.ttsl new file mode 100644 index 00000000..8b5c11d8 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/good-in function.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function myFunction () { + call(); +} diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/good-in pipeline.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/good-in pipeline.sdstest deleted file mode 100644 index a3fb0130..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/good-in pipeline.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - call(); -} diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/good-in segment.sdstest b/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/good-in segment.sdstest deleted file mode 100644 index 57c29420..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/statements/expression statements/good-in segment.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -segment mySegment() { - call(); -} diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/loops/for loops/bad-missing body.ttsl b/packages/ttsl-lang/tests/resources/grammar/statements/loops/for loops/bad-missing body.ttsl new file mode 100644 index 00000000..5ce5be61 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/statements/loops/for loops/bad-missing body.ttsl @@ -0,0 +1,5 @@ +# $TEST$ syntax_error + +function myFunction () { + for(var i = 0; i<=10; i++) +} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/loops/for loops/bad-missing condition.ttsl b/packages/ttsl-lang/tests/resources/grammar/statements/loops/for loops/bad-missing condition.ttsl new file mode 100644 index 00000000..84fbd70f --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/statements/loops/for loops/bad-missing condition.ttsl @@ -0,0 +1,7 @@ +# $TEST$ syntax_error + +function myFunction () { + for(var i = 0; ; i++){ + + } +} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/loops/for loops/bad-missing semicolon.ttsl b/packages/ttsl-lang/tests/resources/grammar/statements/loops/for loops/bad-missing semicolon.ttsl new file mode 100644 index 00000000..ee90c12e --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/statements/loops/for loops/bad-missing semicolon.ttsl @@ -0,0 +1,7 @@ +# $TEST$ syntax_error + +function myFunction () { + for(var i = 0; i<=10){ + + } +} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/loops/for loops/good-in function.ttsl b/packages/ttsl-lang/tests/resources/grammar/statements/loops/for loops/good-in function.ttsl new file mode 100644 index 00000000..1867087a --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/statements/loops/for loops/good-in function.ttsl @@ -0,0 +1,7 @@ +# $TEST$ no_syntax_error + +function myFunction () { + for(var i = 0; i <= 10; i = i+1){ + + } +} diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/loops/foreach loops/bad-missing body.ttsl b/packages/ttsl-lang/tests/resources/grammar/statements/loops/foreach loops/bad-missing body.ttsl new file mode 100644 index 00000000..8c3ab01e --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/statements/loops/foreach loops/bad-missing body.ttsl @@ -0,0 +1,5 @@ +# $TEST$ syntax_error + +function myFunction () { + foreach(elm in list) +} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/loops/foreach loops/bad-missing element.ttsl b/packages/ttsl-lang/tests/resources/grammar/statements/loops/foreach loops/bad-missing element.ttsl new file mode 100644 index 00000000..2b399b59 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/statements/loops/foreach loops/bad-missing element.ttsl @@ -0,0 +1,7 @@ +# $TEST$ syntax_error + +function myFunction () { + foreach() in list){ + + } +} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/loops/foreach loops/bad-missing list.ttsl b/packages/ttsl-lang/tests/resources/grammar/statements/loops/foreach loops/bad-missing list.ttsl new file mode 100644 index 00000000..975c8f0b --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/statements/loops/foreach loops/bad-missing list.ttsl @@ -0,0 +1,7 @@ +# $TEST$ syntax_error + +function myFunction () { + foreach(elm in ){ + + } +} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/loops/foreach loops/good- in function.ttsl b/packages/ttsl-lang/tests/resources/grammar/statements/loops/foreach loops/good- in function.ttsl new file mode 100644 index 00000000..5842bbcf --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/statements/loops/foreach loops/good- in function.ttsl @@ -0,0 +1,7 @@ +# $TEST$ no_syntax_error + +function myFunction () { + foreach(elm in list){ + + } +} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/loops/while loops/bad-missing body.ttsl b/packages/ttsl-lang/tests/resources/grammar/statements/loops/while loops/bad-missing body.ttsl new file mode 100644 index 00000000..6292eba6 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/statements/loops/while loops/bad-missing body.ttsl @@ -0,0 +1,5 @@ +# $TEST$ syntax_error + +function myFunction () { + while(i = 0) +} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/loops/while loops/bad-missing condition.ttsl b/packages/ttsl-lang/tests/resources/grammar/statements/loops/while loops/bad-missing condition.ttsl new file mode 100644 index 00000000..352ab449 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/statements/loops/while loops/bad-missing condition.ttsl @@ -0,0 +1,7 @@ +# $TEST$ syntax_error + +function myFunction () { + while(){ + + } +} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/grammar/statements/loops/while loops/good-in function.ttsl b/packages/ttsl-lang/tests/resources/grammar/statements/loops/while loops/good-in function.ttsl new file mode 100644 index 00000000..e0819c3e --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/statements/loops/while loops/good-in function.ttsl @@ -0,0 +1,7 @@ +# $TEST$ no_syntax_error + +function myFunction () { + while(i == 0){ + + } +} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-argument list of annotation call.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-argument list of annotation call.sdstest deleted file mode 100644 index f8be6908..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-argument list of annotation call.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -@A(1, 2, ) diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-argument list of call.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-argument list of call.sdstest deleted file mode 100644 index 00d833f0..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-argument list of call.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline p { - f(1, 2, ); -} diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-argument list of call.ttsl b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-argument list of call.ttsl new file mode 100644 index 00000000..73a19e4c --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-argument list of call.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function f() { + g(1, 2, ); +} diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-assignee list of assignment in block lambda.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-assignee list of assignment in block lambda.sdstest deleted file mode 100644 index 397d4183..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-assignee list of assignment in block lambda.sdstest +++ /dev/null @@ -1,7 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline p { - () { - val a, val b, = f(); - }; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-assignee list of assignment.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-assignee list of assignment.sdstest deleted file mode 100644 index 83e8ff91..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-assignee list of assignment.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline p { - val a, val b, = f(); -} diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-column list of schema.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-column list of schema.sdstest deleted file mode 100644 index f4dd423f..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-column list of schema.sdstest +++ /dev/null @@ -1,6 +0,0 @@ -// $TEST$ no_syntax_error - -schema MySchemaWithTrailingComma { - "column1" : Int, - "column2" : String, -} diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-constraint list of annotation.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-constraint list of annotation.sdstest deleted file mode 100644 index ab23f1ef..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-constraint list of annotation.sdstest +++ /dev/null @@ -1,6 +0,0 @@ -// $TEST$ no_syntax_error - -annotation A where { - p < 0, - q > 0, -} diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-constraint list of class.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-constraint list of class.sdstest deleted file mode 100644 index c3b80dd9..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-constraint list of class.sdstest +++ /dev/null @@ -1,6 +0,0 @@ -// $TEST$ no_syntax_error - -class C where { - p < 0, - q > 0, -} diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-constraint list of enum variant.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-constraint list of enum variant.sdstest deleted file mode 100644 index 8330bbf5..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-constraint list of enum variant.sdstest +++ /dev/null @@ -1,8 +0,0 @@ -// $TEST$ no_syntax_error - -enum E { - A where { - p < 0, - q > 0, - } -} diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-constraint list of function.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-constraint list of function.sdstest deleted file mode 100644 index 0520d786..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-constraint list of function.sdstest +++ /dev/null @@ -1,6 +0,0 @@ -// $TEST$ no_syntax_error - -fun f() where { - p < 0, - q > 0, -} diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-elements of list.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-elements of list.sdstest deleted file mode 100644 index be2054ad..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-elements of list.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - [1, 2, ]; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-elements of list.ttsl b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-elements of list.ttsl new file mode 100644 index 00000000..1f603fab --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-elements of list.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function myFunction () { + [1, 2, ]; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-entries of map.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-entries of map.sdstest deleted file mode 100644 index 787c00d7..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-entries of map.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline myPipeline { - {1: "one", 2: "two", }; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-entries of map.ttsl b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-entries of map.ttsl new file mode 100644 index 00000000..94f64af6 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-entries of map.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function myFunction () { + {1: "one", 2: "two", }; +} diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-imported declaration list of qualified import.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-imported declaration list of qualified import.sdstest deleted file mode 100644 index e98849e9..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-imported declaration list of qualified import.sdstest +++ /dev/null @@ -1,4 +0,0 @@ -// $TEST$ no_syntax_error - -from myPackage import MyClass, MyClass as Class, - \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-imported declaration list of qualified import.ttsl b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-imported declaration list of qualified import.ttsl new file mode 100644 index 00000000..d2467d4c --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-imported declaration list of qualified import.ttsl @@ -0,0 +1,3 @@ +# $TEST$ no_syntax_error + +from myPackage import MyFunction, MyFunction as Function, diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-literal list of literal type.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-literal list of literal type.sdstest deleted file mode 100644 index 0253c098..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-literal list of literal type.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -segment s( - f: literal -) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of annotation.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of annotation.sdstest deleted file mode 100644 index da48dfa8..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of annotation.sdstest +++ /dev/null @@ -1,6 +0,0 @@ -// $TEST$ no_syntax_error - -annotation A( - a: Int, - b: Int, -) diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of block lambda.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of block lambda.sdstest deleted file mode 100644 index a1f3e4e3..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of block lambda.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline p { - (first, second, ) {}; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of callable type.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of callable type.sdstest deleted file mode 100644 index e1d85571..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of callable type.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -segment s( - f: (x: Int, y: Int, ) -> () -) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of class.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of class.sdstest deleted file mode 100644 index 5101eeba..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of class.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -class C(a: Int, b: Int, ) diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of enum variant.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of enum variant.sdstest deleted file mode 100644 index 449e1df0..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of enum variant.sdstest +++ /dev/null @@ -1,8 +0,0 @@ -// $TEST$ no_syntax_error - -enum E { - A( - a: Int, - b: Int, - ) -} diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of expression lambda.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of expression lambda.sdstest deleted file mode 100644 index b8a58ec3..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of expression lambda.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -pipeline p { - (first, second, ) -> 1; -} diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of function.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of function.sdstest deleted file mode 100644 index 067186c8..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of function.sdstest +++ /dev/null @@ -1,6 +0,0 @@ -// $TEST$ no_syntax_error - -fun f( - a: Int, - b: Int, -) diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of function.ttsl b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of function.ttsl new file mode 100644 index 00000000..ad8160f9 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of function.ttsl @@ -0,0 +1,6 @@ +# $TEST$ no_syntax_error + +function f( + a: Int, + b: Int, +) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of segment.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of segment.sdstest deleted file mode 100644 index 47f64488..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parameter list of segment.sdstest +++ /dev/null @@ -1,6 +0,0 @@ -// $TEST$ no_syntax_error - -segment s( - a: Int, - b: Int, -) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parent type list of class.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parent type list of class.sdstest deleted file mode 100644 index 1bcd73e5..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-parent type list of class.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -class C sub D, E, diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-result list of callable type.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-result list of callable type.sdstest deleted file mode 100644 index e06ea897..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-result list of callable type.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -segment s( - f: () -> (x: Int, y: Int, ) -) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-result list of function.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-result list of function.sdstest deleted file mode 100644 index 6900e96e..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-result list of function.sdstest +++ /dev/null @@ -1,6 +0,0 @@ -// $TEST$ no_syntax_error - -fun f() -> ( - first: Int, - second: Int, -) diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-result list of segment.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-result list of segment.sdstest deleted file mode 100644 index 64c7b4b2..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-result list of segment.sdstest +++ /dev/null @@ -1,6 +0,0 @@ -// $TEST$ no_syntax_error - -segment s() -> ( - first: Int, - second: Int, -) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-type argument list of named type.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-type argument list of named type.sdstest deleted file mode 100644 index c4d43d35..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-type argument list of named type.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -segment s( - f: Type -) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-type argument list of union type.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-type argument list of union type.sdstest deleted file mode 100644 index 83b71756..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-type argument list of union type.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -segment s( - f: union -) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-type parameter list of class.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-type parameter list of class.sdstest deleted file mode 100644 index 8c208c01..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-type parameter list of class.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -class C diff --git a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-type parameter list of function.sdstest b/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-type parameter list of function.sdstest deleted file mode 100644 index f139517e..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/trailing commas/good-type parameter list of function.sdstest +++ /dev/null @@ -1,3 +0,0 @@ -// $TEST$ no_syntax_error - -fun f() diff --git a/packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-missing arrow.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-missing arrow.sdstest deleted file mode 100644 index 5674be22..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-missing arrow.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -segment mySegment( - f: () () -) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-missing parameter list.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-missing parameter list.sdstest deleted file mode 100644 index 73927697..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-missing parameter list.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -segment mySegment( - f: -> () -) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-missing result list.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-missing result list.sdstest deleted file mode 100644 index 89bb1850..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-missing result list.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -segment mySegment( - f: () -> -) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-unclosed parameter list.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-unclosed parameter list.sdstest deleted file mode 100644 index 13278275..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-unclosed parameter list.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -segment mySegment( - f: ( -> () -) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-unclosed result list.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-unclosed result list.sdstest deleted file mode 100644 index 3b2759a8..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/types/callable types/bad-unclosed result list.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -segment mySegment( - f: () -> ( -) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/types/callable types/good-with parameter and result lists.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/callable types/good-with parameter and result lists.sdstest deleted file mode 100644 index 2baa7ff0..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/types/callable types/good-with parameter and result lists.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -segment mySegment( - f: () -> () -) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/types/good-Boolean.ttsl b/packages/ttsl-lang/tests/resources/grammar/types/good-Boolean.ttsl new file mode 100644 index 00000000..36b95ef1 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/types/good-Boolean.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function f( + a: Boolean +){} diff --git a/packages/ttsl-lang/tests/resources/grammar/types/good-Dictionary.ttsl b/packages/ttsl-lang/tests/resources/grammar/types/good-Dictionary.ttsl new file mode 100644 index 00000000..c8d831e5 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/types/good-Dictionary.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function f( + a: Dict +){} diff --git a/packages/ttsl-lang/tests/resources/grammar/types/good-Float.ttsl b/packages/ttsl-lang/tests/resources/grammar/types/good-Float.ttsl new file mode 100644 index 00000000..ed729757 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/types/good-Float.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function f( + a: Float +){} diff --git a/packages/ttsl-lang/tests/resources/grammar/types/good-Int.ttsl b/packages/ttsl-lang/tests/resources/grammar/types/good-Int.ttsl new file mode 100644 index 00000000..f550c0e5 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/types/good-Int.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function f( + a: Int +){} diff --git a/packages/ttsl-lang/tests/resources/grammar/types/good-List.ttsl b/packages/ttsl-lang/tests/resources/grammar/types/good-List.ttsl new file mode 100644 index 00000000..ce27be43 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/types/good-List.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function f( + a: List +){} diff --git a/packages/ttsl-lang/tests/resources/grammar/types/good-String.ttsl b/packages/ttsl-lang/tests/resources/grammar/types/good-String.ttsl new file mode 100644 index 00000000..5992ada3 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/types/good-String.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +function f( + a: String +){} diff --git a/packages/ttsl-lang/tests/resources/grammar/types/literal types/bad-nested.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/literal types/bad-nested.sdstest deleted file mode 100644 index ce0e69ae..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/types/literal types/bad-nested.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -segment mySegment( - x: literal> -) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/types/literal types/bad-no literal list.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/literal types/bad-no literal list.sdstest deleted file mode 100644 index 7c5a3834..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/types/literal types/bad-no literal list.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -segment mySegment( - x: literal -) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/types/literal types/bad-unclosed angle bracket.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/literal types/bad-unclosed angle bracket.sdstest deleted file mode 100644 index abf93699..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/types/literal types/bad-unclosed angle bracket.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -segment mySegment( - x: literal< -) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/types/literal types/good-empty.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/literal types/good-empty.sdstest deleted file mode 100644 index 66a936d1..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/types/literal types/good-empty.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -segment mySegment( - x: literal<> -) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/types/literal types/good-with list literal.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/literal types/good-with list literal.sdstest deleted file mode 100644 index 02435b25..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/types/literal types/good-with list literal.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -segment mySegment( - x: literal<[]> -) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/types/literal types/good-with literals.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/literal types/good-with literals.sdstest deleted file mode 100644 index 3fbda1b5..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/types/literal types/good-with literals.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -segment mySegment( - x: literal -) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/types/literal types/good-with map literal.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/literal types/good-with map literal.sdstest deleted file mode 100644 index d19c3930..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/types/literal types/good-with map literal.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -segment mySegment( - x: literal<{}> -) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-callable type as member.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-callable type as member.sdstest deleted file mode 100644 index 11f5aba3..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-callable type as member.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -segment mySegment( - x: OuterClass.() -> () -) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-literal type as member.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-literal type as member.sdstest deleted file mode 100644 index 701706f1..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-literal type as member.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -segment mySegment( - x: OuterClass.literal<> -) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-missing member.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-missing member.sdstest deleted file mode 100644 index 9f4517d3..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-missing member.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -segment mySegment( - x: OuterClass. -) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-missing receiver.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-missing receiver.sdstest deleted file mode 100644 index 36d39ad5..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-missing receiver.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -segment mySegment( - x: .InnerClass -) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-unclosed angle bracket.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-unclosed angle bracket.sdstest deleted file mode 100644 index b69e017b..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-unclosed angle bracket.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -segment mySegment( - x: OuterClass.InnerClass< -) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-union type as member.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-union type as member.sdstest deleted file mode 100644 index bdbd8075..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/types/member types/bad-union type as member.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -segment mySegment( - x: OuterClass.union<> -) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-long complex chain.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/member types/good-long complex chain.sdstest deleted file mode 100644 index 1a3867f8..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-long complex chain.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -segment mySegment( - x: union<>.MiddleClass?.InnerClass -) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (callable) and member (not nullable).sdstest b/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (callable) and member (not nullable).sdstest deleted file mode 100644 index 4867643c..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (callable) and member (not nullable).sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -segment mySegment( - x: () -> ().InnerClass -) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (callable) and member (nullable).sdstest b/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (callable) and member (nullable).sdstest deleted file mode 100644 index 5cfef9a1..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (callable) and member (nullable).sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -segment mySegment( - x: () -> ().InnerClass? -) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (literal) and member (not nullable).sdstest b/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (literal) and member (not nullable).sdstest deleted file mode 100644 index 6be0c881..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (literal) and member (not nullable).sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -segment mySegment( - x: literal<>.InnerClass -) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (literal) and member (nullable).sdstest b/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (literal) and member (nullable).sdstest deleted file mode 100644 index 2c8e93a9..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (literal) and member (nullable).sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -segment mySegment( - x: literal<>.InnerClass? -) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (named, not nullable) and member (not nullable).sdstest b/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (named, not nullable) and member (not nullable).sdstest deleted file mode 100644 index 56b6bf48..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (named, not nullable) and member (not nullable).sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -segment mySegment( - x: OuterClass.InnerClass -) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (named, not nullable) and member (nullable).sdstest b/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (named, not nullable) and member (nullable).sdstest deleted file mode 100644 index 118f8783..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (named, not nullable) and member (nullable).sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -segment mySegment( - x: OuterClass.InnerClass? -) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (named, nullable) and member (not nullable).sdstest b/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (named, nullable) and member (not nullable).sdstest deleted file mode 100644 index f74fa6e4..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (named, nullable) and member (not nullable).sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -segment mySegment( - x: OuterClass?.InnerClass -) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (named, nullable) and member (nullable).sdstest b/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (named, nullable) and member (nullable).sdstest deleted file mode 100644 index 118f8783..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (named, nullable) and member (nullable).sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -segment mySegment( - x: OuterClass.InnerClass? -) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (union) and member (not nullable).sdstest b/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (union) and member (not nullable).sdstest deleted file mode 100644 index 5d1d5321..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (union) and member (not nullable).sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -segment mySegment( - x: union<>.InnerClass -) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (union) and member (nullable).sdstest b/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (union) and member (nullable).sdstest deleted file mode 100644 index 04ad20cc..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/types/member types/good-receiver (union) and member (nullable).sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -segment mySegment( - x: union<>.InnerClass? -) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/types/named types/bad-unclosed angle bracket.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/named types/bad-unclosed angle bracket.sdstest deleted file mode 100644 index 77d80695..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/types/named types/bad-unclosed angle bracket.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -segment mySegment( - x: OuterClass< -) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/types/named types/good-no type arguments and not nullable.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/named types/good-no type arguments and not nullable.sdstest deleted file mode 100644 index 880fb7dd..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/types/named types/good-no type arguments and not nullable.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -segment mySegment( - x: Int -) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/types/named types/good-no type arguments and nullable.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/named types/good-no type arguments and nullable.sdstest deleted file mode 100644 index 9da0abc2..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/types/named types/good-no type arguments and nullable.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -segment mySegment( - x: Int? -) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/types/named types/good-type argument and nullable.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/named types/good-type argument and nullable.sdstest deleted file mode 100644 index 1959e858..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/types/named types/good-type argument and nullable.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -segment mySegment( - x: Int? -) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/types/named types/good-type arguments and not nullable.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/named types/good-type arguments and not nullable.sdstest deleted file mode 100644 index c814980e..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/types/named types/good-type arguments and not nullable.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -segment mySegment( - x: Int -) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/types/union types/bad-unclosed angle bracket.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/union types/bad-unclosed angle bracket.sdstest deleted file mode 100644 index 05a407af..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/types/union types/bad-unclosed angle bracket.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ syntax_error - -segment mySegment( - x: union< -) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/types/union types/good-empty.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/union types/good-empty.sdstest deleted file mode 100644 index 0d4de615..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/types/union types/good-empty.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -segment mySegment( - x: union<> -) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/types/union types/good-nested.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/union types/good-nested.sdstest deleted file mode 100644 index 9fbe2261..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/types/union types/good-nested.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -segment mySegment( - x: union> -) {} diff --git a/packages/ttsl-lang/tests/resources/grammar/types/union types/good-with type arguments.sdstest b/packages/ttsl-lang/tests/resources/grammar/types/union types/good-with type arguments.sdstest deleted file mode 100644 index 0d9fc775..00000000 --- a/packages/ttsl-lang/tests/resources/grammar/types/union types/good-with type arguments.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -// $TEST$ no_syntax_error - -segment mySegment( - x: union -) {} diff --git a/packages/ttsl-lang/tests/resources/helpers/listSafeDsFiles/nested/test file.sdstest b/packages/ttsl-lang/tests/resources/helpers/listSafeDsFiles/nested/test file.sdstest deleted file mode 100644 index e69de29b..00000000 diff --git a/packages/ttsl-lang/tests/resources/helpers/listSafeDsFiles/not a safe-ds file.txt b/packages/ttsl-lang/tests/resources/helpers/listSafeDsFiles/not a safe-ds file.txt deleted file mode 100644 index e69de29b..00000000 diff --git a/packages/ttsl-lang/tests/resources/helpers/listSafeDsFiles/pipeline file.sdspipe b/packages/ttsl-lang/tests/resources/helpers/listSafeDsFiles/pipeline file.sdspipe deleted file mode 100644 index e69de29b..00000000 diff --git a/packages/ttsl-lang/tests/resources/helpers/listSafeDsFiles/skip pipeline file.sdspipe b/packages/ttsl-lang/tests/resources/helpers/listSafeDsFiles/skip pipeline file.sdspipe deleted file mode 100644 index e69de29b..00000000 diff --git a/packages/ttsl-lang/tests/resources/helpers/listSafeDsFiles/skip stub file.sdsstub b/packages/ttsl-lang/tests/resources/helpers/listSafeDsFiles/skip stub file.sdsstub deleted file mode 100644 index e69de29b..00000000 diff --git a/packages/ttsl-lang/tests/resources/helpers/listSafeDsFiles/skip test file.sdstest b/packages/ttsl-lang/tests/resources/helpers/listSafeDsFiles/skip test file.sdstest deleted file mode 100644 index e69de29b..00000000 diff --git a/packages/ttsl-lang/tests/resources/helpers/listSafeDsFiles/stub file.sdsstub b/packages/ttsl-lang/tests/resources/helpers/listSafeDsFiles/stub file.sdsstub deleted file mode 100644 index e69de29b..00000000 diff --git a/packages/ttsl-lang/tests/resources/helpers/listSafeDsFiles/test file.sdstest b/packages/ttsl-lang/tests/resources/helpers/listSafeDsFiles/test file.sdstest deleted file mode 100644 index e69de29b..00000000 diff --git a/packages/ttsl-lang/tests/resources/helpers/listSafeDsFiles/nested/not a safe-ds file.txt b/packages/ttsl-lang/tests/resources/helpers/listTTSLFiles/function file.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/helpers/listSafeDsFiles/nested/not a safe-ds file.txt rename to packages/ttsl-lang/tests/resources/helpers/listTTSLFiles/function file.ttsl diff --git a/packages/ttsl-lang/tests/resources/helpers/listSafeDsFiles/nested/pipeline file.sdspipe b/packages/ttsl-lang/tests/resources/helpers/listTTSLFiles/nested/function file.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/helpers/listSafeDsFiles/nested/pipeline file.sdspipe rename to packages/ttsl-lang/tests/resources/helpers/listTTSLFiles/nested/function file.ttsl diff --git a/packages/ttsl-lang/tests/resources/helpers/listSafeDsFiles/nested/skip pipeline file.sdspipe b/packages/ttsl-lang/tests/resources/helpers/listTTSLFiles/nested/not a ttsl file.txt similarity index 100% rename from packages/ttsl-lang/tests/resources/helpers/listSafeDsFiles/nested/skip pipeline file.sdspipe rename to packages/ttsl-lang/tests/resources/helpers/listTTSLFiles/nested/not a ttsl file.txt diff --git a/packages/ttsl-lang/tests/resources/helpers/listSafeDsFiles/nested/skip stub file.sdsstub b/packages/ttsl-lang/tests/resources/helpers/listTTSLFiles/nested/skip function file.tts similarity index 100% rename from packages/ttsl-lang/tests/resources/helpers/listSafeDsFiles/nested/skip stub file.sdsstub rename to packages/ttsl-lang/tests/resources/helpers/listTTSLFiles/nested/skip function file.tts diff --git a/packages/ttsl-lang/tests/resources/helpers/listSafeDsFiles/nested/skip test file.sdstest b/packages/ttsl-lang/tests/resources/helpers/listTTSLFiles/not a ttsl file.txt similarity index 100% rename from packages/ttsl-lang/tests/resources/helpers/listSafeDsFiles/nested/skip test file.sdstest rename to packages/ttsl-lang/tests/resources/helpers/listTTSLFiles/not a ttsl file.txt diff --git a/packages/ttsl-lang/tests/resources/helpers/listSafeDsFiles/nested/stub file.sdsstub b/packages/ttsl-lang/tests/resources/helpers/listTTSLFiles/skip function file.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/helpers/listSafeDsFiles/nested/stub file.sdsstub rename to packages/ttsl-lang/tests/resources/helpers/listTTSLFiles/skip function file.ttsl diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/block lambdas/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/block lambdas/main.sdstest index 5e1a56dd..053b3ffe 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/block lambdas/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/block lambdas/main.sdstest @@ -1,6 +1,6 @@ package tests.partialValidation.baseCases.expressionLambdas -pipeline test { - // $TEST$ serialization $expressionLambdaClosure +function test () { + # $TEST$ serialization $expressionLambdaClosure »() -> 1«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/boolean literals/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/boolean literals/main.sdstest index c12e0ca7..c4bc6b25 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/boolean literals/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/boolean literals/main.sdstest @@ -1,9 +1,9 @@ package tests.partialValidation.baseCases.booleanLiterals -pipeline test { - // $TEST$ serialization false +function test () { + # $TEST$ serialization false »false«; - // $TEST$ serialization true + # $TEST$ serialization true »true«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/classes/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/classes/main.sdstest index 372271be..b7a98b21 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/classes/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/classes/main.sdstest @@ -1,4 +1,4 @@ package tests.partialValidation.baseCases.classes -// $TEST$ serialization C +# $TEST$ serialization C »class C« diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/enum variants/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/enum variants/main.sdstest index 8c4fcc88..c5844cd6 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/enum variants/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/enum variants/main.sdstest @@ -1,6 +1,6 @@ package tests.partialValidation.baseCases.enumVariants enum MyEnum { - // $TEST$ serialization MyVariant + # $TEST$ serialization MyVariant »MyVariant« } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/expression lambdas/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/expression lambdas/main.sdstest index 686070ce..d8192c7b 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/expression lambdas/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/expression lambdas/main.sdstest @@ -1,6 +1,6 @@ package tests.partialValidation.baseCases.blockLambdas -pipeline test { - // $TEST$ serialization $blockLambdaClosure +function test () { + # $TEST$ serialization $blockLambdaClosure »() {}«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/float literals/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/float literals/main.sdstest index c5f6dab5..ac3aff79 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/float literals/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/float literals/main.sdstest @@ -1,9 +1,9 @@ package tests.partialValidation.baseCases.floatLiterals -pipeline test { - // $TEST$ serialization 1.25 +function test () { + # $TEST$ serialization 1.25 »1.25«; - // $TEST$ serialization 0.02 + # $TEST$ serialization 0.02 »2e-2«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/functions/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/functions/main.sdstest index 1f0f1b21..f5a02d39 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/functions/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/functions/main.sdstest @@ -1,4 +1,4 @@ package tests.partialValidation.baseCases.functions -// $TEST$ serialization f +# $TEST$ serialization f @Pure »fun f()« diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/int literals/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/int literals/main.sdstest index 6a9e1c38..c878bd3f 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/int literals/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/int literals/main.sdstest @@ -1,6 +1,6 @@ package tests.partialValidation.baseCases.intLiterals -pipeline test { - // $TEST$ serialization 123 +function test () { + # $TEST$ serialization 123 »123«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/null literals/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/null literals/main.sdstest index ce8914a9..1ff4df72 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/null literals/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/null literals/main.sdstest @@ -1,6 +1,6 @@ package tests.partialValidation.baseCases.nullLiterals -pipeline test { - // $TEST$ serialization null +function test () { + # $TEST$ serialization null »null«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/segments/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/segments/main.sdstest index fc5b4734..044fabca 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/segments/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/segments/main.sdstest @@ -1,4 +1,4 @@ package tests.partialValidation.baseCases.segments -// $TEST$ serialization mySegment +# $TEST$ serialization mySegment »segment mySegment() {}« diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/string literals (without interpolation)/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/string literals (without interpolation)/main.sdstest index cfa452d8..ac5c5c28 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/string literals (without interpolation)/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/string literals (without interpolation)/main.sdstest @@ -1,9 +1,9 @@ package tests.partialValidation.baseCases.stringLiteralsWithoutInterpolation -pipeline test { - // $TEST$ serialization "test" +function test () { + # $TEST$ serialization "test" »"test"«; - // $TEST$ serialization "test\t" + # $TEST$ serialization "test\t" »"test\t"«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/invalid nodes/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/invalid nodes/main.sdstest index 90e69ec8..fcbb8463 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/invalid nodes/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/invalid nodes/main.sdstest @@ -1,4 +1,4 @@ package tests.partialValidation.invalidNodes -// $TEST$ serialization ? +# $TEST$ serialization ? »schema mySchema {}« diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/arguments/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/arguments/main.sdstest index 3513e80a..b3972cee 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/arguments/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/arguments/main.sdstest @@ -2,10 +2,10 @@ package tests.partialValidation.recursiveCases.arguments @Pure fun f(p: Any?) -pipeline test { - // $TEST$ serialization 1 +function test () { + # $TEST$ serialization 1 f(»p = 1«); - // $TEST$ serialization null + # $TEST$ serialization null f(»p = null«); } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/block lambda results/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/block lambda results/main.sdstest index 8632b110..e9065fe0 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/block lambda results/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/block lambda results/main.sdstest @@ -4,14 +4,14 @@ segment mySegment() -> r: Int { yield r = 2; } -pipeline test { +function test () { () { - // $TEST$ serialization 1 - // $TEST$ serialization ? + # $TEST$ serialization 1 + # $TEST$ serialization ? »yield a«, »yield b« = 1; - // $TEST$ serialization 2 - // $TEST$ serialization ? + # $TEST$ serialization 2 + # $TEST$ serialization ? »yield c«, »yield d« = mySegment(); }; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/placeholders/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/placeholders/main.sdstest index a3df4036..fbe8a595 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/placeholders/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/placeholders/main.sdstest @@ -4,12 +4,12 @@ segment mySegment() -> r: Int { yield r = 2; } -pipeline test { - // $TEST$ serialization 1 - // $TEST$ serialization ? +function test () { + # $TEST$ serialization 1 + # $TEST$ serialization ? »val a«, »val b« = 1; - // $TEST$ serialization 2 - // $TEST$ serialization ? + # $TEST$ serialization 2 + # $TEST$ serialization ? »val c«, »val d« = mySegment(); } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/wildcards/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/wildcards/main.sdstest index a0876509..0a7224d1 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/wildcards/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/wildcards/main.sdstest @@ -4,12 +4,12 @@ segment mySegment() -> r: Int { yield r = 2; } -pipeline test { - // $TEST$ serialization 1 - // $TEST$ serialization ? +function test () { + # $TEST$ serialization 1 + # $TEST$ serialization ? »_«, »_« = 1; - // $TEST$ serialization 2 - // $TEST$ serialization ? + # $TEST$ serialization 2 + # $TEST$ serialization ? »_«, »_« = mySegment(); } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/yields/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/yields/main.sdstest index 8731cd3a..98316b0e 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/yields/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/yields/main.sdstest @@ -5,11 +5,11 @@ segment mySegment() -> r: Int { } segment mySegment2() -> (a: Int, b: Int, c: Int, d: Int) { - // $TEST$ serialization 1 - // $TEST$ serialization ? + # $TEST$ serialization 1 + # $TEST$ serialization ? »yield a«, »yield b« = 1; - // $TEST$ serialization 2 - // $TEST$ serialization ? + # $TEST$ serialization 2 + # $TEST$ serialization ? »yield c«, »yield d« = mySegment(); } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of block lambdas/closure.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of block lambdas/closure.sdstest index ab57993a..fee587b2 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of block lambdas/closure.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of block lambdas/closure.sdstest @@ -6,7 +6,7 @@ segment mySegment(p: Int) -> (closure: () -> (r: Int)) { }; } -pipeline test { - // $TEST$ serialization 1 +function test () { + # $TEST$ serialization 1 »mySegment(1)()«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of block lambdas/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of block lambdas/main.sdstest index 298349dd..120b3b87 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of block lambdas/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of block lambdas/main.sdstest @@ -1,11 +1,11 @@ package tests.partialValidation.recursiveCases.calls.ofBlockLambdas -pipeline test { +function test () { val blockLambda = () { yield r = 1; yield s = 2; }; - // $TEST$ serialization (r = 1, s = 2) + # $TEST$ serialization (r = 1, s = 2) »blockLambda()«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of block lambdas/previous parameter value used as default value.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of block lambdas/previous parameter value used as default value.sdstest index 3a09c0d5..8703200d 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of block lambdas/previous parameter value used as default value.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of block lambdas/previous parameter value used as default value.sdstest @@ -1,10 +1,10 @@ package tests.partialValidation.recursiveCases.calls.ofBlockLambdas.previousParameterValueUsedAsDefaultValue -pipeline test { +function test () { val blockLambda = (p1: Int, p2: Int = p1) { yield r = p2; }; - // $TEST$ serialization 1 + # $TEST$ serialization 1 »blockLambda(1)«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of classes/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of classes/main.sdstest index fcceeec4..618cc316 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of classes/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of classes/main.sdstest @@ -2,7 +2,7 @@ package tests.partialValidation.recursiveCases.calls.ofClasses class C() -pipeline test { - // $TEST$ serialization ? +function test () { + # $TEST$ serialization ? »C()«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of enum variants/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of enum variants/main.sdstest index e972a57d..8d0b6bb9 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of enum variants/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of enum variants/main.sdstest @@ -5,31 +5,31 @@ enum MyEnum { MyEnumVariantWithParameters(p: Int, q: Int = 3) } -pipeline test { - // $TEST$ serialization MyEnumVariantWithoutParameters() +function test () { + # $TEST$ serialization MyEnumVariantWithoutParameters() »MyEnum.MyEnumVariantWithoutParameters()«; - // $TEST$ serialization MyEnumVariantWithParameters(p = ?, q = 3) + # $TEST$ serialization MyEnumVariantWithParameters(p = ?, q = 3) »MyEnum.MyEnumVariantWithParameters()«; - // $TEST$ serialization MyEnumVariantWithParameters(p = 1, q = 3) + # $TEST$ serialization MyEnumVariantWithParameters(p = 1, q = 3) »MyEnum.MyEnumVariantWithParameters(1)«; - // $TEST$ serialization MyEnumVariantWithParameters(p = 1, q = 2) + # $TEST$ serialization MyEnumVariantWithParameters(p = 1, q = 2) »MyEnum.MyEnumVariantWithParameters(1, 2)«; - // $TEST$ serialization MyEnumVariantWithParameters(p = 1, q = 2) + # $TEST$ serialization MyEnumVariantWithParameters(p = 1, q = 2) »MyEnum.MyEnumVariantWithParameters(q = 2, p = 1)«; - // $TEST$ serialization MyEnumVariantWithParameters(p = 1, q = ?) + # $TEST$ serialization MyEnumVariantWithParameters(p = 1, q = ?) »MyEnum.MyEnumVariantWithParameters(1, f())«; - // $TEST$ serialization MyEnumVariantWithParameters(p = 1, q = ?) + # $TEST$ serialization MyEnumVariantWithParameters(p = 1, q = ?) »MyEnum.MyEnumVariantWithParameters(1, f(), 3)«; - // $TEST$ serialization MyEnumVariantWithParameters(p = 1, q = ?) + # $TEST$ serialization MyEnumVariantWithParameters(p = 1, q = ?) »MyEnum.MyEnumVariantWithParameters(1, f(), r = 3)«; - // $TEST$ serialization ? + # $TEST$ serialization ? »MyEnum.MyEnumVariantWithParameters(q = 2, p = 1)()«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of expression lambdas/closure.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of expression lambdas/closure.sdstest index d21009b1..0eb2f466 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of expression lambdas/closure.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of expression lambdas/closure.sdstest @@ -4,7 +4,7 @@ segment mySegment(p: Int) -> (closure: () -> (r: Int)) { yield closure = () -> p; } -pipeline test { - // $TEST$ serialization 1 +function test () { + # $TEST$ serialization 1 »mySegment(1)()«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of expression lambdas/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of expression lambdas/main.sdstest index dc73fa86..1f4c605c 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of expression lambdas/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of expression lambdas/main.sdstest @@ -1,8 +1,8 @@ package tests.partialValidation.recursiveCases.calls.ofExpressionLambdas -pipeline test { +function test () { val expressionLambda = () -> 1; - // $TEST$ serialization 1 + # $TEST$ serialization 1 »expressionLambda()«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of expression lambdas/previous parameter value used as default value.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of expression lambdas/previous parameter value used as default value.sdstest index 0a679ab7..564faaa9 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of expression lambdas/previous parameter value used as default value.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of expression lambdas/previous parameter value used as default value.sdstest @@ -1,8 +1,8 @@ package tests.partialValidation.recursiveCases.calls.ofExpressionLambdas.previousParameterValueUsedAsDefaultValue -pipeline test { +function test () { val expressionLambda = (p1: Int, p2: Int = p1) -> p2; - // $TEST$ serialization 1 + # $TEST$ serialization 1 »expressionLambda(1)«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of functions/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of functions/main.sdstest index afb1fb27..e095cbcc 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of functions/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of functions/main.sdstest @@ -2,7 +2,7 @@ package tests.partialValidation.recursiveCases.calls.ofFunctions @Pure fun f() -pipeline test { - // $TEST$ serialization ? +function test () { + # $TEST$ serialization ? »f()«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of segments/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of segments/main.sdstest index ee852b01..c08f70f6 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of segments/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of segments/main.sdstest @@ -4,7 +4,7 @@ segment mySegment() -> (r: Int, s: Int) { yield r = 1; } -pipeline test { - // $TEST$ serialization (r = 1, s = ?) +function test () { + # $TEST$ serialization (r = 1, s = ?) »mySegment()«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of segments/previous parameter value used as default value.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of segments/previous parameter value used as default value.sdstest index 9963635f..39d42c3f 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of segments/previous parameter value used as default value.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of segments/previous parameter value used as default value.sdstest @@ -4,7 +4,7 @@ segment mySegment(p1: Int, p2: Int = p1) -> r: Int { yield r = p2; } -pipeline test { - // $TEST$ serialization 1 +function test () { + # $TEST$ serialization 1 »mySegment(1)«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of unknown parameter/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of unknown parameter/main.sdstest index bc6e981f..2a20f556 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of unknown parameter/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of unknown parameter/main.sdstest @@ -1,6 +1,6 @@ package tests.partialValidation.recursiveCases.calls.ofUnknownParameter segment mySegment(p: () -> ()) { - // $TEST$ serialization ? + # $TEST$ serialization ? »p()«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/on null/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/on null/main.sdstest index d09f45c6..97e7d234 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/on null/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/on null/main.sdstest @@ -1,9 +1,9 @@ package tests.partialValidation.recursiveCases.calls.onNull segment mySegment() { - // $TEST$ serialization ? + # $TEST$ serialization ? »null()«; - // $TEST$ serialization null + # $TEST$ serialization null »null?()«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/recursion/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/recursion/main.sdstest index bd812258..5a362728 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/recursion/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/recursion/main.sdstest @@ -1,6 +1,6 @@ package tests.partialValidation.recursiveCases.calls.recursion segment mySegment() -> r: Int { - // $TEST$ serialization ? + # $TEST$ serialization ? yield r = »mySegment()«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/unresolved/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/unresolved/main.sdstest index 3fd30caf..9c04e07b 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/unresolved/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/unresolved/main.sdstest @@ -4,10 +4,10 @@ enum MyEnum { MyEnumVariant } -pipeline test { - // $TEST$ serialization ? +function test () { + # $TEST$ serialization ? »unresolved.MyEnumVariant()«; - // $TEST$ serialization ? + # $TEST$ serialization ? »MyEnum.unresolved()«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on lists/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on lists/main.sdstest index eceb9abb..0d85709f 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on lists/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on lists/main.sdstest @@ -1,24 +1,24 @@ package tests.partialValidation.recursiveCases.indexedAccess.onLists -pipeline test { - // $TEST$ serialization 2 +function test () { + # $TEST$ serialization 2 »[1, 2, 3][1]«; - // $TEST$ serialization 1 + # $TEST$ serialization 1 »[1, 2, unresolved][0]«; - // $TEST$ serialization ? + # $TEST$ serialization ? »[1, 2, unresolved][2]«; - // $TEST$ serialization ? + # $TEST$ serialization ? »[][-1]«; - // $TEST$ serialization ? + # $TEST$ serialization ? »[][1]«; - // $TEST$ serialization ? + # $TEST$ serialization ? »[][""]«; - // $TEST$ serialization ? + # $TEST$ serialization ? »[][unresolved]«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on maps/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on maps/main.sdstest index 9a2e8d60..2740f21d 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on maps/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on maps/main.sdstest @@ -1,21 +1,21 @@ package tests.partialValidation.recursiveCases.indexedAccess.onMaps -pipeline test { - // $TEST$ serialization 1 +function test () { + # $TEST$ serialization 1 »{"1": 1}["1"]«; - // $TEST$ serialization 2 - »{"1": 1, "1": 2}["1"]«; // In Python the last matching entry wins, so we need to mimic that behavior + # $TEST$ serialization 2 + »{"1": 1, "1": 2}["1"]«; # In Python the last matching entry wins, so we need to mimic that behavior - // $TEST$ serialization 2 + # $TEST$ serialization 2 »{"1": 1, "2": 2, "3": unresolved}["2"]«; - // $TEST$ serialization ? + # $TEST$ serialization ? »{"1": 1, "2": 2, "3": unresolved}["3"]«; - // $TEST$ serialization ? + # $TEST$ serialization ? »{}[1]«; - // $TEST$ serialization ? + # $TEST$ serialization ? »{}[unresolved]«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on null/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on null/main.sdstest index e19c2fea..6544feef 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on null/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on null/main.sdstest @@ -1,9 +1,9 @@ package tests.partialValidation.recursiveCases.indexedAccess.onNull -pipeline test { - // $TEST$ serialization ? +function test () { + # $TEST$ serialization ? »null[0]«; - // $TEST$ serialization null + # $TEST$ serialization null »null?[0]«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on other/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on other/main.sdstest index 599dd967..feb80032 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on other/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on other/main.sdstest @@ -1,9 +1,9 @@ package tests.partialValidation.recursiveCases.indexedAccess.onOther -pipeline test { - // $TEST$ serialization ? +function test () { + # $TEST$ serialization ? »1[1]«; - // $TEST$ serialization ? + # $TEST$ serialization ? »unresolved[1]«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/and/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/and/main.sdstest index f9df8974..745111c4 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/and/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/and/main.sdstest @@ -1,27 +1,27 @@ package tests.partialValidation.recursiveCases.infixOperations.`and` -pipeline test { - // $TEST$ serialization false +function test () { + # $TEST$ serialization false »false and false«; - // $TEST$ serialization false + # $TEST$ serialization false »false and true«; - // $TEST$ serialization false + # $TEST$ serialization false »true and false«; - // $TEST$ serialization true + # $TEST$ serialization true »true and true«; - // $TEST$ serialization ? + # $TEST$ serialization ? »1 and true«; - // $TEST$ serialization ? + # $TEST$ serialization ? »true and 0«; - // $TEST$ serialization ? + # $TEST$ serialization ? »unresolved and true«; - // $TEST$ serialization ? + # $TEST$ serialization ? »true and unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/and/short circuiting.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/and/short circuiting.sdstest index 6a17bac2..20c30217 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/and/short circuiting.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/and/short circuiting.sdstest @@ -9,22 +9,22 @@ fun functionWithoutSideEffects() -> result: Boolean @Impure([ImpurityReason.FileWriteToConstantPath("test.txt")]) fun functionWithSideEffects() -> result: Boolean -pipeline test { - // $TEST$ serialization false +function test () { + # $TEST$ serialization false »false and pureFunction()«; - // $TEST$ serialization false + # $TEST$ serialization false »false and functionWithoutSideEffects()«; - // $TEST$ serialization false + # $TEST$ serialization false »false and functionWithSideEffects()«; - // $TEST$ serialization ? + # $TEST$ serialization ? »true and pureFunction()«; - // $TEST$ serialization ? + # $TEST$ serialization ? »true and functionWithoutSideEffects()«; - // $TEST$ serialization ? + # $TEST$ serialization ? »true and functionWithSideEffects()«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/divided by/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/divided by/main.sdstest index c04021c2..e4d2c59e 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/divided by/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/divided by/main.sdstest @@ -1,38 +1,38 @@ package tests.partialValidation.recursiveCases.infixOperations.dividedBy -pipeline test { - // $TEST$ serialization 0.5 +function test () { + # $TEST$ serialization 0.5 »0.25 / 0.5«; - // $TEST$ serialization 1.5 + # $TEST$ serialization 1.5 »1.5 / 1«; - // $TEST$ serialization 1.6 + # $TEST$ serialization 1.6 »1 / 0.625«; - // $TEST$ serialization 1 + # $TEST$ serialization 1 »1 / 1«; - // $TEST$ serialization ? + # $TEST$ serialization ? »1 / 0«; - // $TEST$ serialization ? + # $TEST$ serialization ? »1 / 0.0«; - // $TEST$ serialization ? + # $TEST$ serialization ? »1 / -0.0«; - // $TEST$ serialization ? + # $TEST$ serialization ? »true / 1«; - // $TEST$ serialization ? + # $TEST$ serialization ? »1 / true«; - // $TEST$ serialization ? + # $TEST$ serialization ? »unresolved / 1«; - // $TEST$ serialization ? + # $TEST$ serialization ? »1 / unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/elvis/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/elvis/main.sdstest index 1b3d047c..9d44a444 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/elvis/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/elvis/main.sdstest @@ -1,21 +1,21 @@ package tests.partialValidation.recursiveCases.infixOperations.elvis -pipeline test { - // $TEST$ serialization true +function test () { + # $TEST$ serialization true »true ?: false«; - // $TEST$ serialization false + # $TEST$ serialization false »null ?: false«; - // $TEST$ serialization $expressionLambdaClosure + # $TEST$ serialization $expressionLambdaClosure »(() -> 1) ?: false«; - // $TEST$ serialization ? + # $TEST$ serialization ? »(() -> 1) ?: unresolved«; - // $TEST$ serialization ? + # $TEST$ serialization ? »unresolved ?: null«; - // $TEST$ serialization ? + # $TEST$ serialization ? »null ?: unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/elvis/short circuiting.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/elvis/short circuiting.sdstest index 174cd208..902a6691 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/elvis/short circuiting.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/elvis/short circuiting.sdstest @@ -9,22 +9,22 @@ fun functionWithoutSideEffects() -> result: Boolean @Impure([ImpurityReason.FileWriteToConstantPath("test.txt")]) fun functionWithSideEffects() -> result: Boolean -pipeline test { - // $TEST$ serialization 1 +function test () { + # $TEST$ serialization 1 »1 ?: pureFunction()«; - // $TEST$ serialization 1 + # $TEST$ serialization 1 »1 ?: functionWithoutSideEffects()«; - // $TEST$ serialization 1 + # $TEST$ serialization 1 »1 ?: functionWithSideEffects()«; - // $TEST$ serialization ? + # $TEST$ serialization ? »null ?: pureFunction()«; - // $TEST$ serialization ? + # $TEST$ serialization ? »null ?: functionWithoutSideEffects()«; - // $TEST$ serialization ? + # $TEST$ serialization ? »null ?: functionWithSideEffects()«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/equals/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/equals/main.sdstest index 177b74c1..ebfca5ea 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/equals/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/equals/main.sdstest @@ -1,15 +1,15 @@ package tests.partialValidation.recursiveCases.infixOperations.equals -pipeline test { - // $TEST$ serialization true +function test () { + # $TEST$ serialization true »true == true«; - // $TEST$ serialization false + # $TEST$ serialization false »false == 1«; - // $TEST$ serialization ? + # $TEST$ serialization ? »1 == unresolved«; - // $TEST$ serialization ? + # $TEST$ serialization ? »unresolved == 1.25«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/greater than or equals/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/greater than or equals/main.sdstest index 5f9e3f6b..a4469898 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/greater than or equals/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/greater than or equals/main.sdstest @@ -1,41 +1,41 @@ package tests.partialValidation.recursiveCases.infixOperations.greaterThanOrEquals -pipeline test { - // $TEST$ serialization true +function test () { + # $TEST$ serialization true »0.5 >= 0.5«; - // $TEST$ serialization true + # $TEST$ serialization true »1.5 >= 0«; - // $TEST$ serialization true + # $TEST$ serialization true »1 >= 0.5«; - // $TEST$ serialization true + # $TEST$ serialization true »1 >= 0«; - // $TEST$ serialization false + # $TEST$ serialization false »0.5 >= 1.5«; - // $TEST$ serialization false + # $TEST$ serialization false »0.5 >= 1«; - // $TEST$ serialization false + # $TEST$ serialization false »0 >= 1.5«; - // $TEST$ serialization false + # $TEST$ serialization false »0 >= 1«; - // $TEST$ serialization ? + # $TEST$ serialization ? »1 >= true«; - // $TEST$ serialization ? + # $TEST$ serialization ? »false >= 0«; - // $TEST$ serialization ? + # $TEST$ serialization ? »unresolved >= false«; - // $TEST$ serialization ? + # $TEST$ serialization ? »true >= unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/greater than/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/greater than/main.sdstest index de60757f..24871466 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/greater than/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/greater than/main.sdstest @@ -1,41 +1,41 @@ package tests.partialValidation.recursiveCases.infixOperations.greaterThan -pipeline test { - // $TEST$ serialization true +function test () { + # $TEST$ serialization true »1.5 > 0.5«; - // $TEST$ serialization true + # $TEST$ serialization true »1.5 > 0«; - // $TEST$ serialization true + # $TEST$ serialization true »1 > 0.5«; - // $TEST$ serialization true + # $TEST$ serialization true »1 > 0«; - // $TEST$ serialization false + # $TEST$ serialization false »0.5 > 1.5«; - // $TEST$ serialization false + # $TEST$ serialization false »0.5 > 1«; - // $TEST$ serialization false + # $TEST$ serialization false »0 > 1.5«; - // $TEST$ serialization false + # $TEST$ serialization false »0 > 1«; - // $TEST$ serialization ? + # $TEST$ serialization ? »1 > true«; - // $TEST$ serialization ? + # $TEST$ serialization ? »false > 0«; - // $TEST$ serialization ? + # $TEST$ serialization ? »unresolved > false«; - // $TEST$ serialization ? + # $TEST$ serialization ? »true > unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/identical to/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/identical to/main.sdstest index 9f663404..bf1cfd8a 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/identical to/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/identical to/main.sdstest @@ -1,15 +1,15 @@ package tests.partialValidation.recursiveCases.infixOperations.identicalTo -pipeline test { - // $TEST$ serialization true +function test () { + # $TEST$ serialization true »true === true«; - // $TEST$ serialization false + # $TEST$ serialization false »false === 1«; - // $TEST$ serialization ? + # $TEST$ serialization ? »1 === unresolved«; - // $TEST$ serialization ? + # $TEST$ serialization ? »unresolved === 1.25«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/less than or equals/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/less than or equals/main.sdstest index 19420212..7614b48f 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/less than or equals/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/less than or equals/main.sdstest @@ -1,41 +1,41 @@ package tests.partialValidation.recursiveCases.infixOperations.lessThanOrEquals -pipeline test { - // $TEST$ serialization true +function test () { + # $TEST$ serialization true »0.5 <= 0.5«; - // $TEST$ serialization true + # $TEST$ serialization true »0.5 <= 1«; - // $TEST$ serialization true + # $TEST$ serialization true »0 <= 1.5«; - // $TEST$ serialization true + # $TEST$ serialization true »0 <= 1«; - // $TEST$ serialization false + # $TEST$ serialization false »1.5 <= 0.5«; - // $TEST$ serialization false + # $TEST$ serialization false »1.5 <= 0«; - // $TEST$ serialization false + # $TEST$ serialization false »1 <= 0.5«; - // $TEST$ serialization false + # $TEST$ serialization false »1 <= 0«; - // $TEST$ serialization ? + # $TEST$ serialization ? »1 <= true«; - // $TEST$ serialization ? + # $TEST$ serialization ? »false <= 0«; - // $TEST$ serialization ? + # $TEST$ serialization ? »unresolved <= false«; - // $TEST$ serialization ? + # $TEST$ serialization ? »true <= unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/less than/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/less than/main.sdstest index c368f289..e66f681f 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/less than/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/less than/main.sdstest @@ -1,41 +1,41 @@ package tests.partialValidation.recursiveCases.infixOperations.lessThan -pipeline test { - // $TEST$ serialization true +function test () { + # $TEST$ serialization true »0.5 < 1.5«; - // $TEST$ serialization true + # $TEST$ serialization true »0.5 < 1«; - // $TEST$ serialization true + # $TEST$ serialization true »0 < 1.5«; - // $TEST$ serialization true + # $TEST$ serialization true »0 < 1«; - // $TEST$ serialization false + # $TEST$ serialization false »1.5 < 0.5«; - // $TEST$ serialization false + # $TEST$ serialization false »1.5 < 0«; - // $TEST$ serialization false + # $TEST$ serialization false »1 < 0.5«; - // $TEST$ serialization false + # $TEST$ serialization false »1 < 1«; - // $TEST$ serialization ? + # $TEST$ serialization ? »1 < true«; - // $TEST$ serialization ? + # $TEST$ serialization ? »false < 0«; - // $TEST$ serialization ? + # $TEST$ serialization ? »unresolved < false«; - // $TEST$ serialization ? + # $TEST$ serialization ? »true < unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/minus/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/minus/main.sdstest index 1ab3020d..697d99e8 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/minus/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/minus/main.sdstest @@ -1,28 +1,28 @@ package tests.partialValidation.recursiveCases.infixOperations.minus -pipeline test { - // $TEST$ serialization 1.25 +function test () { + # $TEST$ serialization 1.25 »1.5 - 0.25«; - // $TEST$ serialization 0.5 + # $TEST$ serialization 0.5 »1.5 - 1«; - // $TEST$ serialization 0.75 + # $TEST$ serialization 0.75 »1 - 0.25«; - // $TEST$ serialization 0 + # $TEST$ serialization 0 »1 - 1«; - // $TEST$ serialization ? + # $TEST$ serialization ? »true - 1«; - // $TEST$ serialization ? + # $TEST$ serialization ? »1 - true«; - // $TEST$ serialization ? + # $TEST$ serialization ? »unresolved - 1«; - // $TEST$ serialization ? + # $TEST$ serialization ? »1 - unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/not equals/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/not equals/main.sdstest index 539dbf17..62a328de 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/not equals/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/not equals/main.sdstest @@ -1,15 +1,15 @@ package tests.partialValidation.recursiveCases.infixOperations.notEquals -pipeline test { - // $TEST$ serialization false +function test () { + # $TEST$ serialization false »true != true«; - // $TEST$ serialization true + # $TEST$ serialization true »false != 1«; - // $TEST$ serialization ? + # $TEST$ serialization ? »1 != unresolved«; - // $TEST$ serialization ? + # $TEST$ serialization ? »unresolved != 1.25«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/not identical to/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/not identical to/main.sdstest index 32e217d9..b239af1d 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/not identical to/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/not identical to/main.sdstest @@ -1,15 +1,15 @@ package tests.partialValidation.recursiveCases.infixOperations.notIdenticalTo -pipeline test { - // $TEST$ serialization false +function test () { + # $TEST$ serialization false »true !== true«; - // $TEST$ serialization true + # $TEST$ serialization true »false !== 1«; - // $TEST$ serialization ? + # $TEST$ serialization ? »1 !== unresolved«; - // $TEST$ serialization ? + # $TEST$ serialization ? »unresolved !== 1.25«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/or/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/or/main.sdstest index 5df518f9..19e49cf3 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/or/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/or/main.sdstest @@ -1,27 +1,27 @@ package tests.partialValidation.recursiveCases.infixOperations.`or` -pipeline test { - // $TEST$ serialization false +function test () { + # $TEST$ serialization false »false or false«; - // $TEST$ serialization true + # $TEST$ serialization true »false or true«; - // $TEST$ serialization true + # $TEST$ serialization true »true or false«; - // $TEST$ serialization true + # $TEST$ serialization true »true or true«; - // $TEST$ serialization ? + # $TEST$ serialization ? »1 or false«; - // $TEST$ serialization ? + # $TEST$ serialization ? »false or 0«; - // $TEST$ serialization ? + # $TEST$ serialization ? »unresolved or false«; - // $TEST$ serialization ? + # $TEST$ serialization ? »false or unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/or/short circuiting.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/or/short circuiting.sdstest index 0fa82fc0..ed6ec041 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/or/short circuiting.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/or/short circuiting.sdstest @@ -9,22 +9,22 @@ fun functionWithoutSideEffects() -> result: Boolean @Impure([ImpurityReason.FileWriteToConstantPath("test.txt")]) fun functionWithSideEffects() -> result: Boolean -pipeline test { - // $TEST$ serialization true +function test () { + # $TEST$ serialization true »true or pureFunction()«; - // $TEST$ serialization true + # $TEST$ serialization true »true or functionWithoutSideEffects()«; - // $TEST$ serialization true + # $TEST$ serialization true »true or functionWithSideEffects()«; - // $TEST$ serialization ? + # $TEST$ serialization ? »false or pureFunction()«; - // $TEST$ serialization ? + # $TEST$ serialization ? »false or functionWithoutSideEffects()«; - // $TEST$ serialization ? + # $TEST$ serialization ? »false or functionWithSideEffects()«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/plus/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/plus/main.sdstest index 0d5b0e7f..4dd0f1a6 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/plus/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/plus/main.sdstest @@ -1,28 +1,28 @@ package tests.partialValidation.recursiveCases.infixOperations.plus -pipeline test { - // $TEST$ serialization 1.75 +function test () { + # $TEST$ serialization 1.75 »1.5 + 0.25«; - // $TEST$ serialization 2.5 + # $TEST$ serialization 2.5 »1.5 + 1«; - // $TEST$ serialization 1.25 + # $TEST$ serialization 1.25 »1 + 0.25«; - // $TEST$ serialization 2 + # $TEST$ serialization 2 »1 + 1«; - // $TEST$ serialization ? + # $TEST$ serialization ? »true + 1«; - // $TEST$ serialization ? + # $TEST$ serialization ? »1 + true«; - // $TEST$ serialization ? + # $TEST$ serialization ? »unresolved + 1«; - // $TEST$ serialization ? + # $TEST$ serialization ? »1 + unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/times/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/times/main.sdstest index 1bcac13f..9a2312dd 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/times/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/times/main.sdstest @@ -1,28 +1,28 @@ package tests.partialValidation.recursiveCases.infixOperations.times -pipeline test { - // $TEST$ serialization 0.75 +function test () { + # $TEST$ serialization 0.75 »1.5 * 0.5«; - // $TEST$ serialization 1.5 + # $TEST$ serialization 1.5 »1.5 * 1«; - // $TEST$ serialization 0.25 + # $TEST$ serialization 0.25 »1 * 0.25«; - // $TEST$ serialization 1 + # $TEST$ serialization 1 »1 * 1«; - // $TEST$ serialization ? + # $TEST$ serialization ? »true * 1«; - // $TEST$ serialization ? + # $TEST$ serialization ? »1 * true«; - // $TEST$ serialization ? + # $TEST$ serialization ? »unresolved * 1«; - // $TEST$ serialization ? + # $TEST$ serialization ? »1 * unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/lists/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/lists/main.sdstest index eb3bf454..286140f6 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/lists/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/lists/main.sdstest @@ -1,9 +1,9 @@ package tests.partialValidation.recursiveCases.lists -pipeline test { - // $TEST$ serialization [] +function test () { + # $TEST$ serialization [] »[]«; - // $TEST$ serialization [1, 2.5, null, ?] + # $TEST$ serialization [1, 2.5, null, ?] »[1, 2.5, null, unresolved]«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/maps/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/maps/main.sdstest index 25c0ef45..968867aa 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/maps/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/maps/main.sdstest @@ -1,10 +1,10 @@ package tests.partialValidation.recursiveCases.maps -pipeline test { - // $TEST$ serialization {} +function test () { + # $TEST$ serialization {} »{}«; - // $TEST$ serialization {"a": 1, "b": 2.5, "c": null, "d": ?, ?: true} + # $TEST$ serialization {"a": 1, "b": 2.5, "c": null, "d": ?, ?: true} »{ "a": 1, "b": 2.5, diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/parameters/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/parameters/main.sdstest index 0604d585..860d35f7 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/parameters/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/parameters/main.sdstest @@ -4,19 +4,19 @@ segment mySegment(p: Int) -> r: Int { yield r = p; } -pipeline myPipeline { +function myFunction () { val blockLambda = (p: Int) { yield r = p; }; val expressionLambda = (p: Int) -> p; - // $TEST$ serialization 1 + # $TEST$ serialization 1 »mySegment(1)«; - // $TEST$ serialization 1 + # $TEST$ serialization 1 »blockLambda(1)«; - // $TEST$ serialization 1 + # $TEST$ serialization 1 »expressionLambda(1)«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/parenthesized expressions/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/parenthesized expressions/main.sdstest index 81abee4d..b6fe24b8 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/parenthesized expressions/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/parenthesized expressions/main.sdstest @@ -1,11 +1,11 @@ package tests.partialValidation.recursiveCases.parenthesizedExpression -pipeline test { - // $TEST$ equivalence_class value1 - // $TEST$ equivalence_class value1 +function test () { + # $TEST$ equivalence_class value1 + # $TEST$ equivalence_class value1 »(»1«)«; - // $TEST$ equivalence_class value2 - // $TEST$ equivalence_class value2 + # $TEST$ equivalence_class value2 + # $TEST$ equivalence_class value2 »(»null«)«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/prefix operations/minus/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/prefix operations/minus/main.sdstest index e9bfcc35..5c07f09f 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/prefix operations/minus/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/prefix operations/minus/main.sdstest @@ -1,15 +1,15 @@ package tests.partialValidation.recursiveCases.prefixOperations.minus -pipeline test { - // $TEST$ serialization -1.5 +function test () { + # $TEST$ serialization -1.5 »-1.5«; - // $TEST$ serialization -1 + # $TEST$ serialization -1 »-1«; - // $TEST$ serialization ? + # $TEST$ serialization ? »-true«; - // $TEST$ serialization ? + # $TEST$ serialization ? »-unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/prefix operations/not/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/prefix operations/not/main.sdstest index 84c8e97a..38d1a0f3 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/prefix operations/not/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/prefix operations/not/main.sdstest @@ -1,15 +1,15 @@ package tests.partialValidation.recursiveCases.prefixOperations.`not` -pipeline test { - // $TEST$ serialization true +function test () { + # $TEST$ serialization true »not false«; - // $TEST$ serialization false + # $TEST$ serialization false »not true«; - // $TEST$ serialization ? + # $TEST$ serialization ? »not 0«; - // $TEST$ serialization ? + # $TEST$ serialization ? »not unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/references/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/references/main.sdstest index f19cb14c..2f20d053 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/references/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/references/main.sdstest @@ -1,10 +1,10 @@ package tests.partialEvaluation.recursiveCases.assignees.references -pipeline myPipeline { +function myFunction () { val a = 1; - // $TEST$ serialization 1 + # $TEST$ serialization 1 »a«; - // $TEST$ serialization ? + # $TEST$ serialization ? »unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/results/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/results/main.sdstest index 4b97763c..7586afb0 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/results/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/results/main.sdstest @@ -1,12 +1,12 @@ package tests.partialEvaluation.recursiveCases.assignees.results -// $TEST$ serialization ? -// $TEST$ serialization 1 -// $TEST$ serialization 2 +# $TEST$ serialization ? +# $TEST$ serialization 1 +# $TEST$ serialization 2 segment mySegment() -> (»a: Int«, »b: Int«, »c: Int«) { yield b = 1; - // Use the first yield if the same result is set multiple times + # Use the first yield if the same result is set multiple times yield c = 2; yield c = 3; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/template strings/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/template strings/main.sdstest index df5ab080..3ea78bf2 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/template strings/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/template strings/main.sdstest @@ -1,12 +1,12 @@ package tests.partialValidation.recursiveCases.templateStrings -pipeline test { - // $TEST$ serialization "start 1 inner1 true inner2 test end" +function test () { + # $TEST$ serialization "start 1 inner1 true inner2 test end" »"start {{ 1 }} inner1 {{ true }} inner2 {{ "test" }} end"«; - // $TEST$ serialization "start\\t1 inner1\\ttrue inner2\\ttest end\\t" + # $TEST$ serialization "start\\t1 inner1\\ttrue inner2\\ttest end\\t" »"start\t{{ 1 }} inner1\t{{ true }} inner2\t{{ "test" }} end\t"«; - // $TEST$ serialization ? + # $TEST$ serialization ? »"start {{ call() }} end"«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/type casts/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/type casts/main.sdstest index 5d61c482..266cbf34 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/type casts/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/type casts/main.sdstest @@ -1,9 +1,9 @@ package tests.partialValidation.recursiveCases.typeCasts -pipeline test { - // $TEST$ serialization true +function test () { + # $TEST$ serialization true »true as Boolean«; - // $TEST$ serialization 1 + # $TEST$ serialization 1 »1 as Boolean«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main no imports or own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main no imports or own declarations.sdstest index e901ee7b..a548b6e8 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main no imports or own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main no imports or own declarations.sdstest @@ -1,17 +1,17 @@ package tests.scoping.annotationCalls.acrossFiles -// $TEST$ references same_MyAnnotation +# $TEST$ references same_MyAnnotation @»MyAnnotation« -// $TEST$ references same_AnnotationInSamePackage +# $TEST$ references same_AnnotationInSamePackage @»AnnotationInSamePackage« -// $TEST$ references TTSL_AnnotationInTTSLPackage +# $TEST$ references TTSL_AnnotationInTTSLPackage @»AnnotationInTTSLPackage« -// $TEST$ unresolved +# $TEST$ unresolved @»AnnotationInAnotherPackage« -// $TEST$ unresolved +# $TEST$ unresolved @»AnnotationWithoutPackage« -pipeline myPipeline {} +function myFunction () {} diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with imports and own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with imports and own declarations.sdstest index 6b9acfac..9da51891 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with imports and own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with imports and own declarations.sdstest @@ -3,24 +3,24 @@ package tests.scoping.annotationCalls.acrossFiles from TTSL.scoping.annotationCalls.acrossFiles import MyAnnotation as MyOwnAnnotation from tests.scoping.annotationCalls.acrossFiles.other import AnnotationInAnotherPackage, Annotation2InAnotherPackage -// $TEST$ target own_MyOwnAnnotation +# $TEST$ target own_MyOwnAnnotation annotation »MyOwnAnnotation« -// $TEST$ references own_MyOwnAnnotation +# $TEST$ references own_MyOwnAnnotation @»MyOwnAnnotation« -// $TEST$ references same_AnnotationInSamePackage +# $TEST$ references same_AnnotationInSamePackage @»AnnotationInSamePackage« -// $TEST$ references TTSL_AnnotationInTTSLPackage +# $TEST$ references TTSL_AnnotationInTTSLPackage @»AnnotationInTTSLPackage« -// $TEST$ references other_AnnotationInAnotherPackage +# $TEST$ references other_AnnotationInAnotherPackage @»AnnotationInAnotherPackage« -// $TEST$ references other_Annotation2InAnotherPackage +# $TEST$ references other_Annotation2InAnotherPackage @»Annotation2InAnotherPackage« -// $TEST$ unresolved +# $TEST$ unresolved @»AnnotationWithoutPackage« -pipeline myPipeline {} +function myFunction () {} diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with multiple imports of same name.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with multiple imports of same name.sdstest index 93e73f08..c745108d 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with multiple imports of same name.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with multiple imports of same name.sdstest @@ -4,7 +4,7 @@ from TTSL.scoping.annotationCalls.acrossFiles import MyAnnotation from tests.scoping.annotationCalls.acrossFiles.other import MyAnnotation from tests.scoping.annotationCalls.acrossFiles import MyAnnotation -pipeline myPipeline { - // $TEST$ references TTSL_MyAnnotation +function myFunction () { + # $TEST$ references TTSL_MyAnnotation »MyAnnotation«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with qualified import with alias.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with qualified import with alias.sdstest index dfea21fa..bfc99160 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with qualified import with alias.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with qualified import with alias.sdstest @@ -4,28 +4,28 @@ from tests.scoping.annotationCalls.acrossFiles import MyAnnotation as MyAnnotati from TTSL.scoping.annotationCalls.acrossFiles import MyAnnotation as MyAnnotationInTTSLPackage from tests.scoping.annotationCalls.acrossFiles.other import MyAnnotation as MyAnnotationInAnotherPackage -// $TEST$ references same_MyAnnotation +# $TEST$ references same_MyAnnotation @»MyAnnotation« -// $TEST$ references same_AnnotationInSamePackage +# $TEST$ references same_AnnotationInSamePackage @»AnnotationInSamePackage« -// $TEST$ references TTSL_AnnotationInTTSLPackage +# $TEST$ references TTSL_AnnotationInTTSLPackage @»AnnotationInTTSLPackage« -// $TEST$ unresolved +# $TEST$ unresolved @»AnnotationInAnotherPackage« -// $TEST$ unresolved +# $TEST$ unresolved @»AnnotationWithoutPackage« -// $TEST$ references same_MyAnnotation +# $TEST$ references same_MyAnnotation @»MyAnnotationInSamePackage« -// $TEST$ references TTSL_MyAnnotation +# $TEST$ references TTSL_MyAnnotation @»MyAnnotationInTTSLPackage« -// $TEST$ references other_MyAnnotation +# $TEST$ references other_MyAnnotation @»MyAnnotationInAnotherPackage« -pipeline myPipeline {} +function myFunction () {} diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with qualified import.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with qualified import.sdstest index ada9880a..f3886b28 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with qualified import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with qualified import.sdstest @@ -3,24 +3,24 @@ package tests.scoping.annotationCalls.acrossFiles from TTSL.scoping.annotationCalls.acrossFiles import MyAnnotation from tests.scoping.annotationCalls.acrossFiles.other import AnnotationInAnotherPackage, Annotation2InAnotherPackage, NotAnAnnotation -// $TEST$ references TTSL_MyAnnotation +# $TEST$ references TTSL_MyAnnotation @»MyAnnotation« -// $TEST$ references same_AnnotationInSamePackage +# $TEST$ references same_AnnotationInSamePackage @»AnnotationInSamePackage« -// $TEST$ references TTSL_AnnotationInTTSLPackage +# $TEST$ references TTSL_AnnotationInTTSLPackage @»AnnotationInTTSLPackage« -// $TEST$ references other_AnnotationInAnotherPackage +# $TEST$ references other_AnnotationInAnotherPackage @»AnnotationInAnotherPackage« -// $TEST$ references other_Annotation2InAnotherPackage +# $TEST$ references other_Annotation2InAnotherPackage @»Annotation2InAnotherPackage« -// $TEST$ unresolved +# $TEST$ unresolved @»NotAnAnnotation« -// $TEST$ unresolved +# $TEST$ unresolved @»AnnotationWithoutPackage« -pipeline myPipeline {} +function myFunction () {} diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with wildcard import.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with wildcard import.sdstest index 8b90ccc8..90a7caed 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with wildcard import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/main with wildcard import.sdstest @@ -2,18 +2,18 @@ package tests.scoping.annotationCalls.acrossFiles from TTSL.scoping.annotationCalls.acrossFiles import * -// $TEST$ references TTSL_MyAnnotation +# $TEST$ references TTSL_MyAnnotation @»MyAnnotation« -// $TEST$ references same_AnnotationInSamePackage +# $TEST$ references same_AnnotationInSamePackage @»AnnotationInSamePackage« -// $TEST$ references TTSL_AnnotationInTTSLPackage +# $TEST$ references TTSL_AnnotationInTTSLPackage @»AnnotationInTTSLPackage« -// $TEST$ unresolved +# $TEST$ unresolved @»AnnotationInAnotherPackage« -// $TEST$ unresolved +# $TEST$ unresolved @»AnnotationWithoutPackage« -pipeline myPipeline {} +function myFunction () {} diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/resource other package.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/resource other package.sdstest index ca30cdcb..52b2263d 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/resource other package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/resource other package.sdstest @@ -1,13 +1,13 @@ package tests.scoping.annotationCalls.acrossFiles.other -// $TEST$ target other_MyAnnotation +# $TEST$ target other_MyAnnotation annotation »MyAnnotation« -// $TEST$ target other_AnnotationInAnotherPackage +# $TEST$ target other_AnnotationInAnotherPackage annotation »AnnotationInAnotherPackage« -// $TEST$ target other_Annotation2InAnotherPackage +# $TEST$ target other_Annotation2InAnotherPackage annotation »Annotation2InAnotherPackage« -// $TEST$ target other_NotAnAnnotation +# $TEST$ target other_NotAnAnnotation class »NotAnAnnotation« diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/resource safeds package.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/resource safeds package.sdstest index d0f8568d..327c6aab 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/resource safeds package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/resource safeds package.sdstest @@ -1,7 +1,7 @@ package TTSL.scoping.annotationCalls.acrossFiles -// $TEST$ target TTSL_MyAnnotation +# $TEST$ target TTSL_MyAnnotation annotation »MyAnnotation« -// $TEST$ target TTSL_AnnotationInTTSLPackage +# $TEST$ target TTSL_AnnotationInTTSLPackage annotation »AnnotationInTTSLPackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/resource same package.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/resource same package.sdstest index 1bb35a8b..9854b24a 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/resource same package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/resource same package.sdstest @@ -1,7 +1,7 @@ package tests.scoping.annotationCalls.acrossFiles -// $TEST$ target same_MyAnnotation +# $TEST$ target same_MyAnnotation annotation »MyAnnotation« -// $TEST$ target same_AnnotationInSamePackage +# $TEST$ target same_AnnotationInSamePackage annotation »AnnotationInSamePackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/resource without package.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/resource without package.sdstest index 39a33d04..c4c3bc48 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/resource without package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/across files/resource without package.sdstest @@ -1,5 +1,5 @@ -// $TEST$ target without_MyAnnotation +# $TEST$ target without_MyAnnotation annotation »MyAnnotation« -// $TEST$ target without_AnnotationWithoutPackage +# $TEST$ target without_AnnotationWithoutPackage annotation »AnnotationWithoutPackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on annotation/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on annotation/main.sdstest index 80a2dca1..64f9c08c 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on annotation/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on annotation/main.sdstest @@ -1,19 +1,19 @@ package tests.scoping.annotationCalls.onAnnotation -// $TEST$ target before +# $TEST$ target before annotation »Before« -// $TEST$ references before +# $TEST$ references before @»Before« -// $TEST$ references after +# $TEST$ references after @»After« -// $TEST$ unresolved +# $TEST$ unresolved @»NotAnAnnotation« -// $TEST$ unresolved +# $TEST$ unresolved @»Unresolved« annotation MyAnnotation -// $TEST$ target after +# $TEST$ target after annotation »After« class NotAnAnnotation diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on attribute/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on attribute/main.sdstest index 125e7d75..31eda997 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on attribute/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on attribute/main.sdstest @@ -1,21 +1,21 @@ package tests.scoping.annotationCalls.onAttribute -// $TEST$ target before +# $TEST$ target before annotation »Before« class MyClass { - // $TEST$ references before + # $TEST$ references before @»Before« - // $TEST$ references after + # $TEST$ references after @»After« - // $TEST$ unresolved + # $TEST$ unresolved @»NotAnAnnotation« - // $TEST$ unresolved + # $TEST$ unresolved @»Unresolved« attr myAttribute: Int } -// $TEST$ target after +# $TEST$ target after annotation »After« class NotAnAnnotation diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on class/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on class/main.sdstest index ec43aa3c..4e12ad3a 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on class/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on class/main.sdstest @@ -1,19 +1,19 @@ package tests.scoping.annotationCalls.onClass -// $TEST$ target before +# $TEST$ target before annotation »Before« -// $TEST$ references before +# $TEST$ references before @»Before« -// $TEST$ references after +# $TEST$ references after @»After« -// $TEST$ unresolved +# $TEST$ unresolved @»NotAnAnnotation« -// $TEST$ unresolved +# $TEST$ unresolved @»Unresolved« class MyClass -// $TEST$ target after +# $TEST$ target after annotation »After« class NotAnAnnotation diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on enum variant/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on enum variant/main.sdstest index 1253875f..dfcb4aee 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on enum variant/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on enum variant/main.sdstest @@ -1,21 +1,21 @@ package tests.scoping.annotationCalls.onEnumVariant -// $TEST$ target before +# $TEST$ target before annotation »Before« enum MyEnum { - // $TEST$ references before + # $TEST$ references before @»Before« - // $TEST$ references after + # $TEST$ references after @»After« - // $TEST$ unresolved + # $TEST$ unresolved @»NotAnAnnotation« - // $TEST$ unresolved + # $TEST$ unresolved @»Unresolved« MyEnumVariant } -// $TEST$ target after +# $TEST$ target after annotation »After« class NotAnAnnotation diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on enum/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on enum/main.sdstest index 161aaa07..25e03d30 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on enum/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on enum/main.sdstest @@ -1,19 +1,19 @@ package tests.scoping.annotationCalls.onEnum -// $TEST$ target before +# $TEST$ target before annotation »Before« -// $TEST$ references before +# $TEST$ references before @»Before« -// $TEST$ references after +# $TEST$ references after @»After« -// $TEST$ unresolved +# $TEST$ unresolved @»NotAnAnnotation« -// $TEST$ unresolved +# $TEST$ unresolved @»Unresolved« enum MyEnum -// $TEST$ target after +# $TEST$ target after annotation »After« class NotAnAnnotation diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on function/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on function/main.sdstest index 81bdfa2d..34d8a0d0 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on function/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on function/main.sdstest @@ -1,19 +1,19 @@ package tests.scoping.annotationCalls.onFunction -// $TEST$ target before +# $TEST$ target before annotation »Before« -// $TEST$ references before +# $TEST$ references before @»Before« -// $TEST$ references after +# $TEST$ references after @»After« -// $TEST$ unresolved +# $TEST$ unresolved @»NotAnAnnotation« -// $TEST$ unresolved +# $TEST$ unresolved @»Unresolved« fun myFunction() -// $TEST$ target after +# $TEST$ target after annotation »After« class NotAnAnnotation diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on module/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on module/main.sdstest index 54d5f865..6c06279d 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on module/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on module/main.sdstest @@ -1,13 +1,13 @@ -// $TEST$ references annotation +# $TEST$ references annotation @»MyAnnotation« -// $TEST$ unresolved +# $TEST$ unresolved @»NotAnAnnotation« -// $TEST$ unresolved +# $TEST$ unresolved @»Unresolved« package tests.scoping.annotationCalls.onModule -// $TEST$ target annotation +# $TEST$ target annotation annotation »MyAnnotation« class NotAnAnnotation diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on parameter/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on parameter/main.sdstest index 2fbdde2c..da7dc3c1 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on parameter/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on parameter/main.sdstest @@ -1,31 +1,31 @@ package tests.scoping.annotationCalls.onParameter -// $TEST$ target before +# $TEST$ target before annotation »Before« fun myFunction( - // $TEST$ references before + # $TEST$ references before @»Before« - // $TEST$ references after + # $TEST$ references after @»After« - // $TEST$ unresolved + # $TEST$ unresolved @»NotAnAnnotation« - // $TEST$ unresolved + # $TEST$ unresolved @»Unresolved« myParameter: Int ) -pipeline myPipeline { +function myFunction () { val alias = Before; - // $TEST$ unresolved + # $TEST$ unresolved (@»alias« myParameter) {}; - // $TEST$ unresolved + # $TEST$ unresolved (@»alias« myParameter) -> 1; } -// $TEST$ target after +# $TEST$ target after annotation »After« class NotAnAnnotation diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on pipeline/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on pipeline/main.sdstest index c57cae47..1f3b3428 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on pipeline/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on pipeline/main.sdstest @@ -1,19 +1,19 @@ package tests.scoping.annotationCalls.onPipeline -// $TEST$ target before +# $TEST$ target before annotation »Before« -// $TEST$ references before +# $TEST$ references before @»Before« -// $TEST$ references after +# $TEST$ references after @»After« -// $TEST$ unresolved +# $TEST$ unresolved @»NotAnAnnotation« -// $TEST$ unresolved +# $TEST$ unresolved @»Unresolved« -pipeline myPipeline {} +function myFunction () {} -// $TEST$ target after +# $TEST$ target after annotation »After« class NotAnAnnotation diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on result/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on result/main.sdstest index c34ac239..9aa81f3d 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on result/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on result/main.sdstest @@ -1,21 +1,21 @@ package tests.scoping.annotationCalls.onResult -// $TEST$ target before +# $TEST$ target before annotation »Before« fun myFunction() -> ( - // $TEST$ references before + # $TEST$ references before @»Before« - // $TEST$ references after + # $TEST$ references after @»After« - // $TEST$ unresolved + # $TEST$ unresolved @»NotAnAnnotation« - // $TEST$ unresolved + # $TEST$ unresolved @»Unresolved« myResult: Int ) -// $TEST$ target after +# $TEST$ target after annotation »After« class NotAnAnnotation diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on segment/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on segment/main.sdstest index db7a052a..dc296e02 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on segment/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on segment/main.sdstest @@ -1,19 +1,19 @@ package tests.scoping.annotationCalls.onSegment -// $TEST$ target before +# $TEST$ target before annotation »Before« -// $TEST$ references before +# $TEST$ references before @»Before« -// $TEST$ references after +# $TEST$ references after @»After« -// $TEST$ unresolved +# $TEST$ unresolved @»NotAnAnnotation« -// $TEST$ unresolved +# $TEST$ unresolved @»Unresolved« segment mySegment() {} -// $TEST$ target after +# $TEST$ target after annotation »After« class NotAnAnnotation diff --git a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on type parameter/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on type parameter/main.sdstest index fe990af1..6080fcd4 100644 --- a/packages/ttsl-lang/tests/resources/scoping/annotation calls/on type parameter/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/annotation calls/on type parameter/main.sdstest @@ -1,21 +1,21 @@ package tests.scoping.annotationCalls.onTypeParameter -// $TEST$ target before +# $TEST$ target before annotation »Before« fun myFunction< - // $TEST$ references before + # $TEST$ references before @»Before« - // $TEST$ references after + # $TEST$ references after @»After« - // $TEST$ unresolved + # $TEST$ unresolved @»NotAnAnnotation« - // $TEST$ unresolved + # $TEST$ unresolved @»Unresolved« MyTypeParameter >() -// $TEST$ target after +# $TEST$ target after annotation »After« class NotAnAnnotation diff --git a/packages/ttsl-lang/tests/resources/scoping/arguments/of annotation calls/to parameter/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/arguments/of annotation calls/to parameter/main.sdstest index f718a1e6..7cd8cad1 100644 --- a/packages/ttsl-lang/tests/resources/scoping/arguments/of annotation calls/to parameter/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/arguments/of annotation calls/to parameter/main.sdstest @@ -1,20 +1,20 @@ package tests.scoping.arguments.ofAnnotationCalls.toParameter annotation MyAnnotation( - // $TEST$ target a + # $TEST$ target a »a«: Int, - // $TEST$ target b + # $TEST$ target b »b«: Int = 0, - // $TEST$ target c + # $TEST$ target c »c«: Int ) @MyAnnotation( - // $TEST$ references c + # $TEST$ references c »c« = 0, - // $TEST$ references a + # $TEST$ references a »a« = 0, - // $TEST$ references b + # $TEST$ references b »b« = 0 ) -pipeline myPipeline {} +function myFunction () {} diff --git a/packages/ttsl-lang/tests/resources/scoping/arguments/of annotation calls/to something other than parameter/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/arguments/of annotation calls/to something other than parameter/main.sdstest index a0edd6f0..6d8bea21 100644 --- a/packages/ttsl-lang/tests/resources/scoping/arguments/of annotation calls/to something other than parameter/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/arguments/of annotation calls/to something other than parameter/main.sdstest @@ -3,7 +3,7 @@ package tests.scoping.arguments.ofAnnotationCalls.toSomethingOtherThanParameter annotation MyAnnotation(a: Int) @MyAnnotation( - // $TEST$ unresolved + # $TEST$ unresolved »MyAnnotation« = 0, ) -pipeline myPipeline {} +function myFunction () {} diff --git a/packages/ttsl-lang/tests/resources/scoping/arguments/of annotation calls/unresolved/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/arguments/of annotation calls/unresolved/main.sdstest index d391846e..8eb95f47 100644 --- a/packages/ttsl-lang/tests/resources/scoping/arguments/of annotation calls/unresolved/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/arguments/of annotation calls/unresolved/main.sdstest @@ -3,11 +3,11 @@ package tests.scoping.arguments.ofAnnotationCalls.unresolved annotation MyAnnotation(a: Int) @MyAnnotation( - // $TEST$ unresolved + # $TEST$ unresolved »unresolved« = 0, ) @Unresolved( - // $TEST$ unresolved + # $TEST$ unresolved »a« = 0 ) -pipeline myPipeline {} +function myFunction () {} diff --git a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of annotation/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of annotation/main.sdstest index 97bfa9ed..48fb4652 100644 --- a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of annotation/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of annotation/main.sdstest @@ -1,31 +1,31 @@ package tests.scoping.arguments.ofCalls.toParameterOfAnnotation annotation MyAnnotation( - // $TEST$ target a + # $TEST$ target a »a«: Int, - // $TEST$ target b + # $TEST$ target b »b«: Int = 0, - // $TEST$ target c + # $TEST$ target c »c«: Int ) -pipeline myPipeline { +function myFunction () { MyAnnotation( - // $TEST$ references c + # $TEST$ references c »c« = 0, - // $TEST$ references a + # $TEST$ references a »a« = 0, - // $TEST$ references b + # $TEST$ references b »b« = 0 ); val alias = MyAnnotation; alias( - // $TEST$ references c + # $TEST$ references c »c« = 0, - // $TEST$ references a + # $TEST$ references a »a« = 0, - // $TEST$ references b + # $TEST$ references b »b« = 0 ); } diff --git a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of block lambda/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of block lambda/main.sdstest index 0d1c6bf4..41c0fddc 100644 --- a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of block lambda/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of block lambda/main.sdstest @@ -1,21 +1,21 @@ package tests.scoping.arguments.ofCalls.toParameterOfBlockLambda -pipeline myPipeline { +function myFunction () { val myBlockLambda = ( - // $TEST$ target a + # $TEST$ target a »a«: Int, - // $TEST$ target b + # $TEST$ target b »b«: Int = 0, - // $TEST$ target c + # $TEST$ target c »c«: Int ) {}; myBlockLambda( - // $TEST$ references c + # $TEST$ references c »c« = 0, - // $TEST$ references a + # $TEST$ references a »a« = 0, - // $TEST$ references b + # $TEST$ references b »b« = 0 ); } diff --git a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of callable type/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of callable type/main.sdstest index 68626933..8a9d16d6 100644 --- a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of callable type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of callable type/main.sdstest @@ -1,29 +1,29 @@ package tests.scoping.arguments.ofCalls.toParameterOfCallableType segment mySegment(myCallableType: ( - // $TEST$ target a + # $TEST$ target a »a«: Int, - // $TEST$ target b + # $TEST$ target b »b«: Int = 0, - // $TEST$ target c + # $TEST$ target c »c«: Int ) -> ()) { myCallableType( - // $TEST$ references c + # $TEST$ references c »c« = 0, - // $TEST$ references a + # $TEST$ references a »a« = 0, - // $TEST$ references b + # $TEST$ references b »b« = 0 ); val alias = myCallableType; alias( - // $TEST$ references c + # $TEST$ references c »c« = 0, - // $TEST$ references a + # $TEST$ references a »a« = 0, - // $TEST$ references b + # $TEST$ references b »b« = 0 ); } diff --git a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of class/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of class/main.sdstest index 179e0353..4128dd1b 100644 --- a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of class/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of class/main.sdstest @@ -1,31 +1,31 @@ package tests.scoping.arguments.ofCalls.toParameterOfClass class MyClass( - // $TEST$ target a + # $TEST$ target a »a«: Int, - // $TEST$ target b + # $TEST$ target b »b«: Int = 0, - // $TEST$ target c + # $TEST$ target c »c«: Int ) {} -pipeline myPipeline { +function myFunction () { MyClass( - // $TEST$ references c + # $TEST$ references c »c« = 0, - // $TEST$ references a + # $TEST$ references a »a« = 0, - // $TEST$ references b + # $TEST$ references b »b« = 0 ); val alias = MyClass; alias( - // $TEST$ references c + # $TEST$ references c »c« = 0, - // $TEST$ references a + # $TEST$ references a »a« = 0, - // $TEST$ references b + # $TEST$ references b »b« = 0 ); } diff --git a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of enum variant/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of enum variant/main.sdstest index bcc2d952..8d60ac65 100644 --- a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of enum variant/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of enum variant/main.sdstest @@ -2,33 +2,33 @@ package tests.scoping.arguments.ofCalls.toParameterOfEnumVariant enum MyEnum { MyEnumVariant( - // $TEST$ target a + # $TEST$ target a »a«: Int, - // $TEST$ target b + # $TEST$ target b »b«: Int = 0, - // $TEST$ target c + # $TEST$ target c »c«: Int ) } -pipeline myPipeline { +function myFunction () { MyEnum.MyEnumVariant( - // $TEST$ references c + # $TEST$ references c »c« = 0, - // $TEST$ references a + # $TEST$ references a »a« = 0, - // $TEST$ references b + # $TEST$ references b »b« = 0 ); val alias = MyEnum.MyEnumVariant; alias( - // $TEST$ references c + # $TEST$ references c »c« = 0, - // $TEST$ references a + # $TEST$ references a »a« = 0, - // $TEST$ references b + # $TEST$ references b »b« = 0 ); } diff --git a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of expression lambda/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of expression lambda/main.sdstest index 79ce806f..65e88221 100644 --- a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of expression lambda/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of expression lambda/main.sdstest @@ -1,21 +1,21 @@ package tests.scoping.arguments.ofCalls.toParameterOfExpressionLambda -pipeline myPipeline { +function myFunction () { val myExpressionLambda = ( - // $TEST$ target a + # $TEST$ target a »a«: Int, - // $TEST$ target b + # $TEST$ target b »b«: Int = 0, - // $TEST$ target c + # $TEST$ target c »c«: Int ) -> 1; myExpressionLambda( - // $TEST$ references c + # $TEST$ references c »c« = 0, - // $TEST$ references a + # $TEST$ references a »a« = 0, - // $TEST$ references b + # $TEST$ references b »b« = 0 ); } diff --git a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of function/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of function/main.sdstest index 73a81bc8..50d24be1 100644 --- a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of function/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of function/main.sdstest @@ -1,31 +1,31 @@ package tests.scoping.arguments.ofCalls.toParameterOfFunction fun myFunction( - // $TEST$ target a + # $TEST$ target a »a«: Int, - // $TEST$ target b + # $TEST$ target b »b«: Int = 0, - // $TEST$ target c + # $TEST$ target c »c«: Int ) -pipeline myPipeline { +function myFunction () { myFunction( - // $TEST$ references c + # $TEST$ references c »c« = 0, - // $TEST$ references a + # $TEST$ references a »a« = 0, - // $TEST$ references b + # $TEST$ references b »b« = 0 ); val alias = myFunction; alias( - // $TEST$ references c + # $TEST$ references c »c« = 0, - // $TEST$ references a + # $TEST$ references a »a« = 0, - // $TEST$ references b + # $TEST$ references b »b« = 0 ); } diff --git a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of segment/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of segment/main.sdstest index e4957c07..c59a99e3 100644 --- a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of segment/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to parameter of segment/main.sdstest @@ -1,31 +1,31 @@ package tests.scoping.arguments.ofCalls.toParameterOfSegment segment mySegment( - // $TEST$ target a + # $TEST$ target a »a«: Int, - // $TEST$ target b + # $TEST$ target b »b«: Int = 0, - // $TEST$ target c + # $TEST$ target c »c«: Int ) {} -pipeline myPipeline { +function myFunction () { mySegment( - // $TEST$ references c + # $TEST$ references c »c« = 0, - // $TEST$ references a + # $TEST$ references a »a« = 0, - // $TEST$ references b + # $TEST$ references b »b« = 0 ); val alias = mySegment; alias( - // $TEST$ references c + # $TEST$ references c »c« = 0, - // $TEST$ references a + # $TEST$ references a »a« = 0, - // $TEST$ references b + # $TEST$ references b »b« = 0 ); } diff --git a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to something other than parameter/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to something other than parameter/main.sdstest index 9df97d67..f869429c 100644 --- a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to something other than parameter/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/to something other than parameter/main.sdstest @@ -2,7 +2,7 @@ package tests.scoping.arguments.ofCalls.toSomethingOtherThanParameter fun f(a: Int) -pipeline myPipeline { - // $TEST$ unresolved +function myFunction () { + # $TEST$ unresolved f(»f« = 1); } diff --git a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/unresolved/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/unresolved/main.sdstest index 2c229246..b6506d89 100644 --- a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/unresolved/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/unresolved/main.sdstest @@ -2,10 +2,10 @@ package tests.scoping.arguments.ofCalls.unresolved fun f(a: Int) -pipeline myPipeline { - // $TEST$ unresolved +function myFunction () { + # $TEST$ unresolved f(»unresolved« = 1); - // $TEST$ unresolved + # $TEST$ unresolved unresolved(»a« = 1); } diff --git a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/with nullable receiver/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/with nullable receiver/main.sdstest index e3429f92..6f8cfe0f 100644 --- a/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/with nullable receiver/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/arguments/of calls/with nullable receiver/main.sdstest @@ -2,11 +2,11 @@ package tests.scoping.arguments.ofCalls.withNullableReceiver class MyClass { fun myFunction( - // $TEST$ target a + # $TEST$ target a »a«: Int, - // $TEST$ target b + # $TEST$ target b »b«: Int = 0, - // $TEST$ target c + # $TEST$ target c »c«: Int ) } @@ -15,20 +15,20 @@ segment mySegment( myClassOrNull: MyClass? ) { myClassOrNull?.myFunction( - // $TEST$ references c + # $TEST$ references c »c« = 0, - // $TEST$ references a + # $TEST$ references a »a« = 0, - // $TEST$ references b + # $TEST$ references b »b« = 0 ); myClassOrNull?.myFunction?( - // $TEST$ references c + # $TEST$ references c »c« = 0, - // $TEST$ references a + # $TEST$ references a »a« = 0, - // $TEST$ references b + # $TEST$ references b »b« = 0 ); } diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to annotations/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to annotations/main.sdstest index 27dee140..74253ce3 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to annotations/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to annotations/main.sdstest @@ -1,26 +1,26 @@ package tests.scoping.importedDeclarations.toAnnotations -// $TEST$ references own_OwnAnnotation +# $TEST$ references own_OwnAnnotation from tests.scoping.importedDeclarations.toAnnotations import »OwnAnnotation« -// $TEST$ references firstPackage_AnnotationInFirstPackage +# $TEST$ references firstPackage_AnnotationInFirstPackage from tests.scoping.importedDeclarations.toAnnotations.first import »AnnotationInFirstPackage« -// $TEST$ references secondPackage_AnnotationInSecondPackage +# $TEST$ references secondPackage_AnnotationInSecondPackage from tests.scoping.importedDeclarations.toAnnotations.second import »AnnotationInSecondPackage« -// $TEST$ references secondPackage_RedeclaredAnnotationInSameFile -// $TEST$ references secondPackage_RedeclaredAnnotationInOtherFile +# $TEST$ references secondPackage_RedeclaredAnnotationInSameFile +# $TEST$ references secondPackage_RedeclaredAnnotationInOtherFile from tests.scoping.importedDeclarations.toAnnotations.second import »RedeclaredAnnotationInSameFile«, »RedeclaredAnnotationInOtherFile« -// $TEST$ references secondPackage_AnnotationInBothPackages +# $TEST$ references secondPackage_AnnotationInBothPackages from tests.scoping.importedDeclarations.toAnnotations.second import »AnnotationInBothPackages« -// $TEST$ unresolved +# $TEST$ unresolved from tests.scoping.importedDeclarations.toAnnotations.second import »AnnotationInFirstPackage« -// $TEST$ target own_OwnAnnotation +# $TEST$ target own_OwnAnnotation annotation »OwnAnnotation« diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to annotations/resource first package.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to annotations/resource first package.sdstest index 822775f8..6e15db69 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to annotations/resource first package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to annotations/resource first package.sdstest @@ -1,7 +1,7 @@ package tests.scoping.importedDeclarations.toAnnotations.first -// $TEST$ target firstPackage_AnnotationInFirstPackage +# $TEST$ target firstPackage_AnnotationInFirstPackage annotation »AnnotationInFirstPackage« -// $TEST$ target firstPackage_AnnotationInBothPackages +# $TEST$ target firstPackage_AnnotationInBothPackages annotation »AnnotationInBothPackages« diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to annotations/resource second package.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to annotations/resource second package.sdstest index caaaed0f..ea410040 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to annotations/resource second package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to annotations/resource second package.sdstest @@ -1,14 +1,14 @@ package tests.scoping.importedDeclarations.toAnnotations.second -// $TEST$ target secondPackage_AnnotationInSecondPackage +# $TEST$ target secondPackage_AnnotationInSecondPackage annotation »AnnotationInSecondPackage« -// $TEST$ target secondPackage_RedeclaredAnnotationInSameFile +# $TEST$ target secondPackage_RedeclaredAnnotationInSameFile annotation »RedeclaredAnnotationInSameFile« annotation RedeclaredAnnotationInSameFile -// $TEST$ target secondPackage_RedeclaredAnnotationInOtherFile +# $TEST$ target secondPackage_RedeclaredAnnotationInOtherFile annotation »RedeclaredAnnotationInOtherFile« -// $TEST$ target secondPackage_AnnotationInBothPackages +# $TEST$ target secondPackage_AnnotationInBothPackages annotation »AnnotationInBothPackages« diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global classes/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global classes/main.sdstest index b3b7f341..88c480bc 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global classes/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global classes/main.sdstest @@ -1,26 +1,26 @@ package tests.scoping.importedDeclarations.toClasses -// $TEST$ references own_OwnClass +# $TEST$ references own_OwnClass from tests.scoping.importedDeclarations.toClasses import »OwnClass« -// $TEST$ references firstPackage_ClassInFirstPackage +# $TEST$ references firstPackage_ClassInFirstPackage from tests.scoping.importedDeclarations.toClasses.first import »ClassInFirstPackage« -// $TEST$ references secondPackage_ClassInSecondPackage +# $TEST$ references secondPackage_ClassInSecondPackage from tests.scoping.importedDeclarations.toClasses.second import »ClassInSecondPackage« -// $TEST$ references secondPackage_RedeclaredClassInSameFile -// $TEST$ references secondPackage_RedeclaredClassInOtherFile +# $TEST$ references secondPackage_RedeclaredClassInSameFile +# $TEST$ references secondPackage_RedeclaredClassInOtherFile from tests.scoping.importedDeclarations.toClasses.second import »RedeclaredClassInSameFile«, »RedeclaredClassInOtherFile« -// $TEST$ references secondPackage_ClassInBothPackages +# $TEST$ references secondPackage_ClassInBothPackages from tests.scoping.importedDeclarations.toClasses.second import »ClassInBothPackages« -// $TEST$ unresolved +# $TEST$ unresolved from tests.scoping.importedDeclarations.toClasses.second import »ClassInFirstPackage« -// $TEST$ target own_OwnClass +# $TEST$ target own_OwnClass class »OwnClass« diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global classes/resource first package.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global classes/resource first package.sdstest index 9a9ae936..f700aa6b 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global classes/resource first package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global classes/resource first package.sdstest @@ -1,7 +1,7 @@ package tests.scoping.importedDeclarations.toClasses.first -// $TEST$ target firstPackage_ClassInFirstPackage +# $TEST$ target firstPackage_ClassInFirstPackage class »ClassInFirstPackage« -// $TEST$ target firstPackage_ClassInBothPackages +# $TEST$ target firstPackage_ClassInBothPackages class »ClassInBothPackages« diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global classes/resource second package.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global classes/resource second package.sdstest index 654d717e..2ef76761 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global classes/resource second package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global classes/resource second package.sdstest @@ -1,14 +1,14 @@ package tests.scoping.importedDeclarations.toClasses.second -// $TEST$ target secondPackage_ClassInSecondPackage +# $TEST$ target secondPackage_ClassInSecondPackage class »ClassInSecondPackage« -// $TEST$ target secondPackage_RedeclaredClassInSameFile +# $TEST$ target secondPackage_RedeclaredClassInSameFile class »RedeclaredClassInSameFile« class RedeclaredClassInSameFile -// $TEST$ target secondPackage_RedeclaredClassInOtherFile +# $TEST$ target secondPackage_RedeclaredClassInOtherFile class »RedeclaredClassInOtherFile« -// $TEST$ target secondPackage_ClassInBothPackages +# $TEST$ target secondPackage_ClassInBothPackages class »ClassInBothPackages« diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global enums/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global enums/main.sdstest index 66594ba3..74d82c32 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global enums/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global enums/main.sdstest @@ -1,26 +1,26 @@ package tests.scoping.importedDeclarations.toEnums -// $TEST$ references own_OwnEnum +# $TEST$ references own_OwnEnum from tests.scoping.importedDeclarations.toEnums import »OwnEnum« -// $TEST$ references firstPackage_EnumInFirstPackage +# $TEST$ references firstPackage_EnumInFirstPackage from tests.scoping.importedDeclarations.toEnums.first import »EnumInFirstPackage« -// $TEST$ references secondPackage_EnumInSecondPackage +# $TEST$ references secondPackage_EnumInSecondPackage from tests.scoping.importedDeclarations.toEnums.second import »EnumInSecondPackage« -// $TEST$ references secondPackage_RedeclaredEnumInSameFile -// $TEST$ references secondPackage_RedeclaredEnumInOtherFile +# $TEST$ references secondPackage_RedeclaredEnumInSameFile +# $TEST$ references secondPackage_RedeclaredEnumInOtherFile from tests.scoping.importedDeclarations.toEnums.second import »RedeclaredEnumInSameFile«, »RedeclaredEnumInOtherFile« -// $TEST$ references secondPackage_EnumInBothPackages +# $TEST$ references secondPackage_EnumInBothPackages from tests.scoping.importedDeclarations.toEnums.second import »EnumInBothPackages« -// $TEST$ unresolved +# $TEST$ unresolved from tests.scoping.importedDeclarations.toEnums.second import »EnumInFirstPackage« -// $TEST$ target own_OwnEnum +# $TEST$ target own_OwnEnum enum »OwnEnum« diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global enums/resource first package.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global enums/resource first package.sdstest index a563a8f8..15094ae9 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global enums/resource first package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global enums/resource first package.sdstest @@ -1,7 +1,7 @@ package tests.scoping.importedDeclarations.toEnums.first -// $TEST$ target firstPackage_EnumInFirstPackage +# $TEST$ target firstPackage_EnumInFirstPackage enum »EnumInFirstPackage« -// $TEST$ target firstPackage_EnumInBothPackages +# $TEST$ target firstPackage_EnumInBothPackages enum »EnumInBothPackages« diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global enums/resource second package.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global enums/resource second package.sdstest index 670236f5..cc65e7ed 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global enums/resource second package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global enums/resource second package.sdstest @@ -1,14 +1,14 @@ package tests.scoping.importedDeclarations.toEnums.second -// $TEST$ target secondPackage_EnumInSecondPackage +# $TEST$ target secondPackage_EnumInSecondPackage enum »EnumInSecondPackage« -// $TEST$ target secondPackage_RedeclaredEnumInSameFile +# $TEST$ target secondPackage_RedeclaredEnumInSameFile enum »RedeclaredEnumInSameFile« enum RedeclaredEnumInSameFile -// $TEST$ target secondPackage_RedeclaredEnumInOtherFile +# $TEST$ target secondPackage_RedeclaredEnumInOtherFile enum »RedeclaredEnumInOtherFile« -// $TEST$ target secondPackage_EnumInBothPackages +# $TEST$ target secondPackage_EnumInBothPackages enum »EnumInBothPackages« diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global functions/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global functions/main.sdstest index 17f57d81..cc1a7bee 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global functions/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global functions/main.sdstest @@ -1,26 +1,26 @@ package tests.scoping.importedDeclarations.toFunctions -// $TEST$ references own_ownFunction +# $TEST$ references own_ownFunction from tests.scoping.importedDeclarations.toFunctions import »ownFunction« -// $TEST$ references firstPackage_functionInFirstPackage +# $TEST$ references firstPackage_functionInFirstPackage from tests.scoping.importedDeclarations.toFunctions.first import »functionInFirstPackage« -// $TEST$ references secondPackage_functionInSecondPackage +# $TEST$ references secondPackage_functionInSecondPackage from tests.scoping.importedDeclarations.toFunctions.second import »functionInSecondPackage« -// $TEST$ references secondPackage_redeclaredFunctionInSameFile -// $TEST$ references secondPackage_redeclaredFunctionInOtherFile +# $TEST$ references secondPackage_redeclaredFunctionInSameFile +# $TEST$ references secondPackage_redeclaredFunctionInOtherFile from tests.scoping.importedDeclarations.toFunctions.second import »redeclaredFunctionInSameFile«, »redeclaredFunctionInOtherFile« -// $TEST$ references secondPackage_functionInBothPackages +# $TEST$ references secondPackage_functionInBothPackages from tests.scoping.importedDeclarations.toFunctions.second import »functionInBothPackages« -// $TEST$ unresolved +# $TEST$ unresolved from tests.scoping.importedDeclarations.toFunctions.second import »functionInFirstPackage« -// $TEST$ target own_ownFunction +# $TEST$ target own_ownFunction fun »ownFunction«() diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global functions/resource first package.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global functions/resource first package.sdstest index 4fe65ce3..72fbec46 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global functions/resource first package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global functions/resource first package.sdstest @@ -1,7 +1,7 @@ package tests.scoping.importedDeclarations.toFunctions.first -// $TEST$ target firstPackage_functionInFirstPackage +# $TEST$ target firstPackage_functionInFirstPackage fun »functionInFirstPackage«() -// $TEST$ target firstPackage_functionInBothPackages +# $TEST$ target firstPackage_functionInBothPackages fun »functionInBothPackages«() diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global functions/resource second package.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global functions/resource second package.sdstest index 0b857158..dc61d0e2 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global functions/resource second package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to global functions/resource second package.sdstest @@ -1,14 +1,14 @@ package tests.scoping.importedDeclarations.toFunctions.second -// $TEST$ target secondPackage_functionInSecondPackage +# $TEST$ target secondPackage_functionInSecondPackage fun »functionInSecondPackage«() -// $TEST$ target secondPackage_redeclaredFunctionInSameFile +# $TEST$ target secondPackage_redeclaredFunctionInSameFile fun »redeclaredFunctionInSameFile«() fun redeclaredFunctionInSameFile() -// $TEST$ target secondPackage_redeclaredFunctionInOtherFile +# $TEST$ target secondPackage_redeclaredFunctionInOtherFile fun »redeclaredFunctionInOtherFile«() -// $TEST$ target secondPackage_functionInBothPackages +# $TEST$ target secondPackage_functionInBothPackages fun »functionInBothPackages«() diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to nested declaration/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to nested declaration/main.sdstest index e0216342..dee44e90 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to nested declaration/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to nested declaration/main.sdstest @@ -1,28 +1,28 @@ package tests.scoping.importedDeclarations.toNestedDeclaration -// $TEST$ unresolved +# $TEST$ unresolved from tests.scoping.importedDeclarations.toNestedDeclaration import »OwnClass« -// $TEST$ unresolved +# $TEST$ unresolved from tests.scoping.importedDeclarations.toNestedDeclaration.first import »ClassInFirstPackage« -// $TEST$ unresolved +# $TEST$ unresolved from tests.scoping.importedDeclarations.toNestedDeclaration.second import »ClassInSecondPackage« -// $TEST$ unresolved -// $TEST$ unresolved +# $TEST$ unresolved +# $TEST$ unresolved from tests.scoping.importedDeclarations.toNestedDeclaration.second import »RedeclaredClassInSameFile«, »RedeclaredClassInOtherFile« -// $TEST$ unresolved +# $TEST$ unresolved from tests.scoping.importedDeclarations.toNestedDeclaration.second import »ClassInBothPackages« -// $TEST$ unresolved +# $TEST$ unresolved from tests.scoping.importedDeclarations.toNestedDeclaration.second import »ClassInFirstPackage« class Outer { - // $TEST$ target own_OwnClass + # $TEST$ target own_OwnClass class »OwnClass« } diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to nested declaration/resource first package.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to nested declaration/resource first package.sdstest index 200bf7e8..295affac 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to nested declaration/resource first package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to nested declaration/resource first package.sdstest @@ -1,9 +1,9 @@ package tests.scoping.importedDeclarations.toNestedDeclaration.first class Outer { - // $TEST$ target firstPackage_ClassInFirstPackage + # $TEST$ target firstPackage_ClassInFirstPackage class »ClassInFirstPackage« - // $TEST$ target firstPackage_ClassInBothPackages + # $TEST$ target firstPackage_ClassInBothPackages class »ClassInBothPackages« } diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to nested declaration/resource second package.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to nested declaration/resource second package.sdstest index a2194dd8..6a341092 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to nested declaration/resource second package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to nested declaration/resource second package.sdstest @@ -1,16 +1,16 @@ package tests.scoping.importedDeclarations.toNestedDeclaration.second class Outer { - // $TEST$ target secondPackage_ClassInSecondPackage + # $TEST$ target secondPackage_ClassInSecondPackage class »ClassInSecondPackage« - // $TEST$ target secondPackage_RedeclaredClassInSameFile + # $TEST$ target secondPackage_RedeclaredClassInSameFile class »RedeclaredClassInSameFile« class RedeclaredClassInSameFile - // $TEST$ target secondPackage_RedeclaredClassInOtherFile + # $TEST$ target secondPackage_RedeclaredClassInOtherFile class »RedeclaredClassInOtherFile« - // $TEST$ target secondPackage_ClassInBothPackages + # $TEST$ target secondPackage_ClassInBothPackages class »ClassInBothPackages« } diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to pipelines/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to pipelines/main.sdstest index 0085c16d..3ecf4ead 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to pipelines/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to pipelines/main.sdstest @@ -1,26 +1,26 @@ package tests.scoping.importedDeclarations.toPipelines -// $TEST$ unresolved +# $TEST$ unresolved from tests.scoping.importedDeclarations.toPipelines import »ownPipeline« -// $TEST$ unresolved +# $TEST$ unresolved from tests.scoping.importedDeclarations.toPipelines.first import »pipelineInFirstPackage« -// $TEST$ unresolved +# $TEST$ unresolved from tests.scoping.importedDeclarations.toPipelines.second import »pipelineInSecondPackage« -// $TEST$ unresolved -// $TEST$ unresolved +# $TEST$ unresolved +# $TEST$ unresolved from tests.scoping.importedDeclarations.toPipelines.second import »redeclaredPipelineInSameFile«, »redeclaredPipelineInOtherFile« -// $TEST$ unresolved +# $TEST$ unresolved from tests.scoping.importedDeclarations.toPipelines.second import »pipelineInBothPackages« -// $TEST$ unresolved +# $TEST$ unresolved from tests.scoping.importedDeclarations.toPipelines.second import »pipelineInFirstPackage« -// $TEST$ target own_ownPipeline +# $TEST$ target own_ownPipeline pipeline »ownPipeline« {} diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to pipelines/resource first package.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to pipelines/resource first package.sdstest index 0606253c..b8be21f4 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to pipelines/resource first package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to pipelines/resource first package.sdstest @@ -1,7 +1,7 @@ package tests.scoping.importedDeclarations.toPipelines.first -// $TEST$ target firstPackage_pipelineInFirstPackage +# $TEST$ target firstPackage_pipelineInFirstPackage pipeline »pipelineInFirstPackage« {} -// $TEST$ target firstPackage_pipelineInBothPackages +# $TEST$ target firstPackage_pipelineInBothPackages pipeline »pipelineInBothPackages« {} diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to pipelines/resource second package.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to pipelines/resource second package.sdstest index 87a9d28b..7ab64fe1 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to pipelines/resource second package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to pipelines/resource second package.sdstest @@ -1,14 +1,14 @@ package tests.scoping.importedDeclarations.toPipelines.second -// $TEST$ target secondPackage_pipelineInSecondPackage +# $TEST$ target secondPackage_pipelineInSecondPackage pipeline »pipelineInSecondPackage« {} -// $TEST$ target secondPackage_redeclaredPipelineInSameFile +# $TEST$ target secondPackage_redeclaredPipelineInSameFile pipeline »redeclaredPipelineInSameFile« {} pipeline redeclaredPipelineInSameFile {} -// $TEST$ target secondPackage_redeclaredPipelineInOtherFile +# $TEST$ target secondPackage_redeclaredPipelineInOtherFile pipeline »redeclaredPipelineInOtherFile« {} -// $TEST$ target secondPackage_pipelineInBothPackages +# $TEST$ target secondPackage_pipelineInBothPackages pipeline »pipelineInBothPackages« {} diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to schemas/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to schemas/main.sdstest index 50e262a5..c84bcafb 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to schemas/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to schemas/main.sdstest @@ -1,25 +1,25 @@ package tests.scoping.importedDeclarations.toSchemas -// $TEST$ references own_OwnSchema +# $TEST$ references own_OwnSchema from tests.scoping.importedDeclarations.toSchemas import »OwnSchema« -// $TEST$ references firstPackage_SchemaInFirstPackage +# $TEST$ references firstPackage_SchemaInFirstPackage from tests.scoping.importedDeclarations.toSchemas.first import »SchemaInFirstPackage« -// $TEST$ references secondPackage_SchemaInSecondPackage +# $TEST$ references secondPackage_SchemaInSecondPackage from tests.scoping.importedDeclarations.toSchemas.second import »SchemaInSecondPackage« -// $TEST$ references secondPackage_RedeclaredSchemaInSameFile -// $TEST$ references secondPackage_RedeclaredSchemaInOtherFile +# $TEST$ references secondPackage_RedeclaredSchemaInSameFile +# $TEST$ references secondPackage_RedeclaredSchemaInOtherFile from tests.scoping.importedDeclarations.toSchemas.second import »RedeclaredSchemaInSameFile«, »RedeclaredSchemaInOtherFile« -// $TEST$ references secondPackage_SchemaInBothPackages +# $TEST$ references secondPackage_SchemaInBothPackages from tests.scoping.importedDeclarations.toSchemas.second import »SchemaInBothPackages« -// $TEST$ unresolved +# $TEST$ unresolved from tests.scoping.importedDeclarations.toSchemas.second import »SchemaInFirstPackage« -// $TEST$ target own_OwnSchema +# $TEST$ target own_OwnSchema schema »OwnSchema« {} diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to schemas/resource first package.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to schemas/resource first package.sdstest index 281edb62..6b1fd295 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to schemas/resource first package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to schemas/resource first package.sdstest @@ -1,7 +1,7 @@ package tests.scoping.importedDeclarations.toSchemas.first -// $TEST$ target firstPackage_SchemaInFirstPackage +# $TEST$ target firstPackage_SchemaInFirstPackage schema »SchemaInFirstPackage« {} -// $TEST$ target firstPackage_SchemaInBothPackages +# $TEST$ target firstPackage_SchemaInBothPackages schema »SchemaInBothPackages« {} diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to schemas/resource second package.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to schemas/resource second package.sdstest index 56f66891..e83803bf 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to schemas/resource second package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to schemas/resource second package.sdstest @@ -1,14 +1,14 @@ package tests.scoping.importedDeclarations.toSchemas.second -// $TEST$ target secondPackage_SchemaInSecondPackage +# $TEST$ target secondPackage_SchemaInSecondPackage schema »SchemaInSecondPackage« {} -// $TEST$ target secondPackage_RedeclaredSchemaInSameFile +# $TEST$ target secondPackage_RedeclaredSchemaInSameFile schema »RedeclaredSchemaInSameFile« {} schema RedeclaredSchemaInSameFile {} -// $TEST$ target secondPackage_RedeclaredSchemaInOtherFile +# $TEST$ target secondPackage_RedeclaredSchemaInOtherFile schema »RedeclaredSchemaInOtherFile« {} -// $TEST$ target secondPackage_SchemaInBothPackages +# $TEST$ target secondPackage_SchemaInBothPackages schema »SchemaInBothPackages« {} diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to segments/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to segments/main.sdstest index caff4fa1..af003613 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to segments/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to segments/main.sdstest @@ -1,42 +1,42 @@ package tests.scoping.importedDeclarations.toSegments -// $TEST$ references own_ownSegment +# $TEST$ references own_ownSegment from tests.scoping.importedDeclarations.toSegments import »ownSegment« -// $TEST$ references same_publicSegmentInSamePackage +# $TEST$ references same_publicSegmentInSamePackage from tests.scoping.importedDeclarations.toSegments import »publicSegmentInSamePackage« -// $TEST$ references same_internalSegmentInSamePackage +# $TEST$ references same_internalSegmentInSamePackage from tests.scoping.importedDeclarations.toSegments import »internalSegmentInSamePackage« -// $TEST$ unresolved +# $TEST$ unresolved from tests.scoping.importedDeclarations.toSegments import »privateSegmentInSamePackage« -// $TEST$ references firstPackage_segmentInFirstPackage +# $TEST$ references firstPackage_segmentInFirstPackage from tests.scoping.importedDeclarations.toSegments.first import »segmentInFirstPackage« -// $TEST$ references secondPackage_publicSegmentInSecondPackage +# $TEST$ references secondPackage_publicSegmentInSecondPackage from tests.scoping.importedDeclarations.toSegments.second import »publicSegmentInSecondPackage« -// $TEST$ unresolved +# $TEST$ unresolved from tests.scoping.importedDeclarations.toSegments.second import »internalSegmentInSecondPackage« -// $TEST$ unresolved +# $TEST$ unresolved from tests.scoping.importedDeclarations.toSegments.second import »privateSegmentInSecondPackage« -// $TEST$ references secondPackage_redeclaredSegmentInSameFile -// $TEST$ references secondPackage_redeclaredSegmentInOtherFile +# $TEST$ references secondPackage_redeclaredSegmentInSameFile +# $TEST$ references secondPackage_redeclaredSegmentInOtherFile from tests.scoping.importedDeclarations.toSegments.second import »redeclaredSegmentInSameFile«, »redeclaredSegmentInOtherFile« -// $TEST$ references secondPackage_segmentInBothPackages +# $TEST$ references secondPackage_segmentInBothPackages from tests.scoping.importedDeclarations.toSegments.second import »segmentInBothPackages« -// $TEST$ unresolved +# $TEST$ unresolved from tests.scoping.importedDeclarations.toSegments.second import »segmentInFirstPackage« -// $TEST$ target own_ownSegment +# $TEST$ target own_ownSegment segment »ownSegment«() {} diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to segments/resource first package.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to segments/resource first package.sdstest index 8ba7afa9..8afd310f 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to segments/resource first package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to segments/resource first package.sdstest @@ -1,7 +1,7 @@ package tests.scoping.importedDeclarations.toSegments.first -// $TEST$ target firstPackage_segmentInFirstPackage +# $TEST$ target firstPackage_segmentInFirstPackage segment »segmentInFirstPackage«() {} -// $TEST$ target firstPackage_segmentInBothPackages +# $TEST$ target firstPackage_segmentInBothPackages segment »segmentInBothPackages«() {} diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to segments/resource same package.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to segments/resource same package.sdstest index 682f954b..3a335555 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to segments/resource same package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to segments/resource same package.sdstest @@ -1,10 +1,10 @@ package tests.scoping.importedDeclarations.toSegments -// $TEST$ target same_publicSegmentInSamePackage +# $TEST$ target same_publicSegmentInSamePackage segment »publicSegmentInSamePackage«() {} -// $TEST$ target same_internalSegmentInSamePackage +# $TEST$ target same_internalSegmentInSamePackage internal segment »internalSegmentInSamePackage«() {} -// $TEST$ target same_privateSegmentInSamePackage +# $TEST$ target same_privateSegmentInSamePackage private segment »privateSegmentInSamePackage«() {} diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to segments/resource second package.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to segments/resource second package.sdstest index b3ee4279..73473ec7 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/to segments/resource second package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/to segments/resource second package.sdstest @@ -1,20 +1,20 @@ package tests.scoping.importedDeclarations.toSegments.second -// $TEST$ target secondPackage_publicSegmentInSecondPackage +# $TEST$ target secondPackage_publicSegmentInSecondPackage segment »publicSegmentInSecondPackage«() {} -// $TEST$ target secondPackage_internalSegmentInSecondPackage +# $TEST$ target secondPackage_internalSegmentInSecondPackage internal segment »internalSegmentInSecondPackage«() {} -// $TEST$ target secondPackage_privateSegmentInSecondPackage +# $TEST$ target secondPackage_privateSegmentInSecondPackage private segment »privateSegmentInSecondPackage«() {} -// $TEST$ target secondPackage_redeclaredSegmentInSameFile +# $TEST$ target secondPackage_redeclaredSegmentInSameFile segment »redeclaredSegmentInSameFile«() {} segment redeclaredSegmentInSameFile() {} -// $TEST$ target secondPackage_redeclaredSegmentInOtherFile +# $TEST$ target secondPackage_redeclaredSegmentInOtherFile segment »redeclaredSegmentInOtherFile«() {} -// $TEST$ target secondPackage_segmentInBothPackages +# $TEST$ target secondPackage_segmentInBothPackages segment »segmentInBothPackages«() {} diff --git a/packages/ttsl-lang/tests/resources/scoping/imported declarations/unresolved/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/imported declarations/unresolved/main.sdstest index f536308a..7c0095b4 100644 --- a/packages/ttsl-lang/tests/resources/scoping/imported declarations/unresolved/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/imported declarations/unresolved/main.sdstest @@ -1,4 +1,4 @@ package tests.scoping.importedDeclarations.unresolved -// $TEST$ unresolved +# $TEST$ unresolved from tests.scoping.importedDeclarations.toAnnotations import »unresolved« diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main no imports or own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main no imports or own declarations.sdstest index 7286b411..e2177026 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main no imports or own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main no imports or own declarations.sdstest @@ -1,18 +1,18 @@ package tests.scoping.namedTypes.acrossFiles.toGlobalClasses segment mySegment( - // $TEST$ references same_MyClass + # $TEST$ references same_MyClass p1: »MyClass«, - // $TEST$ references same_ClassInSamePackage + # $TEST$ references same_ClassInSamePackage p2: »ClassInSamePackage«, - // $TEST$ references TTSL_ClassInTTSLPackage + # $TEST$ references TTSL_ClassInTTSLPackage p3: »ClassInTTSLPackage«, - // $TEST$ unresolved + # $TEST$ unresolved p4: »ClassInAnotherPackage«, - // $TEST$ unresolved + # $TEST$ unresolved p5: »ClassWithoutPackage«, ) {} diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with imports and own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with imports and own declarations.sdstest index 3560c072..578463da 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with imports and own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with imports and own declarations.sdstest @@ -3,25 +3,25 @@ package tests.scoping.namedTypes.acrossFiles.toGlobalClasses from TTSL.scoping.namedTypes.acrossFiles.toGlobalClasses import MyClass as MyOwnClass from tests.scoping.namedTypes.acrossFiles.toGlobalClasses.other import ClassInAnotherPackage, Class2InAnotherPackage -// $TEST$ target own_MyOwnClass +# $TEST$ target own_MyOwnClass class »MyOwnClass« segment mySegment( - // $TEST$ references own_MyOwnClass + # $TEST$ references own_MyOwnClass p1: »MyOwnClass«, - // $TEST$ references same_ClassInSamePackage + # $TEST$ references same_ClassInSamePackage p2: »ClassInSamePackage«, - // $TEST$ references TTSL_ClassInTTSLPackage + # $TEST$ references TTSL_ClassInTTSLPackage p3: »ClassInTTSLPackage«, - // $TEST$ references other_ClassInAnotherPackage + # $TEST$ references other_ClassInAnotherPackage p4: »ClassInAnotherPackage«, - // $TEST$ references other_Class2InAnotherPackage + # $TEST$ references other_Class2InAnotherPackage p5: »Class2InAnotherPackage«, - // $TEST$ unresolved + # $TEST$ unresolved p6: »ClassWithoutPackage«, ) {} diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with multiple imports of same name.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with multiple imports of same name.sdstest index 84b50f4a..3ac7166b 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with multiple imports of same name.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with multiple imports of same name.sdstest @@ -5,6 +5,6 @@ from tests.scoping.namedTypes.acrossFiles.toGlobalClasses.other import MyClass from tests.scoping.namedTypes.acrossFiles.toGlobalClasses import MyClass segment mySegment( - // $TEST$ references TTSL_MyClass + # $TEST$ references TTSL_MyClass p: »MyClass«, ) {} diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with qualified import with alias.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with qualified import with alias.sdstest index 1e94f08c..7a9b8238 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with qualified import with alias.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with qualified import with alias.sdstest @@ -5,28 +5,28 @@ from TTSL.scoping.namedTypes.acrossFiles.toGlobalClasses import MyClass as MyCla from tests.scoping.namedTypes.acrossFiles.toGlobalClasses.other import MyClass as MyClassInAnotherPackage segment mySegment( - // $TEST$ references same_MyClass + # $TEST$ references same_MyClass p1: »MyClass«, - // $TEST$ references same_ClassInSamePackage + # $TEST$ references same_ClassInSamePackage p2: »ClassInSamePackage«, - // $TEST$ references TTSL_ClassInTTSLPackage + # $TEST$ references TTSL_ClassInTTSLPackage p3: »ClassInTTSLPackage«, - // $TEST$ unresolved + # $TEST$ unresolved p4: »ClassInAnotherPackage«, - // $TEST$ unresolved + # $TEST$ unresolved p5: »ClassWithoutPackage«, - // $TEST$ references same_MyClass + # $TEST$ references same_MyClass p6: »MyClassInSamePackage«, - // $TEST$ references TTSL_MyClass + # $TEST$ references TTSL_MyClass p7: »MyClassInTTSLPackage«, - // $TEST$ references other_MyClass + # $TEST$ references other_MyClass p8: »MyClassInAnotherPackage«, ) {} diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with qualified import.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with qualified import.sdstest index 195867e7..6af93d95 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with qualified import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with qualified import.sdstest @@ -4,24 +4,24 @@ from TTSL.scoping.namedTypes.acrossFiles.toGlobalClasses import MyClass from tests.scoping.namedTypes.acrossFiles.toGlobalClasses.other import ClassInAnotherPackage, Class2InAnotherPackage, notANamedTypeDeclaration segment mySegment( - // $TEST$ references TTSL_MyClass + # $TEST$ references TTSL_MyClass p1: »MyClass«, - // $TEST$ references same_ClassInSamePackage + # $TEST$ references same_ClassInSamePackage p2: »ClassInSamePackage«, - // $TEST$ references TTSL_ClassInTTSLPackage + # $TEST$ references TTSL_ClassInTTSLPackage p3: »ClassInTTSLPackage«, - // $TEST$ references other_ClassInAnotherPackage + # $TEST$ references other_ClassInAnotherPackage p4: »ClassInAnotherPackage«, - // $TEST$ references other_Class2InAnotherPackage + # $TEST$ references other_Class2InAnotherPackage p5: »Class2InAnotherPackage«, - // $TEST$ unresolved + # $TEST$ unresolved p6: »notANamedTypeDeclaration«, - // $TEST$ unresolved + # $TEST$ unresolved p7: »ClassWithoutPackage«, ) {} diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with wildcard import.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with wildcard import.sdstest index 0c5438d4..1c68b6c1 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with wildcard import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/main with wildcard import.sdstest @@ -3,18 +3,18 @@ package tests.scoping.namedTypes.acrossFiles.toGlobalClasses from TTSL.scoping.namedTypes.acrossFiles.toGlobalClasses import * segment mySegment( - // $TEST$ references TTSL_MyClass + # $TEST$ references TTSL_MyClass p1: »MyClass«, - // $TEST$ references same_ClassInSamePackage + # $TEST$ references same_ClassInSamePackage p2: »ClassInSamePackage«, - // $TEST$ references TTSL_ClassInTTSLPackage + # $TEST$ references TTSL_ClassInTTSLPackage p3: »ClassInTTSLPackage«, - // $TEST$ unresolved + # $TEST$ unresolved p4: »ClassInAnotherPackage«, - // $TEST$ unresolved + # $TEST$ unresolved p5: »ClassWithoutPackage«, ) {} diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/resource other package.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/resource other package.sdstest index 06528eef..ede278c9 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/resource other package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/resource other package.sdstest @@ -1,13 +1,13 @@ package tests.scoping.namedTypes.acrossFiles.toGlobalClasses.other -// $TEST$ target other_MyClass +# $TEST$ target other_MyClass class »MyClass« -// $TEST$ target other_ClassInAnotherPackage +# $TEST$ target other_ClassInAnotherPackage class »ClassInAnotherPackage« -// $TEST$ target other_Class2InAnotherPackage +# $TEST$ target other_Class2InAnotherPackage class »Class2InAnotherPackage« -// $TEST$ target other_notANamedTypeDeclaration +# $TEST$ target other_notANamedTypeDeclaration fun »notANamedTypeDeclaration«() diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/resource safeds package.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/resource safeds package.sdstest index 280f1346..819c3d95 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/resource safeds package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/resource safeds package.sdstest @@ -1,7 +1,7 @@ package TTSL.scoping.namedTypes.acrossFiles.toGlobalClasses -// $TEST$ target TTSL_MyClass +# $TEST$ target TTSL_MyClass class »MyClass« -// $TEST$ target TTSL_ClassInTTSLPackage +# $TEST$ target TTSL_ClassInTTSLPackage class »ClassInTTSLPackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/resource same package.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/resource same package.sdstest index 742ed65e..eeaf529c 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/resource same package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/resource same package.sdstest @@ -1,7 +1,7 @@ package tests.scoping.namedTypes.acrossFiles.toGlobalClasses -// $TEST$ target same_MyClass +# $TEST$ target same_MyClass class »MyClass« -// $TEST$ target same_ClassInSamePackage +# $TEST$ target same_ClassInSamePackage class »ClassInSamePackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/resource without package.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/resource without package.sdstest index bcd07435..82705a3b 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/resource without package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global classes/resource without package.sdstest @@ -1,5 +1,5 @@ -// $TEST$ target without_MyClass +# $TEST$ target without_MyClass class »MyClass« -// $TEST$ target without_ClassWithoutPackage +# $TEST$ target without_ClassWithoutPackage class »ClassWithoutPackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main no imports or own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main no imports or own declarations.sdstest index 6455e2ea..b4027b7a 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main no imports or own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main no imports or own declarations.sdstest @@ -1,18 +1,18 @@ package tests.scoping.namedTypes.acrossFiles.toGlobalEnums segment mySegment( - // $TEST$ references same_MyEnum + # $TEST$ references same_MyEnum p1: »MyEnum«, - // $TEST$ references same_EnumInSamePackage + # $TEST$ references same_EnumInSamePackage p2: »EnumInSamePackage«, - // $TEST$ references TTSL_EnumInTTSLPackage + # $TEST$ references TTSL_EnumInTTSLPackage p3: »EnumInTTSLPackage«, - // $TEST$ unresolved + # $TEST$ unresolved p4: »EnumInAnotherPackage«, - // $TEST$ unresolved + # $TEST$ unresolved p5: »EnumWithoutPackage«, ) {} diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with imports and own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with imports and own declarations.sdstest index 2c731e82..d26d3004 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with imports and own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with imports and own declarations.sdstest @@ -3,25 +3,25 @@ package tests.scoping.namedTypes.acrossFiles.toGlobalEnums from TTSL.scoping.namedTypes.acrossFiles.toGlobalEnums import MyEnum as MyOwnEnum from tests.scoping.namedTypes.acrossFiles.toGlobalEnums.other import EnumInAnotherPackage, Enum2InAnotherPackage -// $TEST$ target own_MyOwnEnum +# $TEST$ target own_MyOwnEnum enum »MyOwnEnum« segment mySegment( - // $TEST$ references own_MyOwnEnum + # $TEST$ references own_MyOwnEnum p1: »MyOwnEnum«, - // $TEST$ references same_EnumInSamePackage + # $TEST$ references same_EnumInSamePackage p2: »EnumInSamePackage«, - // $TEST$ references TTSL_EnumInTTSLPackage + # $TEST$ references TTSL_EnumInTTSLPackage p3: »EnumInTTSLPackage«, - // $TEST$ references other_EnumInAnotherPackage + # $TEST$ references other_EnumInAnotherPackage p4: »EnumInAnotherPackage«, - // $TEST$ references other_Enum2InAnotherPackage + # $TEST$ references other_Enum2InAnotherPackage p5: »Enum2InAnotherPackage«, - // $TEST$ unresolved + # $TEST$ unresolved p6: »EnumWithoutPackage«, ) {} diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with multiple imports of same name.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with multiple imports of same name.sdstest index b0e451ed..1c7f5e77 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with multiple imports of same name.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with multiple imports of same name.sdstest @@ -5,6 +5,6 @@ from tests.scoping.namedTypes.acrossFiles.toGlobalEnums.other import MyEnum from tests.scoping.namedTypes.acrossFiles.toGlobalEnums import MyEnum segment mySegment( - // $TEST$ references TTSL_MyEnum + # $TEST$ references TTSL_MyEnum p: »MyEnum«, ) {} diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with qualified import with alias.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with qualified import with alias.sdstest index 712f4925..85d531fc 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with qualified import with alias.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with qualified import with alias.sdstest @@ -5,29 +5,29 @@ from TTSL.scoping.namedTypes.acrossFiles.toGlobalEnums import MyEnum as MyEnumIn from tests.scoping.namedTypes.acrossFiles.toGlobalEnums.other import MyEnum as MyEnumInAnotherPackage segment mySegment( - // $TEST$ references same_MyEnum + # $TEST$ references same_MyEnum p1: »MyEnum«, - // $TEST$ references same_EnumInSamePackage + # $TEST$ references same_EnumInSamePackage p2: »EnumInSamePackage«, - // $TEST$ references TTSL_EnumInTTSLPackage + # $TEST$ references TTSL_EnumInTTSLPackage p3: »EnumInTTSLPackage«, - // $TEST$ unresolved + # $TEST$ unresolved p4: »EnumInAnotherPackage«, - // $TEST$ unresolved + # $TEST$ unresolved p5: »EnumWithoutPackage«, - // $TEST$ references same_MyEnum + # $TEST$ references same_MyEnum p6: »MyEnumInSamePackage«, - // $TEST$ references TTSL_MyEnum + # $TEST$ references TTSL_MyEnum p7: »MyEnumInTTSLPackage«, - // $TEST$ references other_MyEnum + # $TEST$ references other_MyEnum p8: »MyEnumInAnotherPackage«, ) {} diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with qualified import.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with qualified import.sdstest index c495cec5..ba4eeddd 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with qualified import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with qualified import.sdstest @@ -4,24 +4,24 @@ from TTSL.scoping.namedTypes.acrossFiles.toGlobalEnums import MyEnum from tests.scoping.namedTypes.acrossFiles.toGlobalEnums.other import EnumInAnotherPackage, Enum2InAnotherPackage, notANamedTypeDeclaration segment mySegment( - // $TEST$ references TTSL_MyEnum + # $TEST$ references TTSL_MyEnum p1: »MyEnum«, - // $TEST$ references same_EnumInSamePackage + # $TEST$ references same_EnumInSamePackage p2: »EnumInSamePackage«, - // $TEST$ references TTSL_EnumInTTSLPackage + # $TEST$ references TTSL_EnumInTTSLPackage p3: »EnumInTTSLPackage«, - // $TEST$ references other_EnumInAnotherPackage + # $TEST$ references other_EnumInAnotherPackage p4: »EnumInAnotherPackage«, - // $TEST$ references other_Enum2InAnotherPackage + # $TEST$ references other_Enum2InAnotherPackage p5: »Enum2InAnotherPackage«, - // $TEST$ unresolved + # $TEST$ unresolved p6: »notANamedTypeDeclaration«, - // $TEST$ unresolved + # $TEST$ unresolved p7: »EnumWithoutPackage«, ) {} diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with wildcard import.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with wildcard import.sdstest index 5bd4318b..d63ef141 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with wildcard import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/main with wildcard import.sdstest @@ -3,18 +3,18 @@ package tests.scoping.namedTypes.acrossFiles.toGlobalEnums from TTSL.scoping.namedTypes.acrossFiles.toGlobalEnums import * segment mySegment( - // $TEST$ references TTSL_MyEnum + # $TEST$ references TTSL_MyEnum p1: »MyEnum«, - // $TEST$ references same_EnumInSamePackage + # $TEST$ references same_EnumInSamePackage p2: »EnumInSamePackage«, - // $TEST$ references TTSL_EnumInTTSLPackage + # $TEST$ references TTSL_EnumInTTSLPackage p3: »EnumInTTSLPackage«, - // $TEST$ unresolved + # $TEST$ unresolved p4: »EnumInAnotherPackage«, - // $TEST$ unresolved + # $TEST$ unresolved p5: »EnumWithoutPackage«, ) {} diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/resource other package.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/resource other package.sdstest index d5c036c0..63d3323f 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/resource other package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/resource other package.sdstest @@ -1,13 +1,13 @@ package tests.scoping.namedTypes.acrossFiles.toGlobalEnums.other -// $TEST$ target other_MyEnum +# $TEST$ target other_MyEnum enum »MyEnum« -// $TEST$ target other_EnumInAnotherPackage +# $TEST$ target other_EnumInAnotherPackage enum »EnumInAnotherPackage« -// $TEST$ target other_Enum2InAnotherPackage +# $TEST$ target other_Enum2InAnotherPackage enum »Enum2InAnotherPackage« -// $TEST$ target other_notANamedTypeDeclaration +# $TEST$ target other_notANamedTypeDeclaration fun »notANamedTypeDeclaration«() diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/resource safeds package.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/resource safeds package.sdstest index 21047373..fca4eb95 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/resource safeds package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/resource safeds package.sdstest @@ -1,7 +1,7 @@ package TTSL.scoping.namedTypes.acrossFiles.toGlobalEnums -// $TEST$ target TTSL_MyEnum +# $TEST$ target TTSL_MyEnum enum »MyEnum« -// $TEST$ target TTSL_EnumInTTSLPackage +# $TEST$ target TTSL_EnumInTTSLPackage enum »EnumInTTSLPackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/resource same package.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/resource same package.sdstest index c5e7e0f0..952f0a87 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/resource same package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/resource same package.sdstest @@ -1,7 +1,7 @@ package tests.scoping.namedTypes.acrossFiles.toGlobalEnums -// $TEST$ target same_MyEnum +# $TEST$ target same_MyEnum enum »MyEnum« -// $TEST$ target same_EnumInSamePackage +# $TEST$ target same_EnumInSamePackage enum »EnumInSamePackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/resource without package.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/resource without package.sdstest index 7587c7e2..b0052f12 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/resource without package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/across files/to global enums/resource without package.sdstest @@ -1,5 +1,5 @@ -// $TEST$ target without_MyEnum +# $TEST$ target without_MyEnum enum »MyEnum« -// $TEST$ target without_EnumWithoutPackage +# $TEST$ target without_EnumWithoutPackage enum »EnumWithoutPackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to containing named type declarations/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to containing named type declarations/main.sdstest index 6f334dad..d9b0d992 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to containing named type declarations/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to containing named type declarations/main.sdstest @@ -1,89 +1,89 @@ package tests.scoping.namedTypes.inSameFile.toContainingNamedTypeDeclarations -// $TEST$ target outerClass +# $TEST$ target outerClass class »MyClass«< - // $TEST$ references outerClass + # $TEST$ references outerClass T sub »MyClass« >( - // $TEST$ references outerClass + # $TEST$ references outerClass p: »MyClass« -// $TEST$ references outerClass +# $TEST$ references outerClass ) sub »MyClass« { - // $TEST$ references outerClass + # $TEST$ references outerClass attr a1: »MyClass« - // $TEST$ unresolved + # $TEST$ unresolved attr a2: »MyEnum« fun f< - // $TEST$ references outerClass + # $TEST$ references outerClass T1 sub »MyClass«, - // $TEST$ unresolved + # $TEST$ unresolved T2 sub »MyEnum«, >( - // $TEST$ references outerClass + # $TEST$ references outerClass p1: »MyClass«, - // $TEST$ unresolved + # $TEST$ unresolved p2: »MyEnum« ) -> ( - // $TEST$ references outerClass + # $TEST$ references outerClass r1: »MyClass«, - // $TEST$ unresolved + # $TEST$ unresolved r2: »MyEnum« ) - // $TEST$ target enum + # $TEST$ target enum enum »MyEnum« { - // $TEST$ target variant + # $TEST$ target variant »MyEnumVariant«( - // $TEST$ references outerClass + # $TEST$ references outerClass p1: »MyClass«, - // $TEST$ references enum + # $TEST$ references enum p2: »MyEnum«, - // $TEST$ references variant + # $TEST$ references variant p3: »MyEnumVariant«, ) } - // $TEST$ target innerClass + # $TEST$ target innerClass class »MyClass«( - // $TEST$ references innerClass + # $TEST$ references innerClass p1: »MyClass«, - // $TEST$ unresolved + # $TEST$ unresolved p2: »MyEnum«, - // $TEST$ references innerClass - // $TEST$ unresolved + # $TEST$ references innerClass + # $TEST$ unresolved ) sub »MyClass«, »MyEnum« { - // $TEST$ references innerClass + # $TEST$ references innerClass attr a1: »MyClass« - // $TEST$ unresolved + # $TEST$ unresolved attr a2: »MyEnum« fun f< - // $TEST$ references innerClass + # $TEST$ references innerClass T1 sub »MyClass«, - // $TEST$ unresolved + # $TEST$ unresolved T2 sub »MyEnum«, >( - // $TEST$ references innerClass + # $TEST$ references innerClass p1: »MyClass«, - // $TEST$ unresolved + # $TEST$ unresolved p2: »MyEnum«, ) -> ( - // $TEST$ references innerClass + # $TEST$ references innerClass r1: »MyClass«, - // $TEST$ unresolved + # $TEST$ unresolved r2: »MyEnum«, ) } diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to enum variants in global enums/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to enum variants in global enums/main.sdstest index 47638259..257d200b 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to enum variants in global enums/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to enum variants in global enums/main.sdstest @@ -1,46 +1,46 @@ package tests.scoping.namedTypes.inSameFile.toEnumVariantInGlobalEnums enum BeforeEnum { - // $TEST$ target before + # $TEST$ target before »BeforeVariant« Variant1 - // $TEST$ unresolved + # $TEST$ unresolved Variant2(a: »Variant1«) } class BeforeVariant segment mySegment( - // $TEST$ references before + # $TEST$ references before p1: BeforeEnum.»BeforeVariant«, - // $TEST$ references after + # $TEST$ references after p2: AfterEnum.»AfterVariant«, - // $TEST$ unresolved + # $TEST$ unresolved p3: AfterEnum.»BeforeVariant«, - // $TEST$ unresolved + # $TEST$ unresolved p4: BeforeEnum.»AfterVariant«, - // $TEST$ unresolved + # $TEST$ unresolved p5: BeforeEnum.»Unresolved«, - // $TEST$ unresolved + # $TEST$ unresolved p6: AfterEnum.»Unresolved«, - // $TEST$ unresolved + # $TEST$ unresolved p7: Unresolved.»BeforeVariant«, - // $TEST$ unresolved + # $TEST$ unresolved p8: Unresolved.»AfterVariant«, ) {} class AfterVariant enum AfterEnum { - // $TEST$ target after + # $TEST$ target after »AfterVariant« } diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to enum variants in nested enums/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to enum variants in nested enums/main.sdstest index 26c1e68f..ab8ce73e 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to enum variants in nested enums/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to enum variants in nested enums/main.sdstest @@ -2,12 +2,12 @@ package tests.scoping.namedTypes.inSameFile.toEnumVariantsInNestedEnums class BeforeClass { enum BeforeEnum { - // $TEST$ target before + # $TEST$ target before »BeforeVariant« Variant1 - // $TEST$ unresolved + # $TEST$ unresolved Variant2(a: »Variant1«) } } @@ -17,28 +17,28 @@ enum BeforeEnum { } segment mySegment( - // $TEST$ references before + # $TEST$ references before p1: BeforeClass.BeforeEnum.»BeforeVariant«, - // $TEST$ references after + # $TEST$ references after p2: AfterClass.AfterEnum.»AfterVariant«, - // $TEST$ unresolved + # $TEST$ unresolved p3: AfterClass.AfterEnum.»BeforeVariant«, - // $TEST$ unresolved + # $TEST$ unresolved p4: BeforeClass.BeforeEnum.»AfterVariant«, - // $TEST$ unresolved + # $TEST$ unresolved p5: BeforeClass.BeforeEnum.»Unresolved«, - // $TEST$ unresolved + # $TEST$ unresolved p6: AfterClass.AfterEnum.»Unresolved«, - // $TEST$ unresolved + # $TEST$ unresolved p7: BeforeClass.Unresolved.»BeforeVariant«, - // $TEST$ unresolved + # $TEST$ unresolved p8: AfterClass.Unresolved.»AfterVariant«, ) {} @@ -48,7 +48,7 @@ enum AfterEnum { class AfterClass { enum AfterEnum { - // $TEST$ target after + # $TEST$ target after »AfterVariant« } } diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to global classes/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to global classes/main.sdstest index 412e4c4e..8e1be901 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to global classes/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to global classes/main.sdstest @@ -1,18 +1,18 @@ package tests.scoping.namedTypes.inSameFile.toGlobalClasses -// $TEST$ target before +# $TEST$ target before class »BeforeClass« segment mySegment( - // $TEST$ references before + # $TEST$ references before p1: »BeforeClass«, - // $TEST$ references after + # $TEST$ references after p2: »AfterClass«, - // $TEST$ unresolved + # $TEST$ unresolved p3: »Unresolved«, ) {} -// $TEST$ target after +# $TEST$ target after class »AfterClass« diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to global enums/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to global enums/main.sdstest index dfa877d5..5c15fd09 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to global enums/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to global enums/main.sdstest @@ -1,18 +1,18 @@ package tests.scoping.namedTypes.inSameFile.toGlobalEnums -// $TEST$ target before +# $TEST$ target before enum »BeforeEnum« segment mySegment( - // $TEST$ references before + # $TEST$ references before p1: »BeforeEnum«, - // $TEST$ references after + # $TEST$ references after p2: »AfterEnum«, - // $TEST$ unresolved + # $TEST$ unresolved p3: »Unresolved«, ) {} -// $TEST$ target after +# $TEST$ target after enum »AfterEnum« diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to nested classes/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to nested classes/main.sdstest index 5b92a43c..2a9927dc 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to nested classes/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to nested classes/main.sdstest @@ -1,32 +1,32 @@ package tests.scoping.namedTypes.inSameFile.toNestedClasses class BeforeOuterClass { - // $TEST$ target before + # $TEST$ target before class »BeforeInnerClass« } class BeforeInnerClass segment mySegment( - // $TEST$ references before + # $TEST$ references before p1: BeforeOuterClass.»BeforeInnerClass«, - // $TEST$ references after + # $TEST$ references after p2: AfterOuterClass.»AfterInnerClass«, - // $TEST$ unresolved + # $TEST$ unresolved p3: BeforeOuterClass.»AfterInnerClass«, - // $TEST$ unresolved + # $TEST$ unresolved p4: AfterOuterClass.»BeforeInnerClass«, - // $TEST$ unresolved + # $TEST$ unresolved p5: BeforeOuterClass.»Unresolved«, ) {} class AfterInnerClass class AfterOuterClass { - // $TEST$ target after + # $TEST$ target after class »AfterInnerClass« } diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to nested enums/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to nested enums/main.sdstest index a210c859..ba0e4244 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to nested enums/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to nested enums/main.sdstest @@ -1,32 +1,32 @@ package tests.scoping.namedTypes.inSameFile.toNestedEnums class BeforeClass { - // $TEST$ target before + # $TEST$ target before enum »BeforeEnum« } enum BeforeEnum segment mySegment( - // $TEST$ references before + # $TEST$ references before p1: BeforeClass.»BeforeEnum«, - // $TEST$ references after + # $TEST$ references after p2: AfterClass.»AfterEnum«, - // $TEST$ unresolved + # $TEST$ unresolved p3: BeforeClass.»AfterEnum«, - // $TEST$ unresolved + # $TEST$ unresolved p4: AfterClass.»BeforeEnum«, - // $TEST$ unresolved + # $TEST$ unresolved p5: BeforeClass.»Unresolved«, ) {} enum AfterEnum class AfterClass { - // $TEST$ target after + # $TEST$ target after enum »AfterEnum« } diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to something other than named type declarations/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to something other than named type declarations/main.sdstest index f94e1210..14ecdc30 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to something other than named type declarations/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to something other than named type declarations/main.sdstest @@ -1,6 +1,6 @@ package tests.scoping.namedTypes.inSameFile.toSomethingOtherThanNamedTypeDeclarations -// $TEST$ unresolved +# $TEST$ unresolved segment mySegment(p: »notANamedTypeDeclaration«) {} fun notANamedTypeDeclaration() diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in enum variants in nested enums/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in enum variants in nested enums/main.sdstest index 94290c0c..684ddf4a 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in enum variants in nested enums/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in enum variants in nested enums/main.sdstest @@ -1,21 +1,21 @@ package tests.scoping.namedTypes.inSameFile.toTypeParameter.inEnumVariantsInNestedEnums -// $TEST$ target container +# $TEST$ target container class MyClass<»Container«> { fun myFunction1() enum MyEnum { MyEnumVariant( - // $TEST$ references container + # $TEST$ references container a: »Container«, - // $TEST$ unresolved + # $TEST$ unresolved b: »BeforeEnum«, - // $TEST$ unresolved + # $TEST$ unresolved c: »AfterEnum«, - // $TEST$ unresolved + # $TEST$ unresolved d: »Unresolved«, ) } diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in global classes/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in global classes/main.sdstest index c4dfd05f..ff99c460 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in global classes/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in global classes/main.sdstest @@ -3,50 +3,50 @@ package tests.scoping.namedTypes.inSameFile.toTypeParameter.inGlobalClasses fun myFunction1() class MyClass< - // $TEST$ target own + # $TEST$ target own »Own«, - // $TEST$ references own + # $TEST$ references own T1 sub »Own«, - // $TEST$ unresolved + # $TEST$ unresolved T2 sub »Before«, - // $TEST$ unresolved + # $TEST$ unresolved T3 sub »After«, - // $TEST$ unresolved + # $TEST$ unresolved T4 sub »Unresolved«, - // $TEST$ unresolved + # $TEST$ unresolved T5 sub »Forward«, Forward, >( - // $TEST$ references own + # $TEST$ references own a: »Own«, - // $TEST$ unresolved + # $TEST$ unresolved b: »Before«, - // $TEST$ unresolved + # $TEST$ unresolved c: »After«, - // $TEST$ unresolved + # $TEST$ unresolved d: »Unresolved«, ) -// $TEST$ references own +# $TEST$ references own sub »Own« { - // $TEST$ references own + # $TEST$ references own attr z: »Own« - // $TEST$ unresolved + # $TEST$ unresolved attr y: »Before« - // $TEST$ unresolved + # $TEST$ unresolved attr x: »After« - // $TEST$ unresolved + # $TEST$ unresolved attr w: »Unresolved« } diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in global functions/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in global functions/main.sdstest index b53c3115..c2db8fd3 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in global functions/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in global functions/main.sdstest @@ -3,48 +3,48 @@ package tests.scoping.namedTypes.inSameFile.toTypeParameter.inGlobalFunctions fun myFunction1() fun myFunction2< - // $TEST$ target own + # $TEST$ target own »Own«, - // $TEST$ references own + # $TEST$ references own T1 sub »Own«, - // $TEST$ unresolved + # $TEST$ unresolved T2 sub »Before«, - // $TEST$ unresolved + # $TEST$ unresolved T3 sub »After«, - // $TEST$ unresolved + # $TEST$ unresolved T4 sub »Unresolved«, - // $TEST$ unresolved + # $TEST$ unresolved T5 sub »Forward«, Forward, >( - // $TEST$ references own + # $TEST$ references own a: »Own«, - // $TEST$ unresolved + # $TEST$ unresolved b: »Before«, - // $TEST$ unresolved + # $TEST$ unresolved c: »After«, - // $TEST$ unresolved + # $TEST$ unresolved d: »Unresolved« ) -> ( - // $TEST$ references own + # $TEST$ references own z: »Own«, - // $TEST$ unresolved + # $TEST$ unresolved y: »Before«, - // $TEST$ unresolved + # $TEST$ unresolved x: »After«, - // $TEST$ unresolved + # $TEST$ unresolved w: »Unresolved« ) diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in methods/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in methods/main.sdstest index 47d173c4..1f27c50c 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in methods/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in methods/main.sdstest @@ -2,92 +2,92 @@ package tests.scoping.namedTypes.inSameFile.toTypeParameter.inMethods fun myFunction1() -// $TEST$ target container +# $TEST$ target container class MyClass1<»Container«, Overridden> { fun myFunction2() fun myFunction3< - // $TEST$ target own + # $TEST$ target own »Own«, - // $TEST$ target overridden + # $TEST$ target overridden »Overridden«, - // $TEST$ references own + # $TEST$ references own T1 sub »Own«, - // $TEST$ references overridden + # $TEST$ references overridden T2 sub »Overridden«, - // $TEST$ references container + # $TEST$ references container T3 sub »Container«, - // $TEST$ unresolved + # $TEST$ unresolved T4 sub »BeforeMember«, - // $TEST$ unresolved + # $TEST$ unresolved T5 sub »AfterMember«, - // $TEST$ unresolved + # $TEST$ unresolved T6 sub »BeforeGlobal«, - // $TEST$ unresolved + # $TEST$ unresolved T7 sub »AfterGlobal«, - // $TEST$ unresolved + # $TEST$ unresolved T8 sub »Unresolved«, - // $TEST$ unresolved + # $TEST$ unresolved T9 sub »Forward«, Forward, >( - // $TEST$ references own + # $TEST$ references own a: »Own«, - // $TEST$ references overridden + # $TEST$ references overridden b: »Overridden«, - // $TEST$ references container + # $TEST$ references container c: »Container«, - // $TEST$ unresolved + # $TEST$ unresolved d: »BeforeMember«, - // $TEST$ unresolved + # $TEST$ unresolved e: »AfterMember«, - // $TEST$ unresolved + # $TEST$ unresolved g: »BeforeGlobal«, - // $TEST$ unresolved + # $TEST$ unresolved h: »AfterGlobal«, - // $TEST$ unresolved + # $TEST$ unresolved i: »Unresolved«, ) -> ( - // $TEST$ references own + # $TEST$ references own z: »Own«, - // $TEST$ references overridden + # $TEST$ references overridden y: »Overridden«, - // $TEST$ references container + # $TEST$ references container x: »Container«, - // $TEST$ unresolved + # $TEST$ unresolved w: »BeforeMember«, - // $TEST$ unresolved + # $TEST$ unresolved v: »AfterMember«, - // $TEST$ unresolved + # $TEST$ unresolved u: »BeforeGlobal«, - // $TEST$ unresolved + # $TEST$ unresolved t: »AfterGlobal«, - // $TEST$ unresolved + # $TEST$ unresolved s: »Unresolved«, ) diff --git a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in nested classes/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in nested classes/main.sdstest index 16e72565..7f766424 100644 --- a/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in nested classes/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/named types/in same file/to type parameters/in nested classes/main.sdstest @@ -2,97 +2,97 @@ package tests.scoping.namedTypes.inSameFile.toTypeParameter.inNestedClasses fun myFunction1() -// $TEST$ target container +# $TEST$ target container class MyClass1<»Container«, Overridden> { fun myFunction2() class MyClass2< - // $TEST$ target own + # $TEST$ target own »Own«, - // $TEST$ target overridden + # $TEST$ target overridden »Overridden«, - // $TEST$ references own + # $TEST$ references own T1 sub »Own«, - // $TEST$ references overridden + # $TEST$ references overridden T2 sub »Overridden«, - // $TEST$ references container + # $TEST$ references container T3 sub »Container«, - // $TEST$ unresolved + # $TEST$ unresolved T4 sub »BeforeMember«, - // $TEST$ unresolved + # $TEST$ unresolved T5 sub »AfterMember«, - // $TEST$ unresolved + # $TEST$ unresolved T6 sub »BeforeGlobal«, - // $TEST$ unresolved + # $TEST$ unresolved T7 sub »AfterGlobal«, - // $TEST$ unresolved + # $TEST$ unresolved T8 sub »Unresolved«, - // $TEST$ unresolved + # $TEST$ unresolved T9 sub »Forward«, Forward, >( - // $TEST$ references own + # $TEST$ references own a: »Own«, - // $TEST$ references overridden + # $TEST$ references overridden b: »Overridden«, - // $TEST$ references container + # $TEST$ references container c: »Container«, - // $TEST$ unresolved + # $TEST$ unresolved d: »BeforeMember«, - // $TEST$ unresolved + # $TEST$ unresolved e: »AfterMember«, - // $TEST$ unresolved + # $TEST$ unresolved f: »BeforeGlobal«, - // $TEST$ unresolved + # $TEST$ unresolved g: »AfterGlobal«, - // $TEST$ unresolved + # $TEST$ unresolved h: »Unresolved«, ) - // $TEST$ references own - // $TEST$ references overridden - // $TEST$ references container + # $TEST$ references own + # $TEST$ references overridden + # $TEST$ references container sub »Own«, »Overridden«, »Container« { - // $TEST$ references own + # $TEST$ references own attr z: »Own« - // $TEST$ references overridden + # $TEST$ references overridden attr y: »Overridden« - // $TEST$ references container + # $TEST$ references container attr x: »Container« - // $TEST$ unresolved + # $TEST$ unresolved attr w: »BeforeMember« - // $TEST$ unresolved + # $TEST$ unresolved attr v: »AfterMember« - // $TEST$ unresolved + # $TEST$ unresolved attr u: »BeforeGlobal« - // $TEST$ unresolved + # $TEST$ unresolved attr t: »AfterGlobal« - // $TEST$ unresolved + # $TEST$ unresolved attr s: »Unresolved« } diff --git a/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in annotation/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in annotation/main.sdstest index 314584ad..f92ce51b 100644 --- a/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in annotation/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in annotation/main.sdstest @@ -3,22 +3,22 @@ package tests.scoping.parameterBounds.inAnnotation fun myFunction1(before: Int) annotation MyAnnotation( - // $TEST$ target own + # $TEST$ target own »own«: Int ) where { - // $TEST$ references own + # $TEST$ references own »own« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »before« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »after« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »notAParameter« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »unresolved« < 0 } diff --git a/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in enum variant in nested enum/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in enum variant in nested enum/main.sdstest index 16e0811f..9225e907 100644 --- a/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in enum variant in nested enum/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in enum variant in nested enum/main.sdstest @@ -5,25 +5,25 @@ class MyClass(container: Int) { enum MyEnum { MyEnumVariant( - // $TEST$ target own + # $TEST$ target own »own«: Int ) where { - // $TEST$ references own + # $TEST$ references own »own« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »container« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »beforeEnum« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »afterEnum« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »notAParameter« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »unresolved« < 0 } } diff --git a/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in global class/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in global class/main.sdstest index e3ada215..2b4fea6f 100644 --- a/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in global class/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in global class/main.sdstest @@ -3,22 +3,22 @@ package tests.scoping.parameterBounds.inGlobalClass fun myFunction1(before: Int) class MyClass( - // $TEST$ target own + # $TEST$ target own »own«: Int ) where { - // $TEST$ references own + # $TEST$ references own »own« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »before« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »after« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »notAParameter« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »unresolved« < 0 } diff --git a/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in global function/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in global function/main.sdstest index 79641217..86b4434a 100644 --- a/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in global function/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in global function/main.sdstest @@ -3,22 +3,22 @@ package tests.scoping.parameterBounds.inGlobalFunction fun myFunction1(before: Int) fun myFunction2( - // $TEST$ target own + # $TEST$ target own »own«: Int ) where { - // $TEST$ references own + # $TEST$ references own »own« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »before« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »after« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »notAParameter« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »unresolved« < 0 } diff --git a/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in method/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in method/main.sdstest index 3ea3d3bc..77710ef3 100644 --- a/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in method/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in method/main.sdstest @@ -6,37 +6,37 @@ class MyClass1(container: Int, overridden: Int) { fun myFunction2(beforeMember: Int) fun myFunction3( - // $TEST$ target own + # $TEST$ target own »own«: Int, - // $TEST$ target overridden + # $TEST$ target overridden »overridden«: Int, ) where { - // $TEST$ references own + # $TEST$ references own »own« < 0, - // $TEST$ references overridden + # $TEST$ references overridden »overridden« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »container« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »beforeMember« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »afterMember« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »beforeGlobal« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »afterGlobal« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »notAParameter« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »unresolved« < 0 } diff --git a/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in nested class/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in nested class/main.sdstest index 1d4ec748..e9227c88 100644 --- a/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in nested class/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in nested class/main.sdstest @@ -6,37 +6,37 @@ class MyClass1(container: Int, overridden: Int){ fun myFunction2(beforeMember: Int) class MyClass2( - // $TEST$ target own + # $TEST$ target own »own«: Int, - // $TEST$ target overridden + # $TEST$ target overridden »overridden«: Int, ) where { - // $TEST$ references own + # $TEST$ references own »own« < 0, - // $TEST$ references overridden + # $TEST$ references overridden »overridden« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »container« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »beforeMember« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »afterMember« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »beforeGlobal« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »afterGlobal« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »notAParameter« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »unresolved« < 0 } diff --git a/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in segment/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in segment/main.sdstest index d426d269..c6344698 100644 --- a/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in segment/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/parameter bounds/in segment/main.sdstest @@ -3,22 +3,22 @@ package tests.scoping.parameterBounds.inSegment segment mySegment1(before: Int) {} segment mySegment2( - // $TEST$ target own + # $TEST$ target own »own«: Int ) where { - // $TEST$ references own + # $TEST$ references own »own« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »before« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »after« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »notAParameter« < 0, - // $TEST$ unresolved + # $TEST$ unresolved »unresolved« < 0 } {} diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main no imports or own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main no imports or own declarations.sdstest index f8f26d0f..42c4e2f2 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main no imports or own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main no imports or own declarations.sdstest @@ -1,18 +1,18 @@ package tests.scoping.references.acrossFiles.toAnnotations -pipeline myPipeline { - // $TEST$ references same_MyAnnotation +function myFunction () { + # $TEST$ references same_MyAnnotation »MyAnnotation«; - // $TEST$ references same_AnnotationInSamePackage + # $TEST$ references same_AnnotationInSamePackage »AnnotationInSamePackage«; - // $TEST$ references TTSL_AnnotationInTTSLPackage + # $TEST$ references TTSL_AnnotationInTTSLPackage »AnnotationInTTSLPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »AnnotationInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »AnnotationWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with imports and own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with imports and own declarations.sdstest index 6091c8f0..6c7769b5 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with imports and own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with imports and own declarations.sdstest @@ -3,25 +3,25 @@ package tests.scoping.references.acrossFiles.toAnnotations from TTSL.scoping.references.acrossFiles.toAnnotations import MyAnnotation as MyOwnAnnotation from tests.scoping.references.acrossFiles.toAnnotations.other import AnnotationInAnotherPackage, Annotation2InAnotherPackage -// $TEST$ target own_MyOwnAnnotation +# $TEST$ target own_MyOwnAnnotation annotation »MyOwnAnnotation« -pipeline myPipeline { - // $TEST$ references own_MyOwnAnnotation +function myFunction () { + # $TEST$ references own_MyOwnAnnotation »MyOwnAnnotation«; - // $TEST$ references same_AnnotationInSamePackage + # $TEST$ references same_AnnotationInSamePackage »AnnotationInSamePackage«; - // $TEST$ references TTSL_AnnotationInTTSLPackage + # $TEST$ references TTSL_AnnotationInTTSLPackage »AnnotationInTTSLPackage«; - // $TEST$ references other_AnnotationInAnotherPackage + # $TEST$ references other_AnnotationInAnotherPackage »AnnotationInAnotherPackage«; - // $TEST$ references other_Annotation2InAnotherPackage + # $TEST$ references other_Annotation2InAnotherPackage »Annotation2InAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »AnnotationWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with multiple imports of same name.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with multiple imports of same name.sdstest index 3de2cf61..9dcc56e9 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with multiple imports of same name.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with multiple imports of same name.sdstest @@ -4,7 +4,7 @@ from TTSL.scoping.references.acrossFiles.toAnnotations import MyAnnotation from tests.scoping.references.acrossFiles.toAnnotations.other import MyAnnotation from tests.scoping.references.acrossFiles.toAnnotations import MyAnnotation -pipeline myPipeline { - // $TEST$ references TTSL_MyAnnotation +function myFunction () { + # $TEST$ references TTSL_MyAnnotation »MyAnnotation«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with qualified import with alias.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with qualified import with alias.sdstest index f2f0fd46..fad49b95 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with qualified import with alias.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with qualified import with alias.sdstest @@ -4,29 +4,29 @@ from tests.scoping.references.acrossFiles.toAnnotations import MyAnnotation as M from TTSL.scoping.references.acrossFiles.toAnnotations import MyAnnotation as MyAnnotationInTTSLPackage from tests.scoping.references.acrossFiles.toAnnotations.other import MyAnnotation as MyAnnotationInAnotherPackage -pipeline myPipeline { - // $TEST$ references same_MyAnnotation +function myFunction () { + # $TEST$ references same_MyAnnotation »MyAnnotation«; - // $TEST$ references same_AnnotationInSamePackage + # $TEST$ references same_AnnotationInSamePackage »AnnotationInSamePackage«; - // $TEST$ references TTSL_AnnotationInTTSLPackage + # $TEST$ references TTSL_AnnotationInTTSLPackage »AnnotationInTTSLPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »AnnotationInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »AnnotationWithoutPackage«; - // $TEST$ references same_MyAnnotation + # $TEST$ references same_MyAnnotation »MyAnnotationInSamePackage«; - // $TEST$ references TTSL_MyAnnotation + # $TEST$ references TTSL_MyAnnotation »MyAnnotationInTTSLPackage«; - // $TEST$ references other_MyAnnotation + # $TEST$ references other_MyAnnotation »MyAnnotationInAnotherPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with qualified import.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with qualified import.sdstest index d0f802ae..14de3c0c 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with qualified import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with qualified import.sdstest @@ -3,22 +3,22 @@ package tests.scoping.references.acrossFiles.toAnnotations from TTSL.scoping.references.acrossFiles.toAnnotations import MyAnnotation from tests.scoping.references.acrossFiles.toAnnotations.other import AnnotationInAnotherPackage, Annotation2InAnotherPackage -pipeline myPipeline { - // $TEST$ references TTSL_MyAnnotation +function myFunction () { + # $TEST$ references TTSL_MyAnnotation »MyAnnotation«; - // $TEST$ references same_AnnotationInSamePackage + # $TEST$ references same_AnnotationInSamePackage »AnnotationInSamePackage«; - // $TEST$ references TTSL_AnnotationInTTSLPackage + # $TEST$ references TTSL_AnnotationInTTSLPackage »AnnotationInTTSLPackage«; - // $TEST$ references other_AnnotationInAnotherPackage + # $TEST$ references other_AnnotationInAnotherPackage »AnnotationInAnotherPackage«; - // $TEST$ references other_Annotation2InAnotherPackage + # $TEST$ references other_Annotation2InAnotherPackage »Annotation2InAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »AnnotationWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with wildcard import.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with wildcard import.sdstest index ee918cd6..3feb1337 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with wildcard import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/main with wildcard import.sdstest @@ -2,19 +2,19 @@ package tests.scoping.references.acrossFiles.toAnnotations from TTSL.scoping.references.acrossFiles.toAnnotations import * -pipeline myPipeline { - // $TEST$ references TTSL_MyAnnotation +function myFunction () { + # $TEST$ references TTSL_MyAnnotation »MyAnnotation«; - // $TEST$ references same_AnnotationInSamePackage + # $TEST$ references same_AnnotationInSamePackage »AnnotationInSamePackage«; - // $TEST$ references TTSL_AnnotationInTTSLPackage + # $TEST$ references TTSL_AnnotationInTTSLPackage »AnnotationInTTSLPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »AnnotationInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »AnnotationWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/resource other package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/resource other package.sdstest index 88ac9ad5..df6ccb25 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/resource other package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/resource other package.sdstest @@ -1,10 +1,10 @@ package tests.scoping.references.acrossFiles.toAnnotations.other -// $TEST$ target other_MyAnnotation +# $TEST$ target other_MyAnnotation annotation »MyAnnotation« -// $TEST$ target other_AnnotationInAnotherPackage +# $TEST$ target other_AnnotationInAnotherPackage annotation »AnnotationInAnotherPackage« -// $TEST$ target other_Annotation2InAnotherPackage +# $TEST$ target other_Annotation2InAnotherPackage annotation »Annotation2InAnotherPackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/resource safeds package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/resource safeds package.sdstest index ecd39de9..423802e0 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/resource safeds package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/resource safeds package.sdstest @@ -1,7 +1,7 @@ package TTSL.scoping.references.acrossFiles.toAnnotations -// $TEST$ target TTSL_MyAnnotation +# $TEST$ target TTSL_MyAnnotation annotation »MyAnnotation« -// $TEST$ target TTSL_AnnotationInTTSLPackage +# $TEST$ target TTSL_AnnotationInTTSLPackage annotation »AnnotationInTTSLPackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/resource same package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/resource same package.sdstest index 03f61011..14a44a20 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/resource same package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/resource same package.sdstest @@ -1,7 +1,7 @@ package tests.scoping.references.acrossFiles.toAnnotations -// $TEST$ target same_MyAnnotation +# $TEST$ target same_MyAnnotation annotation »MyAnnotation« -// $TEST$ target same_AnnotationInSamePackage +# $TEST$ target same_AnnotationInSamePackage annotation »AnnotationInSamePackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/resource without package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/resource without package.sdstest index 39a33d04..c4c3bc48 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/resource without package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to annotations/resource without package.sdstest @@ -1,5 +1,5 @@ -// $TEST$ target without_MyAnnotation +# $TEST$ target without_MyAnnotation annotation »MyAnnotation« -// $TEST$ target without_AnnotationWithoutPackage +# $TEST$ target without_AnnotationWithoutPackage annotation »AnnotationWithoutPackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main no imports or own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main no imports or own declarations.sdstest index 5821d49d..4f55799a 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main no imports or own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main no imports or own declarations.sdstest @@ -1,18 +1,18 @@ package tests.scoping.references.acrossFiles.toGlobalClasses -pipeline myPipeline { - // $TEST$ references same_MyClass +function myFunction () { + # $TEST$ references same_MyClass »MyClass«; - // $TEST$ references same_ClassInSamePackage + # $TEST$ references same_ClassInSamePackage »ClassInSamePackage«; - // $TEST$ references TTSL_ClassInTTSLPackage + # $TEST$ references TTSL_ClassInTTSLPackage »ClassInTTSLPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »ClassInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »ClassWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with imports and own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with imports and own declarations.sdstest index 69f7b082..4b86b45f 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with imports and own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with imports and own declarations.sdstest @@ -3,25 +3,25 @@ package tests.scoping.references.acrossFiles.toGlobalClasses from TTSL.scoping.references.acrossFiles.toGlobalClasses import MyClass as MyOwnClass from tests.scoping.references.acrossFiles.toGlobalClasses.other import ClassInAnotherPackage, Class2InAnotherPackage -// $TEST$ target own_MyOwnClass +# $TEST$ target own_MyOwnClass class »MyOwnClass« -pipeline myPipeline { - // $TEST$ references own_MyOwnClass +function myFunction () { + # $TEST$ references own_MyOwnClass »MyOwnClass«; - // $TEST$ references same_ClassInSamePackage + # $TEST$ references same_ClassInSamePackage »ClassInSamePackage«; - // $TEST$ references TTSL_ClassInTTSLPackage + # $TEST$ references TTSL_ClassInTTSLPackage »ClassInTTSLPackage«; - // $TEST$ references other_ClassInAnotherPackage + # $TEST$ references other_ClassInAnotherPackage »ClassInAnotherPackage«; - // $TEST$ references other_Class2InAnotherPackage + # $TEST$ references other_Class2InAnotherPackage »Class2InAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »ClassWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with multiple imports of same name.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with multiple imports of same name.sdstest index bae67381..c0c7403b 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with multiple imports of same name.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with multiple imports of same name.sdstest @@ -4,7 +4,7 @@ from TTSL.scoping.references.acrossFiles.toGlobalClasses import MyClass from tests.scoping.references.acrossFiles.toGlobalClasses.other import MyClass from tests.scoping.references.acrossFiles.toGlobalClasses import MyClass -pipeline myPipeline { - // $TEST$ references TTSL_MyClass +function myFunction () { + # $TEST$ references TTSL_MyClass »MyClass«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with qualified import with alias.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with qualified import with alias.sdstest index 8730fbab..e917f6e6 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with qualified import with alias.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with qualified import with alias.sdstest @@ -4,29 +4,29 @@ from tests.scoping.references.acrossFiles.toGlobalClasses import MyClass as MyCl from TTSL.scoping.references.acrossFiles.toGlobalClasses import MyClass as MyClassInTTSLPackage from tests.scoping.references.acrossFiles.toGlobalClasses.other import MyClass as MyClassInAnotherPackage -pipeline myPipeline { - // $TEST$ references same_MyClass +function myFunction () { + # $TEST$ references same_MyClass »MyClass«; - // $TEST$ references same_ClassInSamePackage + # $TEST$ references same_ClassInSamePackage »ClassInSamePackage«; - // $TEST$ references TTSL_ClassInTTSLPackage + # $TEST$ references TTSL_ClassInTTSLPackage »ClassInTTSLPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »ClassInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »ClassWithoutPackage«; - // $TEST$ references same_MyClass + # $TEST$ references same_MyClass »MyClassInSamePackage«; - // $TEST$ references TTSL_MyClass + # $TEST$ references TTSL_MyClass »MyClassInTTSLPackage«; - // $TEST$ references other_MyClass + # $TEST$ references other_MyClass »MyClassInAnotherPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with qualified import.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with qualified import.sdstest index af0bcb27..b4592f5b 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with qualified import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with qualified import.sdstest @@ -3,22 +3,22 @@ package tests.scoping.references.acrossFiles.toGlobalClasses from TTSL.scoping.references.acrossFiles.toGlobalClasses import MyClass from tests.scoping.references.acrossFiles.toGlobalClasses.other import ClassInAnotherPackage, Class2InAnotherPackage -pipeline myPipeline { - // $TEST$ references TTSL_MyClass +function myFunction () { + # $TEST$ references TTSL_MyClass »MyClass«; - // $TEST$ references same_ClassInSamePackage + # $TEST$ references same_ClassInSamePackage »ClassInSamePackage«; - // $TEST$ references TTSL_ClassInTTSLPackage + # $TEST$ references TTSL_ClassInTTSLPackage »ClassInTTSLPackage«; - // $TEST$ references other_ClassInAnotherPackage + # $TEST$ references other_ClassInAnotherPackage »ClassInAnotherPackage«; - // $TEST$ references other_Class2InAnotherPackage + # $TEST$ references other_Class2InAnotherPackage »Class2InAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »ClassWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with wildcard import.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with wildcard import.sdstest index 4553836f..feb54160 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with wildcard import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/main with wildcard import.sdstest @@ -2,19 +2,19 @@ package tests.scoping.references.acrossFiles.toGlobalClasses from TTSL.scoping.references.acrossFiles.toGlobalClasses import * -pipeline myPipeline { - // $TEST$ references TTSL_MyClass +function myFunction () { + # $TEST$ references TTSL_MyClass »MyClass«; - // $TEST$ references same_ClassInSamePackage + # $TEST$ references same_ClassInSamePackage »ClassInSamePackage«; - // $TEST$ references TTSL_ClassInTTSLPackage + # $TEST$ references TTSL_ClassInTTSLPackage »ClassInTTSLPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »ClassInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »ClassWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/resource other package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/resource other package.sdstest index 67c9b8be..92d67f2c 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/resource other package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/resource other package.sdstest @@ -1,10 +1,10 @@ package tests.scoping.references.acrossFiles.toGlobalClasses.other -// $TEST$ target other_MyClass +# $TEST$ target other_MyClass class »MyClass« -// $TEST$ target other_ClassInAnotherPackage +# $TEST$ target other_ClassInAnotherPackage class »ClassInAnotherPackage« -// $TEST$ target other_Class2InAnotherPackage +# $TEST$ target other_Class2InAnotherPackage class »Class2InAnotherPackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/resource safeds package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/resource safeds package.sdstest index a64b84e2..60913e09 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/resource safeds package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/resource safeds package.sdstest @@ -1,7 +1,7 @@ package TTSL.scoping.references.acrossFiles.toGlobalClasses -// $TEST$ target TTSL_MyClass +# $TEST$ target TTSL_MyClass class »MyClass« -// $TEST$ target TTSL_ClassInTTSLPackage +# $TEST$ target TTSL_ClassInTTSLPackage class »ClassInTTSLPackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/resource same package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/resource same package.sdstest index 5f358622..17f76130 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/resource same package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/resource same package.sdstest @@ -1,7 +1,7 @@ package tests.scoping.references.acrossFiles.toGlobalClasses -// $TEST$ target same_MyClass +# $TEST$ target same_MyClass class »MyClass« -// $TEST$ target same_ClassInSamePackage +# $TEST$ target same_ClassInSamePackage class »ClassInSamePackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/resource without package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/resource without package.sdstest index bcd07435..82705a3b 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/resource without package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global classes/resource without package.sdstest @@ -1,5 +1,5 @@ -// $TEST$ target without_MyClass +# $TEST$ target without_MyClass class »MyClass« -// $TEST$ target without_ClassWithoutPackage +# $TEST$ target without_ClassWithoutPackage class »ClassWithoutPackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main no imports or own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main no imports or own declarations.sdstest index 152119b8..9c8af5ca 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main no imports or own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main no imports or own declarations.sdstest @@ -1,18 +1,18 @@ package tests.scoping.references.acrossFiles.toGlobalEnums -pipeline myPipeline { - // $TEST$ references same_MyEnum +function myFunction () { + # $TEST$ references same_MyEnum »MyEnum«; - // $TEST$ references same_EnumInSamePackage + # $TEST$ references same_EnumInSamePackage »EnumInSamePackage«; - // $TEST$ references TTSL_EnumInTTSLPackage + # $TEST$ references TTSL_EnumInTTSLPackage »EnumInTTSLPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »EnumInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »EnumWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with imports and own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with imports and own declarations.sdstest index c19e5acf..1e60b6df 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with imports and own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with imports and own declarations.sdstest @@ -3,25 +3,25 @@ package tests.scoping.references.acrossFiles.toGlobalEnums from TTSL.scoping.references.acrossFiles.toGlobalEnums import MyEnum as MyOwnEnum from tests.scoping.references.acrossFiles.toGlobalEnums.other import EnumInAnotherPackage, Enum2InAnotherPackage -// $TEST$ target own_MyOwnEnum +# $TEST$ target own_MyOwnEnum enum »MyOwnEnum« -pipeline myPipeline { - // $TEST$ references own_MyOwnEnum +function myFunction () { + # $TEST$ references own_MyOwnEnum »MyOwnEnum«; - // $TEST$ references same_EnumInSamePackage + # $TEST$ references same_EnumInSamePackage »EnumInSamePackage«; - // $TEST$ references TTSL_EnumInTTSLPackage + # $TEST$ references TTSL_EnumInTTSLPackage »EnumInTTSLPackage«; - // $TEST$ references other_EnumInAnotherPackage + # $TEST$ references other_EnumInAnotherPackage »EnumInAnotherPackage«; - // $TEST$ references other_Enum2InAnotherPackage + # $TEST$ references other_Enum2InAnotherPackage »Enum2InAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »EnumWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with multiple imports of same name.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with multiple imports of same name.sdstest index c4d43613..6347b8c4 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with multiple imports of same name.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with multiple imports of same name.sdstest @@ -4,7 +4,7 @@ from TTSL.scoping.references.acrossFiles.toGlobalEnums import MyEnum from tests.scoping.references.acrossFiles.toGlobalEnums.other import MyEnum from tests.scoping.references.acrossFiles.toGlobalEnums import MyEnum -pipeline myPipeline { - // $TEST$ references TTSL_MyEnum +function myFunction () { + # $TEST$ references TTSL_MyEnum »MyEnum«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with qualified import with alias.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with qualified import with alias.sdstest index 8b206f37..014c8022 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with qualified import with alias.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with qualified import with alias.sdstest @@ -4,30 +4,30 @@ from tests.scoping.references.acrossFiles.toGlobalEnums import MyEnum as MyEnumI from TTSL.scoping.references.acrossFiles.toGlobalEnums import MyEnum as MyEnumInTTSLPackage from tests.scoping.references.acrossFiles.toGlobalEnums.other import MyEnum as MyEnumInAnotherPackage -pipeline myPipeline { - // $TEST$ references same_MyEnum +function myFunction () { + # $TEST$ references same_MyEnum »MyEnum«; - // $TEST$ references same_EnumInSamePackage + # $TEST$ references same_EnumInSamePackage »EnumInSamePackage«; - // $TEST$ references TTSL_EnumInTTSLPackage + # $TEST$ references TTSL_EnumInTTSLPackage »EnumInTTSLPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »EnumInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »EnumWithoutPackage«; - // $TEST$ references same_MyEnum + # $TEST$ references same_MyEnum »MyEnumInSamePackage«; - // $TEST$ references TTSL_MyEnum + # $TEST$ references TTSL_MyEnum »MyEnumInTTSLPackage«; - // $TEST$ references other_MyEnum + # $TEST$ references other_MyEnum »MyEnumInAnotherPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with qualified import.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with qualified import.sdstest index a45d1358..cc10592e 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with qualified import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with qualified import.sdstest @@ -3,22 +3,22 @@ package tests.scoping.references.acrossFiles.toGlobalEnums from TTSL.scoping.references.acrossFiles.toGlobalEnums import MyEnum from tests.scoping.references.acrossFiles.toGlobalEnums.other import EnumInAnotherPackage, Enum2InAnotherPackage -pipeline myPipeline { - // $TEST$ references TTSL_MyEnum +function myFunction () { + # $TEST$ references TTSL_MyEnum »MyEnum«; - // $TEST$ references same_EnumInSamePackage + # $TEST$ references same_EnumInSamePackage »EnumInSamePackage«; - // $TEST$ references TTSL_EnumInTTSLPackage + # $TEST$ references TTSL_EnumInTTSLPackage »EnumInTTSLPackage«; - // $TEST$ references other_EnumInAnotherPackage + # $TEST$ references other_EnumInAnotherPackage »EnumInAnotherPackage«; - // $TEST$ references other_Enum2InAnotherPackage + # $TEST$ references other_Enum2InAnotherPackage »Enum2InAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »EnumWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with wildcard import.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with wildcard import.sdstest index 17d4aeb0..5b3f1906 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with wildcard import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/main with wildcard import.sdstest @@ -2,19 +2,19 @@ package tests.scoping.references.acrossFiles.toGlobalEnums from TTSL.scoping.references.acrossFiles.toGlobalEnums import * -pipeline myPipeline { - // $TEST$ references TTSL_MyEnum +function myFunction () { + # $TEST$ references TTSL_MyEnum »MyEnum«; - // $TEST$ references same_EnumInSamePackage + # $TEST$ references same_EnumInSamePackage »EnumInSamePackage«; - // $TEST$ references TTSL_EnumInTTSLPackage + # $TEST$ references TTSL_EnumInTTSLPackage »EnumInTTSLPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »EnumInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »EnumWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/resource other package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/resource other package.sdstest index a561a587..5ac5748d 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/resource other package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/resource other package.sdstest @@ -1,10 +1,10 @@ package tests.scoping.references.acrossFiles.toGlobalEnums.other -// $TEST$ target other_MyEnum +# $TEST$ target other_MyEnum enum »MyEnum« -// $TEST$ target other_EnumInAnotherPackage +# $TEST$ target other_EnumInAnotherPackage enum »EnumInAnotherPackage« -// $TEST$ target other_Enum2InAnotherPackage +# $TEST$ target other_Enum2InAnotherPackage enum »Enum2InAnotherPackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/resource safeds package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/resource safeds package.sdstest index ddd39233..b7f1eaff 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/resource safeds package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/resource safeds package.sdstest @@ -1,7 +1,7 @@ package TTSL.scoping.references.acrossFiles.toGlobalEnums -// $TEST$ target TTSL_MyEnum +# $TEST$ target TTSL_MyEnum enum »MyEnum« -// $TEST$ target TTSL_EnumInTTSLPackage +# $TEST$ target TTSL_EnumInTTSLPackage enum »EnumInTTSLPackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/resource same package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/resource same package.sdstest index 43c20ebc..7710a15d 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/resource same package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/resource same package.sdstest @@ -1,7 +1,7 @@ package tests.scoping.references.acrossFiles.toGlobalEnums -// $TEST$ target same_MyEnum +# $TEST$ target same_MyEnum enum »MyEnum« -// $TEST$ target same_EnumInSamePackage +# $TEST$ target same_EnumInSamePackage enum »EnumInSamePackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/resource without package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/resource without package.sdstest index 7587c7e2..b0052f12 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/resource without package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global enums/resource without package.sdstest @@ -1,5 +1,5 @@ -// $TEST$ target without_MyEnum +# $TEST$ target without_MyEnum enum »MyEnum« -// $TEST$ target without_EnumWithoutPackage +# $TEST$ target without_EnumWithoutPackage enum »EnumWithoutPackage« diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main no imports or own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main no imports or own declarations.sdstest index 58248356..d3050690 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main no imports or own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main no imports or own declarations.sdstest @@ -1,18 +1,18 @@ package tests.scoping.references.acrossFiles.toGlobalFunctions -pipeline myPipeline { - // $TEST$ references same_myFunction +function myFunction () { + # $TEST$ references same_myFunction »myFunction«; - // $TEST$ references same_functionInSamePackage + # $TEST$ references same_functionInSamePackage »functionInSamePackage«; - // $TEST$ references TTSL_functionInTTSLPackage + # $TEST$ references TTSL_functionInTTSLPackage »functionInTTSLPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »functionInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »functionWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with imports and own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with imports and own declarations.sdstest index c8a4f070..e662f62b 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with imports and own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with imports and own declarations.sdstest @@ -3,25 +3,25 @@ package tests.scoping.references.acrossFiles.toGlobalFunctions from TTSL.scoping.references.acrossFiles.toGlobalFunctions import myFunction as myOwnFunction from tests.scoping.references.acrossFiles.toGlobalFunctions.other import functionInAnotherPackage, function2InAnotherPackage -// $TEST$ target own_myOwnFunction +# $TEST$ target own_myOwnFunction fun »myOwnFunction«() -pipeline myPipeline { - // $TEST$ references own_myOwnFunction +function myFunction () { + # $TEST$ references own_myOwnFunction »myOwnFunction«; - // $TEST$ references same_functionInSamePackage + # $TEST$ references same_functionInSamePackage »functionInSamePackage«; - // $TEST$ references TTSL_functionInTTSLPackage + # $TEST$ references TTSL_functionInTTSLPackage »functionInTTSLPackage«; - // $TEST$ references other_functionInAnotherPackage + # $TEST$ references other_functionInAnotherPackage »functionInAnotherPackage«; - // $TEST$ references other_function2InAnotherPackage + # $TEST$ references other_function2InAnotherPackage »function2InAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »functionWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with multiple imports of same name.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with multiple imports of same name.sdstest index d4b849a8..11a2f2f5 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with multiple imports of same name.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with multiple imports of same name.sdstest @@ -4,7 +4,7 @@ from TTSL.scoping.references.acrossFiles.toGlobalFunctions import myFunction from tests.scoping.references.acrossFiles.toGlobalFunctions.other import myFunction from tests.scoping.references.acrossFiles.toGlobalFunctions import myFunction -pipeline myPipeline { - // $TEST$ references TTSL_myFunction +function myFunction () { + # $TEST$ references TTSL_myFunction »myFunction«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with qualified import with alias.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with qualified import with alias.sdstest index 4d511506..aaa4bcd1 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with qualified import with alias.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with qualified import with alias.sdstest @@ -4,30 +4,30 @@ from tests.scoping.references.acrossFiles.toGlobalFunctions import myFunction as from TTSL.scoping.references.acrossFiles.toGlobalFunctions import myFunction as myFunctionInTTSLPackage from tests.scoping.references.acrossFiles.toGlobalFunctions.other import myFunction as myFunctionInAnotherPackage -pipeline myPipeline { - // $TEST$ references same_myFunction +function myFunction () { + # $TEST$ references same_myFunction »myFunction«; - // $TEST$ references same_functionInSamePackage + # $TEST$ references same_functionInSamePackage »functionInSamePackage«; - // $TEST$ references TTSL_functionInTTSLPackage + # $TEST$ references TTSL_functionInTTSLPackage »functionInTTSLPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »functionInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »functionWithoutPackage«; - // $TEST$ references same_myFunction + # $TEST$ references same_myFunction »myFunctionInSamePackage«; - // $TEST$ references TTSL_myFunction + # $TEST$ references TTSL_myFunction »myFunctionInTTSLPackage«; - // $TEST$ references other_myFunction + # $TEST$ references other_myFunction »myFunctionInAnotherPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with qualified import.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with qualified import.sdstest index 6f2b90c7..4652f4fa 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with qualified import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with qualified import.sdstest @@ -3,22 +3,22 @@ package tests.scoping.references.acrossFiles.toGlobalFunctions from TTSL.scoping.references.acrossFiles.toGlobalFunctions import myFunction from tests.scoping.references.acrossFiles.toGlobalFunctions.other import functionInAnotherPackage, function2InAnotherPackage -pipeline myPipeline { - // $TEST$ references TTSL_myFunction +function myFunction () { + # $TEST$ references TTSL_myFunction »myFunction«; - // $TEST$ references same_functionInSamePackage + # $TEST$ references same_functionInSamePackage »functionInSamePackage«; - // $TEST$ references TTSL_functionInTTSLPackage + # $TEST$ references TTSL_functionInTTSLPackage »functionInTTSLPackage«; - // $TEST$ references other_functionInAnotherPackage + # $TEST$ references other_functionInAnotherPackage »functionInAnotherPackage«; - // $TEST$ references other_function2InAnotherPackage + # $TEST$ references other_function2InAnotherPackage »function2InAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »functionWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with wildcard import.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with wildcard import.sdstest index 30c120dc..3d0a0de9 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with wildcard import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/main with wildcard import.sdstest @@ -2,19 +2,19 @@ package tests.scoping.references.acrossFiles.toGlobalFunctions from TTSL.scoping.references.acrossFiles.toGlobalFunctions import * -pipeline myPipeline { - // $TEST$ references TTSL_myFunction +function myFunction () { + # $TEST$ references TTSL_myFunction »myFunction«; - // $TEST$ references same_functionInSamePackage + # $TEST$ references same_functionInSamePackage »functionInSamePackage«; - // $TEST$ references TTSL_functionInTTSLPackage + # $TEST$ references TTSL_functionInTTSLPackage »functionInTTSLPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »functionInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »functionWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/resource other package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/resource other package.sdstest index 350069f5..7a774965 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/resource other package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/resource other package.sdstest @@ -1,10 +1,10 @@ package tests.scoping.references.acrossFiles.toGlobalFunctions.other -// $TEST$ target other_myFunction +# $TEST$ target other_myFunction fun »myFunction«() -// $TEST$ target other_functionInAnotherPackage +# $TEST$ target other_functionInAnotherPackage fun »functionInAnotherPackage«() -// $TEST$ target other_function2InAnotherPackage +# $TEST$ target other_function2InAnotherPackage fun »function2InAnotherPackage«() diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/resource safeds package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/resource safeds package.sdstest index bf222062..94afbdd6 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/resource safeds package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/resource safeds package.sdstest @@ -1,7 +1,7 @@ package TTSL.scoping.references.acrossFiles.toGlobalFunctions -// $TEST$ target TTSL_myFunction +# $TEST$ target TTSL_myFunction fun »myFunction«() -// $TEST$ target TTSL_functionInTTSLPackage +# $TEST$ target TTSL_functionInTTSLPackage fun »functionInTTSLPackage«() diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/resource same package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/resource same package.sdstest index 969c2847..eec5e663 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/resource same package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/resource same package.sdstest @@ -1,7 +1,7 @@ package tests.scoping.references.acrossFiles.toGlobalFunctions -// $TEST$ target same_myFunction +# $TEST$ target same_myFunction fun »myFunction«() -// $TEST$ target same_functionInSamePackage +# $TEST$ target same_functionInSamePackage fun »functionInSamePackage«() diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/resource without package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/resource without package.sdstest index fc524811..bbead6af 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/resource without package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to global functions/resource without package.sdstest @@ -1,5 +1,5 @@ -// $TEST$ target without_myFunction +# $TEST$ target without_myFunction fun »myFunction«() -// $TEST$ target without_functionWithoutPackage +# $TEST$ target without_functionWithoutPackage fun »functionWithoutPackage«() diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main no imports or own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main no imports or own declarations.sdstest index 465810e5..994a17e2 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main no imports or own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main no imports or own declarations.sdstest @@ -1,18 +1,18 @@ package tests.scoping.references.acrossFiles.toPipelines segment mySegment() { - // $TEST$ unresolved + # $TEST$ unresolved »myPipeline«; - // $TEST$ unresolved + # $TEST$ unresolved »pipelineInSamePackage«; - // $TEST$ unresolved + # $TEST$ unresolved »pipelineInTTSLPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »pipelineInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »pipelineWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with imports and own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with imports and own declarations.sdstest index 9fe0f1b4..e5701dcc 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with imports and own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with imports and own declarations.sdstest @@ -3,25 +3,25 @@ package tests.scoping.references.acrossFiles.toPipelines from TTSL.scoping.references.acrossFiles.toPipelines import myPipeline as myOwnPipeline from tests.scoping.references.acrossFiles.toPipelines.other import pipelineInAnotherPackage, pipeline2InAnotherPackage -// $TEST$ target own_myOwnPipeline +# $TEST$ target own_myOwnPipeline pipeline »myOwnPipeline« {} segment mySegment() { - // $TEST$ references own_myOwnPipeline + # $TEST$ references own_myOwnPipeline »myOwnPipeline«; - // $TEST$ unresolved + # $TEST$ unresolved »pipelineInSamePackage«; - // $TEST$ unresolved + # $TEST$ unresolved »pipelineInTTSLPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »pipelineInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »pipeline2InAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »pipelineWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with multiple imports of same name.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with multiple imports of same name.sdstest index b9bd8012..17ac78c0 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with multiple imports of same name.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with multiple imports of same name.sdstest @@ -5,6 +5,6 @@ from tests.scoping.references.acrossFiles.toPipelines.other import myPipeline from tests.scoping.references.acrossFiles.toPipelines import myPipeline segment mySegment() { - // $TEST$ unresolved + # $TEST$ unresolved »myPipeline«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with qualified import with alias.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with qualified import with alias.sdstest index ef5098d0..2a3180ff 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with qualified import with alias.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with qualified import with alias.sdstest @@ -5,29 +5,29 @@ from TTSL.scoping.references.acrossFiles.toPipelines import myPipeline as myPipe from tests.scoping.references.acrossFiles.toPipelines.other import myPipeline as myPipelineInAnotherPackage segment mySegment() { - // $TEST$ unresolved + # $TEST$ unresolved »myPipeline«; - // $TEST$ unresolved + # $TEST$ unresolved »pipelineInSamePackage«; - // $TEST$ unresolved + # $TEST$ unresolved »pipelineInTTSLPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »pipelineInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »pipelineWithoutPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »myPipelineInSamePackage«; - // $TEST$ unresolved + # $TEST$ unresolved »myPipelineInTTSLPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »myPipelineInAnotherPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with qualified import.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with qualified import.sdstest index f3222394..2c6dff8a 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with qualified import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with qualified import.sdstest @@ -4,21 +4,21 @@ from TTSL.scoping.references.acrossFiles.toPipelines import myPipeline from tests.scoping.references.acrossFiles.toPipelines.other import pipelineInAnotherPackage, pipeline2InAnotherPackage segment mySegment() { - // $TEST$ unresolved + # $TEST$ unresolved »myPipeline«; - // $TEST$ unresolved + # $TEST$ unresolved »pipelineInSamePackage«; - // $TEST$ unresolved + # $TEST$ unresolved »pipelineInTTSLPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »pipelineInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »pipeline2InAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »pipelineWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with wildcard import.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with wildcard import.sdstest index d9ca2ec2..14adea57 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with wildcard import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/main with wildcard import.sdstest @@ -3,18 +3,18 @@ package tests.scoping.references.acrossFiles.toPipelines from TTSL.scoping.references.acrossFiles.toPipelines import * segment mySegment() { - // $TEST$ unresolved + # $TEST$ unresolved »myPipeline«; - // $TEST$ unresolved + # $TEST$ unresolved »pipelineInSamePackage«; - // $TEST$ unresolved + # $TEST$ unresolved »pipelineInTTSLPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »pipelineInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »pipelineWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/resource other package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/resource other package.sdstest index 3adecca8..76010a15 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/resource other package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/resource other package.sdstest @@ -1,10 +1,10 @@ package tests.scoping.references.acrossFiles.toPipelines.other -// $TEST$ target other_myPipeline +# $TEST$ target other_myPipeline pipeline »myPipeline« {} -// $TEST$ target other_pipelineInAnotherPackage +# $TEST$ target other_pipelineInAnotherPackage pipeline »pipelineInAnotherPackage« {} -// $TEST$ target other_pipeline2InAnotherPackage +# $TEST$ target other_pipeline2InAnotherPackage pipeline »pipeline2InAnotherPackage« {} diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/resource safeds package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/resource safeds package.sdstest index 757effe7..39f6ef9e 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/resource safeds package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/resource safeds package.sdstest @@ -1,7 +1,7 @@ package TTSL.scoping.references.acrossFiles.toPipelines -// $TEST$ target TTSL_myPipeline +# $TEST$ target TTSL_myPipeline pipeline »myPipeline« {} -// $TEST$ target TTSL_pipelineInTTSLPackage +# $TEST$ target TTSL_pipelineInTTSLPackage pipeline »pipelineInTTSLPackage« {} diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/resource same package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/resource same package.sdstest index 34cec8ca..5bf4de88 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/resource same package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/resource same package.sdstest @@ -1,7 +1,7 @@ package tests.scoping.references.acrossFiles.toPipelines -// $TEST$ target same_myPipeline +# $TEST$ target same_myPipeline pipeline »myPipeline« {} -// $TEST$ target same_pipelineInSamePackage +# $TEST$ target same_pipelineInSamePackage pipeline »pipelineInSamePackage« {} diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/resource without package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/resource without package.sdstest index da94d86f..45977c18 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/resource without package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to pipelines/resource without package.sdstest @@ -1,5 +1,5 @@ -// $TEST$ target without_myPipeline +# $TEST$ target without_myPipeline pipeline »myPipeline« {} -// $TEST$ target without_pipelineWithoutPackage +# $TEST$ target without_pipelineWithoutPackage pipeline »pipelineWithoutPackage« {} diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main no imports or own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main no imports or own declarations.sdstest index d960668d..b32e1140 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main no imports or own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main no imports or own declarations.sdstest @@ -1,18 +1,18 @@ package tests.scoping.references.acrossFiles.toSchemas -pipeline myPipeline { - // $TEST$ references same_MySchema +function myFunction () { + # $TEST$ references same_MySchema »MySchema«; - // $TEST$ references same_SchemaInSamePackage + # $TEST$ references same_SchemaInSamePackage »SchemaInSamePackage«; - // $TEST$ references TTSL_SchemaInTTSLPackage + # $TEST$ references TTSL_SchemaInTTSLPackage »SchemaInTTSLPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »SchemaInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »SchemaWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with imports and own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with imports and own declarations.sdstest index 3e2f7d09..9ef646ac 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with imports and own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with imports and own declarations.sdstest @@ -3,25 +3,25 @@ package tests.scoping.references.acrossFiles.toSchemas from TTSL.scoping.references.acrossFiles.toSchemas import MySchema as MyOwnSchema from tests.scoping.references.acrossFiles.toSchemas.other import SchemaInAnotherPackage, Schema2InAnotherPackage -// $TEST$ target own_MyOwnSchema +# $TEST$ target own_MyOwnSchema schema »MyOwnSchema« {} -pipeline myPipeline { - // $TEST$ references own_MyOwnSchema +function myFunction () { + # $TEST$ references own_MyOwnSchema »MyOwnSchema«; - // $TEST$ references same_SchemaInSamePackage + # $TEST$ references same_SchemaInSamePackage »SchemaInSamePackage«; - // $TEST$ references TTSL_SchemaInTTSLPackage + # $TEST$ references TTSL_SchemaInTTSLPackage »SchemaInTTSLPackage«; - // $TEST$ references other_SchemaInAnotherPackage + # $TEST$ references other_SchemaInAnotherPackage »SchemaInAnotherPackage«; - // $TEST$ references other_Schema2InAnotherPackage + # $TEST$ references other_Schema2InAnotherPackage »Schema2InAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »SchemaWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with multiple imports of same name.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with multiple imports of same name.sdstest index acd69095..423e0d49 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with multiple imports of same name.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with multiple imports of same name.sdstest @@ -4,7 +4,7 @@ from TTSL.scoping.references.acrossFiles.toSchemas import MySchema from tests.scoping.references.acrossFiles.toSchemas.other import MySchema from tests.scoping.references.acrossFiles.toSchemas import MySchema -pipeline myPipeline { - // $TEST$ references TTSL_MySchema +function myFunction () { + # $TEST$ references TTSL_MySchema »MySchema«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with qualified import with alias.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with qualified import with alias.sdstest index 6cbd4b4f..337d0dd4 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with qualified import with alias.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with qualified import with alias.sdstest @@ -4,30 +4,30 @@ from tests.scoping.references.acrossFiles.toSchemas import MySchema as MySchemaI from TTSL.scoping.references.acrossFiles.toSchemas import MySchema as MySchemaInTTSLPackage from tests.scoping.references.acrossFiles.toSchemas.other import MySchema as MySchemaInAnotherPackage -pipeline myPipeline { - // $TEST$ references same_MySchema +function myFunction () { + # $TEST$ references same_MySchema »MySchema«; - // $TEST$ references same_SchemaInSamePackage + # $TEST$ references same_SchemaInSamePackage »SchemaInSamePackage«; - // $TEST$ references TTSL_SchemaInTTSLPackage + # $TEST$ references TTSL_SchemaInTTSLPackage »SchemaInTTSLPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »SchemaInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »SchemaWithoutPackage«; - // $TEST$ references same_MySchema + # $TEST$ references same_MySchema »MySchemaInSamePackage«; - // $TEST$ references TTSL_MySchema + # $TEST$ references TTSL_MySchema »MySchemaInTTSLPackage«; - // $TEST$ references other_MySchema + # $TEST$ references other_MySchema »MySchemaInAnotherPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with qualified import.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with qualified import.sdstest index c0ef64ec..90a7dcbb 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with qualified import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with qualified import.sdstest @@ -3,22 +3,22 @@ package tests.scoping.references.acrossFiles.toSchemas from TTSL.scoping.references.acrossFiles.toSchemas import MySchema from tests.scoping.references.acrossFiles.toSchemas.other import SchemaInAnotherPackage, Schema2InAnotherPackage -pipeline myPipeline { - // $TEST$ references TTSL_MySchema +function myFunction () { + # $TEST$ references TTSL_MySchema »MySchema«; - // $TEST$ references same_SchemaInSamePackage + # $TEST$ references same_SchemaInSamePackage »SchemaInSamePackage«; - // $TEST$ references TTSL_SchemaInTTSLPackage + # $TEST$ references TTSL_SchemaInTTSLPackage »SchemaInTTSLPackage«; - // $TEST$ references other_SchemaInAnotherPackage + # $TEST$ references other_SchemaInAnotherPackage »SchemaInAnotherPackage«; - // $TEST$ references other_Schema2InAnotherPackage + # $TEST$ references other_Schema2InAnotherPackage »Schema2InAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »SchemaWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with wildcard import.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with wildcard import.sdstest index 9e4ad137..19566ef0 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with wildcard import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/main with wildcard import.sdstest @@ -2,19 +2,19 @@ package tests.scoping.references.acrossFiles.toSchemas from TTSL.scoping.references.acrossFiles.toSchemas import * -pipeline myPipeline { - // $TEST$ references TTSL_MySchema +function myFunction () { + # $TEST$ references TTSL_MySchema »MySchema«; - // $TEST$ references same_SchemaInSamePackage + # $TEST$ references same_SchemaInSamePackage »SchemaInSamePackage«; - // $TEST$ references TTSL_SchemaInTTSLPackage + # $TEST$ references TTSL_SchemaInTTSLPackage »SchemaInTTSLPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »SchemaInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »SchemaWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/resource other package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/resource other package.sdstest index 27b7146e..4fb6033e 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/resource other package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/resource other package.sdstest @@ -1,10 +1,10 @@ package tests.scoping.references.acrossFiles.toSchemas.other -// $TEST$ target other_MySchema +# $TEST$ target other_MySchema schema »MySchema« {} -// $TEST$ target other_SchemaInAnotherPackage +# $TEST$ target other_SchemaInAnotherPackage schema »SchemaInAnotherPackage« {} -// $TEST$ target other_Schema2InAnotherPackage +# $TEST$ target other_Schema2InAnotherPackage schema »Schema2InAnotherPackage« {} diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/resource safeds package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/resource safeds package.sdstest index d6dd4db1..989fa707 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/resource safeds package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/resource safeds package.sdstest @@ -1,7 +1,7 @@ package TTSL.scoping.references.acrossFiles.toSchemas -// $TEST$ target TTSL_MySchema +# $TEST$ target TTSL_MySchema schema »MySchema« {} -// $TEST$ target TTSL_SchemaInTTSLPackage +# $TEST$ target TTSL_SchemaInTTSLPackage schema »SchemaInTTSLPackage« {} diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/resource same package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/resource same package.sdstest index 2fdfc079..7207677e 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/resource same package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/resource same package.sdstest @@ -1,7 +1,7 @@ package tests.scoping.references.acrossFiles.toSchemas -// $TEST$ target same_MySchema +# $TEST$ target same_MySchema schema »MySchema« {} -// $TEST$ target same_SchemaInSamePackage +# $TEST$ target same_SchemaInSamePackage schema »SchemaInSamePackage« {} diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/resource without package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/resource without package.sdstest index 89cd8480..3412fadb 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/resource without package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to schemas/resource without package.sdstest @@ -1,5 +1,5 @@ -// $TEST$ target without_MySchema +# $TEST$ target without_MySchema schema »MySchema« {} -// $TEST$ target without_SchemaWithoutPackage +# $TEST$ target without_SchemaWithoutPackage schema »SchemaWithoutPackage« {} diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main no imports or own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main no imports or own declarations.sdstest index 97fdea88..a12eb1c3 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main no imports or own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main no imports or own declarations.sdstest @@ -1,46 +1,46 @@ package tests.scoping.references.acrossFiles.toSegments -pipeline myPipeline { - // $TEST$ references same_mySegment +function myFunction () { + # $TEST$ references same_mySegment »mySegment«; - // $TEST$ references same_publicSegmentInSamePackage + # $TEST$ references same_publicSegmentInSamePackage »publicSegmentInSamePackage«; - // $TEST$ references same_internalSegmentInSamePackage + # $TEST$ references same_internalSegmentInSamePackage »internalSegmentInSamePackage«; - // $TEST$ unresolved + # $TEST$ unresolved »privateSegmentInSamePackage«; - // $TEST$ references TTSL_publicSegmentInTTSLPackage + # $TEST$ references TTSL_publicSegmentInTTSLPackage »publicSegmentInTTSLPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »internalSegmentInTTSLPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »privateSegmentInTTSLPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »publicSegmentInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »internalSegmentInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »privateSegmentInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »publicSegmentWithoutPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »internalSegmentWithoutPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »privateSegmentWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with imports and own declarations.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with imports and own declarations.sdstest index 0edea8a1..07e62dbc 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with imports and own declarations.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with imports and own declarations.sdstest @@ -5,53 +5,53 @@ from tests.scoping.references.acrossFiles.toSegments.other import publicSegmentI from tests.scoping.references.acrossFiles.toSegments.other import internalSegmentInAnotherPackage from tests.scoping.references.acrossFiles.toSegments.other import privateSegmentInAnotherPackage -// $TEST$ target own_myOwnSegment +# $TEST$ target own_myOwnSegment segment »myOwnSegment«() {} -pipeline myPipeline { - // $TEST$ references own_myOwnSegment +function myFunction () { + # $TEST$ references own_myOwnSegment »myOwnSegment«; - // $TEST$ references same_publicSegmentInSamePackage + # $TEST$ references same_publicSegmentInSamePackage »publicSegmentInSamePackage«; - // $TEST$ references same_internalSegmentInSamePackage + # $TEST$ references same_internalSegmentInSamePackage »internalSegmentInSamePackage«; - // $TEST$ unresolved + # $TEST$ unresolved »privateSegmentInSamePackage«; - // $TEST$ references TTSL_publicSegmentInTTSLPackage + # $TEST$ references TTSL_publicSegmentInTTSLPackage »publicSegmentInTTSLPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »internalSegmentInTTSLPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »privateSegmentInTTSLPackage«; - // $TEST$ references other_publicSegmentInAnotherPackage + # $TEST$ references other_publicSegmentInAnotherPackage »publicSegmentInAnotherPackage«; - // $TEST$ references other_public2SegmentInAnotherPackage + # $TEST$ references other_public2SegmentInAnotherPackage »public2SegmentInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »internalSegmentInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »privateSegmentInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »publicSegmentWithoutPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »internalSegmentWithoutPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »privateSegmentWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with multiple imports of same name.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with multiple imports of same name.sdstest index cdf23c4d..f13d320d 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with multiple imports of same name.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with multiple imports of same name.sdstest @@ -4,7 +4,7 @@ from TTSL.scoping.references.acrossFiles.toSegments import mySegment from tests.scoping.references.acrossFiles.toSegments.other import mySegment from tests.scoping.references.acrossFiles.toSegments import mySegment -pipeline myPipeline { - // $TEST$ references TTSL_mySegment +function myFunction () { + # $TEST$ references TTSL_mySegment »mySegment«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with qualified import with alias.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with qualified import with alias.sdstest index f8d07617..b5c2f0c0 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with qualified import with alias.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with qualified import with alias.sdstest @@ -4,57 +4,57 @@ from tests.scoping.references.acrossFiles.toSegments import mySegment as mySegme from TTSL.scoping.references.acrossFiles.toSegments import mySegment as mySegmentInTTSLPackage from tests.scoping.references.acrossFiles.toSegments.other import mySegment as mySegmentInAnotherPackage -pipeline myPipeline { - // $TEST$ references same_mySegment +function myFunction () { + # $TEST$ references same_mySegment »mySegment«; - // $TEST$ references same_publicSegmentInSamePackage + # $TEST$ references same_publicSegmentInSamePackage »publicSegmentInSamePackage«; - // $TEST$ references same_internalSegmentInSamePackage + # $TEST$ references same_internalSegmentInSamePackage »internalSegmentInSamePackage«; - // $TEST$ unresolved + # $TEST$ unresolved »privateSegmentInSamePackage«; - // $TEST$ references TTSL_publicSegmentInTTSLPackage + # $TEST$ references TTSL_publicSegmentInTTSLPackage »publicSegmentInTTSLPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »internalSegmentInTTSLPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »privateSegmentInTTSLPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »publicSegmentInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »internalSegmentInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »privateSegmentInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »publicSegmentWithoutPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »internalSegmentWithoutPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »privateSegmentWithoutPackage«; - // $TEST$ references same_mySegment + # $TEST$ references same_mySegment »mySegmentInSamePackage«; - // $TEST$ references TTSL_mySegment + # $TEST$ references TTSL_mySegment »mySegmentInTTSLPackage«; - // $TEST$ references other_mySegment + # $TEST$ references other_mySegment »mySegmentInAnotherPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with qualified import.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with qualified import.sdstest index 50b8870f..ff93d8bb 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with qualified import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with qualified import.sdstest @@ -5,50 +5,50 @@ from tests.scoping.references.acrossFiles.toSegments.other import publicSegmentI from tests.scoping.references.acrossFiles.toSegments.other import internalSegmentInAnotherPackage from tests.scoping.references.acrossFiles.toSegments.other import privateSegmentInAnotherPackage -pipeline myPipeline { - // $TEST$ references TTSL_mySegment +function myFunction () { + # $TEST$ references TTSL_mySegment »mySegment«; - // $TEST$ references same_publicSegmentInSamePackage + # $TEST$ references same_publicSegmentInSamePackage »publicSegmentInSamePackage«; - // $TEST$ references same_internalSegmentInSamePackage + # $TEST$ references same_internalSegmentInSamePackage »internalSegmentInSamePackage«; - // $TEST$ unresolved + # $TEST$ unresolved »privateSegmentInSamePackage«; - // $TEST$ references TTSL_publicSegmentInTTSLPackage + # $TEST$ references TTSL_publicSegmentInTTSLPackage »publicSegmentInTTSLPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »internalSegmentInTTSLPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »privateSegmentInTTSLPackage«; - // $TEST$ references other_publicSegmentInAnotherPackage + # $TEST$ references other_publicSegmentInAnotherPackage »publicSegmentInAnotherPackage«; - // $TEST$ references other_public2SegmentInAnotherPackage + # $TEST$ references other_public2SegmentInAnotherPackage »public2SegmentInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »internalSegmentInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »privateSegmentInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »publicSegmentWithoutPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »internalSegmentWithoutPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »privateSegmentWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with wildcard import.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with wildcard import.sdstest index 654c4a5a..38f3e078 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with wildcard import.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/main with wildcard import.sdstest @@ -2,47 +2,47 @@ package tests.scoping.references.acrossFiles.toSegments from TTSL.scoping.references.acrossFiles.toSegments import * -pipeline myPipeline { - // $TEST$ references TTSL_mySegment +function myFunction () { + # $TEST$ references TTSL_mySegment »mySegment«; - // $TEST$ references same_publicSegmentInSamePackage + # $TEST$ references same_publicSegmentInSamePackage »publicSegmentInSamePackage«; - // $TEST$ references same_internalSegmentInSamePackage + # $TEST$ references same_internalSegmentInSamePackage »internalSegmentInSamePackage«; - // $TEST$ unresolved + # $TEST$ unresolved »privateSegmentInSamePackage«; - // $TEST$ references TTSL_publicSegmentInTTSLPackage + # $TEST$ references TTSL_publicSegmentInTTSLPackage »publicSegmentInTTSLPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »internalSegmentInTTSLPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »privateSegmentInTTSLPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »publicSegmentInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »internalSegmentInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »privateSegmentInAnotherPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »publicSegmentWithoutPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »internalSegmentWithoutPackage«; - // $TEST$ unresolved + # $TEST$ unresolved »privateSegmentWithoutPackage«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/resource other package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/resource other package.sdstest index 02cd0f13..c1699e56 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/resource other package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/resource other package.sdstest @@ -1,16 +1,16 @@ package tests.scoping.references.acrossFiles.toSegments.other -// $TEST$ target other_mySegment +# $TEST$ target other_mySegment segment »mySegment«() {} -// $TEST$ target other_publicSegmentInAnotherPackage +# $TEST$ target other_publicSegmentInAnotherPackage segment »publicSegmentInAnotherPackage«() {} -// $TEST$ target other_public2SegmentInAnotherPackage +# $TEST$ target other_public2SegmentInAnotherPackage segment »public2SegmentInAnotherPackage«() {} -// $TEST$ target other_internalSegmentInAnotherPackage +# $TEST$ target other_internalSegmentInAnotherPackage internal segment »internalSegmentInAnotherPackage«() {} -// $TEST$ target other_privateSegmentInAnotherPackage +# $TEST$ target other_privateSegmentInAnotherPackage private segment »privateSegmentInAnotherPackage«() {} diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/resource safeds package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/resource safeds package.sdstest index c42d4cbe..5d785946 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/resource safeds package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/resource safeds package.sdstest @@ -1,13 +1,13 @@ package TTSL.scoping.references.acrossFiles.toSegments -// $TEST$ target TTSL_mySegment +# $TEST$ target TTSL_mySegment segment »mySegment«() {} -// $TEST$ target TTSL_publicSegmentInTTSLPackage +# $TEST$ target TTSL_publicSegmentInTTSLPackage segment »publicSegmentInTTSLPackage«() {} -// $TEST$ target TTSL_internalSegmentInTTSLPackage +# $TEST$ target TTSL_internalSegmentInTTSLPackage internal segment »internalSegmentInTTSLPackage«() {} -// $TEST$ target TTSL_privateSegmentInTTSLPackage +# $TEST$ target TTSL_privateSegmentInTTSLPackage private segment »privateSegmentInTTSLPackage«() {} diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/resource same package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/resource same package.sdstest index 9d1f66b4..a3ea3df3 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/resource same package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/resource same package.sdstest @@ -1,13 +1,13 @@ package tests.scoping.references.acrossFiles.toSegments -// $TEST$ target same_mySegment +# $TEST$ target same_mySegment segment »mySegment«() {} -// $TEST$ target same_publicSegmentInSamePackage +# $TEST$ target same_publicSegmentInSamePackage segment »publicSegmentInSamePackage«() {} -// $TEST$ target same_internalSegmentInSamePackage +# $TEST$ target same_internalSegmentInSamePackage internal segment »internalSegmentInSamePackage«() {} -// $TEST$ target same_privateSegmentInSamePackage +# $TEST$ target same_privateSegmentInSamePackage private segment »privateSegmentInSamePackage«() {} diff --git a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/resource without package.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/resource without package.sdstest index 6c6e2ca6..de228f0d 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/resource without package.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/across files/to segments/resource without package.sdstest @@ -1,11 +1,11 @@ -// $TEST$ target without_mySegment +# $TEST$ target without_mySegment segment »mySegment«() {} -// $TEST$ target without_publicSegmentWithoutPackage +# $TEST$ target without_publicSegmentWithoutPackage segment »publicSegmentWithoutPackage«() {} -// $TEST$ target without_internalSegmentWithoutPackage +# $TEST$ target without_internalSegmentWithoutPackage internal segment »internalSegmentWithoutPackage«() {} -// $TEST$ target without_privateSegmentWithoutPackage +# $TEST$ target without_privateSegmentWithoutPackage private segment »privateSegmentWithoutPackage«() {} diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to annotations/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to annotations/main.sdstest index 1564119c..dbc3ba36 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to annotations/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to annotations/main.sdstest @@ -1,15 +1,15 @@ package tests.scoping.references.inSameFile.toAnnotations -// $TEST$ target before +# $TEST$ target before annotation »Before« segment mySegment() { - // $TEST$ references before + # $TEST$ references before »Before«; - // $TEST$ references after + # $TEST$ references after »After«; } -// $TEST$ target after +# $TEST$ target after annotation »After« diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to block lambda results/from outside/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to block lambda results/from outside/main.sdstest index 95875b7d..7f3f2d47 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to block lambda results/from outside/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to block lambda results/from outside/main.sdstest @@ -1,10 +1,10 @@ package tests.scoping.references.inSameFile.toBlockLambdaResults.fromOutside -pipeline myPipeline { +function myFunction () { () { yield myBlockLambdaResult = 1; }; - // $TEST$ unresolved + # $TEST$ unresolved »myBlockLambdaResult«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to block lambda results/of containing block lambda/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to block lambda results/of containing block lambda/main.sdstest index 4a06f68d..2ecf4075 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to block lambda results/of containing block lambda/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to block lambda results/of containing block lambda/main.sdstest @@ -1,9 +1,9 @@ package tests.scoping.references.inSameFile.toBlockLambdaResults.ofContainingBlockLambda -pipeline myPipeline { +function myFunction () { () { yield lambdaResult = 1; - // $TEST$ unresolved + # $TEST$ unresolved »lambdaResult«; }; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to class members/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to class members/main.sdstest index 373eceea..c2f49fc5 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to class members/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to class members/main.sdstest @@ -12,22 +12,22 @@ class MyClass { fun instanceMethod() } -pipeline myPipeline { - // $TEST$ unresolved +function myFunction () { + # $TEST$ unresolved »staticAttribute«; - // $TEST$ unresolved + # $TEST$ unresolved »instanceAttribute«; - // $TEST$ unresolved + # $TEST$ unresolved »NestedClass«; - // $TEST$ unresolved + # $TEST$ unresolved »NestedEnum«; - // $TEST$ unresolved + # $TEST$ unresolved »staticMethod«; - // $TEST$ unresolved + # $TEST$ unresolved »instanceMethod«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to constants/main.ttsl b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to constants/main.ttsl index edfd3b55..bbfb9e7f 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to constants/main.ttsl +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to constants/main.ttsl @@ -1,15 +1,15 @@ package tests.scoping.references.inSameFile.toConstant -// $TEST$ target before +# $TEST$ target before constant »before« : Int = 1 function myFunction() { - // $TEST$ references before + # $TEST$ references before »before«; - // $TEST$ references after + # $TEST$ references after »after«; } -// $TEST$ target after +# $TEST$ target after constant »after«: Int = 2 \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to containing declarations/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to containing declarations/main.sdstest index daee4dd2..86bfd661 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to containing declarations/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to containing declarations/main.sdstest @@ -3,112 +3,112 @@ package tests.scoping.references.inSameFile.toContainingDeclarations @Repeatable annotation MyAnnotation(p: Any?) -// $TEST$ target outerClass +# $TEST$ target outerClass class »MyClass«( @MyAnnotation( - // $TEST$ references outerClass + # $TEST$ references outerClass p = »MyClass«() ) - // $TEST$ references outerClass + # $TEST$ references outerClass p: Any? = »MyClass«() ) { @MyAnnotation( - // $TEST$ references outerClass + # $TEST$ references outerClass p = »MyClass«() ) @MyAnnotation( - // $TEST$ unresolved + # $TEST$ unresolved p = »MyEnum« ) fun f( @MyAnnotation( - // $TEST$ references outerClass + # $TEST$ references outerClass p = »MyClass«() ) - // $TEST$ references outerClass + # $TEST$ references outerClass p1: Any? = »MyClass«(), @MyAnnotation( - // $TEST$ unresolved + # $TEST$ unresolved p = »MyEnum« ) - // $TEST$ unresolved + # $TEST$ unresolved p2: Any? = »MyEnum« ) @MyAnnotation( - // $TEST$ references outerClass + # $TEST$ references outerClass p = »MyClass«() ) @MyAnnotation( - // $TEST$ unresolved + # $TEST$ unresolved p = »MyEnum« ) - // $TEST$ target enum + # $TEST$ target enum enum »MyEnum« { - // $TEST$ target variant + # $TEST$ target variant »MyEnumVariant«( @MyAnnotation( - // $TEST$ references outerClass + # $TEST$ references outerClass p = »MyClass«() ) - // $TEST$ references outerClass + # $TEST$ references outerClass p1: Any? = »MyClass«(), @MyAnnotation( - // $TEST$ references enum + # $TEST$ references enum p = »MyEnum« ) - // $TEST$ references enum + # $TEST$ references enum p2: Any? = »MyEnum«, @MyAnnotation( - // $TEST$ references variant + # $TEST$ references variant p = »MyEnumVariant« ) - // $TEST$ references variant + # $TEST$ references variant p3: Any? = »MyEnumVariant«, ) } @MyAnnotation( - // $TEST$ references outerClass + # $TEST$ references outerClass p = »MyClass«() ) @MyAnnotation( - // $TEST$ unresolved + # $TEST$ unresolved p = »MyEnum« ) - // $TEST$ target innerClass + # $TEST$ target innerClass class »MyClass«( @MyAnnotation( - // $TEST$ references innerClass + # $TEST$ references innerClass p = »MyClass«() ) - // $TEST$ references innerClass + # $TEST$ references innerClass p1: Any? = »MyClass«(), @MyAnnotation( - // $TEST$ unresolved + # $TEST$ unresolved p = »MyEnum« ) - // $TEST$ unresolved + # $TEST$ unresolved p2: Any? = »MyEnum« ) { fun f( @MyAnnotation( - // $TEST$ references innerClass + # $TEST$ references innerClass p = »MyClass«() ) - // $TEST$ references innerClass + # $TEST$ references innerClass p1: Any? = »MyClass«(), @MyAnnotation( - // $TEST$ unresolved + # $TEST$ unresolved p = »MyEnum« ) - // $TEST$ unresolved + # $TEST$ unresolved p2: Any? = »MyEnum« ) } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to enum variants/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to enum variants/main.sdstest index 180d015c..6dde6ed2 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to enum variants/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to enum variants/main.sdstest @@ -4,7 +4,7 @@ enum MyEnum { MyEnumVariant } -pipeline myPipeline { - // $TEST$ unresolved +function myFunction () { + # $TEST$ unresolved »MyEnumVariant«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to functions/main.ttsl b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to functions/main.ttsl index 765c97fb..052c45e4 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to functions/main.ttsl +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to functions/main.ttsl @@ -1,15 +1,15 @@ package tests.scoping.references.inSameFile.toFunction -// $TEST$ target before +# $TEST$ target before function »before«() {} function myFunction() { - // $TEST$ references before + # $TEST$ references before »before«(); - // $TEST$ references after + # $TEST$ references after »after«(); } -// $TEST$ target after +# $TEST$ target after function »after«() {} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to global classes/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to global classes/main.sdstest index 0085cf6c..7eefe674 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to global classes/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to global classes/main.sdstest @@ -1,15 +1,15 @@ package tests.scoping.references.inSameFile.toGlobalClasses -// $TEST$ target before +# $TEST$ target before class »Before«() -pipeline myPipeline { - // $TEST$ references before +function myFunction () { + # $TEST$ references before »Before«; - // $TEST$ references after + # $TEST$ references after »After«; } -// $TEST$ target after +# $TEST$ target after class »After«() diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to global enums/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to global enums/main.sdstest index 9ec1275a..fa9dcc53 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to global enums/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to global enums/main.sdstest @@ -1,15 +1,15 @@ package tests.scoping.references.inSameFile.toGlobalEnums -// $TEST$ target before +# $TEST$ target before enum »Before« -pipeline myPipeline { - // $TEST$ references before +function myFunction () { + # $TEST$ references before »Before«(); - // $TEST$ references after + # $TEST$ references after »After«(); } -// $TEST$ target after +# $TEST$ target after enum »After« diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to global functions/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to global functions/main.sdstest index 7f07163a..c8703560 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to global functions/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to global functions/main.sdstest @@ -1,15 +1,15 @@ package tests.scoping.references.inSameFile.toGlobalFunctions -// $TEST$ target before +# $TEST$ target before fun »before«() -pipeline myPipeline { - // $TEST$ references before +function myFunction () { + # $TEST$ references before »before«(); - // $TEST$ references after + # $TEST$ references after »after«(); } -// $TEST$ target after +# $TEST$ target after fun »after«() diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to modules/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to modules/main.sdstest index 2904f0e2..7b247958 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to modules/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to modules/main.sdstest @@ -1,6 +1,6 @@ package tests -pipeline myPipeline { - // $TEST$ unresolved +function myFunction () { + # $TEST$ unresolved »tests«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/from default value of parameter/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/from default value of parameter/main.sdstest index bdd2e7af..3b48e359 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/from default value of parameter/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/from default value of parameter/main.sdstest @@ -1,84 +1,84 @@ package tests.scoping.references.inSameFile.toParameters.fromDefaultValueOfParameter annotation MyAnnotation( - // $TEST$ target annotation_param - // $TEST$ unresolved + # $TEST$ target annotation_param + # $TEST$ unresolved »p«: String = »q«, - // $TEST$ references annotation_param + # $TEST$ references annotation_param q: String = »p«, - // $TEST$ unresolved + # $TEST$ unresolved r: String = »r«, ) class MyClass( - // $TEST$ target class_param - // $TEST$ unresolved + # $TEST$ target class_param + # $TEST$ unresolved »p«: String = »q«, - // $TEST$ references class_param + # $TEST$ references class_param q: String = »p«, - // $TEST$ unresolved + # $TEST$ unresolved r: String = »r«, ) enum MyEnum { MyEnumVariant( - // $TEST$ target enum_variant_param - // $TEST$ unresolved + # $TEST$ target enum_variant_param + # $TEST$ unresolved »p«: String = »q«, - // $TEST$ references enum_variant_param + # $TEST$ references enum_variant_param q: String = »p«, - // $TEST$ unresolved + # $TEST$ unresolved r: String = »r«, ) } fun myFunction( - // $TEST$ target function_param - // $TEST$ unresolved + # $TEST$ target function_param + # $TEST$ unresolved »p«: String = »q«, - // $TEST$ references function_param + # $TEST$ references function_param q: String = »p«, - // $TEST$ unresolved + # $TEST$ unresolved r: String = »r«, ) segment mySegment1( - // $TEST$ target segment_param - // $TEST$ unresolved + # $TEST$ target segment_param + # $TEST$ unresolved »p«: String = »q«, - // $TEST$ references segment_param + # $TEST$ references segment_param q: String = »p«, - // $TEST$ unresolved + # $TEST$ unresolved r: String = »r«, ) {} segment mySegment2( p: ( - // $TEST$ target callable_type_param - // $TEST$ unresolved + # $TEST$ target callable_type_param + # $TEST$ unresolved »p«: String = »q«, - // $TEST$ references callable_type_param + # $TEST$ references callable_type_param q: String = »p«, - // $TEST$ unresolved + # $TEST$ unresolved r: String = »r«, ) -> () ) { ( - // $TEST$ target block_lambda_param - // $TEST$ unresolved + # $TEST$ target block_lambda_param + # $TEST$ unresolved »p«: String = »q«, - // $TEST$ references block_lambda_param + # $TEST$ references block_lambda_param q: String = »p«, - // $TEST$ unresolved + # $TEST$ unresolved r: String = »r«, ) {}; ( - // $TEST$ target block_function_param - // $TEST$ unresolved + # $TEST$ target block_function_param + # $TEST$ unresolved »p«: String = »q«, - // $TEST$ references block_function_param + # $TEST$ references block_function_param q: String = »p«, - // $TEST$ unresolved + # $TEST$ unresolved r: String = »r«, ) -> 1; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/from outside/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/from outside/main.sdstest index d923ca8e..6af77d45 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/from outside/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/from outside/main.sdstest @@ -18,27 +18,27 @@ segment mySegment2( (myBlockLambdaParameter) {}; (myExpressionLambdaParameter) -> 1; - // $TEST$ unresolved + # $TEST$ unresolved »myAnnotationParameter«; - // $TEST$ unresolved + # $TEST$ unresolved »myClassParameter«; - // $TEST$ unresolved + # $TEST$ unresolved »myEnumVariantParameter«; - // $TEST$ unresolved + # $TEST$ unresolved »myFunctionParameter«; - // $TEST$ unresolved + # $TEST$ unresolved »mySegmentParameter«; - // $TEST$ unresolved + # $TEST$ unresolved »myCallableTypeParameter«; - // $TEST$ unresolved + # $TEST$ unresolved »myBlockLambdaParameter«; - // $TEST$ unresolved + # $TEST$ unresolved »myExpressionLambdaParameter«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/from parameter bound/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/from parameter bound/main.sdstest index dfd795e3..3948dc6e 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/from parameter bound/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/from parameter bound/main.sdstest @@ -1,39 +1,39 @@ package tests.scoping.references.inSameFile.toParameters.fromParameterBound -// $TEST$ target annotation_p +# $TEST$ target annotation_p annotation MyAnnotation(»p«: Int) where { - // $TEST$ references annotation_p + # $TEST$ references annotation_p p < »p«, - // $TEST$ unresolved + # $TEST$ unresolved p > »unresolved«, } -// $TEST$ target class_p +# $TEST$ target class_p class MyClass(»p«: Int) where { - // $TEST$ references class_p + # $TEST$ references class_p p < »p«, - // $TEST$ unresolved + # $TEST$ unresolved p > »unresolved«, } -// $TEST$ target enumVariant_p +# $TEST$ target enumVariant_p enum MyEnum { MyEnumVariant(»p«: Int) where { - // $TEST$ references enumVariant_p + # $TEST$ references enumVariant_p p < »p«, - // $TEST$ unresolved + # $TEST$ unresolved p > »unresolved«, } } -// $TEST$ target function_p +# $TEST$ target function_p fun myFunction(»p«: Int) where { - // $TEST$ references function_p + # $TEST$ references function_p p < »p«, - // $TEST$ unresolved + # $TEST$ unresolved p > »unresolved«, } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/of containing block lambda/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/of containing block lambda/main.sdstest index 5ca399e9..e6ee997b 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/of containing block lambda/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/of containing block lambda/main.sdstest @@ -4,75 +4,75 @@ segment mySegment(myShadowedSegmentParameter: Int) { val myShadowedPlaceholder = 0; ( - // $TEST$ target outer_myOuterBlockLambdaParameter + # $TEST$ target outer_myOuterBlockLambdaParameter »myOuterBlockLambdaParameter«, - // $TEST$ target outer_myShadowedSegmentParameter + # $TEST$ target outer_myShadowedSegmentParameter »myShadowedSegmentParameter«, - // $TEST$ target outer_myShadowedBlockLambdaParameter + # $TEST$ target outer_myShadowedBlockLambdaParameter »myShadowedBlockLambdaParameter«, - // $TEST$ target outer_myShadowedPlaceholder + # $TEST$ target outer_myShadowedPlaceholder »myShadowedPlaceholder«, - // $TEST$ target redeclaredAsParameter + # $TEST$ target redeclaredAsParameter »redeclaredAsParameter«, redeclaredAsParameter, - // $TEST$ target redeclaredAsPlaceholder + # $TEST$ target redeclaredAsPlaceholder »redeclaredAsPlaceholder«, ) { val redeclaredAsPlaceholder = 0; - // $TEST$ references outer_myOuterBlockLambdaParameter + # $TEST$ references outer_myOuterBlockLambdaParameter »myOuterBlockLambdaParameter«; - // $TEST$ references outer_myShadowedSegmentParameter + # $TEST$ references outer_myShadowedSegmentParameter »myShadowedSegmentParameter«; - // $TEST$ references outer_myShadowedBlockLambdaParameter + # $TEST$ references outer_myShadowedBlockLambdaParameter »myShadowedBlockLambdaParameter«; - // $TEST$ references outer_myShadowedPlaceholder + # $TEST$ references outer_myShadowedPlaceholder »myShadowedPlaceholder«; - // $TEST$ references redeclaredAsParameter + # $TEST$ references redeclaredAsParameter »redeclaredAsParameter«; - // $TEST$ references redeclaredAsPlaceholder + # $TEST$ references redeclaredAsPlaceholder »redeclaredAsPlaceholder«; - // $TEST$ unresolved + # $TEST$ unresolved »myInnerBlockLambdaParameter«; ( - // $TEST$ target inner_myInnerBlockLambdaParameter + # $TEST$ target inner_myInnerBlockLambdaParameter »myInnerBlockLambdaParameter«, - // $TEST$ target inner_myShadowedBlockLambdaParameter + # $TEST$ target inner_myShadowedBlockLambdaParameter »myShadowedBlockLambdaParameter« ) { () -> - // $TEST$ references outer_myOuterBlockLambdaParameter + # $TEST$ references outer_myOuterBlockLambdaParameter »myOuterBlockLambdaParameter« + - // $TEST$ references outer_myShadowedSegmentParameter + # $TEST$ references outer_myShadowedSegmentParameter »myShadowedSegmentParameter« + - // $TEST$ references inner_myShadowedBlockLambdaParameter + # $TEST$ references inner_myShadowedBlockLambdaParameter »myShadowedBlockLambdaParameter«; - // $TEST$ references outer_myShadowedPlaceholder + # $TEST$ references outer_myShadowedPlaceholder »myShadowedPlaceholder« + - // $TEST$ references redeclaredAsParameter + # $TEST$ references redeclaredAsParameter »redeclaredAsParameter« + - // $TEST$ references redeclaredAsPlaceholder + # $TEST$ references redeclaredAsPlaceholder »redeclaredAsPlaceholder« + - // $TEST$ references inner_myInnerBlockLambdaParameter + # $TEST$ references inner_myInnerBlockLambdaParameter »myInnerBlockLambdaParameter«; }; diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/of containing expression lambda/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/of containing expression lambda/main.sdstest index 1f5fd6cc..fc2a78fb 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/of containing expression lambda/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/of containing expression lambda/main.sdstest @@ -4,64 +4,64 @@ segment mySegment(myShadowedSegmentParameter: Int) { val myShadowedPlaceholder = 0; ( - // $TEST$ target outer_myOuterExpressionLambdaParameter + # $TEST$ target outer_myOuterExpressionLambdaParameter »myOuterExpressionLambdaParameter«, - // $TEST$ target outer_myShadowedSegmentParameter + # $TEST$ target outer_myShadowedSegmentParameter »myShadowedSegmentParameter«, - // $TEST$ target outer_myShadowedExpressionLambdaParameter + # $TEST$ target outer_myShadowedExpressionLambdaParameter »myShadowedExpressionLambdaParameter«, - // $TEST$ target outer_myShadowedPlaceholder + # $TEST$ target outer_myShadowedPlaceholder »myShadowedPlaceholder«, - // $TEST$ target outer_redeclaredAsParameter + # $TEST$ target outer_redeclaredAsParameter »redeclaredAsParameter«, redeclaredAsParameter ) -> - // $TEST$ references outer_myOuterExpressionLambdaParameter + # $TEST$ references outer_myOuterExpressionLambdaParameter »myOuterExpressionLambdaParameter« + - // $TEST$ references outer_myShadowedSegmentParameter + # $TEST$ references outer_myShadowedSegmentParameter »myShadowedSegmentParameter« + - // $TEST$ references outer_myShadowedPlaceholder + # $TEST$ references outer_myShadowedPlaceholder »myShadowedPlaceholder« + - // $TEST$ references outer_redeclaredAsParameter + # $TEST$ references outer_redeclaredAsParameter »redeclaredAsParameter« + - // $TEST$ unresolved + # $TEST$ unresolved »myInnerExpressionLambdaParameter« + - // $TEST$ references outer_myShadowedExpressionLambdaParameter + # $TEST$ references outer_myShadowedExpressionLambdaParameter »myShadowedExpressionLambdaParameter« + (( - // $TEST$ target inner_myInnerExpressionLambdaParameter + # $TEST$ target inner_myInnerExpressionLambdaParameter »myInnerExpressionLambdaParameter«, - // $TEST$ target inner_myShadowedExpressionLambdaParameter + # $TEST$ target inner_myShadowedExpressionLambdaParameter »myShadowedExpressionLambdaParameter«, ) -> () { - // $TEST$ references outer_myOuterExpressionLambdaParameter + # $TEST$ references outer_myOuterExpressionLambdaParameter »myOuterExpressionLambdaParameter«; - // $TEST$ references outer_myShadowedSegmentParameter + # $TEST$ references outer_myShadowedSegmentParameter »myShadowedSegmentParameter«; - // $TEST$ references outer_myShadowedPlaceholder + # $TEST$ references outer_myShadowedPlaceholder »myShadowedPlaceholder«; - // $TEST$ references outer_redeclaredAsParameter + # $TEST$ references outer_redeclaredAsParameter »redeclaredAsParameter«; - // $TEST$ references inner_myInnerExpressionLambdaParameter + # $TEST$ references inner_myInnerExpressionLambdaParameter »myInnerExpressionLambdaParameter«; - // $TEST$ references inner_myShadowedExpressionLambdaParameter + # $TEST$ references inner_myShadowedExpressionLambdaParameter »myShadowedExpressionLambdaParameter«; } ) diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/of containing segment/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/of containing segment/main.sdstest index 6d0766b7..cfba356d 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/of containing segment/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to parameters/of containing segment/main.sdstest @@ -1,45 +1,45 @@ package tests.scoping.references.inSameFile.toParameters.ofContainingExpressionLambda segment mySegment( - // $TEST$ target parameter + # $TEST$ target parameter »myParameter«: Int, - // $TEST$ target redeclaredAsParameter + # $TEST$ target redeclaredAsParameter »redeclaredAsParameter«: Int, redeclaredAsParameter: Int, - // $TEST$ target redeclaredAsPlaceholder + # $TEST$ target redeclaredAsPlaceholder »redeclaredAsPlaceholder«: Int ) { val redeclaredAsPlaceholder = 0; - // $TEST$ references parameter + # $TEST$ references parameter »myParameter«; - // $TEST$ references redeclaredAsParameter + # $TEST$ references redeclaredAsParameter »redeclaredAsParameter«; - // $TEST$ references redeclaredAsPlaceholder + # $TEST$ references redeclaredAsPlaceholder »redeclaredAsPlaceholder«; () { - // $TEST$ references parameter + # $TEST$ references parameter »myParameter«; - // $TEST$ references redeclaredAsParameter + # $TEST$ references redeclaredAsParameter »redeclaredAsParameter«; - // $TEST$ references redeclaredAsPlaceholder + # $TEST$ references redeclaredAsPlaceholder »redeclaredAsPlaceholder«; }; () -> - // $TEST$ references parameter + # $TEST$ references parameter »myParameter« + - // $TEST$ references redeclaredAsParameter + # $TEST$ references redeclaredAsParameter »redeclaredAsParameter« + - // $TEST$ references redeclaredAsPlaceholder + # $TEST$ references redeclaredAsPlaceholder »redeclaredAsPlaceholder«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to pipelines/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to pipelines/main.sdstest index 6a0fe7a3..9ad61ad5 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to pipelines/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to pipelines/main.sdstest @@ -1,15 +1,15 @@ package tests.scoping.references.inSameFile.toPipelines -// $TEST$ target before +# $TEST$ target before pipeline »before« {} segment mySegment() { - // $TEST$ references before + # $TEST$ references before »before«; - // $TEST$ references after + # $TEST$ references after »after«; } -// $TEST$ target after +# $TEST$ target after pipeline »after« {} diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to placeholders/from outside/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to placeholders/from outside/main.sdstest index 6c0aa54d..1d73b916 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to placeholders/from outside/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to placeholders/from outside/main.sdstest @@ -1,6 +1,6 @@ package tests.scoping.references.inSameFile.toPlaceholders.fromOutside -pipeline myPipeline1 { +function myFunction1 { val pipelinePlaceholder = 1; } @@ -8,17 +8,17 @@ segment mySegment(mySegmentParameter: String) { val segmentPlaceholder = 1; } -pipeline myPipeline2 { +function myFunction2 { () { val blockLambdaPlaceholder = 1; }; - // $TEST$ unresolved + # $TEST$ unresolved »pipelinePlaceholder«; - // $TEST$ unresolved + # $TEST$ unresolved »segmentPlaceholder«; - // $TEST$ unresolved + # $TEST$ unresolved »blockLambdaPlaceholder«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to placeholders/of containing block lambda/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to placeholders/of containing block lambda/main.sdstest index 434bf178..3fe2022c 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to placeholders/of containing block lambda/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to placeholders/of containing block lambda/main.sdstest @@ -4,123 +4,123 @@ segment mySegment(mySegmentParameter: Int) { val mySegmentPlaceholder = 0; (myOuterBlockLambdaParameter) { - // $TEST$ target outer_mySegmentParameter + # $TEST$ target outer_mySegmentParameter val »mySegmentParameter« = 0; - // $TEST$ target outer_mySegmentPlaceholder + # $TEST$ target outer_mySegmentPlaceholder val »mySegmentPlaceholder« = 0; - // $TEST$ target outer_myOuterBlockLambdaPlaceholderBefore + # $TEST$ target outer_myOuterBlockLambdaPlaceholderBefore val »myOuterBlockLambdaPlaceholderBefore« = 0; - // $TEST$ target outer_redeclared + # $TEST$ target outer_redeclared val »redeclared« = 0; val redeclared = 0; - // $TEST$ references outer_mySegmentParameter + # $TEST$ references outer_mySegmentParameter »mySegmentParameter«; - // $TEST$ references outer_mySegmentPlaceholder + # $TEST$ references outer_mySegmentPlaceholder »mySegmentPlaceholder«; - // $TEST$ references outer_myOuterBlockLambdaPlaceholderBefore + # $TEST$ references outer_myOuterBlockLambdaPlaceholderBefore »myOuterBlockLambdaPlaceholderBefore«; - // $TEST$ references outer_redeclared + # $TEST$ references outer_redeclared »redeclared«; - // $TEST$ unresolved + # $TEST$ unresolved »myOuterBlockLambdaPlaceholderAfter«; val blockLambda = () { - // $TEST$ target inner_mySegmentParameter + # $TEST$ target inner_mySegmentParameter val »mySegmentParameter« = 0; - // $TEST$ target inner_mySegmentPlaceholder + # $TEST$ target inner_mySegmentPlaceholder val »mySegmentPlaceholder« = 0; - // $TEST$ target inner_myOuterBlockLambdaParameter + # $TEST$ target inner_myOuterBlockLambdaParameter val »myOuterBlockLambdaParameter« = 0; - // $TEST$ target inner_myOuterBlockLambdaPlaceholderBefore + # $TEST$ target inner_myOuterBlockLambdaPlaceholderBefore val »myOuterBlockLambdaPlaceholderBefore« = 0; - // $TEST$ references inner_mySegmentParameter + # $TEST$ references inner_mySegmentParameter »mySegmentParameter«; - // $TEST$ references inner_mySegmentPlaceholder + # $TEST$ references inner_mySegmentPlaceholder »mySegmentPlaceholder«; - // $TEST$ references inner_myOuterBlockLambdaParameter + # $TEST$ references inner_myOuterBlockLambdaParameter »myOuterBlockLambdaParameter«; - // $TEST$ references inner_myOuterBlockLambdaPlaceholderBefore + # $TEST$ references inner_myOuterBlockLambdaPlaceholderBefore »myOuterBlockLambdaPlaceholderBefore«; - // $TEST$ references outer_redeclared + # $TEST$ references outer_redeclared »redeclared«; - // $TEST$ unresolved + # $TEST$ unresolved »blockLambda«; - // $TEST$ unresolved + # $TEST$ unresolved »myOuterBlockLambdaPlaceholderAfter«; val expressionLambda = () -> - // $TEST$ references inner_mySegmentParameter + # $TEST$ references inner_mySegmentParameter »mySegmentParameter« + - // $TEST$ references inner_mySegmentPlaceholder + # $TEST$ references inner_mySegmentPlaceholder »mySegmentPlaceholder« + - // $TEST$ references inner_myOuterBlockLambdaParameter + # $TEST$ references inner_myOuterBlockLambdaParameter »myOuterBlockLambdaParameter« + - // $TEST$ references inner_myOuterBlockLambdaPlaceholderBefore + # $TEST$ references inner_myOuterBlockLambdaPlaceholderBefore »myOuterBlockLambdaPlaceholderBefore« + - // $TEST$ references outer_redeclared + # $TEST$ references outer_redeclared »redeclared« + - // $TEST$ unresolved + # $TEST$ unresolved »blockLambda« + - // $TEST$ unresolved + # $TEST$ unresolved »expressionLambda« + - // $TEST$ unresolved + # $TEST$ unresolved »myOuterBlockLambdaPlaceholderAfter«; }; () -> () { - // $TEST$ target blockLambdaInExpressionLambda_mySegmentParameter + # $TEST$ target blockLambdaInExpressionLambda_mySegmentParameter val »mySegmentParameter« = 0; - // $TEST$ target blockLambdaInExpressionLambda_mySegmentPlaceholder + # $TEST$ target blockLambdaInExpressionLambda_mySegmentPlaceholder val »mySegmentPlaceholder« = 0; - // $TEST$ target blockLambdaInExpressionLambda_myOuterBlockLambdaParameter + # $TEST$ target blockLambdaInExpressionLambda_myOuterBlockLambdaParameter val »myOuterBlockLambdaParameter« = 0; - // $TEST$ target blockLambdaInExpressionLambda_myOuterBlockLambdaPlaceholderBefore + # $TEST$ target blockLambdaInExpressionLambda_myOuterBlockLambdaPlaceholderBefore val »myOuterBlockLambdaPlaceholderBefore« = 0; - // $TEST$ references blockLambdaInExpressionLambda_mySegmentParameter + # $TEST$ references blockLambdaInExpressionLambda_mySegmentParameter »mySegmentParameter«; - // $TEST$ references blockLambdaInExpressionLambda_mySegmentPlaceholder + # $TEST$ references blockLambdaInExpressionLambda_mySegmentPlaceholder »mySegmentPlaceholder«; - // $TEST$ references blockLambdaInExpressionLambda_myOuterBlockLambdaPlaceholderBefore + # $TEST$ references blockLambdaInExpressionLambda_myOuterBlockLambdaPlaceholderBefore »myOuterBlockLambdaPlaceholderBefore«; - // $TEST$ references outer_redeclared + # $TEST$ references outer_redeclared »redeclared«; - // $TEST$ unresolved + # $TEST$ unresolved »myOuterBlockLambdaPlaceholderAfter«; }; diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to placeholders/of containing function/main.ttsl b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to placeholders/of containing function/main.ttsl index 1a25d494..b6b969c1 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to placeholders/of containing function/main.ttsl +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to placeholders/of containing function/main.ttsl @@ -1,16 +1,16 @@ package tests.scoping.references.inSameFile.toPlaceholders.ofContainingFunction function myFunction() { - // $TEST$ target before + # $TEST$ target before var »before«: Int = 0; - // $TEST$ target redeclared + # $TEST$ target redeclared var »redeclared«: Int = 0; var redeclared: Int = 0; - // $TEST$ references before + # $TEST$ references before »before«; - // $TEST$ references redeclared + # $TEST$ references redeclared »redeclared«; } \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to placeholders/of containing pipeline/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to placeholders/of containing pipeline/main.sdstest index 48ceac04..c8b18491 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to placeholders/of containing pipeline/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to placeholders/of containing pipeline/main.sdstest @@ -1,61 +1,61 @@ package tests.scoping.references.inSameFile.toPlaceholders.ofContainingPipeline -pipeline myPipeline { - // $TEST$ target before +function myFunction () { + # $TEST$ target before val »before« = 0; - // $TEST$ target redeclared + # $TEST$ target redeclared val »redeclared« = 0; val redeclared = 0; - // $TEST$ references before + # $TEST$ references before »before«; - // $TEST$ references redeclared + # $TEST$ references redeclared »redeclared«; - // $TEST$ unresolved + # $TEST$ unresolved »after«; val blockLambda = () { - // $TEST$ references before + # $TEST$ references before »before«; - // $TEST$ references redeclared + # $TEST$ references redeclared »redeclared«; - // $TEST$ unresolved + # $TEST$ unresolved »blockLambda«; - // $TEST$ unresolved + # $TEST$ unresolved »after«; () { - // $TEST$ references before + # $TEST$ references before »before«; - // $TEST$ references redeclared + # $TEST$ references redeclared »redeclared«; - // $TEST$ unresolved + # $TEST$ unresolved »blockLambda«; - // $TEST$ unresolved + # $TEST$ unresolved »after«; }; }; val expressionLambda = () -> - // $TEST$ references before + # $TEST$ references before »before« + - // $TEST$ references redeclared + # $TEST$ references redeclared »redeclared« + - // $TEST$ unresolved + # $TEST$ unresolved »expressionLambda« + - // $TEST$ unresolved + # $TEST$ unresolved »after«; val after = 1; diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to placeholders/of containing segment/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to placeholders/of containing segment/main.sdstest index 4105498b..9f9e467c 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to placeholders/of containing segment/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to placeholders/of containing segment/main.sdstest @@ -1,61 +1,61 @@ package tests.scoping.references.inSameFile.toPlaceholders.ofContainingSegment segment mySegment() { - // $TEST$ target before + # $TEST$ target before val »before« = 0; - // $TEST$ target redeclared + # $TEST$ target redeclared val »redeclared« = 0; val redeclared = 0; - // $TEST$ references before + # $TEST$ references before »before«; - // $TEST$ references redeclared + # $TEST$ references redeclared »redeclared«; - // $TEST$ unresolved + # $TEST$ unresolved »after«; val blockLambda = () { - // $TEST$ references before + # $TEST$ references before »before«; - // $TEST$ references redeclared + # $TEST$ references redeclared »redeclared«; - // $TEST$ unresolved + # $TEST$ unresolved »blockLambda«; - // $TEST$ unresolved + # $TEST$ unresolved »after«; () { - // $TEST$ references before + # $TEST$ references before »before«; - // $TEST$ references redeclared + # $TEST$ references redeclared »redeclared«; - // $TEST$ unresolved + # $TEST$ unresolved »blockLambda«; - // $TEST$ unresolved + # $TEST$ unresolved »after«; }; }; val expressionLambda = () -> - // $TEST$ references before + # $TEST$ references before »before« + - // $TEST$ references redeclared + # $TEST$ references redeclared »redeclared« + - // $TEST$ unresolved + # $TEST$ unresolved »expressionLambda« + - // $TEST$ unresolved + # $TEST$ unresolved »after«; val after = 1; diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to redeclared module member/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to redeclared module member/main.sdstest index 55939d2f..5594298f 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to redeclared module member/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to redeclared module member/main.sdstest @@ -1,19 +1,19 @@ package tests.scoping.references.inSameFile.toRedeclaredModuleMember -// $TEST$ target before +# $TEST$ target before class »Before« class Before segment mySegment() { - // $TEST$ references before + # $TEST$ references before »Before«; - // $TEST$ references after + # $TEST$ references after »after«; } -// $TEST$ target after +# $TEST$ target after fun »after«() fun after() diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to results/from outside/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to results/from outside/main.sdstest index 4943e09c..686d9132 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to results/from outside/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to results/from outside/main.sdstest @@ -7,12 +7,12 @@ segment mySegment1() -> (mySegmentResult: String) {} segment mySegment2( p: () -> (myCallableTypeResult: String) ) { - // $TEST$ unresolved + # $TEST$ unresolved »myFunctionResult«; - // $TEST$ unresolved + # $TEST$ unresolved »mySegmentResult«; - // $TEST$ unresolved + # $TEST$ unresolved »myCallableTypeResult«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to results/of containing segment/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to results/of containing segment/main.sdstest index e0727091..7f000da8 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to results/of containing segment/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to results/of containing segment/main.sdstest @@ -1,6 +1,6 @@ package tests.scoping.references.inSameFile.toResults.ofContainingSegment segment mySegment() -> myResult: Int { - // $TEST$ unresolved + # $TEST$ unresolved »myResult«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to schemas/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to schemas/main.sdstest index a3832361..1b2ecb43 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to schemas/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to schemas/main.sdstest @@ -1,15 +1,15 @@ package tests.scoping.references.inSameFile.toSchemas -// $TEST$ target before +# $TEST$ target before schema »Before« {} segment mySegment() { - // $TEST$ references before + # $TEST$ references before »Before«; - // $TEST$ references after + # $TEST$ references after »After«; } -// $TEST$ target after +# $TEST$ target after schema »After« {} diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to segments/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to segments/main.sdstest index 6223ba59..1163d0f5 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to segments/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to segments/main.sdstest @@ -1,32 +1,32 @@ package tests.scoping.references.inSameFile.toSegments -// $TEST$ target privateBefore +# $TEST$ target privateBefore private segment »privateBefore«() {} -// $TEST$ target internalBefore +# $TEST$ target internalBefore internal segment »internalBefore«() {} -// $TEST$ target publicBefore +# $TEST$ target publicBefore segment »publicBefore«() {} -pipeline myPipeline { - // $TEST$ references privateBefore +function myFunction () { + # $TEST$ references privateBefore »privateBefore«(); - // $TEST$ references internalBefore + # $TEST$ references internalBefore »internalBefore«(); - // $TEST$ references publicBefore + # $TEST$ references publicBefore »publicBefore«(); - // $TEST$ references privateAfter + # $TEST$ references privateAfter »privateAfter«(); - // $TEST$ references internalAfter + # $TEST$ references internalAfter »internalAfter«(); } -// $TEST$ target privateAfter +# $TEST$ target privateAfter private segment »privateAfter«() {} -// $TEST$ target internalAfter +# $TEST$ target internalAfter internal segment »internalAfter«() {} -// $TEST$ target publicAfter +# $TEST$ target publicAfter segment »publicAfter«() {} diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to type parameters/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to type parameters/main.sdstest index 8416c939..bb071650 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to type parameters/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to type parameters/main.sdstest @@ -2,7 +2,7 @@ package tests.scoping.references.inSameFile.toTypeParameters class MyClass() -pipeline myPipeline { - // $TEST$ unresolved +function myFunction () { + # $TEST$ unresolved »T«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/unresolved/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/references/unresolved/main.sdstest index 6bb2abd3..98e4389d 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/unresolved/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/references/unresolved/main.sdstest @@ -1,6 +1,6 @@ package tests.scoping.references.unresolved segment mySegment() { - // $TEST$ unresolved + # $TEST$ unresolved »unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/scoping/type arguments/to something other than type parameter/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/type arguments/to something other than type parameter/main.sdstest index d0006b66..1b8a3ca3 100644 --- a/packages/ttsl-lang/tests/resources/scoping/type arguments/to something other than type parameter/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/type arguments/to something other than type parameter/main.sdstest @@ -1,6 +1,6 @@ package tests.scoping.typeArguments.toSomethingOtherThanTypeParameter -// $TEST$ unresolved +# $TEST$ unresolved segment mySegment(p: MyClass<»notAtypeParameter« = Int>) {} class MyClass diff --git a/packages/ttsl-lang/tests/resources/scoping/type arguments/to type parameter in containing named type declaration/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/type arguments/to type parameter in containing named type declaration/main.sdstest index fa3253f8..74f47b34 100644 --- a/packages/ttsl-lang/tests/resources/scoping/type arguments/to type parameter in containing named type declaration/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/type arguments/to type parameter in containing named type declaration/main.sdstest @@ -1,45 +1,45 @@ package tests.scoping.typeArguments.toTypeParameterInContainingNamedTypeDeclaration -// $TEST$ target outerClass +# $TEST$ target outerClass class MyClass<»T«>( - // $TEST$ references outerClass + # $TEST$ references outerClass p: MyClass<»T« = Int>, -// $TEST$ references outerClass +# $TEST$ references outerClass ) sub MyClass<»T« = Int> { - // $TEST$ references outerClass + # $TEST$ references outerClass attr a: MyClass<»T« = Int> fun f( - // $TEST$ references outerClass + # $TEST$ references outerClass p: MyClass<»T« = Int>, ) -> ( - // $TEST$ references outerClass + # $TEST$ references outerClass r: MyClass<»T« = Int>, ) enum MyEnum { MyEnumVariant( - // $TEST$ references outerClass + # $TEST$ references outerClass p: MyClass<»T« = Int>, ) } - // $TEST$ target innerClass + # $TEST$ target innerClass class MyClass<»T«>( - // $TEST$ references innerClass + # $TEST$ references innerClass p: MyClass<»T« = Int>, - // $TEST$ references innerClass + # $TEST$ references innerClass ) sub MyClass<»T« = Int> { - // $TEST$ references innerClass + # $TEST$ references innerClass attr a: MyClass<»T« = Int> fun f( - // $TEST$ references innerClass + # $TEST$ references innerClass p: MyClass<»T« = Int>, ) -> ( - // $TEST$ references innerClass + # $TEST$ references innerClass r: MyClass<»T« = Int>, ) } diff --git a/packages/ttsl-lang/tests/resources/scoping/type arguments/to type parameter in global class/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/type arguments/to type parameter in global class/main.sdstest index 5ac02bf5..8142d6d2 100644 --- a/packages/ttsl-lang/tests/resources/scoping/type arguments/to type parameter in global class/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/type arguments/to type parameter in global class/main.sdstest @@ -1,9 +1,9 @@ package tests.scoping.typeArguments.toTypeParameterInGlobalClass -// $TEST$ target t +# $TEST$ target t class MyClass<»T«> segment mySegment( - // $TEST$ references t + # $TEST$ references t p: MyClass<»T« = Int> ) {} diff --git a/packages/ttsl-lang/tests/resources/scoping/type arguments/to type parameter in nested class/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/type arguments/to type parameter in nested class/main.sdstest index 5f02c2b8..1a8674b2 100644 --- a/packages/ttsl-lang/tests/resources/scoping/type arguments/to type parameter in nested class/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/type arguments/to type parameter in nested class/main.sdstest @@ -1,11 +1,11 @@ package tests.scoping.typeArguments.toTypeParameterInNestedClass class MyClass { - // $TEST$ target t + # $TEST$ target t class MyNestedClass<»T«> } segment mySegment( - // $TEST$ references t + # $TEST$ references t p: MyClass.MyNestedClass<»T« = Int> ) {} diff --git a/packages/ttsl-lang/tests/resources/scoping/type arguments/to unresolved/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/type arguments/to unresolved/main.sdstest index 808373e7..b8bf729e 100644 --- a/packages/ttsl-lang/tests/resources/scoping/type arguments/to unresolved/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/type arguments/to unresolved/main.sdstest @@ -1,10 +1,10 @@ package tests.scoping.typeArguments.toUnresolved segment mySegment( - // $TEST$ unresolved + # $TEST$ unresolved p1: MyClass<»unresolved« = Int>, - // $TEST$ unresolved + # $TEST$ unresolved p2: unresolved<»T« = Int>, ) {} diff --git a/packages/ttsl-lang/tests/resources/scoping/yields/in pipeline/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/yields/in pipeline/main.sdstest index c43abe9d..2c130e48 100644 --- a/packages/ttsl-lang/tests/resources/scoping/yields/in pipeline/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/yields/in pipeline/main.sdstest @@ -2,17 +2,17 @@ package tests.scoping.yields.inPipeline segment mySegment1() -> before: Int {} -pipeline myPipeline { - // $TEST$ unresolved +function myFunction () { + # $TEST$ unresolved yield »before« = 1; - // $TEST$ unresolved + # $TEST$ unresolved yield »after« = 1; - // $TEST$ unresolved + # $TEST$ unresolved yield »NotAResult« = 1; - // $TEST$ unresolved + # $TEST$ unresolved yield »unresolved« = 1; } diff --git a/packages/ttsl-lang/tests/resources/scoping/yields/in segment/main.sdstest b/packages/ttsl-lang/tests/resources/scoping/yields/in segment/main.sdstest index 56b29de9..655a7b32 100644 --- a/packages/ttsl-lang/tests/resources/scoping/yields/in segment/main.sdstest +++ b/packages/ttsl-lang/tests/resources/scoping/yields/in segment/main.sdstest @@ -3,29 +3,29 @@ package tests.scoping.yields.inSegment segment mySegment1() -> before: Int {} segment mySegment() -> ( - // $TEST$ target result + # $TEST$ target result »result«: Int, - // $TEST$ target redeclared + # $TEST$ target redeclared »redeclared«: Int, redeclared: Int, ) { - // $TEST$ references result + # $TEST$ references result yield »result« = 1; - // $TEST$ references redeclared + # $TEST$ references redeclared yield »redeclared« = 1; - // $TEST$ unresolved + # $TEST$ unresolved yield »before« = 1; - // $TEST$ unresolved + # $TEST$ unresolved yield »after« = 1; - // $TEST$ unresolved + # $TEST$ unresolved yield »NotAResult« = 1; - // $TEST$ unresolved + # $TEST$ unresolved yield »unresolved« = 1; } diff --git a/packages/ttsl-lang/tests/resources/typing/assignees/block lambda results/main.sdstest b/packages/ttsl-lang/tests/resources/typing/assignees/block lambda results/main.sdstest deleted file mode 100644 index a6f46d81..00000000 --- a/packages/ttsl-lang/tests/resources/typing/assignees/block lambda results/main.sdstest +++ /dev/null @@ -1,23 +0,0 @@ -package tests.typing.assignees.blockLambdaResults - -fun f() -> (r1: Int, r2: Float, r3: String) - -segment mySegment() -> (r: Int) { - () { - // $TEST$ equivalence_class assignedValue - // $TEST$ equivalence_class assignedValue - yield »r« = »1«; - }; - - () { - // $TEST$ serialization literal<1> - // $TEST$ serialization $unknown - yield »r«, yield »s« = 1; - }; - - () { - // $TEST$ serialization Int - // $TEST$ serialization String - yield »r«, _, yield »s« = f(); - }; -} diff --git a/packages/ttsl-lang/tests/resources/typing/assignees/placeholders/main.sdstest b/packages/ttsl-lang/tests/resources/typing/assignees/placeholders/main.sdstest deleted file mode 100644 index 144cda8d..00000000 --- a/packages/ttsl-lang/tests/resources/typing/assignees/placeholders/main.sdstest +++ /dev/null @@ -1,21 +0,0 @@ -package tests.typing.assignees.placeholders - -fun f() -> (r1: Int, r2: Float, r3: String) - -segment mySegment1() -> (r: Int) { - // $TEST$ equivalence_class assignedValue - // $TEST$ equivalence_class assignedValue - val »r« = »1«; -} - -segment mySegment2() -> (r: Int, s: String) { - // $TEST$ serialization literal<1> - // $TEST$ serialization $unknown - val »r«, val »s« = 1; -} - -segment mySegment3() -> (r: Int, s: String) { - // $TEST$ serialization Int - // $TEST$ serialization String - val »r«, _, val »s« = f(); -} diff --git a/packages/ttsl-lang/tests/resources/typing/assignees/placeholders/main.ttsl b/packages/ttsl-lang/tests/resources/typing/assignees/placeholders/main.ttsl new file mode 100644 index 00000000..f6f89faf --- /dev/null +++ b/packages/ttsl-lang/tests/resources/typing/assignees/placeholders/main.ttsl @@ -0,0 +1,7 @@ +package tests.typing.assignees.placeholders + +function f1(): Int { + # $TEST$ equivalence_class assignedValue + # $TEST$ equivalence_class assignedValue + var »r« = »1«; +} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/typing/assignees/yields/main.sdstest b/packages/ttsl-lang/tests/resources/typing/assignees/yields/main.sdstest deleted file mode 100644 index b26079cd..00000000 --- a/packages/ttsl-lang/tests/resources/typing/assignees/yields/main.sdstest +++ /dev/null @@ -1,21 +0,0 @@ -package tests.typing.assignees.yields - -fun f() -> (r1: Int, r2: Float, r3: String) - -segment mySegment1() -> (r: Int) { - // $TEST$ equivalence_class assignedValue - // $TEST$ equivalence_class assignedValue - »yield r«, _ = »1«; // the wildcards prevents the marker from matching the entire assignee list -} - -segment mySegment2() -> (r: Int, s: String) { - // $TEST$ serialization literal<1> - // $TEST$ serialization $unknown - »yield r«, »yield s« = 1; -} - -segment mySegment3() -> (r: Int, s: String) { - // $TEST$ serialization Int - // $TEST$ serialization String - »yield r«, _, »yield s« = f(); -} diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/annotations/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/annotations/main.sdstest deleted file mode 100644 index d3e2a94a..00000000 --- a/packages/ttsl-lang/tests/resources/typing/declarations/annotations/main.sdstest +++ /dev/null @@ -1,10 +0,0 @@ -package tests.typing.declarations.annotations - -// $TEST$ serialization () -> () -annotation »myAnnotation1« - -// $TEST$ serialization (p1: Int, p2: String) -> () -annotation »myAnnotation3«(p1: Int, p2: String) - -// $TEST$ serialization (p1: $unknown) -> () -annotation »myAnnotation5«(p1) diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/attributes/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/attributes/main.sdstest deleted file mode 100644 index 7b10c3bc..00000000 --- a/packages/ttsl-lang/tests/resources/typing/declarations/attributes/main.sdstest +++ /dev/null @@ -1,17 +0,0 @@ -package tests.typing.declarations.attributes - -class C { - // $TEST$ serialization $unknown - attr »a« - - // $TEST$ equivalence_class instanceAttribute - // $TEST$ equivalence_class instanceAttribute - attr »b«: »Int« - - // $TEST$ serialization $unknown - static attr »c« - - // $TEST$ equivalence_class staticAttribute - // $TEST$ equivalence_class staticAttribute - static attr »d«: »Int« -} diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/classes/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/classes/main.sdstest deleted file mode 100644 index 17c8bbeb..00000000 --- a/packages/ttsl-lang/tests/resources/typing/declarations/classes/main.sdstest +++ /dev/null @@ -1,7 +0,0 @@ -package tests.typing.declarations.classes - -// $TEST$ serialization MyClass1 -class »MyClass1« - -// $TEST$ serialization MyClass2 -class »MyClass2« diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/enum variants/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/enum variants/main.sdstest deleted file mode 100644 index 1cdf36ae..00000000 --- a/packages/ttsl-lang/tests/resources/typing/declarations/enum variants/main.sdstest +++ /dev/null @@ -1,9 +0,0 @@ -package tests.typing.declarations.enumVariants - -enum MyEnum { - // $TEST$ serialization MyEnum.MyEnumVariant1 - »MyEnumVariant1« - - // $TEST$ serialization MyEnum.MyEnumVariant2 - »MyEnumVariant2« -} diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/enums/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/enums/main.sdstest deleted file mode 100644 index e1297fb1..00000000 --- a/packages/ttsl-lang/tests/resources/typing/declarations/enums/main.sdstest +++ /dev/null @@ -1,7 +0,0 @@ -package tests.typing.declarations.enums - -// $TEST$ serialization MyEnum1 -enum »MyEnum1« - -// $TEST$ serialization MyEnum2 -enum »MyEnum2« diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/functions/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/functions/main.sdstest deleted file mode 100644 index d8e86e84..00000000 --- a/packages/ttsl-lang/tests/resources/typing/declarations/functions/main.sdstest +++ /dev/null @@ -1,16 +0,0 @@ -package tests.typing.declarations.functions - -// $TEST$ serialization () -> () -fun »myFunction1«() - -// $TEST$ serialization () -> (r1: Int, r2: String) -fun »myFunction2«() -> (r1: Int, r2: String) - -// $TEST$ serialization (p1: Int, p2: String) -> () -fun »myFunction3«(p1: Int, p2: String) - -// $TEST$ serialization (p1: Int, p2: String) -> (r1: Int, r2: String) -fun »myFunction4«(p1: Int, p2: String) -> (r1: Int, r2: String) - -// $TEST$ serialization (p1: $unknown) -> (r1: $unknown) -fun »myFunction5«(p1) -> (r1) diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/functions/main.ttsl b/packages/ttsl-lang/tests/resources/typing/declarations/functions/main.ttsl new file mode 100644 index 00000000..069adbef --- /dev/null +++ b/packages/ttsl-lang/tests/resources/typing/declarations/functions/main.ttsl @@ -0,0 +1,13 @@ +package tests.typing.declarations.functions + +# $TEST$ serialization $unknown +function »myFunction1«(){} + +# $TEST$ serialization Int +function »myFunction2«(): Int {} + +# $TEST$ serialization $unknown +function »myFunction3«(p1: Int, p2: String) {} + +# $TEST$ serialization Int +function »myFunction4«(p1: Int, p2: String): Int {} diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of annotations/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of annotations/main.sdstest deleted file mode 100644 index 765e82e7..00000000 --- a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of annotations/main.sdstest +++ /dev/null @@ -1,8 +0,0 @@ -package tests.typing.declarations.parameters.ofAnnotations - -// $TEST$ equivalence_class parameterType -// $TEST$ equivalence_class parameterType -annotation MyAnnotation1(»p«: »Int«) - -// $TEST$ serialization $unknown -annotation MyAnnotation2(»p«) diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/that are isolated/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/that are isolated/main.sdstest deleted file mode 100644 index bc78c346..00000000 --- a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/that are isolated/main.sdstest +++ /dev/null @@ -1,6 +0,0 @@ -package tests.typing.declarations.parameters.ofBlockLambdas.thatAreIsolated - -segment mySegment() { - // $TEST$ serialization $unknown - (»p«) {}; -} diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/that are passed as arguments/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/that are passed as arguments/main.sdstest deleted file mode 100644 index 6acee7d5..00000000 --- a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/that are passed as arguments/main.sdstest +++ /dev/null @@ -1,26 +0,0 @@ -package tests.typing.declarations.parameters.ofBlockLambdas.thatArePassedAsArguments - -// $TEST$ equivalence_class parameterType1 -fun higherOrderFunction1(param: (a: »String«) -> ()) -fun higherOrderFunction2(param: () -> ()) -fun normalFunction(param: Int) - -segment mySegment() { - // $TEST$ equivalence_class parameterType1 - higherOrderFunction1((»p«) {}); - - // $TEST$ equivalence_class parameterType1 - higherOrderFunction1(param = (»p«) {}); - - // $TEST$ serialization $unknown - higherOrderFunction2((»p«) {}); - - // $TEST$ serialization $unknown - higherOrderFunction2(param = (»p«) {}); - - // $TEST$ serialization $unknown - normalFunction((»p«) {}); - - // $TEST$ serialization $unknown - normalFunction(param = (»p«) {}); -} diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/that are passed as default values/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/that are passed as default values/main.sdstest deleted file mode 100644 index 4cbdf821..00000000 --- a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/that are passed as default values/main.sdstest +++ /dev/null @@ -1,17 +0,0 @@ -package tests.typing.declarations.parameters.ofBlockLambdas.thatArePassedAsDefaultValues - -fun higherOrderFunction1( - // $TEST$ equivalence_class parameterType1 - // $TEST$ equivalence_class parameterType1 - param: (p: »String«) -> () = (»p«) {} -) - -fun higherOrderFunction2( - // $TEST$ serialization $unknown - param: () -> () = (»p«) {} -) - -fun normalFunction( - // $TEST$ serialization $unknown - param: Int = (»p«) {} -) diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/that are yielded/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/that are yielded/main.sdstest deleted file mode 100644 index bcb8aca8..00000000 --- a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/that are yielded/main.sdstest +++ /dev/null @@ -1,17 +0,0 @@ -package tests.typing.declarations.parameters.ofBlockLambdas.thatAreYielded - -segment mySegment() -> ( - // $TEST$ equivalence_class parameterType2 - r: (p: »String«) -> (), - s: () -> (), - t: Int, -) { - // $TEST$ equivalence_class parameterType2 - yield r = (»p«) {}; - - // $TEST$ serialization $unknown - yield s = (»p«) {}; - - // $TEST$ serialization $unknown - yield t = (»p«) {}; -} diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/with manifest types/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/with manifest types/main.sdstest deleted file mode 100644 index 4b0564d6..00000000 --- a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of block lambdas/with manifest types/main.sdstest +++ /dev/null @@ -1,7 +0,0 @@ -package tests.typing.declarations.parameters.ofBlockLambdas.withManifestTypes - -segment mySegment() { - // $TEST$ equivalence_class parameterType3 - // $TEST$ equivalence_class parameterType3 - (»p«: »Int«) {}; -} diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of callable types/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of callable types/main.sdstest deleted file mode 100644 index 17a6a703..00000000 --- a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of callable types/main.sdstest +++ /dev/null @@ -1,8 +0,0 @@ -package tests.typing.declarations.parameters.ofCallableTypes - -// $TEST$ equivalence_class parameterType -// $TEST$ equivalence_class parameterType -annotation MyAnnotation1(f: (»p«: »Int«) -> ()) - -// $TEST$ serialization $unknown -annotation MyAnnotation2(f: (»p«) -> ()) diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of classes/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of classes/main.sdstest deleted file mode 100644 index 9185e184..00000000 --- a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of classes/main.sdstest +++ /dev/null @@ -1,8 +0,0 @@ -package tests.typing.declarations.parameters.ofClasses - -// $TEST$ equivalence_class parameterType -// $TEST$ equivalence_class parameterType -class MyClass1(»p«: »Int«) - -// $TEST$ serialization $unknown -class MyClass2(»p«) diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of enum variants/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of enum variants/main.sdstest deleted file mode 100644 index 8267ac61..00000000 --- a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of enum variants/main.sdstest +++ /dev/null @@ -1,10 +0,0 @@ -package tests.typing.declarations.parameters.ofEnumVariants - -enum MyEnum { - // $TEST$ equivalence_class parameterType - // $TEST$ equivalence_class parameterType - MyEnumVariant1(»p«: »Int«) - - // $TEST$ serialization $unknown - MyEnumVariant2(»p«) -} diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/that are isolated/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/that are isolated/main.sdstest deleted file mode 100644 index 51f0a097..00000000 --- a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/that are isolated/main.sdstest +++ /dev/null @@ -1,6 +0,0 @@ -package tests.typing.declarations.parameters.ofExpressionLambdas.thatAreIsolated - -segment mySegment() { - // $TEST$ serialization $unknown - (»p«) -> 1; -} diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/that are passed as arguments/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/that are passed as arguments/main.sdstest deleted file mode 100644 index 5244fdaf..00000000 --- a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/that are passed as arguments/main.sdstest +++ /dev/null @@ -1,26 +0,0 @@ -package tests.typing.declarations.parameters.ofExpressionLambdas.thatArePassedAsArguments - -// $TEST$ equivalence_class parameterType1 -fun higherOrderFunction1(param: (a: »String«) -> r: String) -fun higherOrderFunction2(param: () -> r: String) -fun normalFunction(param: Int) - -segment mySegment() { - // $TEST$ equivalence_class parameterType1 - higherOrderFunction1((»p«) -> ""); - - // $TEST$ equivalence_class parameterType1 - higherOrderFunction1(param = (»p«) -> ""); - - // $TEST$ serialization $unknown - higherOrderFunction2((»p«) -> ""); - - // $TEST$ serialization $unknown - higherOrderFunction2(param = (»p«) -> ""); - - // $TEST$ serialization $unknown - normalFunction((»p«) -> ""); - - // $TEST$ serialization $unknown - normalFunction(param = (»p«) -> ""); -} diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/that are passed as default values/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/that are passed as default values/main.sdstest deleted file mode 100644 index 0476e790..00000000 --- a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/that are passed as default values/main.sdstest +++ /dev/null @@ -1,17 +0,0 @@ -package tests.typing.declarations.parameters.ofExpressionLambdas.thatArePassedAsArguments - -fun higherOrderFunction1( - // $TEST$ equivalence_class parameterType1 - // $TEST$ equivalence_class parameterType1 - param: (p: »String«) -> r: String = (»p«) -> "" -) - -fun higherOrderFunction2( - // $TEST$ serialization $unknown - param: () -> r: String = (»p«) -> "" -) - -fun normalFunction( - // $TEST$ serialization $unknown - param: Int = (»p«) -> "" -) diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/that are yielded/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/that are yielded/main.sdstest deleted file mode 100644 index c5da2c33..00000000 --- a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/that are yielded/main.sdstest +++ /dev/null @@ -1,17 +0,0 @@ -package tests.typing.declarations.parameters.ofExpressionLambdas.thatAreYielded - -segment mySegment() -> ( - // $TEST$ equivalence_class parameterType2 - r: (p: »String«) -> r: String, - s: () -> r: String, - t: Int, -) { - // $TEST$ equivalence_class parameterType2 - yield r = (»p«) -> true; - - // $TEST$ serialization $unknown - yield s = (»p«) -> true; - - // $TEST$ serialization $unknown - yield t = (»p«) -> true; -} diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/with manifest types/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/with manifest types/main.sdstest deleted file mode 100644 index 21689517..00000000 --- a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of expression lambdas/with manifest types/main.sdstest +++ /dev/null @@ -1,7 +0,0 @@ -package tests.typing.declarations.parameters.ofExpressionLambdas.withManifestTypes - -segment mySegment() { - // $TEST$ equivalence_class parameterType3 - // $TEST$ equivalence_class parameterType3 - (»p«: »Int«) -> 1; -} diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of functions/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of functions/main.sdstest index 854f7a2a..9d3eac6d 100644 --- a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of functions/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of functions/main.sdstest @@ -1,8 +1,8 @@ package tests.typing.declarations.parameters.ofFunctions -// $TEST$ equivalence_class parameterType -// $TEST$ equivalence_class parameterType +# $TEST$ equivalence_class parameterType +# $TEST$ equivalence_class parameterType fun myFunction1(»p«: »Int«) -// $TEST$ serialization $unknown +# $TEST$ serialization $unknown fun myFunction2(»p«) diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of segments/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of segments/main.sdstest deleted file mode 100644 index 5937cb36..00000000 --- a/packages/ttsl-lang/tests/resources/typing/declarations/parameters/of segments/main.sdstest +++ /dev/null @@ -1,8 +0,0 @@ -package tests.typing.declarations.parameters.ofSegments - -// $TEST$ equivalence_class parameterType -// $TEST$ equivalence_class parameterType -segment mySegment1(»p«: »Int«) {} - -// $TEST$ serialization $unknown -segment mySegment2(»p«) {} diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/pipelines/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/pipelines/main.sdstest deleted file mode 100644 index 51dd507d..00000000 --- a/packages/ttsl-lang/tests/resources/typing/declarations/pipelines/main.sdstest +++ /dev/null @@ -1,4 +0,0 @@ -package tests.typing.declarations.pipelines - -// $TEST$ serialization $unknown -pipeline »myPipeline« {} diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/results/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/results/main.sdstest deleted file mode 100644 index fe03bfa5..00000000 --- a/packages/ttsl-lang/tests/resources/typing/declarations/results/main.sdstest +++ /dev/null @@ -1,14 +0,0 @@ -package tests.typing.declarations.results - -// $TEST$ equivalence_class functionResult -// $TEST$ equivalence_class functionResult -fun myFun() -> (»r«: »String«) - -segment mySegment( - // $TEST$ equivalence_class callableTypeResult - // $TEST$ equivalence_class callableTypeResult - p: () -> (»r«: »String«) - -// $TEST$ equivalence_class segmentResult -// $TEST$ equivalence_class segmentResult -) -> (»r«: »String«) {} diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/results/main.ttsl b/packages/ttsl-lang/tests/resources/typing/declarations/results/main.ttsl new file mode 100644 index 00000000..de97a8fc --- /dev/null +++ b/packages/ttsl-lang/tests/resources/typing/declarations/results/main.ttsl @@ -0,0 +1,4 @@ +package tests.typing.declarations.results + +# $TEST$ equivalence_class functionResult +function myFun(): »String« {} diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/segments/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/segments/main.sdstest deleted file mode 100644 index 953e8a87..00000000 --- a/packages/ttsl-lang/tests/resources/typing/declarations/segments/main.sdstest +++ /dev/null @@ -1,16 +0,0 @@ -package tests.typing.declarations.segments - -// $TEST$ serialization () -> () -segment »mySegment1«() {} - -// $TEST$ serialization () -> (r1: Int, r2: String) -segment »mySegment2«() -> (r1: Int, r2: String) {} - -// $TEST$ serialization (p1: Int, p2: String) -> () -segment »mySegment3«(p1: Int, p2: String) {} - -// $TEST$ serialization (p1: Int, p2: String) -> (r1: Int, r2: String) -segment »mySegment4«(p1: Int, p2: String) -> (r1: Int, r2: String) {} - -// $TEST$ serialization (p1: $unknown) -> (r1: $unknown) -segment »mySegment5«(p1) -> (r1) {} diff --git a/packages/ttsl-lang/tests/resources/typing/declarations/type parameters/main.sdstest b/packages/ttsl-lang/tests/resources/typing/declarations/type parameters/main.sdstest deleted file mode 100644 index 52586950..00000000 --- a/packages/ttsl-lang/tests/resources/typing/declarations/type parameters/main.sdstest +++ /dev/null @@ -1,5 +0,0 @@ -package tests.typing.declarations.typeParameters - -// $TEST$ serialization K -// $TEST$ serialization V -class MyClass<»K«, »V«> diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/arguments/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/arguments/main.sdstest deleted file mode 100644 index 8efa9e45..00000000 --- a/packages/ttsl-lang/tests/resources/typing/expressions/arguments/main.sdstest +++ /dev/null @@ -1,40 +0,0 @@ -package tests.typing.expressions.arguments - -fun f(p: Any?) - -pipeline myPipeline { - // $TEST$ equivalence_class boolean - // $TEST$ equivalence_class boolean - // $TEST$ equivalence_class boolean - »true«; - f(»true«); - f(»p = true«); - - // $TEST$ equivalence_class float - // $TEST$ equivalence_class float - // $TEST$ equivalence_class float - »1.0«; - f(»1.0«); - f(»p = 1.0«); - - // $TEST$ equivalence_class int - // $TEST$ equivalence_class int - // $TEST$ equivalence_class int - »1«; - f(»1«); - f(»p = 1«); - - // $TEST$ equivalence_class null - // $TEST$ equivalence_class null - // $TEST$ equivalence_class null - »null«; - f(»null«); - f(»p = null«); - - // $TEST$ equivalence_class string - // $TEST$ equivalence_class string - // $TEST$ equivalence_class string - »""«; - f(»""«); - f(»p = ""«); -} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/that are isolated/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/that are isolated/main.sdstest deleted file mode 100644 index 157a8127..00000000 --- a/packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/that are isolated/main.sdstest +++ /dev/null @@ -1,15 +0,0 @@ -package tests.typing.expressions.blockLambdas.thatAreIsolated - -fun g() -> r: Int - -segment mySegment() { - // $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: $unknown) - »(p) { - yield r, yield s = 1; - }«; - - // $TEST$ serialization (p: $unknown) -> (r: Int, s: $unknown) - val f = »(p) { - yield r, yield s = g(); - }«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/that are passed as arguments/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/that are passed as arguments/main.sdstest deleted file mode 100644 index 4303239a..00000000 --- a/packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/that are passed as arguments/main.sdstest +++ /dev/null @@ -1,46 +0,0 @@ -package tests.typing.expressions.blockLambdas.thatArePassedAsArguments - -fun higherOrderFunction1(param: (p: String) -> (r: Int, s: String)) -fun higherOrderFunction2(param: () -> ()) -fun normalFunction(param: Int) -fun parameterlessFunction() - -segment mySegment() { - // $TEST$ serialization (p: String) -> (r: literal<1>, s: literal<"">) - higherOrderFunction1(»(p) { - yield r = 1; - yield s = ""; - }«); - - // $TEST$ serialization (p: String) -> (r: literal<1>, s: $unknown) - higherOrderFunction1(param = »(p) { - yield r, yield s = 1; - }«); - - // $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: literal<"">) - higherOrderFunction2(»(p) { - yield r = 1; - yield s = ""; - }«); - - // $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: $unknown) - higherOrderFunction2(param = »(p) { - yield r, yield s = 1; - }«); - - // $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: literal<"">) - normalFunction(»(p) { - yield r = 1; - yield s = ""; - }«); - - // $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: $unknown) - normalFunction(param = »(p) { - yield r, yield s = 1; - }«); - - // $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: $unknown) - parameterlessFunction(»(p) { - yield r, yield s = 1; - }«); -} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/that are passed as default values/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/that are passed as default values/main.sdstest deleted file mode 100644 index d77d639a..00000000 --- a/packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/that are passed as default values/main.sdstest +++ /dev/null @@ -1,37 +0,0 @@ -package tests.typing.expressions.blockLambdas.thatArePassedAsDefaultValues - -fun higherOrderFunction1( - // $TEST$ serialization (p: String) -> (r: literal<1>, s: literal<"">) - param1: (p: String) -> (r: Int, s: String) = »(p) { - yield r = 1; - yield s = ""; - }«, - // $TEST$ serialization (p: String) -> (r: literal<1>, s: $unknown) - param2: (p: String) -> (r: Int, s: String) = »(p) { - yield r, yield s = 1; - }«, -) - -fun higherOrderFunction2( - // $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: literal<"">) - param1: () -> () = »(p) { - yield r = 1; - yield s = ""; - }«, - // $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: $unknown) - param2: () -> () = »(p) { - yield r, yield s = 1; - }«, -) - -fun normalFunction( - // $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: literal<"">) - param1: Int = »(p) { - yield r = 1; - yield s = ""; - }«, - // $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: $unknown) - param2: Int = »(p) { - yield r, yield s = 1; - }«, -) diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/that are yielded/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/that are yielded/main.sdstest deleted file mode 100644 index 7eaf2d53..00000000 --- a/packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/that are yielded/main.sdstest +++ /dev/null @@ -1,24 +0,0 @@ -package tests.typing.expressions.blockLambdas.thatAreYielded - -segment mySegment() -> ( - r: (p: String) -> (r: Int, s: String), - s: () -> (), - t: Int, -) { - // $TEST$ serialization (p: String) -> (r: literal<1>, s: literal<"">) - yield r = »(p) { - yield r = 1; - yield s = ""; - }«; - - // $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: literal<"">) - yield s = »(p) { - yield r = 1; - yield s = ""; - }«; - - // $TEST$ serialization (p: $unknown) -> (r: literal<1>, s: $unknown) - yield t = »(p) { - yield r, yield s = 1; - }«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/with manifest types/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/with manifest types/main.sdstest deleted file mode 100644 index aa34f81a..00000000 --- a/packages/ttsl-lang/tests/resources/typing/expressions/block lambdas/with manifest types/main.sdstest +++ /dev/null @@ -1,14 +0,0 @@ -package tests.typing.expressions.blockLambdas.withManifestTypes - -segment mySegment() { - // $TEST$ serialization (p: Int) -> (r: literal<1>, s: literal<"">) - »(p: Int) { - yield r = 1; - yield s = ""; - }«; - - // $TEST$ serialization (p: String) -> (r: literal<1>, s: $unknown) - »(p: String) { - yield r, yield s = 1; - }«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of annotations/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/of annotations/main.sdstest deleted file mode 100644 index 350c95c8..00000000 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of annotations/main.sdstest +++ /dev/null @@ -1,11 +0,0 @@ -package tests.typing.expressions.calls.ofAnnotations - -annotation MyAnnotation - -pipeline myPipeline { - // $TEST$ serialization $unknown - »MyAnnotation()«; - - // $TEST$ serialization $unknown - »MyAnnotation?()«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of block lambdas/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/of block lambdas/main.sdstest deleted file mode 100644 index 264025a9..00000000 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of block lambdas/main.sdstest +++ /dev/null @@ -1,25 +0,0 @@ -package tests.typing.expressions.calls.ofBlockLambdas - -pipeline myPipeline { - // $TEST$ serialization literal<""> - »(() { - yield r = ""; - })()«; - - // $TEST$ serialization (r: literal<"">, s: literal<1>) - »(() { - yield r = ""; - yield s = 1; - })()«; - - // $TEST$ serialization literal<""> - »(() { - yield r = ""; - })?()«; - - // $TEST$ serialization (r: literal<"">, s: literal<1>) - »(() { - yield r = ""; - yield s = 1; - })?()«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of callable types/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/of callable types/main.sdstest deleted file mode 100644 index 9e8a2521..00000000 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of callable types/main.sdstest +++ /dev/null @@ -1,18 +0,0 @@ -package tests.typing.expressions.calls.ofCallableTypes - -segment mySegment( - p1: () -> r: String, - p2: () -> (r: String, s: Int) -) { - // $TEST$ serialization String - »p1()«; - - // $TEST$ serialization (r: String, s: Int) - »p2()«; - - // $TEST$ serialization String - »p1?()«; - - // $TEST$ serialization (r: String, s: Int) - »p2?()«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of classes/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/of classes/main.sdstest deleted file mode 100644 index 0e9e5bf9..00000000 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of classes/main.sdstest +++ /dev/null @@ -1,17 +0,0 @@ -package tests.typing.expressions.calls.ofClasses - -class C() - -pipeline myPipeline { - // $TEST$ serialization C - »C()«; - - // $TEST$ serialization $unknown - »C()()«; - - // $TEST$ serialization C - »C?()«; - - // $TEST$ serialization $unknown - »C?()?()«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of enum variants/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/of enum variants/main.sdstest deleted file mode 100644 index 04387c9b..00000000 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of enum variants/main.sdstest +++ /dev/null @@ -1,82 +0,0 @@ -package tests.typing.expressions.calls.ofEnumVariants - -enum MyEnum { - MyEnumVariantWithoutParameterList - MyEnumVariantWithoutParameters() - MyEnumVariantWithParameters(p: Int) -} - -pipeline myPipeline { - // $TEST$ serialization MyEnum.MyEnumVariantWithoutParameterList - »MyEnum.MyEnumVariantWithoutParameterList()«; - - // $TEST$ serialization $unknown - val alias1 = MyEnum.MyEnumVariantWithoutParameterList; - »alias1()«; - - // $TEST$ serialization MyEnum.MyEnumVariantWithoutParameters - »MyEnum.MyEnumVariantWithoutParameters()«; - - // $TEST$ serialization $unknown - val alias2 = MyEnum.MyEnumVariantWithoutParameters; - »alias2()«; - - // $TEST$ serialization $unknown - »MyEnum.MyEnumVariantWithoutParameters()()«; - - // $TEST$ serialization $unknown - val alias3 = MyEnum.MyEnumVariantWithoutParameters(); - »alias3()«; - - // $TEST$ serialization MyEnum.MyEnumVariantWithParameters - »MyEnum.MyEnumVariantWithParameters(1)«; - - // $TEST$ serialization MyEnum.MyEnumVariantWithParameters - val alias4 = MyEnum.MyEnumVariantWithParameters; - »alias4(1)«; - - // $TEST$ serialization $unknown - »MyEnum.MyEnumVariantWithParameters(1)()«; - - // $TEST$ serialization $unknown - val alias5 = MyEnum.MyEnumVariantWithParameters(1); - »alias5()«; - - - // Null-safe calls ------------------------------------------------------------------------------------------------- - - // $TEST$ serialization MyEnum.MyEnumVariantWithoutParameterList - »MyEnum.MyEnumVariantWithoutParameterList?()«; - - // $TEST$ serialization $unknown - val alias1 = MyEnum.MyEnumVariantWithoutParameterList; - »alias1?()«; - - // $TEST$ serialization MyEnum.MyEnumVariantWithoutParameters - »MyEnum.MyEnumVariantWithoutParameters?()«; - - // $TEST$ serialization $unknown - val alias2 = MyEnum.MyEnumVariantWithoutParameters; - »alias2?()«; - - // $TEST$ serialization $unknown - »MyEnum.MyEnumVariantWithoutParameters?()?()«; - - // $TEST$ serialization $unknown - val alias3 = MyEnum.MyEnumVariantWithoutParameters?(); - »alias3?()«; - - // $TEST$ serialization MyEnum.MyEnumVariantWithParameters - »MyEnum.MyEnumVariantWithParameters(1)«; - - // $TEST$ serialization MyEnum.MyEnumVariantWithParameters - val alias4 = MyEnum.MyEnumVariantWithParameters; - »alias4?(1)«; - - // $TEST$ serialization $unknown - »MyEnum.MyEnumVariantWithParameters(1)?()«; - - // $TEST$ serialization $unknown - val alias5 = MyEnum.MyEnumVariantWithParameters(1); - »alias5?()«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of expression lambdas/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/of expression lambdas/main.sdstest deleted file mode 100644 index 5c255a9f..00000000 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of expression lambdas/main.sdstest +++ /dev/null @@ -1,9 +0,0 @@ -package tests.typing.expressions.calls.ofExpressionLambdas - -pipeline myPipeline { - // $TEST$ serialization literal<1> - »(() -> 1)()«; - - // $TEST$ serialization literal<1> - »(() -> 1)?()«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of functions/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/of functions/main.sdstest deleted file mode 100644 index 2df9dfa6..00000000 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of functions/main.sdstest +++ /dev/null @@ -1,18 +0,0 @@ -package tests.typing.expressions.calls.ofFunctions - -fun f1() -> r: String -fun f2() -> (r: String, s: Int) - -pipeline myPipeline { - // $TEST$ serialization String - »f1()«; - - // $TEST$ serialization (r: String, s: Int) - »f2()«; - - // $TEST$ serialization String - »f1?()«; - - // $TEST$ serialization (r: String, s: Int) - »f2?()«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of functions/main.ttsl b/packages/ttsl-lang/tests/resources/typing/expressions/calls/of functions/main.ttsl new file mode 100644 index 00000000..042a35f6 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/typing/expressions/calls/of functions/main.ttsl @@ -0,0 +1,11 @@ +package tests.typing.expressions.calls.ofFunctions + +function f1(): String {} + +function myFunction() { + # $TEST$ serialization String + »f1()«; + + # $TEST$ serialization String + »f1?()«; +} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of non-callable/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/of non-callable/main.sdstest deleted file mode 100644 index 3948cb8f..00000000 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of non-callable/main.sdstest +++ /dev/null @@ -1,11 +0,0 @@ -package tests.typing.expressions.calls.ofNonCallables - -enum MyEnum - -pipeline myPipeline { - // $TEST$ serialization $unknown - »MyEnum()«; - - // $TEST$ serialization $unknown - »MyEnum?()«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of non-callable/main.ttsl b/packages/ttsl-lang/tests/resources/typing/expressions/calls/of non-callable/main.ttsl new file mode 100644 index 00000000..f6895c70 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/typing/expressions/calls/of non-callable/main.ttsl @@ -0,0 +1,11 @@ +package tests.typing.expressions.calls.ofNonCallables + +constant myConstant: Int = 0; + +function MyFunction() { + # $TEST$ serialization $unknown + »myConstant()«; + + # $TEST$ serialization $unknown + »myConstant?()«; +} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of nullable receiver/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/of nullable receiver/main.sdstest deleted file mode 100644 index 358ca43a..00000000 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of nullable receiver/main.sdstest +++ /dev/null @@ -1,20 +0,0 @@ -package tests.typing.expressions.calls.ofNullableReceiver - -class MyClass { - attr a: () -> r: Int - @Pure fun f() -> r: Int -} - -segment mySegment( - myClassOrNull: MyClass? -) { - // $TEST$ serialization Int - »myClassOrNull?.a()«; - // $TEST$ serialization Int - »myClassOrNull?.f()«; - - // $TEST$ serialization Int? - »myClassOrNull?.f?()«; - // $TEST$ serialization Int? - »myClassOrNull?.f?()«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of segments/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/of segments/main.sdstest deleted file mode 100644 index 713685eb..00000000 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/of segments/main.sdstest +++ /dev/null @@ -1,21 +0,0 @@ -package tests.typing.expressions.calls.ofSegments - -segment s1() -> r: String {} -segment s2() -> (r: String, s: Int) { - yield r = ""; - yield s = 1; -} - -pipeline myPipeline { - // $TEST$ serialization String - »s1()«; - - // $TEST$ serialization (r: String, s: Int) - »s2()«; - - // $TEST$ serialization String - »s1?()«; - - // $TEST$ serialization (r: String, s: Int) - »s2?()«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/clamp to upper bound/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/clamp to upper bound/main.sdstest deleted file mode 100644 index 8d16db57..00000000 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/clamp to upper bound/main.sdstest +++ /dev/null @@ -1,19 +0,0 @@ -package tests.typing.expressions.calls.typeParameterInference.clampToUpperBound - -class C1(p1: T) - -@Pure fun f1(p1: T) -> r1: T - -pipeline myPipeline { - // $TEST$ serialization C1 - »C1("")«; - - // $TEST$ serialization C1 - »C1()«; - - // $TEST$ serialization Int - »f1("")«; - - // $TEST$ serialization Int - »f1()«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/deep nesting/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/deep nesting/main.sdstest deleted file mode 100644 index 78c0bbae..00000000 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/deep nesting/main.sdstest +++ /dev/null @@ -1,40 +0,0 @@ -package tests.typing.expressions.calls.typeParameterInference.deepNesting - -class Covariant -class CovariantNumber sub Covariant -class SomeCovariant sub Covariant - -class Contravariant - -class C1(p1: Contravariant>, p2: Contravariant>) -@Pure fun f1(p1: Contravariant>, p2: Contravariant>) -> r1: T - -segment mySegment( - a1: Contravariant>, - a2: Contravariant>, - a3: Contravariant>, - a4: Contravariant, - a5: Contravariant>, -) { - // $TEST$ serialization C1 - »C1(a2, a1)«; - // $TEST$ serialization C1 - »C1(a2, a2)«; - // $TEST$ serialization C1 - »C1(a2, a3)«; - // $TEST$ serialization C1 - »C1(a2, a4)«; - // $TEST$ serialization C1 - »C1(a2, a5)«; - - // $TEST$ serialization Int - »f1(a2, a1)«; - // $TEST$ serialization Number - »f1(a2, a2)«; - // $TEST$ serialization Number - »f1(a2, a3)«; - // $TEST$ serialization Number - »f1(a2, a4)«; - // $TEST$ serialization Number - »f1(a2, a5)«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/default value of parameter/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/default value of parameter/main.sdstest deleted file mode 100644 index 55ffe280..00000000 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/default value of parameter/main.sdstest +++ /dev/null @@ -1,13 +0,0 @@ -package tests.typing.expressions.calls.typeParameterInference.defaultValueOfParameter - -class C1(p1: T = 0) - -@Pure fun f1(p1: T = 0) -> r1: T - -pipeline myPipeline { - // $TEST$ serialization C1> - »C1()«; - - // $TEST$ serialization literal<0> - »f1()«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/default value of type parameter/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/default value of type parameter/main.sdstest deleted file mode 100644 index 52921225..00000000 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/default value of type parameter/main.sdstest +++ /dev/null @@ -1,19 +0,0 @@ -package tests.typing.expressions.calls.typeParameterInference.defaultValueOfTypeParameter - -class C1() -class C2() - -@Pure fun f1() -> r1: T -@Pure fun f2() -> r1: T - -pipeline myPipeline { - // $TEST$ serialization C1 - »C1()«; - // $TEST$ serialization C2 - »C2()«; - - // $TEST$ serialization Nothing - »f1()«; - // $TEST$ serialization Int - »f2()«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/differing variance/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/differing variance/main.sdstest deleted file mode 100644 index b97517ee..00000000 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/differing variance/main.sdstest +++ /dev/null @@ -1,58 +0,0 @@ -package tests.typing.expressions.calls.typeParameterInference.differingVariance - -class Contravariant -class Invariant -class Covariant - -class C1(p1: Contravariant, p2: Invariant) -class C2(p1: Contravariant, p2: Covariant) - -@Pure fun f1(p1: Contravariant, p2: Invariant) -> r1: T -@Pure fun f2(p1: Contravariant, p3: Covariant) -> r1: T - -segment mySegment( - a1: Contravariant, - a2: Invariant, - a3: Covariant, - - b1: Contravariant, - b2: Invariant, - b3: Covariant, -) { - // $TEST$ serialization C1 - »C1(a1, a2)«; - // $TEST$ serialization C1 - »C1(a1, b2)«; - // $TEST$ serialization C1 - »C1(b1, a2)«; - // $TEST$ serialization C1 - »C1(b1, b2)«; - - // $TEST$ serialization C2 - »C2(a1, a3)«; - // $TEST$ serialization C2 - »C2(a1, b3)«; - // $TEST$ serialization C2 - »C2(b1, a3)«; - // $TEST$ serialization C2 - »C2(b1, b3)«; - - // $TEST$ serialization Nothing - »f1(a1, a2)«; - // $TEST$ serialization Nothing - »f1(a1, b2)«; - // $TEST$ serialization Number - »f1(b1, a2)«; - // $TEST$ serialization Number - »f1(b1, b2)«; - - // $TEST$ serialization Nothing - »f2(a1, a3)«; - // $TEST$ serialization Nothing - »f2(a1, b3)«; - // $TEST$ serialization Number - »f2(b1, a3)«; - // $TEST$ serialization Number - »f2(b1, b3)«; - -} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/multiple contravariant/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/multiple contravariant/main.sdstest deleted file mode 100644 index 1a0e825f..00000000 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/multiple contravariant/main.sdstest +++ /dev/null @@ -1,44 +0,0 @@ -package tests.typing.expressions.calls.typeParameterInference.multipleContravariant - -class Contravariant -class ContravariantNumber sub Contravariant -class SomeContravariant sub Contravariant - -class C1(p1: Contravariant, p2: (p1: T) -> ()) -@Pure fun f1(p1: Contravariant, p2: (p1: T) -> ()) -> r1: T - -segment mySegment( - a1: Contravariant, - a2: Contravariant, - a3: Contravariant, - a4: ContravariantNumber, - a5: SomeContravariant, - - c: (p1: Number) -> () -) { - // $TEST$ serialization C1 - »C1(a1, c)«; - // $TEST$ serialization C1 - »C1(a2, c)«; - // $TEST$ serialization C1 - »C1(a3, c)«; - // $TEST$ serialization C1 - »C1(a4, c)«; - // $TEST$ serialization C1 - »C1(a5, c)«; - // $TEST$ serialization C1 - »C1(a1, (p1) {})«; - - // $TEST$ serialization Int - »f1(a1, c)«; - // $TEST$ serialization Number - »f1(a2, c)«; - // $TEST$ serialization Number - »f1(a3, c)«; - // $TEST$ serialization Number - »f1(a4, c)«; - // $TEST$ serialization Nothing - »f1(a5, c)«; - // $TEST$ serialization Int - »f1(a1, (p1) {})«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/multiple covariant/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/multiple covariant/main.sdstest deleted file mode 100644 index c573e92d..00000000 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/multiple covariant/main.sdstest +++ /dev/null @@ -1,52 +0,0 @@ -package tests.typing.expressions.calls.typeParameterInference.multipleCovariant - -class Covariant -class CovariantNumber sub Covariant -class SomeCovariant sub Covariant - -class C1(p1: T, p2: Covariant, p3: () -> r1: T) -@Pure fun f1(p1: T, p2: Covariant, p3: () -> r1: T) -> r1: T - -class SomeClass() - -segment mySegment( - a1: Int, - a2: Number, - a3: Any?, - - b1: Covariant, - b2: CovariantNumber, - b3: SomeCovariant, - - c: () -> r1: Number -) { - // $TEST$ serialization C1 - »C1(a1, b1, c)«; - // $TEST$ serialization C1 - »C1(a2, b1, c)«; - // $TEST$ serialization C1 - »C1(a3, b1, c)«; - // $TEST$ serialization C1 - »C1(a1, b2, c)«; - // $TEST$ serialization C1 - »C1(a1, b3, c)«; - // $TEST$ serialization C1 - »C1(a1, b1, () -> "")«; - // $TEST$ serialization C1 - »C1(a1, b1, SomeClass)«; - - // $TEST$ serialization Number - »f1(a1, b1, c)«; - // $TEST$ serialization Number - »f1(a2, b1, c)«; - // $TEST$ serialization Any? - »f1(a3, b1, c)«; - // $TEST$ serialization Number - »f1(a1, b2, c)«; - // $TEST$ serialization Any? - »f1(a1, b3, c)«; - // $TEST$ serialization Any - »f1(a1, b1, () -> "")«; - // $TEST$ serialization Any - »f1(a1, b1, SomeClass)«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/single contravariant/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/single contravariant/main.sdstest deleted file mode 100644 index f6338b6e..00000000 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/single contravariant/main.sdstest +++ /dev/null @@ -1,16 +0,0 @@ -package tests.typing.expressions.calls.typeParameterInference.singleContravariant - -class Contravariant - -class C1(p1: Contravariant) -@Pure fun f1(p1: Contravariant) -> r1: T - -segment mySegment( - p1: Contravariant, -) { - // $TEST$ serialization C1 - »C1(p1)«; - - // $TEST$ serialization Int - »f1(p1)«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/single covariant/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/single covariant/main.sdstest deleted file mode 100644 index 06b195bb..00000000 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/type parameter inference/single covariant/main.sdstest +++ /dev/null @@ -1,14 +0,0 @@ -package tests.typing.expressions.calls.typeParameterInference.singleCovariant - -class C1(p1: T) -@Pure fun f1(p1: T) -> r1: T - -segment mySegment( - p1: Int, -) { - // $TEST$ serialization C1 - »C1(p1)«; - - // $TEST$ serialization Int - »f1(p1)«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/calls/unresolved/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/calls/unresolved/main.ttsl similarity index 51% rename from packages/ttsl-lang/tests/resources/typing/expressions/calls/unresolved/main.sdstest rename to packages/ttsl-lang/tests/resources/typing/expressions/calls/unresolved/main.ttsl index 4ad038be..9af6d7db 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/calls/unresolved/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/calls/unresolved/main.ttsl @@ -1,9 +1,9 @@ package tests.typing.expressions.calls.ofUnresolved -pipeline myPipeline { - // $TEST$ serialization $unknown +function myFunction() { + # $TEST$ serialization $unknown »unresolved()«; - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown »unresolved?()«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/that are isolated/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/that are isolated/main.sdstest deleted file mode 100644 index 1cca1cc2..00000000 --- a/packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/that are isolated/main.sdstest +++ /dev/null @@ -1,11 +0,0 @@ -package tests.typing.expressions.expressionLambdas.thatAreIsolated - -fun g() -> r: Int - -segment mySegment() { - // $TEST$ serialization (p: $unknown) -> (result: Int) - »(p) -> g()«; - - // $TEST$ serialization (p: $unknown) -> (result: literal<1>) - val f = »(p) -> 1«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/that are passed as arguments/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/that are passed as arguments/main.sdstest deleted file mode 100644 index 4277aabf..00000000 --- a/packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/that are passed as arguments/main.sdstest +++ /dev/null @@ -1,29 +0,0 @@ -package tests.typing.expressions.expressionLambdas.thatArePassedAsArguments - -fun higherOrderFunction1(param: (p: String) -> (r: Int)) -fun higherOrderFunction2(param: () -> ()) -fun normalFunction(param: Int) -fun parameterlessFunction() - -segment mySegment() { - // $TEST$ serialization (p: String) -> (result: literal<1>) - higherOrderFunction1(»(p) -> 1«); - - // $TEST$ serialization (p: String) -> (result: literal<1>) - higherOrderFunction1(param = »(p) -> 1«); - - // $TEST$ serialization (p: $unknown) -> (result: literal<1>) - higherOrderFunction2(»(p) -> 1«); - - // $TEST$ serialization (p: $unknown) -> (result: literal<1>) - higherOrderFunction2(param = »(p) -> 1«); - - // $TEST$ serialization (p: $unknown) -> (result: literal<1>) - normalFunction(»(p) -> 1«); - - // $TEST$ serialization (p: $unknown) -> (result: literal<1>) - normalFunction(param = »(p) -> 1«); - - // $TEST$ serialization (p: $unknown) -> (result: literal<1>) - parameterlessFunction(»(p) -> 1«); -} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/that are passed as default values/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/that are passed as default values/main.sdstest deleted file mode 100644 index 201a0594..00000000 --- a/packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/that are passed as default values/main.sdstest +++ /dev/null @@ -1,16 +0,0 @@ -package tests.typing.expressions.expressionLambdas.thatArePassedAsDefaultValues - -fun higherOrderFunction1( - // $TEST$ serialization (p: String) -> (result: literal<1>) - param: (p: String) -> (r: Int) = »(p) -> 1« -) - -fun higherOrderFunction2( - // $TEST$ serialization (p: $unknown) -> (result: literal<1>) - param: () -> () = »(p) -> 1« -) - -fun normalFunction( - // $TEST$ serialization (p: $unknown) -> (result: literal<1>) - param: Int = »(p) -> 1« -) diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/that are yielded/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/that are yielded/main.sdstest deleted file mode 100644 index c8f26c2a..00000000 --- a/packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/that are yielded/main.sdstest +++ /dev/null @@ -1,16 +0,0 @@ -package tests.typing.expressions.expressionLambdas.thatAreYielded - -segment mySegment() -> ( - r: (p: String) -> (r: Int), - s: () -> (), - t: Int, -) { - // $TEST$ serialization (p: String) -> (result: literal<1>) - yield r = »(p) -> 1«; - - // $TEST$ serialization (p: $unknown) -> (result: literal<1>) - yield s = »(p) -> 1«; - - // $TEST$ serialization (p: $unknown) -> (result: literal<1>) - yield t = »(p) -> 1«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/with manifest types/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/with manifest types/main.sdstest deleted file mode 100644 index 5ad3d084..00000000 --- a/packages/ttsl-lang/tests/resources/typing/expressions/expression lambdas/with manifest types/main.sdstest +++ /dev/null @@ -1,6 +0,0 @@ -package tests.typing.expressions.expressionLambdas.withManifestTypes - -segment mySegment() { - // $TEST$ serialization (p: Int) -> (result: literal<1>) - »(p: Int) -> 1«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on lists/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on lists/main.sdstest deleted file mode 100644 index 99e63e19..00000000 --- a/packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on lists/main.sdstest +++ /dev/null @@ -1,85 +0,0 @@ -package tests.typing.expressions.indexedAccesses.onLists - -class IntList sub List - -segment mySegment(param1: List, param2: List?, param3: IntList) { - // $TEST$ serialization Int - »param1[0]«; - - // $TEST$ serialization Int - »param1[unresolved]«; - - // $TEST$ serialization Int - »param2[0]«; - - // $TEST$ serialization Int - »param2[unresolved]«; - - // $TEST$ serialization Int - »param3[0]«; - - // $TEST$ serialization Int - »param3[unresolved]«; - - - // $TEST$ serialization Int - »param1?[0]«; - - // $TEST$ serialization Int - »param1?[unresolved]«; - - // $TEST$ serialization Int? - »param2?[0]«; - - // $TEST$ serialization Int? - »param2?[unresolved]«; - - // $TEST$ serialization Int - »param3?[0]«; - - // $TEST$ serialization Int - »param3?[unresolved]«; -} - -class MyClass, MyNullableList sub List?>( - param1: MyList, - param2: MyList?, - param3: MyNullableList, - - // $TEST$ serialization Int - p1: Any? = »param1[0]«, - - // $TEST$ serialization Int - p2: Any? = »param1[unresolved]«, - - // $TEST$ serialization Int - p3: Any? = »param2[0]«, - - // $TEST$ serialization Int - p4: Any? = »param2[unresolved]«, - - // $TEST$ serialization Int - p5: Any? = »param3[0]«, - - // $TEST$ serialization Int - p6: Any? = »param3[unresolved]«, - - - // $TEST$ serialization Int - p7: Any? = »param1?[0]«, - - // $TEST$ serialization Int - p8: Any? = »param1?[unresolved]«, - - // $TEST$ serialization Int? - p9: Any? = »param2?[0]«, - - // $TEST$ serialization Int? - p10: Any? = »param2?[unresolved]«, - - // $TEST$ serialization Int? - p11: Any? = »param3?[0]«, - - // $TEST$ serialization Int? - p12: Any? = »param3?[unresolved]«, -) diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on lists/main.ttsl b/packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on lists/main.ttsl new file mode 100644 index 00000000..1b5d5ff7 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on lists/main.ttsl @@ -0,0 +1,28 @@ +package tests.typing.expressions.indexedAccesses.onLists + +function myFunction(param1: List, param2: List?) { + # $TEST$ serialization Int + »param1[0]«; + + # $TEST$ serialization Int + »param1[unresolved]«; + + # $TEST$ serialization Int + »param2[0]«; + + # $TEST$ serialization Int + »param2[unresolved]«; + + + # $TEST$ serialization Int + »param1?[0]«; + + # $TEST$ serialization Int + »param1?[unresolved]«; + + # $TEST$ serialization Int? + »param2?[0]«; + + # $TEST$ serialization Int? + »param2?[unresolved]«; +} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on maps/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on maps/main.sdstest deleted file mode 100644 index b55e8e77..00000000 --- a/packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on maps/main.sdstest +++ /dev/null @@ -1,85 +0,0 @@ -package tests.typing.expressions.indexedAccesses.onMaps - -class MyMap sub Map - -segment mySegment(param1: Map, param2: Map?, param3: MyMap) { - // $TEST$ serialization Int - »param1[""]«; - - // $TEST$ serialization Int - »param1[unresolved]«; - - // $TEST$ serialization Int - »param2[""]«; - - // $TEST$ serialization Int - »param2[unresolved]«; - - // $TEST$ serialization Int - »param3[""]«; - - // $TEST$ serialization Int - »param3[unresolved]«; - - - // $TEST$ serialization Int - »param1?[""]«; - - // $TEST$ serialization Int - »param1?[unresolved]«; - - // $TEST$ serialization Int? - »param2?[""]«; - - // $TEST$ serialization Int? - »param2?[unresolved]«; - - // $TEST$ serialization Int - »param3?[""]«; - - // $TEST$ serialization Int - »param3?[unresolved]«; -} - -class MyClass, MyNullableMap sub Map?>( - param1: MyMap, - param2: MyMap?, - param3: MyNullableMap, - - // $TEST$ serialization Int - p1: Any? = »param1[""]«, - - // $TEST$ serialization Int - p2: Any? = »param1[unresolved]«, - - // $TEST$ serialization Int - p3: Any? = »param2[""]«, - - // $TEST$ serialization Int - p4: Any? = »param2[unresolved]«, - - // $TEST$ serialization Int - p5: Any? = »param3[""]«, - - // $TEST$ serialization Int - p6: Any? = »param3[unresolved]«, - - - // $TEST$ serialization Int - p7: Any? = »param1?[""]«, - - // $TEST$ serialization Int - p8: Any? = »param1?[unresolved]«, - - // $TEST$ serialization Int? - p9: Any? = »param2?[""]«, - - // $TEST$ serialization Int? - p10: Any? = »param2?[unresolved]«, - - // $TEST$ serialization Int? - p11: Any? = »param3?[""]«, - - // $TEST$ serialization Int? - p12: Any? = »param3?[unresolved]«, -) diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on maps/main.ttsl b/packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on maps/main.ttsl new file mode 100644 index 00000000..4514f641 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on maps/main.ttsl @@ -0,0 +1,29 @@ +package tests.typing.expressions.indexedAccesses.onMaps + + +function myFunction(param1: Map, param2: Map?) { + # $TEST$ serialization Int + »param1[""]«; + + # $TEST$ serialization Int + »param1[unresolved]«; + + # $TEST$ serialization Int + »param2[""]«; + + # $TEST$ serialization Int + »param2[unresolved]«; + + + # $TEST$ serialization Int + »param1?[""]«; + + # $TEST$ serialization Int + »param1?[unresolved]«; + + # $TEST$ serialization Int? + »param2?[""]«; + + # $TEST$ serialization Int? + »param2?[unresolved]«; +} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on other/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on other/main.sdstest deleted file mode 100644 index 12637d99..00000000 --- a/packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on other/main.sdstest +++ /dev/null @@ -1,16 +0,0 @@ -package tests.typing.expressions.indexedAccesses.onOther - -segment mySegment3(param1: String, param2: String?) { - // $TEST$ serialization $unknown - »param1[0]«; - - // $TEST$ serialization $unknown - »param2[0]«; - - - // $TEST$ serialization $unknown - »param1?[0]«; - - // $TEST$ serialization $unknown - »param2?[0]«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on unresolved/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on unresolved/main.ttsl similarity index 54% rename from packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on unresolved/main.sdstest rename to packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on unresolved/main.ttsl index 352d9f4b..288c4d29 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on unresolved/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/indexed accesses/on unresolved/main.ttsl @@ -1,9 +1,9 @@ package tests.typing.expressions.indexedAccesses.onUnresolved -segment mySegment() { - // $TEST$ serialization $unknown +function myFunction() { + # $TEST$ serialization $unknown »unresolved[0]«; - // $TEST$ serialization $unknown + # $TEST$ serialization $unknown »unresolved?[0]«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/lists/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/lists/main.sdstest deleted file mode 100644 index 270f8de3..00000000 --- a/packages/ttsl-lang/tests/resources/typing/expressions/lists/main.sdstest +++ /dev/null @@ -1,22 +0,0 @@ -package tests.typing.expressions.lists - -@Pure fun float() -> r: Float -@Pure fun string() -> r: String - -pipeline myPipeline { - - // $TEST$ serialization List - »[]«; - - // $TEST$ serialization List> - »[1, 2, 3]«; - - // $TEST$ serialization List - »[1, float(), 3]«; - - // $TEST$ serialization List - »[1, string(), 3]«; - - // $TEST$ serialization List - »[1, string(), null]«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/lists/main.ttsl b/packages/ttsl-lang/tests/resources/typing/expressions/lists/main.ttsl new file mode 100644 index 00000000..4e8fee49 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/typing/expressions/lists/main.ttsl @@ -0,0 +1,22 @@ +package tests.typing.expressions.lists + +function float(): Float +function string(): String + +function myFunction() { + + # $TEST$ serialization List + »[]«; + + # $TEST$ serialization List + »[1, 2, 3]«; + + # $TEST$ serialization List + »[1, float(), 3]«; + + # $TEST$ serialization List + »[1, string(), 3]«; + + # $TEST$ serialization List + »[1, string(), null]«; +} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/literals/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/literals/main.sdstest deleted file mode 100644 index f17a08ae..00000000 --- a/packages/ttsl-lang/tests/resources/typing/expressions/literals/main.sdstest +++ /dev/null @@ -1,19 +0,0 @@ -package tests.typing.expressions.literals - -pipeline myPipeline { - - // $TEST$ serialization literal - val booleanLiteral = »true«; - - // $TEST$ serialization literal<1.5> - val floatLiteral = »1.5«; - - // $TEST$ serialization literal<1> - val intLiteral = »1«; - - // $TEST$ serialization Nothing? - val nullLiteral = »null«; - - // $TEST$ serialization literal<"myString"> - val stringLiteral = »"myString"«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/literals/main.ttsl b/packages/ttsl-lang/tests/resources/typing/expressions/literals/main.ttsl new file mode 100644 index 00000000..22d3ab34 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/typing/expressions/literals/main.ttsl @@ -0,0 +1,19 @@ +package tests.typing.expressions.literals + +function myFunction() { + + # $TEST$ serialization Boolean + var booleanLiteral = »true«; + + # $TEST$ serialization Float + var floatLiteral = »1.5«; + + # $TEST$ serialization Int + var intLiteral = »1«; + + # $TEST$ serialization Nothing? + var nullLiteral = »null«; + + # $TEST$ serialization String + var stringLiteral = »"myString"«; +} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/maps/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/maps/main.sdstest deleted file mode 100644 index 2d055e1f..00000000 --- a/packages/ttsl-lang/tests/resources/typing/expressions/maps/main.sdstest +++ /dev/null @@ -1,25 +0,0 @@ -package tests.typing.expressions.maps - -@Pure fun float() -> r: Float -@Pure fun string() -> r: String - -pipeline myPipeline { - - // $TEST$ serialization Map - »{}«; - - // $TEST$ serialization Map> - »{1: 1, 2: 2, 3: 3}«; - - // $TEST$ serialization Map - »{1: 1, float(): float(), 3: 3}«; - - // $TEST$ serialization Map - »{1: 1, string(): string(), 3: 3}«; - - // $TEST$ serialization Map - »{1: 1, string(): string(), null: null}«; - - // $TEST$ serialization Map - »{float(): string(), 1: null}«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/maps/main.ttsl b/packages/ttsl-lang/tests/resources/typing/expressions/maps/main.ttsl new file mode 100644 index 00000000..53deaf30 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/typing/expressions/maps/main.ttsl @@ -0,0 +1,25 @@ +package tests.typing.expressions.maps + +function float(): Float +function string(): String + +function myFunction() { + + # $TEST$ serialization Map + »{}«; + + # $TEST$ serialization Map + »{1: 1, 2: 2, 3: 3}«; + + # $TEST$ serialization Map + »{1: 1, float(): float(), 3: 3}«; + + # $TEST$ serialization Map + »{1: 1, string(): string(), 3: 3}«; + + # $TEST$ serialization Map + »{1: 1, string(): string(), null: null}«; + + # $TEST$ serialization Map + »{float(): string(), 1: null}«; +} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/operations/arithmetic/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/operations/arithmetic/main.sdstest deleted file mode 100644 index 57046ac4..00000000 --- a/packages/ttsl-lang/tests/resources/typing/expressions/operations/arithmetic/main.sdstest +++ /dev/null @@ -1,154 +0,0 @@ -package tests.typing.operations.arithmetic - -fun anyInt() -> r: Int -fun anyFloat() -> r: Float - -pipeline constantOperands { - // $TEST$ serialization literal<2> - val additionIntInt = »1 + 1«; - // $TEST$ serialization literal<0> - val subtractionIntInt = »1 - 1«; - // $TEST$ serialization literal<1> - val multiplicationIntInt = »1 * 1«; - // $TEST$ serialization literal<1> - val divisionIntInt = »1 / 1«; - - // $TEST$ serialization literal<2.5> - val additionIntFloat = »1 + 1.5«; - // $TEST$ serialization literal<-0.5> - val subtractionIntFloat = »1 - 1.5«; - // $TEST$ serialization literal<1.5> - val multiplicationIntFloat = »1 * 1.5«; - // $TEST$ serialization literal<1.6> - val divisionIntFloat = »1 / 0.625«; - - // $TEST$ serialization literal<2.5> - val additionFloatInt = »1.5 + 1«; - // $TEST$ serialization literal<0.5> - val subtractionFloatInt = »1.5 - 1«; - // $TEST$ serialization literal<1.5> - val multiplicationFloatInt = »1.5 * 1«; - // $TEST$ serialization literal<1.5> - val divisionFloatInt = »1.5 / 1«; - - // $TEST$ serialization literal<2.75> - val additionFloatFloat = »1.5 + 1.25«; - // $TEST$ serialization literal<0.25> - val subtractionFloatFloat = »1.5 - 1.25«; - // $TEST$ serialization literal<1.875> - val multiplicationFloatFloat = »1.5 * 1.25«; - // $TEST$ serialization literal<0.6> - val divisionFloatFloat = »1.5 / 2.5«; - - // $TEST$ serialization literal<-1> - val negationInt = »-1«; - // $TEST$ serialization literal<-1.5> - val negationFloat = »-1.5«; -} - -pipeline invalidOperands { - // $TEST$ serialization Float - val additionInvalid = »true + true«; - // $TEST$ serialization Float - val subtractionInvalid = »true - true«; - // $TEST$ serialization Float - val multiplicationInvalid = »true * true«; - // $TEST$ serialization Float - val divisionInvalid = »true / true«; - - // $TEST$ serialization Float - val negationInvalid = »-true«; -} - -pipeline nonConstantOperands { - // $TEST$ serialization Int - val additionIntInt = »anyInt() + anyInt()«; - // $TEST$ serialization Int - val subtractionIntInt = »anyInt() - anyInt()«; - // $TEST$ serialization Int - val multiplicationIntInt = »anyInt() * anyInt()«; - // $TEST$ serialization Int - val divisionIntInt = »anyInt() / anyInt()«; - - // $TEST$ serialization Float - val additionIntFloat = »anyInt() + anyFloat()«; - // $TEST$ serialization Float - val subtractionIntFloat = »anyInt() - anyFloat()«; - // $TEST$ serialization Float - val multiplicationIntFloat = »anyInt() * anyFloat()«; - // $TEST$ serialization Float - val divisionIntFloat = »anyInt() / anyFloat()«; - - // $TEST$ serialization Float - val additionFloatInt = »anyFloat() + anyInt()«; - // $TEST$ serialization Float - val subtractionFloatInt = »anyFloat() - anyInt()«; - // $TEST$ serialization Float - val multiplicationFloatInt = »anyFloat() * anyInt()«; - // $TEST$ serialization Float - val divisionFloatInt = »anyFloat() / anyInt()«; - - // $TEST$ serialization Float - val additionFloatFloat = »anyFloat() + anyFloat()«; - // $TEST$ serialization Float - val subtractionFloatFloat = »anyFloat() - anyFloat()«; - // $TEST$ serialization Float - val multiplicationFloatFloat = »anyFloat() * anyFloat()«; - // $TEST$ serialization Float - val divisionFloatFloat = »anyFloat() / anyFloat()«; - - // $TEST$ serialization Int - val negationInt = »-anyInt()«; - // $TEST$ serialization Float - val negationFloat = »-anyFloat()«; -} - -pipeline mixedOperands { - // $TEST$ serialization Int - val additionIntInt = »10 + anyInt()«; - // $TEST$ serialization Int - val subtractionIntInt = »10 - anyInt()«; - // $TEST$ serialization Int - val multiplicationIntInt = »10 * anyInt()«; - // $TEST$ serialization Int - val divisionIntInt = »10 / anyInt()«; - - // $TEST$ serialization Float - val additionIntFloat = »10 + anyFloat()«; - // $TEST$ serialization Float - val subtractionIntFloat = »10 - anyFloat()«; - // $TEST$ serialization Float - val multiplicationIntFloat = »10 * anyFloat()«; - // $TEST$ serialization Float - val divisionIntFloat = »10 / anyFloat()«; - - // $TEST$ serialization Float - val additionFloatInt = »1.5 + anyInt()«; - // $TEST$ serialization Float - val subtractionFloatInt = »1.5 - anyInt()«; - // $TEST$ serialization Float - val multiplicationFloatInt = »1.5 * anyInt()«; - // $TEST$ serialization Float - val divisionFloatInt = »1.5 / anyInt()«; - - // $TEST$ serialization Float - val additionFloatFloat = »1.5 + anyFloat()«; - // $TEST$ serialization Float - val subtractionFloatFloat = »1.5 - anyFloat()«; - // $TEST$ serialization Float - val multiplicationFloatFloat = »1.5 * anyFloat()«; - // $TEST$ serialization Float - val divisionFloatFloat = »1.5 / anyFloat()«; -} - -// Strict checking of type parameter types -class MyClass( - p1: T, - - // $TEST$ serialization Float - p2: Any? = »p1 + 1«, - // $TEST$ serialization Float - p3: Any? = »1 + p1«, - // $TEST$ serialization Float - p4: Any? = »-p1«, -) diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/operations/arithmetic/main.ttsl b/packages/ttsl-lang/tests/resources/typing/expressions/operations/arithmetic/main.ttsl new file mode 100644 index 00000000..12972b57 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/typing/expressions/operations/arithmetic/main.ttsl @@ -0,0 +1,142 @@ +package tests.typing.operations.arithmetic + +function anyInt(): Int +function anyFloat(): Float + +function constantOperands() { + # $TEST$ serialization Int + var additionIntInt = »1 + 1«; + # $TEST$ serialization Int + var subtractionIntInt = »1 - 1«; + # $TEST$ serialization Int + var multiplicationIntInt = »1 * 1«; + # $TEST$ serialization Int + var divisionIntInt = »1 / 1«; + + # $TEST$ serialization Float + var additionIntFloat = »1 + 1.5«; + # $TEST$ serialization Float + var subtractionIntFloat = »1 - 1.5«; + # $TEST$ serialization Float + var multiplicationIntFloat = »1 * 1.5«; + # $TEST$ serialization Float + var divisionIntFloat = »1 / 0.625«; + + # $TEST$ serialization Float + var additionFloatInt = »1.5 + 1«; + # $TEST$ serialization Float + var subtractionFloatInt = »1.5 - 1«; + # $TEST$ serialization Float + var multiplicationFloatInt = »1.5 * 1«; + # $TEST$ serialization Float + var divisionFloatInt = »1.5 / 1«; + + # $TEST$ serialization Float + var additionFloatFloat = »1.5 + 1.25«; + # $TEST$ serialization Float + var subtractionFloatFloat = »1.5 - 1.25«; + # $TEST$ serialization Float + var multiplicationFloatFloat = »1.5 * 1.25«; + # $TEST$ serialization Float + var divisionFloatFloat = »1.5 / 2.5«; + + # $TEST$ serialization Int + var negationInt = »-1«; + # $TEST$ serialization Float + var negationFloat = »-1.5«; +} + +function invaridOperands() { + # $TEST$ serialization Float + var additionInvarid = »true + true«; + # $TEST$ serialization Float + var subtractionInvarid = »true - true«; + # $TEST$ serialization Float + var multiplicationInvarid = »true * true«; + # $TEST$ serialization Float + var divisionInvarid = »true / true«; + + # $TEST$ serialization Float + var negationInvarid = »-true«; +} + +function nonConstantOperands() { + # $TEST$ serialization Int + var additionIntInt = »anyInt() + anyInt()«; + # $TEST$ serialization Int + var subtractionIntInt = »anyInt() - anyInt()«; + # $TEST$ serialization Int + var multiplicationIntInt = »anyInt() * anyInt()«; + # $TEST$ serialization Int + var divisionIntInt = »anyInt() / anyInt()«; + + # $TEST$ serialization Float + var additionIntFloat = »anyInt() + anyFloat()«; + # $TEST$ serialization Float + var subtractionIntFloat = »anyInt() - anyFloat()«; + # $TEST$ serialization Float + var multiplicationIntFloat = »anyInt() * anyFloat()«; + # $TEST$ serialization Float + var divisionIntFloat = »anyInt() / anyFloat()«; + + # $TEST$ serialization Float + var additionFloatInt = »anyFloat() + anyInt()«; + # $TEST$ serialization Float + var subtractionFloatInt = »anyFloat() - anyInt()«; + # $TEST$ serialization Float + var multiplicationFloatInt = »anyFloat() * anyInt()«; + # $TEST$ serialization Float + var divisionFloatInt = »anyFloat() / anyInt()«; + + # $TEST$ serialization Float + var additionFloatFloat = »anyFloat() + anyFloat()«; + # $TEST$ serialization Float + var subtractionFloatFloat = »anyFloat() - anyFloat()«; + # $TEST$ serialization Float + var multiplicationFloatFloat = »anyFloat() * anyFloat()«; + # $TEST$ serialization Float + var divisionFloatFloat = »anyFloat() / anyFloat()«; + + # $TEST$ serialization Int + var negationInt = »-anyInt()«; + # $TEST$ serialization Float + var negationFloat = »-anyFloat()«; +} + +function mixedOperands() { + # $TEST$ serialization Int + var additionIntInt = »10 + anyInt()«; + # $TEST$ serialization Int + var subtractionIntInt = »10 - anyInt()«; + # $TEST$ serialization Int + var multiplicationIntInt = »10 * anyInt()«; + # $TEST$ serialization Int + var divisionIntInt = »10 / anyInt()«; + + # $TEST$ serialization Float + var additionIntFloat = »10 + anyFloat()«; + # $TEST$ serialization Float + var subtractionIntFloat = »10 - anyFloat()«; + # $TEST$ serialization Float + var multiplicationIntFloat = »10 * anyFloat()«; + # $TEST$ serialization Float + var divisionIntFloat = »10 / anyFloat()«; + + # $TEST$ serialization Float + var additionFloatInt = »1.5 + anyInt()«; + # $TEST$ serialization Float + var subtractionFloatInt = »1.5 - anyInt()«; + # $TEST$ serialization Float + var multiplicationFloatInt = »1.5 * anyInt()«; + # $TEST$ serialization Float + var divisionFloatInt = »1.5 / anyInt()«; + + # $TEST$ serialization Float + var additionFloatFloat = »1.5 + anyFloat()«; + # $TEST$ serialization Float + var subtractionFloatFloat = »1.5 - anyFloat()«; + # $TEST$ serialization Float + var multiplicationFloatFloat = »1.5 * anyFloat()«; + # $TEST$ serialization Float + var divisionFloatFloat = »1.5 / anyFloat()«; +} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/operations/comparison/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/operations/comparison/main.sdstest deleted file mode 100644 index 1aa39738..00000000 --- a/packages/ttsl-lang/tests/resources/typing/expressions/operations/comparison/main.sdstest +++ /dev/null @@ -1,21 +0,0 @@ -package tests.typing.operations.comparison - -pipeline myPipeline { - // $TEST$ serialization literal - val lessThan = »1 < 1«; - // $TEST$ serialization literal - val lessThanOrEquals = »1 <= 1«; - // $TEST$ serialization literal - val greaterThanOrEquals = »1 >= 1«; - // $TEST$ serialization literal - val greaterThan = »1 > 1«; - - // $TEST$ serialization Boolean - val lessThanInvalid = »true < true«; - // $TEST$ serialization Boolean - val lessThanOrEqualsInvalid = »true <= true«; - // $TEST$ serialization Boolean - val greaterThanOrEqualsInvalid = »true >= true«; - // $TEST$ serialization Boolean - val greaterThanInvalid = »true > true«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/operations/comparison/main.ttsl b/packages/ttsl-lang/tests/resources/typing/expressions/operations/comparison/main.ttsl new file mode 100644 index 00000000..0a751c77 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/typing/expressions/operations/comparison/main.ttsl @@ -0,0 +1,21 @@ +package tests.typing.operations.comparison + +function myFunction () { + # $TEST$ serialization Boolean + var lessThan = »1 < 1«; + # $TEST$ serialization Boolean + var lessThanOrEquals = »1 <= 1«; + # $TEST$ serialization Boolean + var greaterThanOrEquals = »1 >= 1«; + # $TEST$ serialization Boolean + var greaterThan = »1 > 1«; + + # $TEST$ serialization Boolean + var lessThanInvarid = »true < true«; + # $TEST$ serialization Boolean + var lessThanOrEqualsInvarid = »true <= true«; + # $TEST$ serialization Boolean + var greaterThanOrEqualsInvarid = »true >= true«; + # $TEST$ serialization Boolean + var greaterThanInvarid = »true > true«; +} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/operations/elvis/non nullable left operand.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/operations/elvis/non nullable left operand.sdstest deleted file mode 100644 index 0c69a9d1..00000000 --- a/packages/ttsl-lang/tests/resources/typing/expressions/operations/elvis/non nullable left operand.sdstest +++ /dev/null @@ -1,32 +0,0 @@ -package tests.typing.operations.elvis.nonNullableLeftOperand - -@Pure fun int() -> a: Int -@Pure fun intOrNull() -> a: Int? - -pipeline elvisWithNonNullableLeftOperand { - // $TEST$ equivalence_class leftOperand1 - »1«; - // $TEST$ equivalence_class leftOperand1 - »1 ?: intOrNull()«; - // $TEST$ equivalence_class leftOperand1 - »1 ?: 1«; - // $TEST$ equivalence_class leftOperand1 - »1 ?: 1.0«; - // $TEST$ equivalence_class leftOperand1 - »1 ?: ""«; - // $TEST$ equivalence_class leftOperand1 - »1 ?: null«; - - // $TEST$ equivalence_class leftOperand2 - »int()«; - // $TEST$ equivalence_class leftOperand2 - »int() ?: intOrNull()«; - // $TEST$ equivalence_class leftOperand2 - »int() ?: 1«; - // $TEST$ equivalence_class leftOperand2 - »int() ?: 1.0«; - // $TEST$ equivalence_class leftOperand2 - »int() ?: ""«; - // $TEST$ equivalence_class leftOperand2 - »int() ?: null«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/operations/elvis/non nullable left operand.ttsl b/packages/ttsl-lang/tests/resources/typing/expressions/operations/elvis/non nullable left operand.ttsl new file mode 100644 index 00000000..7b1e3f93 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/typing/expressions/operations/elvis/non nullable left operand.ttsl @@ -0,0 +1,32 @@ +package tests.typing.operations.elvis.nonNullableLeftOperand + +function int(): Int +function intOrNull(): Int? + +function elvisWithNonNullableLeftOperand() { + # $TEST$ equivalence_class leftOperand1 + »1«; + # $TEST$ equivalence_class leftOperand1 + »1 ?: intOrNull()«; + # $TEST$ equivalence_class leftOperand1 + »1 ?: 1«; + # $TEST$ equivalence_class leftOperand1 + »1 ?: 1.0«; + # $TEST$ equivalence_class leftOperand1 + »1 ?: ""«; + # $TEST$ equivalence_class leftOperand1 + »1 ?: null«; + + # $TEST$ equivalence_class leftOperand2 + »int()«; + # $TEST$ equivalence_class leftOperand2 + »int() ?: intOrNull()«; + # $TEST$ equivalence_class leftOperand2 + »int() ?: 1«; + # $TEST$ equivalence_class leftOperand2 + »int() ?: 1.0«; + # $TEST$ equivalence_class leftOperand2 + »int() ?: ""«; + # $TEST$ equivalence_class leftOperand2 + »int() ?: null«; +} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/operations/elvis/nullable left operand.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/operations/elvis/nullable left operand.sdstest deleted file mode 100644 index 099e092e..00000000 --- a/packages/ttsl-lang/tests/resources/typing/expressions/operations/elvis/nullable left operand.sdstest +++ /dev/null @@ -1,19 +0,0 @@ -package tests.typing.operations.elvis.nullableLeftOperand - -@Pure fun intOrNull() -> a: Int? -@Pure fun stringOrNull() -> s: String? - -pipeline elvisWithNullableLeftOperand { - // $TEST$ serialization Int? - »intOrNull() ?: intOrNull()«; - // $TEST$ serialization Int? - »intOrNull() ?: null«; - // $TEST$ serialization Int - »intOrNull() ?: 1«; - // $TEST$ serialization Number - »intOrNull() ?: 1.0«; - // $TEST$ serialization Any - »intOrNull() ?: ""«; - // $TEST$ serialization Any? - »intOrNull() ?: stringOrNull()«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/operations/elvis/nullable left operand.ttsl b/packages/ttsl-lang/tests/resources/typing/expressions/operations/elvis/nullable left operand.ttsl new file mode 100644 index 00000000..e703942b --- /dev/null +++ b/packages/ttsl-lang/tests/resources/typing/expressions/operations/elvis/nullable left operand.ttsl @@ -0,0 +1,19 @@ +package tests.typing.operations.elvis.nullableLeftOperand + +function intOrNull(): Int? +function stringOrNull(): String? + +function elvisWithNullableLeftOperand() { + # $TEST$ serialization Int? + »intOrNull() ?: intOrNull()«; + # $TEST$ serialization Int? + »intOrNull() ?: null«; + # $TEST$ serialization Int + »intOrNull() ?: 1«; + # $TEST$ serialization Any + »intOrNull() ?: 1.0«; + # $TEST$ serialization Any + »intOrNull() ?: ""«; + # $TEST$ serialization Any? + »intOrNull() ?: stringOrNull()«; +} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/operations/equality/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/operations/equality/main.sdstest deleted file mode 100644 index 6d7ffa53..00000000 --- a/packages/ttsl-lang/tests/resources/typing/expressions/operations/equality/main.sdstest +++ /dev/null @@ -1,22 +0,0 @@ -package tests.typing.operations.equality - -pipeline myPipeline { - // $TEST$ serialization literal - val equals = (»1 == 1«); - // $TEST$ serialization literal - val notEquals = (»1 != 1«); - - // $TEST$ serialization literal - val identicalTo = (»1 === 1«); - // $TEST$ serialization literal - val notIdenticalTo = (»1 !== 1«); - - // $TEST$ serialization Boolean - val nonConstantEquals = (»1 == unresolved«); - // $TEST$ serialization Boolean - val nonConstantNotEquals = (»1 != unresolved«); - // $TEST$ serialization Boolean - val nonConstantIdenticalTo = (»1 === unresolved«); - // $TEST$ serialization Boolean - val nonConstantNotIdenticalTo = (»1 !== unresolved«); -} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/operations/equality/main.ttsl b/packages/ttsl-lang/tests/resources/typing/expressions/operations/equality/main.ttsl new file mode 100644 index 00000000..cb989afe --- /dev/null +++ b/packages/ttsl-lang/tests/resources/typing/expressions/operations/equality/main.ttsl @@ -0,0 +1,22 @@ +package tests.typing.operations.equality + +function myFunction() { + # $TEST$ serialization Boolean + var equals = (»1 == 1«); + # $TEST$ serialization Boolean + var notEquals = (»1 != 1«); + + # $TEST$ serialization Boolean + var identicalTo = (»1 === 1«); + # $TEST$ serialization Boolean + var notIdenticalTo = (»1 !== 1«); + + # $TEST$ serialization Boolean + var nonConstantEquals = (»1 == unresolved«); + # $TEST$ serialization Boolean + var nonConstantNotEquals = (»1 != unresolved«); + # $TEST$ serialization Boolean + var nonConstantIdenticalTo = (»1 === unresolved«); + # $TEST$ serialization Boolean + var nonConstantNotIdenticalTo = (»1 !== unresolved«); +} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/operations/logical/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/operations/logical/main.sdstest deleted file mode 100644 index 2428e6b4..00000000 --- a/packages/ttsl-lang/tests/resources/typing/expressions/operations/logical/main.sdstest +++ /dev/null @@ -1,17 +0,0 @@ -package tests.typing.operations.logical - -pipeline myPipeline { - // $TEST$ serialization literal - val conjunction = »true and true«; - // $TEST$ serialization literal - val disjunction = »true or true«; - // $TEST$ serialization literal - val negation = »not true«; - - // $TEST$ serialization Boolean - val conjunctionInvalid = »1 and 1«; - // $TEST$ serialization Boolean - val disjunctionInvalid = »1.0 or 1.0«; - // $TEST$ serialization Boolean - val negationInvalid = »not "true"«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/operations/logical/main.ttsl b/packages/ttsl-lang/tests/resources/typing/expressions/operations/logical/main.ttsl new file mode 100644 index 00000000..e4e70404 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/typing/expressions/operations/logical/main.ttsl @@ -0,0 +1,17 @@ +package tests.typing.operations.logical + +function myFunction() { + # $TEST$ serialization Boolean + var conjunction = »true and true«; + # $TEST$ serialization Boolean + var disjunction = »true or true«; + # $TEST$ serialization Boolean + var negation = »not true«; + + # $TEST$ serialization Boolean + var conjunctionInvarid = »1 and 1«; + # $TEST$ serialization Boolean + var disjunctionInvarid = »1.0 or 1.0«; + # $TEST$ serialization Boolean + var negationInvarid = »not "true"«; +} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/parenthesized expressions/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/parenthesized expressions/main.sdstest deleted file mode 100644 index 7695ced7..00000000 --- a/packages/ttsl-lang/tests/resources/typing/expressions/parenthesized expressions/main.sdstest +++ /dev/null @@ -1,23 +0,0 @@ -package tests.typing.expressions.parenthesizedExpressions - -pipeline myPipeline { - // $TEST$ equivalence_class boolean - // $TEST$ equivalence_class boolean - »(»true«)«; - - // $TEST$ equivalence_class float - // $TEST$ equivalence_class float - »(»1.0«)«; - - // $TEST$ equivalence_class int - // $TEST$ equivalence_class int - »(»1«)«; - - // $TEST$ equivalence_class null - // $TEST$ equivalence_class null - »(»null«)«; - - // $TEST$ equivalence_class string - // $TEST$ equivalence_class string - »(»""«)«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/references/to global classes/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/references/to global classes/main.sdstest deleted file mode 100644 index 1d2be92c..00000000 --- a/packages/ttsl-lang/tests/resources/typing/expressions/references/to global classes/main.sdstest +++ /dev/null @@ -1,8 +0,0 @@ -package tests.typing.expressions.references.toGlobalClasses - -class MyClass - -pipeline myPipeline { - // $TEST$ serialization $type - »MyClass«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/references/to global enums/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/references/to global enums/main.sdstest deleted file mode 100644 index 03b51756..00000000 --- a/packages/ttsl-lang/tests/resources/typing/expressions/references/to global enums/main.sdstest +++ /dev/null @@ -1,8 +0,0 @@ -package tests.typing.expressions.references.toGlobalEnums - -enum MyEnum - -pipeline myPipeline { - // $TEST$ serialization $type - »MyEnum«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/references/to other/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/references/to other/main.sdstest deleted file mode 100644 index e284e171..00000000 --- a/packages/ttsl-lang/tests/resources/typing/expressions/references/to other/main.sdstest +++ /dev/null @@ -1,13 +0,0 @@ -package tests.typing.expressions.references.toOther - -segment mySegment( - // $TEST$ equivalence_class p1 - »p1«: Int, - // $TEST$ equivalence_class p2 - »p2«: String -) { - // $TEST$ equivalence_class p1 - »p1«; - // $TEST$ equivalence_class p2 - »p2«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/references/to other/main.ttsl b/packages/ttsl-lang/tests/resources/typing/expressions/references/to other/main.ttsl new file mode 100644 index 00000000..f47884b6 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/typing/expressions/references/to other/main.ttsl @@ -0,0 +1,13 @@ +package tests.typing.expressions.references.toOther + +function myFunction( + # $TEST$ equivalence_class p1 + »p1«: Int, + # $TEST$ equivalence_class p2 + »p2«: String +) { + # $TEST$ equivalence_class p1 + »p1«; + # $TEST$ equivalence_class p2 + »p2«; +} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/references/unresolved/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/references/unresolved/main.ttsl similarity index 56% rename from packages/ttsl-lang/tests/resources/typing/expressions/references/unresolved/main.sdstest rename to packages/ttsl-lang/tests/resources/typing/expressions/references/unresolved/main.ttsl index a14b2c6e..bad84891 100644 --- a/packages/ttsl-lang/tests/resources/typing/expressions/references/unresolved/main.sdstest +++ b/packages/ttsl-lang/tests/resources/typing/expressions/references/unresolved/main.ttsl @@ -1,6 +1,6 @@ package tests.typing.expressions.references.unresolved -pipeline myPipeline { - // $TEST$ serialization $unknown +function myFunction() { + # $TEST$ serialization $unknown »unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/template strings/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/template strings/main.sdstest deleted file mode 100644 index bf878f09..00000000 --- a/packages/ttsl-lang/tests/resources/typing/expressions/template strings/main.sdstest +++ /dev/null @@ -1,9 +0,0 @@ -package tests.typing.expressions.templateStrings - -pipeline myPipeline { - // $TEST$ serialization literal<"1 + 2 = 3"> - val valid = »"1 + 2 = {{ 1 + 2 }}"«; - - // $TEST$ serialization String - val invalid = »"1 + 2 = {{ unresolved }}"«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/template strings/main.ttsl b/packages/ttsl-lang/tests/resources/typing/expressions/template strings/main.ttsl new file mode 100644 index 00000000..0075cb64 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/typing/expressions/template strings/main.ttsl @@ -0,0 +1,9 @@ +package tests.typing.expressions.templateStrings + +function myFunction() { + # $TEST$ serialization String + var valid = »"1 + 2 = {{ 1 + 2 }}"«; + + # $TEST$ serialization String + var invalid = »"1 + 2 = {{ unresolved }}"«; +} diff --git a/packages/ttsl-lang/tests/resources/typing/expressions/type casts/main.sdstest b/packages/ttsl-lang/tests/resources/typing/expressions/type casts/main.sdstest deleted file mode 100644 index aee79776..00000000 --- a/packages/ttsl-lang/tests/resources/typing/expressions/type casts/main.sdstest +++ /dev/null @@ -1,14 +0,0 @@ -package tests.typing.expressions.typeCasts - -@Pure fun f() -> r: Int - -pipeline myPipeline { - // $TEST$ serialization Boolean - »1 as Boolean«; // Partial evaluator can handle expression - - // $TEST$ serialization Boolean - »r as Boolean«; // Partial evaluator cannot handle expression - - // $TEST$ serialization Boolean - »unresolved as Boolean«; // Expression has unknown type -} diff --git a/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and class type/cannot stop if class has no type parameters.sdstest b/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and class type/cannot stop if class has no type parameters.sdstest deleted file mode 100644 index 5743b68c..00000000 --- a/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and class type/cannot stop if class has no type parameters.sdstest +++ /dev/null @@ -1,14 +0,0 @@ -package tests.typing.highestCommonSubtype.classTypeAndClassType.cannotStopIfClassHasNoTypeParameters - -class Contravariant - -class C -class D sub C - -segment mySegment( - p1: Contravariant>, - p2: Contravariant, -) { - // $TEST$ serialization List> - »[p1, p2]«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and class type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and class type/main.sdstest deleted file mode 100644 index 0282a7a4..00000000 --- a/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and class type/main.sdstest +++ /dev/null @@ -1,42 +0,0 @@ -package tests.typing.highestCommonSubtype.classTypeAndClassType - -class Contravariant - -class C -class D sub C -class E - -segment mySegment1( - c: Contravariant, - cOrNull: Contravariant, - - d: Contravariant, - dOrNull: Contravariant, - - e: Contravariant, - eOrNull: Contravariant, -) { - // $TEST$ serialization List> - »[c, c]«; - // $TEST$ serialization List> - »[c, cOrNull]«; - // $TEST$ serialization List> - »[c, d]«; - // $TEST$ serialization List> - »[c, dOrNull]«; - // $TEST$ serialization List> - »[c, e]«; - // $TEST$ serialization List> - »[c, eOrNull]«; - - // $TEST$ serialization List> - »[cOrNull, cOrNull]«; - // $TEST$ serialization List> - »[cOrNull, d]«; - // $TEST$ serialization List> - »[cOrNull, dOrNull]«; - // $TEST$ serialization List> - »[cOrNull, e]«; - // $TEST$ serialization List> - »[cOrNull, eOrNull]«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and class type/with type parameters.sdstest b/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and class type/with type parameters.sdstest deleted file mode 100644 index f67c8743..00000000 --- a/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and class type/with type parameters.sdstest +++ /dev/null @@ -1,122 +0,0 @@ -package tests.typing.highestCommonSubtype.classTypeAndClassType.withTypeParameters - -class Covariant -class FloatCovariant sub Covariant -class SomeCovariant sub Covariant - -segment covariant( - coNumber: Contravariant>, - coInt: Contravariant>, - coString: Contravariant>, - coFloat: Contravariant, - coFloat2: Contravariant>, -) { - // $TEST$ serialization List>> - »[coNumber, coNumber]«; - // $TEST$ serialization List>> - »[coNumber, coInt]«; - // $TEST$ serialization List>> - »[coNumber, coString]«; - // $TEST$ serialization List> - »[coNumber, coFloat]«; - // $TEST$ serialization List>> - »[coNumber, coFloat2]«; - - // $TEST$ serialization List>> - »[coInt, coInt]«; - // $TEST$ serialization List>> - »[coInt, coString]«; - // $TEST$ serialization List> - »[coInt, coFloat]«; - // $TEST$ serialization List>> - »[coInt, coFloat2]«; - - // $TEST$ serialization List>> - »[coString, coString]«; - // $TEST$ serialization List> - »[coString, coFloat]«; - // $TEST$ serialization List>> - »[coString, coFloat2]«; - - // $TEST$ serialization List> - »[coFloat, coFloat]«; - // $TEST$ serialization List> - »[coFloat, coFloat2]«; - - // $TEST$ serialization List>> - »[coFloat2, coFloat2]«; -} - -class Contravariant - -segment contravariant( - contraFloat: Contravariant>, - contraInt: Contravariant>, -) { - // Most tests are in the "lowest common supertype" folder. Here we only test that we call the right method. - - // $TEST$ serialization List>> - »[contraFloat, contraInt]«; -} - -class Invariant -class IntInvariant sub Invariant -class SomeInvariant sub Invariant - -segment invariant( - invNumber: Contravariant>, - invInt: Contravariant>, - invString: Contravariant>, - invInt2: Contravariant, - invInt3: Contravariant>, -) { - // $TEST$ serialization List>> - »[invNumber, invNumber]«; - // $TEST$ serialization List> - »[invNumber, invInt]«; - // $TEST$ serialization List> - »[invNumber, invString]«; - // $TEST$ serialization List> - »[invNumber, invInt2]«; - // $TEST$ serialization List> - »[invNumber, invInt3]«; - - // $TEST$ serialization List>> - »[invInt, invInt]«; - // $TEST$ serialization List> - »[invInt, invString]«; - // $TEST$ serialization List> - »[invInt, invInt2]«; - // $TEST$ serialization List>> - »[invInt, invInt3]«; - - // $TEST$ serialization List>> - »[invString, invString]«; - // $TEST$ serialization List> - »[invString, invInt2]«; - // $TEST$ serialization List> - »[invString, invInt3]«; - - // $TEST$ serialization List> - »[invInt2, invInt2]«; - // $TEST$ serialization List> - »[invInt2, invInt3]«; - - // $TEST$ serialization List>> - »[invInt3, invInt3]«; -} - -class Multiple - -segment multiple( - multipleNumberNumber: Contravariant>, - multipleNumberFloat: Contravariant>, -) { - // $TEST$ serialization List>> - »[multipleNumberNumber, multipleNumberNumber]«; - // $TEST$ serialization List>> - »[multipleNumberNumber, multipleNumberFloat]«; - - // $TEST$ serialization List>> - »[multipleNumberFloat, multipleNumberFloat]«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and enum type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and enum type/main.sdstest deleted file mode 100644 index a36b52cc..00000000 --- a/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and enum type/main.sdstest +++ /dev/null @@ -1,34 +0,0 @@ -package tests.typing.highestCommonSubtype.classTypeAndEnumType - -class Contravariant - -class C -enum E - -segment mySegment( - any: Contravariant, - anyOrNull: Contravariant, - c: Contravariant, - cOrNull: Contravariant, - - e: Contravariant, - eOrNull: Contravariant, -) { - // $TEST$ serialization List> - »[any, e]«; - // $TEST$ serialization List> - »[anyOrNull, e]«; - // $TEST$ serialization List> - »[any, eOrNull]«; - // $TEST$ serialization List> - »[anyOrNull, eOrNull]«; - - // $TEST$ serialization List> - »[c, e]«; - // $TEST$ serialization List> - »[cOrNull, e]«; - // $TEST$ serialization List> - »[c, eOrNull]«; - // $TEST$ serialization List> - »[cOrNull, eOrNull]«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and enum variant/main.sdstest b/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and enum variant/main.sdstest deleted file mode 100644 index f7ff7cc1..00000000 --- a/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and enum variant/main.sdstest +++ /dev/null @@ -1,36 +0,0 @@ -package tests.typing.highestCommonSubtype.classTypeAndEnumVariantType - -class Contravariant - -class C -enum E { - V -} - -segment mySegment( - any: Contravariant, - anyOrNull: Contravariant, - c: Contravariant, - cOrNull: Contravariant, - - v: Contravariant, - vOrNull: Contravariant, -) { - // $TEST$ serialization List> - »[any, v]«; - // $TEST$ serialization List> - »[anyOrNull, v]«; - // $TEST$ serialization List> - »[any, vOrNull]«; - // $TEST$ serialization List> - »[anyOrNull, vOrNull]«; - - // $TEST$ serialization List> - »[c, v]«; - // $TEST$ serialization List> - »[cOrNull, v]«; - // $TEST$ serialization List> - »[c, vOrNull]«; - // $TEST$ serialization List> - »[cOrNull, vOrNull]«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and literal type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and literal type/main.sdstest deleted file mode 100644 index c228385c..00000000 --- a/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and literal type/main.sdstest +++ /dev/null @@ -1,70 +0,0 @@ -package tests.typing.highestCommonSubtype.classTypeAndLiteralType - -class Contravariant - -class C - -segment mySegment( - one: Contravariant>, - oneOrNull: Contravariant>, - - c: Contravariant, - cOrNull: Contravariant, - int: Contravariant, - intOrNull: Contravariant, - number: Contravariant, - numberOrNull: Contravariant, - string: Contravariant, - stringOrNull: Contravariant, - nothing: Contravariant, - nothingOrNull: Contravariant, -) { - // $TEST$ serialization List> - »[one, c]«; - - // $TEST$ serialization List> - »[one, cOrNull]«; - - // $TEST$ serialization List> - »[oneOrNull, cOrNull]«; - - - // $TEST$ serialization List>> - »[one, int]«; - - // $TEST$ serialization List>> - »[one, intOrNull]«; - - // $TEST$ serialization List>> - »[oneOrNull, intOrNull]«; - - - // $TEST$ serialization List>> - »[one, number]«; - - // $TEST$ serialization List>> - »[one, numberOrNull]«; - - // $TEST$ serialization List>> - »[oneOrNull, numberOrNull]«; - - - // $TEST$ serialization List> - »[one, string]«; - - // $TEST$ serialization List> - »[one, stringOrNull]«; - - // $TEST$ serialization List> - »[oneOrNull, stringOrNull]«; - - - // $TEST$ serialization List> - »[one, nothing]«; - - // $TEST$ serialization List> - »[one, nothingOrNull]«; - - // $TEST$ serialization List> - »[oneOrNull, nothingOrNull]«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and type parameter type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and type parameter type/main.sdstest deleted file mode 100644 index 9586a80c..00000000 --- a/packages/ttsl-lang/tests/resources/typing/highest common subtype/class type and type parameter type/main.sdstest +++ /dev/null @@ -1,50 +0,0 @@ -package tests.typing.highestCommonSubtype.classTypeAndTypeParameterType - -class Contravariant - -class C -class D sub C -class E - -class Test< - ToAnyOrNull, - ToC sub C, - ToD sub D, - ToE sub E, ->( - c: Contravariant, - cOrNull: Contravariant, - - toAnyOrNull: Contravariant, - toAnyOrNullExplicit: Contravariant, - toC: Contravariant, - toD: Contravariant, - toDOrNullExplicit: Contravariant, - toE: Contravariant, - - // $TEST$ serialization List> - a1: Any = »[c, toAnyOrNull]«, - // $TEST$ serialization List> - a2: Any = »[c, toAnyOrNullExplicit]«, - // $TEST$ serialization List> - a3: Any = »[c, toC]«, - // $TEST$ serialization List> - a4: Any = »[c, toD]«, - // $TEST$ serialization List> - a5: Any = »[c, toDOrNullExplicit]«, - // $TEST$ serialization List> - a6: Any = »[c, toE]«, - - // $TEST$ serialization List> - b1: Any = »[cOrNull, toAnyOrNull]«, - // $TEST$ serialization List> - b2: Any = »[cOrNull, toAnyOrNullExplicit]«, - // $TEST$ serialization List> - b3: Any = »[cOrNull, toC]«, - // $TEST$ serialization List> - b4: Any = »[cOrNull, toD]«, - // $TEST$ serialization List> - b5: Any = »[cOrNull, toDOrNullExplicit]«, - // $TEST$ serialization List> - b6: Any = »[cOrNull, toE]«, -) diff --git a/packages/ttsl-lang/tests/resources/typing/highest common subtype/enum type and enum type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/highest common subtype/enum type and enum type/main.sdstest deleted file mode 100644 index c2d540b2..00000000 --- a/packages/ttsl-lang/tests/resources/typing/highest common subtype/enum type and enum type/main.sdstest +++ /dev/null @@ -1,32 +0,0 @@ -package tests.typing.highestCommonSubtype.enumTypeAndEnumType - -class Contravariant - -enum E1 -enum E2 - -segment mySegment( - e1: Contravariant, - e1OrNull: Contravariant, - e2: Contravariant, - e2OrNull: Contravariant -) { - // $TEST$ serialization List> - »[e1, e1]«; - - // $TEST$ serialization List> - »[e1, e1OrNull]«; - - // $TEST$ serialization List> - »[e1OrNull, e1OrNull]«; - - - // $TEST$ serialization List> - »[e1, e2]«; - - // $TEST$ serialization List> - »[e1, e2OrNull]«; - - // $TEST$ serialization List> - »[e1OrNull, e2OrNull]«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/highest common subtype/enum type and enum variant type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/highest common subtype/enum type and enum variant type/main.sdstest deleted file mode 100644 index 459b2b93..00000000 --- a/packages/ttsl-lang/tests/resources/typing/highest common subtype/enum type and enum variant type/main.sdstest +++ /dev/null @@ -1,38 +0,0 @@ -package tests.typing.highestCommonSubtype.enumTypeAndEnumVariantType - -class Contravariant - -enum E1 { - V1 -} -enum E2 { - V2 -} - -segment mySegment( - e1: Contravariant, - e1OrNull: Contravariant, - v1: Contravariant, - v1OrNull: Contravariant, - v2: Contravariant, - v2OrNull: Contravariant, -) { - // $TEST$ serialization List> - »[e1, v1]«; - - // $TEST$ serialization List> - »[e1, v1OrNull]«; - - // $TEST$ serialization List> - »[e1OrNull, v1OrNull]«; - - - // $TEST$ serialization List> - »[e1, v2]«; - - // $TEST$ serialization List> - »[e1, v2OrNull]«; - - // $TEST$ serialization List> - »[e1OrNull, v2OrNull]«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/highest common subtype/enum type and type parameter type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/highest common subtype/enum type and type parameter type/main.sdstest deleted file mode 100644 index 852368bf..00000000 --- a/packages/ttsl-lang/tests/resources/typing/highest common subtype/enum type and type parameter type/main.sdstest +++ /dev/null @@ -1,52 +0,0 @@ -package tests.typing.highestCommonSubtype.enumTypeAndTypeParameterType - -class Contravariant - -enum E { - V -} - -enum F - -class Test< - ToAnyOrNull, - ToE sub E, - ToV sub E.V, - ToF sub F ->( - e: Contravariant, - eOrNull: Contravariant, - - toAnyOrNull: Contravariant, - toAnyOrNullExplicit: Contravariant, - toE: Contravariant, - toV: Contravariant, - toVOrNullExplicit: Contravariant, - toF: Contravariant, - - // $TEST$ serialization List> - a1: Any = »[e, toAnyOrNull]«, - // $TEST$ serialization List> - a2: Any = »[e, toAnyOrNullExplicit]«, - // $TEST$ serialization List> - a3: Any = »[e, toE]«, - // $TEST$ serialization List> - a4: Any = »[e, toV]«, - // $TEST$ serialization List> - a5: Any = »[e, toVOrNullExplicit]«, - // $TEST$ serialization List> - a6: Any = »[e, toF]«, - - // $TEST$ serialization List> - b1: Any = »[eOrNull, toAnyOrNull]«, - // $TEST$ serialization List> - b2: Any = »[eOrNull, toAnyOrNullExplicit]«, - // $TEST$ serialization List> - b3: Any = »[eOrNull, toE]«, - // $TEST$ serialization List> - b4: Any = »[eOrNull, toV]«, - // $TEST$ serialization List> - b5: Any = »[eOrNull, toVOrNullExplicit]«, - // $TEST$ serialization List> - b6: Any = »[eOrNull, toF]«, -) diff --git a/packages/ttsl-lang/tests/resources/typing/highest common subtype/enum variant type and enum variant type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/highest common subtype/enum variant type and enum variant type/main.sdstest deleted file mode 100644 index 33c9919e..00000000 --- a/packages/ttsl-lang/tests/resources/typing/highest common subtype/enum variant type and enum variant type/main.sdstest +++ /dev/null @@ -1,49 +0,0 @@ -package tests.typing.highestCommonSubtype.enumVariantTypeAndEnumVariantType - -class Contravariant - -enum E1 { - V1 - V2 -} -enum E3 { - V3 -} - -segment mySegment( - v1: Contravariant, - v1OrNull: Contravariant, - v2: Contravariant, - v2OrNull: Contravariant, - v3: Contravariant, - v3OrNull: Contravariant -) { - // $TEST$ serialization List> - »[v1, v1]«; - - // $TEST$ serialization List> - »[v1, v1OrNull]«; - - // $TEST$ serialization List> - »[v1OrNull, v1OrNull]«; - - - // $TEST$ serialization List> - »[v1, v2]«; - - // $TEST$ serialization List> - »[v1, v2OrNull]«; - - // $TEST$ serialization List> - »[v1OrNull, v2OrNull]«; - - - // $TEST$ serialization List> - »[v1, v3]«; - - // $TEST$ serialization List> - »[v1, v3OrNull]«; - - // $TEST$ serialization List> - »[v1OrNull, v3OrNull]«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/highest common subtype/enum variant type and type parameter type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/highest common subtype/enum variant type and type parameter type/main.sdstest deleted file mode 100644 index 82b1ef21..00000000 --- a/packages/ttsl-lang/tests/resources/typing/highest common subtype/enum variant type and type parameter type/main.sdstest +++ /dev/null @@ -1,45 +0,0 @@ -package tests.typing.highestCommonSubtype.enumVariantTypeAndTypeParameterType - -class Contravariant - -enum E { - V1 - V2 -} - -class Test< - ToAnyOrNull, - ToV1 sub E.V1, - ToV2 sub E.V2 ->( - v1: Contravariant, - v1OrNull: Contravariant, - - toAnyOrNull: Contravariant, - toAnyOrNullExplicit: Contravariant, - toV1: Contravariant, - toV1OrNullExplicit: Contravariant, - toV2: Contravariant, - - // $TEST$ serialization List> - a1: Any = »[v1, toAnyOrNull]«, - // $TEST$ serialization List> - a2: Any = »[v1, toAnyOrNullExplicit]«, - // $TEST$ serialization List> - a3: Any = »[v1, toV1]«, - // $TEST$ serialization List> - a4: Any = »[v1, toV1OrNullExplicit]«, - // $TEST$ serialization List> - a5: Any = »[v1, toV2]«, - - // $TEST$ serialization List> - b1: Any = »[v1OrNull, toAnyOrNull]«, - // $TEST$ serialization List> - b2: Any = »[v1OrNull, toAnyOrNullExplicit]«, - // $TEST$ serialization List> - b3: Any = »[v1OrNull, toV1]«, - // $TEST$ serialization List> - b4: Any = »[v1OrNull, toV1OrNullExplicit]«, - // $TEST$ serialization List> - b5: Any = »[v1OrNull, toV2]«, -) diff --git a/packages/ttsl-lang/tests/resources/typing/highest common subtype/incompatible types/main.sdstest b/packages/ttsl-lang/tests/resources/typing/highest common subtype/incompatible types/main.sdstest deleted file mode 100644 index 870a0a6f..00000000 --- a/packages/ttsl-lang/tests/resources/typing/highest common subtype/incompatible types/main.sdstest +++ /dev/null @@ -1,56 +0,0 @@ -package tests.typing.highestCommonSubtype.incompatibleTypes - -class Contravariant - -enum E { - V -} - -segment mySegment( - one: Contravariant>, - oneOrNull: Contravariant>, - - e: Contravariant, - eOrNull: Contravariant, - - v: Contravariant, - vOrNull: Contravariant -) { - // $TEST$ serialization List> - »[one, e]«; - // $TEST$ serialization List> - »[oneOrNull, e]«; - - // $TEST$ serialization List> - »[one, eOrNull]«; - // $TEST$ serialization List> - »[oneOrNull, eOrNull]«; - - // $TEST$ serialization List> - »[one, v]«; - // $TEST$ serialization List> - »[oneOrNull, v]«; - - // $TEST$ serialization List> - »[one, vOrNull]«; - // $TEST$ serialization List> - »[oneOrNull, vOrNull]«; -} - -class Test( - one: Contravariant>, - oneOrNull: Contravariant>, - - t: Contravariant, - tOrNull: Contravariant, - - // $TEST$ serialization List> - p1: Any = »[one, t]«, - // $TEST$ serialization List> - p2: Any = »[one, tOrNull]«, - - // $TEST$ serialization List> - p3: Any = »[oneOrNull, t]«, - // $TEST$ serialization List> - p4: Any = »[oneOrNull, tOrNull]« -) diff --git a/packages/ttsl-lang/tests/resources/typing/highest common subtype/literal type and literal type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/highest common subtype/literal type and literal type/main.sdstest deleted file mode 100644 index 01be3a8c..00000000 --- a/packages/ttsl-lang/tests/resources/typing/highest common subtype/literal type and literal type/main.sdstest +++ /dev/null @@ -1,18 +0,0 @@ -package tests.typing.highestCommonSubtype.literalTypeAndLiteralType - -class Contravariant - -segment mySegment( - p1: Contravariant>, - p2: Contravariant>, - p3: Contravariant>, -) { - // $TEST$ serialization List>> - »[p1, p1]«; - - // $TEST$ serialization List>> - »[p1, p2]«; - - // $TEST$ serialization List> - »[p1, p3]«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/highest common subtype/simplification/main.sdstest b/packages/ttsl-lang/tests/resources/typing/highest common subtype/simplification/main.sdstest deleted file mode 100644 index 8afda84c..00000000 --- a/packages/ttsl-lang/tests/resources/typing/highest common subtype/simplification/main.sdstest +++ /dev/null @@ -1,21 +0,0 @@ -package tests.typing.highestCommonSubtype.simplification - -class Contravariant - -segment mySegment( - p1: Contravariant>, - p2: Contravariant>, - p3: Contravariant, literal>>, -) { - // $TEST$ serialization List> - »[p1, p2]«; - - // $TEST$ serialization List> - »[p1, p3]«; - - // $TEST$ serialization List> - »[p2, p3]«; - - // $TEST$ serialization List> - »[p3, p3]«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/highest common subtype/type parameter type and type parameter type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/highest common subtype/type parameter type and type parameter type/main.sdstest deleted file mode 100644 index 829c20a9..00000000 --- a/packages/ttsl-lang/tests/resources/typing/highest common subtype/type parameter type and type parameter type/main.sdstest +++ /dev/null @@ -1,26 +0,0 @@ -package tests.typing.highestCommonSubtype.typeParameterTypeAndTypeParameterType - -class Contravariant - -class Test( - t1: Contravariant, - t1OrNull: Contravariant, - t2: Contravariant, - t2OrNull: Contravariant, - - // $TEST$ serialization List> - a1: Any = »[t1, t1]«, - // $TEST$ serialization List> - a2: Any = »[t1, t1OrNull]«, - // $TEST$ serialization List> - a3: Any = »[t1, t2]«, - // $TEST$ serialization List> - a4: Any = »[t1, t2OrNull]«, - - // $TEST$ serialization List> - b1: Any = »[t1OrNull, t1OrNull]«, - // $TEST$ serialization List> - b2: Any = »[t1OrNull, t2]«, - // $TEST$ serialization List> - b3: Any = »[t1OrNull, t2OrNull]«, -) diff --git a/packages/ttsl-lang/tests/resources/typing/highest common subtype/unhandled type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/highest common subtype/unhandled type/main.sdstest deleted file mode 100644 index 15f6062d..00000000 --- a/packages/ttsl-lang/tests/resources/typing/highest common subtype/unhandled type/main.sdstest +++ /dev/null @@ -1,33 +0,0 @@ -package tests.typing.highestCommonSubtype.unhandledType - -class Contravariant - -segment mySegment( - one: Contravariant>, - oneOrNull: Contravariant>, - - `union`: Contravariant>, - unionOrNull: Contravariant>, - - callable: Contravariant<() -> ()>, - - // Named tuple types and static types are also not handled, but we can't test them here -) { - // $TEST$ serialization List> - »[one, `union`]«; - - // $TEST$ serialization List> - »[oneOrNull, `union`]«; - - // $TEST$ serialization List> - »[one, unionOrNull]«; - - // $TEST$ serialization List> - »[oneOrNull, unionOrNull]«; - - // $TEST$ serialization List> - »[one, callable]«; - - // $TEST$ serialization List> - »[oneOrNull, callable]«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/highest common subtype/unknown type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/highest common subtype/unknown type/main.sdstest deleted file mode 100644 index 2ad0d112..00000000 --- a/packages/ttsl-lang/tests/resources/typing/highest common subtype/unknown type/main.sdstest +++ /dev/null @@ -1,15 +0,0 @@ -package tests.typing.highestCommonSubtype.unknownType - -class Contravariant - -segment mySegment( - one: Contravariant>, - nullable: Contravariant>, - unknown: Contravariant, -) { - // $TEST$ serialization List> - »[one, unknown]«; - - // $TEST$ serialization List> - »[nullable, unknown]«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/class type and class type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/class type and class type/main.sdstest deleted file mode 100644 index 56108684..00000000 --- a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/class type and class type/main.sdstest +++ /dev/null @@ -1,34 +0,0 @@ -package tests.typing.lowestCommonSupertype.classTypeAndClassType - -class C -class D sub C -class E - -segment mySegment1( - c: C, - cOrNull: C?, - d: D, - dOrNull: D?, - e: E, - eOrNull: E?, -) { - // $TEST$ serialization List - »[c, c]«; - - // $TEST$ serialization List - »[c, cOrNull]«; - - - // $TEST$ serialization List - »[c, d]«; - - // $TEST$ serialization List - »[c, dOrNull]«; - - - // $TEST$ serialization List - »[c, e]«; - - // $TEST$ serialization List - »[c, eOrNull]«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/class type and class type/with type parameters.sdstest b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/class type and class type/with type parameters.sdstest deleted file mode 100644 index ed059df9..00000000 --- a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/class type and class type/with type parameters.sdstest +++ /dev/null @@ -1,96 +0,0 @@ -package tests.typing.lowestCommonSupertype.classTypeAndClassType - -class Covariant -class FloatCovariant sub Covariant - -segment covariant( - coNumber: Covariant, - coInt: Covariant, - coString: Covariant, - coFloat: FloatCovariant, -) { - // $TEST$ serialization List> - »[coNumber, coNumber]«; - // $TEST$ serialization List> - »[coNumber, coInt]«; - // $TEST$ serialization List> - »[coNumber, coString]«; - // $TEST$ serialization List> - »[coNumber, coFloat]«; - - // $TEST$ serialization List> - »[coInt, coInt]«; - // $TEST$ serialization List> - »[coInt, coString]«; - // $TEST$ serialization List> - »[coInt, coFloat]«; - - // $TEST$ serialization List> - »[coString, coString]«; - // $TEST$ serialization List> - »[coString, coFloat]«; - - // $TEST$ serialization List - »[coFloat, coFloat]«; -} - -class Contravariant - -segment contravariant( - contraFloat: Contravariant, - contraInt: Contravariant, -) { - // Most tests are in the "highest common subtype" folder. Here we only test that we call the right method. - - // $TEST$ serialization List> - »[contraFloat, contraInt]«; -} - -class Invariant -class FloatInvariant sub Invariant - -segment invariant( - invNumber: Invariant, - invInt: Invariant, - invString: Invariant, - invFloat: FloatInvariant -) { - // $TEST$ serialization List> - »[invNumber, invNumber]«; - // $TEST$ serialization List - »[invNumber, invInt]«; - // $TEST$ serialization List - »[invNumber, invString]«; - // $TEST$ serialization List - »[invNumber, invFloat]«; - - // $TEST$ serialization List> - »[invInt, invInt]«; - // $TEST$ serialization List - »[invInt, invString]«; - // $TEST$ serialization List - »[invInt, invFloat]«; - - // $TEST$ serialization List> - »[invString, invString]«; - // $TEST$ serialization List - »[invString, invFloat]«; - - // $TEST$ serialization List - »[invFloat, invFloat]«; -} - -class Multiple - -segment multiple( - multipleNumberInt: Multiple, - multipleNumberFloat: Multiple, -) { - // $TEST$ serialization List> - »[multipleNumberInt, multipleNumberInt]«; - // $TEST$ serialization List> - »[multipleNumberInt, multipleNumberFloat]«; - - // $TEST$ serialization List> - »[multipleNumberFloat, multipleNumberFloat]«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/class type and literal type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/class type and literal type/main.sdstest deleted file mode 100644 index 93b2dfb4..00000000 --- a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/class type and literal type/main.sdstest +++ /dev/null @@ -1,50 +0,0 @@ -package tests.typing.lowestCommonSupertype.classTypeAndLiteralType - -class C - -segment mySegment( - c: C, - cOrNull: C?, - int: Int, - intOrNull: Int?, - number: Number, - numberOrNull: Number?, - string: String, - stringOrNull: String?, - nothing: Nothing, - nothingOrNull: Nothing?, -) { - // $TEST$ serialization List - »[1, c]«; - - // $TEST$ serialization List - »[1, cOrNull]«; - - - // $TEST$ serialization List - »[1, int]«; - - // $TEST$ serialization List - »[1, intOrNull]«; - - - // $TEST$ serialization List - »[1, number]«; - - // $TEST$ serialization List - »[1, numberOrNull]«; - - - // $TEST$ serialization List - »[1, string]«; - - // $TEST$ serialization List - »[1, stringOrNull]«; - - - // $TEST$ serialization List> - »[1, nothing]«; - - // $TEST$ serialization List> - »[1, nothingOrNull]«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/class type and type parameter type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/class type and type parameter type/main.sdstest deleted file mode 100644 index 6b68b829..00000000 --- a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/class type and type parameter type/main.sdstest +++ /dev/null @@ -1,25 +0,0 @@ -package tests.typing.lowestCommonSupertype.classTypeAndTypeParameterType - -class C -class D - -class Test( - c: C, - - unbounded: Unbounded, - unboundedOrNull: Unbounded?, - boundedByC: BoundedByC, - boundedByD: BoundedByD, - boundedByDOrNull: BoundedByDOrNull, - - // $TEST$ serialization List - p1: Any = »[c, unbounded]«, - // $TEST$ serialization List - p2: Any = »[c, unboundedOrNull]«, - // $TEST$ serialization List - p3: Any = »[c, boundedByC]«, - // $TEST$ serialization List - p4: Any = »[c, boundedByD]«, - // $TEST$ serialization List - p5: Any = »[c, boundedByDOrNull]«, -) diff --git a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum type and enum type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum type and enum type/main.sdstest deleted file mode 100644 index a25495d2..00000000 --- a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum type and enum type/main.sdstest +++ /dev/null @@ -1,24 +0,0 @@ -package tests.typing.lowestCommonSupertype.enumTypeAndEnumType - -enum E1 -enum E2 - -segment mySegment( - e1: E1, - e1OrNull: E1?, - e2: E2, - e2OrNull: E2? -) { - // $TEST$ serialization List - »[e1, e1]«; - - // $TEST$ serialization List - »[e1, e1OrNull]«; - - - // $TEST$ serialization List - »[e1, e2]«; - - // $TEST$ serialization List - »[e1, e2OrNull]«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum type and enum variant type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum type and enum variant type/main.sdstest deleted file mode 100644 index 0f2a8f8c..00000000 --- a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum type and enum variant type/main.sdstest +++ /dev/null @@ -1,29 +0,0 @@ -package tests.typing.lowestCommonSupertype.enumTypeAndEnumVariantType - -enum E1 { - V1 -} -enum E2 { - V2 -} - -segment mySegment( - e1: E1, - v1: E1.V1, - v1OrNull: E1.V1?, - v2: E2.V2, - v2OrNull: E2.V2? -) { - // $TEST$ serialization List - »[e1, v1]«; - - // $TEST$ serialization List - »[e1, v1OrNull]«; - - - // $TEST$ serialization List - »[e1, v2]«; - - // $TEST$ serialization List - »[e1, v2OrNull]«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum type and type parameter type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum type and type parameter type/main.sdstest deleted file mode 100644 index 14568f31..00000000 --- a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum type and type parameter type/main.sdstest +++ /dev/null @@ -1,37 +0,0 @@ -package tests.typing.lowestCommonSupertype.enumTypeAndTypeParameterType - -enum E { - V -} - -enum F - -class Test< - Unbounded, - BoundedByEnum sub E, - BoundedByEnumVariant sub E.V, - BoundedByOtherEnum sub F, - BoundedByOtherEnumOrNull sub F? ->( - e: E, - - unbounded: Unbounded, - unboundedOrNull: Unbounded?, - boundedByEnum: BoundedByEnum, - boundedByEnumVariant: BoundedByEnumVariant, - boundedByOtherEnum: BoundedByOtherEnum, - boundedByOtherEnumOrNull: BoundedByOtherEnumOrNull, - - // $TEST$ serialization List - p1: Any = »[e, unbounded]«, - // $TEST$ serialization List - p2: Any = »[e, unboundedOrNull]«, - // $TEST$ serialization List - p3: Any = »[e, boundedByEnum]«, - // $TEST$ serialization List - p4: Any = »[e, boundedByEnumVariant]«, - // $TEST$ serialization List - p5: Any = »[e, boundedByOtherEnum]«, - // $TEST$ serialization List - p6: Any = »[e, boundedByOtherEnumOrNull]«, -) diff --git a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum variant type and enum variant type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum variant type and enum variant type/main.sdstest deleted file mode 100644 index 1baf1b84..00000000 --- a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum variant type and enum variant type/main.sdstest +++ /dev/null @@ -1,38 +0,0 @@ -package tests.typing.lowestCommonSupertype.enumVariantTypeAndEnumVariantType - -enum E1 { - V1 - V2 -} -enum E3 { - V3 -} - -segment mySegment( - v1: E1.V1, - v1OrNull: E1.V1?, - v2: E1.V2, - v2OrNull: E1.V2?, - v3: E3.V3, - v3OrNull: E3.V3? -) { - // $TEST$ serialization List - »[v1, v1]«; - - // $TEST$ serialization List - »[v1, v1OrNull]«; - - - // $TEST$ serialization List - »[v1, v2]«; - - // $TEST$ serialization List - »[v1, v2OrNull]«; - - - // $TEST$ serialization List - »[v1, v3]«; - - // $TEST$ serialization List - »[v1, v3OrNull]«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum variant type and type parameter type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum variant type and type parameter type/main.sdstest deleted file mode 100644 index 45eeb432..00000000 --- a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/enum variant type and type parameter type/main.sdstest +++ /dev/null @@ -1,32 +0,0 @@ -package tests.typing.lowestCommonSupertype.enumVariantTypeAndTypeParameterType - -enum E { - V1 - V2 -} - -class D< - Unbounded, - BoundedByEnumVariant sub E.V1, - BoundedByOtherEnumVariant sub E.V2, - BoundedByOtherEnumVariantOrNull sub E.V2? ->( - v: E.V1, - - unbounded: Unbounded, - unboundedOrNull: Unbounded?, - boundedByEnumVariant: BoundedByEnumVariant, - boundedByOtherEnumVariant: BoundedByOtherEnumVariant, - boundedByOtherEnumVariantOrNull: BoundedByOtherEnumVariantOrNull, - - // $TEST$ serialization List - p1: Any = »[v, unbounded]«, - // $TEST$ serialization List - p2: Any = »[v, unboundedOrNull]«, - // $TEST$ serialization List - p3: Any = »[v, boundedByEnumVariant]«, - // $TEST$ serialization List - p4: Any = »[v, boundedByOtherEnumVariant]«, - // $TEST$ serialization List - p5: Any = »[v, boundedByOtherEnumVariantOrNull]«, -) diff --git a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/incompatible types/main.sdstest b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/incompatible types/main.sdstest deleted file mode 100644 index 34d6a492..00000000 --- a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/incompatible types/main.sdstest +++ /dev/null @@ -1,39 +0,0 @@ -package tests.typing.lowestCommonSupertype.incompatibleTypes - -class C() -enum E { - V -} - -segment mySegment( - e: E, - eOrNull: E?, - vOrNull: E.V? -) { - // $TEST$ serialization List - »[C(), e]«; - - // $TEST$ serialization List - »[C(), eOrNull]«; - - - // $TEST$ serialization List - »[C(), E.V]«; - - // $TEST$ serialization List - »[C(), vOrNull]«; - - - // $TEST$ serialization List - »[1, e]«; - - // $TEST$ serialization List - »[1, eOrNull]«; - - - // $TEST$ serialization List - »[1, E.V]«; - - // $TEST$ serialization List - »[1, vOrNull]«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/literal type and literal type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/literal type and literal type/main.sdstest deleted file mode 100644 index e69766be..00000000 --- a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/literal type and literal type/main.sdstest +++ /dev/null @@ -1,9 +0,0 @@ -package tests.typing.lowestCommonSupertype.literalTypeAndLiteralType - -segment mySegment() { - // $TEST$ serialization List> - »[true, 1]«; - - // $TEST$ serialization List> - »[true, null]«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/literal type and type parameter type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/literal type and type parameter type/main.sdstest deleted file mode 100644 index 59380141..00000000 --- a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/literal type and type parameter type/main.sdstest +++ /dev/null @@ -1,25 +0,0 @@ -package tests.typing.lowestCommonSupertype.literalTypeAndTypeParameterType - -class Test< - Unbounded, - BoundedByInt sub Int, - BoundedByString sub String, - BoundedByStringOrNull sub String? ->( - unbounded: Unbounded, - unboundedOrNull: Unbounded?, - boundedByInt: BoundedByInt, - boundedByString: BoundedByString, - boundedByStringOrNull: BoundedByStringOrNull, - - // $TEST$ serialization List - p1: Any = »[1, unbounded]«, - // $TEST$ serialization List - p2: Any = »[1, unboundedOrNull]«, - // $TEST$ serialization List - p3: Any = »[1, boundedByInt]«, - // $TEST$ serialization List - p4: Any = »[1, boundedByString]«, - // $TEST$ serialization List - p5: Any = »[1, boundedByStringOrNull]«, -) diff --git a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/no types after simplification/main.sdstest b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/no types after simplification/main.sdstest deleted file mode 100644 index 9b35a2f7..00000000 --- a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/no types after simplification/main.sdstest +++ /dev/null @@ -1,18 +0,0 @@ -package tests.typing.lowestCommonSupertype.noTypesAfterSimplification - -segment mySegment( - p1: literal<>, - p2: union<>, -) { - // $TEST$ serialization List - »[]«; - - // $TEST$ serialization List - »[p1]«; - - // $TEST$ serialization List - »[p2]«; - - // $TEST$ serialization List - »[p1, p2]«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/simplification/main.sdstest b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/simplification/main.sdstest deleted file mode 100644 index 942901e0..00000000 --- a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/simplification/main.sdstest +++ /dev/null @@ -1,20 +0,0 @@ -package tests.typing.lowestCommonSupertype.simplification - -class C() - -segment mySegment( - p1: union, literal>, - p2: literal<> -) { - // $TEST$ serialization List - »[p1, p1]«; - - // $TEST$ serialization List> - »[1, 1.5]«; - - // $TEST$ serialization List - »[C(), p2]«; - - // $TEST$ serialization List - »[C(), null]«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/singular type after simplification/main.sdstest b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/singular type after simplification/main.sdstest deleted file mode 100644 index 72381e3e..00000000 --- a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/singular type after simplification/main.sdstest +++ /dev/null @@ -1,39 +0,0 @@ -package tests.typing.lowestCommonSupertype.singularTypeAfterSimplification - -class C() -enum E { - V -} - -@Pure fun f() -> (r1: Int, r2: Int) - -segment mySegment( - p1: E -) { - // $TEST$ serialization List<() -> ()> - »[() {}]«; - - // $TEST$ serialization List> - »[1]«; - - // $TEST$ serialization List<(r1: Int, r2: Int)> - »[f()]«; - - // $TEST$ serialization List - »[C()]«; - - // $TEST$ serialization List - »[p1]«; - - // $TEST$ serialization List - »[E.V]«; - - // $TEST$ serialization List<$type> - »[C]«; - - // $TEST$ serialization List<$unknown> - »[unknown]«; -} - -// $TEST$ serialization List -class D(t: T, list: Any = »[t]«) diff --git a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/type parameter type and type parameter type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/type parameter type and type parameter type/main.sdstest deleted file mode 100644 index 7a1d97b6..00000000 --- a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/type parameter type and type parameter type/main.sdstest +++ /dev/null @@ -1,37 +0,0 @@ -package tests.typing.lowestCommonSupertype.typeParameterTypeAndTypeParameterType - -class C -class D sub C -class E sub C -class F - -class Test( - nothingToAnyOrNull: NothingToAnyOrNull, - nothingToD: NothingToD, - nothingToE: NothingToE, - nothingToF: NothingToF, - - // $TEST$ serialization List - a1: Any = »[nothingToAnyOrNull, nothingToAnyOrNull]«, - // $TEST$ serialization List - a2: Any = »[nothingToAnyOrNull, nothingToD]«, - // $TEST$ serialization List - a3: Any = »[nothingToAnyOrNull, nothingToE]«, - // $TEST$ serialization List - a4: Any = »[nothingToAnyOrNull, nothingToF]«, - - // $TEST$ serialization List - b1: Any = »[nothingToD, nothingToD]«, - // $TEST$ serialization List - b2: Any = »[nothingToD, nothingToE]«, - // $TEST$ serialization List - b3: Any = »[nothingToD, nothingToF]«, - - // $TEST$ serialization List - c1: Any = »[nothingToE, nothingToE]«, - // $TEST$ serialization List - c2: Any = »[nothingToE, nothingToF]«, - - // $TEST$ serialization List - d1: Any = »[nothingToF, nothingToF]« -) diff --git a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/unhandled type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/unhandled type/main.sdstest deleted file mode 100644 index b9e60d1b..00000000 --- a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/unhandled type/main.sdstest +++ /dev/null @@ -1,24 +0,0 @@ -package tests.typing.lowestCommonSupertype.unhandledType - -class C -@Pure fun f() -> (r1: Int, r2: Int) - -segment mySegment() { - // $TEST$ serialization List - »[1, f]«; - - // $TEST$ serialization List - »[null, f]«; - - // $TEST$ serialization List - »[1, C]«; - - // $TEST$ serialization List - »[null, C]«; - - // $TEST$ serialization List - »[1, f()]«; - - // $TEST$ serialization List - »[null, f()]«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/unknown type/main.sdstest b/packages/ttsl-lang/tests/resources/typing/lowest common supertype/unknown type/main.sdstest deleted file mode 100644 index e73d1d98..00000000 --- a/packages/ttsl-lang/tests/resources/typing/lowest common supertype/unknown type/main.sdstest +++ /dev/null @@ -1,9 +0,0 @@ -package tests.typing.lowestCommonSupertype.unknownType - -segment mySegment() { - // $TEST$ serialization List - »[1, unknown]«; - - // $TEST$ serialization List - »[null, unknown]«; -} diff --git a/packages/ttsl-lang/tests/resources/typing/simplification/merge literal types in union types/main.sdstest b/packages/ttsl-lang/tests/resources/typing/simplification/merge literal types in union types/main.sdstest deleted file mode 100644 index ddadce8a..00000000 --- a/packages/ttsl-lang/tests/resources/typing/simplification/merge literal types in union types/main.sdstest +++ /dev/null @@ -1,18 +0,0 @@ -package tests.typing.simplification.mergeLiteralTypesInUnionTypes - -class C( - // $TEST$ serialization literal<1> - p1: »union, literal<1, 1>>«, - - // $TEST$ serialization literal<1, 2> - p2: »union, literal<1, 2>>«, - - // $TEST$ serialization literal<1, 2, 3> - p3: »union, literal<2, 3>>«, - - // $TEST$ serialization literal<1, 2, 3> - p4: »union, literal<2>, literal<3>>«, - - // $TEST$ serialization union, String> - p5: »union, String, literal<2, 3>>«, -) diff --git a/packages/ttsl-lang/tests/resources/typing/simplification/remove duplicate constants from literal types/main.sdstest b/packages/ttsl-lang/tests/resources/typing/simplification/remove duplicate constants from literal types/main.sdstest deleted file mode 100644 index 4aeb7c89..00000000 --- a/packages/ttsl-lang/tests/resources/typing/simplification/remove duplicate constants from literal types/main.sdstest +++ /dev/null @@ -1,12 +0,0 @@ -package tests.typing.simplification.removeDuplicateConstantsFromLiteralTypes - -class C( - // $TEST$ serialization literal<1> - p1: »literal<1, 1>«, - - // $TEST$ serialization literal<1, 2> - p2: »literal<1, 2>«, - - // $TEST$ serialization literal<1, 1.0> - p3: »literal<1, 1.0>«, -) diff --git a/packages/ttsl-lang/tests/resources/typing/simplification/remove unneeded entries from union types/main.sdstest b/packages/ttsl-lang/tests/resources/typing/simplification/remove unneeded entries from union types/main.sdstest deleted file mode 100644 index f26435ca..00000000 --- a/packages/ttsl-lang/tests/resources/typing/simplification/remove unneeded entries from union types/main.sdstest +++ /dev/null @@ -1,126 +0,0 @@ -package tests.typing.simplification.removeUnneededEntriesFromUnionTypes - -class C( - // $TEST$ serialization Int - p1: »union«, - - // $TEST$ serialization union - p2: »union«, - - - // $TEST$ serialization Number - p3: »union«, - - // $TEST$ serialization Number - p4: »union«, - - // $TEST$ serialization Number? - p5: »union«, - - // $TEST$ serialization Any - p6: »union«, - - // $TEST$ serialization Any - p7: »union«, - - // $TEST$ serialization Any? - p8: »union«, - - - // $TEST$ serialization union - p9: »union«, - - // $TEST$ serialization union - p10: »union«, - - // $TEST$ serialization union - p11: »union«, - - // $TEST$ serialization union - p12: »union«, - - // $TEST$ serialization Any - p13: »union«, - - // $TEST$ serialization Any? - p14: »union«, - - // $TEST$ serialization Any - p15: »union«, - - // $TEST$ serialization Any? - p16: »union«, -) - -class TestsInvolvingNothing( - // $TEST$ serialization Any - p1: »union«, - - // $TEST$ serialization Any? - p2: »union«, - - // $TEST$ serialization literal<1> - p3: »union, Nothing>«, - - // $TEST$ serialization literal<1, null> - p4: »union, Nothing?>«, - - // $TEST$ serialization () -> () - p5: »union<() -> (), Nothing>«, - - // $TEST$ serialization union<() -> (), Nothing?> - p6: »union<() -> (), Nothing?>«, -) - -class TestsInvolvingTypeParameters( - // $TEST$ serialization Unbounded - a1: »union«, - // $TEST$ serialization Unbounded - a2: »union«, - - // $TEST$ serialization Unbounded? - a3: »union«, - // $TEST$ serialization Unbounded? - a4: »union«, - - // $TEST$ serialization union - a5: »union«, - // $TEST$ serialization union - a6: »union«, - - // $TEST$ serialization Any? - a7: »union«, - // $TEST$ serialization Any? - a8: »union«, - - - // $TEST$ serialization UpperBound - b1: »union«, - // $TEST$ serialization UpperBound - b2: »union«, - - // $TEST$ serialization UpperBound? - b3: »union«, - // $TEST$ serialization UpperBound? - b4: »union«, - - // $TEST$ serialization union - b5: »union«, - // $TEST$ serialization union - b6: »union«, - - // $TEST$ serialization Number - b7: »union«, - // $TEST$ serialization Number - b8: »union«, - - // $TEST$ serialization Number? - b9: »union«, - // $TEST$ serialization Number? - b10: »union«, - - // $TEST$ serialization Any? - b11: »union«, - // $TEST$ serialization Any? - b12: »union«, -) diff --git a/packages/ttsl-lang/tests/resources/typing/simplification/replace empty literal types with Nothing/main.sdstest b/packages/ttsl-lang/tests/resources/typing/simplification/replace empty literal types with Nothing/main.sdstest deleted file mode 100644 index 01740bae..00000000 --- a/packages/ttsl-lang/tests/resources/typing/simplification/replace empty literal types with Nothing/main.sdstest +++ /dev/null @@ -1,6 +0,0 @@ -package tests.typing.simplification.replaceEmptyLiteralTypesWithNothing - -class C( - // $TEST$ serialization Nothing - p1: »literal<>« -) diff --git a/packages/ttsl-lang/tests/resources/typing/simplification/replace empty union types with Nothing/main.sdstest b/packages/ttsl-lang/tests/resources/typing/simplification/replace empty union types with Nothing/main.sdstest deleted file mode 100644 index f556c923..00000000 --- a/packages/ttsl-lang/tests/resources/typing/simplification/replace empty union types with Nothing/main.sdstest +++ /dev/null @@ -1,6 +0,0 @@ -package tests.typing.simplification.replaceEmptyUnionTypesWithNothing - -class C( - // $TEST$ serialization Nothing - p1: »union<>« -) diff --git a/packages/ttsl-lang/tests/resources/typing/simplification/replace literals types that allow only null with NothingOrNull/main.sdstest b/packages/ttsl-lang/tests/resources/typing/simplification/replace literals types that allow only null with NothingOrNull/main.sdstest deleted file mode 100644 index b52fa6af..00000000 --- a/packages/ttsl-lang/tests/resources/typing/simplification/replace literals types that allow only null with NothingOrNull/main.sdstest +++ /dev/null @@ -1,9 +0,0 @@ -package tests.typing.simplification.replaceLiteralTypesThatAllowOnlyNullWithNothingOrNull - -class C( - // $TEST$ serialization Nothing? - p1: »literal«, - - // $TEST$ serialization Nothing? - p2: »literal« -) diff --git a/packages/ttsl-lang/tests/resources/typing/simplification/unwrap/main.sdstest b/packages/ttsl-lang/tests/resources/typing/simplification/unwrap/main.sdstest deleted file mode 100644 index 45ad15cb..00000000 --- a/packages/ttsl-lang/tests/resources/typing/simplification/unwrap/main.sdstest +++ /dev/null @@ -1,46 +0,0 @@ -package tests.typing.simplification.unwrap - -segment callableType( - // $TEST$ serialization () -> () - f1: »() -> ()«, - - // $TEST$ serialization (p: String) -> (r: String) - f2: »(p: union>) -> (r: union>)« -) {} - -segment namedTupleType( - f1: () -> (), - f2: () -> (r: String), - f3: () -> (r1: union>, r2: union>) -) { - // $TEST$ serialization () - »f1()«; - - // $TEST$ serialization String - »f2()«; - - // $TEST$ serialization (r1: String, r2: String) - »f3()«; -} - -segment classType( - // $TEST$ serialization String - p1: »String«, - - // $TEST$ serialization List - p2: »List«, - - // $TEST$ serialization List - p3: »List>>«, -) {} - -segment unionType( - // $TEST$ serialization String - p1: »union«, - - // $TEST$ serialization String - p2: »union>«, - - // $TEST$ serialization union - p3: »union, Boolean>«, -) {} diff --git a/packages/ttsl-lang/tests/resources/typing/types/callable types/main.sdstest b/packages/ttsl-lang/tests/resources/typing/types/callable types/main.sdstest deleted file mode 100644 index da9f77e1..00000000 --- a/packages/ttsl-lang/tests/resources/typing/types/callable types/main.sdstest +++ /dev/null @@ -1,16 +0,0 @@ -package tests.typing.types.callableTypes - -// $TEST$ serialization () -> () -fun myFunction1(f: »() -> ()«) - -// $TEST$ serialization () -> (r1: Int, r2: String) -fun myFunction2(f: »() -> (r1: Int, r2: String)«) - -// $TEST$ serialization (p1: Int, p2: String) -> () -fun myFunction3(f: »(p1: Int, p2: String) -> ()«) - -// $TEST$ serialization (p1: Int, p2: String) -> (r1: Int, r2: String) -fun myFunction4(f: »(p1: Int, p2: String) -> (r1: Int, r2: String)«) - -// $TEST$ serialization (p1: $unknown) -> (r1: $unknown) -fun myFunction5(f: »(p1) -> (r1)«) diff --git a/packages/ttsl-lang/tests/resources/typing/types/literal types/main.sdstest b/packages/ttsl-lang/tests/resources/typing/types/literal types/main.sdstest deleted file mode 100644 index 4adb84d6..00000000 --- a/packages/ttsl-lang/tests/resources/typing/types/literal types/main.sdstest +++ /dev/null @@ -1,10 +0,0 @@ -package tests.typing.types.literalTypes - -// $TEST$ serialization Nothing -fun myFunction1(f: »literal<>«) - -// $TEST$ serialization literal<1, 2> -fun myFunction2(f: »literal<1, 2>«) - -// $TEST$ serialization literal<1, ""> -fun myFunction3(f: »literal<1, "">«) diff --git a/packages/ttsl-lang/tests/resources/typing/types/main.ttsl b/packages/ttsl-lang/tests/resources/typing/types/main.ttsl new file mode 100644 index 00000000..3a65202c --- /dev/null +++ b/packages/ttsl-lang/tests/resources/typing/types/main.ttsl @@ -0,0 +1,35 @@ +package tests.typing.types.namedTypes + +function nonNullableTypes( + # $TEST$ serialization Int + a: »Int«, + # $TEST$ serialization Float + b: »Float«, + # $TEST$ serialization String + c: »String«, + # $TEST$ serialization Boolean + d: »Boolean«, + # $TEST$ serialization List + e: »List«, + # $TEST$ serialization Dictionary + f: »Dictionary«, + # $TEST$ serialization $unknown + g: »unresolved«, +) + +function nullableNamedTypes( + # $TEST$ serialization Int? + a: »Int?«, + # $TEST$ serialization Float? + b: »Float?«, + # $TEST$ serialization String? + c: »String?«, + # $TEST$ serialization Boolean? + d: »Boolean?«, + # $TEST$ serialization List? + e: »List?«, + # $TEST$ serialization Dictionary? + f: »Dictionary?«, + # $TEST$ serialization $unknown? + g: »unresolved?«, +) diff --git a/packages/ttsl-lang/tests/resources/typing/types/member types/main.sdstest b/packages/ttsl-lang/tests/resources/typing/types/member types/main.sdstest deleted file mode 100644 index e90431a0..00000000 --- a/packages/ttsl-lang/tests/resources/typing/types/member types/main.sdstest +++ /dev/null @@ -1,36 +0,0 @@ -package tests.typing.types.memberTypes - -class MyClass { - // $TEST$ equivalence_class myNestedClass - class »MyNestedClass« - - // $TEST$ equivalence_class myNestedEnum - enum »MyNestedEnum« -} - -enum MyEnum { - // $TEST$ equivalence_class myEnumVariant - »MyEnumVariant« -} - -fun nonNullableMemberTypes( - // $TEST$ equivalence_class myNestedClass - a: »MyClass.MyNestedClass«, - // $TEST$ equivalence_class myNestedEnum - b: »MyClass.MyNestedEnum«, - // $TEST$ equivalence_class myEnumVariant - d: »MyEnum.MyEnumVariant«, - // $TEST$ serialization $unknown - e: »MyEnum.unresolved«, -) - -fun nullableMemberTypes( - // $TEST$ serialization MyNestedClass? - a: »MyClass.MyNestedClass?«, - // $TEST$ serialization MyNestedEnum? - b: »MyClass.MyNestedEnum?«, - // $TEST$ serialization MyEnum.MyEnumVariant? - d: »MyEnum.MyEnumVariant?«, - // $TEST$ serialization $unknown - e: »MyEnum.unresolved?«, -) diff --git a/packages/ttsl-lang/tests/resources/typing/types/named types/main.sdstest b/packages/ttsl-lang/tests/resources/typing/types/named types/main.sdstest deleted file mode 100644 index a8863f83..00000000 --- a/packages/ttsl-lang/tests/resources/typing/types/named types/main.sdstest +++ /dev/null @@ -1,23 +0,0 @@ -package tests.typing.types.namedTypes - -class MyClass - -enum MyEnum - -fun nonNullableNamedTypes( - // $TEST$ serialization MyClass - a: »MyClass«, - // $TEST$ serialization MyEnum - b: »MyEnum«, - // $TEST$ serialization $unknown - c: »unresolved«, -) - -fun nullableNamedTypes( - // $TEST$ serialization MyClass? - a: »MyClass?«, - // $TEST$ serialization MyEnum? - b: »MyEnum?«, - // $TEST$ serialization $unknown - c: »unresolved?«, -) diff --git a/packages/ttsl-lang/tests/resources/typing/types/named types/with type parameters.sdstest b/packages/ttsl-lang/tests/resources/typing/types/named types/with type parameters.sdstest deleted file mode 100644 index 05cd2dd7..00000000 --- a/packages/ttsl-lang/tests/resources/typing/types/named types/with type parameters.sdstest +++ /dev/null @@ -1,36 +0,0 @@ -package tests.typing.types.namedTypes - -class MyClass2 -class MyClass3 - -fun nonNullableNamedTypes( - // $TEST$ serialization MyClass2 - a: »MyClass2«, - // $TEST$ serialization MyClass2<$unknown> - b: »MyClass2«, - // $TEST$ serialization MyClass2<$unknown> - c: »MyClass2«, - // $TEST$ serialization MyClass2 - d: »MyClass2«, - - // $TEST$ serialization MyClass3 - y: »MyClass3«, - // $TEST$ serialization $unknown - z: »unresolved«, -) - -fun nullableNamedTypes( - // $TEST$ serialization MyClass2? - a: »MyClass2?«, - // $TEST$ serialization MyClass2<$unknown>? - b: »MyClass2?«, - // $TEST$ serialization MyClass2<$unknown>? - c: »MyClass2?«, - // $TEST$ serialization MyClass2? - d: »MyClass2?«, - - // $TEST$ serialization MyClass3? - y: »MyClass3?«, - // $TEST$ serialization $unknown - z: »unresolved?«, -) diff --git a/packages/ttsl-lang/tests/resources/typing/types/type arguments/main.sdstest b/packages/ttsl-lang/tests/resources/typing/types/type arguments/main.sdstest deleted file mode 100644 index 0f6b3c21..00000000 --- a/packages/ttsl-lang/tests/resources/typing/types/type arguments/main.sdstest +++ /dev/null @@ -1,20 +0,0 @@ -package tests.typing.types.typeArguments - -class MyClass - -fun myFunction( - // $TEST$ serialization Int - a: MyClass<»Int«>, - // $TEST$ serialization Int - b: MyClass<»T = Int«>, - - // $TEST$ serialization Boolean - e: unresolved<»Boolean«>, - // $TEST$ serialization Boolean - f: unresolved<»T = Boolean«>, - - // $TEST$ serialization $unknown - g: MyClass<»unresolved«>, - // $TEST$ serialization $unknown - h: MyClass<»T = unresolved«>, -) diff --git a/packages/ttsl-lang/tests/resources/typing/types/union types/main.sdstest b/packages/ttsl-lang/tests/resources/typing/types/union types/main.sdstest deleted file mode 100644 index 12ed6e73..00000000 --- a/packages/ttsl-lang/tests/resources/typing/types/union types/main.sdstest +++ /dev/null @@ -1,7 +0,0 @@ -package tests.typing.types.unionTypes - -// $TEST$ serialization Nothing -fun myFunction(a: »union<>«) - -// $TEST$ serialization union -fun myFunction(a: »union«) diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/assigned result/main.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/assigned result/main.sdstest index f4cc1bd1..6ec94a14 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/assigned result/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/assigned result/main.sdstest @@ -6,25 +6,25 @@ fun myFunction() -> ( ) segment mySegment() -> (result1: Int, result2: Int, result3: Int) { - // $TEST$ warning "The assigned result 'deprecatedResult' is deprecated." - // $TEST$ no warning r"The assigned result '\w*' is deprecated\." - // $TEST$ no warning r"The assigned result '\w*' is deprecated\." + # $TEST$ warning "The assigned result 'deprecatedResult' is deprecated." + # $TEST$ no warning r"The assigned result '\w*' is deprecated\." + # $TEST$ no warning r"The assigned result '\w*' is deprecated\." »val a«, »val b«, »val c« = myFunction(); - // $TEST$ warning "The assigned result 'deprecatedResult' is deprecated." - // $TEST$ no warning r"The assigned result '\w*' is deprecated\." - // $TEST$ no warning r"The assigned result '\w*' is deprecated\." + # $TEST$ warning "The assigned result 'deprecatedResult' is deprecated." + # $TEST$ no warning r"The assigned result '\w*' is deprecated\." + # $TEST$ no warning r"The assigned result '\w*' is deprecated\." »yield result1«, »yield result2«, »yield result3« = myFunction(); - // $TEST$ no warning r"The assigned result '\w*' is deprecated\." - // $TEST$ no warning r"The assigned result '\w*' is deprecated\." - // $TEST$ no warning r"The assigned result '\w*' is deprecated\." + # $TEST$ no warning r"The assigned result '\w*' is deprecated\." + # $TEST$ no warning r"The assigned result '\w*' is deprecated\." + # $TEST$ no warning r"The assigned result '\w*' is deprecated\." »_«, »_«, »_« = myFunction(); - // $TEST$ no warning r"The assigned result '\w*' is deprecated\." + # $TEST$ no warning r"The assigned result '\w*' is deprecated\." »val d« = a; - // $TEST$ no warning r"The assigned result '\w*' is deprecated\." + # $TEST$ no warning r"The assigned result '\w*' is deprecated\." »val e« = b; - // $TEST$ no warning r"The assigned result '\w*' is deprecated\." + # $TEST$ no warning r"The assigned result '\w*' is deprecated\." »val f« = 1; } diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/called annotation/main.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/called annotation/main.sdstest index c7ac37d1..23d94587 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/called annotation/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/called annotation/main.sdstest @@ -4,10 +4,10 @@ package tests.validation.builtins.deprecated.calledAnnotation annotation DeprecatedAnnotation annotation ValidAnnotation -// $TEST$ warning "The called annotation 'DeprecatedAnnotation' is deprecated." +# $TEST$ warning "The called annotation 'DeprecatedAnnotation' is deprecated." @»DeprecatedAnnotation« -// $TEST$ no warning r"The called annotation '\w*' is deprecated\." +# $TEST$ no warning r"The called annotation '\w*' is deprecated\." @»ValidAnnotation« -// $TEST$ no warning r"The called annotation '\w*' is deprecated\." +# $TEST$ no warning r"The called annotation '\w*' is deprecated\." @»Unresolved« -pipeline myPipeline {} +function myFunction () {} diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/corresponding parameter/main.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/corresponding parameter/main.sdstest index 752ebb63..0a4bb1f5 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/corresponding parameter/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/corresponding parameter/main.sdstest @@ -5,22 +5,22 @@ fun f( validParameter: Int = 1 ) -pipeline myPipeline { +function myFunction () { f( - // $TEST$ warning "The corresponding parameter 'deprecatedParameter' is deprecated." + # $TEST$ warning "The corresponding parameter 'deprecatedParameter' is deprecated." »deprecatedParameter = 1«, - // $TEST$ no warning r"The corresponding parameter '\w*' is deprecated\." + # $TEST$ no warning r"The corresponding parameter '\w*' is deprecated\." »validParameter = 1«, - // $TEST$ no warning r"The corresponding parameter '\w*' is deprecated\." + # $TEST$ no warning r"The corresponding parameter '\w*' is deprecated\." »unresolved = 1«, ); f( - // $TEST$ warning "The corresponding parameter 'deprecatedParameter' is deprecated." + # $TEST$ warning "The corresponding parameter 'deprecatedParameter' is deprecated." »1«, - // $TEST$ no warning r"The corresponding parameter '\w*' is deprecated\." + # $TEST$ no warning r"The corresponding parameter '\w*' is deprecated\." »1«, - // $TEST$ no warning r"The corresponding parameter '\w*' is deprecated\." + # $TEST$ no warning r"The corresponding parameter '\w*' is deprecated\." »1«, ); } diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/must not be used on required parameters/main.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/must not be used on required parameters/main.sdstest index 201f9c0c..395606fb 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/must not be used on required parameters/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/must not be used on required parameters/main.sdstest @@ -1,48 +1,48 @@ package tests.validation.builtins.deprecated.mustNotBeUsedOnRequiredParameters -// $TEST$ error "A deprecated parameter must be optional." -// $TEST$ no error "A deprecated parameter must be optional." +# $TEST$ error "A deprecated parameter must be optional." +# $TEST$ no error "A deprecated parameter must be optional." annotation MyAnnotation(@Deprecated »a«: Int, @Deprecated »b«: Int = 3) -// $TEST$ error "A deprecated parameter must be optional." -// $TEST$ no error "A deprecated parameter must be optional." +# $TEST$ error "A deprecated parameter must be optional." +# $TEST$ no error "A deprecated parameter must be optional." class MyClass(@Deprecated »a«: Int, @Deprecated »b«: Int = 3) { - // $TEST$ error "A deprecated parameter must be optional." - // $TEST$ no error "A deprecated parameter must be optional." + # $TEST$ error "A deprecated parameter must be optional." + # $TEST$ no error "A deprecated parameter must be optional." class MyClass(@Deprecated »a«: Int, @Deprecated »b«: Int = 3) - // $TEST$ error "A deprecated parameter must be optional." - // $TEST$ no error "A deprecated parameter must be optional." + # $TEST$ error "A deprecated parameter must be optional." + # $TEST$ no error "A deprecated parameter must be optional." fun myFunction(@Deprecated »a«: Int, @Deprecated »b«: Int = 3) } enum MyEnum { - // $TEST$ error "A deprecated parameter must be optional." - // $TEST$ no error "A deprecated parameter must be optional." + # $TEST$ error "A deprecated parameter must be optional." + # $TEST$ no error "A deprecated parameter must be optional." MyEnumVariant(@Deprecated »a«: Int, @Deprecated »b«: Int = 3) } -// $TEST$ error "A deprecated parameter must be optional." -// $TEST$ no error "A deprecated parameter must be optional." +# $TEST$ error "A deprecated parameter must be optional." +# $TEST$ no error "A deprecated parameter must be optional." fun myFunction(@Deprecated »a«: Int, @Deprecated »b«: Int = 3) -// $TEST$ error "A deprecated parameter must be optional." -// $TEST$ no error "A deprecated parameter must be optional." +# $TEST$ error "A deprecated parameter must be optional." +# $TEST$ no error "A deprecated parameter must be optional." segment mySegment1(@Deprecated »a«: Int, @Deprecated »b«: Int = 3) {} -// $TEST$ no error "A deprecated parameter must be optional." -// $TEST$ no error "A deprecated parameter must be optional." +# $TEST$ no error "A deprecated parameter must be optional." +# $TEST$ no error "A deprecated parameter must be optional." segment mySegment2( f: (@Deprecated »a«: Int, @Deprecated »b«: Int = 3) -> () ) { - // $TEST$ no error "A deprecated parameter must be optional." - // $TEST$ no error "A deprecated parameter must be optional." + # $TEST$ no error "A deprecated parameter must be optional." + # $TEST$ no error "A deprecated parameter must be optional." val g = (@Deprecated »a«: Int, @Deprecated »b«: Int = 3) {}; - // $TEST$ no error "A deprecated parameter must be optional." - // $TEST$ no error "A deprecated parameter must be optional." + # $TEST$ no error "A deprecated parameter must be optional." + # $TEST$ no error "A deprecated parameter must be optional." val h = (@Deprecated »a«: Int, @Deprecated »b«: Int = 3) -> 1; } diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/referenced declaration/from named type/main.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/referenced declaration/from named type/main.sdstest index 8de79583..6f2d798d 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/referenced declaration/from named type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/referenced declaration/from named type/main.sdstest @@ -12,21 +12,21 @@ enum ValidEnum { } segment mySegment( - // $TEST$ warning "The referenced declaration 'DeprecatedClass' is deprecated." + # $TEST$ warning "The referenced declaration 'DeprecatedClass' is deprecated." p1: »DeprecatedClass«, - // $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." + # $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." p2: »ValidClass«, - // $TEST$ warning "The referenced declaration 'DeprecatedEnum' is deprecated." + # $TEST$ warning "The referenced declaration 'DeprecatedEnum' is deprecated." p3: »DeprecatedEnum«, - // $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." + # $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." p4: »ValidEnum«, - // $TEST$ warning "The referenced declaration 'DeprecatedEnumVariant' is deprecated." + # $TEST$ warning "The referenced declaration 'DeprecatedEnumVariant' is deprecated." p5: ValidEnum.»DeprecatedEnumVariant«, - // $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." + # $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." p6: ValidEnum.»ValidEnumVariant«, - // $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." + # $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." p7: »Unresolved« ) {} diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/referenced declaration/from reference/main.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/referenced declaration/from reference/main.sdstest index 71a50203..1be35303 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/referenced declaration/from reference/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/deprecated/referenced declaration/from reference/main.sdstest @@ -41,56 +41,56 @@ segment mySegment( * Deprecation is only relevant for callers */ - // $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." + # $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." »deprecatedParameter«; - // $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." + # $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." »validParameter«; - // $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." + # $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." yield »deprecatedResult« = 1; - // $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." + # $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." yield »validResult« = 1; - // $TEST$ warning "The referenced declaration 'DeprecatedClass' is deprecated." + # $TEST$ warning "The referenced declaration 'DeprecatedClass' is deprecated." »DeprecatedClass«; - // $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." + # $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." »ValidClass«; - // $TEST$ warning "The referenced declaration 'deprecatedAttribute' is deprecated." + # $TEST$ warning "The referenced declaration 'deprecatedAttribute' is deprecated." ValidClass.»deprecatedAttribute«; - // $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." + # $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." ValidClass.»validAttribute«; - // $TEST$ warning "The referenced declaration 'DeprecatedEnum' is deprecated." + # $TEST$ warning "The referenced declaration 'DeprecatedEnum' is deprecated." »DeprecatedEnum«; - // $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." + # $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." »ValidEnum«; - // $TEST$ warning "The referenced declaration 'DeprecatedEnumVariant' is deprecated." + # $TEST$ warning "The referenced declaration 'DeprecatedEnumVariant' is deprecated." ValidEnum.»DeprecatedEnumVariant«; - // $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." + # $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." ValidEnum.»ValidEnumVariant«; - // $TEST$ warning "The referenced declaration 'deprecatedFunction' is deprecated." + # $TEST$ warning "The referenced declaration 'deprecatedFunction' is deprecated." »deprecatedFunction«(); - // $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." + # $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." »validFunction«(); - // $TEST$ warning "The referenced declaration 'deprecatedResult' is deprecated." + # $TEST$ warning "The referenced declaration 'deprecatedResult' is deprecated." validFunction().»deprecatedResult«; - // $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." + # $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." validFunction().»validResult«; - // $TEST$ warning "The referenced declaration 'deprecatedSegment' is deprecated." + # $TEST$ warning "The referenced declaration 'deprecatedSegment' is deprecated." »deprecatedSegment«(); - // $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." + # $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." »validSegment«(); - // $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." + # $TEST$ no warning r"The referenced declaration '\w*' is deprecated\." »unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/assigned result/main.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/assigned result/main.sdstest index 97c2171c..99e1b4c8 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/assigned result/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/assigned result/main.sdstest @@ -6,25 +6,25 @@ fun myFunction() -> ( ) segment mySegment() -> (result1: Int, result2: Int, result3: Int) { - // $TEST$ warning "The assigned result 'experimentalResult' is experimental." - // $TEST$ no warning r"The assigned result '\w*' is experimental\." - // $TEST$ no warning r"The assigned result '\w*' is experimental\." + # $TEST$ warning "The assigned result 'experimentalResult' is experimental." + # $TEST$ no warning r"The assigned result '\w*' is experimental\." + # $TEST$ no warning r"The assigned result '\w*' is experimental\." »val a«, »val b«, »val c« = myFunction(); - // $TEST$ warning "The assigned result 'experimentalResult' is experimental." - // $TEST$ no warning r"The assigned result '\w*' is experimental\." - // $TEST$ no warning r"The assigned result '\w*' is experimental\." + # $TEST$ warning "The assigned result 'experimentalResult' is experimental." + # $TEST$ no warning r"The assigned result '\w*' is experimental\." + # $TEST$ no warning r"The assigned result '\w*' is experimental\." »yield result1«, »yield result2«, »yield result3« = myFunction(); - // $TEST$ no warning r"The assigned result '\w*' is experimental\." - // $TEST$ no warning r"The assigned result '\w*' is experimental\." - // $TEST$ no warning r"The assigned result '\w*' is experimental\." + # $TEST$ no warning r"The assigned result '\w*' is experimental\." + # $TEST$ no warning r"The assigned result '\w*' is experimental\." + # $TEST$ no warning r"The assigned result '\w*' is experimental\." »_«, »_«, »_« = myFunction(); - // $TEST$ no warning r"The assigned result '\w*' is experimental\." + # $TEST$ no warning r"The assigned result '\w*' is experimental\." »val d« = a; - // $TEST$ no warning r"The assigned result '\w*' is experimental\." + # $TEST$ no warning r"The assigned result '\w*' is experimental\." »val e« = b; - // $TEST$ no warning r"The assigned result '\w*' is experimental\." + # $TEST$ no warning r"The assigned result '\w*' is experimental\." »val f« = 1; } diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/called annotation/main.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/called annotation/main.sdstest index 3792aada..f13e8afc 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/called annotation/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/called annotation/main.sdstest @@ -4,10 +4,10 @@ package tests.validation.builtins.experimental.calledAnnotation annotation ExperimentalAnnotation annotation ValidAnnotation -// $TEST$ warning "The called annotation 'ExperimentalAnnotation' is experimental." +# $TEST$ warning "The called annotation 'ExperimentalAnnotation' is experimental." @»ExperimentalAnnotation« -// $TEST$ no warning r"The called annotation '\w*' is experimental\." +# $TEST$ no warning r"The called annotation '\w*' is experimental\." @»ValidAnnotation« -// $TEST$ no warning r"The called annotation '\w*' is experimental\." +# $TEST$ no warning r"The called annotation '\w*' is experimental\." @»Unresolved« -pipeline myPipeline {} +function myFunction () {} diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/corresponding parameter/main.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/corresponding parameter/main.sdstest index ba5934cf..ebe9ce45 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/corresponding parameter/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/corresponding parameter/main.sdstest @@ -5,22 +5,22 @@ fun f( validParameter: Int = 1 ) -pipeline myPipeline { +function myFunction () { f( - // $TEST$ warning "The corresponding parameter 'experimentalParameter' is experimental." + # $TEST$ warning "The corresponding parameter 'experimentalParameter' is experimental." »experimentalParameter = 1«, - // $TEST$ no warning r"The corresponding parameter '\w*' is experimental\." + # $TEST$ no warning r"The corresponding parameter '\w*' is experimental\." »validParameter = 1«, - // $TEST$ no warning r"The corresponding parameter '\w*' is experimental\." + # $TEST$ no warning r"The corresponding parameter '\w*' is experimental\." »unresolved = 1«, ); f( - // $TEST$ warning "The corresponding parameter 'experimentalParameter' is experimental." + # $TEST$ warning "The corresponding parameter 'experimentalParameter' is experimental." »1«, - // $TEST$ no warning r"The corresponding parameter '\w*' is experimental\." + # $TEST$ no warning r"The corresponding parameter '\w*' is experimental\." »1«, - // $TEST$ no warning r"The corresponding parameter '\w*' is experimental\." + # $TEST$ no warning r"The corresponding parameter '\w*' is experimental\." »1«, ); } diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/referenced declaration/from named type/main.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/referenced declaration/from named type/main.sdstest index b2be9f45..4e3671ca 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/referenced declaration/from named type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/referenced declaration/from named type/main.sdstest @@ -12,21 +12,21 @@ enum ValidEnum { } segment mySegment( - // $TEST$ warning "The referenced declaration 'ExperimentalClass' is experimental." + # $TEST$ warning "The referenced declaration 'ExperimentalClass' is experimental." p1: »ExperimentalClass«, - // $TEST$ no warning r"The referenced declaration '\w*' is experimental\." + # $TEST$ no warning r"The referenced declaration '\w*' is experimental\." p2: »ValidClass«, - // $TEST$ warning "The referenced declaration 'ExperimentalEnum' is experimental." + # $TEST$ warning "The referenced declaration 'ExperimentalEnum' is experimental." p3: »ExperimentalEnum«, - // $TEST$ no warning r"The referenced declaration '\w*' is experimental\." + # $TEST$ no warning r"The referenced declaration '\w*' is experimental\." p4: »ValidEnum«, - // $TEST$ warning "The referenced declaration 'ExperimentalEnumVariant' is experimental." + # $TEST$ warning "The referenced declaration 'ExperimentalEnumVariant' is experimental." p5: ValidEnum.»ExperimentalEnumVariant«, - // $TEST$ no warning r"The referenced declaration '\w*' is experimental\." + # $TEST$ no warning r"The referenced declaration '\w*' is experimental\." p6: ValidEnum.»ValidEnumVariant«, - // $TEST$ no warning r"The referenced declaration '\w*' is experimental\." + # $TEST$ no warning r"The referenced declaration '\w*' is experimental\." p7: »Unresolved« ) {} diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/referenced declaration/from reference/main.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/referenced declaration/from reference/main.sdstest index 10745a35..e055945c 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/referenced declaration/from reference/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/experimental/referenced declaration/from reference/main.sdstest @@ -41,56 +41,56 @@ segment mySegment( * Deprecation is only relevant for callers */ - // $TEST$ no warning r"The referenced declaration '\w*' is experimental\." + # $TEST$ no warning r"The referenced declaration '\w*' is experimental\." »experimentalParameter«; - // $TEST$ no warning r"The referenced declaration '\w*' is experimental\." + # $TEST$ no warning r"The referenced declaration '\w*' is experimental\." »validParameter«; - // $TEST$ no warning r"The referenced declaration '\w*' is experimental\." + # $TEST$ no warning r"The referenced declaration '\w*' is experimental\." yield »experimentalResult« = 1; - // $TEST$ no warning r"The referenced declaration '\w*' is experimental\." + # $TEST$ no warning r"The referenced declaration '\w*' is experimental\." yield »validResult« = 1; - // $TEST$ warning "The referenced declaration 'ExperimentalClass' is experimental." + # $TEST$ warning "The referenced declaration 'ExperimentalClass' is experimental." »ExperimentalClass«; - // $TEST$ no warning r"The referenced declaration '\w*' is experimental\." + # $TEST$ no warning r"The referenced declaration '\w*' is experimental\." »ValidClass«; - // $TEST$ warning "The referenced declaration 'experimentalAttribute' is experimental." + # $TEST$ warning "The referenced declaration 'experimentalAttribute' is experimental." ValidClass.»experimentalAttribute«; - // $TEST$ no warning r"The referenced declaration '\w*' is experimental\." + # $TEST$ no warning r"The referenced declaration '\w*' is experimental\." ValidClass.»validAttribute«; - // $TEST$ warning "The referenced declaration 'ExperimentalEnum' is experimental." + # $TEST$ warning "The referenced declaration 'ExperimentalEnum' is experimental." »ExperimentalEnum«; - // $TEST$ no warning r"The referenced declaration '\w*' is experimental\." + # $TEST$ no warning r"The referenced declaration '\w*' is experimental\." »ValidEnum«; - // $TEST$ warning "The referenced declaration 'ExperimentalEnumVariant' is experimental." + # $TEST$ warning "The referenced declaration 'ExperimentalEnumVariant' is experimental." ValidEnum.»ExperimentalEnumVariant«; - // $TEST$ no warning r"The referenced declaration '\w*' is experimental\." + # $TEST$ no warning r"The referenced declaration '\w*' is experimental\." ValidEnum.»ValidEnumVariant«; - // $TEST$ warning "The referenced declaration 'experimentalFunction' is experimental." + # $TEST$ warning "The referenced declaration 'experimentalFunction' is experimental." »experimentalFunction«(); - // $TEST$ no warning r"The referenced declaration '\w*' is experimental\." + # $TEST$ no warning r"The referenced declaration '\w*' is experimental\." »validFunction«(); - // $TEST$ warning "The referenced declaration 'experimentalResult' is experimental." + # $TEST$ warning "The referenced declaration 'experimentalResult' is experimental." validFunction().»experimentalResult«; - // $TEST$ no warning r"The referenced declaration '\w*' is experimental\." + # $TEST$ no warning r"The referenced declaration '\w*' is experimental\." validFunction().»validResult«; - // $TEST$ warning "The referenced declaration 'experimentalSegment' is experimental." + # $TEST$ warning "The referenced declaration 'experimentalSegment' is experimental." »experimentalSegment«(); - // $TEST$ no warning r"The referenced declaration '\w*' is experimental\." + # $TEST$ no warning r"The referenced declaration '\w*' is experimental\." »validSegment«(); - // $TEST$ no warning r"The referenced declaration '\w*' is experimental\." + # $TEST$ no warning r"The referenced declaration '\w*' is experimental\." »unresolved«; } diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/expert/must not be used on required parameters/main.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/expert/must not be used on required parameters/main.sdstest index 9fe2d13d..a543e272 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/expert/must not be used on required parameters/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/expert/must not be used on required parameters/main.sdstest @@ -1,48 +1,48 @@ package tests.validation.builtins.expert.mustNotBeUsedOnRequiredParameters -// $TEST$ error "An expert parameter must be optional." -// $TEST$ no error "An expert parameter must be optional." +# $TEST$ error "An expert parameter must be optional." +# $TEST$ no error "An expert parameter must be optional." annotation MyAnnotation(@Expert »a«: Int, @Expert »b«: Int = 3) -// $TEST$ error "An expert parameter must be optional." -// $TEST$ no error "An expert parameter must be optional." +# $TEST$ error "An expert parameter must be optional." +# $TEST$ no error "An expert parameter must be optional." class MyClass(@Expert »a«: Int, @Expert »b«: Int = 3) { - // $TEST$ error "An expert parameter must be optional." - // $TEST$ no error "An expert parameter must be optional." + # $TEST$ error "An expert parameter must be optional." + # $TEST$ no error "An expert parameter must be optional." class MyClass(@Expert »a«: Int, @Expert »b«: Int = 3) - // $TEST$ error "An expert parameter must be optional." - // $TEST$ no error "An expert parameter must be optional." + # $TEST$ error "An expert parameter must be optional." + # $TEST$ no error "An expert parameter must be optional." fun myFunction(@Expert »a«: Int, @Expert »b«: Int = 3) } enum MyEnum { - // $TEST$ error "An expert parameter must be optional." - // $TEST$ no error "An expert parameter must be optional." + # $TEST$ error "An expert parameter must be optional." + # $TEST$ no error "An expert parameter must be optional." MyEnumVariant(@Expert »a«: Int, @Expert »b«: Int = 3) } -// $TEST$ error "An expert parameter must be optional." -// $TEST$ no error "An expert parameter must be optional." +# $TEST$ error "An expert parameter must be optional." +# $TEST$ no error "An expert parameter must be optional." fun myFunction(@Expert »a«: Int, @Expert »b«: Int = 3) -// $TEST$ error "An expert parameter must be optional." -// $TEST$ no error "An expert parameter must be optional." +# $TEST$ error "An expert parameter must be optional." +# $TEST$ no error "An expert parameter must be optional." segment mySegment1(@Expert »a«: Int, @Expert »b«: Int = 3) {} -// $TEST$ no error "An expert parameter must be optional." -// $TEST$ no error "An expert parameter must be optional." +# $TEST$ no error "An expert parameter must be optional." +# $TEST$ no error "An expert parameter must be optional." segment mySegment2( f: (@Expert »a«: Int, @Expert »b«: Int = 3) -> () ) { - // $TEST$ no error "An expert parameter must be optional." - // $TEST$ no error "An expert parameter must be optional." + # $TEST$ no error "An expert parameter must be optional." + # $TEST$ no error "An expert parameter must be optional." val g = (@Expert »a«: Int, @Expert »b«: Int = 3) {}; - // $TEST$ no error "An expert parameter must be optional." - // $TEST$ no error "An expert parameter must be optional." + # $TEST$ no error "An expert parameter must be optional." + # $TEST$ no error "An expert parameter must be optional." val h = (@Expert »a«: Int, @Expert »b«: Int = 3) -> 1; } diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonCall/main.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonCall/main.sdstest index 80b97dcb..14395788 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonCall/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonCall/main.sdstest @@ -1,39 +1,39 @@ package tests.validation.builtins.pythonCall class MyClass { - // $TEST$ no error r"The template expressions? .* cannot be interpreted." + # $TEST$ no error r"The template expressions? .* cannot be interpreted." @»PythonCall«("myMethod1($param)") fun myMethod1(param: Int) - // $TEST$ no error r"The template expressions? .* cannot be interpreted." + # $TEST$ no error r"The template expressions? .* cannot be interpreted." @»PythonCall«("myMethod2($this)") fun myMethod2(this: Int) - // $TEST$ no error "The template expression '$this' cannot be interpreted." + # $TEST$ no error "The template expression '$this' cannot be interpreted." @»PythonCall«("myMethod3($this)") fun myMethod3() - // $TEST$ error "The template expressions '$param1', '$param2' cannot be interpreted." + # $TEST$ error "The template expressions '$param1', '$param2' cannot be interpreted." @»PythonCall«("myMethod4($param1, $param2)") fun myMethod4() } -// $TEST$ no error r"The template expressions? .* cannot be interpreted." +# $TEST$ no error r"The template expressions? .* cannot be interpreted." @»PythonCall«("myFunction1($param)") fun myFunction1(param: Int) -// $TEST$ no error r"The template expressions? .* cannot be interpreted." +# $TEST$ no error r"The template expressions? .* cannot be interpreted." @»PythonCall«("myFunction2($this)") fun myFunction2(this: Int) -// $TEST$ error "The template expression '$this' cannot be interpreted." +# $TEST$ error "The template expression '$this' cannot be interpreted." @»PythonCall«("myFunction3($this)") fun myFunction3() -// $TEST$ error "The template expressions '$param1', '$param2' cannot be interpreted." +# $TEST$ error "The template expressions '$param1', '$param2' cannot be interpreted." @»PythonCall«("myFunction4($param1, $param2)") fun myFunction4() -// $TEST$ no error "An expert parameter must be optional." +# $TEST$ no error "An expert parameter must be optional." @»PythonCall«("$this") annotation MyAnnotation() diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonModule/error.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonModule/error.sdstest index ae533409..6b8be803 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonModule/error.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonModule/error.sdstest @@ -1,4 +1,4 @@ -// $TEST$ info "The Python module is identical to the TTSL package, so the annotation call can be removed." +# $TEST$ info "The Python module is identical to the TTSL package, so the annotation call can be removed." @»PythonModule«("tests.validation.builtins.annotations.pythonModule") package tests.validation.builtins.annotations.pythonModule diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonModule/no annotation.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonModule/no annotation.sdstest index ad60f338..3443e84f 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonModule/no annotation.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonModule/no annotation.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no info "The Python module is identical to the TTSL package, so the annotation call can be removed." +# $TEST$ no info "The Python module is identical to the TTSL package, so the annotation call can be removed." package tests.validation.builtins.annotations.pythonModule diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonModule/no error.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonModule/no error.sdstest index 751e6a1f..a0332b9e 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonModule/no error.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonModule/no error.sdstest @@ -1,6 +1,6 @@ -// $TEST$ no info "The Python module is identical to the TTSL package, so the annotation call can be removed." +# $TEST$ no info "The Python module is identical to the TTSL package, so the annotation call can be removed." @»PythonModule«("tests.validation.builtins.annotations.pythonModule.other") -// $TEST$ no info "The Python module is identical to the TTSL package, so the annotation call can be removed." +# $TEST$ no info "The Python module is identical to the TTSL package, so the annotation call can be removed." @»PythonModule«("tests.validation.builtins.annotations.pythonModule") package tests.validation.builtins.annotations.pythonModule diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonName/identical to safe-ds name/main.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonName/identical to safe-ds name/main.sdstest index 42ff9d28..a7cf4953 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonName/identical to safe-ds name/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonName/identical to safe-ds name/main.sdstest @@ -1,11 +1,11 @@ package tests.validation.builtins.annotations.pythonName.identicalToTTSLName -// $TEST$ info "The Python name is identical to the TTSL name, so the annotation call can be removed." +# $TEST$ info "The Python name is identical to the TTSL name, so the annotation call can be removed." @»PythonName«("TestClass1") class TestClass1 -// $TEST$ no info "The Python name is identical to the TTSL name, so the annotation call can be removed." +# $TEST$ no info "The Python name is identical to the TTSL name, so the annotation call can be removed." @»PythonName«("Test_Class_2") -// $TEST$ no info "The Python name is identical to the TTSL name, so the annotation call can be removed." +# $TEST$ no info "The Python name is identical to the TTSL name, so the annotation call can be removed." @»PythonName«("TestClass2") class TestClass2 diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonName/identical to safe-ds name/no annotation.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonName/identical to safe-ds name/no annotation.sdstest index 7fa20f30..d40e1a7c 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonName/identical to safe-ds name/no annotation.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonName/identical to safe-ds name/no annotation.sdstest @@ -1,4 +1,4 @@ package tests.validation.builtins.annotations.pythonName.identicalToTTSLName -// $TEST$ no info "The Python name is identical to the TTSL name, so the annotation call can be removed." +# $TEST$ no info "The Python name is identical to the TTSL name, so the annotation call can be removed." class TestClass3 diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonName/mutually exclusive with python call/main.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonName/mutually exclusive with python call/main.sdstest index 23901ea2..f30c3d34 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonName/mutually exclusive with python call/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/pythonName/mutually exclusive with python call/main.sdstest @@ -1,26 +1,26 @@ package tests.validation.builtins.annotations.pythonName.mutuallyExclusiveWithPythonCall @PythonCall("myFunction1()") -// $TEST$ error "A Python name must not be set if a Python call is set." +# $TEST$ error "A Python name must not be set if a Python call is set." @»PythonName«("my_function_1") -// $TEST$ no error "A Python name must not be set if a Python call is set." +# $TEST$ no error "A Python name must not be set if a Python call is set." @»PythonName«("my_function_1") fun myFunction1() -// $TEST$ error "A Python name must not be set if a Python call is set." +# $TEST$ error "A Python name must not be set if a Python call is set." @»PythonName«("my_function_2") -// $TEST$ no error "A Python name must not be set if a Python call is set." +# $TEST$ no error "A Python name must not be set if a Python call is set." @»PythonName«("my_function_2") @PythonCall("myFunction2()") fun myFunction2() -// $TEST$ no error "A Python name must not be set if a Python call is set." +# $TEST$ no error "A Python name must not be set if a Python call is set." @»PythonName«("my_function_3") fun myFunction3() -// $TEST$ no error "A Python name must not be set if a Python call is set." +# $TEST$ no error "A Python name must not be set if a Python call is set." @»PythonName«("my_function_2") -// $TEST$ no error "A Python name must not be set if a Python call is set." +# $TEST$ no error "A Python name must not be set if a Python call is set." @»PythonName«("my_function_2") @PythonCall("myFunction2()") class MyClass() diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/repeatable/main.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/repeatable/main.sdstest index ffbe0d36..10b91850 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/repeatable/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/repeatable/main.sdstest @@ -5,20 +5,20 @@ annotation SingleUse @Repeatable annotation MultiUse -// $TEST$ no error r"The annotation '\w*' is not repeatable\." +# $TEST$ no error r"The annotation '\w*' is not repeatable\." @»SingleUse« -// $TEST$ no error r"The annotation '\w*' is not repeatable\." +# $TEST$ no error r"The annotation '\w*' is not repeatable\." @»MultiUse« -// $TEST$ no error r"The annotation '\w*' is not repeatable\." +# $TEST$ no error r"The annotation '\w*' is not repeatable\." @»MultiUse« -// $TEST$ no error r"The annotation '\w*' is not repeatable\." +# $TEST$ no error r"The annotation '\w*' is not repeatable\." @»UnresolvedAnnotation« -// $TEST$ no error r"The annotation '\w*' is not repeatable\." +# $TEST$ no error r"The annotation '\w*' is not repeatable\." @»UnresolvedAnnotation« class CorrectUse -// $TEST$ no error r"The annotation '\w*' is not repeatable\." +# $TEST$ no error r"The annotation '\w*' is not repeatable\." @»SingleUse« -// $TEST$ error "The annotation 'SingleUse' is not repeatable." +# $TEST$ error "The annotation 'SingleUse' is not repeatable." @»SingleUse« class IncorrectUse diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/target/duplicate target/main.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/target/duplicate target/main.sdstest index 72baa16f..a89a21b1 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/target/duplicate target/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/target/duplicate target/main.sdstest @@ -1,7 +1,7 @@ package tests.validation.builtins.annotations.target.duplicateTarget @Target([ - // $TEST$ no warning "The target 'Annotation' was set already." + # $TEST$ no warning "The target 'Annotation' was set already." »AnnotationTarget.Annotation« ]) @@ -10,33 +10,33 @@ package tests.validation.builtins.annotations.target.duplicateTarget */ @Target([ - // $TEST$ no warning "The target 'Annotation' was set already." + # $TEST$ no warning "The target 'Annotation' was set already." »AnnotationTarget.Annotation«, - // $TEST$ no warning "The target 'Annotation' was set already." + # $TEST$ no warning "The target 'Annotation' was set already." »AnnotationTarget.Annotation«, ]) annotation TestAnnotation1 @Target([ - // $TEST$ no warning "The target 'Annotation' was set already." + # $TEST$ no warning "The target 'Annotation' was set already." »AnnotationTarget.Annotation«, - // $TEST$ warning "The target 'Annotation' was set already." + # $TEST$ warning "The target 'Annotation' was set already." »AnnotationTarget.Annotation«, ]) annotation TestAnnotation2 @Target([ - // $TEST$ no warning "The target 'Class' was set already." + # $TEST$ no warning "The target 'Class' was set already." »AnnotationTarget.Class«, - // $TEST$ warning "The target 'Class' was set already." + # $TEST$ warning "The target 'Class' was set already." »AnnotationTarget.Class«, - // $TEST$ warning "The target 'Class' was set already." + # $TEST$ warning "The target 'Class' was set already." »AnnotationTarget.Class«, - // $TEST$ no warning "The target 'Annotation' was set already." + # $TEST$ no warning "The target 'Annotation' was set already." »AnnotationTarget.Annotation«, - // $TEST$ warning "The target 'Annotation' was set already." + # $TEST$ warning "The target 'Annotation' was set already." »AnnotationTarget.Annotation«, - // $TEST$ warning "The target 'Annotation' was set already." + # $TEST$ warning "The target 'Annotation' was set already." »AnnotationTarget.Annotation«, ]) annotation TestAnnotation3 @@ -46,17 +46,17 @@ annotation TestAnnotation3 */ @Target( - // $TEST$ no warning "The target 'Class' was set already." + # $TEST$ no warning "The target 'Class' was set already." »AnnotationTarget.Class«, - // $TEST$ no warning "The target 'Class' was set already." + # $TEST$ no warning "The target 'Class' was set already." »AnnotationTarget.Class« ) annotation TestAnnotation4 @Target([ - // $TEST$ no warning r"The target '.*' was set already\." + # $TEST$ no warning r"The target '.*' was set already\." »1«, - // $TEST$ no warning r"The target '.*' was set already\." + # $TEST$ no warning r"The target '.*' was set already\." »1«, ]) annotation TestAnnotation5 diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/target/duplicate target/no target annotation.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/target/duplicate target/no target annotation.sdstest index c23ee214..8264ccf4 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/target/duplicate target/no target annotation.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/target/duplicate target/no target annotation.sdstest @@ -1,5 +1,5 @@ package tests.validation.builtins.annotations.target.duplicateTarget -// $TEST$ no warning r"The target '.*' was already set\." +# $TEST$ no warning r"The target '.*' was already set\." annotation TestAnnotation6 diff --git a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/target/wrong target/main.sdstest b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/target/wrong target/main.sdstest index b506ff37..643571a9 100644 --- a/packages/ttsl-lang/tests/resources/validation/builtins/annotations/target/wrong target/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/builtins/annotations/target/wrong target/main.sdstest @@ -1,12 +1,12 @@ -// $TEST$ error "The annotation 'AnnotationForEnums' cannot be applied to a module." +# $TEST$ error "The annotation 'AnnotationForEnums' cannot be applied to a module." @»AnnotationForEnums« -// $TEST$ no error r"This annotation '.*' cannot be applied to .*" +# $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForModules« -// $TEST$ no error r"This annotation '.*' cannot be applied to .*" +# $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForMultipleTargets« -// $TEST$ no error r"This annotation '.*' cannot be applied to .*" +# $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForAnything« -// $TEST$ no error r"This annotation '.*' cannot be applied to .*" +# $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»Unresolved« package tests.validation.builtins.annotations.target.wrongTarget @@ -54,119 +54,119 @@ annotation AnnotationForAnything /* Test declarations -------------------------------------------------------- */ -// $TEST$ error "The annotation 'AnnotationForAttributes' cannot be applied to an annotation." +# $TEST$ error "The annotation 'AnnotationForAttributes' cannot be applied to an annotation." @»AnnotationForAttributes« -// $TEST$ no error r"This annotation '.*' cannot be applied to .*" +# $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForAnnotations« -// $TEST$ no error r"This annotation '.*' cannot be applied to .*" +# $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForAnything« -// $TEST$ no error r"This annotation '.*' cannot be applied to .*" +# $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»Unresolved« annotation TestAnnotation -// $TEST$ error "The annotation 'AnnotationForModules' cannot be applied to a class." +# $TEST$ error "The annotation 'AnnotationForModules' cannot be applied to a class." @»AnnotationForModules« -// $TEST$ no error r"This annotation '.*' cannot be applied to .*" +# $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForClasses« -// $TEST$ no error r"This annotation '.*' cannot be applied to .*" +# $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForMultipleTargets« -// $TEST$ no error r"This annotation '.*' cannot be applied to .*" +# $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForAnything« -// $TEST$ no error r"This annotation '.*' cannot be applied to .*" +# $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»Unresolved« class TestClass< - // $TEST$ error "The annotation 'AnnotationForPipelines' cannot be applied to a type parameter." + # $TEST$ error "The annotation 'AnnotationForPipelines' cannot be applied to a type parameter." @»AnnotationForPipelines« - // $TEST$ no error r"This annotation '.*' cannot be applied to .*" + # $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForTypeParameters« - // $TEST$ no error r"This annotation '.*' cannot be applied to .*" + # $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForAnything« - // $TEST$ no error r"This annotation '.*' cannot be applied to .*" + # $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»Unresolved« TEST_TYPE_PARAMETER > { - // $TEST$ error "The annotation 'AnnotationForClasses' cannot be applied to an attribute." + # $TEST$ error "The annotation 'AnnotationForClasses' cannot be applied to an attribute." @»AnnotationForClasses« - // $TEST$ no error r"This annotation '.*' cannot be applied to .*" + # $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForAttributes« - // $TEST$ no error r"This annotation '.*' cannot be applied to .*" + # $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForAnything« - // $TEST$ no error r"This annotation '.*' cannot be applied to .*" + # $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»Unresolved« attr testAttribute: Int } -// $TEST$ error "The annotation 'AnnotationForEnumVariants' cannot be applied to an enum." +# $TEST$ error "The annotation 'AnnotationForEnumVariants' cannot be applied to an enum." @»AnnotationForEnumVariants« -// $TEST$ no error r"This annotation '.*' cannot be applied to .*" +# $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForEnums« -// $TEST$ no error r"This annotation '.*' cannot be applied to .*" +# $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForAnything« -// $TEST$ no error r"This annotation '.*' cannot be applied to .*" +# $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»Unresolved« enum TestEnum { - // $TEST$ error "The annotation 'AnnotationForFunctions' cannot be applied to an enum variant." + # $TEST$ error "The annotation 'AnnotationForFunctions' cannot be applied to an enum variant." @»AnnotationForFunctions« - // $TEST$ no error r"This annotation '.*' cannot be applied to .*" + # $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForEnumVariants« - // $TEST$ no error r"This annotation '.*' cannot be applied to .*" + # $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForAnything« - // $TEST$ no error r"This annotation '.*' cannot be applied to .*" + # $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»Unresolved« TestEnumVariant } -// $TEST$ error "The annotation 'AnnotationForParameters' cannot be applied to a function." +# $TEST$ error "The annotation 'AnnotationForParameters' cannot be applied to a function." @»AnnotationForParameters« -// $TEST$ no error r"This annotation '.*' cannot be applied to .*" +# $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForFunctions« -// $TEST$ no error r"This annotation '.*' cannot be applied to .*" +# $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForAnything« -// $TEST$ no error r"This annotation '.*' cannot be applied to .*" +# $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»Unresolved« fun testFunction( - // $TEST$ error "The annotation 'AnnotationForResults' cannot be applied to a parameter." + # $TEST$ error "The annotation 'AnnotationForResults' cannot be applied to a parameter." @»AnnotationForResults« - // $TEST$ no error r"This annotation '.*' cannot be applied to .*" + # $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForParameters« - // $TEST$ no error r"This annotation '.*' cannot be applied to .*" + # $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForAnything« - // $TEST$ no error r"This annotation '.*' cannot be applied to .*" + # $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»Unresolved« testParameter: Int ) -> ( - // $TEST$ error "The annotation 'AnnotationForTypeParameters' cannot be applied to a result." + # $TEST$ error "The annotation 'AnnotationForTypeParameters' cannot be applied to a result." @»AnnotationForTypeParameters« - // $TEST$ no error r"This annotation '.*' cannot be applied to .*" + # $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForResults« - // $TEST$ no error r"This annotation '.*' cannot be applied to .*" + # $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForAnything« - // $TEST$ no error r"This annotation '.*' cannot be applied to .*" + # $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»Unresolved« testResult: Int ) -// $TEST$ error "The annotation 'AnnotationForSegments' cannot be applied to a pipeline." +# $TEST$ error "The annotation 'AnnotationForSegments' cannot be applied to a pipeline." @»AnnotationForSegments« -// $TEST$ no error r"This annotation '.*' cannot be applied to .*" +# $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForPipelines« -// $TEST$ no error r"This annotation '.*' cannot be applied to .*" +# $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForAnything« -// $TEST$ no error r"This annotation '.*' cannot be applied to .*" +# $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»Unresolved« pipeline testPipeline {} -// $TEST$ error "The annotation 'AnnotationForAnnotations' cannot be applied to a segment." +# $TEST$ error "The annotation 'AnnotationForAnnotations' cannot be applied to a segment." @»AnnotationForAnnotations« -// $TEST$ no error r"This annotation '.*' cannot be applied to .*" +# $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForSegments« -// $TEST$ no error r"This annotation '.*' cannot be applied to .*" +# $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»AnnotationForAnything« -// $TEST$ no error r"This annotation '.*' cannot be applied to .*" +# $TEST$ no error r"This annotation '.*' cannot be applied to .*" @»Unresolved« segment testSegment() {} diff --git a/packages/ttsl-lang/tests/resources/validation/experimental language feature/constraint lists/main.sdstest b/packages/ttsl-lang/tests/resources/validation/experimental language feature/constraint lists/main.sdstest index d76b39b0..16e84f21 100644 --- a/packages/ttsl-lang/tests/resources/validation/experimental language feature/constraint lists/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/experimental language feature/constraint lists/main.sdstest @@ -1,4 +1,4 @@ package tests.validation.experimentalLanguageFeature.constraintLists -// $TEST$ warning "Constraint lists & constraints are experimental and may change without prior notice." +# $TEST$ warning "Constraint lists & constraints are experimental and may change without prior notice." fun myFunction() »where« {} diff --git a/packages/ttsl-lang/tests/resources/validation/experimental language feature/literal types/main.sdstest b/packages/ttsl-lang/tests/resources/validation/experimental language feature/literal types/main.sdstest index 369e22d5..0cee689c 100644 --- a/packages/ttsl-lang/tests/resources/validation/experimental language feature/literal types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/experimental language feature/literal types/main.sdstest @@ -1,6 +1,6 @@ package tests.validation.experimentalLanguageFeature.literalTypes fun myFunction( - // $TEST$ warning "Literal types are experimental and may change without prior notice." + # $TEST$ warning "Literal types are experimental and may change without prior notice." p: »literal«<> ) diff --git a/packages/ttsl-lang/tests/resources/validation/experimental language feature/maps/main.sdstest b/packages/ttsl-lang/tests/resources/validation/experimental language feature/maps/main.sdstest index 9addb92a..3836c069 100644 --- a/packages/ttsl-lang/tests/resources/validation/experimental language feature/maps/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/experimental language feature/maps/main.sdstest @@ -1,9 +1,9 @@ package tests.validation.experimentalLanguageFeature.maps -pipeline myPipeline { - // $TEST$ warning "Map literals are experimental and may change without prior notice." +function myFunction () { + # $TEST$ warning "Map literals are experimental and may change without prior notice." »{"a": "b"}«; - // $TEST$ no warning "Map literals are experimental and may change without prior notice." + # $TEST$ no warning "Map literals are experimental and may change without prior notice." {"a": »{}«}; } diff --git a/packages/ttsl-lang/tests/resources/validation/experimental language feature/union types/main.sdstest b/packages/ttsl-lang/tests/resources/validation/experimental language feature/union types/main.sdstest index 2db26e87..64322513 100644 --- a/packages/ttsl-lang/tests/resources/validation/experimental language feature/union types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/experimental language feature/union types/main.sdstest @@ -1,13 +1,13 @@ package tests.validation.experimentalLanguageFeature.unionTypes fun myFunction( - // $TEST$ warning "Union types are experimental and may change without prior notice." + # $TEST$ warning "Union types are experimental and may change without prior notice." p: »union«, - // $TEST$ no warning "Union types are experimental and may change without prior notice." + # $TEST$ no warning "Union types are experimental and may change without prior notice." q: union<»union«, Int>, - // $TEST$ no warning "Union types are experimental and may change without prior notice." - // $TEST$ no warning "Union types are experimental and may change without prior notice." + # $TEST$ no warning "Union types are experimental and may change without prior notice." + # $TEST$ no warning "Union types are experimental and may change without prior notice." r: union<(p: »union«) -> (r: »union«), Int>, ) diff --git a/packages/ttsl-lang/tests/resources/validation/inheritance/must be acyclic/main.sdstest b/packages/ttsl-lang/tests/resources/validation/inheritance/must be acyclic/main.sdstest index 84def22e..ee488f61 100644 --- a/packages/ttsl-lang/tests/resources/validation/inheritance/must be acyclic/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/inheritance/must be acyclic/main.sdstest @@ -1,22 +1,22 @@ package tests.validation.inheritance.mustBeAcyclic -// $TEST$ error "A class must not directly or indirectly be a subtype of itself." +# $TEST$ error "A class must not directly or indirectly be a subtype of itself." class MyClass1 sub »MyClass3« -// $TEST$ error "A class must not directly or indirectly be a subtype of itself." +# $TEST$ error "A class must not directly or indirectly be a subtype of itself." class MyClass2 sub »MyClass1« -// $TEST$ error "A class must not directly or indirectly be a subtype of itself." +# $TEST$ error "A class must not directly or indirectly be a subtype of itself." class MyClass3 sub »MyClass2« class MyClass4 -// $TEST$ no error "A class must not directly or indirectly be a subtype of itself." +# $TEST$ no error "A class must not directly or indirectly be a subtype of itself." class MyClass5 sub »MyClass4« -// $TEST$ no error "A class must not directly or indirectly be a subtype of itself." +# $TEST$ no error "A class must not directly or indirectly be a subtype of itself." class MyClass6 sub »MyClass7« -// $TEST$ no error "A class must not directly or indirectly be a subtype of itself." +# $TEST$ no error "A class must not directly or indirectly be a subtype of itself." class MyClass7 sub Any, »MyClass6« -// $TEST$ no error "A class must not directly or indirectly be a subtype of itself." +# $TEST$ no error "A class must not directly or indirectly be a subtype of itself." class MyClass8 sub »Unresolved« -// $TEST$ no error "A class must not directly or indirectly be a subtype of itself." +# $TEST$ no error "A class must not directly or indirectly be a subtype of itself." class MyClass9 sub »MyClass8« diff --git a/packages/ttsl-lang/tests/resources/validation/inheritance/must inherit only classes/class with parent types.sdstest b/packages/ttsl-lang/tests/resources/validation/inheritance/must inherit only classes/class with parent types.sdstest index fcb6c6c0..71de5ac8 100644 --- a/packages/ttsl-lang/tests/resources/validation/inheritance/must inherit only classes/class with parent types.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/inheritance/must inherit only classes/class with parent types.sdstest @@ -7,28 +7,28 @@ enum MyEnum { MyEnumVariant } -// $TEST$ no error "A class must only inherit classes." -// $TEST$ no error "A class must only inherit classes." -// $TEST$ no error "A class must only inherit classes." -// $TEST$ no error "A class must only inherit classes." -// $TEST$ no error "A class must only inherit classes." +# $TEST$ no error "A class must only inherit classes." +# $TEST$ no error "A class must only inherit classes." +# $TEST$ no error "A class must only inherit classes." +# $TEST$ no error "A class must only inherit classes." +# $TEST$ no error "A class must only inherit classes." class TestClass1 sub »MyClass«, »MyClass.MyNestedClass«, »MyEnum«, »MyEnum.MyEnumVariant«, »Unresolved« -// $TEST$ no error "A class must only inherit classes." +# $TEST$ no error "A class must only inherit classes." class TestClass2 sub »MyClass« -// $TEST$ no error "A class must only inherit classes." +# $TEST$ no error "A class must only inherit classes." class TestClass3 sub »MyClass.MyNestedClass« -// $TEST$ error "A class must only inherit classes." +# $TEST$ error "A class must only inherit classes." class TestClass4 sub »MyEnum« -// $TEST$ error "A class must only inherit classes." +# $TEST$ error "A class must only inherit classes." class TestClass5 sub »MyEnum.MyEnumVariant« -// $TEST$ no error "A class must only inherit classes." +# $TEST$ no error "A class must only inherit classes." class TestClass6 sub »Unresolved« diff --git a/packages/ttsl-lang/tests/resources/validation/inheritance/must inherit only classes/class without parent types.sdstest b/packages/ttsl-lang/tests/resources/validation/inheritance/must inherit only classes/class without parent types.sdstest index eb1fc7ec..306d5a81 100644 --- a/packages/ttsl-lang/tests/resources/validation/inheritance/must inherit only classes/class without parent types.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/inheritance/must inherit only classes/class without parent types.sdstest @@ -1,4 +1,4 @@ package tests.validation.inheritance.mustInheritOnlyClasses -// $TEST$ no error "A class must only inherit classes." +# $TEST$ no error "A class must only inherit classes." class TestClass7 diff --git a/packages/ttsl-lang/tests/resources/validation/inheritance/must not be nullable/class with parent types.sdstest b/packages/ttsl-lang/tests/resources/validation/inheritance/must not be nullable/class with parent types.sdstest index 78a28da2..4574d236 100644 --- a/packages/ttsl-lang/tests/resources/validation/inheritance/must not be nullable/class with parent types.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/inheritance/must not be nullable/class with parent types.sdstest @@ -7,28 +7,28 @@ enum MyEnum { MyEnumVariant } -// $TEST$ no error "The parent type must not be nullable." -// $TEST$ no error "The parent type must not be nullable." -// $TEST$ no error "The parent type must not be nullable." -// $TEST$ no error "The parent type must not be nullable." -// $TEST$ no error "The parent type must not be nullable." +# $TEST$ no error "The parent type must not be nullable." +# $TEST$ no error "The parent type must not be nullable." +# $TEST$ no error "The parent type must not be nullable." +# $TEST$ no error "The parent type must not be nullable." +# $TEST$ no error "The parent type must not be nullable." class TestClass1 sub »MyClass«, »MyClass.MyNestedClass?«, »MyEnum?«, »MyEnum.MyEnumVariant?«, »Unresolved?« -// $TEST$ error "The parent type must not be nullable." +# $TEST$ error "The parent type must not be nullable." class TestClass2 sub »MyClass?« -// $TEST$ error "The parent type must not be nullable." +# $TEST$ error "The parent type must not be nullable." class TestClass3 sub »MyClass.MyNestedClass?« -// $TEST$ no error "The parent type must not be nullable." +# $TEST$ no error "The parent type must not be nullable." class TestClass4 sub »MyEnum?« -// $TEST$ no error "The parent type must not be nullable." +# $TEST$ no error "The parent type must not be nullable." class TestClass5 sub »MyEnum.MyEnumVariant?« -// $TEST$ no error "The parent type must not be nullable." +# $TEST$ no error "The parent type must not be nullable." class TestClass6 sub »Unresolved?« diff --git a/packages/ttsl-lang/tests/resources/validation/inheritance/no multiple inheritance/class with parent types.sdstest b/packages/ttsl-lang/tests/resources/validation/inheritance/no multiple inheritance/class with parent types.sdstest index 60b064db..5d4ed2a2 100644 --- a/packages/ttsl-lang/tests/resources/validation/inheritance/no multiple inheritance/class with parent types.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/inheritance/no multiple inheritance/class with parent types.sdstest @@ -7,12 +7,12 @@ enum MyEnum { MyEnumVariant } -// $TEST$ no error "Multiple inheritance is not supported. Only the first parent type will be considered." -// $TEST$ error "Multiple inheritance is not supported. Only the first parent type will be considered." -// $TEST$ error "Multiple inheritance is not supported. Only the first parent type will be considered." -// $TEST$ error "Multiple inheritance is not supported. Only the first parent type will be considered." -// $TEST$ error "Multiple inheritance is not supported. Only the first parent type will be considered." -// $TEST$ error "Multiple inheritance is not supported. Only the first parent type will be considered." +# $TEST$ no error "Multiple inheritance is not supported. Only the first parent type will be considered." +# $TEST$ error "Multiple inheritance is not supported. Only the first parent type will be considered." +# $TEST$ error "Multiple inheritance is not supported. Only the first parent type will be considered." +# $TEST$ error "Multiple inheritance is not supported. Only the first parent type will be considered." +# $TEST$ error "Multiple inheritance is not supported. Only the first parent type will be considered." +# $TEST$ error "Multiple inheritance is not supported. Only the first parent type will be considered." class TestClass1 sub »MyClass«, »MyClass.MyNestedClass«, »MyEnum«, diff --git a/packages/ttsl-lang/tests/resources/validation/inheritance/no multiple inheritance/class without parent types.sdstest b/packages/ttsl-lang/tests/resources/validation/inheritance/no multiple inheritance/class without parent types.sdstest index 3233e0ff..ac4fdf60 100644 --- a/packages/ttsl-lang/tests/resources/validation/inheritance/no multiple inheritance/class without parent types.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/inheritance/no multiple inheritance/class without parent types.sdstest @@ -1,4 +1,4 @@ package tests.validation.inheritance.noMultipleInheritance -// $TEST$ no error "Multiple inheritance is not supported. Only the first parent type will be considered." +# $TEST$ no error "Multiple inheritance is not supported. Only the first parent type will be considered." class TestClass2 diff --git a/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method must match overridden method/main.sdstest b/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method must match overridden method/main.sdstest index 05d224e1..0de22fd9 100644 --- a/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method must match overridden method/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method must match overridden method/main.sdstest @@ -9,47 +9,47 @@ class MySuperClass1 { } class MyClass1 sub MySuperClass1 { - // $TEST$ no error r"Overriding member does not match the overridden member:.*" + # $TEST$ no error r"Overriding member does not match the overridden member:.*" attr »myInstanceAttribute«: Int - // $TEST$ no error r"Overriding member does not match the overridden member:.*" + # $TEST$ no error r"Overriding member does not match the overridden member:.*" static attr »myStaticAttribute«: Int - // $TEST$ no error r"Overriding member does not match the overridden member:.*" + # $TEST$ no error r"Overriding member does not match the overridden member:.*" attr »myInstanceAttribute«: Any - // $TEST$ no error r"Overriding member does not match the overridden member:.*" + # $TEST$ no error r"Overriding member does not match the overridden member:.*" static attr »myStaticAttribute«: Any - // $TEST$ no error r"Overriding member does not match the overridden member:.*" + # $TEST$ no error r"Overriding member does not match the overridden member:.*" attr »myOwnInstanceAttribute«: Int - // $TEST$ no error r"Overriding member does not match the overridden member:.*" + # $TEST$ no error r"Overriding member does not match the overridden member:.*" static attr »myOwnStaticAttribute«: Int - // $TEST$ no error r"Overriding member does not match the overridden member:.*" + # $TEST$ no error r"Overriding member does not match the overridden member:.*" @Pure fun »myInstanceMethod«(a: Any = 0) -> r: Int - // $TEST$ no error r"Overriding member does not match the overridden member:.*" + # $TEST$ no error r"Overriding member does not match the overridden member:.*" @Pure static fun »myStaticMethod«(a: Any = 0) -> r: Int - // $TEST$ no error r"Overriding member does not match the overridden member:.*" + # $TEST$ no error r"Overriding member does not match the overridden member:.*" @Pure fun »myInstanceMethod«() -> r: Int - // $TEST$ no error r"Overriding member does not match the overridden member:.*" + # $TEST$ no error r"Overriding member does not match the overridden member:.*" @Pure static fun »myStaticMethod«() -> r: Int - // $TEST$ no error r"Overriding member does not match the overridden member:.*" + # $TEST$ no error r"Overriding member does not match the overridden member:.*" @Pure fun »myOwnInstanceMethod«(a: Any = 0) -> r: Int - // $TEST$ no error r"Overriding member does not match the overridden member:.*" + # $TEST$ no error r"Overriding member does not match the overridden member:.*" @Pure static fun »myOwnStaticMethod«(a: Any = 0) -> r: Int } class MyClass2 sub MySuperClass1 { - // $TEST$ error r"Overriding member does not match the overridden member:.*" + # $TEST$ error r"Overriding member does not match the overridden member:.*" attr »myInstanceAttribute«: Any - // $TEST$ no error r"Overriding member does not match the overridden member:.*" + # $TEST$ no error r"Overriding member does not match the overridden member:.*" static attr »myStaticAttribute«: Any - // $TEST$ error r"Overriding member does not match the overridden member:.*" + # $TEST$ error r"Overriding member does not match the overridden member:.*" @Pure fun »myInstanceMethod«(a: Number = 0) -> r: Any - // $TEST$ no error r"Overriding member does not match the overridden member:.*" + # $TEST$ no error r"Overriding member does not match the overridden member:.*" @Pure static fun »myStaticMethod«(a: Number = 0) -> r: Any } diff --git a/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method must match overridden method/type parameters.sdstest b/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method must match overridden method/type parameters.sdstest index 04b5fcea..5d404836 100644 --- a/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method must match overridden method/type parameters.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method must match overridden method/type parameters.sdstest @@ -8,39 +8,39 @@ class MySuperClass { } class MyClass1 sub MySuperClass { - // $TEST$ no error r"Overriding member does not match the overridden member:.*" + # $TEST$ no error r"Overriding member does not match the overridden member:.*" attr »myInstanceAttribute«: Int - // $TEST$ no error r"Overriding member does not match the overridden member:.*" + # $TEST$ no error r"Overriding member does not match the overridden member:.*" @Pure fun »myInstanceMethod1«(a: Any = 0) -> r: Int } class MyClass2 sub MySuperClass { - // $TEST$ no error r"Overriding member does not match the overridden member:.*" + # $TEST$ no error r"Overriding member does not match the overridden member:.*" attr »myInstanceAttribute«: T - // $TEST$ no error r"Overriding member does not match the overridden member:.*" + # $TEST$ no error r"Overriding member does not match the overridden member:.*" @Pure fun »myInstanceMethod1«(a: T = 0) -> r: T } class MyClass3 sub MySuperClass { - // $TEST$ error r"Overriding member does not match the overridden member:.*" + # $TEST$ error r"Overriding member does not match the overridden member:.*" attr »myInstanceAttribute«: Any - // $TEST$ error r"Overriding member does not match the overridden member:.*" + # $TEST$ error r"Overriding member does not match the overridden member:.*" @Pure fun »myInstanceMethod1«(a: Number = 0) -> r: Any } class MyClass4 sub MySuperClass { - // $TEST$ no error r"Overriding member does not match the overridden member:.*" + # $TEST$ no error r"Overriding member does not match the overridden member:.*" @Pure fun »myInstanceMethod2«(a: T) -> r: T - // $TEST$ no error r"Overriding member does not match the overridden member:.*" + # $TEST$ no error r"Overriding member does not match the overridden member:.*" @Pure fun »myInstanceMethod3«(a: T) -> r: T } class MyClass5 sub MySuperClass { - // $TEST$ error r"Overriding member does not match the overridden member:.*" + # $TEST$ error r"Overriding member does not match the overridden member:.*" @Pure fun »myInstanceMethod3«(a: Int) -> r: Int } class MyClass6 sub MySuperClass { - // $TEST$ error r"Overriding member does not match the overridden member:.*" + # $TEST$ error r"Overriding member does not match the overridden member:.*" attr »myInstanceAttribute«: T } diff --git a/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method should differ from overridden method/main.sdstest b/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method should differ from overridden method/main.sdstest index ea87ac37..f91e098d 100644 --- a/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method should differ from overridden method/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method should differ from overridden method/main.sdstest @@ -9,47 +9,47 @@ class MySuperClass1 { } class MyClass1 sub MySuperClass1 { - // $TEST$ info "Overriding member is identical to overridden member and can be removed." + # $TEST$ info "Overriding member is identical to overridden member and can be removed." attr »myInstanceAttribute«: Number - // $TEST$ no info "Overriding member is identical to overridden member and can be removed." + # $TEST$ no info "Overriding member is identical to overridden member and can be removed." static attr »myStaticAttribute«: Number - // $TEST$ no info "Overriding member is identical to overridden member and can be removed." + # $TEST$ no info "Overriding member is identical to overridden member and can be removed." attr »myInstanceAttribute«: Number - // $TEST$ no info "Overriding member is identical to overridden member and can be removed." + # $TEST$ no info "Overriding member is identical to overridden member and can be removed." static attr »myStaticAttribute«: Number - // $TEST$ no info "Overriding member is identical to overridden member and can be removed." + # $TEST$ no info "Overriding member is identical to overridden member and can be removed." attr »myOwnInstanceAttribute«: Number - // $TEST$ no info "Overriding member is identical to overridden member and can be removed." + # $TEST$ no info "Overriding member is identical to overridden member and can be removed." static attr »myOwnStaticAttribute«: Number - // $TEST$ info "Overriding member is identical to overridden member and can be removed." + # $TEST$ info "Overriding member is identical to overridden member and can be removed." @Pure fun »myInstanceMethod«(a: Number = 0) -> r: Number - // $TEST$ no info "Overriding member is identical to overridden member and can be removed." + # $TEST$ no info "Overriding member is identical to overridden member and can be removed." @Pure static fun »myStaticMethod«(a: Number = 0) -> r: Number - // $TEST$ no info "Overriding member is identical to overridden member and can be removed." + # $TEST$ no info "Overriding member is identical to overridden member and can be removed." @Pure fun »myInstanceMethod«() -> r: Number - // $TEST$ no info "Overriding member is identical to overridden member and can be removed." + # $TEST$ no info "Overriding member is identical to overridden member and can be removed." @Pure static fun »myStaticMethod«() -> r: Number - // $TEST$ no info "Overriding member is identical to overridden member and can be removed." + # $TEST$ no info "Overriding member is identical to overridden member and can be removed." @Pure fun »myOwnInstanceMethod«(a: Number = 0) -> r: Number - // $TEST$ no info "Overriding member is identical to overridden member and can be removed." + # $TEST$ no info "Overriding member is identical to overridden member and can be removed." @Pure static fun »myOwnStaticMethod«(a: Number = 0) -> r: Number } class MyClass2 sub MySuperClass1 { - // $TEST$ no info "Overriding member is identical to overridden member and can be removed." + # $TEST$ no info "Overriding member is identical to overridden member and can be removed." attr »myInstanceAttribute«: Int - // $TEST$ no info "Overriding member is identical to overridden member and can be removed." + # $TEST$ no info "Overriding member is identical to overridden member and can be removed." static attr »myStaticAttribute«: Int - // $TEST$ no info "Overriding member is identical to overridden member and can be removed." + # $TEST$ no info "Overriding member is identical to overridden member and can be removed." @Pure fun »myInstanceMethod«(a: Number = 0) -> r: Int - // $TEST$ no info "Overriding member is identical to overridden member and can be removed." + # $TEST$ no info "Overriding member is identical to overridden member and can be removed." @Pure static fun »myStaticMethod«(a: Number = 0) -> r: Int } diff --git a/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method should differ from overridden method/purity.sdstest b/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method should differ from overridden method/purity.sdstest index 8ef0a9e8..6ff91e70 100644 --- a/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method should differ from overridden method/purity.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method should differ from overridden method/purity.sdstest @@ -8,19 +8,19 @@ class MySuperClass2 { } class MyClass3 sub MySuperClass2 { - // $TEST$ no info "Overriding member is identical to overridden member and can be removed." + # $TEST$ no info "Overriding member is identical to overridden member and can be removed." @Pure fun »myInstanceMethod«(a: Number = 0) -> r: Number - // $TEST$ no info "Overriding member is identical to overridden member and can be removed." + # $TEST$ no info "Overriding member is identical to overridden member and can be removed." @Pure static fun »myStaticMethod«(a: Number = 0) -> r: Number } class MyClass4 sub MySuperClass2 { - // $TEST$ no info "Overriding member is identical to overridden member and can be removed." + # $TEST$ no info "Overriding member is identical to overridden member and can be removed." @Impure([]) fun »myInstanceMethod«(a: Number = 0) -> r: Number - // $TEST$ no info "Overriding member is identical to overridden member and can be removed." + # $TEST$ no info "Overriding member is identical to overridden member and can be removed." @Impure([]) static fun »myStaticMethod«(a: Number = 0) -> r: Number } diff --git a/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method should differ from overridden method/safeds lang any.sdstest b/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method should differ from overridden method/safeds lang any.sdstest index 2ca1aae9..25b511f4 100644 --- a/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method should differ from overridden method/safeds lang any.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method should differ from overridden method/safeds lang any.sdstest @@ -1,6 +1,6 @@ package TTSL.lang class Any { - // $TEST$ no info "Overriding member is identical to overridden member and can be removed." + # $TEST$ no info "Overriding member is identical to overridden member and can be removed." fun »toString«() -> s: String } diff --git a/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method should differ from overridden method/type parameters.sdstest b/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method should differ from overridden method/type parameters.sdstest index d6e2216f..46b66ada 100644 --- a/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method should differ from overridden method/type parameters.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/inheritance/overriding method should differ from overridden method/type parameters.sdstest @@ -8,34 +8,34 @@ class MySuperClass { } class MyClass2 sub MySuperClass { - // $TEST$ info "Overriding member is identical to overridden member and can be removed." + # $TEST$ info "Overriding member is identical to overridden member and can be removed." attr »myInstanceAttribute«: T - // $TEST$ info "Overriding member is identical to overridden member and can be removed." + # $TEST$ info "Overriding member is identical to overridden member and can be removed." @Pure fun »myInstanceMethod1«(a: T = 0) -> r: T } class MyClass1 sub MySuperClass { - // $TEST$ info "Overriding member is identical to overridden member and can be removed." + # $TEST$ info "Overriding member is identical to overridden member and can be removed." attr »myInstanceAttribute«: Number - // $TEST$ info "Overriding member is identical to overridden member and can be removed." + # $TEST$ info "Overriding member is identical to overridden member and can be removed." @Pure fun »myInstanceMethod1«(a: Number = 0) -> r: Number } class MyClass3 sub MySuperClass { - // $TEST$ no info "Overriding member is identical to overridden member and can be removed." + # $TEST$ no info "Overriding member is identical to overridden member and can be removed." attr »myInstanceAttribute«: Int - // $TEST$ no info "Overriding member is identical to overridden member and can be removed." + # $TEST$ no info "Overriding member is identical to overridden member and can be removed." @Pure fun »myInstanceMethod1«(a: Number = 0) -> r: Int } class MyClass4 sub MySuperClass { - // $TEST$ no info "Overriding member is identical to overridden member and can be removed." + # $TEST$ no info "Overriding member is identical to overridden member and can be removed." @Pure fun »myInstanceMethod2«(a: T) -> r: T - // $TEST$ info "Overriding member is identical to overridden member and can be removed." + # $TEST$ info "Overriding member is identical to overridden member and can be removed." @Pure fun »myInstanceMethod3«(a: T) -> r: T } class MyClass5 sub MySuperClass { - // $TEST$ no info "Overriding member is identical to overridden member and can be removed." + # $TEST$ no info "Overriding member is identical to overridden member and can be removed." @Pure fun »myInstanceMethod3«(a: Int) -> r: Int } diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/annotations.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/annotations.sdstest index d1b1be50..afac890b 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/annotations.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/annotations.sdstest @@ -1,12 +1,12 @@ package tests.validation.names.casing -// $TEST$ no warning "Names of annotations should be UpperCamelCase." +# $TEST$ no warning "Names of annotations should be UpperCamelCase." annotation »AnnotationUppercase1« -// $TEST$ no warning "Names of annotations should be UpperCamelCase." +# $TEST$ no warning "Names of annotations should be UpperCamelCase." annotation »`AnnotationUppercase2`« -// $TEST$ warning "Names of annotations should be UpperCamelCase." +# $TEST$ warning "Names of annotations should be UpperCamelCase." annotation »annotationLowercase« -// $TEST$ warning "Names of annotations should be UpperCamelCase." +# $TEST$ warning "Names of annotations should be UpperCamelCase." annotation »_annotationUnderscore« -// $TEST$ warning "Names of annotations should be UpperCamelCase." +# $TEST$ warning "Names of annotations should be UpperCamelCase." annotation »Annotation_Snake_Case« diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/attributes.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/attributes.sdstest index 66099ce6..469bd6e8 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/attributes.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/attributes.sdstest @@ -1,14 +1,14 @@ package tests.validation.names.casing class MyClass { - // $TEST$ warning "Names of attributes should be lowerCamelCase." + # $TEST$ warning "Names of attributes should be lowerCamelCase." attr »AttributeUppercase«: Int - // $TEST$ no warning "Names of attributes should be lowerCamelCase." + # $TEST$ no warning "Names of attributes should be lowerCamelCase." attr »attributeLowercase1«: Int - // $TEST$ no warning "Names of attributes should be lowerCamelCase." + # $TEST$ no warning "Names of attributes should be lowerCamelCase." attr »`attributeLowercase2`«: Int - // $TEST$ warning "Names of attributes should be lowerCamelCase." + # $TEST$ warning "Names of attributes should be lowerCamelCase." attr »_attributeUnderscore«: Int - // $TEST$ warning "Names of attributes should be lowerCamelCase." + # $TEST$ warning "Names of attributes should be lowerCamelCase." attr »attribute_snake_case«: Int } diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/block lambda results.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/block lambda results.sdstest index 63ca47c3..85902edc 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/block lambda results.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/block lambda results.sdstest @@ -1,16 +1,16 @@ package tests.validation.names.casing -pipeline myPipeline1 { +function myFunction1 { () { - // $TEST$ warning "Names of block lambda results should be lowerCamelCase." + # $TEST$ warning "Names of block lambda results should be lowerCamelCase." yield »LambdaResultUppercase« = 1; - // $TEST$ no warning "Names of block lambda results should be lowerCamelCase." + # $TEST$ no warning "Names of block lambda results should be lowerCamelCase." yield »lambdaResultLowercase1« = 1; - // $TEST$ no warning "Names of block lambda results should be lowerCamelCase." + # $TEST$ no warning "Names of block lambda results should be lowerCamelCase." yield »`lambdaResultLowercase2`« = 1; - // $TEST$ warning "Names of block lambda results should be lowerCamelCase." + # $TEST$ warning "Names of block lambda results should be lowerCamelCase." yield »_lambdaResultUnderscore« = 1; - // $TEST$ warning "Names of block lambda results should be lowerCamelCase." + # $TEST$ warning "Names of block lambda results should be lowerCamelCase." yield »lambdaResult_snake_case« = 1; }; } diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/classes.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/classes.sdstest index 8c571f72..b33faf44 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/classes.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/classes.sdstest @@ -1,12 +1,12 @@ package tests.validation.names.casing -// $TEST$ no warning "Names of classes should be UpperCamelCase." +# $TEST$ no warning "Names of classes should be UpperCamelCase." class »ClassUppercase1« -// $TEST$ no warning "Names of classes should be UpperCamelCase." +# $TEST$ no warning "Names of classes should be UpperCamelCase." class »`ClassUppercase2`« -// $TEST$ warning "Names of classes should be UpperCamelCase." +# $TEST$ warning "Names of classes should be UpperCamelCase." class »classLowercase« -// $TEST$ warning "Names of classes should be UpperCamelCase." +# $TEST$ warning "Names of classes should be UpperCamelCase." class »_classUnderscore« -// $TEST$ warning "Names of classes should be UpperCamelCase." +# $TEST$ warning "Names of classes should be UpperCamelCase." class »Class_Snake_Case« diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/enum variants.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/enum variants.sdstest index 11fbe086..4b5f0db9 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/enum variants.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/enum variants.sdstest @@ -1,14 +1,14 @@ package tests.validation.names.casing enum MyEnum { - // $TEST$ no warning "Names of enum variants should be UpperCamelCase." + # $TEST$ no warning "Names of enum variants should be UpperCamelCase." »EnumVariantUppercase1« - // $TEST$ no warning "Names of enum variants should be UpperCamelCase." + # $TEST$ no warning "Names of enum variants should be UpperCamelCase." »`EnumVariantUppercase2`« - // $TEST$ warning "Names of enum variants should be UpperCamelCase." + # $TEST$ warning "Names of enum variants should be UpperCamelCase." »enumVariantLowercase« - // $TEST$ warning "Names of enum variants should be UpperCamelCase." + # $TEST$ warning "Names of enum variants should be UpperCamelCase." »_enumVariantUnderscore« - // $TEST$ warning "Names of enum variants should be UpperCamelCase." + # $TEST$ warning "Names of enum variants should be UpperCamelCase." »Enum_Variant_Snake_Case« } diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/enums.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/enums.sdstest index 90bf4cf0..f55b3ef7 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/enums.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/enums.sdstest @@ -1,12 +1,12 @@ package tests.validation.names.casing -// $TEST$ no warning "Names of enums should be UpperCamelCase." +# $TEST$ no warning "Names of enums should be UpperCamelCase." enum »EnumUppercase1« -// $TEST$ no warning "Names of enums should be UpperCamelCase." +# $TEST$ no warning "Names of enums should be UpperCamelCase." enum »`EnumUppercase2`« -// $TEST$ warning "Names of enums should be UpperCamelCase." +# $TEST$ warning "Names of enums should be UpperCamelCase." enum »enumLowercase« -// $TEST$ warning "Names of enums should be UpperCamelCase." +# $TEST$ warning "Names of enums should be UpperCamelCase." enum »_enumUnderscore« -// $TEST$ warning "Names of enums should be UpperCamelCase." +# $TEST$ warning "Names of enums should be UpperCamelCase." enum »Enum_Snake_Case« diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/functions.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/functions.sdstest index 41d16b3d..8ed50041 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/functions.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/functions.sdstest @@ -1,12 +1,12 @@ package tests.validation.names.casing -// $TEST$ warning "Names of functions should be lowerCamelCase." +# $TEST$ warning "Names of functions should be lowerCamelCase." fun »FunctionUppercase«() -// $TEST$ no warning "Names of functions should be lowerCamelCase." +# $TEST$ no warning "Names of functions should be lowerCamelCase." fun »functionLowercase1«() -// $TEST$ no warning "Names of functions should be lowerCamelCase." +# $TEST$ no warning "Names of functions should be lowerCamelCase." fun »`functionLowercase2`«() -// $TEST$ warning "Names of functions should be lowerCamelCase." +# $TEST$ warning "Names of functions should be lowerCamelCase." fun »_functionUnderscore«() -// $TEST$ warning "Names of functions should be lowerCamelCase." +# $TEST$ warning "Names of functions should be lowerCamelCase." fun »function_snake_case«() diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/no package name.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/no package name.sdstest index b31d16d3..3948a368 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/no package name.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/no package name.sdstest @@ -1 +1 @@ -// $TEST$ no warning "All segments of the qualified name of a package should be lowerCamelCase." +# $TEST$ no warning "All segments of the qualified name of a package should be lowerCamelCase." diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/package name leading underscore.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/package name leading underscore.sdstest index 252c47d9..c2ae50bb 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/package name leading underscore.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/package name leading underscore.sdstest @@ -1,2 +1,2 @@ -// $TEST$ warning "All segments of the qualified name of a package should be lowerCamelCase." +# $TEST$ warning "All segments of the qualified name of a package should be lowerCamelCase." package »tests.validation.declarations._underscore« diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/package name lowercase escaped.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/package name lowercase escaped.sdstest index c5bf8580..2aff365f 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/package name lowercase escaped.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/package name lowercase escaped.sdstest @@ -1,2 +1,2 @@ -// $TEST$ no warning "All segments of the qualified name of a package should be lowerCamelCase." +# $TEST$ no warning "All segments of the qualified name of a package should be lowerCamelCase." package »tests.validation.declarations.`lowercase1`« diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/package name lowercase.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/package name lowercase.sdstest index 44069623..ad036921 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/package name lowercase.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/package name lowercase.sdstest @@ -1,2 +1,2 @@ -// $TEST$ no warning "All segments of the qualified name of a package should be lowerCamelCase." +# $TEST$ no warning "All segments of the qualified name of a package should be lowerCamelCase." package »tests.validation.declarations.lowercase1« diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/package name snake case.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/package name snake case.sdstest index 41197e77..efe68e9d 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/package name snake case.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/package name snake case.sdstest @@ -1,2 +1,2 @@ -// $TEST$ warning "All segments of the qualified name of a package should be lowerCamelCase." +# $TEST$ warning "All segments of the qualified name of a package should be lowerCamelCase." package »tests.validation.declarations.snake_case« diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/package name uppercase.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/package name uppercase.sdstest index 07272cee..3ef878ac 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/package name uppercase.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/package name uppercase.sdstest @@ -1,2 +1,2 @@ -// $TEST$ warning "All segments of the qualified name of a package should be lowerCamelCase." +# $TEST$ warning "All segments of the qualified name of a package should be lowerCamelCase." package »tests.validation.declarations.Uppercase« diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/parameters.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/parameters.sdstest index 59b57573..15f15a52 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/parameters.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/parameters.sdstest @@ -1,14 +1,14 @@ package tests.validation.names.casing fun myFunction1( - // $TEST$ warning "Names of parameters should be lowerCamelCase." + # $TEST$ warning "Names of parameters should be lowerCamelCase." »ParameterUppercase«: Int, - // $TEST$ no warning "Names of parameters should be lowerCamelCase." + # $TEST$ no warning "Names of parameters should be lowerCamelCase." »parameterLowercase1«: Int, - // $TEST$ no warning "Names of parameters should be lowerCamelCase." + # $TEST$ no warning "Names of parameters should be lowerCamelCase." »`parameterLowercase2`«: Int, - // $TEST$ warning "Names of parameters should be lowerCamelCase." + # $TEST$ warning "Names of parameters should be lowerCamelCase." »_parameterUnderscore«: Int, - // $TEST$ warning "Names of parameters should be lowerCamelCase." + # $TEST$ warning "Names of parameters should be lowerCamelCase." »parameter_snake_case«: Int ) diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/pipelines.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/pipelines.sdstest index c9a46ef9..5b31adeb 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/pipelines.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/pipelines.sdstest @@ -1,12 +1,12 @@ package tests.validation.names.casing -// $TEST$ warning "Names of pipelines should be lowerCamelCase." +# $TEST$ warning "Names of pipelines should be lowerCamelCase." pipeline »PipelineUppercase« {} -// $TEST$ no warning "Names of pipelines should be lowerCamelCase." +# $TEST$ no warning "Names of pipelines should be lowerCamelCase." pipeline »pipelineLowercase1« {} -// $TEST$ no warning "Names of pipelines should be lowerCamelCase." +# $TEST$ no warning "Names of pipelines should be lowerCamelCase." pipeline »`pipelineLowercase2`« {} -// $TEST$ warning "Names of pipelines should be lowerCamelCase." +# $TEST$ warning "Names of pipelines should be lowerCamelCase." pipeline »_pipelineUnderscore« {} -// $TEST$ warning "Names of pipelines should be lowerCamelCase." +# $TEST$ warning "Names of pipelines should be lowerCamelCase." pipeline »pipeline_snake_case« {} diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/placeholders.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/placeholders.sdstest index 1cb0658b..1c39e44e 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/placeholders.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/placeholders.sdstest @@ -1,14 +1,14 @@ package tests.validation.names.casing -pipeline myPipeline2 { - // $TEST$ warning "Names of placeholders should be lowerCamelCase." +function myFunction2 { + # $TEST$ warning "Names of placeholders should be lowerCamelCase." val »PlaceholderUppercase« = 1; - // $TEST$ no warning "Names of placeholders should be lowerCamelCase." + # $TEST$ no warning "Names of placeholders should be lowerCamelCase." val »placeholderLowercase1« = 1; - // $TEST$ no warning "Names of placeholders should be lowerCamelCase." + # $TEST$ no warning "Names of placeholders should be lowerCamelCase." val »`placeholderLowercase2`« = 1; - // $TEST$ warning "Names of placeholders should be lowerCamelCase." + # $TEST$ warning "Names of placeholders should be lowerCamelCase." val »_placeholderUnderscore« = 1; - // $TEST$ warning "Names of placeholders should be lowerCamelCase." + # $TEST$ warning "Names of placeholders should be lowerCamelCase." val »placeholder_snake_case« = 1; } diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/results.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/results.sdstest index f0d2a048..5299c82e 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/results.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/results.sdstest @@ -1,14 +1,14 @@ package tests.validation.names.casing fun myFunction2() -> ( - // $TEST$ warning "Names of results should be lowerCamelCase." + # $TEST$ warning "Names of results should be lowerCamelCase." »ResultUppercase«: Int, - // $TEST$ no warning "Names of results should be lowerCamelCase." + # $TEST$ no warning "Names of results should be lowerCamelCase." »resultLowercase1«: Int, - // $TEST$ no warning "Names of results should be lowerCamelCase." + # $TEST$ no warning "Names of results should be lowerCamelCase." »`resultLowercase2`«: Int, - // $TEST$ warning "Names of results should be lowerCamelCase." + # $TEST$ warning "Names of results should be lowerCamelCase." »_resultUnderscore«: Int, - // $TEST$ warning "Names of results should be lowerCamelCase." + # $TEST$ warning "Names of results should be lowerCamelCase." »result_snake_case«: Int ) diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/schemas.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/schemas.sdstest index a456b764..b53308ca 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/schemas.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/schemas.sdstest @@ -1,12 +1,12 @@ package tests.validation.names.casing -// $TEST$ no warning "Names of schemas should be UpperCamelCase." +# $TEST$ no warning "Names of schemas should be UpperCamelCase." schema »SchemaUppercase1« {} -// $TEST$ no warning "Names of schemas should be UpperCamelCase." +# $TEST$ no warning "Names of schemas should be UpperCamelCase." schema »`SchemaUppercase2`« {} -// $TEST$ warning "Names of schemas should be UpperCamelCase." +# $TEST$ warning "Names of schemas should be UpperCamelCase." schema »schemaLowercase« {} -// $TEST$ warning "Names of schemas should be UpperCamelCase." +# $TEST$ warning "Names of schemas should be UpperCamelCase." schema »_schemaUnderscore« {} -// $TEST$ warning "Names of schemas should be UpperCamelCase." +# $TEST$ warning "Names of schemas should be UpperCamelCase." schema »Schema_Snake_Case« {} diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/segments.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/segments.sdstest index b06585eb..38d40953 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/segments.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/segments.sdstest @@ -1,12 +1,12 @@ package tests.validation.names.casing -// $TEST$ warning "Names of segments should be lowerCamelCase." +# $TEST$ warning "Names of segments should be lowerCamelCase." segment »SegmentUppercase«() {} -// $TEST$ no warning "Names of segments should be lowerCamelCase." +# $TEST$ no warning "Names of segments should be lowerCamelCase." segment »segmentLowercase1«() {} -// $TEST$ no warning "Names of segments should be lowerCamelCase." +# $TEST$ no warning "Names of segments should be lowerCamelCase." segment »`segmentLowercase2`«() {} -// $TEST$ warning "Names of segments should be lowerCamelCase." +# $TEST$ warning "Names of segments should be lowerCamelCase." segment »_segmentUnderscore«() {} -// $TEST$ warning "Names of segments should be lowerCamelCase." +# $TEST$ warning "Names of segments should be lowerCamelCase." segment »segment_snake_case«() {} diff --git a/packages/ttsl-lang/tests/resources/validation/names/casing/type parameters.sdstest b/packages/ttsl-lang/tests/resources/validation/names/casing/type parameters.sdstest index 267bec76..9e2bf7eb 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/casing/type parameters.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/casing/type parameters.sdstest @@ -1,14 +1,14 @@ package tests.validation.names.casing fun myFunction3< - // $TEST$ no warning "Names of type parameters should be UpperCamelCase." + # $TEST$ no warning "Names of type parameters should be UpperCamelCase." »TypeParameterUppercase1«, - // $TEST$ no warning "Names of type parameters should be UpperCamelCase." + # $TEST$ no warning "Names of type parameters should be UpperCamelCase." »`TypeParameterUppercase2`«, - // $TEST$ warning "Names of type parameters should be UpperCamelCase." + # $TEST$ warning "Names of type parameters should be UpperCamelCase." »typeParameterLowercase«, - // $TEST$ warning "Names of type parameters should be UpperCamelCase." + # $TEST$ warning "Names of type parameters should be UpperCamelCase." »_typeParameterUnderscore«, - // $TEST$ warning "Names of type parameters should be UpperCamelCase." + # $TEST$ warning "Names of type parameters should be UpperCamelCase." »Type_Parameter_Snake_Case« >() diff --git a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/annotations.sdstest b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/annotations.sdstest index 2f1ed513..de2b2d78 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/annotations.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/annotations.sdstest @@ -1,7 +1,7 @@ package tests.validation.names.blockLambdaPrefix -// $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." +# $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." annotation »__gen_0« -// $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." +# $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." annotation »_gen_1« diff --git a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/attributes.sdstest b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/attributes.sdstest index 410cd100..0dcf4433 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/attributes.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/attributes.sdstest @@ -1,9 +1,9 @@ package tests.validation.names.blockLambdaPrefix class MyClass { - // $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." + # $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." attr »__gen_0«: Int - // $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." + # $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." attr »_gen_1«: Int } diff --git a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/block lambda results.sdstest b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/block lambda results.sdstest index dcb4646b..97b81a09 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/block lambda results.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/block lambda results.sdstest @@ -1,11 +1,11 @@ package tests.validation.names.blockLambdaPrefix -pipeline myPipeline2 { +function myFunction2 { () { - // $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." + # $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." yield »__gen_0« = 1; - // $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." + # $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." yield »_gen_1« = 1; }; } diff --git a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/classes.sdstest b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/classes.sdstest index d7e77027..0eb9ea1f 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/classes.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/classes.sdstest @@ -1,7 +1,7 @@ package tests.validation.names.blockLambdaPrefix -// $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." +# $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." class »__gen_0« -// $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." +# $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." class »_gen_1« diff --git a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/enum variants.sdstest b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/enum variants.sdstest index d69569bd..7c352b41 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/enum variants.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/enum variants.sdstest @@ -1,9 +1,9 @@ package tests.validation.names.blockLambdaPrefix enum MyEnum { - // $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." + # $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." »__gen_0« - // $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." + # $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." »_gen_1« } diff --git a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/enums.sdstest b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/enums.sdstest index c549ec75..4d1d05e4 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/enums.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/enums.sdstest @@ -1,7 +1,7 @@ package tests.validation.names.blockLambdaPrefix -// $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." +# $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." enum »__gen_0« -// $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." +# $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." enum »_gen_1« diff --git a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/functions.sdstest b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/functions.sdstest index bdd235e7..e263101b 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/functions.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/functions.sdstest @@ -1,7 +1,7 @@ package tests.validation.names.blockLambdaPrefix -// $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." +# $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." fun »__gen_0«() -// $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." +# $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." fun »_gen_1«() diff --git a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/no package name.sdstest b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/no package name.sdstest index 961d17e5..1078f95c 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/no package name.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/no package name.sdstest @@ -1 +1 @@ -// $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." +# $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." diff --git a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/package name with codegen prefix.sdstest b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/package name with codegen prefix.sdstest index 72430e42..6d083e3f 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/package name with codegen prefix.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/package name with codegen prefix.sdstest @@ -1,2 +1,2 @@ -// $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." +# $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." package »__gen_0« diff --git a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/package name without codegen prefix.sdstest b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/package name without codegen prefix.sdstest index 56bc1da4..74a1d36e 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/package name without codegen prefix.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/package name without codegen prefix.sdstest @@ -1,2 +1,2 @@ -// $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." +# $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." package »_gen_1« diff --git a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/parameters.sdstest b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/parameters.sdstest index 6fc81e57..f1c36bd1 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/parameters.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/parameters.sdstest @@ -1,9 +1,9 @@ package tests.validation.names.blockLambdaPrefix fun myFunction1( - // $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." + # $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." »__gen_0«: Int, - // $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." + # $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." »_gen_1«: Int, ) diff --git a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/pipelines.sdstest b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/pipelines.sdstest index e5da70f5..cc0724f1 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/pipelines.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/pipelines.sdstest @@ -1,7 +1,7 @@ package tests.validation.names.blockLambdaPrefix -// $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." +# $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." pipeline »__gen_0« {} -// $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." +# $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." pipeline »_gen_1« {} diff --git a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/placeholders.sdstest b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/placeholders.sdstest index 7bb4abb1..9c21d292 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/placeholders.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/placeholders.sdstest @@ -1,9 +1,9 @@ package tests.validation.names.blockLambdaPrefix -pipeline myPipeline1 { - // $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." +function myFunction1 { + # $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." val »__gen_0« = 1; - // $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." + # $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." val »_gen_1« = 1; } diff --git a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/results.sdstest b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/results.sdstest index 654e3798..23be1a97 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/results.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/results.sdstest @@ -1,9 +1,9 @@ package tests.validation.names.blockLambdaPrefix fun myFunction2() -> ( - // $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." + # $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." »__gen_0«: Int, - // $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." + # $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." »_gen_1«: Int, ) diff --git a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/schemas.sdstest b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/schemas.sdstest index 7ec0a8ad..17445874 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/schemas.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/schemas.sdstest @@ -1,7 +1,7 @@ package tests.validation.names.blockLambdaPrefix -// $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." +# $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." schema »__gen_0« {} -// $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." +# $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." schema »_gen_1« {} diff --git a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/segments.sdstest b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/segments.sdstest index fe7c64e4..42dae59c 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/segments.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/segments.sdstest @@ -1,7 +1,7 @@ package tests.validation.names.blockLambdaPrefix -// $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." +# $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." segment »__gen_0«() {} -// $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." +# $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." segment »_gen_1«() {} diff --git a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/type parameters.sdstest b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/type parameters.sdstest index 71f70028..17ffc0ee 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/type parameters.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/codegen prefix/type parameters.sdstest @@ -1,9 +1,9 @@ package tests.validation.names.blockLambdaPrefix fun myFunction3< - // $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." + # $TEST$ error "Names of declarations must not start with '__gen_'. This is reserved for code generation." »__gen_0«, - // $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." + # $TEST$ no error "Names of declarations must not start with '__gen_'. This is reserved for code generation." »_gen_1«, >() diff --git a/packages/ttsl-lang/tests/resources/validation/names/core names/in safeds lang.sdstest b/packages/ttsl-lang/tests/resources/validation/names/core names/in safeds lang.sdstest index da71df08..24be345d 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/core names/in safeds lang.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/core names/in safeds lang.sdstest @@ -1,4 +1,4 @@ package TTSL.lang -// $TEST$ no error "Names of core declarations must not be used for own declarations." +# $TEST$ no error "Names of core declarations must not be used for own declarations." annotation »Number« diff --git a/packages/ttsl-lang/tests/resources/validation/names/core names/main.sdstest b/packages/ttsl-lang/tests/resources/validation/names/core names/main.sdstest index 78ccb7d0..03e5f4d2 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/core names/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/core names/main.sdstest @@ -1,7 +1,7 @@ package tests.validation.names.coreNames -// $TEST$ error "Names of core declarations must not be used for own declarations." +# $TEST$ error "Names of core declarations must not be used for own declarations." annotation »Any« -// $TEST$ no error "Names of core declarations must not be used for own declarations." +# $TEST$ no error "Names of core declarations must not be used for own declarations." annotation »Any1« diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/main.sdstest b/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/main.sdstest index 433eb345..b95de097 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/main.sdstest @@ -1,78 +1,78 @@ package tests.validation.names.acrossFiles -// $TEST$ error "Multiple declarations in this package have the name 'DuplicateAnnotation'." +# $TEST$ error "Multiple declarations in this package have the name 'DuplicateAnnotation'." annotation »DuplicateAnnotation« -// $TEST$ error "Multiple declarations in this package have the name 'DuplicateClass'." +# $TEST$ error "Multiple declarations in this package have the name 'DuplicateClass'." class »DuplicateClass« -// $TEST$ error "Multiple declarations in this package have the name 'DuplicateEnum'." +# $TEST$ error "Multiple declarations in this package have the name 'DuplicateEnum'." enum »DuplicateEnum« -// $TEST$ error "Multiple declarations in this package have the name 'duplicateFunction'." +# $TEST$ error "Multiple declarations in this package have the name 'duplicateFunction'." fun »duplicateFunction«() -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." pipeline »duplicatePipeline« {} -// $TEST$ error "Multiple declarations in this package have the name 'DuplicateSchema'." +# $TEST$ error "Multiple declarations in this package have the name 'DuplicateSchema'." schema »DuplicateSchema« {} -// $TEST$ error "Multiple declarations in this package have the name 'duplicatePublicSegment'." +# $TEST$ error "Multiple declarations in this package have the name 'duplicatePublicSegment'." segment »duplicatePublicSegment«() {} -// $TEST$ error "Multiple declarations in this package have the name 'duplicateInternalSegment'." +# $TEST$ error "Multiple declarations in this package have the name 'duplicateInternalSegment'." internal segment »duplicateInternalSegment«() {} -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." private segment »duplicatePrivateSegment«() {} -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." annotation »UniqueAnnotation« -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." class »UniqueClass« -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." enum »UniqueEnum« -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." fun »uniqueFunction«() -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." pipeline »uniquePipeline« {} -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." schema »UniqueSchema« {} -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." segment »uniquePublicSegment«() {} -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." internal segment »uniqueInternalSegment«() {} -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." private segment »uniquePrivateSegment«() {} -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." annotation »MyAnnotation« -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." annotation »MyAnnotation« -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." class »MyClass« -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." class »MyClass« -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." enum »MyEnum« -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." enum »MyEnum« -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." fun »myFunction«() -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." fun »myFunction«() -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." pipeline »myPipeline« {} -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." pipeline »myPipeline« {} -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." schema »MySchema« {} -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." schema »MySchema« {} -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." segment »myPublicSegment«() {} -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." segment »myPublicSegment«() {} -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." internal segment »myInternalSegment«() {} -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." internal segment »myInternalSegment«() {} -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." private segment »myPrivateSegment«() {} -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." private segment »myPrivateSegment«() {} diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/other package.sdstest b/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/other package.sdstest index 84389abf..b61ab2b3 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/other package.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/other package.sdstest @@ -1,20 +1,20 @@ package tests.validation.names.acrossFiles.other -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." annotation »UniqueAnnotation« -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." class »UniqueClass« -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." enum »UniqueEnum« -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." fun »uniqueFunction«() -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." pipeline »uniquePipeline« {} -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." schema »UniqueSchema« {} -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." segment »uniquePublicSegment«() {} -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." internal segment »uniqueInternalSegment«() {} -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." private segment »uniquePrivateSegment«() {} diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/safeds 1.sdstest b/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/safeds 1.sdstest index 28cbd4b8..2b32cf27 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/safeds 1.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/safeds 1.sdstest @@ -4,24 +4,24 @@ package TTSL.lang * Declarations that only occur a second time in builtin files should be excluded, so we don't get errors while editing them. */ -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." class »Any« -// $TEST$ error "Multiple builtin declarations have the name 'DuplicateAnnotation'." +# $TEST$ error "Multiple builtin declarations have the name 'DuplicateAnnotation'." annotation »DuplicateAnnotation« -// $TEST$ error "Multiple builtin declarations have the name 'DuplicateClass'." +# $TEST$ error "Multiple builtin declarations have the name 'DuplicateClass'." class »DuplicateClass« -// $TEST$ error "Multiple builtin declarations have the name 'DuplicateEnum'." +# $TEST$ error "Multiple builtin declarations have the name 'DuplicateEnum'." enum »DuplicateEnum« -// $TEST$ error "Multiple builtin declarations have the name 'duplicateFunction'." +# $TEST$ error "Multiple builtin declarations have the name 'duplicateFunction'." fun »duplicateFunction«() -// $TEST$ no error r"Multiple builtin declarations have the name '\w*'\." +# $TEST$ no error r"Multiple builtin declarations have the name '\w*'\." pipeline »duplicatePipeline« {} -// $TEST$ error "Multiple builtin declarations have the name 'DuplicateSchema'." +# $TEST$ error "Multiple builtin declarations have the name 'DuplicateSchema'." schema »DuplicateSchema« {} -// $TEST$ error "Multiple builtin declarations have the name 'duplicatePublicSegment'." +# $TEST$ error "Multiple builtin declarations have the name 'duplicatePublicSegment'." segment »duplicatePublicSegment«() {} -// $TEST$ error "Multiple builtin declarations have the name 'duplicateInternalSegment'." +# $TEST$ error "Multiple builtin declarations have the name 'duplicateInternalSegment'." internal segment »duplicateInternalSegment«() {} -// $TEST$ no error r"Multiple builtin declarations have the name '\w*'\." +# $TEST$ no error r"Multiple builtin declarations have the name '\w*'\." private segment »duplicatePrivateSegment«() {} diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/safeds 2.sdstest b/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/safeds 2.sdstest index 5ee81a98..7a652e12 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/safeds 2.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/safeds 2.sdstest @@ -1,20 +1,20 @@ package TTSL.lang.other -// $TEST$ error "Multiple builtin declarations have the name 'DuplicateAnnotation'." +# $TEST$ error "Multiple builtin declarations have the name 'DuplicateAnnotation'." annotation »DuplicateAnnotation« -// $TEST$ error "Multiple builtin declarations have the name 'DuplicateClass'." +# $TEST$ error "Multiple builtin declarations have the name 'DuplicateClass'." class »DuplicateClass« -// $TEST$ error "Multiple builtin declarations have the name 'DuplicateEnum'." +# $TEST$ error "Multiple builtin declarations have the name 'DuplicateEnum'." enum »DuplicateEnum« -// $TEST$ error "Multiple builtin declarations have the name 'duplicateFunction'." +# $TEST$ error "Multiple builtin declarations have the name 'duplicateFunction'." fun »duplicateFunction«() -// $TEST$ no error r"Multiple builtin declarations have the name '\w*'\." +# $TEST$ no error r"Multiple builtin declarations have the name '\w*'\." pipeline »duplicatePipeline« {} -// $TEST$ error "Multiple builtin declarations have the name 'DuplicateSchema'." +# $TEST$ error "Multiple builtin declarations have the name 'DuplicateSchema'." schema »DuplicateSchema« {} -// $TEST$ error "Multiple builtin declarations have the name 'duplicatePublicSegment'." +# $TEST$ error "Multiple builtin declarations have the name 'duplicatePublicSegment'." segment »duplicatePublicSegment«() {} -// $TEST$ error "Multiple builtin declarations have the name 'duplicateInternalSegment'." +# $TEST$ error "Multiple builtin declarations have the name 'duplicateInternalSegment'." internal segment »duplicateInternalSegment«() {} -// $TEST$ no error r"Multiple builtin declarations have the name '\w*'\." +# $TEST$ no error r"Multiple builtin declarations have the name '\w*'\." private segment »duplicatePrivateSegment«() {} diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/same package.sdstest b/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/same package.sdstest index ea17382a..a3686834 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/same package.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/across files/same package.sdstest @@ -1,20 +1,20 @@ package tests.validation.names.acrossFiles -// $TEST$ error "Multiple declarations in this package have the name 'DuplicateAnnotation'." +# $TEST$ error "Multiple declarations in this package have the name 'DuplicateAnnotation'." annotation »DuplicateAnnotation« -// $TEST$ error "Multiple declarations in this package have the name 'DuplicateClass'." +# $TEST$ error "Multiple declarations in this package have the name 'DuplicateClass'." class »DuplicateClass« -// $TEST$ error "Multiple declarations in this package have the name 'DuplicateEnum'." +# $TEST$ error "Multiple declarations in this package have the name 'DuplicateEnum'." enum »DuplicateEnum« -// $TEST$ error "Multiple declarations in this package have the name 'duplicateFunction'." +# $TEST$ error "Multiple declarations in this package have the name 'duplicateFunction'." fun »duplicateFunction«() -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." pipeline »duplicatePipeline« {} -// $TEST$ error "Multiple declarations in this package have the name 'DuplicateSchema'." +# $TEST$ error "Multiple declarations in this package have the name 'DuplicateSchema'." schema »DuplicateSchema« {} -// $TEST$ error "Multiple declarations in this package have the name 'duplicatePublicSegment'." +# $TEST$ error "Multiple declarations in this package have the name 'duplicatePublicSegment'." segment »duplicatePublicSegment«() {} -// $TEST$ error "Multiple declarations in this package have the name 'duplicateInternalSegment'." +# $TEST$ error "Multiple declarations in this package have the name 'duplicateInternalSegment'." internal segment »duplicateInternalSegment«() {} -// $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." +# $TEST$ no error r"Multiple declarations in this package have the name '\w*'\." private segment »duplicatePrivateSegment«() {} diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in annotation/main.sdstest b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in annotation/main.sdstest index 425a5f85..86e23675 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in annotation/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in annotation/main.sdstest @@ -1,10 +1,10 @@ package tests.validation.names.duplicates.inAnnotation annotation A( - // $TEST$ no error r"A parameter with name '\w*' exists already\." + # $TEST$ no error r"A parameter with name '\w*' exists already\." »duplicateParameter«: Int, - // $TEST$ error "A parameter with name 'duplicateParameter' exists already." + # $TEST$ error "A parameter with name 'duplicateParameter' exists already." »duplicateParameter«: Int, - // $TEST$ no error r"A parameter with name '\w*' exists already\." + # $TEST$ no error r"A parameter with name '\w*' exists already\." »uniqueParameter«: Int ) diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in block lambda/main.sdstest b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in block lambda/main.sdstest index 5a2cbd98..e91fc67b 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in block lambda/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in block lambda/main.sdstest @@ -2,50 +2,50 @@ package tests.validation.names.duplicates.inBlockLambda pipeline p { ( - // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." »duplicateParameter«, - // $TEST$ error "A parameter or placeholder with name 'duplicateParameter' exists already." + # $TEST$ error "A parameter or placeholder with name 'duplicateParameter' exists already." »duplicateParameter«, - // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." »uniqueParameter«, - // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." »parameterAndPlaceholder«, - // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." »parameterAndResult« ) { - // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." val »duplicatePlaceholder« = 1; - // $TEST$ error "A parameter or placeholder with name 'duplicatePlaceholder' exists already." + # $TEST$ error "A parameter or placeholder with name 'duplicatePlaceholder' exists already." val »duplicatePlaceholder« = 1; - // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." val »uniquePlaceholder« = 1; - // $TEST$ error "A parameter or placeholder with name 'parameterAndPlaceholder' exists already." + # $TEST$ error "A parameter or placeholder with name 'parameterAndPlaceholder' exists already." val »parameterAndPlaceholder« = 1; - // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." val »placeholderAndResult« = 1; - // $TEST$ no error r"A result with name '\w*' exists already\." + # $TEST$ no error r"A result with name '\w*' exists already\." yield »duplicateResult« = 0; - // $TEST$ error "A result with name 'duplicateResult' exists already." + # $TEST$ error "A result with name 'duplicateResult' exists already." yield »duplicateResult« = 0; - // $TEST$ no error r"A result with name '\w*' exists already\." + # $TEST$ no error r"A result with name '\w*' exists already\." yield »uniqueResult« = 0; - // $TEST$ no error r"A result with name '\w*' exists already\." + # $TEST$ no error r"A result with name '\w*' exists already\." yield »parameterAndResult« = 0; - //$TEST$ no error r"A result with name '\w*' exists already\." + #$TEST$ no error r"A result with name '\w*' exists already\." yield »placeholderAndResult« = 0; - //$TEST$ no error r"A result with name '\w*' exists already\." + #$TEST$ no error r"A result with name '\w*' exists already\." yield »resultAndPlaceholder« = 0; - // $TEST$ no error "A parameter or placeholder with name '\w*' exists already\." + # $TEST$ no error "A parameter or placeholder with name '\w*' exists already\." val »resultAndPlaceholder« = 1; () { - // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." val »duplicatePlaceholder« = 1; - // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." val »parameterAndPlaceholder« = 1; - // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." val »placeholderAndResult« = 1; }; }; diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in callable type/main.sdstest b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in callable type/main.sdstest index 9320563e..2076ff96 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in callable type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in callable type/main.sdstest @@ -2,22 +2,22 @@ package tests.validation.names.duplicates.inCallableType segment s( f: ( - // $TEST$ no error r"A parameter with name '\w*' exists already\." + # $TEST$ no error r"A parameter with name '\w*' exists already\." »duplicateParameter«: Int, - // $TEST$ error "A parameter with name 'duplicateParameter' exists already." + # $TEST$ error "A parameter with name 'duplicateParameter' exists already." »duplicateParameter«: Int, - // $TEST$ no error r"A parameter with name '\w*' exists already\." + # $TEST$ no error r"A parameter with name '\w*' exists already\." »uniqueParameter«: Int, - // $TEST$ no error r"A parameter with name '\w*' exists already\." + # $TEST$ no error r"A parameter with name '\w*' exists already\." »parameterAndResult«: Int ) -> ( - // $TEST$ no error r"A result with name '\w*' exists already\." + # $TEST$ no error r"A result with name '\w*' exists already\." »duplicateResult«: Int, - // $TEST$ error "A result with name 'duplicateResult' exists already." + # $TEST$ error "A result with name 'duplicateResult' exists already." »duplicateResult«: Int, - // $TEST$ no error r"A result with name '\w*' exists already\." + # $TEST$ no error r"A result with name '\w*' exists already\." »uniqueResult«: Int, - // $TEST$ no error r"A result with name '\w*' exists already\." + # $TEST$ no error r"A result with name '\w*' exists already\." »parameterAndResult«: Int ) ) {} diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in class/main.sdstest b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in class/main.sdstest index 650707e0..5c05d96c 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in class/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in class/main.sdstest @@ -1,241 +1,241 @@ package tests.validation.names.duplicates.inClass class MyClass1< - // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »DuplicateTypeParameter«, - // $TEST$ error "A type parameter or parameter with name 'DuplicateTypeParameter' exists already." + # $TEST$ error "A type parameter or parameter with name 'DuplicateTypeParameter' exists already." »DuplicateTypeParameter«, - // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »UniqueTypeParameter«, - // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »TypeParameterAndParameter«, - // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »TypeParameterAndMember«, >( - // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »duplicateParameter«: Int, - // $TEST$ error "A type parameter or parameter with name 'duplicateParameter' exists already." + # $TEST$ error "A type parameter or parameter with name 'duplicateParameter' exists already." »duplicateParameter«: Int, - // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »uniqueParameter«: Int, - // $TEST$ error "A type parameter or parameter with name 'TypeParameterAndParameter' exists already." + # $TEST$ error "A type parameter or parameter with name 'TypeParameterAndParameter' exists already." »TypeParameterAndParameter«: Int, - // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »parameterAndMember«: Int, ) { - // $TEST$ no error r"An instance member with name '\w*' exists already\." + # $TEST$ no error r"An instance member with name '\w*' exists already\." attr »duplicateInstanceAttribute«: Int - // $TEST$ error "An instance member with name 'duplicateInstanceAttribute' exists already." + # $TEST$ error "An instance member with name 'duplicateInstanceAttribute' exists already." attr »duplicateInstanceAttribute«: Int - // $TEST$ no error r"An instance member with name '\w*' exists already\." + # $TEST$ no error r"An instance member with name '\w*' exists already\." attr »uniqueInstanceAttribute«: Int - // $TEST$ no error r"A static member with name '\w*' exists already\." + # $TEST$ no error r"A static member with name '\w*' exists already\." static attr »duplicateStaticAttribute«: Int - // $TEST$ error "A static member with name 'duplicateStaticAttribute' exists already." + # $TEST$ error "A static member with name 'duplicateStaticAttribute' exists already." static attr »duplicateStaticAttribute«: Int - // $TEST$ no error r"A static member with name '\w*' exists already\." + # $TEST$ no error r"A static member with name '\w*' exists already\." static attr »uniqueStaticAttribute«: Int - // $TEST$ no error r"A static member with name '\w*' exists already\." + # $TEST$ no error r"A static member with name '\w*' exists already\." class »DuplicateClass« - // $TEST$ error "A static member with name 'DuplicateClass' exists already." + # $TEST$ error "A static member with name 'DuplicateClass' exists already." class »DuplicateClass« - // $TEST$ no error r"A static member with name '\w*' exists already\." + # $TEST$ no error r"A static member with name '\w*' exists already\." class »UniqueClass« - // $TEST$ no error r"A static member with name '\w*' exists already\." + # $TEST$ no error r"A static member with name '\w*' exists already\." enum »DuplicateEnum« - // $TEST$ error "A static member with name 'DuplicateEnum' exists already." + # $TEST$ error "A static member with name 'DuplicateEnum' exists already." enum »DuplicateEnum« - // $TEST$ no error r"A static member with name '\w*' exists already\." + # $TEST$ no error r"A static member with name '\w*' exists already\." enum »UniqueEnum« - // $TEST$ no error r"An instance member with name '\w*' exists already\." + # $TEST$ no error r"An instance member with name '\w*' exists already\." fun »duplicateInstanceMethod«() - // $TEST$ error "An instance member with name 'duplicateInstanceMethod' exists already." + # $TEST$ error "An instance member with name 'duplicateInstanceMethod' exists already." fun »duplicateInstanceMethod«() - // $TEST$ no error r"An instance member with name '\w*' exists already\." + # $TEST$ no error r"An instance member with name '\w*' exists already\." fun »uniqueInstanceMethod«() - // $TEST$ no error r"A static member with name '\w*' exists already\." + # $TEST$ no error r"A static member with name '\w*' exists already\." static fun »duplicateStaticMethod«() - // $TEST$ error "A static member with name 'duplicateStaticMethod' exists already." + # $TEST$ error "A static member with name 'duplicateStaticMethod' exists already." static fun »duplicateStaticMethod«() - // $TEST$ no error r"A static member with name '\w*' exists already\." + # $TEST$ no error r"A static member with name '\w*' exists already\." static fun »uniqueStaticMethod«() - // $TEST$ no error r"An instance member with name '\w*' exists already\." + # $TEST$ no error r"An instance member with name '\w*' exists already\." attr »duplicateInstanceMember«: Int - // $TEST$ error "An instance member with name 'duplicateInstanceMember' exists already." + # $TEST$ error "An instance member with name 'duplicateInstanceMember' exists already." fun »duplicateInstanceMember«() - // $TEST$ no error r"A static member with name '\w*' exists already\." + # $TEST$ no error r"A static member with name '\w*' exists already\." static attr »duplicateStaticMember«: Int - // $TEST$ error "A static member with name 'duplicateStaticMember' exists already." + # $TEST$ error "A static member with name 'duplicateStaticMember' exists already." class »duplicateStaticMember« - // $TEST$ error "A static member with name 'duplicateStaticMember' exists already." + # $TEST$ error "A static member with name 'duplicateStaticMember' exists already." enum »duplicateStaticMember« - // $TEST$ error "A static member with name 'duplicateStaticMember' exists already." + # $TEST$ error "A static member with name 'duplicateStaticMember' exists already." static fun »duplicateStaticMember«() } class MyClass2< - // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »TypeParameterAndMember«, > { - // $TEST$ no error r"A.*member with name '\w*' exists already\." + # $TEST$ no error r"A.*member with name '\w*' exists already\." attr »TypeParameterAndMember«: Int - // $TEST$ no error r"A.*member with name '\w*' exists already\." + # $TEST$ no error r"A.*member with name '\w*' exists already\." attr »instanceAndStaticMember«: Int - // $TEST$ no error "r"A.*member with name '\w*' exists already\." + # $TEST$ no error "r"A.*member with name '\w*' exists already\." static attr »instanceAndStaticMember«: Int - // $TEST$ no error "r"A.*member with name '\w*' exists already\." + # $TEST$ no error "r"A.*member with name '\w*' exists already\." static attr »staticAndInstanceMember«: Int - // $TEST$ no error r"A.*member with name '\w*' exists already\." + # $TEST$ no error r"A.*member with name '\w*' exists already\." attr »staticAndInstanceMember«: Int } class MyClass3< - // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »TypeParameterAndMember«, > { - // $TEST$ no error r"A.*member with name '\w*' exists already\." + # $TEST$ no error r"A.*member with name '\w*' exists already\." static attr »TypeParameterAndMember«: Int - // $TEST$ no error r"A.*member with name '\w*' exists already\." + # $TEST$ no error r"A.*member with name '\w*' exists already\." attr »instanceAndStaticMember«: Int - // $TEST$ no error "r"A.*member with name '\w*' exists already\." + # $TEST$ no error "r"A.*member with name '\w*' exists already\." class »instanceAndStaticMember« - // $TEST$ no error "r"A.*member with name '\w*' exists already\." + # $TEST$ no error "r"A.*member with name '\w*' exists already\." class »staticAndInstanceMember« - // $TEST$ no error r"A.*member with name '\w*' exists already\." + # $TEST$ no error r"A.*member with name '\w*' exists already\." attr »staticAndInstanceMember«: Int } class MyClass4< - // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »TypeParameterAndMember«, > { - // $TEST$ no error r"A.*member with name '\w*' exists already\." + # $TEST$ no error r"A.*member with name '\w*' exists already\." class »TypeParameterAndMember« - // $TEST$ no error r"A.*member with name '\w*' exists already\." + # $TEST$ no error r"A.*member with name '\w*' exists already\." attr »instanceAndStaticMember«: Int - // $TEST$ no error "r"A.*member with name '\w*' exists already\." + # $TEST$ no error "r"A.*member with name '\w*' exists already\." enum »instanceAndStaticMember« - // $TEST$ no error "r"A.*member with name '\w*' exists already\." + # $TEST$ no error "r"A.*member with name '\w*' exists already\." enum »staticAndInstanceMember« - // $TEST$ no error r"A.*member with name '\w*' exists already\." + # $TEST$ no error r"A.*member with name '\w*' exists already\." attr »staticAndInstanceMember«: Int } class MyClass5< - // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »TypeParameterAndMember«, > { - // $TEST$ no error r"A.*member with name '\w*' exists already\." + # $TEST$ no error r"A.*member with name '\w*' exists already\." enum »TypeParameterAndMember« - // $TEST$ no error r"A.*member with name '\w*' exists already\." + # $TEST$ no error r"A.*member with name '\w*' exists already\." attr »instanceAndStaticMember«: Int - // $TEST$ no error "r"A.*member with name '\w*' exists already\." + # $TEST$ no error "r"A.*member with name '\w*' exists already\." static fun »instanceAndStaticMember«() - // $TEST$ no error "r"A.*member with name '\w*' exists already\." + # $TEST$ no error "r"A.*member with name '\w*' exists already\." static fun »staticAndInstanceMember«() - // $TEST$ no error r"A.*member with name '\w*' exists already\." + # $TEST$ no error r"A.*member with name '\w*' exists already\." attr »staticAndInstanceMember«: Int } class MyClass6< - // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »TypeParameterAndMember«, > { - // $TEST$ no error r"A.*member with name '\w*' exists already\." + # $TEST$ no error r"A.*member with name '\w*' exists already\." fun »TypeParameterAndMember«() - // $TEST$ no error r"A.*member with name '\w*' exists already\." + # $TEST$ no error r"A.*member with name '\w*' exists already\." fun »instanceAndStaticMember«() - // $TEST$ no error "r"A.*member with name '\w*' exists already\." + # $TEST$ no error "r"A.*member with name '\w*' exists already\." static attr »instanceAndStaticMember«: Int - // $TEST$ no error "r"A.*member with name '\w*' exists already\." + # $TEST$ no error "r"A.*member with name '\w*' exists already\." static attr »staticAndInstanceMember«: Int - // $TEST$ no error r"A.*member with name '\w*' exists already\." + # $TEST$ no error r"A.*member with name '\w*' exists already\." fun »staticAndInstanceMember«() } class MyClass7< - // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »TypeParameterAndMember«, > { - // $TEST$ no error r"A.*member with name '\w*' exists already\." + # $TEST$ no error r"A.*member with name '\w*' exists already\." fun »TypeParameterAndMember«() - // $TEST$ no error r"A.*member with name '\w*' exists already\." + # $TEST$ no error r"A.*member with name '\w*' exists already\." fun »instanceAndStaticMember«() - // $TEST$ no error "r"A.*member with name '\w*' exists already\." + # $TEST$ no error "r"A.*member with name '\w*' exists already\." class »instanceAndStaticMember« - // $TEST$ no error "r"A.*member with name '\w*' exists already\." + # $TEST$ no error "r"A.*member with name '\w*' exists already\." class »staticAndInstanceMember« - // $TEST$ no error r"A.*member with name '\w*' exists already\." + # $TEST$ no error r"A.*member with name '\w*' exists already\." fun »staticAndInstanceMember«() } class MyClass8( - // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »parameterAndMember«: Int, ) { - // $TEST$ no error r"A.*member with name '\w*' exists already\." + # $TEST$ no error r"A.*member with name '\w*' exists already\." attr »parameterAndMember«: Int - // $TEST$ no error r"A.*member with name '\w*' exists already\." + # $TEST$ no error r"A.*member with name '\w*' exists already\." fun »instanceAndStaticMember«() - // $TEST$ no error "r"A.*member with name '\w*' exists already\." + # $TEST$ no error "r"A.*member with name '\w*' exists already\." enum »instanceAndStaticMember« - // $TEST$ no error "r"A.*member with name '\w*' exists already\." + # $TEST$ no error "r"A.*member with name '\w*' exists already\." enum »staticAndInstanceMember« - // $TEST$ no error r"A.*member with name '\w*' exists already\." + # $TEST$ no error r"A.*member with name '\w*' exists already\." fun »staticAndInstanceMember«() } class MyClass9( - // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »parameterAndMember«: Int, ) { - // $TEST$ no error r"A.*member with name '\w*' exists already\." + # $TEST$ no error r"A.*member with name '\w*' exists already\." class »parameterAndMember« - // $TEST$ no error r"A.*member with name '\w*' exists already\." + # $TEST$ no error r"A.*member with name '\w*' exists already\." fun »instanceAndStaticMember«() - // $TEST$ no error "r"A.*member with name '\w*' exists already\." + # $TEST$ no error "r"A.*member with name '\w*' exists already\." static fun »instanceAndStaticMember«() - // $TEST$ no error "r"A.*member with name '\w*' exists already\." + # $TEST$ no error "r"A.*member with name '\w*' exists already\." static fun »staticAndInstanceMember«() - // $TEST$ no error r"A.*member with name '\w*' exists already\." + # $TEST$ no error r"A.*member with name '\w*' exists already\." fun »staticAndInstanceMember«() } class MyClass10( - // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »parameterAndMember«: Int, ) { - // $TEST$ no error r"A.*member with name '\w*' exists already\." + # $TEST$ no error r"A.*member with name '\w*' exists already\." enum »parameterAndMember« } class MyClass11( - // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »parameterAndMember«: Int, ) { - // $TEST$ no error r"A.*member with name '\w*' exists already\." + # $TEST$ no error r"A.*member with name '\w*' exists already\." fun »parameterAndMember«() } diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in enum variant/main.sdstest b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in enum variant/main.sdstest index e9f30a7c..3149a17a 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in enum variant/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in enum variant/main.sdstest @@ -2,11 +2,11 @@ package tests.validation.names.duplicates.inEnumVariant enum MyEnum { MyEnumVariant( - // $TEST$ no error r"A parameter with name '\w*' exists already\." + # $TEST$ no error r"A parameter with name '\w*' exists already\." »duplicateParameter«: Int, - // $TEST$ error "A parameter with name 'duplicateParameter' exists already." + # $TEST$ error "A parameter with name 'duplicateParameter' exists already." »duplicateParameter«: Int, - // $TEST$ no error r"A parameter with name '\w*' exists already\." + # $TEST$ no error r"A parameter with name '\w*' exists already\." »uniqueParameter«: Int, ) } diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in enum/main.sdstest b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in enum/main.sdstest index 08903cba..d868bab6 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in enum/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in enum/main.sdstest @@ -1,10 +1,10 @@ package tests.validation.names.duplicates.inEnum enum MyEnum { - // $TEST$ no error r"A variant with name '\w*' exists already\." + # $TEST$ no error r"A variant with name '\w*' exists already\." »MyVariant1« - // $TEST$ error "A variant with name 'MyVariant1' exists already." + # $TEST$ error "A variant with name 'MyVariant1' exists already." »MyVariant1« - // $TEST$ no error r"A variant with name '\w*' exists already\." + # $TEST$ no error r"A variant with name '\w*' exists already\." »MyVariant2« } diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in expression lambda/main.sdstest b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in expression lambda/main.sdstest index 71f4bb00..88a373fd 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in expression lambda/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in expression lambda/main.sdstest @@ -2,11 +2,11 @@ package tests.validation.names.duplicates.inExpressionLambda pipeline p { ( - // $TEST$ no error r"A parameter with name '\w*' exists already\." + # $TEST$ no error r"A parameter with name '\w*' exists already\." »duplicateParameter«, - // $TEST$ error "A parameter with name 'duplicateParameter' exists already." + # $TEST$ error "A parameter with name 'duplicateParameter' exists already." »duplicateParameter«, - // $TEST$ no error r"A parameter with name '\w*' exists already\." + # $TEST$ no error r"A parameter with name '\w*' exists already\." »uniqueParameter«, ) -> 1; } diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in function/main.sdstest b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in function/main.sdstest index 802d3412..6f75534b 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in function/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in function/main.sdstest @@ -1,36 +1,36 @@ package tests.validation.names.duplicates.inFunction fun myFunction< - // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »DuplicateTypeParameter«, - // $TEST$ error "A type parameter or parameter with name 'DuplicateTypeParameter' exists already." + # $TEST$ error "A type parameter or parameter with name 'DuplicateTypeParameter' exists already." »DuplicateTypeParameter«, - // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »UniqueTypeParameter«, - // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »TypeParameterAndParameter«, - // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »TypeParameterAndResult«, >( - // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »duplicateParameter«: Int, - // $TEST$ error "A type parameter or parameter with name 'duplicateParameter' exists already." + # $TEST$ error "A type parameter or parameter with name 'duplicateParameter' exists already." »duplicateParameter«: Int, - // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »uniqueParameter«: Int, - // $TEST$ error "A type parameter or parameter with name 'TypeParameterAndParameter' exists already." + # $TEST$ error "A type parameter or parameter with name 'TypeParameterAndParameter' exists already." »TypeParameterAndParameter«: Int, - // $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." + # $TEST$ no error r"A type parameter or parameter with name '\w*' exists already\." »parameterAndResult«: Int, ) -> ( - // $TEST$ no error r"A result with name '\w*' exists already\." + # $TEST$ no error r"A result with name '\w*' exists already\." »duplicateResult« : Int, - // $TEST$ error "A result with name 'duplicateResult' exists already." + # $TEST$ error "A result with name 'duplicateResult' exists already." »duplicateResult« : Int, - // $TEST$ no error r"A result with name '\w*' exists already\." + # $TEST$ no error r"A result with name '\w*' exists already\." »uniqueResult« : Int, - // $TEST$ no error r"A result with name '\w*' exists already\." + # $TEST$ no error r"A result with name '\w*' exists already\." »parameterAndResult« : Int, - // $TEST$ no error r"A result with name '\w*' exists already\." + # $TEST$ no error r"A result with name '\w*' exists already\." »TypeParameterAndResult« : Int, ) diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in pipeline file/main.sdspipe b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in pipeline file/main.sdspipe index 92c59bf4..c0c48adc 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in pipeline file/main.sdspipe +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in pipeline file/main.sdspipe @@ -1,85 +1,85 @@ package tests.validation.names.inPipelineFile -// $TEST$ no error r"A declaration with name '\w*' was imported already\." +# $TEST$ no error r"A declaration with name '\w*' was imported already\." from tests.validation.names.inPipelineFile.other import »UniqueImport« -// $TEST$ no error r"A declaration with name '\w*' was imported already\." +# $TEST$ no error r"A declaration with name '\w*' was imported already\." from tests.validation.names.inPipelineFile.other import »DuplicateImport« -// $TEST$ error "A declaration with name 'DuplicateImport' was imported already." +# $TEST$ error "A declaration with name 'DuplicateImport' was imported already." from tests.validation.names.inPipelineFile.other import »DuplicateImport« -// $TEST$ no error r"A declaration with name '\w*' was imported already\." -// $TEST$ error "A declaration with name 'DuplicateAliasedImport' was imported already." +# $TEST$ no error r"A declaration with name '\w*' was imported already\." +# $TEST$ error "A declaration with name 'DuplicateAliasedImport' was imported already." from tests.validation.names.inPipelineFile.other import »DuplicateAliasedImport«, DuplicateImport as »DuplicateAliasedImport« -// $TEST$ no error r"A declaration with name '\w*' was imported already\." +# $TEST$ no error r"A declaration with name '\w*' was imported already\." from tests.validation.names.inPipelineFile.other import »Unresolved« -// $TEST$ no error r"A declaration with name '\w*' was imported already\." +# $TEST$ no error r"A declaration with name '\w*' was imported already\." from tests.validation.names.inPipelineFile.other import »Unresolved« -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." annotation »UniqueAnnotation« -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." annotation »DuplicateAnnotation« -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." annotation »DuplicateAnnotation« -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." class »UniqueClass« -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." class »DuplicateClass« -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." class »DuplicateClass« -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." enum »UniqueEnum« -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." enum »DuplicateEnum« -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." enum »DuplicateEnum« -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." fun »uniqueFunction«() -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." fun »duplicateFunction«() -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." fun »duplicateFunction«() -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." schema »UniqueSchema« {} -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." schema »DuplicateSchema« {} -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." schema »DuplicateSchema« {} -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." pipeline »uniquePipeline« {} -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." pipeline »duplicatePipeline« {} -// $TEST$ error "A declaration with name 'duplicatePipeline' exists already in this file." +# $TEST$ error "A declaration with name 'duplicatePipeline' exists already in this file." pipeline »duplicatePipeline« {} -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." segment »uniqueSegment«() {} -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." segment »duplicateSegment«() {} -// $TEST$ error "A declaration with name 'duplicateSegment' exists already in this file." +# $TEST$ error "A declaration with name 'duplicateSegment' exists already in this file." segment »duplicateSegment«() {} -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." annotation »DuplicateDeclaration« -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." class »DuplicateDeclaration« -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." enum »DuplicateDeclaration« -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." fun »DuplicateDeclaration«() -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." schema »DuplicateDeclaration« {} -// $TEST$ error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ error r"A declaration with name '\w*' exists already in this file\." pipeline »DuplicateDeclaration« {} -// $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." +# $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." segment »DuplicateDeclaration«() {} diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in pipeline/main.sdstest b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in pipeline/main.sdstest index f53765c2..577f8d9c 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in pipeline/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in pipeline/main.sdstest @@ -1,10 +1,10 @@ package tests.validation.names.duplicates.inPipeline pipeline p { - // $TEST$ no error r"A placeholder with name '\w*' exists already\." + # $TEST$ no error r"A placeholder with name '\w*' exists already\." val »duplicatePlaceholder« = 1; - // $TEST$ error "A placeholder with name 'duplicatePlaceholder' exists already." + # $TEST$ error "A placeholder with name 'duplicatePlaceholder' exists already." val »duplicatePlaceholder« = 1; - // $TEST$ no error r"A placeholder with name '\w*' exists already\." + # $TEST$ no error r"A placeholder with name '\w*' exists already\." val »uniquePlaceholder« = 1; } diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in schema/main.sdstest b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in schema/main.sdstest index 735d2be7..eab9185b 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in schema/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in schema/main.sdstest @@ -1,10 +1,10 @@ package tests.validation.names.duplicates.inSchema schema S { - // $TEST$ no error r"A column with name '\w*' exists already\." + # $TEST$ no error r"A column with name '\w*' exists already\." »"duplicateColumn"«: Int, - // $TEST$ error "A column with name 'duplicateColumn' exists already." + # $TEST$ error "A column with name 'duplicateColumn' exists already." »"duplicateColumn"«: Int, - // $TEST$ no error r"A column with name '\w*' exists already\." + # $TEST$ no error r"A column with name '\w*' exists already\." »"uniqueColumn"«: Int, } diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in segment/main.sdstest b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in segment/main.sdstest index a46b224c..e8e2c548 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in segment/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in segment/main.sdstest @@ -1,45 +1,45 @@ package tests.validation.names.duplicates.inSegment segment mySegment( - // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." »duplicateParameter«: Int, - // $TEST$ error "A parameter or placeholder with name 'duplicateParameter' exists already." + # $TEST$ error "A parameter or placeholder with name 'duplicateParameter' exists already." »duplicateParameter«: Int, - // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." »uniqueParameter«: Int, - // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." »parameterAndPlaceholder«: Int, - // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." »parameterAndResult«: Int, ) -> ( - // $TEST$ no error r"A result with name '\w*' exists already\." + # $TEST$ no error r"A result with name '\w*' exists already\." »duplicateResult« : Int, - // $TEST$ error "A result with name 'duplicateResult' exists already." + # $TEST$ error "A result with name 'duplicateResult' exists already." »duplicateResult« : Int, - // $TEST$ no error r"A result with name '\w*' exists already\." + # $TEST$ no error r"A result with name '\w*' exists already\." »uniqueResult« : Int, - // $TEST$ no error r"A result with name '\w*' exists already\." + # $TEST$ no error r"A result with name '\w*' exists already\." »parameterAndResult« : Int, - // $TEST$ no error r"A result with name '\w*' exists already\." + # $TEST$ no error r"A result with name '\w*' exists already\." »placeholderAndResult« : Int, ) { - // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." val »duplicatePlaceholder« = 1; - // $TEST$ error "A parameter or placeholder with name 'duplicatePlaceholder' exists already." + # $TEST$ error "A parameter or placeholder with name 'duplicatePlaceholder' exists already." val »duplicatePlaceholder« = 1; - // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." val »uniquePlaceholder« = 1; - // $TEST$ error "A parameter or placeholder with name 'parameterAndPlaceholder' exists already." + # $TEST$ error "A parameter or placeholder with name 'parameterAndPlaceholder' exists already." val »parameterAndPlaceholder« = 1; - // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." val »placeholderAndResult« = 1; () { - // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." val »duplicatePlaceholder« = 1; - // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." val »parameterAndPlaceholder« = 1; - // $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." + # $TEST$ no error r"A parameter or placeholder with name '\w*' exists already\." val »placeholderAndResult« = 1; }; } diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in stub file/main.sdsstub b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in stub file/main.sdsstub index 867baa1f..e9a7c6ad 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in stub file/main.sdsstub +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in stub file/main.sdsstub @@ -1,85 +1,85 @@ package tests.validation.names.inStubFile -// $TEST$ no error r"A declaration with name '\w*' was imported already\." +# $TEST$ no error r"A declaration with name '\w*' was imported already\." from tests.validation.names.inStubFile.other import »UniqueImport« -// $TEST$ no error r"A declaration with name '\w*' was imported already\." +# $TEST$ no error r"A declaration with name '\w*' was imported already\." from tests.validation.names.inStubFile.other import »DuplicateImport« -// $TEST$ error "A declaration with name 'DuplicateImport' was imported already." +# $TEST$ error "A declaration with name 'DuplicateImport' was imported already." from tests.validation.names.inStubFile.other import »DuplicateImport« -// $TEST$ no error r"A declaration with name '\w*' was imported already\." -// $TEST$ error "A declaration with name 'DuplicateAliasedImport' was imported already." +# $TEST$ no error r"A declaration with name '\w*' was imported already\." +# $TEST$ error "A declaration with name 'DuplicateAliasedImport' was imported already." from tests.validation.names.inStubFile.other import »DuplicateAliasedImport«, DuplicateImport as »DuplicateAliasedImport« -// $TEST$ no error r"A declaration with name '\w*' was imported already\." +# $TEST$ no error r"A declaration with name '\w*' was imported already\." from tests.validation.names.inStubFile.other import »Unresolved« -// $TEST$ no error r"A declaration with name '\w*' was imported already\." +# $TEST$ no error r"A declaration with name '\w*' was imported already\." from tests.validation.names.inStubFile.other import »Unresolved« -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." pipeline »uniqueTest« {} -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." pipeline »duplicateTest« {} -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." pipeline »duplicateTest« {} -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." segment »uniqueSegment«() {} -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." segment »duplicateSegment«() {} -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." segment »duplicateSegment«() {} -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." annotation »UniqueAnnotation« -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." annotation »DuplicateAnnotation« -// $TEST$ error "A declaration with name 'DuplicateAnnotation' exists already in this file." +# $TEST$ error "A declaration with name 'DuplicateAnnotation' exists already in this file." annotation »DuplicateAnnotation« -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." class »UniqueClass« -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." class »DuplicateClass« -// $TEST$ error "A declaration with name 'DuplicateClass' exists already in this file." +# $TEST$ error "A declaration with name 'DuplicateClass' exists already in this file." class »DuplicateClass« -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." enum »UniqueEnum« -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." enum »DuplicateEnum« -// $TEST$ error "A declaration with name 'DuplicateEnum' exists already in this file." +# $TEST$ error "A declaration with name 'DuplicateEnum' exists already in this file." enum »DuplicateEnum« -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." fun »uniqueFunction«() -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." fun »duplicateFunction«() -// $TEST$ error "A declaration with name 'duplicateFunction' exists already in this file." +# $TEST$ error "A declaration with name 'duplicateFunction' exists already in this file." fun »duplicateFunction«() -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." schema »UniqueSchema« {} -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." schema »DuplicateSchema« {} -// $TEST$ error "A declaration with name 'DuplicateSchema' exists already in this file." +# $TEST$ error "A declaration with name 'DuplicateSchema' exists already in this file." schema »DuplicateSchema« {} -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." pipeline »DuplicateDeclaration« {} -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." segment »DuplicateDeclaration«() {} -// $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." +# $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." annotation »DuplicateDeclaration« -// $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." +# $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." class »DuplicateDeclaration« -// $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." +# $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." enum »DuplicateDeclaration« -// $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." +# $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." fun »DuplicateDeclaration«() -// $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." +# $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." schema »DuplicateDeclaration« {} diff --git a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in test file/main.sdstest b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in test file/main.sdstest index acd73161..b6641e25 100644 --- a/packages/ttsl-lang/tests/resources/validation/names/duplicates/in test file/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/names/duplicates/in test file/main.sdstest @@ -1,84 +1,84 @@ package tests.validation.names.inTestFile -// $TEST$ no error r"A declaration with name '\w*' was imported already\." +# $TEST$ no error r"A declaration with name '\w*' was imported already\." from tests.validation.names.inTestFile.other import »UniqueImport« -// $TEST$ no error r"A declaration with name '\w*' was imported already\." +# $TEST$ no error r"A declaration with name '\w*' was imported already\." from tests.validation.names.inTestFile.other import »DuplicateImport« -// $TEST$ error "A declaration with name 'DuplicateImport' was imported already." +# $TEST$ error "A declaration with name 'DuplicateImport' was imported already." from tests.validation.names.inTestFile.other import »DuplicateImport« -// $TEST$ no error r"A declaration with name '\w*' was imported already\." -// $TEST$ error "A declaration with name 'DuplicateAliasedImport' was imported already." +# $TEST$ no error r"A declaration with name '\w*' was imported already\." +# $TEST$ error "A declaration with name 'DuplicateAliasedImport' was imported already." from tests.validation.names.inTestFile.other import »DuplicateAliasedImport«, DuplicateImport as »DuplicateAliasedImport« -// $TEST$ no error r"A declaration with name '\w*' was imported already\." +# $TEST$ no error r"A declaration with name '\w*' was imported already\." from tests.validation.names.inTestFile.other import »Unresolved« -// $TEST$ no error r"A declaration with name '\w*' was imported already\." +# $TEST$ no error r"A declaration with name '\w*' was imported already\." from tests.validation.names.inTestFile.other import »Unresolved« -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." annotation »UniqueAnnotation« -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." annotation »DuplicateAnnotation« -// $TEST$ error "A declaration with name 'DuplicateAnnotation' exists already in this file." +# $TEST$ error "A declaration with name 'DuplicateAnnotation' exists already in this file." annotation »DuplicateAnnotation« -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." class »UniqueClass« -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." class »DuplicateClass« -// $TEST$ error "A declaration with name 'DuplicateClass' exists already in this file." +# $TEST$ error "A declaration with name 'DuplicateClass' exists already in this file." class »DuplicateClass« -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." enum »UniqueEnum« -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." enum »DuplicateEnum« -// $TEST$ error "A declaration with name 'DuplicateEnum' exists already in this file." +# $TEST$ error "A declaration with name 'DuplicateEnum' exists already in this file." enum »DuplicateEnum« -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." fun »uniqueFunction«() -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." fun »duplicateFunction«() -// $TEST$ error "A declaration with name 'duplicateFunction' exists already in this file." +# $TEST$ error "A declaration with name 'duplicateFunction' exists already in this file." fun »duplicateFunction«() -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." pipeline »uniquePipeline« {} -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." pipeline »duplicatePipeline« {} -// $TEST$ error "A declaration with name 'duplicatePipeline' exists already in this file." +# $TEST$ error "A declaration with name 'duplicatePipeline' exists already in this file." pipeline »duplicatePipeline« {} -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." schema »UniqueSchema« {} -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." schema »DuplicateSchema« {} -// $TEST$ error "A declaration with name 'DuplicateSchema' exists already in this file." +# $TEST$ error "A declaration with name 'DuplicateSchema' exists already in this file." schema »DuplicateSchema« {} -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." segment »uniqueSegment«() {} -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." segment »duplicateSegment«() {} -// $TEST$ error "A declaration with name 'duplicateSegment' exists already in this file." +# $TEST$ error "A declaration with name 'duplicateSegment' exists already in this file." segment »duplicateSegment«() {} -// $TEST$ no error r"A declaration with name '\w*' exists already in this file\." +# $TEST$ no error r"A declaration with name '\w*' exists already in this file\." annotation »DuplicateDeclaration« -// $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." +# $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." class »DuplicateDeclaration« -// $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." +# $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." enum »DuplicateDeclaration« -// $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." +# $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." fun »DuplicateDeclaration«() -// $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." +# $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." pipeline »DuplicateDeclaration« {} -// $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." +# $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." segment »DuplicateDeclaration«() {} -// $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." +# $TEST$ error "A declaration with name 'DuplicateDeclaration' exists already in this file." schema »DuplicateDeclaration« {} diff --git a/packages/ttsl-lang/tests/resources/validation/other/argument lists/duplicate parameter/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/argument lists/duplicate parameter/main.sdstest index 244b3d03..2d105184 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/argument lists/duplicate parameter/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/argument lists/duplicate parameter/main.sdstest @@ -13,25 +13,25 @@ fun myFunction(a: Int, b: Int = 0) segment mySegment(a: Int, b: Int = 0) {} -pipeline myPipeline {} +function myFunction () {} @MyAnnotation( - // $TEST$ no error "The parameter 'a' is already set." + # $TEST$ no error "The parameter 'a' is already set." »1«, - // $TEST$ error "The parameter 'a' is already set." + # $TEST$ error "The parameter 'a' is already set." »a = 1« ) @MyAnnotation( - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »b = 1«, - // $TEST$ error "The parameter 'b' is already set." + # $TEST$ error "The parameter 'b' is already set." »b = 1« ) @MyAnnotation( - // $TEST$ no error "The parameter 'a' is already set." + # $TEST$ no error "The parameter 'a' is already set." »a = 1«, - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »b = 1« ) segment test( @@ -45,101 +45,101 @@ segment test( val myAnnotationAlias = MyAnnotation; MyAnnotation( - // $TEST$ no error "The parameter 'a' is already set." + # $TEST$ no error "The parameter 'a' is already set." »1«, - // $TEST$ no error "The parameter 'a' is already set." + # $TEST$ no error "The parameter 'a' is already set." »a = 1« ); myAnnotationAlias( - // $TEST$ no error "The parameter 'b' is already set." + # $TEST$ no error "The parameter 'b' is already set." »b = 1«, - // $TEST$ no error "The parameter 'b' is already set." + # $TEST$ no error "The parameter 'b' is already set." »b = 1« ); MyAnnotation( - // $TEST$ no error "The parameter 'a' is already set." + # $TEST$ no error "The parameter 'a' is already set." »a = 1«, - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »b = 1« ); MyClass( - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »1«, - // $TEST$ error "The parameter 'a' is already set." + # $TEST$ error "The parameter 'a' is already set." »a = 1« ); MyClass( - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »b = 1«, - // $TEST$ error "The parameter 'b' is already set." + # $TEST$ error "The parameter 'b' is already set." »b = 1« ); MyClass( - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »a = 1«, - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »b = 1« ); MyEnum.MyEnumVariant( - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »1«, - // $TEST$ error "The parameter 'a' is already set." + # $TEST$ error "The parameter 'a' is already set." »a = 1« ); MyEnum.MyEnumVariant( - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »b = 1«, - // $TEST$ error "The parameter 'b' is already set." + # $TEST$ error "The parameter 'b' is already set." »b = 1« ); MyEnum.MyEnumVariant( - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »a = 1«, - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »b = 1« ); myFunction( - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »1«, - // $TEST$ error "The parameter 'a' is already set." + # $TEST$ error "The parameter 'a' is already set." »a = 1« ); myFunction( - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »b = 1«, - // $TEST$ error "The parameter 'b' is already set." + # $TEST$ error "The parameter 'b' is already set." »b = 1« ); myFunction( - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »a = 1«, - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »b = 1« ); myCallableType( - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »1«, - // $TEST$ error "The parameter 'a' is already set." + # $TEST$ error "The parameter 'a' is already set." »a = 1« ); myCallableType( - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »b = 1«, - // $TEST$ error "The parameter 'b' is already set." + # $TEST$ error "The parameter 'b' is already set." »b = 1« ); myCallableType( - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »a = 1«, - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »b = 1« ); @@ -147,21 +147,21 @@ segment test( val myBlockLambda = (a, b) {}; ((a, b) {})( - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »1«, - // $TEST$ error "The parameter 'a' is already set." + # $TEST$ error "The parameter 'a' is already set." »a = 1« ); myBlockLambda( - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »b = 1«, - // $TEST$ error "The parameter 'b' is already set." + # $TEST$ error "The parameter 'b' is already set." »b = 1« ); ((a, b) {})( - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »a = 1«, - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »b = 1« ); @@ -169,47 +169,47 @@ segment test( val myExpressionLambda = (a, b) -> 1; ((a, b) -> 1)( - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »1«, - // $TEST$ error "The parameter 'a' is already set." + # $TEST$ error "The parameter 'a' is already set." »a = 1« ); myExpressionLambda( - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »b = 1«, - // $TEST$ error "The parameter 'b' is already set." + # $TEST$ error "The parameter 'b' is already set." »b = 1« ); ((a, b) -> 1)( - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »a = 1«, - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »b = 1« ); myPipeline( - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »1«, - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »1« ); myPipeline( - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »a = 1«, - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »a = 1« ); unresolved( - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »1«, - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »1« ); unresolved( - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »a = 1«, - // $TEST$ no error r"The parameter '\w+' is already set\." + # $TEST$ no error r"The parameter '\w+' is already set\." »a = 1« ); } diff --git a/packages/ttsl-lang/tests/resources/validation/other/argument lists/missing required parameter/dont show this error if the argument list is missing altogether.sdstest b/packages/ttsl-lang/tests/resources/validation/other/argument lists/missing required parameter/dont show this error if the argument list is missing altogether.sdstest index 46a3935a..9f6741d3 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/argument lists/missing required parameter/dont show this error if the argument list is missing altogether.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/argument lists/missing required parameter/dont show this error if the argument list is missing altogether.sdstest @@ -1,6 +1,6 @@ package tests.validation.other.argumentLists.missingRequiredParameter -// $TEST$ no error r"The parameters? .* must be set here\." +# $TEST$ no error r"The parameters? .* must be set here\." @MyAnnotation segment mySegment3( diff --git a/packages/ttsl-lang/tests/resources/validation/other/argument lists/missing required parameter/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/argument lists/missing required parameter/main.sdstest index 167d6fea..9077cd25 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/argument lists/missing required parameter/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/argument lists/missing required parameter/main.sdstest @@ -13,22 +13,22 @@ fun myFunction(a: Int, b: Int, c: Int = 0) segment mySegment1(a: Int, b: Int, c: Int = 0) {} -pipeline myPipeline {} +function myFunction () {} -// $TEST$ error "The parameters 'a', 'b' must be set here." +# $TEST$ error "The parameters 'a', 'b' must be set here." @MyAnnotation»()« -// $TEST$ error "The parameter 'b' must be set here." +# $TEST$ error "The parameter 'b' must be set here." @MyAnnotation»(1)« -// $TEST$ no error r"The parameters? .* must be set here\." +# $TEST$ no error r"The parameters? .* must be set here\." @MyAnnotation»(1, 2)« -// $TEST$ no error r"The parameters? .* must be set here\." +# $TEST$ no error r"The parameters? .* must be set here\." @MyAnnotation»(1, 2, 3)« -// $TEST$ no error r"The parameters? .* must be set here\." +# $TEST$ no error r"The parameters? .* must be set here\." @MyAnnotation»(1, 2, 3, 4)« -// $TEST$ error "The parameter 'b' must be set here." +# $TEST$ error "The parameter 'b' must be set here." @MyAnnotation»(1, c = 2)« -// $TEST$ no error r"The parameters? .* must be set here\." +# $TEST$ no error r"The parameters? .* must be set here\." @MyAnnotation»(b = 1, a = 2)« segment mySegment2( myCallableType: (a: Int, b: Int, c: Int = 0) -> () @@ -40,136 +40,136 @@ segment mySegment2( * We can never call an annotation directly and should avoid showing additional errors. */ - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." MyAnnotation»()«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." MyAnnotation»(1)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." MyAnnotation»(1, 2)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." MyAnnotation»(1, 2, 3)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." MyAnnotation»(1, 2, 3, 4)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." MyAnnotation»(1, c = 2)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." MyAnnotation»(b = 1, a = 2)«; - // $TEST$ error "The parameters 'a', 'b' must be set here." + # $TEST$ error "The parameters 'a', 'b' must be set here." MyClass»()«; - // $TEST$ error "The parameter 'b' must be set here." + # $TEST$ error "The parameter 'b' must be set here." MyClass»(1)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." MyClass»(1, 2)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." MyClass»(1, 2, 3)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." MyClass»(1, 2, 3, 4)«; - // $TEST$ error "The parameter 'b' must be set here." + # $TEST$ error "The parameter 'b' must be set here." MyClass»(1, c = 2)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." MyClass»(b = 1, a = 2)«; - // $TEST$ error "The parameters 'a', 'b' must be set here." + # $TEST$ error "The parameters 'a', 'b' must be set here." MyEnum.MyEnumVariant»()«; - // $TEST$ error "The parameter 'b' must be set here." + # $TEST$ error "The parameter 'b' must be set here." MyEnum.MyEnumVariant»(1)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." MyEnum.MyEnumVariant»(1, 2)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." MyEnum.MyEnumVariant»(1, 2, 3)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." MyEnum.MyEnumVariant»(1, 2, 3, 4)«; - // $TEST$ error "The parameter 'b' must be set here." + # $TEST$ error "The parameter 'b' must be set here." MyEnum.MyEnumVariant»(1, c = 2)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." MyEnum.MyEnumVariant»(b = 1, a = 2)«; - // $TEST$ error "The parameters 'a', 'b' must be set here." + # $TEST$ error "The parameters 'a', 'b' must be set here." myFunction»()«; - // $TEST$ error "The parameter 'b' must be set here." + # $TEST$ error "The parameter 'b' must be set here." myFunction»(1)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." myFunction»(1, 2)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." myFunction»(1, 2, 3)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." myFunction»(1, 2, 3, 4)«; - // $TEST$ error "The parameter 'b' must be set here." + # $TEST$ error "The parameter 'b' must be set here." myFunction»(1, c = 2)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." myFunction»(b = 1, a = 2)«; - // $TEST$ error "The parameters 'a', 'b' must be set here." + # $TEST$ error "The parameters 'a', 'b' must be set here." mySegment1»()«; - // $TEST$ error "The parameter 'b' must be set here." + # $TEST$ error "The parameter 'b' must be set here." mySegment1»(1)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." mySegment1»(1, 2)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." mySegment1»(1, 2, 3)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." mySegment1»(1, 2, 3, 4)«; - // $TEST$ error "The parameter 'b' must be set here." + # $TEST$ error "The parameter 'b' must be set here." mySegment1»(1, c = 2)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." mySegment1»(b = 1, a = 2)«; - // $TEST$ error "The parameters 'a', 'b' must be set here." + # $TEST$ error "The parameters 'a', 'b' must be set here." myCallableType»()«; - // $TEST$ error "The parameter 'b' must be set here." + # $TEST$ error "The parameter 'b' must be set here." myCallableType»(1)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." myCallableType»(1, 2)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." myCallableType»(1, 2, 3)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." myCallableType»(1, 2, 3, 4)«; - // $TEST$ error "The parameter 'b' must be set here." + # $TEST$ error "The parameter 'b' must be set here." myCallableType»(1, c = 2)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." myCallableType»(b = 1, a = 2)«; - // $TEST$ error "The parameters 'a', 'b' must be set here." + # $TEST$ error "The parameters 'a', 'b' must be set here." myBlockLambda»()«; - // $TEST$ error "The parameter 'b' must be set here." + # $TEST$ error "The parameter 'b' must be set here." myBlockLambda»(1)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." myBlockLambda»(1, 2)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." myBlockLambda»(1, 2, 3)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." myBlockLambda»(1, 2, 3, 4)«; - // $TEST$ error "The parameter 'b' must be set here." + # $TEST$ error "The parameter 'b' must be set here." myBlockLambda»(1, c = 2)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." myBlockLambda»(b = 1, a = 2)«; - // $TEST$ error "The parameters 'a', 'b' must be set here." + # $TEST$ error "The parameters 'a', 'b' must be set here." myExpressionLambda»()«; - // $TEST$ error "The parameter 'b' must be set here." + # $TEST$ error "The parameter 'b' must be set here." myExpressionLambda»(1)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." myExpressionLambda»(1, 2)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." myExpressionLambda»(1, 2, 3)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." myExpressionLambda»(1, 2, 3, 4)«; - // $TEST$ error "The parameter 'b' must be set here." + # $TEST$ error "The parameter 'b' must be set here." myExpressionLambda»(1, c = 2)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." myExpressionLambda»(b = 1, a = 2)«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." myPipeline»()«; - // $TEST$ no error r"The parameters? .* must be set here\." + # $TEST$ no error r"The parameters? .* must be set here\." unresolved»()«; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/argument lists/must not have positional argument after named argument/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/argument lists/must not have positional argument after named argument/main.sdstest index 62634ca3..8f24375a 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/argument lists/must not have positional argument after named argument/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/argument lists/must not have positional argument after named argument/main.sdstest @@ -2,62 +2,62 @@ package tests.validation.other.argumentLists.mustNotHavePositionalArgumentAfterN annotation MyAnnotation(a: Int, b: Int = 0, c: Int = 0, d: Int = 0) -// $TEST$ no error "After the first named argument all arguments must be named." -// $TEST$ no error "After the first named argument all arguments must be named." -// $TEST$ error "After the first named argument all arguments must be named." -// $TEST$ no error "After the first named argument all arguments must be named." -// $TEST$ error "After the first named argument all arguments must be named." +# $TEST$ no error "After the first named argument all arguments must be named." +# $TEST$ no error "After the first named argument all arguments must be named." +# $TEST$ error "After the first named argument all arguments must be named." +# $TEST$ no error "After the first named argument all arguments must be named." +# $TEST$ error "After the first named argument all arguments must be named." @MyAnnotation(»0«, »a = 1«, »2«, »b = 3«, »4«) class MyClass1 -// $TEST$ no error "After the first named argument all arguments must be named." +# $TEST$ no error "After the first named argument all arguments must be named." @MyAnnotation(»0«) class MyClass2 -// $TEST$ no error "After the first named argument all arguments must be named." +# $TEST$ no error "After the first named argument all arguments must be named." @MyAnnotation(»a = 0«) class MyClass3 -// $TEST$ no error "After the first named argument all arguments must be named." -// $TEST$ no error "After the first named argument all arguments must be named." -// $TEST$ error "After the first named argument all arguments must be named." -// $TEST$ no error "After the first named argument all arguments must be named." +# $TEST$ no error "After the first named argument all arguments must be named." +# $TEST$ no error "After the first named argument all arguments must be named." +# $TEST$ error "After the first named argument all arguments must be named." +# $TEST$ no error "After the first named argument all arguments must be named." @UnresolvedAnnotation(»0«, »a = 1«, »2«, »b = 3«) class MyClass4 -// $TEST$ no error "After the first named argument all arguments must be named." +# $TEST$ no error "After the first named argument all arguments must be named." @UnresolvedAnnotation(»0«) class MyClass5 -// $TEST$ no error "After the first named argument all arguments must be named." +# $TEST$ no error "After the first named argument all arguments must be named." @UnresolvedAnnotation(»a = 0«) class MyClass3 fun f(a: Int, b: Int = 0, c: Int = 0, d: Int = 0) -pipeline myPipeline { - // $TEST$ no error "After the first named argument all arguments must be named." - // $TEST$ no error "After the first named argument all arguments must be named." - // $TEST$ error "After the first named argument all arguments must be named." - // $TEST$ no error "After the first named argument all arguments must be named." - // $TEST$ error "After the first named argument all arguments must be named." +function myFunction () { + # $TEST$ no error "After the first named argument all arguments must be named." + # $TEST$ no error "After the first named argument all arguments must be named." + # $TEST$ error "After the first named argument all arguments must be named." + # $TEST$ no error "After the first named argument all arguments must be named." + # $TEST$ error "After the first named argument all arguments must be named." f(»0«, »a = 1«, »2«, »b = 3«, »4«); - // $TEST$ no error "After the first named argument all arguments must be named." + # $TEST$ no error "After the first named argument all arguments must be named." f(»0«); - // $TEST$ no error "After the first named argument all arguments must be named." + # $TEST$ no error "After the first named argument all arguments must be named." f(»a = 0«); - // $TEST$ no error "After the first named argument all arguments must be named." - // $TEST$ no error "After the first named argument all arguments must be named." - // $TEST$ error "After the first named argument all arguments must be named." - // $TEST$ no error "After the first named argument all arguments must be named." + # $TEST$ no error "After the first named argument all arguments must be named." + # $TEST$ no error "After the first named argument all arguments must be named." + # $TEST$ error "After the first named argument all arguments must be named." + # $TEST$ no error "After the first named argument all arguments must be named." unresolvedCallable(»0«, »a = 1«, »2«, »b = 3«); - // $TEST$ no error "After the first named argument all arguments must be named." + # $TEST$ no error "After the first named argument all arguments must be named." unresolvedCallable(»0«); - // $TEST$ no error "After the first named argument all arguments must be named." + # $TEST$ no error "After the first named argument all arguments must be named." unresolvedCallable(»a = 0«); } diff --git a/packages/ttsl-lang/tests/resources/validation/other/argument lists/too many arguments/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/argument lists/too many arguments/main.sdstest index 3934b8a0..546a9431 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/argument lists/too many arguments/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/argument lists/too many arguments/main.sdstest @@ -19,22 +19,22 @@ fun myFunction2(a: Int, b: Int = 0) segment mySegment1(a: Int, b: Int) {} segment mySegment2(a: Int, b: Int = 0) {} -pipeline myPipeline {} +function myFunction () {} -// $TEST$ no error r"Expected .* arguments? but got \d*\." +# $TEST$ no error r"Expected .* arguments? but got \d*\." @MyAnnotation1»(1)« -// $TEST$ no error r"Expected .* arguments? but got \d*\." +# $TEST$ no error r"Expected .* arguments? but got \d*\." @MyAnnotation1»(1, 2)« -// $TEST$ error "Expected exactly 2 arguments but got 3." +# $TEST$ error "Expected exactly 2 arguments but got 3." @MyAnnotation1»(1, 2, 3)« -// $TEST$ no error r"Expected .* arguments? but got \d*\." +# $TEST$ no error r"Expected .* arguments? but got \d*\." @MyAnnotation2»()« -// $TEST$ no error r"Expected .* arguments? but got \d*\." +# $TEST$ no error r"Expected .* arguments? but got \d*\." @MyAnnotation2»(1)« -// $TEST$ no error r"Expected .* arguments? but got \d*\." +# $TEST$ no error r"Expected .* arguments? but got \d*\." @MyAnnotation2»(1, 2)« -// $TEST$ error "Expected between 1 and 2 arguments but got 3." +# $TEST$ error "Expected between 1 and 2 arguments but got 3." @MyAnnotation2»(1, 2, 3)« segment mySegment3( myCallableType1: (a: Int, b: Int) -> (), @@ -51,136 +51,136 @@ segment mySegment3( * We can never call an annotation directly and should avoid showing additional errors. */ - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." MyAnnotation1»(1)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." MyAnnotation1»(1, 2)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." MyAnnotation1»(1, 2, 3)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." MyAnnotation2»()«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." MyAnnotation2»(1)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." MyAnnotation2»(1, 2)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." MyAnnotation2»(1, 2, 3)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." MyClass1»(1)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." MyClass1»(1, 2)«; - // $TEST$ error "Expected exactly 2 arguments but got 3." + # $TEST$ error "Expected exactly 2 arguments but got 3." MyClass1»(1, 2, 3)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." MyClass2»()«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." MyClass2»(1)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." MyClass2»(1, 2)«; - // $TEST$ error "Expected between 1 and 2 arguments but got 3." + # $TEST$ error "Expected between 1 and 2 arguments but got 3." MyClass2»(1, 2, 3)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." MyEnum.MyEnumVariant1»(1)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." MyEnum.MyEnumVariant1»(1, 2)«; - // $TEST$ error "Expected exactly 2 arguments but got 3." + # $TEST$ error "Expected exactly 2 arguments but got 3." MyEnum.MyEnumVariant1»(1, 2, 3)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." MyEnum.MyEnumVariant2»()«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." MyEnum.MyEnumVariant2»(1)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." MyEnum.MyEnumVariant2»(1, 2)«; - // $TEST$ error "Expected between 1 and 2 arguments but got 3." + # $TEST$ error "Expected between 1 and 2 arguments but got 3." MyEnum.MyEnumVariant2»(1, 2, 3)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." myFunction1»(1)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." myFunction1»(1, 2)«; - // $TEST$ error "Expected exactly 2 arguments but got 3." + # $TEST$ error "Expected exactly 2 arguments but got 3." myFunction1»(1, 2, 3)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." myFunction2»()«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." myFunction2»(1)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." myFunction2»(1, 2)«; - // $TEST$ error "Expected between 1 and 2 arguments but got 3." + # $TEST$ error "Expected between 1 and 2 arguments but got 3." myFunction2»(1, 2, 3)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." mySegment1»(1)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." mySegment1»(1, 2)«; - // $TEST$ error "Expected exactly 2 arguments but got 3." + # $TEST$ error "Expected exactly 2 arguments but got 3." mySegment1»(1, 2, 3)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." mySegment2»()«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." mySegment2»(1)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." mySegment2»(1, 2)«; - // $TEST$ error "Expected between 1 and 2 arguments but got 3." + # $TEST$ error "Expected between 1 and 2 arguments but got 3." mySegment2»(1, 2, 3)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." myCallableType1»(1)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." myCallableType1»(1, 2)«; - // $TEST$ error "Expected exactly 2 arguments but got 3." + # $TEST$ error "Expected exactly 2 arguments but got 3." myCallableType1»(1, 2, 3)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." myCallableType2»()«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." myCallableType2»(1)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." myCallableType2»(1, 2)«; - // $TEST$ error "Expected between 1 and 2 arguments but got 3." + # $TEST$ error "Expected between 1 and 2 arguments but got 3." myCallableType2»(1, 2, 3)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." myBlockLambda1»(1)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." myBlockLambda1»(1, 2)«; - // $TEST$ error "Expected exactly 2 arguments but got 3." + # $TEST$ error "Expected exactly 2 arguments but got 3." myBlockLambda1»(1, 2, 3)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." myBlockLambda2»()«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." myBlockLambda2»(1)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." myBlockLambda2»(1, 2)«; - // $TEST$ error "Expected between 1 and 2 arguments but got 3." + # $TEST$ error "Expected between 1 and 2 arguments but got 3." myBlockLambda2»(1, 2, 3)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." myExpressionLambda1»(1)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." myExpressionLambda1»(1, 2)«; - // $TEST$ error "Expected exactly 2 arguments but got 3." + # $TEST$ error "Expected exactly 2 arguments but got 3." myExpressionLambda1»(1, 2, 3)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." myExpressionLambda2»()«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." myExpressionLambda2»(1)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." myExpressionLambda2»(1, 2)«; - // $TEST$ error "Expected between 1 and 2 arguments but got 3." + # $TEST$ error "Expected between 1 and 2 arguments but got 3." myExpressionLambda2»(1, 2, 3)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." myPipeline»(1)«; - // $TEST$ no error r"Expected .* arguments? but got \d*\." + # $TEST$ no error r"Expected .* arguments? but got \d*\." unresolved»(1)«; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/annotation calls/missing argument list/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/annotation calls/missing argument list/main.sdstest index 02d258d8..b8909fa2 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/annotation calls/missing argument list/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/annotation calls/missing argument list/main.sdstest @@ -12,24 +12,24 @@ annotation AnnotationWithoutRequiredParameters(a: Int = 0) @Repeatable annotation AnnotationWithRequiredParameters(a: Int) -// $TEST$ no error r"The annotation '\w*' has required parameters, so an argument list must be added\." +# $TEST$ no error r"The annotation '\w*' has required parameters, so an argument list must be added\." @»AnnotationWithoutParameterList« -// $TEST$ no error r"The annotation '\w*' has required parameters, so an argument list must be added\." +# $TEST$ no error r"The annotation '\w*' has required parameters, so an argument list must be added\." @»AnnotationWithoutParameterList()« -// $TEST$ no error r"The annotation '\w*' has required parameters, so an argument list must be added\." +# $TEST$ no error r"The annotation '\w*' has required parameters, so an argument list must be added\." @»AnnotationWithEmptyParameterList« -// $TEST$ no error r"The annotation '\w*' has required parameters, so an argument list must be added\." +# $TEST$ no error r"The annotation '\w*' has required parameters, so an argument list must be added\." @»AnnotationWithEmptyParameterList()« -// $TEST$ no error r"The annotation '\w*' has required parameters, so an argument list must be added\." +# $TEST$ no error r"The annotation '\w*' has required parameters, so an argument list must be added\." @»AnnotationWithoutRequiredParameters« -// $TEST$ no error r"The annotation '\w*' has required parameters, so an argument list must be added\." +# $TEST$ no error r"The annotation '\w*' has required parameters, so an argument list must be added\." @»AnnotationWithoutRequiredParameters()« -// $TEST$ error "The annotation 'AnnotationWithRequiredParameters' has required parameters, so an argument list must be added." +# $TEST$ error "The annotation 'AnnotationWithRequiredParameters' has required parameters, so an argument list must be added." @»AnnotationWithRequiredParameters« -// $TEST$ no error r"The annotation '\w*' has required parameters, so an argument list must be added\." +# $TEST$ no error r"The annotation '\w*' has required parameters, so an argument list must be added\." @»AnnotationWithRequiredParameters()« -// $TEST$ no error r"The annotation '\w*' has required parameters, so an argument list must be added\." +# $TEST$ no error r"The annotation '\w*' has required parameters, so an argument list must be added\." @»UnresolvedAnnotation« -// $TEST$ no error r"The annotation '\w*' has required parameters, so an argument list must be added\." +# $TEST$ no error r"The annotation '\w*' has required parameters, so an argument list must be added\." @»UnresolvedAnnotation()« class MyClass diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/annotation calls/must not be used on lambda parameters/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/annotation calls/must not be used on lambda parameters/main.sdstest index a589ae4b..6ff1bd57 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/annotation calls/must not be used on lambda parameters/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/annotation calls/must not be used on lambda parameters/main.sdstest @@ -2,15 +2,15 @@ package tests.validation.other.declarations.annotationCalls.mustNotBeUsedOnLambd annotation MyAnnotation -pipeline myPipeline { +function myFunction () { - // $TEST$ error "Lambda parameters must not be annotated." - // $TEST$ error "Lambda parameters must not be annotated." - // $TEST$ error "Lambda parameters must not be annotated." + # $TEST$ error "Lambda parameters must not be annotated." + # $TEST$ error "Lambda parameters must not be annotated." + # $TEST$ error "Lambda parameters must not be annotated." val f = (»@MyAnnotation« »@MyAnnotation« a: Int, »@MyAnnotation« b: Int = 3) {}; - // $TEST$ error "Lambda parameters must not be annotated." - // $TEST$ error "Lambda parameters must not be annotated." - // $TEST$ error "Lambda parameters must not be annotated." + # $TEST$ error "Lambda parameters must not be annotated." + # $TEST$ error "Lambda parameters must not be annotated." + # $TEST$ error "Lambda parameters must not be annotated." val g = (»@MyAnnotation« »@MyAnnotation« a: Int, »@MyAnnotation« b: Int = 3) -> 1; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/annotation calls/must not be used on parameters of callable types/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/annotation calls/must not be used on parameters of callable types/main.sdstest index 03d930b8..1e6911c6 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/annotation calls/must not be used on parameters of callable types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/annotation calls/must not be used on parameters of callable types/main.sdstest @@ -2,9 +2,9 @@ package tests.validation.other.declarations.annotationCalls.mustNotBeUsedOnParam annotation MyAnnotation -// $TEST$ error "Parameters of callable types must not be annotated." -// $TEST$ error "Parameters of callable types must not be annotated." -// $TEST$ error "Parameters of callable types must not be annotated." +# $TEST$ error "Parameters of callable types must not be annotated." +# $TEST$ error "Parameters of callable types must not be annotated." +# $TEST$ error "Parameters of callable types must not be annotated." segment mySegment( f: (»@MyAnnotation« »@MyAnnotation« a: Int, »@MyAnnotation« b: Int = 3) -> () ) {} diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/annotation calls/must not be used on results of callable types/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/annotation calls/must not be used on results of callable types/main.sdstest index 33657cbf..b1376d9b 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/annotation calls/must not be used on results of callable types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/annotation calls/must not be used on results of callable types/main.sdstest @@ -2,9 +2,9 @@ package tests.validation.other.declarations.annotationCalls.mustNotBeUsedOnResul annotation MyAnnotation -// $TEST$ error "Results of callable types must not be annotated." -// $TEST$ error "Results of callable types must not be annotated." -// $TEST$ error "Results of callable types must not be annotated." +# $TEST$ error "Results of callable types must not be annotated." +# $TEST$ error "Results of callable types must not be annotated." +# $TEST$ error "Results of callable types must not be annotated." segment mySegment( f: () -> (»@MyAnnotation« »@MyAnnotation« a: Int, »@MyAnnotation« b: Int) ) {} diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/arguments must match parameter bounds/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/arguments must match parameter bounds/main.sdstest index 7146498a..da597b5a 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/arguments must match parameter bounds/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/arguments must match parameter bounds/main.sdstest @@ -28,62 +28,62 @@ package tests.validation.other.declarations.parameterBounds.argumentsMustMatchPa } segment mySegment(p: Int) { - // $TEST$ error "The value of 'notConst' must be greater than 0 but was 0." + # $TEST$ error "The value of 'notConst' must be greater than 0 but was 0." f1(»0«); - // $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." f1(»""«); - // $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." f1(»p«); - // $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." f1(»unresolved«); - // $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." f1(unresolved = »1«); - // $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." f2(»1«); - // $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." f2(»""«); - // $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." f2(»p«); - // $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." f2(»unresolved«); - // $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." f2(unresolved = »1«); - // $TEST$ error "The value of 'bothBounds' must be greater than 0 but was 0." + # $TEST$ error "The value of 'bothBounds' must be greater than 0 but was 0." f3(»0«); - // $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." f3(»5«); - // $TEST$ error "The value of 'bothBounds' must be less than 10 but was 10." + # $TEST$ error "The value of 'bothBounds' must be less than 10 but was 10." f3(»10«); - // $TEST$ error "The value of 'lowerBound' must be greater than or equal to 0 but was -1." - // $TEST$ error "The value of 'indirectLowerBound' must be greater than or equal to -1 but was -2." + # $TEST$ error "The value of 'lowerBound' must be greater than or equal to 0 but was -1." + # $TEST$ error "The value of 'indirectLowerBound' must be greater than or equal to -1 but was -2." f4(»-1«, »-2«); - // $TEST$ error "The value of 'lowerBound' must be greater than or equal to 0 but was -1." - // $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ error "The value of 'lowerBound' must be greater than or equal to 0 but was -1." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." f4(»-1«, »-1«); - // $TEST$ no error r"The value of '.*' must be .* but was .*\." - // $TEST$ error "The value of 'indirectLowerBound' must be greater than or equal to 0 but was -1." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ error "The value of 'indirectLowerBound' must be greater than or equal to 0 but was -1." f4(»0«, »-1«); - // $TEST$ no error r"The value of '.*' must be .* but was .*\." - // $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." f4(»0«, »0«); - // $TEST$ error "The value of 'upperBound' must be less than or equal to 0 but was 1." - // $TEST$ error "The value of 'indirectUpperBound' must be less than or equal to 1 but was 2." + # $TEST$ error "The value of 'upperBound' must be less than or equal to 0 but was 1." + # $TEST$ error "The value of 'indirectUpperBound' must be less than or equal to 1 but was 2." f5(»1«, »2«); - // $TEST$ error "The value of 'upperBound' must be less than or equal to 0 but was 1." - // $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ error "The value of 'upperBound' must be less than or equal to 0 but was 1." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." f5(»1«, »1«); - // $TEST$ no error r"The value of '.*' must be .* but was .*\." - // $TEST$ error "The value of 'indirectUpperBound' must be less than or equal to 0 but was 1." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ error "The value of 'indirectUpperBound' must be less than or equal to 0 but was 1." f5(»0«, »1«); - // $TEST$ no error r"The value of '.*' must be .* but was .*\." - // $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." f5(»0«, »0«); - // $TEST$ error "The value of 'indirectUpperBound' must be less than or equal to -1 but was 0." + # $TEST$ error "The value of 'indirectUpperBound' must be less than or equal to -1 but was 0." f5(indirectUpperBound = »0«); - // $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." f5(indirectUpperBound = »-1«); } diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/default values must match parameter bounds/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/default values must match parameter bounds/main.sdstest index 54de5438..f40bb5ac 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/default values must match parameter bounds/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/default values must match parameter bounds/main.sdstest @@ -1,13 +1,13 @@ package tests.validation.other.declarations.parameterBounds.defaultValuesMustMatchParameterBounds @Pure fun f1( - // $TEST$ error "The value of 'notConst1' must be greater than 0 but was 0." + # $TEST$ error "The value of 'notConst1' must be greater than 0 but was 0." notConst1: Int = »0«, - // $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." notConst2: Int = »""«, - // $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." notConst3: Int = »p«, - // $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." notConst4: Int = »unresolved«, ) where { notConst1 > 0, @@ -17,22 +17,22 @@ package tests.validation.other.declarations.parameterBounds.defaultValuesMustMat } @Pure fun f2( - // $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." const unbounded1: Int = »1«, - // $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." const unbounded2: Int = »""«, - // $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." const unbounded3: Int = »p«, - // $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." const unbounded4: Int = »unresolved«, ) @Pure fun f3( - // $TEST$ error "The value of 'bothBounds1' must be greater than 0 but was 0." + # $TEST$ error "The value of 'bothBounds1' must be greater than 0 but was 0." const bothBounds1: Int = »0«, - // $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." const bothBounds2: Int= »5«, - // $TEST$ error "The value of 'bothBounds3' must be less than 10 but was 10." + # $TEST$ error "The value of 'bothBounds3' must be less than 10 but was 10." const bothBounds3: Int = »10«, ) where { bothBounds1 > 0, @@ -46,11 +46,11 @@ package tests.validation.other.declarations.parameterBounds.defaultValuesMustMat } @Pure fun f4( - // $TEST$ error "The value of 'lowerBound1' must be greater than or equal to 0 but was -1." + # $TEST$ error "The value of 'lowerBound1' must be greater than or equal to 0 but was -1." const lowerBound1: Int = »-1«, - // $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." const lowerBound2: Int = »0«, - // $TEST$ error "Cannot verify whether the parameter bounds are always met." + # $TEST$ error "Cannot verify whether the parameter bounds are always met." const indirectLowerBound: Int = »0«, ) where { lowerBound1 >= 0, @@ -59,11 +59,11 @@ package tests.validation.other.declarations.parameterBounds.defaultValuesMustMat } @Pure fun f5( - // $TEST$ error "The value of 'upperBound1' must be less than or equal to 0 but was 1." + # $TEST$ error "The value of 'upperBound1' must be less than or equal to 0 but was 1." const upperBound1: Int = »1«, - // $TEST$ no error r"The value of '.*' must be .* but was .*\." + # $TEST$ no error r"The value of '.*' must be .* but was .*\." const upperBound2: Int = »0«, - // $TEST$ error "Cannot verify whether the parameter bounds are always met." + # $TEST$ error "Cannot verify whether the parameter bounds are always met." const indirectUpperBound: Int = »0«, ) where { upperBound1 <= 0, diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/parameter must be const/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/parameter must be const/main.sdstest index 3c494101..bad49358 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/parameter must be const/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/parameter must be const/main.sdstest @@ -9,68 +9,68 @@ package tests.validation.other.declarations.parameterBounds.parameterMustBeConst const b2: Float, const b3: String ) where { - // $TEST$ error "Only constant parameters can have bounds." + # $TEST$ error "Only constant parameters can have bounds." »a1« < 0, - // $TEST$ error "Only constant parameters can have bounds." + # $TEST$ error "Only constant parameters can have bounds." »a1« <= 0, - // $TEST$ error "Only constant parameters can have bounds." + # $TEST$ error "Only constant parameters can have bounds." »a1« >= 0, - // $TEST$ error "Only constant parameters can have bounds." + # $TEST$ error "Only constant parameters can have bounds." »a1« > 0, - // $TEST$ error "Only constant parameters can have bounds." + # $TEST$ error "Only constant parameters can have bounds." »a2« < 0, - // $TEST$ error "Only constant parameters can have bounds." + # $TEST$ error "Only constant parameters can have bounds." »a2« <= 0, - // $TEST$ error "Only constant parameters can have bounds." + # $TEST$ error "Only constant parameters can have bounds." »a2« >= 0, - // $TEST$ error "Only constant parameters can have bounds." + # $TEST$ error "Only constant parameters can have bounds." »a2« > 0, - // $TEST$ no error "Only constant parameters can have bounds." + # $TEST$ no error "Only constant parameters can have bounds." »a3« < 0, - // $TEST$ no error "Only constant parameters can have bounds." + # $TEST$ no error "Only constant parameters can have bounds." »a3« <= 0, - // $TEST$ no error "Only constant parameters can have bounds." + # $TEST$ no error "Only constant parameters can have bounds." »a3« >= 0, - // $TEST$ no error "Only constant parameters can have bounds." + # $TEST$ no error "Only constant parameters can have bounds." »a3« > 0, - // $TEST$ no error "Only constant parameters can have bounds." + # $TEST$ no error "Only constant parameters can have bounds." »b1« < 0, - // $TEST$ no error "Only constant parameters can have bounds." + # $TEST$ no error "Only constant parameters can have bounds." »b1« <= 0, - // $TEST$ no error "Only constant parameters can have bounds." + # $TEST$ no error "Only constant parameters can have bounds." »b1« >= 0, - // $TEST$ no error "Only constant parameters can have bounds." + # $TEST$ no error "Only constant parameters can have bounds." »b1« > 0, - // $TEST$ no error "Only constant parameters can have bounds." + # $TEST$ no error "Only constant parameters can have bounds." »b2« < 0, - // $TEST$ no error "Only constant parameters can have bounds." + # $TEST$ no error "Only constant parameters can have bounds." »b2« <= 0, - // $TEST$ no error "Only constant parameters can have bounds." + # $TEST$ no error "Only constant parameters can have bounds." »b2« >= 0, - // $TEST$ no error "Only constant parameters can have bounds." + # $TEST$ no error "Only constant parameters can have bounds." »b2« > 0, - // $TEST$ no error "Only constant parameters can have bounds." + # $TEST$ no error "Only constant parameters can have bounds." »b3« < 0, - // $TEST$ no error "Only constant parameters can have bounds." + # $TEST$ no error "Only constant parameters can have bounds." »b3« <= 0, - // $TEST$ no error "Only constant parameters can have bounds." + # $TEST$ no error "Only constant parameters can have bounds." »b3« >= 0, - // $TEST$ no error "Only constant parameters can have bounds." + # $TEST$ no error "Only constant parameters can have bounds." »b3« > 0, - // $TEST$ no error "Only constant parameters can have bounds." + # $TEST$ no error "Only constant parameters can have bounds." »unresolved« < 0, - // $TEST$ no error "Only constant parameters can have bounds." + # $TEST$ no error "Only constant parameters can have bounds." »unresolved« <= 0, - // $TEST$ no error "Only constant parameters can have bounds." + # $TEST$ no error "Only constant parameters can have bounds." »unresolved« >= 0, - // $TEST$ no error "Only constant parameters can have bounds." + # $TEST$ no error "Only constant parameters can have bounds." »unresolved« > 0, } diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/parameter must be float or int/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/parameter must be float or int/main.sdstest index d3634119..2f370cd9 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/parameter must be float or int/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/parameter must be float or int/main.sdstest @@ -5,40 +5,40 @@ package tests.validation.other.declarations.parameterBounds.parameterMustBeFloat p2: Float, p3: String ) where { - // $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." + # $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." »p1« < 0, - // $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." + # $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." »p1« <= 0, - // $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." + # $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." »p1« >= 0, - // $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." + # $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." »p1« > 0, - // $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." + # $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." »p2« < 0, - // $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." + # $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." »p2« <= 0, - // $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." + # $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." »p2« >= 0, - // $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." + # $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." »p2« > 0, - // $TEST$ error "Only 'Float' and 'Int' parameters can have bounds." + # $TEST$ error "Only 'Float' and 'Int' parameters can have bounds." »p3« < 0, - // $TEST$ error "Only 'Float' and 'Int' parameters can have bounds." + # $TEST$ error "Only 'Float' and 'Int' parameters can have bounds." »p3« <= 0, - // $TEST$ error "Only 'Float' and 'Int' parameters can have bounds." + # $TEST$ error "Only 'Float' and 'Int' parameters can have bounds." »p3« >= 0, - // $TEST$ error "Only 'Float' and 'Int' parameters can have bounds." + # $TEST$ error "Only 'Float' and 'Int' parameters can have bounds." »p3« > 0, - // $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." + # $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." »unresolved« < 0, - // $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." + # $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." »unresolved« <= 0, - // $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." + # $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." »unresolved« >= 0, - // $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." + # $TEST$ no error "Only 'Float' and 'Int' parameters can have bounds." »unresolved« > 0, } diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/right operand must evaluate to float constant or int constant/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/right operand must evaluate to float constant or int constant/main.sdstest index 3121d3d8..3965dd39 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/right operand must evaluate to float constant or int constant/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter bounds/right operand must evaluate to float constant or int constant/main.sdstest @@ -9,86 +9,86 @@ package tests.validation.other.declarations.parameterBounds.rightOperandMustEval const b2: Float, const b3: String, ) where { - // $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." b1 < »0«, - // $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." b1 <= »0«, - // $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." b1 >= »0«, - // $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." b1 > »0«, - // $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." b1 < »0.5«, - // $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." b1 <= »0.5«, - // $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." b1 >= »0.5«, - // $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." b1 > »0.5«, - // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 < »""«, - // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 <= »""«, - // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 >= »""«, - // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 > »""«, - // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 < »a1«, - // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 <= »a1«, - // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 >= »a1«, - // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 > »a1«, - // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 < »a2«, - // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 <= »a2«, - // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 >= »a2«, - // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 > »a2«, - // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 < »a3«, - // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 <= »a3«, - // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 >= »a3«, - // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 > »a3«, - // $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." b1 < »b1«, - // $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." b1 <= »b1«, - // $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." b1 >= »b1«, - // $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." b1 > »b1«, - // $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." b1 < »b2«, - // $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." b1 <= »b2«, - // $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." b1 >= »b2«, - // $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ no error "The right operand of a parameter bound must evaluate to a float or int constant." b1 > »b2«, - // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 < »b3«, - // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 <= »b3«, - // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 >= »b3«, - // $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." + # $TEST$ error "The right operand of a parameter bound must evaluate to a float or int constant." b1 > »b3«, } diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter lists/must not have required after optional/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter lists/must not have required after optional/main.sdstest index 41c66761..f4a6f210 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter lists/must not have required after optional/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameter lists/must not have required after optional/main.sdstest @@ -1,118 +1,118 @@ package tests.validation.other.declarations.parameterLists.mustNotHaveRequiredAfterOptional -// $TEST$ no error "After the first optional parameter all parameters must be optional." -// $TEST$ no error "After the first optional parameter all parameters must be optional." -// $TEST$ error "After the first optional parameter all parameters must be optional." -// $TEST$ no error "After the first optional parameter all parameters must be optional." +# $TEST$ no error "After the first optional parameter all parameters must be optional." +# $TEST$ no error "After the first optional parameter all parameters must be optional." +# $TEST$ error "After the first optional parameter all parameters must be optional." +# $TEST$ no error "After the first optional parameter all parameters must be optional." annotation MyAnnotation1(»a«: Int, »b«: Int = 1, »c«: Int, »d«: Int = 2) -// $TEST$ no error "After the first optional parameter all parameters must be optional." -// $TEST$ no error "After the first optional parameter all parameters must be optional." +# $TEST$ no error "After the first optional parameter all parameters must be optional." +# $TEST$ no error "After the first optional parameter all parameters must be optional." annotation MyAnnotation2(»a«: Int, »b«: Int = 1) -// $TEST$ no error "After the first optional parameter all parameters must be optional." +# $TEST$ no error "After the first optional parameter all parameters must be optional." annotation MyAnnotation3(»a«: Int) -// $TEST$ no error "After the first optional parameter all parameters must be optional." -// $TEST$ no error "After the first optional parameter all parameters must be optional." -// $TEST$ error "After the first optional parameter all parameters must be optional." -// $TEST$ no error "After the first optional parameter all parameters must be optional." +# $TEST$ no error "After the first optional parameter all parameters must be optional." +# $TEST$ no error "After the first optional parameter all parameters must be optional." +# $TEST$ error "After the first optional parameter all parameters must be optional." +# $TEST$ no error "After the first optional parameter all parameters must be optional." class MyClass1(»a«: Int, »b«: Int = 1, »c«: Int, »d«: Int = 2) -// $TEST$ no error "After the first optional parameter all parameters must be optional." -// $TEST$ no error "After the first optional parameter all parameters must be optional." +# $TEST$ no error "After the first optional parameter all parameters must be optional." +# $TEST$ no error "After the first optional parameter all parameters must be optional." class MyClass2(»a«: Int, »b«: Int = 1) -// $TEST$ no error "After the first optional parameter all parameters must be optional." +# $TEST$ no error "After the first optional parameter all parameters must be optional." class MyClass3(»a«: Int) enum MyEnum { - // $TEST$ no error "After the first optional parameter all parameters must be optional." - // $TEST$ no error "After the first optional parameter all parameters must be optional." - // $TEST$ error "After the first optional parameter all parameters must be optional." - // $TEST$ no error "After the first optional parameter all parameters must be optional." + # $TEST$ no error "After the first optional parameter all parameters must be optional." + # $TEST$ no error "After the first optional parameter all parameters must be optional." + # $TEST$ error "After the first optional parameter all parameters must be optional." + # $TEST$ no error "After the first optional parameter all parameters must be optional." MyEnumVariant1(»a«: Int, »b«: Int = 1, »c«: Int, »d«: Int = 2) - // $TEST$ no error "After the first optional parameter all parameters must be optional." - // $TEST$ no error "After the first optional parameter all parameters must be optional." + # $TEST$ no error "After the first optional parameter all parameters must be optional." + # $TEST$ no error "After the first optional parameter all parameters must be optional." MyEnumVariant2(»a«: Int, »b«: Int = 1) - // $TEST$ no error "After the first optional parameter all parameters must be optional." + # $TEST$ no error "After the first optional parameter all parameters must be optional." MyEnumVariant3(»a«: Int) } -// $TEST$ no error "After the first optional parameter all parameters must be optional." -// $TEST$ no error "After the first optional parameter all parameters must be optional." -// $TEST$ error "After the first optional parameter all parameters must be optional." -// $TEST$ no error "After the first optional parameter all parameters must be optional." +# $TEST$ no error "After the first optional parameter all parameters must be optional." +# $TEST$ no error "After the first optional parameter all parameters must be optional." +# $TEST$ error "After the first optional parameter all parameters must be optional." +# $TEST$ no error "After the first optional parameter all parameters must be optional." fun myFunction1(»a«: Int, »b«: Int = 1, »c«: Int, »d«: Int = 2) -// $TEST$ no error "After the first optional parameter all parameters must be optional." -// $TEST$ no error "After the first optional parameter all parameters must be optional." +# $TEST$ no error "After the first optional parameter all parameters must be optional." +# $TEST$ no error "After the first optional parameter all parameters must be optional." fun myFunction2(»a«: Int, »b«: Int = 1) -// $TEST$ no error "After the first optional parameter all parameters must be optional." +# $TEST$ no error "After the first optional parameter all parameters must be optional." fun myFunction3(»a«: Int) -// $TEST$ no error "After the first optional parameter all parameters must be optional." -// $TEST$ no error "After the first optional parameter all parameters must be optional." -// $TEST$ error "After the first optional parameter all parameters must be optional." -// $TEST$ no error "After the first optional parameter all parameters must be optional." +# $TEST$ no error "After the first optional parameter all parameters must be optional." +# $TEST$ no error "After the first optional parameter all parameters must be optional." +# $TEST$ error "After the first optional parameter all parameters must be optional." +# $TEST$ no error "After the first optional parameter all parameters must be optional." segment mySegment1(»a«: Int, »b«: Int = 1, »c«: Int, »d«: Int = 2) {} -// $TEST$ no error "After the first optional parameter all parameters must be optional." -// $TEST$ no error "After the first optional parameter all parameters must be optional." +# $TEST$ no error "After the first optional parameter all parameters must be optional." +# $TEST$ no error "After the first optional parameter all parameters must be optional." segment mySegment2(»a«: Int, »b«: Int = 1) {} -// $TEST$ no error "After the first optional parameter all parameters must be optional." +# $TEST$ no error "After the first optional parameter all parameters must be optional." segment mySegment3(»a«: Int) {} -pipeline myPipeline { - // $TEST$ no error "After the first optional parameter all parameters must be optional." - // $TEST$ no error "After the first optional parameter all parameters must be optional." - // $TEST$ error "After the first optional parameter all parameters must be optional." - // $TEST$ no error "After the first optional parameter all parameters must be optional." +function myFunction () { + # $TEST$ no error "After the first optional parameter all parameters must be optional." + # $TEST$ no error "After the first optional parameter all parameters must be optional." + # $TEST$ error "After the first optional parameter all parameters must be optional." + # $TEST$ no error "After the first optional parameter all parameters must be optional." (»a«: Int, »b«: Int = 1, »c«: Int, »d«: Int = 2) {}; - // $TEST$ no error "After the first optional parameter all parameters must be optional." - // $TEST$ no error "After the first optional parameter all parameters must be optional." + # $TEST$ no error "After the first optional parameter all parameters must be optional." + # $TEST$ no error "After the first optional parameter all parameters must be optional." (»a«: Int, »b«: Int = 1) {}; - // $TEST$ no error "After the first optional parameter all parameters must be optional." + # $TEST$ no error "After the first optional parameter all parameters must be optional." (»a«: Int) {}; - // $TEST$ no error "After the first optional parameter all parameters must be optional." - // $TEST$ no error "After the first optional parameter all parameters must be optional." - // $TEST$ error "After the first optional parameter all parameters must be optional." - // $TEST$ no error "After the first optional parameter all parameters must be optional." + # $TEST$ no error "After the first optional parameter all parameters must be optional." + # $TEST$ no error "After the first optional parameter all parameters must be optional." + # $TEST$ error "After the first optional parameter all parameters must be optional." + # $TEST$ no error "After the first optional parameter all parameters must be optional." (»a«: Int, »b«: Int = 1, »c«: Int, »d«: Int = 2) -> 1; - // $TEST$ no error "After the first optional parameter all parameters must be optional." - // $TEST$ no error "After the first optional parameter all parameters must be optional." + # $TEST$ no error "After the first optional parameter all parameters must be optional." + # $TEST$ no error "After the first optional parameter all parameters must be optional." (»a«: Int, »b«: Int = 1) -> 1; - // $TEST$ no error "After the first optional parameter all parameters must be optional." + # $TEST$ no error "After the first optional parameter all parameters must be optional." (»a«: Int) -> 1; } fun myFunction4( - // $TEST$ no error "After the first optional parameter all parameters must be optional." - // $TEST$ no error "After the first optional parameter all parameters must be optional." - // $TEST$ error "After the first optional parameter all parameters must be optional." - // $TEST$ no error "After the first optional parameter all parameters must be optional." + # $TEST$ no error "After the first optional parameter all parameters must be optional." + # $TEST$ no error "After the first optional parameter all parameters must be optional." + # $TEST$ error "After the first optional parameter all parameters must be optional." + # $TEST$ no error "After the first optional parameter all parameters must be optional." p1: (»a«: Int, »b«: Int = 1, »c«: Int, »d«: Int = 2) -> (), - // $TEST$ no error "After the first optional parameter all parameters must be optional." - // $TEST$ no error "After the first optional parameter all parameters must be optional." + # $TEST$ no error "After the first optional parameter all parameters must be optional." + # $TEST$ no error "After the first optional parameter all parameters must be optional." p2: (»a«: Int, »b«: Int = 1) -> (), - // $TEST$ no error "After the first optional parameter all parameters must be optional." + # $TEST$ no error "After the first optional parameter all parameters must be optional." p3: (»a«: Int) -> (), ) diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/const modifier/error.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/const modifier/error.sdstest index 891b8653..6ab0d100 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/const modifier/error.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/const modifier/error.sdstest @@ -2,19 +2,19 @@ package tests.validation.other.declarations.parameters.illegalConstModifier fun f( g: ( - // $TEST$ error "The const modifier is not applicable to parameters of callable types." + # $TEST$ error "The const modifier is not applicable to parameters of callable types." »const« p1: Int ) -> () ) -pipeline myPipeline { +function myFunction () { ( - // $TEST$ error "The const modifier is not applicable to parameters of lambdas." + # $TEST$ error "The const modifier is not applicable to parameters of lambdas." »const« p1: Int ) {}; ( - // $TEST$ error "The const modifier is not applicable to parameters of lambdas." + # $TEST$ error "The const modifier is not applicable to parameters of lambdas." »const« p1: Int ) -> 1; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/const modifier/no error.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/const modifier/no error.sdstest index 1f0601ea..07c4f090 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/const modifier/no error.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/const modifier/no error.sdstest @@ -1,12 +1,12 @@ package tests.validation.other.declarations.parameters.illegalConstModifier -// $TEST$ no error "The const modifier is not applicable to parameters of callable types." +# $TEST$ no error "The const modifier is not applicable to parameters of callable types." fun f( g: (p2: Int) -> () ) -pipeline myPipeline { +function myFunction () { (p2: Int) {}; (p2: Int) -> 1; diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/const must only be used for specific types/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/const must only be used for specific types/main.sdstest index 7e1c3865..7aa07f4e 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/const must only be used for specific types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/const must only be used for specific types/main.sdstest @@ -1,24 +1,24 @@ package tests.validation.other.declarations.parameters.constMustOnlyBeUsedForSpecificTypes annotation MyAnnotation( - // $TEST$ error "An annotation parameter cannot have type 'Any'." + # $TEST$ error "An annotation parameter cannot have type 'Any'." anyParam: »Any«, - // $TEST$ no error r"An annotation parameter cannot have type '.*'\." + # $TEST$ no error r"An annotation parameter cannot have type '.*'\." intParam: »Int«, ) @Pure fun functionWithConstantParameters( - // $TEST$ error "A constant parameter cannot have type 'Any'." + # $TEST$ error "A constant parameter cannot have type 'Any'." const anyParam: »Any«, - // $TEST$ no error r"A constant parameter cannot have type '.*'\." + # $TEST$ no error r"A constant parameter cannot have type '.*'\." const intParam: »Int«, ) @Pure fun functionWithNormalParameters( - // $TEST$ no error r"A constant parameter cannot have type '.*'\." + # $TEST$ no error r"A constant parameter cannot have type '.*'\." anyParam: »Any«, - // $TEST$ no error r"A constant parameter cannot have type '.*'\." + # $TEST$ no error r"A constant parameter cannot have type '.*'\." intParam: »Int«, ) diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/const must only be used for specific types/no type.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/const must only be used for specific types/no type.sdstest index 9e604098..17033d15 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/const must only be used for specific types/no type.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/const must only be used for specific types/no type.sdstest @@ -1,6 +1,6 @@ package tests.validation.other.declarations.parameters.constMustOnlyBeUsedForSpecificTypes -// $TEST$ no error r"A.* parameter cannot have type '.*'\." +# $TEST$ no error r"A.* parameter cannot have type '.*'\." annotation AnnotationMissingType(p) diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/default value must be constant if parameter is constant/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/default value must be constant if parameter is constant/main.sdstest index 6307cf81..9fc58284 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/default value must be constant if parameter is constant/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/parameters/default value must be constant if parameter is constant/main.sdstest @@ -4,132 +4,132 @@ package tests.validation.other.parameters.defaultValueMustBeConstantIfParameterI fun f() -> value: Int annotation MyAnnotation( - // $TEST$ no error "Default values of annotation parameters must be constant." + # $TEST$ no error "Default values of annotation parameters must be constant." param1: Int = »1«, - // $TEST$ no error "Default values of annotation parameters must be constant." + # $TEST$ no error "Default values of annotation parameters must be constant." param2: Int = »-2«, - // $TEST$ error "Default values of annotation parameters must be constant." + # $TEST$ error "Default values of annotation parameters must be constant." param3: Int = »f()«, - // $TEST$ no error "Default values of annotation parameters must be constant." + # $TEST$ no error "Default values of annotation parameters must be constant." const param4: Int = »1«, - // $TEST$ no error "Default values of annotation parameters must be constant." + # $TEST$ no error "Default values of annotation parameters must be constant." const param5: Int = »-2«, - // $TEST$ error "Default values of annotation parameters must be constant." + # $TEST$ error "Default values of annotation parameters must be constant." const param6: Int = »f()« ) class MyClass( - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." param1: Int = »1«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." param2: Int = »-2«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." param3: Int = »f()«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." const param4: Int = »1«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." const param5: Int = »-2«, - // $TEST$ error "Default values of constant parameters must be constant." + # $TEST$ error "Default values of constant parameters must be constant." const param6: Int = »f()« ) enum MyEnum { MyEnumVariant( - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." param1: Int = »1«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." param2: Int = »-2«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." param3: Int = »f()«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." const param4: Int = »1«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." const param5: Int = »-2«, - // $TEST$ error "Default values of constant parameters must be constant." + # $TEST$ error "Default values of constant parameters must be constant." const param6: Int = »f()« ) } @Pure fun myFunction( - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." param1: Int = »1«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." param2: Int = »-2«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." param3: Int = »f()«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." const param4: Int = »1«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." const param5: Int = »-2«, - // $TEST$ error "Default values of constant parameters must be constant." + # $TEST$ error "Default values of constant parameters must be constant." const param6: Int = »f()« ) segment mySegment( callableType: ( - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." param1: Int = »1«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." param2: Int = »-2«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." param3: Int = »f()«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." const param4: Int = »1«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." const param5: Int = »-2«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." const param6: Int = »f()«, ) -> (), - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." param1: Int = »1«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." param2: Int = »-2«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." param3: Int = »f()«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." const param4: Int = »1«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." const param5: Int = »-2«, - // $TEST$ error "Default values of constant parameters must be constant." + # $TEST$ error "Default values of constant parameters must be constant." const param6: Int = »f()«, ) { ( - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." param1: Int = »1«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." param2: Int = »-2«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." param3: Int = »f()«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." const param4: Int = »1«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." const param5: Int = »-2«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." const param6: Int = »f()«, ) {}; ( - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." param1: Int = »1«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." param2: Int = »-2«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." param3: Int = »f()«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." const param4: Int = »1«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." const param5: Int = »-2«, - // $TEST$ no error "Default values of constant parameters must be constant." + # $TEST$ no error "Default values of constant parameters must be constant." const param6: Int = »f()«, ) -> 1; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/placeholders/alias/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/placeholders/alias/main.sdstest index fe1b0230..f9394b0d 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/placeholders/alias/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/placeholders/alias/main.sdstest @@ -14,39 +14,39 @@ enum MyEnum { fun myFunction() -pipeline myPipeline {} +function myFunction () {} schema MySchema {} segment mySegment1() {} segment mySegment2(myParameter: Int) { - // $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." + # $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." val »myPlaceholder« = 1; - // $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." + # $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." val »a« = MyAnnotation; - // $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." + # $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." val »b« = MyClass.myAttribute; - // $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." + # $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." val »c« = MyClass; - // $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." + # $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." val »d« = MyEnum; - // $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." + # $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." val »e« = MyEnum.MyEnumVariant; - // $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." + # $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." val »f« = myFunction; - // $TEST$ error "Aliases are not allowed to provide a cleaner graphical view." - // $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." + # $TEST$ error "Aliases are not allowed to provide a cleaner graphical view." + # $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." val »g1«, val »g2« = myParameter; - // $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." + # $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." val »h« = myPipeline; - // $TEST$ error "Aliases are not allowed to provide a cleaner graphical view." - // $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." + # $TEST$ error "Aliases are not allowed to provide a cleaner graphical view." + # $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." val »i1«, val »i2« = myPlaceholder; - // $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." + # $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." val »j« = MySchema; - // $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." + # $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." val »k« = mySegment1; - // $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." + # $TEST$ no error "Aliases are not allowed to provide a cleaner graphical view." val »l« = unresolved; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/placeholders/unused/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/placeholders/unused/main.sdstest index 1527cb7a..74171687 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/placeholders/unused/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/placeholders/unused/main.sdstest @@ -3,42 +3,42 @@ package tests.validation.other.declarations.placeholders.unused fun f() -> (r1: Int, r2: Int) segment mySegment() { - // $TEST$ warning "This placeholder is unused and can be removed." + # $TEST$ warning "This placeholder is unused and can be removed." val »unused« = 1; - // $TEST$ no warning "This placeholder is unused and can be removed." + # $TEST$ no warning "This placeholder is unused and can be removed." val »used« = 1; used; - // $TEST$ no warning "This placeholder is unused and can be removed." - // $TEST$ no warning "This placeholder is unused and can be removed." + # $TEST$ no warning "This placeholder is unused and can be removed." + # $TEST$ no warning "This placeholder is unused and can be removed." val »last1«, val »last2« = f(); } -pipeline myPipeline1 { - // $TEST$ warning "This placeholder is unused and can be removed." +function myFunction1 { + # $TEST$ warning "This placeholder is unused and can be removed." val »unused« = 1; - // $TEST$ no warning "This placeholder is unused and can be removed." + # $TEST$ no warning "This placeholder is unused and can be removed." val »used« = 1; used; - // $TEST$ no warning "This placeholder is unused and can be removed." - // $TEST$ no warning "This placeholder is unused and can be removed." + # $TEST$ no warning "This placeholder is unused and can be removed." + # $TEST$ no warning "This placeholder is unused and can be removed." val »last1«, val »last2« = f(); } -pipeline myPipeline2 { +function myFunction2 { () { - // $TEST$ warning "This placeholder is unused and can be removed." + # $TEST$ warning "This placeholder is unused and can be removed." val »unused« = 1; - // $TEST$ no warning "This placeholder is unused and can be removed." + # $TEST$ no warning "This placeholder is unused and can be removed." val »used« = 1; used; - // $TEST$ no warning "This placeholder is unused and can be removed." - // $TEST$ no warning "This placeholder is unused and can be removed." + # $TEST$ no warning "This placeholder is unused and can be removed." + # $TEST$ no warning "This placeholder is unused and can be removed." val »last1«, val »last2« = f(); }; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/segments/duplicate yield/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/segments/duplicate yield/main.sdstest index f6677b70..358a0988 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/segments/duplicate yield/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/segments/duplicate yield/main.sdstest @@ -1,20 +1,20 @@ package tests.validation.other.declarations.segments.duplicateYield segment mySegment() -> (a: Int, b: Int, c: Int) { - // $TEST$ no error r"The result '\w*' has been assigned already\." + # $TEST$ no error r"The result '\w*' has been assigned already\." yield »a« = 1; - // $TEST$ no error r"The result '\w*' has been assigned already\." + # $TEST$ no error r"The result '\w*' has been assigned already\." yield »b« = 1; - // $TEST$ error "The result 'b' has been assigned already." + # $TEST$ error "The result 'b' has been assigned already." yield »b« = 1; - // $TEST$ no error r"The result '\w*' has been assigned already\." - // $TEST$ error "The result 'c' has been assigned already." + # $TEST$ no error r"The result '\w*' has been assigned already\." + # $TEST$ error "The result 'c' has been assigned already." yield »c«, yield »c« = 1; - // $TEST$ no error r"The result '\w*' has been assigned already\." + # $TEST$ no error r"The result '\w*' has been assigned already\." yield »unresolved« = 1; - // $TEST$ no error r"The result '\w*' has been assigned already\." + # $TEST$ no error r"The result '\w*' has been assigned already\." yield »unresolved« = 1; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/segments/unassigned result/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/segments/unassigned result/main.sdstest index f4ef6680..05a336a7 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/segments/unassigned result/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/segments/unassigned result/main.sdstest @@ -1,10 +1,10 @@ package tests.validation.other.declarations.segments.unassignedResult -// $TEST$ no error "Nothing is assigned to this result." -// $TEST$ no error "Nothing is assigned to this result." -// $TEST$ no error "Nothing is assigned to this result." -// $TEST$ no error "Nothing is assigned to this result." -// $TEST$ error "Nothing is assigned to this result." +# $TEST$ no error "Nothing is assigned to this result." +# $TEST$ no error "Nothing is assigned to this result." +# $TEST$ no error "Nothing is assigned to this result." +# $TEST$ no error "Nothing is assigned to this result." +# $TEST$ error "Nothing is assigned to this result." segment mySegment() -> (»a«: Int, »b«: Int, »c«: Int, »d«: Int, »e«: Int) { yield b = 1; yield a = 1; @@ -12,6 +12,6 @@ segment mySegment() -> (»a«: Int, »b«: Int, »c«: Int, »d«: Int, »e«: I yield c = 1; yield c = 1; - // While nothing is assigned to d, the programmer still states their intention to do so. We already show another error for this. + # While nothing is assigned to d, the programmer still states their intention to do so. We already show another error for this. _, yield d = 1; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/segments/unused parameter/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/segments/unused parameter/main.sdstest index aa0cdfdb..5a35cb31 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/segments/unused parameter/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/segments/unused parameter/main.sdstest @@ -1,11 +1,11 @@ package tests.validation.other.declarations.segments.unusedParameters segment mySegment( - // $TEST$ warning "This parameter is unused and can be removed." + # $TEST$ warning "This parameter is unused and can be removed." »unused«: Int, - // $TEST$ warning "This parameter is unused and can be removed." + # $TEST$ warning "This parameter is unused and can be removed." »onlyHasBound«: Int, - // $TEST$ no warning "This parameter is unused and can be removed." + # $TEST$ no warning "This parameter is unused and can be removed." »used«: Int ) where { onlyHasBound < 0 @@ -17,37 +17,37 @@ segment mySegment( */ ( - // $TEST$ no warning "This parameter is unused and can be removed." + # $TEST$ no warning "This parameter is unused and can be removed." »unused«: Int, - // $TEST$ no warning "This parameter is unused and can be removed." + # $TEST$ no warning "This parameter is unused and can be removed." »used«: Int ) { used; }; ( - // $TEST$ no warning "This parameter is unused and can be removed." + # $TEST$ no warning "This parameter is unused and can be removed." »unused«: Int, - // $TEST$ no warning "This parameter is unused and can be removed." + # $TEST$ no warning "This parameter is unused and can be removed." »used«: Int ) -> used; } -// $TEST$ no warning "This parameter is unused and can be removed." +# $TEST$ no warning "This parameter is unused and can be removed." annotation MyAnnotation(»unused«: Int) -// $TEST$ no warning "This parameter is unused and can be removed." +# $TEST$ no warning "This parameter is unused and can be removed." class MyClass(»unused«: Int) enum MyEnum { - // $TEST$ no warning "This parameter is unused and can be removed." + # $TEST$ no warning "This parameter is unused and can be removed." MyEnumVariant(»unused«: Int) } fun myFunction( - // $TEST$ no warning "This parameter is unused and can be removed." + # $TEST$ no warning "This parameter is unused and can be removed." »unused«: Int, - // $TEST$ no warning "This parameter is unused and can be removed." + # $TEST$ no warning "This parameter is unused and can be removed." myCallableType: (»unused«: Int) -> (), ) diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/segments/unused/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/segments/unused/main.sdstest index 4cf658e6..1d3c3280 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/segments/unused/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/segments/unused/main.sdstest @@ -1,23 +1,23 @@ package tests.validation.other.declarations.segments.unused -// $TEST$ warning "This segment is unused and can be removed." +# $TEST$ warning "This segment is unused and can be removed." private segment »myUnusedPrivateSegment«() {} -// $TEST$ no warning "This segment is unused and can be removed." +# $TEST$ no warning "This segment is unused and can be removed." private segment »myUsedPrivateSegment«() {} -// $TEST$ warning "This segment is unused and can be removed." +# $TEST$ warning "This segment is unused and can be removed." internal segment »myUnusedInternalSegment«() {} -// $TEST$ no warning "This segment is unused and can be removed." +# $TEST$ no warning "This segment is unused and can be removed." internal segment »myUsedInternalSegment«() {} -// $TEST$ no warning "This segment is unused and can be removed." +# $TEST$ no warning "This segment is unused and can be removed." segment »myUnusedPublicSegment«() {} -// $TEST$ no warning "This segment is unused and can be removed." +# $TEST$ no warning "This segment is unused and can be removed." segment »myUsedPublicSegment«() {} -pipeline myPipeline1 { +function myFunction1 { myUsedPrivateSegment(); } diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/segments/unused/same package.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/segments/unused/same package.sdstest index a2928905..ce42b150 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/segments/unused/same package.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/segments/unused/same package.sdstest @@ -1,6 +1,6 @@ package tests.validation.other.declarations.segments.unused -pipeline myPipeline2 { +function myFunction2 { myUsedInternalSegment(); myUsedPublicSegment(); } diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameter lists/must not have required after optional/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameter lists/must not have required after optional/main.sdstest index f759ad68..72fc5850 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameter lists/must not have required after optional/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameter lists/must not have required after optional/main.sdstest @@ -1,28 +1,28 @@ package tests.validation.other.declarations.typeParameterLists.mustNotHaveRequiredAfterOptional -// $TEST$ no error "After the first optional type parameter all type parameters must be optional." -// $TEST$ no error "After the first optional type parameter all type parameters must be optional." -// $TEST$ error "After the first optional type parameter all type parameters must be optional." -// $TEST$ no error "After the first optional type parameter all type parameters must be optional." +# $TEST$ no error "After the first optional type parameter all type parameters must be optional." +# $TEST$ no error "After the first optional type parameter all type parameters must be optional." +# $TEST$ error "After the first optional type parameter all type parameters must be optional." +# $TEST$ no error "After the first optional type parameter all type parameters must be optional." class MyClass1<»A«, »B« = Int, »C«, »D« = String> -// $TEST$ no error "After the first optional type parameter all type parameters must be optional." -// $TEST$ no error "After the first optional type parameter all type parameters must be optional." +# $TEST$ no error "After the first optional type parameter all type parameters must be optional." +# $TEST$ no error "After the first optional type parameter all type parameters must be optional." class MyClass2<»A«, »B« = Int> -// $TEST$ no error "After the first optional type parameter all type parameters must be optional." +# $TEST$ no error "After the first optional type parameter all type parameters must be optional." class MyClass3<»A«> -// $TEST$ no error "After the first optional type parameter all type parameters must be optional." -// $TEST$ no error "After the first optional type parameter all type parameters must be optional." -// $TEST$ error "After the first optional type parameter all type parameters must be optional." -// $TEST$ no error "After the first optional type parameter all type parameters must be optional." +# $TEST$ no error "After the first optional type parameter all type parameters must be optional." +# $TEST$ no error "After the first optional type parameter all type parameters must be optional." +# $TEST$ error "After the first optional type parameter all type parameters must be optional." +# $TEST$ no error "After the first optional type parameter all type parameters must be optional." fun myFunction1<»A«, »B« = Int, »C«, »D« = String>() -// $TEST$ no error "After the first optional type parameter all type parameters must be optional." -// $TEST$ no error "After the first optional type parameter all type parameters must be optional." +# $TEST$ no error "After the first optional type parameter all type parameters must be optional." +# $TEST$ no error "After the first optional type parameter all type parameters must be optional." fun myFunction2<»A«, »B« = Int>() -// $TEST$ no error "After the first optional type parameter all type parameters must be optional." +# $TEST$ no error "After the first optional type parameter all type parameters must be optional." fun myFunction3<»A«>() diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/insufficient context/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/insufficient context/main.sdstest index be989fcd..d41dacbc 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/insufficient context/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/insufficient context/main.sdstest @@ -1,41 +1,41 @@ package tests.validation.other.declarations.typeParameters.insufficientContext -// $TEST$ no error "Insufficient context to infer this type parameter." +# $TEST$ no error "Insufficient context to infer this type parameter." class MyClass1<»T«> -// $TEST$ error "Insufficient context to infer this type parameter." +# $TEST$ error "Insufficient context to infer this type parameter." class MyClass2<»T« sub Int>() -// $TEST$ error "Insufficient context to infer this type parameter." +# $TEST$ error "Insufficient context to infer this type parameter." class MyClass3<»T«>() { attr myAttr: T } -// $TEST$ no error "Insufficient context to infer this type parameter." +# $TEST$ no error "Insufficient context to infer this type parameter." class MyClass4<»T« sub Int>(param: T) -// $TEST$ no error "Insufficient context to infer this type parameter." +# $TEST$ no error "Insufficient context to infer this type parameter." class MyClass5<»T«>(param: MyClass4?) -// $TEST$ no error "Insufficient context to infer this type parameter." +# $TEST$ no error "Insufficient context to infer this type parameter." class MyClass6<»T«>(param: () -> (r: T)) -// $TEST$ error "Insufficient context to infer this type parameter." +# $TEST$ error "Insufficient context to infer this type parameter." class MyClass7<»T«>(param: (p: T) -> ()) -// $TEST$ error "Insufficient context to infer this type parameter." +# $TEST$ error "Insufficient context to infer this type parameter." class MyClass8<»T«>(param: () -> (r: (p: T) -> ())) -// $TEST$ error "Insufficient context to infer this type parameter." +# $TEST$ error "Insufficient context to infer this type parameter." class MyClass9<»T«>(param: union) -// $TEST$ error "Insufficient context to infer this type parameter." +# $TEST$ error "Insufficient context to infer this type parameter." class MyClass10<»T«>(param: union) -// $TEST$ error "Insufficient context to infer this type parameter." +# $TEST$ error "Insufficient context to infer this type parameter." fun myFunction1<»T« sub Int>() -// $TEST$ no error "Insufficient context to infer this type parameter." +# $TEST$ no error "Insufficient context to infer this type parameter." fun myFunction2<»T«>(param: T) -// $TEST$ no error "Insufficient context to infer this type parameter." +# $TEST$ no error "Insufficient context to infer this type parameter." fun myFunction3<»T«>(param: MyClass4?) -// $TEST$ no error "Insufficient context to infer this type parameter." +# $TEST$ no error "Insufficient context to infer this type parameter." fun myFunction4<»T«>(param: () -> (r: T)) -// $TEST$ error "Insufficient context to infer this type parameter." +# $TEST$ error "Insufficient context to infer this type parameter." fun myFunction5<»T«>(param: (p: T) -> ()) -// $TEST$ error "Insufficient context to infer this type parameter." +# $TEST$ error "Insufficient context to infer this type parameter." fun myFunction6<»T«>(param: () -> (r: (p: T) -> ())) -// $TEST$ error "Insufficient context to infer this type parameter." +# $TEST$ error "Insufficient context to infer this type parameter." fun myFunction7<»T«>(param: union) -// $TEST$ error "Insufficient context to infer this type parameter." +# $TEST$ error "Insufficient context to infer this type parameter." fun myFunction8<»T«>(param: union) diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/upper bound must be named type/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/upper bound must be named type/main.sdstest index 5eeba74b..c75c00df 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/upper bound must be named type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/upper bound must be named type/main.sdstest @@ -5,27 +5,27 @@ enum E { V } -// $TEST$ error "The upper bound of a type parameter must be a named type." +# $TEST$ error "The upper bound of a type parameter must be a named type." class MyClass1 ()«> -// $TEST$ error "The upper bound of a type parameter must be a named type." +# $TEST$ error "The upper bound of a type parameter must be a named type." class MyClass2«> -// $TEST$ no error "The upper bound of a type parameter must be a named type." +# $TEST$ no error "The upper bound of a type parameter must be a named type." class MyClass3 -// $TEST$ no error "The upper bound of a type parameter must be a named type." +# $TEST$ no error "The upper bound of a type parameter must be a named type." class MyClass4 -// $TEST$ no error "The upper bound of a type parameter must be a named type." +# $TEST$ no error "The upper bound of a type parameter must be a named type." class MyClass5 -// $TEST$ no error "The upper bound of a type parameter must be a named type." -// $TEST$ no error "The upper bound of a type parameter must be a named type." +# $TEST$ no error "The upper bound of a type parameter must be a named type." +# $TEST$ no error "The upper bound of a type parameter must be a named type." class MyClass6 -// $TEST$ error "The upper bound of a type parameter must be a named type." +# $TEST$ error "The upper bound of a type parameter must be a named type." class MyClass7«> -// $TEST$ no error "The upper bound of a type parameter must be a named type." +# $TEST$ no error "The upper bound of a type parameter must be a named type." class MyClass8 diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of class type parameters/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of class type parameters/main.sdstest index 6a5b11d7..929598df 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of class type parameters/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of class type parameters/main.sdstest @@ -1,44 +1,44 @@ package tests.validation.other.declarations.typeParameters.usageOfClassTypeParameters -// $TEST$ no error "This type parameter of a containing class cannot be used here." -// $TEST$ no error "This type parameter of a containing class cannot be used here." +# $TEST$ no error "This type parameter of a containing class cannot be used here." +# $TEST$ no error "This type parameter of a containing class cannot be used here." class MyClass(p: »T«) sub »T« { - // $TEST$ no error "This type parameter of a containing class cannot be used here." + # $TEST$ no error "This type parameter of a containing class cannot be used here." attr a: »T« - // $TEST$ error "This type parameter of a containing class cannot be used here." + # $TEST$ error "This type parameter of a containing class cannot be used here." static attr a: »T« - // $TEST$ no error "This type parameter of a containing class cannot be used here." - // $TEST$ no error "This type parameter of a containing class cannot be used here." - // $TEST$ no error "This type parameter of a containing class cannot be used here." - // $TEST$ no error "This type parameter of a containing class cannot be used here." + # $TEST$ no error "This type parameter of a containing class cannot be used here." + # $TEST$ no error "This type parameter of a containing class cannot be used here." + # $TEST$ no error "This type parameter of a containing class cannot be used here." + # $TEST$ no error "This type parameter of a containing class cannot be used here." fun f(p1: »T«, p2: »S«) -> (r1: »T«, r2: »S«) - // $TEST$ error "This type parameter of a containing class cannot be used here." - // $TEST$ no error "This type parameter of a containing class cannot be used here." - // $TEST$ error "This type parameter of a containing class cannot be used here." - // $TEST$ no error "This type parameter of a containing class cannot be used here." + # $TEST$ error "This type parameter of a containing class cannot be used here." + # $TEST$ no error "This type parameter of a containing class cannot be used here." + # $TEST$ error "This type parameter of a containing class cannot be used here." + # $TEST$ no error "This type parameter of a containing class cannot be used here." static fun f(p1: »T«, p2: »S«) -> (r1: »T«, r2: »S«) - // $TEST$ error "This type parameter of a containing class cannot be used here." - // $TEST$ no error "This type parameter of a containing class cannot be used here." + # $TEST$ error "This type parameter of a containing class cannot be used here." + # $TEST$ no error "This type parameter of a containing class cannot be used here." class MyInnerClass(p1: »T«, p2: »S«) { - // $TEST$ error "This type parameter of a containing class cannot be used here." + # $TEST$ error "This type parameter of a containing class cannot be used here." attr a: »T« - // $TEST$ error "This type parameter of a containing class cannot be used here." + # $TEST$ error "This type parameter of a containing class cannot be used here." static attr a: »T« - // $TEST$ error "This type parameter of a containing class cannot be used here." + # $TEST$ error "This type parameter of a containing class cannot be used here." fun f(p: »T«) - // $TEST$ error "This type parameter of a containing class cannot be used here." + # $TEST$ error "This type parameter of a containing class cannot be used here." static fun f(p: »T«) } enum MyInnerEnum { - // $TEST$ error "This type parameter of a containing class cannot be used here." + # $TEST$ error "This type parameter of a containing class cannot be used here." MyEnumVariant(p1: »T«) } } diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of variant type parameter/contravariant type parameter.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of variant type parameter/contravariant type parameter.sdstest index f75cda4f..daa47e14 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of variant type parameter/contravariant type parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of variant type parameter/contravariant type parameter.sdstest @@ -1,78 +1,78 @@ package tests.validation.other.declarations.typeParameters.usageOfVariantTypeParameters -// $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." +# $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." class MyClass1(p1: »Contravariant«) -// $TEST$ error "A contravariant type parameter cannot be used in covariant position." -// $TEST$ error "A contravariant type parameter cannot be used in invariant position." -// $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." +# $TEST$ error "A contravariant type parameter cannot be used in covariant position." +# $TEST$ error "A contravariant type parameter cannot be used in invariant position." +# $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." sub Producer<»Contravariant«>, Middleware<»Contravariant«>, Consumer<»Contravariant«> { - // $TEST$ error "A contravariant type parameter cannot be used in covariant position." + # $TEST$ error "A contravariant type parameter cannot be used in covariant position." attr a1: »Contravariant« - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." - // $TEST$ error "A contravariant type parameter cannot be used in covariant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ error "A contravariant type parameter cannot be used in covariant position." attr a2: (a1: »Contravariant«) -> (r1: »Contravariant«) - // $TEST$ error "A contravariant type parameter cannot be used in covariant position." + # $TEST$ error "A contravariant type parameter cannot be used in covariant position." attr a3: Producer<»Contravariant«> - // $TEST$ error "A contravariant type parameter cannot be used in invariant position." + # $TEST$ error "A contravariant type parameter cannot be used in invariant position." attr a4: Middleware<»Contravariant«> - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." attr a5: Consumer<»Contravariant«> - // $TEST$ error "A contravariant type parameter cannot be used in covariant position." + # $TEST$ error "A contravariant type parameter cannot be used in covariant position." attr a6: Producer> - // $TEST$ error "A contravariant type parameter cannot be used in invariant position." + # $TEST$ error "A contravariant type parameter cannot be used in invariant position." attr a7: Middleware> - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." attr a8: Consumer> fun f( - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." p1: »Contravariant«, - // $TEST$ error "A contravariant type parameter cannot be used in covariant position." - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ error "A contravariant type parameter cannot be used in covariant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." p2: (a1: »Contravariant«) -> (r1: »Contravariant«), - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." p3: Producer<»Contravariant«>, - // $TEST$ error "A contravariant type parameter cannot be used in invariant position." + # $TEST$ error "A contravariant type parameter cannot be used in invariant position." p4: Middleware<»Contravariant«>, - // $TEST$ error "A contravariant type parameter cannot be used in covariant position." + # $TEST$ error "A contravariant type parameter cannot be used in covariant position." p5: Consumer<»Contravariant«>, ) -> ( - // $TEST$ error "A contravariant type parameter cannot be used in covariant position." + # $TEST$ error "A contravariant type parameter cannot be used in covariant position." r1: »Contravariant«, - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." - // $TEST$ error "A contravariant type parameter cannot be used in covariant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ error "A contravariant type parameter cannot be used in covariant position." r2: (a1: »Contravariant«) -> (r1: »Contravariant«), - // $TEST$ error "A contravariant type parameter cannot be used in covariant position." + # $TEST$ error "A contravariant type parameter cannot be used in covariant position." r3: Producer<»Contravariant«>, - // $TEST$ error "A contravariant type parameter cannot be used in invariant position." + # $TEST$ error "A contravariant type parameter cannot be used in invariant position." r4: Middleware<»Contravariant«>, - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." r5: Consumer<»Contravariant«>, ) } fun f1( - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." p1: »Contravariant«, - // $TEST$ error "A contravariant type parameter cannot be used in covariant position." - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ error "A contravariant type parameter cannot be used in covariant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." p2: (a1: »Contravariant«) -> (r1: »Contravariant«), - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." p3: Producer<»Contravariant«>, - // $TEST$ error "A contravariant type parameter cannot be used in invariant position." + # $TEST$ error "A contravariant type parameter cannot be used in invariant position." p4: Middleware<»Contravariant«>, - // $TEST$ error "A contravariant type parameter cannot be used in covariant position." + # $TEST$ error "A contravariant type parameter cannot be used in covariant position." p5: Consumer<»Contravariant«>, ) -> ( - // $TEST$ error "A contravariant type parameter cannot be used in covariant position." + # $TEST$ error "A contravariant type parameter cannot be used in covariant position." r1: »Contravariant«, - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." - // $TEST$ error "A contravariant type parameter cannot be used in covariant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ error "A contravariant type parameter cannot be used in covariant position." r2: (a1: »Contravariant«) -> (r1: »Contravariant«), - // $TEST$ error "A contravariant type parameter cannot be used in covariant position." + # $TEST$ error "A contravariant type parameter cannot be used in covariant position." r3: Producer<»Contravariant«>, - // $TEST$ error "A contravariant type parameter cannot be used in invariant position." + # $TEST$ error "A contravariant type parameter cannot be used in invariant position." r4: Middleware<»Contravariant«>, - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." r5: Consumer<»Contravariant«>, ) diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of variant type parameter/covariant type parameter.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of variant type parameter/covariant type parameter.sdstest index a8c2a196..0521acf5 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of variant type parameter/covariant type parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of variant type parameter/covariant type parameter.sdstest @@ -1,78 +1,78 @@ package tests.validation.other.declarations.typeParameters.usageOfVariantTypeParameters -// $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." +# $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." class MyClass2(p1: »Covariant«) -// $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." -// $TEST$ error "A covariant type parameter cannot be used in invariant position." -// $TEST$ error "A covariant type parameter cannot be used in contravariant position." +# $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." +# $TEST$ error "A covariant type parameter cannot be used in invariant position." +# $TEST$ error "A covariant type parameter cannot be used in contravariant position." sub Producer<»Covariant«>, Middleware<»Covariant«>, Consumer<»Covariant«> { - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." attr a1: »Covariant« - // $TEST$ error "A covariant type parameter cannot be used in contravariant position." - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ error "A covariant type parameter cannot be used in contravariant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." attr a2: (a1: »Covariant«) -> (r1: »Covariant«) - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." attr a3: Producer<»Covariant«> - // $TEST$ error "A covariant type parameter cannot be used in invariant position." + # $TEST$ error "A covariant type parameter cannot be used in invariant position." attr a4: Middleware<»Covariant«> - // $TEST$ error "A covariant type parameter cannot be used in contravariant position." + # $TEST$ error "A covariant type parameter cannot be used in contravariant position." attr a5: Consumer<»Covariant«> - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." attr a6: Producer> - // $TEST$ error "A covariant type parameter cannot be used in invariant position." + # $TEST$ error "A covariant type parameter cannot be used in invariant position." attr a7: Middleware> - // $TEST$ error "A covariant type parameter cannot be used in contravariant position." + # $TEST$ error "A covariant type parameter cannot be used in contravariant position." attr a8: Consumer> fun f( - // $TEST$ error "A covariant type parameter cannot be used in contravariant position." + # $TEST$ error "A covariant type parameter cannot be used in contravariant position." p1: »Covariant«, - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." - // $TEST$ error "A covariant type parameter cannot be used in contravariant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ error "A covariant type parameter cannot be used in contravariant position." p2: (a1: »Covariant«) -> (r1: »Covariant«), - // $TEST$ error "A covariant type parameter cannot be used in contravariant position." + # $TEST$ error "A covariant type parameter cannot be used in contravariant position." p3: Producer<»Covariant«>, - // $TEST$ error "A covariant type parameter cannot be used in invariant position." + # $TEST$ error "A covariant type parameter cannot be used in invariant position." p4: Middleware<»Covariant«>, - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." p5: Consumer<»Covariant«>, ) -> ( - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." r1: »Covariant«, - // $TEST$ error "A covariant type parameter cannot be used in contravariant position." - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ error "A covariant type parameter cannot be used in contravariant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." r2: (a1: »Covariant«) -> (r1: »Covariant«), - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." r3: Producer<»Covariant«>, - // $TEST$ error "A covariant type parameter cannot be used in invariant position." + # $TEST$ error "A covariant type parameter cannot be used in invariant position." r4: Middleware<»Covariant«>, - // $TEST$ error "A covariant type parameter cannot be used in contravariant position." + # $TEST$ error "A covariant type parameter cannot be used in contravariant position." r5: Consumer<»Covariant«>, ) } fun f2( - // $TEST$ error "A covariant type parameter cannot be used in contravariant position." + # $TEST$ error "A covariant type parameter cannot be used in contravariant position." p1: »Covariant«, - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." - // $TEST$ error "A covariant type parameter cannot be used in contravariant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ error "A covariant type parameter cannot be used in contravariant position." p2: (a1: »Covariant«) -> (r1: »Covariant«), - // $TEST$ error "A covariant type parameter cannot be used in contravariant position." + # $TEST$ error "A covariant type parameter cannot be used in contravariant position." p3: Producer<»Covariant«>, - // $TEST$ error "A covariant type parameter cannot be used in invariant position." + # $TEST$ error "A covariant type parameter cannot be used in invariant position." p4: Middleware<»Covariant«>, - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." p5: Consumer<»Covariant«>, ) -> ( - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." r1: »Covariant«, - // $TEST$ error "A covariant type parameter cannot be used in contravariant position." - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ error "A covariant type parameter cannot be used in contravariant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." r2: (a1: »Covariant«) -> (r1: »Covariant«), - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." r3: Producer<»Covariant«>, - // $TEST$ error "A covariant type parameter cannot be used in invariant position." + # $TEST$ error "A covariant type parameter cannot be used in invariant position." r4: Middleware<»Covariant«>, - // $TEST$ error "A covariant type parameter cannot be used in contravariant position." + # $TEST$ error "A covariant type parameter cannot be used in contravariant position." r5: Consumer<»Covariant«>, ) diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of variant type parameter/invariant type parameter.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of variant type parameter/invariant type parameter.sdstest index b9651f3d..7dd84bb5 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of variant type parameter/invariant type parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of variant type parameter/invariant type parameter.sdstest @@ -1,78 +1,78 @@ package tests.validation.other.declarations.typeParameters.usageOfVariantTypeParameters -// $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." +# $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." class MyClass3(p1: »Invariant«) -// $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." -// $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." -// $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." +# $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." +# $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." +# $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." sub Producer<»Invariant«>, Middleware<»Invariant«>, Consumer<»Invariant«> { - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." attr a1: »Invariant« - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." attr a2: (a1: »Invariant«) -> (r1: »Invariant«) - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." attr a3: Producer<»Invariant«> - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." attr a4: Middleware<»Invariant«> - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." attr a5: Consumer<»Invariant«> - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." attr a6: Producer> - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." attr a7: Middleware> - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." attr a8: Consumer> fun f( - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." p1: »Invariant«, - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." p2: (a1: »Invariant«) -> (r1: »Invariant«), - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." p3: Producer<»Invariant«>, - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." p4: Middleware<»Invariant«>, - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." p5: Consumer<»Invariant«>, ) -> ( - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." r1: »Invariant«, - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." r2: (a1: »Invariant«) -> (r1: »Invariant«), - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." r3: Producer<»Invariant«>, - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." r4: Middleware<»Invariant«>, - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." r5: Consumer<»Invariant«>, ) } fun f3( - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." p1: »Invariant«, - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." p2: (a1: »Invariant«) -> (r1: »Invariant«), - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." p3: Producer<»Invariant«>, - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." p4: Middleware<»Invariant«>, - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." p5: Consumer<»Invariant«>, ) -> ( - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." r1: »Invariant«, - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." r2: (a1: »Invariant«) -> (r1: »Invariant«), - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." r3: Producer<»Invariant«>, - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." r4: Middleware<»Invariant«>, - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." r5: Consumer<»Invariant«>, ) diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of variant type parameter/usage of class type parameters.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of variant type parameter/usage of class type parameters.sdstest index faf8e0a2..a1f140ce 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of variant type parameter/usage of class type parameters.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/usage of variant type parameter/usage of class type parameters.sdstest @@ -1,34 +1,34 @@ package tests.validation.other.declarations.typeParameters.usageOfVariantTypeParameters -// We already show other errors in those cases. +# We already show other errors in those cases. class MyClass4() { - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." static attr a: »Contra« - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." static fun f(p1: »Co«) -> (r1: »Contra«) - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." class MyInnerClass(p1: »Co«) { - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." attr a: »Contra« - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." static attr a: »Contra« - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." fun f(p1: »Co«) -> (r1: »Contra«) - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." static fun f(p1: »Co«) -> (r1: »Contra«) } enum MyInnerEnum { - // $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." + # $TEST$ no error r"A .*variant type parameter cannot be used in .*variant position." MyEnumVariant(p1: »Co«) } } diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/variance only on classes/invariant.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/variance only on classes/invariant.sdstest index e4a1859a..59ecc452 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/variance only on classes/invariant.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/variance only on classes/invariant.sdstest @@ -1,6 +1,6 @@ package tests.validation.other.declarations.typeParameters.varianceOnlyOnClasses -// $TEST$ no error "Only type parameters of classes can be variant." +# $TEST$ no error "Only type parameters of classes can be variant." class C1 diff --git a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/variance only on classes/variant.sdstest b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/variance only on classes/variant.sdstest index a9ce52db..daef18d3 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/variance only on classes/variant.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/declarations/type parameters/variance only on classes/variant.sdstest @@ -1,11 +1,11 @@ package tests.validation.other.declarations.typeParameters.varianceOnlyOnClasses -// $TEST$ no error "Only type parameters of classes can be variant." +# $TEST$ no error "Only type parameters of classes can be variant." class C2<»in« T> -// $TEST$ no error "Only type parameters of classes can be variant." +# $TEST$ no error "Only type parameters of classes can be variant." class C3<»out« T> -// $TEST$ error "Only type parameters of classes can be variant." +# $TEST$ error "Only type parameters of classes can be variant." fun f2<»in« T>() -// $TEST$ error "Only type parameters of classes can be variant." +# $TEST$ error "Only type parameters of classes can be variant." fun f3<»out« T>() diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/arguments/must be constant if parameter is constant/annotation calls.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/arguments/must be constant if parameter is constant/annotation calls.sdstest index 98ef0ddb..b68ff36d 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/arguments/must be constant if parameter is constant/annotation calls.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/arguments/must be constant if parameter is constant/annotation calls.sdstest @@ -6,22 +6,22 @@ annotation MyAnnotation1(value: Int) @Repeatable annotation MyAnnotation2(constantParam: MyEnum) -// $TEST$ no error "Values assigned to annotation parameters must be constant." +# $TEST$ no error "Values assigned to annotation parameters must be constant." @MyAnnotation1(»1«) -// $TEST$ no error "Values assigned to annotation parameters must be constant." +# $TEST$ no error "Values assigned to annotation parameters must be constant." @MyAnnotation1(»-2«) -// $TEST$ error "Values assigned to annotation parameters must be constant." +# $TEST$ error "Values assigned to annotation parameters must be constant." @MyAnnotation1(»[1, 2][0]«) -// $TEST$ error "Values assigned to annotation parameters must be constant." +# $TEST$ error "Values assigned to annotation parameters must be constant." @MyAnnotation1(»intFunction()«) -// $TEST$ error "Values assigned to annotation parameters must be constant." +# $TEST$ error "Values assigned to annotation parameters must be constant." @MyAnnotation1(value = »intFunction()«) -// $TEST$ no error "Values assigned to annotation parameters must be constant." +# $TEST$ no error "Values assigned to annotation parameters must be constant." @MyAnnotation2(»MyEnum.MyConstantVariant(1)«) -// $TEST$ error "Values assigned to annotation parameters must be constant." +# $TEST$ error "Values assigned to annotation parameters must be constant." @Unresolved(»intFunction()«) -// $TEST$ error "Values assigned to annotation parameters must be constant." +# $TEST$ error "Values assigned to annotation parameters must be constant." @MyAnnotation1(unresolved = »intFunction()«) pipeline testPipeline {} diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/arguments/must be constant if parameter is constant/const parameters.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/arguments/must be constant if parameter is constant/const parameters.sdstest index a3608cd7..d12779b7 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/arguments/must be constant if parameter is constant/const parameters.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/arguments/must be constant if parameter is constant/const parameters.sdstest @@ -11,17 +11,17 @@ fun anotherFunctionWithConstantParameter( ) pipeline testPipeline { - // $TEST$ no error "Values assigned to constant parameters must be constant." + # $TEST$ no error "Values assigned to constant parameters must be constant." myFunctionWithConstantParameter(»1«); - // $TEST$ no error "Values assigned to constant parameters must be constant." + # $TEST$ no error "Values assigned to constant parameters must be constant." myFunctionWithConstantParameter(»-2«); - // $TEST$ error "Values assigned to constant parameters must be constant." + # $TEST$ error "Values assigned to constant parameters must be constant." myFunctionWithConstantParameter(»[1, 2][0]«); - // $TEST$ error "Values assigned to constant parameters must be constant." + # $TEST$ error "Values assigned to constant parameters must be constant." myFunctionWithConstantParameter(»intFunction()«); - // $TEST$ error "Values assigned to constant parameters must be constant." + # $TEST$ error "Values assigned to constant parameters must be constant." myFunctionWithConstantParameter(constantParam = »intFunction()«); - // $TEST$ no error "Values assigned to constant parameters must be constant." + # $TEST$ no error "Values assigned to constant parameters must be constant." anotherFunctionWithConstantParameter(»MyEnum.MyConstantVariant(1)«); } diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/arguments/must be constant if parameter is constant/normal parameters.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/arguments/must be constant if parameter is constant/normal parameters.sdstest index 5cc70771..86ac41b8 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/arguments/must be constant if parameter is constant/normal parameters.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/arguments/must be constant if parameter is constant/normal parameters.sdstest @@ -6,13 +6,13 @@ fun myFunctionWithNormalParameter( ) pipeline testPipeline { - // $TEST$ no error "Values assigned to constant parameters must be constant." + # $TEST$ no error "Values assigned to constant parameters must be constant." myFunctionWithNormalParameter(»intFunction()«); - // $TEST$ no error "Values assigned to constant parameters must be constant." + # $TEST$ no error "Values assigned to constant parameters must be constant." myFunctionWithNormalParameter(param = »intFunction()«); - // $TEST$ no error "Values assigned to constant parameters must be constant." + # $TEST$ no error "Values assigned to constant parameters must be constant." unresolved(»intFunction()«); - // $TEST$ no error "Values assigned to constant parameters must be constant." + # $TEST$ no error "Values assigned to constant parameters must be constant." myFunctionWithNormalParameter(unresolved = »intFunction()«); } diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/direct.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/direct.sdstest index 5cd39024..661a6546 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/direct.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/direct.sdstest @@ -1,16 +1,16 @@ package tests.validation.other.expression.calls.recurcion.direct segment s1() { - // $TEST$ error "Call leads to infinite recursion." + # $TEST$ error "Call leads to infinite recursion." »s2()«; } segment s2() { - // $TEST$ error "Call leads to infinite recursion." + # $TEST$ error "Call leads to infinite recursion." »s3()«; } segment s3() { - // $TEST$ error "Call leads to infinite recursion." + # $TEST$ error "Call leads to infinite recursion." »s2()«; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/not recursive.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/not recursive.sdstest index 56cca762..e4d3265b 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/not recursive.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/not recursive.sdstest @@ -6,7 +6,7 @@ package tests.validation.other.expression.calls.recurcion.notRecursive */ segment s1() { - // $TEST$ no error "Call leads to infinite recursion." + # $TEST$ no error "Call leads to infinite recursion." »s2(() -> s2())«; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/transitive via function pointer argument.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/transitive via function pointer argument.sdstest index 7b987816..8365b787 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/transitive via function pointer argument.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/transitive via function pointer argument.sdstest @@ -1,7 +1,7 @@ package tests.validation.other.expression.calls.recurcion.transitiveViaFunctionPointerArgument segment s1() { - // $TEST$ error "Call leads to infinite recursion." + # $TEST$ error "Call leads to infinite recursion." »s2(s1)«; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/transitive via lambda argument.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/transitive via lambda argument.sdstest index 04cda9eb..6118843f 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/transitive via lambda argument.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/transitive via lambda argument.sdstest @@ -1,7 +1,7 @@ package tests.validation.other.expression.calls.recurcion.transitiveViaLambdaArgument segment s1() { - // $TEST$ error "Call leads to infinite recursion." + # $TEST$ error "Call leads to infinite recursion." »s2(() -> s1())«; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/transitive.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/transitive.sdstest index aac91299..f27abb27 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/transitive.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/calls/recursion/transitive.sdstest @@ -1,16 +1,16 @@ package tests.validation.other.expression.calls.recurcion.transitive segment s1() { - // $TEST$ error "Call leads to infinite recursion." + # $TEST$ error "Call leads to infinite recursion." »s2()«; } segment s2() { - // $TEST$ error "Call leads to infinite recursion." + # $TEST$ error "Call leads to infinite recursion." »s3()«; } segment s3() { - // $TEST$ error "Call leads to infinite recursion." + # $TEST$ error "Call leads to infinite recursion." »s1()«; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/chained expression/missing null safety/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/chained expression/missing null safety/main.sdstest index 2bd87988..16dfac3c 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/chained expression/missing null safety/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/chained expression/missing null safety/main.sdstest @@ -13,41 +13,41 @@ segment call( val myFunction = myClass.f; val myFunctionOrNull = myClassOrNull?.f; - // $TEST$ no error "The receiver can be null so a null-safe call must be used." + # $TEST$ no error "The receiver can be null so a null-safe call must be used." »(() {})()«; - // $TEST$ no error "The receiver can be null so a null-safe call must be used." + # $TEST$ no error "The receiver can be null so a null-safe call must be used." »1()«; - // $TEST$ no error "The receiver can be null so a null-safe call must be used." + # $TEST$ no error "The receiver can be null so a null-safe call must be used." »null()«; - // $TEST$ no error "The receiver can be null so a null-safe call must be used." + # $TEST$ no error "The receiver can be null so a null-safe call must be used." »myFunction()«; - // $TEST$ error "The receiver can be null so a null-safe call must be used." + # $TEST$ error "The receiver can be null so a null-safe call must be used." »myFunctionOrNull()«; - // $TEST$ no error "The receiver can be null so a null-safe call must be used." + # $TEST$ no error "The receiver can be null so a null-safe call must be used." »unresolved()«; - // $TEST$ no error "The receiver can be null so a null-safe call must be used." + # $TEST$ no error "The receiver can be null so a null-safe call must be used." »(() {})?()«; - // $TEST$ no error "The receiver can be null so a null-safe call must be used." + # $TEST$ no error "The receiver can be null so a null-safe call must be used." »1?()«; - // $TEST$ no error "The receiver can be null so a null-safe call must be used." + # $TEST$ no error "The receiver can be null so a null-safe call must be used." »null?()«; - // $TEST$ no error "The receiver can be null so a null-safe call must be used." + # $TEST$ no error "The receiver can be null so a null-safe call must be used." »myFunction?()«; - // $TEST$ no error "The receiver can be null so a null-safe call must be used." + # $TEST$ no error "The receiver can be null so a null-safe call must be used." »myFunctionOrNull?()«; - // $TEST$ no error "The receiver can be null so a null-safe call must be used." + # $TEST$ no error "The receiver can be null so a null-safe call must be used." »unresolved?()«; } @@ -58,38 +58,38 @@ segment indexedAccess( val myList = myClass.l; val myListOrNull = myClassOrNull?.l; - // $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." + # $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." »[1][0]«; - // $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." + # $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." »1[0]«; - // $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." + # $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." »null[0]«; - // $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." + # $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." »myList[0]«; - // $TEST$ error "The receiver can be null so a null-safe indexed access must be used." + # $TEST$ error "The receiver can be null so a null-safe indexed access must be used." »myListOrNull[0]«; - // $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." + # $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." »unresolved[0]«; - // $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." + # $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." »1?[0]«; - // $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." + # $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." »null?[0]«; - // $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." + # $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." »myList?[0]«; - // $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." + # $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." »myListOrNull?[0]«; - // $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." + # $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." »unresolved?[0]«; } @@ -97,13 +97,13 @@ class IndexedAccess?, NonNullable sub List>( nullable: Nullable, nonNullable: NonNullable, - // $TEST$ error "The receiver can be null so a null-safe indexed access must be used." + # $TEST$ error "The receiver can be null so a null-safe indexed access must be used." p1: Any? = »nullable[0]«, - // $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." + # $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." p2: Any? = »nonNullable[0]«, - // $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." + # $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." p3: Any? = »nullable?[0]«, - // $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." + # $TEST$ no error "The receiver can be null so a null-safe indexed access must be used." p4: Any? = »nonNullable?[0]«, ) diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/indexed access/list index out of bounds/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/indexed access/list index out of bounds/main.sdstest index a22e3b64..dc78adfd 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/indexed access/list index out of bounds/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/indexed access/list index out of bounds/main.sdstest @@ -10,44 +10,44 @@ segment mySegment( ) { val placeholderList = [1]; - // $TEST$ error "List index '-1' is out of bounds." + # $TEST$ error "List index '-1' is out of bounds." myFunction()[»-1«]; - // $TEST$ no error r"List index '.*' is out of bounds\." + # $TEST$ no error r"List index '.*' is out of bounds\." myFunction()[»0«]; - // $TEST$ no error r"List index '.*' is out of bounds\." + # $TEST$ no error r"List index '.*' is out of bounds\." myFunction()[»1«]; - // $TEST$ no error r"List index '.*' is out of bounds\." + # $TEST$ no error r"List index '.*' is out of bounds\." myFunction()[»parameterIndex«]; - // $TEST$ error "List index '-1' is out of bounds." + # $TEST$ error "List index '-1' is out of bounds." parameterList[»-1«]; - // $TEST$ no error r"List index '.*' is out of bounds\." + # $TEST$ no error r"List index '.*' is out of bounds\." parameterList[»0«]; - // $TEST$ no error r"List index '.*' is out of bounds\." + # $TEST$ no error r"List index '.*' is out of bounds\." parameterList[»1«]; - // $TEST$ no error r"List index '.*' is out of bounds\." + # $TEST$ no error r"List index '.*' is out of bounds\." parameterList[»parameterIndex«]; - // $TEST$ error "List index '-1' is out of bounds." + # $TEST$ error "List index '-1' is out of bounds." nullableList[»-1«]; - // $TEST$ no error r"List index '.*' is out of bounds\." + # $TEST$ no error r"List index '.*' is out of bounds\." nullableList[»0«]; - // $TEST$ no error r"List index '.*' is out of bounds\." + # $TEST$ no error r"List index '.*' is out of bounds\." nullableList[»1«]; - // $TEST$ no error r"List index '.*' is out of bounds\." + # $TEST$ no error r"List index '.*' is out of bounds\." nullableList[»parameterIndex«]; - // $TEST$ error "List index '-1' is out of bounds." + # $TEST$ error "List index '-1' is out of bounds." placeholderList[»-1«]; - // $TEST$ no error r"List index '.*' is out of bounds\." + # $TEST$ no error r"List index '.*' is out of bounds\." placeholderList[»0«]; - // $TEST$ error "List index '1' is out of bounds." + # $TEST$ error "List index '1' is out of bounds." placeholderList[»1«]; - // $TEST$ no error r"List index '.*' is out of bounds\." + # $TEST$ no error r"List index '.*' is out of bounds\." placeholderList[»parameterIndex«]; - // $TEST$ no error r"List index '.*' is out of bounds\." + # $TEST$ no error r"List index '.*' is out of bounds\." unresolved[»-1«]; - // $TEST$ no error r"List index '.*' is out of bounds\." + # $TEST$ no error r"List index '.*' is out of bounds\." placeholderList[»unresolved«]; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/indexed access/map key does not exist/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/indexed access/map key does not exist/main.sdstest index b2978f1e..c266fd76 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/indexed access/map key does not exist/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/indexed access/map key does not exist/main.sdstest @@ -6,29 +6,29 @@ fun myFunction() -> resultMap: Map segment mySegment(parameterMap: Map, parameterKey: String) { val placeholderMap = {"key": 1}; - // $TEST$ no error r"Map key '.*' does not exist\." + # $TEST$ no error r"Map key '.*' does not exist\." myFunction()[»"unknown"«]; - // $TEST$ no error r"Map key '.*' does not exist\." + # $TEST$ no error r"Map key '.*' does not exist\." myFunction()[»"key"«]; - // $TEST$ no error r"Map key '.*' does not exist\." + # $TEST$ no error r"Map key '.*' does not exist\." myFunction()[»parameterKey«]; - // $TEST$ no error r"Map key '.*' does not exist\." + # $TEST$ no error r"Map key '.*' does not exist\." parameterMap[»"unknown"«]; - // $TEST$ no error r"Map key '.*' does not exist\." + # $TEST$ no error r"Map key '.*' does not exist\." parameterMap[»"key"«]; - // $TEST$ no error r"Map key '.*' does not exist\." + # $TEST$ no error r"Map key '.*' does not exist\." parameterMap[»parameterKey«]; - // $TEST$ error "Map key '"unknown"' does not exist." + # $TEST$ error "Map key '"unknown"' does not exist." placeholderMap[»"unknown"«]; - // $TEST$ no error r"Map key '.*' does not exist\." + # $TEST$ no error r"Map key '.*' does not exist\." placeholderMap[»"key"«]; - // $TEST$ no error r"Map key '.*' does not exist\." + # $TEST$ no error r"Map key '.*' does not exist\." placeholderMap[»parameterKey«]; - // $TEST$ no error r"Map key '.*' does not exist\." + # $TEST$ no error r"Map key '.*' does not exist\." unresolved[»"unknown"«]; - // $TEST$ no error r"Map key '.*' does not exist\." + # $TEST$ no error r"Map key '.*' does not exist\." placeholderMap[»unresolved«]; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/infix operations/division by zero/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/infix operations/division by zero/main.sdstest index 365a2c93..492831ad 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/infix operations/division by zero/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/infix operations/division by zero/main.sdstest @@ -1,38 +1,38 @@ package tests.validation.other.expressions.infixOperations.divisionByZero -pipeline test { - // $TEST$ error "Division by zero." +function test () { + # $TEST$ error "Division by zero." »1.0 / 0.0«; - // $TEST$ error "Division by zero." + # $TEST$ error "Division by zero." »1.0 / -0.0«; - // $TEST$ no error "Division by zero." + # $TEST$ no error "Division by zero." »1.0 / 1.0«; - // $TEST$ error "Division by zero." + # $TEST$ error "Division by zero." »1.0 / 0«; - // $TEST$ no error "Division by zero." + # $TEST$ no error "Division by zero." »1.0 / 1«; - // $TEST$ error "Division by zero." + # $TEST$ error "Division by zero." »1 / 0.0«; - // $TEST$ error "Division by zero." + # $TEST$ error "Division by zero." »1 / -0.0«; - // $TEST$ no error "Division by zero." + # $TEST$ no error "Division by zero." »1 / 1.0«; - // $TEST$ error "Division by zero." + # $TEST$ error "Division by zero." »1 / 0«; - // $TEST$ no error "Division by zero." + # $TEST$ no error "Division by zero." »1 / 1«; - // $TEST$ no error "Division by zero." + # $TEST$ no error "Division by zero." »null / 0.0«; - // $TEST$ no error "Division by zero." + # $TEST$ no error "Division by zero." »null / -0.0«; - // $TEST$ no error "Division by zero." + # $TEST$ no error "Division by zero." »null / 1.0«; - // $TEST$ no error "Division by zero." + # $TEST$ no error "Division by zero." »null / 0«; - // $TEST$ no error "Division by zero." + # $TEST$ no error "Division by zero." »null / 1«; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/lambdas/context/assigned to typed parameter.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/lambdas/context/assigned to typed parameter.sdstest index 5bdb35bc..bdb60e5e 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/lambdas/context/assigned to typed parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/lambdas/context/assigned to typed parameter.sdstest @@ -6,59 +6,59 @@ package tests.validation.other.expressions.lambdas.assignedToTypedParameter @Repeatable annotation MyAnnotation( - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." f: () -> () = »() {}«, - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." g: () -> r: Int = »() -> 1« ) class MyClass( - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." f: () -> () = »() {}«, - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." g: () -> r: Int = ((»() -> 1«)) ) enum MyEnum { MyEnumVariant( - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." f: () -> () = »() {}«, - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." g: () -> r: Int = ((»() -> 1«)) ) } fun myFunction( - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." f: () -> () = »() {}«, - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." g: () -> r: Int = ((»() -> 1«)) ) segment mySegment1( - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." f: () -> () = »() {}«, - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." g: () -> r: Int = ((»() -> 1«)) ) {} segment mySegment2( - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." f: (p: () -> () = »() {}«) -> (), - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." g: (p: () -> (r: Int) = ((»() -> 1«))) -> (), ) { ( - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." f: () -> () = »() {}«, - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." g: () -> r: Int = ((»() -> 1«)) ) {}; ( - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." f: () -> () = »() {}«, - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." g: () -> r: Int = ((»() -> 1«)) ) -> 1; } @@ -68,15 +68,15 @@ segment mySegment2( */ @MyAnnotation( - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." »() {}«, - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." ((»() -> 1«)) ) @MyAnnotation( - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." f = »() {}«, - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." g = ((»() -> 1«)) ) segment lambdasPassedAsArguments( @@ -86,106 +86,106 @@ segment lambdasPassedAsArguments( val expressionLambda = (p: () -> (), q: () -> (r: Int)) -> 1; MyAnnotation( - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." »() {}«, - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." ((»() -> 1«)) ); MyAnnotation( - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." f = »() {}«, - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." g = ((»() -> 1«)) ); MyClass( - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." »() {}«, - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." ((»() -> 1«)) ); MyClass( - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." f = »() {}«, - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." g = ((»() -> 1«)) ); MyEnum.MyEnumVariant( - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." »() {}«, - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." ((»() -> 1«)) ); MyEnum.MyEnumVariant( - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." f = »() {}«, - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." g = ((»() -> 1«)) ); myFunction( - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." »() {}«, - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." ((»() -> 1«)) ); myFunction( - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." f = »() {}«, - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." g = ((»() -> 1«)) ); mySegment1( - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." »() {}«, - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." ((»() -> 1«)) ); mySegment1( - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." f = »() {}«, - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." g = ((»() -> 1«)) ); callableType( - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." »() {}«, - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." ((»() -> 1«)) ); callableType( - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." p = »() {}«, - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." q = ((»() -> 1«)) ); blockLambda( - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." »() {}«, - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." ((»() -> 1«)) ); blockLambda( - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." p = »() {}«, - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." q = ((»() -> 1«)) ); expressionLambda( - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." »() {}«, - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." ((»() -> 1«)) ); expressionLambda( - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." p = »() {}«, - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." q = ((»() -> 1«)) ); } diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/lambdas/context/assigned to unresolved parameter.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/lambdas/context/assigned to unresolved parameter.sdstest index 1f6db20d..9ef52e47 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/lambdas/context/assigned to unresolved parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/lambdas/context/assigned to unresolved parameter.sdstest @@ -3,18 +3,18 @@ package tests.validation.other.expressions.lambdas.context.assignedToUnresolvedP fun myFunction() pipeline unresolvedParameter { - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." myFunction(»() {}«); - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." myFunction(»() -> 1«); - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." myFunction(unresolved = »() {}«); - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." myFunction(unresolved = »() -> 1«); - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." unresolved(»() {}«); - // $TEST$ no error "A lambda must be assigned to a typed parameter." + # $TEST$ no error "A lambda must be assigned to a typed parameter." unresolved(»() -> 1«); } diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/lambdas/context/assigned to untyped parameter.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/lambdas/context/assigned to untyped parameter.sdstest index 4a9b77d5..0e2b3cde 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/lambdas/context/assigned to untyped parameter.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/lambdas/context/assigned to untyped parameter.sdstest @@ -6,59 +6,59 @@ package tests.validation.other.expressions.lambdas.context.assignedToUntypedPara @Repeatable annotation MyAnnotation( - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." f = (»() {}«), - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." g = »() -> 1« ) class MyClass( - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." f = (»() {}«), - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." g = »() -> 1« ) enum MyEnum { MyEnumVariant( - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." f = (»() {}«), - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." g = »() -> 1« ) } fun myFunction( - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." f = (»() {}«), - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." g = »() -> 1« ) segment mySegment1( - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." f = (»() {}«), - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." g = »() -> 1« ) {} segment mySegment2( - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." f: (p = (»() {}«)) -> (), - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." g: (p = »() -> 1«) -> (), ) { ( - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." f = (»() {}«), - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." g = »() -> 1« ) {}; ( - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." f = (»() {}«), - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." g = »() -> 1« ) -> 1; } @@ -68,15 +68,15 @@ segment mySegment2( */ @MyAnnotation( - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." (»() {}«), - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." »() -> 1« ) @MyAnnotation( - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." f = (»() {}«), - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." g = »() -> 1« ) segment lambdasPassedAsArguments( @@ -86,106 +86,106 @@ segment lambdasPassedAsArguments( val expressionLambda = (p, q) -> 1; MyAnnotation( - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." (»() {}«), - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." »() -> 1« ); MyAnnotation( - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." f = (»() {}«), - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." g = »() -> 1« ); MyClass( - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." (»() {}«), - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." »() -> 1« ); MyClass( - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." f = (»() {}«), - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." g = »() -> 1« ); MyEnum.MyEnumVariant( - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." (»() {}«), - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." »() -> 1« ); MyEnum.MyEnumVariant( - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." f = (»() {}«), - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." g = »() -> 1« ); myFunction( - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." (»() {}«), - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." »() -> 1« ); myFunction( - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." f = (»() {}«), - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." g = »() -> 1« ); mySegment1( - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." (»() {}«), - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." »() -> 1« ); mySegment1( - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." f = (»() {}«), - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." g = »() -> 1« ); callableType( - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." (»() {}«), - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." »() -> 1« ); callableType( - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." p = (»() {}«), - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." q = »() -> 1« ); blockLambda( - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." (»() {}«), - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." »() -> 1« ); blockLambda( - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." p = (»() {}«), - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." q = »() -> 1« ); expressionLambda( - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." (»() {}«), - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." »() -> 1« ); expressionLambda( - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." p = (»() {}«), - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." q = »() -> 1« ); } diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/lambdas/context/invalid context.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/lambdas/context/invalid context.sdstest index 192f8fea..53a576ef 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/lambdas/context/invalid context.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/lambdas/context/invalid context.sdstest @@ -1,16 +1,16 @@ package tests.validation.other.expressions.lambdas.context.invalidContext pipeline invalidContext { - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." »() {}«; - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." »() -> 1«; - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." (»() {}«)(); - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." (»() -> 1«)(); - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." val a = »() {}«; - // $TEST$ error "A lambda must be assigned to a typed parameter." + # $TEST$ error "A lambda must be assigned to a typed parameter." val b = »() -> 1«; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/references/function pointer/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/references/function pointer/main.sdstest index e5a957ba..b2cf5d7f 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/references/function pointer/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/references/function pointer/main.sdstest @@ -11,58 +11,58 @@ fun myFunction2(p: Any) segment mySegment1() {} segment mySegment2() { - // $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + # $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." MyClass().»myInstanceMethod«; - // $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + # $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." MyClass().»myInstanceMethod«.a; - // $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + # $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." MyClass().»myInstanceMethod«.a(); - // $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + # $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." myFunction2(MyClass().»myInstanceMethod«); - // $TEST$ no error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + # $TEST$ no error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." MyClass().»myInstanceMethod«(); - // $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + # $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." MyClass.»myStaticMethod«; - // $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + # $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." MyClass.»myStaticMethod«.a; - // $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + # $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." MyClass.»myStaticMethod«.a(); - // $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + # $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." myFunction2(MyClass.»myStaticMethod«); - // $TEST$ no error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + # $TEST$ no error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." MyClass.»myStaticMethod«(); - // $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + # $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." »myFunction1«; - // $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + # $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." »myFunction1«.a; - // $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + # $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." »myFunction1«.a(); - // $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + # $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." myFunction2(»myFunction1«); - // $TEST$ no error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + # $TEST$ no error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." »myFunction1«(); - // $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + # $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." »mySegment1«; - // $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + # $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." »mySegment1«.a; - // $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + # $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." »mySegment1«.a(); - // $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + # $TEST$ error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." myFunction2(»mySegment1«); - // $TEST$ no error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + # $TEST$ no error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." »mySegment1«(); - // $TEST$ no error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + # $TEST$ no error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." »unresolved«; - // $TEST$ no error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + # $TEST$ no error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." »unresolved«.a; - // $TEST$ no error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + # $TEST$ no error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." »unresolved«.a(); - // $TEST$ no error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + # $TEST$ no error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." myFunction2(»unresolved«); - // $TEST$ no error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." + # $TEST$ no error "Function pointers are not allowed to provide a cleaner graphical view. Use a lambda instead." »unresolved«(); } diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/references/static class reference/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/references/static class reference/main.sdstest index 729e2e53..5c70df50 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/references/static class reference/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/references/static class reference/main.sdstest @@ -14,31 +14,31 @@ class ClassWithStaticMembers { class InnerClassWithoutConstructor } -pipeline test { - // $TEST$ no error "A class must not be statically referenced." +function test () { + # $TEST$ no error "A class must not be statically referenced." »Unresolved«; - // $TEST$ error "A class must not be statically referenced." + # $TEST$ error "A class must not be statically referenced." »ClassWithConstructor«; - // $TEST$ error "A class must not be statically referenced." + # $TEST$ error "A class must not be statically referenced." »ClassWithoutConstructor«; - // $TEST$ no error "A class must not be statically referenced." + # $TEST$ no error "A class must not be statically referenced." »ClassWithoutConstructor«(); - // $TEST$ no error "A class must not be statically referenced." + # $TEST$ no error "A class must not be statically referenced." »ClassWithConstructor«(); - // $TEST$ no error "A class must not be statically referenced." + # $TEST$ no error "A class must not be statically referenced." »ClassWithStaticMembers«.myAttribute; - // $TEST$ no error "A class must not be statically referenced." + # $TEST$ no error "A class must not be statically referenced." »ClassWithStaticMembers«.unresolved; - // $TEST$ no error "A class must not be statically referenced." - // $TEST$ error "A class must not be statically referenced." + # $TEST$ no error "A class must not be statically referenced." + # $TEST$ error "A class must not be statically referenced." »ClassWithStaticMembers«.»InnerClassWithConstructor«; - // $TEST$ no error "A class must not be statically referenced." - // $TEST$ error "A class must not be statically referenced." + # $TEST$ no error "A class must not be statically referenced." + # $TEST$ error "A class must not be statically referenced." »ClassWithStaticMembers«.»InnerClassWithoutConstructor«; - // $TEST$ no error "A class must not be statically referenced." - // $TEST$ no error "A class must not be statically referenced." + # $TEST$ no error "A class must not be statically referenced." + # $TEST$ no error "A class must not be statically referenced." »ClassWithStaticMembers«.»InnerClassWithConstructor«(); - // $TEST$ no error "A class must not be statically referenced." - // $TEST$ no error "A class must not be statically referenced." + # $TEST$ no error "A class must not be statically referenced." + # $TEST$ no error "A class must not be statically referenced." »ClassWithStaticMembers«.»InnerClassWithConstructor«.myAttribute; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/references/static enum reference/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/references/static enum reference/main.sdstest index 60fc554a..f2b5b6e9 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/references/static enum reference/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/references/static enum reference/main.sdstest @@ -16,23 +16,23 @@ class ClassWithEnum { } } -pipeline test { - // $TEST$ no error "An enum must not be statically referenced." +function test () { + # $TEST$ no error "An enum must not be statically referenced." »Unresolved«; - // $TEST$ error "An enum must not be statically referenced." + # $TEST$ error "An enum must not be statically referenced." »Enum«; - // $TEST$ no error "An enum must not be statically referenced." + # $TEST$ no error "An enum must not be statically referenced." »Enum«(); - // $TEST$ no error "An enum must not be statically referenced." + # $TEST$ no error "An enum must not be statically referenced." »Enum«.Variant; - // $TEST$ no error "An enum must not be statically referenced." + # $TEST$ no error "An enum must not be statically referenced." »Enum«.unresolved; - // $TEST$ error "An enum must not be statically referenced." + # $TEST$ error "An enum must not be statically referenced." ClassWithEnum.»Enum«; - // $TEST$ no error "An enum must not be statically referenced." + # $TEST$ no error "An enum must not be statically referenced." ClassWithEnum.»Enum«.Variant; - // $TEST$ error "An enum must not be statically referenced." + # $TEST$ error "An enum must not be statically referenced." ClassWithEnum.ClassWithEnum.»Enum«; - // $TEST$ no error "An enum must not be statically referenced." + # $TEST$ no error "An enum must not be statically referenced." ClassWithEnum.ClassWithEnum.»Enum«.Variant; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/references/target/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/references/target/main.sdstest index 1d2b7fac..60206529 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/references/target/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/references/target/main.sdstest @@ -2,17 +2,17 @@ package tests.validation.other.expressions.references.target annotation MyAnnotation -pipeline myPipeline {} +function myFunction () {} schema MySchema {} segment mySegment() { - // $TEST$ error "An annotation must not be the target of a reference." + # $TEST$ error "An annotation must not be the target of a reference." »MyAnnotation«; - // $TEST$ error "A pipeline must not be the target of a reference." + # $TEST$ error "A pipeline must not be the target of a reference." »myPipeline«; - // $TEST$ error "A schema must not be the target of a reference." + # $TEST$ error "A schema must not be the target of a reference." »MySchema«; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/expressions/template strings/missing template expression/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/expressions/template strings/missing template expression/main.sdstest index 4e394d56..21a7906e 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/expressions/template strings/missing template expression/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/expressions/template strings/missing template expression/main.sdstest @@ -1,11 +1,11 @@ package tests.validation.other.expressions.templateStrings.missingTemplateExpression -pipeline test { - // $TEST$ error "There must be an expression between two string parts." - // $TEST$ error "There must be an expression between two string parts." +function test () { + # $TEST$ error "There must be an expression between two string parts." + # $TEST$ error "There must be an expression between two string parts." "start {{ »}} inner {{« »}} end"«; - // $TEST$ no error "There must be an expression between two string parts." - // $TEST$ no error "There must be an expression between two string parts." + # $TEST$ no error "There must be an expression between two string parts." + # $TEST$ no error "There must be an expression between two string parts." "start {{ 1 »}} inner {{« 1 »}} end"«; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/imports/main with issues.sdstest b/packages/ttsl-lang/tests/resources/validation/other/imports/main with issues.sdstest index 85cdcf69..b3413319 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/imports/main with issues.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/imports/main with issues.sdstest @@ -1,15 +1,15 @@ package tests.other.imports -// $TEST$ error "The package 'tests.other.imports.missing' does not exist." +# $TEST$ error "The package 'tests.other.imports.missing' does not exist." from »tests.other.imports.missing« import * -// $TEST$ error "The package 'tests.other.imports.missing' does not exist." +# $TEST$ error "The package 'tests.other.imports.missing' does not exist." from »tests.other.imports.missing« import C -// $TEST$ error "The package 'tests.other.imports.missing' does not exist." +# $TEST$ error "The package 'tests.other.imports.missing' does not exist." from »tests.other.imports.missing« import C as D -// $TEST$ warning "The package 'tests.other.imports.empty' is empty." +# $TEST$ warning "The package 'tests.other.imports.empty' is empty." from »tests.other.imports.empty« import * -// $TEST$ warning "The package 'tests.other.imports.empty' is empty." +# $TEST$ warning "The package 'tests.other.imports.empty' is empty." from »tests.other.imports.empty« import C -// $TEST$ warning "The package 'tests.other.imports.empty' is empty." +# $TEST$ warning "The package 'tests.other.imports.empty' is empty." from »tests.other.imports.empty« import C as D diff --git a/packages/ttsl-lang/tests/resources/validation/other/imports/main without issues.sdstest b/packages/ttsl-lang/tests/resources/validation/other/imports/main without issues.sdstest index 193d07a8..5e0b52df 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/imports/main without issues.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/imports/main without issues.sdstest @@ -1,7 +1,7 @@ package tests.other.imports -// $TEST$ no error r"The package '\.*' does not exist\." -// $TEST$ no warning r"The package '\.*' is empty\." +# $TEST$ no error r"The package '\.*' does not exist\." +# $TEST$ no warning r"The package '\.*' is empty\." from tests.other.imports.nonEmpty import * from tests.other.imports.nonEmpty import C diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/declarations in pipeline files/main.sdspipe b/packages/ttsl-lang/tests/resources/validation/other/modules/declarations in pipeline files/main.sdspipe index 522c1778..c4a9678c 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/declarations in pipeline files/main.sdspipe +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/declarations in pipeline files/main.sdspipe @@ -1,33 +1,33 @@ package tests.validation.other.modules.declarationsInPipelineFiles -// $TEST$ error "A pipeline file must only declare pipelines and segments." +# $TEST$ error "A pipeline file must only declare pipelines and segments." annotation »MyAnnotation« -// $TEST$ error "A pipeline file must only declare pipelines and segments." +# $TEST$ error "A pipeline file must only declare pipelines and segments." class »MyClass« { - // $TEST$ no error "A pipeline file must only declare pipelines and segments." + # $TEST$ no error "A pipeline file must only declare pipelines and segments." attr »a«: Int - // $TEST$ no error "A pipeline file must only declare pipelines and segments." + # $TEST$ no error "A pipeline file must only declare pipelines and segments." class »MyNestedClass« - // $TEST$ no error "A pipeline file must only declare pipelines and segments." + # $TEST$ no error "A pipeline file must only declare pipelines and segments." enum »MyEnum« - // $TEST$ no error "A pipeline file must only declare pipelines and segments." + # $TEST$ no error "A pipeline file must only declare pipelines and segments." fun »myFunction«() } -// $TEST$ error "A pipeline file must only declare pipelines and segments." +# $TEST$ error "A pipeline file must only declare pipelines and segments." enum »MyEnum« { - // $TEST$ no error "A pipeline file must only declare pipelines and segments." + # $TEST$ no error "A pipeline file must only declare pipelines and segments." »MyEnumInstance« } -// $TEST$ error "A pipeline file must only declare pipelines and segments." +# $TEST$ error "A pipeline file must only declare pipelines and segments." fun »myFunction«() -// $TEST$ error "A pipeline file must only declare pipelines and segments." +# $TEST$ error "A pipeline file must only declare pipelines and segments." schema »MySchema« {} -// $TEST$ no error "A pipeline file must only declare pipelines and segments." +# $TEST$ no error "A pipeline file must only declare pipelines and segments." pipeline »myPipeline« {} -// $TEST$ no error "A pipeline file must only declare pipelines and segments." +# $TEST$ no error "A pipeline file must only declare pipelines and segments." segment »mySegment«() {} diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/declarations in stub files/main.sdsstub b/packages/ttsl-lang/tests/resources/validation/other/modules/declarations in stub files/main.sdsstub index 29a5e436..dc1967cc 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/declarations in stub files/main.sdsstub +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/declarations in stub files/main.sdsstub @@ -1,33 +1,33 @@ package tests.validation.other.modules.declarationsInStubFiles -// $TEST$ error "A stub file must not declare pipelines or segments." +# $TEST$ error "A stub file must not declare pipelines or segments." pipeline »myPipeline« {} -// $TEST$ error "A stub file must not declare pipelines or segments." +# $TEST$ error "A stub file must not declare pipelines or segments." segment »mySegment«() {} -// $TEST$ no error "A stub file must not declare pipelines or segments." +# $TEST$ no error "A stub file must not declare pipelines or segments." annotation »MyAnnotation« -// $TEST$ no error "A stub file must not declare pipelines or segments." +# $TEST$ no error "A stub file must not declare pipelines or segments." class »MyClass« { - // $TEST$ no error "A stub file must not declare pipelines or segments." + # $TEST$ no error "A stub file must not declare pipelines or segments." attr »a«: Int - // $TEST$ no error "A stub file must not declare pipelines or segments." + # $TEST$ no error "A stub file must not declare pipelines or segments." class »MyNestedClass« - // $TEST$ no error "A stub file must not declare pipelines or segments." + # $TEST$ no error "A stub file must not declare pipelines or segments." enum »MyEnum« - // $TEST$ no error "A stub file must not declare pipelines or segments." + # $TEST$ no error "A stub file must not declare pipelines or segments." fun »myFunction«() } -// $TEST$ no error "A stub file must not declare pipelines or segments." +# $TEST$ no error "A stub file must not declare pipelines or segments." enum »MyEnum« { - // $TEST$ no error "A stub file must not declare pipelines or segments." + # $TEST$ no error "A stub file must not declare pipelines or segments." »MyEnumInstance« } -// $TEST$ no error "A stub file must not declare pipelines or segments." +# $TEST$ no error "A stub file must not declare pipelines or segments." fun »myFunction«() -// $TEST$ no error "A stub file must not declare pipelines or segments." +# $TEST$ no error "A stub file must not declare pipelines or segments." schema »MySchema« {} diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/declarations in test files/everything is allowed (no pipeline errors).sdstest b/packages/ttsl-lang/tests/resources/validation/other/modules/declarations in test files/everything is allowed (no pipeline errors).sdstest index d5fe1da7..5524fd2f 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/declarations in test files/everything is allowed (no pipeline errors).sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/declarations in test files/everything is allowed (no pipeline errors).sdstest @@ -1,33 +1,33 @@ package tests.validation.other.modules.declarationsInTestFiles -// $TEST$ no error "A pipeline file must only declare pipelines and segments." +# $TEST$ no error "A pipeline file must only declare pipelines and segments." annotation »MyAnnotation« -// $TEST$ no error "A pipeline file must only declare pipelines and segments." +# $TEST$ no error "A pipeline file must only declare pipelines and segments." class »MyClass« { - // $TEST$ no error "A pipeline file must only declare pipelines and segments." + # $TEST$ no error "A pipeline file must only declare pipelines and segments." attr »a«: Int - // $TEST$ no error "A pipeline file must only declare pipelines and segments." + # $TEST$ no error "A pipeline file must only declare pipelines and segments." class »MyNestedClass« - // $TEST$ no error "A pipeline file must only declare pipelines and segments." + # $TEST$ no error "A pipeline file must only declare pipelines and segments." enum »MyEnum« - // $TEST$ no error "A pipeline file must only declare pipelines and segments." + # $TEST$ no error "A pipeline file must only declare pipelines and segments." fun »myFunction«() } -// $TEST$ no error "A pipeline file must only declare pipelines and segments." +# $TEST$ no error "A pipeline file must only declare pipelines and segments." enum »MyEnum« { - // $TEST$ no error "A pipeline file must only declare pipelines and segments." + # $TEST$ no error "A pipeline file must only declare pipelines and segments." »MyEnumInstance« } -// $TEST$ no error "A pipeline file must only declare pipelines and segments." +# $TEST$ no error "A pipeline file must only declare pipelines and segments." fun »myFunction«() -// $TEST$ no error "A pipeline file must only declare pipelines and segments." +# $TEST$ no error "A pipeline file must only declare pipelines and segments." schema »MySchema« {} -// $TEST$ no error "A pipeline file must only declare pipelines and segments." +# $TEST$ no error "A pipeline file must only declare pipelines and segments." pipeline »myPipeline« {} -// $TEST$ no error "A pipeline file must only declare pipelines and segments." +# $TEST$ no error "A pipeline file must only declare pipelines and segments." segment »mySegment«() {} diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/declarations in test files/everything is allowed (no stub errors).sdstest b/packages/ttsl-lang/tests/resources/validation/other/modules/declarations in test files/everything is allowed (no stub errors).sdstest index cae23b56..70fa2ca0 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/declarations in test files/everything is allowed (no stub errors).sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/declarations in test files/everything is allowed (no stub errors).sdstest @@ -1,33 +1,33 @@ package tests.validation.other.modules.declarationsInTestFiles -// $TEST$ no error "A stub file must not declare pipelines or segments." +# $TEST$ no error "A stub file must not declare pipelines or segments." pipeline »myPipeline« {} -// $TEST$ no error "A stub file must not declare pipelines or segments." +# $TEST$ no error "A stub file must not declare pipelines or segments." segment »mySegment«() {} -// $TEST$ no error "A stub file must not declare pipelines or segments." +# $TEST$ no error "A stub file must not declare pipelines or segments." annotation »MyAnnotation« -// $TEST$ no error "A stub file must not declare pipelines or segments." +# $TEST$ no error "A stub file must not declare pipelines or segments." class »MyClass« { - // $TEST$ no error "A stub file must not declare pipelines or segments." + # $TEST$ no error "A stub file must not declare pipelines or segments." attr »a«: Int - // $TEST$ no error "A stub file must not declare pipelines or segments." + # $TEST$ no error "A stub file must not declare pipelines or segments." class »MyNestedClass« - // $TEST$ no error "A stub file must not declare pipelines or segments." + # $TEST$ no error "A stub file must not declare pipelines or segments." enum »MyEnum« - // $TEST$ no error "A stub file must not declare pipelines or segments." + # $TEST$ no error "A stub file must not declare pipelines or segments." fun »myFunction«() } -// $TEST$ no error "A stub file must not declare pipelines or segments." +# $TEST$ no error "A stub file must not declare pipelines or segments." enum »MyEnum« { - // $TEST$ no error "A stub file must not declare pipelines or segments." + # $TEST$ no error "A stub file must not declare pipelines or segments." »MyEnumInstance« } -// $TEST$ no error "A stub file must not declare pipelines or segments." +# $TEST$ no error "A stub file must not declare pipelines or segments." fun »myFunction«() -// $TEST$ no error "A stub file must not declare pipelines or segments." +# $TEST$ no error "A stub file must not declare pipelines or segments." schema »MySchema« {} diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (empty).sdspipe b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (empty).sdspipe index 27af28cb..1efef064 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (empty).sdspipe +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (empty).sdspipe @@ -1 +1 @@ -// $TEST$ no error "A module with declarations must state its package." +# $TEST$ no error "A module with declarations must state its package." diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (only annotations).sdspipe b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (only annotations).sdspipe index d78842d9..7583c76e 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (only annotations).sdspipe +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (only annotations).sdspipe @@ -1,3 +1,3 @@ -// $TEST$ no error "A module with declarations must state its package." +# $TEST$ no error "A module with declarations must state its package." @AnnotationCall diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (only imports).sdspipe b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (only imports).sdspipe index d27d113d..15f5d970 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (only imports).sdspipe +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (only imports).sdspipe @@ -1,3 +1,3 @@ -// $TEST$ no error "A module with declarations must state its package." +# $TEST$ no error "A module with declarations must state its package." from myPackage import MyClass diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (with declarations and package).sdspipe b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (with declarations and package).sdspipe index 6f4bf0ff..fd8c0c92 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (with declarations and package).sdspipe +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (with declarations and package).sdspipe @@ -1,7 +1,7 @@ package tests.validation.other.modules.mustStatePackage -// $TEST$ no error "A module with declarations must state its package." +# $TEST$ no error "A module with declarations must state its package." segment »s«() {} -// $TEST$ no error "A module with declarations must state its package." +# $TEST$ no error "A module with declarations must state its package." segment »t«() {} diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (with declarations but no package).sdspipe b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (with declarations but no package).sdspipe index a55723f4..192ad2b2 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (with declarations but no package).sdspipe +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/pipeline file (with declarations but no package).sdspipe @@ -1,5 +1,5 @@ -// $TEST$ error "A module with declarations must state its package." +# $TEST$ error "A module with declarations must state its package." segment »s«() {} -// $TEST$ no error "A module with declarations must state its package." +# $TEST$ no error "A module with declarations must state its package." segment »t«() {} diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (empty).sdsstub b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (empty).sdsstub index 27af28cb..1efef064 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (empty).sdsstub +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (empty).sdsstub @@ -1 +1 @@ -// $TEST$ no error "A module with declarations must state its package." +# $TEST$ no error "A module with declarations must state its package." diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (only annotations).sdsstub b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (only annotations).sdsstub index d78842d9..7583c76e 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (only annotations).sdsstub +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (only annotations).sdsstub @@ -1,3 +1,3 @@ -// $TEST$ no error "A module with declarations must state its package." +# $TEST$ no error "A module with declarations must state its package." @AnnotationCall diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (only imports).sdsstub b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (only imports).sdsstub index d27d113d..15f5d970 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (only imports).sdsstub +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (only imports).sdsstub @@ -1,3 +1,3 @@ -// $TEST$ no error "A module with declarations must state its package." +# $TEST$ no error "A module with declarations must state its package." from myPackage import MyClass diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (with declarations and package).sdsstub b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (with declarations and package).sdsstub index 0a9fbaa5..80ece2d4 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (with declarations and package).sdsstub +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (with declarations and package).sdsstub @@ -1,7 +1,7 @@ package tests.validation.other.modules.mustStatePackage -// $TEST$ no error "A module with declarations must state its package." +# $TEST$ no error "A module with declarations must state its package." class »C« -// $TEST$ no error "A module with declarations must state its package." +# $TEST$ no error "A module with declarations must state its package." class »D« diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (with declarations but no package).sdsstub b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (with declarations but no package).sdsstub index ca0e6e42..1064b7c2 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (with declarations but no package).sdsstub +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/must state package/stub file (with declarations but no package).sdsstub @@ -1,5 +1,5 @@ -// $TEST$ error "A module with declarations must state its package." +# $TEST$ error "A module with declarations must state its package." class »C« -// $TEST$ no error "A module with declarations must state its package." +# $TEST$ no error "A module with declarations must state its package." class »D« diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/pipe elsewhere.sdspipe b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/pipe elsewhere.sdspipe index 80242d68..3252dfef 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/pipe elsewhere.sdspipe +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/pipe elsewhere.sdspipe @@ -1,3 +1,3 @@ -// $TEST$ no error "A pipeline file must not be in a 'TTSL' package." +# $TEST$ no error "A pipeline file must not be in a 'TTSL' package." package »tests.validation.other.modules.pipelineFilesMustNotBeInTTSLPackage« diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/pipe in safeds.sdspipe b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/pipe in safeds.sdspipe index 8a14a9bc..847e5388 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/pipe in safeds.sdspipe +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/pipe in safeds.sdspipe @@ -1,3 +1,3 @@ -// $TEST$ error "A pipeline file must not be in a 'TTSL' package." +# $TEST$ error "A pipeline file must not be in a 'TTSL' package." package »TTSL« diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/pipe in subpackage of safeds.sdspipe b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/pipe in subpackage of safeds.sdspipe index e678a22a..4292cb0d 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/pipe in subpackage of safeds.sdspipe +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/pipe in subpackage of safeds.sdspipe @@ -1,3 +1,3 @@ -// $TEST$ error "A pipeline file must not be in a 'TTSL' package." +# $TEST$ error "A pipeline file must not be in a 'TTSL' package." package »TTSL.validation.other.modules.pipelineFilesMustNotBeInTTSLPackage« diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/stub elsewhere.sdsstub b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/stub elsewhere.sdsstub index 80242d68..3252dfef 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/stub elsewhere.sdsstub +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/stub elsewhere.sdsstub @@ -1,3 +1,3 @@ -// $TEST$ no error "A pipeline file must not be in a 'TTSL' package." +# $TEST$ no error "A pipeline file must not be in a 'TTSL' package." package »tests.validation.other.modules.pipelineFilesMustNotBeInTTSLPackage« diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/stub in safeds.sdsstub b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/stub in safeds.sdsstub index b0110830..30cb34fe 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/stub in safeds.sdsstub +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/stub in safeds.sdsstub @@ -1,3 +1,3 @@ -// $TEST$ no error "A pipeline file must not be in a 'TTSL' package." +# $TEST$ no error "A pipeline file must not be in a 'TTSL' package." package »TTSL« diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/stub in subpackage of safeds.sdsstub b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/stub in subpackage of safeds.sdsstub index 609f3db4..eec21884 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/stub in subpackage of safeds.sdsstub +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/stub in subpackage of safeds.sdsstub @@ -1,3 +1,3 @@ -// $TEST$ no error "A pipeline file must not be in a 'TTSL' package." +# $TEST$ no error "A pipeline file must not be in a 'TTSL' package." package »TTSL.validation.other.modules.pipelineFilesMustNotBeInTTSLPackage« diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/test elsewhere.sdstest b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/test elsewhere.sdstest index 80242d68..3252dfef 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/test elsewhere.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/test elsewhere.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no error "A pipeline file must not be in a 'TTSL' package." +# $TEST$ no error "A pipeline file must not be in a 'TTSL' package." package »tests.validation.other.modules.pipelineFilesMustNotBeInTTSLPackage« diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/test in safeds.sdstest b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/test in safeds.sdstest index b0110830..30cb34fe 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/test in safeds.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/test in safeds.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no error "A pipeline file must not be in a 'TTSL' package." +# $TEST$ no error "A pipeline file must not be in a 'TTSL' package." package »TTSL« diff --git a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/test in subpackage of safeds.sdstest b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/test in subpackage of safeds.sdstest index 609f3db4..eec21884 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/test in subpackage of safeds.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/modules/pipeline files must not be in safeds package/test in subpackage of safeds.sdstest @@ -1,3 +1,3 @@ -// $TEST$ no error "A pipeline file must not be in a 'TTSL' package." +# $TEST$ no error "A pipeline file must not be in a 'TTSL' package." package »TTSL.validation.other.modules.pipelineFilesMustNotBeInTTSLPackage« diff --git a/packages/ttsl-lang/tests/resources/validation/other/statements/assignments/has no effect/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/statements/assignments/has no effect/main.sdstest index 10702000..b6aa8c0f 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/statements/assignments/has no effect/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/statements/assignments/has no effect/main.sdstest @@ -1,29 +1,29 @@ package tests.validation.other.statements.assignments.hasNoEffect segment mySegment() -> a: Int { - // $TEST$ warning "This statement does nothing." + # $TEST$ warning "This statement does nothing." »_ = 1 + 2;« - // $TEST$ no warning "This statement does nothing." + # $TEST$ no warning "This statement does nothing." »val a = 1;« - // $TEST$ no warning "This statement does nothing." + # $TEST$ no warning "This statement does nothing." »yield a = 1;« () { - // $TEST$ warning "This statement does nothing." + # $TEST$ warning "This statement does nothing." »_ = 1 + 2;« - // $TEST$ no warning "This statement does nothing." + # $TEST$ no warning "This statement does nothing." »val a = 1;« - // $TEST$ no warning "This statement does nothing." + # $TEST$ no warning "This statement does nothing." »yield a = 1;« }; } segment mySegment2(f: () -> (r: Int)) { - // $TEST$ no warning "This statement does nothing." + # $TEST$ no warning "This statement does nothing." »_ = f();« - // $TEST$ no warning "This statement does nothing." + # $TEST$ no warning "This statement does nothing." »_ = unresolved();« } diff --git a/packages/ttsl-lang/tests/resources/validation/other/statements/assignments/implicitly ignore result/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/statements/assignments/implicitly ignore result/main.sdstest index 1747c2f1..710ba5d6 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/statements/assignments/implicitly ignore result/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/statements/assignments/implicitly ignore result/main.sdstest @@ -11,42 +11,42 @@ enum MyEnum { MyEnumVariant } -pipeline myPipeline { - // $TEST$ warning "The assignment implicitly ignores the result 'second'." +function myFunction () { + # $TEST$ warning "The assignment implicitly ignores the result 'second'." »_ = twoResults();« - // $TEST$ warning "The assignment implicitly ignores the results 'second', 'third'." + # $TEST$ warning "The assignment implicitly ignores the results 'second', 'third'." »_ = threeResults();« - // $TEST$ no warning r"The assignment implicitly ignores the result\.*" + # $TEST$ no warning r"The assignment implicitly ignores the result\.*" »_ = oneResult();« - // $TEST$ no warning r"The assignment implicitly ignores the result\.*" + # $TEST$ no warning r"The assignment implicitly ignores the result\.*" »_, _ = twoResults();« - // $TEST$ no warning r"The assignment implicitly ignores the result\.*" + # $TEST$ no warning r"The assignment implicitly ignores the result\.*" »_, _, _ = threeResults();« - // $TEST$ no warning r"The assignment implicitly ignores the result\.*" + # $TEST$ no warning r"The assignment implicitly ignores the result\.*" »_ = MyClass();« - // $TEST$ no warning r"The assignment implicitly ignores the result\.*" + # $TEST$ no warning r"The assignment implicitly ignores the result\.*" »_ = MyEnum.MyEnumVariant();« - // $TEST$ no warning r"The assignment implicitly ignores the result\.*" + # $TEST$ no warning r"The assignment implicitly ignores the result\.*" »_ = 1;« - // $TEST$ no warning r"The assignment implicitly ignores the result\.*" + # $TEST$ no warning r"The assignment implicitly ignores the result\.*" »_ = noResults();« - // $TEST$ no warning r"The assignment implicitly ignores the result\.*" + # $TEST$ no warning r"The assignment implicitly ignores the result\.*" »_, _ = oneResult();« - // $TEST$ no warning r"The assignment implicitly ignores the result\.*" + # $TEST$ no warning r"The assignment implicitly ignores the result\.*" »_, _, _ = twoResults();« - // $TEST$ no warning r"The assignment implicitly ignores the result\.*" + # $TEST$ no warning r"The assignment implicitly ignores the result\.*" »_, _, _, _ = threeResults();« - // $TEST$ no warning r"The assignment implicitly ignores the result\.*" + # $TEST$ no warning r"The assignment implicitly ignores the result\.*" »_, _ = MyClass();« - // $TEST$ no warning r"The assignment implicitly ignores the result\.*" + # $TEST$ no warning r"The assignment implicitly ignores the result\.*" »_, _ = MyEnum.MyEnumVariant();« - // $TEST$ no warning r"The assignment implicitly ignores the result\.*" + # $TEST$ no warning r"The assignment implicitly ignores the result\.*" »_, _ = 1;« - // $TEST$ no warning r"The assignment implicitly ignores the result\.*" + # $TEST$ no warning r"The assignment implicitly ignores the result\.*" »_ = unresolved;« - // $TEST$ no warning r"The assignment implicitly ignores the result\.*" + # $TEST$ no warning r"The assignment implicitly ignores the result\.*" »_ = unresolved();« } diff --git a/packages/ttsl-lang/tests/resources/validation/other/statements/assignments/nothing assigned/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/statements/assignments/nothing assigned/main.sdstest index c0c6a2be..3c04d43a 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/statements/assignments/nothing assigned/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/statements/assignments/nothing assigned/main.sdstest @@ -26,78 +26,78 @@ segment mySegment() -> ( r13: Any?, r14: Any?, ) { - // $TEST$ error "No value is assigned to this assignee." + # $TEST$ error "No value is assigned to this assignee." »_« = noResults(); - // $TEST$ no error "No value is assigned to this assignee." - // $TEST$ error "No value is assigned to this assignee." + # $TEST$ no error "No value is assigned to this assignee." + # $TEST$ error "No value is assigned to this assignee." »_«, »_« = oneResult(); - // $TEST$ no error "No value is assigned to this assignee." - // $TEST$ no error "No value is assigned to this assignee." - // $TEST$ error "No value is assigned to this assignee." + # $TEST$ no error "No value is assigned to this assignee." + # $TEST$ no error "No value is assigned to this assignee." + # $TEST$ error "No value is assigned to this assignee." »_«, »_«, »_« = twoResults(); - // $TEST$ no error "No value is assigned to this assignee." - // $TEST$ error "No value is assigned to this assignee." + # $TEST$ no error "No value is assigned to this assignee." + # $TEST$ error "No value is assigned to this assignee." »_«, »_« = MyClass(); - // $TEST$ no error "No value is assigned to this assignee." - // $TEST$ error "No value is assigned to this assignee." + # $TEST$ no error "No value is assigned to this assignee." + # $TEST$ error "No value is assigned to this assignee." »_«, »_« = MyEnum.MyEnumVariant(); - // $TEST$ no error "No value is assigned to this assignee." - // $TEST$ error "No value is assigned to this assignee." + # $TEST$ no error "No value is assigned to this assignee." + # $TEST$ error "No value is assigned to this assignee." »_«, »_« = 1; - // $TEST$ no error "No value is assigned to this assignee." - // $TEST$ error "No value is assigned to this assignee." + # $TEST$ no error "No value is assigned to this assignee." + # $TEST$ error "No value is assigned to this assignee." »_«, »_« = unresolved; - // $TEST$ error "No value is assigned to this assignee." - // $TEST$ error "No value is assigned to this assignee." + # $TEST$ error "No value is assigned to this assignee." + # $TEST$ error "No value is assigned to this assignee." »_«, »_« = unresolved(); - // $TEST$ error "No value is assigned to this assignee." + # $TEST$ error "No value is assigned to this assignee." »val a« = noResults(); - // $TEST$ no error "No value is assigned to this assignee." - // $TEST$ error "No value is assigned to this assignee." + # $TEST$ no error "No value is assigned to this assignee." + # $TEST$ error "No value is assigned to this assignee." »val b«, »val c« = oneResult(); - // $TEST$ no error "No value is assigned to this assignee." - // $TEST$ no error "No value is assigned to this assignee." - // $TEST$ error "No value is assigned to this assignee." + # $TEST$ no error "No value is assigned to this assignee." + # $TEST$ no error "No value is assigned to this assignee." + # $TEST$ error "No value is assigned to this assignee." »val d«, »val e«, »val f« = twoResults(); - // $TEST$ no error "No value is assigned to this assignee." - // $TEST$ error "No value is assigned to this assignee." + # $TEST$ no error "No value is assigned to this assignee." + # $TEST$ error "No value is assigned to this assignee." »val g«, »val h« = MyClass(); - // $TEST$ no error "No value is assigned to this assignee." - // $TEST$ error "No value is assigned to this assignee." + # $TEST$ no error "No value is assigned to this assignee." + # $TEST$ error "No value is assigned to this assignee." »val i«, »val j« = MyEnum.MyEnumVariant(); - // $TEST$ no error "No value is assigned to this assignee." - // $TEST$ error "No value is assigned to this assignee." + # $TEST$ no error "No value is assigned to this assignee." + # $TEST$ error "No value is assigned to this assignee." »val k«, »val l« = 1; - // $TEST$ no error "No value is assigned to this assignee." - // $TEST$ error "No value is assigned to this assignee." + # $TEST$ no error "No value is assigned to this assignee." + # $TEST$ error "No value is assigned to this assignee." »val m«, »val n« = unresolved; - // $TEST$ error "No value is assigned to this assignee." - // $TEST$ error "No value is assigned to this assignee." + # $TEST$ error "No value is assigned to this assignee." + # $TEST$ error "No value is assigned to this assignee." »val o«, »val p« = unresolved(); - // $TEST$ error "No value is assigned to this assignee." + # $TEST$ error "No value is assigned to this assignee." »yield r1« = noResults(); - // $TEST$ no error "No value is assigned to this assignee." - // $TEST$ error "No value is assigned to this assignee." + # $TEST$ no error "No value is assigned to this assignee." + # $TEST$ error "No value is assigned to this assignee." »yield r2«, »yield r3« = oneResult(); - // $TEST$ no error "No value is assigned to this assignee." - // $TEST$ no error "No value is assigned to this assignee." - // $TEST$ error "No value is assigned to this assignee." + # $TEST$ no error "No value is assigned to this assignee." + # $TEST$ no error "No value is assigned to this assignee." + # $TEST$ error "No value is assigned to this assignee." »yield r4«, »yield r5«, »yield r6« = twoResults(); - // $TEST$ no error "No value is assigned to this assignee." - // $TEST$ error "No value is assigned to this assignee." + # $TEST$ no error "No value is assigned to this assignee." + # $TEST$ error "No value is assigned to this assignee." »yield r7«, »yield r8« = MyClass(); - // $TEST$ no error "No value is assigned to this assignee." - // $TEST$ error "No value is assigned to this assignee." + # $TEST$ no error "No value is assigned to this assignee." + # $TEST$ error "No value is assigned to this assignee." »yield r9«, »yield r10« = MyEnum.MyEnumVariant(); - // $TEST$ no error "No value is assigned to this assignee." - // $TEST$ error "No value is assigned to this assignee." + # $TEST$ no error "No value is assigned to this assignee." + # $TEST$ error "No value is assigned to this assignee." »yield r11«, »yield r12« = 1; - // $TEST$ no error "No value is assigned to this assignee." - // $TEST$ error "No value is assigned to this assignee." + # $TEST$ no error "No value is assigned to this assignee." + # $TEST$ error "No value is assigned to this assignee." »yield r13«, »yield r14« = unresolved; - // $TEST$ error "No value is assigned to this assignee." - // $TEST$ error "No value is assigned to this assignee." + # $TEST$ error "No value is assigned to this assignee." + # $TEST$ error "No value is assigned to this assignee." »yield r15«, »yield r16« = unresolved(); } diff --git a/packages/ttsl-lang/tests/resources/validation/other/statements/assignments/yield forbidden in pipeline/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/statements/assignments/yield forbidden in pipeline/main.sdstest index 95bc46e8..d865f0be 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/statements/assignments/yield forbidden in pipeline/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/statements/assignments/yield forbidden in pipeline/main.sdstest @@ -1,16 +1,16 @@ package tests.validation.other.statements.assignments.yieldForbiddenInPipeline segment s() { - // $TEST$ no error "Yield must not be used in a pipeline." + # $TEST$ no error "Yield must not be used in a pipeline." »yield a« = 1; } pipeline p { - // $TEST$ error "Yield must not be used in a pipeline." + # $TEST$ error "Yield must not be used in a pipeline." »yield a« = 1; () { - // $TEST$ no error "Yield must not be used in a pipeline." + # $TEST$ no error "Yield must not be used in a pipeline." »yield a« = 1; }; } diff --git a/packages/ttsl-lang/tests/resources/validation/other/statements/expression statements/has no effect/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/statements/expression statements/has no effect/main.sdstest index 5dcf20fe..c72c2b3d 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/statements/expression statements/has no effect/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/statements/expression statements/has no effect/main.sdstest @@ -30,62 +30,62 @@ segment recursiveB() { } segment mySegment() { - // $TEST$ warning "This statement does nothing." + # $TEST$ warning "This statement does nothing." »1 + 2;« - // $TEST$ warning "This statement does nothing." + # $TEST$ warning "This statement does nothing." »pureFunction();« - // $TEST$ warning "This statement does nothing." + # $TEST$ warning "This statement does nothing." »MyClass().pureFunction();« - // $TEST$ no warning "This statement does nothing." + # $TEST$ no warning "This statement does nothing." »impureFunction();« - // $TEST$ no warning "This statement does nothing." + # $TEST$ no warning "This statement does nothing." »MyClass().impureFunction();« () { - // $TEST$ warning "This statement does nothing." + # $TEST$ warning "This statement does nothing." »1 + 2;« - // $TEST$ warning "This statement does nothing." + # $TEST$ warning "This statement does nothing." »pureFunction();« - // $TEST$ warning "This statement does nothing." + # $TEST$ warning "This statement does nothing." »MyClass().pureFunction();« - // $TEST$ no warning "This statement does nothing." + # $TEST$ no warning "This statement does nothing." »impureFunction();« - // $TEST$ no warning "This statement does nothing." + # $TEST$ no warning "This statement does nothing." »MyClass().impureFunction();« }; - // $TEST$ warning "This statement does nothing." + # $TEST$ warning "This statement does nothing." »pureSegment();« - // $TEST$ no warning "This statement does nothing." + # $TEST$ no warning "This statement does nothing." »impureSegment();« - // $TEST$ warning "This statement does nothing." + # $TEST$ warning "This statement does nothing." »(() { pureFunction(); MyClass().pureFunction(); })();« - // $TEST$ no warning "This statement does nothing." + # $TEST$ no warning "This statement does nothing." »(() { impureFunction(); })();« - // $TEST$ no warning "This statement does nothing." + # $TEST$ no warning "This statement does nothing." »(() { MyClass().impureFunction(); })();« - // $TEST$ no warning "This statement does nothing." + # $TEST$ no warning "This statement does nothing." »recursiveA();« } segment mySegment2(f: () -> (r: Int)) { - // $TEST$ no warning "This statement does nothing." + # $TEST$ no warning "This statement does nothing." »f();« - // $TEST$ no warning "This statement does nothing." + # $TEST$ no warning "This statement does nothing." »unresolved();« } diff --git a/packages/ttsl-lang/tests/resources/validation/other/types/callable types/context/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/types/callable types/context/main.sdstest index b166586e..9f2b929c 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/types/callable types/context/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/types/callable types/context/main.sdstest @@ -1,68 +1,68 @@ package tests.validation.other.types.callableTypes.context annotation MyAnnotation( - // $TEST$ no error "Callable types must only be used for parameters." + # $TEST$ no error "Callable types must only be used for parameters." p: »() -> ()«, ) class MyClass( - // $TEST$ no error "Callable types must only be used for parameters." + # $TEST$ no error "Callable types must only be used for parameters." p: »() -> ()«, ) { - // $TEST$ error "Callable types must only be used for parameters." + # $TEST$ error "Callable types must only be used for parameters." attr a: »() -> ()« } enum MyEnum { MyEnumVariant( - // $TEST$ no error "Callable types must only be used for parameters." + # $TEST$ no error "Callable types must only be used for parameters." p: »() -> ()«, ) } fun myFunction( - // $TEST$ no error "Callable types must only be used for parameters." + # $TEST$ no error "Callable types must only be used for parameters." p: »() -> ()«, ) -> ( - // $TEST$ error "Callable types must only be used for parameters." + # $TEST$ error "Callable types must only be used for parameters." r: »() -> ()«, ) segment mySegment1( - // $TEST$ no error "Callable types must only be used for parameters." + # $TEST$ no error "Callable types must only be used for parameters." p: »() -> ()«, ) -> ( - // $TEST$ error "Callable types must only be used for parameters." + # $TEST$ error "Callable types must only be used for parameters." r: »() -> ()«, ) {} segment mySegment2( - // $TEST$ no error "Callable types must only be used for parameters." - // $TEST$ error "Callable types must only be used for parameters." + # $TEST$ no error "Callable types must only be used for parameters." + # $TEST$ error "Callable types must only be used for parameters." c: (p: »() -> ()«) -> (r: »() -> ()«), ) { - // $TEST$ no error "Callable types must only be used for parameters." + # $TEST$ no error "Callable types must only be used for parameters." ( p: »() -> ()«, ) {}; - // $TEST$ no error "Callable types must only be used for parameters." + # $TEST$ no error "Callable types must only be used for parameters." ( p: »() -> ()«, ) -> 1; } segment mySegment3( - // $TEST$ error "Callable types must only be used for parameters." + # $TEST$ error "Callable types must only be used for parameters." p1: MyClass<»() -> ()«>, ) {} segment mySegment4( - // $TEST$ error "Callable types must only be used for parameters." + # $TEST$ error "Callable types must only be used for parameters." p1: »() -> ()«.MyClass ) {} segment mySegment5( - // $TEST$ error "Callable types must only be used for parameters." + # $TEST$ error "Callable types must only be used for parameters." p1: union<»() -> ()«> ) {} diff --git a/packages/ttsl-lang/tests/resources/validation/other/types/callable types/context/nested.sdstest b/packages/ttsl-lang/tests/resources/validation/other/types/callable types/context/nested.sdstest index 3389e2ac..6add3efd 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/types/callable types/context/nested.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/types/callable types/context/nested.sdstest @@ -5,12 +5,12 @@ package tests.validation.other.types.callableTypes.context */ class MyClass1 { - // $TEST$ no error "Callable types must only be used for parameters." + # $TEST$ no error "Callable types must only be used for parameters." attr a: () -> (r: »() -> ()«) } class MyClass2 { - // $TEST$ no error "Callable types must only be used for parameters." - // $TEST$ no error "Callable types must only be used for parameters." + # $TEST$ no error "Callable types must only be used for parameters." + # $TEST$ no error "Callable types must only be used for parameters." attr a: () -> (r: (p: »() -> ()«) -> (r: »() -> ()«)) } diff --git a/packages/ttsl-lang/tests/resources/validation/other/types/callable types/must not have optional parameters/optional.sdstest b/packages/ttsl-lang/tests/resources/validation/other/types/callable types/must not have optional parameters/optional.sdstest index b7e13798..8ce5ad98 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/types/callable types/must not have optional parameters/optional.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/types/callable types/must not have optional parameters/optional.sdstest @@ -2,7 +2,7 @@ package tests.validation.other.types.callableTypes.mustNotHaveOptionalParameters fun f( g: ( - // $TEST$ error "A callable type must not have optional parameters." + # $TEST$ error "A callable type must not have optional parameters." p: Int = »1«, ) -> () ) diff --git a/packages/ttsl-lang/tests/resources/validation/other/types/callable types/must not have optional parameters/required.sdstest b/packages/ttsl-lang/tests/resources/validation/other/types/callable types/must not have optional parameters/required.sdstest index a70ae8c0..68c4f378 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/types/callable types/must not have optional parameters/required.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/types/callable types/must not have optional parameters/required.sdstest @@ -2,7 +2,7 @@ package tests.validation.other.types.callableTypes.mustNotHaveOptionalParameters fun f( g: ( - // $TEST$ no error "A callable type must not have optional parameters." + # $TEST$ no error "A callable type must not have optional parameters." p: Int, ) -> () ) diff --git a/packages/ttsl-lang/tests/resources/validation/other/types/literal types/duplicate literals/empty list.sdstest b/packages/ttsl-lang/tests/resources/validation/other/types/literal types/duplicate literals/empty list.sdstest index ad8a0237..ca1f7cdc 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/types/literal types/duplicate literals/empty list.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/types/literal types/duplicate literals/empty list.sdstest @@ -1,6 +1,6 @@ package tests.validation.other.types.literalTypes.duplicateLiterals -// $TEST$ no warning r"The literal .* was already listed." +# $TEST$ no warning r"The literal .* was already listed." segment mySegment1( p: literal<> diff --git a/packages/ttsl-lang/tests/resources/validation/other/types/literal types/duplicate literals/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/types/literal types/duplicate literals/main.sdstest index 7ecff256..31457305 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/types/literal types/duplicate literals/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/types/literal types/duplicate literals/main.sdstest @@ -1,14 +1,14 @@ package tests.validation.other.types.literalTypes.duplicateLiterals segment mySegment( - // $TEST$ no warning r"The literal .* was already listed." + # $TEST$ no warning r"The literal .* was already listed." p: literal<»1«>, q: literal< - // $TEST$ no warning r"The literal .* was already listed." + # $TEST$ no warning r"The literal .* was already listed." »1«, - // $TEST$ no warning r"The literal .* was already listed." + # $TEST$ no warning r"The literal .* was already listed." »2«, - // $TEST$ warning r"The literal 1 was already listed." + # $TEST$ warning r"The literal 1 was already listed." »1«, >, ) {} diff --git a/packages/ttsl-lang/tests/resources/validation/other/types/literal types/must have literals/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/types/literal types/must have literals/main.sdstest index e93a113f..89d7492e 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/types/literal types/must have literals/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/types/literal types/must have literals/main.sdstest @@ -1,16 +1,16 @@ package tests.validation.other.types.literalTypes.mustHaveLiterals -// $TEST$ error "A literal type must have at least one literal." +# $TEST$ error "A literal type must have at least one literal." segment mySegment1( p: literal»<>« ) {} -// $TEST$ no error "A literal type must have at least one literal." +# $TEST$ no error "A literal type must have at least one literal." segment mySegment2( p: literal»<1>« ) {} -// $TEST$ no error "A literal type must have at least one literal." +# $TEST$ no error "A literal type must have at least one literal." segment mySegment3( p: literal»<1, "">« ) {} diff --git a/packages/ttsl-lang/tests/resources/validation/other/types/literal types/must not contain list literals/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/types/literal types/must not contain list literals/main.sdstest index d0e6cae7..356e8edd 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/types/literal types/must not contain list literals/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/types/literal types/must not contain list literals/main.sdstest @@ -1,6 +1,6 @@ package tests.validation.other.types.literalTypes.mustNotContanListLiterals -// $TEST$ error "Literal types must not contain list literals." +# $TEST$ error "Literal types must not contain list literals." segment mySegment( x: literal<»[]«> ) {} diff --git a/packages/ttsl-lang/tests/resources/validation/other/types/literal types/must not contain map literals/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/types/literal types/must not contain map literals/main.sdstest index 08bdf73f..e4acfaa9 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/types/literal types/must not contain map literals/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/types/literal types/must not contain map literals/main.sdstest @@ -1,6 +1,6 @@ package tests.validation.other.types.literalsTypes.mustNotContainMapLiterals -// $TEST$ error "Literal types must not contain map literals." +# $TEST$ error "Literal types must not contain map literals." segment mySegment( x: literal<»{}«> ) {} diff --git a/packages/ttsl-lang/tests/resources/validation/other/types/type argument lists/duplicate type parameter/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/types/type argument lists/duplicate type parameter/main.sdstest index 0cbf53fe..2bae294e 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/types/type argument lists/duplicate type parameter/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/types/type argument lists/duplicate type parameter/main.sdstest @@ -4,33 +4,33 @@ class MyClass fun myFunction( f: MyClass< - // $TEST$ no error r"The type parameter '\w+' is already set\." + # $TEST$ no error r"The type parameter '\w+' is already set\." »Int«, - // $TEST$ error "The type parameter 'A' is already set." + # $TEST$ error "The type parameter 'A' is already set." »A = Int« >, g: MyClass< - // $TEST$ no error r"The type parameter '\w+' is already set\." + # $TEST$ no error r"The type parameter '\w+' is already set\." »B = Int«, - // $TEST$ error "The type parameter 'B' is already set." + # $TEST$ error "The type parameter 'B' is already set." »B = Int« >, h: MyClass< - // $TEST$ no error r"The type parameter '\w+' is already set\." + # $TEST$ no error r"The type parameter '\w+' is already set\." »A = Int«, - // $TEST$ no error r"The type parameter '\w+' is already set\." + # $TEST$ no error r"The type parameter '\w+' is already set\." »B = Int« >, i: MyClass< - // $TEST$ no error r"The type parameter '\w+' is already set\." + # $TEST$ no error r"The type parameter '\w+' is already set\." »Int«, - // $TEST$ no error r"The type parameter '\w+' is already set\." + # $TEST$ no error r"The type parameter '\w+' is already set\." »Int« >, j: MyClass< - // $TEST$ no error r"The type parameter '\w+' is already set\." + # $TEST$ no error r"The type parameter '\w+' is already set\." »Unresolved = Int«, - // $TEST$ no error r"The type parameter '\w+' is already set\." + # $TEST$ no error r"The type parameter '\w+' is already set\." »Unresolved = Int« > ) diff --git a/packages/ttsl-lang/tests/resources/validation/other/types/type argument lists/must not have positional type argument after named type argument/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/types/type argument lists/must not have positional type argument after named type argument/main.sdstest index c6237952..eb18a08a 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/types/type argument lists/must not have positional type argument after named type argument/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/types/type argument lists/must not have positional type argument after named type argument/main.sdstest @@ -1,19 +1,19 @@ package tests.validation.other.types.typeArgumentLists.mustNotHavePositionalTypeArgumentAfterNamedTypeArgument -// $TEST$ no error "After the first named type argument all type arguments must be named." -// $TEST$ no error "After the first named type argument all type arguments must be named." -// $TEST$ error "After the first named type argument all type arguments must be named." -// $TEST$ no error "After the first named type argument all type arguments must be named." +# $TEST$ no error "After the first named type argument all type arguments must be named." +# $TEST$ no error "After the first named type argument all type arguments must be named." +# $TEST$ error "After the first named type argument all type arguments must be named." +# $TEST$ no error "After the first named type argument all type arguments must be named." segment mySegment1( f: MyClass<»Int«, »A = Int«, »Int«, »B = Int«> ) {} -// $TEST$ no error "After the first named type argument all type arguments must be named." +# $TEST$ no error "After the first named type argument all type arguments must be named." segment mySegment2( f: MyClass<»Int«> ) {} -// $TEST$ no error "After the first named type argument all type arguments must be named." +# $TEST$ no error "After the first named type argument all type arguments must be named." segment mySegment2( f: MyClass<»A = Int«> ) {} diff --git a/packages/ttsl-lang/tests/resources/validation/other/types/type argument lists/too many type arguments/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/types/type argument lists/too many type arguments/main.sdstest index 564e9add..f7f7fc7b 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/types/type argument lists/too many type arguments/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/types/type argument lists/too many type arguments/main.sdstest @@ -5,16 +5,16 @@ class MyClass2 class MyClass3 fun myFunction( - // $TEST$ no error r"Expected .* type arguments? but got \d*\." + # $TEST$ no error r"Expected .* type arguments? but got \d*\." a: MyClass1»<>«, - // $TEST$ no error r"Expected .* type arguments? but got \d*\." + # $TEST$ no error r"Expected .* type arguments? but got \d*\." b: MyClass1»«, - // $TEST$ error "Expected exactly 1 type argument but got 2." + # $TEST$ error "Expected exactly 1 type argument but got 2." c: MyClass1»«, - // $TEST$ error "Expected exactly 2 type arguments but got 3." + # $TEST$ error "Expected exactly 2 type arguments but got 3." d: MyClass2»«, - // $TEST$ error "Expected between 1 and 2 type arguments but got 3." + # $TEST$ error "Expected between 1 and 2 type arguments but got 3." f: MyClass3»«, - // $TEST$ no error r"Expected .* type arguments? but got \d*\." + # $TEST$ no error r"Expected .* type arguments? but got \d*\." g: Unresolved»« ) diff --git a/packages/ttsl-lang/tests/resources/validation/other/types/union types/context/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/types/union types/context/main.sdstest index 1060fd99..a0585788 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/types/union types/context/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/types/union types/context/main.sdstest @@ -1,63 +1,63 @@ package tests.validation.other.types.unionTypes.context annotation MyAnnotation( - // $TEST$ no error "Union types must only be used for parameters of annotations, classes, and functions." + # $TEST$ no error "Union types must only be used for parameters of annotations, classes, and functions." p: »union«, ) class MyClass( - // $TEST$ no error "Union types must only be used for parameters of annotations, classes, and functions." + # $TEST$ no error "Union types must only be used for parameters of annotations, classes, and functions." p: »union«, ) { - // $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." + # $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." attr a: »union« } enum MyEnum { MyEnumVariant( - // $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." + # $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." p: »union«, ) } fun myFunction( - // $TEST$ no error "Union types must only be used for parameters of annotations, classes, and functions." + # $TEST$ no error "Union types must only be used for parameters of annotations, classes, and functions." p: »union«, ) -> ( - // $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." + # $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." r: »union«, ) segment mySegment1( - // $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." + # $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." p: »union«, ) -> ( - // $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." + # $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." r: »union«, ) {} segment mySegment2( - // $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." - // $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." + # $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." + # $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." c: (p: »union«) -> (r: »union«), ) { - // $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." + # $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." ( p: »union«, ) {}; - // $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." + # $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." ( p: »union«, ) -> 1; } segment mySegment3( - // $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." + # $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." p1: MyClass<»union«>, ) {} segment mySegment4( - // $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." + # $TEST$ error "Union types must only be used for parameters of annotations, classes, and functions." p1: »union«.MyClass ) {} diff --git a/packages/ttsl-lang/tests/resources/validation/other/types/union types/context/nested.sdstest b/packages/ttsl-lang/tests/resources/validation/other/types/union types/context/nested.sdstest index 3c0707f3..5bc12c76 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/types/union types/context/nested.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/types/union types/context/nested.sdstest @@ -5,12 +5,12 @@ package tests.validation.other.types.unionTypes.context */ class MyClass1 { - // $TEST$ no error "Union types must only be used for parameters of annotations, classes, and functions." + # $TEST$ no error "Union types must only be used for parameters of annotations, classes, and functions." attr a: union«> } class MyClass2 { - // $TEST$ no error "Union types must only be used for parameters of annotations, classes, and functions." - // $TEST$ no error "Union types must only be used for parameters of annotations, classes, and functions." + # $TEST$ no error "Union types must only be used for parameters of annotations, classes, and functions." + # $TEST$ no error "Union types must only be used for parameters of annotations, classes, and functions." attr a: union«) -> (r: »union«)> } diff --git a/packages/ttsl-lang/tests/resources/validation/other/types/union types/duplicate types/empty list.sdstest b/packages/ttsl-lang/tests/resources/validation/other/types/union types/duplicate types/empty list.sdstest index cd81b4d1..26ee335b 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/types/union types/duplicate types/empty list.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/types/union types/duplicate types/empty list.sdstest @@ -1,6 +1,6 @@ package tests.validation.other.types.unionTypes.duplicateTypes -// $TEST$ no warning r"The type .* was already listed." +# $TEST$ no warning r"The type .* was already listed." fun myFunction1( p: union<> diff --git a/packages/ttsl-lang/tests/resources/validation/other/types/union types/duplicate types/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/types/union types/duplicate types/main.sdstest index bc3931b9..64dd8e67 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/types/union types/duplicate types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/types/union types/duplicate types/main.sdstest @@ -1,14 +1,14 @@ package tests.validation.other.types.unionTypes.duplicateTypes fun myFunction2( - // $TEST$ no warning r"The type .* was already listed." + # $TEST$ no warning r"The type .* was already listed." p: union<»Int«>, q: union< - // $TEST$ no warning r"The type .* was already listed." + # $TEST$ no warning r"The type .* was already listed." »Int«, - // $TEST$ no warning r"The type .* was already listed." + # $TEST$ no warning r"The type .* was already listed." »String«, - // $TEST$ warning r"The type 'Int' was already listed." + # $TEST$ warning r"The type 'Int' was already listed." »Int«, >, ) diff --git a/packages/ttsl-lang/tests/resources/validation/other/types/union types/must have types/main.sdstest b/packages/ttsl-lang/tests/resources/validation/other/types/union types/must have types/main.sdstest index b4779c26..3268a912 100644 --- a/packages/ttsl-lang/tests/resources/validation/other/types/union types/must have types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/other/types/union types/must have types/main.sdstest @@ -1,16 +1,16 @@ package tests.validation.other.types.unionTypes.mustHaveTypes -// $TEST$ error "A union type must have at least one type." +# $TEST$ error "A union type must have at least one type." fun myFunction1( p: union»<>« ) -// $TEST$ no error "A union type must have at least one type." +# $TEST$ no error "A union type must have at least one type." fun myFunction2( p: union»« ) -// $TEST$ no error "A union type must have at least one type." +# $TEST$ no error "A union type must have at least one type." fun myFunction3( p: union»« ) diff --git a/packages/ttsl-lang/tests/resources/validation/purity/duplicate impurity reason/main.sdstest b/packages/ttsl-lang/tests/resources/validation/purity/duplicate impurity reason/main.sdstest index 6a90b3b0..d7c09504 100644 --- a/packages/ttsl-lang/tests/resources/validation/purity/duplicate impurity reason/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/purity/duplicate impurity reason/main.sdstest @@ -1,7 +1,7 @@ package tests.validation.purity.duplicateImpurityReason @Impure([ - // $TEST$ no warning r"The impurity reason '.*' was set already\." + # $TEST$ no warning r"The impurity reason '.*' was set already\." »ImpurityReason.FileReadFromConstantPath("text.txt")« ]) @@ -10,33 +10,33 @@ package tests.validation.purity.duplicateImpurityReason */ @Impure([ - // $TEST$ no warning r"The impurity reason '.*' was set already\." + # $TEST$ no warning r"The impurity reason '.*' was set already\." »ImpurityReason.FileReadFromConstantPath("text.txt")«, - // $TEST$ no warning r"The impurity reason '.*' was set already\." + # $TEST$ no warning r"The impurity reason '.*' was set already\." »ImpurityReason.FileReadFromConstantPath("text.txt")«, ]) fun testFunction1() @Impure([ - // $TEST$ no warning r"The impurity reason '.*' was set already\." + # $TEST$ no warning r"The impurity reason '.*' was set already\." »ImpurityReason.FileReadFromConstantPath("text.txt")«, - // $TEST$ warning "The impurity reason 'FileReadFromConstantPath(path = "text.txt")' was set already." + # $TEST$ warning "The impurity reason 'FileReadFromConstantPath(path = "text.txt")' was set already." »ImpurityReason.FileReadFromConstantPath("text.txt")«, ]) fun testFunction2() @Impure([ - // $TEST$ no warning r"The impurity reason '.*' was set already\." + # $TEST$ no warning r"The impurity reason '.*' was set already\." »ImpurityReason.FileWriteToConstantPath("text.txt")«, - // $TEST$ warning "The impurity reason 'FileWriteToConstantPath(path = "text.txt")' was set already." + # $TEST$ warning "The impurity reason 'FileWriteToConstantPath(path = "text.txt")' was set already." »ImpurityReason.FileWriteToConstantPath("text.txt")«, - // $TEST$ warning "The impurity reason 'FileWriteToConstantPath(path = "text.txt")' was set already." + # $TEST$ warning "The impurity reason 'FileWriteToConstantPath(path = "text.txt")' was set already." »ImpurityReason.FileWriteToConstantPath("text.txt")«, - // $TEST$ no warning r"The impurity reason '.*' was set already\." + # $TEST$ no warning r"The impurity reason '.*' was set already\." »ImpurityReason.FileReadFromConstantPath("text.txt")«, - // $TEST$ warning "The impurity reason 'FileReadFromConstantPath(path = "text.txt")' was set already." + # $TEST$ warning "The impurity reason 'FileReadFromConstantPath(path = "text.txt")' was set already." »ImpurityReason.FileReadFromConstantPath("text.txt")«, - // $TEST$ warning "The impurity reason 'FileReadFromConstantPath(path = "text.txt")' was set already." + # $TEST$ warning "The impurity reason 'FileReadFromConstantPath(path = "text.txt")' was set already." »ImpurityReason.FileReadFromConstantPath("text.txt")«, ]) fun testFunction3() @@ -46,17 +46,17 @@ fun testFunction3() */ @Impure( - // $TEST$ no warning r"The impurity reason '.*' was set already\." + # $TEST$ no warning r"The impurity reason '.*' was set already\." »ImpurityReason.FileWriteToConstantPath("text.txt")«, - // $TEST$ no warning r"The impurity reason '.*' was set already\." + # $TEST$ no warning r"The impurity reason '.*' was set already\." »ImpurityReason.FileWriteToConstantPath("text.txt")« ) fun testFunction4() @Impure([ - // $TEST$ no warning r"The impurity reason '.*' was set already\." + # $TEST$ no warning r"The impurity reason '.*' was set already\." »1«, - // $TEST$ no warning r"The impurity reason '.*' was set already\." + # $TEST$ no warning r"The impurity reason '.*' was set already\." »1«, ]) fun testFunction5() diff --git a/packages/ttsl-lang/tests/resources/validation/purity/duplicate impurity reason/no impure annotation.sdstest b/packages/ttsl-lang/tests/resources/validation/purity/duplicate impurity reason/no impure annotation.sdstest index 524b60ec..d48711b8 100644 --- a/packages/ttsl-lang/tests/resources/validation/purity/duplicate impurity reason/no impure annotation.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/purity/duplicate impurity reason/no impure annotation.sdstest @@ -1,5 +1,5 @@ package tests.validation.purity.duplicateImpurityReason -// $TEST$ no warning r"The impurity reason '.*' was set already\." +# $TEST$ no warning r"The impurity reason '.*' was set already\." fun testFunction6() diff --git a/packages/ttsl-lang/tests/resources/validation/purity/impure callable passed to pure parameter/arguments.sdstest b/packages/ttsl-lang/tests/resources/validation/purity/impure callable passed to pure parameter/arguments.sdstest index 1be44b86..72380413 100644 --- a/packages/ttsl-lang/tests/resources/validation/purity/impure callable passed to pure parameter/arguments.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/purity/impure callable passed to pure parameter/arguments.sdstest @@ -53,68 +53,68 @@ segment mySegment2( other: Int = 1, ) -> 1; - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." MyAnnotation(»pureFunction«, »pureFunction«); - // $TEST$ error "Cannot pass an impure callable to a pure parameter." - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." MyAnnotation(»impureFunction«, »impureFunction«); - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." MyClass(»pureFunction«, »pureFunction«); - // $TEST$ error "Cannot pass an impure callable to a pure parameter." - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." MyClass(»impureFunction«, »impureFunction«); - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." MyEnum.MyEnumVariant(»pureFunction«, »pureFunction«); - // $TEST$ error "Cannot pass an impure callable to a pure parameter." - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." MyEnum.MyEnumVariant(»impureFunction«, »impureFunction«); - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." myFunction(»pureFunction«, »pureFunction«, »pureFunction«); - // $TEST$ error "Cannot pass an impure callable to a pure parameter." - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." myFunction(»impureFunction«, »impureFunction«, »impureFunction«); - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." mySegment1(»pureFunction«, »pureFunction«); - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." mySegment1(»impureFunction«, »impureFunction«); - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." myCallableType(»pureFunction«, »pureFunction«); - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." myCallableType(»impureFunction«, »impureFunction«); - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." myBlockLambda(»pureFunction«, »pureFunction«); - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." myBlockLambda(»impureFunction«, »impureFunction«); - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." myExpressionLambda(»pureFunction«, »pureFunction«); - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." myExpressionLambda(»impureFunction«, »impureFunction«); } -// Argument does not have callable type -pipeline myPipeline { - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." +# Argument does not have callable type +function myFunction () { + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." MyClass(»1«, »1«); } diff --git a/packages/ttsl-lang/tests/resources/validation/purity/impure callable passed to pure parameter/default values.sdstest b/packages/ttsl-lang/tests/resources/validation/purity/impure callable passed to pure parameter/default values.sdstest index d6bfa9ac..40498134 100644 --- a/packages/ttsl-lang/tests/resources/validation/purity/impure callable passed to pure parameter/default values.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/purity/impure callable passed to pure parameter/default values.sdstest @@ -7,41 +7,41 @@ fun pureFunction() fun impureFunction() annotation MyAnnotation( - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." f: () -> () = »pureFunction«, - // $TEST$ error "Cannot pass an impure callable to a pure parameter." + # $TEST$ error "Cannot pass an impure callable to a pure parameter." g: () -> () = »impureFunction«, - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." other: Int = »impureFunction«, ) class MyClass1( - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." f: () -> () = »pureFunction«, - // $TEST$ error "Cannot pass an impure callable to a pure parameter." + # $TEST$ error "Cannot pass an impure callable to a pure parameter." g: () -> () = »impureFunction«, - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." other: Int = »impureFunction«, ) enum MyEnum { MyEnumVariant( - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." f: () -> () = »pureFunction«, - // $TEST$ error "Cannot pass an impure callable to a pure parameter." + # $TEST$ error "Cannot pass an impure callable to a pure parameter." g: () -> () = »impureFunction«, - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." other: Int = »impureFunction«, ) } @Pure fun myFunction1( - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." f: () -> () = »pureFunction«, - // $TEST$ error "Cannot pass an impure callable to a pure parameter." + # $TEST$ error "Cannot pass an impure callable to a pure parameter." g: () -> () = »impureFunction«, - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." other: Int = »impureFunction«, ) @@ -50,60 +50,60 @@ fun myFunction1( ImpurityReason.PotentiallyImpureParameterCall("g1"), ]) fun myFunction2( - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." f1: () -> () = »pureFunction«, - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." g1: () -> () = »impureFunction«, - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." f2: () -> () = »pureFunction«, - // $TEST$ error "Cannot pass an impure callable to a pure parameter." + # $TEST$ error "Cannot pass an impure callable to a pure parameter." g2: () -> () = »impureFunction«, - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." other: Int = »impureFunction«, ) segment mySegment1( myCallableType: ( - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." f: () -> () = »pureFunction«, - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." g: () -> () = »impureFunction«, - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." other: Int = »impureFunction«, ) -> () ) {} segment mySegment2( - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." f: () -> () = »pureFunction«, - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." g: () -> () = »impureFunction«, - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." other: Int = »impureFunction«, ) {} -pipeline myPipeline { +function myFunction () { ( - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." f: () -> () = »pureFunction«, - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." g: () -> () = »impureFunction«, - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." other: Int = »impureFunction«, ) {}; ( - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." f: () -> () = »pureFunction«, - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." g: () -> () = »impureFunction«, - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." other: Int = »impureFunction«, ) -> 1; } -// Default value does not have callable type +# Default value does not have callable type class MyClass2( - // $TEST$ no error "Cannot pass an impure callable to a pure parameter." + # $TEST$ no error "Cannot pass an impure callable to a pure parameter." f: () -> () = »1«, ) diff --git a/packages/ttsl-lang/tests/resources/validation/purity/invalid parameter name/main.sdstest b/packages/ttsl-lang/tests/resources/validation/purity/invalid parameter name/main.sdstest index d7dc2b74..b36d59b9 100644 --- a/packages/ttsl-lang/tests/resources/validation/purity/invalid parameter name/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/purity/invalid parameter name/main.sdstest @@ -1,26 +1,26 @@ package tests.validation.purity.parameterNamesMustBeValid @Impure([ - // $TEST$ no error r"The parameter '.*' does not exist\." + # $TEST$ no error r"The parameter '.*' does not exist\." ImpurityReason.FileReadFromConstantPath(»"text.txt"«), - // $TEST$ no error "The parameter 'p' does not exist." + # $TEST$ no error "The parameter 'p' does not exist." ImpurityReason.FileReadFromParameterizedPath(»"p"«), - // $TEST$ error "The parameter 'q' does not exist." + # $TEST$ error "The parameter 'q' does not exist." ImpurityReason.FileReadFromParameterizedPath(»"q"«), - // $TEST$ no error r"The parameter '.*' does not exist\." + # $TEST$ no error r"The parameter '.*' does not exist\." ImpurityReason.FileWriteToConstantPath(»"text.txt"«), - // $TEST$ no error "The parameter 'p' does not exist." + # $TEST$ no error "The parameter 'p' does not exist." ImpurityReason.FileWriteToParameterizedPath(»"p"«), - // $TEST$ error "The parameter 'q' does not exist." + # $TEST$ error "The parameter 'q' does not exist." ImpurityReason.FileWriteToParameterizedPath(»"q"«), - // $TEST$ no error "The parameter 'p' does not exist." + # $TEST$ no error "The parameter 'p' does not exist." ImpurityReason.PotentiallyImpureParameterCall(»"p"«), - // $TEST$ error "The parameter 'q' does not exist." + # $TEST$ error "The parameter 'q' does not exist." ImpurityReason.PotentiallyImpureParameterCall(»"q"«), - // $TEST$ no error r"The parameter '.*' does not exist\." + # $TEST$ no error r"The parameter '.*' does not exist\." ImpurityReason.PotentiallyImpureParameterCall(»1«), - // $TEST$ no error "The parameter 'q' does not exist." + # $TEST$ no error "The parameter 'q' does not exist." AnotherEnum.SomeVariant(»"q"«) ]) fun f(p: Int) diff --git a/packages/ttsl-lang/tests/resources/validation/purity/must be subset of impurity reasons of overridden method/main.sdstest b/packages/ttsl-lang/tests/resources/validation/purity/must be subset of impurity reasons of overridden method/main.sdstest index 9267adaf..3b4562a9 100644 --- a/packages/ttsl-lang/tests/resources/validation/purity/must be subset of impurity reasons of overridden method/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/purity/must be subset of impurity reasons of overridden method/main.sdstest @@ -1,15 +1,15 @@ package tests.validation.purity.mustBeSubsetOfImpurityReasonsOfOverriddenMethod class Superclass { - // $TEST$ no error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." + # $TEST$ no error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." @Pure fun »pureFunction«() - // $TEST$ no error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." + # $TEST$ no error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." @Impure([]) fun »impureFunctionWithoutReason«() - // $TEST$ no error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." + # $TEST$ no error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." @Impure([ImpurityReason.Other]) fun »impureFunctionWithReasons«() } @@ -19,40 +19,40 @@ class IdenticalSubclass sub Superclass { * We already show another error if the `@Impure` annotation is called multiple times. */ - // $TEST$ no error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." + # $TEST$ no error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." @Pure @Impure([ImpurityReason.Other]) fun »pureFunction«() - // $TEST$ no error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." + # $TEST$ no error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." @Impure([]) fun »impureFunctionWithoutReason«() - // $TEST$ no error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." + # $TEST$ no error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." @Impure([ImpurityReason.Other]) fun »impureFunctionWithReasons«() } class SubsetSubclass sub Superclass { - // $TEST$ no error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." + # $TEST$ no error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." @Pure fun »impureFunctionWithoutReason«() - // $TEST$ no error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." + # $TEST$ no error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." @Impure([]) fun »impureFunctionWithReasons«() } class IllegalSubclass sub Superclass { - // $TEST$ error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." + # $TEST$ error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." @Impure([ImpurityReason.Other]) fun »pureFunction«() - // $TEST$ error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." + # $TEST$ error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." @Impure([ImpurityReason.Other]) fun »impureFunctionWithoutReason«() - // $TEST$ error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." + # $TEST$ error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." @Impure([ImpurityReason.FileReadFromConstantPath("")]) fun impureFunctionWithReasons() } diff --git a/packages/ttsl-lang/tests/resources/validation/purity/must be subset of impurity reasons of overridden method/no purity annotation.sdstest b/packages/ttsl-lang/tests/resources/validation/purity/must be subset of impurity reasons of overridden method/no purity annotation.sdstest index 8af99d5c..a72973c7 100644 --- a/packages/ttsl-lang/tests/resources/validation/purity/must be subset of impurity reasons of overridden method/no purity annotation.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/purity/must be subset of impurity reasons of overridden method/no purity annotation.sdstest @@ -1,6 +1,6 @@ package tests.validation.purity.mustBeSubsetOfImpurityReasonsOfOverriddenMethod -// $TEST$ no error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." +# $TEST$ no error "The impurity reasons of an overriding function must be a subset of the impurity reasons of the overridden function." class A { fun functionWithUnspecifiedPurity() diff --git a/packages/ttsl-lang/tests/resources/validation/purity/no impurity reasons/main.sdstest b/packages/ttsl-lang/tests/resources/validation/purity/no impurity reasons/main.sdstest index 707de1cf..0cc3820e 100644 --- a/packages/ttsl-lang/tests/resources/validation/purity/no impurity reasons/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/purity/no impurity reasons/main.sdstest @@ -1,21 +1,21 @@ package tests.validation.purity.noImpurityReasons -// $TEST$ error "At least one impurity reason must be specified." +# $TEST$ error "At least one impurity reason must be specified." @»Impure« fun f1() -// $TEST$ error "At least one impurity reason must be specified." +# $TEST$ error "At least one impurity reason must be specified." @»Impure«() fun f2() -// $TEST$ error "At least one impurity reason must be specified." +# $TEST$ error "At least one impurity reason must be specified." @»Impure«([]) -// $TEST$ no error "At least one impurity reason must be specified." +# $TEST$ no error "At least one impurity reason must be specified." @»Impure«([]) fun f3() -// $TEST$ no error "At least one impurity reason must be specified." +# $TEST$ no error "At least one impurity reason must be specified." @»Impure«([ImpurityReason.Other]) -// $TEST$ no error "At least one impurity reason must be specified." +# $TEST$ no error "At least one impurity reason must be specified." @»Impure«([ImpurityReason.Other]) fun f4() diff --git a/packages/ttsl-lang/tests/resources/validation/purity/not specified/main.sdstest b/packages/ttsl-lang/tests/resources/validation/purity/not specified/main.sdstest index 5486cb11..ef447f26 100644 --- a/packages/ttsl-lang/tests/resources/validation/purity/not specified/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/purity/not specified/main.sdstest @@ -1,12 +1,12 @@ package tests.validation.purity.notSpecified -// $TEST$ error r"The purity of a function must be specified. Call the annotation '@Pure' or '@Impure'." +# $TEST$ error r"The purity of a function must be specified. Call the annotation '@Pure' or '@Impure'." fun »functionWithUnknownPurity«() -// $TEST$ no error r"The purity of a function must be specified. Call the annotation '@Pure' or '@Impure'." +# $TEST$ no error r"The purity of a function must be specified. Call the annotation '@Pure' or '@Impure'." @Impure([]) fun »impureFunction«() -// $TEST$ no error r"The purity of a function must be specified. Call the annotation '@Pure' or '@Impure'." +# $TEST$ no error r"The purity of a function must be specified. Call the annotation '@Pure' or '@Impure'." @Pure fun »pureFunction«() diff --git a/packages/ttsl-lang/tests/resources/validation/purity/potentially impure parameter must have callable type/main.sdstest b/packages/ttsl-lang/tests/resources/validation/purity/potentially impure parameter must have callable type/main.sdstest index 67f51a2b..4044f91b 100644 --- a/packages/ttsl-lang/tests/resources/validation/purity/potentially impure parameter must have callable type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/purity/potentially impure parameter must have callable type/main.sdstest @@ -1,15 +1,15 @@ package tests.validation.purity.potentiallyImpureParameterMustHaveCallableType @Impure([ - // $TEST$ error "The parameter 'a' must have a callable type." + # $TEST$ error "The parameter 'a' must have a callable type." ImpurityReason.PotentiallyImpureParameterCall(»"a"«), - // $TEST$ error "The parameter 'b' must have a callable type." + # $TEST$ error "The parameter 'b' must have a callable type." ImpurityReason.PotentiallyImpureParameterCall(»"b"«), - // $TEST$ no error r"The parameter '.*' must have a callable type\." + # $TEST$ no error r"The parameter '.*' must have a callable type\." ImpurityReason.PotentiallyImpureParameterCall(»"c"«), - // $TEST$ no error r"The parameter '.*' must have a callable type\." + # $TEST$ no error r"The parameter '.*' must have a callable type\." ImpurityReason.PotentiallyImpureParameterCall(»"d"«), - // $TEST$ no error r"The parameter '.*' must have a callable type\." + # $TEST$ no error r"The parameter '.*' must have a callable type\." ImpurityReason.PotentiallyImpureParameterCall(»"e"«), ]) fun myFunction( diff --git a/packages/ttsl-lang/tests/resources/validation/purity/pure and impure/main.sdstest b/packages/ttsl-lang/tests/resources/validation/purity/pure and impure/main.sdstest index 308c281c..fb3fd30b 100644 --- a/packages/ttsl-lang/tests/resources/validation/purity/pure and impure/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/purity/pure and impure/main.sdstest @@ -1,17 +1,17 @@ package tests.validation.purity.pureAndImpure -// $TEST$ no error "'@Impure' and '@Pure' are mutually exclusive." +# $TEST$ no error "'@Impure' and '@Pure' are mutually exclusive." fun »neither«() -// $TEST$ no error "'@Impure' and '@Pure' are mutually exclusive." +# $TEST$ no error "'@Impure' and '@Pure' are mutually exclusive." @Impure fun »impure«() -// $TEST$ no error "'@Impure' and '@Pure' are mutually exclusive." +# $TEST$ no error "'@Impure' and '@Pure' are mutually exclusive." @Pure fun »pure«() -// $TEST$ error "'@Impure' and '@Pure' are mutually exclusive." +# $TEST$ error "'@Impure' and '@Pure' are mutually exclusive." @Impure @Pure fun »both«() diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary argument list in annotation call/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary argument list in annotation call/main.sdstest index 9889671f..69696532 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary argument list in annotation call/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary argument list in annotation call/main.sdstest @@ -12,24 +12,24 @@ annotation AnnotationWithoutRequiredParameters(a: Int = 0) @Repeatable annotation AnnotationWithRequiredParameters(a: Int) -// $TEST$ info "This argument list can be removed." +# $TEST$ info "This argument list can be removed." @AnnotationWithoutParameterList»()« -// $TEST$ no info "This argument list can be removed." +# $TEST$ no info "This argument list can be removed." @AnnotationWithoutParameterList»(1)« -// $TEST$ info "This argument list can be removed." +# $TEST$ info "This argument list can be removed." @AnnotationWithEmptyParameterList»()« -// $TEST$ no info "This argument list can be removed." +# $TEST$ no info "This argument list can be removed." @AnnotationWithEmptyParameterList»(1)« -// $TEST$ info "This argument list can be removed." +# $TEST$ info "This argument list can be removed." @AnnotationWithoutRequiredParameters»()« -// $TEST$ no info "This argument list can be removed." +# $TEST$ no info "This argument list can be removed." @AnnotationWithoutRequiredParameters»(1)« -// $TEST$ no info "This argument list can be removed." +# $TEST$ no info "This argument list can be removed." @AnnotationWithRequiredParameters»()« -// $TEST$ no info "This argument list can be removed." +# $TEST$ no info "This argument list can be removed." @AnnotationWithRequiredParameters»(1)« -// $TEST$ no info "This argument list can be removed." +# $TEST$ no info "This argument list can be removed." @Unresolved»()« -// $TEST$ no info "This argument list can be removed." +# $TEST$ no info "This argument list can be removed." @Unresolved»(1)« class MyClass diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary argument list in call/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary argument list in call/main.sdstest index c4abf085..193f4ca2 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary argument list in call/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary argument list in call/main.sdstest @@ -21,45 +21,45 @@ segment mySegment2( val blockLambda = () {}; val expressionLambda = () -> 0; - // $TEST$ no info "This argument list can be removed." + # $TEST$ no info "This argument list can be removed." MyAnnotation»()«; - // $TEST$ no info "This argument list can be removed." + # $TEST$ no info "This argument list can be removed." MyClass»()«; - // $TEST$ info "This argument list can be removed." + # $TEST$ info "This argument list can be removed." MyEnum.EnumVariantWithoutParameterList»()«; - // $TEST$ no info "This argument list can be removed." + # $TEST$ no info "This argument list can be removed." MyEnum.EnumVariantWithoutParameterList»(1)«; - // $TEST$ info "This argument list can be removed." + # $TEST$ info "This argument list can be removed." MyEnum.EnumVariantWithEmptyParameterList»()«; - // $TEST$ no info "This argument list can be removed." + # $TEST$ no info "This argument list can be removed." MyEnum.EnumVariantWithEmptyParameterList»(1)«; - // $TEST$ no info "This argument list can be removed." + # $TEST$ no info "This argument list can be removed." MyEnum.EnumVariantWithoutRequiredParameters»()«; - // $TEST$ no info "This argument list can be removed." + # $TEST$ no info "This argument list can be removed." MyEnum.EnumVariantWithoutRequiredParameters»(1)«; - // $TEST$ no info "This argument list can be removed." + # $TEST$ no info "This argument list can be removed." MyEnum.EnumVariantWithRequiredParameters»()«; - // $TEST$ no info "This argument list can be removed." + # $TEST$ no info "This argument list can be removed." MyEnum.EnumVariantWithRequiredParameters»(1)«; - // $TEST$ no info "This argument list can be removed." + # $TEST$ no info "This argument list can be removed." MyEnum.Unresolved»()«; - // $TEST$ no info "This argument list can be removed." + # $TEST$ no info "This argument list can be removed." MyEnum.Unresolved»(1)«; - // $TEST$ no info "This argument list can be removed." + # $TEST$ no info "This argument list can be removed." myFunction»()«; - // $TEST$ no info "This argument list can be removed." + # $TEST$ no info "This argument list can be removed." mySegment1»()«; - // $TEST$ no info "This argument list can be removed." + # $TEST$ no info "This argument list can be removed." callableType»()«; - // $TEST$ no info "This argument list can be removed." + # $TEST$ no info "This argument list can be removed." blockLambda»()«; - // $TEST$ no info "This argument list can be removed." + # $TEST$ no info "This argument list can be removed." expressionLambda»()«; } diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary assignment/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary assignment/main.sdstest index 59097760..eed80fa7 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary assignment/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary assignment/main.sdstest @@ -7,25 +7,25 @@ class MyClass { } segment mySegment() -> a: Int { - // $TEST$ info "This assignment can be replaced by an expression statement." + # $TEST$ info "This assignment can be replaced by an expression statement." »_, _ = f();« - // $TEST$ info "This assignment can be replaced by an expression statement." + # $TEST$ info "This assignment can be replaced by an expression statement." »_, _ = MyClass().f();« - // $TEST$ no info "This assignment can be replaced by an expression statement." + # $TEST$ no info "This assignment can be replaced by an expression statement." »val a = 1;« - // $TEST$ no info "This assignment can be replaced by an expression statement." + # $TEST$ no info "This assignment can be replaced by an expression statement." »yield a = 1;« () { - // $TEST$ info "This assignment can be replaced by an expression statement." + # $TEST$ info "This assignment can be replaced by an expression statement." »_, _ = f();« - // $TEST$ info "This assignment can be replaced by an expression statement." + # $TEST$ info "This assignment can be replaced by an expression statement." »_, _ = MyClass().f();« - // $TEST$ no info "This assignment can be replaced by an expression statement." + # $TEST$ no info "This assignment can be replaced by an expression statement." »val a = 1;« - // $TEST$ no info "This assignment can be replaced by an expression statement." + # $TEST$ no info "This assignment can be replaced by an expression statement." »yield a = 1;« }; } diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary body in class/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary body in class/main.sdstest index 24001d56..16a3aefe 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary body in class/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary body in class/main.sdstest @@ -1,14 +1,14 @@ package tests.validation.style.unnecessaryBodyInClass -// $TEST$ info "This body can be removed." +# $TEST$ info "This body can be removed." class MyClass1 »{}« -// $TEST$ no info "This body can be removed." +# $TEST$ no info "This body can be removed." class MyClass2 »{ fun f() }« -// $TEST$ no info "This body can be removed." +# $TEST$ no info "This body can be removed." class MyClass3 »{ attr a: Int }« diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary body in enum/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary body in enum/main.sdstest index 91b9bf82..6bae5c77 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary body in enum/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary body in enum/main.sdstest @@ -1,9 +1,9 @@ package tests.validation.style.unnecessaryBodyInEnum -// $TEST$ info "This body can be removed." +# $TEST$ info "This body can be removed." enum MyEnum1 »{}« -// $TEST$ no info "This body can be removed." +# $TEST$ no info "This body can be removed." enum MyEnum2 »{ Instance }« diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary const modifier on annotation parameter/info.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary const modifier on annotation parameter/info.sdstest index c23d3171..89a5c24c 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary const modifier on annotation parameter/info.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary const modifier on annotation parameter/info.sdstest @@ -1,6 +1,6 @@ package tests.validation.style.unnecessaryConstModifierOnAnnotationParameters annotation MyAnnotation( - // $TEST$ info "Annotation parameters are always const, so this modifier can be removed." + # $TEST$ info "Annotation parameters are always const, so this modifier can be removed." »const« p1: Int ) diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary const modifier on annotation parameter/no info.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary const modifier on annotation parameter/no info.sdstest index d9d5f58f..68c01ed3 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary const modifier on annotation parameter/no info.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary const modifier on annotation parameter/no info.sdstest @@ -1,6 +1,6 @@ package tests.validation.style.unnecessaryConstModifierOnAnnotationParameters annotation MyAnnotation( - // $TEST$ no info "Annotation parameters are always const, so this modifier can be removed." + # $TEST$ no info "Annotation parameters are always const, so this modifier can be removed." p2: Int, ) diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in annotation/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in annotation/main.sdstest index 18384871..b8f39688 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in annotation/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in annotation/main.sdstest @@ -1,9 +1,9 @@ package tests.validation.style.unnecessaryConstraintListInAnnotation -// $TEST$ info "This constraint list can be removed." +# $TEST$ info "This constraint list can be removed." annotation MyAnnotation1 »where {}« -// $TEST$ no info "This constraint list can be removed." +# $TEST$ no info "This constraint list can be removed." annotation MyAnnotation2(p: Int) »where { p < 0 }« diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in class/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in class/main.sdstest index 1819c189..5ab9591e 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in class/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in class/main.sdstest @@ -1,9 +1,9 @@ package tests.validation.style.unnecessaryConstraintListInClass -// $TEST$ info "This constraint list can be removed." +# $TEST$ info "This constraint list can be removed." class MyClass1 »where {}« -// $TEST$ no info "This constraint list can be removed." +# $TEST$ no info "This constraint list can be removed." class MyClass2(p: Int) »where { p < 0 }« diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in enum variant/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in enum variant/main.sdstest index e2e51aea..1bc212ef 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in enum variant/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in enum variant/main.sdstest @@ -1,10 +1,10 @@ package tests.validation.style.unnecessaryConstraintInEnumVariant enum MyEnum { - // $TEST$ info "This constraint list can be removed." + # $TEST$ info "This constraint list can be removed." MyVariant1 »where {}« - // $TEST$ no info "This constraint list can be removed." + # $TEST$ no info "This constraint list can be removed." MyVariant2(p: Int) »where { p < 0 }« diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in function/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in function/main.sdstest index e104e176..eeadb021 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in function/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in function/main.sdstest @@ -1,9 +1,9 @@ package tests.validation.style.unnecessaryConstraintListInFunction -// $TEST$ info "This constraint list can be removed." +# $TEST$ info "This constraint list can be removed." fun myFunction1() »where {}« -// $TEST$ no info "This constraint list can be removed." +# $TEST$ no info "This constraint list can be removed." fun myFunction2(p: Int) »where { p < 0 }« diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in segment/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in segment/main.sdstest index 45e9ca48..893e2c85 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in segment/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary constraint list in segment/main.sdstest @@ -1,9 +1,9 @@ package tests.validation.style.unnecessaryConstraintListInSegment -// $TEST$ info "This constraint list can be removed." +# $TEST$ info "This constraint list can be removed." segment mySegment1() »where {}« {} -// $TEST$ no info "This constraint list can be removed." +# $TEST$ no info "This constraint list can be removed." segment mySegment2(p: Int) »where { p < 0 }« {} diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary elvis operator/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary elvis operator/main.sdstest index 3ba83ddc..d55197eb 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary elvis operator/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary elvis operator/main.sdstest @@ -2,42 +2,42 @@ package validation.style.unnecessaryElvisOperator @Pure fun f() -> result: Any? -pipeline test { +function test () { - // $TEST$ info "The left operand is never null, so the elvis operator is unnecessary (keep the left operand)." + # $TEST$ info "The left operand is never null, so the elvis operator is unnecessary (keep the left operand)." »1 ?: 2«; - // $TEST$ info "The left operand is never null, so the elvis operator is unnecessary (keep the left operand)." + # $TEST$ info "The left operand is never null, so the elvis operator is unnecessary (keep the left operand)." »1 ?: null«; - // $TEST$ no info "The left operand is never null, so the elvis operator is unnecessary (keep the left operand)." + # $TEST$ no info "The left operand is never null, so the elvis operator is unnecessary (keep the left operand)." »null ?: 2«; - // $TEST$ no info "The left operand is never null, so the elvis operator is unnecessary (keep the left operand)." + # $TEST$ no info "The left operand is never null, so the elvis operator is unnecessary (keep the left operand)." »null ?: null«; - // $TEST$ no info "The right operand is always null, so the elvis operator is unnecessary (keep the left operand)." + # $TEST$ no info "The right operand is always null, so the elvis operator is unnecessary (keep the left operand)." »1 ?: 2«; - // $TEST$ info "The right operand is always null, so the elvis operator is unnecessary (keep the left operand)." + # $TEST$ info "The right operand is always null, so the elvis operator is unnecessary (keep the left operand)." »f() ?: null«; - // $TEST$ no info "The right operand is always null, so the elvis operator is unnecessary (keep the left operand)." + # $TEST$ no info "The right operand is always null, so the elvis operator is unnecessary (keep the left operand)." »null ?: 2«; - // $TEST$ no info "The right operand is always null, so the elvis operator is unnecessary (keep the left operand)." + # $TEST$ no info "The right operand is always null, so the elvis operator is unnecessary (keep the left operand)." »null ?: null«; - // $TEST$ no info "The left operand is always null, so the elvis operator is unnecessary (keep the right operand)." + # $TEST$ no info "The left operand is always null, so the elvis operator is unnecessary (keep the right operand)." »1 ?: 2«; - // $TEST$ no info "The left operand is always null, so the elvis operator is unnecessary (keep the right operand)." + # $TEST$ no info "The left operand is always null, so the elvis operator is unnecessary (keep the right operand)." »1 ?: null«; - // $TEST$ info "The left operand is always null, so the elvis operator is unnecessary (keep the right operand)." + # $TEST$ info "The left operand is always null, so the elvis operator is unnecessary (keep the right operand)." »null ?: 2«; - // $TEST$ no info "The left operand is always null, so the elvis operator is unnecessary (keep the right operand)." + # $TEST$ no info "The left operand is always null, so the elvis operator is unnecessary (keep the right operand)." »null ?: null«; - // $TEST$ no info "Both operands are always null, so the elvis operator is unnecessary (replace it with null)." + # $TEST$ no info "Both operands are always null, so the elvis operator is unnecessary (replace it with null)." »1 ?: 2«; - // $TEST$ no info "Both operands are always null, so the elvis operator is unnecessary (replace it with null)." + # $TEST$ no info "Both operands are always null, so the elvis operator is unnecessary (replace it with null)." »1 ?: null«; - // $TEST$ no info "Both operands are always null, so the elvis operator is unnecessary (replace it with null)." + # $TEST$ no info "Both operands are always null, so the elvis operator is unnecessary (replace it with null)." »null ?: 2«; - // $TEST$ info "Both operands are always null, so the elvis operator is unnecessary (replace it with null)." + # $TEST$ info "Both operands are always null, so the elvis operator is unnecessary (replace it with null)." »null ?: null«; } @@ -45,12 +45,12 @@ class TestsForTypeParameters( nullable: Nullable, nonNullable: NonNullable, - // $TEST$ no info "The left operand is never null, so the elvis operator is unnecessary (keep the left operand)." + # $TEST$ no info "The left operand is never null, so the elvis operator is unnecessary (keep the left operand)." p1: Any? = »nullable ?: 2«, - // $TEST$ no info "The left operand is never null, so the elvis operator is unnecessary (keep the left operand)." + # $TEST$ no info "The left operand is never null, so the elvis operator is unnecessary (keep the left operand)." p2: Any? = »nullable ?: null«, - // $TEST$ info "The left operand is never null, so the elvis operator is unnecessary (keep the left operand)." + # $TEST$ info "The left operand is never null, so the elvis operator is unnecessary (keep the left operand)." p3: Any? = »nonNullable ?: 2«, - // $TEST$ info "The left operand is never null, so the elvis operator is unnecessary (keep the left operand)." + # $TEST$ info "The left operand is never null, so the elvis operator is unnecessary (keep the left operand)." p4: Any? = »nonNullable ?: null«, ) diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary import alias/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary import alias/main.sdstest index 4e8c2468..34d52b89 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary import alias/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary import alias/main.sdstest @@ -1,7 +1,7 @@ package tests.validation.style.unnecessaryImportAlias -// $TEST$ no info "This alias can be removed." +# $TEST$ no info "This alias can be removed." from tests.validation.style.unnecessaryImportAlias.other import C »as D« -// $TEST$ info "This alias can be removed." -// $TEST$ info "This alias can be removed." +# $TEST$ info "This alias can be removed." +# $TEST$ info "This alias can be removed." from tests.validation.style.unnecessaryImportAlias.other import C »as C«, C »as C« diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary null safety/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary null safety/main.sdstest index a05bdf54..9a38d61b 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary null safety/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary null safety/main.sdstest @@ -13,41 +13,41 @@ segment call( val myFunction = myClass.f; val myFunctionOrNull = myClassOrNull?.f; - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »(() {})()«; - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »1()«; - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »null()«; - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »myFunction()«; - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »myFunctionOrNull()«; - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »unresolved()«; - // $TEST$ info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ info "The receiver is never null, so null-safety is unnecessary." »(() {})?()«; - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »1?()«; - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »null?()«; - // $TEST$ info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ info "The receiver is never null, so null-safety is unnecessary." »myFunction?()«; - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »myFunctionOrNull?()«; - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »unresolved?()«; } @@ -58,38 +58,38 @@ segment indexedAccess( val myList = myClass.l; val myListOrNull = myClassOrNull?.l; - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »[1][0]«; - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »1[0]«; - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »null[0]«; - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »myList[0]«; - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »myListOrNull[0]«; - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »unresolved[0]«; - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »1?[0]«; - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »null?[0]«; - // $TEST$ info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ info "The receiver is never null, so null-safety is unnecessary." »myList?[0]«; - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »myListOrNull?[0]«; - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." »unresolved?[0]«; } @@ -97,13 +97,13 @@ class IndexedAccess?, NonNullable sub List>( nullable: Nullable, nonNullable: NonNullable, - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." p1: Any? = »nullable[0]«, - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." p2: Any? = »nonNullable[0]«, - // $TEST$ no info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ no info "The receiver is never null, so null-safety is unnecessary." p3: Any? = »nullable?[0]«, - // $TEST$ info "The receiver is never null, so null-safety is unnecessary." + # $TEST$ info "The receiver is never null, so null-safety is unnecessary." p4: Any? = »nonNullable?[0]«, ) diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary parameter list in annotation/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary parameter list in annotation/main.sdstest index 9cdeefb3..85e0854d 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary parameter list in annotation/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary parameter list in annotation/main.sdstest @@ -1,7 +1,7 @@ package tests.validation.style.unnecessaryParameterListInAnnotation -// $TEST$ info "This parameter list can be removed." +# $TEST$ info "This parameter list can be removed." annotation MyAnnotation1»()« -// $TEST$ no info "This parameter list can be removed." +# $TEST$ no info "This parameter list can be removed." annotation MyAnnotation2»(a: Int)« diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary parameter list in enum variant/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary parameter list in enum variant/main.sdstest index 90c689b0..2caf017f 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary parameter list in enum variant/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary parameter list in enum variant/main.sdstest @@ -1,7 +1,7 @@ package tests.validation.style.unnecessaryParameterListInEnumVariant -// $TEST$ info "This parameter list can be removed." +# $TEST$ info "This parameter list can be removed." annotation MyAnnotation1»()« -// $TEST$ no info "This parameter list can be removed." +# $TEST$ no info "This parameter list can be removed." annotation MyAnnotation2»(a: Int)« diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary result list in function/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary result list in function/main.sdstest index edb55960..6e116a0c 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary result list in function/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary result list in function/main.sdstest @@ -1,7 +1,7 @@ package tests.validation.style.unnecessaryResultListInFunction -// $TEST$ info "This result list can be removed." +# $TEST$ info "This result list can be removed." fun myFun1() »-> ()« -// $TEST$ no info "This result list can be removed." +# $TEST$ no info "This result list can be removed." fun myFun2() »-> (r: Int)« diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary result list in segment/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary result list in segment/main.sdstest index baea207e..ec71f7e6 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary result list in segment/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary result list in segment/main.sdstest @@ -1,7 +1,7 @@ package tests.validation.style.unnecessaryResultListInSegment -// $TEST$ info "This result list can be removed." +# $TEST$ info "This result list can be removed." segment mySegment1() »-> ()« {} -// $TEST$ no info "This result list can be removed." +# $TEST$ no info "This result list can be removed." segment mySegment2() »-> (r: Int)« {} diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary type argument list/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary type argument list/main.sdstest index ecc14ba0..0105e424 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary type argument list/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary type argument list/main.sdstest @@ -5,21 +5,21 @@ class ClassWithEmptyTypeParameterList<> class ClassWithTypeParameters fun myFunction( - // $TEST$ info "This type argument list can be removed." + # $TEST$ info "This type argument list can be removed." a1: ClassWithoutTypeParameterList»<>«, - // $TEST$ no info "This type argument list can be removed." + # $TEST$ no info "This type argument list can be removed." a2: ClassWithoutTypeParameterList»«, - // $TEST$ info "This type argument list can be removed." + # $TEST$ info "This type argument list can be removed." a3: ClassWithEmptyTypeParameterList»<>«, - // $TEST$ no info "This type argument list can be removed." + # $TEST$ no info "This type argument list can be removed." a4: ClassWithEmptyTypeParameterList»«, - // $TEST$ no info "This type argument list can be removed." + # $TEST$ no info "This type argument list can be removed." a5: ClassWithTypeParameters»<>«, - // $TEST$ no info "This type argument list can be removed." + # $TEST$ no info "This type argument list can be removed." a6: ClassWithTypeParameters»«, - // $TEST$ no info "This type argument list can be removed." + # $TEST$ no info "This type argument list can be removed." d1: Unresolved»<>«, - // $TEST$ no info "This type argument list can be removed." + # $TEST$ no info "This type argument list can be removed." d2: Unresolved»«, ) diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary type parameter list in class/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary type parameter list in class/main.sdstest index 8d3f68db..ebe8411f 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary type parameter list in class/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary type parameter list in class/main.sdstest @@ -1,7 +1,7 @@ package tests.validation.style.unnecessaryTypeParameterListInClass -// $TEST$ info "This type parameter list can be removed." +# $TEST$ info "This type parameter list can be removed." class MyClass1»<>« -// $TEST$ no info "This type parameter list can be removed." +# $TEST$ no info "This type parameter list can be removed." class MyClass2»« diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary type parameter list in function/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary type parameter list in function/main.sdstest index 8c67cca9..eeed1e9f 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary type parameter list in function/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary type parameter list in function/main.sdstest @@ -1,7 +1,7 @@ package tests.validation.style.unnecessaryTypeParameterListInFunction -// $TEST$ info "This type parameter list can be removed." +# $TEST$ info "This type parameter list can be removed." fun myFunction1»<>«() -// $TEST$ no info "This type parameter list can be removed." +# $TEST$ no info "This type parameter list can be removed." fun myFunction2»«() diff --git a/packages/ttsl-lang/tests/resources/validation/style/unnecessary union type/main.sdstest b/packages/ttsl-lang/tests/resources/validation/style/unnecessary union type/main.sdstest index 451142b8..f078b0ed 100644 --- a/packages/ttsl-lang/tests/resources/validation/style/unnecessary union type/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/style/unnecessary union type/main.sdstest @@ -1,16 +1,16 @@ package tests.validation.style.unnecessaryUnionType -// $TEST$ no info "This can be replaced by the singular type argument of the union type." +# $TEST$ no info "This can be replaced by the singular type argument of the union type." segment mySegment1( p: »union<>« ) {} -// $TEST$ info "This can be replaced by the singular type argument of the union type." +# $TEST$ info "This can be replaced by the singular type argument of the union type." segment mySegment2( p: »union« ) {} -// $TEST$ no info "This can be replaced by the singular type argument of the union type." +# $TEST$ no info "This can be replaced by the singular type argument of the union type." segment mySegment3( p: »union« ) {} diff --git a/packages/ttsl-lang/tests/resources/validation/types/checking/arguments/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/checking/arguments/main.sdstest index 95aa5c2f..9e86a4a4 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/checking/arguments/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/checking/arguments/main.sdstest @@ -3,18 +3,18 @@ package tests.validation.types.checking.arguments fun f(p: Int) segment mySegment() { - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." f(»1«); - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." f(p = »1«); - // $TEST$ error "Expected type 'Int' but got 'literal<"">'." + # $TEST$ error "Expected type 'Int' but got 'literal<"">'." f(»""«); - // $TEST$ error "Expected type 'Int' but got 'literal<"">'." + # $TEST$ error "Expected type 'Int' but got 'literal<"">'." f(p = »""«); - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." f(unresolved = »1«); } diff --git a/packages/ttsl-lang/tests/resources/validation/types/checking/arguments/with type parameters.sdstest b/packages/ttsl-lang/tests/resources/validation/types/checking/arguments/with type parameters.sdstest index c1bb33da..379f84fa 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/checking/arguments/with type parameters.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/checking/arguments/with type parameters.sdstest @@ -26,50 +26,50 @@ segment mySegment( number: Number, contravariantInt: Contravariant, ) { - // $TEST$ no error r"Expected type .* but got .*\." - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." C1(»1«, »2«); - // $TEST$ no error r"Expected type .* but got .*\." - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." C1(»1«, »int«); - // $TEST$ no error r"Expected type .* but got .*\." - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." C2(»1«, »2«); - // $TEST$ no error r"Expected type .* but got .*\." - // $TEST$ error "Expected type 'Number' but got 'literal<"">'." + # $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ error "Expected type 'Number' but got 'literal<"">'." C2(»1«, »""«); - // $TEST$ no error r"Expected type .* but got .*\." - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." C3(»1«, »contravariantInt«); - // $TEST$ no error r"Expected type .* but got .*\." - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." C3(»int«, »contravariantInt«); - // $TEST$ no error r"Expected type .* but got .*\." - // $TEST$ error "Expected type 'Contravariant' but got 'Contravariant'." + # $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ error "Expected type 'Contravariant' but got 'Contravariant'." C3(»number«, »contravariantInt«); - // $TEST$ no error r"Expected type .* but got .*\." - // $TEST$ error "Expected type 'Contravariant>' but got 'Contravariant'." + # $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ error "Expected type 'Contravariant>' but got 'Contravariant'." C3(»""«, »contravariantInt«); - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." f(»(p) -> p«); - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." f(»(p) -> 1«); - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." f(»(p: Int) -> p«); - // $TEST$ error "Expected type '(p: Int) -> (r: Int)' but got '(p: Int) -> (result: literal<"">)'." + # $TEST$ error "Expected type '(p: Int) -> (r: Int)' but got '(p: Int) -> (result: literal<"">)'." f(»(p: Int) -> ""«); } diff --git a/packages/ttsl-lang/tests/resources/validation/types/checking/call receiver/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/checking/call receiver/main.sdstest index 979cf38d..d600e5e6 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/checking/call receiver/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/checking/call receiver/main.sdstest @@ -16,7 +16,7 @@ enum MyEnum { fun myFunction() -pipeline myPipeline {} +function myFunction () {} schema MySchema {} @@ -32,66 +32,66 @@ segment mySegment2( val blockLambda = () {}; val expressionLambda = () -> 1; - // $TEST$ no error "This expression is not callable." + # $TEST$ no error "This expression is not callable." »MyAnnotation«(); - // $TEST$ error "This expression is not callable." + # $TEST$ error "This expression is not callable." val myAnnotationAlias = MyAnnotation; »myAnnotationAlias«(); - // $TEST$ no error "This expression is not callable." + # $TEST$ no error "This expression is not callable." »MyClass«(); - // $TEST$ error "This expression is not callable." + # $TEST$ error "This expression is not callable." »MyClass.myAttribute«(); - // $TEST$ no error "This expression is not callable." + # $TEST$ no error "This expression is not callable." »MyClass.MyClass«(); - // $TEST$ error "This expression is not callable." + # $TEST$ error "This expression is not callable." »MyClass.MyEnum«(); - // $TEST$ no error "This expression is not callable." + # $TEST$ no error "This expression is not callable." »MyClass.myFunction«(); - // $TEST$ error "This expression is not callable." + # $TEST$ error "This expression is not callable." »MyEnum«(); - // $TEST$ no error "This expression is not callable." + # $TEST$ no error "This expression is not callable." »MyEnum.MySimpleEnumVariant«(); - // $TEST$ no error "This expression is not callable." + # $TEST$ no error "This expression is not callable." »MyEnum.MyComplexEnumVariant«(); - // $TEST$ no error "This expression is not callable." + # $TEST$ no error "This expression is not callable." »myFunction«(); - // $TEST$ no error "This expression is not callable." + # $TEST$ no error "This expression is not callable." »myPipeline«(); - // $TEST$ error "This expression is not callable." + # $TEST$ error "This expression is not callable." val myPipelineAlias = MyPipeline; »myPipelineAlias«(); - // $TEST$ no error "This expression is not callable." + # $TEST$ no error "This expression is not callable." »MySchema«(); - // $TEST$ error "This expression is not callable." + # $TEST$ error "This expression is not callable." val mySchemaAlias = MySchema; »mySchemaAlias«(); - // $TEST$ no error "This expression is not callable." + # $TEST$ no error "This expression is not callable." »mySegment1«(); - // $TEST$ error "This expression is not callable." + # $TEST$ error "This expression is not callable." »int«(); - // $TEST$ no error "This expression is not callable." + # $TEST$ no error "This expression is not callable." »callable«(); - // $TEST$ error "This expression is not callable." + # $TEST$ error "This expression is not callable." »intLiteral«(); - // $TEST$ no error "This expression is not callable." + # $TEST$ no error "This expression is not callable." »blockLambda«(); - // $TEST$ no error "This expression is not callable." + # $TEST$ no error "This expression is not callable." »expressionLambda«(); - // $TEST$ no error "This expression is not callable." + # $TEST$ no error "This expression is not callable." »(blockLambda)«(); - // $TEST$ no error "This expression is not callable." + # $TEST$ no error "This expression is not callable." »(expressionLambda)«(); - // $TEST$ error "This expression is not callable." + # $TEST$ error "This expression is not callable." »intOrNull«(); - // $TEST$ no error "This expression is not callable." + # $TEST$ no error "This expression is not callable." »callableOrNull«(); /* @@ -100,14 +100,14 @@ segment mySegment2( * distance to the linking error might be too large. */ - // $TEST$ no error "This expression is not callable." + # $TEST$ no error "This expression is not callable." »unknownGlobal«(); - // $TEST$ no error "This expression is not callable." + # $TEST$ no error "This expression is not callable." »MyClass.unknownMember«(); - // $TEST$ error "This expression is not callable." + # $TEST$ error "This expression is not callable." val alias1 = unknownGlobal; »alias1«(); - // $TEST$ error "This expression is not callable." + # $TEST$ error "This expression is not callable." val alias2 = MyClass.unknownMember; »alias2«(); } diff --git a/packages/ttsl-lang/tests/resources/validation/types/checking/called class must have constructor/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/checking/called class must have constructor/main.sdstest index d42292eb..a1e31d4a 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/checking/called class must have constructor/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/checking/called class must have constructor/main.sdstest @@ -4,11 +4,11 @@ class A class B() -pipeline test { +function test () { - // $TEST$ error "Cannot instantiate a class that has no constructor." + # $TEST$ error "Cannot instantiate a class that has no constructor." val a = »A«(); - // $TEST$ no error "Cannot instantiate a class that has no constructor." + # $TEST$ no error "Cannot instantiate a class that has no constructor." val b = »B«(); } diff --git a/packages/ttsl-lang/tests/resources/validation/types/checking/default values/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/checking/default values/main.sdstest index 8dd59f9b..e246e86f 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/checking/default values/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/checking/default values/main.sdstest @@ -1,19 +1,19 @@ package tests.validation.types.checking.defaultValues fun myFun( - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." param1: Int = »1«, - // $TEST$ error "Expected type 'Int' but got 'literal<"">'." + # $TEST$ error "Expected type 'Int' but got 'literal<"">'." param2: Int = »""«, ) fun myOtherFun(callback: (a: Int) -> ()) segment mySegment() { - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." myOtherFun((a = »1«) {}); - // $TEST$ error "Expected type 'Int' but got 'literal<"">'." + # $TEST$ error "Expected type 'Int' but got 'literal<"">'." myOtherFun((a = »""«) {}); } diff --git a/packages/ttsl-lang/tests/resources/validation/types/checking/default values/with type parameters.sdstest b/packages/ttsl-lang/tests/resources/validation/types/checking/default values/with type parameters.sdstest index 93259f6e..d37b3aeb 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/checking/default values/with type parameters.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/checking/default values/with type parameters.sdstest @@ -1,45 +1,45 @@ package tests.validation.types.checking.defaultValues class SomeClass( - // $TEST$ error "Expected type 'T1' but got 'literal'." + # $TEST$ error "Expected type 'T1' but got 'literal'." a1: T1 = »true«, - // $TEST$ error "Expected type 'T1' but got 'literal<1>'." + # $TEST$ error "Expected type 'T1' but got 'literal<1>'." a2: T1 = »1«, - // $TEST$ error "Expected type 'T2' but got 'literal<"">'." + # $TEST$ error "Expected type 'T2' but got 'literal<"">'." a3: T2 = »""«, - // $TEST$ error "Expected type 'T3' but got 'literal<1>'." + # $TEST$ error "Expected type 'T3' but got 'literal<1>'." a4: T3 = »1«, - // $TEST$ error "Expected type 'T3' but got 'literal<"">'." + # $TEST$ error "Expected type 'T3' but got 'literal<"">'." a5: T3 = »""«, - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." b1: T1 = »a1«, - // $TEST$ error "Expected type 'T2' but got 'T1'." + # $TEST$ error "Expected type 'T2' but got 'T1'." b2: T2 = »a1«, - // $TEST$ error "Expected type 'T1' but got 'T2'." + # $TEST$ error "Expected type 'T1' but got 'T2'." b3: T1 = »a3«, - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." b4: T2 = »a4«, ) @Pure fun someFunction( - // $TEST$ error "Expected type 'T1' but got 'literal'." + # $TEST$ error "Expected type 'T1' but got 'literal'." a1: T1 = »true«, - // $TEST$ error "Expected type 'T1' but got 'literal<1>'." + # $TEST$ error "Expected type 'T1' but got 'literal<1>'." a2: T1 = »1«, - // $TEST$ error "Expected type 'T2' but got 'literal<"">'." + # $TEST$ error "Expected type 'T2' but got 'literal<"">'." a3: T2 = »""«, - // $TEST$ error "Expected type 'T3' but got 'literal<1>'." + # $TEST$ error "Expected type 'T3' but got 'literal<1>'." a4: T3 = »1«, - // $TEST$ error "Expected type 'T3' but got 'literal<"">'." + # $TEST$ error "Expected type 'T3' but got 'literal<"">'." a5: T3 = »""«, - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." b1: T1 = »a1«, - // $TEST$ error "Expected type 'T2' but got 'T1'." + # $TEST$ error "Expected type 'T2' but got 'T1'." b2: T2 = »a1«, - // $TEST$ error "Expected type 'T1' but got 'T2'." + # $TEST$ error "Expected type 'T1' but got 'T2'." b3: T1 = »a3«, - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." b4: T2 = »a4«, ) diff --git a/packages/ttsl-lang/tests/resources/validation/types/checking/indexed access on list/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/checking/indexed access on list/main.sdstest index dd10f865..4814de99 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/checking/indexed access on list/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/checking/indexed access on list/main.sdstest @@ -3,33 +3,33 @@ package tests.validation.types.checking.indexedAccessOnList @Pure fun list() -> list: List @Pure fun index() -> index: Int -pipeline myPipeline { - // $TEST$ no error r"Expected type .* but got .*\." +function myFunction () { + # $TEST$ no error r"Expected type .* but got .*\." [0][»0«]; - // $TEST$ error "Expected type 'Int' but got 'literal<"">'." + # $TEST$ error "Expected type 'Int' but got 'literal<"">'." [0][»""«]; - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." [0][»index()«]; - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." list()[»0«]; - // $TEST$ error "Expected type 'Int' but got 'literal<"">'." + # $TEST$ error "Expected type 'Int' but got 'literal<"">'." list()[»""«]; - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." list()[»index()«]; - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." unresolved[»""«]; } -// Strict checking of type parameter types +# Strict checking of type parameter types class MyClass( p1: T, - // $TEST$ error "Expected type 'Int' but got 'T'." + # $TEST$ error "Expected type 'Int' but got 'T'." a: Any? = [0][»p1«], ) diff --git a/packages/ttsl-lang/tests/resources/validation/types/checking/indexed access on map/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/checking/indexed access on map/main.sdstest index c47863f9..588ac89f 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/checking/indexed access on map/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/checking/indexed access on map/main.sdstest @@ -3,26 +3,26 @@ package tests.validation.types.checking.indexedAccessOnMap @Pure fun map() -> map: Map @Pure fun key() -> key: String -pipeline myPipeline { - // $TEST$ no error r"Expected type .* but got .*\." +function myFunction () { + # $TEST$ no error r"Expected type .* but got .*\." {"": ""}[»""«]; - // $TEST$ error "Expected type 'String' but got 'literal<1>'." + # $TEST$ error "Expected type 'String' but got 'literal<1>'." {"": ""}[»1«]; - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." {"": ""}[»key()«]; - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." map()[»""«]; - // $TEST$ error "Expected type 'String' but got 'literal<1>'." + # $TEST$ error "Expected type 'String' but got 'literal<1>'." map()[»1«]; - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." map()[»key()«]; - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." unresolved[»""«]; } @@ -31,20 +31,20 @@ class MyMap sub Map segment mySegment( myMap: MyMap, ) { - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." myMap[»""«]; - // $TEST$ error "Expected type 'String' but got 'literal<1>'." + # $TEST$ error "Expected type 'String' but got 'literal<1>'." myMap[»1«]; - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." myMap[»key()«]; } -// Strict checking of type parameter types +# Strict checking of type parameter types class MyClass( p1: T, - // $TEST$ error "Expected type 'String' but got 'T'." + # $TEST$ error "Expected type 'String' but got 'T'." a: Any? = {"": ""}[»p1«], ) diff --git a/packages/ttsl-lang/tests/resources/validation/types/checking/indexed access receiver/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/checking/indexed access receiver/main.sdstest index 7486419b..e42fae26 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/checking/indexed access receiver/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/checking/indexed access receiver/main.sdstest @@ -11,32 +11,32 @@ segment mySegment( myList: MyList, myMap: MyMap, ) { - // $TEST$ no error r"Expected type 'List' or 'Map' but got .*\." + # $TEST$ no error r"Expected type 'List' or 'Map' but got .*\." »[1]«[0]; - // $TEST$ no error r"Expected type 'List' or 'Map' but got .*\." + # $TEST$ no error r"Expected type 'List' or 'Map' but got .*\." »{0: 1}«[0]; - // $TEST$ error "Expected type 'List' or 'Map' but got 'literal<1>'." + # $TEST$ error "Expected type 'List' or 'Map' but got 'literal<1>'." »1«[0]; - // $TEST$ no error r"Expected type 'List' or 'Map' but got .*\." + # $TEST$ no error r"Expected type 'List' or 'Map' but got .*\." »listOrNull«[0]; - // $TEST$ no error r"Expected type 'List' or 'Map' but got .*\." + # $TEST$ no error r"Expected type 'List' or 'Map' but got .*\." »mapOrNull«[""]; - // $TEST$ error "Expected type 'List' or 'Map' but got 'Int?'." + # $TEST$ error "Expected type 'List' or 'Map' but got 'Int?'." »intOrNull«[0]; - // $TEST$ no error r"Expected type 'List' or 'Map' but got .*\." + # $TEST$ no error r"Expected type 'List' or 'Map' but got .*\." »myList«[0]; - // $TEST$ no error r"Expected type 'List' or 'Map' but got .*\." + # $TEST$ no error r"Expected type 'List' or 'Map' but got .*\." »myMap«[""]; - // $TEST$ error "Expected type 'List' or 'Map' but got '$unknown'." + # $TEST$ error "Expected type 'List' or 'Map' but got '$unknown'." »unresolved«[0]; } -// Strict checking of type parameter types +# Strict checking of type parameter types class MyClass( p1: T, - // $TEST$ error "Expected type 'List' or 'Map' but got 'T'." + # $TEST$ error "Expected type 'List' or 'Map' but got 'T'." p2: Any? = »p1«[0], ) diff --git a/packages/ttsl-lang/tests/resources/validation/types/checking/infix operations/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/checking/infix operations/main.sdstest index ecb4643d..62a380c9 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/checking/infix operations/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/checking/infix operations/main.sdstest @@ -1,168 +1,168 @@ package tests.validation.types.checking.infixOperations -pipeline myPipeline { +function myFunction () { - // $TEST$ no error r"Expected type 'Boolean' but got .*\." - // $TEST$ no error r"Expected type 'Boolean' but got .*\." + # $TEST$ no error r"Expected type 'Boolean' but got .*\." + # $TEST$ no error r"Expected type 'Boolean' but got .*\." »true« or »true« ; - // $TEST$ error "Expected type 'Boolean' but got 'literal<0>'." - // $TEST$ error "Expected type 'Boolean' but got 'literal<0>'." + # $TEST$ error "Expected type 'Boolean' but got 'literal<0>'." + # $TEST$ error "Expected type 'Boolean' but got 'literal<0>'." »0« or »0«; - // $TEST$ error "Expected type 'Boolean' but got '$unknown'." - // $TEST$ error "Expected type 'Boolean' but got '$unknown'." + # $TEST$ error "Expected type 'Boolean' but got '$unknown'." + # $TEST$ error "Expected type 'Boolean' but got '$unknown'." »unresolved« or »unresolved«; - // $TEST$ no error r"Expected type 'Boolean' but got .*\." - // $TEST$ no error r"Expected type 'Boolean' but got .*\." + # $TEST$ no error r"Expected type 'Boolean' but got .*\." + # $TEST$ no error r"Expected type 'Boolean' but got .*\." »true« and »true«; - // $TEST$ error "Expected type 'Boolean' but got 'literal<0>'." - // $TEST$ error "Expected type 'Boolean' but got 'literal<0>'." + # $TEST$ error "Expected type 'Boolean' but got 'literal<0>'." + # $TEST$ error "Expected type 'Boolean' but got 'literal<0>'." »0« and »0«; - // $TEST$ error "Expected type 'Boolean' but got '$unknown'." - // $TEST$ error "Expected type 'Boolean' but got '$unknown'." + # $TEST$ error "Expected type 'Boolean' but got '$unknown'." + # $TEST$ error "Expected type 'Boolean' but got '$unknown'." »unresolved« and »unresolved«; - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." »0.0« + »0.0«; - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." »0« + »0«; - // $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." - // $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." »""« + »""«; - // $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." - // $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." + # $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." + # $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." »unresolved« + »unresolved«; - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." »0.0« - »0.0«; - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." »0« - »0«; - // $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." - // $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." »""« - »""«; - // $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." - // $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." + # $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." + # $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." »unresolved« - »unresolved«; - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." »0.0« * »0.0«; - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." »0« * »0«; - // $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." - // $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." »""« * »""«; - // $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." - // $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." + # $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." + # $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." »unresolved« * »unresolved«; - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." »0.0« / »0.0«; - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." »0« / »0«; - // $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." - // $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." »""« / »""«; - // $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." - // $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." + # $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." + # $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." »unresolved« / »unresolved«; - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." »0.0« < »0.0«; - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." »0« < »0«; - // $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." - // $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." »""« < »""«; - // $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." - // $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." + # $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." + # $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." »unresolved« < »unresolved«; - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." »0.0« <= »0.0«; - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." »0« <= »0«; - // $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." - // $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." »""« <= »""«; - // $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." - // $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." + # $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." + # $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." »unresolved« <= »unresolved«; - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." »0.0« >= »0.0«; - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." »0« >= »0«; - // $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." - // $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." »""« >= »""«; - // $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." - // $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." + # $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." + # $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." »unresolved« >= »unresolved«; - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." »0.0« > »0.0«; - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." »0« > »0«; - // $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." - // $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." »""« > »""«; - // $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." - // $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." + # $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." + # $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." »unresolved« > »unresolved«; } -// Strict checking of type parameter types +# Strict checking of type parameter types class MyClass( p1: T, - // $TEST$ error "Expected type 'Boolean' but got 'T'." - // $TEST$ error "Expected type 'Boolean' but got 'T'." + # $TEST$ error "Expected type 'Boolean' but got 'T'." + # $TEST$ error "Expected type 'Boolean' but got 'T'." a1: Any? = »p1« or »p1«, - // $TEST$ error "Expected type 'Boolean' but got 'T'." - // $TEST$ error "Expected type 'Boolean' but got 'T'." + # $TEST$ error "Expected type 'Boolean' but got 'T'." + # $TEST$ error "Expected type 'Boolean' but got 'T'." a2: Any? = »p1« and »p1«, - // $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." - // $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." b1: Any? = »p1« + »p1«, - // $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." - // $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." b2: Any? = »p1« - »p1«, - // $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." - // $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." b3: Any? = »p1« * »p1«, - // $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." - // $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." b4: Any? = »p1« / »p1«, - // $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." - // $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." c1: Any? = »p1« < »p1«, - // $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." - // $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." c2: Any? = »p1« <= »p1«, - // $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." - // $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." c3: Any? = »p1« >= »p1«, - // $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." - // $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." c4: Any? = »p1« > »p1«, ) diff --git a/packages/ttsl-lang/tests/resources/validation/types/checking/lists/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/checking/lists/main.sdstest index aa7a127a..d5a8dea5 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/checking/lists/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/checking/lists/main.sdstest @@ -6,11 +6,11 @@ fun twoResults() -> (r1: Int, r2: Int) segment mySegment() { [ - // $TEST$ error "Cannot add a value of type '()' to a list." + # $TEST$ error "Cannot add a value of type '()' to a list." »noResults()«, - // $TEST$ no error r"Cannot add a value of type '.*' to a list\." + # $TEST$ no error r"Cannot add a value of type '.*' to a list\." »oneResult()«, - // $TEST$ error "Cannot add a value of type '(r1: Int, r2: Int)' to a list." + # $TEST$ error "Cannot add a value of type '(r1: Int, r2: Int)' to a list." »twoResults()« ]; } diff --git a/packages/ttsl-lang/tests/resources/validation/types/checking/maps/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/checking/maps/main.sdstest index 5ad3501f..b2786291 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/checking/maps/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/checking/maps/main.sdstest @@ -6,14 +6,14 @@ fun twoResults() -> (r1: Int, r2: Int) segment mySegment() { { - // $TEST$ error "Cannot use a value of type '()' as a map key." - // $TEST$ error "Cannot use a value of type '()' as a map value." + # $TEST$ error "Cannot use a value of type '()' as a map key." + # $TEST$ error "Cannot use a value of type '()' as a map value." »noResults()«: »noResults()«, - // $TEST$ no error r"Cannot use a value of type '.*' as a map key\." - // $TEST$ no error r"Cannot use a value of type '.*' as a map value\." + # $TEST$ no error r"Cannot use a value of type '.*' as a map key\." + # $TEST$ no error r"Cannot use a value of type '.*' as a map value\." »oneResult()«: »oneResult()«, - // $TEST$ error "Cannot use a value of type '(r1: Int, r2: Int)' as a map key." - // $TEST$ error "Cannot use a value of type '(r1: Int, r2: Int)' as a map value." + # $TEST$ error "Cannot use a value of type '(r1: Int, r2: Int)' as a map key." + # $TEST$ error "Cannot use a value of type '(r1: Int, r2: Int)' as a map value." »twoResults()«: »twoResults()« }; } diff --git a/packages/ttsl-lang/tests/resources/validation/types/checking/prefix operations/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/checking/prefix operations/main.sdstest index 5a1c9fcc..d632fe3e 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/checking/prefix operations/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/checking/prefix operations/main.sdstest @@ -2,30 +2,30 @@ package tests.validation.types.checking.prefixOperations segment mySegment() { - // $TEST$ no error r"Expected type 'Boolean' but got .*\." + # $TEST$ no error r"Expected type 'Boolean' but got .*\." not »true«; - // $TEST$ error "Expected type 'Boolean' but got 'literal<0>'." + # $TEST$ error "Expected type 'Boolean' but got 'literal<0>'." not »0«; - // $TEST$ error "Expected type 'Boolean' but got '$unknown'." + # $TEST$ error "Expected type 'Boolean' but got '$unknown'." not »unresolved«; - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." -»0.0«; - // $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." + # $TEST$ no error r"Expected type 'Float' or 'Int' but got .*\." -»0«; - // $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'literal<"">'." -»""«; - // $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." + # $TEST$ error "Expected type 'Float' or 'Int' but got '$unknown'." -»unresolved«; } -// Strict checking of type parameter types +# Strict checking of type parameter types class MyClass( p1: T, - // $TEST$ error "Expected type 'Boolean' but got 'T'." + # $TEST$ error "Expected type 'Boolean' but got 'T'." a: Any? = not »p1«, - // $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." + # $TEST$ error "Expected type 'Float' or 'Int' but got 'T'." b: Any? = -»p1«, ) diff --git a/packages/ttsl-lang/tests/resources/validation/types/checking/type casts/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/checking/type casts/main.sdstest index 10308aa4..d703f7c8 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/checking/type casts/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/checking/type casts/main.sdstest @@ -1,9 +1,9 @@ package tests.validation.types.checking.typeCasts -pipeline test { - // $TEST$ no error "Type casts can only be applied to expressions of unknown type." +function test () { + # $TEST$ no error "Type casts can only be applied to expressions of unknown type." »unresolved« as Int; - // $TEST$ error "Type casts can only be applied to expressions of unknown type." + # $TEST$ error "Type casts can only be applied to expressions of unknown type." »1« as Int; } diff --git a/packages/ttsl-lang/tests/resources/validation/types/checking/type parameter bounds for default values/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/checking/type parameter bounds for default values/main.sdstest index 08129ba3..eafdceea 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/checking/type parameter bounds for default values/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/checking/type parameter bounds for default values/main.sdstest @@ -2,60 +2,60 @@ package tests.validation.types.checking.typeParameterBoundsForDefaultValues class C1< T1 sub Any, - // $TEST$ error "Expected type 'Number' but got 'T1'." + # $TEST$ error "Expected type 'Number' but got 'T1'." T2 sub Number = »T1«, - // $TEST$ error "Expected type 'Number' but got 'Any'." + # $TEST$ error "Expected type 'Number' but got 'Any'." T3 sub Number = »Any«, - // $TEST$ error "Expected type 'T1' but got 'Any'." + # $TEST$ error "Expected type 'T1' but got 'Any'." T4 sub T1 = »Any«, > class C2< T1 sub Number, - // $TEST$ no error r"Expected type '.*' but got '.*'\." + # $TEST$ no error r"Expected type '.*' but got '.*'\." T2 sub Number = »T1«, - // $TEST$ no error r"Expected type '.*' but got '.*'\." + # $TEST$ no error r"Expected type '.*' but got '.*'\." T3 sub Number = »Number«, - // $TEST$ no error r"Expected type '.*' but got '.*'\." + # $TEST$ no error r"Expected type '.*' but got '.*'\." T4 sub T1 = »T1«, - // $TEST$ error "Expected type 'T1' but got 'T2'." + # $TEST$ error "Expected type 'T1' but got 'T2'." T5 sub T1 = »T2«, > class C3< T1 sub Int, - // $TEST$ no error r"Expected type '.*' but got '.*'\." + # $TEST$ no error r"Expected type '.*' but got '.*'\." T2 sub Number = »T1«, - // $TEST$ no error r"Expected type '.*' but got '.*'\." + # $TEST$ no error r"Expected type '.*' but got '.*'\." T3 sub Number = »Int«, - // $TEST$ no error r"Expected type '.*' but got '.*'\." + # $TEST$ no error r"Expected type '.*' but got '.*'\." T4 sub T1 = »Nothing«, > @Pure fun f1< T1 sub Any, - // $TEST$ error "Expected type 'Number' but got 'T1'." + # $TEST$ error "Expected type 'Number' but got 'T1'." T2 sub Number = »T1«, - // $TEST$ error "Expected type 'Number' but got 'Any'." + # $TEST$ error "Expected type 'Number' but got 'Any'." T3 sub Number = »Any«, - // $TEST$ error "Expected type 'T1' but got 'Any'." + # $TEST$ error "Expected type 'T1' but got 'Any'." T4 sub T1 = »Any«, >() @Pure fun f2< T1 sub Number, - // $TEST$ no error r"Expected type '.*' but got '.*'\." + # $TEST$ no error r"Expected type '.*' but got '.*'\." T2 sub Number = »T1«, - // $TEST$ no error r"Expected type '.*' but got '.*'\." + # $TEST$ no error r"Expected type '.*' but got '.*'\." T3 sub Number = »Number«, - // $TEST$ no error r"Expected type '.*' but got '.*'\." + # $TEST$ no error r"Expected type '.*' but got '.*'\." T4 sub T1 = »T1«, - // $TEST$ error "Expected type 'T1' but got 'T2'." + # $TEST$ error "Expected type 'T1' but got 'T2'." T5 sub T1 = »T2«, >() @Pure fun f3< T1 sub Int, - // $TEST$ no error r"Expected type '.*' but got '.*'\." + # $TEST$ no error r"Expected type '.*' but got '.*'\." T2 sub Number = »T1«, - // $TEST$ no error r"Expected type '.*' but got '.*'\." + # $TEST$ no error r"Expected type '.*' but got '.*'\." T3 sub Number = »Int«, - // $TEST$ no error r"Expected type '.*' but got '.*'\." + # $TEST$ no error r"Expected type '.*' but got '.*'\." T4 sub T1 = »Nothing«, >() diff --git a/packages/ttsl-lang/tests/resources/validation/types/checking/type parameter bounds for named types/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/checking/type parameter bounds for named types/main.sdstest index 6b929029..3fe0f1dc 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/checking/type parameter bounds for named types/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/checking/type parameter bounds for named types/main.sdstest @@ -5,29 +5,29 @@ class C2 class C3 @Pure fun f( - // $TEST$ no error r"Expected type '.*' but got '.*'\." + # $TEST$ no error r"Expected type '.*' but got '.*'\." a1: C1<»Any?«>, - // $TEST$ no error r"Expected type '.*' but got '.*'\." + # $TEST$ no error r"Expected type '.*' but got '.*'\." a2: C1, - // $TEST$ no error r"Expected type '.*' but got '.*'\." + # $TEST$ no error r"Expected type '.*' but got '.*'\." a3: C1, - // $TEST$ no error r"Expected type '.*' but got '.*'\." + # $TEST$ no error r"Expected type '.*' but got '.*'\." a4: C1<»T«>, - // $TEST$ no error r"Expected type '.*' but got '.*'\." + # $TEST$ no error r"Expected type '.*' but got '.*'\." b1: C2<»Number«>, - // $TEST$ error "Expected type 'Number' but got 'String'." + # $TEST$ error "Expected type 'Number' but got 'String'." b2: C2<»String«>, - // $TEST$ error "Expected type 'Number' but got 'T'." + # $TEST$ error "Expected type 'Number' but got 'T'." b3: C2<»T«>, - // $TEST$ no error r"Expected type '.*' but got '.*'\." - // $TEST$ no error r"Expected type '.*' but got '.*'\." + # $TEST$ no error r"Expected type '.*' but got '.*'\." + # $TEST$ no error r"Expected type '.*' but got '.*'\." c1: C3<»Number«, »Number«>, - // $TEST$ no error r"Expected type '.*' but got '.*'\." - // $TEST$ no error r"Expected type '.*' but got '.*'\." + # $TEST$ no error r"Expected type '.*' but got '.*'\." + # $TEST$ no error r"Expected type '.*' but got '.*'\." c2: C3<»Number«, »Int«>, - // $TEST$ no error r"Expected type '.*' but got '.*'\." - // $TEST$ error "Expected type 'Int' but got 'Number'." + # $TEST$ no error r"Expected type '.*' but got '.*'\." + # $TEST$ error "Expected type 'Int' but got 'Number'." c3: C3<»Int«, »Number«>, ) diff --git a/packages/ttsl-lang/tests/resources/validation/types/checking/yields/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/checking/yields/main.sdstest index 79a363df..3cdf080c 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/checking/yields/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/checking/yields/main.sdstest @@ -1,16 +1,16 @@ package tests.validation.types.checking.yields segment mySegment1() -> result: Int { - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." yield »result« = 1; } segment mySegment2() -> result: Int { - // $TEST$ error "Expected type 'Int' but got 'literal<"">'." + # $TEST$ error "Expected type 'Int' but got 'literal<"">'." yield »result« = ""; } segment mySegment3() { - // $TEST$ no error r"Expected type .* but got .*\." + # $TEST$ no error r"Expected type .* but got .*\." yield »unresolved« = 1; } diff --git a/packages/ttsl-lang/tests/resources/validation/types/named types/missing required type parameter/dont show this error if the type argument list is missing altogether.sdstest b/packages/ttsl-lang/tests/resources/validation/types/named types/missing required type parameter/dont show this error if the type argument list is missing altogether.sdstest index 1ee6c48c..c80089de 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/named types/missing required type parameter/dont show this error if the type argument list is missing altogether.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/named types/missing required type parameter/dont show this error if the type argument list is missing altogether.sdstest @@ -1,6 +1,6 @@ package tests.validation.other.namedTypes.missingRequiredTypeParameter -// $TEST$ no error r"The type parameters? .* must be set here\." +# $TEST$ no error r"The type parameters? .* must be set here\." class MyClass diff --git a/packages/ttsl-lang/tests/resources/validation/types/named types/missing required type parameter/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/named types/missing required type parameter/main.sdstest index 52049aea..f2720e73 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/named types/missing required type parameter/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/named types/missing required type parameter/main.sdstest @@ -5,28 +5,28 @@ class MyClassWithoutTypeParameter class MyClassWithTypeParameters fun myFunction1( - // $TEST$ no error r"The type parameters? .* must be set here\." + # $TEST$ no error r"The type parameters? .* must be set here\." a1: MyClassWithoutTypeParameter»<>«, - // $TEST$ no error r"The type parameters? .* must be set here\." + # $TEST$ no error r"The type parameters? .* must be set here\." a2: MyClassWithoutTypeParameter»«, - // $TEST$ no error r"The type parameters? .* must be set here\." + # $TEST$ no error r"The type parameters? .* must be set here\." a3: MyClassWithoutTypeParameter»«, - // $TEST$ error "The type parameters 'T1', 'T2' must be set here." + # $TEST$ error "The type parameters 'T1', 'T2' must be set here." b1: MyClassWithTypeParameters»<>«, - // $TEST$ error "The type parameter 'T2' must be set here." + # $TEST$ error "The type parameter 'T2' must be set here." b2: MyClassWithTypeParameters»«, - // $TEST$ error "The type parameter 'T1' must be set here." + # $TEST$ error "The type parameter 'T1' must be set here." b3: MyClassWithTypeParameters»«, - // $TEST$ no error r"The type parameters? .* must be set here\." + # $TEST$ no error r"The type parameters? .* must be set here\." b4: MyClassWithTypeParameters»«, - // $TEST$ no error r"The type parameters? .* must be set here\." + # $TEST$ no error r"The type parameters? .* must be set here\." b5: MyClassWithTypeParameters»«, - // $TEST$ no error r"The type parameters? .* must be set here\." + # $TEST$ no error r"The type parameters? .* must be set here\." d1: Unresolved»<>«, - // $TEST$ no error r"The type parameters? .* must be set here\." + # $TEST$ no error r"The type parameters? .* must be set here\." d2: Unresolved»«, - // $TEST$ no error r"The type parameters? .* must be set here\." + # $TEST$ no error r"The type parameters? .* must be set here\." d3: Unresolved»«, ) diff --git a/packages/ttsl-lang/tests/resources/validation/types/named types/missing type argument list/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/named types/missing type argument list/main.sdstest index e7793cda..1b6302da 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/named types/missing type argument list/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/named types/missing type argument list/main.sdstest @@ -5,23 +5,23 @@ class MyClassWithRequiredTypeParameters class MyClassWithOptionalTypeParameters fun myFunction( - // $TEST$ no error r"The type '\w*' has required type parameters, so a type argument list must be added\." + # $TEST$ no error r"The type '\w*' has required type parameters, so a type argument list must be added\." a1: »MyClassWithoutTypeParameters«, - // $TEST$ no error r"The type '\w*' has required type parameters, so a type argument list must be added\." + # $TEST$ no error r"The type '\w*' has required type parameters, so a type argument list must be added\." a2: »MyClassWithoutTypeParameters«<>, - // $TEST$ error "The type 'MyClassWithRequiredTypeParameters' has required type parameters, so a type argument list must be added." + # $TEST$ error "The type 'MyClassWithRequiredTypeParameters' has required type parameters, so a type argument list must be added." b1: »MyClassWithRequiredTypeParameters«, - // $TEST$ no error r"The type '\w*' has required type parameters, so a type argument list must be added\." + # $TEST$ no error r"The type '\w*' has required type parameters, so a type argument list must be added\." b2: »MyClassWithRequiredTypeParameters«<>, - // $TEST$ no error r"The type '\w*' has required type parameters, so a type argument list must be added\." + # $TEST$ no error r"The type '\w*' has required type parameters, so a type argument list must be added\." c1: »MyClassWithOptionalTypeParameters«, - // $TEST$ no error r"The type '\w*' has required type parameters, so a type argument list must be added\." + # $TEST$ no error r"The type '\w*' has required type parameters, so a type argument list must be added\." c2: »MyClassWithOptionalTypeParameters«<>, - // $TEST$ no error r"The type '\w*' has required type parameters, so a type argument list must be added\." + # $TEST$ no error r"The type '\w*' has required type parameters, so a type argument list must be added\." d1: »UnresolvedClass«, - // $TEST$ no error r"The type '\w*' has required type parameters, so a type argument list must be added\." + # $TEST$ no error r"The type '\w*' has required type parameters, so a type argument list must be added\." d2: »UnresolvedClass«<>, ) diff --git a/packages/ttsl-lang/tests/resources/validation/types/type hints/missing for attribute/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/type hints/missing for attribute/main.sdstest index 06b9c856..b8d46c41 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/type hints/missing for attribute/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/type hints/missing for attribute/main.sdstest @@ -1,9 +1,9 @@ package tests.validation.types.typeHints.missingForAttribute class MyClass { - // $TEST$ error "An attribute must have a type hint." + # $TEST$ error "An attribute must have a type hint." attr »myAttribute1« - // $TEST$ no error "An attribute must have a type hint." + # $TEST$ no error "An attribute must have a type hint." attr »myAttribute2«: Int } diff --git a/packages/ttsl-lang/tests/resources/validation/types/type hints/missing for parameter/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/type hints/missing for parameter/main.sdstest index f7250652..7bb0cdb8 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/type hints/missing for parameter/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/type hints/missing for parameter/main.sdstest @@ -1,39 +1,39 @@ package tests.validation.types.typeHints.missingForParameter -// $TEST$ error "A parameter must have a type hint." -// $TEST$ no error "A parameter must have a type hint." +# $TEST$ error "A parameter must have a type hint." +# $TEST$ no error "A parameter must have a type hint." annotation MyAnnotation(»a«, »b«: Int) -// $TEST$ error "A parameter must have a type hint." -// $TEST$ no error "A parameter must have a type hint." +# $TEST$ error "A parameter must have a type hint." +# $TEST$ no error "A parameter must have a type hint." class MyClass(»a«, »b«: Int) { - // $TEST$ error "A parameter must have a type hint." - // $TEST$ no error "A parameter must have a type hint." + # $TEST$ error "A parameter must have a type hint." + # $TEST$ no error "A parameter must have a type hint." class MyClass(»a«, »b«: Int) {} - // $TEST$ error "A parameter must have a type hint." - // $TEST$ no error "A parameter must have a type hint." + # $TEST$ error "A parameter must have a type hint." + # $TEST$ no error "A parameter must have a type hint." fun myFunction(»a«, »b«: Int) } -// $TEST$ error "A parameter must have a type hint." -// $TEST$ no error "A parameter must have a type hint." +# $TEST$ error "A parameter must have a type hint." +# $TEST$ no error "A parameter must have a type hint." fun myFunction(»a«, »b«: Int) -pipeline myPipeline { - // $TEST$ no error "A parameter must have a type hint." +function myFunction () { + # $TEST$ no error "A parameter must have a type hint." (»a«) -> a; - // $TEST$ no error "A parameter must have a type hint." + # $TEST$ no error "A parameter must have a type hint." (»a«) {}; } -// $TEST$ error "A parameter must have a type hint." -// $TEST$ no error "A parameter must have a type hint." +# $TEST$ error "A parameter must have a type hint." +# $TEST$ no error "A parameter must have a type hint." segment mySegment1(»a«, »b«: Int) {} -// $TEST$ error "A parameter must have a type hint." -// $TEST$ no error "A parameter must have a type hint." +# $TEST$ error "A parameter must have a type hint." +# $TEST$ no error "A parameter must have a type hint." segment mySegment2( f: (»a«, »b«: Int) -> () ) {} diff --git a/packages/ttsl-lang/tests/resources/validation/types/type hints/missing for result/main.sdstest b/packages/ttsl-lang/tests/resources/validation/types/type hints/missing for result/main.sdstest index 29e4df16..3382cbf0 100644 --- a/packages/ttsl-lang/tests/resources/validation/types/type hints/missing for result/main.sdstest +++ b/packages/ttsl-lang/tests/resources/validation/types/type hints/missing for result/main.sdstest @@ -1,21 +1,21 @@ package tests.validation.types.typeHints.missingForResult class MyClass { - // $TEST$ error "A result must have a type hint." - // $TEST$ no error "A result must have a type hint." + # $TEST$ error "A result must have a type hint." + # $TEST$ no error "A result must have a type hint." fun myFunction() -> (»a«, »b«: Int) } -// $TEST$ error "A result must have a type hint." -// $TEST$ no error "A result must have a type hint." +# $TEST$ error "A result must have a type hint." +# $TEST$ no error "A result must have a type hint." fun myFunction() -> (»a«, »b«: Int) -// $TEST$ error "A result must have a type hint." -// $TEST$ no error "A result must have a type hint." +# $TEST$ error "A result must have a type hint." +# $TEST$ no error "A result must have a type hint." segment mySegment1() -> (»a«, »b«: Int) {} -// $TEST$ error "A result must have a type hint." -// $TEST$ no error "A result must have a type hint." +# $TEST$ error "A result must have a type hint." +# $TEST$ no error "A result must have a type hint." segment mySegment2( f: () -> (»a«, »b«: Int) ) {} diff --git a/packages/ttsl-vscode/language-configuration.json b/packages/ttsl-vscode/language-configuration.json index 350fc8ad..927dadfd 100644 --- a/packages/ttsl-vscode/language-configuration.json +++ b/packages/ttsl-vscode/language-configuration.json @@ -1,6 +1,6 @@ { "comments": { - "lineComment": "//", + "lineComment": "#", "blockComment": ["/*", "*/"] }, "brackets": [ diff --git a/packages/ttsl-vscode/snippets/ttsl.json b/packages/ttsl-vscode/snippets/ttsl.json index 6e27696f..63cf5171 100644 --- a/packages/ttsl-vscode/snippets/ttsl.json +++ b/packages/ttsl-vscode/snippets/ttsl.json @@ -14,6 +14,11 @@ "body": ["/*", " * $0", " */"], "description": "A block comment." }, + "Line Comment": { + "prefix": ["line-comment"], + "body": ["#", " * $0"], + "description": "A line comment." + }, "Documentation Comment": { "prefix": ["documentation-comment"], "body": ["/**", " * $0", " */"], diff --git a/packages/ttsl-vscode/syntaxes/ttsl.tmLanguage.json b/packages/ttsl-vscode/syntaxes/ttsl.tmLanguage.json index 9c795d7c..ef94b651 100644 --- a/packages/ttsl-vscode/syntaxes/ttsl.tmLanguage.json +++ b/packages/ttsl-vscode/syntaxes/ttsl.tmLanguage.json @@ -65,7 +65,7 @@ "patterns": [ { "name": "comment.line.double-slash.ttsl", - "begin": "//", + "begin": "#", "end": "(?=$)" }, { From ed1b7b88fe6727c9d258efc1df816014bc108164 Mon Sep 17 00:00:00 2001 From: methr0 Date: Tue, 20 Aug 2024 18:51:37 +0200 Subject: [PATCH 145/183] update old links (code documentation doesn't have a new one yet) --- docs/README.md | 2 +- packages/ttsl-vscode/README.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/README.md b/docs/README.md index 1f4e7783..66b301fc 100644 --- a/docs/README.md +++ b/docs/README.md @@ -2,4 +2,4 @@ A domain-specific language (DSL) to simulate taxes and transfers. -This project is based on the [TTSL](https://github.com/TTSL/DSL) DSL for statically checked Data Science programs. +This project is based on the [TTSL](https://github.com/SEEDS-Group/TTSL) DSL for statically checked Data Science programs. diff --git a/packages/ttsl-vscode/README.md b/packages/ttsl-vscode/README.md index a57962c9..d3e5f2f3 100644 --- a/packages/ttsl-vscode/README.md +++ b/packages/ttsl-vscode/README.md @@ -4,4 +4,4 @@ Safely develop Data Science programs with a statically checked domain specific l ## Documentation -You can find the full documentation [here](https://dsl.TTSL.com). +You can find the full documentation [here]() <- TODO. From 0cc4d6f1672ed08c0a68ed30fe0767ceef0a57ed Mon Sep 17 00:00:00 2001 From: methr0 Date: Tue, 20 Aug 2024 19:18:12 +0200 Subject: [PATCH 146/183] make MegaLinter happy --- .../generation/ttsl-python-generator.ts | 21 +------------- .../src/language/helpers/ttsl-node-mapper.ts | 1 - .../src/language/lsp/ttsl-formatter.ts | 11 -------- .../lsp/ttsl-semantic-token-provider.ts | 6 +--- .../lsp/ttsl-signature-help-provider.ts | 1 - .../src/language/partialEvaluation/model.ts | 2 -- .../ttsl-partial-evaluator.ts | 28 ++----------------- .../language/scoping/ttsl-scope-provider.ts | 1 - .../src/language/typing/ttsl-type-checker.ts | 2 -- .../src/language/typing/ttsl-type-computer.ts | 2 +- .../src/language/validation/aggregation.ts | 12 ++++---- .../src/language/validation/names.ts | 2 -- .../validation/other/argumentLists.ts | 1 - .../other/declarations/parameters.ts | 4 +-- .../other/declarations/placeholders.ts | 4 +-- .../other/statements/assignments.ts | 4 +-- .../src/language/validation/style.ts | 2 +- .../src/language/validation/types.ts | 8 ++---- .../workspace/ttsl-package-manager.ts | 2 +- .../safe-ds-comment-provider.test.ts | 1 - .../safe-ds-documentation-provider.test.ts | 1 - 21 files changed, 20 insertions(+), 96 deletions(-) diff --git a/packages/ttsl-lang/src/language/generation/ttsl-python-generator.ts b/packages/ttsl-lang/src/language/generation/ttsl-python-generator.ts index 664a5e30..355163cc 100644 --- a/packages/ttsl-lang/src/language/generation/ttsl-python-generator.ts +++ b/packages/ttsl-lang/src/language/generation/ttsl-python-generator.ts @@ -59,18 +59,13 @@ import { isTslConstant, TslConstant, TslTimespan, - isTslData, - TslData, isTslBlock, TslTimeunit, - isTslExpression, isTslString, isTslParenthesizedExpression, - isTslResult, isTslReturnStatement, isTslLiteral, isTslInt, - isTslDate, isTslNull, isTslBoolean, isTslFloat, @@ -94,7 +89,6 @@ import { TTSLNodeMapper } from '../helpers/ttsl-node-mapper.js'; import { TTSLPartialEvaluator } from '../partialEvaluation/ttsl-partial-evaluator.js'; import { TTSLServices } from '../ttsl-module.js'; import { TTSLFunction } from '../builtins/ttsl-ds-functions.js'; -import { Console } from 'console'; export const CODEGEN_PREFIX = '__gen_'; @@ -155,18 +149,6 @@ const UTILITY_NULL_SAFE_INDEXED_ACCESS: UtilityFunction = { typeVariables: [`${CODEGEN_PREFIX}T`], }; -const UTILITY_NULL_SAFE_MEMBER_ACCESS: UtilityFunction = { - name: `${CODEGEN_PREFIX}null_safe_member_access`, - code: expandToNode`def ${CODEGEN_PREFIX}null_safe_member_access(receiver: Any, member_name: str) -> ${CODEGEN_PREFIX}T | None:` - .appendNewLine() - .indent({ - indentedChildren: ['return getattr(receiver, member_name) if receiver is not None else None'], - indentation: PYTHON_INDENT, - }), - imports: [{ importPath: 'typing', declarationName: 'Any' }], - typeVariables: [`${CODEGEN_PREFIX}T`], -}; - const UTILITY_AGGREGATION: UtilityFunction = { name: `${CODEGEN_PREFIX}aggregation`, code: expandToNode`def ${CODEGEN_PREFIX}aggregation(dataFrame: pd, data, id, function: str) -> pd | None:` @@ -1101,9 +1083,8 @@ export class TTSLPythonGenerator { private generateFunctionParameter( funct: TslFunction, - frame: GenerationInfoFrame, ): CompositeGeneratorNode | undefined { - if(funct.timeunit != undefined|| funct.groupedBy != undefined){ + if(funct.timeunit !== undefined|| funct.groupedBy !== undefined){ return expandToNode`timeunit = None, groupedBy = None, date = None` } return undefined diff --git a/packages/ttsl-lang/src/language/helpers/ttsl-node-mapper.ts b/packages/ttsl-lang/src/language/helpers/ttsl-node-mapper.ts index ab27bede..1f8e75e4 100644 --- a/packages/ttsl-lang/src/language/helpers/ttsl-node-mapper.ts +++ b/packages/ttsl-lang/src/language/helpers/ttsl-node-mapper.ts @@ -115,7 +115,6 @@ export class TTSLNodeMapper { // link the arguments of the call properly, even if the user forgot to make the call null-safe. In this // case, an error is being shown anyway. const receiverType = this.typeComputer().computeType(node.receiver); - const nonNullableReceiverType = this.typeComputer().computeNonNullableType(receiverType); if(isTslReference(node.receiver)){ if(isTslCallable(node.receiver.target.ref)){ diff --git a/packages/ttsl-lang/src/language/lsp/ttsl-formatter.ts b/packages/ttsl-lang/src/language/lsp/ttsl-formatter.ts index 00bdd1c6..7023d317 100644 --- a/packages/ttsl-lang/src/language/lsp/ttsl-formatter.ts +++ b/packages/ttsl-lang/src/language/lsp/ttsl-formatter.ts @@ -7,17 +7,6 @@ import newLines = Formatting.newLines; import noSpace = Formatting.noSpace; import oneSpace = Formatting.oneSpace; -const newLinesWithIndent = function (count: number, options?: FormattingActionOptions): FormattingAction { - return { - options: options ?? {}, - moves: [ - { - tabs: 1, - lines: count, - }, - ], - }; -}; export class TTSLFormatter extends AbstractFormatter { protected override format(node: AstNode): void { diff --git a/packages/ttsl-lang/src/language/lsp/ttsl-semantic-token-provider.ts b/packages/ttsl-lang/src/language/lsp/ttsl-semantic-token-provider.ts index df567fca..c2b0b5b9 100644 --- a/packages/ttsl-lang/src/language/lsp/ttsl-semantic-token-provider.ts +++ b/packages/ttsl-lang/src/language/lsp/ttsl-semantic-token-provider.ts @@ -1,5 +1,5 @@ import { AbstractSemanticTokenProvider, SemanticTokenAcceptor } from 'langium/lsp'; -import { AstNode, AstUtils } from 'langium'; +import { AstNode } from 'langium'; import { SemanticTokenModifiers, SemanticTokenTypes } from 'vscode-languageserver'; import { isTslArgument, @@ -16,10 +16,6 @@ import { import { TTSLServices } from '../ttsl-module.js'; export class TTSLSemanticTokenProvider extends AbstractSemanticTokenProvider { - constructor(services: TTSLServices) { - super(services); - } - protected highlightElement(node: AstNode, acceptor: SemanticTokenAcceptor): void { if (isTslArgument(node)) { if (node.parameter) { diff --git a/packages/ttsl-lang/src/language/lsp/ttsl-signature-help-provider.ts b/packages/ttsl-lang/src/language/lsp/ttsl-signature-help-provider.ts index bb61001f..6cb54385 100644 --- a/packages/ttsl-lang/src/language/lsp/ttsl-signature-help-provider.ts +++ b/packages/ttsl-lang/src/language/lsp/ttsl-signature-help-provider.ts @@ -4,7 +4,6 @@ import { CstUtils, type DocumentationProvider, GrammarUtils, - isNamed, type LangiumDocument, type MaybePromise, } from 'langium'; diff --git a/packages/ttsl-lang/src/language/partialEvaluation/model.ts b/packages/ttsl-lang/src/language/partialEvaluation/model.ts index 1da49900..0c469958 100644 --- a/packages/ttsl-lang/src/language/partialEvaluation/model.ts +++ b/packages/ttsl-lang/src/language/partialEvaluation/model.ts @@ -3,10 +3,8 @@ import { TslResult, type TslCallable, type TslDeclaration, - type TslExpression, type TslParameter, } from '../generated/ast.js'; -import { getParameters } from '../helpers/nodeProperties.js'; import { escapeString } from '../grammar/ttsl-value-converter.js'; export type ParameterSubstitutions = Map; diff --git a/packages/ttsl-lang/src/language/partialEvaluation/ttsl-partial-evaluator.ts b/packages/ttsl-lang/src/language/partialEvaluation/ttsl-partial-evaluator.ts index 97f48e37..5dc28bf8 100644 --- a/packages/ttsl-lang/src/language/partialEvaluation/ttsl-partial-evaluator.ts +++ b/packages/ttsl-lang/src/language/partialEvaluation/ttsl-partial-evaluator.ts @@ -39,11 +39,6 @@ import { type TslPrefixOperation, type TslTemplateString, isTslAggregation, - TslAggregation, - TslModifier, - isTslGroupedBy, - isTslVisibility, - isTslTimeunit, isTslString, isTslParenthesizedExpression, } from '../generated/ast.js'; @@ -130,7 +125,7 @@ export class TTSLPartialEvaluator { if (isTslAssignee(node)) { return this.evaluateAssignee(node, substitutions, visited); } else if (isTslDeclaration(node)) { - return this.evaluateDeclaration(node, substitutions, visited); + return this.evaluateDeclaration(node, substitutions); } else if (isTslExpression(node)) { return this.evaluateExpression(node, substitutions, visited); } /* c8 ignore start */ else { @@ -167,7 +162,6 @@ export class TTSLPartialEvaluator { private evaluateDeclaration( node: TslDeclaration, substitutions: ParameterSubstitutions, - visited: VisitedState[], ): EvaluatedNode { if (isTslFunction(node)) { return new NamedCallable(node); @@ -223,7 +217,7 @@ export class TTSLPartialEvaluator { } else if (isTslTypeCast(node)) { return this.evaluateWithRecursionCheck(node.expression, substitutions, visited); } else if (isTslAggregation(node)) { - return this.evaluateAggregation(node, substitutions, visited); + return this.evaluateAggregation(); } else if (isTslParenthesizedExpression(node)) { return this.evaluateWithRecursionCheck(node, substitutions, visited); } /* c8 ignore start */ else { @@ -490,26 +484,10 @@ export class TTSLPartialEvaluator { return UnknownEvaluatedNode; } - private evaluateAggregation(node: TslAggregation, substitutions: ParameterSubstitutions, visited: VisitedState[]): EvaluatedNode { - const data = this.evaluateExpression(node.data, substitutions, visited).unwrap(); - const funct = this.evaluateExpression(node.function, substitutions, visited).unwrap(); - const groupedBy = this.evaluateModifier(node.groupedBy, substitutions, visited).unwrap(); - + private evaluateAggregation(): EvaluatedNode { return UnknownEvaluatedNode; } - private evaluateModifier(node: TslModifier, substitutions: ParameterSubstitutions, visited: VisitedState[]): EvaluatedNode { - if (isTslGroupedBy(node)) { - return this.evaluateExpression(node.id, substitutions, visited); - } else if (isTslVisibility(node)) { - throw new Error(`noch nicht evaluierbar`); - } else if (isTslTimeunit(node)) { - throw new Error(`noch nicht evaluierbar`); - }/* c8 ignore start */ else { - throw new Error(`Unexpected Modifier type: ${node.$type}`); - } /* c8 ignore stop */ - } - private evaluateCallableCall( callable: TslCallable | TslParameter, args: TslArgument[], diff --git a/packages/ttsl-lang/src/language/scoping/ttsl-scope-provider.ts b/packages/ttsl-lang/src/language/scoping/ttsl-scope-provider.ts index f61f95a9..4aff0a1c 100644 --- a/packages/ttsl-lang/src/language/scoping/ttsl-scope-provider.ts +++ b/packages/ttsl-lang/src/language/scoping/ttsl-scope-provider.ts @@ -44,7 +44,6 @@ import { } from '../helpers/nodeProperties.js'; import { TTSLNodeMapper } from '../helpers/ttsl-node-mapper.js'; import { TTSLServices } from '../ttsl-module.js'; -import { TTSLTypeComputer } from '../typing/ttsl-type-computer.js'; import { TTSLPackageManager } from '../workspace/ttsl-package-manager.js'; export class TTSLScopeProvider extends DefaultScopeProvider { diff --git a/packages/ttsl-lang/src/language/typing/ttsl-type-checker.ts b/packages/ttsl-lang/src/language/typing/ttsl-type-checker.ts index 3d723258..766cbf74 100644 --- a/packages/ttsl-lang/src/language/typing/ttsl-type-checker.ts +++ b/packages/ttsl-lang/src/language/typing/ttsl-type-checker.ts @@ -1,4 +1,3 @@ -import { TTSLServices } from '../ttsl-module.js'; import { AnyType, DictionaryType, @@ -8,7 +7,6 @@ import { export class TTSLTypeChecker { - constructor(services: TTSLServices) {} // ----------------------------------------------------------------------------------------------------------------- // General cases diff --git a/packages/ttsl-lang/src/language/typing/ttsl-type-computer.ts b/packages/ttsl-lang/src/language/typing/ttsl-type-computer.ts index 83984038..5c196074 100644 --- a/packages/ttsl-lang/src/language/typing/ttsl-type-computer.ts +++ b/packages/ttsl-lang/src/language/typing/ttsl-type-computer.ts @@ -346,7 +346,7 @@ export class TTSLTypeComputer { /** * Computes the lowest common supertype for the given types. The result is simplified as much as possible. */ - private lowestCommonSupertype(types: Type[], options: LowestCommonSupertypeOptions = {}): Type { + private lowestCommonSupertype(types: Type[]): Type { // A single type is its own lowest common supertype if (types.length === 1) { return types[0]!; diff --git a/packages/ttsl-lang/src/language/validation/aggregation.ts b/packages/ttsl-lang/src/language/validation/aggregation.ts index 796c1d6a..daef5ba2 100644 --- a/packages/ttsl-lang/src/language/validation/aggregation.ts +++ b/packages/ttsl-lang/src/language/validation/aggregation.ts @@ -58,11 +58,11 @@ export const groupedFunctionHasValidID = () => { export const groupedFunctionHasAggregation = () => { return (node: TslFunction, accept: ValidationAcceptor) => { let id = node.groupedBy?.id.target.ref?.name - if (id != undefined){ + if (id !== undefined){ let parameters = getParameters(node) let isGrouped = false parameters.forEach(elm => { - if (elm.groupedBy?.id.target.ref?.name == id){ + if (elm.groupedBy?.id.target.ref?.name === id){ isGrouped = true } }); @@ -82,11 +82,11 @@ export const groupedFunctionHasAggregation = () => { function hasAggregation(statements: TslStatement[]| undefined, id: string): boolean{ let result = false - if(statements == undefined){ + if(statements === undefined){ return result } statements.forEach(elm => { - if(isTslExpressionStatement(elm) && isTslAggregation(elm.expression) && elm.expression.groupedBy.id.target.ref?.name == id){ + if(isTslExpressionStatement(elm) && isTslAggregation(elm.expression) && elm.expression.groupedBy.id.target.ref?.name === id){ result = true } else if(isTslConditionalStatement(elm)){ result = (hasAggregation(elm.ifBlock.statements, id) && hasAggregation(elm.elseBlock?.statements, id)) @@ -96,8 +96,8 @@ function hasAggregation(statements: TslStatement[]| undefined, id: string): bool if(isTslAggregation(elm.expression)){ result = true }else if(elm.assigneeList?.assignees.filter(isTslPlaceholder)){ - elm.assigneeList.assignees.filter(isTslPlaceholder).forEach(elm => { - if(elm.groupedBy?.id.target.ref?.name == id){ + elm.assigneeList.assignees.filter(isTslPlaceholder).forEach(placeholder => { + if(placeholder.groupedBy?.id.target.ref?.name === id){ result = true } }) diff --git a/packages/ttsl-lang/src/language/validation/names.ts b/packages/ttsl-lang/src/language/validation/names.ts index 4b47a14b..cb108425 100644 --- a/packages/ttsl-lang/src/language/validation/names.ts +++ b/packages/ttsl-lang/src/language/validation/names.ts @@ -18,8 +18,6 @@ import { getImports, getModuleMembers, getPackageName, - getParameters, - getResults, } from '../helpers/nodeProperties.js'; import { TTSLServices } from '../ttsl-module.js'; diff --git a/packages/ttsl-lang/src/language/validation/other/argumentLists.ts b/packages/ttsl-lang/src/language/validation/other/argumentLists.ts index caab7fb8..c208e6c2 100644 --- a/packages/ttsl-lang/src/language/validation/other/argumentLists.ts +++ b/packages/ttsl-lang/src/language/validation/other/argumentLists.ts @@ -77,7 +77,6 @@ export const argumentListMustNotSetParameterMultipleTimes = (services: TTSLServi return (node: TslArgumentList, accept: ValidationAcceptor): void => { // We already report other errors in this case const containingCall = AstUtils.getContainerOfType(node, isTslCall); - const callable = nodeMapper.callToCallable(containingCall); const args = getArguments(node); const duplicates = duplicatesBy(args, argumentToParameterOrUndefined); diff --git a/packages/ttsl-lang/src/language/validation/other/declarations/parameters.ts b/packages/ttsl-lang/src/language/validation/other/declarations/parameters.ts index b61f45a1..9f6e24e7 100644 --- a/packages/ttsl-lang/src/language/validation/other/declarations/parameters.ts +++ b/packages/ttsl-lang/src/language/validation/other/declarations/parameters.ts @@ -1,5 +1,5 @@ -import { AstUtils, ValidationAcceptor } from 'langium'; -import { isTslCallable, TslParameter } from '../../../generated/ast.js'; +import { ValidationAcceptor } from 'langium'; +import { TslParameter } from '../../../generated/ast.js'; import { Parameter } from '../../../helpers/nodeProperties.js'; import { TTSLServices } from '../../../ttsl-module.js'; diff --git a/packages/ttsl-lang/src/language/validation/other/declarations/placeholders.ts b/packages/ttsl-lang/src/language/validation/other/declarations/placeholders.ts index f1be2499..597832a9 100644 --- a/packages/ttsl-lang/src/language/validation/other/declarations/placeholders.ts +++ b/packages/ttsl-lang/src/language/validation/other/declarations/placeholders.ts @@ -1,8 +1,6 @@ import { isTslAssignment, isTslBlock, - isTslParameter, - isTslPlaceholder, isTslReference, isTslStatement, TslPlaceholder, @@ -15,7 +13,7 @@ import { last } from '../../../../helpers/collections.js'; export const CODE_PLACEHOLDER_UNUSED = 'placeholder/unused'; -export const placeholdersMustNotBeAnAlias = (node: TslPlaceholder, accept: ValidationAcceptor): void => { +export const placeholdersMustNotBeAnAlias = (node: TslPlaceholder): void => { if (node.$containerIndex ?? 0 > 0) { return; } diff --git a/packages/ttsl-lang/src/language/validation/other/statements/assignments.ts b/packages/ttsl-lang/src/language/validation/other/statements/assignments.ts index dd0897c3..f7cbdefb 100644 --- a/packages/ttsl-lang/src/language/validation/other/statements/assignments.ts +++ b/packages/ttsl-lang/src/language/validation/other/statements/assignments.ts @@ -1,4 +1,4 @@ -import { isTslCall, isTslFunction, TslAssignment} from '../../../generated/ast.js'; +import { isTslFunction, TslAssignment} from '../../../generated/ast.js'; import { ValidationAcceptor } from 'langium'; import { TTSLServices } from '../../../ttsl-module.js'; import { getResults, getAssignees } from '../../../helpers/nodeProperties.js'; @@ -21,8 +21,6 @@ export const assignmentAssigneeMustGetValue = }; export const assignmentShouldNotImplicitlyIgnoreResult = (services: TTSLServices) => { - const nodeMapper = services.helpers.NodeMapper; - return (node: TslAssignment, accept: ValidationAcceptor): void => { const expression = node.expression; if (!isTslFunction(expression)) { diff --git a/packages/ttsl-lang/src/language/validation/style.ts b/packages/ttsl-lang/src/language/validation/style.ts index 14426926..ff81905f 100644 --- a/packages/ttsl-lang/src/language/validation/style.ts +++ b/packages/ttsl-lang/src/language/validation/style.ts @@ -192,7 +192,7 @@ export const functionResultListShouldNotBeEmpty = (services: TTSLServices) => { return; } - if (node.result && node.body.statements.filter(isTslReturnStatement).at(0) == undefined) { + if (node.result && node.body.statements.filter(isTslReturnStatement).at(0) === undefined) { accept('info', 'This result list can be removed.', { node, property: 'result', diff --git a/packages/ttsl-lang/src/language/validation/types.ts b/packages/ttsl-lang/src/language/validation/types.ts index 731a71ea..b4e0ef53 100644 --- a/packages/ttsl-lang/src/language/validation/types.ts +++ b/packages/ttsl-lang/src/language/validation/types.ts @@ -40,7 +40,7 @@ export const callArgumentTypesMustMatchParameterTypes = (services: TTSLServices) const argumentType = typeComputer.computeType(argument); const parameterType = typeComputer.computeType(parameter); - if (!(argumentType.toString == parameterType.toString || parameterType instanceof AnyType)) { + if (!(argumentType.toString === parameterType.toString || parameterType instanceof AnyType)) { accept('error', `Expected type '${parameterType}' but got '${argumentType}'.`, { node: argument, property: 'value', @@ -97,7 +97,6 @@ export const indexedAccessReceiverMustBeListOrMap = (services: TTSLServices) => }; export const indexedAccessIndexMustHaveCorrectType = (services: TTSLServices) => { - const typeChecker = services.types.TypeChecker; const typeComputer = services.types.TypeComputer; return (node: TslIndexedAccess, accept: ValidationAcceptor): void => { @@ -116,7 +115,6 @@ export const indexedAccessIndexMustHaveCorrectType = (services: TTSLServices) => }; export const infixOperationOperandsMustHaveCorrectType = (services: TTSLServices) => { - const typeChecker = services.types.TypeChecker; const typeComputer = services.types.TypeComputer; return (node: TslInfixOperation, accept: ValidationAcceptor): void => { @@ -218,7 +216,6 @@ export const mapMustNotContainNamedTuples = (services: TTSLServices) => { }; export const parameterDefaultValueTypeMustMatchParameterType = (services: TTSLServices) => { - const typeChecker = services.types.TypeChecker; const typeComputer = services.types.TypeComputer; return (node: TslParameter, accept: ValidationAcceptor) => { @@ -230,7 +227,7 @@ export const parameterDefaultValueTypeMustMatchParameterType = (services: TTSLSe const defaultValueType = typeComputer.computeType(defaultValue); const parameterType = typeComputer.computeType(node); - if (!(defaultValueType.toString == parameterType.toString)) { + if (!(defaultValueType.toString === parameterType.toString)) { accept('error', `Expected type '${parameterType}' but got '${defaultValueType}'.`, { node, property: 'defaultValue', @@ -241,7 +238,6 @@ export const parameterDefaultValueTypeMustMatchParameterType = (services: TTSLSe }; export const prefixOperationOperandMustHaveCorrectType = (services: TTSLServices) => { - const typeChecker = services.types.TypeChecker; const typeComputer = services.types.TypeComputer; return (node: TslPrefixOperation, accept: ValidationAcceptor): void => { diff --git a/packages/ttsl-lang/src/language/workspace/ttsl-package-manager.ts b/packages/ttsl-lang/src/language/workspace/ttsl-package-manager.ts index 465dfea7..010480cf 100644 --- a/packages/ttsl-lang/src/language/workspace/ttsl-package-manager.ts +++ b/packages/ttsl-lang/src/language/workspace/ttsl-package-manager.ts @@ -9,7 +9,7 @@ import { LangiumDocuments, } from 'langium'; import { getPackageName, isPackagePrivate, isPrivate } from '../helpers/nodeProperties.js'; -import { isTslDeclaration, isTslFunction } from '../generated/ast.js'; +import { isTslDeclaration } from '../generated/ast.js'; export class TTSLPackageManager { private readonly astNodeLocator: AstNodeLocator; diff --git a/packages/ttsl-lang/tests/language/documentation/safe-ds-comment-provider.test.ts b/packages/ttsl-lang/tests/language/documentation/safe-ds-comment-provider.test.ts index 4930f834..2fc610eb 100644 --- a/packages/ttsl-lang/tests/language/documentation/safe-ds-comment-provider.test.ts +++ b/packages/ttsl-lang/tests/language/documentation/safe-ds-comment-provider.test.ts @@ -144,7 +144,6 @@ describe('TTSLCommentProvider', () => { throw new AssertionError({ message: 'Node not found.' }); } - console.log(node.$type + ': ' + commentProvider.getComment(node) + '\n'); expect(commentProvider.getComment(node)).toStrictEqual(expectedComment); }); }); diff --git a/packages/ttsl-lang/tests/language/documentation/safe-ds-documentation-provider.test.ts b/packages/ttsl-lang/tests/language/documentation/safe-ds-documentation-provider.test.ts index 944b4351..9a352456 100644 --- a/packages/ttsl-lang/tests/language/documentation/safe-ds-documentation-provider.test.ts +++ b/packages/ttsl-lang/tests/language/documentation/safe-ds-documentation-provider.test.ts @@ -2,7 +2,6 @@ import { AstNode, EmptyFileSystem } from 'langium'; import { describe, expect, it } from 'vitest'; import { normalizeLineBreaks } from '../../../src/helpers/strings.js'; import { - isTslConstant, isTslFunction, isTslParameter, isTslResult, From 118ffaed87beeea1a8c7d7e10545ead4939be8f1 Mon Sep 17 00:00:00 2001 From: methr0 Date: Tue, 20 Aug 2024 19:43:07 +0200 Subject: [PATCH 147/183] make MegaLinter happy --- .../src/language/builtins/ttsl-ds-functions.ts | 2 +- .../ttsl-lang/src/language/helpers/ttsl-node-mapper.ts | 1 - packages/ttsl-lang/src/language/lsp/ttsl-formatter.ts | 2 +- .../src/language/lsp/ttsl-semantic-token-provider.ts | 1 - .../src/language/typing/ttsl-type-computer.ts | 10 ---------- .../src/language/validation/other/argumentLists.ts | 2 -- .../validation/other/statements/assignments.ts | 2 +- packages/ttsl-lang/src/language/validation/types.ts | 1 - 8 files changed, 3 insertions(+), 18 deletions(-) diff --git a/packages/ttsl-lang/src/language/builtins/ttsl-ds-functions.ts b/packages/ttsl-lang/src/language/builtins/ttsl-ds-functions.ts index 2f8eccbc..01146412 100644 --- a/packages/ttsl-lang/src/language/builtins/ttsl-ds-functions.ts +++ b/packages/ttsl-lang/src/language/builtins/ttsl-ds-functions.ts @@ -72,7 +72,7 @@ export class TTSLFunction extends TTSLModuleMembers { funct: TslFunction | undefined, parameterName: string, ): EvaluatedNode { - const value = funct?.parameterList?.parameters.find((param) => param.name== parameterName) + const value = funct?.parameterList?.parameters.find((param) => param.name === parameterName) if(!value){ return UnknownEvaluatedNode } diff --git a/packages/ttsl-lang/src/language/helpers/ttsl-node-mapper.ts b/packages/ttsl-lang/src/language/helpers/ttsl-node-mapper.ts index 1f8e75e4..6c24c503 100644 --- a/packages/ttsl-lang/src/language/helpers/ttsl-node-mapper.ts +++ b/packages/ttsl-lang/src/language/helpers/ttsl-node-mapper.ts @@ -114,7 +114,6 @@ export class TTSLNodeMapper { // We ignore nullability, since calls can be made null-safe. For scoping, for instance, we still want to // link the arguments of the call properly, even if the user forgot to make the call null-safe. In this // case, an error is being shown anyway. - const receiverType = this.typeComputer().computeType(node.receiver); if(isTslReference(node.receiver)){ if(isTslCallable(node.receiver.target.ref)){ diff --git a/packages/ttsl-lang/src/language/lsp/ttsl-formatter.ts b/packages/ttsl-lang/src/language/lsp/ttsl-formatter.ts index 7023d317..f89ed300 100644 --- a/packages/ttsl-lang/src/language/lsp/ttsl-formatter.ts +++ b/packages/ttsl-lang/src/language/lsp/ttsl-formatter.ts @@ -1,6 +1,6 @@ import { AstNode, CstNode, CstUtils, isAstNode } from 'langium'; import * as ast from '../generated/ast.js'; -import { AbstractFormatter, Formatting, FormattingAction, FormattingActionOptions } from 'langium/lsp'; +import { AbstractFormatter, Formatting} from 'langium/lsp'; import indent = Formatting.indent; import newLine = Formatting.newLine; import newLines = Formatting.newLines; diff --git a/packages/ttsl-lang/src/language/lsp/ttsl-semantic-token-provider.ts b/packages/ttsl-lang/src/language/lsp/ttsl-semantic-token-provider.ts index c2b0b5b9..52c79c61 100644 --- a/packages/ttsl-lang/src/language/lsp/ttsl-semantic-token-provider.ts +++ b/packages/ttsl-lang/src/language/lsp/ttsl-semantic-token-provider.ts @@ -13,7 +13,6 @@ import { isTslReference, isTslResult, } from '../generated/ast.js'; -import { TTSLServices } from '../ttsl-module.js'; export class TTSLSemanticTokenProvider extends AbstractSemanticTokenProvider { protected highlightElement(node: AstNode, acceptor: SemanticTokenAcceptor): void { diff --git a/packages/ttsl-lang/src/language/typing/ttsl-type-computer.ts b/packages/ttsl-lang/src/language/typing/ttsl-type-computer.ts index 5c196074..10437c8a 100644 --- a/packages/ttsl-lang/src/language/typing/ttsl-type-computer.ts +++ b/packages/ttsl-lang/src/language/typing/ttsl-type-computer.ts @@ -407,16 +407,6 @@ export class TTSLTypeComputer { } -/** - * Options for {@link lowestCommonSupertype}. - */ -interface LowestCommonSupertypeOptions { - /** - * If `true`, the type simplification is skipped and the given types are used as is. - */ - skipTypeSimplification?: boolean; -} - interface PartitionTypesLCSResult { containsUnknownType: boolean; containsOtherType: boolean; diff --git a/packages/ttsl-lang/src/language/validation/other/argumentLists.ts b/packages/ttsl-lang/src/language/validation/other/argumentLists.ts index c208e6c2..449068d3 100644 --- a/packages/ttsl-lang/src/language/validation/other/argumentLists.ts +++ b/packages/ttsl-lang/src/language/validation/other/argumentLists.ts @@ -76,8 +76,6 @@ export const argumentListMustNotSetParameterMultipleTimes = (services: TTSLServi return (node: TslArgumentList, accept: ValidationAcceptor): void => { // We already report other errors in this case - const containingCall = AstUtils.getContainerOfType(node, isTslCall); - const args = getArguments(node); const duplicates = duplicatesBy(args, argumentToParameterOrUndefined); diff --git a/packages/ttsl-lang/src/language/validation/other/statements/assignments.ts b/packages/ttsl-lang/src/language/validation/other/statements/assignments.ts index f7cbdefb..43b01d63 100644 --- a/packages/ttsl-lang/src/language/validation/other/statements/assignments.ts +++ b/packages/ttsl-lang/src/language/validation/other/statements/assignments.ts @@ -20,7 +20,7 @@ export const assignmentAssigneeMustGetValue = } }; -export const assignmentShouldNotImplicitlyIgnoreResult = (services: TTSLServices) => { +export const assignmentShouldNotImplicitlyIgnoreResult = () => { return (node: TslAssignment, accept: ValidationAcceptor): void => { const expression = node.expression; if (!isTslFunction(expression)) { diff --git a/packages/ttsl-lang/src/language/validation/types.ts b/packages/ttsl-lang/src/language/validation/types.ts index b4e0ef53..b98064d2 100644 --- a/packages/ttsl-lang/src/language/validation/types.ts +++ b/packages/ttsl-lang/src/language/validation/types.ts @@ -26,7 +26,6 @@ export const CODE_TYPE_MISSING_TYPE_HINT = 'type/missing-type-hint'; export const callArgumentTypesMustMatchParameterTypes = (services: TTSLServices) => { const nodeMapper = services.helpers.NodeMapper; - const typeChecker = services.types.TypeChecker; const typeComputer = services.types.TypeComputer; return (node: TslCall, accept: ValidationAcceptor) => { From 50c5d4ed2d7d5100c9e37d6d1e906a319f6575ab Mon Sep 17 00:00:00 2001 From: methr0 Date: Tue, 20 Aug 2024 19:53:17 +0200 Subject: [PATCH 148/183] make MegaLinter happy --- .../ttsl-lang/src/language/generation/ttsl-python-generator.ts | 2 +- packages/ttsl-lang/src/language/ttsl-module.ts | 2 +- packages/ttsl-lang/src/language/validation/ttsl-validator.ts | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/packages/ttsl-lang/src/language/generation/ttsl-python-generator.ts b/packages/ttsl-lang/src/language/generation/ttsl-python-generator.ts index 355163cc..9fa32130 100644 --- a/packages/ttsl-lang/src/language/generation/ttsl-python-generator.ts +++ b/packages/ttsl-lang/src/language/generation/ttsl-python-generator.ts @@ -534,7 +534,7 @@ export class TTSLPythonGenerator { return expandTracedToNode(funct)`def ${traceToNode( funct, 'name', - )(this.getPythonNameOrDefault(funct))}(${this.generateFunctionParameter(funct, infoFrame)}${this.generateParameters(funct.parameterList, infoFrame)}):` + )(this.getPythonNameOrDefault(funct))}(${this.generateFunctionParameter(funct)}${this.generateParameters(funct.parameterList, infoFrame)}):` .appendNewLine() .indent({ indentedChildren: [this.generateFunctionBlock(funct.body, infoFrame, funct.timeunit)], indentation: PYTHON_INDENT }); } diff --git a/packages/ttsl-lang/src/language/ttsl-module.ts b/packages/ttsl-lang/src/language/ttsl-module.ts index 686d42fb..21e9b360 100644 --- a/packages/ttsl-lang/src/language/ttsl-module.ts +++ b/packages/ttsl-lang/src/language/ttsl-module.ts @@ -116,7 +116,7 @@ export const TTSLModule: Module new TTSLScopeProvider(services), }, types: { - TypeChecker: (services) => new TTSLTypeChecker(services), + TypeChecker: (services) => new TTSLTypeChecker(), TypeComputer: (services) => new TTSLTypeComputer(services), }, workspace: { diff --git a/packages/ttsl-lang/src/language/validation/ttsl-validator.ts b/packages/ttsl-lang/src/language/validation/ttsl-validator.ts index 66a2490e..bc6ac434 100644 --- a/packages/ttsl-lang/src/language/validation/ttsl-validator.ts +++ b/packages/ttsl-lang/src/language/validation/ttsl-validator.ts @@ -72,7 +72,7 @@ export const registerValidationChecks = function (services: TTSLServices) { ], TslAssignment: [ assignmentAssigneeMustGetValue(services), - assignmentShouldNotImplicitlyIgnoreResult(services), + assignmentShouldNotImplicitlyIgnoreResult(), ], TslAbstractCall: [ argumentListMustNotHaveTooManyArguments(services), From 98f2cb12f6d9afcb4853b8c69fae92b9abb6b1c9 Mon Sep 17 00:00:00 2001 From: methr0 Date: Tue, 20 Aug 2024 20:26:57 +0200 Subject: [PATCH 149/183] add Timespan tests and semicolon after value --- .../generation/ttsl-python-generator.ts | 8 ++--- .../src/language/grammar/ttsl.langium | 6 ++-- .../tests/generator/timespan/gen_input.py | 30 +++++++++++++++++++ .../tests/generator/timespan/gen_input.py.map | 1 + .../generation/modifier/timespan/input.ttsl | 6 ++++ .../timespan/bad-missing semicolon.ttsl | 6 ++++ .../timespan/bad-wrong date formate.ttsl | 6 ++++ .../grammar/modifier/timespan/good.ttsl | 6 ++++ 8 files changed, 62 insertions(+), 7 deletions(-) create mode 100644 packages/ttsl-lang/tests/resources/generation/modifier/timespan/generated/tests/generator/timespan/gen_input.py create mode 100644 packages/ttsl-lang/tests/resources/generation/modifier/timespan/generated/tests/generator/timespan/gen_input.py.map create mode 100644 packages/ttsl-lang/tests/resources/generation/modifier/timespan/input.ttsl create mode 100644 packages/ttsl-lang/tests/resources/grammar/modifier/timespan/bad-missing semicolon.ttsl create mode 100644 packages/ttsl-lang/tests/resources/grammar/modifier/timespan/bad-wrong date formate.ttsl create mode 100644 packages/ttsl-lang/tests/resources/grammar/modifier/timespan/good.ttsl diff --git a/packages/ttsl-lang/src/language/generation/ttsl-python-generator.ts b/packages/ttsl-lang/src/language/generation/ttsl-python-generator.ts index 9fa32130..c2e0b128 100644 --- a/packages/ttsl-lang/src/language/generation/ttsl-python-generator.ts +++ b/packages/ttsl-lang/src/language/generation/ttsl-python-generator.ts @@ -633,9 +633,9 @@ export class TTSLPythonGenerator { timespan: TslTimespan, ): CompositeGeneratorNode | undefined { if(timespan.start){ - return expandToNode`s${timespan.start.date.toUTCString()}` // add 's' to mark that it's the start of the timespan + return expandToNode`"s${timespan.start.date}"` // add 's' to mark that it's the start of the timespan } else if (timespan.end){ - return expandToNode`e${timespan.end.date.toUTCString()}` // add 'e' to mark that it's the end of the timespan + return expandToNode`"e${timespan.end.date}"` // add 'e' to mark that it's the end of the timespan } else { /* c8 ignore next 2 */ return undefined; @@ -798,10 +798,10 @@ export class TTSLPythonGenerator { var start = '' var end = '' if (statement.timespan.start){ - start = statement.timespan.start.date.toUTCString() + ' <=' + start = statement.timespan.start.date + ' <=' } if (statement.timespan.end){ - end = '< ' + statement.timespan.end.date.toUTCString() + end = '< ' + statement.timespan.end.date } if (!statement.timespan.start && !statement.timespan.end){ throw new Error(`Timespan has neither a start nor an end value`); diff --git a/packages/ttsl-lang/src/language/grammar/ttsl.langium b/packages/ttsl-lang/src/language/grammar/ttsl.langium index 48235c6a..24f8a050 100644 --- a/packages/ttsl-lang/src/language/grammar/ttsl.langium +++ b/packages/ttsl-lang/src/language/grammar/ttsl.langium @@ -625,7 +625,7 @@ TslNull returns TslNull: ; interface TslDate extends TslLiteral{ - date: Date + date: string } TslDate returns TslDate: @@ -753,7 +753,7 @@ interface TslTimespanValueEntry extends TslObject{ } TslTimespanValueEntry returns TslTimespanValueEntry: - timespan=TslTimespan '=' value=TslExpression + timespan=TslTimespan '=' value=TslExpression ';' ; // ----------------------------------------------------------------------------- @@ -861,7 +861,7 @@ terminal FLOAT returns number : DECIMAL_DIGIT+ '.' DECIMAL_DIGIT+ FLOAT_EXPONENT? | DECIMAL_DIGIT+ FLOAT_EXPONENT; terminal fragment DECIMAL_DIGIT: /[0-9]/; -terminal DATE returns Date: /[0-9]{4}-[0-9]{2}-[0-9]{2}(T[0-9]{2}:[0-9]{2})?/; +terminal DATE returns string: /[0-9]{4}-[0-9]{2}-[0-9]{2}(T[0-9]{2}:[0-9]{2})?/; terminal fragment FLOAT_EXPONENT: ('e' | 'E' )('+' | '-' )? DECIMAL_DIGIT+; terminal INT returns bigint: DECIMAL_DIGIT+; terminal STRING returns string: STRING_START STRING_TEXT* STRING_END; diff --git a/packages/ttsl-lang/tests/resources/generation/modifier/timespan/generated/tests/generator/timespan/gen_input.py b/packages/ttsl-lang/tests/resources/generation/modifier/timespan/generated/tests/generator/timespan/gen_input.py new file mode 100644 index 00000000..0ae32672 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/modifier/timespan/generated/tests/generator/timespan/gen_input.py @@ -0,0 +1,30 @@ +# Imports ---------------------------------------------------------------------- + +from typing import Any, TypeVar + +# Type variables --------------------------------------------------------------- + +__gen_T = TypeVar("__gen_T") + +# Utils ------------------------------------------------------------------------ + +class __gen_ClassConstants(): + def __init__(self, dictionary: dict): + self.dict = dictionary + def getValue(self, date = None): + keys = sorted(self.dict.keys()) + if(keys[0] == "empty"): + return self.dict["empty"] + for index, key in enumerate(keys): + if key[0] == "s": + if key.replace("s", "") <= date: + result = self.dict[key] + if key[0] == "e": + if date <= keys[len(keys)-1-index].replace("e", ""): + result = self.dict[keys[len(keys)-1-index]] + return result + +# Constants -------------------------------------------------------------------- + +testDict = {"s2000-01-01": 1, "s2001-01-01": 2} +test = __gen_ClassConstants(testDict) diff --git a/packages/ttsl-lang/tests/resources/generation/modifier/timespan/generated/tests/generator/timespan/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/modifier/timespan/generated/tests/generator/timespan/gen_input.py.map new file mode 100644 index 00000000..0dacf279 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/modifier/timespan/generated/tests/generator/timespan/gen_input.py.map @@ -0,0 +1 @@ +{"version":3,"sources":["input.ttsl"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAEA,YACI,eAAkB,CAAC,EACnB,eAAkB,CAAC;AAFvB,OAAA","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/modifier/timespan/input.ttsl b/packages/ttsl-lang/tests/resources/generation/modifier/timespan/input.ttsl new file mode 100644 index 00000000..114a63c4 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/modifier/timespan/input.ttsl @@ -0,0 +1,6 @@ +package tests.generator.timespan + +constant test: Int { + from 2000-01-01 = 1; + from 2001-01-01 = 2; +} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/grammar/modifier/timespan/bad-missing semicolon.ttsl b/packages/ttsl-lang/tests/resources/grammar/modifier/timespan/bad-missing semicolon.ttsl new file mode 100644 index 00000000..13604fe7 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/modifier/timespan/bad-missing semicolon.ttsl @@ -0,0 +1,6 @@ +# $TEST$ syntax_error + +constant test: Int{ + from 1997-01-01 = 0 + from 2000-01-01 = 1 +} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/grammar/modifier/timespan/bad-wrong date formate.ttsl b/packages/ttsl-lang/tests/resources/grammar/modifier/timespan/bad-wrong date formate.ttsl new file mode 100644 index 00000000..f2378a12 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/modifier/timespan/bad-wrong date formate.ttsl @@ -0,0 +1,6 @@ +# $TEST$ syntax_error + +constant test: Int{ + from 197-01-01 = 0; + from 2000-01-01 = 1; +} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/grammar/modifier/timespan/good.ttsl b/packages/ttsl-lang/tests/resources/grammar/modifier/timespan/good.ttsl new file mode 100644 index 00000000..0dbc3ff5 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/modifier/timespan/good.ttsl @@ -0,0 +1,6 @@ +# $TEST$ no_syntax_error + +constant test: Int{ + from 1997-01-01 = 0; + from 2000-01-01 = 1; +} \ No newline at end of file From aa1c6d53b825ecb431a655c6c1a798db5161b567 Mon Sep 17 00:00:00 2001 From: methr0 Date: Tue, 20 Aug 2024 20:41:41 +0200 Subject: [PATCH 150/183] adding Timeunit grammar tests --- .../grammar/modifier/timeunit/bad- wrong timeunit.ttsl | 4 ++++ .../grammar/modifier/timeunit/bad-missing timeunit.ttsl | 4 ++++ .../tests/resources/grammar/modifier/timeunit/good.ttsl | 7 +++++++ 3 files changed, 15 insertions(+) create mode 100644 packages/ttsl-lang/tests/resources/grammar/modifier/timeunit/bad- wrong timeunit.ttsl create mode 100644 packages/ttsl-lang/tests/resources/grammar/modifier/timeunit/bad-missing timeunit.ttsl create mode 100644 packages/ttsl-lang/tests/resources/grammar/modifier/timeunit/good.ttsl diff --git a/packages/ttsl-lang/tests/resources/grammar/modifier/timeunit/bad- wrong timeunit.ttsl b/packages/ttsl-lang/tests/resources/grammar/modifier/timeunit/bad- wrong timeunit.ttsl new file mode 100644 index 00000000..53707571 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/modifier/timeunit/bad- wrong timeunit.ttsl @@ -0,0 +1,4 @@ +# $TEST$ syntax_error + +# Function definition: +function per abcd f(): Int {} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/grammar/modifier/timeunit/bad-missing timeunit.ttsl b/packages/ttsl-lang/tests/resources/grammar/modifier/timeunit/bad-missing timeunit.ttsl new file mode 100644 index 00000000..3a91a6fe --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/modifier/timeunit/bad-missing timeunit.ttsl @@ -0,0 +1,4 @@ +# $TEST$ syntax_error + +# Function definition: +function per f(): Int {} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/grammar/modifier/timeunit/good.ttsl b/packages/ttsl-lang/tests/resources/grammar/modifier/timeunit/good.ttsl new file mode 100644 index 00000000..e1b01cdd --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/modifier/timeunit/good.ttsl @@ -0,0 +1,7 @@ +# $TEST$ no_syntax_error + +# Function definition: +function per day f(): Int {} + +# Data definition: +data per month salary: Int; \ No newline at end of file From 5b46db3ed3a920d19caf1817816b428889faa4bb Mon Sep 17 00:00:00 2001 From: methr0 Date: Tue, 20 Aug 2024 20:45:59 +0200 Subject: [PATCH 151/183] adding id grammar tests --- .../resources/grammar/modifier/id/bad- on constant.ttsl | 3 +++ .../grammar/modifier/id/bad-missing declaration.ttsl | 3 +++ .../ttsl-lang/tests/resources/grammar/modifier/id/good.ttsl | 5 +++++ 3 files changed, 11 insertions(+) create mode 100644 packages/ttsl-lang/tests/resources/grammar/modifier/id/bad- on constant.ttsl create mode 100644 packages/ttsl-lang/tests/resources/grammar/modifier/id/bad-missing declaration.ttsl create mode 100644 packages/ttsl-lang/tests/resources/grammar/modifier/id/good.ttsl diff --git a/packages/ttsl-lang/tests/resources/grammar/modifier/id/bad- on constant.ttsl b/packages/ttsl-lang/tests/resources/grammar/modifier/id/bad- on constant.ttsl new file mode 100644 index 00000000..bc1a4716 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/modifier/id/bad- on constant.ttsl @@ -0,0 +1,3 @@ +# $TEST$ syntax_error + +id constant testConstant: Int = 0; \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/grammar/modifier/id/bad-missing declaration.ttsl b/packages/ttsl-lang/tests/resources/grammar/modifier/id/bad-missing declaration.ttsl new file mode 100644 index 00000000..336256f4 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/modifier/id/bad-missing declaration.ttsl @@ -0,0 +1,3 @@ +# $TEST$ syntax_error + +id \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/grammar/modifier/id/good.ttsl b/packages/ttsl-lang/tests/resources/grammar/modifier/id/good.ttsl new file mode 100644 index 00000000..d1424898 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/modifier/id/good.ttsl @@ -0,0 +1,5 @@ +# $TEST$ no_syntax_error + +id data testData: Int; + +id function testFunction(y: Int): Int {} \ No newline at end of file From 206fe81da565e37b80ebf12e902d1ea2b7df7ccd Mon Sep 17 00:00:00 2001 From: methr0 Date: Tue, 20 Aug 2024 20:52:36 +0200 Subject: [PATCH 152/183] add grouping grammar tests --- .../grammar/modifier/grouping/bad- wrong position.ttsl | 6 ++++++ .../grammar/modifier/grouping/bad-missing id.ttsl | 5 +++++ .../tests/resources/grammar/modifier/grouping/good.ttsl | 8 ++++++++ 3 files changed, 19 insertions(+) create mode 100644 packages/ttsl-lang/tests/resources/grammar/modifier/grouping/bad- wrong position.ttsl create mode 100644 packages/ttsl-lang/tests/resources/grammar/modifier/grouping/bad-missing id.ttsl create mode 100644 packages/ttsl-lang/tests/resources/grammar/modifier/grouping/good.ttsl diff --git a/packages/ttsl-lang/tests/resources/grammar/modifier/grouping/bad- wrong position.ttsl b/packages/ttsl-lang/tests/resources/grammar/modifier/grouping/bad- wrong position.ttsl new file mode 100644 index 00000000..5e4b7a0c --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/modifier/grouping/bad- wrong position.ttsl @@ -0,0 +1,6 @@ +# $TEST$ syntax_error + + +function taxes(name: String): groupedBy XYZ_ID List { + var x: Int groupedBy XYZ_ID = 1; +} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/grammar/modifier/grouping/bad-missing id.ttsl b/packages/ttsl-lang/tests/resources/grammar/modifier/grouping/bad-missing id.ttsl new file mode 100644 index 00000000..5ab0fc87 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/modifier/grouping/bad-missing id.ttsl @@ -0,0 +1,5 @@ +# $TEST$ syntax_error + +function taxes(name: String): List groupedBy { + var x: Int groupedBy = 1; +} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/grammar/modifier/grouping/good.ttsl b/packages/ttsl-lang/tests/resources/grammar/modifier/grouping/good.ttsl new file mode 100644 index 00000000..3013502f --- /dev/null +++ b/packages/ttsl-lang/tests/resources/grammar/modifier/grouping/good.ttsl @@ -0,0 +1,8 @@ +# $TEST$ no_syntax_error + +id data XYZ_ID: Int; + +function taxes(name: String): List groupedBy XYZ_ID { + var x: Int groupedBy XYZ_ID = 1; +} + From f059ef1b96047a9a9d3cd48b97329c2bfa51f5f7 Mon Sep 17 00:00:00 2001 From: methr0 Date: Wed, 21 Aug 2024 09:57:23 +0200 Subject: [PATCH 153/183] scoping tests for loop and conditional Statement --- .../in Conditional Statement/to local variable.ttsl | 11 +++++++++++ .../scoping/references/in Loop/to local variable.ttsl | 11 +++++++++++ 2 files changed, 22 insertions(+) create mode 100644 packages/ttsl-lang/tests/resources/scoping/references/in Conditional Statement/to local variable.ttsl create mode 100644 packages/ttsl-lang/tests/resources/scoping/references/in Loop/to local variable.ttsl diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in Conditional Statement/to local variable.ttsl b/packages/ttsl-lang/tests/resources/scoping/references/in Conditional Statement/to local variable.ttsl new file mode 100644 index 00000000..82f144eb --- /dev/null +++ b/packages/ttsl-lang/tests/resources/scoping/references/in Conditional Statement/to local variable.ttsl @@ -0,0 +1,11 @@ +package tests.scoping.references.inLoop + +function f(){ + # $TEST$ target before + var »x«: Int = 0 + + if(1==1){ + # $TEST$ references before + »x« = 2 + } +} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in Loop/to local variable.ttsl b/packages/ttsl-lang/tests/resources/scoping/references/in Loop/to local variable.ttsl new file mode 100644 index 00000000..161a9bc2 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/scoping/references/in Loop/to local variable.ttsl @@ -0,0 +1,11 @@ +package tests.scoping.references.inLoop + +function f(){ + # $TEST$ target before + var »x«: Int = 0 + + while(1==1){ + # $TEST$ references before + »x« = 2 + } +} \ No newline at end of file From 871ec92ad6b9e546cc926f76310f79f1fa0b19a9 Mon Sep 17 00:00:00 2001 From: methr0 Date: Wed, 21 Aug 2024 10:03:34 +0200 Subject: [PATCH 154/183] fix import generation test --- .../gen_context_different_package.py | 7 ++++++ .../gen_context_different_package.py.map | 1 + ...ent_package_function1InDifferentPackage.py | 4 ++++ ...ent_package_function2InDifferentPackage.py | 4 ++++ .../imports/gen_context_same_package.py | 12 ++++++++++ .../imports/gen_context_same_package.py.map | 1 + ...ext_same_package_function1InSamePackage.py | 4 ++++ ...ext_same_package_function2InSamePackage.py | 4 ++++ ...gen_context_same_package_impureFunction.py | 4 ++++ .../tests/generator/imports/gen_input.py | 24 +++++++++++++++++++ .../tests/generator/imports/gen_input.py.map | 1 + .../tests/generator/imports/gen_input_f.py | 4 ++++ .../tests/generator/imports/gen_input_test.py | 4 ++++ .../gen_context_package_with_python_module.py | 7 ++++++ ..._context_package_with_python_module.py.map | 1 + ...ction1InCompilationUnitWithPythonModule.py | 4 ++++ ...ction2InCompilationUnitWithPythonModule.py | 4 ++++ .../generation/imports/general/input.ttsl | 8 +++---- 18 files changed, 94 insertions(+), 4 deletions(-) create mode 100644 packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/differentPackage/gen_context_different_package.py create mode 100644 packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/differentPackage/gen_context_different_package.py.map create mode 100644 packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/differentPackage/gen_context_different_package_function1InDifferentPackage.py create mode 100644 packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/differentPackage/gen_context_different_package_function2InDifferentPackage.py create mode 100644 packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_context_same_package.py create mode 100644 packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_context_same_package.py.map create mode 100644 packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_context_same_package_function1InSamePackage.py create mode 100644 packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_context_same_package_function2InSamePackage.py create mode 100644 packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_context_same_package_impureFunction.py create mode 100644 packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_input.py create mode 100644 packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_input.py.map create mode 100644 packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_input_f.py create mode 100644 packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_input_test.py create mode 100644 packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/withPythonModule/gen_context_package_with_python_module.py create mode 100644 packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/withPythonModule/gen_context_package_with_python_module.py.map create mode 100644 packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/withPythonModule/gen_context_package_with_python_module_function1InCompilationUnitWithPythonModule.py create mode 100644 packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/withPythonModule/gen_context_package_with_python_module_function2InCompilationUnitWithPythonModule.py diff --git a/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/differentPackage/gen_context_different_package.py b/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/differentPackage/gen_context_different_package.py new file mode 100644 index 00000000..73318fcd --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/differentPackage/gen_context_different_package.py @@ -0,0 +1,7 @@ +# Functions -------------------------------------------------------------------- + +def function1InDifferentPackage(): + pass + +def function2InDifferentPackage(): + pass diff --git a/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/differentPackage/gen_context_different_package.py.map b/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/differentPackage/gen_context_different_package.py.map new file mode 100644 index 00000000..139adeb3 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/differentPackage/gen_context_different_package.py.map @@ -0,0 +1 @@ +{"version":3,"sources":["context different package.ttsl"],"names":["function1indifferentpackage","function2indifferentpackage"],"mappings":"AAAA;;AAEA,IAASA,2BAA2B;IAAQ,IAAE;;AAC9C,IAASC,2BAA2B;IAAQ,IAAE","file":"gen_context_different_package.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/differentPackage/gen_context_different_package_function1InDifferentPackage.py b/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/differentPackage/gen_context_different_package_function1InDifferentPackage.py new file mode 100644 index 00000000..b0ea536e --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/differentPackage/gen_context_different_package_function1InDifferentPackage.py @@ -0,0 +1,4 @@ +from .gen_context_different_package import function1InDifferentPackage + +if __name__ == '__main__': + function1InDifferentPackage() diff --git a/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/differentPackage/gen_context_different_package_function2InDifferentPackage.py b/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/differentPackage/gen_context_different_package_function2InDifferentPackage.py new file mode 100644 index 00000000..ec0551f0 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/differentPackage/gen_context_different_package_function2InDifferentPackage.py @@ -0,0 +1,4 @@ +from .gen_context_different_package import function2InDifferentPackage + +if __name__ == '__main__': + function2InDifferentPackage() diff --git a/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_context_same_package.py b/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_context_same_package.py new file mode 100644 index 00000000..f25a07c8 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_context_same_package.py @@ -0,0 +1,12 @@ +# Functions -------------------------------------------------------------------- + +def impureFunction(): + pass + +def function1InSamePackage(): + + return [object Object],(,[object Object],) + +def function2InSamePackage(): + + return [object Object],(,[object Object],) diff --git a/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_context_same_package.py.map b/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_context_same_package.py.map new file mode 100644 index 00000000..bb56ec71 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_context_same_package.py.map @@ -0,0 +1 @@ +{"version":3,"sources":["context same package.ttsl"],"names":["impurefunction","function1insamepackage","function2insamepackage"],"mappings":"AAAA;;AAEA,IAASA,cAAc;IAAO,IAAE;;AAEhC,IAASC,sBAAsB;AAC3B;;;AAGJ,IAASC,sBAAsB;AAC3B","file":"gen_context_same_package.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_context_same_package_function1InSamePackage.py b/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_context_same_package_function1InSamePackage.py new file mode 100644 index 00000000..7ed561b9 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_context_same_package_function1InSamePackage.py @@ -0,0 +1,4 @@ +from .gen_context_same_package import function1InSamePackage + +if __name__ == '__main__': + function1InSamePackage() diff --git a/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_context_same_package_function2InSamePackage.py b/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_context_same_package_function2InSamePackage.py new file mode 100644 index 00000000..6926c872 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_context_same_package_function2InSamePackage.py @@ -0,0 +1,4 @@ +from .gen_context_same_package import function2InSamePackage + +if __name__ == '__main__': + function2InSamePackage() diff --git a/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_context_same_package_impureFunction.py b/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_context_same_package_impureFunction.py new file mode 100644 index 00000000..73935b76 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_context_same_package_impureFunction.py @@ -0,0 +1,4 @@ +from .gen_context_same_package import impureFunction + +if __name__ == '__main__': + impureFunction() diff --git a/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_input.py b/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_input.py new file mode 100644 index 00000000..b9ff0724 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_input.py @@ -0,0 +1,24 @@ +# Imports ---------------------------------------------------------------------- + +from tests.generator.differentPackage import function1InDifferentPackage, function2InDifferentPackage as g +from tests.generator.withPythonModule import function1InCompilationUnitWithPythonModule, function2InCompilationUnitWithPythonModule as h + +# Functions -------------------------------------------------------------------- + +def f(param): + pass + +def test(): + f(function1InSamePackage()) + f(function1InSamePackage()) + f(function2InSamePackage()) + f(function2InSamePackage()) + f(function1InDifferentPackage()) + f(function1InDifferentPackage()) + f(g()) + f(g()) + f(function1InCompilationUnitWithPythonModule()) + f(function1InCompilationUnitWithPythonModule()) + f(h()) + f(h()) + diff --git a/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_input.py.map new file mode 100644 index 00000000..906d780d --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_input.py.map @@ -0,0 +1 @@ +{"version":3,"sources":["input.ttsl"],"names":["f","param","test","function1insamepackage","function2insamepackage","function1indifferentpackage","g","function1incompilationunitwithpythonmodule","h"],"mappings":"AAAA;;;;;;;AAOA,IAASA,CAAC,CAACC,KAAK;IAAO,IAAE;;AAEzB,IAASC,IAAI;IACTF,CAAC,CAACG,sBAAsB;IACxBH,CAAC,CAACG,sBAAsB;IACxBH,CAAC,CAACI,sBAAsB;IACxBJ,CAAC,CAACI,sBAAsB;IAExBJ,CAAC,CAACK,2BAA2B;IAC7BL,CAAC,CAACK,2BAA2B;IAC7BL,CAAC,CAACM,CAAC;IACHN,CAAC,CAACM,CAAC;IAEHN,CAAC,CAACO,0CAA0C;IAC5CP,CAAC,CAACO,0CAA0C;IAC5CP,CAAC,CAACQ,CAAC;IACHR,CAAC,CAACQ,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_input_f.py b/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_input_f.py new file mode 100644 index 00000000..3c6273bd --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_input_f.py @@ -0,0 +1,4 @@ +from .gen_input import f + +if __name__ == '__main__': + f() diff --git a/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_input_test.py b/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_input_test.py new file mode 100644 index 00000000..824f70b1 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_input_test.py @@ -0,0 +1,4 @@ +from .gen_input import test + +if __name__ == '__main__': + test() diff --git a/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/withPythonModule/gen_context_package_with_python_module.py b/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/withPythonModule/gen_context_package_with_python_module.py new file mode 100644 index 00000000..50744d95 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/withPythonModule/gen_context_package_with_python_module.py @@ -0,0 +1,7 @@ +# Functions -------------------------------------------------------------------- + +def function1InCompilationUnitWithPythonModule(): + pass + +def function2InCompilationUnitWithPythonModule(): + pass diff --git a/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/withPythonModule/gen_context_package_with_python_module.py.map b/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/withPythonModule/gen_context_package_with_python_module.py.map new file mode 100644 index 00000000..ef0ac19c --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/withPythonModule/gen_context_package_with_python_module.py.map @@ -0,0 +1 @@ +{"version":3,"sources":["context package with python module.ttsl"],"names":["function1incompilationunitwithpythonmodule","function2incompilationunitwithpythonmodule"],"mappings":"AAAA;;AAEA,IAASA,0CAA0C;IAAQ,IAAE;;AAC7D,IAASC,0CAA0C;IAAO,IAAE","file":"gen_context_package_with_python_module.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/withPythonModule/gen_context_package_with_python_module_function1InCompilationUnitWithPythonModule.py b/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/withPythonModule/gen_context_package_with_python_module_function1InCompilationUnitWithPythonModule.py new file mode 100644 index 00000000..67a53b1d --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/withPythonModule/gen_context_package_with_python_module_function1InCompilationUnitWithPythonModule.py @@ -0,0 +1,4 @@ +from .gen_context_package_with_python_module import function1InCompilationUnitWithPythonModule + +if __name__ == '__main__': + function1InCompilationUnitWithPythonModule() diff --git a/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/withPythonModule/gen_context_package_with_python_module_function2InCompilationUnitWithPythonModule.py b/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/withPythonModule/gen_context_package_with_python_module_function2InCompilationUnitWithPythonModule.py new file mode 100644 index 00000000..1bd534bd --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/withPythonModule/gen_context_package_with_python_module_function2InCompilationUnitWithPythonModule.py @@ -0,0 +1,4 @@ +from .gen_context_package_with_python_module import function2InCompilationUnitWithPythonModule + +if __name__ == '__main__': + function2InCompilationUnitWithPythonModule() diff --git a/packages/ttsl-lang/tests/resources/generation/imports/general/input.ttsl b/packages/ttsl-lang/tests/resources/generation/imports/general/input.ttsl index 739ca838..5c4c9f29 100644 --- a/packages/ttsl-lang/tests/resources/generation/imports/general/input.ttsl +++ b/packages/ttsl-lang/tests/resources/generation/imports/general/input.ttsl @@ -8,10 +8,10 @@ from tests.generator.withPythonModule import function2InCompilationUnitWithPytho function f(param: Any?){} function test () { - f(segment1InSamePackage()); - f(segment1InSamePackage()); - f(segment2InSamePackage()); - f(segment2InSamePackage()); + f(function1InSamePackage()); + f(function1InSamePackage()); + f(function2InSamePackage()); + f(function2InSamePackage()); f(function1InDifferentPackage()); f(function1InDifferentPackage()); From d60f91fed777083724b558f26201ed47d6a73c4d Mon Sep 17 00:00:00 2001 From: methr0 Date: Wed, 21 Aug 2024 16:59:59 +0200 Subject: [PATCH 155/183] fix scoping for conditionalStatements and Loops --- .../src/language/grammar/ttsl.langium | 12 +---- .../src/language/helpers/nodeProperties.ts | 7 ++- .../src/language/lsp/ttsl-formatter.ts | 8 ---- .../scoping/ttsl-scope-computation.ts | 21 ++++----- .../language/scoping/ttsl-scope-provider.ts | 37 +++++++++++---- .../src/language/validation/aggregation.ts | 12 ++--- .../other/statements/assignments.ts | 46 ------------------- .../src/language/validation/ttsl-validator.ts | 8 ---- .../src/language/validation/types.ts | 6 +-- .../statements/Loops/forLoop/input.ttsl | 1 + .../references/in Loop/to local variable.ttsl | 14 +++--- 11 files changed, 63 insertions(+), 109 deletions(-) delete mode 100644 packages/ttsl-lang/src/language/validation/other/statements/assignments.ts diff --git a/packages/ttsl-lang/src/language/grammar/ttsl.langium b/packages/ttsl-lang/src/language/grammar/ttsl.langium index 24f8a050..0ae8e383 100644 --- a/packages/ttsl-lang/src/language/grammar/ttsl.langium +++ b/packages/ttsl-lang/src/language/grammar/ttsl.langium @@ -261,20 +261,12 @@ TslStatement returns TslStatement: ; interface TslAssignment extends TslStatement { - assigneeList?: TslAssigneeList + assignee: TslAssignee expression?: TslExpression } TslAssignment returns TslAssignment: - assigneeList=TslAssigneeList '=' expression=TslExpression ';'? -; - -interface TslAssigneeList extends TslObject { - assignees: TslAssignee[] -} - -TslAssigneeList returns TslAssigneeList: - assignees+=TslAssignee (',' assignees+=TslAssignee)* ','? + assignee=TslAssignee '=' expression=TslExpression ';'? ; interface TslAssignee extends TslObject {} diff --git a/packages/ttsl-lang/src/language/helpers/nodeProperties.ts b/packages/ttsl-lang/src/language/helpers/nodeProperties.ts index 17ef6e78..de6d62a9 100644 --- a/packages/ttsl-lang/src/language/helpers/nodeProperties.ts +++ b/packages/ttsl-lang/src/language/helpers/nodeProperties.ts @@ -101,7 +101,12 @@ export const getArguments = (node: TslArgumentList | TslAbstractCall | undefined }; export const getAssignees = (node: TslAssignment | undefined): TslAssignee[] => { - return node?.assigneeList?.assignees ?? []; + if(node?.assignee){ + return [node?.assignee]; + }else{ + return [] + } + }; export const getImports = (node: TslModule | undefined): TslImport[] => { diff --git a/packages/ttsl-lang/src/language/lsp/ttsl-formatter.ts b/packages/ttsl-lang/src/language/lsp/ttsl-formatter.ts index f89ed300..59268d4f 100644 --- a/packages/ttsl-lang/src/language/lsp/ttsl-formatter.ts +++ b/packages/ttsl-lang/src/language/lsp/ttsl-formatter.ts @@ -52,8 +52,6 @@ export class TTSLFormatter extends AbstractFormatter { this.formatTslBlock(node); } else if (ast.isTslAssignment(node)) { this.formatTslAssignment(node); - } else if (ast.isTslAssigneeList(node)) { - this.formatTslAssigneeList(node); } else if (ast.isTslPlaceholder(node)) { this.formatTslPlaceholder(node); } else if (ast.isTslExpressionStatement(node)) { @@ -295,12 +293,6 @@ export class TTSLFormatter extends AbstractFormatter { formatter.keyword(';').prepend(noSpace()); } - private formatTslAssigneeList(node: ast.TslAssigneeList) { - const formatter = this.getNodeFormatter(node); - - formatter.keywords(',').prepend(noSpace()).append(oneSpace()); - } - private formatTslPlaceholder(node: ast.TslPlaceholder) { const formatter = this.getNodeFormatter(node); diff --git a/packages/ttsl-lang/src/language/scoping/ttsl-scope-computation.ts b/packages/ttsl-lang/src/language/scoping/ttsl-scope-computation.ts index 41b6daa7..b15d7c33 100644 --- a/packages/ttsl-lang/src/language/scoping/ttsl-scope-computation.ts +++ b/packages/ttsl-lang/src/language/scoping/ttsl-scope-computation.ts @@ -7,6 +7,7 @@ import { PrecomputedScopes, } from 'langium'; import { + isTslAssignment, isTslConditionalStatement, isTslDeclaration, isTslForeachLoop, @@ -14,6 +15,7 @@ import { isTslFunction, isTslLoop, isTslModule, + isTslPlaceholder, isTslWhileLoop, TslConditionalStatement, TslFunction, @@ -72,25 +74,20 @@ export class TTSLScopeComputation extends DefaultScopeComputation { return; } - const description = this.descriptions.createDescription(node, name, document); - - this.addToScopesIfKeyIsDefined(scopes, node.block, description); - - if (isTslForLoop(node)){ - this.addToScopesIfKeyIsDefined(scopes, node.definitionStatement, description); - this.addToScopesIfKeyIsDefined(scopes, node.condition, description); - this.addToScopesIfKeyIsDefined(scopes, node.iteration, description); - } else if(isTslWhileLoop(node)){ - this.addToScopesIfKeyIsDefined(scopes, node.condition, description); + if (isTslForLoop(node) && isTslAssignment(node.definitionStatement) && isTslPlaceholder(node.definitionStatement.assignee)){ + const description = this.descriptions.createDescription(node.definitionStatement.assignee, name, document); + this.addToScopesIfKeyIsDefined(scopes, node.block, description); } else if(isTslForeachLoop(node)){ + const description = this.descriptions.createDescription(node, name, document); this.addToScopesIfKeyIsDefined(scopes, node.element, description); - this.addToScopesIfKeyIsDefined(scopes, node.list, description); + this.addToScopesIfKeyIsDefined(scopes, node.block, description); } - +/* const containingDeclaration = AstUtils.getContainerOfType(node.$container, isTslDeclaration); if (isTslModule(containingDeclaration)) { this.addToScopesIfKeyIsDefined(scopes, containingDeclaration, description); } + */ } private processTslConditionalStatement(node: TslConditionalStatement, document: LangiumDocument, scopes: PrecomputedScopes): void { diff --git a/packages/ttsl-lang/src/language/scoping/ttsl-scope-provider.ts b/packages/ttsl-lang/src/language/scoping/ttsl-scope-provider.ts index 4aff0a1c..4b7d2d08 100644 --- a/packages/ttsl-lang/src/language/scoping/ttsl-scope-provider.ts +++ b/packages/ttsl-lang/src/language/scoping/ttsl-scope-provider.ts @@ -16,7 +16,10 @@ import { isTslBlock, isTslCallable, isTslDeclaration, + isTslForeachLoop, + isTslForLoop, isTslImportedDeclaration, + isTslLocalVariable, isTslModule, isTslParameter, isTslPlaceholder, @@ -28,6 +31,7 @@ import { type TslCallable, TslDeclaration, TslImportedDeclaration, + TslLocalVariable, type TslParameter, TslPlaceholder, TslReference, @@ -117,6 +121,7 @@ export class TTSLScopeProvider extends DefaultScopeProvider { // Declarations in containing blocks currentScope = this.localDeclarations(node, currentScope); + // Core declarations return this.coreDeclarations(TslDeclaration, currentScope); } @@ -169,18 +174,34 @@ export class TTSLScopeProvider extends DefaultScopeProvider { // Placeholders up to the containing statement const containingStatement = AstUtils.getContainerOfType(node.$container, isTslStatement); - let placeholders: Iterable; + let placeholders: TslLocalVariable[] = []; + if(isTslForLoop(containingStatement) && isTslAssignment(containingStatement.definitionStatement) && isTslPlaceholder(containingStatement.definitionStatement.assignee)){ + placeholders.push(containingStatement.definitionStatement.assignee) + } else if (isTslForeachLoop(containingStatement)){ + placeholders.push(containingStatement.element) + } + if (!containingCallable || isContainedInOrEqual(containingStatement, containingCallable)) { - placeholders = this.placeholdersUpToStatement(containingStatement); - } else { - // Placeholders are further away than the parameters - placeholders = []; + placeholders.push(...this.placeholdersUpToStatement(containingStatement)); } // Local declarations - const localDeclarations = [...parameters, ...placeholders]; - - return this.createScopeForNodes(localDeclarations, outerScope); + const result = [...parameters, ...placeholders]; + + const containingLoop = AstUtils.getContainerOfType(node.$container, isTslAssignment); + const containingBlock = AstUtils.getContainerOfType(node.$container, isTslBlock); + + if(containingBlock) { + const outerLocalDeclarations = this.localDeclarations(containingBlock, outerScope) + if(!containingLoop){ + return this.createScopeForNodes(result, outerLocalDeclarations); + } + } if(containingLoop){ + const loopDeclarations = this.localDeclarations(containingLoop, outerScope) + return this.createScopeForNodes(result, loopDeclarations); + } else{ + return this.createScopeForNodes(result, outerScope); + } } private *parametersUpToParameter( diff --git a/packages/ttsl-lang/src/language/validation/aggregation.ts b/packages/ttsl-lang/src/language/validation/aggregation.ts index daef5ba2..80ef4a3c 100644 --- a/packages/ttsl-lang/src/language/validation/aggregation.ts +++ b/packages/ttsl-lang/src/language/validation/aggregation.ts @@ -95,14 +95,12 @@ function hasAggregation(statements: TslStatement[]| undefined, id: string): bool } else if(isTslAssignment(elm)){ if(isTslAggregation(elm.expression)){ result = true - }else if(elm.assigneeList?.assignees.filter(isTslPlaceholder)){ - elm.assigneeList.assignees.filter(isTslPlaceholder).forEach(placeholder => { - if(placeholder.groupedBy?.id.target.ref?.name === id){ - result = true - } - }) + }else if(isTslPlaceholder(elm.assignee)){ + if(elm.assignee.groupedBy?.id.target.ref?.name === id){ + result = true + } } - } + } }); return result } diff --git a/packages/ttsl-lang/src/language/validation/other/statements/assignments.ts b/packages/ttsl-lang/src/language/validation/other/statements/assignments.ts deleted file mode 100644 index 43b01d63..00000000 --- a/packages/ttsl-lang/src/language/validation/other/statements/assignments.ts +++ /dev/null @@ -1,46 +0,0 @@ -import { isTslFunction, TslAssignment} from '../../../generated/ast.js'; -import { ValidationAcceptor } from 'langium'; -import { TTSLServices } from '../../../ttsl-module.js'; -import { getResults, getAssignees } from '../../../helpers/nodeProperties.js'; -import { pluralize } from '../../../../helpers/strings.js'; - -export const CODE_ASSIGNMENT_IMPLICITLY_IGNORED_RESULT = 'assignment/implicitly-ignored-result'; -export const CODE_ASSIGMENT_NOTHING_ASSIGNED = 'assignment/nothing-assigned'; - -export const assignmentAssigneeMustGetValue = - (services: TTSLServices) => - (node: TslAssignment, accept: ValidationAcceptor): void => { - for (const assignee of getAssignees(node)) { - if (!services.helpers.NodeMapper.assigneeToAssignedObject(assignee)) { - accept('error', 'No value is assigned to this assignee.', { - node: assignee, - code: CODE_ASSIGMENT_NOTHING_ASSIGNED, - }); - } - } - }; - -export const assignmentShouldNotImplicitlyIgnoreResult = () => { - return (node: TslAssignment, accept: ValidationAcceptor): void => { - const expression = node.expression; - if (!isTslFunction(expression)) { - return; - } - - const assignees = getAssignees(node); - const results = getResults(expression); - - if (results.length > assignees.length) { - const kind = pluralize(results.length - assignees.length, 'result'); - const names = results - .slice(assignees.length) - .map((result) => `'${result.name}'`) - .join(', '); - - accept('warning', `The assignment implicitly ignores the ${kind} ${names}.`, { - node, - code: CODE_ASSIGNMENT_IMPLICITLY_IGNORED_RESULT, - }); - } - }; -}; diff --git a/packages/ttsl-lang/src/language/validation/ttsl-validator.ts b/packages/ttsl-lang/src/language/validation/ttsl-validator.ts index bc6ac434..367fc7c9 100644 --- a/packages/ttsl-lang/src/language/validation/ttsl-validator.ts +++ b/packages/ttsl-lang/src/language/validation/ttsl-validator.ts @@ -33,10 +33,6 @@ import { importPackageMustExist, importPackageShouldNotBeEmpty } from './other/i import { moduleWithDeclarationsMustStatePackage, } from './other/modules.js'; -import { - assignmentAssigneeMustGetValue, - assignmentShouldNotImplicitlyIgnoreResult, -} from './other/statements/assignments.js'; import { callArgumentListShouldBeNeeded, chainedExpressionNullSafetyShouldBeNeeded, @@ -70,10 +66,6 @@ export const registerValidationChecks = function (services: TTSLServices) { const checks: ValidationChecks = { TslAssignee: [ ], - TslAssignment: [ - assignmentAssigneeMustGetValue(services), - assignmentShouldNotImplicitlyIgnoreResult(), - ], TslAbstractCall: [ argumentListMustNotHaveTooManyArguments(services), argumentListMustSetAllRequiredParameters(services), diff --git a/packages/ttsl-lang/src/language/validation/types.ts b/packages/ttsl-lang/src/language/validation/types.ts index b98064d2..9b10362d 100644 --- a/packages/ttsl-lang/src/language/validation/types.ts +++ b/packages/ttsl-lang/src/language/validation/types.ts @@ -39,7 +39,7 @@ export const callArgumentTypesMustMatchParameterTypes = (services: TTSLServices) const argumentType = typeComputer.computeType(argument); const parameterType = typeComputer.computeType(parameter); - if (!(argumentType.toString === parameterType.toString || parameterType instanceof AnyType)) { + if (!(argumentType.toString() === parameterType.toString() || parameterType instanceof AnyType)) { accept('error', `Expected type '${parameterType}' but got '${argumentType}'.`, { node: argument, property: 'value', @@ -155,8 +155,8 @@ export const infixOperationOperandsMustHaveCorrectType = (services: TTSLServices } if ( node.rightOperand && - !(leftType instanceof FloatType) && - !(leftType instanceof IntType) + !(rightType instanceof FloatType) && + !(rightType instanceof IntType) ) { accept( 'error', diff --git a/packages/ttsl-lang/tests/resources/generation/statements/Loops/forLoop/input.ttsl b/packages/ttsl-lang/tests/resources/generation/statements/Loops/forLoop/input.ttsl index c0a37126..69a2cde9 100644 --- a/packages/ttsl-lang/tests/resources/generation/statements/Loops/forLoop/input.ttsl +++ b/packages/ttsl-lang/tests/resources/generation/statements/Loops/forLoop/input.ttsl @@ -3,6 +3,7 @@ package tests.generator.forLoop function myFunction () { var x = 0; for(var i = 0; i <= 10; i = i+1){ + } return x; } diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in Loop/to local variable.ttsl b/packages/ttsl-lang/tests/resources/scoping/references/in Loop/to local variable.ttsl index 161a9bc2..a9825e6a 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in Loop/to local variable.ttsl +++ b/packages/ttsl-lang/tests/resources/scoping/references/in Loop/to local variable.ttsl @@ -1,11 +1,13 @@ package tests.scoping.references.inLoop function f(){ - # $TEST$ target before - var »x«: Int = 0 - - while(1==1){ - # $TEST$ references before - »x« = 2 + + var x: Int = 0 + # $TEST$ target before + for(var »i« = 0; + i<= 10; + # $TEST$ references before + »i« = i+1){ + x = 2 } } \ No newline at end of file From 123e6f9c1fbe85efaa3aa2c84b7cbca4ef257cc4 Mon Sep 17 00:00:00 2001 From: methr0 Date: Wed, 21 Aug 2024 18:14:24 +0200 Subject: [PATCH 156/183] fix indexed Access and dictionary test --- .../src/language/grammar/ttsl.langium | 6 +-- .../src/language/typing/ttsl-type-computer.ts | 42 +++++++++++++++---- .../src/language/validation/types.ts | 4 +- .../generator/indexedAccess/gen_input.py | 19 +++++++++ .../generator/indexedAccess/gen_input.py.map | 1 + .../generator/indexedAccess/gen_input_test.py | 4 ++ .../expressions/indexed access/input.ttsl | 6 +-- .../tests/generator/maps/gen_input.py | 20 +++++++++ .../tests/generator/maps/gen_input.py.map | 1 + .../tests/generator/maps/gen_input_g2.py | 4 ++ .../tests/generator/maps/gen_input_g3.py | 4 ++ .../tests/generator/maps/gen_input_h1.py | 4 ++ .../tests/generator/maps/gen_input_h2.py | 4 ++ .../tests/generator/maps/gen_input_test.py | 4 ++ .../generation/expressions/maps/input.ttsl | 3 -- 15 files changed, 108 insertions(+), 18 deletions(-) create mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/indexed access/generated/tests/generator/indexedAccess/gen_input.py create mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/indexed access/generated/tests/generator/indexedAccess/gen_input.py.map create mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/indexed access/generated/tests/generator/indexedAccess/gen_input_test.py create mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/maps/generated/tests/generator/maps/gen_input.py create mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/maps/generated/tests/generator/maps/gen_input.py.map create mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/maps/generated/tests/generator/maps/gen_input_g2.py create mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/maps/generated/tests/generator/maps/gen_input_g3.py create mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/maps/generated/tests/generator/maps/gen_input_h1.py create mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/maps/generated/tests/generator/maps/gen_input_h2.py create mode 100644 packages/ttsl-lang/tests/resources/generation/expressions/maps/generated/tests/generator/maps/gen_input_test.py diff --git a/packages/ttsl-lang/src/language/grammar/ttsl.langium b/packages/ttsl-lang/src/language/grammar/ttsl.langium index 0ae8e383..c7558f12 100644 --- a/packages/ttsl-lang/src/language/grammar/ttsl.langium +++ b/packages/ttsl-lang/src/language/grammar/ttsl.langium @@ -18,7 +18,7 @@ interface TslDeclaration extends TslObject { interface TslLocalVariable extends TslDeclaration { groupedBy?: TslGroupedBy value?: TslExpression - ^type?: TslType + type?: TslType } TslLocalVariable returns TslLocalVariable: @@ -208,7 +208,7 @@ interface TslParameter extends TslLocalVariable { TslParameter returns TslParameter: isConstant?='constant'? name=ID - ':' ^type=TslType + ':' type=TslType ('=' defaultValue=TslExpression)? ; @@ -275,7 +275,7 @@ interface TslPlaceholder extends TslAssignee, TslLocalVariable {} TslAssignee returns TslAssignee: {TslPlaceholder} 'var' name=ID (':' ^type=TslType)? (groupedBy=TslGroupedBy)? - | TslReference + | TslReference ; interface TslExpressionStatement extends TslStatement { diff --git a/packages/ttsl-lang/src/language/typing/ttsl-type-computer.ts b/packages/ttsl-lang/src/language/typing/ttsl-type-computer.ts index 10437c8a..e3c004a4 100644 --- a/packages/ttsl-lang/src/language/typing/ttsl-type-computer.ts +++ b/packages/ttsl-lang/src/language/typing/ttsl-type-computer.ts @@ -38,6 +38,14 @@ import { isTslBoolean, isTslString, isTslAnyType, + isTslLocalVariable, + TslLocalVariable, + isTslForeachLoop, + isTslDictionaryType, + isTslListType, + isTslTypeParameterList, + isTslTypeParameter, + TslTypeParameter, } from '../generated/ast.js'; import { TTSLServices } from '../ttsl-module.js'; import { @@ -102,7 +110,13 @@ export class TTSLTypeComputer { return this.computeTypeOfExpression(node); } else if (isTslType(node)) { return this.computeTypeOfType(node); - } /* c8 ignore start */ else { + } else if (isTslTypeParameter(node)){ + console.log(node.$containerProperty) + return this.computeTypeOfTypeParameter(node); + } else if (isTslLocalVariable(node)){ + console.log(node.$containerProperty) + return this.computeTypeOfElm(node); + }/* c8 ignore start */ else { return UnknownType; } /* c8 ignore stop */ } @@ -114,13 +128,8 @@ export class TTSLTypeComputer { return UnknownType; } - const assigneePosition = node.$containerIndex ?? -1; const expressionType = this.computeType(containingAssignment?.expression); - if (assigneePosition === 0) { - return expressionType; - } - - return UnknownType; + return expressionType; } private computeTypeOfDeclaration(node: TslDeclaration): Type { @@ -322,6 +331,25 @@ export class TTSLTypeComputer { return new BooleanType(false); } else if (isTslAnyType(node)) { return new AnyType(false); + } else if (isTslListType(node)) { + const elementType = this.lowestCommonSupertype(node.typeParameterList.typeParameters.map((it) => this.computeType(it))); + return new ListType([elementType], false); + } else if (isTslDictionaryType(node)) { + const types = this.lowestCommonSupertype(node.typeParameterList.typeParameters.map((it) => this.computeType(it))); + return new DictionaryType([types], false); + } /* c8 ignore start */ else { + return UnknownType; + } /* c8 ignore stop */ + } + + private computeTypeOfTypeParameter(node: TslTypeParameter): Type{ + return this.computeType(node.type) + } + + private computeTypeOfElm(node: TslLocalVariable): Type{ + console.log(node) + if(isTslForeachLoop(node.$container)){ + return this.computeType(node.$container.list) } /* c8 ignore start */ else { return UnknownType; } /* c8 ignore stop */ diff --git a/packages/ttsl-lang/src/language/validation/types.ts b/packages/ttsl-lang/src/language/validation/types.ts index 9b10362d..7a4b4e25 100644 --- a/packages/ttsl-lang/src/language/validation/types.ts +++ b/packages/ttsl-lang/src/language/validation/types.ts @@ -102,7 +102,7 @@ export const indexedAccessIndexMustHaveCorrectType = (services: TTSLServices) => const receiverType = typeComputer.computeType(node.receiver); if (receiverType instanceof ListType) { const indexType = typeComputer.computeType(node.index); - if (indexType instanceof IntType) { + if (!(indexType instanceof IntType)) { accept('error', `Expected type 'Int' but got '${indexType}'.`, { node, property: 'index', @@ -226,7 +226,7 @@ export const parameterDefaultValueTypeMustMatchParameterType = (services: TTSLSe const defaultValueType = typeComputer.computeType(defaultValue); const parameterType = typeComputer.computeType(node); - if (!(defaultValueType.toString === parameterType.toString)) { + if (!(defaultValueType.toString() === parameterType.toString())) { accept('error', `Expected type '${parameterType}' but got '${defaultValueType}'.`, { node, property: 'defaultValue', diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/indexed access/generated/tests/generator/indexedAccess/gen_input.py b/packages/ttsl-lang/tests/resources/generation/expressions/indexed access/generated/tests/generator/indexedAccess/gen_input.py new file mode 100644 index 00000000..3ac96f16 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/expressions/indexed access/generated/tests/generator/indexedAccess/gen_input.py @@ -0,0 +1,19 @@ +# Imports ---------------------------------------------------------------------- + +from typing import Any, TypeVar + +# Type variables --------------------------------------------------------------- + +__gen_T = TypeVar("__gen_T") + +# Utils ------------------------------------------------------------------------ + +def __gen_null_safe_indexed_access(receiver: Any, index: Any) -> __gen_T | None: + return receiver[index] if receiver is not None else None + +# Functions -------------------------------------------------------------------- + +def test(one, two): + x = one[0] + y = __gen_null_safe_indexed_access(two, 0) + diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/indexed access/generated/tests/generator/indexedAccess/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/expressions/indexed access/generated/tests/generator/indexedAccess/gen_input.py.map new file mode 100644 index 00000000..8b2c17c3 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/expressions/indexed access/generated/tests/generator/indexedAccess/gen_input.py.map @@ -0,0 +1 @@ +{"version":3,"sources":["input.ttsl"],"names":["test","one","two"],"mappings":"AAAA;;;;;;;;;;;;;;;AAEA,IAASA,IAAI,CAACC,GAAG,EAAaC,GAAG;IAC7B,IAAQD,GAAG,CAAC,CAAC;IACb,IAAW,8BAAC,CAAJC,GAAG,EAAE,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/indexed access/generated/tests/generator/indexedAccess/gen_input_test.py b/packages/ttsl-lang/tests/resources/generation/expressions/indexed access/generated/tests/generator/indexedAccess/gen_input_test.py new file mode 100644 index 00000000..824f70b1 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/expressions/indexed access/generated/tests/generator/indexedAccess/gen_input_test.py @@ -0,0 +1,4 @@ +from .gen_input import test + +if __name__ == '__main__': + test() diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/indexed access/input.ttsl b/packages/ttsl-lang/tests/resources/generation/expressions/indexed access/input.ttsl index 24528c73..1ecfd7fe 100644 --- a/packages/ttsl-lang/tests/resources/generation/expressions/indexed access/input.ttsl +++ b/packages/ttsl-lang/tests/resources/generation/expressions/indexed access/input.ttsl @@ -1,6 +1,6 @@ package tests.generator.indexedAccess -function test(param1: List, param2: List?) { - var x = param1[0]; - var y = param2?[0]; +function test(one: List, two: List?) { + var x = one[0]; + var y = two?[0]; } diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/maps/generated/tests/generator/maps/gen_input.py b/packages/ttsl-lang/tests/resources/generation/expressions/maps/generated/tests/generator/maps/gen_input.py new file mode 100644 index 00000000..1ddb8df1 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/expressions/maps/generated/tests/generator/maps/gen_input.py @@ -0,0 +1,20 @@ +# Functions -------------------------------------------------------------------- + +def g2(param): + pass + +def g3(param): + pass + +def h1(): + pass + +def h2(): + pass + +def test(): + g2({"a": 1.2, "b": 1}) + g2({h2(): -(0.5), "b": h1()}) + g3({1.2: "a", 1: "b"}) + g3({5.6: "c", h1(): h2()}) + diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/maps/generated/tests/generator/maps/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/expressions/maps/generated/tests/generator/maps/gen_input.py.map new file mode 100644 index 00000000..dc9d0efb --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/expressions/maps/generated/tests/generator/maps/gen_input.py.map @@ -0,0 +1 @@ +{"version":3,"sources":["input.ttsl"],"names":["g2","param","g3","h1","h2","test"],"mappings":"AAAA;;AAEA,IAASA,EAAE,CAACC,KAAK;IAAsB,IAAE;;AAEzC,IAASC,EAAE,CAACD,KAAK;IAAsB,IAAE;;AAEzC,IAASE,EAAE;IAAU,IAAE;;AAEvB,IAASC,EAAE;IAAU,IAAE;;AAEvB,IAASC,IAAI;IACTL,EAAE,CAAC,CAAC,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,CAAG;IACtBA,EAAE,CAAC,CAACI,EAAE,IAAI,CAAC,CAAA,GAAG,GAAE,GAAG,EAAED,EAAE;IACvBD,EAAE,CAAC,CAAC,GAAG,EAAE,GAAG,EAAE,CAAG,EAAE,GAAG;IACtBA,EAAE,CAAC,CAAC,GAAG,EAAE,GAAG,EAAEC,EAAE,IAAIC,EAAE","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/maps/generated/tests/generator/maps/gen_input_g2.py b/packages/ttsl-lang/tests/resources/generation/expressions/maps/generated/tests/generator/maps/gen_input_g2.py new file mode 100644 index 00000000..13a0e612 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/expressions/maps/generated/tests/generator/maps/gen_input_g2.py @@ -0,0 +1,4 @@ +from .gen_input import g2 + +if __name__ == '__main__': + g2() diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/maps/generated/tests/generator/maps/gen_input_g3.py b/packages/ttsl-lang/tests/resources/generation/expressions/maps/generated/tests/generator/maps/gen_input_g3.py new file mode 100644 index 00000000..fa3b6522 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/expressions/maps/generated/tests/generator/maps/gen_input_g3.py @@ -0,0 +1,4 @@ +from .gen_input import g3 + +if __name__ == '__main__': + g3() diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/maps/generated/tests/generator/maps/gen_input_h1.py b/packages/ttsl-lang/tests/resources/generation/expressions/maps/generated/tests/generator/maps/gen_input_h1.py new file mode 100644 index 00000000..b1a933ea --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/expressions/maps/generated/tests/generator/maps/gen_input_h1.py @@ -0,0 +1,4 @@ +from .gen_input import h1 + +if __name__ == '__main__': + h1() diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/maps/generated/tests/generator/maps/gen_input_h2.py b/packages/ttsl-lang/tests/resources/generation/expressions/maps/generated/tests/generator/maps/gen_input_h2.py new file mode 100644 index 00000000..435effb1 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/expressions/maps/generated/tests/generator/maps/gen_input_h2.py @@ -0,0 +1,4 @@ +from .gen_input import h2 + +if __name__ == '__main__': + h2() diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/maps/generated/tests/generator/maps/gen_input_test.py b/packages/ttsl-lang/tests/resources/generation/expressions/maps/generated/tests/generator/maps/gen_input_test.py new file mode 100644 index 00000000..824f70b1 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/expressions/maps/generated/tests/generator/maps/gen_input_test.py @@ -0,0 +1,4 @@ +from .gen_input import test + +if __name__ == '__main__': + test() diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/maps/input.ttsl b/packages/ttsl-lang/tests/resources/generation/expressions/maps/input.ttsl index ac15bac0..2a0f6c76 100644 --- a/packages/ttsl-lang/tests/resources/generation/expressions/maps/input.ttsl +++ b/packages/ttsl-lang/tests/resources/generation/expressions/maps/input.ttsl @@ -1,7 +1,5 @@ package tests.generator.maps -function g1(param: Dict){} - function g2(param: Dict){} function g3(param: Dict){} @@ -11,7 +9,6 @@ function h1(): Float {} function h2(): String{} function test () { - g1({}); g2({"a": 1.2, "b": 1.0}); g2({h2(): -0.5, "b": h1()}); g3({1.2: "a", 1.0: "b"}); From 0ba804d28786747b353f2fc11591e48b19ccb3e7 Mon Sep 17 00:00:00 2001 From: methr0 Date: Fri, 23 Aug 2024 08:53:53 +0200 Subject: [PATCH 157/183] fix default value generation in parameters --- .../generation/ttsl-python-generator.ts | 49 ++++++++++++++++--- .../tests/generator/assignment/gen_input.py | 2 +- .../generator/assignment/gen_input.py.map | 2 +- .../statements/assignment/input.ttsl | 2 +- 4 files changed, 46 insertions(+), 9 deletions(-) diff --git a/packages/ttsl-lang/src/language/generation/ttsl-python-generator.ts b/packages/ttsl-lang/src/language/generation/ttsl-python-generator.ts index c2e0b128..d98f7402 100644 --- a/packages/ttsl-lang/src/language/generation/ttsl-python-generator.ts +++ b/packages/ttsl-lang/src/language/generation/ttsl-python-generator.ts @@ -71,6 +71,14 @@ import { isTslFloat, isTslTimeunit, isTslPredefinedFunction, + TslType, + isTslIntType, + isTslFloatType, + isTslListType, + isTslDictionaryType, + isTslBooleanType, + isTslStringType, + isTslExpression, } from '../generated/ast.js'; import { isInFile, isFile } from '../helpers/fileExtensions.js'; import { @@ -652,7 +660,7 @@ export class TTSLPythonGenerator { } return joinTracedToNode(parameters, 'parameters')( parameters?.parameters || [], - (param) => this.generateParameter(param, frame), + (param) => `${this.generateParameter(param, frame).contents}: ${this.generateType(param.type, frame)?.contents} ${this.generateDefaultValue(param.defaultValue, frame)?.contents}`, { separator: ', ' }, ); } @@ -662,11 +670,40 @@ export class TTSLPythonGenerator { frame: GenerationInfoFrame, defaultValue: boolean = true, ): CompositeGeneratorNode { - return expandTracedToNode(parameter)`${traceToNode(parameter, 'name')(this.getPythonNameOrDefault(parameter))}${ - defaultValue && parameter.defaultValue !== undefined - ? expandToNode`=${this.generateExpression(parameter.defaultValue, frame)}` - : '' - }`; + return expandTracedToNode(parameter)`${this.getPythonNameOrDefault(parameter)}`; + } + + private generateType( + type: TslType | undefined, + frame: GenerationInfoFrame, + ): CompositeGeneratorNode| undefined { + if(isTslIntType(type)){ + return expandTracedToNode(type)`int` + } else if(isTslFloatType(type)){ + return expandTracedToNode(type)`float` + } else if(isTslBooleanType(type)){ + return expandTracedToNode(type)`bool` + } else if(isTslStringType(type)){ + return expandTracedToNode(type)`str` + } else if(isTslListType(type)){ + return expandTracedToNode(type)`list[${this.generateType(type.typeParameterList.typeParameters.at(0)?.type, frame)}]` + } else if(isTslDictionaryType(type)){ + return expandTracedToNode(type)`dict[${this.generateType(type.typeParameterList.typeParameters.at(0)?.type, frame)},${this.generateType(type.typeParameterList.typeParameters.at(1)?.type, frame)}]` + } else { + return undefined + } + } + + private generateDefaultValue( + value: TslExpression | undefined, + frame: GenerationInfoFrame, + ): CompositeGeneratorNode| undefined { + if(isTslExpression(value)){ + let result = new CompositeGeneratorNode + return result.append(`= ${this.generateExpression(value, frame).contents}`) + } else{ + return undefined; + } } private generateImports(importSet: ImportData[]): string[] { diff --git a/packages/ttsl-lang/tests/resources/generation/statements/assignment/generated/tests/generator/assignment/gen_input.py b/packages/ttsl-lang/tests/resources/generation/statements/assignment/generated/tests/generator/assignment/gen_input.py index d3edd0c4..4946d110 100644 --- a/packages/ttsl-lang/tests/resources/generation/statements/assignment/generated/tests/generator/assignment/gen_input.py +++ b/packages/ttsl-lang/tests/resources/generation/statements/assignment/generated/tests/generator/assignment/gen_input.py @@ -3,7 +3,7 @@ def f(): pass -def g(x): +def g(x: int = 0): pass def testFunction(): diff --git a/packages/ttsl-lang/tests/resources/generation/statements/assignment/generated/tests/generator/assignment/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/statements/assignment/generated/tests/generator/assignment/gen_input.py.map index 20568ba6..128737c8 100644 --- a/packages/ttsl-lang/tests/resources/generation/statements/assignment/generated/tests/generator/assignment/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/statements/assignment/generated/tests/generator/assignment/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.ttsl"],"names":["f","g","x","testfunction"],"mappings":"AAAA;;AAEA,IAASA,CAAC;IAAQ,IAAE;;AACpB,IAASC,CAAC,CAACC,CAAC;IAAM,IAAE;;AAEpB,IAASC,YAAY;IACjB,IAAQH,CAAC","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["f","g","testfunction"],"mappings":"AAAA;;AAEA,IAASA,CAAC;IAAQ,IAAE;;AACpB,IAASC,CAAC,CAAC;IAAW,IAAE;;AAExB,IAASC,YAAY;IACjB,IAAQF,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/statements/assignment/input.ttsl b/packages/ttsl-lang/tests/resources/generation/statements/assignment/input.ttsl index 67959e4f..58bf322b 100644 --- a/packages/ttsl-lang/tests/resources/generation/statements/assignment/input.ttsl +++ b/packages/ttsl-lang/tests/resources/generation/statements/assignment/input.ttsl @@ -1,7 +1,7 @@ package tests.generator.assignment function f(): Int {} -function g(x: Int){} +function g(x: Int = 0){} function testFunction() { var a = f(); From a3fded1238d2db56278a884febfaaf738ac7a6cc Mon Sep 17 00:00:00 2001 From: methr0 Date: Fri, 23 Aug 2024 09:59:18 +0200 Subject: [PATCH 158/183] update tests with parameter types and fix errors --- .../generation/ttsl-python-generator.ts | 42 +++++++++++++------ .../functionWithParameter/gen_input.py | 2 +- .../functionWithParameter/gen_input.py.map | 2 +- .../tests/generator/call/gen_input.py | 8 ++-- .../tests/generator/call/gen_input.py.map | 2 +- .../tests/generator/const/gen_input.py.map | 2 +- .../generator/indexedAccess/gen_input.py | 6 +-- .../generator/indexedAccess/gen_input.py.map | 2 +- .../expressions/indexed access/input.ttsl | 6 +-- .../generator/infixOperation/gen_input.py.map | 2 +- .../tests/generator/maps/gen_input.py | 4 +- .../tests/generator/maps/gen_input.py.map | 2 +- .../parenthesizedExpression/gen_input.py.map | 2 +- .../prefixOperation/gen_input.py.map | 2 +- .../generator/reference/gen_input.py.map | 2 +- .../tests/generator/imports/gen_input.py.map | 2 +- 16 files changed, 52 insertions(+), 36 deletions(-) diff --git a/packages/ttsl-lang/src/language/generation/ttsl-python-generator.ts b/packages/ttsl-lang/src/language/generation/ttsl-python-generator.ts index d98f7402..415a9f1f 100644 --- a/packages/ttsl-lang/src/language/generation/ttsl-python-generator.ts +++ b/packages/ttsl-lang/src/language/generation/ttsl-python-generator.ts @@ -660,7 +660,7 @@ export class TTSLPythonGenerator { } return joinTracedToNode(parameters, 'parameters')( parameters?.parameters || [], - (param) => `${this.generateParameter(param, frame).contents}: ${this.generateType(param.type, frame)?.contents} ${this.generateDefaultValue(param.defaultValue, frame)?.contents}`, + (param) => `${this.generateParameter(param, frame).contents}${this.generateType(param.type, frame)?.contents}${this.generateDefaultValue(param.defaultValue, frame)?.contents}`, { separator: ', ' }, ); } @@ -676,33 +676,49 @@ export class TTSLPythonGenerator { private generateType( type: TslType | undefined, frame: GenerationInfoFrame, - ): CompositeGeneratorNode| undefined { + rekursion: boolean = false, + ): CompositeGeneratorNode { + let result = new CompositeGeneratorNode + if(isTslIntType(type)){ - return expandTracedToNode(type)`int` + if(!rekursion){ + return result.append(`: int`) + } + return result.append(`int`) } else if(isTslFloatType(type)){ - return expandTracedToNode(type)`float` + if(!rekursion){ + return result.append(`: float`) + } + return result.append(`float`) } else if(isTslBooleanType(type)){ - return expandTracedToNode(type)`bool` + if(!rekursion){ + return result.append(`: bool`) + } + return result.append(`bool`) } else if(isTslStringType(type)){ - return expandTracedToNode(type)`str` + if(!rekursion){ + return result.append(`: str`) + } + return result.append(`str`) } else if(isTslListType(type)){ - return expandTracedToNode(type)`list[${this.generateType(type.typeParameterList.typeParameters.at(0)?.type, frame)}]` + return result.append(`: list[${this.generateType(type.typeParameterList.typeParameters.at(0)?.type, frame, true)?.contents}]`) } else if(isTslDictionaryType(type)){ - return expandTracedToNode(type)`dict[${this.generateType(type.typeParameterList.typeParameters.at(0)?.type, frame)},${this.generateType(type.typeParameterList.typeParameters.at(1)?.type, frame)}]` + return result.append(`: dict[${this.generateType(type.typeParameterList.typeParameters.at(0)?.type, frame, true)?.contents}, ${this.generateType(type.typeParameterList.typeParameters.at(1)?.type, frame, true)?.contents}]`) } else { - return undefined + return new CompositeGeneratorNode(``) } } private generateDefaultValue( value: TslExpression | undefined, frame: GenerationInfoFrame, - ): CompositeGeneratorNode| undefined { + ): CompositeGeneratorNode { + let result = new CompositeGeneratorNode if(isTslExpression(value)){ - let result = new CompositeGeneratorNode - return result.append(`= ${this.generateExpression(value, frame).contents}`) + + return result.append(` = ${this.generateExpression(value, frame).contents}`) } else{ - return undefined; + return result; } } diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/function with parameter/generated/tests/generator/functionWithParameter/gen_input.py b/packages/ttsl-lang/tests/resources/generation/declarations/function with parameter/generated/tests/generator/functionWithParameter/gen_input.py index c405de84..26de0504 100644 --- a/packages/ttsl-lang/tests/resources/generation/declarations/function with parameter/generated/tests/generator/functionWithParameter/gen_input.py +++ b/packages/ttsl-lang/tests/resources/generation/declarations/function with parameter/generated/tests/generator/functionWithParameter/gen_input.py @@ -1,4 +1,4 @@ # Functions -------------------------------------------------------------------- -def test(x, y): +def test(x: int, y: int): pass \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/declarations/function with parameter/generated/tests/generator/functionWithParameter/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/declarations/function with parameter/generated/tests/generator/functionWithParameter/gen_input.py.map index 76147013..6dd8bf6d 100644 --- a/packages/ttsl-lang/tests/resources/generation/declarations/function with parameter/generated/tests/generator/functionWithParameter/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/declarations/function with parameter/generated/tests/generator/functionWithParameter/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.ttsl"],"names":["test","x","y"],"mappings":"AAAA;;AAEA,IAASA,IAAI,CAACC,CAAC,EAAOC,CAAC;IAAO,IAAE","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["test"],"mappings":"AAAA;;AAEA,IAASA,IAAI,CAAC,QAAQ;IAAQ,IAAE","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/call/generated/tests/generator/call/gen_input.py b/packages/ttsl-lang/tests/resources/generation/expressions/call/generated/tests/generator/call/gen_input.py index 9d09ecf3..d34139c2 100644 --- a/packages/ttsl-lang/tests/resources/generation/expressions/call/generated/tests/generator/call/gen_input.py +++ b/packages/ttsl-lang/tests/resources/generation/expressions/call/generated/tests/generator/call/gen_input.py @@ -13,16 +13,16 @@ def __gen_null_safe_call(receiver: Any, callable: Callable[[], __gen_T]) -> __ge # Functions -------------------------------------------------------------------- -def f(param): +def f(param: bool): pass -def g(param1, param2=0): +def g(param1: int, param2: int = 0): pass -def h(param1, param2=0): +def h(param1: int, param2: int = 0): pass -def i(param): +def i(param: str): pass def test(): diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/call/generated/tests/generator/call/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/expressions/call/generated/tests/generator/call/gen_input.py.map index 5faae5ef..81586dd9 100644 --- a/packages/ttsl-lang/tests/resources/generation/expressions/call/generated/tests/generator/call/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/expressions/call/generated/tests/generator/call/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.ttsl"],"names":["f","param","g","param1","param2","h","i","test"],"mappings":"AAAA;;;;;;;;;;;;;;;AAEA,IAASA,CAAC,CAACC,KAAK;IAAW,IAAE;;AAE7B,IAASC,CAAC,CACNC,MAAM,EACNC,MAAM,CAAQ,CAAC;IACR,IAAE;;AAEb,IAASC,CAAC,CAACF,MAAM,EAAOC,MAAM,CAAQ,CAAC;IAC5B,IAAE;;AAEb,IAASE,CAAC,CAACL,KAAK;IAAW,IAAE;;AAE7B,IAASM,IAAI;IACTP,CAAC,CAAEE,CAAC,CAAC,CAAC,EATNE,MAAM,CASE,CAAC;IACTJ,CAAC,CAAEE,CAAC,CAAsB,CAAC,EAV3BE,MAAM,CAUQ,CAAC;IACfJ,CAAC,CAAEK,CAAC,CAAC,CAAC,EARcD,MAAM,CAQlB,CAAC;IACTJ,CAAC,CAAEK,CAAC,CAAsB,CAAC,EATPD,MAAM,CASZ,CAAC;IACfJ,CAAC,CAAEK,CAAC,CAAU,CAAC;IACfC,CAAC,CAAC,KAAK;IAEN,oBAAC,CAAFN,CAAC,UAADA,CAAC,CAAGE,CAAC,CAAC,CAAC,EAhBPE,MAAM,CAgBG,CAAC;IACT,oBAAC,CAAFJ,CAAC,UAADA,CAAC,CAAGE,CAAC,CAAsB,CAAC,EAjB5BE,MAAM,CAiBS,CAAC;IACf,oBAAC,CAAFJ,CAAC,UAADA,CAAC,CAAGK,CAAC,CAAC,CAAC,EAfaD,MAAM,CAejB,CAAC;IACT,oBAAC,CAAFJ,CAAC,UAADA,CAAC,CAAGK,CAAC,CAAsB,CAAC,EAhBRD,MAAM,CAgBX,CAAC;IACf,oBAAC,CAAFJ,CAAC,UAADA,CAAC,CAAGK,CAAC,CAAU,CAAC;IACf,oBAAC,CAAFC,CAAC,UAADA,CAAC,CAAE,KAAK","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["f","g","h","i","test"],"mappings":"AAAA;;;;;;;;;;;;;;;AAEA,IAASA,CAAC,CAAC;IAAgB,IAAE;;AAE7B,IAASC,CAAC,CACN,aACA;IACO,IAAE;;AAEb,IAASC,CAAC,CAAC,aAAa;IACb,IAAE;;AAEb,IAASC,CAAC,CAAC;IAAgB,IAAE;;AAE7B,IAASC,IAAI;IACTJ,CAAC,CAAEC,CAAC,CAAC,CAAC,EATN,OASQ,CAAC;IACTD,CAAC,CAAEC,CAAC,CAAsB,CAAC,EAV3B,OAUc,CAAC;IACfD,CAAC,CAAEE,CAAC,CAAC,CAAC,EARc,OAQZ,CAAC;IACTF,CAAC,CAAEE,CAAC,CAAsB,CAAC,EATP,OASN,CAAC;IACfF,CAAC,CAAEE,CAAC,CAAU,CAAC;IACfC,CAAC,CAAC,KAAK;IAEN,oBAAC,CAAFH,CAAC,UAADA,CAAC,CAAGC,CAAC,CAAC,CAAC,EAhBP,OAgBS,CAAC;IACT,oBAAC,CAAFD,CAAC,UAADA,CAAC,CAAGC,CAAC,CAAsB,CAAC,EAjB5B,OAiBe,CAAC;IACf,oBAAC,CAAFD,CAAC,UAADA,CAAC,CAAGE,CAAC,CAAC,CAAC,EAfa,OAeX,CAAC;IACT,oBAAC,CAAFF,CAAC,UAADA,CAAC,CAAGE,CAAC,CAAsB,CAAC,EAhBR,OAgBL,CAAC;IACf,oBAAC,CAAFF,CAAC,UAADA,CAAC,CAAGE,CAAC,CAAU,CAAC;IACf,oBAAC,CAAFC,CAAC,UAADA,CAAC,CAAE,KAAK","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/constant/generated/tests/generator/const/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/expressions/constant/generated/tests/generator/const/gen_input.py.map index e21842ee..0534d74d 100644 --- a/packages/ttsl-lang/tests/resources/generation/expressions/constant/generated/tests/generator/const/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/expressions/constant/generated/tests/generator/const/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.ttsl"],"names":["f","param","test","null"],"mappings":"AAAA;;AAEA,IAASA,CAAC,CAACC,KAAK;IAAO,IAAE;;AAEzB,IAASC,IAAI;IACTF,CAAC,CAAC,CAAA,CAAC,EAAC,CAAC,EAAC,CAAC;IACPA,CAAC,CAAC,CAAA,CAAG,EAAC,CAAC,EAAC,CAAG;IACXA,CAAC,CAAC,CAAA,CAAC,EAAC,CAAC,EAAC,CAAC;IACPA,CAAC,CAACG,IAAI","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["f","test","null"],"mappings":"AAAA;;AAEA,IAASA,CAAC,CAAC;IAAY,IAAE;;AAEzB,IAASC,IAAI;IACTD,CAAC,CAAC,CAAA,CAAC,EAAC,CAAC,EAAC,CAAC;IACPA,CAAC,CAAC,CAAA,CAAG,EAAC,CAAC,EAAC,CAAG;IACXA,CAAC,CAAC,CAAA,CAAC,EAAC,CAAC,EAAC,CAAC;IACPA,CAAC,CAACE,IAAI","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/indexed access/generated/tests/generator/indexedAccess/gen_input.py b/packages/ttsl-lang/tests/resources/generation/expressions/indexed access/generated/tests/generator/indexedAccess/gen_input.py index 3ac96f16..3726fd76 100644 --- a/packages/ttsl-lang/tests/resources/generation/expressions/indexed access/generated/tests/generator/indexedAccess/gen_input.py +++ b/packages/ttsl-lang/tests/resources/generation/expressions/indexed access/generated/tests/generator/indexedAccess/gen_input.py @@ -13,7 +13,7 @@ def __gen_null_safe_indexed_access(receiver: Any, index: Any) -> __gen_T | None: # Functions -------------------------------------------------------------------- -def test(one, two): - x = one[0] - y = __gen_null_safe_indexed_access(two, 0) +def test(param1: list[int], param2: list[int]): + x = param1[0] + y = __gen_null_safe_indexed_access(param2, 0) diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/indexed access/generated/tests/generator/indexedAccess/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/expressions/indexed access/generated/tests/generator/indexedAccess/gen_input.py.map index 8b2c17c3..c377ce76 100644 --- a/packages/ttsl-lang/tests/resources/generation/expressions/indexed access/generated/tests/generator/indexedAccess/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/expressions/indexed access/generated/tests/generator/indexedAccess/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.ttsl"],"names":["test","one","two"],"mappings":"AAAA;;;;;;;;;;;;;;;AAEA,IAASA,IAAI,CAACC,GAAG,EAAaC,GAAG;IAC7B,IAAQD,GAAG,CAAC,CAAC;IACb,IAAW,8BAAC,CAAJC,GAAG,EAAE,CAAC","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["test","param1","param2"],"mappings":"AAAA;;;;;;;;;;;;;;;AAEA,IAASA,IAAI,CAAC,mBAAmB;IAC7B,IAAQC,MAAM,CAAC,CAAC;IAChB,IAAc,8BAAC,CAAPC,MAAM,EAAE,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/indexed access/input.ttsl b/packages/ttsl-lang/tests/resources/generation/expressions/indexed access/input.ttsl index 1ecfd7fe..24528c73 100644 --- a/packages/ttsl-lang/tests/resources/generation/expressions/indexed access/input.ttsl +++ b/packages/ttsl-lang/tests/resources/generation/expressions/indexed access/input.ttsl @@ -1,6 +1,6 @@ package tests.generator.indexedAccess -function test(one: List, two: List?) { - var x = one[0]; - var y = two?[0]; +function test(param1: List, param2: List?) { + var x = param1[0]; + var y = param2?[0]; } diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/infix operation/generated/tests/generator/infixOperation/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/expressions/infix operation/generated/tests/generator/infixOperation/gen_input.py.map index 731200ff..2632473d 100644 --- a/packages/ttsl-lang/tests/resources/generation/expressions/infix operation/generated/tests/generator/infixOperation/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/expressions/infix operation/generated/tests/generator/infixOperation/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.ttsl"],"names":["f","param","g","h","i","test","or","and"],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;AAEA,IAASA,CAAC,CAACC,KAAK;IAAO,IAAE;;AAEzB,IAASC,CAAC;IAAW,IAAE;;AAEvB,IAASC,CAAC;IAAO,IAAE;;AAEnB,IAASC,CAAC;IAAQ,IAAE;;AAEpB,IAASC,IAAI;IACTL,CAAC,CAAKM,cAAE,CAANJ,CAAC,IAAMA,CAAC;IACVF,CAAC,CAAKO,eAAG,CAAPL,CAAC,IAAOA,CAAC;IAEXF,CAAC,CAAC,CAAAG,CAAC,IAAG,EAAE,EAACA,CAAC;IACVH,CAAC,CAAC,CAAAG,CAAC,IAAG,EAAE,EAACA,CAAC;IACVH,CAAC,CAAC,CAAAG,CAAC,IAAG,EAAG,EAACA,CAAC;IACXH,CAAC,CAAC,CAAAG,CAAC,IAAG,QAAIA,CAAC;IAEXH,CAAC,CAAC,CAAAG,CAAC,IAAG,CAAC,EAACA,CAAC;IACTH,CAAC,CAAC,CAAAG,CAAC,IAAG,EAAE,EAACA,CAAC;IACVH,CAAC,CAAC,CAAAG,CAAC,IAAG,EAAE,EAACA,CAAC;IACVH,CAAC,CAAC,CAAAG,CAAC,IAAG,CAAC,EAACA,CAAC;IAETH,CAAC,CAAC,CAAAG,CAAC,IAAG,CAAC,EAACA,CAAC;IACTH,CAAC,CAAC,CAAAG,CAAC,IAAG,CAAC,EAACA,CAAC;IACTH,CAAC,CAAC,CAAAG,CAAC,IAAG,CAAC,EAACA,CAAC;IACTH,CAAC,CAAC,CAAAG,CAAC,IAAG,CAAC,EAACA,CAAC;IAETH,CAAC,CAAK,iBAAE,CAANI,CAAC,IAAMA,CAAC","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["f","g","h","i","test","or","and"],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;AAEA,IAASA,CAAC,CAAC;IAAY,IAAE;;AAEzB,IAASC,CAAC;IAAW,IAAE;;AAEvB,IAASC,CAAC;IAAO,IAAE;;AAEnB,IAASC,CAAC;IAAQ,IAAE;;AAEpB,IAASC,IAAI;IACTJ,CAAC,CAAKK,cAAE,CAANJ,CAAC,IAAMA,CAAC;IACVD,CAAC,CAAKM,eAAG,CAAPL,CAAC,IAAOA,CAAC;IAEXD,CAAC,CAAC,CAAAE,CAAC,IAAG,EAAE,EAACA,CAAC;IACVF,CAAC,CAAC,CAAAE,CAAC,IAAG,EAAE,EAACA,CAAC;IACVF,CAAC,CAAC,CAAAE,CAAC,IAAG,EAAG,EAACA,CAAC;IACXF,CAAC,CAAC,CAAAE,CAAC,IAAG,QAAIA,CAAC;IAEXF,CAAC,CAAC,CAAAE,CAAC,IAAG,CAAC,EAACA,CAAC;IACTF,CAAC,CAAC,CAAAE,CAAC,IAAG,EAAE,EAACA,CAAC;IACVF,CAAC,CAAC,CAAAE,CAAC,IAAG,EAAE,EAACA,CAAC;IACVF,CAAC,CAAC,CAAAE,CAAC,IAAG,CAAC,EAACA,CAAC;IAETF,CAAC,CAAC,CAAAE,CAAC,IAAG,CAAC,EAACA,CAAC;IACTF,CAAC,CAAC,CAAAE,CAAC,IAAG,CAAC,EAACA,CAAC;IACTF,CAAC,CAAC,CAAAE,CAAC,IAAG,CAAC,EAACA,CAAC;IACTF,CAAC,CAAC,CAAAE,CAAC,IAAG,CAAC,EAACA,CAAC;IAETF,CAAC,CAAK,iBAAE,CAANG,CAAC,IAAMA,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/maps/generated/tests/generator/maps/gen_input.py b/packages/ttsl-lang/tests/resources/generation/expressions/maps/generated/tests/generator/maps/gen_input.py index 1ddb8df1..6397e1d4 100644 --- a/packages/ttsl-lang/tests/resources/generation/expressions/maps/generated/tests/generator/maps/gen_input.py +++ b/packages/ttsl-lang/tests/resources/generation/expressions/maps/generated/tests/generator/maps/gen_input.py @@ -1,9 +1,9 @@ # Functions -------------------------------------------------------------------- -def g2(param): +def g2(param: dict[str, float]): pass -def g3(param): +def g3(param: dict[float, str]): pass def h1(): diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/maps/generated/tests/generator/maps/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/expressions/maps/generated/tests/generator/maps/gen_input.py.map index dc9d0efb..2256b227 100644 --- a/packages/ttsl-lang/tests/resources/generation/expressions/maps/generated/tests/generator/maps/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/expressions/maps/generated/tests/generator/maps/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.ttsl"],"names":["g2","param","g3","h1","h2","test"],"mappings":"AAAA;;AAEA,IAASA,EAAE,CAACC,KAAK;IAAsB,IAAE;;AAEzC,IAASC,EAAE,CAACD,KAAK;IAAsB,IAAE;;AAEzC,IAASE,EAAE;IAAU,IAAE;;AAEvB,IAASC,EAAE;IAAU,IAAE;;AAEvB,IAASC,IAAI;IACTL,EAAE,CAAC,CAAC,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,CAAG;IACtBA,EAAE,CAAC,CAACI,EAAE,IAAI,CAAC,CAAA,GAAG,GAAE,GAAG,EAAED,EAAE;IACvBD,EAAE,CAAC,CAAC,GAAG,EAAE,GAAG,EAAE,CAAG,EAAE,GAAG;IACtBA,EAAE,CAAC,CAAC,GAAG,EAAE,GAAG,EAAEC,EAAE,IAAIC,EAAE","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["g2","g3","h1","h2","test"],"mappings":"AAAA;;AAEA,IAASA,EAAE,CAAC;IAA2B,IAAE;;AAEzC,IAASC,EAAE,CAAC;IAA2B,IAAE;;AAEzC,IAASC,EAAE;IAAU,IAAE;;AAEvB,IAASC,EAAE;IAAU,IAAE;;AAEvB,IAASC,IAAI;IACTJ,EAAE,CAAC,CAAC,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,CAAG;IACtBA,EAAE,CAAC,CAACG,EAAE,IAAI,CAAC,CAAA,GAAG,GAAE,GAAG,EAAED,EAAE;IACvBD,EAAE,CAAC,CAAC,GAAG,EAAE,GAAG,EAAE,CAAG,EAAE,GAAG;IACtBA,EAAE,CAAC,CAAC,GAAG,EAAE,GAAG,EAAEC,EAAE,IAAIC,EAAE","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/parenthesized expression/generated/tests/generator/parenthesizedExpression/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/expressions/parenthesized expression/generated/tests/generator/parenthesizedExpression/gen_input.py.map index f1123f8d..0ea2f1cf 100644 --- a/packages/ttsl-lang/tests/resources/generation/expressions/parenthesized expression/generated/tests/generator/parenthesizedExpression/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/expressions/parenthesized expression/generated/tests/generator/parenthesizedExpression/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.ttsl"],"names":["f","param","g","test"],"mappings":"AAAA;;AAEA,IAASA,CAAC,CAACC,KAAK;IAAO,IAAE;;AAEzB,IAASC,CAAC;IAAW,IAAE;;AAEvB,IAASC,IAAI;IACTH,CAAC,CAAEE,CAAC","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["f","g","test"],"mappings":"AAAA;;AAEA,IAASA,CAAC,CAAC;IAAY,IAAE;;AAEzB,IAASC,CAAC;IAAW,IAAE;;AAEvB,IAASC,IAAI;IACTF,CAAC,CAAEC,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/prefix operation/generated/tests/generator/prefixOperation/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/expressions/prefix operation/generated/tests/generator/prefixOperation/gen_input.py.map index 209f515e..62ea4c1e 100644 --- a/packages/ttsl-lang/tests/resources/generation/expressions/prefix operation/generated/tests/generator/prefixOperation/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/expressions/prefix operation/generated/tests/generator/prefixOperation/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.ttsl"],"names":["f","param","g","h","test","not"],"mappings":"AAAA;;AAEA,IAASA,CAAC,CAACC,KAAK;IAAO,IAAE;;AAEzB,IAASC,CAAC;IAAW,IAAE;;AAEvB,IAASC,CAAC;IAAO,IAAE;;AAEnB,IAASC,IAAI;IACTJ,CAAC,CAACK,GAAG,EAACH,CAAC;IACPF,CAAC,CAAC,CAAC,CAAAG,CAAC","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["f","g","h","test","not"],"mappings":"AAAA;;AAEA,IAASA,CAAC,CAAC;IAAY,IAAE;;AAEzB,IAASC,CAAC;IAAW,IAAE;;AAEvB,IAASC,CAAC;IAAO,IAAE;;AAEnB,IAASC,IAAI;IACTH,CAAC,CAACI,GAAG,EAACH,CAAC;IACPD,CAAC,CAAC,CAAC,CAAAE,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/expressions/reference/generated/tests/generator/reference/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/expressions/reference/generated/tests/generator/reference/gen_input.py.map index 34edf6b3..5e393170 100644 --- a/packages/ttsl-lang/tests/resources/generation/expressions/reference/generated/tests/generator/reference/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/expressions/reference/generated/tests/generator/reference/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.ttsl"],"names":["f","param","explainmodel","test"],"mappings":"AAAA;;AAEA,IAASA,CAAC,CAACC,KAAK;IAAO,IAAE;;AAEzB,IAASC,YAAY;IAAO,IAAE;;AAE9B,IAASC,IAAI;IACTH,CAAC,CAACE,YAAY","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["f","explainmodel","test"],"mappings":"AAAA;;AAEA,IAASA,CAAC,CAAC;IAAY,IAAE;;AAEzB,IAASC,YAAY;IAAO,IAAE;;AAE9B,IAASC,IAAI;IACTF,CAAC,CAACC,YAAY","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_input.py.map index 906d780d..d10ea08a 100644 --- a/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/imports/general/generated/tests/generator/imports/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.ttsl"],"names":["f","param","test","function1insamepackage","function2insamepackage","function1indifferentpackage","g","function1incompilationunitwithpythonmodule","h"],"mappings":"AAAA;;;;;;;AAOA,IAASA,CAAC,CAACC,KAAK;IAAO,IAAE;;AAEzB,IAASC,IAAI;IACTF,CAAC,CAACG,sBAAsB;IACxBH,CAAC,CAACG,sBAAsB;IACxBH,CAAC,CAACI,sBAAsB;IACxBJ,CAAC,CAACI,sBAAsB;IAExBJ,CAAC,CAACK,2BAA2B;IAC7BL,CAAC,CAACK,2BAA2B;IAC7BL,CAAC,CAACM,CAAC;IACHN,CAAC,CAACM,CAAC;IAEHN,CAAC,CAACO,0CAA0C;IAC5CP,CAAC,CAACO,0CAA0C;IAC5CP,CAAC,CAACQ,CAAC;IACHR,CAAC,CAACQ,CAAC","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["f","test","function1insamepackage","function2insamepackage","function1indifferentpackage","g","function1incompilationunitwithpythonmodule","h"],"mappings":"AAAA;;;;;;;AAOA,IAASA,CAAC,CAAC;IAAY,IAAE;;AAEzB,IAASC,IAAI;IACTD,CAAC,CAACE,sBAAsB;IACxBF,CAAC,CAACE,sBAAsB;IACxBF,CAAC,CAACG,sBAAsB;IACxBH,CAAC,CAACG,sBAAsB;IAExBH,CAAC,CAACI,2BAA2B;IAC7BJ,CAAC,CAACI,2BAA2B;IAC7BJ,CAAC,CAACK,CAAC;IACHL,CAAC,CAACK,CAAC;IAEHL,CAAC,CAACM,0CAA0C;IAC5CN,CAAC,CAACM,0CAA0C;IAC5CN,CAAC,CAACO,CAAC;IACHP,CAAC,CAACO,CAAC","file":"gen_input.py"} \ No newline at end of file From c59ac7e416c9019e4b48b82e34a7c7a3e42ecdd2 Mon Sep 17 00:00:00 2001 From: methr0 Date: Sat, 24 Aug 2024 10:04:18 +0200 Subject: [PATCH 159/183] fix ability to reassign local variables --- .../src/language/generation/ttsl-python-generator.ts | 10 ++++++---- packages/ttsl-lang/src/language/grammar/ttsl.langium | 8 +++++++- .../generated/tests/generator/forLoop/gen_input.py | 8 ++++++++ .../generated/tests/generator/forLoop/gen_input.py.map | 1 + .../tests/generator/forLoop/gen_input_myFunction.py | 4 ++++ .../generation/statements/Loops/foreachLoop/input.ttsl | 2 +- .../tests/generator/whileLoop/gen_input.py.map | 2 +- 7 files changed, 28 insertions(+), 7 deletions(-) create mode 100644 packages/ttsl-lang/tests/resources/generation/statements/Loops/forLoop/generated/tests/generator/forLoop/gen_input.py create mode 100644 packages/ttsl-lang/tests/resources/generation/statements/Loops/forLoop/generated/tests/generator/forLoop/gen_input.py.map create mode 100644 packages/ttsl-lang/tests/resources/generation/statements/Loops/forLoop/generated/tests/generator/forLoop/gen_input_myFunction.py diff --git a/packages/ttsl-lang/src/language/generation/ttsl-python-generator.ts b/packages/ttsl-lang/src/language/generation/ttsl-python-generator.ts index 415a9f1f..6906ad41 100644 --- a/packages/ttsl-lang/src/language/generation/ttsl-python-generator.ts +++ b/packages/ttsl-lang/src/language/generation/ttsl-python-generator.ts @@ -771,7 +771,7 @@ export class TTSLPythonGenerator { if (targetPlaceholder) { statements = this.getStatementsNeededForPartialExecution(targetPlaceholder, statements); } - if (statements.length === 0) { + if (statements.length === 0 && !isTslForLoop(block.$container)) { return traceToNode(block)('pass'); } return joinTracedToNode(block, 'statements')( @@ -885,8 +885,8 @@ export class TTSLPythonGenerator { thirdParameter = this.generateStatement((statement.iteration), frame) } return expandTracedToNode(statement)`${firstParameter} - while ${this.generateExpression((statement.condition), frame)}:`.appendNewLine().indent(indentingNode => - indentingNode.append(this.generateBlock((statement.block), frame))).append(`${thirdParameter}`); +while ${this.generateExpression((statement.condition), frame)}:`.appendNewLine().indent(indentingNode => + indentingNode.append(this.generateBlock((statement.block), frame)).append(thirdParameter)); } else if (isTslForeachLoop(statement)){ return expandTracedToNode(statement)`for ${statement.element} in ${statement.list}:`.appendNewLine().indent(indentingNode => indentingNode.append(this.generateBlock((statement.block), frame))); @@ -935,7 +935,9 @@ export class TTSLPythonGenerator { private generateAssignee(assignee: TslAssignee): CompositeGeneratorNode { if (isTslPlaceholder(assignee)) { return traceToNode(assignee)(assignee.name); - } + } else if(isTslReference(assignee)) { + return traceToNode(assignee)(assignee.target.ref?.name) + } /* c8 ignore next 2 */ throw new Error(`Unknown TslAssignment: ${assignee.$type}`); } diff --git a/packages/ttsl-lang/src/language/grammar/ttsl.langium b/packages/ttsl-lang/src/language/grammar/ttsl.langium index c7558f12..9544948d 100644 --- a/packages/ttsl-lang/src/language/grammar/ttsl.langium +++ b/packages/ttsl-lang/src/language/grammar/ttsl.langium @@ -273,9 +273,15 @@ interface TslAssignee extends TslObject {} interface TslPlaceholder extends TslAssignee, TslLocalVariable {} +interface TslPlaceholderReference extends TslAssignee, TslReference{} + +TslPlaceholderReference returns TslPlaceholderReference: + target = [TslPlaceholder:ID] +; + TslAssignee returns TslAssignee: {TslPlaceholder} 'var' name=ID (':' ^type=TslType)? (groupedBy=TslGroupedBy)? - | TslReference + | TslPlaceholderReference ; interface TslExpressionStatement extends TslStatement { diff --git a/packages/ttsl-lang/tests/resources/generation/statements/Loops/forLoop/generated/tests/generator/forLoop/gen_input.py b/packages/ttsl-lang/tests/resources/generation/statements/Loops/forLoop/generated/tests/generator/forLoop/gen_input.py new file mode 100644 index 00000000..1b763cba --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/statements/Loops/forLoop/generated/tests/generator/forLoop/gen_input.py @@ -0,0 +1,8 @@ +# Functions -------------------------------------------------------------------- + +def myFunction(): + x = 0 + i = 0 + while (i) <= (10): + i = (i) + (1) + return x diff --git a/packages/ttsl-lang/tests/resources/generation/statements/Loops/forLoop/generated/tests/generator/forLoop/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/statements/Loops/forLoop/generated/tests/generator/forLoop/gen_input.py.map new file mode 100644 index 00000000..6cd9b759 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/statements/Loops/forLoop/generated/tests/generator/forLoop/gen_input.py.map @@ -0,0 +1 @@ +{"version":3,"sources":["input.ttsl"],"names":["myfunction","i"],"mappings":"AAAA;;AAEA,IAASA,UAAU;IACf,IAAQ,CAAC;IACL,IAAQ,CAAC;UAAE,CAAAC,CAAC,EAAC,EAAE,EAAC,EAAE;QAAEA,CAAC,GAAG,CAAAA,CAAC,EAAA,CAAC,EAAA,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/statements/Loops/forLoop/generated/tests/generator/forLoop/gen_input_myFunction.py b/packages/ttsl-lang/tests/resources/generation/statements/Loops/forLoop/generated/tests/generator/forLoop/gen_input_myFunction.py new file mode 100644 index 00000000..1e39903c --- /dev/null +++ b/packages/ttsl-lang/tests/resources/generation/statements/Loops/forLoop/generated/tests/generator/forLoop/gen_input_myFunction.py @@ -0,0 +1,4 @@ +from .gen_input import myFunction + +if __name__ == '__main__': + myFunction() diff --git a/packages/ttsl-lang/tests/resources/generation/statements/Loops/foreachLoop/input.ttsl b/packages/ttsl-lang/tests/resources/generation/statements/Loops/foreachLoop/input.ttsl index f5cac2ab..11f32524 100644 --- a/packages/ttsl-lang/tests/resources/generation/statements/Loops/foreachLoop/input.ttsl +++ b/packages/ttsl-lang/tests/resources/generation/statements/Loops/foreachLoop/input.ttsl @@ -5,7 +5,7 @@ constant list: List = [1,2,3] function myFunction (): Int { var x = 0; foreach(elm in list){ - x = x + elm; + var y = x + elm; } return x; } \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/statements/Loops/whileLoop/generated/tests/generator/whileLoop/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/statements/Loops/whileLoop/generated/tests/generator/whileLoop/gen_input.py.map index 4c551223..f26da151 100644 --- a/packages/ttsl-lang/tests/resources/generation/statements/Loops/whileLoop/generated/tests/generator/whileLoop/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/statements/Loops/whileLoop/generated/tests/generator/whileLoop/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.ttsl"],"names":["myfunction","i"],"mappings":"AAAA;;AAEA,IAASA,UAAU;IACf,IAAa,CAAC;IACd,MAAM,CAAAC,CAAC,EAAC,EAAE,EAAC,CAAC;QAAC","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["myfunction","i"],"mappings":"AAAA;;AAEA,IAASA,UAAU;IACf,IAAa,CAAC;IACd,MAAM,CAAAC,CAAC,EAAC,EAAE,EAAC,CAAC;QACRA,CAAC,GAAG,CAAC","file":"gen_input.py"} \ No newline at end of file From 75b28073d7a6dfe229d0edb31fc9d4ea9b94848c Mon Sep 17 00:00:00 2001 From: methr0 Date: Sat, 24 Aug 2024 12:09:15 +0200 Subject: [PATCH 160/183] fix foreach element type computation --- .../generation/ttsl-python-generator.ts | 2 +- .../src/language/typing/ttsl-type-computer.ts | 44 ++++++++++--------- .../tests/generator/forEachLoop/gen_input.py | 2 +- .../generator/forEachLoop/gen_input.py.map | 2 +- .../statements/Loops/foreachLoop/input.ttsl | 2 +- 5 files changed, 28 insertions(+), 24 deletions(-) diff --git a/packages/ttsl-lang/src/language/generation/ttsl-python-generator.ts b/packages/ttsl-lang/src/language/generation/ttsl-python-generator.ts index 6906ad41..c2610d4c 100644 --- a/packages/ttsl-lang/src/language/generation/ttsl-python-generator.ts +++ b/packages/ttsl-lang/src/language/generation/ttsl-python-generator.ts @@ -888,7 +888,7 @@ export class TTSLPythonGenerator { while ${this.generateExpression((statement.condition), frame)}:`.appendNewLine().indent(indentingNode => indentingNode.append(this.generateBlock((statement.block), frame)).append(thirdParameter)); } else if (isTslForeachLoop(statement)){ - return expandTracedToNode(statement)`for ${statement.element} in ${statement.list}:`.appendNewLine().indent(indentingNode => + return expandTracedToNode(statement)`for ${statement.element.name} in ${this.generateExpression(statement.list, frame).contents}:`.appendNewLine().indent(indentingNode => indentingNode.append(this.generateBlock((statement.block), frame))); } }else if (isTslReturnStatement(statement)){ diff --git a/packages/ttsl-lang/src/language/typing/ttsl-type-computer.ts b/packages/ttsl-lang/src/language/typing/ttsl-type-computer.ts index e3c004a4..69058023 100644 --- a/packages/ttsl-lang/src/language/typing/ttsl-type-computer.ts +++ b/packages/ttsl-lang/src/language/typing/ttsl-type-computer.ts @@ -46,6 +46,7 @@ import { isTslTypeParameterList, isTslTypeParameter, TslTypeParameter, + isTslConstant, } from '../generated/ast.js'; import { TTSLServices } from '../ttsl-module.js'; import { @@ -110,13 +111,7 @@ export class TTSLTypeComputer { return this.computeTypeOfExpression(node); } else if (isTslType(node)) { return this.computeTypeOfType(node); - } else if (isTslTypeParameter(node)){ - console.log(node.$containerProperty) - return this.computeTypeOfTypeParameter(node); - } else if (isTslLocalVariable(node)){ - console.log(node.$containerProperty) - return this.computeTypeOfElm(node); - }/* c8 ignore start */ else { + } /* c8 ignore start */ else { return UnknownType; } /* c8 ignore stop */ } @@ -139,7 +134,11 @@ export class TTSLTypeComputer { return this.computeTypeOfParameter(node); } else if (isTslResult(node)) { return this.computeType(node.type); - } /* c8 ignore start */ else { + } else if (isTslConstant(node)){ + return this.computeType(node.type); + } else if (isTslLocalVariable(node) && isTslForeachLoop(node.$container)){ + return this.computeTypeOfElm(node); + }/* c8 ignore start */ else { return UnknownType; } /* c8 ignore stop */ } @@ -332,24 +331,24 @@ export class TTSLTypeComputer { } else if (isTslAnyType(node)) { return new AnyType(false); } else if (isTslListType(node)) { - const elementType = this.lowestCommonSupertype(node.typeParameterList.typeParameters.map((it) => this.computeType(it))); - return new ListType([elementType], false); + const elementType = node.typeParameterList.typeParameters.map((it) => this.computeTypeOfType(it.type)); + return new ListType(elementType, false); } else if (isTslDictionaryType(node)) { - const types = this.lowestCommonSupertype(node.typeParameterList.typeParameters.map((it) => this.computeType(it))); - return new DictionaryType([types], false); + const types = node.typeParameterList.typeParameters.map((it) => this.computeTypeOfType(it.type)); + return new DictionaryType(types, false); } /* c8 ignore start */ else { return UnknownType; } /* c8 ignore stop */ } - private computeTypeOfTypeParameter(node: TslTypeParameter): Type{ - return this.computeType(node.type) - } - private computeTypeOfElm(node: TslLocalVariable): Type{ - console.log(node) if(isTslForeachLoop(node.$container)){ - return this.computeType(node.$container.list) + let listType = this.computeType(node.$container.list) + if(listType instanceof ListType){ + return listType.getTypeParameterTypeByIndex(0) + } else{ + return UnknownType; + } } /* c8 ignore start */ else { return UnknownType; } /* c8 ignore stop */ @@ -396,6 +395,11 @@ export class TTSLTypeComputer { return this.Any(isNullable); } + let firstType = types.at(0) + if (firstType && types.every(type => type.toString() === firstType.toString())){ + return types[0]! + } + return UnknownType } @@ -409,13 +413,13 @@ export class TTSLTypeComputer { containsUnknownType: false, containsOtherType: false, }; - + for (const type of types) { if (type.equals(new NothingType(false)) || type.equals(new NothingType(true))) { // Drop Nothing/Nothing? types. They are compatible to everything with appropriate nullability. } else if (type === UnknownType) { result.containsUnknownType = true; - } else { + } else if(!(type instanceof AnyType)) { // Since these types don't occur in legal programs, we don't need to handle them better result.containsOtherType = true; return result; diff --git a/packages/ttsl-lang/tests/resources/generation/statements/Loops/foreachLoop/generated/tests/generator/forEachLoop/gen_input.py b/packages/ttsl-lang/tests/resources/generation/statements/Loops/foreachLoop/generated/tests/generator/forEachLoop/gen_input.py index d6d3c25c..ef383333 100644 --- a/packages/ttsl-lang/tests/resources/generation/statements/Loops/foreachLoop/generated/tests/generator/forEachLoop/gen_input.py +++ b/packages/ttsl-lang/tests/resources/generation/statements/Loops/foreachLoop/generated/tests/generator/forEachLoop/gen_input.py @@ -29,7 +29,7 @@ def getValue(self, date = None): def myFunction(): x = 0 for elm in list: - x = x + elm + x = (x) + (elm) return x # Constants -------------------------------------------------------------------- diff --git a/packages/ttsl-lang/tests/resources/generation/statements/Loops/foreachLoop/generated/tests/generator/forEachLoop/gen_input.py.map b/packages/ttsl-lang/tests/resources/generation/statements/Loops/foreachLoop/generated/tests/generator/forEachLoop/gen_input.py.map index 5ca7b3ef..c187ed68 100644 --- a/packages/ttsl-lang/tests/resources/generation/statements/Loops/foreachLoop/generated/tests/generator/forEachLoop/gen_input.py.map +++ b/packages/ttsl-lang/tests/resources/generation/statements/Loops/foreachLoop/generated/tests/generator/forEachLoop/gen_input.py.map @@ -1 +1 @@ -{"version":3,"sources":["input.ttsl"],"names":["myfunction"],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAIA,IAASA,UAAU;IACf,IAAQ,CAAC;IACT;oBAAoB;;;;;AAJxB,OAAA,+BAA2B,CAAC,CAAC,EAAC,CAAC,EAAC,CAAC","file":"gen_input.py"} \ No newline at end of file +{"version":3,"sources":["input.ttsl"],"names":["myfunction","x","elm"],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAIA,IAASA,UAAU;IACf,IAAQ,CAAC;IACT;QACIC,CAAC,GAAG,CAAAA,CAAC,EAAC,CAAC,EAACC,GAAG;;;;;AALnB,OAAA,+BAA2B,CAAC,CAAC,EAAC,CAAC,EAAC,CAAC","file":"gen_input.py"} \ No newline at end of file diff --git a/packages/ttsl-lang/tests/resources/generation/statements/Loops/foreachLoop/input.ttsl b/packages/ttsl-lang/tests/resources/generation/statements/Loops/foreachLoop/input.ttsl index 11f32524..f5cac2ab 100644 --- a/packages/ttsl-lang/tests/resources/generation/statements/Loops/foreachLoop/input.ttsl +++ b/packages/ttsl-lang/tests/resources/generation/statements/Loops/foreachLoop/input.ttsl @@ -5,7 +5,7 @@ constant list: List = [1,2,3] function myFunction (): Int { var x = 0; foreach(elm in list){ - var y = x + elm; + x = x + elm; } return x; } \ No newline at end of file From 75aab3f11542dd887217c7691ec29187f8730435 Mon Sep 17 00:00:00 2001 From: methr0 Date: Thu, 29 Aug 2024 10:01:00 +0200 Subject: [PATCH 161/183] Update existing partial evaluation tests file extention --- .../call graph/annotation call.sdstest | 8 ----- .../argument/block lambda.sdstest | 14 -------- .../callable does not get called.sdstest | 10 ------ .../argument/expression lambda.sdstest | 12 ------- .../argument/function.sdstest | 12 ------- .../argument/segment.sdstest | 16 --------- .../block lambda call/basic.sdstest | 8 ----- .../function call in nested lambda.sdstest | 10 ------ .../body/function call.sdstest | 10 ------ .../default value/call.sdstest | 12 ------- .../default value/callable.sdstest | 14 -------- .../default value/previous parameter.sdstest | 13 ------- .../block lambda call/null safe.sdstest | 8 ----- .../class call/argument/call.sdstest | 13 ------- .../class call/argument/callable.sdstest | 13 ------- .../class call/argument/other.sdstest | 13 ------- .../call graph/class call/basic.sdstest | 8 ----- .../class call/default value/call.sdstest | 13 ------- .../class call/default value/callable.sdstest | 13 ------- .../default value/previous parameter.sdstest | 13 ------- .../call graph/class call/null safe.sdstest | 8 ----- .../enum variant call/argument/call.sdstest | 15 -------- .../argument/callable.sdstest | 15 -------- .../enum variant call/argument/other.sdstest | 15 -------- .../enum variant call/basic.sdstest | 10 ------ .../enum variant call/called twice.sdstest | 10 ------ .../default value/call.sdstest | 15 -------- .../default value/callable.sdstest | 15 -------- .../default value/previous parameter.sdstest | 15 -------- .../enum variant call/null safe.sdstest | 10 ------ .../argument/block lambda.sdstest | 13 ------- .../callable does not get called.sdstest | 10 ------ .../argument/expression lambda.sdstest | 11 ------ .../argument/function.sdstest | 11 ------ .../argument/segment.sdstest | 15 -------- .../expression lambda call/basic.sdstest | 8 ----- .../function call in nested lambda.sdstest | 10 ------ .../body/function call.sdstest | 10 ------ .../default value/call.sdstest | 12 ------- .../default value/callable.sdstest | 12 ------- .../default value/previous parameter.sdstest | 13 ------- .../expression lambda call/null safe.sdstest | 8 ----- .../argument/block lambda.sdstest | 14 -------- .../callable does not get called.sdstest | 10 ------ .../argument/expression lambda.sdstest | 12 ------- .../segment call/argument/function.sdstest | 12 ------- .../segment call/argument/segment.sdstest | 16 --------- .../call graph/segment call/basic.sdstest | 8 ----- .../function call in nested lambda.sdstest | 12 ------- .../segment call/body/function call.sdstest | 12 ------- .../segment call/default value/call.sdstest | 12 ------- .../default value/callable.sdstest | 14 -------- .../default value/previous parameter.sdstest | 13 ------- .../call graph/segment call/null safe.sdstest | 8 ----- .../base cases/block lambdas/main.sdstest | 6 ---- .../{main.sdstest => main.ttsl} | 0 .../base cases/classes/main.sdstest | 4 --- .../base cases/enum variants/main.sdstest | 6 ---- .../expression lambdas/main.sdstest | 6 ---- .../{main.sdstest => main.ttsl} | 0 .../functions/{main.sdstest => main.ttsl} | 2 +- .../int literals/{main.sdstest => main.ttsl} | 0 .../null literals/{main.sdstest => main.ttsl} | 0 .../base cases/segments/main.sdstest | 4 --- .../{main.sdstest => main.ttsl} | 0 .../invalid nodes/{main.sdstest => main.ttsl} | 0 .../arguments/{main.sdstest => main.ttsl} | 2 +- .../block lambda results/main.sdstest | 17 --------- .../placeholders/{main.sdstest => main.ttsl} | 8 ++--- .../assignees/wildcards/main.sdstest | 15 -------- .../assignees/yields/main.sdstest | 15 -------- .../calls/of block lambdas/closure.sdstest | 12 ------- .../calls/of block lambdas/main.sdstest | 11 ------ ...ameter value used as default value.sdstest | 10 ------ .../calls/of classes/main.sdstest | 8 ----- .../calls/of enum variants/main.sdstest | 35 ------------------- .../of expression lambdas/closure.sdstest | 10 ------ .../calls/of expression lambdas/main.sdstest | 8 ----- ...ameter value used as default value.sdstest | 8 ----- .../of functions/{main.sdstest => main.ttsl} | 2 +- .../calls/of segments/main.sdstest | 10 ------ ...ameter value used as default value.sdstest | 10 ------ .../calls/of unknown parameter/main.sdstest | 6 ---- .../calls/on null/{main.sdstest => main.ttsl} | 2 +- .../recursion/{main.sdstest => main.ttsl} | 4 +-- .../calls/unresolved/main.sdstest | 13 ------- .../on lists/{main.sdstest => main.ttsl} | 0 .../on maps/{main.sdstest => main.ttsl} | 0 .../on null/{main.sdstest => main.ttsl} | 0 .../on other/{main.sdstest => main.ttsl} | 0 .../and/{main.sdstest => main.ttsl} | 0 .../and/short circuiting.sdstest | 30 ---------------- .../and/short circuiting.ttsl | 11 ++++++ .../divided by/{main.sdstest => main.ttsl} | 0 .../elvis/{main.sdstest => main.ttsl} | 6 ---- .../elvis/short circuiting.sdstest | 30 ---------------- .../elvis/short circuiting.ttsl | 11 ++++++ .../equals/{main.sdstest => main.ttsl} | 0 .../{main.sdstest => main.ttsl} | 0 .../greater than/{main.sdstest => main.ttsl} | 0 .../identical to/{main.sdstest => main.ttsl} | 0 .../{main.sdstest => main.ttsl} | 0 .../less than/{main.sdstest => main.ttsl} | 0 .../minus/{main.sdstest => main.ttsl} | 0 .../not equals/{main.sdstest => main.ttsl} | 0 .../{main.sdstest => main.ttsl} | 0 .../or/{main.sdstest => main.ttsl} | 0 .../or/short circuiting.sdstest | 30 ---------------- .../infix operations/or/short circuiting.ttsl | 11 ++++++ .../plus/{main.sdstest => main.ttsl} | 0 .../times/{main.sdstest => main.ttsl} | 0 .../lists/{main.sdstest => main.ttsl} | 0 .../maps/{main.sdstest => main.ttsl} | 0 .../recursive cases/parameters/main.sdstest | 22 ------------ .../recursive cases/parameters/main.ttsl | 10 ++++++ .../{main.sdstest => main.ttsl} | 0 .../minus/{main.sdstest => main.ttsl} | 0 .../not/{main.sdstest => main.ttsl} | 0 .../references/{main.sdstest => main.ttsl} | 2 +- .../recursive cases/results/main.sdstest | 12 ------- .../recursive cases/results/main.ttsl | 7 ++++ .../{main.sdstest => main.ttsl} | 0 .../type casts/{main.sdstest => main.ttsl} | 0 .../in same file/to functions/main.ttsl | 19 +++++----- 124 files changed, 68 insertions(+), 1004 deletions(-) delete mode 100644 packages/ttsl-lang/tests/resources/call graph/annotation call.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/block lambda.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/callable does not get called.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/expression lambda.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/function.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/segment.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/call graph/block lambda call/basic.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/call graph/block lambda call/body/function call in nested lambda.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/call graph/block lambda call/body/function call.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/call graph/block lambda call/default value/call.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/call graph/block lambda call/default value/callable.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/call graph/block lambda call/default value/previous parameter.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/call graph/block lambda call/null safe.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/call graph/class call/argument/call.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/call graph/class call/argument/callable.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/call graph/class call/argument/other.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/call graph/class call/basic.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/call graph/class call/default value/call.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/call graph/class call/default value/callable.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/call graph/class call/default value/previous parameter.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/call graph/class call/null safe.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/call graph/enum variant call/argument/call.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/call graph/enum variant call/argument/callable.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/call graph/enum variant call/argument/other.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/call graph/enum variant call/basic.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/call graph/enum variant call/called twice.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/call graph/enum variant call/default value/call.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/call graph/enum variant call/default value/callable.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/call graph/enum variant call/default value/previous parameter.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/call graph/enum variant call/null safe.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/block lambda.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/callable does not get called.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/expression lambda.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/function.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/segment.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/call graph/expression lambda call/basic.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/call graph/expression lambda call/body/function call in nested lambda.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/call graph/expression lambda call/body/function call.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/call graph/expression lambda call/default value/call.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/call graph/expression lambda call/default value/callable.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/call graph/expression lambda call/default value/previous parameter.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/call graph/expression lambda call/null safe.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/call graph/segment call/argument/block lambda.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/call graph/segment call/argument/callable does not get called.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/call graph/segment call/argument/expression lambda.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/call graph/segment call/argument/function.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/call graph/segment call/argument/segment.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/call graph/segment call/basic.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/call graph/segment call/body/function call in nested lambda.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/call graph/segment call/body/function call.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/call graph/segment call/default value/call.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/call graph/segment call/default value/callable.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/call graph/segment call/default value/previous parameter.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/call graph/segment call/null safe.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/partial evaluation/base cases/block lambdas/main.sdstest rename packages/ttsl-lang/tests/resources/partial evaluation/base cases/boolean literals/{main.sdstest => main.ttsl} (100%) delete mode 100644 packages/ttsl-lang/tests/resources/partial evaluation/base cases/classes/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/partial evaluation/base cases/enum variants/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/partial evaluation/base cases/expression lambdas/main.sdstest rename packages/ttsl-lang/tests/resources/partial evaluation/base cases/float literals/{main.sdstest => main.ttsl} (100%) rename packages/ttsl-lang/tests/resources/partial evaluation/base cases/functions/{main.sdstest => main.ttsl} (79%) rename packages/ttsl-lang/tests/resources/partial evaluation/base cases/int literals/{main.sdstest => main.ttsl} (100%) rename packages/ttsl-lang/tests/resources/partial evaluation/base cases/null literals/{main.sdstest => main.ttsl} (100%) delete mode 100644 packages/ttsl-lang/tests/resources/partial evaluation/base cases/segments/main.sdstest rename packages/ttsl-lang/tests/resources/partial evaluation/base cases/string literals (without interpolation)/{main.sdstest => main.ttsl} (100%) rename packages/ttsl-lang/tests/resources/partial evaluation/invalid nodes/{main.sdstest => main.ttsl} (100%) rename packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/arguments/{main.sdstest => main.ttsl} (89%) delete mode 100644 packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/block lambda results/main.sdstest rename packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/placeholders/{main.sdstest => main.ttsl} (51%) delete mode 100644 packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/wildcards/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/yields/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of block lambdas/closure.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of block lambdas/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of block lambdas/previous parameter value used as default value.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of classes/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of enum variants/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of expression lambdas/closure.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of expression lambdas/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of expression lambdas/previous parameter value used as default value.sdstest rename packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of functions/{main.sdstest => main.ttsl} (89%) delete mode 100644 packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of segments/main.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of segments/previous parameter value used as default value.sdstest delete mode 100644 packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of unknown parameter/main.sdstest rename packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/on null/{main.sdstest => main.ttsl} (86%) rename packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/recursion/{main.sdstest => main.ttsl} (59%) delete mode 100644 packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/unresolved/main.sdstest rename packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on lists/{main.sdstest => main.ttsl} (100%) rename packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on maps/{main.sdstest => main.ttsl} (100%) rename packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on null/{main.sdstest => main.ttsl} (100%) rename packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on other/{main.sdstest => main.ttsl} (100%) rename packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/and/{main.sdstest => main.ttsl} (100%) delete mode 100644 packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/and/short circuiting.sdstest create mode 100644 packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/and/short circuiting.ttsl rename packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/divided by/{main.sdstest => main.ttsl} (100%) rename packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/elvis/{main.sdstest => main.ttsl} (68%) delete mode 100644 packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/elvis/short circuiting.sdstest create mode 100644 packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/elvis/short circuiting.ttsl rename packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/equals/{main.sdstest => main.ttsl} (100%) rename packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/greater than or equals/{main.sdstest => main.ttsl} (100%) rename packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/greater than/{main.sdstest => main.ttsl} (100%) rename packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/identical to/{main.sdstest => main.ttsl} (100%) rename packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/less than or equals/{main.sdstest => main.ttsl} (100%) rename packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/less than/{main.sdstest => main.ttsl} (100%) rename packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/minus/{main.sdstest => main.ttsl} (100%) rename packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/not equals/{main.sdstest => main.ttsl} (100%) rename packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/not identical to/{main.sdstest => main.ttsl} (100%) rename packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/or/{main.sdstest => main.ttsl} (100%) delete mode 100644 packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/or/short circuiting.sdstest create mode 100644 packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/or/short circuiting.ttsl rename packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/plus/{main.sdstest => main.ttsl} (100%) rename packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/times/{main.sdstest => main.ttsl} (100%) rename packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/lists/{main.sdstest => main.ttsl} (100%) rename packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/maps/{main.sdstest => main.ttsl} (100%) delete mode 100644 packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/parameters/main.sdstest create mode 100644 packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/parameters/main.ttsl rename packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/parenthesized expressions/{main.sdstest => main.ttsl} (100%) rename packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/prefix operations/minus/{main.sdstest => main.ttsl} (100%) rename packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/prefix operations/not/{main.sdstest => main.ttsl} (100%) rename packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/references/{main.sdstest => main.ttsl} (92%) delete mode 100644 packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/results/main.sdstest create mode 100644 packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/results/main.ttsl rename packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/template strings/{main.sdstest => main.ttsl} (100%) rename packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/type casts/{main.sdstest => main.ttsl} (100%) diff --git a/packages/ttsl-lang/tests/resources/call graph/annotation call.sdstest b/packages/ttsl-lang/tests/resources/call graph/annotation call.sdstest deleted file mode 100644 index 146e5ce8..00000000 --- a/packages/ttsl-lang/tests/resources/call graph/annotation call.sdstest +++ /dev/null @@ -1,8 +0,0 @@ -package tests.callGraph.annotationCall - -annotation MyAnnotation - -function myFunction () { - # $TEST$ ["undefined"] - »MyAnnotation()«; -} diff --git a/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/block lambda.sdstest b/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/block lambda.sdstest deleted file mode 100644 index c854dad0..00000000 --- a/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/block lambda.sdstest +++ /dev/null @@ -1,14 +0,0 @@ -package tests.callGraph.blockLambdaCall.argument.blockLambda - -@Pure fun f() - -function myFunction () { - val lambda = (param1: (param: () -> ()) -> ()) { - param1(f); - }; - - # $TEST$ ["$blockLambda", "$blockLambda", "f"] - »lambda((param) { - param(); - })«; -} diff --git a/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/callable does not get called.sdstest b/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/callable does not get called.sdstest deleted file mode 100644 index 21b0ad63..00000000 --- a/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/callable does not get called.sdstest +++ /dev/null @@ -1,10 +0,0 @@ -package tests.callGraph.blockLambdaCall.argument.callableDoesNotGetCalled - -@Pure fun f() - -function myFunction () { - val lambda = (param: () -> ()) {}; - - # $TEST$ ["$blockLambda"] - »lambda(f)«; -} diff --git a/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/expression lambda.sdstest b/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/expression lambda.sdstest deleted file mode 100644 index bd7562ce..00000000 --- a/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/expression lambda.sdstest +++ /dev/null @@ -1,12 +0,0 @@ -package tests.callGraph.blockLambdaCall.argument.expressionLambda - -@Pure fun f() - -function myFunction () { - val lambda = (param1: (param: () -> ()) -> ()) { - param1(f); - }; - - # $TEST$ ["$blockLambda", "$expressionLambda", "f"] - »lambda((param) -> param())«; -} diff --git a/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/function.sdstest b/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/function.sdstest deleted file mode 100644 index 29b15f41..00000000 --- a/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/function.sdstest +++ /dev/null @@ -1,12 +0,0 @@ -package tests.callGraph.blockLambdaCall.argument.function - -@Pure fun f() - -function myFunction () { - val lambda = (param: () -> ()) { - param(); - }; - - # $TEST$ ["$blockLambda", "f"] - »lambda(f)«; -} diff --git a/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/segment.sdstest b/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/segment.sdstest deleted file mode 100644 index f05ac5bf..00000000 --- a/packages/ttsl-lang/tests/resources/call graph/block lambda call/argument/segment.sdstest +++ /dev/null @@ -1,16 +0,0 @@ -package tests.callGraph.blockLambdaCall.argument.`segment` - -@Pure fun f() - -function myFunction () { - val lambda = (param1: (param: () -> ()) -> ()) { - param1(f); - }; - - # $TEST$ ["$blockLambda", "mySegment", "f"] - »lambda(mySegment)«; -} - -segment mySegment(param: () -> ()) { - param(); -} diff --git a/packages/ttsl-lang/tests/resources/call graph/block lambda call/basic.sdstest b/packages/ttsl-lang/tests/resources/call graph/block lambda call/basic.sdstest deleted file mode 100644 index 5ca27c5d..00000000 --- a/packages/ttsl-lang/tests/resources/call graph/block lambda call/basic.sdstest +++ /dev/null @@ -1,8 +0,0 @@ -package tests.callGraph.blockLambdaCall.basic - -function myFunction () { - val lambda = () {}; - - # $TEST$ ["$blockLambda"] - »lambda()«; -} diff --git a/packages/ttsl-lang/tests/resources/call graph/block lambda call/body/function call in nested lambda.sdstest b/packages/ttsl-lang/tests/resources/call graph/block lambda call/body/function call in nested lambda.sdstest deleted file mode 100644 index 447206a3..00000000 --- a/packages/ttsl-lang/tests/resources/call graph/block lambda call/body/function call in nested lambda.sdstest +++ /dev/null @@ -1,10 +0,0 @@ -package tests.callGraph.blockLambdaCall.body.functionCallInNestedLambda - -@Pure fun f() - -function myFunction () { - val lambda = () { () -> f(); }; - - # $TEST$ ["$blockLambda"] - »lambda()«; -} diff --git a/packages/ttsl-lang/tests/resources/call graph/block lambda call/body/function call.sdstest b/packages/ttsl-lang/tests/resources/call graph/block lambda call/body/function call.sdstest deleted file mode 100644 index 383279b0..00000000 --- a/packages/ttsl-lang/tests/resources/call graph/block lambda call/body/function call.sdstest +++ /dev/null @@ -1,10 +0,0 @@ -package tests.callGraph.blockLambdaCall.body.functionCall - -@Pure fun f() - -function myFunction () { - val lambda = () { f(); }; - - # $TEST$ ["$blockLambda", "f"] - »lambda()«; -} diff --git a/packages/ttsl-lang/tests/resources/call graph/block lambda call/default value/call.sdstest b/packages/ttsl-lang/tests/resources/call graph/block lambda call/default value/call.sdstest deleted file mode 100644 index 0b2e06c0..00000000 --- a/packages/ttsl-lang/tests/resources/call graph/block lambda call/default value/call.sdstest +++ /dev/null @@ -1,12 +0,0 @@ -package tests.callGraph.blockLambdaCall.defaultValue.call - -@Pure fun default() -> r: Any - -function myFunction () { - val lambda = ( - f: Any = default() - ) {}; - - # $TEST$ ["$blockLambda", "default"] - »lambda()«; -} diff --git a/packages/ttsl-lang/tests/resources/call graph/block lambda call/default value/callable.sdstest b/packages/ttsl-lang/tests/resources/call graph/block lambda call/default value/callable.sdstest deleted file mode 100644 index 4a8c5c7a..00000000 --- a/packages/ttsl-lang/tests/resources/call graph/block lambda call/default value/callable.sdstest +++ /dev/null @@ -1,14 +0,0 @@ -package tests.callGraph.blockLambdaCall.defaultValue.callable - -@Pure fun default() - -function myFunction () { - val lambda = ( - f: () -> () = default - ) { - f(); - }; - - # $TEST$ ["$blockLambda", "default"] - »lambda()«; -} diff --git a/packages/ttsl-lang/tests/resources/call graph/block lambda call/default value/previous parameter.sdstest b/packages/ttsl-lang/tests/resources/call graph/block lambda call/default value/previous parameter.sdstest deleted file mode 100644 index b9348fcd..00000000 --- a/packages/ttsl-lang/tests/resources/call graph/block lambda call/default value/previous parameter.sdstest +++ /dev/null @@ -1,13 +0,0 @@ -package tests.callGraph.blockLambdaCall.defaultValue.previousParameter - -@Pure fun default() -> result: Any - -function myFunction () { - val lambda = ( - f: () -> (result: Any) = default, - g: Any = f() - ) {}; - - # $TEST$ ["$blockLambda", "default"] - »lambda()«; -} diff --git a/packages/ttsl-lang/tests/resources/call graph/block lambda call/null safe.sdstest b/packages/ttsl-lang/tests/resources/call graph/block lambda call/null safe.sdstest deleted file mode 100644 index 77cdbf94..00000000 --- a/packages/ttsl-lang/tests/resources/call graph/block lambda call/null safe.sdstest +++ /dev/null @@ -1,8 +0,0 @@ -package tests.callGraph.blockLambdaCall.nullSafe - -function myFunction () { - val lambda = () {}; - - # $TEST$ ["$blockLambda"] - »lambda?()«; -} diff --git a/packages/ttsl-lang/tests/resources/call graph/class call/argument/call.sdstest b/packages/ttsl-lang/tests/resources/call graph/class call/argument/call.sdstest deleted file mode 100644 index c7e482b5..00000000 --- a/packages/ttsl-lang/tests/resources/call graph/class call/argument/call.sdstest +++ /dev/null @@ -1,13 +0,0 @@ -package tests.callGraph.classCall.argument.call - -class Default() -class Passed() - -class MyClass( - f: Any = Default() -) - -function myFunction () { - # $TEST$ ["MyClass"] - »MyClass(Passed())«; -} diff --git a/packages/ttsl-lang/tests/resources/call graph/class call/argument/callable.sdstest b/packages/ttsl-lang/tests/resources/call graph/class call/argument/callable.sdstest deleted file mode 100644 index bd567855..00000000 --- a/packages/ttsl-lang/tests/resources/call graph/class call/argument/callable.sdstest +++ /dev/null @@ -1,13 +0,0 @@ -package tests.callGraph.classCall.argument.callable - -class Default() -class Passed() - -class MyClass( - f: () -> () = Default -) - -function myFunction () { - # $TEST$ ["MyClass", "Passed"] - »MyClass(Passed)«; -} diff --git a/packages/ttsl-lang/tests/resources/call graph/class call/argument/other.sdstest b/packages/ttsl-lang/tests/resources/call graph/class call/argument/other.sdstest deleted file mode 100644 index 1dbb72c3..00000000 --- a/packages/ttsl-lang/tests/resources/call graph/class call/argument/other.sdstest +++ /dev/null @@ -1,13 +0,0 @@ -package tests.callGraph.classCall.argument.other - -class Default() -class Passed() - -class MyClass( - f: Any = Default() -) - -function myFunction () { - # $TEST$ ["MyClass"] - »MyClass(1)«; -} diff --git a/packages/ttsl-lang/tests/resources/call graph/class call/basic.sdstest b/packages/ttsl-lang/tests/resources/call graph/class call/basic.sdstest deleted file mode 100644 index e07ff838..00000000 --- a/packages/ttsl-lang/tests/resources/call graph/class call/basic.sdstest +++ /dev/null @@ -1,8 +0,0 @@ -package tests.callGraph.classCall.basic - -class MyClass() - -function myFunction () { - # $TEST$ ["MyClass"] - »MyClass()«; -} diff --git a/packages/ttsl-lang/tests/resources/call graph/class call/default value/call.sdstest b/packages/ttsl-lang/tests/resources/call graph/class call/default value/call.sdstest deleted file mode 100644 index 448690e5..00000000 --- a/packages/ttsl-lang/tests/resources/call graph/class call/default value/call.sdstest +++ /dev/null @@ -1,13 +0,0 @@ -package tests.callGraph.classCall.defaultValue.call - -class Default() -class Passed() - -class MyClass( - f: Any = Default() -) - -function myFunction () { - # $TEST$ ["MyClass", "Default"] - »MyClass()«; -} diff --git a/packages/ttsl-lang/tests/resources/call graph/class call/default value/callable.sdstest b/packages/ttsl-lang/tests/resources/call graph/class call/default value/callable.sdstest deleted file mode 100644 index 8d07f566..00000000 --- a/packages/ttsl-lang/tests/resources/call graph/class call/default value/callable.sdstest +++ /dev/null @@ -1,13 +0,0 @@ -package tests.callGraph.classCall.defaultValue.callable - -class Default() -class Passed() - -class MyClass( - f: () -> () = Default -) - -function myFunction () { - # $TEST$ ["MyClass", "Default"] - »MyClass()«; -} diff --git a/packages/ttsl-lang/tests/resources/call graph/class call/default value/previous parameter.sdstest b/packages/ttsl-lang/tests/resources/call graph/class call/default value/previous parameter.sdstest deleted file mode 100644 index 7885648a..00000000 --- a/packages/ttsl-lang/tests/resources/call graph/class call/default value/previous parameter.sdstest +++ /dev/null @@ -1,13 +0,0 @@ -package tests.callGraph.classCall.defaultValue.previousParameter - -@Pure fun default() -> result: Any - -class MyClass( - f: () -> (result: Any) = default, - g: Any = f() -) - -function myFunction () { - # $TEST$ ["MyClass", "default", "default"] - »MyClass()«; -} diff --git a/packages/ttsl-lang/tests/resources/call graph/class call/null safe.sdstest b/packages/ttsl-lang/tests/resources/call graph/class call/null safe.sdstest deleted file mode 100644 index c2f93934..00000000 --- a/packages/ttsl-lang/tests/resources/call graph/class call/null safe.sdstest +++ /dev/null @@ -1,8 +0,0 @@ -package tests.callGraph.classCall.nullSafe - -class MyClass() - -function myFunction () { - # $TEST$ ["MyClass"] - »MyClass?()«; -} diff --git a/packages/ttsl-lang/tests/resources/call graph/enum variant call/argument/call.sdstest b/packages/ttsl-lang/tests/resources/call graph/enum variant call/argument/call.sdstest deleted file mode 100644 index 30ac130e..00000000 --- a/packages/ttsl-lang/tests/resources/call graph/enum variant call/argument/call.sdstest +++ /dev/null @@ -1,15 +0,0 @@ -package tests.callGraph.enumVariantCall.argument.call - -@Pure fun default() -> r: Any -@Pure fun passed() -> r: Any - -enum MyEnum { - MyVariant( - f: Any = default() - ) -} - -function myFunction () { - # $TEST$ ["MyVariant"] - »MyEnum.MyVariant(passed())«; -} diff --git a/packages/ttsl-lang/tests/resources/call graph/enum variant call/argument/callable.sdstest b/packages/ttsl-lang/tests/resources/call graph/enum variant call/argument/callable.sdstest deleted file mode 100644 index 37dc1622..00000000 --- a/packages/ttsl-lang/tests/resources/call graph/enum variant call/argument/callable.sdstest +++ /dev/null @@ -1,15 +0,0 @@ -package tests.callGraph.enumVariantCall.argument.callable - -@Pure fun default() -@Pure fun passed() - -enum MyEnum { - MyVariant( - f: () -> () = default - ) -} - -function myFunction () { - # $TEST$ ["MyVariant", "passed"] - »MyEnum.MyVariant(passed)«; -} diff --git a/packages/ttsl-lang/tests/resources/call graph/enum variant call/argument/other.sdstest b/packages/ttsl-lang/tests/resources/call graph/enum variant call/argument/other.sdstest deleted file mode 100644 index 598345da..00000000 --- a/packages/ttsl-lang/tests/resources/call graph/enum variant call/argument/other.sdstest +++ /dev/null @@ -1,15 +0,0 @@ -package tests.callGraph.enumVariantCall.argument.other - -@Pure fun default() -> r: Any -@Pure fun passed() -> r: Any - -enum MyEnum { - MyVariant( - f: Any = default() - ) -} - -function myFunction () { - # $TEST$ ["MyVariant"] - »MyEnum.MyVariant(1)«; -} diff --git a/packages/ttsl-lang/tests/resources/call graph/enum variant call/basic.sdstest b/packages/ttsl-lang/tests/resources/call graph/enum variant call/basic.sdstest deleted file mode 100644 index 9d017299..00000000 --- a/packages/ttsl-lang/tests/resources/call graph/enum variant call/basic.sdstest +++ /dev/null @@ -1,10 +0,0 @@ -package tests.callGraph.enumVariantCall.basic - -enum MyEnum { - MyVariant -} - -function myFunction () { - # $TEST$ ["MyVariant"] - »MyEnum.MyVariant()«; -} diff --git a/packages/ttsl-lang/tests/resources/call graph/enum variant call/called twice.sdstest b/packages/ttsl-lang/tests/resources/call graph/enum variant call/called twice.sdstest deleted file mode 100644 index 52fe8d5e..00000000 --- a/packages/ttsl-lang/tests/resources/call graph/enum variant call/called twice.sdstest +++ /dev/null @@ -1,10 +0,0 @@ -package tests.callGraph.enumVariantCall.calledTwice - -enum MyEnum { - MyVariant -} - -function myFunction () { - # $TEST$ ["undefined"] - »MyEnum.MyVariant()()«; -} diff --git a/packages/ttsl-lang/tests/resources/call graph/enum variant call/default value/call.sdstest b/packages/ttsl-lang/tests/resources/call graph/enum variant call/default value/call.sdstest deleted file mode 100644 index 29154572..00000000 --- a/packages/ttsl-lang/tests/resources/call graph/enum variant call/default value/call.sdstest +++ /dev/null @@ -1,15 +0,0 @@ -package tests.callGraph.enumVariantCall.defaultValue.call - -@Pure fun default() -> r: Any -@Pure fun passed() -> r: Any - -enum MyEnum { - MyVariant( - f: Any = default() - ) -} - -function myFunction () { - # $TEST$ ["MyVariant", "default"] - »MyEnum.MyVariant()«; -} diff --git a/packages/ttsl-lang/tests/resources/call graph/enum variant call/default value/callable.sdstest b/packages/ttsl-lang/tests/resources/call graph/enum variant call/default value/callable.sdstest deleted file mode 100644 index 1d821f9a..00000000 --- a/packages/ttsl-lang/tests/resources/call graph/enum variant call/default value/callable.sdstest +++ /dev/null @@ -1,15 +0,0 @@ -package tests.callGraph.enumVariantCall.defaultvalue.callable - -@Pure fun default() -@Pure fun passed() - -enum MyEnum { - MyVariant( - f: () -> () = default - ) -} - -function myFunction () { - # $TEST$ ["MyVariant", "default"] - »MyEnum.MyVariant()«; -} diff --git a/packages/ttsl-lang/tests/resources/call graph/enum variant call/default value/previous parameter.sdstest b/packages/ttsl-lang/tests/resources/call graph/enum variant call/default value/previous parameter.sdstest deleted file mode 100644 index 42ac7035..00000000 --- a/packages/ttsl-lang/tests/resources/call graph/enum variant call/default value/previous parameter.sdstest +++ /dev/null @@ -1,15 +0,0 @@ -package tests.callGraph.enumVariantCall.defaultValue.previousParameter - -@Pure fun default() -> result: Any - -enum MyEnum { - MyVariant( - f: () -> (result: Any) = default, - g: Any = f() - ) -} - -function myFunction () { - # $TEST$ ["MyVariant", "default", "default"] - »MyEnum.MyVariant()«; -} diff --git a/packages/ttsl-lang/tests/resources/call graph/enum variant call/null safe.sdstest b/packages/ttsl-lang/tests/resources/call graph/enum variant call/null safe.sdstest deleted file mode 100644 index 8dc14274..00000000 --- a/packages/ttsl-lang/tests/resources/call graph/enum variant call/null safe.sdstest +++ /dev/null @@ -1,10 +0,0 @@ -package tests.callGraph.enumVariantCall.nullSafe - -enum MyEnum { - MyVariant -} - -function myFunction () { - # $TEST$ ["MyVariant"] - »MyEnum.MyVariant?()«; -} diff --git a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/block lambda.sdstest b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/block lambda.sdstest deleted file mode 100644 index dbde7cd1..00000000 --- a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/block lambda.sdstest +++ /dev/null @@ -1,13 +0,0 @@ -package tests.callGraph.expressionLambdaCall.argument.blockLambda - -@Pure fun f() - -function myFunction () { - val lambda = (param1: (param: () -> ()) -> ()) -> - param1(f); - - # $TEST$ ["$expressionLambda", "$blockLambda", "f"] - »lambda((param) { - param(); - })«; -} diff --git a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/callable does not get called.sdstest b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/callable does not get called.sdstest deleted file mode 100644 index 02b0549f..00000000 --- a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/callable does not get called.sdstest +++ /dev/null @@ -1,10 +0,0 @@ -package tests.callGraph.expressionLambdaCall.argument.callableDoesNotGetCalled - -@Pure fun f() - -function myFunction () { - val lambda = (param: () -> ()) -> 1; - - # $TEST$ ["$expressionLambda"] - »lambda(f)«; -} diff --git a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/expression lambda.sdstest b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/expression lambda.sdstest deleted file mode 100644 index 83b90c3b..00000000 --- a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/expression lambda.sdstest +++ /dev/null @@ -1,11 +0,0 @@ -package tests.callGraph.expressionLambdaCall.argument.expressionLambda - -@Pure fun f() - -function myFunction () { - val lambda = (param1: (param: () -> ()) -> ()) -> - param1(f); - - # $TEST$ ["$expressionLambda", "$expressionLambda", "f"] - »lambda((param) -> param())«; -} diff --git a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/function.sdstest b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/function.sdstest deleted file mode 100644 index bdcc9e63..00000000 --- a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/function.sdstest +++ /dev/null @@ -1,11 +0,0 @@ -package tests.callGraph.expressionLambdaCall.argument.function - -@Pure fun f() - -function myFunction () { - val lambda = (param: () -> ()) -> - param(); - - # $TEST$ ["$expressionLambda", "f"] - »lambda(f)«; -} diff --git a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/segment.sdstest b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/segment.sdstest deleted file mode 100644 index 04b7a24d..00000000 --- a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/argument/segment.sdstest +++ /dev/null @@ -1,15 +0,0 @@ -package tests.callGraph.expressionLambdaCall.argument.`segment` - -@Pure fun f() - -function myFunction () { - val lambda = (param1: (param: () -> ()) -> ()) -> - param1(f); - - # $TEST$ ["$expressionLambda", "mySegment", "f"] - »lambda(mySegment)«; -} - -segment mySegment(param: () -> ()) { - param(); -} diff --git a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/basic.sdstest b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/basic.sdstest deleted file mode 100644 index c6cad9b4..00000000 --- a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/basic.sdstest +++ /dev/null @@ -1,8 +0,0 @@ -package tests.callGraph.expressionLambdaCall.basic - -function myFunction () { - val lambda = () -> 1; - - # $TEST$ ["$expressionLambda"] - »lambda()«; -} diff --git a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/body/function call in nested lambda.sdstest b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/body/function call in nested lambda.sdstest deleted file mode 100644 index 2858ac2d..00000000 --- a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/body/function call in nested lambda.sdstest +++ /dev/null @@ -1,10 +0,0 @@ -package tests.callGraph.expressionLambdaCall.body.functionCallInNestedLambda - -@Pure fun f() - -function myFunction () { - val lambda = () -> () -> f(); - - # $TEST$ ["$expressionLambda"] - »lambda()«; -} diff --git a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/body/function call.sdstest b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/body/function call.sdstest deleted file mode 100644 index b8c54561..00000000 --- a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/body/function call.sdstest +++ /dev/null @@ -1,10 +0,0 @@ -package tests.callGraph.expressionLambdaCall.body.functionCall - -@Pure fun f() - -function myFunction () { - val lambda = () -> f(); - - # $TEST$ ["$expressionLambda", "f"] - »lambda()«; -} diff --git a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/default value/call.sdstest b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/default value/call.sdstest deleted file mode 100644 index d9500563..00000000 --- a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/default value/call.sdstest +++ /dev/null @@ -1,12 +0,0 @@ -package tests.callGraph.expressionLambdaCall.defaultValue.call - -@Pure fun default() -> r: Any - -function myFunction () { - val lambda = ( - f: Any = default() - ) -> 1; - - # $TEST$ ["$expressionLambda", "default"] - »lambda()«; -} diff --git a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/default value/callable.sdstest b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/default value/callable.sdstest deleted file mode 100644 index 18d64ea1..00000000 --- a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/default value/callable.sdstest +++ /dev/null @@ -1,12 +0,0 @@ -package tests.callGraph.expressionLambdaCall.defaultValue.callable - -@Pure fun default() - -function myFunction () { - val lambda = ( - f: () -> () = default - ) -> f(); - - # $TEST$ ["$expressionLambda", "default"] - »lambda()«; -} diff --git a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/default value/previous parameter.sdstest b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/default value/previous parameter.sdstest deleted file mode 100644 index 445d9b5e..00000000 --- a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/default value/previous parameter.sdstest +++ /dev/null @@ -1,13 +0,0 @@ -package tests.callGraph.expressionLambdaCall.defaultValue.previousParameter - -@Pure fun default() -> result: Any - -function myFunction () { - val lambda = ( - f: () -> (result: Any) = default, - g: Any = f() - ) -> 1; - - # $TEST$ ["$expressionLambda", "default"] - »lambda()«; -} diff --git a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/null safe.sdstest b/packages/ttsl-lang/tests/resources/call graph/expression lambda call/null safe.sdstest deleted file mode 100644 index c9cc7018..00000000 --- a/packages/ttsl-lang/tests/resources/call graph/expression lambda call/null safe.sdstest +++ /dev/null @@ -1,8 +0,0 @@ -package tests.callGraph.expressionLambdaCall.nullSafe - -function myFunction () { - val lambda = () -> 1; - - # $TEST$ ["$expressionLambda"] - »lambda?()«; -} diff --git a/packages/ttsl-lang/tests/resources/call graph/segment call/argument/block lambda.sdstest b/packages/ttsl-lang/tests/resources/call graph/segment call/argument/block lambda.sdstest deleted file mode 100644 index ba73fecc..00000000 --- a/packages/ttsl-lang/tests/resources/call graph/segment call/argument/block lambda.sdstest +++ /dev/null @@ -1,14 +0,0 @@ -package tests.callGraph.segmentCall.argument.blockLambda - -@Pure fun f() - -segment mySegment(param1: (param: () -> ()) -> ()) { - param1(f); -} - -function myFunction () { - # $TEST$ ["mySegment", "$blockLambda", "f"] - »mySegment((param) { - param(); - })«; -} diff --git a/packages/ttsl-lang/tests/resources/call graph/segment call/argument/callable does not get called.sdstest b/packages/ttsl-lang/tests/resources/call graph/segment call/argument/callable does not get called.sdstest deleted file mode 100644 index 70448cd8..00000000 --- a/packages/ttsl-lang/tests/resources/call graph/segment call/argument/callable does not get called.sdstest +++ /dev/null @@ -1,10 +0,0 @@ -package tests.callGraph.segmentCall.argument.callableDoesNotGetCalled - -@Pure fun f() - -segment mySegment(param: () -> ()) {} - -function myFunction () { - # $TEST$ ["mySegment"] - »mySegment(f)«; -} diff --git a/packages/ttsl-lang/tests/resources/call graph/segment call/argument/expression lambda.sdstest b/packages/ttsl-lang/tests/resources/call graph/segment call/argument/expression lambda.sdstest deleted file mode 100644 index af745c67..00000000 --- a/packages/ttsl-lang/tests/resources/call graph/segment call/argument/expression lambda.sdstest +++ /dev/null @@ -1,12 +0,0 @@ -package tests.callGraph.segmentCall.argument.expressionLambda - -@Pure fun f() - -segment mySegment(param1: (param: () -> ()) -> ()) { - param1(f); -} - -function myFunction () { - # $TEST$ ["mySegment", "$expressionLambda", "f"] - »mySegment((param) -> param())«; -} diff --git a/packages/ttsl-lang/tests/resources/call graph/segment call/argument/function.sdstest b/packages/ttsl-lang/tests/resources/call graph/segment call/argument/function.sdstest deleted file mode 100644 index 9aa3bbce..00000000 --- a/packages/ttsl-lang/tests/resources/call graph/segment call/argument/function.sdstest +++ /dev/null @@ -1,12 +0,0 @@ -package tests.callGraph.segmentCall.argument.function - -@Pure fun f() - -segment mySegment(param: () -> ()) { - param(); -} - -function myFunction () { - # $TEST$ ["mySegment", "f"] - »mySegment(f)«; -} diff --git a/packages/ttsl-lang/tests/resources/call graph/segment call/argument/segment.sdstest b/packages/ttsl-lang/tests/resources/call graph/segment call/argument/segment.sdstest deleted file mode 100644 index 41279ac8..00000000 --- a/packages/ttsl-lang/tests/resources/call graph/segment call/argument/segment.sdstest +++ /dev/null @@ -1,16 +0,0 @@ -package tests.callGraph.segmentCall.argument.`segment` - -@Pure fun f() - -segment mySegment1(param1: (param: () -> ()) -> ()) { - param1(f); -} - -segment mySegment2(param: () -> ()) { - param(); -} - -function myFunction () { - # $TEST$ ["mySegment1", "mySegment2", "f"] - »mySegment1(mySegment2)«; -} diff --git a/packages/ttsl-lang/tests/resources/call graph/segment call/basic.sdstest b/packages/ttsl-lang/tests/resources/call graph/segment call/basic.sdstest deleted file mode 100644 index ff514f4f..00000000 --- a/packages/ttsl-lang/tests/resources/call graph/segment call/basic.sdstest +++ /dev/null @@ -1,8 +0,0 @@ -package tests.callGraph.segmentCall.basic - -segment mySegment() {} - -function myFunction () { - # $TEST$ ["mySegment"] - »mySegment()«; -} diff --git a/packages/ttsl-lang/tests/resources/call graph/segment call/body/function call in nested lambda.sdstest b/packages/ttsl-lang/tests/resources/call graph/segment call/body/function call in nested lambda.sdstest deleted file mode 100644 index 329aabcc..00000000 --- a/packages/ttsl-lang/tests/resources/call graph/segment call/body/function call in nested lambda.sdstest +++ /dev/null @@ -1,12 +0,0 @@ -package tests.callGraph.segmentCall.body.functionCallInNestedLambda - -@Pure fun f() - -segment mySegment() { - () -> f(); -} - -function myFunction () { - # $TEST$ ["mySegment"] - »mySegment()«; -} diff --git a/packages/ttsl-lang/tests/resources/call graph/segment call/body/function call.sdstest b/packages/ttsl-lang/tests/resources/call graph/segment call/body/function call.sdstest deleted file mode 100644 index 803f9a5c..00000000 --- a/packages/ttsl-lang/tests/resources/call graph/segment call/body/function call.sdstest +++ /dev/null @@ -1,12 +0,0 @@ -package tests.callGraph.segmentCall.body.functionCall - -@Pure fun f() - -segment mySegment() { - f(); -} - -function myFunction () { - # $TEST$ ["mySegment", "f"] - »mySegment()«; -} diff --git a/packages/ttsl-lang/tests/resources/call graph/segment call/default value/call.sdstest b/packages/ttsl-lang/tests/resources/call graph/segment call/default value/call.sdstest deleted file mode 100644 index 102a8d1b..00000000 --- a/packages/ttsl-lang/tests/resources/call graph/segment call/default value/call.sdstest +++ /dev/null @@ -1,12 +0,0 @@ -package tests.callGraph.segmentCall.defaultValue.call - -@Pure fun default() -> r: Any - -segment mySegment( - f: Any = default() -) {} - -function myFunction () { - # $TEST$ ["mySegment", "default"] - »mySegment()«; -} diff --git a/packages/ttsl-lang/tests/resources/call graph/segment call/default value/callable.sdstest b/packages/ttsl-lang/tests/resources/call graph/segment call/default value/callable.sdstest deleted file mode 100644 index 91a808be..00000000 --- a/packages/ttsl-lang/tests/resources/call graph/segment call/default value/callable.sdstest +++ /dev/null @@ -1,14 +0,0 @@ -package tests.callGraph.segmentCall.defaultValue.callable - -@Pure fun default() - -segment mySegment( - f: () -> () = default -) { - f(); -} - -function myFunction () { - # $TEST$ ["mySegment", "default"] - »mySegment()«; -} diff --git a/packages/ttsl-lang/tests/resources/call graph/segment call/default value/previous parameter.sdstest b/packages/ttsl-lang/tests/resources/call graph/segment call/default value/previous parameter.sdstest deleted file mode 100644 index bb7ff368..00000000 --- a/packages/ttsl-lang/tests/resources/call graph/segment call/default value/previous parameter.sdstest +++ /dev/null @@ -1,13 +0,0 @@ -package tests.callGraph.segmentCall.defaultValue.previousParameter - -@Pure fun default() -> result: Any - -segment mySegment( - f: () -> (result: Any) = default, - g: Any = f() -) {} - -function myFunction () { - # $TEST$ ["mySegment", "default"] - »mySegment()«; -} diff --git a/packages/ttsl-lang/tests/resources/call graph/segment call/null safe.sdstest b/packages/ttsl-lang/tests/resources/call graph/segment call/null safe.sdstest deleted file mode 100644 index dcd3134b..00000000 --- a/packages/ttsl-lang/tests/resources/call graph/segment call/null safe.sdstest +++ /dev/null @@ -1,8 +0,0 @@ -package tests.callGraph.segmentCall.nullSafe - -segment mySegment() {} - -function myFunction () { - # $TEST$ ["mySegment"] - »mySegment?()«; -} diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/block lambdas/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/block lambdas/main.sdstest deleted file mode 100644 index 053b3ffe..00000000 --- a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/block lambdas/main.sdstest +++ /dev/null @@ -1,6 +0,0 @@ -package tests.partialValidation.baseCases.expressionLambdas - -function test () { - # $TEST$ serialization $expressionLambdaClosure - »() -> 1«; -} diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/boolean literals/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/boolean literals/main.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/partial evaluation/base cases/boolean literals/main.sdstest rename to packages/ttsl-lang/tests/resources/partial evaluation/base cases/boolean literals/main.ttsl diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/classes/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/classes/main.sdstest deleted file mode 100644 index b7a98b21..00000000 --- a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/classes/main.sdstest +++ /dev/null @@ -1,4 +0,0 @@ -package tests.partialValidation.baseCases.classes - -# $TEST$ serialization C -»class C« diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/enum variants/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/enum variants/main.sdstest deleted file mode 100644 index c5844cd6..00000000 --- a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/enum variants/main.sdstest +++ /dev/null @@ -1,6 +0,0 @@ -package tests.partialValidation.baseCases.enumVariants - -enum MyEnum { - # $TEST$ serialization MyVariant - »MyVariant« -} diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/expression lambdas/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/expression lambdas/main.sdstest deleted file mode 100644 index d8192c7b..00000000 --- a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/expression lambdas/main.sdstest +++ /dev/null @@ -1,6 +0,0 @@ -package tests.partialValidation.baseCases.blockLambdas - -function test () { - # $TEST$ serialization $blockLambdaClosure - »() {}«; -} diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/float literals/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/float literals/main.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/partial evaluation/base cases/float literals/main.sdstest rename to packages/ttsl-lang/tests/resources/partial evaluation/base cases/float literals/main.ttsl diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/functions/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/functions/main.ttsl similarity index 79% rename from packages/ttsl-lang/tests/resources/partial evaluation/base cases/functions/main.sdstest rename to packages/ttsl-lang/tests/resources/partial evaluation/base cases/functions/main.ttsl index f5a02d39..f41ed588 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/functions/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/functions/main.ttsl @@ -1,4 +1,4 @@ package tests.partialValidation.baseCases.functions # $TEST$ serialization f -@Pure »fun f()« +»function f() {}« diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/int literals/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/int literals/main.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/partial evaluation/base cases/int literals/main.sdstest rename to packages/ttsl-lang/tests/resources/partial evaluation/base cases/int literals/main.ttsl diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/null literals/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/null literals/main.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/partial evaluation/base cases/null literals/main.sdstest rename to packages/ttsl-lang/tests/resources/partial evaluation/base cases/null literals/main.ttsl diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/segments/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/segments/main.sdstest deleted file mode 100644 index 044fabca..00000000 --- a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/segments/main.sdstest +++ /dev/null @@ -1,4 +0,0 @@ -package tests.partialValidation.baseCases.segments - -# $TEST$ serialization mySegment -»segment mySegment() {}« diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/base cases/string literals (without interpolation)/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/base cases/string literals (without interpolation)/main.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/partial evaluation/base cases/string literals (without interpolation)/main.sdstest rename to packages/ttsl-lang/tests/resources/partial evaluation/base cases/string literals (without interpolation)/main.ttsl diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/invalid nodes/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/invalid nodes/main.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/partial evaluation/invalid nodes/main.sdstest rename to packages/ttsl-lang/tests/resources/partial evaluation/invalid nodes/main.ttsl diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/arguments/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/arguments/main.ttsl similarity index 89% rename from packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/arguments/main.sdstest rename to packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/arguments/main.ttsl index b3972cee..0dbc596c 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/arguments/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/arguments/main.ttsl @@ -1,6 +1,6 @@ package tests.partialValidation.recursiveCases.arguments -@Pure fun f(p: Any?) +function f(p: Any?){} function test () { # $TEST$ serialization 1 diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/block lambda results/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/block lambda results/main.sdstest deleted file mode 100644 index e9065fe0..00000000 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/block lambda results/main.sdstest +++ /dev/null @@ -1,17 +0,0 @@ -package tests.partialEvaluation.recursiveCases.assignees.blockLambda - -segment mySegment() -> r: Int { - yield r = 2; -} - -function test () { - () { - # $TEST$ serialization 1 - # $TEST$ serialization ? - »yield a«, »yield b« = 1; - - # $TEST$ serialization 2 - # $TEST$ serialization ? - »yield c«, »yield d« = mySegment(); - }; -} diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/placeholders/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/placeholders/main.ttsl similarity index 51% rename from packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/placeholders/main.sdstest rename to packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/placeholders/main.ttsl index fbe8a595..8ee0ade1 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/placeholders/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/placeholders/main.ttsl @@ -1,15 +1,13 @@ package tests.partialValidation.recursiveCases.assignees.placeholders -segment mySegment() -> r: Int { +function myFunction(): Int { yield r = 2; } function test () { # $TEST$ serialization 1 - # $TEST$ serialization ? - »val a«, »val b« = 1; + »val a« = 1; # $TEST$ serialization 2 - # $TEST$ serialization ? - »val c«, »val d« = mySegment(); + »val c« = myFunction(); } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/wildcards/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/wildcards/main.sdstest deleted file mode 100644 index 0a7224d1..00000000 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/wildcards/main.sdstest +++ /dev/null @@ -1,15 +0,0 @@ -package tests.partialValidation.recursiveCases.assignees.wildcards - -segment mySegment() -> r: Int { - yield r = 2; -} - -function test () { - # $TEST$ serialization 1 - # $TEST$ serialization ? - »_«, »_« = 1; - - # $TEST$ serialization 2 - # $TEST$ serialization ? - »_«, »_« = mySegment(); -} diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/yields/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/yields/main.sdstest deleted file mode 100644 index 98316b0e..00000000 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/assignees/yields/main.sdstest +++ /dev/null @@ -1,15 +0,0 @@ -package tests.partialEvaluation.recursiveCases.assignees.yields - -segment mySegment() -> r: Int { - yield r = 2; -} - -segment mySegment2() -> (a: Int, b: Int, c: Int, d: Int) { - # $TEST$ serialization 1 - # $TEST$ serialization ? - »yield a«, »yield b« = 1; - - # $TEST$ serialization 2 - # $TEST$ serialization ? - »yield c«, »yield d« = mySegment(); -} diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of block lambdas/closure.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of block lambdas/closure.sdstest deleted file mode 100644 index fee587b2..00000000 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of block lambdas/closure.sdstest +++ /dev/null @@ -1,12 +0,0 @@ -package tests.partialValidation.recursiveCases.calls.ofBlockLambdas.closures - -segment mySegment(p: Int) -> (closure: () -> (r: Int)) { - yield closure = () { - yield r = p; - }; -} - -function test () { - # $TEST$ serialization 1 - »mySegment(1)()«; -} diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of block lambdas/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of block lambdas/main.sdstest deleted file mode 100644 index 120b3b87..00000000 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of block lambdas/main.sdstest +++ /dev/null @@ -1,11 +0,0 @@ -package tests.partialValidation.recursiveCases.calls.ofBlockLambdas - -function test () { - val blockLambda = () { - yield r = 1; - yield s = 2; - }; - - # $TEST$ serialization (r = 1, s = 2) - »blockLambda()«; -} diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of block lambdas/previous parameter value used as default value.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of block lambdas/previous parameter value used as default value.sdstest deleted file mode 100644 index 8703200d..00000000 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of block lambdas/previous parameter value used as default value.sdstest +++ /dev/null @@ -1,10 +0,0 @@ -package tests.partialValidation.recursiveCases.calls.ofBlockLambdas.previousParameterValueUsedAsDefaultValue - -function test () { - val blockLambda = (p1: Int, p2: Int = p1) { - yield r = p2; - }; - - # $TEST$ serialization 1 - »blockLambda(1)«; -} diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of classes/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of classes/main.sdstest deleted file mode 100644 index 618cc316..00000000 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of classes/main.sdstest +++ /dev/null @@ -1,8 +0,0 @@ -package tests.partialValidation.recursiveCases.calls.ofClasses - -class C() - -function test () { - # $TEST$ serialization ? - »C()«; -} diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of enum variants/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of enum variants/main.sdstest deleted file mode 100644 index 8d0b6bb9..00000000 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of enum variants/main.sdstest +++ /dev/null @@ -1,35 +0,0 @@ -package tests.partialValidation.recursiveCases.calls.ofEnumVariants - -enum MyEnum { - MyEnumVariantWithoutParameters - MyEnumVariantWithParameters(p: Int, q: Int = 3) -} - -function test () { - # $TEST$ serialization MyEnumVariantWithoutParameters() - »MyEnum.MyEnumVariantWithoutParameters()«; - - # $TEST$ serialization MyEnumVariantWithParameters(p = ?, q = 3) - »MyEnum.MyEnumVariantWithParameters()«; - - # $TEST$ serialization MyEnumVariantWithParameters(p = 1, q = 3) - »MyEnum.MyEnumVariantWithParameters(1)«; - - # $TEST$ serialization MyEnumVariantWithParameters(p = 1, q = 2) - »MyEnum.MyEnumVariantWithParameters(1, 2)«; - - # $TEST$ serialization MyEnumVariantWithParameters(p = 1, q = 2) - »MyEnum.MyEnumVariantWithParameters(q = 2, p = 1)«; - - # $TEST$ serialization MyEnumVariantWithParameters(p = 1, q = ?) - »MyEnum.MyEnumVariantWithParameters(1, f())«; - - # $TEST$ serialization MyEnumVariantWithParameters(p = 1, q = ?) - »MyEnum.MyEnumVariantWithParameters(1, f(), 3)«; - - # $TEST$ serialization MyEnumVariantWithParameters(p = 1, q = ?) - »MyEnum.MyEnumVariantWithParameters(1, f(), r = 3)«; - - # $TEST$ serialization ? - »MyEnum.MyEnumVariantWithParameters(q = 2, p = 1)()«; -} diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of expression lambdas/closure.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of expression lambdas/closure.sdstest deleted file mode 100644 index 0eb2f466..00000000 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of expression lambdas/closure.sdstest +++ /dev/null @@ -1,10 +0,0 @@ -package tests.partialValidation.recursiveCases.calls.ofExpressionLambdas.closures - -segment mySegment(p: Int) -> (closure: () -> (r: Int)) { - yield closure = () -> p; -} - -function test () { - # $TEST$ serialization 1 - »mySegment(1)()«; -} diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of expression lambdas/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of expression lambdas/main.sdstest deleted file mode 100644 index 1f4c605c..00000000 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of expression lambdas/main.sdstest +++ /dev/null @@ -1,8 +0,0 @@ -package tests.partialValidation.recursiveCases.calls.ofExpressionLambdas - -function test () { - val expressionLambda = () -> 1; - - # $TEST$ serialization 1 - »expressionLambda()«; -} diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of expression lambdas/previous parameter value used as default value.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of expression lambdas/previous parameter value used as default value.sdstest deleted file mode 100644 index 564faaa9..00000000 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of expression lambdas/previous parameter value used as default value.sdstest +++ /dev/null @@ -1,8 +0,0 @@ -package tests.partialValidation.recursiveCases.calls.ofExpressionLambdas.previousParameterValueUsedAsDefaultValue - -function test () { - val expressionLambda = (p1: Int, p2: Int = p1) -> p2; - - # $TEST$ serialization 1 - »expressionLambda(1)«; -} diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of functions/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of functions/main.ttsl similarity index 89% rename from packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of functions/main.sdstest rename to packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of functions/main.ttsl index e095cbcc..09624540 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of functions/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of functions/main.ttsl @@ -1,6 +1,6 @@ package tests.partialValidation.recursiveCases.calls.ofFunctions -@Pure fun f() +function f(){} function test () { # $TEST$ serialization ? diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of segments/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of segments/main.sdstest deleted file mode 100644 index c08f70f6..00000000 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of segments/main.sdstest +++ /dev/null @@ -1,10 +0,0 @@ -package tests.partialValidation.recursiveCases.calls.ofSegments - -segment mySegment() -> (r: Int, s: Int) { - yield r = 1; -} - -function test () { - # $TEST$ serialization (r = 1, s = ?) - »mySegment()«; -} diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of segments/previous parameter value used as default value.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of segments/previous parameter value used as default value.sdstest deleted file mode 100644 index 39d42c3f..00000000 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of segments/previous parameter value used as default value.sdstest +++ /dev/null @@ -1,10 +0,0 @@ -package tests.partialValidation.recursiveCases.calls.ofSegment.previousParameterValueUsedAsDefaultValue - -segment mySegment(p1: Int, p2: Int = p1) -> r: Int { - yield r = p2; -} - -function test () { - # $TEST$ serialization 1 - »mySegment(1)«; -} diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of unknown parameter/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of unknown parameter/main.sdstest deleted file mode 100644 index 2a20f556..00000000 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/of unknown parameter/main.sdstest +++ /dev/null @@ -1,6 +0,0 @@ -package tests.partialValidation.recursiveCases.calls.ofUnknownParameter - -segment mySegment(p: () -> ()) { - # $TEST$ serialization ? - »p()«; -} diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/on null/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/on null/main.ttsl similarity index 86% rename from packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/on null/main.sdstest rename to packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/on null/main.ttsl index 97e7d234..cb265402 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/on null/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/on null/main.ttsl @@ -1,6 +1,6 @@ package tests.partialValidation.recursiveCases.calls.onNull -segment mySegment() { +function myFunction() { # $TEST$ serialization ? »null()«; diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/recursion/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/recursion/main.ttsl similarity index 59% rename from packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/recursion/main.sdstest rename to packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/recursion/main.ttsl index 5a362728..48246377 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/recursion/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/recursion/main.ttsl @@ -1,6 +1,6 @@ package tests.partialValidation.recursiveCases.calls.recursion -segment mySegment() -> r: Int { +function myFunction(): Int { # $TEST$ serialization ? - yield r = »mySegment()«; + return let r = »myFunction()«; } diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/unresolved/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/unresolved/main.sdstest deleted file mode 100644 index 9c04e07b..00000000 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/calls/unresolved/main.sdstest +++ /dev/null @@ -1,13 +0,0 @@ -package tests.partialValidation.recursiveCases.calls.unresolved - -enum MyEnum { - MyEnumVariant -} - -function test () { - # $TEST$ serialization ? - »unresolved.MyEnumVariant()«; - - # $TEST$ serialization ? - »MyEnum.unresolved()«; -} diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on lists/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on lists/main.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on lists/main.sdstest rename to packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on lists/main.ttsl diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on maps/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on maps/main.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on maps/main.sdstest rename to packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on maps/main.ttsl diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on null/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on null/main.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on null/main.sdstest rename to packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on null/main.ttsl diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on other/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on other/main.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on other/main.sdstest rename to packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/indexed access/on other/main.ttsl diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/and/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/and/main.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/and/main.sdstest rename to packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/and/main.ttsl diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/and/short circuiting.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/and/short circuiting.sdstest deleted file mode 100644 index 20c30217..00000000 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/and/short circuiting.sdstest +++ /dev/null @@ -1,30 +0,0 @@ -package tests.partialValidation.recursiveCases.infixOperations.`and` - -@Pure -fun pureFunction() -> result: Boolean - -@Impure([ImpurityReason.FileReadFromConstantPath("test.txt")]) -fun functionWithoutSideEffects() -> result: Boolean - -@Impure([ImpurityReason.FileWriteToConstantPath("test.txt")]) -fun functionWithSideEffects() -> result: Boolean - -function test () { - # $TEST$ serialization false - »false and pureFunction()«; - - # $TEST$ serialization false - »false and functionWithoutSideEffects()«; - - # $TEST$ serialization false - »false and functionWithSideEffects()«; - - # $TEST$ serialization ? - »true and pureFunction()«; - - # $TEST$ serialization ? - »true and functionWithoutSideEffects()«; - - # $TEST$ serialization ? - »true and functionWithSideEffects()«; -} diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/and/short circuiting.ttsl b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/and/short circuiting.ttsl new file mode 100644 index 00000000..1f4581e0 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/and/short circuiting.ttsl @@ -0,0 +1,11 @@ +package tests.partialValidation.recursiveCases.infixOperations.`and` + +function pureFunction(): Boolean {} + +function test () { + # $TEST$ serialization false + »false and pureFunction()«; + + # $TEST$ serialization ? + »true and pureFunction()«; +} diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/divided by/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/divided by/main.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/divided by/main.sdstest rename to packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/divided by/main.ttsl diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/elvis/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/elvis/main.ttsl similarity index 68% rename from packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/elvis/main.sdstest rename to packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/elvis/main.ttsl index 9d44a444..e841f421 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/elvis/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/elvis/main.ttsl @@ -7,12 +7,6 @@ function test () { # $TEST$ serialization false »null ?: false«; - # $TEST$ serialization $expressionLambdaClosure - »(() -> 1) ?: false«; - - # $TEST$ serialization ? - »(() -> 1) ?: unresolved«; - # $TEST$ serialization ? »unresolved ?: null«; diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/elvis/short circuiting.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/elvis/short circuiting.sdstest deleted file mode 100644 index 902a6691..00000000 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/elvis/short circuiting.sdstest +++ /dev/null @@ -1,30 +0,0 @@ -package tests.partialValidation.recursiveCases.infixOperations.elvis - -@Pure -fun pureFunction() -> result: Boolean - -@Impure([ImpurityReason.FileReadFromConstantPath("test.txt")]) -fun functionWithoutSideEffects() -> result: Boolean - -@Impure([ImpurityReason.FileWriteToConstantPath("test.txt")]) -fun functionWithSideEffects() -> result: Boolean - -function test () { - # $TEST$ serialization 1 - »1 ?: pureFunction()«; - - # $TEST$ serialization 1 - »1 ?: functionWithoutSideEffects()«; - - # $TEST$ serialization 1 - »1 ?: functionWithSideEffects()«; - - # $TEST$ serialization ? - »null ?: pureFunction()«; - - # $TEST$ serialization ? - »null ?: functionWithoutSideEffects()«; - - # $TEST$ serialization ? - »null ?: functionWithSideEffects()«; -} diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/elvis/short circuiting.ttsl b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/elvis/short circuiting.ttsl new file mode 100644 index 00000000..b7c8ca4d --- /dev/null +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/elvis/short circuiting.ttsl @@ -0,0 +1,11 @@ +package tests.partialValidation.recursiveCases.infixOperations.elvis + +function pureFunction(): Boolean {} + +function test () { + # $TEST$ serialization 1 + »1 ?: pureFunction()«; + + # $TEST$ serialization ? + »null ?: pureFunction()«; +} diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/equals/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/equals/main.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/equals/main.sdstest rename to packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/equals/main.ttsl diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/greater than or equals/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/greater than or equals/main.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/greater than or equals/main.sdstest rename to packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/greater than or equals/main.ttsl diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/greater than/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/greater than/main.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/greater than/main.sdstest rename to packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/greater than/main.ttsl diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/identical to/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/identical to/main.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/identical to/main.sdstest rename to packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/identical to/main.ttsl diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/less than or equals/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/less than or equals/main.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/less than or equals/main.sdstest rename to packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/less than or equals/main.ttsl diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/less than/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/less than/main.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/less than/main.sdstest rename to packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/less than/main.ttsl diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/minus/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/minus/main.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/minus/main.sdstest rename to packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/minus/main.ttsl diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/not equals/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/not equals/main.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/not equals/main.sdstest rename to packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/not equals/main.ttsl diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/not identical to/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/not identical to/main.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/not identical to/main.sdstest rename to packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/not identical to/main.ttsl diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/or/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/or/main.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/or/main.sdstest rename to packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/or/main.ttsl diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/or/short circuiting.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/or/short circuiting.sdstest deleted file mode 100644 index ed6ec041..00000000 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/or/short circuiting.sdstest +++ /dev/null @@ -1,30 +0,0 @@ -package tests.partialValidation.recursiveCases.infixOperations.`or` - -@Pure -fun pureFunction() -> result: Boolean - -@Impure([ImpurityReason.FileReadFromConstantPath("test.txt")]) -fun functionWithoutSideEffects() -> result: Boolean - -@Impure([ImpurityReason.FileWriteToConstantPath("test.txt")]) -fun functionWithSideEffects() -> result: Boolean - -function test () { - # $TEST$ serialization true - »true or pureFunction()«; - - # $TEST$ serialization true - »true or functionWithoutSideEffects()«; - - # $TEST$ serialization true - »true or functionWithSideEffects()«; - - # $TEST$ serialization ? - »false or pureFunction()«; - - # $TEST$ serialization ? - »false or functionWithoutSideEffects()«; - - # $TEST$ serialization ? - »false or functionWithSideEffects()«; -} diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/or/short circuiting.ttsl b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/or/short circuiting.ttsl new file mode 100644 index 00000000..a3a3b53c --- /dev/null +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/or/short circuiting.ttsl @@ -0,0 +1,11 @@ +package tests.partialValidation.recursiveCases.infixOperations.`or` + +function pureFunction(): Boolean {} + +function test () { + # $TEST$ serialization true + »true or pureFunction()«; + + # $TEST$ serialization ? + »false or pureFunction()«; +} diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/plus/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/plus/main.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/plus/main.sdstest rename to packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/plus/main.ttsl diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/times/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/times/main.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/times/main.sdstest rename to packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/infix operations/times/main.ttsl diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/lists/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/lists/main.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/lists/main.sdstest rename to packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/lists/main.ttsl diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/maps/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/maps/main.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/maps/main.sdstest rename to packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/maps/main.ttsl diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/parameters/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/parameters/main.sdstest deleted file mode 100644 index 860d35f7..00000000 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/parameters/main.sdstest +++ /dev/null @@ -1,22 +0,0 @@ -package tests.partialEvaluation.recursiveCases.assignees.parameters - -segment mySegment(p: Int) -> r: Int { - yield r = p; -} - -function myFunction () { - val blockLambda = (p: Int) { - yield r = p; - }; - - val expressionLambda = (p: Int) -> p; - - # $TEST$ serialization 1 - »mySegment(1)«; - - # $TEST$ serialization 1 - »blockLambda(1)«; - - # $TEST$ serialization 1 - »expressionLambda(1)«; -} diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/parameters/main.ttsl b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/parameters/main.ttsl new file mode 100644 index 00000000..4f3edf08 --- /dev/null +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/parameters/main.ttsl @@ -0,0 +1,10 @@ +package tests.partialEvaluation.recursiveCases.assignees.parameters + +function myFunction(p: Int): Int { + return p; +} + +function myTestFunction () { + # $TEST$ serialization 1 + myFunction(1)«; +} diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/parenthesized expressions/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/parenthesized expressions/main.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/parenthesized expressions/main.sdstest rename to packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/parenthesized expressions/main.ttsl diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/prefix operations/minus/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/prefix operations/minus/main.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/prefix operations/minus/main.sdstest rename to packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/prefix operations/minus/main.ttsl diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/prefix operations/not/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/prefix operations/not/main.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/prefix operations/not/main.sdstest rename to packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/prefix operations/not/main.ttsl diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/references/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/references/main.ttsl similarity index 92% rename from packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/references/main.sdstest rename to packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/references/main.ttsl index 2f20d053..a844275f 100644 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/references/main.sdstest +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/references/main.ttsl @@ -1,7 +1,7 @@ package tests.partialEvaluation.recursiveCases.assignees.references function myFunction () { - val a = 1; + var a = 1; # $TEST$ serialization 1 »a«; diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/results/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/results/main.sdstest deleted file mode 100644 index 7586afb0..00000000 --- a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/results/main.sdstest +++ /dev/null @@ -1,12 +0,0 @@ -package tests.partialEvaluation.recursiveCases.assignees.results - -# $TEST$ serialization ? -# $TEST$ serialization 1 -# $TEST$ serialization 2 -segment mySegment() -> (»a: Int«, »b: Int«, »c: Int«) { - yield b = 1; - - # Use the first yield if the same result is set multiple times - yield c = 2; - yield c = 3; -} diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/results/main.ttsl b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/results/main.ttsl new file mode 100644 index 00000000..00291fcb --- /dev/null +++ b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/results/main.ttsl @@ -0,0 +1,7 @@ +package tests.partialEvaluation.recursiveCases.assignees.results + +# $TEST$ serialization 1 +function myFunction(): »Int« { + return 1; + return 2; +} diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/template strings/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/template strings/main.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/template strings/main.sdstest rename to packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/template strings/main.ttsl diff --git a/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/type casts/main.sdstest b/packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/type casts/main.ttsl similarity index 100% rename from packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/type casts/main.sdstest rename to packages/ttsl-lang/tests/resources/partial evaluation/recursive cases/type casts/main.ttsl diff --git a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to functions/main.ttsl b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to functions/main.ttsl index 052c45e4..af736338 100644 --- a/packages/ttsl-lang/tests/resources/scoping/references/in same file/to functions/main.ttsl +++ b/packages/ttsl-lang/tests/resources/scoping/references/in same file/to functions/main.ttsl @@ -1,15 +1,12 @@ package tests.scoping.references.inSameFile.toFunction -# $TEST$ target before -function »before«() {} +constant myConstant : Float = 0.0; -function myFunction() { - # $TEST$ references before - »before«(); - - # $TEST$ references after - »after«(); +id data myDataID: Int +constant myKonstante: Int { + from 1999-01-01 = myConstant + 1; + from 2000-01-01 = myConstant + 2; } - -# $TEST$ target after -function »after«() {} \ No newline at end of file +function myFunction() { + var y: Int = m +} \ No newline at end of file From 83c6916417133ac2281d71229f805a5e9453c62e Mon Sep 17 00:00:00 2001 From: alex-senger Date: Thu, 29 Aug 2024 19:40:56 +0200 Subject: [PATCH 162/183] arbeitslosengeld syntax fix --- .../builtins/parameters/arbeitslosengeld.ttsl | 24 +++++++++---------- 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/src/resources/builtins/parameters/arbeitslosengeld.ttsl b/src/resources/builtins/parameters/arbeitslosengeld.ttsl index f30528a4..8a34921c 100644 --- a/src/resources/builtins/parameters/arbeitslosengeld.ttsl +++ b/src/resources/builtins/parameters/arbeitslosengeld.ttsl @@ -99,20 +99,20 @@ public constant stundengrenze: Int { */ public constant anspruchsdauer: Dict { from 1997-03-24 = { - nach_alter: { - 0: 12 - 50: 15 - 55: 18 + "nach_alter": { + 0: 12, + 50: 15, + 55: 18, 58: 24 }, - nach_versicherungspflichtige_monate: { - 12: 6 - 18: 8 - 20: 10 - 24: 12 - 30: 15 - 36: 18 + "nach_versicherungspflichtige_monate": { + 12: 6, + 18: 8, + 20: 10, + 24: 12, + 30: 15, + 36: 18, 48: 24 } - } + }; } From 38fb597e11d5ab2e6e3458ed57c49bcec49e8785 Mon Sep 17 00:00:00 2001 From: alex-senger Date: Thu, 29 Aug 2024 19:41:07 +0200 Subject: [PATCH 163/183] einkommenssteuer syntax fix --- .../builtins/parameters/einkommenssteuer.ttsl | 268 +++++++++--------- 1 file changed, 134 insertions(+), 134 deletions(-) diff --git a/src/resources/builtins/parameters/einkommenssteuer.ttsl b/src/resources/builtins/parameters/einkommenssteuer.ttsl index 8100a6ce..fbe5cbb6 100644 --- a/src/resources/builtins/parameters/einkommenssteuer.ttsl +++ b/src/resources/builtins/parameters/einkommenssteuer.ttsl @@ -15,307 +15,307 @@ public constant einkommenssteuerTarif: Dict> { from 2002-01-01 = { 0: { - lower_threshold: -inf, - upper_threshold: 7235, - rate_linear: 0, - rate_quadratic: 0, - intercept_at_lower_threshold: 0 + "lower_threshold": -1e10, + "upper_threshold": 7235, + "rate_linear": 0, + "rate_quadratic": 0, + "intercept_at_lower_threshold": 0 }, 1: { - upper_threshold: 9251, - rate_linear: 0.199 + "upper_threshold": 9251, + "rate_linear": 0.199 }, 2: { - upper_threshold: 55007, - rate_linear: 0.23 + "upper_threshold": 55007, + "rate_linear": 0.23 }, 3: { - upper_threshold: inf, - rate_linear: 0.485, - rate_quadratic: 0 + "upper_threshold": 1e10, + "rate_linear": 0.485, + "rate_quadratic": 0 } - } + }; from 2004-01-01 = { 0: { - lower_threshold: -inf, - upper_threshold: 7664, - rate_linear: 0, - intercept_at_lower_threshold: 0 + "lower_threshold": -1e10, + "upper_threshold": 7664, + "rate_linear": 0, + "intercept_at_lower_threshold": 0 }, 1: { - upper_threshold: 12739, - rate_linear: 0.16 + "upper_threshold": 12739, + "rate_linear": 0.16 }, 2: { - upper_threshold: 52151, - rate_linear: 0.2405 + "upper_threshold": 52151, + "rate_linear": 0.2405 }, 3: { - upper_threshold: inf, - rate_linear: 0.45, - rate_quadratic: 0 + "upper_threshold": 1e10, + "rate_linear": 0.45, + "rate_quadratic": 0 } - } + }; from 2005-01-01 = { 0: { - lower_threshold: -inf, - upper_threshold: 7664, - rate_linear: 0, - rate_quadratic: 0, - intercept_at_lower_threshold: 0 + "lower_threshold": -1e10, + "upper_threshold": 7664, + "rate_linear": 0, + "rate_quadratic": 0, + "intercept_at_lower_threshold": 0 }, 1: { - upper_threshold: 12739, - rate_linear: 0.15 + "upper_threshold": 12739, + "rate_linear": 0.15 }, 2: { - upper_threshold: 52151, - rate_linear: 0.2397 + "upper_threshold": 52151, + "rate_linear": 0.2397 }, 3: { - upper_threshold: inf, - rate_linear: 0.42, - rate_quadratic: 0 + "upper_threshold": 1e10, + "rate_linear": 0.42, + "rate_quadratic": 0 } - } + }; from 2007-01-01 = { 0: { - lower_threshold: -inf, - upper_threshold: 7664, - rate_linear: 0, - rate_quadratic: 0, - intercept_at_lower_threshold: 0 + "lower_threshold": -1e10, + "upper_threshold": 7664, + "rate_linear": 0, + "rate_quadratic": 0, + "intercept_at_lower_threshold": 0 }, 1: { - upper_threshold: 12739, - rate_linear: 0.15 + "upper_threshold": 12739, + "rate_linear": 0.15 }, 2: { - upper_threshold: 52151, - rate_linear: 0.2397 + "upper_threshold": 52151, + "rate_linear": 0.2397 }, 3: { - upper_threshold: 250000, - rate_linear: 0.42, - rate_quadratic: 0 + "upper_threshold": 250000, + "rate_linear": 0.42, + "rate_quadratic": 0 }, 4: { - upper_threshold: inf, - rate_linear: 0.45, - rate_quadratic: 0 + "upper_threshold": 1e10, + "rate_linear": 0.45, + "rate_quadratic": 0 } - } + }; from 2009-01-01 = { # deviation_from: previous, 0: { - upper_threshold: 7834 + "upper_threshold": 7834 }, 1: { - upper_threshold: 13139, - rate_linear: 0.14 + "upper_threshold": 13139, + "rate_linear": 0.14 }, 2: { - upper_threshold: 52551 + "upper_threshold": 52551 }, 3: { - upper_threshold: 250400 + "upper_threshold": 250400 } - } + }; from 2010-01-01 = { # deviation_from: previous, 0: { - upper_threshold: 8004 + "upper_threshold": 8004 }, 1: { - upper_threshold: 13469 + "upper_threshold": 13469 }, 2: { - upper_threshold: 52881 + "upper_threshold": 52881 }, 3: { - upper_threshold: 250730 + "upper_threshold": 250730 } - } + }; from 2013-01-01 = { # deviation_from: previous, 0: { - upper_threshold: 8130 + "upper_threshold": 8130 } - } + }; from 2014-01-01 = { # Reference: G. v. 20.2.2013, BGBl I S.283 # deviation_from: previous, 0: { - upper_threshold: 8354 + "upper_threshold": 8354 } - } + }; from 2015-07-01 = { # Reference: G. v. 15.07.2015, BGBl. Nr. 30 2015 # deviation_from: previous, 0: { - upper_threshold: 8472 + "upper_threshold": 8472 } - } + }; from 2016-01-01 = { # Reference: G. v. 15.07.2015, BGBl. Nr. 30 2015 # deviation_from: previous, 0: { - upper_threshold: 8652 + "upper_threshold": 8652 }, 1: { - upper_threshold: 13669 + "upper_threshold": 13669 }, 2: { - upper_threshold: 53665 + "upper_threshold": 53665 }, 3: { - upper_threshold: 254446 + "upper_threshold": 254446 } - } + }; from 2017-01-01 = { # Reference: Artikel 8 G. v. 20.12.2016, BGBl I S. 3000 # deviation_from: previous, 0: { - upper_threshold: 8820 + "upper_threshold": 8820 }, 1: { - upper_threshold: 13769 + "upper_threshold": 13769 }, 2: { - upper_threshold: 54057 + "upper_threshold": 54057 }, 3: { - upper_threshold: 256303 + "upper_threshold": 256303 } - } + }; from 2018-01-01 = { # Reference: Artikel 9 G. v 23.12.2016, BGBL I, S. 3000 # deviation_from: previous, 0: { - upper_threshold: 9000 + "upper_threshold": 9000 }, 1: { - upper_threshold: 13996 + "upper_threshold": 13996 }, 2: { - upper_threshold: 54949 + "upper_threshold": 54949 }, 3: { - upper_threshold: 260532 + "upper_threshold": 260532 } - } + }; from 2019-01-01 = { # deviation_from: previous, 0: { - upper_threshold: 9169 + "upper_threshold": 9169 }, 1: { - upper_threshold: 14255 + "upper_threshold": 14255 }, 2: { - upper_threshold: 55961 + "upper_threshold": 55961 }, 3: { - upper_threshold: 265327 + "upper_threshold": 265327 } - } + }; from 2020-01-01 = { # Reference: Art. 3 G. v. 29.11.2018 BGBl. I S. 2210 # deviation_from: previous, 0: { - upper_threshold: 9408 + "upper_threshold": 9408 }, 1: { - upper_threshold: 14532 + "upper_threshold": 14532 }, 2: { - upper_threshold: 57051 + "upper_threshold": 57051 }, 3: { - upper_threshold: 270501 + "upper_threshold": 270501 } - } + }; from 2021-01-01 = { # Reference: Art. 1 G. v. 01.12.2020 BGBl. I S. 2616 # deviation_from: previous, 0: { - upper_threshold: 9744 + "upper_threshold": 9744 }, 1: { - upper_threshold: 14753 + "upper_threshold": 14753 }, 2: { - upper_threshold: 57918 + "upper_threshold": 57918 }, 3: { - upper_threshold: 274613 + "upper_threshold": 274613 } - } + }; from 2022-01-01 = { # Reference: Art. 1 G. v. 23.05.2022 BGBl. I S. 749 # deviation_from: previous, 0: { - upper_threshold: 10347 + "upper_threshold": 10347 }, 1: { - upper_threshold: 14926 + "upper_threshold": 14926 }, 2: { - upper_threshold: 58596 + "upper_threshold": 58596 }, 3: { - upper_threshold: 277826 + "upper_threshold": 277826 } - } + }; from 2023-01-01 = { # Reference: Art. 2 G. v. 08.12.2022 BGBl. I S. 2230., # deviation_from: previous 0: { - upper_threshold: 10909 + "upper_threshold": 10909 }, 1: { - upper_threshold: 16000 + "upper_threshold": 16000 }, 2: { - upper_threshold: 62810 + "upper_threshold": 62810 }, 3: { - upper_threshold: 277826 + "upper_threshold": 277826 } - } + }; from 2024-01-01 = { # Reference: Art. 3 G. v. 08.12.2022 BGBl. I S. 2230. - deviation_from: previous, + # deviation_from: previous, 0: { - upper_threshold: 11605 + "upper_threshold": 11605 }, 1: { - upper_threshold: 17006 + "upper_threshold": 17006 }, 2: { - upper_threshold: 66761 + "upper_threshold": 66761 }, 3: { - upper_threshold: 277826 + "upper_threshold": 277826 } - } + }; } /** @@ -328,30 +328,30 @@ public constant einkommenssteuerTarif: Dict> { public constant renteErtragsanteil: Dict> { from 2002-01-01 = { 0: { - lower_threshold: -inf, - upper_threshold: 2005, - rate_linear: 0, - intercept_at_lower_threshold: 0.27 + "lower_threshold": -1e10, + "upper_threshold": 2005, + "rate_linear": 0, + "intercept_at_lower_threshold": 0.27 }, 1: { - lower_threshold: 2005, - upper_threshold: 2021, - rate_linear: 0.02, - intercept_at_lower_threshold: 0.5 + "lower_threshold": 2005, + "upper_threshold": 2021, + "rate_linear": 0.02, + "intercept_at_lower_threshold": 0.5 }, 2: { - lower_threshold: 2021, - upper_threshold: 2041, - rate_linear: 0.01, - intercept_at_lower_threshold: 0.8 + "lower_threshold": 2021, + "upper_threshold": 2041, + "rate_linear": 0.01, + "intercept_at_lower_threshold": 0.8 }, 3: { - lower_threshold: 2041, - upper_threshold: inf, - rate_linear: 0.0, - intercept_at_lower_threshold: 1 + "lower_threshold": 2041, + "upper_threshold": 1e10, + "rate_linear": 0.0, + "intercept_at_lower_threshold": 1 } - } + }; } # TODO: rounding From 62e8a28a6ec726dc0e04bbe7df1ec6119f352c12 Mon Sep 17 00:00:00 2001 From: alex-senger Date: Thu, 29 Aug 2024 19:41:15 +0200 Subject: [PATCH 164/183] elterngeld syntax fix --- .../builtins/parameters/elterngeld.ttsl | 32 +++++++++---------- 1 file changed, 16 insertions(+), 16 deletions(-) diff --git a/src/resources/builtins/parameters/elterngeld.ttsl b/src/resources/builtins/parameters/elterngeld.ttsl index 4f6f14d2..657387ca 100644 --- a/src/resources/builtins/parameters/elterngeld.ttsl +++ b/src/resources/builtins/parameters/elterngeld.ttsl @@ -7,7 +7,7 @@ package elterngeld * § 2 (1) BEEG */ public constant faktor: Float { - from 2007-01-01 = 0.67 + from 2007-01-01 = 0.67; } /** @@ -15,7 +15,7 @@ public constant faktor: Float { * § 2 (1) BEEG */ public constant hoechstbetrag: Int { - from 2007-01-01 = 1800 + from 2007-01-01 = 1800; } /** @@ -28,13 +28,13 @@ public constant nettoeinkommenStufen: Dict { from 2007-01-01 = { 1: 1000, 2: 1001 - } + }; # Reference: Art. 14 G. v. 09.12.2010 BGBl. I S. 1885 from 2011-01-01 = { 1: 1000, 2: 1201 - } + }; } /** @@ -43,7 +43,7 @@ public constant nettoeinkommenStufen: Dict { */ public constant mindestbetrag: Int { # Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 - from 2007-01-01 = 300 + from 2007-01-01 = 300; } /** @@ -52,7 +52,7 @@ public constant mindestbetrag: Int { */ public constant prozentKorrektur: Float { # Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 - from 2007-01-01 = 0.001 + from 2007-01-01 = 0.001; } /** @@ -60,10 +60,10 @@ public constant prozentKorrektur: Float { * § 2 (2) BEEG */ public constant prozentMinimum: Float { - from 2007-01-01 = 0.67 + from 2007-01-01 = 0.67; # Reference: Art. 14 G. v. 09.12.2010 BGBl. I S. 1885 - from 2011-01-01 = 0.65 + from 2011-01-01 = 0.65; } /** @@ -72,7 +72,7 @@ public constant prozentMinimum: Float { */ public constant einkommensSchrittKorrektur: Int { # Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 - from 2007-01-01 = 2 + from 2007-01-01 = 2; } /** @@ -85,7 +85,7 @@ public constant geschwisterbonusAltersgrenzenKinder: Dict { from 2007-01-01 = { 3: 2, 6: 3 - } + }; } /** @@ -94,7 +94,7 @@ public constant geschwisterbonusAltersgrenzenKinder: Dict { */ public constant geschwisterbonusAufschlag: Float { # Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 - from 2007-01-01 = 0.1 + from 2007-01-01 = 0.1; } /** @@ -103,7 +103,7 @@ public constant geschwisterbonusAufschlag: Float { */ public constant geschwisterbonusMinimum: Int { # Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 - from 2007-01-01 = 75 + from 2007-01-01 = 75; } /** @@ -113,7 +113,7 @@ public constant geschwisterbonusMinimum: Int { */ public constant mehrlingbonus: Int { # Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 - from 2007-01-01 = 300 + from 2007-01-01 = 300; } /** @@ -122,7 +122,7 @@ public constant mehrlingbonus: Int { */ public constant sozialversicherungspauschale: Float { # Reference: Art. 1 G. v. 10.09.2012 BGBl. I S. 1878 - from 2012-09-18 = 0.21 + from 2012-09-18 = 0.21; } /** @@ -131,7 +131,7 @@ public constant sozialversicherungspauschale: Float { */ public constant maxMonatePaar: Int { # Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 - from 2007-01-01 = 14 + from 2007-01-01 = 14; } /** @@ -140,5 +140,5 @@ public constant maxMonatePaar: Int { */ public constant maxMonateIndividuell: Int { # Reference: Art. 1 G. v. 05.12.2006 BGBl. I S. 2748 - from 2007-01-01 = 12 + from 2007-01-01 = 12; } From 1c691c1cd23cd884fd2e4a4fffa97d12e926c8a2 Mon Sep 17 00:00:00 2001 From: alex-senger Date: Thu, 29 Aug 2024 19:41:37 +0200 Subject: [PATCH 165/183] erwerbsminderungsrente syntax fix --- .../parameters/erwerbsminderungsrente.ttsl | 168 +++++++++--------- 1 file changed, 84 insertions(+), 84 deletions(-) diff --git a/src/resources/builtins/parameters/erwerbsminderungsrente.ttsl b/src/resources/builtins/parameters/erwerbsminderungsrente.ttsl index 2c1e5b3a..9f9e7aa2 100644 --- a/src/resources/builtins/parameters/erwerbsminderungsrente.ttsl +++ b/src/resources/builtins/parameters/erwerbsminderungsrente.ttsl @@ -1,4 +1,4 @@ -package Erwerbsminderungsrente +package erwerbsminderungsrente # erwerbsm_rente.yaml --------------------------------------------------- @@ -10,26 +10,26 @@ package Erwerbsminderungsrente * Reference: § 77 SGB VI Zugangsfaktor * pro Jahr */ -public constant abschlagsfreieAltersgrenze: Dict { - from 2001-01-01 = 63 - from 2012-01-01 = 63.083333 - from 2012-02-01 = 63.166666 - from 2012-03-01 = 63.25 - from 2012-04-01 = 63.333333 - from 2012-05-01 = 63.416666 - from 2012-06-01 = 63.5 - from 2013-01-01 = 63.583333 - from 2014-01-01 = 63.666666 - from 2015-01-01 = 63.75 - from 2016-01-01 = 63.833333 - from 2017-01-01 = 63.916666 - from 2018-01-01 = 64 - from 2019-01-01 = 64.166666 - from 2020-01-01 = 64.333333 - from 2021-01-01 = 64.5 - from 2022-01-01 = 64.666666 - from 2023-01-01 = 64.833333 - from 2024-01-01 = 65 +public constant abschlagsfreieAltersgrenze: Float { + from 2001-01-01 = 63; + from 2012-01-01 = 63.083333; + from 2012-02-01 = 63.166666; + from 2012-03-01 = 63.25; + from 2012-04-01 = 63.333333; + from 2012-05-01 = 63.416666; + from 2012-06-01 = 63.5; + from 2013-01-01 = 63.583333; + from 2014-01-01 = 63.666666; + from 2015-01-01 = 63.75; + from 2016-01-01 = 63.833333; + from 2017-01-01 = 63.916666; + from 2018-01-01 = 64; + from 2019-01-01 = 64.166666; + from 2020-01-01 = 64.333333; + from 2021-01-01 = 64.5; + from 2022-01-01 = 64.666666; + from 2023-01-01 = 64.833333; + from 2024-01-01 = 65; } /** @@ -39,8 +39,8 @@ public constant abschlagsfreieAltersgrenze: Dict { * Reference: § 77 Abs. 4 SGB VI Zugangsfaktor * pro Jahr */ -public constant regelaltersgrezeLangjaehrigeVersicherte: Dict { - from 2001-01-01 = 63 +public constant regelaltersgrezeLangjaehrigeVersicherte: Float { + from 2001-01-01 = 63; } /** @@ -50,9 +50,9 @@ public constant regelaltersgrezeLangjaehrigeVersicherte: Dict { * Reference: § 264d SGB VI Zugangsfaktor * pro Jahr */ -public constant wartezeitgrenzeLangjaehrigeVersicherteAbschlagsfrei: Dict { - from 2001-01-01 = 35 - from 2024-01-01 = 40 +public constant wartezeitgrenzeLangjaehrigeVersicherteAbschlagsfrei: Int { + from 2001-01-01 = 35; + from 2024-01-01 = 40; } /** @@ -63,57 +63,57 @@ public constant wartezeitgrenzeLangjaehrigeVersicherteAbschlagsfrei: Dict { - from 2001-01-01 = 62.916666 - from 2001-02-01 = 62.833333 - from 2001-03-01 = 62.75 - from 2001-04-01 = 62.666666 - from 2001-05-01 = 62.583333 - from 2001-06-01 = 62.5 - from 2001-07-01 = 62.416666 - from 2001-08-01 = 62.333333 - from 2001-09-01 = 62.25 - from 2001-10-01 = 62.166666 - from 2001-11-01 = 62.083333 - from 2001-12-01 = 62 - from 2002-01-01 = 61.916666 - from 2002-02-01 = 61.833333 - from 2002-03-01 = 61.75 - from 2002-04-01 = 61.666666 - from 2002-05-01 = 61.583333 - from 2002-06-01 = 61.5 - from 2002-07-01 = 61.416666 - from 2002-08-01 = 61.333333 - from 2002-09-01 = 61.25 - from 2002-10-01 = 61.166666 - from 2002-11-01 = 61.083333 - from 2002-12-01 = 61 - from 2003-01-01 = 60.916666 - from 2003-02-01 = 60.833333 - from 2003-03-01 = 60.75 - from 2003-04-01 = 60.666666 - from 2003-05-01 = 60.583333 - from 2003-06-01 = 60.5 - from 2003-07-01 = 60.416666 - from 2003-08-01 = 60.333333 - from 2003-09-01 = 60.25 - from 2003-10-01 = 60.166666 - from 2003-11-01 = 60.083333 - from 2003-12-01 = 60 - from 2014-07-01 = 62 - from 2019-01-01 = 65.666666 - from 2020-01-01 = 65.75 - from 2021-01-01 = 65.833333 - from 2022-01-01 = 65.916666 - from 2023-01-01 = 66 - from 2024-01-01 = 66.083333 - from 2025-01-01 = 66.166666 - from 2026-01-01 = 66.25 - from 2027-01-01 = 66.333333 - from 2028-01-01 = 66.5 - from 2029-01-01 = 66.666666 - from 2030-01-01 = 66.833333 - from 2031-01-01 = 67 +public constant zurechnungszeitgrenze: Float { + from 2001-01-01 = 62.916666; + from 2001-02-01 = 62.833333; + from 2001-03-01 = 62.75; + from 2001-04-01 = 62.666666; + from 2001-05-01 = 62.583333; + from 2001-06-01 = 62.5; + from 2001-07-01 = 62.416666; + from 2001-08-01 = 62.333333; + from 2001-09-01 = 62.25; + from 2001-10-01 = 62.166666; + from 2001-11-01 = 62.083333; + from 2001-12-01 = 62; + from 2002-01-01 = 61.916666; + from 2002-02-01 = 61.833333; + from 2002-03-01 = 61.75; + from 2002-04-01 = 61.666666; + from 2002-05-01 = 61.583333; + from 2002-06-01 = 61.5; + from 2002-07-01 = 61.416666; + from 2002-08-01 = 61.333333; + from 2002-09-01 = 61.25; + from 2002-10-01 = 61.166666; + from 2002-11-01 = 61.083333; + from 2002-12-01 = 61; + from 2003-01-01 = 60.916666; + from 2003-02-01 = 60.833333; + from 2003-03-01 = 60.75; + from 2003-04-01 = 60.666666; + from 2003-05-01 = 60.583333; + from 2003-06-01 = 60.5; + from 2003-07-01 = 60.416666; + from 2003-08-01 = 60.333333; + from 2003-09-01 = 60.25; + from 2003-10-01 = 60.166666; + from 2003-11-01 = 60.083333; + from 2003-12-01 = 60; + from 2014-07-01 = 62; + from 2019-01-01 = 65.666666; + from 2020-01-01 = 65.75; + from 2021-01-01 = 65.833333; + from 2022-01-01 = 65.916666; + from 2023-01-01 = 66; + from 2024-01-01 = 66.083333; + from 2025-01-01 = 66.166666; + from 2026-01-01 = 66.25; + from 2027-01-01 = 66.333333; + from 2028-01-01 = 66.5; + from 2029-01-01 = 66.666666; + from 2030-01-01 = 66.833333; + from 2031-01-01 = 67; } /** @@ -122,8 +122,8 @@ public constant zurechnungszeitgrenze: Dict { * sind bei 10.8% gedeckelt. * Reference: § 77 SGB VI Zugangsfaktor */ -public constant minZugangsfaktor: Dict { - from 2000-01-01 = 0.892 +public constant minZugangsfaktor: Float { + from 2000-01-01 = 0.892; } /** @@ -135,9 +135,9 @@ public constant minZugangsfaktor: Dict { */ public constant rentenartfaktor: Dict { from 2001-01-01 = { - teilw: 0.5, - voll: 1.0 - } + "teilw": 0.5, + "voll": 1.0 + }; } /** @@ -147,6 +147,6 @@ public constant rentenartfaktor: Dict { * Lebensjahr bis zum Beginn der Rente * Reference: SGB VI § 72: Grundbewertung */ -public constant altersgrenzeGrundbewertung: Dict { - from 2001-01-01 = 16 +public constant altersgrenzeGrundbewertung: Int { + from 2001-01-01 = 16; } From fef2f51a2b870c8750c16f13ea1b0ef423154d13 Mon Sep 17 00:00:00 2001 From: alex-senger Date: Thu, 29 Aug 2024 19:41:50 +0200 Subject: [PATCH 166/183] erziehungsgeld syntax fix --- .../builtins/parameters/erziehungsgeld.ttsl | 48 +++++++++---------- 1 file changed, 24 insertions(+), 24 deletions(-) diff --git a/src/resources/builtins/parameters/erziehungsgeld.ttsl b/src/resources/builtins/parameters/erziehungsgeld.ttsl index 327e7fb0..44751190 100644 --- a/src/resources/builtins/parameters/erziehungsgeld.ttsl +++ b/src/resources/builtins/parameters/erziehungsgeld.ttsl @@ -8,27 +8,27 @@ package erziehungsgeld */ public constant erziehungsgeldEinkommensgrenze: Dict>> { from 2004-02-09 = { - limit: { - alleinerz: { - regelsatz: 23000, - budgetsatz: 19086 + "limit": { + "alleinerz": { + "regelsatz": 23000, + "budgetsatz": 19086 }, - paar: { - regelsatz: 30000, - budgetsatz: 22086 + "paar": { + "regelsatz": 30000, + "budgetsatz": 22086 } }, - reduced_limit: { - alleinerz: { - regelsatz: 13500, - budgetsatz: 13500 + "reduced_limit": { + "alleinerz": { + "regelsatz": 13500, + "budgetsatz": 13500 }, - paar: { - regelsatz: 16500, - budgetsatz: 16500 + "paar": { + "regelsatz": 16500, + "budgetsatz": 16500 } } - } + }; } /** @@ -36,7 +36,7 @@ public constant erziehungsgeldEinkommensgrenze: Dict { - from 2004-02-09 = 3140 + from 2004-02-09 = 3140; } /** @@ -45,9 +45,9 @@ public constant erziehungsgeldAufschlagEinkommen: Dict { */ public constant erziehungsgeldSatz: Dict { from 2004-02-09 = { - regelsatz: 300, - budgetsatz: 450 - } + "regelsatz": 300, + "budgetsatz": 450 + }; } /** @@ -59,7 +59,7 @@ public constant erziehungsgeldSatz: Dict { * Reference: Bundesgesetzblatt Jahrgang 2004 Teil I Nr. 6 */ public constant abschlagFaktor: Float { - from 2004-02-09 = 0.052 + from 2004-02-09 = 0.052; } /** @@ -68,7 +68,7 @@ public constant abschlagFaktor: Float { * Reference: Bundesgesetzblatt Jahrgang 2004 Teil I Nr. 6 § 6 (p.209) */ public constant pauschalAbzugAufEinkommen: Float { - from 2004-02-09 = 0.76 + from 2004-02-09 = 0.76; } /** @@ -76,7 +76,7 @@ public constant pauschalAbzugAufEinkommen: Float { * Reference: Bundesgesetzblatt Jahrgang 2004 Teil I Nr. 6 § 15 (p.211) */ public constant arbeitsstundenWoechentlicheGrenze: Int { - from 2004-02-09 = 30 + from 2004-02-09 = 30; } /** @@ -84,7 +84,7 @@ public constant arbeitsstundenWoechentlicheGrenze: Int { * Reference: Bundesgesetzblatt Jahrgang 2004 Teil I Nr. 6 */ public constant endAlterKindRegelsatz: Int { - from 2004-01-01 = 24 + from 2004-01-01 = 24; } /** @@ -92,7 +92,7 @@ public constant endAlterKindRegelsatz: Int { * Reference: Bundesgesetzblatt Jahrgang 2004 Teil I Nr. 6 */ public constant endAlterKindBudgetsatz: Int { - from 2004-01-01 = 12 + from 2004-01-01 = 12; } # TODO: rounding From b7cef312b56d13f279c7d36142fe852a4905d694 Mon Sep 17 00:00:00 2001 From: alex-senger Date: Thu, 29 Aug 2024 19:42:01 +0200 Subject: [PATCH 167/183] grundsicherungImAlter syntax fix --- .../parameters/grundsicherungImAlter.ttsl | 106 +++++++++--------- 1 file changed, 55 insertions(+), 51 deletions(-) diff --git a/src/resources/builtins/parameters/grundsicherungImAlter.ttsl b/src/resources/builtins/parameters/grundsicherungImAlter.ttsl index 7f024b59..99d23053 100644 --- a/src/resources/builtins/parameters/grundsicherungImAlter.ttsl +++ b/src/resources/builtins/parameters/grundsicherungImAlter.ttsl @@ -10,18 +10,20 @@ package grundsicherungImAlter * Sozialgesetzbuch */ public constant vermoegensfreibetrag: Dict { - from 1984-01-01: { - adult: 0, - child: 0, - }, - from 2003-01-01: { - adult: 2600, - child: 0, - }, - from 2017-04-01: { - adult: 5000, - child: 500, - }, + from 1984-01-01 = { + "adult": 0, + "child": 0, + }; + + from 2003-01-01 = { + "adult": 2600, + "child": 0, + }; + + from 2017-04-01 = { + "adult": 5000, + "child": 500, + }; } /** @@ -30,31 +32,32 @@ public constant vermoegensfreibetrag: Dict { * Grundrentenzeiten erreicht wurden. */ public constant gesetzlicheRenteAnrechnungsfrei: Dict> { - from 1984-01-01: { + from 1984-01-01 = { 0: { - lower_threshold: -inf, - upper_threshold: inf, - rate: 0, - intercept_at_lower_threshold: 0, + "lower_threshold": -1e10, + "upper_threshold": 1e10, + "rate": 0, + "intercept_at_lower_threshold": 0, }, - }, - from 2021-01-01: { + }; + + from 2021-01-01 = { 0: { - lower_threshold: -inf, - upper_threshold: 0, - rate: 0, - intercept_at_lower_threshold: 0, + "lower_threshold": -1e10, + "upper_threshold": 0, + "rate": 0, + "intercept_at_lower_threshold": 0, }, 1: { - lower_threshold: 0, - upper_threshold: 100, - rate: 1, + "lower_threshold": 0, + "upper_threshold": 100, + "rate": 1, }, 2: { - upper_threshold: inf, - rate: 0.3, + "upper_threshold": 1e10, + "rate": 0.3, }, - }, + }; } /** @@ -63,10 +66,10 @@ public constant gesetzlicheRenteAnrechnungsfrei: Dict> * Grundsicherung im Alter angerechnet. The reference is § 82 SGB XII Abs. 2. */ public constant kapitaleinkommensfreibetrag: Int { - from 1984-01-01 = 0 + from 1984-01-01 = 0; # Reference: § 43 SGB XII Abs. 2 - from 2016-01-01 = 26 + from 2016-01-01 = 26; } /** @@ -77,9 +80,9 @@ public constant kapitaleinkommensfreibetrag: Int { */ public constant erwerbseinkommensfreibetrag: Float { # Unclear how it was handled before 2005 - from 1984-01-01 = 0 + from 1984-01-01 = 0; - from 2005-01-01 = 0.3 + from 2005-01-01 = 0.3; } /** @@ -89,32 +92,33 @@ public constant erwerbseinkommensfreibetrag: Float { * Reference: § 82 SGB XII Abs. 4 */ public constant privateRenteAnrechnungsfrei: Dict> { - from 1984-01-01: { + from 1984-01-01 = { # Unclear how it was handled before 2005, 0: { - lower_threshold: -inf, - upper_threshold: inf, - rate: 0, - intercept_at_lower_threshold: 0, + "lower_threshold": -1e10, + "upper_threshold": 1e10, + "rate": 0, + "intercept_at_lower_threshold": 0, }, - }, - from 2005-01-01: { + }; + + from 2005-01-01 = { 0: { - lower_threshold: -inf, - upper_threshold: 0, - rate: 0, - intercept_at_lower_threshold: 0, + "lower_threshold": -1e10, + "upper_threshold": 0, + "rate": 0, + "intercept_at_lower_threshold": 0, }, 1: { - lower_threshold: 0, - upper_threshold: 100, - rate: 1, + "lower_threshold": 0, + "upper_threshold": 100, + "rate": 1, }, 2: { - upper_threshold: inf, - rate: 0.3, + "upper_threshold": 1e10, + "rate": 0.3, }, - }, + }; } /** @@ -125,5 +129,5 @@ public constant privateRenteAnrechnungsfrei: Dict> { * Reference: § 30 Abs. 1 SGB XII, https:#www.buzer.de/gesetz/3415/al0-3758.htm */ public constant mehrbedarfSchwerbehinderung: Float { - from 2006-12-07 = 0.17 + from 2006-12-07 = 0.17; } From 0156a50fb8b4191590b17ab3075a002d092821c5 Mon Sep 17 00:00:00 2001 From: methr0 Date: Fri, 30 Aug 2024 10:55:06 +0200 Subject: [PATCH 168/183] fix bug in type generation --- .../src/language/generation/ttsl-python-generator.ts | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/packages/ttsl-lang/src/language/generation/ttsl-python-generator.ts b/packages/ttsl-lang/src/language/generation/ttsl-python-generator.ts index c2610d4c..93fe6c87 100644 --- a/packages/ttsl-lang/src/language/generation/ttsl-python-generator.ts +++ b/packages/ttsl-lang/src/language/generation/ttsl-python-generator.ts @@ -701,9 +701,15 @@ export class TTSLPythonGenerator { } return result.append(`str`) } else if(isTslListType(type)){ - return result.append(`: list[${this.generateType(type.typeParameterList.typeParameters.at(0)?.type, frame, true)?.contents}]`) + if(!rekursion){ + return result.append(`: list[${this.generateType(type.typeParameterList.typeParameters.at(0)?.type, frame, true)?.contents}]`) + } + return result.append(`list[${this.generateType(type.typeParameterList.typeParameters.at(0)?.type, frame, true)?.contents}]`) } else if(isTslDictionaryType(type)){ - return result.append(`: dict[${this.generateType(type.typeParameterList.typeParameters.at(0)?.type, frame, true)?.contents}, ${this.generateType(type.typeParameterList.typeParameters.at(1)?.type, frame, true)?.contents}]`) + if(!rekursion){ + return result.append(`: dict[${this.generateType(type.typeParameterList.typeParameters.at(0)?.type, frame, true)?.contents}, ${this.generateType(type.typeParameterList.typeParameters.at(1)?.type, frame, true)?.contents}]`) + } + return result.append(`dict[${this.generateType(type.typeParameterList.typeParameters.at(0)?.type, frame, true)?.contents}, ${this.generateType(type.typeParameterList.typeParameters.at(1)?.type, frame, true)?.contents}]`) } else { return new CompositeGeneratorNode(``) } From f8903fe57f18a0bd174e1c7f93723c7f7c584826 Mon Sep 17 00:00:00 2001 From: alex-senger Date: Sun, 1 Sep 2024 14:44:41 +0200 Subject: [PATCH 169/183] fix syntax errors --- .../parameters/arbeitslosengeld2.ttsl | 236 +- .../parameters/einkommenssteuerAbzuege.ttsl | 344 ++- .../builtins/parameters/gesetzlicheRente.ttsl | 781 ++++--- .../builtins/parameters/kindergeld.ttsl | 268 +-- .../builtins/parameters/kinderzuschlag.ttsl | 629 +++--- .../parameters/kinderzuschlagEinkommen.ttsl | 26 +- .../builtins/parameters/lohnsteuer.ttsl | 60 +- .../parameters/solidaritaetszuschlag.ttsl | 126 +- .../sozialversicherungsbeitrag.ttsl | 1976 ++++++++--------- 9 files changed, 2213 insertions(+), 2233 deletions(-) diff --git a/src/resources/builtins/parameters/arbeitslosengeld2.ttsl b/src/resources/builtins/parameters/arbeitslosengeld2.ttsl index 7c706b98..15afa62e 100644 --- a/src/resources/builtins/parameters/arbeitslosengeld2.ttsl +++ b/src/resources/builtins/parameters/arbeitslosengeld2.ttsl @@ -9,98 +9,98 @@ package arbeitslosengeld2 * § 11b (2) SGB II (neugefasst durch B. v. 13.05.2011 BGBl. I S. 850. Artikel 2 * G. v. 24.03.2011 BGBl. I S. 453). */ -public constant anrechnungsfreieEinkommensanteile: Dict>> { +public constant anrechnungsfreieEinkommensanteile: Dict> { # Reference: Artikel 1. G. v. 24.12.2003 BGBl. I S. 2954. from 2005-01-01 = { 0: { - lower_threshold: -inf, - upper_threshold: 0, - rate: 0, - intercept_at_lower_threshold: 0 + "lower_threshold": -inf, + "upper_threshold": 0, + "rate": 0, + "intercept_at_lower_threshold": 0 }, 1: { - lower_threshold: 0, - upper_threshold: 400, - rate: 0.15 + "lower_threshold": 0, + "upper_threshold": 400, + "rate": 0.15 }, 2: { - upper_threshold: 900, - rate: 0.3 + "upper_threshold": 900, + "rate": 0.3 }, 3: { - upper_threshold: 1500, - rate: 0.15 + "upper_threshold": 1500, + "rate": 0.15 }, 4: { - upper_threshold: inf, - rate: 0 + "upper_threshold": inf, + "rate": 0 } - } + }; # Reference: Artikel 1 G. v. 14.08.2005 BGBl. I S. 2407. from 2005-10-01 = { 0: { - lower_threshold: -inf, - upper_threshold: 0, - rate: 0, - intercept_at_lower_threshold: 0 + "lower_threshold": -inf, + "upper_threshold": 0, + "rate": 0, + "intercept_at_lower_threshold": 0 }, 1: { - lower_threshold: 0, - upper_threshold: 100, - rate: 1.0 + "lower_threshold": 0, + "upper_threshold": 100, + "rate": 1.0 }, 2: { - upper_threshold: 800, - rate: 0.2 + "upper_threshold": 800, + "rate": 0.2 }, 3: { - upper_threshold: 1200, - rate: 0.1 + "upper_threshold": 1200, + "rate": 0.1 }, 4: { - upper_threshold: inf, - rate: 0 + "upper_threshold": inf, + "rate": 0 } - } + }; # Reference: Artikel 1 G. v. 20.12.2011 BGBl. I 2854. from 2011-04-01 = { 2: { - upper_threshold: 1000 + "upper_threshold": 1000 } - } + }; # Reference: G. v. 20.12.2022 BGBl. I S. 2328. from 2023-07-01 = { 0: { - lower_threshold: -inf, - upper_threshold: 0, - rate: 0, - intercept_at_lower_threshold: 0 + "lower_threshold": -inf, + "upper_threshold": 0, + "rate": 0, + "intercept_at_lower_threshold": 0 }, 1: { - lower_threshold: 0, - upper_threshold: 100, - rate: 1.0 + "lower_threshold": 0, + "upper_threshold": 100, + "rate": 1.0 }, 2: { - upper_threshold: 520, - rate: 0.2 + "upper_threshold": 520, + "rate": 0.2 }, 3: { - upper_threshold: 1000, - rate: 0.3 + "upper_threshold": 1000, + "rate": 0.3 }, 4: { - upper_threshold: 1200, - rate: 0.1 + "upper_threshold": 1200, + "rate": 0.1 }, 5: { - upper_threshold: inf, - rate: 0 + "upper_threshold": inf, + "rate": 0 } - } + }; } /** @@ -112,20 +112,20 @@ public constant anrechnungsfreieEinkommensanteile: Dict>> { +public constant anrechnungsfreieEinkommensanteileFallsKinder: Dict> { # Reference: Artikel 1 G. v. 14.08.2005 BGBl. I S. 2407. from 2005-10-01 = { 3: { - upper_threshold: 1500 + "upper_threshold": 1500 } - } + }; # Reference: G. v. 20.12.2022 BGBl. I S. 2328. from 2023-07-01 = { 4: { - upper_threshold: 1500 + "upper_threshold": 1500 } - } + }; } /** @@ -137,30 +137,26 @@ public constant anrechnungsfreieEinkommensanteileFallsKinder: Dict { - from 2005-01-01 = { - scalar: 338, - reference: "Artikel 1 G. v. 24.12.2003 BGBl. I S. 2954.", - note: "Der tatsächliche Wert unterscheidet sich zwischen Ost und West. Korrekte Werte sind in den alten Bundesländern einschließlich Berlin (Ost) 345 Euro, in den neuen Bundesländern 331 Euro." - }, + from 2005-01-01 = 338; # Reference: B. v. 01.09.2005 BGBl. I S. 2718. # Betrag unverändert. Der tatsächliche Wert unterscheidet sich zwischen Ost und West. Hier wurde vereinfachend 338 Euro als ungewichteter Mittelwert genommen. Korrekte Werte für die Zeit ab 1. Juli 2005 sind in den alten Bundesländern einschließlich Berlin (Ost) 345 Euro, in den neuen Bundesländern 331 Euro. - from 2005-07-01 = 338 + from 2005-07-01 = 338; # Reference: B. v. 20.07.2006 BGBl. I S. 1702. - from 2006-07-01 = 345 + from 2006-07-01 = 345; # Reference: B. v. 18.06.2007 BGBl. I S. 1139. - from 2007-07-01 = 347 + from 2007-07-01 = 347; # Reference: B. v. 26.06.2008 BGBl. I S. 1102. - from 2008-07-01 = 351 + from 2008-07-01 = 351; # Reference: B. v. 17.06.2009 BGBl. I S. 1342. - from 2009-07-01 = 359 + from 2009-07-01 = 359; # Reference: B. v. 07.06.2010 BGBl. I S. 820. Betrag unverändert. - from 2010-07-01 = 359 + from 2010-07-01 = 359; # Reference: Artikel 1 G. v. 24.03.2011 BGBl. I S. 453. from 2011-01-01 = { @@ -170,7 +166,7 @@ public constant regelsatz: Int or Dict { 4: 287, 5: 251, 6: 215, - } + }; # Reference: V. v. 20.10.2011 BGBl. I S. 2093. from 2012-01-01 = { @@ -180,7 +176,7 @@ public constant regelsatz: Int or Dict { 4: 287, 5: 251, 6: 219, - } + }; # Reference: B. v. 18.10.2012 BGBl. I S. 2175. from 2013-01-01 = { @@ -190,7 +186,7 @@ public constant regelsatz: Int or Dict { 4: 289, 5: 255, 6: 224, - } + }; # Reference: B. v. 16.10.2013 BGBl. I S. 3857. from 2014-01-01 = { @@ -200,7 +196,7 @@ public constant regelsatz: Int or Dict { 4: 296, 5: 261, 6: 229, - } + }; # Reference: B. v. 15.10.2014 BGBl. I S. 1620. from 2015-01-01 = { @@ -210,7 +206,7 @@ public constant regelsatz: Int or Dict { 4: 302, 5: 267, 6: 234, - } + }; # Reference: B. v. 22.10.2015 BGBl. I S. 1792. from 2016-01-01 = { @@ -220,7 +216,7 @@ public constant regelsatz: Int or Dict { 4: 306, 5: 270, 6: 237, - } + }; # Reference: G. v. 22.12.2016 BGBl. I S. 3159. from 2017-01-01 = { @@ -230,7 +226,7 @@ public constant regelsatz: Int or Dict { 4: 311, 5: 291, 6: 236, - } + }; # Reference: V. v. 08.11.2017 BGBl. I S. 3767. from 2018-01-01 = { @@ -240,7 +236,7 @@ public constant regelsatz: Int or Dict { 4: 316, 5: 296, 6: 240, - } + }; # Reference: V. v. 19.10.2018 BGBl. I S. 1766. from 2019-01-01 = { @@ -250,7 +246,7 @@ public constant regelsatz: Int or Dict { 4: 322, 5: 302, 6: 245, - } + }; # Reference: V. v. 18.10.2019 BGBl. I S. 1452. from 2020-01-01 = { @@ -260,7 +256,7 @@ public constant regelsatz: Int or Dict { 4: 328, 5: 308, 6: 250 - } + }; # Reference: G. v. 09.12.2020 BGBl. I S. 2855. from 2021-01-01 = { @@ -270,7 +266,7 @@ public constant regelsatz: Int or Dict { 4: 373, 5: 309, 6: 283 - } + }; # Reference: V. v. 13.10.2021 BGBl. I S. 4674. from 2022-01-01 = { @@ -280,7 +276,7 @@ public constant regelsatz: Int or Dict { 4: 376, 5: 311, 6: 285 - } + }; # Reference: G. v. 20.12.2022 BGBl. I S. 2328. # Bürgergeld-Gesetz @@ -291,7 +287,7 @@ public constant regelsatz: Int or Dict { 4: 420, 5: 348, 6: 318 - } + }; # Reference: §2 V. v. 24.10.2024 BGBl. I Nr. 287 from 2024-01-01 = { @@ -301,7 +297,7 @@ public constant regelsatz: Int or Dict { 4: 471, 5: 390, 6: 357 - } + }; } /** @@ -314,23 +310,23 @@ public constant regelsatz: Int or Dict { public constant anteilRegelsatz: Dict { # Reference: Artikel 1 G. v. 24.12.2003 BGBl. I S. 2954. from 2005-01-01 = { - zwei_erwachsene: 0.9, - weitere_erwachsene: 0.8, - kinder_bis_5: 0.6, - kinder_ab_6_bis_13: 0.6, - kinder_ab_14_bis_24: 0.8 - } + "zwei_erwachsene": 0.9, + "weitere_erwachsene": 0.8, + "kinder_bis_5": 0.6, + "kinder_ab_6_bis_13": 0.6, + "kinder_ab_14_bis_24": 0.8 + }; # TODO: WAS HEIßT DEVIATION_FROM # Reference: Artikel 1 G. v. 02.03.2009 BGBl. I S. 416. from 2009-07-01 = { - zwei_erwachsene: 0.9, - weitere_erwachsene: 0.8, - kinder_bis_5: 0.6, - kinder_ab_6_bis_13: 0.7, - kinder_ab_14_bis_24: 0.8 - } + "zwei_erwachsene": 0.9, + "weitere_erwachsene": 0.8, + "kinder_bis_5": 0.6, + "kinder_ab_6_bis_13": 0.7, + "kinder_ab_14_bis_24": 0.8 + }; } /** @@ -346,10 +342,10 @@ public constant anteilRegelsatz: Dict { public constant mehrbedarfAnteil: Dict { # Reference: G. v. 24.12.2003 BGBl. I S. 2954. from 2005-01-01 = { - min_1_kind: 0.12, - kind_unter_7_oder_mehr: 0.36, - max: 0.6 - } + "min_1_kind": 0.12, + "kind_unter_7_oder_mehr": 0.36, + "max": 0.6 + }; } /** @@ -359,14 +355,14 @@ public constant mehrbedarfAnteil: Dict { * mehr auf und ist nicht mehr relevant, * da alle betroffenen Personen zu alt für ALG 2 sind. */ -public constant vermögensGrundfreibetragObergrenze: Dict { +public constant vermoegensGrundfreibetragObergrenze: Dict { # Reference: Artikel 1 G. v. 23.12.2002 BGBl. I S. 4607. from 2005-01-01 = { 1947: 33800, 1948: 13000, 1958: 13000, 1964: 13000 - } + }; # Reference: Artikel 1 G. v. 20.07.2006 BGBl. I S. 1706. from 2006-08-01 = { @@ -374,7 +370,7 @@ public constant vermögensGrundfreibetragObergrenze: Dict { 1948: 9750, 1958: 9750, 1964: 9750 - } + }; # Reference: Artikel 1 G. v. 20.04.2007 BGBl. I S. 554. from 2008-01-01 = { @@ -382,7 +378,7 @@ public constant vermögensGrundfreibetragObergrenze: Dict { 1948: 9750, 1958: 9900, 1964: 10050 - } + }; # Reference: G. v. 20.12.2022 BGBl. I S. 2328. (Bürgergeld-Gesetz) from 2023-01-01 = { @@ -390,7 +386,7 @@ public constant vermögensGrundfreibetragObergrenze: Dict { 1948: null, 1958: null, 1964: null - } + }; } /** @@ -403,9 +399,9 @@ public constant vermögensGrundfreibetragObergrenze: Dict { public constant schonvermoegenBuergergeld: Dict { # Reference: G. v. 20.12.2022 BGBl. I S. 2328. (Bürgergeld-Gesetz) from 2023-01-01 = { - während_karenzzeit: 40000, - normaler_satz: 15000 - } + "waehrend_karenzzeit": 40000, + "normaler_satz": 15000 + }; } /** @@ -440,18 +436,18 @@ public constant vermoegensfreibetragKind: Int { * Vermögensfreibetrag ändert sich nach Geburtsjahr */ public constant vermoegensfreibetragAlter: Dict { - 2005-01-01: { + from 2005-01-01 = { 1: 1948, 2: 1958, 3: 1963 - } + }; # Reference: G. v. 20.12.2022 BGBl. I S. 2328. (Bürgergeld-Gesetz) - 2023-01-01: { + from 2023-01-01 = { 1: null, 2: null, 3: null - } + }; } /** @@ -463,15 +459,15 @@ public constant vermoegensfreibetragAlter: Dict { public constant abzugfaehigePauschale: Dict { # Reference: V. v. 20.10.2004 BGBl. I S. 2622 from 2005-01-01 = { - werbung: 15.33, - versicherung: 30.0 - } + "werbung": 15.33, + "versicherung": 30.0 + }; # Reference: V. v. 21.06.2011 BGBl. I S. 1175. from 2011-01-01 = { - werbung: 15.33, - versicherung: 30.0 - } + "werbung": 15.33, + "versicherung": 30.0 + }; } /** @@ -483,7 +479,7 @@ public constant abzugfaehigePauschale: Dict { * unit: Euro / Quadratmeter */ public constant maxMieteProQuadratMeter: Int { - from 1984-01-01 = 10 + from 1984-01-01 = 10; } /** @@ -493,9 +489,9 @@ public constant maxMieteProQuadratMeter: Int { */ public constant berechtigteWohnflaecheMiete: Dict { from 1984-01-01 = { - single: 45, - je_weitere_person: 15 - } + "single": 45, + "je_weitere_person": 15 + }; } /** @@ -506,14 +502,14 @@ public constant berechtigteWohnflaecheMiete: Dict { * gestiegen und wird ab 5 Personen im Haushalt um 20 Quadratmeter pro Person * angehoben. */ -public constant berechtigteWohnflaecheEigentum: Dict { +public constant berechtigteWohnflaecheEigentum: Dict { from 1984-01-01 = { 1: 80, 2: 80, 3: 100, 4: 120, - je_weitere_person: 20 - } + "je_weitere_person": 20 + }; # Reference: Art. 1 Nr.12 Abschnitt 5, G. v. 20.12.2022 BGBl. I S. 2328 from 2023-01-01 = { @@ -521,6 +517,6 @@ public constant berechtigteWohnflaecheEigentum: Dict { 2: 140, 3: 140, 4: 140, - je_weitere_person: 20 - } + "je_weitere_person": 20 + }; } diff --git a/src/resources/builtins/parameters/einkommenssteuerAbzuege.ttsl b/src/resources/builtins/parameters/einkommenssteuerAbzuege.ttsl index c166b100..b34c77fb 100644 --- a/src/resources/builtins/parameters/einkommenssteuerAbzuege.ttsl +++ b/src/resources/builtins/parameters/einkommenssteuerAbzuege.ttsl @@ -1,4 +1,4 @@ -pacakge einkommenssteuerAbzuege +package einkommenssteuerAbzuege # eink_st_abzuege.yaml -------------------------------------------------- @@ -12,126 +12,118 @@ pacakge einkommenssteuerAbzuege public constant kinderFreibetrag: Dict { # Reference: Art. 1 G. v. 23.12.1982 BGBl. I S. 1857. from 1983-01-01 = { - saechlichesExistenzminimum: 110 - } + "saechlichesExistenzminimum": 110 + }; # Reference: Art. 1 G. v. 26.06.1985 BGBl. I S. 1153. from 1986-01-01 = { - saechlichesExistenzminimum: 635 - } + "saechlichesExistenzminimum": 635 + }; # Reference: Artikel 1 G. v. 25.07.1988 BGBl. I S. 1093. from 1990-01-01 = { - saechlichesExistenzminimum: 773 - } + "saechlichesExistenzminimum": 773 + }; # Reference: Art. 1 G. v. 25.02.1992 BGBl. I S. 297. from 1992-01-01 = { - saechlichesExistenzminimum: 1049 - } + "saechlichesExistenzminimum": 1049 + }; # Reference: Art. 1. G. v. 11.10.1995 BGBl. I S. 1250. from 1996-01-01 = { - saechlichesExistenzminimum: 1601 - } + "saechlichesExistenzminimum": 1601 + }; from 1997-01-01 = { - saechlichesExistenzminimum: 1767 - } + "saechlichesExistenzminimum": 1767 + }; # Reference: Art. 1 G. v. 28.12.1999 BGBl. I. S. 2552. from 2000-01-01 = { - beitragErziehungAusbildung: 774, - saechlichesExistenzminimum: 1767 - } + "beitragErziehungAusbildung": 774, + "saechlichesExistenzminimum": 1767 + }; # Reference: Art. 1 G. v. 16.08.2001 BGBl. I S. 2074 from 2002-01-01 = { - beitragErziehungAusbildung: 1080, - saechlichesExistenzminimum: 1824 - } + "beitragErziehungAusbildung": 1080, + "saechlichesExistenzminimum": 1824 + }; # Reference: Art. 1 G. v. 22.12.2008 BGBl. I S. 2955 from 2009-01-01 = { - beitragErziehungAusbildung: 1080, # previous - saechlichesExistenzminimum: 1932 - } + "beitragErziehungAusbildung": 1080, # previous + "saechlichesExistenzminimum": 1932 + }; # Reference: Art. 1 G. v. 22.12.2009 BGBl. I S. 3950 from 2010-01-01 = { - beitragErziehungAusbildung: 1320, - saechlichesExistenzminimum: 2184 - } + "beitragErziehungAusbildung": 1320, + "saechlichesExistenzminimum": 2184 + }; # Reference: Art. 1 G. v. 16.07.2015 BGBl. I S. 1202 from 2015-01-01 = { - beitragErziehungAusbildung: 1320, # previous - saechlichesExistenzminimum: 2256 - } + "beitragErziehungAusbildung": 1320, # previous + "saechlichesExistenzminimum": 2256 + }; # Reference: Art. 2 G. v. 16.07.2015 BGBl. I S. 1202 from 2016-01-01 = { - beitragErziehungAusbildung: 1320, # previous - saechlichesExistenzminimum: 2304 - } + "beitragErziehungAusbildung": 1320, # previous + "saechlichesExistenzminimum": 2304 + }; # Reference: Art. 8 G. v. 20.12.2016 BGBl. I. S. 3000 from 2017-01-01 = { - beitragErziehungAusbildung: 1320, # previous - saechlichesExistenzminimum: 2358 - } + "beitragErziehungAusbildung": 1320, # previous + "saechlichesExistenzminimum": 2358 + }; # Reference: Art. 9 G. v. 20.12.2016 BGBl. I. S. 3000 from 2018-01-01 = { - beitragErziehungAusbildung: 1320, # previous - saechlichesExistenzminimum: 2394 - } + "beitragErziehungAusbildung": 1320, # previous + "saechlichesExistenzminimum": 2394 + }; # Reference: Art. 1 G. v. 29.11.2018 BGBl. I S. 2210 from 2019-01-01 = { - beitragErziehungAusbildung: 1320, # previous - saechlichesExistenzminimum: 2490 - } + "beitragErziehungAusbildung": 1320, # previous + "saechlichesExistenzminimum": 2490 + }; # Reference: Art. 3 G. v. 29.11.2018 BGBl. I S. 2210 from 2020-01-01 = { - beitragErziehungAusbildung: 1320, # previous - saechlichesExistenzminimum: 2586 - } + "beitragErziehungAusbildung": 1320, # previous + "saechlichesExistenzminimum": 2586 + }; # Reference: Art. 1 G. v. 01.12.2020 BGBl. I S. 2616 from 2021-01-01 = { - saechlichesExistenzminimum: 2730, + "saechlichesExistenzminimum": 2730, beitr_erz_ausb: 1464 - } + }; # Reference: Art. 1 G. v. 08.12.2022 BGBl. I S. 2230. from 2022-01-01 = { - beitragErziehungAusbildung: 2730, # previous - saechlichesExistenzminimum: 2810 - } + "beitragErziehungAusbildung": 2730, # previous + "saechlichesExistenzminimum": 2810 + }; # Reference: Art. 2 G. v. 08.12.2022 BGBl. I S. 2230. from 2023-01-01 = { - beitragErziehungAusbildung: 2730, # previous - saechlichesExistenzminimum: 3012 - } - - 2024-01-01: - deviation_from: previous - sächl_existenzmin: 3306 - reference: >- - Not implemented in law yet, but announced. - https:#www.bmfsfj.de/bmfsfj/aktuelles/alle-meldungen/ - spuerbare-verbesserungen-fuer-familien--234802 + "beitragErziehungAusbildung": 2730, # previous + "saechlichesExistenzminimum": 3012 + }; # Reference: Art. 3 G. v. 08.12.2022 BGBl. I S. 2230. # Not implemented in law yet, but announced. https:#www.bmfsfj.de/bmfsfj/aktuelles/alle-meldungen/spuerbare-verbesserungen-fuer-familien--234802 from 2024-01-01 = { # deviation_from: previous - beitragErziehungAusbildung: 2730, # previous - saechlichesExistenzminimum: 3306 - } + "beitragErziehungAusbildung": 2730, # previous + "saechlichesExistenzminimum": 3306 + }; } /** @@ -141,18 +133,18 @@ public constant kinderFreibetrag: Dict { * Zeitverlauf wurde bereits 2005 festgelegt. */ public constant vorsorge2004Vorwegabzug: Int { - from 1985-01-01 = 1534 - from 1989-01-01 = 2045 - from 1993-01-01 = 3068 - from 2011-01-01 = 2700 - from 2012-01-01 = 2400 - from 2013-01-01 = 2100 - from 2014-01-01 = 1800 - from 2015-01-01 = 1500 - from 2016-01-01 = 1200 - from 2017-01-01 = 900 - from 2018-01-01 = 600 - from 2019-01-01 = 300 + from 1985-01-01 = 1534; + from 1989-01-01 = 2045; + from 1993-01-01 = 3068; + from 2011-01-01 = 2700; + from 2012-01-01 = 2400; + from 2013-01-01 = 2100; + from 2014-01-01 = 1800; + from 2015-01-01 = 1500; + from 2016-01-01 = 1200; + from 2017-01-01 = 900; + from 2018-01-01 = 600; + from 2019-01-01 = 300; } /** @@ -161,18 +153,18 @@ public constant vorsorge2004Vorwegabzug: Int { * This is the minimum amount deducted from any employment income. */ public constant werbungskostenpauschbetrag: Int { - from 1975-01-01 = 288 - from 1990-01-01 = 1044 - from 2004-01-01 = 920 + from 1975-01-01 = 288; + from 1990-01-01 = 1044; + from 2004-01-01 = 920; # Reference: Art. 1 G. v. 01.11.2011 BGBl. I S. 2131. - from 2012-01-01 = 1000 + from 2012-01-01 = 1000; # Reference: Art. 2 G. v. 23.05.2022 BGBl. I S. 749 - from 2022-01-01 = 1200 + from 2022-01-01 = 1200; # Reference: G. v. 20.12.2022 BGBl. I S. 2294. - from 2023-01-01 = 1230 + from 2023-01-01 = 1230; } /** @@ -180,13 +172,13 @@ public constant werbungskostenpauschbetrag: Int { * § 10c EStG */ public constant sonderausgabenpauschbetrag: Int { - from 1984-01-01 = 138 + from 1984-01-01 = 138; # Reference: Art. 1 G. v. 25.07.1988, BGBl. I S. 1093 - from 1988-01-01 = 55 + from 1988-01-01 = 55; # Reference: Art. 1 G. v. 19.12.2000, BGBl. I S. 1790 - from 2002-01-01 = 36 + from 2002-01-01 = 36; } /** @@ -195,21 +187,21 @@ public constant sonderausgabenpauschbetrag: Int { * gemeinsam veranlagte. seit 2009. vor 2008 Sparerfreibetrag. */ public constant sparerpauschbetrag: Int { - from 1975-01-01 = 153 - from 1990-01-01 = 307 - from 1993-01-01 = 3068 - from 2000-01-01 = 1534 + from 1975-01-01 = 153; + from 1990-01-01 = 307; + from 1993-01-01 = 3068; + from 2000-01-01 = 1534; # Reference: Art. 1 G. v. 19.12.2000 BGBl I S. 1790. - from 2002-01-01 = 1550 - from 2004-01-01 = 1370 - from 2007-01-01 = 750 + from 2002-01-01 = 1550; + from 2004-01-01 = 1370; + from 2007-01-01 = 750; # Reference: Art. 1 G. v. 14.08.2007 BGBl. I S. 1912 - from 2009-01-01 = 801 + from 2009-01-01 = 801; # Reference: G. v. 20.12.2022 BGBl. I S. 2294. - from 2023-01-01 = 1000 + from 2023-01-01 = 1000; } /** @@ -218,8 +210,8 @@ public constant sparerpauschbetrag: Int { * gemeinsam veranlagte. seit 2009. vor 2008 Sparerfreibetrag. */ public constant sparerWerbungskostenPauschbetrag: Int { - from 1975-01-01 = 51 - from 2009-01-01 = 0 + from 1975-01-01 = 51; + from 2009-01-01 = 0; } /** @@ -227,8 +219,8 @@ public constant sparerWerbungskostenPauschbetrag: Int { * §10 (3) EStG bis 2004. */ public constant vorsorge2004Grundhoechstbetrag: Int { - from 1985-01-01 = 1196 - from 1992-01-01 = 1334 + from 1985-01-01 = 1196; + from 1992-01-01 = 1334; } /** @@ -239,9 +231,9 @@ public constant vorsorge2004Grundhoechstbetrag: Int { * den diese Steuerpflichtigen erhalten, vom Geburtsjahr ab. */ public constant altersentlastungsbetragMax: Int or Dict { - from 1984-01-01 = 1534 - from 1989-01-01 = 1902 - from 2002-01-01 = 1908 + from 1984-01-01 = 1534; + from 1989-01-01 = 1902; + from 2002-01-01 = 1908; # Reference: Artikel 1 G. v. 05.07.2004 BGBl. I S. 1427. 2005-01-01 = { @@ -281,7 +273,7 @@ public constant altersentlastungsbetragMax: Int or Dict { 1973: 76, 1974: 38, 1975: 0 - } + }; } /** @@ -292,7 +284,7 @@ public constant altersentlastungsbetragMax: Int or Dict { * den diese Steuerpflichtigen erhalten, vom Geburtsjahr ab. */ public constant altersentlastungQuote: Float or Dict { - from 1984-01-01 = 0.4 + from 1984-01-01 = 0.4; # Reference: Artikel 1 G. v. 05.07.2004 BGBl. I S. 1427. 2005-01-01 = { @@ -332,7 +324,7 @@ public constant altersentlastungQuote: Float or Dict { 1973: 0.016, 1974: 0.008, 1975: 0 - } + }; } /** @@ -343,7 +335,7 @@ public constant altersentlastungQuote: Float or Dict { * Reference: § 24a Art. 3 EStG */ public constant altersentlastungsbetragAltersgrenze: Int { - from 1984-01-01 = 64 + from 1984-01-01 = 64; } /** @@ -355,20 +347,20 @@ public constant altersentlastungsbetragAltersgrenze: Int { * 2023 auf 100% gesetzt. * Reference: § 10 Abs. 1 Nr. 2 Buchst. a und b EStG */ -public constant einfuehrungsfaktor: { +public constant einfuehrungsfaktor: Dict> { from 2005-01-01 = { - 0: {lower_threshold: -inf, rate_linear: 0, intercept_at_lower_threshold: 0.6}, - 1: {lower_threshold: 2005, upper_threshold: 2025, rate_linear: 0.02}, - 2: {upper_threshold: inf, rate_linear: 0} - } + 0: {"lower_threshold": -1e10, "rate_linear": 0, "intercept_at_lower_threshold": 0.6}, + 1: {"lower_threshold": 2005, "upper_threshold": 2025, "rate_linear": 0.02}, + 2: {"upper_threshold": 1e10, "rate_linear": 0} + }; # Reference: G. v. 20.12.2022 BGBl. I S. 2294. from 2023-01-01 = { - 0: {lower_threshold: -inf, rate_linear: 0, intercept_at_lower_threshold: 0.6}, - 1: {lower_threshold: 2005, rate_linear: 0.02}, - 2: {lower_threshold: 2022, upper_threshold: 2023, rate_linear: 0.06}, - 3: {upper_threshold: inf, rate_linear: 0} - } + 0: {"lower_threshold": -1e10, "rate_linear": 0, "intercept_at_lower_threshold": 0.6}, + 1: {"lower_threshold": 2005, "rate_linear": 0.02}, + 2: {"lower_threshold": 2022, "upper_threshold": 2023, "rate_linear": 0.06}, + 3: {"upper_threshold": 1e10, "rate_linear": 0} + }; } /** @@ -376,21 +368,21 @@ public constant einfuehrungsfaktor: { * § 24b (1) EStG. vor 2004 "Haushaltsfreibetrag", § 32 (7) EStG */ public constant alleinerzFreibetrag: Int { - from 1984-01-01 = 2154 - from 1986-01-01 = 2319 - from 1989-01-01 = 2871 - from 2001-01-01 = 2916 - from 2002-01-01 = 2340 - from 2004-01-01 = 1308 + from 1984-01-01 = 2154; + from 1986-01-01 = 2319; + from 1989-01-01 = 2871; + from 2001-01-01 = 2916; + from 2002-01-01 = 2340; + from 2004-01-01 = 1308; # Reference: Art. 1 G. v. 16.07.2015 BGBl. I S.1202 - from 2015-01-01 = 1908 + from 2015-01-01 = 1908; # Reference: Art. 3 Nr. 2 G. v. 29.12.2020 BGBl. I S.3096 - from 2020-01-01 = 4008 + from 2020-01-01 = 4008; # Reference: G. v. 20.12.2022 BGBl. I S. 2294. - from 2023-01-01 = 4260 + from 2023-01-01 = 4260; } /** @@ -400,7 +392,7 @@ public constant alleinerzFreibetrag: Int { */ public constant alleinerzFreibetragZusatz: Int { # Reference: Art. 1 G. vs. 16.07.2015 BGBl. I S.1202 - from 2015-01-01 = 240 + from 2015-01-01 = 240; } /** @@ -409,15 +401,15 @@ public constant alleinerzFreibetragZusatz: Int { * gekürzt bei abhängig Beschäftigten (vereinfacht). */ public constant vorsorge2004KuerzungVorwegabzug: Float { - from 1985-01-01 = 0.0935 - from 1986-01-01 = 0.096 - from 1987-01-01 = 0.0935 + from 1985-01-01 = 0.0935; + from 1986-01-01 = 0.096; + from 1987-01-01 = 0.0935; # Reference: Art. 1 G. v. 25.07.1988 BGBl. I S. 1093 - from 1989-01-01 = 0.12 + from 1989-01-01 = 0.12; # Reference: Art. 1 G. v. 21.12.1993 BGBl. I S. 2310. - from 1994-01-01 = 0.16 + from 1994-01-01 = 0.16; } /** @@ -427,10 +419,10 @@ public constant vorsorge2004KuerzungVorwegabzug: Float { */ public constant vorsorgeSonstigeAufwendungenMax: Int { # Reference: Art. 1 G. v. 05.07.2004 BGBl. I S.1427 - from 2005-01-01 = 1500 + from 2005-01-01 = 1500; # Reference: Art. 1 G. v. 23.07.2009 BGBl. I S.1959. - from 2010-01-01 = 1900 + from 2010-01-01 = 1900; } /** @@ -439,35 +431,35 @@ public constant vorsorgeSonstigeAufwendungenMax: Int { */ public constant vorsorgeAltersvorsorgeaufwendungenMax: Int { # Art. 1 G. v. 05.07.2004 BGBl. I S.1427 - from 2005-01-01 = 20000 + from 2005-01-01 = 20000; # Ab 2015 knappschaftlicher Höchstbetrag, d.h. knappschaftlicher Beitragssatz * # knappschaftliche Beitragsbemessungsgrenze - from 2015-01-01 = 22170 + from 2015-01-01 = 22170; # .248 * 91800 - from 2016-01-01 = 22766 + from 2016-01-01 = 22766; # .247 * 94200 - from 2017-01-01 = 23362 + from 2017-01-01 = 23362; # .247 * 96000 - from 2018-01-01 = 23712 + from 2018-01-01 = 23712; # .247 * 98400 - from 2019-01-01 = 24305 + from 2019-01-01 = 24305; # .247 * 101400 # Reference: Art. 3 V. v. 17.12.2019 BGBl I S. 2848. - from 2020-01-01 = 25046 + from 2020-01-01 = 25046; # .247 * 104400 # Reference: §3 V. v. 30.11.2020 BGBl. I S. 2612. - from 2021-01-01 = 25787 + from 2021-01-01 = 25787; # .247 * 103800 # Reference: §3 V. v. 30.11.2021, BGBl. I S. 5044. - from 2022-01-01 = 25640 + from 2022-01-01 = 25640; } /** @@ -477,7 +469,7 @@ public constant vorsorgeAltersvorsorgeaufwendungenMax: Int { */ public constant vorsorgeKrankenMinderung: Float { # Reference: Art. 1 G. v. 16.07.2009 BGBl. I S. 1959 - from 2009-07-23 = 0.04 + from 2009-07-23 = 0.04; } /** @@ -496,7 +488,7 @@ public constant behindertenPauschbetrag: Dict { 75: 1058, 85: 1227, 95: 1411 - } + }; # Reference: Art. 1 G. v. 19.12.2000 BGBl. I S. 1790. from 2002-01-01 = { @@ -509,7 +501,7 @@ public constant behindertenPauschbetrag: Dict { 75: 1060, 85: 1230, 95: 1420 - } + }; # Reference: Art. 1 G. v. 09.12.2020 BGBL. I S. 2770. from 2021-01-01 = { @@ -523,7 +515,7 @@ public constant behindertenPauschbetrag: Dict { 80: 2120, 90: 2460, 100: 2840 - } + }; } /** @@ -533,7 +525,7 @@ public constant behindertenPauschbetrag: Dict { */ public constant kinderbetreuungskostenAbzAnteil: Float { # Reference: Art. 1 G. v. 01.11.2011 BGBl. I S.2131 - from 2012-01-01 = 0.6666666 + from 2012-01-01 = 0.6666666; } /** @@ -542,7 +534,7 @@ public constant kinderbetreuungskostenAbzAnteil: Float { */ public constant kinderbetreuungskostenAbzMaximum: Int { # Reference: Art. 1 G. v. 01.11.2011 BGBl. I S.2131 - from 2012-01-01 = 4000 + from 2012-01-01 = 4000; } /** @@ -550,48 +542,48 @@ public constant kinderbetreuungskostenAbzMaximum: Int { * §10 (3) a) S.4 EStG */ public constant vorsorgepauschaleRentenversicherungsAnteil: Dict> { - 2005-01-01 = { + from 2005-01-01 = { 0: { - lower_threshold: -inf, - upper_threshold: 2005, - rate_linear: 0, - intercept_at_lower_threshold: 0.2 + "lower_threshold": -1e10, + "upper_threshold": 2005, + "rate_linear": 0, + "intercept_at_lower_threshold": 0.2 }, 1: { - lower_threshold: 2005, - upper_threshold: 2025, - rate_linear: 0.04, - intercept_at_lower_threshold: 0.2 + "lower_threshold": 2005, + "upper_threshold": 2025, + "rate_linear": 0.04, + "intercept_at_lower_threshold": 0.2 }, 2: { - lower_threshold: 2025, - upper_threshold: inf, - rate_linear: 0, - intercept_at_lower_threshold: 1 + "lower_threshold": 2025, + "upper_threshold": 1e10, + "rate_linear": 0, + "intercept_at_lower_threshold": 1 } - } + }; - 2023-01-01 = { + from 2023-01-01 = { 0: { - lower_threshold: -inf, - rate_linear: 0, - intercept_at_lower_threshold: 0.2 + "lower_threshold": -1e10, + "rate_linear": 0, + "intercept_at_lower_threshold": 0.2 }, 1: { - lower_threshold: 2005, - rate_linear: 0.04 + "lower_threshold": 2005, + "rate_linear": 0.04 }, 2: { - lower_threshold: 2022, - upper_threshold: 2023, - rate_linear: 0.12 + "lower_threshold": 2022, + "upper_threshold": 2023, + "rate_linear": 0.12 }, 3: { - lower_threshold: 2023, - upper_threshold: inf, - rate_linear: 0 + "lower_threshold": 2023, + "upper_threshold": 1e10, + "rate_linear": 0 } - } + }; } /** @@ -602,7 +594,7 @@ public constant vorsorgepauschaleRentenversicherungsAnteil: Dict { # Reference: Art. 1 G. v. 16.07.2009 BGBl. I S. 1959 from 2009-07-23 = { - steuerklasse_3: 3000, - steuerklasse_nicht3: 1900 - } + "steuerklasse_3": 3000, + "steuerklasse_nicht3": 1900 + }; } # TODO: rounding diff --git a/src/resources/builtins/parameters/gesetzlicheRente.ttsl b/src/resources/builtins/parameters/gesetzlicheRente.ttsl index 59d9aa04..499ba5b4 100644 --- a/src/resources/builtins/parameters/gesetzlicheRente.ttsl +++ b/src/resources/builtins/parameters/gesetzlicheRente.ttsl @@ -8,8 +8,8 @@ package gesetzlicheRente * Reference: §68 Abs. 4 S. 6 SGB VI */ public constant alpha: Float { - from 1984-01-01 = 0.0 - from 2002-01-01 = 0.25 + from 1984-01-01 = 0.0; + from 2002-01-01 = 0.25; } /** @@ -17,15 +17,15 @@ public constant alpha: Float { * Reference: §68 Abs. 5 SGB VI */ public constant altersVorsorgeAnteil: Float { - from 1993-01-01 = 0.0 - from 2002-01-01 = 0.5 - from 2003-01-01 = 1.0 - from 2004-01-01 = 1.5 - from 2005-01-01 = 2.0 - from 2009-01-01 = 2.5 - from 2010-01-01 = 3.0 - from 2011-01-01 = 3.5 - from 2012-01-01 = 4.0 + from 1993-01-01 = 0.0; + from 2002-01-01 = 0.5; + from 2003-01-01 = 1.0; + from 2004-01-01 = 1.5; + from 2005-01-01 = 2.0; + from 2009-01-01 = 2.5; + from 2010-01-01 = 3.0; + from 2011-01-01 = 3.5; + from 2012-01-01 = 4.0; } /** @@ -34,35 +34,35 @@ public constant altersVorsorgeAnteil: Float { * statistik-rente.de/drv */ public constant beitragsvolumen: Dict { - from 1991-01-01 = 108688000 - from 1992-01-01 = 117359000 - from 1993-01-01 = 120559000 - from 1994-01-01 = 132938000 - from 1995-01-01 = 139921000 - from 1996-01-01 = 146160000 - from 1997-01-01 = 153658000 - from 1998-01-01 = 153763000 - from 1999-01-01 = 160506000 - from 2000-01-01 = 163367000 - from 2001-01-01 = 164694000 - from 2002-01-01 = 165481000 - from 2003-01-01 = 169425000 - from 2004-01-01 = 169399000 - from 2005-01-01 = 168954000 - from 2006-01-01 = 180545000 - from 2007-01-01 = 174726000 - from 2008-01-01 = 180028000 - from 2009-01-01 = 181572000 - from 2010-01-01 = 185288000 - from 2011-01-01 = 189850000 - from 2012-01-01 = 193687000 - from 2013-01-01 = 194334000 - from 2014-01-01 = 201647000 - from 2015-01-01 = 207317000 - from 2016-01-01 = 215422000 - from 2017-01-01 = 225244000 - from 2018-01-01 = 236404000 - from 2019-01-01 = 247949000 + from 1991-01-01 = 108688000; + from 1992-01-01 = 117359000; + from 1993-01-01 = 120559000; + from 1994-01-01 = 132938000; + from 1995-01-01 = 139921000; + from 1996-01-01 = 146160000; + from 1997-01-01 = 153658000; + from 1998-01-01 = 153763000; + from 1999-01-01 = 160506000; + from 2000-01-01 = 163367000; + from 2001-01-01 = 164694000; + from 2002-01-01 = 165481000; + from 2003-01-01 = 169425000; + from 2004-01-01 = 169399000; + from 2005-01-01 = 168954000; + from 2006-01-01 = 180545000; + from 2007-01-01 = 174726000; + from 2008-01-01 = 180028000; + from 2009-01-01 = 181572000; + from 2010-01-01 = 185288000; + from 2011-01-01 = 189850000; + from 2012-01-01 = 193687000; + from 2013-01-01 = 194334000; + from 2014-01-01 = 201647000; + from 2015-01-01 = 207317000; + from 2016-01-01 = 215422000; + from 2017-01-01 = 225244000; + from 2018-01-01 = 236404000; + from 2019-01-01 = 247949000; } /** @@ -72,30 +72,30 @@ public constant beitragsvolumen: Dict { * Reference: § 154 Abs. 3 Satz 1 Nr. 2 SGB VI */ public constant eckrente: Float { - from 1995-01-01 = 988.15 - from 1996-01-01 = 992.72 - from 1997-01-01 = 1009.1 - from 1998-01-01 = 1012.47 - from 1999-01-01 = 1026.62 - from 2000-01-01 = 1032.79 - from 2001-01-01 = 1051.99 - from 2002-01-01 = 1072.35 - from 2003-01-01 = 1081.79 - from 2004-01-01 = 1071.79 - from 2005-01-01 = 1063.41 - from 2006-01-01 = 1066.35 - from 2007-01-01 = 1067.8 - from 2008-01-01 = 1077.02 - from 2009-01-01 = 1100.84 - from 2010-01-01 = 1102.67 - from 2011-01-01 = 1109.91 - from 2012-01-01 = 1134.15 - from 2013-01-01 = 1135.71 - from 2014-01-01 = 1154.68 - from 2015-01-01 = 1174.96 - from 2016-01-01 = 1222.09 - from 2017-01-01 = 1242.58 - from 2018-01-01 = 1284.06 + from 1995-01-01 = 988.15; + from 1996-01-01 = 992.72; + from 1997-01-01 = 1009.1; + from 1998-01-01 = 1012.47; + from 1999-01-01 = 1026.62; + from 2000-01-01 = 1032.79; + from 2001-01-01 = 1051.99; + from 2002-01-01 = 1072.35; + from 2003-01-01 = 1081.79; + from 2004-01-01 = 1071.79; + from 2005-01-01 = 1063.41; + from 2006-01-01 = 1066.35; + from 2007-01-01 = 1067.8; + from 2008-01-01 = 1077.02; + from 2009-01-01 = 1100.84; + from 2010-01-01 = 1102.67; + from 2011-01-01 = 1109.91; + from 2012-01-01 = 1134.15; + from 2013-01-01 = 1135.71; + from 2014-01-01 = 1154.68; + from 2015-01-01 = 1174.96; + from 2016-01-01 = 1222.09; + from 2017-01-01 = 1242.58; + from 2018-01-01 = 1284.06; } /** @@ -103,18 +103,18 @@ public constant eckrente: Float { * Durchschnittsbruttolohn aller Arbeitnehmer:innen in einem Jahr */ public constant durchschnittslohn: Float { - from 2005-01-01 = 28468.23 - from 2006-01-01 = 28673.22 - from 2007-01-01 = 28978.19 - from 2008-01-01 = 29262.71 - from 2009-01-01 = 29774.24 - from 2010-01-01 = 30086.57 - from 2011-01-01 = 30770.62 - from 2012-01-01 = 31452.49 - from 2013-01-01 = 31583.35 - from 2014-01-01 = 32313.66 - from 2015-01-01 = 33047.02 - from 2016-01-01 = 33608.42 + from 2005-01-01 = 28468.23; + from 2006-01-01 = 28673.22; + from 2007-01-01 = 28978.19; + from 2008-01-01 = 29262.71; + from 2009-01-01 = 29774.24; + from 2010-01-01 = 30086.57; + from 2011-01-01 = 30770.62; + from 2012-01-01 = 31452.49; + from 2013-01-01 = 31583.35; + from 2014-01-01 = 32313.66; + from 2015-01-01 = 33047.02; + from 2016-01-01 = 33608.42; } /** @@ -123,42 +123,42 @@ public constant durchschnittslohn: Float { * Dieses wird benötigt zur Berechnung der Entgeltpunkte. */ public constant beitragspflichtigesDurchschnittsentgelt: Int { - from 2005-01-01 = 29202 - from 2006-01-01 = 29494 - from 2007-01-01 = 29951 - from 2008-01-01 = 30625 - from 2009-01-01 = 30506 - from 2010-01-01 = 31144 - from 2011-01-01 = 32100 - from 2012-01-01 = 33002 - from 2013-01-01 = 33659 - from 2014-01-01 = 34514 - from 2015-01-01 = 35363 - from 2016-01-01 = 36187 - from 2017-01-01 = 37077 + from 2005-01-01 = 29202; + from 2006-01-01 = 29494; + from 2007-01-01 = 29951; + from 2008-01-01 = 30625; + from 2009-01-01 = 30506; + from 2010-01-01 = 31144; + from 2011-01-01 = 32100; + from 2012-01-01 = 33002; + from 2013-01-01 = 33659; + from 2014-01-01 = 34514; + from 2015-01-01 = 35363; + from 2016-01-01 = 36187; + from 2017-01-01 = 37077; # Reference: V. v. 17.12.2019 BGBl. I S. 2848. - from 2018-01-01 = 38212 + from 2018-01-01 = 38212; # Reference: V. v. 30.11.2020 BGBl. I S. 2612. - from 2019-01-01 = 39301 + from 2019-01-01 = 39301; # Reference: §1 V. v. 30.11.2021, BGBl. I S. 5044. - from 2020-01-01 = 39167 + from 2020-01-01 = 39167; # Reference: §3 V. v. 28.11.2022 BGBl. I S. 2128 (Nr. 47). - from 2021-01-01 = 40463 + from 2021-01-01 = 40463; # Reference: §3 V. v. 24.11.2023 BGBl. 2023 I Nr. 322 - from 2022-01-01 = 42053 + from 2022-01-01 = 42053; # Reference: §3 V. v. 28.11.2022 BGBl. 2022 I Nr. 2128 # Vorläufiges Durchschnittsentgelt - from 2023-01-01 = 43142 + from 2023-01-01 = 43142; # Reference: §3 V. v. 24.11.2023 BGBl. 2023 I Nr. 322 # Vorläufiges Durchschnittsentgelt - from 2024-01-01 = 45358 + from 2024-01-01 = 45358; } /** @@ -168,87 +168,87 @@ public constant beitragspflichtigesDurchschnittsentgelt: Int { * Reference: §256a SGB VI and Anlage 10 SGB VI */ public constant umrechnungEntgeltpBeitrittsgebiet: Float { - from 1945-01-01 = 1.0000 - from 1946-01-01 = 1.0000 - from 1947-01-01 = 1.0000 - from 1948-01-01 = 1.0000 - from 1949-01-01 = 1.0000 - from 1950-01-01 = 0.9931 - from 1951-01-01 = 1.0502 - from 1952-01-01 = 1.0617 - from 1953-01-01 = 1.0458 - from 1954-01-01 = 1.0185 - from 1955-01-01 = 1.0656 - from 1956-01-01 = 1.1029 - from 1957-01-01 = 1.1081 - from 1958-01-01 = 1.0992 - from 1959-01-01 = 1.0838 - from 1960-01-01 = 1.1451 - from 1961-01-01 = 1.2374 - from 1962-01-01 = 1.3156 - from 1963-01-01 = 1.3667 - from 1964-01-01 = 1.4568 - from 1965-01-01 = 1.5462 - from 1966-01-01 = 1.6018 - from 1967-01-01 = 1.5927 - from 1968-01-01 = 1.6405 - from 1969-01-01 = 1.7321 - from 1970-01-01 = 1.8875 - from 1971-01-01 = 2.0490 - from 1972-01-01 = 2.1705 - from 1973-01-01 = 2.3637 - from 1974-01-01 = 2.5451 - from 1975-01-01 = 2.6272 - from 1976-01-01 = 2.7344 - from 1977-01-01 = 2.8343 - from 1978-01-01 = 2.8923 - from 1979-01-01 = 2.9734 - from 1980-01-01 = 3.1208 - from 1981-01-01 = 3.1634 - from 1982-01-01 = 3.2147 - from 1983-01-01 = 3.2627 - from 1984-01-01 = 3.2885 - from 1985-01-01 = 3.3129 - from 1986-01-01 = 3.2968 - from 1987-01-01 = 3.2548 - from 1988-01-01 = 3.2381 - from 1989-01-01 = 3.2330 - from 1990-01-01 = 3.0707 - from 1990-06-01 = 2.3473 - from 1991-01-01 = 1.7235 - from 1992-01-01 = 1.4393 - from 1993-01-01 = 1.3197 - from 1994-01-01 = 1.2687 - from 1995-01-01 = 1.2317 - from 1996-01-01 = 1.2209 - from 1997-01-01 = 1.2089 - from 1998-01-01 = 1.2113 - from 1999-01-01 = 1.2054 - from 2000-01-01 = 1.2030 - from 2001-01-01 = 1.2003 - from 2002-01-01 = 1.1972 - from 2003-01-01 = 1.1943 - from 2004-01-01 = 1.1932 - from 2005-01-01 = 1.1827 - from 2006-01-01 = 1.1827 - from 2007-01-01 = 1.1841 - from 2008-01-01 = 1.1857 - from 2009-01-01 = 1.1712 - from 2010-01-01 = 1.1726 - from 2011-01-01 = 1.1740 - from 2012-01-01 = 1.1785 - from 2013-01-01 = 1.1762 - from 2014-01-01 = 1.1665 - from 2015-01-01 = 1.1502 - from 2016-01-01 = 1.1415 - from 2017-01-01 = 1.1374 - from 2018-01-01 = 1.1339 - from 2019-01-01 = 1.0840 - from 2020-01-01 = 1.0700 - from 2021-01-01 = 1.0560 - from 2022-01-01 = 1.0420 - from 2023-01-01 = 1.0280 - from 2024-01-01 = 1.0140 + from 1945-01-01 = 1.0000; + from 1946-01-01 = 1.0000; + from 1947-01-01 = 1.0000; + from 1948-01-01 = 1.0000; + from 1949-01-01 = 1.0000; + from 1950-01-01 = 0.9931; + from 1951-01-01 = 1.0502; + from 1952-01-01 = 1.0617; + from 1953-01-01 = 1.0458; + from 1954-01-01 = 1.0185; + from 1955-01-01 = 1.0656; + from 1956-01-01 = 1.1029; + from 1957-01-01 = 1.1081; + from 1958-01-01 = 1.0992; + from 1959-01-01 = 1.0838; + from 1960-01-01 = 1.1451; + from 1961-01-01 = 1.2374; + from 1962-01-01 = 1.3156; + from 1963-01-01 = 1.3667; + from 1964-01-01 = 1.4568; + from 1965-01-01 = 1.5462; + from 1966-01-01 = 1.6018; + from 1967-01-01 = 1.5927; + from 1968-01-01 = 1.6405; + from 1969-01-01 = 1.7321; + from 1970-01-01 = 1.8875; + from 1971-01-01 = 2.0490; + from 1972-01-01 = 2.1705; + from 1973-01-01 = 2.3637; + from 1974-01-01 = 2.5451; + from 1975-01-01 = 2.6272; + from 1976-01-01 = 2.7344; + from 1977-01-01 = 2.8343; + from 1978-01-01 = 2.8923; + from 1979-01-01 = 2.9734; + from 1980-01-01 = 3.1208; + from 1981-01-01 = 3.1634; + from 1982-01-01 = 3.2147; + from 1983-01-01 = 3.2627; + from 1984-01-01 = 3.2885; + from 1985-01-01 = 3.3129; + from 1986-01-01 = 3.2968; + from 1987-01-01 = 3.2548; + from 1988-01-01 = 3.2381; + from 1989-01-01 = 3.2330; + from 1990-01-01 = 3.0707; + from 1990-06-01 = 2.3473; + from 1991-01-01 = 1.7235; + from 1992-01-01 = 1.4393; + from 1993-01-01 = 1.3197; + from 1994-01-01 = 1.2687; + from 1995-01-01 = 1.2317; + from 1996-01-01 = 1.2209; + from 1997-01-01 = 1.2089; + from 1998-01-01 = 1.2113; + from 1999-01-01 = 1.2054; + from 2000-01-01 = 1.2030; + from 2001-01-01 = 1.2003; + from 2002-01-01 = 1.1972; + from 2003-01-01 = 1.1943; + from 2004-01-01 = 1.1932; + from 2005-01-01 = 1.1827; + from 2006-01-01 = 1.1827; + from 2007-01-01 = 1.1841; + from 2008-01-01 = 1.1857; + from 2009-01-01 = 1.1712; + from 2010-01-01 = 1.1726; + from 2011-01-01 = 1.1740; + from 2012-01-01 = 1.1785; + from 2013-01-01 = 1.1762; + from 2014-01-01 = 1.1665; + from 2015-01-01 = 1.1502; + from 2016-01-01 = 1.1415; + from 2017-01-01 = 1.1374; + from 2018-01-01 = 1.1339; + from 2019-01-01 = 1.0840; + from 2020-01-01 = 1.0700; + from 2021-01-01 = 1.0560; + from 2022-01-01 = 1.0420; + from 2023-01-01 = 1.0280; + from 2024-01-01 = 1.0140; } /** @@ -256,35 +256,35 @@ public constant umrechnungEntgeltpBeitrittsgebiet: Float { * Gesamtvolumen der ausgezahlten Renten */ public constant gesamtesRentenvolumen: Int { - from 1991-01-01 = 117912000 - from 1992-01-01 = 130901000 - from 1993-01-01 = 141180000 - from 1994-01-01 = 152798000 - from 1995-01-01 = 162625000 - from 1996-01-01 = 168955000 - from 1997-01-01 = 174479000 - from 1998-01-01 = 180323800 - from 1999-01-01 = 184139000 - from 2000-01-01 = 190198000 - from 2001-01-01 = 195776000 - from 2002-01-01 = 202355000 - from 2003-01-01 = 207749000 - from 2004-01-01 = 210522000 - from 2005-01-01 = 211861000 - from 2006-01-01 = 212421000 - from 2007-01-01 = 213649000 - from 2008-01-01 = 216182000 - from 2009-01-01 = 220841000 - from 2010-01-01 = 224352000 - from 2011-01-01 = 225411000 - from 2012-01-01 = 229231000 - from 2013-01-01 = 232297000 - from 2014-01-01 = 238991000 - from 2015-01-01 = 249568000 - from 2016-01-01 = 259345000 - from 2017-01-01 = 286860000 - from 2018-01-01 = 277102000 - from 2019-01-01 = 291359000 + from 1991-01-01 = 117912000; + from 1992-01-01 = 130901000; + from 1993-01-01 = 141180000; + from 1994-01-01 = 152798000; + from 1995-01-01 = 162625000; + from 1996-01-01 = 168955000; + from 1997-01-01 = 174479000; + from 1998-01-01 = 180323800; + from 1999-01-01 = 184139000; + from 2000-01-01 = 190198000; + from 2001-01-01 = 195776000; + from 2002-01-01 = 202355000; + from 2003-01-01 = 207749000; + from 2004-01-01 = 210522000; + from 2005-01-01 = 211861000; + from 2006-01-01 = 212421000; + from 2007-01-01 = 213649000; + from 2008-01-01 = 216182000; + from 2009-01-01 = 220841000; + from 2010-01-01 = 224352000; + from 2011-01-01 = 225411000; + from 2012-01-01 = 229231000; + from 2013-01-01 = 232297000; + from 2014-01-01 = 238991000; + from 2015-01-01 = 249568000; + from 2016-01-01 = 259345000; + from 2017-01-01 = 286860000; + from 2018-01-01 = 277102000; + from 2019-01-01 = 291359000; } /** @@ -297,167 +297,167 @@ public constant rentenwert: Dict { from 1992-01-01 = { west: 21.19, ost: 12.05 - } + }; from 1992-07-01 = { west: 21.80, ost: 13.59 - } + }; from 1993-01-01 = { west: 21.80, # deviation_from: previous ost: 14.41 - } + }; from 1993-07-01 = { west: 22.75, ost: 16.45 - } + }; from 1994-01-01 = { west: 22.75, # deviation_from: previous ost: 17.05 - } + }; from 1994-07-01 = { west: 23.52, ost: 17.63 - } + }; from 1995-01-01 = { west: 23.52, # deviation_from: previous ost: 18.13 - } + }; from 1995-07-01 = { west: 23.64, ost: 18.58 - } + }; from 1996-01-01 = { west: 23.64, # deviation_from: previous ost: 19.39 - } + }; from 1996-07-01 = { west: 23.86, ost: 19.62 - } + }; from 1997-07-01 = { west: 24.26, ost: 20.71 - } + }; from 1998-07-01 = { west: 24.36, ost: 20.90 - } + }; from 1999-07-01 = { west: 24.69, ost: 21.48 - } + }; from 2000-07-01 = { west: 24.84, ost: 21.61 - } + }; from 2001-07-01 = { west: 25.31, ost: 22.06 - } + }; from 2002-07-01 = { west: 25.86, ost: 22.70 - } + }; from 2003-07-01 = { west: 26.13, ost: 22.97 - } + }; from 2007-07-01 = { west: 26.27, ost: 23.09 - } + }; from 2008-07-01 = { west: 26.56, ost: 23.34 - } + }; from 2009-07-01 = { west: 27.2, ost: 24.13 - } + }; from 2011-07-01 = { west: 27.47, ost: 24.37 - } + }; from 2012-07-01 = { west: 28.07, ost: 24.92 - } + }; from 2013-07-01 = { west: 28.14, ost: 25.74 - } + }; from 2014-07-01 = { west: 28.61, ost: 26.39 - } + }; from 2015-07-01 = { west: 29.21, ost: 27.05 - } + }; from 2016-07-01 = { west: 30.45, ost: 28.66 - } + }; from 2017-07-01 = { west: 31.03, ost: 29.69 - } + }; from 2018-07-01 = { west: 32.03, ost: 30.69 - } + }; from 2019-07-01 = { west: 33.05, ost: 31.89 - } + }; from 2020-07-01 = { west: 34.19, ost: 33.23 - } + }; from 2021-07-01 = { west: 34.19, # deviation_from: previous ost: 33.47 - } + }; from 2022-07-01 = { west: 36.02, ost: 36.52 - } + }; from 2023-07-01 = { west: 37.60, ost: 37.60 - } + }; } /** @@ -470,7 +470,7 @@ public constant grundrenteHöchstwert: Dict { from 2021-01-01 = { base: 0.0334, increment: 0.001389, - } + }; } /** @@ -479,7 +479,7 @@ public constant grundrenteHöchstwert: Dict { * Reference: § 77 Abs. 2 SGB VI */ public constant grundrenteZugangsfaktorMax: Int { - from 2021-01-01 = 1 + from 2021-01-01 = 1; } /** @@ -493,7 +493,7 @@ public constant grundrenteZeiten: Dict { from 2021-01-01 = { min: 396, max: 420, - } + }; } /** @@ -506,20 +506,20 @@ public constant grundrenteEinkommensanrechnungSingle: Dict { # Reference: §77 Abs. 2 Nr. 2 SGB VI from 2001-01-01 = { - vorzeitiger_renteneintritt: 0.036, - späterer_renteneintritt: 0.06, - } + "vorzeitiger_renteneintritt": 0.036, + "späterer_renteneintritt": 0.06, + }; } /** @@ -583,24 +583,24 @@ public constant zugangsfaktorVeraenderungProJahr: Dict { public constant regelaltersgrenze: Dict> { from 1984-01-01 = { 0: { - lower_threshold: -inf, - upper_threshold: 1946, - rate_linear: 0, - intercept_at_lower_threshold: 65, + "lower_threshold": -1e10, + "upper_threshold": 1946, + "rate_linear": 0, + "intercept_at_lower_threshold": 65, }, 1: { - upper_threshold: 1958, - rate_linear: 0.083333333, + "upper_threshold": 1958, + "rate_linear": 0.083333333, }, 2: { - upper_threshold: 1964, - rate_linear: 0.16666666, + "upper_threshold": 1964, + "rate_linear": 0.16666666, }, 3: { - upper_threshold: inf, - rate_linear: 0, + "upper_threshold": 1e10, + "rate_linear": 0, }, - } + }; } /** @@ -612,37 +612,37 @@ public constant regelaltersgrenze: Dict> { public constant altersgrenzeFrauen: Dict> { from 1980-01-01 = { 0: { - lower_threshold: -inf, - upper_threshold: 1939.916667, - rate_linear: 0, - intercept_at_lower_threshold: 60, + "lower_threshold": -1e10, + "upper_threshold": 1939.916667, + "rate_linear": 0, + "intercept_at_lower_threshold": 60, }, 1: { - upper_threshold: 1944.916666666, - rate_linear: 1, + "upper_threshold": 1944.916666666, + "rate_linear": 1, }, 2: { - upper_threshold: 1951.916666666, # 65 - rate_linear: 0, + "upper_threshold": 1951.916666666, # 65 + "rate_linear": 0, }, 3: { - upper_threshold: 1952, + "upper_threshold": 1952, # since 1952 abolished - regelaltersgrenze applies - jump in theshold by 6 month - rate_linear: 6, + "rate_linear": 6, }, 4: { - upper_threshold: 1958, - rate_linear: 0.083333333, + "upper_threshold": 1958, + "rate_linear": 0.083333333, }, 5: { - upper_threshold: 1964, - rate_linear: 0.16666666, + "upper_threshold": 1964, + "rate_linear": 0.16666666, }, 6: { - upper_threshold: inf, - rate_linear: 0, + "upper_threshold": 1e10, + "rate_linear": 0, }, - } + }; } /** @@ -654,20 +654,20 @@ public constant altersgrenzeFrauen: Dict> { public constant altersgrenzeFrauenVorzeitig: Dict> { from 1980-01-01 = { 0: { - lower_threshold: -inf, - upper_threshold: 1952, - rate_linear: 0, - intercept_at_lower_threshold: 60, + "lower_threshold": -1e10, + "upper_threshold": 1952, + "rate_linear": 0, + "intercept_at_lower_threshold": 60, }, 1: { - upper_threshold: 1953, - rate_linear: 7, + "upper_threshold": 1953, + "rate_linear": 7, }, 2: { - upper_threshold: inf, # 67 - rate_linear: 0, + "upper_threshold": 1e10, # 67 + "rate_linear": 0, }, - } + }; } /** @@ -676,7 +676,7 @@ public constant altersgrenzeFrauenVorzeitig: Dict> { * Reference: § 237a SGB VI */ public constant firstBirthyearWithoutRenteFrauen: Int { - from 1980-01-01 = 1952 + from 1980-01-01 = 1952; } /** @@ -687,7 +687,7 @@ public constant firstBirthyearWithoutRenteFrauen: Int { * Reference: § 237a SGB VI */ public constant renteFrauenPflichtbeitrag: Int { - from 1950-01-01 = 10 + from 1950-01-01 = 10; } /** @@ -697,15 +697,10 @@ public constant renteFrauenPflichtbeitrag: Int { * Reference: § 237 SGB VI */ public constant altersgrenzeArbeitslosigkeitAbschlagsfrei: Float or Dict> { - from 1980-01-01 = { - 0: { - scalar: 60.0, - }, - } + from 1980-01-01 = 60.0; + from 1992-01-01 = { - 0: { - scalar: 60.0, - }, + 0: 60.0, 1941: { 1: 60.083333, 2: 60.083333, @@ -874,11 +869,10 @@ public constant altersgrenzeArbeitslosigkeitAbschlagsfrei: Float or Dict>{ - from 1980-01-01 = 60.0 + from 1980-01-01 = 60.0; # Increase of early retirement age from 60 to 62 for birth cohort 1949-1952. # Reference: Rentenreformgesetz 1992. BGBl. I S. 2261 1989 § 41 from 1992-01-01 = { - max_birthyear_old_regime: 1948, - min_birthyear_new_regime: 1953, - entry_age_old_regime: 60.0, - entry_age_new_regime: 62.0, + "max_birthyear_old_regime": 1948, + "min_birthyear_new_regime": 1953, + "entry_age_old_regime": 60.0, + "entry_age_new_regime": 62.0, 1949: { 1: 60.083333, 2: 60.083333, @@ -1371,15 +1365,15 @@ public constant altersgrenzeArbeitslosigkeitVorzeitig: Float or Dict> { from 1984-01-01 = { 0: { - lower_threshold: -inf, - upper_threshold: 1936.916666666, - rate_linear: 0, - intercept_at_lower_threshold: 63, + "lower_threshold": -1e10, + "upper_threshold": 1936.916666666, + "rate_linear": 0, + "intercept_at_lower_threshold": 63, }, 1: { - upper_threshold: 1938.916666666, - rate_linear: 1, + "upper_threshold": 1938.916666666, + "rate_linear": 1, }, 2: { - upper_threshold: 1948.916666666, - rate_linear: 0, + "upper_threshold": 1948.916666666, + "rate_linear": 0, }, 3: { - upper_threshold: 1949.25, - rate_linear: 1, + "upper_threshold": 1949.25, + "rate_linear": 1, }, 4: { - upper_threshold: 1950, # 1950.91667 - rate_linear: 0, + "upper_threshold": 1950, # 1950.91667 + "rate_linear": 0, }, 5: { - upper_threshold: 1958, - rate_linear: 0.083333333, + "upper_threshold": 1958, + "rate_linear": 0.083333333, }, 6: { - upper_threshold: 1964, - rate_linear: 0.16666666, + "upper_threshold": 1964, + "rate_linear": 0.16666666, }, 7: { - upper_threshold: inf, - rate_linear: 0, + "upper_threshold": 1e10, + "rate_linear": 0, }, - } + }; } /** @@ -1611,7 +1605,7 @@ public constant altersgrenzeLangjährigVersicherteAbschlagsfrei: Dict> { from 2012-01-01 = { 0: { - lower_threshold: -inf, - upper_threshold: inf, - rate_linear: 0, - intercept_at_lower_threshold: 65, + "lower_threshold": -1e10, + "upper_threshold": 1e10, + "rate_linear": 0, + "intercept_at_lower_threshold": 65, }, - }, + }; + from 2014-07-01 = { 0: { - lower_threshold: -inf, - upper_threshold: 1949.5, - rate_linear: 0, - intercept_at_lower_threshold: 65, + "lower_threshold": -1e10, + "upper_threshold": 1949.5, + "rate_linear": 0, + "intercept_at_lower_threshold": 65, }, 1: { - upper_threshold: 1951.5, - rate_linear: -1, + "upper_threshold": 1951.5, + "rate_linear": -1, }, 2: { - upper_threshold: 1952, - rate_linear: 0, + "upper_threshold": 1952, + "rate_linear": 0, }, 3: { - upper_threshold: 1964, - rate_linear: 0.16666666, + "upper_threshold": 1964, + "rate_linear": 0.16666666, }, 4: { - upper_threshold: inf, - rate_linear: 0, + "upper_threshold": 1e10, + "rate_linear": 0, } - } + }; } /** @@ -1672,7 +1667,7 @@ public constant altersgrenzeBesondersLangjährigVersicherte: Dict { from 1984-01-01 = { - mit_bedingungen: 27 - ohne_bedingungen: 18 - } + "mit_bedingungen": 27, + "ohne_bedingungen": 18 + }; # Reference: Art. 1 G. v. 19.07.2006 BGBl I S. 1652 from 2007-01-01 = { - mit_bedingungen: 25 - ohne_bedingungen: 18 - } + "mit_bedingungen": 25, + "ohne_bedingungen": 18 + }; } /** @@ -29,175 +29,175 @@ public constant altersgrenze: Dict { */ public constant kindergeld: Dict { from 1975-01-01 = { - 1: 26 - 2: 36 - 3: 61 - 4: 61 - } + 1: 26, + 2: 36, + 3: 61, + 4: 61, + }; from 1978-01-01 = { - 1: 26 - 2: 41 - 3: 77 - 4: 77 - } + 1: 26, + 2: 41, + 3: 77, + 4: 77, + }; from 1979-01-01 = { - 1: 26 - 2: 51 - 3: 102 - 4: 102 - } + 1: 26, + 2: 51, + 3: 102, + 4: 102, + }; from 1979-07-01 = { - 1: 26 - 2: 61 - 3: 102 - 4: 102 - } + 1: 26, + 2: 61, + 3: 102, + 4: 102, + }; from 1981-02-01 = { - 1: 26 - 2: 61 - 3: 123 - 4: 123 - } + 1: 26, + 2: 61, + 3: 123, + 4: 123, + }; from 1982-01-01 = { - 1: 26 - 2: 51 - 3: 112 - 4: 123 - } + 1: 26, + 2: 51, + 3: 112, + 4: 123, + }; from 1990-07-01 = { - 1: 26 - 2: 66 - 3: 112 - 4: 123 - } + 1: 26, + 2: 66, + 3: 112, + 4: 123, + }; from 1992-01-01 = { - 1: 36 - 2: 66 - 3: 112 - 4: 123 - } + 1: 36, + 2: 66, + 3: 112, + 4: 123, + }; from 1996-01-01 = { - 1: 102 - 2: 102 - 3: 153 - 4: 179 - } + 1: 102, + 2: 102, + 3: 153, + 4: 179, + }; from 1997-01-01 = { - 1: 112 - 2: 112 - 3: 153 - 4: 179 - } + 1: 112, + 2: 112, + 3: 153, + 4: 179, + }; from 1999-01-01 = { - 1: 128 - 2: 128 - 3: 153 - 4: 179 - } + 1: 128, + 2: 128, + 3: 153, + 4: 179, + }; from 2000-01-01 = { - 1: 138 - 2: 138 - 3: 153 - 4: 179 - } + 1: 138, + 2: 138, + 3: 153, + 4: 179, + }; from 2002-01-01 = { - 1: 154 - 2: 154 - 3: 154 - 4: 179 - } + 1: 154, + 2: 154, + 3: 154, + 4: 179, + }; # Reference: Art. 1 G. v. 22.12.2008 BGBl. I S. 2955 from 2009-01-01 = { - 1: 164 - 2: 164 - 3: 170 - 4: 195 - } + 1: 164, + 2: 164, + 3: 170, + 4: 195, + }; # Reference: Art. 1 G. v. 02.03.2009 BGBl. I S. 416 from 2009-03-01 = { - 1: 164 - 2: 164 - 3: 170 - 4: 195 - } + 1: 164, + 2: 164, + 3: 170, + 4: 195, + }; # Reference: Art. 1 G. v. 22.12.2009 BGBl. I S. 3950 from 2009-12-01 = { - 1: 184 - 2: 184 - 3: 190 - 4: 215 - } + 1: 184, + 2: 184, + 3: 190, + 4: 215, + }; # Reference: Art. 1 G. v. 16.07.2015 BGBl. I S. 1202 from 2015-07-01 = { - 1: 188 - 2: 188 - 3: 194 - 4: 219 - } + 1: 188, + 2: 188, + 3: 194, + 4: 219, + }; # Reference: Art. 2 G. v. 16.07.2015 BGBl. I S. 1202 from 2016-01-01 = { - 1: 190 - 2: 190 - 3: 196 - 4: 221 - } + 1: 190, + 2: 190, + 3: 196, + 4: 221, + }; # Reference: Art. 8 G. v. 20.12.2016 BGBl. I S. 3000 from 2017-01-01 = { - 1: 192 - 2: 192 - 3: 198 - 4: 223 - } + 1: 192, + 2: 192, + 3: 198, + 4: 223, + }; # Reference: Art. 9 G. v. 20.12.2016 BGBl. I S. 3000. from 2018-01-01 = { - 1: 194 - 2: 194 - 3: 200 - 4: 225 - } + 1: 194, + 2: 194, + 3: 200, + 4: 225, + }; # Reference: Art. 2 G. v. 29.11.2018 BGBl. I S. 2210. from 2019-07-01 = { - 1: 204 - 2: 204 - 3: 210 - 4: 235 - } + 1: 204, + 2: 204, + 3: 210, + 4: 235, + }; # Reference: Art. 1 Abs. 9 G. v. 01.12.2020 BGBl. I S. 2616. from 2021-01-01 = { - 1: 219 - 2: 219 - 3: 225 - 4: 250 - } + 1: 219, + 2: 219, + 3: 225, + 4: 250, + }; # Reference: Art. 6 G. v. 08.12.2022 BGBl. I S. 2230. from 2023-01-01 = { - 1: 250 - 2: 250 - 3: 250 - 4: 250 - } + 1: 250, + 2: 250, + 3: 250, + 4: 250, + }; } /** @@ -206,24 +206,24 @@ public constant kindergeld: Dict { * reference period: Year */ public constant einkommensgrenze: Int { - from 1984-01-01 = 0 + from 1984-01-01 = 0; # Reference: Art. 1 G. v. 11.10.1995 BGBl. I S. 1250 - from 1996-01-01 = 6136 + from 1996-01-01 = 6136; - from 1999-01-01 = 6657 + from 1999-01-01 = 6657; - from 2000-01-01 = 6902 + from 2000-01-01 = 6902; - from 2001-01-01 = 7179 + from 2001-01-01 = 7179; # Reference: Art. 1 G. v. 16.08.2001 BGBl. I S. 2074 - from 2002-01-01 = 7188 + from 2002-01-01 = 7188; - from 2004-01-01 = 7680 + from 2004-01-01 = 7680; # Reference: Art. 1 G. v. 16.07.2009 BGBl. I S. 1959 - from 2009-01-01 = 8004 + from 2009-01-01 = 8004; } /** @@ -234,7 +234,7 @@ public constant einkommensgrenze: Int { */ public constant stundengrenze: Int { # Reference: Art. 1 G. v. 01.11.2011 BGBl. I S. 2131 - from 2012-01-01 = 20 + from 2012-01-01 = 20; } /** @@ -244,14 +244,14 @@ public constant stundengrenze: Int { * reference period: Year */ public constant kinderbonus: Dict { - from 1984-01-01 = 0 + from 1984-01-01 = 0; # Reference: Art. 1 Zweites Corona-Steuerhilfegesetz v. 29.06.2020 BGBl. I S. 1512 - from 2020-01-01 = 300 + from 2020-01-01 = 300; # Reference: Art. 1 Drittes Corona-Steuerhilfegesetz v. 10.03.2021 BGBl. I S. 330 - from 2021-01-01 = 150 + from 2021-01-01 = 150; # only one-time payment - from 2022-01-01 = 0 + from 2022-01-01 = 0; } diff --git a/src/resources/builtins/parameters/kinderzuschlag.ttsl b/src/resources/builtins/parameters/kinderzuschlag.ttsl index 1c16d217..251ca303 100644 --- a/src/resources/builtins/parameters/kinderzuschlag.ttsl +++ b/src/resources/builtins/parameters/kinderzuschlag.ttsl @@ -1,4 +1,4 @@ -package kidnerzuschlag +package kinderzuschlag /** * Maximale Höhe des Kinderzuschlags @@ -6,46 +6,46 @@ package kidnerzuschlag */ constant maximum: Int { # Reference: Art. 46 G. v. 24.12.2003 BGBl. I S. 2954. - from 2005-01-01 = 140 + from 2005-01-01 = 140; # Reference: Art. 12 G. v. 20.12.2016 BGBl. I S. 3000. - from 2017-01-01 = 170 + from 2017-01-01 = 170; # Reference: Art. 1 G. v. 29.04.2019 BGBl. I S. 530. # Note: For 2020, Art. 2 Nr. 4 G. v. 29.04.2019 BGBl. I S. 530. - from 2019-07-01 = 185 + from 2019-07-01 = 185; # Reference: § 6a (2) BKGG # Note: Ab 2021 wird der Betrag aus anderen Parametern berechnet. - from 2021-01-01 = null + from 2021-01-01 = null; # Reference: Art. 6 G. v. 08.12.2022 BGBl. I S. 2230. # Note: Regelung für das Kalenderjahr 2023, abweichend von § 6a Absatz 2. - from 2023-01-01 = 250 + from 2023-01-01 = 250; # Reference: § 6a (2) BKGG # Note: Ab 2024 wird der Betrag wieder aus anderen Parametern berechnet. - from 2024-01-01 = null + from 2024-01-01 = null; # No law, should be calculated from other parameters (as 2021/2022), # but parameters are not known yet. - from 2024-01-01 = 292 + from 2024-01-01 = 292; } /** * Kindersofortzuschlag für Kinderzuschlag * With the introduction of the immediate supplement from July 1, 2022, - * the maximum amount in the child supplement increases by 20 euros. + * the maximum amount in the "child" supplement increases by 20 euros. * § 6a Abs. 2 Satz 4 BKGG */ constant kindersofortzuschl: Int { # Reference: § 6a Abs. 2 Satz 4 BKGG - from 2022-07-01 = 20 + from 2022-07-01 = 20; # Included in maximum Kinderzuschlag since 2023. - from 2023-01-01 = null + from 2023-01-01 = null; - from 2024-01-01 = 20 + from 2024-01-01 = 20; } /** @@ -54,10 +54,10 @@ constant kindersofortzuschl: Int { */ constant min_eink_paare: Int { # Reference: kein expliziter Wert im Gesetz. - from 2005-01-01 = 0 + from 2005-01-01 = 0; # Reference: Art. 1 G. v. 24.09.2008 BGBl. I S. 1854. - from 2008-10-01 = 900 + from 2008-10-01 = 900; } /** @@ -66,10 +66,10 @@ constant min_eink_paare: Int { */ constant min_eink_alleinerz: Int { # Reference: kein expliziter Wert im Gesetz. - from 2005-01-01 = 0 + from 2005-01-01 = 0; # Reference: Art. 1 G. v. 24.09.2008 BGBl. I S. 1854. - from 2008-10-01 = 600 + from 2008-10-01 = 600; } /** @@ -81,13 +81,13 @@ constant min_eink_alleinerz: Int { */ constant entzugsrate_eltern: Float { # Reference: Art. 46 G. v. 24.12.2003 BGBl. I. S. 2954. - from 2005-01-01 = 0.7 + from 2005-01-01 = 0.7; # Reference: Art. 1 G. v. 24.09.2008 BGBl. I S. 1854. - from 2008-10-01 = 0.5 + from 2008-10-01 = 0.5; # Reference: Art. 1 G. v. 29.04.2019 BGBl. I S. 530. - from 2020-01-01 = 0.45 + from 2020-01-01 = 0.45; } /** @@ -98,10 +98,10 @@ constant entzugsrate_eltern: Float { */ constant entzugsrate_kind: Float { # Reference: Art. 46 G. v. 24.12.2003 BGBl. I. S. 2954. - from 2005-01-01 = 1 + from 2005-01-01 = 1; # Reference: Art. 1 G. v. 29.04.2019 BGBl. I S. 530. - from 2019-07-01 = 0.45 + from 2019-07-01 = 0.45; } /** @@ -110,347 +110,346 @@ constant entzugsrate_kind: Float { * Berechnet für jeweils zwei Jahre die Höhe der steuerfrei zu stellenden * Existenzminima (nicht identisch mit dem steuerlichen Grundfreibetrag). */ -constant existenzminimum: Dict{ +constant existenzminimum: Dict>{ # Reference: 5. Existenzminimumsbericht, Bundestag Drucksache 15/2462, Übersicht 3 from 2005-01-01 = { - regelsatz: { - single: 4164 - paare: 7488 - kinder: 2688 - } - kosten_der_unterkunft: { - single: 2592 - paare: 3984 - kinder: 804 - } - heizkosten: { - single: 600 - paare: 768 - kinder: 156 - } - } + "regelsatz": { + "single": 4164, + "paare": 7488, + "kinder": 2688, + }, + "kosten_der_unterkunft": { + "single": 2592, + "paare": 3984, + "kinder": 804, + }, + "heizkosten": { + "single": 600, + "paare": 768, + "kinder": 156, + } + }; # Reference: 6. Existenzminimumsbericht, Bundestag Drucksache 16/3265, Übersicht 3 from 2008-01-01 = { - regelsatz: { - single: 4140 - paare: 7464 - kinder: 2676 - } - kosten_der_unterkunft: { - single: 2364 - paare: 4020 - kinder: 804 - } - heizkosten: { - single: 636 - paare: 792 - kinder: 168 - } - } + "regelsatz": { + "single": 4140, + "paare": 7464, + "kinder": 2676, + }, + "kosten_der_unterkunft": { + "single": 2364, + "paare": 4020, + "kinder": 804, + }, + "heizkosten": { + "single": 636, + "paare": 792, + "kinder": 168, + } + }; # Reference: 7. Existenzminimumsbericht, Bundestag Drucksache 16/11065, Übersicht 3 from 2010-01-01 = { - regelsatz: { - single: 4368 - paare: 7860 - kinder: 2820 - } - kosten_der_unterkunft: { - single: 2520 - paare: 4164 - kinder: 840 - } - heizkosten: { - single: 768 - paare: 972 - kinder: 204 - } - } + "regelsatz": { + "single": 4368, + "paare": 7860, + "kinder": 2820, + }, + "kosten_der_unterkunft": { + "single": 2520, + "paare": 4164, + "kinder": 840, + }, + "heizkosten": { + "single": 768, + "paare": 972, + "kinder": 204, + }, + }; # Reference: 8. Existenzminimumsbericht, Bundestag Drucksache 17/5550, Übersicht 4 from 2012-01-01 = { - regelsatz: { - single: 4488 - paare: 8064 - kinder: 2988 - } - bildung_und_teilhabe: { - kinder: 228 - } - kosten_der_unterkunft: { - single: 2724 - paare: 4344 - kinder: 876 - } - heizkosten: { - single: 684 - paare: 864 - kinder: 180 - } - } + "regelsatz": { + "single": 4488, + "paare": 8064, + "kinder": 2988, + }, + "bildung_und_teilhabe": { + "kinder": 228, + }, + "kosten_der_unterkunft": { + "single": 2724, + "paare": 4344, + "kinder": 876, + }, + "heizkosten": { + "single": 684, + "paare": 864, + "kinder": 180, + }, + }; # Reference: 9. Existenzminimumsbericht, Bundestag Drucksache 17/5550, Übersicht 5. Werte nur # für Singles anders from 2013-01-01 = { - regelsatz: { - single: 4584 - paare: 8064 - kinder: 2988 - } - bildung_und_teilhabe: { - kinder: 228 - } - kosten_der_unterkunft: { - single: 2796 - paare: 4344 - kinder: 876 - } - heizkosten: { - single: 744 - paare: 864 - kinder: 180 - } - } + "regelsatz": { + "single": 4584, + "paare": 8064, + "kinder": 2988, + }, + "bildung_und_teilhabe": { + "kinder": 228, + }, + "kosten_der_unterkunft": { + "single": 2796, + "paare": 4344, + "kinder": 876, + }, + "heizkosten": { + "single": 744, + "paare": 864, + "kinder": 180, + } + }; # Reference: 9. Existenzminimumsbericht, Bundestag Drucksache 17/5550, Übersicht 5. from 2014-01-01 = { - regelsatz: { - single: 4680 - paare: 8448 - kinder: 3096 - } - bildung_und_teilhabe: { - kinder: 228 - } - kosten_der_unterkunft: { - single: 2868 - paare: 4560 - kinder: 912 - } - heizkosten: { - single: 804 - paare: 1008 - kinder: 204 - } - } + "regelsatz": { + "single": 4680, + "paare": 8448, + "kinder": 3096, + }, + "bildung_und_teilhabe": { + "kinder": 228, + }, + "kosten_der_unterkunft": { + "single": 2868, + "paare": 4560, + "kinder": 912, + }, + "heizkosten": { + "single": 804, + "paare": 1008, + "kinder": 204, + } + }; # Reference: 10. Existenzminimumsbericht, Bundestag Drucksache 17/5550, # Übersicht 4. Werte für Paare unverändert. from 2015-01-01 = { - regelsatz: { - single: 4788 - paare: 8448 - kinder: 3168 - } - bildung_und_teilhabe: { - kinder: 228 - } - kosten_der_unterkunft: { - single: 2988 - paare: 4560 - kinder: 936 - } - heizkosten: { - single: 696 - paare: 1008 - kinder: 180 - } - } + "regelsatz": { + "single": 4788, + "paare": 8448, + "kinder": 3168, + }, + "bildung_und_teilhabe": { + "kinder": 228, + }, + "kosten_der_unterkunft": { + "single": 2988, + "paare": 4560, + "kinder": 936, + }, + "heizkosten": { + "single": 696, + "paare": 1008, + "kinder": 180, + } + }; # Reference: 10. Existenzminimumsbericht, Bundestag Drucksache 17/5550, Übersicht 4. from 2016-01-01 = { - regelsatz: { - single: 4872 - paare: 8784 - kinder: 3228 - } - bildung_und_teilhabe: { - kinder: 228 - } - kosten_der_unterkunft: { - single: 3060 - paare: 4788 - kinder: 960 - } - heizkosten: { - single: 720 - paare: 900 - kinder: 192 - } - } + "regelsatz": { + "single": 4872, + "paare": 8784, + "kinder": 3228, + }, + "bildung_und_teilhabe": { + "kinder": 228, + }, + "kosten_der_unterkunft": { + "single": 3060, + "paare": 4788, + "kinder": 960, + }, + "heizkosten": { + "single": 720, + "paare": 900, + "kinder": 192, + } + }; # Reference: 11. Existenzminimumsbericht, Bundestag Drucksache 18/10220, Übersicht 4. from 2017-01-01 = { - regelsatz: { - single: 4908 - paare: 8784 - kinder: 3336 - } - bildung_und_teilhabe: { - kinder: 228 - } - kosten_der_unterkunft: { - single: 3312 - paare: 4788 - kinder: 996 - } - heizkosten: { - single: 600 - paare: 900 - kinder: 156 - } - } + "regelsatz": { + "single": 4908, + "paare": 8784, + "kinder": 3336, + }, + "bildung_und_teilhabe": { + "kinder": 228, + }, + "kosten_der_unterkunft": { + "single": 3312, + "paare": 4788, + "kinder": 996, + }, + "heizkosten": { + "single": 600, + "paare": 900, + "kinder": 156, + } + }; # Reference: 11. Existenzminimumsbericht, Bundestag Drucksache 18/10220, Übersicht 4. from 2018-01-01 = { - regelsatz: { - single: 4968 - paare: 8952 - kinder: 3372 - } - bildung_und_teilhabe: { - kinder: 228 - } - kosten_der_unterkunft: { - single: 3396 - paare: 5088 - kinder: 1020 - } - heizkosten: { - single: 636 - paare: 816 - kinder: 168 - } - } + "regelsatz": { + "single": 4968, + "paare": 8952, + "kinder": 3372, + }, + "bildung_und_teilhabe": { + "kinder": 228, + }, + "kosten_der_unterkunft": { + "single": 3396, + "paare": 5088, + "kinder": 1020, + }, + "heizkosten": { + "single": 636, + "paare": 816, + "kinder": 168, + } + }; # Reference: 12. Existenzminimumsbericht, Bundestag Drucksache 19/5400, Übersicht 4. from 2019-01-01 = { - regelsatz: { - single: 5088 - paare: 8952 - kinder: 3456 - } - bildung_und_teilhabe: { - kinder: 228 - } - kosten_der_unterkunft: { - single: 3468 - paare: 5088 - kinder: 1044 - } - heizkosten: { - single: 612 - paare: 816 - kinder: 168 - } - } + "regelsatz": { + "single": 5088, + "paare": 8952, + "kinder": 3456, + }, + "bildung_und_teilhabe": { + "kinder": 228, + }, + "kosten_der_unterkunft": { + "single": 3468, + "paare": 5088, + "kinder": 1044, + }, + "heizkosten": { + "single": 612, + "paare": 816, + "kinder": 168, + } + }; # Reference: 12. Existenzminimumsbericht, Bundestag Drucksache 19/5400, Übersicht 4. from 2020-01-01 = { - regelsatz: { - single: 5196 - paare: 9360 - kinder: 3528 - } - bildung_und_teilhabe: { - kinder: 228 - } - kosten_der_unterkunft: { - single: 3552 - paare: 5328 - kinder: 1068 - } - heizkosten: { - single: 660 - paare: 852 - kinder: 180 - } - } + "regelsatz": { + "single": 5196, + "paare": 9360, + "kinder": 3528, + }, + "bildung_und_teilhabe": { + "kinder": 228, + }, + "kosten_der_unterkunft": { + "single": 3552, + "paare": 5328, + "kinder": 1068, + }, + "heizkosten": { + "single": 660, + "paare": 852, + "kinder": 180, + } + }; # Reference: 13. Existenzminimumsbericht, Bundestag Drucksache 19/22800, Übersicht 4. from 2021-01-01 = { - regelsatz: { - single: 5352 - paare: 9360 - kinder: 3780 - } - bildung_und_teilhabe: { - kinder: 324 - } - kosten_der_unterkunft: { - single: 3612 - paare: 5328 - kinder: 1092 - } - heizkosten: { - single: 780 - paare: 852 - kinder: 216 - } - } + "regelsatz": { + "single": 5352, + "paare": 9360, + "kinder": 3780, + }, + "bildung_und_teilhabe": { + "kinder": 324, + }, + "kosten_der_unterkunft": { + "single": 3612, + "paare": 5328, + "kinder": 1092, + }, + "heizkosten": { + "single": 780, + "paare": 852, + "kinder": 216, + } + }; # Reference: 13. Existenzminimumsbericht, Bundestag Drucksache 19/22800, Übersicht 4. from 2022-01-01 = { - regelsatz: { - single: 5400 - paare: 9720 - kinder: 3816 - } - bildung_und_teilhabe: { - kinder: 324 - } - kosten_der_unterkunft: { - single: 3684 - paare: 5520 - kinder: 1104 - } - heizkosten: { - single: 804 - paare: 1080 - kinder: 216 - } - } + "regelsatz": { + "single": 5400, + "paare": 9720, + "kinder": 3816, + }, + "bildung_und_teilhabe": { + "kinder": 324, + }, + "kosten_der_unterkunft": { + "single": 3684, + "paare": 5520, + "kinder": 1104, + }, + "heizkosten": { + "single": 804, + "paare": 1080, + "kinder": 216, + } + }; # Reference: 14. Existenzminimumsbericht, Bundestag Drucksache 20/4443, Übersicht 4. from 2023-01-01 = { - deviation_from: previous - regelsatz: { - single: 6024 - kinder: 4248 - } - bildung_und_teilhabe: { - kinder: 336 - } - kosten_der_unterkunft: { - single: 3828 - kinder: 1152 - } - heizkosten: { - single: 1056 - kinder: 288 - } - } + "regelsatz": { + "single": 6024, + "kinder": 4248, + }, + "bildung_und_teilhabe": { + "kinder": 336, + }, + "kosten_der_unterkunft": { + "single": 3828, + "kinder": 1152, + }, + "heizkosten": { + "single": 1056, + "kinder": 288, + }, + }; # Reference: 14. Existenzminimumsbericht, Bundestag Drucksache 20/4443, Übersicht 4. from 2024-01-01 = { - regelsatz: { - single: 6444 - paare: 11592 - kinder: 4548 - } - bildung_und_teilhabe: { - kinder: 336 - } - kosten_der_unterkunft: { - single: 3924 - paare: 5892 - kinder: 1188 - } - heizkosten: { - single: 1104 - paare: 1500 - kinder: 312 - } - } + "regelsatz": { + "single": 6444, + "paare": 11592, + "kinder": 4548, + }, + "bildung_und_teilhabe": { + "kinder": 336, + }, + "kosten_der_unterkunft": { + "single": 3924, + "paare": 5892, + "kinder": 1188, + }, + "heizkosten": { + "single": 1104, + "paare": 1500, + "kinder": 312, + } + }; } diff --git a/src/resources/builtins/parameters/kinderzuschlagEinkommen.ttsl b/src/resources/builtins/parameters/kinderzuschlagEinkommen.ttsl index 362ef59c..c978fc8b 100644 --- a/src/resources/builtins/parameters/kinderzuschlagEinkommen.ttsl +++ b/src/resources/builtins/parameters/kinderzuschlagEinkommen.ttsl @@ -2,17 +2,17 @@ package kidnerzuschlagEinkommen # TODO: rounding ---- -rounding: - kinderzuschl_eink_eltern_m: - 2005-01-01: - base: 10 - direction: down - reference: § 6a Abs. 4 BKGG - note: - en: Rounding changed via BGBl. I S. 530 StaFamG Artikel 1 - 2019-07-01: - base: 1 - direction: nearest - reference: § 11 Abs. 2 BKGG +# --- +# rounding: +# kinderzuschl_eink_eltern_m: +# 2005-01-01: +# base: 10 +# direction: down +# reference: § 6a Abs. 4 BKGG +# note: +# en: Rounding changed via BGBl. I S. 530 StaFamG Artikel 1 +# 2019-07-01: +# base: 1 +# direction: nearest +# reference: § 11 Abs. 2 BKGG diff --git a/src/resources/builtins/parameters/lohnsteuer.ttsl b/src/resources/builtins/parameters/lohnsteuer.ttsl index 9890cf62..99e722b9 100644 --- a/src/resources/builtins/parameters/lohnsteuer.ttsl +++ b/src/resources/builtins/parameters/lohnsteuer.ttsl @@ -7,95 +7,95 @@ package lohnsteuer * Referenz: § 39b Absatz 2 Satz 7 EStG */ public constant lohnsteuerEinkommensgrenzen: Dict { - from 2002-01-01 { + from 2002-01-01 = { 0: 8946, 1: 27306, 2: 10000000, - } + }; - from 2004-01-01 { + from 2004-01-01 = { 0: 9228, 1: 26072, 2: 10000000, - } + }; - from 2005-01-01 { + from 2005-01-01 = { 0: 9144, 1: 25812, 2: 200000, - } + }; - from 2009-01-01 { + from 2009-01-01 = { 0: 9225, 1: 26276, 2: 200320, - } + }; - from 2010-01-01 { + from 2010-01-01 = { 0: 9429, 1: 26441, 2: 200584, - } + }; - from 2013-01-01 { + from 2013-01-01 = { 0: 9550, 1: 26441, 2: 200584, - } + }; - from 2014-01-01 { + from 2014-01-01 = { 0: 9763, 1: 26441, 2: 200584, - } + }; - from 2016-01-01 { + from 2016-01-01 = { 0: 10070, 1: 26832, 2: 203557, - } + }; - from 2017-01-01 { + from 2017-01-01 = { 0: 10240, 1: 27029, 2: 205043, - } + }; - from 2018-01-01 { + from 2018-01-01 = { 0: 10440, 1: 27475, 2: 208426, - } + }; - from 2019-01-01 { + from 2019-01-01 = { 0: 10635, 1: 27980, 2: 212261, - } + }; - from 2020-01-01 { + from 2020-01-01 = { 0: 10898, 1: 28526, 2: 216400, - } + }; - from 2021-01-01 { + from 2021-01-01 = { 0: 11237, 1: 28959, 2: 219690, - } + }; - from 2022-01-01 { + from 2022-01-01 = { 0: 11793, 1: 29298, 2: 222260, - } + }; - from 2023-01-01 { + from 2023-01-01 = { 0: 12485, 1: 31404, 2: 222260, - } + }; } # TODO: rounding diff --git a/src/resources/builtins/parameters/solidaritaetszuschlag.ttsl b/src/resources/builtins/parameters/solidaritaetszuschlag.ttsl index 328afa9b..b4586989 100644 --- a/src/resources/builtins/parameters/solidaritaetszuschlag.ttsl +++ b/src/resources/builtins/parameters/solidaritaetszuschlag.ttsl @@ -7,120 +7,120 @@ package solidaritaetszuschlag */ public constant solidaritaetszuschlag: Dict> { # Reference: Artikel 1 G. v. 24.06.1991 BGBl. I S. 1318. - from 1991-01-01 { + from 1991-01-01 = { 0: { - lower_threshold: -inf - rate: 0 - intercept_at_lower_threshold: 0 - upper_threshold: 0 + "lower_threshold": -1e10, + "rate": 0, + "intercept_at_lower_threshold": 0, + "upper_threshold": 0 }, 1: { - lower_threshold: 0 - rate: 0.0375 - upper_threshold: inf + "lower_threshold": 0, + "rate": 0.0375, + "upper_threshold": 1e10 } - } + }; - from 1993-01-01 { + from 1993-01-01 = { 0: { - lower_threshold: -inf - rate: 0 - intercept_at_lower_threshold: 0 - upper_threshold: inf + "lower_threshold": -1e10, + "rate": 0, + "intercept_at_lower_threshold": 0, + "upper_threshold": 1e10 } - } # TODO: BEISPIEL FÜR DEVIATION!!!! + }; # TODO: BEISPIEL FÜR DEVIATION!!!! # Reference: Artikel 31 G. v. 23.06.1993 BGBl. I S. 944. - from 1995-01-01 { + from 1995-01-01 = { 0: { - lower_threshold: -inf - intercept_at_lower_threshold: 0 - rate: 0 - upper_threshold: 681 + "lower_threshold": -1e10, + "intercept_at_lower_threshold": 0, + "rate": 0, + "upper_threshold": 681, }, 1: { - upper_threshold: 1089.6 - rate: 0.2 + "upper_threshold": 1089.6, + "rate": 0.2, }, 2: { - rate: 0.075 - upper_threshold: inf + "rate": 0.075, + "upper_threshold": 1e10, } - } + }; # Reference: Artikel 1 G. v. 21.11.1997 BGBl. I S. 2743. - from 1998-01-01 { + from 1998-01-01 = { 0: { - lower_threshold: -inf - upper_threshold: 939 - rate: 0 - intercept_at_lower_threshold: 0 + "lower_threshold": -1e10, + "upper_threshold": 939, + "rate": 0, + "intercept_at_lower_threshold": 0, }, 1: { - upper_threshold: 1295.17 - rate: 0.2 + "upper_threshold": 1295.17, + "rate": 0.2, }, 2: { - rate: 0.055 - upper_threshold: inf + "rate": 0.055, + "upper_threshold": 1e10, } - } + }; # Reference: G. v. 15.10.2002 BGBl. I S. 4131. - from 2002-01-01 { + from 2002-01-01 = { 0: { - lower_threshold: -inf - upper_threshold: 972 - rate: 0 - intercept_at_lower_threshold: 0 + "lower_threshold": -1e10, + "upper_threshold": 972, + "rate": 0, + "intercept_at_lower_threshold": 0, }, 1: { - upper_threshold: 1340.69 - rate: 0.2 + "upper_threshold": 1340.69, + "rate": 0.2, }, 2: { - rate: 0.055 - upper_threshold: inf + "rate": 0.055, + "upper_threshold": 1e10, } - } + }; # Reference: Artikel 1 G. v. 10.12.2019 BGBl. I S. 2115. - from 2021-01-01 { + from 2021-01-01 = { 0: { - lower_threshold: -inf - upper_threshold: 16956 - rate: 0 - intercept_at_lower_threshold: 0 + "lower_threshold": -1e10, + "upper_threshold": 16956, + "rate": 0, + "intercept_at_lower_threshold": 0, }, 1: { - upper_threshold: 31527.56 - rate: 0.119 + "upper_threshold": 31527.56, + "rate": 0.119, }, 2: { - rate: 0.055 - upper_threshold: inf + "rate": 0.055, + "upper_threshold": 1e10, } - } + }; # Reference: Art. 4 G. v. 08.12.2022 BGBl. I S. 2230. - from 2023-01-01 { + from 2023-01-01 = { # deviation_from: previous 0: { - upper_threshold: 17543 + "upper_threshold": 17543, }, 1: { - upper_threshold: 32619.02 + "upper_threshold": 32619.02, } - } + }; # Reference: Art. 5 G. v. 08.12.2022 BGBl. I S. 2230. - from 2024-01-01 { + from 2024-01-01 = { # deviation_from: previous 0: { - upper_threshold: 18130 + "upper_threshold": 18130, }, 1: { - upper_threshold: 33710.47 + "upper_threshold": 33710.47, } - } + }; } diff --git a/src/resources/builtins/parameters/sozialversicherungsbeitrag.ttsl b/src/resources/builtins/parameters/sozialversicherungsbeitrag.ttsl index c6e682ce..ca265a8f 100644 --- a/src/resources/builtins/parameters/sozialversicherungsbeitrag.ttsl +++ b/src/resources/builtins/parameters/sozialversicherungsbeitrag.ttsl @@ -4,10 +4,10 @@ package sozialversicherungsbeitrag * Beitragssätze zu den gesetzlichen Sozialversicherungen * * gesetzliche Krankenversicherung: - * Beitragssätze für gesetzliche Krankenversicherung. mean_allgemein - - * durchschnittlicher Beitragssatz, bis 2008 allgemein - allgemeiner Satz (§241 SGB - * V), ab 2009 sonderbeitrag - bezahlt von Arbeitnehmern, ab Jul 2005 bis 2014 - * ermäßigt - ermäßigter Satz (§243 SGB V) zusatz - durchschnittlicher + * Beitragssätze für gesetzliche Krankenversicherung. "mean_allgemein" - + * durchschnittlicher Beitragssatz, bis 2008 "allgemein" - allgemeiner Satz (§241 SGB + * V), ab 2009 "sonderbeitrag" - bezahlt von Arbeitnehmern, ab Jul 2005 bis 2014 + * "ermäßigt" - ermäßigter Satz (§243 SGB V) zusatz - durchschnittlicher * Zusatzbeitragssatz. * * gesetzliche Pflegeversicherung: @@ -16,7 +16,7 @@ package sozialversicherungsbeitrag * Versicherte, die das 23. Lebensjahr vollendet haben. Wird vom Arbeitnehmer * alleine getragen. Eingeführt 2005. * - * arbeitslosenversicherung: + * "arbeitslosenversicherung": * Beitragssätze zur Arbeitslosenversicherung für Arbeitnehmer. * * gesetzliche Rentenversicherung: @@ -25,343 +25,343 @@ package sozialversicherungsbeitrag * access_different_date: jahresanfang */ public constant beitragssatz: Dict> { - from 1984-01-01 { - gesetzlicheKrankenversicherung: { - mean_allgemein: 0.134 - } - gesetzlichePflegeversicherung: 0.0085 - arbeitslosenversicherung: 0.0325 - gesetzlicheRentenversicherung: 0.0975 - } - - from 1985-01-01 { - gesetzlicheKrankenversicherung: { - mean_allgemein: 0.118 - } - arbeitslosenversicherung: 0.022 - gesetzlicheRentenversicherung: 0.0935 - } - - from 1986-01-01 { - gesetzlicheKrankenversicherung: { - mean_allgemein: 0.122 - } - arbeitslosenversicherung: 0.0205 - gesetzlicheRentenversicherung: 0.096 - } - - from 1987-01-01 { - gesetzlicheKrankenversicherung: { - mean_allgemein: 0.1248 - } - arbeitslosenversicherung: 0.0215 - gesetzlicheRentenversicherung: 0.0935 - } - - from 1988-01-01 { + from 1984-01-01 = { + "gesetzlicheKrankenversicherung": { + "mean_allgemein": 0.134 + }, + "gesetzlichePflegeversicherung": 0.0085, + "arbeitslosenversicherung": 0.0325, + "gesetzlicheRentenversicherung": 0.0975, + }; + + from 1985-01-01 = { + "gesetzlicheKrankenversicherung": { + "mean_allgemein": 0.118, + }, + "arbeitslosenversicherung": 0.022, + "gesetzlicheRentenversicherung": 0.0935, + }; + + from 1986-01-01 = { + "gesetzlicheKrankenversicherung": { + "mean_allgemein": 0.122, + }, + "arbeitslosenversicherung": 0.0205, + "gesetzlicheRentenversicherung": 0.096, + }; + + from 1987-01-01 = { + "gesetzlicheKrankenversicherung": { + "mean_allgemein": 0.1248, + }; + "arbeitslosenversicherung": 0.0215, + "gesetzlicheRentenversicherung": 0.0935, + }; + + from 1988-01-01 = { # deviation_from: previous - gesetzlicheKrankenversicherung: { - mean_allgemein: 0.1288 - } - } + "gesetzlicheKrankenversicherung": { + "mean_allgemein": 0.1288, + }, + }; - from 1989-01-01 { + from 1989-01-01 = { # deviation_from: previous - gesetzlicheKrankenversicherung: { - mean_allgemein: 0.129 + "gesetzlicheKrankenversicherung": { + "mean_allgemein": 0.129, } - } + }; - from 1990-01-01 { + from 1990-01-01 = { # deviation_from: previous - gesetzlicheKrankenversicherung: { - mean_allgemein: 0.125 - } - } + "gesetzlicheKrankenversicherung": { + "mean_allgemein": 0.125, + }, + }; - from 1991-01-01 { + from 1991-01-01 = { # deviation_from: previous - gesetzlicheKrankenversicherung: { - mean_allgemein: .128 + "gesetzlicheKrankenversicherung": { + "mean_allgemein": .128, } - } + }; - from 1992-01-01 { + from 1992-01-01 = { # deviation_from: previous - arbeitslosenversicherung: 0.0315 - gesetzlicheRentenversicherung: 0.0885 - } - - from 1993-01-01 { - gesetzlicheKrankenversicherung: { - mean_allgemein: 0.134 - } - arbeitslosenversicherung: 0.0325 - gesetzlicheRentenversicherung: 0.0875 - } - - from 1994-01-01 { + "arbeitslosenversicherung": 0.0315, + "gesetzlicheRentenversicherung": 0.0885 + }; + + from 1993-01-01 = { + "gesetzlicheKrankenversicherung": { + "mean_allgemein": 0.134, + }, + "arbeitslosenversicherung": 0.0325, + "gesetzlicheRentenversicherung": 0.0875, + }; + + from 1994-01-01 = { # deviation_from: previous - gesetzlicheRentenversicherung: 0.096 - } - - from 1995-01-01 { - arbeitslosenversicherung: 0.0325 - gesetzlicheKrankenversicherung: { - mean_allgemein: 0.132 - } - gesetzlichePflegeversicherung: 0.005 - gesetzlicheRentenversicherung: 0.093 - } - - from 1996-01-01 { + "gesetzlicheRentenversicherung": 0.096 + }; + + from 1995-01-01 = { + "arbeitslosenversicherung": 0.0325, + "gesetzlicheKrankenversicherung": { + "mean_allgemein": 0.132, + }, + "gesetzlichePflegeversicherung": 0.005, + "gesetzlicheRentenversicherung": 0.093, + }; + + from 1996-01-01 = { # deviation_from: previous - gesetzlicheRentenversicherung: 0.096 - } - - from 1997-01-01 { - gesetzlicheKrankenversicherung: { - mean_allgemein: 0.134 - } - gesetzlichePflegeversicherung: 0.0085 - arbeitslosenversicherung: 0.0325 - gesetzlicheRentenversicherung: 0.1015 - } - - from 1998-01-01 { + "gesetzlicheRentenversicherung": 0.096, + }; + + from 1997-01-01 = { + "gesetzlicheKrankenversicherung": { + "mean_allgemein": 0.134, + }, + "gesetzlichePflegeversicherung": 0.0085, + "arbeitslosenversicherung": 0.0325, + "gesetzlicheRentenversicherung": 0.1015, + }; + + from 1998-01-01 = { # deviation_from: previous - gesetzlicheKrankenversicherung: { - mean_allgemein: 0.136 + "gesetzlicheKrankenversicherung": { + "mean_allgemein": 0.136 } - } + }; - from 2000-01-01 { + from 2000-01-01 = { # deviation_from: previous - gesetzlicheKrankenversicherung: { - mean_allgemein: 0.1357 - } - gesetzlicheRentenversicherung: 0.0965 - } + "gesetzlicheKrankenversicherung": { + "mean_allgemein": 0.1357, + }, + "gesetzlicheRentenversicherung": 0.0965, + }; - from 2001-01-01 { + from 2001-01-01 = { # deviation_from: previous - gesetzlicheKrankenversicherung: { - mean_allgemein: 0.1358 - } - gesetzlicheRentenversicherung: 0.0955 - } + "gesetzlicheKrankenversicherung": { + "mean_allgemein": 0.1358, + }, + "gesetzlicheRentenversicherung": 0.0955, + }; - from 2002-01-01 { + from 2002-01-01 = { # deviation_from: previous - gesetzlicheKrankenversicherung: { - mean_allgemein: 0.14 - } - } + "gesetzlicheKrankenversicherung": { + "mean_allgemein": 0.14, + }, + }; - from 2003-01-01 { + from 2003-01-01 = { # deviation_from: previous - gesetzlicheKrankenversicherung: { - mean_allgemein: 0.144 - } - gesetzlicheRentenversicherung: 0.0975 - } + "gesetzlicheKrankenversicherung": { + "mean_allgemein": 0.144, + }, + "gesetzlicheRentenversicherung": 0.0975, + }; - from 2004-01-01 { + from 2004-01-01 = { # deviation_from: previous - gesetzlicheKrankenversicherung: { - mean_allgemein: 0.142 - } - } - - from 2005-01-01 { - gesetzlicheKrankenversicherung: { - mean_allgemein: 0.142 - } - gesetzlichePflegeversicherung: { - standard: 0.0085 - zusatz_kinderlos: 0.0025 - } - arbeitslosenversicherung: 0.0325 - gesetzlicheRentenversicherung: 0.0975 - } + "gesetzlicheKrankenversicherung": { + "mean_allgemein": 0.142 + }, + }; + + from 2005-01-01 = { + "gesetzlicheKrankenversicherung": { + "mean_allgemein": 0.142, + }, + "gesetzlichePflegeversicherung": = { + standard: 0.0085, + zusatz_kinderlos: 0.0025, + }, + "arbeitslosenversicherung": 0.0325, + "gesetzlicheRentenversicherung": 0.0975, + }; # Allgemeiner Beitragssatz wird nicht mehr gleichmäßig aufgeteilt, Einführung des Sonderbeitrags # Reference: Art. 1 G. v. 15.12.2004, BGBl I S. 3445. - from 2005-07-01 { + from 2005-07-01 = { # deviation_from: previous - gesetzlicheKrankenversicherung: { - mean_allgemein: 0.133 - sonderbeitrag: 0.009 + "gesetzlicheKrankenversicherung": { + "mean_allgemein": 0.133, + "sonderbeitrag": 0.009, } - } + }; - from 2007-01-01 { + from 2007-01-01 = { # deviation_from: previous - gesetzlicheKrankenversicherung: { - mean_allgemein: 0.139 - } - arbeitslosenversicherung: 0.021 - gesetzlicheRentenversicherung: 0.0995 - } - - from 2008-01-01 { - gesetzlicheKrankenversicherung: { - mean_allgemein: 0.14 - sonderbeitrag: 0.009 - } - gesetzlichePflegeversicherung: { - standard: 0.00975 - zusatzKinderlos: 0.0025 - } - arbeitslosenversicherung: 0.016 - gesetzlicheRentenversicherung: 0.0995 - } - - from 2009-01-01 { + "gesetzlicheKrankenversicherung": { + "mean_allgemein": 0.139, + }, + "arbeitslosenversicherung": 0.021, + "gesetzlicheRentenversicherung": 0.0995, + }; + + from 2008-01-01 = { + "gesetzlicheKrankenversicherung": { + "mean_allgemein": 0.14, + "sonderbeitrag": 0.009, + }, + "gesetzlichePflegeversicherung": { + "standard": 0.00975, + "zusatzKinderlos": 0.0025, + }, + "arbeitslosenversicherung": 0.016, + "gesetzlicheRentenversicherung": 0.0995, + }; + + from 2009-01-01 = { # deviation_from: previous - gesetzlicheKrankenversicherung: { - allgemein: 0.146 - sonderbeitrag: 0.009 - ermäßigt: 0.140 - } - arbeitslosenversicherung: 0.014 - } - - from 2009-07-01 { + "gesetzlicheKrankenversicherung": { + "allgemein": 0.146, + "sonderbeitrag": 0.009, + "ermäßigt": 0.140, + }, + "arbeitslosenversicherung": 0.014, + }; + + from 2009-07-01 = { # deviation_from: previous - gesetzlicheKrankenversicherung: { - allgemein: 0.14 - ermäßigt: 0.134 - sonderbeitrag: 0.009 + "gesetzlicheKrankenversicherung": { + "allgemein": 0.14, + "ermäßigt": 0.134, + "sonderbeitrag": 0.009, } - } + }; # Reference: Art. 1 G. v. 22.12.2010 BGBl. I S. 2309 - from 2011-01-01 { + from 2011-01-01 = { # deviation_from: previous - gesetzlicheKrankenversicherung: { - allgemein: 0.146 - ermäßigt: 0.14 - } - arbeitslosenversicherung: 0.015 - } + "gesetzlicheKrankenversicherung": { + "allgemein": 0.146, + "ermäßigt": 0.14, + }, + "arbeitslosenversicherung": 0.015, + }; # Quelle: http:#www.bmas.de/DE/Service/Presse/Pressemitteilungen/rentenbericht-16-11-2011.html - from 2012-01-01 { + from 2012-01-01 = { # deviation_from: previous - gesetzlicheRentenversicherung: 0.098 - } + "gesetzlicheRentenversicherung": 0.098 + }; - from 2013-01-01 { + from 2013-01-01 = { # deviation_from: previous - gesetzlicheRentenversicherung: 0.0945 - gesetzlichePflegeversicherung: { - standard: 0.01025 - } - } + "gesetzlicheRentenversicherung": 0.0945, + "gesetzlichePflegeversicherung": { + standard: 0.01025, + }, + }; # Abschaffung Sonderbeitrag, Einführung kassenabhängiger Zusatzbeitrag - from 2015-01-01 { - gesetzlicheKrankenversicherung: { - allgemein: 0.146 - ermäßigt: 0.14 - meanZusatzbeitrag: 0.009 - } - gesetzlichePflegeversicherung: { - standard: 0.01175 - zusatzKinderlos: 0.0025 - } - arbeitslosenversicherung: 0.015 - gesetzlicheRentenversicherung: 0.0935 - } + from 2015-01-01 = { + "gesetzlicheKrankenversicherung": { + "allgemein": 0.146, + "ermäßigt": 0.14, + "meanZusatzbeitrag": 0.009, + }, + "gesetzlichePflegeversicherung": { + "standard": 0.01175, + "zusatzKinderlos": 0.0025, + }, + "arbeitslosenversicherung": 0.015, + "gesetzlicheRentenversicherung": 0.0935, + }; # Bekanntmachung Bundesanzeiger 30.12.2015 - from 2016-01-01 { + from 2016-01-01 = { # deviation_from: previous - gesetzlicheKrankenversicherung: { - meanZusatzbeitrag: 0.011 - } - } + "gesetzlicheKrankenversicherung": { + "meanZusatzbeitrag": 0.011 + }, + }; - from 2017-01-01 { + from 2017-01-01 = { # deviation_from: previous - gesetzlichePflegeversicherung: { - standard: 0.01275 - } - } + "gesetzlichePflegeversicherung": { + "standard": 0.01275, + }, + }; - from 2018-01-01 { + from 2018-01-01 = { # deviation_from: previous - gesetzlicheKrankenversicherung: { - meanZusatzbeitrag: 0.01 - } - gesetzlicheRentenversicherung: 0.093 - } + "gesetzlicheKrankenversicherung": { + "meanZusatzbeitrag": 0.01, + }, + "gesetzlicheRentenversicherung": 0.093, + }; # Wieder-Einführung der Parität. Art. 2 G. v. 11.12.2018, BGBl. I S. 2387 # (arbeitsl_v:) Set to 0.026 in Art. 2 Nr. 15 G. v. 18.12.2018 BGBl. I S. 2651. # Temporarily reduced to 0.025 in BeiSaV 2019. # Reference: (arbeitsl_v:) V. v. 21.12.2018 BGBl. I S. 2663 - from 2019-01-01 { - gesetzlicheKrankenversicherung: { - allgemein: 0.146 - ermäßigt: 0.14 - meanZusatzbeitrag: 0.009 - } - gesetzlichePflegeversicherung: { - standard: 0.01525 - zusatzKinderlos: 0.0025 - } - arbeitslosenversicherung: 0.0125 - gesetzlicheRentenversicherung: 0.093 - } + from 2019-01-01 = { + "gesetzlicheKrankenversicherung": { + "allgemein": 0.146, + "ermäßigt": 0.14, + "meanZusatzbeitrag": 0.009, + }, + "gesetzlichePflegeversicherung": { + "standard": 0.01525, + "zusatzKinderlos": 0.0025, + }, + "arbeitslosenversicherung": 0.0125, + "gesetzlicheRentenversicherung": 0.093, + }; # Temporarily reduced to 0.024 in BeiSaV 2019. - # Reference: (ges_krankenv mean_zusatzbeitrag:) BAnz AT 28.10.2019 B3 + # Reference: ("ges_krankenv" mean_zusatzbeitrag:) BAnz AT 28.10.2019 B3 # (arbeitsl_v:) V. v. 02.12.2019 BGBl. I S. 1998 - from 2020-01-01 { + from 2020-01-01 = { # deviation_from: previous - gesetzlicheKrankenversicherung: { - meanZusatzbeitrag: 0.011 - } - arbeitslosenversicherung: 0.012 - } - - # Reference: (ges_krankenv mean_zusatzbeitrag:) BAnz AT 30.10.2020 B5 - from 2021-01-01 { + "gesetzlicheKrankenversicherung": { + "meanZusatzbeitrag": 0.011 + }, + "arbeitslosenversicherung": 0.012, + }; + + # Reference: ("ges_krankenv" mean_zusatzbeitrag:) BAnz AT 30.10.2020 B5 + from 2021-01-01 = { # deviation_from: previous - gesetzlicheKrankenversicherung: { - meanZusatzbeitrag: 0.013 - } - } + "gesetzlicheKrankenversicherung": { + "meanZusatzbeitrag": 0.013, + }, + }; # Reference: Art. 2 Nr. 14 G. v. 11.07.2021, BGBl. I S. 2754. - from 2022-01-01 { + from 2022-01-01 = { # deviation_from: previous - gesetzlichePflegeversicherung: { - zusatzKinderlos: 0.0035 - } - } + "gesetzlichePflegeversicherung": { + "zusatzKinderlos": 0.0035, + }, + }; - # Contribution rate for arbeitsl_v was temporarily reduced from 2019 to 2022 in BeiSaV 2019. + # Contribution "rate" for arbeitsl_v was temporarily reduced from 2019 to 2022 in BeiSaV 2019. # Now back to level specified in § 341 Abs. 2 SGB III. # Reference: (arbeitsl_v:) Art. 2 Nr. 15 G. v. 18.12.2018 BGBl. I S. 2651 - # (ges_krankenv mean_zusatzbeitrag:) BAnz AT 31.10.2022 B5 - from 2023-01-01 { + # ("ges_krankenv" mean_zusatzbeitrag:) BAnz AT 31.10.2022 B5 + from 2023-01-01 = { # deviation_from: previous - arbeitslosenversicherung: 0.013 - gesetzlicheKrankenversicherung: { - meanZusatzbeitrag: 0.016 - } - } + "arbeitslosenversicherung": 0.013, + "gesetzlicheKrankenversicherung": { + "meanZusatzbeitrag": 0.016, + }, + }; # Reference: BAnz AT 31.10.2023 B3 - from 2024-01-01 { + from 2024-01-01 = { # deviation_from: previous - gesetzlicheKrankenversicherung: { - meanZusatzbeitrag: 0.017 - } - } + "gesetzlicheKrankenversicherung": { + "meanZusatzbeitrag": 0.017, + }, + }; } /** @@ -369,445 +369,445 @@ public constant beitragssatz: Dict> { * Die Beitragsbemessungsgrenze für Kranken- und Pflegeversicherung ist identisch. */ public constant beitragsbemessungsgrenze: Dict> { - from 1984-01-01 { - ges_krankenv: { - west: 1994 - } - ges_rentenv: { - west: 2659 - } - } - - from 1985-01-01 { - ges_krankenv: { - west: 2071 - } - ges_rentenv: { - west: 2761 - } - } - - from 1986-01-01 { - ges_krankenv: { - west: 2147 - } - ges_rentenv: { - west: 2863 - } - } - - from 1987-01-01 { - ges_krankenv: { - west: 2186 - } - ges_rentenv: { - west: 2914 - } - } - - from 1988-01-01 { - ges_krankenv: { - west: 2301 - } - ges_rentenv: { - west: 3068 - } - } - - from 1989-01-01 { - ges_krankenv: { - west: 2339 - } - ges_rentenv: { - west: 3119 - } - } - - from 1990-01-01 { - ges_krankenv: { - west: 2416 - ost: 1035 - } - ges_rentenv: { - west: 3221 - ost: 1380 - } - } - - from 1991-01-01 { - ges_krankenv: { - west: 2493 - ost: 1151 - } - ges_rentenv: { - west: 3323 - ost: 1534 - } - } - - from 1992-01-01 { - ges_krankenv: { - west: 2608 - ost: 1841 - } - ges_rentenv: { - west: 3477 - ost: 2454 - } - } - - from 1993-01-01 { - ges_krankenv: { - west: 2761 - ost: 2032 - } - ges_rentenv: { - west: 3681 - ost: 271 - } - } - - from 1994-01-01 { - ges_krankenv: { - west: 2914 - ost: 2262 - } - ges_rentenv: { - west: 3886 - ost: 3017 - } - } - - from 1995-01-01 { - ges_krankenv: { - west: 2991 - ost: 2454 - } - ges_rentenv: { - west: 3988 - ost: 3272 - } - } - - from 1996-01-01 { - ges_krankenv: { - west: 3068 - ost: 2608 - } - ges_rentenv: { - west: 4090 - ost: 3477 - } - } - - from 1997-01-01 { - ges_krankenv: { - west: 3144 - ost: 2723 - } - ges_rentenv: { - west: 4193 - ost: 3630 - } - } - - from 1998-01-01 { - ges_krankenv: { - west: 3221 - ost: 2684 - } - ges_rentenv: { - west: 4295 - ost: 3579 - } - } - - from 1999-01-01 { - ges_krankenv: { - west: 3259 - ost: 2761 - } - ges_rentenv: { - west: 4339 - ost: 3681 - } - } - - from 2000-01-01 { - ges_krankenv: { - west: 3298 - ost: 2723 - } - ges_rentenv: { - west: 4397 - ost: 3630 - } - } - - from 2001-01-01 { - ges_krankenv: { - west: 3336 - ost: 3336 - } - ges_rentenv: { - west: 4448 - ost: 3732 - } - } - - from 2002-01-01 { - ges_krankenv: { - west: 3375 - ost: 3375 - } - ges_rentenv: { - west: 4500 - ost: 3750 - } - } - - from 2003-01-01 { - ges_krankenv: { - west: 3450 - ost: 3375 - } - ges_rentenv: { - west: 5100 - ost: 4250 - } - } - - from 2004-01-01 { - ges_krankenv: { - west: 3488 - ost: 3488 - } - ges_rentenv: { - west: 5150 - ost: 4350 - } - } - - from 2005-01-01 { - ges_krankenv: { - west: 3525 - ost: 3525 - } - ges_rentenv: { - west: 5200 - ost: 4400 - } - } - - from 2006-01-01 { - ges_krankenv: { - west: 3562.5 - ost: 3562.5 - } - ges_rentenv: { - west: 5250 - ost: 4400 - } - } - - from 2007-01-01 { + from 1984-01-01 = { + "ges_krankenv": { + "west": 1994 + }, + "ges_rentenv": { + "west": 2659 + }, + }; + + from 1985-01-01 = { + "ges_krankenv": { + "west": 2071 + }, + "ges_rentenv": { + "west": 2761 + }, + }; + + from 1986-01-01 = { + "ges_krankenv": { + "west": 2147 + }, + "ges_rentenv": { + "west": 2863 + }, + }; + + from 1987-01-01 = { + "ges_krankenv": { + "west": 2186 + }, + "ges_rentenv": { + "west": 2914 + }, + }; + + from 1988-01-01 = { + "ges_krankenv": { + "west": 2301 + }, + "ges_rentenv": { + "west": 3068 + }, + }; + + from 1989-01-01 = { + "ges_krankenv": { + "west": 2339 + }, + "ges_rentenv": { + "west": 3119 + }, + }; + + from 1990-01-01 = { + "ges_krankenv": { + "west": 2416, + "ost": 1035 + }, + "ges_rentenv": { + "west": 3221, + "ost": 1380 + }, + }; + + from 1991-01-01 = { + "ges_krankenv": { + "west": 2493, + "ost": 1151, + }, + "ges_rentenv": { + "west": 3323, + "ost": 1534 + }, + }; + + from 1992-01-01 = { + "ges_krankenv": { + "west": 2608, + "ost": 1841 + }, + "ges_rentenv": { + "west": 3477, + "ost": 2454, + } + }; + + from 1993-01-01 = { + "ges_krankenv": { + "west": 2761, + "ost": 2032, + }, + "ges_rentenv": { + "west": 3681, + "ost": 271, + } + }; + + from 1994-01-01 = { + "ges_krankenv": { + "west": 2914, + "ost": 2262, + }, + "ges_rentenv": { + "west": 3886, + "ost": 3017, + } + }; + + from 1995-01-01 = { + "ges_krankenv": { + "west": 2991, + "ost": 2454, + }, + "ges_rentenv": { + "west": 3988, + "ost": 3272, + }, + }; + + from 1996-01-01 = { + "ges_krankenv": { + "west": 3068, + "ost": 2608, + }, + "ges_rentenv": { + "west": 4090, + "ost": 3477, + } + }; + + from 1997-01-01 = { + "ges_krankenv": { + "west": 3144, + "ost": 2723, + }, + "ges_rentenv": { + "west": 4193, + "ost": 3630, + } + }; + + from 1998-01-01 = { + "ges_krankenv": { + "west": 3221, + "ost": 2684, + }, + "ges_rentenv": { + "west": 4295, + "ost": 3579, + } + }; + + from 1999-01-01 = { + "ges_krankenv": { + "west": 3259, + "ost": 2761, + }, + "ges_rentenv": { + "west": 4339, + "ost": 3681, + }, + }; + + from 2000-01-01 = { + "ges_krankenv": { + "west": 3298, + "ost": 2723, + }, + "ges_rentenv": { + "west": 4397, + "ost": 3630, + }, + }; + + from 2001-01-01 = { + "ges_krankenv": { + "west": 3336, + "ost": 3336, + }, + "ges_rentenv": { + "west": 4448, + "ost": 3732, + }, + }; + + from 2002-01-01 = { + "ges_krankenv": { + "west": 3375, + "ost": 3375, + }, + "ges_rentenv": { + "west": 4500, + "ost": 3750, + }, + }; + + from 2003-01-01 = { + "ges_krankenv": { + "west": 3450, + "ost": 3375, + }, + "ges_rentenv": { + "west": 5100, + "ost": 4250, + }, + }; + + from 2004-01-01 = { + "ges_krankenv": { + "west": 3488, + "ost": 3488, + }, + "ges_rentenv": { + "west": 5150, + "ost": 4350, + }, + }; + + from 2005-01-01 = { + "ges_krankenv": { + "west": 3525, + "ost": 3525, + }, + "ges_rentenv": { + "west": 5200, + "ost": 4400, + } + }; + + from 2006-01-01 = { + "ges_krankenv": { + "west": 3562.5, + "ost": 3562.5, + }, + "ges_rentenv": { + "west": 5250, + "ost": 4400, + } + }; + + from 2007-01-01 = { # deviation_from: previous - ges_rentenv: { - ost: 4550 - } - } - - from 2008-01-01 { - ges_krankenv: { - west: 3600 - ost: 3600 - } - ges_rentenv: { - west: 5300 - ost: 4500 - } - } - - from 2009-01-01 { - ges_krankenv: { - west: 3675 - ost: 3675 - } - ges_rentenv: { - west: 5400 - ost: 4550 - } - } - - from 2010-01-01 { - ges_krankenv: { - west: 3750 - ost: 3750 - } - ges_rentenv: { - west: 5500 - ost: 4650 - } - } - - from 2011-01-01 { + "ges_rentenv": { + "ost": 4550, + }, + }; + + from 2008-01-01 = { + "ges_krankenv": { + "west": 3600, + "ost": 3600, + }, + "ges_rentenv": { + "west": 5300, + "ost": 4500, + } + }; + + from 2009-01-01 = { + "ges_krankenv": { + "west": 3675, + "ost": 3675, + }, + "ges_rentenv": { + "west": 5400, + "ost": 4550, + } + }; + + from 2010-01-01 = { + "ges_krankenv": { + "west": 3750, + "ost": 3750, + }, + "ges_rentenv": { + "west": 5500, + "ost": 4650, + } + }; + + from 2011-01-01 = { # deviation_from: previous - ges_krankenv: { - west: 3712.5 - ost: 3712.5 - } - ges_rentenv: { - ost: 4800 + "ges_krankenv": { + "west": 3712.5, + "ost": 3712.5, + }, + "ges_rentenv": { + "ost": 4800, } - } + }; - from 2012-01-01 { + from 2012-01-01 = { # deviation_from: previous - ges_krankenv: { - west: 3825 - ost: 3825 - } - ges_rentenv: { - west: 5600 - } - } - - from 2013-01-01 { - ges_krankenv: { - west: 3937.5 - ost: 3937.5 - } - ges_rentenv: { - west: 5800 - ost: 4900 - } - } + "ges_krankenv": { + "west": 3825, + "ost": 3825, + }, + "ges_rentenv": { + "west": 5600, + } + }; + + from 2013-01-01 = { + "ges_krankenv": { + "west": 3937.5, + "ost": 3937.5, + }, + "ges_rentenv": { + "west": 5800, + "ost": 4900, + } + }; # http:#www.bundesregierung.de/ContentArchiv/DE/Archiv17/Artikel/2013/10/2013-10-16-rechengroessen-sozialversicherung.html - from 2014-01-01 { - ges_krankenv: { - west: 4050 - ost: 4050 - } - ges_rentenv: { - west: 5950 - ost: 5000 - } - } - - from 2015-01-01 { - ges_krankenv: { - west: 4125 - ost: 4125 - } - ges_rentenv: { - west: 6050 - ost: 5200 - } - } + from 2014-01-01 = { + "ges_krankenv": { + "west": 4050, + "ost": 4050, + }, + "ges_rentenv": { + "west": 5950, + "ost": 5000, + }, + }; + + from 2015-01-01 = { + "ges_krankenv": { + "west": 4125, + "ost": 4125, + }, + "ges_rentenv": { + "west": 6050, + "ost": 5200, + }, + }; # https:#www.bundesregierung.de/Content/DE/Artikel/2015/10/2015-10-14-sozialversicherung.html - from 2016-01-01 { - ges_krankenv: { - west: 4237.5 - ost: 4237.5 - } - ges_rentenv: { - west: 6200 - ost: 5400 + from 2016-01-01 = { + "ges_krankenv": { + "west": 4237.5, + "ost": 4237.5, + }, + "ges_rentenv": { + "west": 6200, + "ost": 5400, } - } + }; # https:#www.bundesregierung.de/Content/DE/Artikel/2016/10/2016-10-12-bemessunggrenzen-sozialversicherung.html - from 2017-01-01 { - ges_krankenv: { - west: 4350 - ost: 4350 - } - ges_rentenv: { - west: 6350 - ost: 5700 - } - } - - from 2018-01-01 { - ges_krankenv: { - west: 4425 - ost: 4425 - } - ges_rentenv: { - west: 6500 - ost: 5800 - } - } - - from 2019-01-01 { - ges_krankenv: { - west: 4537.5 - ost: 4537.5 - } - ges_rentenv: { - west: 6700 - ost: 6150 - } - } + from 2017-01-01 = { + "ges_krankenv": { + "west": 4350, + "ost": 4350, + }, + "ges_rentenv": { + "west": 6350, + "ost": 5700, + } + }; + + from 2018-01-01 = { + "ges_krankenv": { + "west": 4425, + "ost": 4425, + }, + "ges_rentenv": { + "west": 6500, + "ost": 5800, + } + }; + + from 2019-01-01 = { + "ges_krankenv": { + "west": 4537.5, + "ost": 4537.5, + }, + "ges_rentenv": { + "west": 6700, + "ost": 6150, + } + }; # Reference: V. v. 17.12.2019 BGBl. I S. 2848 - from 2020-01-01 { - ges_krankenv: { - west: 4687.5 - ost: 4687.5 + from 2020-01-01 = { + "ges_krankenv": { + "west": 4687.5, + "ost": 4687.5, + }, + "ges_rentenv": { + "west": 6900, + "ost": 6450, } - ges_rentenv: { - west: 6900 - ost: 6450 - } - } + }; # Reference: §3, §4 V. v. 30.11.2020, BGBl. I S. 2612. - from 2021-01-01 { - ges_krankenv: { - west: 4837.5 - ost: 4837.5 - } - ges_rentenv: { - west: 7100 - ost: 6700 + from 2021-01-01 = { + "ges_krankenv": { + "west": 4837.5, + "ost": 4837.5, + }, + "ges_rentenv": { + "west": 7100, + "ost": 6700, } - } + }; # Reference: §3 V. v. 30.11.2021, BGBl. I S. 5044. - from 2022-01-01 { + from 2022-01-01 = { # deviation_from: previous - ges_rentenv: { - west: 7050 - ost: 6750 - } - } + "ges_rentenv": { + "west": 7050, + "ost": 6750, + }, + }; # Reference: V. v. 28.11.2022 BGBl. I. S. 2128. - from 2023-01-01 { - ges_krankenv: { - west: 4987.5 - ost: 4987.5 - } - ges_rentenv: { - west: 7300 - ost: 7100 + from 2023-01-01 = { + "ges_krankenv": { + "west": 4987.5, + "ost": 4987.5, + }, + "ges_rentenv": { + "west": 7300, + "ost": 7100, } - } + }; # Reference: V. v. 24.11.2023 BGBl. 2023 I Nr. 322 - from 2024-01-01 { - ges_krankenv: { - west: 5175 - ost: 5175 - } - ges_rentenv: { - west: 7550 - ost: 7450 - } - } + from 2024-01-01 = { + "ges_krankenv": { + "west": 5175, + "ost": 5175, + }, + "ges_rentenv": { + "west": 7550, + "ost": 7450, + } + }; } /** @@ -815,208 +815,208 @@ public constant beitragsbemessungsgrenze: Dict> { * §18 SGB IV and https:#de.wikipedia.org/wiki/Bezugsgr%C3%B6%C3%9Fe */ public constant monatlicheBezugsgroeße: Dict { - from 1984-01-01 { - west: 1396 - } - - from 1985-01-01 { - west: 1432 - } - - from 1986-01-01 { - west: 1467 - } - - from 1987-01-01 { - west: 1539 - } - - from 1988-01-01 { - west: 1575 - } - - from 1989-01-01 { - west: 1611 - } - - from 1990-01-01 { - west: 1682 - ost: 715.8086336747059 - } - - from 1991-01-01 { - west: 1718 - ost: 787.3894970421765 - } - - from 1992-01-01 { - west: 1790 - ost: 1073.712950512059 - } - - from 1993-01-01 { - west: 1897 - ost: 1395.826835665677 - } - - from 1994-01-01 { - west: 2004 - ost: 1574.778994084353 - } - - from 1995-01-01 { - west: 2076 - ost: 1682.150289135559 - } - - from 1996-01-01 { - west: 2112 - ost: 1789.521584186765 - } - - from 1997-01-01 { - west: 2183 - ost: 1861.102447554235 - } - - from 1998-01-01 { - west: 2219 - ost: 1896.892879237971 - } - - from 1999-01-01 { - west: 2255 - ost: 1896.892879237971 - } - - from 2000-01-01 { - west: 2291 - ost: 1861.102447554235 - } - - from 2001-01-01 { + from 1984-01-01 = { + "west": 1396 + }; + + from 1985-01-01 = { + "west": 1432 + }; + + from 1986-01-01 = { + "west": 1467 + }; + + from 1987-01-01 = { + "west": 1539 + }; + + from 1988-01-01 = { + "west": 1575 + }; + + from 1989-01-01 = { + "west": 1611 + }; + + from 1990-01-01 = { + "west": 1682, + "ost": 715.8086336747059 + }; + + from 1991-01-01 = { + "west": 1718, + "ost": 787.3894970421765 + }; + + from 1992-01-01 = { + "west": 1790, + "ost": 1073.712950512059 + }; + + from 1993-01-01 = { + "west": 1897, + "ost": 1395.826835665677 + }; + + from 1994-01-01 = { + "west": 2004, + "ost": 1574.778994084353 + }; + + from 1995-01-01 = { + "west": 2076, + "ost": 1682.150289135559 + }; + + from 1996-01-01 = { + "west": 2112, + "ost": 1789.521584186765 + }; + + from 1997-01-01 = { + "west": 2183, + "ost": 1861.102447554235 + }; + + from 1998-01-01 = { + "west": 2219, + "ost": 1896.892879237971 + }; + + from 1999-01-01 = { + "west": 2255, + "ost": 1896.892879237971 + }; + + from 2000-01-01 = { + "west": 2291, + "ost": 1861.102447554235 + }; + + from 2001-01-01 = { # deviation_from: previous - ost: 1932.683310921706 - } - - from 2002-01-01 { - west: 2345 - ost: 1960 - } - - from 2003-01-01 { - west: 2380 - ost: 1995 - } - - from 2004-01-01 { - west: 2415 - ost: 2030 - } - - from 2006-01-01 { - west: 2450 - ost: 2065 - } - - from 2007-01-01 { + "ost": 1932.683310921706 + }; + + from 2002-01-01 = { + "west": 2345, + "ost": 1960 + }; + + from 2003-01-01 = { + "west": 2380, + "ost": 1995 + }; + + from 2004-01-01 = { + "west": 2415, + "ost": 2030 + }; + + from 2006-01-01 = { + "west": 2450, + "ost": 2065 + }; + + from 2007-01-01 = { # deviation_from: previous - ost: 2100 - } + "ost": 2100 + }; - from 2008-01-01 { + from 2008-01-01 = { # deviation_from: previous - west: 2485 - } + "west": 2485 + }; - from 2009-01-01 { - west: 2520 - ost: 2135 - } + from 2009-01-01 = { + "west": 2520, + "ost": 2135 + }; - from 2010-01-01 { - west: 2555 - ost: 2170 - } + from 2010-01-01 = = { + "west": 2555, + "ost": 2170 + }; - from 2011-01-01 { + from 2011-01-01 = = { # deviation_from: previous - ost: 2240 - } + "ost": 2240 + }; - from 2012-01-01 { + from 2012-01-01 = = { # deviation_from: previous - west: 2625 - } + "west": 2625 + }; - from 2013-01-01 { - west: 2695 - ost: 2275 - } + from 2013-01-01 = = { + "west": 2695, + "ost": 2275 + }; # http:#www.bundesregierung.de/ContentArchiv/DE/Archiv17/Artikel/2013/10/2013-10-16-rechengroessen-sozialversicherung.html - from 2014-01-01 { - west: 2765 - ost: 2345 - } + from 2014-01-01 = = { + "west": 2765, + "ost": 2345 + }; - from 2015-01-01 { - west: 2835 - ost: 2415 - } + from 2015-01-01 = = { + "west": 2835, + "ost": 2415 + }; # https:#www.bundesregierung.de/Content/DE/Artikel/2015/10/2015-10-14-sozialversicherung.html - from 2016-01-01 { - west: 2905 - ost: 2520 - } + from 2016-01-01 = = { + "west": 2905, + "ost": 2520 + }; # https:#www.bundesregierung.de/Content/DE/Artikel/2016/10/2016-10-12-bemessunggrenzen-sozialversicherung.html - from 2017-01-01 { - west: 2975 - ost: 2660 - } + from 2017-01-01 = = { + "west": 2975, + "ost": 2660 + }; - from 2018-01-01 { - west: 3045 - ost: 2695 - } + from 2018-01-01 = = { + "west": 3045, + "ost": 2695 + }; # Sozialversicherungs-Rechengrößenverordnung 2019, BGBl I S. 2024, 27.11.2018 - from 2019-01-01 { - west: 3115 - ost: 2870 - } + from 2019-01-01 = = { + "west": 3115, + "ost": 2870 + }; # Reference: §2 V. v. 17.12.2019 BGBl. I S. 2848 - from 2020-01-01 { - west: 3185 - ost: 3010 - } + from 2020-01-01 = = { + "west": 3185, + "ost": 3010 + }; # Reference: §2 V. v. 30.11.2020, BGBl. I S. 2612. - from 2021-01-01 { - west: 3290 - ost: 3115 - } + from 2021-01-01 = = { + "west": 3290, + "ost": 3115 + }; # Reference: §2 V. v. 30.11.2021, BGBl. I S. 5044. - from 2022-01-01 { - west: 3290 - ost: 3150 - } + from 2022-01-01 = = { + "west": 3290, + "ost": 3150 + }; # Reference: V. v. 28.11.2022 BGBl. I. S. 2128. - from 2023-01-01 { - west: 3395 - ost: 3290 - } + from 2023-01-01 = = { + "west": 3395, + "ost": 3290 + }; # Reference: V. v. 29.11.2023 BGBl. 2023 I Nr. 322. - from 2024-01-01 { - west: 3535 - ost: 3465 - } + from 2024-01-01 = = { + "west": 3535, + "ost": 3465 + }; } /** @@ -1026,9 +1026,7 @@ public constant monatlicheBezugsgroeße: Dict { * Reference: §240 SGB V Abs. 4 */ public constant mindestanteilBezugsgroeßeBeitragspflichtigeEinnahmeSelbst: Float { - from 1990-01-01 { - scalar: 0.33333333 - } + from 1990-01-01 = 0.33333333; } /** @@ -1036,166 +1034,166 @@ public constant mindestanteilBezugsgroeßeBeitragspflichtigeEinnahmeSelbst: Floa * Reference: Midijob § 20 (2) SGB IV, Minijob § 8 (1) Nr. 1 SGB IV */ public constant geringfuegigeEinkommensgrenzenMonatlich: Dict> { - from 1984-01-01 { - minijob: { - west: 199 + from 1984-01-01 = { + "minijob": { + "west": 199 } - } + }; - from 1985-01-01 { + from 1985-01-01 = { # deviation_from: previous - minijob: { - west: 205 + "minijob": { + "west": 205 } - } + }; - from 1986-01-01 { + from 1986-01-01 = { # deviation_from: previous - minijob: { - west: 210 + "minijob": { + "west": 210 } - } + }; - from 1987-01-01 { + from 1987-01-01 = { # deviation_from: previous - minijob: { - west: 220 + "minijob": { + "west": 220 } - } + }; - from 1988-01-01 { + from 1988-01-01 = { # deviation_from: previous - minijob: { - west: 225 + "minijob": { + "west": 225 } - } + }; - from 1989-01-01 { + from 1989-01-01 = { # deviation_from: previous - minijob: { - west: 230 + "minijob": { + "west": 230 } - } + }; - from 1990-01-01 { - minijob: { - west: 240 - ost: 102 + from 1990-01-01 = { + "minijob": { + "west": 240, + "ost": 102 } - } + }; - from 1991-01-01 { + from 1991-01-01 = { # deviation_from: previous - minijob: { - west: 245 - ost: 120 + "minijob": { + "west": 245, + "ost": 120 } - } + }; - from 1992-01-01 { + from 1992-01-01 = { # deviation_from: previous - minijob: { - west: 256 - ost: 153 + "minijob": { + "west": 256, + "ost": 153 } - } + }; - from 1993-01-01 { + from 1993-01-01 = { # deviation_from: previous - minijob: { - west: 271 - ost: 199 + "minijob": { + "west": 271, + "ost": 199 } - } + }; - from 1994-01-01 { + from 1994-01-01 = { # deviation_from: previous - minijob: { - west: 286 - ost: 225 + "minijob": { + "west": 286, + "ost": 225 } - } + }; - from 1995-01-01 { + from 1995-01-01 = { # deviation_from: previous - minijob: { - west: 297 - ost: 240 + "minijob": { + "west": 297, + "ost": 240 } - } + }; - from 1996-01-01 { + from 1996-01-01 = { # deviation_from: previous - minijob: { - west: 302 - ost: 256 + "minijob": { + "west": 302, + "ost": 256 } - } + }; - from 1997-01-01 { + from 1997-01-01 = { # deviation_from: previous - minijob: { - west: 312 - ost: 266 + "minijob": { + "west": 312, + "ost": 266 } - } + }; - from 1998-01-01 { + from 1998-01-01 = { # deviation_from: previous - minijob: { - west: 317 + "minijob": { + "west": 317 } - } + }; - from 1999-01-01 { + from 1999-01-01 = { # deviation_from: previous - minijob: { - west: 322 - ost: 271 + "minijob": { + "west": 322, + "ost": 271 } - } + }; - from 2000-01-01 { + from 2000-01-01 = { # deviation_from: previous - minijob: 322 - } + "minijob": 322 + }; - from 2002-01-01 { + from 2002-01-01 = { # deviation_from: previous - minijob: 325 - } + "minijob": 325 + }; - from 2003-04-01 { + from 2003-04-01 = { # deviation_from: previous - minijob: 400 - midijob: 800 - } + "minijob": 400, + "midijob": 800 + }; - from 2013-01-01 { + from 2013-01-01 = { # deviation_from: previous - minijob: 450 - midijob: 850 - } + "minijob": 450, + "midijob": 850 + }; # Reference: Art. 4 G. v. 28.11.2018 BGBl. I S. 2016 - from 2019-01-01 { + from 2019-01-01 = { # deviation_from: previous - midijob: 1300 - } + "midijob": 1300 + }; # Reference: Art. 7 G. v. 28.06.2022 BGBl. I S. 969 - # minijob thresholds now calculated based on statutory minimum wage - from 2022-10-01 { + # "minijob" thresholds now calculated based on statutory minimum wage + from 2022-10-01 = { # deviation_from: previous - minijob: null - midijob: 1600 - } + "minijob": null, + "midijob": 1600 + }; # Reference: Art. 3 G. v. 11.11.2022 BGBl. I S. 1985 - from 2023-01-01 { + from 2023-01-01 = { # deviation_from: previous - midijob: 2000 - } + "midijob": 2000 + }; } /** @@ -1204,7 +1202,7 @@ public constant geringfuegigeEinkommensgrenzenMonatlich: Dict { - from 1984-01-01 { - ges_krankenv: 0 - ges_rentenv: 0 - st: 0 - } + from 1984-01-01 = { + "ges_krankenv": 0, + "ges_rentenv": 0, + "st": 0 + }; - from 1999-01-01 { + from 1999-01-01 = { # deviation_from: previous - ges_krankenv: 0.1 - ges_rentenv: 0.12 - st: 0 - } + "ges_krankenv": 0.1, + "ges_rentenv": 0.12, + "st": 0 + }; - from 2003-04-01 { + from 2003-04-01 = { # deviation_from: previous - ges_krankenv: 0.11 - ges_rentenv: 0.12 - st: 0.02 - } + "ges_krankenv": 0.11, + "ges_rentenv": 0.12, + "st": 0.02 + }; - from 2007-01-01 { + from 2007-01-01 = { # deviation_from: previous - ges_krankenv: 0.13 - ges_rentenv: 0.15 - st: 0.02 - } + "ges_krankenv": 0.13, + "ges_rentenv": 0.15, + "st": 0.02 + }; } /** @@ -1260,7 +1258,7 @@ public constant pauschalabgabenGeringfuegigeBeschaeftigung: Dict * Reference: § 55 Abs. 3 SGB XI, KiBG Art. 1 */ public constant mindestalterBeitragszuschlagKinderlose: Int { - from 2005-01-01 = 23 + from 2005-01-01 = 23; } /** @@ -1268,21 +1266,21 @@ public constant mindestalterBeitragszuschlagKinderlose: Int { * Reference: §1 (2) Mindestlohngesetz */ public constant mindestlohn: Float { - from 2015-01-01 = 8.5 - from 2017-01-01 = 8.84 - from 2019-01-01 = 9.19 - from 2020-01-01 = 9.35 - from 2021-01-01 = 9.5 - from 2021-07-01 = 9.6 - from 2022-01-01 = 9.82 - from 2022-07-01 = 10.45 - from 2022-10-01 = 12 + from 2015-01-01 = 8.5; + from 2017-01-01 = 8.84; + from 2019-01-01 = 9.19; + from 2020-01-01 = 9.35; + from 2021-01-01 = 9.5; + from 2021-07-01 = 9.6; + from 2022-01-01 = 9.82; + from 2022-07-01 = 10.45; + from 2022-10-01 = 12; # Reference: V. v. 24.11.2023 BGBl. 2023 I Nr. 321 - from 2024-01-01 = 12.41 + from 2024-01-01 = 12.41; # Reference: V. v. 24.11.2023 BGBl. 2023 I Nr. 321 - from 2025-01-01 = 12.82 + from 2025-01-01 = 12.82; } # TODO: rounding From cb81d568a04ed93c265d684dccad25a8ab2e8fff Mon Sep 17 00:00:00 2001 From: alex-senger Date: Sun, 1 Sep 2024 14:56:55 +0200 Subject: [PATCH 170/183] fix syntax errors --- .../builtins/parameters/unterhalt.ttsl | 26 +++++++++---------- .../parameters/unterhaltvorschuss.ttsl | 6 ++--- 2 files changed, 16 insertions(+), 16 deletions(-) diff --git a/src/resources/builtins/parameters/unterhalt.ttsl b/src/resources/builtins/parameters/unterhalt.ttsl index 5a93e8ae..df2a362a 100644 --- a/src/resources/builtins/parameters/unterhalt.ttsl +++ b/src/resources/builtins/parameters/unterhalt.ttsl @@ -11,63 +11,63 @@ public constant mindestunterhalt: Dict { 6: 335, 12: 384, 18: 450 - } + }; # Reference: V. v. 03.12.2015 BGBl. I S. 2188. from 2017-01-01 = { 6: 342, 12: 393, 18: 460 - } + }; # Reference: Artikel 1 V. v. 28.09.2017 BGBl. I S. 3525. from 2018-01-01 = { 6: 348, 12: 399, 18: 467 - } + }; # Reference: Artikel 1 V. v. 28.09.2017 BGBl. I S. 3525. from 2019-01-01 = { 6: 354, 12: 406, 18: 476 - } + }; # Reference: Artikel 1 V. v. 12.09.2019 BGBl. I S. 1393. from 2020-01-01 = { 6: 369, 12: 424, 18: 497 - } + }; # Reference: Artikel 1 V. v. 03.11.2020 BGBl. I S. 2344. from 2021-01-01 = { 6: 393, 12: 451, 18: 528 - } + }; # Reference: Artikel 1 V. v. 30.11.2021 BGBl. I S. 5066. from 2022-01-01 = { 6: 396, 12: 455, 18: 533 - } + }; # Reference: Artikel 1 V. v. 30.11.2022 BGBl. I S. 2130. from 2023-01-01 = { 6: 437, 12: 502, 18: 588 - } + }; # Reference: Artikel 1 V. v. 29.11.2023 BGBl. I Nr. 330. from 2024-01-01 = { 6: 480, 12: 551, 18: 645 - } + }; } /** @@ -80,7 +80,7 @@ public constant mindestunterhalt: Dict { */ public constant abzugsrateKindergeld: Dict { from 2008-01-01 = { - kind: 0.5, - erwachsener: 1 - } -} \ No newline at end of file + "kind": 0.5, + "erwachsener": 1 + }; +} diff --git a/src/resources/builtins/parameters/unterhaltvorschuss.ttsl b/src/resources/builtins/parameters/unterhaltvorschuss.ttsl index c8ac2694..8c0c6a94 100644 --- a/src/resources/builtins/parameters/unterhaltvorschuss.ttsl +++ b/src/resources/builtins/parameters/unterhaltvorschuss.ttsl @@ -5,7 +5,7 @@ package unterhaltvorschuss * `altersgrenze_mindesteinkommen` Jahren zu erhalten. * Reference: § 1 (1a) Nr. 2 Unterhaltsvorschussgesetz */ -public constant mindesteinkommen: Int = { +public constant mindesteinkommen: Int { # Reference: Art. 23 G. v. 14.08.2017 BGBl. I S. 3122. from 2017-01-01 = 600; } @@ -15,7 +15,7 @@ public constant mindesteinkommen: Int = { * `mindesteinkommen` bezogen werden kann. * Reference: § 1 (1a) Nr. 2 Unterhaltsvorschussgesetz */ -public constant altersgrenzeMindesteinkommen: Int = { +public constant altersgrenzeMindesteinkommen: Int { # Reference: Art. 23 G. v. 14.08.2017 BGBl. I S. 3122. from 2017-01-01 = 12; } @@ -28,7 +28,7 @@ public constant altersgrenzeMindesteinkommen: Int = { * bekommen, wenn das Elternteil ein Mindesteinkommen hat. * Reference: § 1 Abs. 1, 1a UhVorschG */ -public constant altersgrenzen: Dict = { +public constant altersgrenzen: Dict { # Reference: § 1 Abs. 1, 1a UhVorschG from 2017-01-01 = { 1: 6, From c826b1aa8d87f26fdbef8a9d9bfa25edf363c80e Mon Sep 17 00:00:00 2001 From: methr0 Date: Mon, 2 Sep 2024 10:31:57 +0200 Subject: [PATCH 171/183] remove experimental Language validation check and add Umlaute to grammar --- .../src/language/grammar/ttsl.langium | 2 +- .../experimentalLanguageFeatures.ts | 29 ------------------- .../src/language/validation/ttsl-validator.ts | 5 +--- 3 files changed, 2 insertions(+), 34 deletions(-) delete mode 100644 packages/ttsl-lang/src/language/validation/experimentalLanguageFeatures.ts diff --git a/packages/ttsl-lang/src/language/grammar/ttsl.langium b/packages/ttsl-lang/src/language/grammar/ttsl.langium index 9544948d..7dd5e7af 100644 --- a/packages/ttsl-lang/src/language/grammar/ttsl.langium +++ b/packages/ttsl-lang/src/language/grammar/ttsl.langium @@ -853,7 +853,7 @@ TslAnyType returns TslAnyType: // ----------------------------------------------------------------------------- terminal ID returns string: IDENTIFIER | '`' IDENTIFIER '`'; -terminal fragment IDENTIFIER: /[_a-zA-Z][_a-zA-Z0-9]*/; +terminal fragment IDENTIFIER: /[_a-zA-Zäöüß][_a-zA-Zäöüß0-9]*/; terminal FLOAT returns number : DECIMAL_DIGIT+ '.' DECIMAL_DIGIT+ FLOAT_EXPONENT? diff --git a/packages/ttsl-lang/src/language/validation/experimentalLanguageFeatures.ts b/packages/ttsl-lang/src/language/validation/experimentalLanguageFeatures.ts deleted file mode 100644 index fd1ffaa4..00000000 --- a/packages/ttsl-lang/src/language/validation/experimentalLanguageFeatures.ts +++ /dev/null @@ -1,29 +0,0 @@ -import { AstUtils, ValidationAcceptor } from 'langium'; -import { - isTslDictionary, - type TslDictionary, -} from '../generated/ast.js'; -import { TTSLServices } from '../ttsl-module.js'; - -export const CODE_EXPERIMENTAL_LANGUAGE_FEATURE = 'experimental/language-feature'; - -export const mapsShouldBeUsedWithCaution = (services: TTSLServices) => { - const settingsProvider = services.workspace.SettingsProvider; - - return async (node: TslDictionary, accept: ValidationAcceptor) => { - if (!(await settingsProvider.shouldValidateExperimentalLanguageFeature())) { - /* c8 ignore next 2 */ - return; - } - - // There's already a warning on the container - if (AstUtils.hasContainerOfType(node.$container, isTslDictionary)) { - return; - } - - accept('warning', 'Map literals are experimental and may change without prior notice.', { - node, - code: CODE_EXPERIMENTAL_LANGUAGE_FEATURE, - }); - }; -}; \ No newline at end of file diff --git a/packages/ttsl-lang/src/language/validation/ttsl-validator.ts b/packages/ttsl-lang/src/language/validation/ttsl-validator.ts index 367fc7c9..85c8d67b 100644 --- a/packages/ttsl-lang/src/language/validation/ttsl-validator.ts +++ b/packages/ttsl-lang/src/language/validation/ttsl-validator.ts @@ -1,9 +1,6 @@ import { ValidationChecks } from 'langium'; import { TTSLAstType } from '../generated/ast.js'; import type { TTSLServices } from '../ttsl-module.js'; -import { - mapsShouldBeUsedWithCaution, -} from './experimentalLanguageFeatures.js'; import { moduleMemberMustHaveNameThatIsUniqueInPackage, moduleMustContainUniqueNames, @@ -113,7 +110,7 @@ export const registerValidationChecks = function (services: TTSLServices) { infixOperationOperandsMustHaveCorrectType(services), ], TslList: [listMustNotContainNamedTuples(services)], - TslDictionary: [mapMustNotContainNamedTuples(services), mapsShouldBeUsedWithCaution(services)], + TslDictionary: [mapMustNotContainNamedTuples(services)], TslModule: [ moduleMemberMustHaveNameThatIsUniqueInPackage(services), moduleMustContainUniqueNames, From 13f0192f68cf0efad7a3383eab54c3b45f761ca7 Mon Sep 17 00:00:00 2001 From: alex-senger Date: Tue, 3 Sep 2024 13:46:29 +0200 Subject: [PATCH 172/183] wohngeld wip --- .../builtins/parameters/wohngeld.ttsl | 736 +++++++++--------- 1 file changed, 368 insertions(+), 368 deletions(-) diff --git a/src/resources/builtins/parameters/wohngeld.ttsl b/src/resources/builtins/parameters/wohngeld.ttsl index 366268fa..ffd87de6 100644 --- a/src/resources/builtins/parameters/wohngeld.ttsl +++ b/src/resources/builtins/parameters/wohngeld.ttsl @@ -5,13 +5,13 @@ package wohngeld * Anlage 2 WoGG zu §19 Abs. 2 WoGG */ public constant faktorBerechnungsformel: Float { - from 1984-01-01 = 1 + from 1984-01-01 = 1; # Reference: Art. 1 G. v. 24.09 2008 BGBl. I S. 1856 - from 2009-01-01 = 1.08 + from 2009-01-01 = 1.08; # Reference: Art. 1 G. v. 08.10.2015 BGBl 38 S.1610 - from 2016-01-01 = 1.15 + from 2016-01-01 = 1.15; } /** @@ -20,582 +20,582 @@ public constant faktorBerechnungsformel: Float { * Wohngeldverordnung (WoGV). * The keys from 1 to 12 below refer to the household size. */ -public constant koeffizientenBerechnungsformel: Dict> { +public constant koeffizientenBerechnungsformel: Dict> { # Parameter aus Regressionsanalyse der Wohngeldtabellen from 1984-01-01 = { 1: { - a: 0.0532, - b: 0.00135, - c: 0.0000632 + "a": 0.0532, + "b": 0.00135, + "c": 0.0000632 }, 2: { - a: 0.0574, - b: 0.000957, - c: 0.0000352 + "a": 0.0574, + "b": 0.000957, + "c": 0.0000352 }, 3: { - a: 0.0612, - b: 0.00078, - c: 0.0000202 + "a": 0.0612, + "b": 0.00078, + "c": 0.0000202 }, 4: { - a: 0.0596, - b: 0.000613, - c: 2.78e-06 + "a": 0.0596, + "b": 0.000613, + "c": 2.78e-06 }, 5: { - a: 0.0572, - b: 0.000554, - c: 5.38e-07 + "a": 0.0572, + "b": 0.000554, + "c": 5.38e-07 }, 6: { - a: 0.0365, - b: 0.000531, - c: 4.62e-06 + "a": 0.0365, + "b": 0.000531, + "c": 4.62e-06 }, 7: { - a: 0.0129, - b: 0.000502, - c: 0.0000124 + "a": 0.0129, + "b": 0.000502, + "c": 0.0000124 }, 8: { - a: -0.0176, - b: 0.000468, - c: 0.0000253 + "a": -0.0176, + "b": 0.000468, + "c": 0.0000253 }, 9: { - a: -0.0397, - b: 0.000424, - c: 0.0000364 + "a": -0.0397, + "b": 0.000424, + "c": 0.0000364 }, 10: { - a: -0.0595, - b: 0.000373, - c: 0.0000481 + "a": -0.0595, + "b": 0.000373, + "c": 0.0000481 }, 11: { - a: -0.0595, - b: 0.000373, - c: 0.0000481 + "a": -0.0595, + "b": 0.000373, + "c": 0.0000481 }, 12: { - a: -0.0595, - b: 0.000373, - c: 0.0000481 + "a": -0.0595, + "b": 0.000373, + "c": 0.0000481 } - } + }; # Parameter aus Regressionsanalyse der Wohngeldtabellen from 1990-01-01 = { 1: { - a: 0.0648, - b: 0.00102, - c: 0.0000613 + "a": 0.0648, + "b": 0.00102, + "c": 0.0000613 }, 2: { - a: 0.0694, - b: 0.000715, - c: 0.0000347 + "a": 0.0694, + "b": 0.000715, + "c": 0.0000347 }, 3: { - a: 0.0741, - b: 0.000604, - c: 0.000011 + "a": 0.0741, + "b": 0.000604, + "c": 0.000011 }, 4: { - a: 0.0669, - b: 0.000476, - c: 1.75e-06 + "a": 0.0669, + "b": 0.000476, + "c": 1.75e-06 }, 5: { - a: 0.064, - b: 0.00043, - c: 9.14e-07 + "a": 0.064, + "b": 0.00043, + "c": 9.14e-07 }, 6: { - a: 0.0445, - b: 0.000414, - c: 4.02e-06 + "a": 0.0445, + "b": 0.000414, + "c": 4.02e-06 }, 7: { - a: 0.0226, - b: 0.000397, - c: 9.44e-06 + "a": 0.0226, + "b": 0.000397, + "c": 9.44e-06 }, 8: { - a: -0.0005, - b: 0.000387, - c: 0.0000136 + "a": -0.0005, + "b": 0.000387, + "c": 0.0000136 }, 9: { - a: -0.0281, - b: 0.000337, - c: 0.0000308 + "a": -0.0281, + "b": 0.000337, + "c": 0.0000308 }, 10: { - a: -0.0455, - b: 0.000298, - c: 0.0000386 + "a": -0.0455, + "b": 0.000298, + "c": 0.0000386 }, 11: { - a: -0.0455, - b: 0.000298, - c: 0.0000386 + "a": -0.0455, + "b": 0.000298, + "c": 0.0000386 }, 12: { - a: -0.0455, - b: 0.000298, - c: 0.0000386 + "a": -0.0455, + "b": 0.000298, + "c": 0.0000386 } - } + }; # Parameter aus Regressionsanalyse der Wohngeldtabellen from 1992-01-01 = { 1: { - a: 0.0666, - b: 0.00102, - c: 0.0000579 + "a": 0.0666, + "b": 0.00102, + "c": 0.0000579 }, 2: { - a: 0.0716, - b: 0.000713, - c: 0.0000317 + "a": 0.0716, + "b": 0.000713, + "c": 0.0000317 }, 3: { - a: 0.0748, - b: 0.000604, - c: 0.0000102 + "a": 0.0748, + "b": 0.000604, + "c": 0.0000102 }, 4: { - a: 0.0671, - b: 0.000475, - c: 1.63e-06 + "a": 0.0671, + "b": 0.000475, + "c": 1.63e-06 }, 5: { - a: 0.0642, - b: 0.00043, - c: 8.96e-07 + "a": 0.0642, + "b": 0.00043, + "c": 8.96e-07 }, 6: { - a: 0.0463, - b: 0.000419, - c: 1.35e-06 + "a": 0.0463, + "b": 0.000419, + "c": 1.35e-06 }, 7: { - a: 0.0256, - b: 0.000404, - c: 5.66e-06 + "a": 0.0256, + "b": 0.000404, + "c": 5.66e-06 }, 8: { - a: -0.00252, - b: 0.000377, - c: 0.0000173 + "a": -0.00252, + "b": 0.000377, + "c": 0.0000173 }, 9: { - a: -0.00252, - b: 0.000377, - c: 0.0000173 + "a": -0.00252, + "b": 0.000377, + "c": 0.0000173 }, 10: { - a: -0.00252, - b: 0.000377, - c: 0.0000173 + "a": -0.00252, + "b": 0.000377, + "c": 0.0000173 }, 11: { - a: -0.00252, - b: 0.000377, - c: 0.0000173 + "a": -0.00252, + "b": 0.000377, + "c": 0.0000173 }, 12: { - a: -0.00252, - b: 0.000377, - c: 0.0000173 + "a": -0.00252, + "b": 0.000377, + "c": 0.0000173 } - } + }; # Reference: Art. 5 G. v. 22.12.1999 BGBl. I S. 2671 from 2001-01-01 = { 1: { - a: 0.063, - b: 0.000796, - c: 0.00009102 + "a": 0.063, + "b": 0.000796, + "c": 0.00009102 }, 2: { - a: 0.057, - b: 0.000576, - c: 0.00006431 + "a": 0.057, + "b": 0.000576, + "c": 0.00006431 }, 3: { - a: 0.055, - b: 0.000518, - c: 0.0000325 + "a": 0.055, + "b": 0.000518, + "c": 0.0000325 }, 4: { - a: 0.047, - b: 0.000395, - c: 0.00002325 + "a": 0.047, + "b": 0.000395, + "c": 0.00002325 }, 5: { - a: 0.042, - b: 0.000348, - c: 0.00002151 + "a": 0.042, + "b": 0.000348, + "c": 0.00002151 }, 6: { - a: 0.037, - b: 0.000327, - c: 0.00001519 + "a": 0.037, + "b": 0.000327, + "c": 0.00001519 }, 7: { - a: 0.033, - b: 0.000313, - c: 8.745e-06 + "a": 0.033, + "b": 0.000313, + "c": 8.745e-06 }, 8: { - a: 0.023, - b: 0.000296, - c: 7.44e-06 + "a": 0.023, + "b": 0.000296, + "c": 7.44e-06 }, 9: { - a: -0.017, - b: 0.000225, - c: 0.00003522 + "a": -0.017, + "b": 0.000225, + "c": 0.00003522 }, 10: { - a: -0.037, - b: 0.000157, - c: 0.00005547 + "a": -0.037, + "b": 0.000157, + "c": 0.00005547 }, 11: { - a: -0.067, - b: 0.000153, - c: 0.00005686 + "a": -0.067, + "b": 0.000153, + "c": 0.00005686 }, 12: { - a: -0.092, - b: 0.000136, - c: 0.00006182 + "a": -0.092, + "b": 0.000136, + "c": 0.00006182 } - } + }; # Reference: Art. 1 G. v. 24.09 2008 BGBl. I S. 1856 from 2009-01-01 = { 1: { - a: 0.063, - b: 0.0007963, - c: 0.00009102 + "a": 0.063, + "b": 0.0007963, + "c": 0.00009102 }, 2: { - a: 0.057, - b: 0.0005761, - c: 0.00006431 + "a": 0.057, + "b": 0.0005761, + "c": 0.00006431 }, 3: { - a: 0.055, - b: 0.0005176, - c: 0.0000325 + "a": 0.055, + "b": 0.0005176, + "c": 0.0000325 }, 4: { - a: 0.047, - b: 0.0003945, - c: 0.00002325 + "a": 0.047, + "b": 0.0003945, + "c": 0.00002325 }, 5: { - a: 0.042, - b: 0.0003483, - c: 0.00002151 + "a": 0.042, + "b": 0.0003483, + "c": 0.00002151 }, 6: { - a: 0.037, - b: 0.0003269, - c: 0.00001519 + "a": 0.037, + "b": 0.0003269, + "c": 0.00001519 }, 7: { - a: 0.033, - b: 0.0003129, - c: 8.745e-06 + "a": 0.033, + "b": 0.0003129, + "c": 8.745e-06 }, 8: { - a: 0.023, - b: 0.0002959, - c: 7.44e-06 + "a": 0.023, + "b": 0.0002959, + "c": 7.44e-06 }, 9: { - a: -0.0197, - b: 0.0002245, - c: 0.00003459 + "a": -0.0197, + "b": 0.0002245, + "c": 0.00003459 }, 10: { - a: -0.0401, - b: 0.0001565, - c: 0.0000514 + "a": -0.0401, + "b": 0.0001565, + "c": 0.0000514 }, 11: { - a: -0.066, - b: 0.00012, - c: 0.00005686 + "a": -0.066, + "b": 0.00012, + "c": 0.00005686 }, 12: { - a: -0.0899, - b: 0.000109, - c: 0.00006182 + "a": -0.0899, + "b": 0.000109, + "c": 0.00006182 } - } + }; # Reference: Art. 1 G. v. 08.10.2015 BGBl 38 S.1610 from 2016-01-01 = { 1: { - a: 0.04, - b: 0.00063, - c: 0.000138 + "a": 0.04, + "b": 0.00063, + "c": 0.000138 }, 2: { - a: 0.03, - b: 0.00044, - c: 0.000103 + "a": 0.03, + "b": 0.00044, + "c": 0.000103 }, 3: { - a: 0.02, - b: 0.00038, - c: 0.000083 + "a": 0.02, + "b": 0.00038, + "c": 0.000083 }, 4: { - a: 0.01, - b: 0.00034, - c: 0.000043 + "a": 0.01, + "b": 0.00034, + "c": 0.000043 }, 5: { - a: 0, - b: 0.0003, - c: 0.000042 + "a": 0, + "b": 0.0003, + "c": 0.000042 }, 6: { - a: -0.01, - b: 0.00028, - c: 0.000036 + "a": -0.01, + "b": 0.00028, + "c": 0.000036 }, 7: { - a: -0.02, - b: 0.00026, - c: 0.000037 + "a": -0.02, + "b": 0.00026, + "c": 0.000037 }, 8: { - a: -0.03, - b: 0.00023, - c: 0.000037 + "a": -0.03, + "b": 0.00023, + "c": 0.000037 }, 9: { - a: -0.04, - b: 0.0002, - c: 0.000039 + "a": -0.04, + "b": 0.0002, + "c": 0.000039 }, 10: { - a: -0.06, - b: 0.00016, - c: 0.000045 + "a": -0.06, + "b": 0.00016, + "c": 0.000045 }, 11: { - a: -0.1, - b: 0.00012, - c: 0.000053 + "a": -0.1, + "b": 0.00012, + "c": 0.000053 }, 12: { - a: -0.14, - b: 0.00011, - c: 0.00006 + "a": -0.14, + "b": 0.00011, + "c": 0.00006 } - } + }; # Reference: Art. 1 G. v. 30.11.2019 BGBl. I S. 1877 from 2020-01-01 = { 1: { - a: 0.04, - b: 0.00058, - c: 0.000118 + "a": 0.04, + "b": 0.00058, + "c": 0.000118 }, 2: { - a: 0.03, - b: 0.000405, - c: 0.000088 + "a": 0.03, + "b": 0.000405, + "c": 0.000088 }, 3: { - a: 0.02, - b: 0.00035, - c: 0.0000709 + "a": 0.02, + "b": 0.00035, + "c": 0.0000709 }, 4: { - a: 0.01, - b: 0.000313, - c: 0.0000368 + "a": 0.01, + "b": 0.000313, + "c": 0.0000368 }, 5: { - a: 0, - b: 0.000276, - c: 0.0000359 + "a": 0, + "b": 0.000276, + "c": 0.0000359 }, 6: { - a: -0.01, - b: 0.000258, - c: 0.0000308 + "a": -0.01, + "b": 0.000258, + "c": 0.0000308 }, 7: { - a: -0.02, - b: 0.000239, - c: 0.0000316 + "a": -0.02, + "b": 0.000239, + "c": 0.0000316 }, 8: { - a: -0.03, - b: 0.000212, - c: 0.0000316 + "a": -0.03, + "b": 0.000212, + "c": 0.0000316 }, 9: { - a: -0.04, - b: 0.000184, - c: 0.0000333 + "a": -0.04, + "b": 0.000184, + "c": 0.0000333 }, 10: { - a: -0.06, - b: 0.000147, - c: 0.0000385 + "a": -0.06, + "b": 0.000147, + "c": 0.0000385 }, 11: { - a: -0.1, - b: 0.00011, - c: 0.0000453 + "a": -0.1, + "b": 0.00011, + "c": 0.0000453 }, 12: { - a: -0.14, - b: 0.000101, - c: 0.0000513 + "a": -0.14, + "b": 0.000101, + "c": 0.0000513 } - } + }; # Reference: V. v. 03.06.2021 BGBl. I S. 1369. from 2022-01-01 = { 1: { - a: 0.04, - b: 0.000564, - c: 0.0001157 + "a": 0.04, + "b": 0.000564, + "c": 0.0001157 }, 2: { - a: 0.03, - b: 0.000394, - c: 0.0000863 + "a": 0.03, + "b": 0.000394, + "c": 0.0000863 }, 3: { - a: 0.02, - b: 0.00034, - c: 0.0000695 + "a": 0.02, + "b": 0.00034, + "c": 0.0000695 }, 4: { - a: 0.01, - b: 0.000304, - c: 0.0000361 + "a": 0.01, + "b": 0.000304, + "c": 0.0000361 }, 5: { - a: 0, - b: 0.000268, - c: 0.0000352 + "a": 0, + "b": 0.000268, + "c": 0.0000352 }, 6: { - a: -0.01, - b: 0.000251, - c: 0.0000302 + "a": -0.01, + "b": 0.000251, + "c": 0.0000302 }, 7: { - a: -0.02, - b: 0.000232, - c: 0.000031 + "a": -0.02, + "b": 0.000232, + "c": 0.000031 }, 8: { - a: -0.03, - b: 0.000206, - c: 0.000031 + "a": -0.03, + "b": 0.000206, + "c": 0.000031 }, 9: { - a: -0.04, - b: 0.000179, - c: 0.0000326 + "a": -0.04, + "b": 0.000179, + "c": 0.0000326 }, 10: { - a: -0.06, - b: 0.000143, - c: 0.0000377 + "a": -0.06, + "b": 0.000143, + "c": 0.0000377 }, 11: { - a: -0.1, - b: 0.000107, - c: 0.0000444 + "a": -0.1, + "b": 0.000107, + "c": 0.0000444 }, 12: { - a: -0.14, - b: 0.000098, - c: 0.0000503 + "a": -0.14, + "b": 0.000098, + "c": 0.0000503 } - } + }; # Reference: Art. 1 G. v. 08.12.2022 BGBl. I Nr. 48 S. 2160 from 2023-01-01 = { 1: { - a: 0.04, - b: 0.0004991, - c: 0.0000462 + "a": 0.04, + "b": 0.0004991, + "c": 0.0000462 }, 2: { - a: 0.03, - b: 0.0003716, - c: 0.0000345 + "a": 0.03, + "b": 0.0003716, + "c": 0.0000345 }, 3: { - a: 0.02, - b: 0.0003035, - c: 0.0000278 + "a": 0.02, + "b": 0.0003035, + "c": 0.0000278 }, 4: { - a: 0.01, - b: 0.0002251, - c: 0.00002 + "a": 0.01, + "b": 0.0002251, + "c": 0.00002 }, 5: { - a: 0, - b: 0.0001985, - c: 0.0000195 + "a": 0, + "b": 0.0001985, + "c": 0.0000195 }, 6: { - a: -0.01, - b: 0.0001792, - c: 0.0000188 + "a": -0.01, + "b": 0.0001792, + "c": 0.0000188 }, 7: { - a: -0.02, - b: 0.0001657, - c: 0.0000187 + "a": -0.02, + "b": 0.0001657, + "c": 0.0000187 }, 8: { - a: -0.03, - b: 0.0001648, - c: 0.0000187 + "a": -0.03, + "b": 0.0001648, + "c": 0.0000187 }, 9: { - a: -0.04, - b: 0.0001432, - c: 0.0000188 + "a": -0.04, + "b": 0.0001432, + "c": 0.0000188 }, 10: { - a: -0.06, - b: 0.00013, - c: 0.0000188 + "a": -0.06, + "b": 0.00013, + "c": 0.0000188 }, 11: { - a: -0.09, - b: 0.0001188, - c: 0.0000222 + "a": -0.09, + "b": 0.0001188, + "c": 0.0000222 }, 12: { - a: -0.12, - b: 0.0001152, - c: 0.0000251 + "a": -0.12, + "b": 0.0001152, + "c": 0.0000251 } - } + }; } /** @@ -609,31 +609,31 @@ public constant bonusSehrGrosseHaushalte: Dict { from 2001-01-01 = { max_anz_personen_normale_berechnung: 12, bonus_jede_weitere_person: 40 - } + }; # Reference: Art. 1 G. v. 24.09 2008 BGBl. I S. 1856 from 2009-01-01 = { # deviation_from: previous bonus_jede_weitere_person: 43 - } + }; # Reference: Art. 1 G. v. 08.10.2015 BGBl 38 S.1610 from 2016-01-01 = { # deviation_from: previous bonus_jede_weitere_person: 47 - } + }; # Reference: Art. 1 G. v. 30.11.2019 BGBl. I S. 1877 from 2020-01-01 = { # deviation_from: previous bonus_jede_weitere_person: 51 - } + }; # Reference: Art. 1 G. v. 08.12.2022 BGBl. I Nr. 48 S. 2160 from 2023-01-01 = { # deviation_from: previous bonus_jede_weitere_person: 57 - } + }; } /** @@ -649,24 +649,24 @@ public constant abzugStufen: Dict { 1: 0.125, 2: 0.2, 3: 0.3 - } + }; from 1991-01-01 = { # deviation_from: previous 3: 0.26 - } + }; from 2002-01-01 = { # deviation_from: previous 1: 0.1, 3: 0.3 - } + }; # Reference: Art. G. v. 02.10.2015 BGBl I S. 1610 from 2016-01-01 = { # deviation_from: previous 0: 0.0 - } + }; } /** @@ -687,7 +687,7 @@ public constant minMiete: Dict { 10: 0, 11: 0, 12: 0 - } + }; from 2001-01-01 = { 1: 22.5, @@ -702,7 +702,7 @@ public constant minMiete: Dict { 10: 37.5, 11: 75, 12: 155 - } + }; from 2009-01-01 = { 1: 45, @@ -717,7 +717,7 @@ public constant minMiete: Dict { 10: 125, 11: 155, 12: 245, - } + }; # Reference: Art. 1 G. v. 08.10.2015 BGBl Nr.38, S.1617 from 2016-01-01 = { @@ -733,7 +733,7 @@ public constant minMiete: Dict { 10: 134, 11: 155, 12: 263 - } + }; # Reference: Art. 1 G. v. 30.11.2019 BGBl. I S. 1877 from 2020-01-01 = { @@ -749,7 +749,7 @@ public constant minMiete: Dict { 10: 146, 11: 180, 12: 286 - } + }; } /** @@ -770,7 +770,7 @@ public constant minEink: Dict { 10: 0, 11: 0, 12: 0 - } + }; from 2001-01-01 = { 1: 120, @@ -785,7 +785,7 @@ public constant minEink: Dict { 10: 730, 11: 1000, 12: 1175 - } + }; from 2009-01-01 = { 1: 205, @@ -800,7 +800,7 @@ public constant minEink: Dict { 10: 805, 11: 1085, 12: 1255 - } + }; # Reference: Art. 1 G. v. 08.10.2015 BGBl Nr.38, S.1617 from 2016-01-01 = { @@ -816,7 +816,7 @@ public constant minEink: Dict { 10: 832, 11: 1085, 12: 1255 - } + }; # reference: Art. 1 G. v. 30.11.2019 BGBl. I S. 1877 from 2020-01-01 = { @@ -832,7 +832,7 @@ public constant minEink: Dict { 10: 957, 11: 1248, 12: 1443 - } + }; # Reference: Art. 1 G. v. 08.12.2022 BGBl. I Nr. 48 S. 2160 from 2023-01-01 = { @@ -848,7 +848,7 @@ public constant minEink: Dict { 10: 2200, 11: 2400, 12: 2600 - } + }; } /** @@ -859,24 +859,24 @@ public constant freibetragKinder: Dict { from 1984-01-01 = { alleinerz: 51, arbeitendes_kind: 0 - } + }; from 2001-01-01 = { # deviation_from: previous arbeitendes_kind: 51 - } + }; from 2002-01-01 = { alleinerz: 50, arbeitendes_kind: 50 - } + }; # Reference: Art. 1 G. v. 08.10.2015 BGBl Nr.38, S.1617 # Neu §17 3. WoGG a) Alleinerziehend b) Kind unter 18 und neu §17 4. WoGG Kind noch nicht 25J. from 2016-01-01 = { alleinerz: 110, arbeitendes_kind: 100 - } + }; } /** @@ -893,31 +893,31 @@ public constant freibetragBehinderung: Dict or Int { 0: 0, 1: 0, 80: 1224 - } + }; from 1986-01-01 = { # deviation_from: previous 80: 612 - } + }; from 1991-01-01 = { 0: 0, 1: 1224, 80: 1536 - } + }; from 2002-01-01 = { 0: 0, 1: 1200, 80: 1500 - } + }; # Reference: 2 Art. 1 G. v. 08.10.2015 BGBl Nr.38 S.1612 # neue Regelung - §17 1. WoGG a) GDB = 100 b) GDB < 100 & pflegebedürftig gem. §14 SGB XI. + gleichz. Häusliche/teilstationäre/Kurzzeit-Pflege - from 2016-01-01 = 1500 + from 2016-01-01 = 1500; # Reference: Art. 1 G. v. 30.11.2019 BGBl. I S. 1877 - from 2020-01-01 = 1800 + from 2020-01-01 = 1800; } # TODO: DEVIATION FROM BEISPIEL!!! @@ -932,7 +932,7 @@ public constant behinderungsgrad: Dict { from 1984-01-01 = { 1: 0, 2: 80 - } + }; } /** From 6ad01731590a681dc46323d55ea5996aba533465 Mon Sep 17 00:00:00 2001 From: alex-senger Date: Mon, 9 Sep 2024 16:05:35 +0200 Subject: [PATCH 173/183] fix typehints --- .../parameters/arbeitslosengeld2.ttsl | 342 +++++++++--------- 1 file changed, 173 insertions(+), 169 deletions(-) diff --git a/src/resources/builtins/parameters/arbeitslosengeld2.ttsl b/src/resources/builtins/parameters/arbeitslosengeld2.ttsl index 15afa62e..c5b9db5b 100644 --- a/src/resources/builtins/parameters/arbeitslosengeld2.ttsl +++ b/src/resources/builtins/parameters/arbeitslosengeld2.ttsl @@ -136,168 +136,172 @@ public constant anrechnungsfreieEinkommensanteileFallsKinder: Dict { - from 2005-01-01 = 338; - - # Reference: B. v. 01.09.2005 BGBl. I S. 2718. - # Betrag unverändert. Der tatsächliche Wert unterscheidet sich zwischen Ost und West. Hier wurde vereinfachend 338 Euro als ungewichteter Mittelwert genommen. Korrekte Werte für die Zeit ab 1. Juli 2005 sind in den alten Bundesländern einschließlich Berlin (Ost) 345 Euro, in den neuen Bundesländern 331 Euro. - from 2005-07-01 = 338; - - # Reference: B. v. 20.07.2006 BGBl. I S. 1702. - from 2006-07-01 = 345; - - # Reference: B. v. 18.06.2007 BGBl. I S. 1139. - from 2007-07-01 = 347; - - # Reference: B. v. 26.06.2008 BGBl. I S. 1102. - from 2008-07-01 = 351; - - # Reference: B. v. 17.06.2009 BGBl. I S. 1342. - from 2009-07-01 = 359; - - # Reference: B. v. 07.06.2010 BGBl. I S. 820. Betrag unverändert. - from 2010-07-01 = 359; - - # Reference: Artikel 1 G. v. 24.03.2011 BGBl. I S. 453. - from 2011-01-01 = { - 1: 364, - 2: 328, - 3: 291, - 4: 287, - 5: 251, - 6: 215, - }; - - # Reference: V. v. 20.10.2011 BGBl. I S. 2093. - from 2012-01-01 = { - 1: 374, - 2: 337, - 3: 299, - 4: 287, - 5: 251, - 6: 219, - }; - - # Reference: B. v. 18.10.2012 BGBl. I S. 2175. - from 2013-01-01 = { - 1: 382, - 2: 345, - 3: 306, - 4: 289, - 5: 255, - 6: 224, - }; - - # Reference: B. v. 16.10.2013 BGBl. I S. 3857. - from 2014-01-01 = { - 1: 391, - 2: 353, - 3: 313, - 4: 296, - 5: 261, - 6: 229, - }; - - # Reference: B. v. 15.10.2014 BGBl. I S. 1620. - from 2015-01-01 = { - 1: 399, - 2: 360, - 3: 320, - 4: 302, - 5: 267, - 6: 234, - }; - - # Reference: B. v. 22.10.2015 BGBl. I S. 1792. - from 2016-01-01 = { - 1: 404, - 2: 364, - 3: 324, - 4: 306, - 5: 270, - 6: 237, - }; - - # Reference: G. v. 22.12.2016 BGBl. I S. 3159. - from 2017-01-01 = { - 1: 409, - 2: 368, - 3: 327, - 4: 311, - 5: 291, - 6: 236, - }; - - # Reference: V. v. 08.11.2017 BGBl. I S. 3767. - from 2018-01-01 = { - 1: 416, - 2: 374, - 3: 332, - 4: 316, - 5: 296, - 6: 240, - }; - - # Reference: V. v. 19.10.2018 BGBl. I S. 1766. - from 2019-01-01 = { - 1: 424, - 2: 382, - 3: 339, - 4: 322, - 5: 302, - 6: 245, - }; - - # Reference: V. v. 18.10.2019 BGBl. I S. 1452. - from 2020-01-01 = { - 1: 432, - 2: 389, - 3: 345, - 4: 328, - 5: 308, - 6: 250 - }; - - # Reference: G. v. 09.12.2020 BGBl. I S. 2855. - from 2021-01-01 = { - 1: 446, - 2: 401, - 3: 357, - 4: 373, - 5: 309, - 6: 283 - }; - - # Reference: V. v. 13.10.2021 BGBl. I S. 4674. - from 2022-01-01 = { - 1: 449, - 2: 404, - 3: 360, - 4: 376, - 5: 311, - 6: 285 - }; - - # Reference: G. v. 20.12.2022 BGBl. I S. 2328. - # Bürgergeld-Gesetz - from 2023-01-01 = { - 1: 502, - 2: 451, - 3: 402, - 4: 420, - 5: 348, - 6: 318 - }; - - # Reference: §2 V. v. 24.10.2024 BGBl. I Nr. 287 - from 2024-01-01 = { - 1: 563, - 2: 506, - 3: 451, - 4: 471, - 5: 390, - 6: 357 - }; +public constant regelsatz { + Int { + from 2005-01-01 = 338; + + # Reference: B. v. 01.09.2005 BGBl. I S. 2718. + # Betrag unverändert. Der tatsächliche Wert unterscheidet sich zwischen Ost und West. Hier wurde vereinfachend 338 Euro als ungewichteter Mittelwert genommen. Korrekte Werte für die Zeit ab 1. Juli 2005 sind in den alten Bundesländern einschließlich Berlin (Ost) 345 Euro, in den neuen Bundesländern 331 Euro. + from 2005-07-01 = 338; + + # Reference: B. v. 20.07.2006 BGBl. I S. 1702. + from 2006-07-01 = 345; + + # Reference: B. v. 18.06.2007 BGBl. I S. 1139. + from 2007-07-01 = 347; + + # Reference: B. v. 26.06.2008 BGBl. I S. 1102. + from 2008-07-01 = 351; + + # Reference: B. v. 17.06.2009 BGBl. I S. 1342. + from 2009-07-01 = 359; + + # Reference: B. v. 07.06.2010 BGBl. I S. 820. Betrag unverändert. + from 2010-07-01 = 359; + } + + Dict { + # Reference: Artikel 1 G. v. 24.03.2011 BGBl. I S. 453. + from 2011-01-01 = { + 1: 364, + 2: 328, + 3: 291, + 4: 287, + 5: 251, + 6: 215, + }; + + # Reference: V. v. 20.10.2011 BGBl. I S. 2093. + from 2012-01-01 = { + 1: 374, + 2: 337, + 3: 299, + 4: 287, + 5: 251, + 6: 219, + }; + + # Reference: B. v. 18.10.2012 BGBl. I S. 2175. + from 2013-01-01 = { + 1: 382, + 2: 345, + 3: 306, + 4: 289, + 5: 255, + 6: 224, + }; + + # Reference: B. v. 16.10.2013 BGBl. I S. 3857. + from 2014-01-01 = { + 1: 391, + 2: 353, + 3: 313, + 4: 296, + 5: 261, + 6: 229, + }; + + # Reference: B. v. 15.10.2014 BGBl. I S. 1620. + from 2015-01-01 = { + 1: 399, + 2: 360, + 3: 320, + 4: 302, + 5: 267, + 6: 234, + }; + + # Reference: B. v. 22.10.2015 BGBl. I S. 1792. + from 2016-01-01 = { + 1: 404, + 2: 364, + 3: 324, + 4: 306, + 5: 270, + 6: 237, + }; + + # Reference: G. v. 22.12.2016 BGBl. I S. 3159. + from 2017-01-01 = { + 1: 409, + 2: 368, + 3: 327, + 4: 311, + 5: 291, + 6: 236, + }; + + # Reference: V. v. 08.11.2017 BGBl. I S. 3767. + from 2018-01-01 = { + 1: 416, + 2: 374, + 3: 332, + 4: 316, + 5: 296, + 6: 240, + }; + + # Reference: V. v. 19.10.2018 BGBl. I S. 1766. + from 2019-01-01 = { + 1: 424, + 2: 382, + 3: 339, + 4: 322, + 5: 302, + 6: 245, + }; + + # Reference: V. v. 18.10.2019 BGBl. I S. 1452. + from 2020-01-01 = { + 1: 432, + 2: 389, + 3: 345, + 4: 328, + 5: 308, + 6: 250 + }; + + # Reference: G. v. 09.12.2020 BGBl. I S. 2855. + from 2021-01-01 = { + 1: 446, + 2: 401, + 3: 357, + 4: 373, + 5: 309, + 6: 283 + }; + + # Reference: V. v. 13.10.2021 BGBl. I S. 4674. + from 2022-01-01 = { + 1: 449, + 2: 404, + 3: 360, + 4: 376, + 5: 311, + 6: 285 + }; + + # Reference: G. v. 20.12.2022 BGBl. I S. 2328. + # Bürgergeld-Gesetz + from 2023-01-01 = { + 1: 502, + 2: 451, + 3: 402, + 4: 420, + 5: 348, + 6: 318 + }; + + # Reference: §2 V. v. 24.10.2024 BGBl. I Nr. 287 + from 2024-01-01 = { + 1: 563, + 2: 506, + 3: 451, + 4: 471, + 5: 390, + 6: 357 + }; + } } /** @@ -502,8 +506,8 @@ public constant berechtigteWohnflaecheMiete: Dict { * gestiegen und wird ab 5 Personen im Haushalt um 20 Quadratmeter pro Person * angehoben. */ -public constant berechtigteWohnflaecheEigentum: Dict { - from 1984-01-01 = { +public constant berechtigteWohnflaecheEigentum { + from 1984-01-01: Dict = { 1: 80, 2: 80, 3: 100, @@ -512,11 +516,11 @@ public constant berechtigteWohnflaecheEigentum: Dict { }; # Reference: Art. 1 Nr.12 Abschnitt 5, G. v. 20.12.2022 BGBl. I S. 2328 - from 2023-01-01 = { - 1: 140, - 2: 140, - 3: 140, - 4: 140, + from 2023-01-01: Dict = { + "1": 140, + "2": 140, + "3": 140, + "4": 140, "je_weitere_person": 20 }; } From 2349478e3d07d2fba901e59558caae18cbdbc843 Mon Sep 17 00:00:00 2001 From: alex-senger Date: Mon, 9 Sep 2024 16:07:24 +0200 Subject: [PATCH 174/183] fix typehints --- .../parameters/einkommenssteuerAbzuege.ttsl | 174 +++++++++--------- 1 file changed, 90 insertions(+), 84 deletions(-) diff --git a/src/resources/builtins/parameters/einkommenssteuerAbzuege.ttsl b/src/resources/builtins/parameters/einkommenssteuerAbzuege.ttsl index b34c77fb..a24418fb 100644 --- a/src/resources/builtins/parameters/einkommenssteuerAbzuege.ttsl +++ b/src/resources/builtins/parameters/einkommenssteuerAbzuege.ttsl @@ -230,49 +230,53 @@ public constant vorsorge2004Grundhoechstbetrag: Int { * haben, maximal den gleichen Altersentlastungsbetrag. Ab 2005 hängt dieser Betrag, * den diese Steuerpflichtigen erhalten, vom Geburtsjahr ab. */ -public constant altersentlastungsbetragMax: Int or Dict { - from 1984-01-01 = 1534; - from 1989-01-01 = 1902; - from 2002-01-01 = 1908; - - # Reference: Artikel 1 G. v. 05.07.2004 BGBl. I S. 1427. - 2005-01-01 = { - 1940: 1900, - 1941: 1824, - 1942: 1748, - 1943: 1672, - 1944: 1596, - 1945: 1520, - 1946: 1444, - 1947: 1368, - 1948: 1292, - 1949: 1216, - 1950: 1140, - 1951: 1064, - 1952: 988, - 1953: 912, - 1954: 836, - 1955: 760, - 1956: 722, - 1957: 684, - 1958: 646, - 1959: 608, - 1960: 570, - 1961: 532, - 1962: 494, - 1963: 456, - 1964: 418, - 1965: 380, - 1966: 342, - 1967: 304, - 1968: 266, - 1969: 228, - 1970: 190, - 1971: 152, - 1972: 114, - 1973: 76, - 1974: 38, - 1975: 0 +public constant altersentlastungsbetragMax { + Int { + from 1984-01-01 = 1534; + from 1989-01-01 = 1902; + from 2002-01-01 = 1908; + }; + + Dict { + # Reference: Artikel 1 G. v. 05.07.2004 BGBl. I S. 1427. + 2005-01-01 = { + 1940: 1900, + 1941: 1824, + 1942: 1748, + 1943: 1672, + 1944: 1596, + 1945: 1520, + 1946: 1444, + 1947: 1368, + 1948: 1292, + 1949: 1216, + 1950: 1140, + 1951: 1064, + 1952: 988, + 1953: 912, + 1954: 836, + 1955: 760, + 1956: 722, + 1957: 684, + 1958: 646, + 1959: 608, + 1960: 570, + 1961: 532, + 1962: 494, + 1963: 456, + 1964: 418, + 1965: 380, + 1966: 342, + 1967: 304, + 1968: 266, + 1969: 228, + 1970: 190, + 1971: 152, + 1972: 114, + 1973: 76, + 1974: 38, + 1975: 0 + }; }; } @@ -283,47 +287,49 @@ public constant altersentlastungsbetragMax: Int or Dict { * haben, die gleiche Altersentlastungsquote abgezogen. Ab 2005 hängt diese Quote, * den diese Steuerpflichtigen erhalten, vom Geburtsjahr ab. */ -public constant altersentlastungQuote: Float or Dict { - from 1984-01-01 = 0.4; - - # Reference: Artikel 1 G. v. 05.07.2004 BGBl. I S. 1427. - 2005-01-01 = { - 1940: 0.4, - 1941: 0.384, - 1942: 0.368, - 1943: 0.352, - 1944: 0.336, - 1945: 0.32, - 1946: 0.304, - 1947: 0.288, - 1948: 0.272, - 1949: 0.256, - 1950: 0.24, - 1951: 0.224, - 1952: 0.208, - 1953: 0.192, - 1954: 0.176, - 1955: 0.16, - 1956: 0.152, - 1957: 0.144, - 1958: 0.136, - 1959: 0.128, - 1960: 0.12, - 1961: 0.112, - 1962: 0.104, - 1963: 0.096, - 1964: 0.088, - 1965: 0.08, - 1966: 0.072, - 1967: 0.064, - 1968: 0.056, - 1969: 0.048, - 1970: 0.04, - 1971: 0.032, - 1972: 0.024, - 1973: 0.016, - 1974: 0.008, - 1975: 0 +public constant altersentlastungQuote { + from 1984-01-01: Float = 0.4; + + Dict { + # Reference: Artikel 1 G. v. 05.07.2004 BGBl. I S. 1427. + from 2005-01-01 = { + 1940: 0.4, + 1941: 0.384, + 1942: 0.368, + 1943: 0.352, + 1944: 0.336, + 1945: 0.32, + 1946: 0.304, + 1947: 0.288, + 1948: 0.272, + 1949: 0.256, + 1950: 0.24, + 1951: 0.224, + 1952: 0.208, + 1953: 0.192, + 1954: 0.176, + 1955: 0.16, + 1956: 0.152, + 1957: 0.144, + 1958: 0.136, + 1959: 0.128, + 1960: 0.12, + 1961: 0.112, + 1962: 0.104, + 1963: 0.096, + 1964: 0.088, + 1965: 0.08, + 1966: 0.072, + 1967: 0.064, + 1968: 0.056, + 1969: 0.048, + 1970: 0.04, + 1971: 0.032, + 1972: 0.024, + 1973: 0.016, + 1974: 0.008, + 1975: 0 + }; }; } From 882fe1a4d2b9de716ad2e878eb9df6383800d3ab Mon Sep 17 00:00:00 2001 From: alex-senger Date: Mon, 9 Sep 2024 16:53:25 +0200 Subject: [PATCH 175/183] split vertrauensschutz constants --- .../builtins/parameters/gesetzlicheRente.ttsl | 1547 +++++++++-------- 1 file changed, 791 insertions(+), 756 deletions(-) diff --git a/src/resources/builtins/parameters/gesetzlicheRente.ttsl b/src/resources/builtins/parameters/gesetzlicheRente.ttsl index 499ba5b4..4114c27a 100644 --- a/src/resources/builtins/parameters/gesetzlicheRente.ttsl +++ b/src/resources/builtins/parameters/gesetzlicheRente.ttsl @@ -696,417 +696,12 @@ public constant renteFrauenPflichtbeitrag: Int { * bezogen werden kann. * Reference: § 237 SGB VI */ -public constant altersgrenzeArbeitslosigkeitAbschlagsfrei: Float or Dict> { - from 1980-01-01 = 60.0; +public constant altersgrenzeArbeitslosigkeitAbschlagsfrei { + from 1980-01-01: Float = 60.0; - from 1992-01-01 = { - 0: 60.0, - 1941: { - 1: 60.083333, - 2: 60.083333, - 3: 60.083333, - 4: 60.083333, - 5: 60.166667, - 6: 60.166667, - 7: 60.166667, - 8: 60.166667, - 9: 60.25, - 10: 60.25, - 11: 60.25, - 12: 60.25, - }, - 1942: { - 1: 60.333333, - 2: 60.333333, - 3: 60.333333, - 4: 60.333333, - 5: 60.416667, - 6: 60.416667, - 7: 60.416667, - 8: 60.416667, - 9: 60.5, - 10: 60.5, - 11: 60.5, - 12: 60.5, - }, - 1943: { - 1: 60.583333, - 2: 60.583333, - 3: 60.583333, - 4: 60.583333, - 5: 60.666667, - 6: 60.666667, - 7: 60.666667, - 8: 60.666667, - 9: 60.75, - 10: 60.75, - 11: 60.75, - 12: 60.75, - }, - 1944: { - 1: 60.833333, - 2: 60.833333, - 3: 60.833333, - 4: 60.833333, - 5: 61.916667, - 6: 61.916667, - 7: 61.916667, - 8: 61.916667, - 9: 61.0, - 10: 61, - 11: 61, - 12: 61, - }, - 1945: { - 1: 61.083333, - 2: 61.083333, - 3: 61.166667, - 4: 61.166667, - 5: 61.25, - 6: 61.25, - 7: 61.333333, - 8: 61.333333, - 9: 61.416667, - 10: 61.416667, - 11: 61.5, - 12: 61.5, - }, - 1946: { - 1: 61.583333, - 2: 61.583333, - 3: 61.666667, - 4: 61.666667, - 5: 61.75, - 6: 61.75, - 7: 61.833333, - 8: 61.833333, - 9: 61.916667, - 10: 61.916667, - 11: 62.0, - 12: 62.0, - }, - 1947: { - 1: 62.083333, - 2: 62.083333, - 3: 62.166667, - 4: 62.166667, - 5: 62.25, - 6: 62.25, - 7: 62.333333, - 8: 62.333333, - 9: 62.416667, - 10: 62.416667, - 11: 62.5, - 12: 62.5, - }, - 1948: { - 1: 62.583333, - 2: 62.583333, - 3: 62.666667, - 4: 62.666667, - 5: 62.75, - 6: 62.75, - 7: 62.833333, - 8: 62.833333, - 9: 62.916667, - 10: 62.916667, - 11: 63.0, - 12: 63.0, - }, - 1949: { - 1: 63.083333, - 2: 63.083333, - 3: 63.166667, - 4: 63.166667, - 5: 63.25, - 6: 63.25, - 7: 63.333333, - 8: 63.333333, - 9: 63.416667, - 10: 63.416667, - 11: 63.5, - 12: 63.5, - }, - 1950: { - 1: 63.583333, - 2: 63.583333, - 3: 63.666667, - 4: 63.666667, - 5: 63.75, - 6: 63.75, - 7: 63.833333, - 8: 63.833333, - 9: 63.916667, - 10: 63.916667, - 11: 64.0, - 12: 64.0, - }, - 1951: { - 1: 64.083333, - 2: 64.083333, - 3: 64.166667, - 4: 64.166667, - 5: 64.25, - 6: 64.25, - 7: 64.333333, - 8: 64.333333, - 9: 64.416667, - 10: 64.416667, - 11: 64.5, - 12: 64.5, - }, - 1952: { - 1: 64.583333, - 2: 64.583333, - 3: 64.666667, - 4: 64.666667, - 5: 64.75, - 6: 64.75, - 7: 64.833333, - 8: 64.833333, - 9: 64.916667, - 10: 64.916667, - 11: 65.0, - 12: 65.0, - }, - }; - - from 1996-07-29 = { - 0: 60.0, - 1937: { - 1: 60.083333, - 2: 60.166667, - 3: 60.25, - 4: 60.333333, - 5: 60.416667, - 6: 60.5, - 7: 60.583333, - 8: 60.666667, - 9: 60.75, - 10: 60.833333, - 11: 60.916667, - 12: 61.0, - }, - 1938: { - 1: 61.083333, - 2: 61.166667, - 3: 61.25, - 4: 61.333333, - 5: 61.416667, - 6: 61.5, - 7: 61.583333, - 8: 61.666667, - 9: 61.75, - 10: 61.833333, - 11: 61.916667, - 12: 62.0, - }, - 1939: { - 1: 62.083333, - 2: 62.166667, - 3: 62.25, - 4: 62.333333, - 5: 62.416667, - 6: 62.5, - 7: 62.583333, - 8: 62.666667, - 9: 62.75, - 10: 62.833333, - 11: 62.916667, - 12: 63.0, - }, - 1940: { - 1: 63.0, - 2: 63.0, - 3: 63.0, - 4: 63.0, - 5: 63.0, - 6: 63.0, - 7: 63.0, - 8: 63.0, - 9: 63.0, - 10: 63.0, - 11: 63.0, - 12: 63.0, - }, - 1941: { - 1: 63.0, - 2: 63.0, - 3: 63.0, - 4: 63.0, - 5: 63.0, - 6: 63.0, - 7: 63.0, - 8: 63.0, - 9: 63.0, - 10: 63.0, - 11: 63.0, - 12: 63.0, - }, - 1942: { - 1: 63.0, - 2: 63.0, - 3: 63.0, - 4: 63.0, - 5: 63.0, - 6: 63.0, - 7: 63.0, - 8: 63.0, - 9: 63.0, - 10: 63.0, - 11: 63.0, - 12: 63.0, - }, - 1943: { - 1: 63.0, - 2: 63.0, - 3: 63.0, - 4: 63.0, - 5: 63.0, - 6: 63.0, - 7: 63.0, - 8: 63.0, - 9: 63.0, - 10: 63.0, - 11: 63.0, - 12: 63.0, - }, - 1944: { - 1: 63.0, - 2: 63.0, - 3: 63.0, - 4: 63.0, - 5: 63.0, - 6: 63.0, - 7: 63.0, - 8: 63.0, - 9: 63.0, - 10: 63.0, - 11: 63.0, - 12: 63.0, - }, - 1945: { - 1: 63.0, - 2: 63.0, - 3: 63.0, - 4: 63.0, - 5: 63.0, - 6: 63.0, - 7: 63.0, - 8: 63.0, - 9: 63.0, - 10: 63.0, - 11: 63.0, - 12: 63.0, - }, - 1946: { - 1: 63.0, - 2: 63.0, - 3: 63.0, - 4: 63.0, - 5: 63.0, - 6: 63.0, - 7: 63.0, - 8: 63.0, - 9: 63.0, - 10: 63.0, - 11: 63.0, - 12: 63.0, - }, - 1947: { - 1: 63.0, - 2: 63.0, - 3: 63.0, - 4: 63.0, - 5: 63.0, - 6: 63.0, - 7: 63.0, - 8: 63.0, - 9: 63.0, - 10: 63.0, - 11: 63.0, - 12: 63.0, - }, - 1948: { - 1: 63.0, - 2: 63.0, - 3: 63.0, - 4: 63.0, - 5: 63.0, - 6: 63.0, - 7: 63.0, - 8: 63.0, - 9: 63.0, - 10: 63.0, - 11: 63.0, - 12: 63.0, - }, - 1949: { - 1: 63.083333, - 2: 63.083333, - 3: 63.166667, - 4: 63.166667, - 5: 63.25, - 6: 63.25, - 7: 63.333333, - 8: 63.333333, - 9: 63.416667, - 10: 63.416667, - 11: 63.5, - 12: 63.5, - }, - 1950: { - 1: 63.583333, - 2: 63.583333, - 3: 63.666667, - 4: 63.666667, - 5: 63.75, - 6: 63.75, - 7: 63.833333, - 8: 63.833333, - 9: 63.916667, - 10: 63.916667, - 11: 64.0, - 12: 64.0, - }, - 1951: { - 1: 64.083333, - 2: 64.083333, - 3: 64.166667, - 4: 64.166667, - 5: 64.25, - 6: 64.25, - 7: 64.333333, - 8: 64.333333, - 9: 64.416667, - 10: 64.416667, - 11: 64.5, - 12: 64.5, - }, - 1952: { - 1: 64.583333, - 2: 64.583333, - 3: 64.666667, - 4: 64.666667, - 5: 64.75, - 6: 64.75, - 7: 64.833333, - 8: 64.833333, - 9: 64.916667, - 10: 64.916667, - 11: 65.0, - 12: 65.0, - }, - /* - Altersgrenze für Altersrente wegen Arbeitslosigkeit mit Vertrauensschutz - (abschlagsfrei). - Increase of full retirement age according to old law (RRG 1992) for individuals - covered under Vertrauensschutz. - Reference: § 237 SGB VI Abs. 4 - */ - "vertrauensschutz": { - "max_birthyear_old_regime": 1940, - "entry_age_old_regime": 60.0, + Dict> { + from 1992-01-01 = { + 0: 60.0, 1941: { 1: 60.083333, 2: 60.083333, @@ -1152,392 +747,832 @@ public constant altersgrenzeArbeitslosigkeitAbschlagsfrei: Float or Dict>{ - from 1980-01-01 = 60.0; - - # Increase of early retirement age from 60 to 62 for birth cohort 1949-1952. - # Reference: Rentenreformgesetz 1992. BGBl. I S. 2261 1989 § 41 - from 1992-01-01 = { - "max_birthyear_old_regime": 1948, - "min_birthyear_new_regime": 1953, - "entry_age_old_regime": 60.0, - "entry_age_new_regime": 62.0, - 1949: { +public constant altersgrenzeArbeitslosigkeitAbschlagsfreiVertrauensschutz: Dict> { + /* + Altersgrenze für Altersrente wegen Arbeitslosigkeit mit Vertrauensschutz + (abschlagsfrei). + Increase of full retirement age according to old law (RRG 1992) for individuals + covered under Vertrauensschutz. + Reference: § 237 SGB VI Abs. 4 + */ + from 1996-07-29 { + 1941: { 1: 60.083333, 2: 60.083333, - 3: 60.166667, - 4: 60.166667, - 5: 60.25, - 6: 60.25, - 7: 60.333333, - 8: 60.333333, - 9: 60.416667, - 10: 60.416667, + 3: 60.083333, + 4: 60.083333, + 5: 60.166667, + 6: 60.166667, + 7: 60.166667, + 8: 60.166667, + 9: 60.25, + 10: 60.25, + 11: 60.25, + 12: 60.25, + }, + 1942: { + 1: 60.333333, + 2: 60.333333, + 3: 60.333333, + 4: 60.333333, + 5: 60.416667, + 6: 60.416667, + 7: 60.416667, + 8: 60.416667, + 9: 60.5, + 10: 60.5, 11: 60.5, 12: 60.5, }, - 1950: { + 1943: { 1: 60.583333, 2: 60.583333, - 3: 60.666667, - 4: 60.666667, - 5: 60.75, - 6: 60.75, - 7: 60.833333, - 8: 60.833333, - 9: 60.916667, - 10: 60.916667, - 11: 61.0, - 12: 61.0, - }, - 1951: { - 1: 61.083333, - 2: 61.083333, - 3: 61.166667, - 4: 61.166667, - 5: 61.25, - 6: 61.25, - 7: 61.333333, - 8: 61.333333, - 9: 61.416667, - 10: 61.416667, - 11: 61.5, - 12: 61.5, + 3: 60.583333, + 4: 60.583333, + 5: 60.666667, + 6: 60.666667, + 7: 60.666667, + 8: 60.666667, + 9: 60.75, + 10: 60.75, + 11: 60.75, + 12: 60.75, }, - 1952: { - 1: 61.583333, - 2: 61.583333, - 3: 61.666667, - 4: 61.666667, - 5: 61.75, - 6: 61.75, - 7: 61.833333, - 8: 61.833333, - 9: 61.916667, - 10: 61.916667, - 11: 62.0, - 12: 62.0, + 1944: { + 1: 60.833333, + 2: 60.833333, }, }; - # Increase of early retirement age from 60 to 65 for birth cohort 1937-1941. - # Reference: Wachstums- und Beschäftigungsförderungsgesetz 1996. BGBl. I S. 1461 1996 - from 1996-07-29 = { - "max_birthyear_old_regime": 1948, - "min_birthyear_new_regime": 1953, - "entry_age_old_regime": 60.0, - "entry_age_new_regime": 62.0, - 1949: { + /* + Altersgrenze für Altersrente wegen Arbeitslosigkeit mit Vertrauensschutz + (abschlagsfrei). + Increase of full retirement age according to old law (RRG 1992) for individuals + covered under Vertrauensschutz. + Reference: § 237 SGB VI Abs. 4 + */ + from 1996-09-27 = { + 1941: { 1: 60.083333, 2: 60.083333, - 3: 60.166667, - 4: 60.166667, - 5: 60.25, - 6: 60.25, - 7: 60.333333, - 8: 60.333333, - 9: 60.416667, - 10: 60.416667, + 3: 60.083333, + 4: 60.083333, + 5: 60.166667, + 6: 60.166667, + 7: 60.166667, + 8: 60.166667, + 9: 60.25, + 10: 60.25, + 11: 60.25, + 12: 60.25, + }, + 1942: { + 1: 60.333333, + 2: 60.333333, + 3: 60.333333, + 4: 60.333333, + 5: 60.416667, + 6: 60.416667, + 7: 60.416667, + 8: 60.416667, + 9: 60.5, + 10: 60.5, 11: 60.5, 12: 60.5, }, - 1950: { + 1943: { 1: 60.583333, 2: 60.583333, - 3: 60.666667, - 4: 60.666667, - 5: 60.75, - 6: 60.75, - 7: 60.833333, - 8: 60.833333, - 9: 60.916667, - 10: 60.916667, - 11: 61.0, - 12: 61.0, - }, - 1951: { - 1: 61.083333, - 2: 61.083333, - 3: 61.166667, - 4: 61.166667, - 5: 61.25, - 6: 61.25, - 7: 61.333333, - 8: 61.333333, - 9: 61.416667, - 10: 61.416667, - 11: 61.5, - 12: 61.5, + 3: 60.583333, + 4: 60.583333, + 5: 60.666667, + 6: 60.666667, + 7: 60.666667, + 8: 60.666667, + 9: 60.75, + 10: 60.75, + 11: 60.75, + 12: 60.75, }, - 1952: { - 1: 61.583333, - 2: 61.583333, - 3: 61.666667, - 4: 61.666667, - 5: 61.75, - 6: 61.75, - 7: 61.833333, - 8: 61.833333, - 9: 61.916667, - 10: 61.916667, - 11: 62.0, - 12: 62.0, + 1944: { + 1: 60.833333, + 2: 60.833333, }, - "vertrauensschutz": 60.0, }; +} - # Increase of ERA was revoked. - # Reference: Wachstums- und Beschäftigungsförderungsgesetz 1996. BGBl. I S. 1461 1996 +public const altersgrenzeArbeitslosigkeitAbschlagsfreiVertrauensschutzMaxBirthyearOldRegime: Int { + from 1996-07-29 = 1940; +} + +public const altersgrenzeArbeitslosigkeitAbschlagsfreiVertrauensschutzEntryAgeOldRegime: Float{ + from 1996-07-29 = 60.0; +} + +public const altersgrenzeArbeitslosigkeitAbschlagsfreiMaxBirthyearOldRegime: Int { + from 1996-09-27 = 1936; +} + +public const altersgrenzeArbeitslosigkeitAbschlagsfreiMinBirthyearNewRegime: Int { + from 1996-09-27 = 1942; +} + +public const altersgrenzeArbeitslosigkeitAbschlagsfreiEntryAgeOldRegime: Float { from 1996-09-27 = 60.0; +} - from 2004-07-26 = { - "max_birthyear_old_regime": 1945, - "min_birthyear_new_regime": 1949, - "entry_age_old_regime": 60.0, - "entry_age_new_regime": 63.0, - 1946: { - 1: 60.083333, - 2: 60.166667, - 3: 60.25, - 4: 60.333333, - 5: 60.416667, - 6: 60.5, - 7: 60.583333, - 8: 60.666667, - 9: 60.75, - 10: 60.833333, - 11: 60.916667, - 12: 61.0, - }, - 1947: { - 1: 61.083333, - 2: 61.166667, - 3: 61.25, - 4: 61.333333, - 5: 61.416667, - 6: 61.5, - 7: 61.583333, - 8: 61.666667, - 9: 61.75, - 10: 61.833333, - 11: 61.916667, - 12: 62.0, - }, - 1948: { - 1: 62.083333, - 2: 62.166667, - 3: 62.25, - 4: 62.333333, - 5: 62.416667, - 6: 62.5, - 7: 62.583333, - 8: 62.666667, - 9: 62.75, - 10: 62.833333, - 11: 62.916667, - 12: 63.0, - }, - "vertrauensschutz": 60.0, +public const altersgrenzeArbeitslosigkeitAbschlagsfreiEntryAgeNewRegime: Float { + from 1996-09-27 = 65.0; +} + + +public const altersgrenzeArbeitslosigkeitVorzeitigMaxBirthYearOldRegime: Int { + from 1992-01-01 = 1948; + from 2004-07-26 = 1945; +} + +public const altersgrenzeArbeitslosigkeitVorzeitigMinBirthYearNewRegime: Int { + from 1992-01-01 = 1953; + from 2004-07-26 = 1949; +} + +public const altersgrenzeArbeitslosigkeitVorzeitigEntryAgeOldRegime: Float { + from 1992-01-01 = 60.0; + from 2004-07-26 = 60.0 +} + +public const altersgrenzeArbeitslosigkeitVorzeitigEntryAgeNewRegime: Float { + from 1992-01-01 = 62.0; + from 2004-07-26 = 63.0; +} + +public constant altersgrenzeArbeitslosigkeitVorzeitigVertrauensschutz: Float { + from 1996-07-29 = 60.0; +} + +public constant altersgrenzeArbeitslosigkeitVorzeitigFirstBirthyearWithoutRenteFürArbeitslose: Int { + from 2004-07-26 = 1952; +} + +/** + * Altersgrenze für vorzeitige Inanspruchnahme Altersrente wegen Arbeitslosigkeit + * Frühestmögliches Alter ab dem die Altersrente für Arbeitslose + * bezogen werden kann (mit Abschlägen), einschließlich Vertrauensschutz. + * Reference: § 237 SGB VI + */ +public constant altersgrenzeArbeitslosigkeitVorzeitig: Float or Dict>{ + from 1980-01-01: Float = 60.0; + + Dict> { + # Increase of early retirement age from 60 to 62 for birth cohort 1949-1952. + # Reference: Rentenreformgesetz 1992. BGBl. I S. 2261 1989 § 41 + from 1992-01-01 = { + 1949: { + 1: 60.083333, + 2: 60.083333, + 3: 60.166667, + 4: 60.166667, + 5: 60.25, + 6: 60.25, + 7: 60.333333, + 8: 60.333333, + 9: 60.416667, + 10: 60.416667, + 11: 60.5, + 12: 60.5, + }, + 1950: { + 1: 60.583333, + 2: 60.583333, + 3: 60.666667, + 4: 60.666667, + 5: 60.75, + 6: 60.75, + 7: 60.833333, + 8: 60.833333, + 9: 60.916667, + 10: 60.916667, + 11: 61.0, + 12: 61.0, + }, + 1951: { + 1: 61.083333, + 2: 61.083333, + 3: 61.166667, + 4: 61.166667, + 5: 61.25, + 6: 61.25, + 7: 61.333333, + 8: 61.333333, + 9: 61.416667, + 10: 61.416667, + 11: 61.5, + 12: 61.5, + }, + 1952: { + 1: 61.583333, + 2: 61.583333, + 3: 61.666667, + 4: 61.666667, + 5: 61.75, + 6: 61.75, + 7: 61.833333, + 8: 61.833333, + 9: 61.916667, + 10: 61.916667, + 11: 62.0, + 12: 62.0, + }, + }; + + # Increase of early retirement age from 60 to 65 for birth cohort 1937-1941. + # Reference: Wachstums- und Beschäftigungsförderungsgesetz 1996. BGBl. I S. 1461 1996 + from 1996-07-29 = { + 1949: { + 1: 60.083333, + 2: 60.083333, + 3: 60.166667, + 4: 60.166667, + 5: 60.25, + 6: 60.25, + 7: 60.333333, + 8: 60.333333, + 9: 60.416667, + 10: 60.416667, + 11: 60.5, + 12: 60.5, + }, + 1950: { + 1: 60.583333, + 2: 60.583333, + 3: 60.666667, + 4: 60.666667, + 5: 60.75, + 6: 60.75, + 7: 60.833333, + 8: 60.833333, + 9: 60.916667, + 10: 60.916667, + 11: 61.0, + 12: 61.0, + }, + 1951: { + 1: 61.083333, + 2: 61.083333, + 3: 61.166667, + 4: 61.166667, + 5: 61.25, + 6: 61.25, + 7: 61.333333, + 8: 61.333333, + 9: 61.416667, + 10: 61.416667, + 11: 61.5, + 12: 61.5, + }, + 1952: { + 1: 61.583333, + 2: 61.583333, + 3: 61.666667, + 4: 61.666667, + 5: 61.75, + 6: 61.75, + 7: 61.833333, + 8: 61.833333, + 9: 61.916667, + 10: 61.916667, + 11: 62.0, + 12: 62.0, + } + }; }; - # Same statutory retirement ages as before, but abolishment with birth cohort 1952. - # Reference: RV-Nachhaltigkeitsgesetz 2004 and RV-Altersgrenzenanpassungsgesetz 2007. - from 2007-04-30 = { - "first_birthyear_without_rente_für_arbeitsl": 1952, - "max_birthyear_old_regime": 1945, - "min_birthyear_new_regime": 1949, - "entry_age_old_regime": 60.0, - "entry_age_new_regime": 63.0, - 1946: { - 1: 60.083333, - 2: 60.166667, - 3: 60.25, - 4: 60.333333, - 5: 60.416667, - 6: 60.5, - 7: 60.583333, - 8: 60.666667, - 9: 60.75, - 10: 60.833333, - 11: 60.916667, - 12: 61.0, - }, - 1947: { - 1: 61.083333, - 2: 61.166667, - 3: 61.25, - 4: 61.333333, - 5: 61.416667, - 6: 61.5, - 7: 61.583333, - 8: 61.666667, - 9: 61.75, - 10: 61.833333, - 11: 61.916667, - 12: 62.0, - }, - 1948: { - 1: 62.083333, - 2: 62.166667, - 3: 62.25, - 4: 62.333333, - 5: 62.416667, - 6: 62.5, - 7: 62.583333, - 8: 62.666667, - 9: 62.75, - 10: 62.833333, - 11: 62.916667, - 12: 63.0, - }, - "vertrauensschutz": 60.0, + # Increase of ERA was revoked. + # Reference: Wachstums- und Beschäftigungsförderungsgesetz 1996. BGBl. I S. 1461 1996 + from 1996-09-27: Float = 60.0; + + Dict> { + from 2004-07-26 = { + 1946: { + 1: 60.083333, + 2: 60.166667, + 3: 60.25, + 4: 60.333333, + 5: 60.416667, + 6: 60.5, + 7: 60.583333, + 8: 60.666667, + 9: 60.75, + 10: 60.833333, + 11: 60.916667, + 12: 61.0, + }, + 1947: { + 1: 61.083333, + 2: 61.166667, + 3: 61.25, + 4: 61.333333, + 5: 61.416667, + 6: 61.5, + 7: 61.583333, + 8: 61.666667, + 9: 61.75, + 10: 61.833333, + 11: 61.916667, + 12: 62.0, + }, + 1948: { + 1: 62.083333, + 2: 62.166667, + 3: 62.25, + 4: 62.333333, + 5: 62.416667, + 6: 62.5, + 7: 62.583333, + 8: 62.666667, + 9: 62.75, + 10: 62.833333, + 11: 62.916667, + 12: 63.0, + }, + }; + + # Same statutory retirement ages as before, but abolishment with birth cohort 1952. + # Reference: RV-Nachhaltigkeitsgesetz 2004 and RV-Altersgrenzenanpassungsgesetz 2007. + from 2007-04-30 = { + 1946: { + 1: 60.083333, + 2: 60.166667, + 3: 60.25, + 4: 60.333333, + 5: 60.416667, + 6: 60.5, + 7: 60.583333, + 8: 60.666667, + 9: 60.75, + 10: 60.833333, + 11: 60.916667, + 12: 61.0, + }, + 1947: { + 1: 61.083333, + 2: 61.166667, + 3: 61.25, + 4: 61.333333, + 5: 61.416667, + 6: 61.5, + 7: 61.583333, + 8: 61.666667, + 9: 61.75, + 10: 61.833333, + 11: 61.916667, + 12: 62.0, + }, + 1948: { + 1: 62.083333, + 2: 62.166667, + 3: 62.25, + 4: 62.333333, + 5: 62.416667, + 6: 62.5, + 7: 62.583333, + 8: 62.666667, + 9: 62.75, + 10: 62.833333, + 11: 62.916667, + 12: 63.0, + } + }; }; } From 147d8f92d66220a42000632a1ff65ab610cf8351 Mon Sep 17 00:00:00 2001 From: alex-senger Date: Sat, 14 Sep 2024 13:01:11 +0200 Subject: [PATCH 176/183] fix type hints --- .../builtins/parameters/gesetzlicheRente.ttsl | 28 +- .../sozialversicherungsbeitrag.ttsl | 760 ++--- .../builtins/parameters/wohngeld.ttsl | 2641 +++++++++-------- 3 files changed, 1644 insertions(+), 1785 deletions(-) diff --git a/src/resources/builtins/parameters/gesetzlicheRente.ttsl b/src/resources/builtins/parameters/gesetzlicheRente.ttsl index 4114c27a..1294e0f4 100644 --- a/src/resources/builtins/parameters/gesetzlicheRente.ttsl +++ b/src/resources/builtins/parameters/gesetzlicheRente.ttsl @@ -33,7 +33,7 @@ public constant altersVorsorgeAnteil: Float { * Beschäftigten, der geringfügig Beschäftigten und der Bezieher von ALG. * statistik-rente.de/drv */ -public constant beitragsvolumen: Dict { +public constant beitragsvolumen: Int { from 1991-01-01 = 108688000; from 1992-01-01 = 117359000; from 1993-01-01 = 120559000; @@ -1185,7 +1185,7 @@ public constant altersgrenzeArbeitslosigkeitAbschlagsfreiVertrauensschutz: Dict< covered under Vertrauensschutz. Reference: § 237 SGB VI Abs. 4 */ - from 1996-07-29 { + from 1996-07-29 = { 1941: { 1: 60.083333, 2: 60.083333, @@ -1291,47 +1291,47 @@ public constant altersgrenzeArbeitslosigkeitAbschlagsfreiVertrauensschutz: Dict< }; } -public const altersgrenzeArbeitslosigkeitAbschlagsfreiVertrauensschutzMaxBirthyearOldRegime: Int { +public constant altersgrenzeArbeitslosigkeitAbschlagsfreiVertrauensschutzMaxBirthyearOldRegime: Int { from 1996-07-29 = 1940; } -public const altersgrenzeArbeitslosigkeitAbschlagsfreiVertrauensschutzEntryAgeOldRegime: Float{ +public constant altersgrenzeArbeitslosigkeitAbschlagsfreiVertrauensschutzEntryAgeOldRegime: Float{ from 1996-07-29 = 60.0; } -public const altersgrenzeArbeitslosigkeitAbschlagsfreiMaxBirthyearOldRegime: Int { +public constant altersgrenzeArbeitslosigkeitAbschlagsfreiMaxBirthyearOldRegime: Int { from 1996-09-27 = 1936; } -public const altersgrenzeArbeitslosigkeitAbschlagsfreiMinBirthyearNewRegime: Int { +public constant altersgrenzeArbeitslosigkeitAbschlagsfreiMinBirthyearNewRegime: Int { from 1996-09-27 = 1942; } -public const altersgrenzeArbeitslosigkeitAbschlagsfreiEntryAgeOldRegime: Float { +public constant altersgrenzeArbeitslosigkeitAbschlagsfreiEntryAgeOldRegime: Float { from 1996-09-27 = 60.0; } -public const altersgrenzeArbeitslosigkeitAbschlagsfreiEntryAgeNewRegime: Float { +public constant altersgrenzeArbeitslosigkeitAbschlagsfreiEntryAgeNewRegime: Float { from 1996-09-27 = 65.0; } -public const altersgrenzeArbeitslosigkeitVorzeitigMaxBirthYearOldRegime: Int { +public constant altersgrenzeArbeitslosigkeitVorzeitigMaxBirthYearOldRegime: Int { from 1992-01-01 = 1948; from 2004-07-26 = 1945; } -public const altersgrenzeArbeitslosigkeitVorzeitigMinBirthYearNewRegime: Int { +public constant altersgrenzeArbeitslosigkeitVorzeitigMinBirthYearNewRegime: Int { from 1992-01-01 = 1953; from 2004-07-26 = 1949; } -public const altersgrenzeArbeitslosigkeitVorzeitigEntryAgeOldRegime: Float { +public constant altersgrenzeArbeitslosigkeitVorzeitigEntryAgeOldRegime: Float { from 1992-01-01 = 60.0; - from 2004-07-26 = 60.0 + from 2004-07-26 = 60.0; } -public const altersgrenzeArbeitslosigkeitVorzeitigEntryAgeNewRegime: Float { +public constant altersgrenzeArbeitslosigkeitVorzeitigEntryAgeNewRegime: Float { from 1992-01-01 = 62.0; from 2004-07-26 = 63.0; } @@ -1350,7 +1350,7 @@ public constant altersgrenzeArbeitslosigkeitVorzeitigFirstBirthyearWithoutRenteF * bezogen werden kann (mit Abschlägen), einschließlich Vertrauensschutz. * Reference: § 237 SGB VI */ -public constant altersgrenzeArbeitslosigkeitVorzeitig: Float or Dict>{ +public constant altersgrenzeArbeitslosigkeitVorzeitig { from 1980-01-01: Float = 60.0; Dict> { diff --git a/src/resources/builtins/parameters/sozialversicherungsbeitrag.ttsl b/src/resources/builtins/parameters/sozialversicherungsbeitrag.ttsl index ca265a8f..aad4d7a1 100644 --- a/src/resources/builtins/parameters/sozialversicherungsbeitrag.ttsl +++ b/src/resources/builtins/parameters/sozialversicherungsbeitrag.ttsl @@ -24,346 +24,196 @@ package sozialversicherungsbeitrag * * access_different_date: jahresanfang */ -public constant beitragssatz: Dict> { - from 1984-01-01 = { - "gesetzlicheKrankenversicherung": { - "mean_allgemein": 0.134 - }, - "gesetzlichePflegeversicherung": 0.0085, - "arbeitslosenversicherung": 0.0325, - "gesetzlicheRentenversicherung": 0.0975, - }; - - from 1985-01-01 = { - "gesetzlicheKrankenversicherung": { - "mean_allgemein": 0.118, - }, - "arbeitslosenversicherung": 0.022, - "gesetzlicheRentenversicherung": 0.0935, - }; - - from 1986-01-01 = { - "gesetzlicheKrankenversicherung": { - "mean_allgemein": 0.122, - }, - "arbeitslosenversicherung": 0.0205, - "gesetzlicheRentenversicherung": 0.096, - }; - - from 1987-01-01 = { - "gesetzlicheKrankenversicherung": { - "mean_allgemein": 0.1248, - }; - "arbeitslosenversicherung": 0.0215, - "gesetzlicheRentenversicherung": 0.0935, - }; - - from 1988-01-01 = { - # deviation_from: previous - "gesetzlicheKrankenversicherung": { - "mean_allgemein": 0.1288, - }, - }; - - from 1989-01-01 = { - # deviation_from: previous - "gesetzlicheKrankenversicherung": { - "mean_allgemein": 0.129, - } - }; - - from 1990-01-01 = { - # deviation_from: previous - "gesetzlicheKrankenversicherung": { - "mean_allgemein": 0.125, - }, - }; - - from 1991-01-01 = { - # deviation_from: previous - "gesetzlicheKrankenversicherung": { - "mean_allgemein": .128, - } - }; - - from 1992-01-01 = { - # deviation_from: previous - "arbeitslosenversicherung": 0.0315, - "gesetzlicheRentenversicherung": 0.0885 - }; - - from 1993-01-01 = { - "gesetzlicheKrankenversicherung": { - "mean_allgemein": 0.134, - }, - "arbeitslosenversicherung": 0.0325, - "gesetzlicheRentenversicherung": 0.0875, - }; - - from 1994-01-01 = { - # deviation_from: previous - "gesetzlicheRentenversicherung": 0.096 - }; - - from 1995-01-01 = { - "arbeitslosenversicherung": 0.0325, - "gesetzlicheKrankenversicherung": { - "mean_allgemein": 0.132, - }, - "gesetzlichePflegeversicherung": 0.005, - "gesetzlicheRentenversicherung": 0.093, - }; - - from 1996-01-01 = { - # deviation_from: previous - "gesetzlicheRentenversicherung": 0.096, - }; - - from 1997-01-01 = { - "gesetzlicheKrankenversicherung": { - "mean_allgemein": 0.134, - }, - "gesetzlichePflegeversicherung": 0.0085, - "arbeitslosenversicherung": 0.0325, - "gesetzlicheRentenversicherung": 0.1015, - }; - - from 1998-01-01 = { - # deviation_from: previous - "gesetzlicheKrankenversicherung": { - "mean_allgemein": 0.136 - } - }; - - from 2000-01-01 = { - # deviation_from: previous - "gesetzlicheKrankenversicherung": { - "mean_allgemein": 0.1357, - }, - "gesetzlicheRentenversicherung": 0.0965, - }; - - from 2001-01-01 = { - # deviation_from: previous - "gesetzlicheKrankenversicherung": { - "mean_allgemein": 0.1358, - }, - "gesetzlicheRentenversicherung": 0.0955, - }; - - from 2002-01-01 = { - # deviation_from: previous - "gesetzlicheKrankenversicherung": { - "mean_allgemein": 0.14, - }, - }; - - from 2003-01-01 = { - # deviation_from: previous - "gesetzlicheKrankenversicherung": { - "mean_allgemein": 0.144, - }, - "gesetzlicheRentenversicherung": 0.0975, - }; - from 2004-01-01 = { - # deviation_from: previous - "gesetzlicheKrankenversicherung": { - "mean_allgemein": 0.142 - }, - }; - from 2005-01-01 = { - "gesetzlicheKrankenversicherung": { - "mean_allgemein": 0.142, - }, - "gesetzlichePflegeversicherung": = { - standard: 0.0085, - zusatz_kinderlos: 0.0025, - }, - "arbeitslosenversicherung": 0.0325, - "gesetzlicheRentenversicherung": 0.0975, - }; +/** + * Beitragssatz der gesetzlichen Krankenversicherung + */ +public constant gesetzlicheKrankenversicherung { + Float { + from 1984-01-01 = 0.134; + from 1985-01-01 = 0.118; + from 1986-01-01 = 0.122; + from 1987-01-01 = 0.1248; + + from 1988-01-01 = 0.1288; + from 1989-01-01 = 0.129; + from 1990-01-01 = 0.125; + from 1991-01-01 = .128; + from 1993-01-01 = 0.134; + from 1995-01-01 = 0.132; + from 1996-01-01 = 0.134; + from 1998-01-01 = 0.136; + from 2000-01-01 = 0.1357; + from 2001-01-01 = 0.1358; + from 2002-01-01 = 0.14; + from 2003-01-01 = 0.144; + from 2004-01-01 = 0.142; + from 2005-01-01 = 0.142; + } # Allgemeiner Beitragssatz wird nicht mehr gleichmäßig aufgeteilt, Einführung des Sonderbeitrags # Reference: Art. 1 G. v. 15.12.2004, BGBl I S. 3445. - from 2005-07-01 = { - # deviation_from: previous - "gesetzlicheKrankenversicherung": { - "mean_allgemein": 0.133, - "sonderbeitrag": 0.009, - } + from 2005-07-01: Dict = { + "mean_allgemein": 0.133, + "sonderbeitrag": 0.009, }; - from 2007-01-01 = { - # deviation_from: previous - "gesetzlicheKrankenversicherung": { - "mean_allgemein": 0.139, - }, - "arbeitslosenversicherung": 0.021, - "gesetzlicheRentenversicherung": 0.0995, - }; + from 2007-01-01: Float = 0.139; - from 2008-01-01 = { - "gesetzlicheKrankenversicherung": { + Dict { + from 2008-01-01 = { "mean_allgemein": 0.14, "sonderbeitrag": 0.009, - }, - "gesetzlichePflegeversicherung": { - "standard": 0.00975, - "zusatzKinderlos": 0.0025, - }, - "arbeitslosenversicherung": 0.016, - "gesetzlicheRentenversicherung": 0.0995, - }; - - from 2009-01-01 = { - # deviation_from: previous - "gesetzlicheKrankenversicherung": { + }; + from 2009-01-01 = { "allgemein": 0.146, "sonderbeitrag": 0.009, "ermäßigt": 0.140, - }, - "arbeitslosenversicherung": 0.014, - }; - - from 2009-07-01 = { - # deviation_from: previous - "gesetzlicheKrankenversicherung": { + }; + from 2009-07-01 = { "allgemein": 0.14, "ermäßigt": 0.134, "sonderbeitrag": 0.009, - } - }; - - # Reference: Art. 1 G. v. 22.12.2010 BGBl. I S. 2309 - from 2011-01-01 = { - # deviation_from: previous - "gesetzlicheKrankenversicherung": { + }; + from 2011-01-01 = { "allgemein": 0.146, "ermäßigt": 0.14, - }, - "arbeitslosenversicherung": 0.015, - }; - - # Quelle: http:#www.bmas.de/DE/Service/Presse/Pressemitteilungen/rentenbericht-16-11-2011.html - from 2012-01-01 = { - # deviation_from: previous - "gesetzlicheRentenversicherung": 0.098 - }; - - from 2013-01-01 = { - # deviation_from: previous - "gesetzlicheRentenversicherung": 0.0945, - "gesetzlichePflegeversicherung": { - standard: 0.01025, - }, - }; - - # Abschaffung Sonderbeitrag, Einführung kassenabhängiger Zusatzbeitrag - from 2015-01-01 = { - "gesetzlicheKrankenversicherung": { + }; + from 2015-01-01 = { "allgemein": 0.146, "ermäßigt": 0.14, "meanZusatzbeitrag": 0.009, - }, - "gesetzlichePflegeversicherung": { - "standard": 0.01175, - "zusatzKinderlos": 0.0025, - }, - "arbeitslosenversicherung": 0.015, - "gesetzlicheRentenversicherung": 0.0935, - }; + }; + # Bekanntmachung Bundesanzeiger 30.12.2015 + from 2016-01-01 = { + "meanZusatzbeitrag": 0.011 + }; + from 2018-01-01 = { + "meanZusatzbeitrag": 0.01, + }; + from 2019-01-01 = { + "allgemein": 0.146, + "ermäßigt": 0.14, + "meanZusatzbeitrag": 0.009, + }; - # Bekanntmachung Bundesanzeiger 30.12.2015 - from 2016-01-01 = { - # deviation_from: previous - "gesetzlicheKrankenversicherung": { + # Temporarily reduced to 0.024 in BeiSaV 2019. + # Reference: ("ges_krankenv" mean_zusatzbeitrag:) BAnz AT 28.10.2019 B3 + from 2020-01-01 = { "meanZusatzbeitrag": 0.011 - }, - }; + }; - from 2017-01-01 = { - # deviation_from: previous - "gesetzlichePflegeversicherung": { - "standard": 0.01275, - }, + # Reference: ("ges_krankenv" mean_zusatzbeitrag:) BAnz AT 30.10.2020 B5 + from 2021-01-01 = { + "meanZusatzbeitrag": 0.013, + }; + + # Contribution "rate" for arbeitsl_v was temporarily reduced from 2019 to 2022 in BeiSaV 2019. + # Now back to level specified in § 341 Abs. 2 SGB III. + # Reference: (arbeitsl_v:) Art. 2 Nr. 15 G. v. 18.12.2018 BGBl. I S. 2651 + # ("ges_krankenv" mean_zusatzbeitrag:) BAnz AT 31.10.2022 B5 + from 2023-01-01 = { + "meanZusatzbeitrag": 0.016, + }; + + # Reference: BAnz AT 31.10.2023 B3 + from 2024-01-01 = { + "meanZusatzbeitrag": 0.017, + }; + } +} + +public constant gesetzlichePflegeversicherung { + Float { + from 1984-01-01 = 0.0085; + from 1995-01-01 = 0.005; + from 1997-01-01 = 0.0085; + } + + from 2005-01-01: Dict = { + "standard": 0.0085, + "zusatz_kinderlos": 0.0025, + }; + from 2008-01-01: Dict = { + "standard": 0.00975, + "zusatzKinderlos": 0.0025, }; + from 2013-01-01: Float = 0.01025; - from 2018-01-01 = { - # deviation_from: previous - "gesetzlicheKrankenversicherung": { - "meanZusatzbeitrag": 0.01, - }, - "gesetzlicheRentenversicherung": 0.093, + from 2015-01-01: Dict = { + "standard": 0.01175, + "zusatzKinderlos": 0.0025, + }; + from 2017-01-01: Float = 0.01275; + from 2019-01-01: Dict = { + "standard": 0.01525, + "zusatzKinderlos": 0.0025, }; + # Reference: Art. 2 Nr. 14 G. v. 11.07.2021, BGBl. I S. 2754. + from 2022-01-01: Dict = { + "zusatzKinderlos": 0.0035, + }; +} + +public constant arbeitslosenversicherung: Float { + from 1984-01-01 = 0.0325; + from 1985-01-01 = 0.022; + from 1986-01-01 = 0.0205; + from 1987-01-01 = 0.0215; + from 1992-01-01 = 0.0315; + from 1993-01-01 = 0.0325; + from 1997-01-01 = 0.0325; + from 2005-01-01 = 0.0325; + from 2007-01-01 = 0.021; + from 2008-01-01 = 0.016; + from 2009-01-01 = 0.014; + + # Reference: Art. 1 G. v. 22.12.2010 BGBl. I S. 2309 + from 2011-01-01 = 0.015; + from 2015-01-01 = 0.015; # Wieder-Einführung der Parität. Art. 2 G. v. 11.12.2018, BGBl. I S. 2387 # (arbeitsl_v:) Set to 0.026 in Art. 2 Nr. 15 G. v. 18.12.2018 BGBl. I S. 2651. # Temporarily reduced to 0.025 in BeiSaV 2019. # Reference: (arbeitsl_v:) V. v. 21.12.2018 BGBl. I S. 2663 - from 2019-01-01 = { - "gesetzlicheKrankenversicherung": { - "allgemein": 0.146, - "ermäßigt": 0.14, - "meanZusatzbeitrag": 0.009, - }, - "gesetzlichePflegeversicherung": { - "standard": 0.01525, - "zusatzKinderlos": 0.0025, - }, - "arbeitslosenversicherung": 0.0125, - "gesetzlicheRentenversicherung": 0.093, - }; + from 2019-01-01 = 0.0125; # Temporarily reduced to 0.024 in BeiSaV 2019. - # Reference: ("ges_krankenv" mean_zusatzbeitrag:) BAnz AT 28.10.2019 B3 # (arbeitsl_v:) V. v. 02.12.2019 BGBl. I S. 1998 - from 2020-01-01 = { - # deviation_from: previous - "gesetzlicheKrankenversicherung": { - "meanZusatzbeitrag": 0.011 - }, - "arbeitslosenversicherung": 0.012, - }; - - # Reference: ("ges_krankenv" mean_zusatzbeitrag:) BAnz AT 30.10.2020 B5 - from 2021-01-01 = { - # deviation_from: previous - "gesetzlicheKrankenversicherung": { - "meanZusatzbeitrag": 0.013, - }, - }; - - # Reference: Art. 2 Nr. 14 G. v. 11.07.2021, BGBl. I S. 2754. - from 2022-01-01 = { - # deviation_from: previous - "gesetzlichePflegeversicherung": { - "zusatzKinderlos": 0.0035, - }, - }; + from 2020-01-01 = 0.012; + from 2023-01-01 = 0.013; +} - # Contribution "rate" for arbeitsl_v was temporarily reduced from 2019 to 2022 in BeiSaV 2019. - # Now back to level specified in § 341 Abs. 2 SGB III. - # Reference: (arbeitsl_v:) Art. 2 Nr. 15 G. v. 18.12.2018 BGBl. I S. 2651 - # ("ges_krankenv" mean_zusatzbeitrag:) BAnz AT 31.10.2022 B5 - from 2023-01-01 = { - # deviation_from: previous - "arbeitslosenversicherung": 0.013, - "gesetzlicheKrankenversicherung": { - "meanZusatzbeitrag": 0.016, - }, - }; +public constant gesetzlicheRentenversicherung: Float{ + + from 1984-01-01 = 0.0975; + from 1985-01-01 = 0.0935; + from 1986-01-01 = 0.096; + from 1987-01-01 = 0.0935; + from 1992-01-01 = 0.0885; + from 1993-01-01 = 0.0875; + from 1994-01-01 = 0.096; + from 1995-01-01 = 0.093; + from 1996-01-01 = 0.096; + from 1997-01-01 = 0.1015; + from 2000-01-01 = 0.0965; + from 2001-01-01 = 0.0955; + from 2003-01-01 = 0.0975; + from 2005-01-01 = 0.0975; + from 2007-01-01 = 0.0995; + from 2008-01-01 = 0.0995; - # Reference: BAnz AT 31.10.2023 B3 - from 2024-01-01 = { - # deviation_from: previous - "gesetzlicheKrankenversicherung": { - "meanZusatzbeitrag": 0.017, - }, - }; + # Quelle: http:#www.bmas.de/DE/Service/Presse/Pressemitteilungen/rentenbericht-16-11-2011.html + from 2012-01-01 = 0.098; + from 2013-01-01 = 0.0945; + # Abschaffung Sonderbeitrag, Einführung kassenabhängiger Zusatzbeitrag + from 2015-01-01 = 0.0935; + from 2018-01-01 = 0.093; + from 2019-01-01 = 0.093; } + /** * Beitragssätze zu den gesetzlichen Sozialversicherungen * Die Beitragsbemessungsgrenze für Kranken- und Pflegeversicherung ist identisch. @@ -934,86 +784,86 @@ public constant monatlicheBezugsgroeße: Dict { "ost": 2135 }; - from 2010-01-01 = = { + from 2010-01-01 = { "west": 2555, "ost": 2170 }; - from 2011-01-01 = = { + from 2011-01-01 = { # deviation_from: previous "ost": 2240 }; - from 2012-01-01 = = { + from 2012-01-01 = { # deviation_from: previous "west": 2625 }; - from 2013-01-01 = = { + from 2013-01-01 = { "west": 2695, "ost": 2275 }; # http:#www.bundesregierung.de/ContentArchiv/DE/Archiv17/Artikel/2013/10/2013-10-16-rechengroessen-sozialversicherung.html - from 2014-01-01 = = { + from 2014-01-01 = { "west": 2765, "ost": 2345 }; - from 2015-01-01 = = { + from 2015-01-01 = { "west": 2835, "ost": 2415 }; # https:#www.bundesregierung.de/Content/DE/Artikel/2015/10/2015-10-14-sozialversicherung.html - from 2016-01-01 = = { + from 2016-01-01 = { "west": 2905, "ost": 2520 }; # https:#www.bundesregierung.de/Content/DE/Artikel/2016/10/2016-10-12-bemessunggrenzen-sozialversicherung.html - from 2017-01-01 = = { + from 2017-01-01 = { "west": 2975, "ost": 2660 }; - from 2018-01-01 = = { + from 2018-01-01 = { "west": 3045, "ost": 2695 }; # Sozialversicherungs-Rechengrößenverordnung 2019, BGBl I S. 2024, 27.11.2018 - from 2019-01-01 = = { + from 2019-01-01 = { "west": 3115, "ost": 2870 }; # Reference: §2 V. v. 17.12.2019 BGBl. I S. 2848 - from 2020-01-01 = = { + from 2020-01-01 = { "west": 3185, "ost": 3010 }; # Reference: §2 V. v. 30.11.2020, BGBl. I S. 2612. - from 2021-01-01 = = { + from 2021-01-01 = { "west": 3290, "ost": 3115 }; # Reference: §2 V. v. 30.11.2021, BGBl. I S. 5044. - from 2022-01-01 = = { + from 2022-01-01 = { "west": 3290, "ost": 3150 }; # Reference: V. v. 28.11.2022 BGBl. I. S. 2128. - from 2023-01-01 = = { + from 2023-01-01 = { "west": 3395, "ost": 3290 }; # Reference: V. v. 29.11.2023 BGBl. 2023 I Nr. 322. - from 2024-01-01 = = { + from 2024-01-01 = { "west": 3535, "ost": 3465 }; @@ -1033,167 +883,167 @@ public constant mindestanteilBezugsgroeßeBeitragspflichtigeEinnahmeSelbst: Floa * Gleitzone (Midijob Grenze) und Minijob Grenze (bis 1999 unterschiedliche Grenzen) * Reference: Midijob § 20 (2) SGB IV, Minijob § 8 (1) Nr. 1 SGB IV */ -public constant geringfuegigeEinkommensgrenzenMonatlich: Dict> { - from 1984-01-01 = { - "minijob": { - "west": 199 - } - }; +public constant geringfuegigeEinkommensgrenzenMonatlich { + Dict> { + from 1984-01-01 = { + "minijob": { + "west": 199 + } + }; - from 1985-01-01 = { - # deviation_from: previous - "minijob": { - "west": 205 - } - }; + from 1985-01-01 = { + # deviation_from: previous + "minijob": { + "west": 205 + } + }; - from 1986-01-01 = { - # deviation_from: previous - "minijob": { - "west": 210 - } - }; + from 1986-01-01 = { + # deviation_from: previous + "minijob": { + "west": 210 + } + }; - from 1987-01-01 = { - # deviation_from: previous - "minijob": { - "west": 220 - } - }; + from 1987-01-01 = { + # deviation_from: previous + "minijob": { + "west": 220 + } + }; - from 1988-01-01 = { - # deviation_from: previous - "minijob": { - "west": 225 - } - }; + from 1988-01-01 = { + # deviation_from: previous + "minijob": { + "west": 225 + } + }; - from 1989-01-01 = { - # deviation_from: previous - "minijob": { - "west": 230 - } - }; + from 1989-01-01 = { + # deviation_from: previous + "minijob": { + "west": 230 + } + }; - from 1990-01-01 = { - "minijob": { - "west": 240, - "ost": 102 - } - }; + from 1990-01-01 = { + "minijob": { + "west": 240, + "ost": 102 + } + }; - from 1991-01-01 = { - # deviation_from: previous - "minijob": { - "west": 245, - "ost": 120 - } - }; + from 1991-01-01 = { + # deviation_from: previous + "minijob": { + "west": 245, + "ost": 120 + } + }; - from 1992-01-01 = { - # deviation_from: previous - "minijob": { - "west": 256, - "ost": 153 - } - }; + from 1992-01-01 = { + # deviation_from: previous + "minijob": { + "west": 256, + "ost": 153 + } + }; - from 1993-01-01 = { - # deviation_from: previous - "minijob": { - "west": 271, - "ost": 199 - } - }; + from 1993-01-01 = { + # deviation_from: previous + "minijob": { + "west": 271, + "ost": 199 + } + }; - from 1994-01-01 = { - # deviation_from: previous - "minijob": { - "west": 286, - "ost": 225 - } - }; + from 1994-01-01 = { + # deviation_from: previous + "minijob": { + "west": 286, + "ost": 225 + } + }; - from 1995-01-01 = { - # deviation_from: previous - "minijob": { - "west": 297, - "ost": 240 - } - }; + from 1995-01-01 = { + # deviation_from: previous + "minijob": { + "west": 297, + "ost": 240 + } + }; - from 1996-01-01 = { - # deviation_from: previous - "minijob": { - "west": 302, - "ost": 256 - } - }; + from 1996-01-01 = { + # deviation_from: previous + "minijob": { + "west": 302, + "ost": 256 + } + }; - from 1997-01-01 = { - # deviation_from: previous - "minijob": { - "west": 312, - "ost": 266 - } - }; + from 1997-01-01 = { + # deviation_from: previous + "minijob": { + "west": 312, + "ost": 266 + } + }; - from 1998-01-01 = { - # deviation_from: previous - "minijob": { - "west": 317 - } - }; + from 1998-01-01 = { + # deviation_from: previous + "minijob": { + "west": 317 + } + }; - from 1999-01-01 = { - # deviation_from: previous - "minijob": { - "west": 322, - "ost": 271 - } - }; + from 1999-01-01 = { + # deviation_from: previous + "minijob": { + "west": 322, + "ost": 271 + } + }; + } - from 2000-01-01 = { - # deviation_from: previous - "minijob": 322 - }; + Dict { + from 2000-01-01 = { + "minijob": 322 + }; - from 2002-01-01 = { - # deviation_from: previous - "minijob": 325 - }; + from 2002-01-01 = { + "minijob": 325 + }; - from 2003-04-01 = { - # deviation_from: previous - "minijob": 400, - "midijob": 800 - }; + from 2003-04-01 = { + "minijob": 400, + "midijob": 800 + }; - from 2013-01-01 = { - # deviation_from: previous - "minijob": 450, - "midijob": 850 - }; + from 2013-01-01 = { + "minijob": 450, + "midijob": 850 + }; - # Reference: Art. 4 G. v. 28.11.2018 BGBl. I S. 2016 - from 2019-01-01 = { - # deviation_from: previous - "midijob": 1300 - }; + # Reference: Art. 4 G. v. 28.11.2018 BGBl. I S. 2016 + from 2019-01-01 = { + # deviation_from: previous + "midijob": 1300 + }; - # Reference: Art. 7 G. v. 28.06.2022 BGBl. I S. 969 - # "minijob" thresholds now calculated based on statutory minimum wage - from 2022-10-01 = { - # deviation_from: previous - "minijob": null, - "midijob": 1600 - }; + # Reference: Art. 7 G. v. 28.06.2022 BGBl. I S. 969 + # "minijob" thresholds now calculated based on statutory minimum wage + from 2022-10-01 = { + # deviation_from: previous + "minijob": null, + "midijob": 1600 + }; - # Reference: Art. 3 G. v. 11.11.2022 BGBl. I S. 1985 - from 2023-01-01 = { - # deviation_from: previous - "midijob": 2000 - }; + # Reference: Art. 3 G. v. 11.11.2022 BGBl. I S. 1985 + from 2023-01-01 = { + # deviation_from: previous + "midijob": 2000 + }; + } } /** diff --git a/src/resources/builtins/parameters/wohngeld.ttsl b/src/resources/builtins/parameters/wohngeld.ttsl index ffd87de6..0f72e62d 100644 --- a/src/resources/builtins/parameters/wohngeld.ttsl +++ b/src/resources/builtins/parameters/wohngeld.ttsl @@ -762,7 +762,7 @@ public constant minEink: Dict { 2: 0, 3: 0, 4: 0, - 5: 0 + 5: 0, 6: 0, 7: 0, 8: 0, @@ -826,7 +826,7 @@ public constant minEink: Dict { 4: 447, 5: 532, 6: 618, - 7: 702 + 7: 702, 8: 787, 9: 872, 10: 957, @@ -839,7 +839,7 @@ public constant minEink: Dict { 1: 350, 2: 600, 3: 800, - 4: 1000 + 4: 1000, 5: 1200, 6: 1400, 7: 1600, @@ -888,36 +888,40 @@ public constant freibetragKinder: Dict { * vorliegen. Dies ist aktuell nicht implementiert. § 17 Nr. 1 WoGG. (früher § 17 (2) * WoGG) */ -public constant freibetragBehinderung: Dict or Int { - from 1984-01-01 = { - 0: 0, - 1: 0, - 80: 1224 - }; +public constant freibetragBehinderung { + Dict { + from 1984-01-01 = { + 0: 0, + 1: 0, + 80: 1224 + }; - from 1986-01-01 = { - # deviation_from: previous - 80: 612 - }; + from 1986-01-01 = { + # deviation_from: previous + 80: 612 + }; - from 1991-01-01 = { - 0: 0, - 1: 1224, - 80: 1536 - }; + from 1991-01-01 = { + 0: 0, + 1: 1224, + 80: 1536 + }; - from 2002-01-01 = { - 0: 0, - 1: 1200, - 80: 1500 - }; + from 2002-01-01 = { + 0: 0, + 1: 1200, + 80: 1500 + }; + } - # Reference: 2 Art. 1 G. v. 08.10.2015 BGBl Nr.38 S.1612 - # neue Regelung - §17 1. WoGG a) GDB = 100 b) GDB < 100 & pflegebedürftig gem. §14 SGB XI. + gleichz. Häusliche/teilstationäre/Kurzzeit-Pflege - from 2016-01-01 = 1500; + Int { + # Reference: 2 Art. 1 G. v. 08.10.2015 BGBl Nr.38 S.1612 + # neue Regelung - §17 1. WoGG a) GDB = 100 b) GDB < 100 & pflegebedürftig gem. §14 SGB XI. + gleichz. Häusliche/teilstationäre/Kurzzeit-Pflege + from 2016-01-01 = 1500; - # Reference: Art. 1 G. v. 30.11.2019 BGBl. I S. 1877 - from 2020-01-01 = 1800; + # Reference: Art. 1 G. v. 30.11.2019 BGBl. I S. 1877 + from 2020-01-01 = 1800; + } } # TODO: DEVIATION FROM BEISPIEL!!! @@ -942,1288 +946,1292 @@ public constant behinderungsgrad: Dict { * Die Werte sind nach Anzahl Personen - maximales Baujahr des Hauses (vor 2009) - * Mietstufe geordnet. Alle Werte in vollen Euro. */ -public constant maxMiete: Dict>> { +public constant maxMiete { # Reference: Art. 1 G. v. 04.08.1980 BGBl I S. 1159. # Bis 1985 nur drei Mietstufen, streng abhängig von der Größe der Gemeinde. Es wird "Wohnung mit Sammelheizung und mit Bad oder Duschraum" angenommen. - from 1981-01-01 = { - 1: { - 1965: { - 1: 130, - 2: 135, - 3: 143 - }, - 1971: { - 1: 148, - 2: 153, - 3: 161 - }, - 1977: { - 1: 161, - 2: 166, - 3: 174 - }, - 2009: { - 1: 169, - 2: 179, - 3: 189 - } - }, - 2: { - 1965: { - 1: 164, - 2: 171, - 3: 182 - }, - 1971: { - 1: 189, - 2: 197, - 3: 207 - }, - 1977: { - 1: 210, - 2: 217, - 3: 228 - }, - 2009: { - 1: 225, - 2: 235, - 3: 245 - } - }, - 3: { - 1965: { - 1: 199, - 2: 207, - 3: 215 - }, - 1971: { - 1: 233, - 2: 240, - 3: 251 - }, - 1977: { - 1: 256, - 2: 263, - 3: 274 - }, - 2009: { - 1: 276, - 2: 286, - 3: 297 + Dict>> { + from 1981-01-01 = { + "1": { + 1965: { + 1: 130, + 2: 135, + 3: 143 + }, + 1971: { + 1: 148, + 2: 153, + 3: 161 + }, + 1977: { + 1: 161, + 2: 166, + 3: 174 + }, + 2009: { + 1: 169, + 2: 179, + 3: 189 + } + }, + "2": { + 1965: { + 1: 164, + 2: 171, + 3: 182 + }, + 1971: { + 1: 189, + 2: 197, + 3: 207 + }, + 1977: { + 1: 210, + 2: 217, + 3: 228 + }, + 2009: { + 1: 225, + 2: 235, + 3: 245 + } + }, + "3": { + 1965: { + 1: 199, + 2: 207, + 3: 215 + }, + 1971: { + 1: 233, + 2: 240, + 3: 251 + }, + 1977: { + 1: 256, + 2: 263, + 3: 274 + }, + 2009: { + 1: 276, + 2: 286, + 3: 297 + } + }, + "4": { + 1965: { + 1: 235, + 2: 245, + 3: 258 + }, + 1971: { + 1: 266, + 2: 276, + 3: 289 + }, + 1977: { + 1: 294, + 2: 304, + 3: 317 + }, + 2009: { + 1: 320, + 2: 332, + 3: 345 + } + }, + "5": { + 1965: { + 1: 268, + 2: 281, + 3: 294 + }, + 1971: { + 1: 304, + 2: 314, + 3: 330 + }, + 1977: { + 1: 335, + 2: 348, + 3: 363 + }, + 2009: { + 1: 366, + 2: 378, + 3: 394 + }, + }, + "jede_weitere_person": { + 1965: { + 1: 33, + 2: 34, + 3: 36 + }, + 1971: { + 1: 37, + 2: 39, + 3: 40 + }, + 1977: { + 1: 41, + 2: 42, + 3: 44 + }, + 2009: { + 1: 45, + 2: 47, + 3: 48 + } } - }, - 4: { - 1965: { - 1: 235, - 2: 245, - 3: 258 - }, - 1971: { - 1: 266, - 2: 276, - 3: 289 - }, - 1977: { - 1: 294, - 2: 304, - 3: 317 - }, - 2009: { - 1: 320, - 2: 332, - 3: 345 - } - }, - 5: { - 1965: { - 1: 268, - 2: 281, - 3: 294 - }, - 1971: { - 1: 304, - 2: 314, - 3: 330 - }, - 1977: { - 1: 335, - 2: 348, - 3: 363 - }, - 2009: { - 1: 366, - 2: 378, - 3: 394 - }, - }, - jede_weitere_person: { - 1965: { - 1: 33, - 2: 34, - 3: 36 - }, - 1971: { - 1: 37, - 2: 39, - 3: 40 - }, - 1977: { - 1: 41, - 2: 42, - 3: 44 - }, - 2009: { - 1: 45, - 2: 47, - 3: 48 - } - } - } + }; - - # Reference: Art. 1 G. v. 11.07.1985 BGBl I S. 1318. - # Es wird eine Wohnung mit "Sammelheizung und mit Bad oder Duschraum" angenommen. - from 1985-01-01 = { - 1: { - 1965: { - 1: 146, - 2: 156, - 3: 164, - 4: 174, - 5: 184 - }, - 1971: { - 1: 161, - 2: 174, - 3: 184, - 4: 194, - 5: 207 - }, - 1977: { - 1: 171, - 2: 182, - 3: 194, - 4: 205, - 5: 217 - }, - 2009: { - 1: 184, - 2: 194, - 3: 207, - 4: 220, - 5: 233 + # Reference: Art. 1 G. v. 11.07.1985 BGBl I S. 1318. + # Es wird eine Wohnung mit "Sammelheizung und mit Bad oder Duschraum" angenommen. + from 1985-01-01 = { + "1": { + 1965: { + 1: 146, + 2: 156, + 3: 164, + 4: 174, + 5: 184 + }, + 1971: { + 1: 161, + 2: 174, + 3: 184, + 4: 194, + 5: 207 + }, + 1977: { + 1: 171, + 2: 182, + 3: 194, + 4: 205, + 5: 217 + }, + 2009: { + 1: 184, + 2: 194, + 3: 207, + 4: 220, + 5: 233 + } + }, + "2": { + 1965: { + 1: 187, + 2: 199, + 3: 212, + 4: 225, + 5: 238 + }, + 1971: { + 1: 210, + 2: 222, + 3: 238, + 4: 251, + 5: 266 + }, + 1977: { + 1: 220, + 2: 235, + 3: 251, + 4: 266, + 5: 281 + }, + 2009: { + 1: 235, + 2: 253, + 3: 268, + 4: 284, + 5: 302 + } + }, + "3": { + 1965: { + 1: 222, + 2: 238, + 3: 253, + 4: 268, + 5: 284 + }, + 1971: { + 1: 251, + 2: 266, + 3: 284, + 4: 299, + 5: 317 + }, + 1977: { + 1: 263, + 2: 281, + 3: 299, + 4: 317, + 5: 335 + }, + 2009: { + 1: 281, + 2: 302, + 3: 320, + 4: 340, + 5: 358 + } + }, + "4": { + 1965: { + 1: 261, + 2: 279, + 3: 294, + 4: 312, + 5: 330 + }, + 1971: { + 1: 289, + 2: 309, + 3: 330, + 4: 350, + 5: 368 + }, + 1977: { + 1: 307, + 2: 327, + 3: 348, + 4: 368, + 5: 389 + }, + 2009: { + 1: 327, + 2: 350, + 3: 373, + 4: 396, + 5: 417 + } + }, + "5": { + 1965: { + 1: 297, + 2: 317, + 3: 337, + 4: 355, + 5: 376 + }, + 1971: { + 1: 330, + 2: 353, + 3: 376, + 4: 399, + 5: 419 + }, + 1977: { + 1: 348, + 2: 373, + 3: 396, + 4: 419, + 5: 442 + }, + 2009: { + 1: 373, + 2: 399, + 3: 424, + 4: 450, + 5: 476 + } + }, + "jede_weitere_person": { + 1965: { + 1: 36, + 2: 38, + 3: 41, + 4: 43, + 5: 46 + }, + 1971: { + 1: 41, + 2: 43, + 3: 46, + 4: 49, + 5: 51 + }, + 1977: { + 1: 41, + 2: 43, + 3: 46 + 4: 49, + 5: 51 + }, + 2009: { + 1: 46, + 2: 49, + 3: 51, + 4: 56, + 5: 59 + } } - }, - 2: { - 1965: { - 1: 187, - 2: 199, - 3: 212, - 4: 225, - 5: 238 - }, - 1971: { - 1: 210, - 2: 222, - 3: 238, - 4: 251, - 5: 266 - }, - 1977: { - 1: 220, - 2: 235, - 3: 251, - 4: 266, - 5: 281 - }, - 2009: { - 1: 235, - 2: 253, - 3: 268, - 4: 284, - 5: 302 - } - }, - 3: { - 1965: { - 1: 222, - 2: 238, - 3: 253, - 4: 268, - 5: 284 - }, - 1971: { - 1: 251, - 2: 266, - 3: 284, - 4: 299, - 5: 317 - }, - 1977: { - 1: 263, - 2: 281, - 3: 299, - 4: 317, - 5: 335 - }, - 2009: { - 1: 281, - 2: 302, - 3: 320, - 4: 340, - 5: 358 - } - }, - 4: { - 1965: { - 1: 261, - 2: 279, - 3: 294, - 4: 312, - 5: 330 - }, - 1971: { - 1: 289, - 2: 309, - 3: 330, - 4: 350, - 5: 368 - }, - 1977: { - 1: 307, - 2: 327, - 3: 348, - 4: 368, - 5: 389 - }, - 2009: { - 1: 327, - 2: 350, - 3: 373, - 4: 396, - 5: 417 - } - }, - 5: { - 1965: { - 1: 297, - 2: 317, - 3: 337, - 4: 355, - 5: 376 - }, - 1971: { - 1: 330, - 2: 353, - 3: 376, - 4: 399, - 5: 419 - }, - 1977: { - 1: 348, - 2: 373, - 3: 396, - 4: 419, - 5: 442 - }, - 2009: { - 1: 373, - 2: 399, - 3: 424, - 4: 450, - 5: 476 - } - }, - jede_weitere_person: { - 1965: { - 1: 36, - 2: 38, - 3: 41, - 4: 43, - 5: 46 - }, - 1971: { - 1: 41, - 2: 43, - 3: 46, - 4: 49, - 5: 51 - }, - 1977: { - 1: 41, - 2: 43, - 3: 46 - 4: 49, - 5: 51 - }, - 2009: { - 1: 46, - 2: 49, - 3: 51, - 4: 56, - 5: 59 - } - } - } + }; - # Reference: Art. 1 G. v. 13.12.1989 BGBl I S. 2148. - # Es wird eine Wohnung mit "Sammelheizung und mit Bad oder Duschraum" angenommen. - from 1990-01-01 = { - 1: { - 1965: { - 1: 146, - 2: 156, - 3: 164, - 4: 174, - 5: 184, - 6: 194 - }, - 1971: { - 1: 161, - 2: 174, - 3: 184, - 4: 194, - 5: 207, - 6: 220 - }, - 1977: { - 1: 171, - 2: 182, - 3: 194, - 4: 205, - 5: 217, - 6: 230 - }, - 2009: { - 1: 184, - 2: 194, - 3: 207, - 4: 220, - 5: 233, - 6: 245 - } - }, - 2: { - 1965: { - 1: 187, - 2: 199, - 3: 212, - 4: 225, - 5: 238, - 6: 251 - }, - 1971: { - 1: 210, - 2: 222, - 3: 238, - 4: 251, - 5: 266, - 6: 281 - }, - 1977: { - 1: 220, - 2: 235, - 3: 251, - 4: 266, - 5: 281, - 6: 297 - }, - 2009: { - 1: 235, - 2: 253, - 3: 268, - 4: 284, - 5: 302, - 6: 320 - } - }, - 3: { - 1965: { - 1: 222, - 2: 238, - 3: 253, - 4: 268, - 5: 284, - 6: 299 - }, - 1971: { - 1: 251, - 2: 266, - 3: 284, - 4: 299, - 5: 317, - 6: 335 - }, - 1977: { - 1: 263, - 2: 281, - 3: 299, - 4: 317, - 5: 335, - 6: 353 - }, - 2009: { - 1: 281, - 2: 302, - 3: 320, - 4: 340, - 5: 358, - 6: 376 - } - }, - 4: { - 1965: { - 1: 261, - 2: 279, - 3: 294, - 4: 312, - 5: 330, - 6: 348 - }, - 1971: { - 1: 289, - 2: 309, - 3: 330, - 4: 350, - 5: 368, - 6: 386 - }, - 1977: { - 1: 307, - 2: 327, - 3: 348, - 4: 368, - 5: 389, - 6: 409 - }, - 2009: { - 1: 327, - 2: 350, - 3: 373, - 4: 396, - 5: 417, - 6: 437 - } - }, - 5: { - 1965: { - 1: 297, - 2: 317, - 3: 337, - 4: 355, - 5: 376, - 6: 396 - }, - 1971: { - 1: 330, - 2: 353, - 3: 376, - 4: 399, - 5: 419, - 6: 440 - }, - 1977: { - 1: 348, - 2: 373, - 3: 396, - 4: 419, - 5: 442, - 6: 465 - }, - 2009: { - 1: 373, - 2: 399, - 3: 424, - 4: 450, - 5: 476, - 6: 501 + # Reference: Art. 1 G. v. 13.12.1989 BGBl I S. 2148. + # Es wird eine Wohnung mit "Sammelheizung und mit Bad oder Duschraum" angenommen. + from 1990-01-01 = { + "1": { + 1965: { + 1: 146, + 2: 156, + 3: 164, + 4: 174, + 5: 184, + 6: 194 + }, + 1971: { + 1: 161, + 2: 174, + 3: 184, + 4: 194, + 5: 207, + 6: 220 + }, + 1977: { + 1: 171, + 2: 182, + 3: 194, + 4: 205, + 5: 217, + 6: 230 + }, + 2009: { + 1: 184, + 2: 194, + 3: 207, + 4: 220, + 5: 233, + 6: 245 + } + }, + "2": { + 1965: { + 1: 187, + 2: 199, + 3: 212, + 4: 225, + 5: 238, + 6: 251 + }, + 1971: { + 1: 210, + 2: 222, + 3: 238, + 4: 251, + 5: 266, + 6: 281 + }, + 1977: { + 1: 220, + 2: 235, + 3: 251, + 4: 266, + 5: 281, + 6: 297 + }, + 2009: { + 1: 235, + 2: 253, + 3: 268, + 4: 284, + 5: 302, + 6: 320 + } + }, + "3": { + 1965: { + 1: 222, + 2: 238, + 3: 253, + 4: 268, + 5: 284, + 6: 299 + }, + 1971: { + 1: 251, + 2: 266, + 3: 284, + 4: 299, + 5: 317, + 6: 335 + }, + 1977: { + 1: 263, + 2: 281, + 3: 299, + 4: 317, + 5: 335, + 6: 353 + }, + 2009: { + 1: 281, + 2: 302, + 3: 320, + 4: 340, + 5: 358, + 6: 376 + } + }, + "4": { + 1965: { + 1: 261, + 2: 279, + 3: 294, + 4: 312, + 5: 330, + 6: 348 + }, + 1971: { + 1: 289, + 2: 309, + 3: 330, + 4: 350, + 5: 368, + 6: 386 + }, + 1977: { + 1: 307, + 2: 327, + 3: 348, + 4: 368, + 5: 389, + 6: 409 + }, + 2009: { + 1: 327, + 2: 350, + 3: 373, + 4: 396, + 5: 417, + 6: 437 + } + }, + "5": { + 1965: { + 1: 297, + 2: 317, + 3: 337, + 4: 355, + 5: 376, + 6: 396 + }, + 1971: { + 1: 330, + 2: 353, + 3: 376, + 4: 399, + 5: 419, + 6: 440 + }, + 1977: { + 1: 348, + 2: 373, + 3: 396, + 4: 419, + 5: 442, + 6: 465 + }, + 2009: { + 1: 373, + 2: 399, + 3: 424, + 4: 450, + 5: 476, + 6: 501 + } + }, + "jede_weitere_person": { + 1965: { + 1: 36, + 2: 38, + 3: 41, + 4: 43, + 5: 46, + 6: 49 + }, + 1971: { + 1: 41, + 2: 43, + 3: 46, + 4: 49, + 5: 51, + 6: 54 + }, + 1977: { + 1: 43, + 2: 46, + 3: 49, + 4: 51, + 5: 54, + 6: 56 + }, + 2009: { + 1: 46, + 2: 49, + 3: 51, + 4: 56, + 5: 59, + 6: 61 + } } - }, - jede_weitere_person: { - 1965: { - 1: 36, - 2: 38, - 3: 41, - 4: 43, - 5: 46, - 6: 49 - }, - 1971: { - 1: 41, - 2: 43, - 3: 46, - 4: 49, - 5: 51, - 6: 54 - }, - 1977: { - 1: 43, - 2: 46, - 3: 49, - 4: 51, - 5: 54, - 6: 56 - }, - 2009: { - 1: 46, - 2: 49, - 3: 51, - 4: 56, - 5: 59, - 6: 61 - } - } - } + }; - # Reference: Art. 1 G. v. 10.08.1990 BGBl I S. 1522. - # Es wird eine Wohnung mit "Sammelheizung und mit Bad oder Duschraum" angenommen. - from 1990-10-01 = { - 1: { - 1965: { - 1: 159, - 2: 171, - 3: 182, - 4: 194, - 5: 210, - 6: 225 - }, - 1977: { - 1: 182, - 2: 194, - 3: 207, - 4: 222, - 5: 240, - 6: 256 - }, - 2009: { - 1: 194, - 2: 207, - 3: 220, - 4: 238, - 5: 256, - 6: 274 - } - }, - 2: { - 1965: { - 1: 205, - 2: 220, - 3: 233, - 4: 253, - 5: 271, - 6: 289 - }, - 1977: { - 1: 235, - 2: 251, - 3: 268, - 4: 289, - 5: 309, - 6: 332 - }, - 2009: { - 1: 251, - 2: 268, - 3: 284, - 4: 307, - 5: 330, - 6: 353 - } - }, - 3: { - 1965: { - 1: 245, - 2: 263, - 3: 279, - 4: 302, - 5: 325, - 6: 345 - }, - 1977: { - 1: 281, - 2: 299, - 3: 320, - 4: 345, - 5: 371, - 6: 396 - }, - 2009: { - 1: 299, - 2: 320, - 3: 340, - 4: 366, - 5: 394, - 6: 422 - } - }, - 4: { - 1965: { - 1: 286, - 2: 304, - 3: 325, - 4: 350, - 5: 376, - 6: 401 - }, - 1977: { - 1: 327, - 2: 348, - 3: 371, - 4: 401, - 5: 429, - 6: 460 - }, - 2009: { - 1: 348, - 2: 371, - 3: 394, - 4: 427, - 5: 458, - 6: 488 + # Reference: Art. 1 G. v. 10.08.1990 BGBl I S. 1522. + # Es wird eine Wohnung mit "Sammelheizung und mit Bad oder Duschraum" angenommen. + from 1990-10-01 = { + "1": { + 1965: { + 1: 159, + 2: 171, + 3: 182, + 4: 194, + 5: 210, + 6: 225 + }, + 1977: { + 1: 182, + 2: 194, + 3: 207, + 4: 222, + 5: 240, + 6: 256 + }, + 2009: { + 1: 194, + 2: 207, + 3: 220, + 4: 238, + 5: 256, + 6: 274 + } + }, + "2": { + 1965: { + 1: 205, + 2: 220, + 3: 233, + 4: 253, + 5: 271, + 6: 289 + }, + 1977: { + 1: 235, + 2: 251, + 3: 268, + 4: 289, + 5: 309, + 6: 332 + }, + 2009: { + 1: 251, + 2: 268, + 3: 284, + 4: 307, + 5: 330, + 6: 353 + } + }, + "3": { + 1965: { + 1: 245, + 2: 263, + 3: 279, + 4: 302, + 5: 325, + 6: 345 + }, + 1977: { + 1: 281, + 2: 299, + 3: 320, + 4: 345, + 5: 371, + 6: 396 + }, + 2009: { + 1: 299, + 2: 320, + 3: 340, + 4: 366, + 5: 394, + 6: 422 + } + }, + "4": { + 1965: { + 1: 286, + 2: 304, + 3: 325, + 4: 350, + 5: 376, + 6: 401 + }, + 1977: { + 1: 327, + 2: 348, + 3: 371, + 4: 401, + 5: 429, + 6: 460 + }, + 2009: { + 1: 348, + 2: 371, + 3: 394, + 4: 427, + 5: 458, + 6: 488 + } + }, + "5": { + 1965: { + 1: 325, + 2: 348, + 3: 371, + 4: 399, + 5: 429, + 6: 458 + }, + 1977: { + 1: 373, + 2: 396, + 3: 422, + 4: 458, + 5: 491, + 6: 524 + }, + 2009: { + 1: 396, + 2: 422, + 3: 450, + 4: 486, + 5: 522, + 6: 557 + } + }, + "jede_weitere_person": { + 1965: { + 1: 41, + 2: 43, + 3: 46, + 4: 49, + 5: 54, + 6: 56 + }, + 1977: { + 1: 46, + 2: 51, + 3: 54, + 4: 56, + 5: 61, + 6: 64 + }, + 2009: { + 1: 49, + 2: 51, + 3: 54, + 4: 56, + 5: 61, + 6: 64 + } } - }, - 5: { - 1965: { - 1: 325, - 2: 348, - 3: 371, - 4: 399, - 5: 429, - 6: 458 - }, - 1977: { - 1: 373, - 2: 396, - 3: 422, - 4: 458, - 5: 491, - 6: 524 - }, - 2009: { - 1: 396, - 2: 422, - 3: 450, - 4: 486, - 5: 522, - 6: 557 - } - }, - jede_weitere_person: { - 1965: { - 1: 41, - 2: 43, - 3: 46, - 4: 49, - 5: 54, - 6: 56 - }, - 1977: { - 1: 46, - 2: 51, - 3: 54, - 4: 56, - 5: 61, - 6: 64 - }, - 2009: { - 1: 49, - 2: 51, - 3: 54, - 4: 56, - 5: 61, - 6: 64 - } - } - } + }; - # Reference: Neufassung WoGG v. 11.02.1993 BGBl I S. 183. - # Es wird eine Wohnung mit "Sammelheizung und mit Bad oder Duschraum" angenommen. - from 1993-01-01 = { - 1: { - 1965: { - 1: 159, - 2: 171, - 3: 182, - 4: 194, - 5: 210, - 6: 225 - }, - 1977: { - 1: 182, - 2: 194, - 3: 207, - 4: 222, - 5: 240, - 6: 256 - }, - 1991: { - 1: 194, - 2: 207, - 3: 220, - 4: 238, - 5: 256, - 6: 274 - }, - 2009: { - 1: 228, - 2: 243, - 3: 258, - 4: 279, - 5: 299, - 6: 320 - } - }, - 2: { - 1965: { - 1: 205, - 2: 220, - 3: 233, - 4: 253, - 5: 271, - 6: 289 - }, - 1977: { - 1: 235, - 2: 251, - 3: 268, - 4: 289, - 5: 309, - 6: 332 - }, - 1991: { - 1: 251, - 2: 268, - 3: 284, - 4: 307, - 5: 330, - 6: 353 - }, - 2009: { - 1: 294, - 2: 314, - 3: 335, - 4: 360, - 5: 389, - 6: 414 - } - }, - 3: { - 1965: { - 1: 245, - 2: 263, - 3: 279, - 4: 302, - 5: 325, - 6: 345 - }, - 1977: { - 1: 281, - 2: 299, - 3: 320, - 4: 345, - 5: 371, - 6: 396 - }, - 1991: { - 1: 299, - 2: 320, - 3: 340, - 4: 366, - 5: 394, - 6: 422 - }, - 2009: { - 1: 353, - 2: 378, - 3: 401, - 4: 435, - 5: 465, - 6: 496 + # Reference: Neufassung WoGG v. 11.02.1993 BGBl I S. 183. + # Es wird eine Wohnung mit "Sammelheizung und mit Bad oder Duschraum" angenommen. + from 1993-01-01 = { + "1": { + 1965: { + 1: 159, + 2: 171, + 3: 182, + 4: 194, + 5: 210, + 6: 225 + }, + 1977: { + 1: 182, + 2: 194, + 3: 207, + 4: 222, + 5: 240, + 6: 256 + }, + 1991: { + 1: 194, + 2: 207, + 3: 220, + 4: 238, + 5: 256, + 6: 274 + }, + 2009: { + 1: 228, + 2: 243, + 3: 258, + 4: 279, + 5: 299, + 6: 320 + } + }, + "2": { + 1965: { + 1: 205, + 2: 220, + 3: 233, + 4: 253, + 5: 271, + 6: 289 + }, + 1977: { + 1: 235, + 2: 251, + 3: 268, + 4: 289, + 5: 309, + 6: 332 + }, + 1991: { + 1: 251, + 2: 268, + 3: 284, + 4: 307, + 5: 330, + 6: 353 + }, + 2009: { + 1: 294, + 2: 314, + 3: 335, + 4: 360, + 5: 389, + 6: 414 + } + }, + "3": { + 1965: { + 1: 245, + 2: 263, + 3: 279, + 4: 302, + 5: 325, + 6: 345 + }, + 1977: { + 1: 281, + 2: 299, + 3: 320, + 4: 345, + 5: 371, + 6: 396 + }, + 1991: { + 1: 299, + 2: 320, + 3: 340, + 4: 366, + 5: 394, + 6: 422 + }, + 2009: { + 1: 353, + 2: 378, + 3: 401, + 4: 435, + 5: 465, + 6: 496 + } + }, + "4": { + 1965: { + 1: 286, + 2: 304, + 3: 325, + 4: 350, + 5: 376, + 6: 401 + }, + 1977: { + 1: 327, + 2: 348, + 3: 371, + 4: 401, + 5: 429, + 6: 460 + }, + 1991: { + 1: 348, + 2: 371, + 3: 394, + 4: 427, + 5: 458, + 6: 488 + }, + 2009: { + 1: 409, + 2: 437, + 3: 465, + 4: 504, + 5: 539, + 6: 437 + } + }, + "5": { + 1965: { + 1: 325, + 2: 348, + 3: 371, + 4: 399, + 5: 429, + 6: 458 + }, + 1977: { + 1: 373, + 2: 396, + 3: 422, + 4: 458, + 5: 491, + 6: 524 + }, + 1991: { + 1: 396, + 2: 422, + 3: 450, + 4: 486, + 5: 522, + 6: 557 + }, + 2009: { + 1: 465, + 2: 499, + 3: 529, + 4: 573, + 5: 614, + 6: 657 + } + }, + "jede_weitere_person": { + 1965: { + 1: 41, + 2: 43, + 3: 46, + 4: 49, + 5: 54, + 6: 56 + }, + 1977: { + 1: 46, + 2: 51, + 3: 54, + 4: 56, + 5: 61, + 6: 64 + }, + 1991: { + 1: 49, + 2: 54, + 3: 56, + 4: 61, + 5: 64, + 6: 69 + }, + 2009: { + 1: 56, + 2: 61, + 3: 64, + 4: 69, + 5: 74, + 6: 79 + } } - }, - 4: { - 1965: { - 1: 286, - 2: 304, - 3: 325, - 4: 350, - 5: 376, - 6: 401 - }, - 1977: { - 1: 327, - 2: 348, - 3: 371, - 4: 401, - 5: 429, - 6: 460 - }, - 1991: { - 1: 348, - 2: 371, - 3: 394, - 4: 427, - 5: 458, - 6: 488 - }, - 2009: { - 1: 409, - 2: 437, - 3: 465, - 4: 504, - 5: 539, - 6: 437 - } - }, - 5: { - 1965: { - 1: 325, - 2: 348, - 3: 371, - 4: 399, - 5: 429, - 6: 458 - }, - 1977: { - 1: 373, - 2: 396, - 3: 422, - 4: 458, - 5: 491, - 6: 524 - }, - 1991: { - 1: 396, - 2: 422, - 3: 450, - 4: 486, - 5: 522, - 6: 557 - }, - 2009: { - 1: 465, - 2: 499, - 3: 529, - 4: 573, - 5: 614, - 6: 657 - } - }, - jede_weitere_person: { - 1965: { - 1: 41, - 2: 43, - 3: 46, - 4: 49, - 5: 54, - 6: 56 - }, - 1977: { - 1: 46, - 2: 51, - 3: 54, - 4: 56, - 5: 61, - 6: 64 - }, - 1991: { - 1: 49, - 2: 54, - 3: 56, - 4: 61, - 5: 64, - 6: 69 - }, - 2009: { - 1: 56, - 2: 61, - 3: 64, - 4: 69, - 5: 74, - 6: 79 - } - } - } + }; - # Reference: Art. 5 G. v. 22.12.1999, BGBl I S. 2671. - # Nimmt die Umrechnung in Euro von 2002 vorweg. - from 2001-01-01: - 1: { - 1965: { - 1: 200, - 2: 210, - 3: 225, - 4: 245, - 5: 260, - 6: 280 - }, - 1991: { - 1: 215, - 2: 230, - 3: 245, - 4: 265, - 5: 285, - 6: 305 - }, - 2009: { - 1: 265, - 2: 280, - 3: 300, - 4: 325, - 5: 350, - 6: 370 + # Reference: Art. 5 G. v. 22.12.1999, BGBl I S. 2671. + # Nimmt die Umrechnung in Euro von 2002 vorweg. + from 2001-01-01: + "1": { + 1965: { + 1: 200, + 2: 210, + 3: 225, + 4: 245, + 5: 260, + 6: 280 + }, + 1991: { + 1: 215, + 2: 230, + 3: 245, + 4: 265, + 5: 285, + 6: 305 + }, + 2009: { + 1: 265, + 2: 280, + 3: 300, + 4: 325, + 5: 350, + 6: 370 + } + }, + "2": { + 1965: { + 1: 265, + 2: 285, + 3: 300, + 4: 325, + 5: 350, + 6: 375 + }, + 1991: { + 1: 290, + 2: 310, + 3: 330, + 4: 355, + 5: 380, + 6: 405 + }, + 2009: { + 1: 320, + 2: 345, + 3: 365, + 4: 395, + 5: 425, + 6: 455 + } + }, + "3": { + 1965: { + 1: 322, + 2: 340, + 3: 360, + 4: 390, + 5: 420, + 6: 445 + }, + 1991: { + 1: 345, + 2: 365, + 3: 390, + 4: 420, + 5: 455, + 6: 485 + }, + 2009: { + 1: 385, + 2: 410, + 3: 435, + 4: 470, + 5: 505, + 6: 540 + } + }, + "4": { + 1965: { + 1: 370, + 2: 395, + 3: 420, + 4: 454, + 5: 520 + # TODO: Eintrag vergessen? + }, + 1991: { + 1: 400, + 2: 425, + 3: 455, + 4: 490, + 5: 525, + 6: 565 + }, + 2009: { + 1: 445, + 2: 475, + 3: 505, + 4: 545, + 5: 590, + 6: 630 + } + }, + "5": { + 1965: { + 1: 420, + 2: 450, + 3: 480, + 4: 515, + 5: 555, + 6: 595 + }, + 1991: { + 1: 455, + 2: 485, + 3: 520, + 4: 560, + 5: 600, + 6: 640 + }, + 2009: { + 1: 510, + 2: 545, + 3: 580, + 4: 625, + 5: 670, + 6: 715 + } + }, + "jede_weitere_person": { + 1965: { + 1: 50, + 2: 55, + 3: 60, + 4: 65, + 5: 70, + 6: 75 + }, + 1991: { + 1: 55, + 2: 60, + 3: 65, + 4: 70, + 5: 75, + 6: 80 + }, + 2009: { + 1: 60, + 2: 65, + 3: 70, + 4: 75, + 5: 80, + 6: 90 + } } - }, - 2: { - 1965: { - 1: 265, - 2: 285, - 3: 300, - 4: 325, - 5: 350, - 6: 375 - }, - 1991: { - 1: 290, - 2: 310, + }; + }; + + Dict> { + # Reference: Art. 1 G. v. 24.09.2008, BGBl I S. 1856. + from 2009-01-01 = { + "1": { + 1: 292, + 2: 308, 3: 330, - 4: 355, - 5: 380, - 6: 405 + 4: 358, + 5: 385, + 6: 407 + }, + "2": { + 1: 352, + 2: 380, + 3: 402, + 4: 435, + 5: 468, + 6: 501 }, - 2009: { - 1: 320, - 2: 345, - 3: 365, - 4: 395, - 5: 425, - 6: 455 + "3": { + 1: 424, + 2: 451, + 3: 479, + 4: 517, + 5: 556, + 6: 594 + }, + "4": { + 1: 490, + 2: 523, + 3: 556, + 4: 600, + 5: 649, + 6: 693 + }, + "5": { + 1: 561, + 2: 600, + 3: 638, + 4: 688, + 5: 737, + 6: 787 + }, + "jede_weitere_person": { + 1: 66, + 2: 72, + 3: 77, + 4: 83, + 5: 88, + 6: 99 } - }, - 3: { - 1965: { - 1: 322, - 2: 340, - 3: 360, - 4: 390, - 5: 420, - 6: 445 - }, - 1991: { - 1: 345, - 2: 365, + }; + + # Reference: Art. 1 G. v. 02.10.2015, BGBl I S. 1610. + from 2016-01-01 = { + "1": { + 1: 312, + 2: 351, 3: 390, - 4: 420, - 5: 455, - 6: 485 + 4: 434, + 5: 482, + 6: 522 }, - 2009: { - 1: 385, - 2: 410, - 3: 435, - 4: 470, - 5: 505, - 6: 540 - } - }, - 4: { - 1965: { - 1: 370, - 2: 395, - 3: 420, - 4: 454, - 5: 520 - # TODO: Eintrag vergessen? - }, - 1991: { - 1: 400, + "2": { + 1: 378, 2: 425, - 3: 455, - 4: 490, + 3: 473, + 4: 526, + 5: 584, + 6: 633 + }, + "3": { + 1: 450, + 2: 506, + 3: 563, + 4: 626, + 5: 695, + 6: 753 + }, + "4": { + 1: 525, + 2: 591, + 3: 656, + 4: 730, + 5: 811, + 6: 879 + }, + "5": { + 1: 600, + 2: 675, + 3: 750, + 4: 834, + 5: 927, + 6: 1004 + }, + "jede_weitere_person": { + 1: 71, + 2: 81, + 3: 91, + 4: 101, + 5: 111, + 6: 126 + } + }; + + # Reference: Art. 1 G. v. 30.11.2019, BGBl I S. 1877. + from 2020-01-01 = { + "1": { + 1: 338, + 2: 381, + 3: 426, + 4: 478, 5: 525, - 6: 565 + 6: 575, + 7: 633 }, - 2009: { - 1: 445, - 2: 475, - 3: 505, - 4: 545, - 5: 590, - 6: 630 + "2": { + 1: 409, + 2: 461, + 3: 516, + 4: 579, + 5: 636, + 6: 697, + 7: 767 + }, + "3": { + 1: 487, + 2: 549, + 3: 614, + 4: 689, + 5: 757, + 6: 830, + 7: 912 + }, + "4": { + 1: 568, + 2: 641, + 3: 716, + 4: 803, + 5: 884, + 6: 968, + 7: 1065 + }, + "5": { + 1: 649, + 2: 732, + 3: 818, + 4: 918, + 5: 1010, + 6: 1106, + 7: 1217 + }, + "jede_weitere_person": { + 1: 77, + 2: 88, + 3: 99, + 4: 111, + 5: 121, + 6: 139, + 7: 153 } - }, - 5: { - 1965: { + }; + + # Reference: V. v. 03.06.2021 BGBl. I S. 1369. + from 2022-01-01 = { + "1": { + 1: 347, + 2: 392, + 3: 438, + 4: 491, + 5: 540, + 6: 591, + 7: 651 + }, + "2": { 1: 420, - 2: 450, - 3: 480, - 4: 515, - 5: 555, - 6: 595 - }, - 1991: { - 1: 455, - 2: 485, - 3: 520, - 4: 560, - 5: 600, - 6: 640 - }, - 2009: { - 1: 510, - 2: 545, - 3: 580, - 4: 625, - 5: 670, - 6: 715 + 2: 474, + 3: 530, + 4: 595, + 5: 654, + 6: 716, + 7: 788 + }, + "3": { + 1: 501, + 2: 564, + 3: 631, + 4: 708, + 5: 778, + 6: 853, + 7: 937 + }, + "4": { + 1: 584, + 2: 659, + 3: 736, + 4: 825, + 5: 909, + 6: 995, + 7: 1095 + }, + "5": { + 1: 667, + 2: 752, + 3: 841, + 4: 944, + 5: 1038, + 6: 1137, + 7: 1251 + }, + "jede_weitere_person": { + 1: 79, + 2: 90, + 3: 102, + 4: 114, + 5: 124, + 6: 143, + 7: 157 } - }, - jede_weitere_person: { - 1965: { - 1: 50, - 2: 55, - 3: 60, - 4: 65, - 5: 70, - 6: 75 - }, - 1991: { - 1: 55, - 2: 60, - 3: 65, - 4: 70, - 5: 75, - 6: 80 - }, - 2009: { - 1: 60, - 2: 65, - 3: 70, - 4: 75, - 5: 80, - 6: 90 - } - } - } - - # Reference: Art. 1 G. v. 24.09.2008, BGBl I S. 1856. - from 2009-01-01 = { - 1: { - 1: 292, - 2: 308, - 3: 330, - 4: 358, - 5: 385, - 6: 407 - }, - 2: { - 1: 352, - 2: 380, - 3: 402, - 4: 435, - 5: 468, - 6: 501 - }, - 3: { - 1: 424, - 2: 451, - 3: 479, - 4: 517, - 5: 556, - 6: 594 - }, - 4: { - 1: 490, - 2: 523, - 3: 556, - 4: 600, - 5: 649, - 6: 693 - }, - 5: { - 1: 561, - 2: 600, - 3: 638, - 4: 688, - 5: 737, - 6: 787 - }, - jede_weitere_person: { - 1: 66, - 2: 72, - 3: 77, - 4: 83, - 5: 88, - 6: 99 - } - } - - # Reference: Art. 1 G. v. 02.10.2015, BGBl I S. 1610. - from 2016-01-01 = { - 1: { - 1: 312, - 2: 351, - 3: 390, - 4: 434, - 5: 482, - 6: 522 - }, - 2: { - 1: 378, - 2: 425, - 3: 473, - 4: 526, - 5: 584, - 6: 633 - }, - 3: { - 1: 450, - 2: 506, - 3: 563, - 4: 626, - 5: 695, - 6: 753 - }, - 4: { - 1: 525, - 2: 591, - 3: 656, - 4: 730, - 5: 811, - 6: 879 - }, - 5: { - 1: 600, - 2: 675, - 3: 750, - 4: 834, - 5: 927, - 6: 1004 - }, - jede_weitere_person: { - 1: 71, - 2: 81, - 3: 91, - 4: 101, - 5: 111, - 6: 126 - } - - # Reference: Art. 1 G. v. 30.11.2019, BGBl I S. 1877. - from 2020-01-01 = { - 1: { - 1: 338, - 2: 381, - 3: 426, - 4: 478, - 5: 525, - 6: 575, - 7: 633 - }, - 2: { - 1: 409, - 2: 461, - 3: 516, - 4: 579, - 5: 636, - 6: 697, - 7: 767 - }, - 3: { - 1: 487, - 2: 549, - 3: 614, - 4: 689, - 5: 757, - 6: 830, - 7: 912 - }, - 4: { - 1: 568, - 2: 641, - 3: 716, - 4: 803, - 5: 884, - 6: 968, - 7: 1065 - }, - 5: { - 1: 649, - 2: 732, - 3: 818, - 4: 918, - 5: 1010, - 6: 1106, - 7: 1217 - }, - jede_weitere_person: { - 1: 77, - 2: 88, - 3: 99, - 4: 111, - 5: 121, - 6: 139, - 7: 153 - } - } - - # Reference: V. v. 03.06.2021 BGBl. I S. 1369. - from 2022-01-01 = { - 1: { - 1: 347, - 2: 392, - 3: 438, - 4: 491, - 5: 540, - 6: 591, - 7: 651 - }, - 2: { - 1: 420, - 2: 474, - 3: 530, - 4: 595, - 5: 654, - 6: 716, - 7: 788 - }, - 3: { - 1: 501, - 2: 564, - 3: 631, - 4: 708, - 5: 778, - 6: 853, - 7: 937 - }, - 4: { - 1: 584, - 2: 659, - 3: 736, - 4: 825, - 5: 909, - 6: 995, - 7: 1095 - }, - 5: { - 1: 667, - 2: 752, - 3: 841, - 4: 944, - 5: 1038, - 6: 1137, - 7: 1251 - }, - jede_weitere_person: { - 1: 79, - 2: 90, - 3: 102, - 4: 114, - 5: 124, - 6: 143, - 7: 157 - } - } + }; + }; } /** @@ -2235,11 +2243,11 @@ public constant maxMiete: Dict>> { */ public constant vermoegensgrundfreibetrag: Float { # No wealth threshold in place. - from 1970-01-01 = inf + from 1970-01-01 = inf; # Reference: Wohngeld-Verwaltungsvorschrift 2009. # At least in place since then. - from 2009-01-01 = 60000 + from 2009-01-01 = 60000; } /** @@ -2248,11 +2256,11 @@ public constant vermoegensgrundfreibetrag: Float { */ public constant vermoegensfreibetragPerson: Float { # No wealth threshold in place - from 1970-01-01 = inf + from 1970-01-01 = inf; # Reference: Wohngeld-Verwaltungsvorschrift 2009. # At least in place since then. - from 2009-01-01 = 30000 + from 2009-01-01 = 30000; } /** @@ -2262,15 +2270,15 @@ public constant vermoegensfreibetragPerson: Float { * Reference: §12 (6) WoGG, Art. 1 G. v. 15.05.2020, BGBl I S. 1015. * per month */ -public constant heizkostenentlastung: Dict { - from 2021-01-01 { - 1: 14.4, - 2: 18.6, - 3: 22.2, - 4: 25.8, - 5: 29.4, - jede_weitere_person: 3.6 - } +public constant heizkostenentlastung: Dict { + from 2021-01-01 = { + "1": 14.4, + "2": 18.6, + "3": 22.2, + "4": 25.8, + "5": 29.4, + "jede_weitere_person": 3.6 + }; } /** @@ -2280,15 +2288,16 @@ public constant heizkostenentlastung: Dict { * Reference: Art. 1 G. v. 08.12.2022 BGBl. I Nr. 48 S. 2160 * per month */ -public constant dauerhafteHeizkostenkomponente: Dict { - from 2023-01-01 { - 1: 96, - 2: 124, - 3: 148, - 4: 172, - 5: 196, - jede_weitere_person: 24 - } +public constant dauerhafteHeizkostenkomponente: Dict { + from 2023-01-01 = { + "1": 96, + "2": 124, + "3": 148, + "4": 172, + "5": 196, + "jede_weitere_person": 24 + }; +} /** * Klimakomponente @@ -2298,15 +2307,15 @@ public constant dauerhafteHeizkostenkomponente: Dict { * Reference: Art. 1 G. v. 08.12.2022 BGBl. I Nr. 48 S. 2160 * per month */ -public constant klimakomponente: Dict { +public constant klimakomponente: Dict { from 2023-01-01 = { - 1: 19.20, - 2: 24.80, - 3: 29.60, - 4: 34.40, - 5: 39.20, - jede_weitere_person: 4.8 - } + "1": 19.20, + "2": 24.80, + "3": 29.60, + "4": 34.40, + "5": 39.20, + "jede_weitere_person": 4.8 + }; } # TODO: rounding \ No newline at end of file From 6f6ed7f9a227047377d1e222b4f354622afd2492 Mon Sep 17 00:00:00 2001 From: alex-senger Date: Sat, 14 Sep 2024 14:12:22 +0200 Subject: [PATCH 177/183] umlaute --- .../arbeitslosenversicherung.ttsl" | 12 +-- .../beitragsbemessungsgrenzen.ttsl" | 8 +- .../einkommensgrenzen.ttsl" | 52 +++++----- .../gesetzlichekrankenversicherung.ttsl" | 96 +++++++++---------- .../gesetzlichepflegeversicherung.ttsl" | 56 +++++------ .../gesetzlicherentenversicherung.ttsl" | 14 +-- .../builtins/steuern/abgeltungssteuer.ttsl | 8 +- .../builtins/steuern/einkommenssteuer.ttsl | 14 +-- .../builtins/steuern/lohnsteuer.ttsl | 14 +-- 9 files changed, 137 insertions(+), 137 deletions(-) diff --git "a/src/resources/builtins/sozialversicherungsBeitr\303\244ge/arbeitslosenversicherung.ttsl" "b/src/resources/builtins/sozialversicherungsBeitr\303\244ge/arbeitslosenversicherung.ttsl" index 0023c87e..47557aa1 100644 --- "a/src/resources/builtins/sozialversicherungsBeitr\303\244ge/arbeitslosenversicherung.ttsl" +++ "b/src/resources/builtins/sozialversicherungsBeitr\303\244ge/arbeitslosenversicherung.ttsl" @@ -38,14 +38,14 @@ private function sozialversicherungsBeitragArbeitnehmerArbeitgeber(): Float per */ public function beitrag(): Float per month { to 2003-03-31 { - if (geringfuegigBeschaeftigt()) { + if (geringfügigBeschäftigt()) { return 0; } else { return gesetzlicheRentenversicherungBetragBruttolohn() per month * beitragssatz[arbeitslosenversicherung]; } } from 2003-04-01 { - if (geringfuegigBeschaeftigt()) { + if (geringfügigBeschäftigt()) { return 0; } @@ -62,7 +62,7 @@ public function beitrag(): Float per month { */ public function beitragArbeitgeber(): Float per month { to 2003-03-31 { - if (geringfuegigBeschaeftigt()) { + if (geringfügigBeschäftigt()) { return 0; } else { return gesetzlicheRentenversicherungBetragBruttolohn() per month * beitragssatz[arbeitslosenversicherung]; @@ -70,7 +70,7 @@ public function beitragArbeitgeber(): Float per month { } from 2003-04-01 { - if (geringfuegigBeschaeftigt()) { + if (geringfügigBeschäftigt()) { return 0; } @@ -78,11 +78,11 @@ public function beitragArbeitgeber(): Float per month { return arbeitslosenversicherungBeitragMidijobArbeitgeber() per month; } - return arbeitslosenversicherungRegulaerBeschaeftigt() per month; + return arbeitslosenversicherungRegulärBeschäftigt() per month; } } -/** +/** * Sum of employee's and employer's unemployment insurance contribution * for midijobs. */ diff --git "a/src/resources/builtins/sozialversicherungsBeitr\303\244ge/beitragsbemessungsgrenzen.ttsl" "b/src/resources/builtins/sozialversicherungsBeitr\303\244ge/beitragsbemessungsgrenzen.ttsl" index 4e8e986a..36cdc5a8 100644 --- "a/src/resources/builtins/sozialversicherungsBeitr\303\244ge/beitragsbemessungsgrenzen.ttsl" +++ "b/src/resources/builtins/sozialversicherungsBeitr\303\244ge/beitragsbemessungsgrenzen.ttsl" @@ -1,6 +1,6 @@ package beitragsbemessungsgrenzen -from sozialversicherungsbeitrag import beitragsbemessungsgrenze, monatlicheBezugsgroesse +from sozialversicherungsbeitrag import beitragsbemessungsgrenze, monatlicheBezugsgrße public function gesetzlicheRentenversicherung(): Float per month { params = beitragsbemessungsgrenze[ges_rentenv]; @@ -20,10 +20,10 @@ public function gesetzlicheKrankenversicherung(): Float per month { } } -public function gesetzlicheKrankenversicherungBezugsgroesse(): Float per month { +public function gesetzlicheKrankenversicherungBezugsgrße(): Float per month { if wohnort_ost() { - return monatlicheBezugsgroesse[ost]; + return monatlicheBezugsgrße[ost]; } else { - return monatlicheBezugsgroesse[west]; + return monatlicheBezugsgrße[west]; } } \ No newline at end of file diff --git "a/src/resources/builtins/sozialversicherungsBeitr\303\244ge/einkommensgrenzen.ttsl" "b/src/resources/builtins/sozialversicherungsBeitr\303\244ge/einkommensgrenzen.ttsl" index cf6686c9..07d5ff67 100644 --- "a/src/resources/builtins/sozialversicherungsBeitr\303\244ge/einkommensgrenzen.ttsl" +++ "b/src/resources/builtins/sozialversicherungsBeitr\303\244ge/einkommensgrenzen.ttsl" @@ -1,14 +1,14 @@ package einkomensgrenzen -from sozialversicherungsbeitrag import geringfuegigeEinkommensgrenzenMonatlich, mindestlohn, geringfuegigeEinkommensfaktor, geringfuegigeEinkommensdivisor, beitragssatz +from sozialversicherungsbeitrag import geringfügigeEinkommensgrenzenMonatlich, mindestlohn, geringfügigeEinkommensfaktor, geringfügigeEinkommensdivisor, beitragssatz /** * Select the income threshold depending on place of living. */ public function minijobGrenze(): Float per month { to 1999-12-31 { - var west = geringfuegigeEinkommensgrenzenMonatlich[minijob][west] - var ost = geringfuegigeEinkommensgrenzenMonatlich[minijob][ost] + var west = geringfügigeEinkommensgrenzenMonatlich[minijob][west] + var ost = geringfügigeEinkommensgrenzenMonatlich[minijob][ost] if wohnort_ost() { return ost } else { @@ -17,7 +17,7 @@ public function minijobGrenze(): Float per month { } from 2000-01-01 to 2022-09-30 { - return geringfuegigeEinkommensgrenzenMonatlich[minijob] + return geringfügigeEinkommensgrenzenMonatlich[minijob] } /** @@ -25,7 +25,7 @@ public function minijobGrenze(): Float per month { * the statutory minimum wage. */ from 2022-10-01 { - return mindestlohn * geringfuegigeEinkommensfaktor / geringfuegigeEinkommensdivisor + return mindestlohn * geringfügigeEinkommensfaktor / geringfügigeEinkommensdivisor } } @@ -34,7 +34,7 @@ public function minijobGrenze(): Float per month { * Marginal employed pay no social insurance contributions. * Legal reference: § 8 Abs. 1 Satz 1 and 2 SGB IV */ -public function geringuegigBeschaeftigt(bruttolohn per month): Boolean { +public function geringügigBeschäftigt(bruttolohn per month): Boolean { return bruttolohn per month <= minijobGrenze() } @@ -46,7 +46,7 @@ public function geringuegigBeschaeftigt(bruttolohn per month): Boolean { */ public function inGleitzone(bruttolohn per month): Boolean { from 2003-04-01 { - return (bruttolohn per month <= geringfuegigeEinkommensgrenzenMonatlich[midijob]) and (not geringuegigBeschaeftigt(bruttolohn per month)); + return (bruttolohn per month <= geringfügigeEinkommensgrenzenMonatlich[midijob]) and (not geringügigBeschäftigt(bruttolohn per month)); } } @@ -63,7 +63,7 @@ public function midijobFaktorF(): Float { + beitragssatz[arbeitslosenversicherung] ); - allg_sozialv_beitr += beitragssatz[ges_pflegev]; + allg_sozialv_beitr = allg_sozialv_beitr + beitragssatz[ges_pflegev]; # Then calculate specific shares var an_anteil = allg_sozialv_beitr + gesetzlicheKrankenversicherungBeitragssatzJahresanfang(); @@ -71,9 +71,9 @@ public function midijobFaktorF(): Float { # Sum over the shares which are specific for midijobs. var pausch_mini = ( - pauschalabgabenGeringfuegigeBeschaeftigung[ges_krankenv] - + pauschalabgabenGeringfuegigeBeschaeftigung[ges_rentenv] - + pauschalabgabenGeringfuegigeBeschaeftigung[st] + pauschalabgabenGeringfügigeBeschäftigung[ges_krankenv] + + pauschalabgabenGeringfügigeBeschäftigung[ges_rentenv] + + pauschalabgabenGeringfügigeBeschäftigung[st] ); # Now calculate final factor @@ -100,9 +100,9 @@ public function midijobFaktorF(): Float { # Sum over the shares which are specific for midijobs. var pausch_mini = ( - pauschalabgabenGeringfuegigeBeschaeftigung[ges_krankenv] - + pauschalabgabenGeringfuegigeBeschaeftigung[ges_rentenv] - + pauschalabgabenGeringfuegigeBeschaeftigung[st] + pauschalabgabenGeringfügigeBeschäftigung[ges_krankenv] + + pauschalabgabenGeringfügigeBeschäftigung[ges_rentenv] + + pauschalabgabenGeringfügigeBeschäftigung[st] ); # Now calculate final factor @@ -129,8 +129,8 @@ public function midijobFaktorF(): Float { # New formula only inludes the lump-sum contributions to health care # and pension insurance var pausch_mini = ( - pauschalabgabenGeringfuegigeBeschaeftigung[ges_krankenv] - pauschalabgabenGeringfuegigeBeschaeftigung[ges_rentenv] + pauschalabgabenGeringfügigeBeschäftigung[ges_krankenv] + pauschalabgabenGeringfügigeBeschäftigung[ges_rentenv] ) # Now calculate final factor f @@ -138,7 +138,7 @@ public function midijobFaktorF(): Float { } } -/** +/** * Income subject to social insurance contributions for midijob until September * 2022. * Bemessungsgeld (Gleitzonenentgelt) is the reference income for midijobs subject to @@ -149,23 +149,23 @@ public function midijobBemessungsgeld(bruttolohn per month): Float per month { from 2003-04-01 { # Now use the factor to calculate the overall bemessungsentgelt var minijob_anteil = midijobFaktorF() * minijobGrenze() - var lohn_ueber_mini = bruttolohn per month - minijobGrenze() + var lohn_über_mini = bruttolohn per month - minijobGrenze() var gewichtete_midijob_rate = ( - geringfuegigeEinkommensgrenzenMonatlich[midijob] + geringfügigeEinkommensgrenzenMonatlich[midijob] / ( - geringfuegigeEinkommensgrenzenMonatlich[midijob] + geringfügigeEinkommensgrenzenMonatlich[midijob] - minijobGrenze() ) ) - ( minijobGrenze() / ( - geringfuegigeEinkommensgrenzenMonatlich[midijob] + geringfügigeEinkommensgrenzenMonatlich[midijob] - minijobGrenze() ) * midijobFaktorF() ) - return minijob_anteil + lohn_ueber_mini * gewichtete_midijob_rate + return minijob_anteil + lohn_über_mini * gewichtete_midijob_rate } /** @@ -177,7 +177,7 @@ public function midijobBemessungsgeld(bruttolohn per month): Float per month { * Legal reference: Changes in § 20 SGB IV from 01.10.2022 */ from 2022-10-01 { - var midijob_grenze = geringfuegigeEinkommensgrenzenMonatlich[midijob] + var midijob_grenze = geringfügigeEinkommensgrenzenMonatlich[midijob] var quotient1 = (midijob_grenze) / (midijob_grenze - minijobGrenze()) var quotient2 = (minijobGrenze()) / (midijob_grenze - minijobGrenze()) @@ -197,7 +197,7 @@ public function midijobBemessungsgeld(bruttolohn per month): Float per month { * Legal reference: Changes in § 20 SGB IV from 01.10.2022 */ private function midijobBeitragspflichtigeEinnahmeArbeitnehmer(bruttolohn per month): Float per month { - var midijob_grenze = geringfuegigeEinkommensgrenzenMonatlich[midijob] + var midijob_grenze = geringfügigeEinkommensgrenzenMonatlich[midijob] var quotient = midijob_grenze / (midijob_grenze - minijobGrenze()) var einkommen_diff = bruttolohn per month - minijobGrenze() @@ -206,7 +206,7 @@ private function midijobBeitragspflichtigeEinnahmeArbeitnehmer(bruttolohn per mo } -public function regulaerBeschaeftigt(bruttolohn per month): Boolean { +public function regulärBeschäftigt(bruttolohn per month): Boolean { /** * Regular employment check until March 2003. * Employees earning more than the minijob threshold, are subject to all ordinary @@ -224,6 +224,6 @@ public function regulaerBeschaeftigt(bruttolohn per month): Boolean { * regular employed. */ from 2003-04-01 { - return bruttolohn per month >= geringfuegigeEinkommensgrenzenMonatlich[midijob] + return bruttolohn per month >= geringfügigeEinkommensgrenzenMonatlich[midijob] } } diff --git "a/src/resources/builtins/sozialversicherungsBeitr\303\244ge/gesetzlichekrankenversicherung.ttsl" "b/src/resources/builtins/sozialversicherungsBeitr\303\244ge/gesetzlichekrankenversicherung.ttsl" index d4545375..e319763d 100644 --- "a/src/resources/builtins/sozialversicherungsBeitr\303\244ge/gesetzlichekrankenversicherung.ttsl" +++ "b/src/resources/builtins/sozialversicherungsBeitr\303\244ge/gesetzlichekrankenversicherung.ttsl" @@ -1,60 +1,60 @@ package gesetzlicheKrankenversicherung -from sozialversicherungsBeitragsParameter import pauschalabgabenGeringfuegigeBeschaeftigung, beitragssatz, mindestanteilBezugsgroesseBeitragspflichtigeEinnahmeSelbst +from sozialversicherungsBeitragsParameter import pauschalabgabenGeringfügigeBeschäftigung, beitragssatz, mindestanteilBezugsgrßeBeitragspflichtigeEinnahmeSelbst from math import min, max /** - * Beitrag fuer die gesetzliche Krankenversicherung. + * Beitrag für die gesetzliche Krankenversicherung. */ public function beitrag( - selbststaendig: Boolean + selbstständig: Boolean ): Float per month { to 2003-03-31 { - if selbststaendig { - return beitragSelbststaendig() + beitragRente(); + if selbstständig { + return beitragSelbstständig() + beitragRente(); } - if geringfuegigBeschaeftigt { + if geringfügigBeschäftigt { return 0 + beitragRente(); } - return beitragRegulaerBeschaeftigt() + beitragRente(); + return beitragRegulärBeschäftigt() + beitragRente(); } from 2003-04-01 { - if selbststaendig { - return beitragSelbststaendig() + beitragRente(); + if selbstständig { + return beitragSelbstständig() + beitragRente(); } - if geringfuegigBeschaeftigt { + if geringfügigBeschäftigt { return 0 + beitragRente(); } if inGleitzone { return beitragMidijobArbeitnehmer() + beitragRente(); } - return beitragRegulaerBeschaeftigt() + beitragRente(); + return beitragRegulärBeschäftigt() + beitragRente(); } } /** - * Beitrag des Arbeitgebers fuer die gesetzliche Krankenversicherung. + * Beitrag des Arbeitgebers für die gesetzliche Krankenversicherung. */ public function beitragArbeitgeber( - geringfuegigBeschaeftigt: Boolean, - selbststaendig: Boolean, + geringfügigBeschäftigt: Boolean, + selbstständig: Boolean, bruttolohn: Float ): Float per month { to 2003-03-31 { - if selbststaendig { + if selbstständig { return 0.0; - } else if geringfuegigBeschaeftigt { - return bruttolohn * pauschalabgabenGeringfuegigeBeschaeftigung["ges_krankenv"]; + } else if geringfügigBeschäftigt { + return bruttolohn * pauschalabgabenGeringfügigeBeschäftigung["ges_krankenv"]; } else { return bruttolohnMonatlich() * beitragssatzArbeitgeber(); } } from 2003-04-01 { - if selbststaendig { + if selbstständig { return 0.0; - } else if geringfuegigBeschaeftigt { - return bruttolohn * pauschalabgabenGeringfuegigeBeschaeftigung["ges_krankenv"]; + } else if geringfügigBeschäftigt { + return bruttolohn * pauschalabgabenGeringfügigeBeschäftigung["ges_krankenv"]; } else if inGleitzone { return beitragMidijobArbeitgeber(); } else { @@ -76,7 +76,7 @@ public function zusatzbeitragssatz(): Float per year { } /** - * Beitragssatz fuer die gesetzliche Krankenversicherung, inklusive kassenspezifischer und einheitlicher Zusatzbeitragssaetze. + * Beitragssatz für die gesetzliche Krankenversicherung, inklusive kassenspezifischer und einheitlicher Zusatzbeitragssätze. */ public function beitragssatz(): Float per month { to 2005-06-30 { @@ -97,7 +97,7 @@ public function beitragssatz(): Float per month { } /** - * Beitragssatz fuer die gesetzliche Krankenversicherung am Jahresanfang, inklusive kassenspezifischer und einheitlicher Zusatzbeitragssaetze. + * Beitragssatz für die gesetzliche Krankenversicherung am Jahresanfang, inklusive kassenspezifischer und einheitlicher Zusatzbeitragssätze. */ public function beitragssatzJahresanfang(): Float per month { to 2005-06-30 { @@ -118,7 +118,7 @@ public function beitragssatzJahresanfang(): Float per month { } /** - * Beitragssatz des Arbeitgebers fuer die gesetzliche Krankenversicherung, inklusive kassenspezifischer und einheitlicher Zusatzbeitragssaetze. + * Beitragssatz des Arbeitgebers für die gesetzliche Krankenversicherung, inklusive kassenspezifischer und einheitlicher Zusatzbeitragssätze. */ public function beitragssatzArbeitgeber(): Float per month { to 2008-12-31 { @@ -135,7 +135,7 @@ public function beitragssatzArbeitgeber(): Float per month { } /** - * Beitragssatz des Arbeitgebers fuer die gesetzliche Krankenversicherung am Jahresanfang, inklusive kassenspezifischer und einheitlicher Zusatzbeitragssaetze. + * Beitragssatz des Arbeitgebers für die gesetzliche Krankenversicherung am Jahresanfang, inklusive kassenspezifischer und einheitlicher Zusatzbeitragssätze. */ public function beitragssatzArbeitgeberJahresanfang(): Float per month { to 2008-12-31 { @@ -152,9 +152,9 @@ public function beitragssatzArbeitgeberJahresanfang(): Float per month { } /** - * Bruttolohn fuer regulaer Beschaeftigte, der der gesetzlichen Krankenversicherung unterliegt. + * Bruttolohn für regulär Beschäftigte, der der gesetzlichen Krankenversicherung unterliegt. */ -public function bruttolohnRegulaerBeschaeftigt( +public function bruttolohnRegulärBeschäftigt( bruttolohn: Float ): Float per month { if bruttolohn > beitragsbemessungsgrenze() { @@ -168,36 +168,36 @@ public function bruttolohnRegulaerBeschaeftigt( * Bruttolohn, der der gesetzlichen Krankenversicherung unterliegt. */ public function bruttolohn( - regulaerBeschaeftigt: Boolean + regulärBeschäftigt: Boolean ): Float per month { - if regulaerBeschaeftigt { - return bruttolohnRegulaerBeschaeftigt(); + if regulärBeschäftigt { + return bruttolohnRegulärBeschäftigt(); } else { return 0.0; } } /** - * Beitrag fuer regulaer Beschaeftigte. + * Beitrag für regulär Beschäftigte. */ -public function beitragRegulaerBeschaeftigt(): Float per month { +public function beitragRegulärBeschäftigt(): Float per month { return beitragssatz() * bruttolohn(); } /** - * Bemessungsgrundlage fuer selbststaendiges Einkommen. + * Bemessungsgrundlage für selbstständiges Einkommen. */ -public function bemessungsgrundlageSelbststaendig( - einkommenSelbststaendig: Float, - selbststaendig: Boolean, +public function bemessungsgrundlageSelbstständig( + einkommenSelbstständig: Float, + selbstständig: Boolean, inPrivaterKrankenversicherung: Boolean, ): Float per month { - if selbststaendig and not inPrivaterKrankenversicherung { + if selbstständig and not inPrivaterKrankenversicherung { return min( beitragsbemessungsgrenze(), max( - bezugsgroesseSelbststaendig() * mindestanteilBezugsgroesseBeitragspflichtigeEinnahmeSelbst, - einkommenSelbststaendig + bezugsgrßeSelbstständig() * mindestanteilBezugsgrßeBeitragspflichtigeEinnahmeSelbst, + einkommenSelbstständig ) ); } else { @@ -206,32 +206,32 @@ public function bemessungsgrundlageSelbststaendig( } /** - * Beitrag fuer selbststaendiges Einkommen. + * Beitrag für selbstständiges Einkommen. */ -public function beitragSelbststaendig(): Float per month { +public function beitragSelbstständig(): Float per month { var params = beitragssatz["gesetzlicheKrankenversicherung"]; - var ermaessigterBeitrag = params["ermaessigt"] if "ermaessigt" in params else params["mean_allgemein"]; + var ermßigterBeitrag = params["ermßigt"] if "ermßigt" in params else params["mean_allgemein"]; var zusatzbeitrag = params["mean_zusatzbeitrag"] if "mean_zusatzbeitrag" in params else 0.0; - var beitragssatzSelbststaendig = ermaessigterBeitrag + zusatzbeitrag; - return beitragssatzSelbststaendig * bemessungsgrundlageSelbststaendig(); + var beitragssatzSelbstständig = ermßigterBeitrag + zusatzbeitrag; + return beitragssatzSelbstständig * bemessungsgrundlageSelbstständig(); } /** - * Bemessungsgrundlage fuer Renteneinkommen. + * Bemessungsgrundlage für Renteneinkommen. */ public function bemessungsgrundlageRente(): Float per month { return min(summeGesetzlicheRentePrivateRente(), beitragsbemessungsgrenze()); } /** - * Beitrag fuer Renteneinkommen. + * Beitrag für Renteneinkommen. */ public function beitragRente(): Float per month { return beitragssatz() * bemessungsgrundlageRente(); } /** - * Beitrag fuer Midijobs. + * Beitrag für Midijobs. */ public function beitragMidijobSummeArbeitnehmerArbeitgeber(): Float per month { from 2003-04-01 { @@ -240,7 +240,7 @@ public function beitragMidijobSummeArbeitnehmerArbeitgeber(): Float per month { } /** - * Arbeitgeberanteil fuer Midijobs. + * Arbeitgeberanteil für Midijobs. */ public function beitragMidijobArbeitgeber( bruttolohn: Float @@ -262,7 +262,7 @@ public function beitragMidijobArbeitgeber( } /** - * Arbeitnehmeranteil fuer Midijobs. + * Arbeitnehmeranteil für Midijobs. */ public function beitragMidijobArbeitnehmer(): Float per month { from 2003-04-01 to 2022-09-30 { diff --git "a/src/resources/builtins/sozialversicherungsBeitr\303\244ge/gesetzlichepflegeversicherung.ttsl" "b/src/resources/builtins/sozialversicherungsBeitr\303\244ge/gesetzlichepflegeversicherung.ttsl" index 75f655a8..2b49c39c 100644 --- "a/src/resources/builtins/sozialversicherungsBeitr\303\244ge/gesetzlichepflegeversicherung.ttsl" +++ "b/src/resources/builtins/sozialversicherungsBeitr\303\244ge/gesetzlichepflegeversicherung.ttsl" @@ -3,7 +3,7 @@ package gesetzlichePflegeversicherung from sozialversicherungsBeitragsParameter import beitragssatz, mindestalterBeitragszuschlagKinderlose /** - * Zusaetzlicher Beitrag fuer Kinderlose ab 2005. + * Zusätzlicher Beitrag für Kinderlose ab 2005. */ public function zusatzbeitragKinderlos( hatKinder: Boolean, @@ -16,7 +16,7 @@ public function zusatzbeitragKinderlos( } /** - * Beitragssatz fuer die gesetzliche Pflegeversicherung. + * Beitragssatz für die gesetzliche Pflegeversicherung. */ public function beitragssatz( anzEigeneKinderBis24: Int @@ -44,57 +44,57 @@ public function beitragssatz( } /** - * Beitrag fuer die gesetzliche Pflegeversicherung bis Maerz 2003. + * Beitrag für die gesetzliche Pflegeversicherung bis März 2003. */ public function beitrag( - selbststaendig: Boolean + selbstständig: Boolean ): Float per month { to 2003-03-31 { - if selbststaendig { - return beitragSelbststaendig() + beitragRente(); + if selbstständig { + return beitragSelbstständig() + beitragRente(); } - if geringfuegigBeschaeftigt { + if geringfügigBeschäftigt { return 0 + beitragRente(); } - return beitragRegulaerBeschaeftigt() + beitragRente(); + return beitragRegulärBeschäftigt() + beitragRente(); } from 2003-04-01 { - if selbststaendig { - return beitragSelbststaendig() + beitragRente(); + if selbstständig { + return beitragSelbstständig() + beitragRente(); } - if geringfuegigBeschaeftigt { + if geringfügigBeschäftigt { return 0 + beitragRente(); } if inGleitzone { return beitragMidijobArbeitnehmer() + beitragRente(); } - return beitragRegulaerBeschaeftigt() + beitragRente(); + return beitragRegulärBeschäftigt() + beitragRente(); } } /** - * Beitrag fuer regulaer Beschaeftigte in der gesetzlichen Pflegeversicherung. + * Beitrag für regulär Beschäftigte in der gesetzlichen Pflegeversicherung. */ -public function beitragRegulaerBeschaeftigt(): Float per month { - var beitrRegulaerBeschaeftigt = gesetzlicheKrankenversicherung.bruttolohn() * beitragssatz(); - return beitrRegulaerBeschaeftigt; +public function beitragRegulärBeschäftigt(): Float per month { + var beitrRegulärBeschäftigt = gesetzlicheKrankenversicherung.bruttolohn() * beitragssatz(); + return beitrRegulärBeschäftigt; } /** - * Beitrag des Arbeitgebers fuer die gesetzliche Pflegeversicherung bis Maerz 2003. + * Beitrag des Arbeitgebers für die gesetzliche Pflegeversicherung bis März 2003. */ public function beitragArbeitgeber( - selbststaendig: Boolean + selbstständig: Boolean ): Float per month { to 2003-03-31 { - if selbststaendig or geringfuegigBeschaeftigt { + if selbstständig or geringfügigBeschäftigt { return 0.0; } else { return bruttolohn * beitragssatz["ges_pflegev"]; } } from 2003-04-01 { - if selbststaendig or geringfuegigBeschaeftigt { + if selbstständig or geringfügigBeschäftigt { return 0.0; } else if inGleitzone { return beitragMidijobArbeitgeber; @@ -105,19 +105,19 @@ public function beitragArbeitgeber( } /** - * Beitragssatz fuer selbststaendige bis Maerz 2003. + * Beitragssatz für selbstständige bis März 2003. */ -public function beitragSelbststaendig(): Float per month { +public function beitragSelbstständig(): Float per month { from 1995-01-01 to 2004-12-31 { - return bemessungsgrundlageSelbststaendig() * beitragssatz["ges_pflegev"] * 2; + return bemessungsgrundlageSelbstständig() * beitragssatz["ges_pflegev"] * 2; } from 2005-01-01 { - return bemessungsgrundlageSelbststaendig() * (beitragssatz() + beitragssatz["ges_pflegev"]["standard"]); + return bemessungsgrundlageSelbstständig() * (beitragssatz() + beitragssatz["ges_pflegev"]["standard"]); } } /** - * Beitrag fuer Renteneinkommen in der gesetzlichen Pflegeversicherung. + * Beitrag für Renteneinkommen in der gesetzlichen Pflegeversicherung. */ public function beitragRente(): Float per month { to 2004-03-31 { @@ -134,7 +134,7 @@ public function beitragRente(): Float per month { } /** - * Beitrag fuer Midijobs. + * Beitrag für Midijobs. */ public function beitragMidijobSummeArbeitnehmerArbeitgeber(): Float per month { from 2003-04-01 to 2004-12-31 { @@ -146,7 +146,7 @@ public function beitragMidijobSummeArbeitnehmerArbeitgeber(): Float per month { } /** - * Arbeitgeberanteil fuer Midijobs bis Dezember 2004. + * Arbeitgeberanteil für Midijobs bis Dezember 2004. */ public function beitragMidijobArbeitgeber( bruttolohn: Float @@ -163,7 +163,7 @@ public function beitragMidijobArbeitgeber( } /** - * Arbeitnehmeranteil fuer Midijobs in der gesetzlichen Pflegeversicherung. + * Arbeitnehmeranteil für Midijobs in der gesetzlichen Pflegeversicherung. */ public function beitragMidijobArbeitnehmer( anzEigeneKinderBis24: Int diff --git "a/src/resources/builtins/sozialversicherungsBeitr\303\244ge/gesetzlicherentenversicherung.ttsl" "b/src/resources/builtins/sozialversicherungsBeitr\303\244ge/gesetzlicherentenversicherung.ttsl" index 25253582..bcd2a5f4 100644 --- "a/src/resources/builtins/sozialversicherungsBeitr\303\244ge/gesetzlicherentenversicherung.ttsl" +++ "b/src/resources/builtins/sozialversicherungsBeitr\303\244ge/gesetzlicherentenversicherung.ttsl" @@ -1,6 +1,6 @@ package gesetzlicheRentenversicherung -from sozialversicherungsBeitragsParameter import beitragssatz, pauschalabgabenGeringfuegigeBeschaeftigung +from sozialversicherungsBeitragsParameter import beitragssatz, pauschalabgabenGeringfügigeBeschäftigung from math import min @@ -10,7 +10,7 @@ from math import min public function beitrag(): Float per month { to 2003-03-31 { var beitrRegularJob = bruttolohn() * beitragssatz["ges_rentenv"]; - if geringfuegigBeschaeftigt() { + if geringfügigBeschäftigt() { return 0.0; } else { return beitrRegularJob(); @@ -18,7 +18,7 @@ public function beitrag(): Float per month { } from 2003-04-01 { var beitrRegularJob = bruttolohn() * beitragssatz["ges_rentenv"]; - if geringfuegigBeschaeftigt() { + if geringfügigBeschäftigt() { return 0.0; } else if inGleitzone() { return beitrMidijobArbeitnehmer(); @@ -36,16 +36,16 @@ public function beitragArbeitgeber( ): Float per month { to 2003-03-31 { var beitrRegularJob = bruttolohn * beitragssatz["ges_rentenv"]; - if geringfuegigBeschaeftigt() { - return bruttolohn * pauschalabgabenGeringfuegigeBeschaeftigung["ges_rentenv"]; + if geringfügigBeschäftigt() { + return bruttolohn * pauschalabgabenGeringfügigeBeschäftigung["ges_rentenv"]; } else { return beitrRegularJob(); } } from 2003-04-01 { var beitrRegularJob = bruttolohn * beitragssatz["ges_rentenv"]; - if geringfuegigBeschaeftigt() { - return bruttolohn * pauschalabgabenGeringfuegigeBeschaeftigung["ges_rentenv"]; + if geringfügigBeschäftigt() { + return bruttolohn * pauschalabgabenGeringfügigeBeschäftigung["ges_rentenv"]; } else if inGleitzone { return beitrMidijobArbeitgeber(); } else { diff --git a/src/resources/builtins/steuern/abgeltungssteuer.ttsl b/src/resources/builtins/steuern/abgeltungssteuer.ttsl index bf86e9b8..9e150614 100644 --- a/src/resources/builtins/steuern/abgeltungssteuer.ttsl +++ b/src/resources/builtins/steuern/abgeltungssteuer.ttsl @@ -1,7 +1,7 @@ package abgeltungssteuer from abgeltungssteuersatz import abgeltungssteuersatz -from einkommenssteuerAbzuege import sparerpauschbetrag, sparerWerbungskostenPauschbetrag +from einkommenssteuerAbzüge import sparerpauschbetrag, sparerWerbungskostenPauschbetrag from math import max /** @@ -9,17 +9,17 @@ from math import max */ public function abgeltungssteuer(): Float per year { from 2009-01-01 { - return abgeltungssteuersatz * zuVersteuerndeKapitalertraege(); + return abgeltungssteuersatz * zuVersteuerndeKapitalerträge(); } } /** * Berechnung des zu versteuernden Einkommens auf Steuernummer-Ebene. */ -public function zuVersteuerndeKapitalertraege(): Float per year { +public function zuVersteuerndeKapitalerträge(): Float per year { var abzug = anzahlPersonen() * ( sparerpauschbetrag + sparerWerbungskostenPauschbetrag ); - return max(kapitalertraegeBrutto() - abzug, 0.0); + return max(kapitalerträgeBrutto() - abzug, 0.0); } \ No newline at end of file diff --git a/src/resources/builtins/steuern/einkommenssteuer.ttsl b/src/resources/builtins/steuern/einkommenssteuer.ttsl index cac3bfc9..a7d0c7d7 100644 --- a/src/resources/builtins/steuern/einkommenssteuer.ttsl +++ b/src/resources/builtins/steuern/einkommenssteuer.ttsl @@ -45,7 +45,7 @@ public function einkommenssteuer(): Float per year { einkommenssteuerMitKinderfreibetrag() } from 1997-01-01 { - if kinderfreibetragGuenstiger() { + if kinderfreibetragGünstiger() { return einkommenssteuerMitKinderfreibetrag() + relativesKindergeld(); } else { return einkommenssteuerOhneKinderfreibetrag(); @@ -56,7 +56,7 @@ public function einkommenssteuer(): Float per year { /** * Bestimmung, ob der Kinderfreibetrag günstiger ist als das Kindergeld. */ -public function kinderfreibetragGuenstiger(): Boolean { +public function kinderfreibetragGünstiger(): Boolean { var differenzbetrag = einkommenssteuerOhneKinderfreibetrag() - einkommenssteuerMitKinderfreibetrag(); return differenzbetrag > relativesKindergeld(); } @@ -66,19 +66,19 @@ public function kinderfreibetragGuenstiger(): Boolean { */ public function relativesKindergeldOhneStaffelung(): Float per month { to 2022-12-31 { - var anzahlAnsprueche = anzahlAnsprueche1() + anzahlAnsprueche2(); - if anzahlAnsprueche == 0 { + var anzahlAnsprüche = anzahlAnsprüche1() + anzahlAnsprüche2(); + if anzahlAnsprüche == 0 { return 0.0; } var sumKindergeld = 0.0; - for(var i = 1; i < anzahlAnsprueche; i = i + 1) { + for(var i = 1; i < anzahlAnsprüche; i = i + 1) { var kindergeldKey = min(i, max(kindergeldParameter["kindergeld"].keys())); sumKindergeld += kindergeldParameter["kindergeld"][kindergeldKey]; } return sumKindergeld / 2; } from 2023-01-01 { - var anzahlAnsprueche = anzahlAnsprueche1 + anzahlAnsprueche2; - return kindergeldParameter["kindergeld"] * anzahlAnsprueche / 2; + var anzahlAnsprüche = anzahlAnsprüche1 + anzahlAnsprüche2; + return kindergeldParameter["kindergeld"] * anzahlAnsprüche / 2; } } \ No newline at end of file diff --git a/src/resources/builtins/steuern/lohnsteuer.ttsl b/src/resources/builtins/steuern/lohnsteuer.ttsl index e0ba9101..bc634396 100644 --- a/src/resources/builtins/steuern/lohnsteuer.ttsl +++ b/src/resources/builtins/steuern/lohnsteuer.ttsl @@ -1,6 +1,6 @@ package lohnsteuer -from einkommenssteuerAbzuege import alleinerzFreibetrag, werbungskostenpauschale, sonderausgabenpauschbetrag, einkommenssteuerTarif, vorsorgepauschaleMindestanteil, vorsorgepauschaleKvMax +from einkommenssteuerAbzüge import alleinerzFreibetrag, werbungskostenpauschale, sonderausgabenpauschbetrag, einkommenssteuerTarif, vorsorgepauschaleMindestanteil, vorsorgepauschaleKvMax from sozialversicherungsbeitrag import beitragssatz from einkommenssteuer import einkommenssteuer from math import max @@ -55,7 +55,7 @@ public function vorsorgeKrankenversicherungOptionB( ): Float per year { to 2018-12-31 { return bruttolohn * 12 * ( - beitragssatz["gesetzlicheKrankenversicherung"]["ermaessigt"] / 2 + beitragssatz["gesetzlicheKrankenversicherung"]["ermßigt"] / 2 + krankenversicherungZusatzbeitragssatz() / 100 + pflegeversicherungBeitragssatz() ); @@ -63,7 +63,7 @@ public function vorsorgeKrankenversicherungOptionB( from 2019-01-01 { return bruttolohn * 12 * ( - beitragssatz["gesetzlicheKrankenversicherung"]["ermaessigt"] / 2 + beitragssatz["gesetzlicheKrankenversicherung"]["ermßigt"] / 2 + krankenversicherungZusatzbeitragssatz() / 2 / 100 + pflegeversicherungBeitragssatz() ); @@ -126,16 +126,16 @@ public function vorsorgePauschale( /** * Berechnung des Kinderfreibetrags für die Lohnsteuer und den Solidaritätszuschlag. */ -public function kinderfreibetragFuerLohnsteuerSoli( +public function kinderfreibetragFürLohnsteuerSoli( steuerklasse: Int ): Float per year { - Float kinderfreibetragBasis = kinderfreibetrag["SaechlichesExistenzminimum"] + Float kinderfreibetragBasis = kinderfreibetrag["SächlichesExistenzminimum"] + kinderfreibetragBeitrag["ErziehungAusbildung"]; if steuerklasse == 1 or steuerklasse == 2 or steuerklasse == 3} { - return kinderfreibetragBasis * 2 * kinderfreibetragAnsprueche(); + return kinderfreibetragBasis * 2 * kinderfreibetragAnsprüche(); } else if steuerklasse == 4 { - return kinderfreibetragBasis * kinderfreibetragAnsprueche(); + return kinderfreibetragBasis * kinderfreibetragAnsprüche(); } else { return 0.0; } From 3440a1a810b1a5e7d88098785d0ffb77f707b134 Mon Sep 17 00:00:00 2001 From: alex-senger Date: Fri, 20 Sep 2024 20:04:06 +0200 Subject: [PATCH 178/183] add method linking in arbeitslosenversicherung --- .../arbeitslosenversicherung.ttsl" | 39 ++++++++++++------- .../einkommensgrenzen.ttsl" | 4 +- 2 files changed, 28 insertions(+), 15 deletions(-) diff --git "a/src/resources/builtins/sozialversicherungsBeitr\303\244ge/arbeitslosenversicherung.ttsl" "b/src/resources/builtins/sozialversicherungsBeitr\303\244ge/arbeitslosenversicherung.ttsl" index 47557aa1..4e93980b 100644 --- "a/src/resources/builtins/sozialversicherungsBeitr\303\244ge/arbeitslosenversicherung.ttsl" +++ "b/src/resources/builtins/sozialversicherungsBeitr\303\244ge/arbeitslosenversicherung.ttsl" @@ -1,15 +1,29 @@ package arbeitslosenversicherung -from sozialversichernugsbeitrag import beitragssatz +from gesetzlichePflegeversicherung import beitrag as gesetzlichePflegeVersicherungsBeitrag +from gesetzlicheKrankenversicherung import beitrag as gesetzlicheKrankenVersicherungsBeitrag +from gesetzlicheRentenversicherung import beitrag as gesetzlicheRentenVersicherungsBeitrag + +from gesetzlichePflegeversicherung import beitragArbeitgeber as gesetzlicherPflegeVersicherungsBeitragArbeitgeber +from gesetzlicheKrankenversicherung import beitragArbeitgeber as gesetzlicherKrankenVersicherungsBeitragArbeitgeber +from gesetzlicheRentenversicherung import beitragArbeitgeber as gesetzlicherRentenVersicherungsBeitragArbeitgeber + +from einkommensgrenzen import geringfügigBeschäftigt +from einkommensgrenzen import inGleitzone +from einkommensgrenzen import midijobBemessungsentgeld +from einkommensgrenzen import midijobBeitragspflichtigeEinnahmeArbeitnehmer +from gesetzlicheRentenversicherung import beitragBruttolohn as gesetzlicheRentenversicherungBetragBruttolohn + +from parameters.sozialversicherungsbeitrag import arbeitslosenversicherung as beitragssatzArbeitslosenversicherung /** * Sum of employee's social insurance contributions. */ -public function sozialversicherungsBeitrag(): Float per month { +public function per month sozialversicherungsBeitrag(): Float { var pv = gesetzlichePflegeVersicherungsBeitrag() per month; var kv = gesetzlicheKrankenVersicherungsBeitrag() per month; var rv = gesetzlicheRentenVersicherungsBeitrag() per month; - var av = arbeitslosenversicherungsBeitrag() per month; + var av = beitrag() per month; return pv + kv + rv + av; } @@ -21,7 +35,7 @@ public function sozialversicherungsBeitragArbeitgeber(): Float per month { var pv = gesetzlicherPflegeVersicherungsBeitragArbeitgeber() per month; var kv = gesetzlicherKrankenVersicherungsBeitragArbeitgeber() per month; var rv = gesetzlicherRentenVersicherungsBeitragArbeitgeber() per month; - var av = arbeitslosenversicherungsBeitragArbeitgeber() per month; + var av = beitragArbeitgeber() per month; return pv + kv + rv + av; } @@ -41,7 +55,7 @@ public function beitrag(): Float per month { if (geringfügigBeschäftigt()) { return 0; } else { - return gesetzlicheRentenversicherungBetragBruttolohn() per month * beitragssatz[arbeitslosenversicherung]; + return gesetzlicheRentenversicherungBetragBruttolohn() per month * beitragssatzArbeitslosenversicherung; } } from 2003-04-01 { @@ -53,7 +67,7 @@ public function beitrag(): Float per month { return arbeitslosenversicherungBeitragArbeitnehmer() per month; } - return gesetzlicheRentenversicherungBetragBruttolohn() per month * beitragssatz[arbeitslosenversicherung]; + return gesetzlicheRentenversicherungBetragBruttolohn() per month * beitragssatzArbeitslosenversicherung; } } @@ -65,7 +79,7 @@ public function beitragArbeitgeber(): Float per month { if (geringfügigBeschäftigt()) { return 0; } else { - return gesetzlicheRentenversicherungBetragBruttolohn() per month * beitragssatz[arbeitslosenversicherung]; + return gesetzlicheRentenversicherungBetragBruttolohn() per month * beitragssatzArbeitslosenversicherung; } } @@ -75,10 +89,10 @@ public function beitragArbeitgeber(): Float per month { } if (inGleitzone()) { - return arbeitslosenversicherungBeitragMidijobArbeitgeber() per month; + return midijobArbeitnehmer() per month; } - return arbeitslosenversicherungRegulärBeschäftigt() per month; + return gesetzlicheRentenversicherungBetragBruttolohn() per month * beitragssatzArbeitslosenversicherung } } @@ -88,7 +102,7 @@ public function beitragArbeitgeber(): Float per month { */ private function midijobSummeArbeitgeberArbeitnehmer(): Float per month { from 2003-04-01 { - return midijobBemessungsentgeld() per month * 2 * beitragssatz[arbeitslosenversicherung]; + return midijobBemessungsentgeld() per month * 2 * beitragssatzArbeitslosenversicherung; } } @@ -98,7 +112,7 @@ private function midijobSummeArbeitgeberArbeitnehmer(): Float per month { */ private function midijobArbeitgeberAnteilBruttolohn(bruttolohn per month): Float per month { from 2003-04-01 to 2022-09-30 { - bruttolohn per month * beitragssatz[arbeitslosenversicherung]; + bruttolohn per month * beitragssatzArbeitslosenversicherung; } } @@ -121,7 +135,6 @@ private function midijobArbeitnehmer(): Float per month { } from 2022-10-01 { - # TODO - return _midijob_beitragspfl_einnahme_arbeitn_m * beitragssatz[arbeitslosenversicherung]; + return midijobBeitragspflichtigeEinnahmeArbeitnehmer() * beitragssatzArbeitslosenversicherung; } } diff --git "a/src/resources/builtins/sozialversicherungsBeitr\303\244ge/einkommensgrenzen.ttsl" "b/src/resources/builtins/sozialversicherungsBeitr\303\244ge/einkommensgrenzen.ttsl" index 07d5ff67..269570ee 100644 --- "a/src/resources/builtins/sozialversicherungsBeitr\303\244ge/einkommensgrenzen.ttsl" +++ "b/src/resources/builtins/sozialversicherungsBeitr\303\244ge/einkommensgrenzen.ttsl" @@ -34,7 +34,7 @@ public function minijobGrenze(): Float per month { * Marginal employed pay no social insurance contributions. * Legal reference: § 8 Abs. 1 Satz 1 and 2 SGB IV */ -public function geringügigBeschäftigt(bruttolohn per month): Boolean { +public function geringfügigBeschäftigt(bruttolohn per month): Boolean { return bruttolohn per month <= minijobGrenze() } @@ -145,7 +145,7 @@ public function midijobFaktorF(): Float { * social insurance contribution. * Legal reference: § 163 Abs. 10 SGB VI */ -public function midijobBemessungsgeld(bruttolohn per month): Float per month { +public function midijobBemessungsentgeld(bruttolohn per month): Float per month { from 2003-04-01 { # Now use the factor to calculate the overall bemessungsentgelt var minijob_anteil = midijobFaktorF() * minijobGrenze() From af1ebf9a7379d6c91dd20e0c822d90e6abed0089 Mon Sep 17 00:00:00 2001 From: alex-senger Date: Fri, 20 Sep 2024 20:08:03 +0200 Subject: [PATCH 179/183] param linking --- .../sozialversicherungsbeitrag.ttsl | 2 +- .../beitragsbemessungsgrenzen.ttsl" | 26 +++++++++---------- 2 files changed, 14 insertions(+), 14 deletions(-) diff --git a/src/resources/builtins/parameters/sozialversicherungsbeitrag.ttsl b/src/resources/builtins/parameters/sozialversicherungsbeitrag.ttsl index aad4d7a1..197794a6 100644 --- a/src/resources/builtins/parameters/sozialversicherungsbeitrag.ttsl +++ b/src/resources/builtins/parameters/sozialversicherungsbeitrag.ttsl @@ -664,7 +664,7 @@ public constant beitragsbemessungsgrenze: Dict> { * Monatliche Bezugsgröße * §18 SGB IV and https:#de.wikipedia.org/wiki/Bezugsgr%C3%B6%C3%9Fe */ -public constant monatlicheBezugsgroeße: Dict { +public constant monatlicheBezugsgröße: Dict { from 1984-01-01 = { "west": 1396 }; diff --git "a/src/resources/builtins/sozialversicherungsBeitr\303\244ge/beitragsbemessungsgrenzen.ttsl" "b/src/resources/builtins/sozialversicherungsBeitr\303\244ge/beitragsbemessungsgrenzen.ttsl" index 36cdc5a8..5cc3ed6d 100644 --- "a/src/resources/builtins/sozialversicherungsBeitr\303\244ge/beitragsbemessungsgrenzen.ttsl" +++ "b/src/resources/builtins/sozialversicherungsBeitr\303\244ge/beitragsbemessungsgrenzen.ttsl" @@ -1,29 +1,29 @@ package beitragsbemessungsgrenzen -from sozialversicherungsbeitrag import beitragsbemessungsgrenze, monatlicheBezugsgrße +from sozialversicherungsbeitrag import beitragsbemessungsgrenze, monatlicheBezugsgröße -public function gesetzlicheRentenversicherung(): Float per month { - params = beitragsbemessungsgrenze[ges_rentenv]; +public function gesetzlicheRentenversicherung(wohnort_ost: Boolean): Float per month { + params = beitragsbemessungsgrenze["ges_rentenv"]; if wohnort_ost() { - return params[ost]; + return params["ost"]; } else { - return params[west]; + return params["west"]; } } -public function gesetzlicheKrankenversicherung(): Float per month { - params = beitragsbemessungsgrenze[ges_krankenv]; +public function gesetzlicheKrankenversicherung(wohnort_ost: Boolean): Float per month { + params = beitragsbemessungsgrenze["ges_krankenv"]; if wohnort_ost() { - return params[ost]; + return params["ost"]; } else { - return params[west]; + return params["west"]; } } -public function gesetzlicheKrankenversicherungBezugsgrße(): Float per month { +public function gesetzlicheKrankenversicherungBezugsgrße(wohnort_ost: Boolean): Float per month { if wohnort_ost() { - return monatlicheBezugsgrße[ost]; + return monatlicheBezugsgröße["ost"]; } else { - return monatlicheBezugsgrße[west]; + return monatlicheBezugsgröße["west"]; } -} \ No newline at end of file +} From 1f2455ea41227a372485dbaa1bb5053f3723a2bc Mon Sep 17 00:00:00 2001 From: alex-senger Date: Fri, 20 Sep 2024 20:09:52 +0200 Subject: [PATCH 180/183] wohnort_ost brackets --- .../beitragsbemessungsgrenzen.ttsl" | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git "a/src/resources/builtins/sozialversicherungsBeitr\303\244ge/beitragsbemessungsgrenzen.ttsl" "b/src/resources/builtins/sozialversicherungsBeitr\303\244ge/beitragsbemessungsgrenzen.ttsl" index 5cc3ed6d..f0db2910 100644 --- "a/src/resources/builtins/sozialversicherungsBeitr\303\244ge/beitragsbemessungsgrenzen.ttsl" +++ "b/src/resources/builtins/sozialversicherungsBeitr\303\244ge/beitragsbemessungsgrenzen.ttsl" @@ -4,7 +4,7 @@ from sozialversicherungsbeitrag import beitragsbemessungsgrenze, monatlicheBezug public function gesetzlicheRentenversicherung(wohnort_ost: Boolean): Float per month { params = beitragsbemessungsgrenze["ges_rentenv"]; - if wohnort_ost() { + if wohnort_ost { return params["ost"]; } else { return params["west"]; @@ -13,7 +13,7 @@ public function gesetzlicheRentenversicherung(wohnort_ost: Boolean): Float per m public function gesetzlicheKrankenversicherung(wohnort_ost: Boolean): Float per month { params = beitragsbemessungsgrenze["ges_krankenv"]; - if wohnort_ost() { + if wohnort_ost { return params["ost"]; } else { return params["west"]; @@ -21,7 +21,7 @@ public function gesetzlicheKrankenversicherung(wohnort_ost: Boolean): Float per } public function gesetzlicheKrankenversicherungBezugsgrße(wohnort_ost: Boolean): Float per month { - if wohnort_ost() { + if wohnort_ost { return monatlicheBezugsgröße["ost"]; } else { return monatlicheBezugsgröße["west"]; From f9fe0cac6175a95862e9eebf3df882b945d8b6f9 Mon Sep 17 00:00:00 2001 From: alex-senger Date: Fri, 20 Sep 2024 20:33:42 +0200 Subject: [PATCH 181/183] method linking --- .../sozialversicherungsbeitrag.ttsl | 6 +- .../einkommensgrenzen.ttsl" | 130 ++++++++++-------- 2 files changed, 74 insertions(+), 62 deletions(-) diff --git a/src/resources/builtins/parameters/sozialversicherungsbeitrag.ttsl b/src/resources/builtins/parameters/sozialversicherungsbeitrag.ttsl index 197794a6..57a49e28 100644 --- a/src/resources/builtins/parameters/sozialversicherungsbeitrag.ttsl +++ b/src/resources/builtins/parameters/sozialversicherungsbeitrag.ttsl @@ -883,7 +883,7 @@ public constant mindestanteilBezugsgroeßeBeitragspflichtigeEinnahmeSelbst: Floa * Gleitzone (Midijob Grenze) und Minijob Grenze (bis 1999 unterschiedliche Grenzen) * Reference: Midijob § 20 (2) SGB IV, Minijob § 8 (1) Nr. 1 SGB IV */ -public constant geringfuegigeEinkommensgrenzenMonatlich { +public constant geringfügigeEinkommensgrenzenMonatlich { Dict> { from 1984-01-01 = { "minijob": { @@ -1051,7 +1051,7 @@ public constant geringfuegigeEinkommensgrenzenMonatlich { * multipliziert wird. * Reference: §8 (1a) SGB IV */ -public constant geringfuegigeEinkommensfaktor: Int { +public constant geringfügigeEinkommensfaktor: Int { from 2022-10-01 = 130; } @@ -1071,7 +1071,7 @@ public constant geringfuegigeEinkommensdivisor: Int { * Rentenversicherung (§ 168 I Nr. 1b SGB VI), Pauschalierte Lohnsteuer (§40a II * EStG) */ -public constant pauschalabgabenGeringfuegigeBeschaeftigung: Dict { +public constant pauschalabgabenGeringfügigeBeschäftigung: Dict { from 1984-01-01 = { "ges_krankenv": 0, "ges_rentenv": 0, diff --git "a/src/resources/builtins/sozialversicherungsBeitr\303\244ge/einkommensgrenzen.ttsl" "b/src/resources/builtins/sozialversicherungsBeitr\303\244ge/einkommensgrenzen.ttsl" index 269570ee..d0a6d43d 100644 --- "a/src/resources/builtins/sozialversicherungsBeitr\303\244ge/einkommensgrenzen.ttsl" +++ "b/src/resources/builtins/sozialversicherungsBeitr\303\244ge/einkommensgrenzen.ttsl" @@ -1,32 +1,42 @@ package einkomensgrenzen -from sozialversicherungsbeitrag import geringfügigeEinkommensgrenzenMonatlich, mindestlohn, geringfügigeEinkommensfaktor, geringfügigeEinkommensdivisor, beitragssatz +from sozialversicherungsbeitrag import geringfügigeEinkommensgrenzenMonatlich +from sozialversicherungsbeitrag import mindestlohn +from sozialversicherungsbeitrag import geringfügigeEinkommensfaktor +from sozialversicherungsbeitrag import geringfügigeEinkommensdivisor +from sozialversicherungsbeitrag import pauschalabgabenGeringfügigeBeschäftigung + +from sozialversicherungsbeitrag import gesetzlicheRentenversicherung as beitragssatzGesetzlicheRentenversicherung +from sozialversicherungsbeitrag import arbeitslosenversicherung as beitragssatzArbeitslosenversicherung +from sozialversicherungsbeitrag import gesetzlicheKrankenversicherung as beitragssatzGesetzlicheKrankenversicherung +from sozialversicherungsbeitrag import gesetzlichePflegeversicherung as beitragssatzGesetzlichePflegeversicherung + +from gesetzlicheKrankenversicherung import beitragssatzJahresanfang as gesetzlicheKrankenversicherungBeitragssatzJahresanfang +from gesetzlicheKrankenversicherung import beitragssatzArbeitgeberJahresanfang as gesetzlicheKrankenversicherungBeitragssatzArbeitgeberJahresanfang /** * Select the income threshold depending on place of living. */ -public function minijobGrenze(): Float per month { +public function minijobGrenze(wohnort_ost: Boolean): Float per month { to 1999-12-31 { - var west = geringfügigeEinkommensgrenzenMonatlich[minijob][west] - var ost = geringfügigeEinkommensgrenzenMonatlich[minijob][ost] - if wohnort_ost() { - return ost + if wohnort_ost { + return geringfügigeEinkommensgrenzenMonatlich["minijob"]["ost"]; } else { - return west + return geringfügigeEinkommensgrenzenMonatlich["minijob"]["west"]; } - } + }; from 2000-01-01 to 2022-09-30 { - return geringfügigeEinkommensgrenzenMonatlich[minijob] - } + return geringfügigeEinkommensgrenzenMonatlich["minijob"]; + }; /** * Obtains marginal job threshold since 10/2022. Since then, it is calculated from * the statutory minimum wage. */ from 2022-10-01 { - return mindestlohn * geringfügigeEinkommensfaktor / geringfügigeEinkommensdivisor - } + return mindestlohn * geringfügigeEinkommensfaktor / geringfügigeEinkommensdivisor; + }; } /** @@ -35,7 +45,7 @@ public function minijobGrenze(): Float per month { * Legal reference: § 8 Abs. 1 Satz 1 and 2 SGB IV */ public function geringfügigBeschäftigt(bruttolohn per month): Boolean { - return bruttolohn per month <= minijobGrenze() + return bruttolohn per month <= minijobGrenze(); } /** @@ -46,8 +56,8 @@ public function geringfügigBeschäftigt(bruttolohn per month): Boolean { */ public function inGleitzone(bruttolohn per month): Boolean { from 2003-04-01 { - return (bruttolohn per month <= geringfügigeEinkommensgrenzenMonatlich[midijob]) and (not geringügigBeschäftigt(bruttolohn per month)); - } + return (bruttolohn per month <= geringfügigeEinkommensgrenzenMonatlich["midijob"]) and (not geringfügigBeschäftigt(bruttolohn per month)); + }; } public function midijobFaktorF(): Float { @@ -59,11 +69,11 @@ public function midijobFaktorF(): Float { # First calculate the factor F from the formula in § 163 (10) SGB VI # Therefore sum the contributions which are the same for employee and employer var allg_sozialv_beitr = ( - beitragssatz[gesetzlicheRentenversicherung] - + beitragssatz[arbeitslosenversicherung] + beitragssatzGesetzlicheRentenversicherung + + beitragssatzArbeitslosenversicherung ); - allg_sozialv_beitr = allg_sozialv_beitr + beitragssatz[ges_pflegev]; + allg_sozialv_beitr = allg_sozialv_beitr + beitragssatzGesetzlichePflegeversicherung; # Then calculate specific shares var an_anteil = allg_sozialv_beitr + gesetzlicheKrankenversicherungBeitragssatzJahresanfang(); @@ -71,14 +81,14 @@ public function midijobFaktorF(): Float { # Sum over the shares which are specific for midijobs. var pausch_mini = ( - pauschalabgabenGeringfügigeBeschäftigung[ges_krankenv] - + pauschalabgabenGeringfügigeBeschäftigung[ges_rentenv] - + pauschalabgabenGeringfügigeBeschäftigung[st] + pauschalabgabenGeringfügigeBeschäftigung["ges_krankenv"] + + pauschalabgabenGeringfügigeBeschäftigung["ges_rentenv"] + + pauschalabgabenGeringfügigeBeschäftigung["st"] ); # Now calculate final factor - return pausch_mini / (an_anteil + ag_anteil) - } + return pausch_mini / (an_anteil + ag_anteil); + }; /** * Midijob Faktor F between 2005 and September 2025. @@ -88,11 +98,11 @@ public function midijobFaktorF(): Float { # First calculate the factor F from the formula in § 163 (10) SGB VI # Therefore sum the contributions which are the same for employee and employer var allg_sozialv_beitr = ( - beitragssatz[gesetzlicheRentenversicherung] - + beitragssatz[arbeitslosenversicherung] + beitragssatzGesetzlicheRentenversicherung + + beitragssatzArbeitslosenversicherung ); - allg_sozialv_beitr += beitragssatz[gesetzlichePflegeversicherung][standard] + allg_sozialv_beitr = allg_sozialv_beitr + beitragssatzGesetzlichePflegeversicherung["standard"]; # Then calculate specific shares var an_anteil = allg_sozialv_beitr + gesetzlicheKrankenversicherungBeitragssatzJahresanfang(); @@ -100,14 +110,14 @@ public function midijobFaktorF(): Float { # Sum over the shares which are specific for midijobs. var pausch_mini = ( - pauschalabgabenGeringfügigeBeschäftigung[ges_krankenv] - + pauschalabgabenGeringfügigeBeschäftigung[ges_rentenv] - + pauschalabgabenGeringfügigeBeschäftigung[st] + pauschalabgabenGeringfügigeBeschäftigung["ges_krankenv"] + + pauschalabgabenGeringfügigeBeschäftigung["ges_rentenv"] + + pauschalabgabenGeringfügigeBeschäftigung["st"] ); # Now calculate final factor - return pausch_mini / (an_anteil + ag_anteil) - } + return pausch_mini / (an_anteil + ag_anteil); + }; from 2022-10-01 { # Calculate the Gesamtsozialversicherungsbeitragssatz by summing social @@ -116,9 +126,9 @@ public function midijobFaktorF(): Float { # First calculate the factor F from the formula in § 163 (10) SGB VI # Therefore sum the contributions which are the same for employee and employer var allg_sozialv_beitr = ( - beitragssatz[gesetzlicheRentenversicherung] - + beitragssatz[gesetzlichePflegeversicherung][standard] - + beitragssatz[arbeitslosenversicherung] + beitragssatzGesetzlicheRentenversicherung + + beitragssatzGesetzlichePflegeversicherung["standard"] + + beitragssatzArbeitslosenversicherung ); # Then calculate specific shares @@ -129,13 +139,13 @@ public function midijobFaktorF(): Float { # New formula only inludes the lump-sum contributions to health care # and pension insurance var pausch_mini = ( - pauschalabgabenGeringfügigeBeschäftigung[ges_krankenv] - pauschalabgabenGeringfügigeBeschäftigung[ges_rentenv] - ) + pauschalabgabenGeringfügigeBeschäftigung["ges_krankenv"] + + pauschalabgabenGeringfügigeBeschäftigung["ges_rentenv"] + ); # Now calculate final factor f - return pausch_mini / (an_anteil + ag_anteil) - } + return pausch_mini / (an_anteil + ag_anteil); + }; } /** @@ -148,25 +158,25 @@ public function midijobFaktorF(): Float { public function midijobBemessungsentgeld(bruttolohn per month): Float per month { from 2003-04-01 { # Now use the factor to calculate the overall bemessungsentgelt - var minijob_anteil = midijobFaktorF() * minijobGrenze() - var lohn_über_mini = bruttolohn per month - minijobGrenze() + var minijob_anteil = midijobFaktorF() * minijobGrenze(); + var lohn_über_mini = bruttolohn per month - minijobGrenze(); var gewichtete_midijob_rate = ( - geringfügigeEinkommensgrenzenMonatlich[midijob] + geringfügigeEinkommensgrenzenMonatlich["midijob"] / ( - geringfügigeEinkommensgrenzenMonatlich[midijob] + geringfügigeEinkommensgrenzenMonatlich["midijob"] - minijobGrenze() ) ) - ( minijobGrenze() / ( - geringfügigeEinkommensgrenzenMonatlich[midijob] + geringfügigeEinkommensgrenzenMonatlich["midijob"] - minijobGrenze() ) * midijobFaktorF() - ) + ); - return minijob_anteil + lohn_über_mini * gewichtete_midijob_rate - } + return minijob_anteil + lohn_über_mini * gewichtete_midijob_rate; + }; /** * Total income subject to social insurance contributions for employers a and @@ -177,16 +187,17 @@ public function midijobBemessungsentgeld(bruttolohn per month): Float per month * Legal reference: Changes in § 20 SGB IV from 01.10.2022 */ from 2022-10-01 { - var midijob_grenze = geringfügigeEinkommensgrenzenMonatlich[midijob] + var midijob_grenze = geringfügigeEinkommensgrenzenMonatlich["midijob"]; + var minijob_grenze = minijobGrenze(); - var quotient1 = (midijob_grenze) / (midijob_grenze - minijobGrenze()) - var quotient2 = (minijobGrenze()) / (midijob_grenze - minijobGrenze()) - var einkommen_diff = bruttolohn per month - minijobGrenze() + var quotient1 = (midijob_grenze) / (midijob_grenze - minijob_grenze); + var quotient2 = (minijob_grenze) / (midijob_grenze - minijob_grenze); + var einkommen_diff = bruttolohn per month - minijob_grenze; - var faktor1 = midijobFaktorF * minijobGrenze() - var faktor2 = (quotient1 - quotient2 * midijobFaktorF) * einkommen_diff - return faktor1 + faktor2 - } + var faktor1 = midijobFaktorF() * minijob_grenze; + var faktor2 = (quotient1 - quotient2 * midijobFaktorF()) * einkommen_diff; + return faktor1 + faktor2; + }; } /** @@ -197,10 +208,11 @@ public function midijobBemessungsentgeld(bruttolohn per month): Float per month * Legal reference: Changes in § 20 SGB IV from 01.10.2022 */ private function midijobBeitragspflichtigeEinnahmeArbeitnehmer(bruttolohn per month): Float per month { - var midijob_grenze = geringfügigeEinkommensgrenzenMonatlich[midijob] + var midijob_grenze = geringfügigeEinkommensgrenzenMonatlich["midijob"] + var minijob_grenze = minijobGrenze() - var quotient = midijob_grenze / (midijob_grenze - minijobGrenze()) - var einkommen_diff = bruttolohn per month - minijobGrenze() + var quotient = midijob_grenze / (midijob_grenze - minijob_grenze) + var einkommen_diff = bruttolohn per month - minijob_grenze return quotient * einkommen_diff } @@ -224,6 +236,6 @@ public function regulärBeschäftigt(bruttolohn per month): Boolean { * regular employed. */ from 2003-04-01 { - return bruttolohn per month >= geringfügigeEinkommensgrenzenMonatlich[midijob] + return bruttolohn per month >= geringfügigeEinkommensgrenzenMonatlich["midijob"] } } From c5be6b525b7d7a48bbc76c7f2b49c83dee1714c3 Mon Sep 17 00:00:00 2001 From: alex-senger Date: Mon, 23 Sep 2024 19:33:41 +0200 Subject: [PATCH 182/183] fix methods gesetzliche Krankenversicherung --- .../beitragsbemessungsgrenzen.ttsl" | 2 +- .../gesetzlichekrankenversicherung.ttsl" | 119 +++++++++++------- 2 files changed, 74 insertions(+), 47 deletions(-) diff --git "a/src/resources/builtins/sozialversicherungsBeitr\303\244ge/beitragsbemessungsgrenzen.ttsl" "b/src/resources/builtins/sozialversicherungsBeitr\303\244ge/beitragsbemessungsgrenzen.ttsl" index f0db2910..124b13fb 100644 --- "a/src/resources/builtins/sozialversicherungsBeitr\303\244ge/beitragsbemessungsgrenzen.ttsl" +++ "b/src/resources/builtins/sozialversicherungsBeitr\303\244ge/beitragsbemessungsgrenzen.ttsl" @@ -20,7 +20,7 @@ public function gesetzlicheKrankenversicherung(wohnort_ost: Boolean): Float per } } -public function gesetzlicheKrankenversicherungBezugsgrße(wohnort_ost: Boolean): Float per month { +public function gesetzlicheKrankenversicherungBezugsgröße(wohnort_ost: Boolean): Float per month { if wohnort_ost { return monatlicheBezugsgröße["ost"]; } else { diff --git "a/src/resources/builtins/sozialversicherungsBeitr\303\244ge/gesetzlichekrankenversicherung.ttsl" "b/src/resources/builtins/sozialversicherungsBeitr\303\244ge/gesetzlichekrankenversicherung.ttsl" index e319763d..c4f73a80 100644 --- "a/src/resources/builtins/sozialversicherungsBeitr\303\244ge/gesetzlichekrankenversicherung.ttsl" +++ "b/src/resources/builtins/sozialversicherungsBeitr\303\244ge/gesetzlichekrankenversicherung.ttsl" @@ -1,6 +1,17 @@ package gesetzlicheKrankenversicherung -from sozialversicherungsBeitragsParameter import pauschalabgabenGeringfügigeBeschäftigung, beitragssatz, mindestanteilBezugsgrßeBeitragspflichtigeEinnahmeSelbst +from sozialversicherungsbeitrag import pauschalabgabenGeringfügigeBeschäftigung +from sozialversicherungsbeitrag import gesetzlicheKrankenversicherung as beitragssatzGesetzlicheKrankenversicherung +from sozialversicherungsbeitrag import mindestanteilBezugsgrößeBeitragspflichtigeEinnahmeSelbst + +from beitragsbemessungsgrenzen import gesetzlicheKrankenversicherung as gesetzlicheKrankenversicherungBeitragsbemessungsgrenze +from beitragsbemessungsgrenzen import gesetzlicheKrankenversicherungBezugsgröße + +from einkommensgrenzen import inGleitzone +from einkommensgrenzen import geringfügigBeschäftigt +from einkommensgrenzen import midijobBemessungsentgeld +from einkommensgrenzen import midijobBeitragspflichtigeEinnahmeArbeitnehmer + from math import min, max /** @@ -47,7 +58,7 @@ public function beitragArbeitgeber( } else if geringfügigBeschäftigt { return bruttolohn * pauschalabgabenGeringfügigeBeschäftigung["ges_krankenv"]; } else { - return bruttolohnMonatlich() * beitragssatzArbeitgeber(); + return bruttolohn() per month * beitragssatzArbeitgeber(); } } from 2003-04-01 { @@ -55,10 +66,10 @@ public function beitragArbeitgeber( return 0.0; } else if geringfügigBeschäftigt { return bruttolohn * pauschalabgabenGeringfügigeBeschäftigung["ges_krankenv"]; - } else if inGleitzone { + } else if inGleitzone() { return beitragMidijobArbeitgeber(); } else { - return bruttolohnMonatlich() * beitragssatzArbeitgeber(); + return bruttolohn() per month * beitragssatzArbeitgeber(); } } } @@ -68,10 +79,10 @@ public function beitragArbeitgeber( */ public function zusatzbeitragssatz(): Float per year { to 2014-12-31 { - return beitragssatz["gesetzlicheKrankenversicherung"]["sonderbeitrag"]; + return beitragssatzGesetzlicheKrankenversicherung["sonderbeitrag"]; } from 2015-01-01 { - return beitragssatz["gesetzlicheKrankenversicherung"]["mean_zusatzbeitrag"]; + return beitragssatzGesetzlicheKrankenversicherung["mean_zusatzbeitrag"]; } } @@ -80,18 +91,18 @@ public function zusatzbeitragssatz(): Float per year { */ public function beitragssatz(): Float per month { to 2005-06-30 { - return beitragssatz["gesetzlicheKrankenversicherung"]["mean_allgemein"] / 2; + return beitragssatzGesetzlicheKrankenversicherung["mean_allgemein"] / 2; } from 2005-07-01 to 2008-12-31 { - var meanAllgemein = beitragssatz["gesetzlicheKrankenversicherung"]["mean_allgemein"]; + var meanAllgemein = beitragssatzGesetzlicheKrankenversicherung["mean_allgemein"]; return meanAllgemein / 2 + zusatzbeitragssatz(); } from 2009-01-01 to 2018-12-31 { - var allgemein = beitragssatz["gesetzlicheKrankenversicherung"]["allgemein"]; + var allgemein = beitragssatzGesetzlicheKrankenversicherung["allgemein"]; return allgemein / 2 + zusatzbeitragssatz(); } from 2019-01-01 { - var allgemeinerBeitragssatz = beitragssatz["gesetzlicheKrankenversicherung"]["allgemein"]; + var allgemeinerBeitragssatz = beitragssatzGesetzlicheKrankenversicherung["allgemein"]; return (allgemeinerBeitragssatz + zusatzbeitragssatz()) / 2; } } @@ -101,18 +112,18 @@ public function beitragssatz(): Float per month { */ public function beitragssatzJahresanfang(): Float per month { to 2005-06-30 { - return sozialversicherungsBeitragsParameter["beitr_satz_jahresanfang"]["gesetzlicheKrankenversicherung"]["mean_allgemein"] / 2; + return beitragssatzGesetzlicheKrankenversicherung["mean_allgemein"] / 2; } from 2005-07-01 to 2008-12-31 { - var meanAllgemein = sozialversicherungsBeitragsParameter["beitr_satz_jahresanfang"]["gesetzlicheKrankenversicherung"]["mean_allgemein"]; + var meanAllgemein = beitragssatzGesetzlicheKrankenversicherung["mean_allgemein"]; return meanAllgemein / 2 + zusatzbeitragssatz(); } from 2009-01-01 to 2018-12-31 { - var allgemein = sozialversicherungsBeitragsParameter["beitr_satz_jahresanfang"]["gesetzlicheKrankenversicherung"]["allgemein"]; + var allgemein = beitragssatzGesetzlicheKrankenversicherung["allgemein"]; return allgemein / 2 + zusatzbeitragssatz(); } from 2019-01-01 { - var allgemeinerBeitragssatz = sozialversicherungsBeitragsParameter["beitr_satz_jahresanfang"]["gesetzlicheKrankenversicherung"]["allgemein"]; + var allgemeinerBeitragssatz = beitragssatzGesetzlicheKrankenversicherung["allgemein"]; return (allgemeinerBeitragssatz() + zusatzbeitragssatz()) / 2; } } @@ -122,15 +133,15 @@ public function beitragssatzJahresanfang(): Float per month { */ public function beitragssatzArbeitgeber(): Float per month { to 2008-12-31 { - return beitragssatz["gesetzlicheKrankenversicherung"]["mean_allgemein"] / 2; + return beitragssatzGesetzlicheKrankenversicherung["mean_allgemein"] / 2; } from 2009-01-01 to 2018-12-31 { - return beitragssatz["gesetzlicheKrankenversicherung"]["allgemein"] / 2; + return beitragssatzGesetzlicheKrankenversicherung["allgemein"] / 2; } from 2019-01-01 { - var allgemeinerBeitragssatz = beitragssatz["gesetzlicheKrankenversicherung"]["allgemein"]; - var zusatzbeitragssatz = beitragssatz["gesetzlicheKrankenversicherung"]["mean_zusatzbeitrag"]; - return (allgemeinerBeitragssatz + zusatzbeitragssatz) / 2; + var allgemeinerBeitragssatz = beitragssatzGesetzlicheKrankenversicherung["allgemein"]; + var zusatzbeitragssatz = beitragssatzGesetzlicheKrankenversicherung["mean_zusatzbeitrag"]; + return (allgemeinerBeitragssatz + zusatzbeitragssatz()) / 2; } } @@ -139,14 +150,14 @@ public function beitragssatzArbeitgeber(): Float per month { */ public function beitragssatzArbeitgeberJahresanfang(): Float per month { to 2008-12-31 { - return sozialversicherungsBeitragsParameter["beitr_satz_jahresanfang"]["gesetzlicheKrankenversicherung"]["mean_allgemein"] / 2; + return beitragssatzGesetzlicheKrankenversicherung["mean_allgemein"] / 2; } from 2009-01-01 to 2018-12-31 { - return sozialversicherungsBeitragsParameter["beitr_satz_jahresanfang"]["gesetzlicheKrankenversicherung"]["allgemein"] / 2; + return beitragssatzGesetzlicheKrankenversicherung["allgemein"] / 2; } from 2019-01-01 { var allgemeinerBeitragssatz = sozialversicherungsBeitragsParameter["beitr_satz_jahresanfang"]["gesetzlicheKrankenversicherung"]["allgemein"]; - var zusatzbeitragssatz = beitragssatz["gesetzlicheKrankenversicherung"]["mean_zusatzbeitrag"]; + var zusatzbeitragssatz = beitragssatzGesetzlicheKrankenversicherung["mean_zusatzbeitrag"]; return (allgemeinerBeitragssatz + zusatzbeitragssatz) / 2; } } @@ -157,8 +168,8 @@ public function beitragssatzArbeitgeberJahresanfang(): Float per month { public function bruttolohnRegulärBeschäftigt( bruttolohn: Float ): Float per month { - if bruttolohn > beitragsbemessungsgrenze() { - return beitragsbemessungsgrenze(); + if bruttolohn > gesetzlicheKrankenversicherungBeitragsbemessungsgrenze() { + return gesetzlicheKrankenversicherungBeitragsbemessungsgrenze(); } else { return bruttolohn; } @@ -167,10 +178,8 @@ public function bruttolohnRegulärBeschäftigt( /** * Bruttolohn, der der gesetzlichen Krankenversicherung unterliegt. */ -public function bruttolohn( - regulärBeschäftigt: Boolean -): Float per month { - if regulärBeschäftigt { +public function bruttolohn(): Float per month { + if regulärBeschäftigt() { return bruttolohnRegulärBeschäftigt(); } else { return 0.0; @@ -192,11 +201,11 @@ public function bemessungsgrundlageSelbstständig( selbstständig: Boolean, inPrivaterKrankenversicherung: Boolean, ): Float per month { - if selbstständig and not inPrivaterKrankenversicherung { + if (selbstständig and not inPrivaterKrankenversicherung) { return min( - beitragsbemessungsgrenze(), + gesetzlicheKrankenversicherungBeitragsbemessungsgrenze(), max( - bezugsgrßeSelbstständig() * mindestanteilBezugsgrßeBeitragspflichtigeEinnahmeSelbst, + gesetzlicheKrankenversicherungBezugsgröße() * mindestanteilBezugsgrößeBeitragspflichtigeEinnahmeSelbst, einkommenSelbstständig ) ); @@ -205,23 +214,43 @@ public function bemessungsgrundlageSelbstständig( } } +/** + * Choose the amount of pension which is subject to health insurance contribution. + * TODO: Abhängigkeit zu Transfer Rente + */ +public function bemessungsgrundlageRente(): Float per month { + min(summeGesetzlicheRentePrivateRente, gesetzlicheKrankenversicherungBeitragsbemessungsgrenze) +} + /** * Beitrag für selbstständiges Einkommen. */ public function beitragSelbstständig(): Float per month { - var params = beitragssatz["gesetzlicheKrankenversicherung"]; - var ermßigterBeitrag = params["ermßigt"] if "ermßigt" in params else params["mean_allgemein"]; - var zusatzbeitrag = params["mean_zusatzbeitrag"] if "mean_zusatzbeitrag" in params else 0.0; - var beitragssatzSelbstständig = ermßigterBeitrag + zusatzbeitrag; - return beitragssatzSelbstständig * bemessungsgrundlageSelbstständig(); + var params = beitragssatzGesetzlicheKrankenversicherung; + if ("ermäßigt" in params) { + var ermäßigterBeitrag = params["ermäßigt"]; + } else { + var ermäßigterBeitrag = params["mean_allgemein"]; + } + + if ("zusatzbeitrag" in params) { + zusatzbeitrag = params["zusatzbeitrag"]; + } else { + zusatzbeitrag = 0.0; + } + + var beitragssatzSelbstständig = ermäßigterBeitrag + zusatzbeitrag; + return beitragssatzSelbstständig * gesetzlicheKrankenversicherungBeitragsbemessungsgrenze(); } /** * Bemessungsgrundlage für Renteneinkommen. */ -public function bemessungsgrundlageRente(): Float per month { - return min(summeGesetzlicheRentePrivateRente(), beitragsbemessungsgrenze()); -} + +# TODO: summeGesetzlicheRentePrivateRente Abhängigkeit zum Transfer Rente +# public function bemessungsgrundlageRente(): Float per month { +# return min(summeGesetzlicheRentePrivateRente(), beitragsbemessungsgrenze()); +# } /** * Beitrag für Renteneinkommen. @@ -235,7 +264,7 @@ public function beitragRente(): Float per month { */ public function beitragMidijobSummeArbeitnehmerArbeitgeber(): Float per month { from 2003-04-01 { - return (beitragssatz() + beitragssatzArbeitgeber()) * midijobBemessungsentgelt(); + return (beitragssatz() + beitragssatzArbeitgeber()) * midijobBemessungsentgeld(); } } @@ -245,13 +274,14 @@ public function beitragMidijobSummeArbeitnehmerArbeitgeber(): Float per month { public function beitragMidijobArbeitgeber( bruttolohn: Float ): Float per month { - from 2003-04-01 to 2022-09-30 { + from 2003-04-01 { if inGleitzone() { return beitragssatzArbeitgeber() * bruttolohn; } else { return 0.0; } } + from 2022-10-01 { if inGleitzone() { return beitragMidijobSummeArbeitnehmerArbeitgeber() - beitragMidijobArbeitnehmer(); @@ -268,11 +298,8 @@ public function beitragMidijobArbeitnehmer(): Float per month { from 2003-04-01 to 2022-09-30 { return beitragMidijobSummeArbeitnehmerArbeitgeber() - beitragMidijobArbeitgeber(); } + from 2022-10-01 { - if inGleitzone { - return beitragspflichtigesEinkommenArbeitnehmer() * beitragssatz(); - } else { - return 0.0; - } + return midijobBeitragspflichtigeEinnahmeArbeitnehmer() * beitragssatz(); } } From 9c562c1387c7d39c3ff1b97cc09048a7bc0fdcc3 Mon Sep 17 00:00:00 2001 From: alex-senger Date: Mon, 23 Sep 2024 20:15:23 +0200 Subject: [PATCH 183/183] fix methods gesetzliche Pflegeversicherung --- .../gesetzlichepflegeversicherung.ttsl" | 141 +++++++++++------- 1 file changed, 84 insertions(+), 57 deletions(-) diff --git "a/src/resources/builtins/sozialversicherungsBeitr\303\244ge/gesetzlichepflegeversicherung.ttsl" "b/src/resources/builtins/sozialversicherungsBeitr\303\244ge/gesetzlichepflegeversicherung.ttsl" index 2b49c39c..f765d6dd 100644 --- "a/src/resources/builtins/sozialversicherungsBeitr\303\244ge/gesetzlichepflegeversicherung.ttsl" +++ "b/src/resources/builtins/sozialversicherungsBeitr\303\244ge/gesetzlichepflegeversicherung.ttsl" @@ -1,6 +1,17 @@ package gesetzlichePflegeversicherung -from sozialversicherungsBeitragsParameter import beitragssatz, mindestalterBeitragszuschlagKinderlose +from sozialversicherungsbeitrag import beitragssatz +from sozialversicherungsbeitrag import mindestalterBeitragszuschlagKinderlose +from sozialversicherungsbeitrag import gesetzlichePflegeversicherung + +from einkommensgrenzen import inGleitzone +from einkommensgrenzen import geringfügigBeschäftigt +from einkommensgrenzen import midijobBemessungsentgeld +from einkommensgrenzen import midijobBeitragspflichtigeEinnahmeArbeitnehmer + +from gesetzlicheKrankenversicherung import bruttolohn as gesetzlicheKrankenversicherungBruttolohn +from gesetzlicheKrankenversicherung import bemessungsgrundlageSelbstständig +from gesetzlicheKrankenversicherung import bemessungsgrundlageRente /** * Zusätzlicher Beitrag für Kinderlose ab 2005. @@ -11,8 +22,12 @@ public function zusatzbeitragKinderlos( ): Boolean { from 2005-01-01 { var mindestalter = mindestalterBeitragszuschlagKinderlose; - return (not hatKinder) or alter >= mindestalter; - } + if (not hatKinder or alter >= mindestalter) { + return true; + } else { + return false; + } + }; } /** @@ -22,25 +37,27 @@ public function beitragssatz( anzEigeneKinderBis24: Int ): Float per year { from 1995-01-01 to 2004-12-31 { - return beitragssatz["ges_pflegev"]; - } + return gesetzlichePflegeversicherung; + }; + from 2005-01-01 to 2023-06-30 { - var out = beitragssatz["ges_pflegev"]["standard"]; - if zusatzbeitragKinderlos { - out += beitragssatz["ges_pflegev"]["zusatz_kinderlos"]; + var out = gesetzlichePflegeversicherung["standard"]; + if zusatzbeitragKinderlos() { + out = out + gesetzlichePflegeversicherung["zusatz_kinderlos"]; } return out; - } + }; + from 2023-07-01 { - var out = beitragssatz["ges_pflegev"]["standard"]; - if zusatzbeitragKinderlos { - out += beitragssatz["ges_pflegev"]["zusatz_kinderlos"]; + var out = gesetzlichePflegeversicherung["standard"]; + if zusatzbeitragKinderlos() { + out = out + gesetzlichePflegeversicherung["zusatz_kinderlos"]; } if anzEigeneKinderBis24 >= 2 { - out -= beitragssatz["ges_pflegev"]["abschlag_kinder"] * min(anzEigeneKinderBis24 - 1, 4); + out = out - gesetzlichePflegeversicherung["abschlag_kinder"] * min(anzEigeneKinderBis24 - 1, 4); } return out; - } + }; } /** @@ -53,30 +70,31 @@ public function beitrag( if selbstständig { return beitragSelbstständig() + beitragRente(); } - if geringfügigBeschäftigt { + if geringfügigBeschäftigt() { return 0 + beitragRente(); } return beitragRegulärBeschäftigt() + beitragRente(); - } + }; + from 2003-04-01 { if selbstständig { return beitragSelbstständig() + beitragRente(); } - if geringfügigBeschäftigt { + if geringfügigBeschäftigt() { return 0 + beitragRente(); } - if inGleitzone { + if inGleitzone() { return beitragMidijobArbeitnehmer() + beitragRente(); } return beitragRegulärBeschäftigt() + beitragRente(); - } + }; } /** * Beitrag für regulär Beschäftigte in der gesetzlichen Pflegeversicherung. */ public function beitragRegulärBeschäftigt(): Float per month { - var beitrRegulärBeschäftigt = gesetzlicheKrankenversicherung.bruttolohn() * beitragssatz(); + var beitrRegulärBeschäftigt = gesetzlicheKrankenversicherungBruttolohn() * beitragssatz(); return beitrRegulärBeschäftigt; } @@ -87,21 +105,22 @@ public function beitragArbeitgeber( selbstständig: Boolean ): Float per month { to 2003-03-31 { - if selbstständig or geringfügigBeschäftigt { + if selbstständig or geringfügigBeschäftigt() { return 0.0; } else { - return bruttolohn * beitragssatz["ges_pflegev"]; + return gesetzlicheKrankenversicherungBruttolohn() * gesetzlichePflegeversicherung; } - } + }; + from 2003-04-01 { - if selbstständig or geringfügigBeschäftigt { + if selbstständig or geringfügigBeschäftigt() { return 0.0; - } else if inGleitzone { - return beitragMidijobArbeitgeber; + } else if inGleitzone() { + return beitragMidijobArbeitgeber(); } else { - return bruttolohn * beitragssatz["ges_pflegev"]["standard"]; + return bruttogesetzlicheKrankenversicherungBruttolohn() * gesetzlichePflegeversicherung["standard"]; } - } + }; } /** @@ -109,11 +128,12 @@ public function beitragArbeitgeber( */ public function beitragSelbstständig(): Float per month { from 1995-01-01 to 2004-12-31 { - return bemessungsgrundlageSelbstständig() * beitragssatz["ges_pflegev"] * 2; - } + return bemessungsgrundlageSelbstständig() * gesetzlichePflegeversicherung * 2; + }; + from 2005-01-01 { - return bemessungsgrundlageSelbstständig() * (beitragssatz() + beitragssatz["ges_pflegev"]["standard"]); - } + return bemessungsgrundlageSelbstständig() * (beitragssatz() + gesetzlichePflegeversicherung["standard"]); + }; } /** @@ -122,15 +142,17 @@ public function beitragSelbstständig(): Float per month { public function beitragRente(): Float per month { to 2004-03-31 { return bemessungsgrundlageRente() * beitragssatz(); - } + }; + from 2004-04-01 to 2004-12-31 { return bemessungsgrundlageRente() * (beitragssatz() * 2); - } + }; + from 2005-01-01 { return bemessungsgrundlageRente() * ( - beitragssatz() + beitragssatz["ges_pflegev"]["standard"] + beitragssatz() + gesetzlichePflegeversicherung["standard"] ); - } + }; } /** @@ -138,11 +160,12 @@ public function beitragRente(): Float per month { */ public function beitragMidijobSummeArbeitnehmerArbeitgeber(): Float per month { from 2003-04-01 to 2004-12-31 { - return midijobBemessungsentgelt() * (beitragssatz() + beitragssatz["ges_pflegev"]); - } + return midijobBemessungsentgeld() * (beitragssatz() + gesetzlichePflegeversicherung); + }; + from 2005-01-01 { - return midijobBemessungsentgelt() * (beitragssatz() + beitragssatz["ges_pflegev"]["standard"]); - } + return midijobBemessungsentgeld() * (beitragssatz() + gesetzlichePflegeversicherung["standard"]); + }; } /** @@ -152,14 +175,16 @@ public function beitragMidijobArbeitgeber( bruttolohn: Float ): Float per month { to 2004-12-31 { - return bruttolohn * beitragssatz["ges_pflegev"]; - } + return bruttolohn * gesetzlichePflegeversicherung; + }; + from 2005-01-01 to 2022-09-30 { - return bruttolohn * beitragssatz["ges_pflegev"]["standard"]; - } + return bruttolohn * gesetzlichePflegeversicherung["standard"]; + }; + from 2022-10-01 { return beitragMidijobSummeArbeitnehmerArbeitgeber() - beitragMidijobArbeitnehmer(); - } + }; } /** @@ -168,25 +193,27 @@ public function beitragMidijobArbeitgeber( public function beitragMidijobArbeitnehmer( anzEigeneKinderBis24: Int ): Float per month { - from 2003-04-01 to 2022-09-30 { + to 2022-09-30 { return beitragMidijobSummeArbeitnehmerArbeitgeber() - beitragMidijobArbeitgeber(); - } + }; + from 2022-10-01 to 2023-06-30 { - var anBeitragMidijob = beitragspflichtigesEinkommenArbeitnehmer() * beitragssatz["ges_pflegev"]["standard"]; - if gesPflegevZusatzKinderlos { - anBeitragMidijob += midijobBemessungsentgelt() * beitragssatz["ges_pflegev"]["zusatz_kinderlos"]; + var anBeitragMidijob = midijobBeitragspflichtigeEinnahmeArbeitnehmer() * gesetzlichePflegeversicherung["standard"]; + if zusatzbeitragKinderlos() { + anBeitragMidijob = anBeitragMidijob + midijobBemessungsentgeld() * gesetzlichePflegeversicherung["zusatz_kinderlos"]; } return anBeitragMidijob; - } + }; + from 2023-07-01 { - var pflegevRate = beitragssatz["ges_pflegev"]["standard"]; + var pflegevRate = gesetzlichePflegeversicherung["standard"]; if anzEigeneKinderBis24 >= 2 { - pflegevRate -= beitragssatz["ges_pflegev"]["abschlag_kinder"] * min(anzEigeneKinderBis24 - 1, 4); + pflegevRate = pflegevRate - gesetzlichePflegeversicherung["abschlag_kinder"] * min(anzEigeneKinderBis24 - 1, 4); } - var anBeitragMidijob = beitragspflichtigesEinkommenArbeitnehmer() * pflegevRate; - if gesPflegevZusatzKinderlos { - anBeitragMidijob += midijobBemessungsentgelt() * beitragssatz["ges_pflegev"]["zusatz_kinderlos"]; + var anBeitragMidijob = midijobBeitragspflichtigeEinnahmeArbeitnehmer() * pflegevRate; + if zusatzbeitragKinderlos() { + anBeitragMidijob = anBeitragMidijob + midijobBemessungsentgeld() * gesetzlichePflegeversicherung["zusatz_kinderlos"]; } return anBeitragMidijob; - } + }; } \ No newline at end of file