-
Notifications
You must be signed in to change notification settings - Fork 26
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
10 changed files
with
190 additions
and
9 deletions.
There are no files selected for viewing
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
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 @@ | ||
-1 -i input\DocGen.tcbl -o output\DocGen.json -d output\error.txt -e rdz -f Documentation -s ..\skeletons.xml |
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,68 @@ | ||
IDENTIFICATION DIVISION. | ||
PROGRAM-ID. DocGen. | ||
|
||
DATA DIVISION. | ||
LOCAL-STORAGE SECTION. | ||
|
||
*<<< | ||
@ description : inline typedef | ||
@ params: | ||
- none: Type doesn't have any params | ||
@deprec | ||
@Restriction : Do not Use BOOL var | ||
@Params: | ||
- Typedefs: should not have any params | ||
*>>> | ||
01 myType TYPEDEF STRICT PUBLIC pic X(01). | ||
|
||
*<<< Vect2D | ||
*>>> | ||
01 Vect2D TYPEDEF STRICT PUBLIC. | ||
02 Coord2d. | ||
03 X PIC 9(4). | ||
03 Y PIC 9(4). | ||
|
||
|
||
*<<< This type is private | ||
*>>> | ||
01 PrivateType TYPEDEF STRICT pic XXX. | ||
|
||
|
||
*<<< My program | ||
@ Description description | ||
@deprecated | ||
@ replacedBy MyFonction2 | ||
@ rEsTrIcTiOn Do not Use BOOL var | ||
@ need some needs | ||
- description | ||
@ see Thank you for your attention | ||
@ todo | ||
- Add BOOL support | ||
- implement a call counter | ||
*>>> | ||
PROCEDURE DIVISION. | ||
|
||
*<<< MyProc info | ||
@ deprec : It is | ||
deprecated | ||
@ need : long need | ||
@ todo: | ||
- todo1 | ||
- todo 2 | ||
@ params: | ||
- myDate: just a date | ||
- bla: bla < 2 | ||
- toto: toto | ||
-blu: will be ignored | ||
*>>> | ||
DECLARE PROCEDURE MyProc PUBLIC | ||
INPUT myDate TYPE Date | ||
bla Pic S9(1)V9(12) | ||
IN-OUT myBool TYPE BOOL | ||
OUTPUT toto TYPE BOOL | ||
bli Pic PPP999PPP. | ||
PROCEDURE DIVISION. | ||
CONTINUE. | ||
END-DECLARE. | ||
|
||
END PROGRAM DocGen. |
2 changes: 2 additions & 0 deletions
2
CLI/test/ressources/documentation/output_expected/DocGen.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,2 @@ | ||
*TypeCobol_Version:0.1(alpha) | ||
{"__type":"DocumentationForProgram:#TypeCobol.Compiler.Nodes","Deprecated":"","Description":"My program description ","Name":"DocGen","Namespace":"DocGen","Needs":["some needs","description"],"ReplacedBy":"MyFonction2 ","Restriction":"Do not Use BOOL var ","See":"Thank you for your attention ","ToDos":["Add BOOL support","implement a call counter"]}{"__type":"DocumentationForType:#TypeCobol.Compiler.Nodes","Deprecated":"","Description":"inline typedef ","Name":"myType","Namespace":"DocGen","Restriction":"Do not Use BOOL var ","Visibility":0,"DocDataType":{"MaxOccurence":1,"Picture":"X(01)"}}{"__type":"DocumentationForType:#TypeCobol.Compiler.Nodes","Description":"Vect2D ","Name":"Vect2D","Namespace":"DocGen","Visibility":0,"Childrens":[{"Childrens":[{"DocDataType":{"MaxOccurence":1,"Picture":"9(4)"},"Name":"X"},{"DocDataType":{"MaxOccurence":1,"Picture":"9(4)"},"Name":"Y"}],"DocDataType":{"MaxOccurence":1},"Name":"Coord2d"}],"DocDataType":{"MaxOccurence":1}}{"__type":"DocumentationForFunction:#TypeCobol.Compiler.Nodes","Deprecated":"It is deprecated ","Description":"MyProc info ","Name":"MyProc","Namespace":"DocGen","Needs":["long need"],"ToDos":["todo1","todo 2"],"Visibility":0,"Parameters":[{"DocDataType":{"MaxOccurence":1,"TypeName":"DATE"},"Info":"just a date","Name":"myDate","PassingType":0},{"DocDataType":{"MaxOccurence":1,"Picture":"S9(1)V9(12)"},"Info":"bla < 2","Name":"bla","PassingType":0},{"DocDataType":{"MaxOccurence":1,"TypeName":"BOOL"},"Name":"myBool","PassingType":2},{"DocDataType":{"MaxOccurence":1,"TypeName":"BOOL"},"Info":"toto","Name":"toto","PassingType":1},{"DocDataType":{"MaxOccurence":1,"Picture":"PPP999PPP"},"Name":"bli","PassingType":1}]} |
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 @@ | ||
ReturnCode=Warning_ | ||
6 errors in "input\DocGen.tcbl": | ||
Line 9[13,18] <37, Warning, General> - Warning: Type Definition does not support Parameters field | ||
Line 9[13,18] <37, Warning, General> - Warning: Formalized comment field is declared more than once : params | ||
Line 13[12,17] <37, Warning, General> - Warning: Formalized comment field is declared more than once : Params | ||
Line 56[12,14] <37, Warning, General> - Warning: Parameter name does not match to any function parameter: blu | ||
Line 61[21,26] <37, Warning, General> - Warning: Parameter does not have any description inside the formalized comments: myBool | ||
Line 63[21,23] <37, Warning, General> - Warning: Parameter does not have any description inside the formalized comments: bli |
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
33 changes: 33 additions & 0 deletions
33
...est/ressources/outputSignature_1/output_expected/ProcedureCall-Public-Signatures.rdz.tcbl
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
8 changes: 6 additions & 2 deletions
8
CLI/test/ressources/outputSignature_1/output_expected/error.txt
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 |
---|---|---|
@@ -1,2 +1,6 @@ | ||
ReturnCode=Success_ | ||
No error in "input\Callee.rdz.tcbl". | ||
ReturnCode=Warning_ | ||
4 errors in "input\Callee.rdz.tcbl": | ||
Line 78[17,22] <37, Warning, General> - Warning: Parameter does not have any description inside the formalized comments: mydate | ||
Line 79[17,23] <37, Warning, General> - Warning: Parameter does not have any description inside the formalized comments: myDate2 | ||
Line 90[17,22] <37, Warning, General> - Warning: Parameter does not have any description inside the formalized comments: mydate | ||
Line 91[17,23] <37, Warning, General> - Warning: Parameter does not have any description inside the formalized comments: myDate2 |
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
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