Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

missing or extra end statements in pl/I

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> PL/I & Assembler
View previous topic :: :: View next topic  
Author Message
Harvey Sullivan

New User


Joined: 05 Nov 2007
Posts: 19
Location: Monterey CA

PostPosted: Sat Jan 19, 2008 4:08 am    Post subject: missing or extra end statements in pl/I
Reply with quote

is there an easy way to find missing or extra end; statements? I have a very large program, many procs and many do statements and do loops is there any way to match them up to solve the problem without doing it by hand? TIA, Harvey
Back to top
View user's profile Send private message

dick scherrer

Site Director


Joined: 23 Nov 2006
Posts: 19270
Location: Inside the Matrix

PostPosted: Sat Jan 19, 2008 4:25 am    Post subject:
Reply with quote

Hello,

If a compilation does not "flag" them, might they be correct?

If they are syntactically correct, analysis may be needed to determine if they are "good" or not. . .

If i'm way off, please ignore - dain brammage - long week today icon_smile.gif
Back to top
View user's profile Send private message
Harvey Sullivan

New User


Joined: 05 Nov 2007
Posts: 19
Location: Monterey CA

PostPosted: Sat Jan 19, 2008 4:51 am    Post subject:
Reply with quote

Sorry, the compiler does flag it with this:

IBM1861I S All statements other than DECLARE, DEFAULT and PROCEDURE statements must be contained inside a PROCEDURE. Explanation: This message can occur, for instance, if the first PROCEDURE statement is invalid or if a PROCEDURE contains too many END statements.

it flags the last statement of a 2500 statement program. The first procedure statemnt is OK.
Back to top
View user's profile Send private message
Phrzby Phil

Active Member


Joined: 31 Oct 2006
Posts: 964
Location: Richmond, Virginia

PostPosted: Sat Jan 19, 2008 6:27 am    Post subject:
Reply with quote

The compile listing also has BLOCK and DO counters down the left (may be an option. Check if each BLOCK and DO matches with the END you think it should (you did indent properly I hope). If not, you have a problem within that group.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> PL/I & Assembler All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Extra character appears in file when ... Balu5491 All Other Mainframe Topics 1 Wed Jul 26, 2017 2:39 pm
No new posts Cobol upgrade - source code missing f... gthmrj IBM Tools 1 Wed Apr 26, 2017 6:04 pm
No new posts Removing Extra Spaces in a comma sepa... Puspojit DFSORT/ICETOOL 3 Tue Sep 13, 2016 7:46 am
No new posts Fault Analyser - missing code explana... egrove IBM Tools 1 Thu Aug 11, 2016 5:55 pm
No new posts Symbolic Parameters in SYSIN DD state... madishpa DFSORT/ICETOOL 3 Mon Jun 27, 2016 6:23 pm


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us