Skip to content

Commit

Permalink
Add ProtectedTypeDecl and ProtectedTypeDef configuration
Browse files Browse the repository at this point in the history
  • Loading branch information
CKMonika committed Mar 27, 2024
1 parent 4efb1b4 commit d36a3b7
Show file tree
Hide file tree
Showing 38 changed files with 22,538 additions and 20,130 deletions.
122 changes: 121 additions & 1 deletion extensions/default_unparsing_config.json
Original file line number Diff line number Diff line change
Expand Up @@ -2905,6 +2905,119 @@
"hardline"
]
},
"ProtectedDef": {
"node": {
"kind": "group",
"document": [
{
"kind": "indent",
"contents": [
{
"kind": "recurse_field",
"field": "f_public_part"
}
]
},
"hardline",
{
"kind": "recurse_field",
"field": "f_private_part"
},
{
"kind": "text",
"text": "end"
},
"whitespace",
{
"kind": "recurse_field",
"field": "f_end_name"
}
]
},
"fields": {
"f_private_part": {
"kind": "ifEmpty",
"then": "recurse",
"else": [
{
"kind": "indent",
"contents": "recurse"
},
"hardline"
]
}
}
},
"ProtectedTypeDecl": {
"node": {
"kind": "group",
"document": [
{
"kind": "group",
"document": [
{
"kind": "text",
"text": "protected"
},
{
"kind": "text",
"text": "type"
},
"whitespace",
{
"kind": "recurse_field",
"field": "f_name"
},
{
"kind": "recurse_field",
"field": "f_discriminants"
},
{
"kind": "recurse_field",
"field": "f_aspects"
},
"line",
{
"kind": "text",
"text": "is"
}
]
},
{
"kind": "group",
"document": [
{
"kind": "recurse_field",
"field": "f_interfaces"
}
]
},
{
"kind": "recurse_field",
"field": "f_definition"
},
{
"kind": "text",
"text": ";"
}
]
},
"fields": {
"f_discriminants": {
"kind": "align",
"width": 2,
"contents": "recurse"
},
"f_aspects": {
"kind": "align",
"width": 2,
"contents": [
"hardline",
"recurse"
]
}
}
},
"RangeSpec": {
"node": {
"kind": "align",
Expand Down Expand Up @@ -3147,7 +3260,6 @@
"kind": "recurse_field",
"field": "f_subp_name"
},
"line",
{
"kind": "group",
"document": [
Expand Down Expand Up @@ -3180,6 +3292,14 @@
"recurse"
]
}
},
"f_subp_params": {
"kind": "ifEmpty",
"then": "recurse",
"else": [
"line",
"recurse"
]
}
}
},
Expand Down
1,252 changes: 626 additions & 626 deletions testsuite/tests/unparsing/expr_function/everything_long/doc-baseline.json

Large diffs are not rendered by default.

1,080 changes: 540 additions & 540 deletions testsuite/tests/unparsing/expr_function/long_spec/doc-baseline.json

Large diffs are not rendered by default.

1,252 changes: 626 additions & 626 deletions testsuite/tests/unparsing/expr_function/long_spec_with_aspect/doc-baseline.json

Large diffs are not rendered by default.

1,080 changes: 540 additions & 540 deletions testsuite/tests/unparsing/expr_function/short/doc-baseline.json

Large diffs are not rendered by default.

1,252 changes: 626 additions & 626 deletions testsuite/tests/unparsing/expr_function/short_with_aspect/doc-baseline.json

Large diffs are not rendered by default.

220 changes: 105 additions & 115 deletions testsuite/tests/unparsing/generic_formal_subp_decl/doc-baseline.json
Original file line number Diff line number Diff line change
@@ -1,115 +1,105 @@
{
"id": 13,
"kind": "command",
"command": {
"command": "group",
"id": 0,
"groupContents": {
"id": 12,
"kind": "command",
"command": {
"command": "align",
"alignData": {
"kind": "width",
"n": 2
},
"alignContents": {
"id": 11,
"kind": "command",
"command": {
"command": "group",
"id": 0,
"groupContents": {
"id": 10,
"kind": "list",
"list": [
{
"id": 0,
"kind": "text",
"text": "with"
},
{
"id": 1,
"kind": "command",
"command": {
"command": "line",
"literal": false,
"soft": false,
"hard": false
}
},
{
"id": 8,
"kind": "command",
"command": {
"command": "align",
"alignData": {
"kind": "width",
"n": 2
},
"alignContents": {
"id": 7,
"kind": "command",
"command": {
"command": "group",
"id": 0,
"groupContents": {
"id": 6,
"kind": "list",
"list": [
{
"id": 2,
"kind": "text",
"text": "procedure Foo"
},
{
"id": 3,
"kind": "command",
"command": {
"command": "line",
"literal": false,
"soft": false,
"hard": false
}
},
{
"id": 5,
"kind": "command",
"command": {
"command": "group",
"id": 0,
"groupContents": {
"id": 4,
"kind": "list",
"list": [
]
},
"break": false,
"expandedStates": null
}
}
]
},
"break": false,
"expandedStates": null
}
}
}
},
{
"id": 9,
"kind": "text",
"text": "is Bar;"
}
]
},
"break": false,
"expandedStates": null
}
}
}
},
"break": false,
"expandedStates": null
}
}
{
"id": 12,
"kind": "command",
"command": {
"command": "group",
"id": 0,
"groupContents": {
"id": 11,
"kind": "command",
"command": {
"command": "align",
"alignData": {
"kind": "width",
"n": 2
},
"alignContents": {
"id": 10,
"kind": "command",
"command": {
"command": "group",
"id": 0,
"groupContents": {
"id": 9,
"kind": "list",
"list": [
{
"id": 0,
"kind": "text",
"text": "with"
},
{
"id": 1,
"kind": "command",
"command": {
"command": "line",
"literal": false,
"soft": false,
"hard": false
}
},
{
"id": 7,
"kind": "command",
"command": {
"command": "align",
"alignData": {
"kind": "width",
"n": 2
},
"alignContents": {
"id": 6,
"kind": "command",
"command": {
"command": "group",
"id": 0,
"groupContents": {
"id": 5,
"kind": "list",
"list": [
{
"id": 2,
"kind": "text",
"text": "procedure Foo"
},
{
"id": 4,
"kind": "command",
"command": {
"command": "group",
"id": 0,
"groupContents": {
"id": 3,
"kind": "list",
"list": [
]
},
"break": false,
"expandedStates": null
}
}
]
},
"break": false,
"expandedStates": null
}
}
}
},
{
"id": 8,
"kind": "text",
"text": " is Bar;"
}
]
},
"break": false,
"expandedStates": null
}
}
}
},
"break": false,
"expandedStates": null
}
}
Loading

0 comments on commit d36a3b7

Please sign in to comment.