-
Notifications
You must be signed in to change notification settings - Fork 42
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
16 changed files
with
724 additions
and
0 deletions.
There are no files selected for viewing
179 changes: 179 additions & 0 deletions
179
testsuite/tests/unparsing/use_type_clause/long_use_types_list/doc-baseline.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,179 @@ | ||
{ | ||
"id": 23, | ||
"kind": "command", | ||
"command": { | ||
"command": "group", | ||
"id": 0, | ||
"groupContents": { | ||
"id": 22, | ||
"kind": "list", | ||
"list": [ | ||
{ | ||
"id": 0, | ||
"kind": "text", | ||
"text": "use type " | ||
}, | ||
{ | ||
"id": 20, | ||
"kind": "command", | ||
"command": { | ||
"command": "align", | ||
"alignData": { | ||
"kind": "innerRoot" | ||
}, | ||
"alignContents": { | ||
"id": 19, | ||
"kind": "list", | ||
"list": [ | ||
{ | ||
"id": 9, | ||
"kind": "command", | ||
"command": { | ||
"command": "align", | ||
"alignData": { | ||
"kind": "innerRoot" | ||
}, | ||
"alignContents": { | ||
"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": 1, | ||
"kind": "text", | ||
"text": "Aaaaaaaaa" | ||
}, | ||
{ | ||
"id": 2, | ||
"kind": "command", | ||
"command": { | ||
"command": "line", | ||
"literal": false, | ||
"soft": true, | ||
"hard": false | ||
} | ||
}, | ||
{ | ||
"id": 3, | ||
"kind": "text", | ||
"text": ".Bbbbbbb" | ||
}, | ||
{ | ||
"id": 4, | ||
"kind": "command", | ||
"command": { | ||
"command": "line", | ||
"literal": false, | ||
"soft": true, | ||
"hard": false | ||
} | ||
}, | ||
{ | ||
"id": 5, | ||
"kind": "text", | ||
"text": ".Cccccc" | ||
} | ||
] | ||
}, | ||
"break": false, | ||
"expandedStates": null | ||
} | ||
} | ||
} | ||
} | ||
} | ||
}, | ||
{ | ||
"id": 10, | ||
"kind": "text", | ||
"text": "," | ||
}, | ||
{ | ||
"id": 11, | ||
"kind": "command", | ||
"command": { | ||
"command": "line", | ||
"literal": false, | ||
"soft": false, | ||
"hard": false | ||
} | ||
}, | ||
{ | ||
"id": 12, | ||
"kind": "text", | ||
"text": "Dddddddddddddddddddd," | ||
}, | ||
{ | ||
"id": 13, | ||
"kind": "command", | ||
"command": { | ||
"command": "line", | ||
"literal": false, | ||
"soft": false, | ||
"hard": false | ||
} | ||
}, | ||
{ | ||
"id": 14, | ||
"kind": "text", | ||
"text": "eeeeeeeeeeeeeeeeeeeeeeeeee," | ||
}, | ||
{ | ||
"id": 15, | ||
"kind": "command", | ||
"command": { | ||
"command": "line", | ||
"literal": false, | ||
"soft": false, | ||
"hard": false | ||
} | ||
}, | ||
{ | ||
"id": 16, | ||
"kind": "text", | ||
"text": "Fff," | ||
}, | ||
{ | ||
"id": 17, | ||
"kind": "command", | ||
"command": { | ||
"command": "line", | ||
"literal": false, | ||
"soft": false, | ||
"hard": false | ||
} | ||
}, | ||
{ | ||
"id": 18, | ||
"kind": "text", | ||
"text": "Ggg" | ||
} | ||
] | ||
} | ||
} | ||
}, | ||
{ | ||
"id": 21, | ||
"kind": "text", | ||
"text": ";" | ||
} | ||
] | ||
}, | ||
"break": false, | ||
"expandedStates": null | ||
} | ||
} |
1 change: 1 addition & 0 deletions
1
testsuite/tests/unparsing/use_type_clause/long_use_types_list/input.ada
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
use type Aaaaaaaaa .Bbbbbbb. Cccccc, Dddddddddddddddddddd, eeeeeeeeeeeeeeeeeeeeeeeeee, Fff, Ggg; |
5 changes: 5 additions & 0 deletions
5
testsuite/tests/unparsing/use_type_clause/long_use_types_list/test.out
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
use type Aaaaaaaaa.Bbbbbbb.Cccccc, | ||
Dddddddddddddddddddd, | ||
eeeeeeeeeeeeeeeeeeeeeeeeee, | ||
Fff, | ||
Ggg; |
10 changes: 10 additions & 0 deletions
10
testsuite/tests/unparsing/use_type_clause/long_use_types_list/test.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
description: | | ||
This test checks the formatting of a use type clause line | ||
with an exceeding length. Dotted names and simple names are | ||
used to designate the types. | ||
It is expected to break after the first used type and get | ||
all the types aligned afterbased on this element initial | ||
position. | ||
driver: unparser | ||
rule: use_clause |
179 changes: 179 additions & 0 deletions
179
testsuite/tests/unparsing/use_type_clause/simple_types_list/doc-baseline.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,179 @@ | ||
{ | ||
"id": 23, | ||
"kind": "command", | ||
"command": { | ||
"command": "group", | ||
"id": 0, | ||
"groupContents": { | ||
"id": 22, | ||
"kind": "list", | ||
"list": [ | ||
{ | ||
"id": 0, | ||
"kind": "text", | ||
"text": "use type " | ||
}, | ||
{ | ||
"id": 20, | ||
"kind": "command", | ||
"command": { | ||
"command": "align", | ||
"alignData": { | ||
"kind": "innerRoot" | ||
}, | ||
"alignContents": { | ||
"id": 19, | ||
"kind": "list", | ||
"list": [ | ||
{ | ||
"id": 9, | ||
"kind": "command", | ||
"command": { | ||
"command": "align", | ||
"alignData": { | ||
"kind": "innerRoot" | ||
}, | ||
"alignContents": { | ||
"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": 1, | ||
"kind": "text", | ||
"text": "Aaa" | ||
}, | ||
{ | ||
"id": 2, | ||
"kind": "command", | ||
"command": { | ||
"command": "line", | ||
"literal": false, | ||
"soft": true, | ||
"hard": false | ||
} | ||
}, | ||
{ | ||
"id": 3, | ||
"kind": "text", | ||
"text": ".Bbb" | ||
}, | ||
{ | ||
"id": 4, | ||
"kind": "command", | ||
"command": { | ||
"command": "line", | ||
"literal": false, | ||
"soft": true, | ||
"hard": false | ||
} | ||
}, | ||
{ | ||
"id": 5, | ||
"kind": "text", | ||
"text": ".C" | ||
} | ||
] | ||
}, | ||
"break": false, | ||
"expandedStates": null | ||
} | ||
} | ||
} | ||
} | ||
} | ||
}, | ||
{ | ||
"id": 10, | ||
"kind": "text", | ||
"text": "," | ||
}, | ||
{ | ||
"id": 11, | ||
"kind": "command", | ||
"command": { | ||
"command": "line", | ||
"literal": false, | ||
"soft": false, | ||
"hard": false | ||
} | ||
}, | ||
{ | ||
"id": 12, | ||
"kind": "text", | ||
"text": "Ddd," | ||
}, | ||
{ | ||
"id": 13, | ||
"kind": "command", | ||
"command": { | ||
"command": "line", | ||
"literal": false, | ||
"soft": false, | ||
"hard": false | ||
} | ||
}, | ||
{ | ||
"id": 14, | ||
"kind": "text", | ||
"text": "eeeee," | ||
}, | ||
{ | ||
"id": 15, | ||
"kind": "command", | ||
"command": { | ||
"command": "line", | ||
"literal": false, | ||
"soft": false, | ||
"hard": false | ||
} | ||
}, | ||
{ | ||
"id": 16, | ||
"kind": "text", | ||
"text": "Fff," | ||
}, | ||
{ | ||
"id": 17, | ||
"kind": "command", | ||
"command": { | ||
"command": "line", | ||
"literal": false, | ||
"soft": false, | ||
"hard": false | ||
} | ||
}, | ||
{ | ||
"id": 18, | ||
"kind": "text", | ||
"text": "Ggg" | ||
} | ||
] | ||
} | ||
} | ||
}, | ||
{ | ||
"id": 21, | ||
"kind": "text", | ||
"text": ";" | ||
} | ||
] | ||
}, | ||
"break": false, | ||
"expandedStates": null | ||
} | ||
} |
1 change: 1 addition & 0 deletions
1
testsuite/tests/unparsing/use_type_clause/simple_types_list/input.ada
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
use type Aaa .Bbb. C, Ddd, eeeee, Fff, Ggg; |
1 change: 1 addition & 0 deletions
1
testsuite/tests/unparsing/use_type_clause/simple_types_list/test.out
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
use type Aaa.Bbb.C, Ddd, eeeee, Fff, Ggg; |
8 changes: 8 additions & 0 deletions
8
testsuite/tests/unparsing/use_type_clause/simple_types_list/test.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
description: | | ||
This test checks the formatting of a single line use type clause | ||
with a dotted name ada kind used to designate the package. | ||
It is expected to kee everything on the same line and keep the | ||
initial casing as well. | ||
driver: unparser | ||
rule: use_clause |
Oops, something went wrong.