diff --git a/extensions/default_unparsing_config.json b/extensions/default_unparsing_config.json index 9eabec288..744e693d2 100644 --- a/extensions/default_unparsing_config.json +++ b/extensions/default_unparsing_config.json @@ -608,6 +608,25 @@ ] } }, + "DeclarativePart": { + "node": { + "kind": "recurse_field", + "field": "f_decls" + }, + "fields": { + "f_decls": { + "kind": "ifEmpty", + "then": "recurse", + "else": { + "kind": "group", + "document": [ + "hardline", + "recurse" + ] + } + } + } + }, "DefiningNameList": { "sep": [ "recurse", @@ -1226,7 +1245,6 @@ { "kind": "indent", "contents": [ - "hardline", { "kind": "recurse_field", "field": "f_public_part" @@ -1256,7 +1274,6 @@ { "kind": "indent", "contents": [ - "hardline", "recurse" ] }, @@ -1315,6 +1332,44 @@ ] } }, + "HandledStmts": { + "node": { + "kind": "group", + "break": true, + "document": [ + { + "kind": "indent", + "contents": [ + "hardline", + { + "kind": "recurse_field", + "field": "f_stmts" + } + ] + }, + { + "kind": "recurse_field", + "field": "f_exceptions" + } + ] + }, + "fields": { + "f_exceptions": [ + "hardline", + { + "kind": "text", + "text": "exception" + }, + { + "kind": "indent", + "contents": [ + "hardline", + "recurse" + ] + } + ] + } + }, "IfStmt": { "node": { "kind": "group", @@ -1712,7 +1767,6 @@ { "kind": "indent", "contents": [ - "hardline", { "kind": "recurse_field", "field": "f_decls" @@ -1747,13 +1801,7 @@ ] }, "f_stmts": [ - { - "kind": "indent", - "contents": [ - "hardline", - "recurse" - ] - }, + "recurse", "hardline" ] } @@ -1786,7 +1834,6 @@ { "kind": "indent", "contents": [ - "hardline", { "kind": "recurse_field", "field": "f_public_part" @@ -1826,7 +1873,6 @@ { "kind": "indent", "contents": [ - "hardline", "recurse" ] }, @@ -2258,14 +2304,8 @@ "text": "begin" }, { - "kind": "indent", - "contents": [ - "hardlineWithoutBreakParent", - { - "kind": "recurse_field", - "field": "f_stmts" - } - ] + "kind": "recurse_field", + "field": "f_stmts" }, "hardlineWithoutBreakParent", { @@ -2291,7 +2331,6 @@ { "kind": "indent", "contents": [ - "hardlineWithoutBreakParent", "recurse" ] }, diff --git a/testsuite/tests/unparsing/aspect_spec/multiple_long_aspects/doc-baseline.json b/testsuite/tests/unparsing/aspect_spec/multiple_long_aspects/doc-baseline.json index af37593a0..f6b8495ef 100644 --- a/testsuite/tests/unparsing/aspect_spec/multiple_long_aspects/doc-baseline.json +++ b/testsuite/tests/unparsing/aspect_spec/multiple_long_aspects/doc-baseline.json @@ -1,5 +1,5 @@ { - "id": 32, + "id": 33, "kind": "list", "list": [ { @@ -172,52 +172,62 @@ } }, { - "id": 27, + "id": 28, "kind": "command", "command": { "command": "indent", "indentContents": { - "id": 26, - "kind": "list", - "list": [ - { - "id": 24, + "id": 27, + "kind": "command", + "command": { + "command": "group", + "id": 0, + "groupContents": { + "id": 26, "kind": "list", "list": [ { - "id": 22, - "kind": "command", - "command": { - "command": "line", - "literal": false, - "soft": false, - "hard": true - } + "id": 24, + "kind": "list", + "list": [ + { + "id": 22, + "kind": "command", + "command": { + "command": "line", + "literal": false, + "soft": false, + "hard": true + } + }, + { + "id": 23, + "kind": "command", + "command": { + "command": "breakParent" + } + } + ] }, { - "id": 23, - "kind": "command", - "command": { - "command": "breakParent" - } + "id": 25, + "kind": "text", + "text": "type Corge;" } ] }, - { - "id": 25, - "kind": "text", - "text": "type Corge;" - } - ] + "break": true, + "expandedStates": null + } } } }, { - "id": 30, + "id": 31, "kind": "list", "list": [ { - "id": 28, + "id": 29, "kind": "command", "command": { "command": "line", @@ -227,7 +237,7 @@ } }, { - "id": 29, + "id": 30, "kind": "command", "command": { "command": "breakParent" @@ -236,7 +246,7 @@ ] }, { - "id": 31, + "id": 32, "kind": "text", "text": "end Foo;" } diff --git a/testsuite/tests/unparsing/aspect_spec/multiple_short_aspects/doc-baseline.json b/testsuite/tests/unparsing/aspect_spec/multiple_short_aspects/doc-baseline.json index 666516723..7f27e03be 100644 --- a/testsuite/tests/unparsing/aspect_spec/multiple_short_aspects/doc-baseline.json +++ b/testsuite/tests/unparsing/aspect_spec/multiple_short_aspects/doc-baseline.json @@ -1,5 +1,5 @@ { - "id": 30, + "id": 31, "kind": "list", "list": [ { @@ -157,52 +157,62 @@ } }, { - "id": 25, + "id": 26, "kind": "command", "command": { "command": "indent", "indentContents": { - "id": 24, - "kind": "list", - "list": [ - { - "id": 22, + "id": 25, + "kind": "command", + "command": { + "command": "group", + "id": 0, + "groupContents": { + "id": 24, "kind": "list", "list": [ { - "id": 20, - "kind": "command", - "command": { - "command": "line", - "literal": false, - "soft": false, - "hard": true - } + "id": 22, + "kind": "list", + "list": [ + { + "id": 20, + "kind": "command", + "command": { + "command": "line", + "literal": false, + "soft": false, + "hard": true + } + }, + { + "id": 21, + "kind": "command", + "command": { + "command": "breakParent" + } + } + ] }, { - "id": 21, - "kind": "command", - "command": { - "command": "breakParent" - } + "id": 23, + "kind": "text", + "text": "type Qux;" } ] }, - { - "id": 23, - "kind": "text", - "text": "type Qux;" - } - ] + "break": true, + "expandedStates": null + } } } }, { - "id": 28, + "id": 29, "kind": "list", "list": [ { - "id": 26, + "id": 27, "kind": "command", "command": { "command": "line", @@ -212,7 +222,7 @@ } }, { - "id": 27, + "id": 28, "kind": "command", "command": { "command": "breakParent" @@ -221,7 +231,7 @@ ] }, { - "id": 29, + "id": 30, "kind": "text", "text": "end Foo;" } diff --git a/testsuite/tests/unparsing/generic_package_decl/empty_formal_part/doc-baseline.json b/testsuite/tests/unparsing/generic_package_decl/empty_formal_part/doc-baseline.json index 925a73d4a..f8a31585c 100644 --- a/testsuite/tests/unparsing/generic_package_decl/empty_formal_part/doc-baseline.json +++ b/testsuite/tests/unparsing/generic_package_decl/empty_formal_part/doc-baseline.json @@ -1,11 +1,11 @@ { - "id": 81, + "id": 82, "kind": "command", "command": { "command": "group", "id": 0, "groupContents": { - "id": 80, + "id": 81, "kind": "list", "list": [ { @@ -205,351 +205,361 @@ } }, { - "id": 67, + "id": 68, "kind": "command", "command": { "command": "indent", "indentContents": { - "id": 66, - "kind": "list", - "list": [ - { - "id": 27, + "id": 67, + "kind": "command", + "command": { + "command": "group", + "id": 0, + "groupContents": { + "id": 66, "kind": "list", "list": [ { - "id": 25, - "kind": "command", - "command": { - "command": "line", - "literal": false, - "soft": false, - "hard": true - } - }, - { - "id": 26, - "kind": "command", - "command": { - "command": "breakParent" - } - } - ] - }, - { - "id": 65, - "kind": "command", - "command": { - "command": "group", - "id": 0, - "groupContents": { - "id": 64, + "id": 27, "kind": "list", "list": [ { - "id": 62, + "id": 25, "kind": "command", "command": { - "command": "group", - "id": 0, - "groupContents": { - "id": 61, - "kind": "list", - "list": [ - { - "id": 60, - "kind": "command", - "command": { - "command": "align", - "alignData": { - "kind": "width", - "n": 2 - }, - "alignContents": { - "id": 59, + "command": "line", + "literal": false, + "soft": false, + "hard": true + } + }, + { + "id": 26, + "kind": "command", + "command": { + "command": "breakParent" + } + } + ] + }, + { + "id": 65, + "kind": "command", + "command": { + "command": "group", + "id": 0, + "groupContents": { + "id": 64, + "kind": "list", + "list": [ + { + "id": 62, + "kind": "command", + "command": { + "command": "group", + "id": 0, + "groupContents": { + "id": 61, + "kind": "list", + "list": [ + { + "id": 60, "kind": "command", "command": { - "command": "group", - "id": 0, - "groupContents": { - "id": 58, - "kind": "list", - "list": [ - { - "id": 28, - "kind": "text", - "text": "procedure Garply" - }, - { - "id": 29, - "kind": "command", - "command": { - "command": "line", - "literal": false, - "soft": false, - "hard": false - } - }, - { - "id": 57, - "kind": "command", - "command": { - "command": "group", - "id": 0, - "groupContents": { - "id": 56, - "kind": "list", - "list": [ - { - "id": 55, - "kind": "command", - "command": { - "command": "group", - "id": 0, - "groupContents": { - "id": 54, + "command": "align", + "alignData": { + "kind": "width", + "n": 2 + }, + "alignContents": { + "id": 59, + "kind": "command", + "command": { + "command": "group", + "id": 0, + "groupContents": { + "id": 58, + "kind": "list", + "list": [ + { + "id": 28, + "kind": "text", + "text": "procedure Garply" + }, + { + "id": 29, + "kind": "command", + "command": { + "command": "line", + "literal": false, + "soft": false, + "hard": false + } + }, + { + "id": 57, + "kind": "command", + "command": { + "command": "group", + "id": 0, + "groupContents": { + "id": 56, + "kind": "list", + "list": [ + { + "id": 55, "kind": "command", "command": { - "command": "align", - "alignData": { - "kind": "width", - "n": 1 - }, - "alignContents": { - "id": 53, - "kind": "list", - "list": [ - { - "id": 30, - "kind": "text", - "text": "(" + "command": "group", + "id": 0, + "groupContents": { + "id": 54, + "kind": "command", + "command": { + "command": "align", + "alignData": { + "kind": "width", + "n": 1 }, - { - "id": 51, - "kind": "command", - "command": { - "command": "align", - "alignData": { - "kind": "innerRoot" + "alignContents": { + "id": 53, + "kind": "list", + "list": [ + { + "id": 30, + "kind": "text", + "text": "(" }, - "alignContents": { - "id": 50, + { + "id": 51, "kind": "command", "command": { - "command": "group", - "id": 0, - "groupContents": { - "id": 49, - "kind": "list", - "list": [ - { - "id": 41, - "kind": "command", - "command": { - "command": "group", - "id": 1, - "groupContents": { - "id": 40, - "kind": "list", - "list": [ - { - "id": 32, - "kind": "command", - "command": { - "command": "group", - "id": 0, - "groupContents": { - "id": 31, - "kind": "text", - "text": "G" + "command": "align", + "alignData": { + "kind": "innerRoot" + }, + "alignContents": { + "id": 50, + "kind": "command", + "command": { + "command": "group", + "id": 0, + "groupContents": { + "id": 49, + "kind": "list", + "list": [ + { + "id": 41, + "kind": "command", + "command": { + "command": "group", + "id": 1, + "groupContents": { + "id": 40, + "kind": "list", + "list": [ + { + "id": 32, + "kind": "command", + "command": { + "command": "group", + "id": 0, + "groupContents": { + "id": 31, + "kind": "text", + "text": "G" + }, + "break": false, + "expandedStates": null + } }, - "break": false, - "expandedStates": null - } - }, - { - "id": 33, - "kind": "text", - "text": " :" - }, - { - "id": 39, - "kind": "command", - "command": { - "command": "align", - "alignData": { - "kind": "width", - "n": 2 + { + "id": 33, + "kind": "text", + "text": " :" }, - "alignContents": { - "id": 38, - "kind": "list", - "list": [ - { - "id": 34, - "kind": "command", - "command": { - "command": "line", - "literal": false, - "soft": false, - "hard": false - } + { + "id": 39, + "kind": "command", + "command": { + "command": "align", + "alignData": { + "kind": "width", + "n": 2 }, - { - "id": 37, - "kind": "command", - "command": { - "command": "group", - "id": 0, - "groupContents": { - "id": 36, - "kind": "list", - "list": [ - { - "id": 35, - "kind": "text", - "text": "Foo" - } - ] + "alignContents": { + "id": 38, + "kind": "list", + "list": [ + { + "id": 34, + "kind": "command", + "command": { + "command": "line", + "literal": false, + "soft": false, + "hard": false + } }, - "break": false, - "expandedStates": null - } + { + "id": 37, + "kind": "command", + "command": { + "command": "group", + "id": 0, + "groupContents": { + "id": 36, + "kind": "list", + "list": [ + { + "id": 35, + "kind": "text", + "text": "Foo" + } + ] + }, + "break": false, + "expandedStates": null + } + } + ] } - ] + } } - } - } - ] + ] + }, + "break": false, + "expandedStates": null + } }, - "break": false, - "expandedStates": null - } - }, - { - "id": 48, - "kind": "command", - "command": { - "command": "ifBreak", - "ifBreakGroupId": 1, - "breakContents": { - "id": 44, + { + "id": 48, "kind": "command", "command": { - "command": "align", - "alignData": { - "kind": "width", - "n": 4 - }, - "alignContents": { - "id": 43, + "command": "ifBreak", + "ifBreakGroupId": 1, + "breakContents": { + "id": 44, "kind": "command", "command": { - "command": "group", - "id": 0, - "groupContents": { - "id": 42, - "kind": "list", - "list": [ - ] + "command": "align", + "alignData": { + "kind": "width", + "n": 4 }, - "break": false, - "expandedStates": null + "alignContents": { + "id": 43, + "kind": "command", + "command": { + "command": "group", + "id": 0, + "groupContents": { + "id": 42, + "kind": "list", + "list": [ + ] + }, + "break": false, + "expandedStates": null + } + } } - } - } - }, - "flatContents": { - "id": 47, - "kind": "command", - "command": { - "command": "align", - "alignData": { - "kind": "width", - "n": 2 }, - "alignContents": { - "id": 46, + "flatContents": { + "id": 47, "kind": "command", "command": { - "command": "group", - "id": 0, - "groupContents": { - "id": 45, - "kind": "list", - "list": [ - ] + "command": "align", + "alignData": { + "kind": "width", + "n": 2 }, - "break": false, - "expandedStates": null + "alignContents": { + "id": 46, + "kind": "command", + "command": { + "command": "group", + "id": 0, + "groupContents": { + "id": 45, + "kind": "list", + "list": [ + ] + }, + "break": false, + "expandedStates": null + } + } } } } } - } - } - ] - }, - "break": false, - "expandedStates": null + ] + }, + "break": false, + "expandedStates": null + } + } } + }, + { + "id": 52, + "kind": "text", + "text": ")" } - } - }, - { - "id": 52, - "kind": "text", - "text": ")" + ] } - ] - } + } + }, + "break": false, + "expandedStates": null } - }, - "break": false, - "expandedStates": null - } - } - ] - }, - "break": false, - "expandedStates": null - } - } - ] - }, - "break": false, - "expandedStates": null + } + ] + }, + "break": false, + "expandedStates": null + } + } + ] + }, + "break": false, + "expandedStates": null + } + } } } - } - } - ] + ] + }, + "break": false, + "expandedStates": null + } }, - "break": false, - "expandedStates": null - } + { + "id": 63, + "kind": "text", + "text": ";" + } + ] }, - { - "id": 63, - "kind": "text", - "text": ";" - } - ] - }, - "break": false, - "expandedStates": null - } - } - ] + "break": false, + "expandedStates": null + } + } + ] + }, + "break": true, + "expandedStates": null + } } } }, { - "id": 70, + "id": 71, "kind": "list", "list": [ { - "id": 68, + "id": 69, "kind": "command", "command": { "command": "line", @@ -559,7 +569,7 @@ } }, { - "id": 69, + "id": 70, "kind": "command", "command": { "command": "breakParent" @@ -568,12 +578,12 @@ ] }, { - "id": 71, + "id": 72, "kind": "text", "text": "end" }, { - "id": 78, + "id": 79, "kind": "command", "command": { "command": "align", @@ -581,7 +591,7 @@ "kind": "innerRoot" }, "alignContents": { - "id": 77, + "id": 78, "kind": "command", "command": { "command": "align", @@ -590,22 +600,22 @@ "n": 2 }, "alignContents": { - "id": 76, + "id": 77, "kind": "command", "command": { "command": "group", "id": 0, "groupContents": { - "id": 75, + "id": 76, "kind": "list", "list": [ { - "id": 72, + "id": 73, "kind": "text", "text": " GNATfuzz" }, { - "id": 73, + "id": 74, "kind": "command", "command": { "command": "line", @@ -615,7 +625,7 @@ } }, { - "id": 74, + "id": 75, "kind": "text", "text": ".AFL_Seed_Data_Chunks" } @@ -630,7 +640,7 @@ } }, { - "id": 79, + "id": 80, "kind": "text", "text": ";" } diff --git a/testsuite/tests/unparsing/generic_package_decl/non_empty_formal_part/doc-baseline.json b/testsuite/tests/unparsing/generic_package_decl/non_empty_formal_part/doc-baseline.json index 5f93b957e..c883003c6 100644 --- a/testsuite/tests/unparsing/generic_package_decl/non_empty_formal_part/doc-baseline.json +++ b/testsuite/tests/unparsing/generic_package_decl/non_empty_formal_part/doc-baseline.json @@ -1,11 +1,11 @@ { - "id": 178, + "id": 179, "kind": "command", "command": { "command": "group", "id": 0, "groupContents": { - "id": 177, + "id": 178, "kind": "list", "list": [ { @@ -990,351 +990,361 @@ } }, { - "id": 164, + "id": 165, "kind": "command", "command": { "command": "indent", "indentContents": { - "id": 163, - "kind": "list", - "list": [ - { - "id": 124, + "id": 164, + "kind": "command", + "command": { + "command": "group", + "id": 0, + "groupContents": { + "id": 163, "kind": "list", "list": [ { - "id": 122, - "kind": "command", - "command": { - "command": "line", - "literal": false, - "soft": false, - "hard": true - } - }, - { - "id": 123, - "kind": "command", - "command": { - "command": "breakParent" - } - } - ] - }, - { - "id": 162, - "kind": "command", - "command": { - "command": "group", - "id": 0, - "groupContents": { - "id": 161, + "id": 124, "kind": "list", "list": [ { - "id": 159, + "id": 122, "kind": "command", "command": { - "command": "group", - "id": 0, - "groupContents": { - "id": 158, - "kind": "list", - "list": [ - { - "id": 157, - "kind": "command", - "command": { - "command": "align", - "alignData": { - "kind": "width", - "n": 2 - }, - "alignContents": { - "id": 156, + "command": "line", + "literal": false, + "soft": false, + "hard": true + } + }, + { + "id": 123, + "kind": "command", + "command": { + "command": "breakParent" + } + } + ] + }, + { + "id": 162, + "kind": "command", + "command": { + "command": "group", + "id": 0, + "groupContents": { + "id": 161, + "kind": "list", + "list": [ + { + "id": 159, + "kind": "command", + "command": { + "command": "group", + "id": 0, + "groupContents": { + "id": 158, + "kind": "list", + "list": [ + { + "id": 157, "kind": "command", "command": { - "command": "group", - "id": 0, - "groupContents": { - "id": 155, - "kind": "list", - "list": [ - { - "id": 125, - "kind": "text", - "text": "procedure Garply" - }, - { - "id": 126, - "kind": "command", - "command": { - "command": "line", - "literal": false, - "soft": false, - "hard": false - } - }, - { - "id": 154, - "kind": "command", - "command": { - "command": "group", - "id": 0, - "groupContents": { - "id": 153, - "kind": "list", - "list": [ - { - "id": 152, - "kind": "command", - "command": { - "command": "group", - "id": 0, - "groupContents": { - "id": 151, + "command": "align", + "alignData": { + "kind": "width", + "n": 2 + }, + "alignContents": { + "id": 156, + "kind": "command", + "command": { + "command": "group", + "id": 0, + "groupContents": { + "id": 155, + "kind": "list", + "list": [ + { + "id": 125, + "kind": "text", + "text": "procedure Garply" + }, + { + "id": 126, + "kind": "command", + "command": { + "command": "line", + "literal": false, + "soft": false, + "hard": false + } + }, + { + "id": 154, + "kind": "command", + "command": { + "command": "group", + "id": 0, + "groupContents": { + "id": 153, + "kind": "list", + "list": [ + { + "id": 152, "kind": "command", "command": { - "command": "align", - "alignData": { - "kind": "width", - "n": 1 - }, - "alignContents": { - "id": 150, - "kind": "list", - "list": [ - { - "id": 127, - "kind": "text", - "text": "(" + "command": "group", + "id": 0, + "groupContents": { + "id": 151, + "kind": "command", + "command": { + "command": "align", + "alignData": { + "kind": "width", + "n": 1 }, - { - "id": 148, - "kind": "command", - "command": { - "command": "align", - "alignData": { - "kind": "innerRoot" + "alignContents": { + "id": 150, + "kind": "list", + "list": [ + { + "id": 127, + "kind": "text", + "text": "(" }, - "alignContents": { - "id": 147, + { + "id": 148, "kind": "command", "command": { - "command": "group", - "id": 0, - "groupContents": { - "id": 146, - "kind": "list", - "list": [ - { - "id": 138, - "kind": "command", - "command": { - "command": "group", - "id": 1, - "groupContents": { - "id": 137, - "kind": "list", - "list": [ - { - "id": 129, - "kind": "command", - "command": { - "command": "group", - "id": 0, - "groupContents": { - "id": 128, - "kind": "text", - "text": "G" + "command": "align", + "alignData": { + "kind": "innerRoot" + }, + "alignContents": { + "id": 147, + "kind": "command", + "command": { + "command": "group", + "id": 0, + "groupContents": { + "id": 146, + "kind": "list", + "list": [ + { + "id": 138, + "kind": "command", + "command": { + "command": "group", + "id": 1, + "groupContents": { + "id": 137, + "kind": "list", + "list": [ + { + "id": 129, + "kind": "command", + "command": { + "command": "group", + "id": 0, + "groupContents": { + "id": 128, + "kind": "text", + "text": "G" + }, + "break": false, + "expandedStates": null + } }, - "break": false, - "expandedStates": null - } - }, - { - "id": 130, - "kind": "text", - "text": " :" - }, - { - "id": 136, - "kind": "command", - "command": { - "command": "align", - "alignData": { - "kind": "width", - "n": 2 + { + "id": 130, + "kind": "text", + "text": " :" }, - "alignContents": { - "id": 135, - "kind": "list", - "list": [ - { - "id": 131, - "kind": "command", - "command": { - "command": "line", - "literal": false, - "soft": false, - "hard": false - } + { + "id": 136, + "kind": "command", + "command": { + "command": "align", + "alignData": { + "kind": "width", + "n": 2 }, - { - "id": 134, - "kind": "command", - "command": { - "command": "group", - "id": 0, - "groupContents": { - "id": 133, - "kind": "list", - "list": [ - { - "id": 132, - "kind": "text", - "text": "Foo" - } - ] + "alignContents": { + "id": 135, + "kind": "list", + "list": [ + { + "id": 131, + "kind": "command", + "command": { + "command": "line", + "literal": false, + "soft": false, + "hard": false + } }, - "break": false, - "expandedStates": null - } + { + "id": 134, + "kind": "command", + "command": { + "command": "group", + "id": 0, + "groupContents": { + "id": 133, + "kind": "list", + "list": [ + { + "id": 132, + "kind": "text", + "text": "Foo" + } + ] + }, + "break": false, + "expandedStates": null + } + } + ] } - ] + } } - } - } - ] + ] + }, + "break": false, + "expandedStates": null + } }, - "break": false, - "expandedStates": null - } - }, - { - "id": 145, - "kind": "command", - "command": { - "command": "ifBreak", - "ifBreakGroupId": 1, - "breakContents": { - "id": 141, + { + "id": 145, "kind": "command", "command": { - "command": "align", - "alignData": { - "kind": "width", - "n": 4 - }, - "alignContents": { - "id": 140, + "command": "ifBreak", + "ifBreakGroupId": 1, + "breakContents": { + "id": 141, "kind": "command", "command": { - "command": "group", - "id": 0, - "groupContents": { - "id": 139, - "kind": "list", - "list": [ - ] + "command": "align", + "alignData": { + "kind": "width", + "n": 4 }, - "break": false, - "expandedStates": null + "alignContents": { + "id": 140, + "kind": "command", + "command": { + "command": "group", + "id": 0, + "groupContents": { + "id": 139, + "kind": "list", + "list": [ + ] + }, + "break": false, + "expandedStates": null + } + } } - } - } - }, - "flatContents": { - "id": 144, - "kind": "command", - "command": { - "command": "align", - "alignData": { - "kind": "width", - "n": 2 }, - "alignContents": { - "id": 143, + "flatContents": { + "id": 144, "kind": "command", "command": { - "command": "group", - "id": 0, - "groupContents": { - "id": 142, - "kind": "list", - "list": [ - ] + "command": "align", + "alignData": { + "kind": "width", + "n": 2 }, - "break": false, - "expandedStates": null + "alignContents": { + "id": 143, + "kind": "command", + "command": { + "command": "group", + "id": 0, + "groupContents": { + "id": 142, + "kind": "list", + "list": [ + ] + }, + "break": false, + "expandedStates": null + } + } } } } } - } - } - ] - }, - "break": false, - "expandedStates": null + ] + }, + "break": false, + "expandedStates": null + } + } } + }, + { + "id": 149, + "kind": "text", + "text": ")" } - } - }, - { - "id": 149, - "kind": "text", - "text": ")" + ] } - ] - } + } + }, + "break": false, + "expandedStates": null } - }, - "break": false, - "expandedStates": null - } - } - ] - }, - "break": false, - "expandedStates": null - } - } - ] - }, - "break": false, - "expandedStates": null + } + ] + }, + "break": false, + "expandedStates": null + } + } + ] + }, + "break": false, + "expandedStates": null + } + } } } - } - } - ] + ] + }, + "break": false, + "expandedStates": null + } }, - "break": false, - "expandedStates": null - } + { + "id": 160, + "kind": "text", + "text": ";" + } + ] }, - { - "id": 160, - "kind": "text", - "text": ";" - } - ] - }, - "break": false, - "expandedStates": null - } - } - ] + "break": false, + "expandedStates": null + } + } + ] + }, + "break": true, + "expandedStates": null + } } } }, { - "id": 167, + "id": 168, "kind": "list", "list": [ { - "id": 165, + "id": 166, "kind": "command", "command": { "command": "line", @@ -1344,7 +1354,7 @@ } }, { - "id": 166, + "id": 167, "kind": "command", "command": { "command": "breakParent" @@ -1353,12 +1363,12 @@ ] }, { - "id": 168, + "id": 169, "kind": "text", "text": "end" }, { - "id": 175, + "id": 176, "kind": "command", "command": { "command": "align", @@ -1366,7 +1376,7 @@ "kind": "innerRoot" }, "alignContents": { - "id": 174, + "id": 175, "kind": "command", "command": { "command": "align", @@ -1375,22 +1385,22 @@ "n": 2 }, "alignContents": { - "id": 173, + "id": 174, "kind": "command", "command": { "command": "group", "id": 0, "groupContents": { - "id": 172, + "id": 173, "kind": "list", "list": [ { - "id": 169, + "id": 170, "kind": "text", "text": " GNATfuzz" }, { - "id": 170, + "id": 171, "kind": "command", "command": { "command": "line", @@ -1400,7 +1410,7 @@ } }, { - "id": 171, + "id": 172, "kind": "text", "text": ".AFL_Seed_Data_Chunks" } @@ -1415,7 +1425,7 @@ } }, { - "id": 176, + "id": 177, "kind": "text", "text": ";" } diff --git a/testsuite/tests/unparsing/package_body/short_names_w_stmts/doc-baseline.json b/testsuite/tests/unparsing/package_body/short_names_w_stmts/doc-baseline.json index 31bc2ddab..d7822eb53 100644 --- a/testsuite/tests/unparsing/package_body/short_names_w_stmts/doc-baseline.json +++ b/testsuite/tests/unparsing/package_body/short_names_w_stmts/doc-baseline.json @@ -1,5 +1,5 @@ { - "id": 38, + "id": 41, "kind": "list", "list": [ { @@ -142,52 +142,62 @@ } }, { - "id": 23, + "id": 24, "kind": "command", "command": { "command": "indent", "indentContents": { - "id": 22, - "kind": "list", - "list": [ - { - "id": 20, + "id": 23, + "kind": "command", + "command": { + "command": "group", + "id": 0, + "groupContents": { + "id": 22, "kind": "list", "list": [ { - "id": 18, - "kind": "command", - "command": { - "command": "line", - "literal": false, - "soft": false, - "hard": true - } + "id": 20, + "kind": "list", + "list": [ + { + "id": 18, + "kind": "command", + "command": { + "command": "line", + "literal": false, + "soft": false, + "hard": true + } + }, + { + "id": 19, + "kind": "command", + "command": { + "command": "breakParent" + } + } + ] }, { - "id": 19, - "kind": "command", - "command": { - "command": "breakParent" - } + "id": 21, + "kind": "text", + "text": "type Baz;" } ] }, - { - "id": 21, - "kind": "text", - "text": "type Baz;" - } - ] + "break": true, + "expandedStates": null + } } } }, { - "id": 26, + "id": 27, "kind": "list", "list": [ { - "id": 24, + "id": 25, "kind": "command", "command": { "command": "line", @@ -197,7 +207,7 @@ } }, { - "id": 25, + "id": 26, "kind": "command", "command": { "command": "breakParent" @@ -206,57 +216,73 @@ ] }, { - "id": 27, + "id": 28, "kind": "text", "text": "begin" }, { - "id": 33, + "id": 36, "kind": "command", "command": { - "command": "indent", - "indentContents": { - "id": 32, + "command": "group", + "id": 0, + "groupContents": { + "id": 35, "kind": "list", "list": [ { - "id": 30, - "kind": "list", - "list": [ - { - "id": 28, - "kind": "command", - "command": { - "command": "line", - "literal": false, - "soft": false, - "hard": true - } - }, - { - "id": 29, - "kind": "command", - "command": { - "command": "breakParent" - } + "id": 34, + "kind": "command", + "command": { + "command": "indent", + "indentContents": { + "id": 33, + "kind": "list", + "list": [ + { + "id": 31, + "kind": "list", + "list": [ + { + "id": 29, + "kind": "command", + "command": { + "command": "line", + "literal": false, + "soft": false, + "hard": true + } + }, + { + "id": 30, + "kind": "command", + "command": { + "command": "breakParent" + } + } + ] + }, + { + "id": 32, + "kind": "text", + "text": "null;" + } + ] } - ] - }, - { - "id": 31, - "kind": "text", - "text": "null;" + } } ] - } + }, + "break": true, + "expandedStates": null } }, { - "id": 36, + "id": 39, "kind": "list", "list": [ { - "id": 34, + "id": 37, "kind": "command", "command": { "command": "line", @@ -266,7 +292,7 @@ } }, { - "id": 35, + "id": 38, "kind": "command", "command": { "command": "breakParent" @@ -275,7 +301,7 @@ ] }, { - "id": 37, + "id": 40, "kind": "text", "text": "end Foo;" } diff --git a/testsuite/tests/unparsing/package_body/short_names_wo_stmts/doc-baseline.json b/testsuite/tests/unparsing/package_body/short_names_wo_stmts/doc-baseline.json index d8d2a9dd0..643a77297 100644 --- a/testsuite/tests/unparsing/package_body/short_names_wo_stmts/doc-baseline.json +++ b/testsuite/tests/unparsing/package_body/short_names_wo_stmts/doc-baseline.json @@ -1,5 +1,5 @@ { - "id": 28, + "id": 29, "kind": "list", "list": [ { @@ -142,52 +142,62 @@ } }, { - "id": 23, + "id": 24, "kind": "command", "command": { "command": "indent", "indentContents": { - "id": 22, - "kind": "list", - "list": [ - { - "id": 20, + "id": 23, + "kind": "command", + "command": { + "command": "group", + "id": 0, + "groupContents": { + "id": 22, "kind": "list", "list": [ { - "id": 18, - "kind": "command", - "command": { - "command": "line", - "literal": false, - "soft": false, - "hard": true - } + "id": 20, + "kind": "list", + "list": [ + { + "id": 18, + "kind": "command", + "command": { + "command": "line", + "literal": false, + "soft": false, + "hard": true + } + }, + { + "id": 19, + "kind": "command", + "command": { + "command": "breakParent" + } + } + ] }, { - "id": 19, - "kind": "command", - "command": { - "command": "breakParent" - } + "id": 21, + "kind": "text", + "text": "type Baz;" } ] }, - { - "id": 21, - "kind": "text", - "text": "type Baz;" - } - ] + "break": true, + "expandedStates": null + } } } }, { - "id": 26, + "id": 27, "kind": "list", "list": [ { - "id": 24, + "id": 25, "kind": "command", "command": { "command": "line", @@ -197,7 +207,7 @@ } }, { - "id": 25, + "id": 26, "kind": "command", "command": { "command": "breakParent" @@ -206,7 +216,7 @@ ] }, { - "id": 27, + "id": 28, "kind": "text", "text": "end Foo;" } diff --git a/testsuite/tests/unparsing/package_decl/long_aspect/doc-baseline.json b/testsuite/tests/unparsing/package_decl/long_aspect/doc-baseline.json index 34ea363c6..f591edde3 100644 --- a/testsuite/tests/unparsing/package_decl/long_aspect/doc-baseline.json +++ b/testsuite/tests/unparsing/package_decl/long_aspect/doc-baseline.json @@ -1,5 +1,5 @@ { - "id": 38, + "id": 40, "kind": "list", "list": [ { @@ -142,52 +142,62 @@ } }, { - "id": 23, + "id": 24, "kind": "command", "command": { "command": "indent", "indentContents": { - "id": 22, - "kind": "list", - "list": [ - { - "id": 20, + "id": 23, + "kind": "command", + "command": { + "command": "group", + "id": 0, + "groupContents": { + "id": 22, "kind": "list", "list": [ { - "id": 18, - "kind": "command", - "command": { - "command": "line", - "literal": false, - "soft": false, - "hard": true - } + "id": 20, + "kind": "list", + "list": [ + { + "id": 18, + "kind": "command", + "command": { + "command": "line", + "literal": false, + "soft": false, + "hard": true + } + }, + { + "id": 19, + "kind": "command", + "command": { + "command": "breakParent" + } + } + ] }, { - "id": 19, - "kind": "command", - "command": { - "command": "breakParent" - } + "id": 21, + "kind": "text", + "text": "type Baz;" } ] }, - { - "id": 21, - "kind": "text", - "text": "type Baz;" - } - ] + "break": true, + "expandedStates": null + } } } }, { - "id": 26, + "id": 27, "kind": "list", "list": [ { - "id": 24, + "id": 25, "kind": "command", "command": { "command": "line", @@ -197,7 +207,7 @@ } }, { - "id": 25, + "id": 26, "kind": "command", "command": { "command": "breakParent" @@ -206,57 +216,67 @@ ] }, { - "id": 27, + "id": 28, "kind": "text", "text": "private" }, { - "id": 33, + "id": 35, "kind": "command", "command": { "command": "indent", "indentContents": { - "id": 32, - "kind": "list", - "list": [ - { - "id": 30, + "id": 34, + "kind": "command", + "command": { + "command": "group", + "id": 0, + "groupContents": { + "id": 33, "kind": "list", "list": [ { - "id": 28, - "kind": "command", - "command": { - "command": "line", - "literal": false, - "soft": false, - "hard": true - } + "id": 31, + "kind": "list", + "list": [ + { + "id": 29, + "kind": "command", + "command": { + "command": "line", + "literal": false, + "soft": false, + "hard": true + } + }, + { + "id": 30, + "kind": "command", + "command": { + "command": "breakParent" + } + } + ] }, { - "id": 29, - "kind": "command", - "command": { - "command": "breakParent" - } + "id": 32, + "kind": "text", + "text": "type Qux;" } ] }, - { - "id": 31, - "kind": "text", - "text": "type Qux;" - } - ] + "break": true, + "expandedStates": null + } } } }, { - "id": 36, + "id": 38, "kind": "list", "list": [ { - "id": 34, + "id": 36, "kind": "command", "command": { "command": "line", @@ -266,7 +286,7 @@ } }, { - "id": 35, + "id": 37, "kind": "command", "command": { "command": "breakParent" @@ -275,7 +295,7 @@ ] }, { - "id": 37, + "id": 39, "kind": "text", "text": "end Foo;" } diff --git a/testsuite/tests/unparsing/package_decl/long_name/doc-baseline.json b/testsuite/tests/unparsing/package_decl/long_name/doc-baseline.json index 844455c6a..1442f7425 100644 --- a/testsuite/tests/unparsing/package_decl/long_name/doc-baseline.json +++ b/testsuite/tests/unparsing/package_decl/long_name/doc-baseline.json @@ -1,5 +1,5 @@ { - "id": 38, + "id": 40, "kind": "list", "list": [ { @@ -142,52 +142,62 @@ } }, { - "id": 23, + "id": 24, "kind": "command", "command": { "command": "indent", "indentContents": { - "id": 22, - "kind": "list", - "list": [ - { - "id": 20, + "id": 23, + "kind": "command", + "command": { + "command": "group", + "id": 0, + "groupContents": { + "id": 22, "kind": "list", "list": [ { - "id": 18, - "kind": "command", - "command": { - "command": "line", - "literal": false, - "soft": false, - "hard": true - } + "id": 20, + "kind": "list", + "list": [ + { + "id": 18, + "kind": "command", + "command": { + "command": "line", + "literal": false, + "soft": false, + "hard": true + } + }, + { + "id": 19, + "kind": "command", + "command": { + "command": "breakParent" + } + } + ] }, { - "id": 19, - "kind": "command", - "command": { - "command": "breakParent" - } + "id": 21, + "kind": "text", + "text": "type Baz;" } ] }, - { - "id": 21, - "kind": "text", - "text": "type Baz;" - } - ] + "break": true, + "expandedStates": null + } } } }, { - "id": 26, + "id": 27, "kind": "list", "list": [ { - "id": 24, + "id": 25, "kind": "command", "command": { "command": "line", @@ -197,7 +207,7 @@ } }, { - "id": 25, + "id": 26, "kind": "command", "command": { "command": "breakParent" @@ -206,57 +216,67 @@ ] }, { - "id": 27, + "id": 28, "kind": "text", "text": "private" }, { - "id": 33, + "id": 35, "kind": "command", "command": { "command": "indent", "indentContents": { - "id": 32, - "kind": "list", - "list": [ - { - "id": 30, + "id": 34, + "kind": "command", + "command": { + "command": "group", + "id": 0, + "groupContents": { + "id": 33, "kind": "list", "list": [ { - "id": 28, - "kind": "command", - "command": { - "command": "line", - "literal": false, - "soft": false, - "hard": true - } + "id": 31, + "kind": "list", + "list": [ + { + "id": 29, + "kind": "command", + "command": { + "command": "line", + "literal": false, + "soft": false, + "hard": true + } + }, + { + "id": 30, + "kind": "command", + "command": { + "command": "breakParent" + } + } + ] }, { - "id": 29, - "kind": "command", - "command": { - "command": "breakParent" - } + "id": 32, + "kind": "text", + "text": "type Qux;" } ] }, - { - "id": 31, - "kind": "text", - "text": "type Qux;" - } - ] + "break": true, + "expandedStates": null + } } } }, { - "id": 36, + "id": 38, "kind": "list", "list": [ { - "id": 34, + "id": 36, "kind": "command", "command": { "command": "line", @@ -266,7 +286,7 @@ } }, { - "id": 35, + "id": 37, "kind": "command", "command": { "command": "breakParent" @@ -275,7 +295,7 @@ ] }, { - "id": 37, + "id": 39, "kind": "text", "text": "end Foo;" } diff --git a/testsuite/tests/unparsing/package_decl/long_name_and_aspect/doc-baseline.json b/testsuite/tests/unparsing/package_decl/long_name_and_aspect/doc-baseline.json index 6bbd42636..bdfcca9bb 100644 --- a/testsuite/tests/unparsing/package_decl/long_name_and_aspect/doc-baseline.json +++ b/testsuite/tests/unparsing/package_decl/long_name_and_aspect/doc-baseline.json @@ -1,5 +1,5 @@ { - "id": 38, + "id": 40, "kind": "list", "list": [ { @@ -142,52 +142,62 @@ } }, { - "id": 23, + "id": 24, "kind": "command", "command": { "command": "indent", "indentContents": { - "id": 22, - "kind": "list", - "list": [ - { - "id": 20, + "id": 23, + "kind": "command", + "command": { + "command": "group", + "id": 0, + "groupContents": { + "id": 22, "kind": "list", "list": [ { - "id": 18, - "kind": "command", - "command": { - "command": "line", - "literal": false, - "soft": false, - "hard": true - } + "id": 20, + "kind": "list", + "list": [ + { + "id": 18, + "kind": "command", + "command": { + "command": "line", + "literal": false, + "soft": false, + "hard": true + } + }, + { + "id": 19, + "kind": "command", + "command": { + "command": "breakParent" + } + } + ] }, { - "id": 19, - "kind": "command", - "command": { - "command": "breakParent" - } + "id": 21, + "kind": "text", + "text": "type Baz;" } ] }, - { - "id": 21, - "kind": "text", - "text": "type Baz;" - } - ] + "break": true, + "expandedStates": null + } } } }, { - "id": 26, + "id": 27, "kind": "list", "list": [ { - "id": 24, + "id": 25, "kind": "command", "command": { "command": "line", @@ -197,7 +207,7 @@ } }, { - "id": 25, + "id": 26, "kind": "command", "command": { "command": "breakParent" @@ -206,57 +216,67 @@ ] }, { - "id": 27, + "id": 28, "kind": "text", "text": "private" }, { - "id": 33, + "id": 35, "kind": "command", "command": { "command": "indent", "indentContents": { - "id": 32, - "kind": "list", - "list": [ - { - "id": 30, + "id": 34, + "kind": "command", + "command": { + "command": "group", + "id": 0, + "groupContents": { + "id": 33, "kind": "list", "list": [ { - "id": 28, - "kind": "command", - "command": { - "command": "line", - "literal": false, - "soft": false, - "hard": true - } + "id": 31, + "kind": "list", + "list": [ + { + "id": 29, + "kind": "command", + "command": { + "command": "line", + "literal": false, + "soft": false, + "hard": true + } + }, + { + "id": 30, + "kind": "command", + "command": { + "command": "breakParent" + } + } + ] }, { - "id": 29, - "kind": "command", - "command": { - "command": "breakParent" - } + "id": 32, + "kind": "text", + "text": "type Qux;" } ] }, - { - "id": 31, - "kind": "text", - "text": "type Qux;" - } - ] + "break": true, + "expandedStates": null + } } } }, { - "id": 36, + "id": 38, "kind": "list", "list": [ { - "id": 34, + "id": 36, "kind": "command", "command": { "command": "line", @@ -266,7 +286,7 @@ } }, { - "id": 35, + "id": 37, "kind": "command", "command": { "command": "breakParent" @@ -275,7 +295,7 @@ ] }, { - "id": 37, + "id": 39, "kind": "text", "text": "end Foo;" } diff --git a/testsuite/tests/unparsing/package_decl/no_end_name/doc-baseline.json b/testsuite/tests/unparsing/package_decl/no_end_name/doc-baseline.json index e7e5a1b15..d3cea6c20 100644 --- a/testsuite/tests/unparsing/package_decl/no_end_name/doc-baseline.json +++ b/testsuite/tests/unparsing/package_decl/no_end_name/doc-baseline.json @@ -1,5 +1,5 @@ { - "id": 38, + "id": 40, "kind": "list", "list": [ { @@ -142,52 +142,62 @@ } }, { - "id": 23, + "id": 24, "kind": "command", "command": { "command": "indent", "indentContents": { - "id": 22, - "kind": "list", - "list": [ - { - "id": 20, + "id": 23, + "kind": "command", + "command": { + "command": "group", + "id": 0, + "groupContents": { + "id": 22, "kind": "list", "list": [ { - "id": 18, - "kind": "command", - "command": { - "command": "line", - "literal": false, - "soft": false, - "hard": true - } + "id": 20, + "kind": "list", + "list": [ + { + "id": 18, + "kind": "command", + "command": { + "command": "line", + "literal": false, + "soft": false, + "hard": true + } + }, + { + "id": 19, + "kind": "command", + "command": { + "command": "breakParent" + } + } + ] }, { - "id": 19, - "kind": "command", - "command": { - "command": "breakParent" - } + "id": 21, + "kind": "text", + "text": "type Baz;" } ] }, - { - "id": 21, - "kind": "text", - "text": "type Baz;" - } - ] + "break": true, + "expandedStates": null + } } } }, { - "id": 26, + "id": 27, "kind": "list", "list": [ { - "id": 24, + "id": 25, "kind": "command", "command": { "command": "line", @@ -197,7 +207,7 @@ } }, { - "id": 25, + "id": 26, "kind": "command", "command": { "command": "breakParent" @@ -206,57 +216,67 @@ ] }, { - "id": 27, + "id": 28, "kind": "text", "text": "private" }, { - "id": 33, + "id": 35, "kind": "command", "command": { "command": "indent", "indentContents": { - "id": 32, - "kind": "list", - "list": [ - { - "id": 30, + "id": 34, + "kind": "command", + "command": { + "command": "group", + "id": 0, + "groupContents": { + "id": 33, "kind": "list", "list": [ { - "id": 28, - "kind": "command", - "command": { - "command": "line", - "literal": false, - "soft": false, - "hard": true - } + "id": 31, + "kind": "list", + "list": [ + { + "id": 29, + "kind": "command", + "command": { + "command": "line", + "literal": false, + "soft": false, + "hard": true + } + }, + { + "id": 30, + "kind": "command", + "command": { + "command": "breakParent" + } + } + ] }, { - "id": 29, - "kind": "command", - "command": { - "command": "breakParent" - } + "id": 32, + "kind": "text", + "text": "type Qux;" } ] }, - { - "id": 31, - "kind": "text", - "text": "type Qux;" - } - ] + "break": true, + "expandedStates": null + } } } }, { - "id": 36, + "id": 38, "kind": "list", "list": [ { - "id": 34, + "id": 36, "kind": "command", "command": { "command": "line", @@ -266,7 +286,7 @@ } }, { - "id": 35, + "id": 37, "kind": "command", "command": { "command": "breakParent" @@ -275,7 +295,7 @@ ] }, { - "id": 37, + "id": 39, "kind": "text", "text": "end;" } diff --git a/testsuite/tests/unparsing/package_decl/no_private_part/doc-baseline.json b/testsuite/tests/unparsing/package_decl/no_private_part/doc-baseline.json index 91dac9be5..fc1ec973d 100644 --- a/testsuite/tests/unparsing/package_decl/no_private_part/doc-baseline.json +++ b/testsuite/tests/unparsing/package_decl/no_private_part/doc-baseline.json @@ -1,5 +1,5 @@ { - "id": 28, + "id": 29, "kind": "list", "list": [ { @@ -142,52 +142,62 @@ } }, { - "id": 23, + "id": 24, "kind": "command", "command": { "command": "indent", "indentContents": { - "id": 22, - "kind": "list", - "list": [ - { - "id": 20, + "id": 23, + "kind": "command", + "command": { + "command": "group", + "id": 0, + "groupContents": { + "id": 22, "kind": "list", "list": [ { - "id": 18, - "kind": "command", - "command": { - "command": "line", - "literal": false, - "soft": false, - "hard": true - } + "id": 20, + "kind": "list", + "list": [ + { + "id": 18, + "kind": "command", + "command": { + "command": "line", + "literal": false, + "soft": false, + "hard": true + } + }, + { + "id": 19, + "kind": "command", + "command": { + "command": "breakParent" + } + } + ] }, { - "id": 19, - "kind": "command", - "command": { - "command": "breakParent" - } + "id": 21, + "kind": "text", + "text": "type Baz;" } ] }, - { - "id": 21, - "kind": "text", - "text": "type Baz;" - } - ] + "break": true, + "expandedStates": null + } } } }, { - "id": 26, + "id": 27, "kind": "list", "list": [ { - "id": 24, + "id": 25, "kind": "command", "command": { "command": "line", @@ -197,7 +207,7 @@ } }, { - "id": 25, + "id": 26, "kind": "command", "command": { "command": "breakParent" @@ -206,7 +216,7 @@ ] }, { - "id": 27, + "id": 28, "kind": "text", "text": "end Foo;" } diff --git a/testsuite/tests/unparsing/package_decl/short_names/doc-baseline.json b/testsuite/tests/unparsing/package_decl/short_names/doc-baseline.json index 6ad89b0ff..ccb4d36e2 100644 --- a/testsuite/tests/unparsing/package_decl/short_names/doc-baseline.json +++ b/testsuite/tests/unparsing/package_decl/short_names/doc-baseline.json @@ -1,5 +1,5 @@ { - "id": 38, + "id": 40, "kind": "list", "list": [ { @@ -142,52 +142,62 @@ } }, { - "id": 23, + "id": 24, "kind": "command", "command": { "command": "indent", "indentContents": { - "id": 22, - "kind": "list", - "list": [ - { - "id": 20, + "id": 23, + "kind": "command", + "command": { + "command": "group", + "id": 0, + "groupContents": { + "id": 22, "kind": "list", "list": [ { - "id": 18, - "kind": "command", - "command": { - "command": "line", - "literal": false, - "soft": false, - "hard": true - } + "id": 20, + "kind": "list", + "list": [ + { + "id": 18, + "kind": "command", + "command": { + "command": "line", + "literal": false, + "soft": false, + "hard": true + } + }, + { + "id": 19, + "kind": "command", + "command": { + "command": "breakParent" + } + } + ] }, { - "id": 19, - "kind": "command", - "command": { - "command": "breakParent" - } + "id": 21, + "kind": "text", + "text": "type Baz;" } ] }, - { - "id": 21, - "kind": "text", - "text": "type Baz;" - } - ] + "break": true, + "expandedStates": null + } } } }, { - "id": 26, + "id": 27, "kind": "list", "list": [ { - "id": 24, + "id": 25, "kind": "command", "command": { "command": "line", @@ -197,7 +207,7 @@ } }, { - "id": 25, + "id": 26, "kind": "command", "command": { "command": "breakParent" @@ -206,57 +216,67 @@ ] }, { - "id": 27, + "id": 28, "kind": "text", "text": "private" }, { - "id": 33, + "id": 35, "kind": "command", "command": { "command": "indent", "indentContents": { - "id": 32, - "kind": "list", - "list": [ - { - "id": 30, + "id": 34, + "kind": "command", + "command": { + "command": "group", + "id": 0, + "groupContents": { + "id": 33, "kind": "list", "list": [ { - "id": 28, - "kind": "command", - "command": { - "command": "line", - "literal": false, - "soft": false, - "hard": true - } + "id": 31, + "kind": "list", + "list": [ + { + "id": 29, + "kind": "command", + "command": { + "command": "line", + "literal": false, + "soft": false, + "hard": true + } + }, + { + "id": 30, + "kind": "command", + "command": { + "command": "breakParent" + } + } + ] }, { - "id": 29, - "kind": "command", - "command": { - "command": "breakParent" - } + "id": 32, + "kind": "text", + "text": "type Qux;" } ] }, - { - "id": 31, - "kind": "text", - "text": "type Qux;" - } - ] + "break": true, + "expandedStates": null + } } } }, { - "id": 36, + "id": 38, "kind": "list", "list": [ { - "id": 34, + "id": 36, "kind": "command", "command": { "command": "line", @@ -266,7 +286,7 @@ } }, { - "id": 35, + "id": 37, "kind": "command", "command": { "command": "breakParent" @@ -275,7 +295,7 @@ ] }, { - "id": 37, + "id": 39, "kind": "text", "text": "end Foo;" } diff --git a/testsuite/tests/unparsing/subp_body/no_end_name/doc-baseline.json b/testsuite/tests/unparsing/subp_body/no_end_name/doc-baseline.json index 9283b80d9..90b8b5a83 100644 --- a/testsuite/tests/unparsing/subp_body/no_end_name/doc-baseline.json +++ b/testsuite/tests/unparsing/subp_body/no_end_name/doc-baseline.json @@ -1,11 +1,11 @@ { - "id": 120, + "id": 127, "kind": "command", "command": { "command": "group", "id": 0, "groupContents": { - "id": 119, + "id": 126, "kind": "list", "list": [ { @@ -870,35 +870,58 @@ "text": "is" }, { - "id": 110, + "id": 113, "kind": "command", "command": { "command": "indent", "indentContents": { - "id": 109, - "kind": "list", - "list": [ - { - "id": 107, - "kind": "command", - "command": { - "command": "line", - "literal": false, - "soft": false, - "hard": true - } + "id": 112, + "kind": "command", + "command": { + "command": "group", + "id": 0, + "groupContents": { + "id": 111, + "kind": "list", + "list": [ + { + "id": 109, + "kind": "list", + "list": [ + { + "id": 107, + "kind": "command", + "command": { + "command": "line", + "literal": false, + "soft": false, + "hard": true + } + }, + { + "id": 108, + "kind": "command", + "command": { + "command": "breakParent" + } + } + ] + }, + { + "id": 110, + "kind": "text", + "text": "type Garply;" + } + ] }, - { - "id": 108, - "kind": "text", - "text": "type Garply;" - } - ] + "break": true, + "expandedStates": null + } } } }, { - "id": 111, + "id": 114, "kind": "command", "command": { "command": "line", @@ -908,40 +931,69 @@ } }, { - "id": 112, + "id": 115, "kind": "text", "text": "begin" }, { - "id": 116, + "id": 123, "kind": "command", "command": { - "command": "indent", - "indentContents": { - "id": 115, + "command": "group", + "id": 0, + "groupContents": { + "id": 122, "kind": "list", "list": [ { - "id": 113, + "id": 121, "kind": "command", "command": { - "command": "line", - "literal": false, - "soft": false, - "hard": true + "command": "indent", + "indentContents": { + "id": 120, + "kind": "list", + "list": [ + { + "id": 118, + "kind": "list", + "list": [ + { + "id": 116, + "kind": "command", + "command": { + "command": "line", + "literal": false, + "soft": false, + "hard": true + } + }, + { + "id": 117, + "kind": "command", + "command": { + "command": "breakParent" + } + } + ] + }, + { + "id": 119, + "kind": "text", + "text": "null;" + } + ] + } } - }, - { - "id": 114, - "kind": "text", - "text": "null;" } ] - } + }, + "break": true, + "expandedStates": null } }, { - "id": 117, + "id": 124, "kind": "command", "command": { "command": "line", @@ -951,13 +1003,13 @@ } }, { - "id": 118, + "id": 125, "kind": "text", "text": "end;" } ] }, - "break": false, + "break": true, "expandedStates": null } } diff --git a/testsuite/tests/unparsing/subp_body/with_decls/doc-baseline.json b/testsuite/tests/unparsing/subp_body/with_decls/doc-baseline.json index a92a1226a..c619bd48c 100644 --- a/testsuite/tests/unparsing/subp_body/with_decls/doc-baseline.json +++ b/testsuite/tests/unparsing/subp_body/with_decls/doc-baseline.json @@ -1,11 +1,11 @@ { - "id": 120, + "id": 127, "kind": "command", "command": { "command": "group", "id": 0, "groupContents": { - "id": 119, + "id": 126, "kind": "list", "list": [ { @@ -870,35 +870,58 @@ "text": "is" }, { - "id": 110, + "id": 113, "kind": "command", "command": { "command": "indent", "indentContents": { - "id": 109, - "kind": "list", - "list": [ - { - "id": 107, - "kind": "command", - "command": { - "command": "line", - "literal": false, - "soft": false, - "hard": true - } + "id": 112, + "kind": "command", + "command": { + "command": "group", + "id": 0, + "groupContents": { + "id": 111, + "kind": "list", + "list": [ + { + "id": 109, + "kind": "list", + "list": [ + { + "id": 107, + "kind": "command", + "command": { + "command": "line", + "literal": false, + "soft": false, + "hard": true + } + }, + { + "id": 108, + "kind": "command", + "command": { + "command": "breakParent" + } + } + ] + }, + { + "id": 110, + "kind": "text", + "text": "type Garply;" + } + ] }, - { - "id": 108, - "kind": "text", - "text": "type Garply;" - } - ] + "break": true, + "expandedStates": null + } } } }, { - "id": 111, + "id": 114, "kind": "command", "command": { "command": "line", @@ -908,40 +931,69 @@ } }, { - "id": 112, + "id": 115, "kind": "text", "text": "begin" }, { - "id": 116, + "id": 123, "kind": "command", "command": { - "command": "indent", - "indentContents": { - "id": 115, + "command": "group", + "id": 0, + "groupContents": { + "id": 122, "kind": "list", "list": [ { - "id": 113, + "id": 121, "kind": "command", "command": { - "command": "line", - "literal": false, - "soft": false, - "hard": true + "command": "indent", + "indentContents": { + "id": 120, + "kind": "list", + "list": [ + { + "id": 118, + "kind": "list", + "list": [ + { + "id": 116, + "kind": "command", + "command": { + "command": "line", + "literal": false, + "soft": false, + "hard": true + } + }, + { + "id": 117, + "kind": "command", + "command": { + "command": "breakParent" + } + } + ] + }, + { + "id": 119, + "kind": "text", + "text": "null;" + } + ] + } } - }, - { - "id": 114, - "kind": "text", - "text": "null;" } ] - } + }, + "break": true, + "expandedStates": null } }, { - "id": 117, + "id": 124, "kind": "command", "command": { "command": "line", @@ -951,13 +1003,13 @@ } }, { - "id": 118, + "id": 125, "kind": "text", "text": "end Foo;" } ] }, - "break": false, + "break": true, "expandedStates": null } } diff --git a/testsuite/tests/unparsing/subp_body/without_decls/doc-baseline.json b/testsuite/tests/unparsing/subp_body/without_decls/doc-baseline.json index daf9e4533..73174ab96 100644 --- a/testsuite/tests/unparsing/subp_body/without_decls/doc-baseline.json +++ b/testsuite/tests/unparsing/subp_body/without_decls/doc-baseline.json @@ -1,11 +1,11 @@ { - "id": 119, + "id": 122, "kind": "command", "command": { "command": "group", "id": 0, "groupContents": { - "id": 118, + "id": 121, "kind": "list", "list": [ { @@ -189,7 +189,7 @@ "command": "ifBreak", "ifBreakGroupId": 1, "breakContents": { - "id": 19, + "id": 16, "kind": "command", "command": { "command": "align", @@ -198,13 +198,13 @@ "n": 4 }, "alignContents": { - "id": 18, + "id": 15, "kind": "command", "command": { "command": "group", "id": 0, "groupContents": { - "id": 17, + "id": 14, "kind": "list", "list": [ ] @@ -216,7 +216,7 @@ } }, "flatContents": { - "id": 16, + "id": 19, "kind": "command", "command": { "command": "align", @@ -225,13 +225,13 @@ "n": 2 }, "alignContents": { - "id": 15, + "id": 18, "kind": "command", "command": { "command": "group", "id": 0, "groupContents": { - "id": 14, + "id": 17, "kind": "list", "list": [ ] @@ -366,7 +366,7 @@ "command": "ifBreak", "ifBreakGroupId": 1, "breakContents": { - "id": 41, + "id": 38, "kind": "command", "command": { "command": "align", @@ -375,13 +375,13 @@ "n": 4 }, "alignContents": { - "id": 40, + "id": 37, "kind": "command", "command": { "command": "group", "id": 0, "groupContents": { - "id": 39, + "id": 36, "kind": "list", "list": [ ] @@ -393,7 +393,7 @@ } }, "flatContents": { - "id": 38, + "id": 41, "kind": "command", "command": { "command": "align", @@ -402,13 +402,13 @@ "n": 2 }, "alignContents": { - "id": 37, + "id": 40, "kind": "command", "command": { "command": "group", "id": 0, "groupContents": { - "id": 36, + "id": 39, "kind": "list", "list": [ ] @@ -543,7 +543,7 @@ "command": "ifBreak", "ifBreakGroupId": 1, "breakContents": { - "id": 63, + "id": 60, "kind": "command", "command": { "command": "align", @@ -552,13 +552,13 @@ "n": 4 }, "alignContents": { - "id": 62, + "id": 59, "kind": "command", "command": { "command": "group", "id": 0, "groupContents": { - "id": 61, + "id": 58, "kind": "list", "list": [ ] @@ -570,7 +570,7 @@ } }, "flatContents": { - "id": 60, + "id": 63, "kind": "command", "command": { "command": "align", @@ -579,13 +579,13 @@ "n": 2 }, "alignContents": { - "id": 59, + "id": 62, "kind": "command", "command": { "command": "group", "id": 0, "groupContents": { - "id": 58, + "id": 61, "kind": "list", "list": [ ] @@ -720,7 +720,7 @@ "command": "ifBreak", "ifBreakGroupId": 1, "breakContents": { - "id": 85, + "id": 82, "kind": "command", "command": { "command": "align", @@ -729,13 +729,13 @@ "n": 4 }, "alignContents": { - "id": 84, + "id": 81, "kind": "command", "command": { "command": "group", "id": 0, "groupContents": { - "id": 83, + "id": 80, "kind": "list", "list": [ ] @@ -747,7 +747,7 @@ } }, "flatContents": { - "id": 82, + "id": 85, "kind": "command", "command": { "command": "align", @@ -756,13 +756,13 @@ "n": 2 }, "alignContents": { - "id": 81, + "id": 84, "kind": "command", "command": { "command": "group", "id": 0, "groupContents": { - "id": 80, + "id": 83, "kind": "list", "list": [ ] @@ -870,30 +870,20 @@ "text": "is" }, { - "id": 109, + "id": 108, "kind": "command", "command": { "command": "indent", "indentContents": { - "id": 108, + "id": 107, "kind": "list", "list": [ - { - "id": 107, - "kind": "command", - "command": { - "command": "line", - "literal": false, - "soft": false, - "hard": true - } - } ] } } }, { - "id": 110, + "id": 109, "kind": "command", "command": { "command": "line", @@ -903,40 +893,69 @@ } }, { - "id": 111, + "id": 110, "kind": "text", "text": "begin" }, { - "id": 115, + "id": 118, "kind": "command", "command": { - "command": "indent", - "indentContents": { - "id": 114, + "command": "group", + "id": 0, + "groupContents": { + "id": 117, "kind": "list", "list": [ { - "id": 112, + "id": 116, "kind": "command", "command": { - "command": "line", - "literal": false, - "soft": false, - "hard": true + "command": "indent", + "indentContents": { + "id": 115, + "kind": "list", + "list": [ + { + "id": 113, + "kind": "list", + "list": [ + { + "id": 111, + "kind": "command", + "command": { + "command": "line", + "literal": false, + "soft": false, + "hard": true + } + }, + { + "id": 112, + "kind": "command", + "command": { + "command": "breakParent" + } + } + ] + }, + { + "id": 114, + "kind": "text", + "text": "null;" + } + ] + } } - }, - { - "id": 113, - "kind": "text", - "text": "null;" } ] - } + }, + "break": true, + "expandedStates": null } }, { - "id": 116, + "id": 119, "kind": "command", "command": { "command": "line", @@ -946,13 +965,13 @@ } }, { - "id": 117, + "id": 120, "kind": "text", "text": "end Foo;" } ] }, - "break": false, + "break": true, "expandedStates": null } } diff --git a/testsuite/tests/unparsing/subp_body/without_decls/test.yaml b/testsuite/tests/unparsing/subp_body/without_decls/test.yaml index a14b8b3c0..dc068b337 100644 --- a/testsuite/tests/unparsing/subp_body/without_decls/test.yaml +++ b/testsuite/tests/unparsing/subp_body/without_decls/test.yaml @@ -3,9 +3,3 @@ rule: subp_body description: | Test that when `f_decls` is empty, there is not an empty line between `is` and `begin`. -control: - - [ - XFAIL, - "True", - "https://gitlab.adacore-it.com/eng/libadalang/langkit/-/issues/760", - ]