Hi to all the experts in this forum,
I want to write/create a program/tool that,
1. will check all the MOVE statements in a COBOL program
2. calculate the length of 'from' variables - length a
3. calculate the length of 'to' variable - length b (assuming for now that there is only one variable after TO keyword)
4. compare the lengths a and b and check if it matches.
EG: say there is a statement MOVE A B C D to E. I want to check and make sure the length of A+B+C+D is equal to E.
I want to make this tool because I see that sometimes we make mistakes in MOVE statements where the FROM variable is larger than the TO variable leading to truncation that may go unnoticed sometimes.
Any suggestions on which language will be easier to do this? and what commands can help with Steps 1,2 & 3.
I am familiar with cobol,eazytrieve and little bit of Rexx.