HP 3000 Manuals

COBOL/HP-UX Language Reference for the Series 700 and 800 : COPYRIGHT NOTICE [ COBOL/HP-UX Language Reference for the Series 700 and 800 ] MPE/iX 5.0 Documentation


COBOL/HP-UX Language Reference for the Series 700 and 800


COBOL/HP-UX Language Reference for the Series 700 and 800 Volumes 1 and 2 HP 9000 Computers Printed in U.S.A. HP Part No. B2433-90007 Edition Third Edition E0293
(c) Copyright 1993 Hewlett-Packard Company. This document contains information which is protected by copyright. All rights are reserved. Reproduction, adaptation, or translation without prior written permission is prohibited, except as allowed under the copyright laws. Restricted Rights Legend Use, duplication, or disclosure by the U.S. Government is subject to restrictions as set forth in sub-paragraph (c)(1)(ii) of the Rights in Technical Data and Computer Software clause in DFARS 252.227-7013. Hewlett-Packard Company 3000 Hanover Street Palo Alto, CA 94304 U.S.A. Rights for non-DOD U.S. Government Departments and Agencies are as set forth in FAR 52.227-19(c)(1,2). Use of this manual and flexible disks(s) or tape cartridge(s) supplied for this pack is restricted to this product only. Additional copies of the programs can be made for security and back-up purposes only. Resale of the programs in their present form or with alterations, is expressly prohibited. (c)Copyright 1980, 1984, 1986 AT&T Technologies, Inc. UNIX is a registered trademark of UNIX System Laboratories Inc. in the U.S.A. and other countries. COBOL is an industry language and is not the property of any company or group of companies or group of organizations. No warranty, expressed or implied, is made by any contributor or by the CODASYL Programming Language Committee as to the accuracy and functioning of the programming system and language. Moreover, no responsibility is assumed by any contributor, or by the committee, in connection herewith. The authors and copyright holders of the copyrighted material used herein: FLOW-MATIC (Trademark for Sperry Rand Corporation) Programming for the Univac(R) I and II, Data Automation Systems copyrighted 1958, 1959, by Sperry Rand Corporation; IBM(R) Commercial Translator Form No. F28-8013, copyrighted 1959 by IBM; FACT, DS127A5260-2760, copyrighted 1960 by Minneapolis-Honeywell. have specifically authorized the use of this material in whole or in part, in the COBOL specifications. Such authorization extends to the reproduction and use of COBOL specifications in programming manuals or similar publications. The software described in this document is supplied under a license and may be used or copied only in accordance with the terms of such license, and in particular any warranty of fitness of Micro Focus software products for any particular purpose is expressly excluded and in no event will Micro Focus be liable for any consequential loss. Micro Focus has made every effort to ensure that this manual is correct and accurate, but reserves the right to make changes without notice at its sole descretion at any time. Micro Focus(R) is a registered trademark of Micro Focus Ltd. Micro Focus(TM), VS COBOL(TM), ANIMATOR(TM), LEVEL II COBOL(TM), LEVEL II COBOL/ET(TM), and Professional COBOL(TM) are trademarks of Micro Focus Ltd. IBM(R) is a registered trademark of International Business Machines Corporation. Systems Application Architecture(TM) is a trademark of International Business Machines Corporation Data General(R) is a registered trademark of Data General Corporation RM/COBOL(R) is a registered trademark of Ryan-McFarland Corporation. Microsoft(R) is a registered trademark of Microsoft Corporation UNIX(R) is a registered trademark of AT&T PANVALET(TM) is a trademark of Pansophic LIBRARIAN(TM) is a trademark of Computer Associates X/Open(R) is a registered trademark of the X/Open Company Limited in the UK and other countries. (c) Copyright 1978, 1992 by Micro Focus Ltd. All rights reserved. Printed February 1993 Legal Notices The information contained in this document is subject to change without notice. HEWLETT-PACKARD MAKES NO WARRANTY OF ANY KIND WITH REGARD TO THIS MATERIAL, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. Hewlett-Packard shall not be liable for errors contained herein or for incidental or consequential damages in connection with the furnishing, performance or use of this material. Hewlett-Packard assumes no responsibility for the use or reliability of its software on equipment that is not furnished by Hewlett-Packard. Warranty A copy of the specific warranty terms applicable to your Hewlett-Packard product and replacement parts can be obtained from your local Sales and Service Office. Print History New editions are complete revisions of the manual. The dates on the title page change only when a new edition is printed. The software code printed alongside the date indicates the version level of the software product at the time the manual was issued. Many product updates and fixes do not require manual changes and, conversely, manual corrections may be done without accompanying product changes. Therefore, do not expect a one-to-one correspondence between product updates and manual updates. First Edition June 1991 35328B.04.50 Second Edition November 1991 35328B.06.25 Third Edition February 1993 B2433B.07.00 Additional Documentation The following documents are supplied with COBOL/HP-UX. * COBOL/HP-UX Implementation Notes for Series 700/800 (part number B2433-90001) * COBOL/HP-UX Getting Started (part number B2433-90005) replaces 35328-90002 * COBOL/HP-UX Language Reference Manual Vol. 1 & 2 (part number B2433-90007) replaces 35328-90001 * COBOL/HP-UX Operating Guide (part number B2433-90009) replaces 35328-90002 * COBOL/HP-UX Compatibility Guide (part number B2433-90011) replaces 35328-90003 * COBOL/HP-UX Error Messages (part number B2433-90013) replaces 35328-90002 * COBOL/HP-UX Master Index (part number B2433-90015) * COBOL/HP-UX Pocket Guide (part number B2433-90017) replaces 35328-90012 Refer to the following documents for more information on the HP-UX operating system: * HP-UX Reference (part number B2355-90033) * HP-UX System Administration Tasks Manual (part number B3108-90012) * Installing and Updating HP-UX (part number B3108-90006) * How HP-UX Works: Concepts for the System Administrator (part number B2355-90029) * Installing and Administering NFS Services (part number B1013-90009) * Programming on HP-UX (part number B2355-90026) * HP Symbolic Debugger User's Guide (part number B2355-90044) Preface This manual describes the COBOL language supported by this system for programming microcomputers. This COBOL language is based on the ANSI COBOL standard X3.23-1985. It also describes the additional COBOL language features that exploit the capabilities of microprocessors. This COBOL language is supported by a number of COBOL systems. See your COBOL System Reference for details of your system. Audience This manual is intended for programmers already familiar with the COBOL language. Related Publications Other manuals in your document set which you may need to refer to are the: * COBOL System Reference * Error Messages * Compatibility Guide Notation in this Manual Throughout this manual, the following notation is used to describe the format of COBOL statements: 1. All words printed in capital letters which are underlined must always be present when the functions of which they are a part are used. An error will be reported by your COBOL system if the underlined words are absent or incorrectly spelled. The underlining is not necessary when writing a COBOL source program. 2. All words printed in capital letters which are not underlined are used in the COBOL source program for readability only. They may be written, or not, as the programmer wishes, but if written, must be correctly spelled. 3. All words printed in small letters are generic terms representing names which will be devised by the programmer. 4. When material is enclosed in braces { }, a choice must be made from the options within them. If there is only one available option enclosed within braces, that material must be written. In this case braces indicate repetition. 5. When material is enclosed in choice indicators { | | }, one or more of the unique options must be specified, but a single option may be specified only once. 6. When material is enclosed in square brackets [ ] , it is an indication that the material is an option which may be included or omitted as required. 7. When material is enclosed in boxed, square brackets [ ] it is an indication that the material is mandatory for ANSI'74 COBOL (American National Standards Institute publication X3.23-1974) but may be optionally omitted as an extension to that language specification. The symbol in the margin indicates the dialects of COBOL in which that material is optional. See rule 9 for further details on dialect features. 8. In text, the ellipsis (...) shows the omission of a portion of a source program or a sequence. This meaning becomes apparent in context. In the General Formats, the ellipsis represents the position at which repetition may occur at the user's option. The portion of the format that may be repeated is determined as follows: Given ... in a clause or statement format, scanning right to left, determine the } or ] immediately to the left of the ...; continue scanning right to left and determine the logically matching { or [; the ... applies to the words between the determined pair of delimiters. [REV BEG] 9. This Reference presents the syntax of IBM SAA AD/Cycle COBOL370 (COBOL/370) statements and the rules for writing source programs that are to be compiled by the COBOL/370 compiler. The only difference between COBOL/370 and IBM VS COBOL II is that for the Procedure-Pointer format, the default length is eight bytes rather than four bytes. 10. This Reference presents the syntax of Multivendor Integration Architecture (MIA) - Technical Requirements for the programming language COBOL.[REV END] 11. The COBOL language accepted by most COBOL compilers includes extensions to the COBOL language defined in American National Standard X2.23-1974. Different compilers allow different extensions to this standard which means there are different versions, called `dialects', of COBOL. This COBOL product is designed for use in cross-development; it can be used for developing not only programs for use on your COBOL system itself but also programs for use with IBM OS/VS COBOL or IBM VS COBOL II, or programs that conform entirely to ANS X3.23-1974 or its successor ANS X3.23-1985. It allows most extensions that are in the two IBM COBOLs, and all the features from ANS X3.23-1985. To help you keep to the appropriate dialect - that of your target system - this manual shows the dialects in which each feature appears. Features outside ANS X3.23-1974 are enclosed in boxes, with symbols in the margin, thus: (OSVS) These features are extensions to ANS X3.23-1974 that appear in IBM OS/VS COBOL. (VSC2) These features are extensions to ANS X3.23-1985 that appear in IBM VS COBOL II. (ANS85) These features are new features defined in ANS X3.23-1985 which are not supported under ANS X3.23-1974. (XOPEN) These features are extensions to ANS X3.23-1985 that appear in the X/Open CAE Specification, COBOL language (XPG-4). (MF) These features are extensions to ANS X3.23-1985 that are specific to Micro Focus COBOL. Note: The Micro Focus, VS COBOL II, and X/Open dialects are all based on the ANS X3.23-1985 COBOL Standard. Therefore, any syntax (or rules) which are marked as valid for ANS85 are also valid for Micro Focus, VS COBOL II, and X/Open unless explicitly designated otherwise. You should note that these bubbles only reflect support for a particular syntax and its semantics. You have to use system directives to effect a set of reserved words associated with a particular dialect. See your COBOL System Reference for details on these directives, and Appendix B of this manual for a list of the reserved words affected by various dialects. Thus, for example, if you are developing a program for use on IBM OS/VS COBOL, you can use the unmarked features plus any marked OSVS; while if developing solely for your COBOL environment you can use any feature. There is a `flag' directive that you can supply when you invoke the system software which causes your COBOL system software to flag any features outside the given dialect. (See your COBOL System Reference for details.) Also see your COBOL System Reference for information on the FLAGAS directive which turns flagging messages into error messages. 12. Some features have different effects in different dialects; you specify a `dialect-control' directive to select the dialect with which you want compatibility. The boxes around such features are double-ruled. Extra reserved words needed by features outside ANS X3.23-1985 are reserved only when the appropriate dialect-control directive is present; this means you can ensure that the only words reserved in the specified dialect are reserved on your target system. If you use only features that need no extra reserved words, and whose effects are the same in all dialects, you need not specify a dialect-control directive. The dialect-control directive specifying the ANS X3.23-1985 dialect also causes the few ANS 3.23-1974 features not allowed in ANS X3.23-1985 to be flagged with a warning message. (See your COBOL System Reference for details of these dialect-control directives.) 13. The phrase `for documentation purposes only' in the text of this manual means that the associated coding is accepted syntactically by your COBOL system software, but is ignored when producing the object program. 14. The changes for this release are summarized in your product's Release Notes. Specific changes within this manual are indicated by a vertical bar to the right of the change. These bars may be deleted at any re-publication of the page affected. Editorial changes that have no technical significance are not noted. [REV BEG] 15. Hexadecimal numbers are enclosed in quotation marks and preceded by a lowercase x; for example, x"9D".[REV END]


MPE/iX 5.0 Documentation