AS/NZS ISO/IEC 1539.1:2024 identically adopts ISO/IEC 1539 1:2023, which specifies the form and establishes the interpretation of programs expressed in the base Fortran language
Table of contents
Header
About this publication
Preface
Foreword
Introduction
1 Scope
2 Normative references
3 Terms and definitions
4 Notation, conformance, and compatibility
4.1 Notation, symbols and abbreviated terms
4.1.1 Syntax rules
4.1.2 Constraints
4.1.3 Assumed syntax rules
4.1.4 Syntax conventions and characteristics
4.1.5 Text conventions
4.2 Conformance
4.3 Compatibility
4.3.1 Previous Fortran standards
4.3.2 New intrinsic procedures
4.3.3 Fortran 2018 compatibility
4.3.4 Fortran 2008 compatibility
4.3.5 Fortran 2003 compatibility
4.3.6 Fortran 95 compatibility
4.3.7 Fortran 90 compatibility
4.3.8 Fortran 77 compatibility
4.4 Deleted and obsolescent features
4.4.1 General
4.4.2 Nature of deleted features
4.4.3 Nature of obsolescent features
5 Fortran concepts
5.1 High level syntax
5.2 Program unit concepts
5.2.1 Program units and scoping units
5.2.2 Program
5.2.3 Procedure
5.2.4 Module
5.2.5 Submodule
5.3 Execution concepts
5.3.1 Statement classification
5.3.2 Statement order
5.3.3 The END statement
5.3.4 Program execution
5.3.5 Execution sequence
5.3.6 Image execution states
5.3.7 Termination of execution
5.4 Data concepts
5.4.1 Type
5.4.1.1 General
5.4.1.2 Intrinsic type
5.4.1.3 Derived type
5.4.2 Data value
5.4.3 Data entity
5.4.3.1 General
5.4.3.2 Data object
5.4.3.2.1 Data object classification
5.4.3.2.2 Variable
5.4.3.2.3 Constant
5.4.3.2.4 Subobject of a constant
5.4.3.3 Expression
5.4.3.4 Function reference
5.4.4 Definition of objects and pointers
5.4.5 Reference
5.4.6 Array
5.4.7 Coarray
5.4.8 Established coarrays
5.4.9 Pointer
5.4.10 Allocatable variables
5.4.11 Storage
5.5 Fundamental concepts
5.5.1 Names and designators
5.5.2 Statement keyword
5.5.3 Other keywords
5.5.4 Association
5.5.5 Intrinsic
5.5.6 Operator
5.5.7 Companion processors
6 Lexical tokens and source form
6.1 Processor character set
6.1.1 Characters
6.1.2 Letters
6.1.3 Digits
6.1.4 Underscore
6.1.5 Special characters
6.1.6 Other characters
6.2 Low-level syntax
6.2.1 Tokens
6.2.2 Names
6.2.3 Constants
6.2.4 Operators
6.2.5 Statement labels
6.2.6 Delimiters
6.3 Source form
6.3.1 Program units, statements, and lines
6.3.2 Free source form
6.3.2.1 Free form line length
6.3.2.2 Blank characters in free form
6.3.2.3 Free form commentary
6.3.2.4 Free form statement continuation
6.3.2.5 Free form statement termination
6.3.2.6 Free form statements
6.3.3 Fixed source form
6.3.3.1 General
6.3.3.2 Fixed form commentary
6.3.3.3 Fixed form statement continuation
6.3.3.4 Fixed form statement termination
6.3.3.5 Fixed form statements
6.4 Including source text
7 Types
7.1 Characteristics of types
7.1.1 The concept of type
7.1.2 Type classification
7.1.3 Set of values
7.1.4 Constants
7.1.5 Operations
7.2 Type parameters
7.3 Types, type specifiers, and values
7.3.1 Relationship of types and values to objects
7.3.2 Type specifiers
7.3.2.1 Type specifier syntax
7.3.2.2 TYPE type specifier
7.3.2.3 CLASS type specifier
7.3.3 Type compatibility
7.4 Intrinsic types
7.4.1 Classification and specification
7.4.2 Intrinsic operations on intrinsic types
7.4.3 Numeric intrinsic types
7.4.3.1 Integer type
7.4.3.2 Real type
7.4.3.3 Complex type
7.4.4 Character type
7.4.4.1 Character sets
7.4.4.2 Character type specifier
7.4.4.3 Character literal constant
7.4.4.4 Collating sequence
7.4.5 Logical type
7.5 Derived types
7.5.1 Derived type concepts
7.5.2 Derived-type definition
7.5.2.1 Syntax of a derived-type definition
7.5.2.2 Accessibility
7.5.2.3 Sequence type
7.5.2.4 Determination of derived types
7.5.3 Derived-type parameters
7.5.3.1 Type parameter definition statement
7.5.3.2 Type parameter order
7.5.4 Components
7.5.4.1 Component definition statement
7.5.4.2 Array components
7.5.4.3 Coarray components
7.5.4.4 Pointer components
7.5.4.5 The passed-object dummy argument
7.5.4.6 Default initialization for components
7.5.4.7 Component order
7.5.4.8 Component accessibility
7.5.5 Type-bound procedures
7.5.6 Final subroutines
7.5.6.1 FINAL statement
7.5.6.2 The finalization process
7.5.6.3 When finalization occurs
7.5.6.4 Entities that are not finalized
7.5.7 Type extension
7.5.7.1 Extensible, extended, and abstract types
7.5.7.2 Inheritance
7.5.7.3 Type-bound procedure overriding
7.5.8 Derived-type values
7.5.9 Derived-type specifier
7.5.10 Construction of derived-type values
7.5.11 Derived-type operations and assignment
7.6 Other nonintrinsic types
7.6.1 Interoperable enumerations and enum types
7.6.2 Enumeration types
7.7 Binary, octal, and hexadecimal literal constants
7.8 Construction of array values
8 Attribute declarations and specifications
8.1 Attributes of procedures and data objects
8.2 Type declaration statement
8.3 Automatic data objects
8.4 Initialization
8.5 Attributes
8.5.1 Attribute specification
8.5.2 Accessibility attribute
8.5.3 ALLOCATABLE attribute
8.5.4 ASYNCHRONOUS attribute
8.5.5 BIND attribute for data entities
8.5.6 CODIMENSION attribute
8.5.6.1 General
8.5.6.2 Allocatable coarray
8.5.6.3 Explicit-coshape coarray
8.5.7 CONTIGUOUS attribute
8.5.8 DIMENSION attribute
8.5.8.1 General
8.5.8.2 Explicit-shape array
8.5.8.3 Assumed-shape array
8.5.8.4 Deferred-shape array
8.5.8.5 Assumed-size array
8.5.8.6 Implied-shape array
8.5.8.7 Assumed-rank entity
8.5.9 EXTERNAL attribute
8.5.10 INTENT attribute
8.5.11 INTRINSIC attribute
8.5.12 OPTIONAL attribute
8.5.13 PARAMETER attribute
8.5.14 POINTER attribute
8.5.15 PROTECTED attribute
8.5.16 SAVE attribute
8.5.17 RANK clause
8.5.18 TARGET attribute
8.5.19 VALUE attribute
8.5.20 VOLATILE attribute
8.6 Attribute specification statements
8.6.1 Accessibility statement
8.6.2 ALLOCATABLE statement
8.6.3 ASYNCHRONOUS statement
8.6.4 BIND statement
8.6.5 CODIMENSION statement
8.6.6 CONTIGUOUS statement
8.6.7 DATA statement
8.6.8 DIMENSION statement
8.6.9 INTENT statement
8.6.10 OPTIONAL statement
8.6.11 PARAMETER statement
8.6.12 POINTER statement
8.6.13 PROTECTED statement
8.6.14 SAVE statement
8.6.15 TARGET statement
8.6.16 VALUE statement
8.6.17 VOLATILE statement
8.7 IMPLICIT statement
8.8 IMPORT statement
8.9 NAMELIST statement
8.10 Storage association of data objects
8.10.1 EQUIVALENCE statement
8.10.1.1 General
8.10.1.2 Equivalence association
8.10.1.3 Equivalence of default character objects
8.10.1.4 Array names and array element designators
8.10.1.5 Restrictions on EQUIVALENCE statements
8.10.2 COMMON statement
8.10.2.1 General
8.10.2.2 Common block storage sequence
8.10.2.3 Size of a common block
8.10.2.4 Common association
8.10.2.5 Differences between named common and blank common
8.10.3 Restrictions on common and equivalence
9 Use of data objects
9.1 Designator
9.2 Variable
9.3 Constants
9.4 Scalars
9.4.1 Substrings
9.4.2 Structure components
9.4.3 Coindexed named objects
9.4.4 Complex parts
9.4.5 Type parameter inquiry
9.5 Arrays
9.5.1 Order of reference
9.5.2 Whole arrays
9.5.3 Array elements and array sections
9.5.3.1 Syntax
9.5.3.2 Sequences of subscripts and subscript triplets
9.5.3.3 Array element order
9.5.3.4 Array sections
9.5.3.4.1 Section subscript lists
9.5.3.4.2 Subscript triplet
9.5.3.4.3 Vector subscript
9.5.4 Simply contiguous array designators
9.6 Image selectors
9.7 Dynamic association
9.7.1 ALLOCATE statement
9.7.1.1 Form of the ALLOCATE statement
9.7.1.2 Execution of an ALLOCATE statement
9.7.1.3 Allocation of allocatable variables
9.7.1.4 Allocation of pointer targets
9.7.2 NULLIFY statement
9.7.3 DEALLOCATE statement
9.7.3.1 Form of the DEALLOCATE statement
9.7.3.2 Deallocation of allocatable variables
9.7.3.3 Deallocation of pointer targets
9.7.4 STAT= specifier
9.7.5 ERRMSG= specifier
10 Expressions and assignment
10.1 Expressions
10.1.1 Expression semantics
10.1.2 Form of an expression
10.1.2.1 Overall expression syntax
10.1.2.2 Primary
10.1.2.3 Conditional expressions
10.1.2.4 Level-1 expressions
10.1.2.5 Level-2 expressions
10.1.2.6 Level-3 expressions
10.1.2.7 Level-4 expressions
10.1.2.8 Level-5 expressions
10.1.2.9 General form of an expression
10.1.3 Precedence of operators
10.1.4 Evaluation of operations
10.1.5 Intrinsic operations
10.1.5.1 Intrinsic operation classification
10.1.5.2 Numeric intrinsic operations
10.1.5.2.1 Interpretation of numeric intrinsic operations
10.1.5.2.2 Integer division
10.1.5.2.3 Complex exponentiation
10.1.5.2.4 Evaluation of numeric intrinsic operations
10.1.5.3 Character intrinsic operation
10.1.5.3.1 Interpretation of the character intrinsic operation
10.1.5.3.2 Evaluation of the character intrinsic operation
10.1.5.4 Logical intrinsic operations
10.1.5.4.1 Interpretation of logical intrinsic operations
10.1.5.4.2 Evaluation of logical intrinsic operations
10.1.5.5 Relational intrinsic operations
10.1.5.5.1 Interpretation of relational intrinsic operations
10.1.5.5.2 Evaluation of relational intrinsic operations
10.1.6 Defined operations
10.1.6.1 Definitions
10.1.6.2 Interpretation of a defined operation
10.1.6.3 Evaluation of a defined operation
10.1.7 Evaluation of operands
10.1.8 Integrity of parentheses
10.1.9 Type, type parameters, and shape of an expression
10.1.9.1 General
10.1.9.2 Type, type parameters, and shape of a primary
10.1.9.3 Type, type parameters, and shape of the result of an operation
10.1.10 Conformability rules for elemental operations
10.1.11 Specification expression
10.1.12 Constant expression
10.2 Assignment
10.2.1 Assignment statement
10.2.1.1 General form
10.2.1.2 Intrinsic assignment statement
10.2.1.3 Interpretation of intrinsic assignments
10.2.1.4 Defined assignment statement
10.2.1.5 Interpretation of defined assignment statements
10.2.2 Pointer assignment
10.2.2.1 General
10.2.2.2 Syntax of the pointer assignment statement
10.2.2.3 Data pointer assignment
10.2.2.4 Procedure pointer assignment
10.2.2.5 Examples of pointer assignment statements
10.2.3 Masked array assignment − WHERE
10.2.3.1 General form of the masked array assignment
10.2.3.2 Interpretation of masked array assignments
10.2.4 FORALL
10.2.4.1 Form of the FORALL Construct
10.2.4.2 Execution of the FORALL construct
10.2.4.2.1 Execution stages
10.2.4.2.2 Determination of the values for index variables
10.2.4.2.3 Evaluation of the mask expression
10.2.4.2.4 Execution of the FORALL body constructs
10.2.4.3 The FORALL statement
10.2.4.4 Restrictions on FORALL constructs and statements
11 Execution control
11.1 Executable constructs containing blocks
11.1.1 Blocks
11.1.2 Rules governing blocks
11.1.2.1 Control flow in blocks
11.1.2.2 Execution of a block
11.1.3 ASSOCIATE construct
11.1.3.1 Purpose and form of the ASSOCIATE construct
11.1.3.2 Execution of the ASSOCIATE construct
11.1.3.3 Other attributes of associate names
11.1.3.4 Examples of the ASSOCIATE construct
11.1.4 BLOCK construct
11.1.5 CHANGE TEAM construct
11.1.5.1 Purpose and form of the CHANGE TEAM construct
11.1.5.2 Execution of a CHANGE TEAM construct
11.1.6 CRITICAL construct
11.1.7 DO construct
11.1.7.1 Purpose and form of the DO construct
11.1.7.2 Form of the DO construct
11.1.7.3 Active and inactive DO constructs
11.1.7.4 Execution of a DO construct
11.1.7.4.1 Loop initiation
11.1.7.4.2 DO CONCURRENT loop control
11.1.7.4.3 The execution cycle
11.1.7.4.4 CYCLE statement
11.1.7.4.5 Loop termination
11.1.7.5 Additional semantics for DO CONCURRENT constructs
11.1.7.6 Examples of DO constructs
11.1.8 IF construct and statement
11.1.8.1 Purpose and form of the IF construct
11.1.8.2 Execution of an IF construct
11.1.8.3 Examples of IF constructs
11.1.8.4 IF statement
11.1.9 SELECT CASE construct
11.1.9.1 Purpose and form of the SELECT CASE construct
11.1.9.2 Execution of a SELECT CASE construct
11.1.9.3 Examples of SELECT CASE constructs
11.1.10 SELECT RANK construct
11.1.10.1 Purpose and form of the SELECT RANK construct
11.1.10.2 Execution of the SELECT RANK construct
11.1.10.3 Attributes of a SELECT RANK associate name
11.1.10.4 Examples of the SELECT RANK construct
11.1.11 SELECT TYPE construct
11.1.11.1 Purpose and form of the SELECT TYPE construct
11.1.11.2 Execution of the SELECT TYPE construct
11.1.11.3 Examples of the SELECT TYPE construct
11.1.12 EXIT statement
11.2 Branching
11.2.1 Branch concepts
11.2.2 GO TO statement
11.2.3 Computed GO TO statement
11.3 CONTINUE statement
11.4 STOP and ERROR STOP statements
11.5 FAIL IMAGE statement
11.6 NOTIFY WAIT statement
11.7 Image execution control
11.7.1 Image control statements
11.7.2 Segments
11.7.3 SYNC ALL statement
11.7.4 SYNC IMAGES statement
11.7.5 SYNC MEMORY statement
11.7.6 SYNC TEAM statement
11.7.7 EVENT POST statement
11.7.8 EVENT WAIT statement
11.7.9 FORM TEAM statement
11.7.10 LOCK and UNLOCK statements
11.7.11 STAT= and ERRMSG= specifiers in image control statements
12 Input/output statements
12.1 Input/output concepts
12.2 Records
12.2.1 Definition of a record
12.2.2 Formatted record
12.2.3 Unformatted record
12.2.4 Endfile record
12.3 External files
12.3.1 External file concepts
12.3.2 File existence
12.3.3 File access
12.3.3.1 File access methods
12.3.3.2 Sequential access
12.3.3.3 Direct access
12.3.3.4 Stream access
12.3.4 File position
12.3.4.1 General
12.3.4.2 Advancing and nonadvancing input/output
12.3.4.3 File position prior to data transfer
12.3.4.4 File position after data transfer
12.3.5 File storage units
12.4 Internal files
12.5 File connection
12.5.1 Referring to a file
12.5.2 Connection modes
12.5.3 Unit existence
12.5.4 Connection of a file to a unit
12.5.5 Preconnection
12.5.6 OPEN statement
12.5.6.1 General
12.5.6.2 Syntax of the OPEN statement
12.5.6.3 ACCESS= specifier in the OPEN statement
12.5.6.4 ACTION= specifier in the OPEN statement
12.5.6.5 ASYNCHRONOUS= specifier in the OPEN statement
12.5.6.6 BLANK= specifier in the OPEN statement
12.5.6.7 DECIMAL= specifier in the OPEN statement
12.5.6.8 DELIM= specifier in the OPEN statement
12.5.6.9 ENCODING= specifier in the OPEN statement
12.5.6.10 FILE= specifier in the OPEN statement
12.5.6.11 FORM= specifier in the OPEN statement
12.5.6.12 LEADING_ZERO= specifier in the OPEN statement
12.5.6.13 NEWUNIT= specifier in the OPEN statement
12.5.6.14 PAD= specifier in the OPEN statement
12.5.6.15 POSITION= specifier in the OPEN statement
12.5.6.16 RECL= specifier in the OPEN statement
12.5.6.17 ROUND= specifier in the OPEN statement
12.5.6.18 SIGN= specifier in the OPEN statement
12.5.6.19 STATUS= specifier in the OPEN statement
12.5.7 CLOSE statement
12.5.7.1 General
12.5.7.2 Syntax
12.5.7.3 STATUS= specifier in the CLOSE statement
12.6 Data transfer statements
12.6.1 Form of input and output statements
12.6.2 Control information list
12.6.2.1 Syntax
12.6.2.2 Format specification in a data transfer statement
12.6.2.3 NML= specifier in a data transfer statement
12.6.2.4 ADVANCE= specifier in a data transfer statement
12.6.2.5 ASYNCHRONOUS= specifier in a data transfer statement
12.6.2.6 BLANK= specifier in a data transfer statement
12.6.2.7 DECIMAL= specifier in a data transfer statement
12.6.2.8 DELIM= specifier in a data transfer statement
12.6.2.9 ID= specifier in a data transfer statement
12.6.2.10 LEADING_ZERO= specifier in a data transfer statement
12.6.2.11 PAD= specifier in a data transfer statement
12.6.2.12 POS= specifier in a data transfer statement
12.6.2.13 REC= specifier in a data transfer statement
12.6.2.14 ROUND= specifier in a data transfer statement
12.6.2.15 SIGN= specifier in a data transfer statement
12.6.2.16 SIZE= specifier in a data transfer statement
12.6.3 Data transfer input/output list
12.6.4 Execution of a data transfer input/output statement
12.6.4.1 Data transfer sequence of operations
12.6.4.2 Direction of data transfer
12.6.4.3 Identifying a unit
12.6.4.4 Establishing a format
12.6.4.5 Data transfer
12.6.4.5.1 General
12.6.4.5.2 Unformatted data transfer
12.6.4.5.3 Formatted data transfer
12.6.4.6 List-directed formatting
12.6.4.7 Namelist formatting
12.6.4.8 Defined input/output
12.6.4.8.1 General
12.6.4.8.2 Defined input/output procedures
12.6.4.8.3 Executing defined input/output data transfers
12.6.4.8.4 Resolving defined input/output procedure references
12.6.5 Termination of data transfer statements
12.7 Waiting on pending data transfer
12.7.1 Wait operation
12.7.2 WAIT statement
12.8 File positioning statements
12.8.1 Syntax
12.8.2 BACKSPACE statement
12.8.3 ENDFILE statement
12.8.4 REWIND statement
12.9 FLUSH statement
12.10 File inquiry statement
12.10.1 Forms of the INQUIRE statement
12.10.2 Inquiry specifiers
12.10.2.1 Syntax
12.10.2.2 FILE= specifier in the INQUIRE statement
12.10.2.3 ACCESS= specifier in the INQUIRE statement
12.10.2.4 ACTION= specifier in the INQUIRE statement
12.10.2.5 ASYNCHRONOUS= specifier in the INQUIRE statement
12.10.2.6 BLANK= specifier in the INQUIRE statement
12.10.2.7 DECIMAL= specifier in the INQUIRE statement
12.10.2.8 DELIM= specifier in the INQUIRE statement
12.10.2.9 DIRECT= specifier in the INQUIRE statement
12.10.2.10 ENCODING= specifier in the INQUIRE statement
12.10.2.11 EXIST= specifier in the INQUIRE statement
12.10.2.12 FORM= specifier in the INQUIRE statement
12.10.2.13 FORMATTED= specifier in the INQUIRE statement
12.10.2.14 ID= specifier in the INQUIRE statement
12.10.2.15 LEADING_ZERO= specifier in the INQUIRE statement
12.10.2.16 NAME= specifier in the INQUIRE statement
12.10.2.17 NAMED= specifier in the INQUIRE statement
12.10.2.18 NEXTREC= specifier in the INQUIRE statement
12.10.2.19 NUMBER= specifier in the INQUIRE statement
12.10.2.20 OPENED= specifier in the INQUIRE statement
12.10.2.21 PAD= specifier in the INQUIRE statement
12.10.2.22 PENDING= specifier in the INQUIRE statement
12.10.2.23 POS= specifier in the INQUIRE statement
12.10.2.24 POSITION= specifier in the INQUIRE statement
12.10.2.25 READ= specifier in the INQUIRE statement
12.10.2.26 READWRITE= specifier in the INQUIRE statement
12.10.2.27 RECL= specifier in the INQUIRE statement
12.10.2.28 ROUND= specifier in the INQUIRE statement
12.10.2.29 SEQUENTIAL= specifier in the INQUIRE statement
12.10.2.30 SIGN= specifier in the INQUIRE statement
12.10.2.31 SIZE= specifier in the INQUIRE statement
12.10.2.32 STREAM= specifier in the INQUIRE statement
12.10.2.33 UNFORMATTED= specifier in the INQUIRE statement
12.10.2.34 WRITE= specifier in the INQUIRE statement
12.10.3 Inquire by output list
12.11 Error, end-of-record, and end-of-file conditions
12.11.1 Occurrence of input/output conditions
12.11.2 Error conditions and the ERR= specifier
12.11.3 End-of-file condition and the END= specifier
12.11.4 End-of-record condition and the EOR= specifier
12.11.5 IOSTAT= specifier
12.11.6 IOMSG= specifier
12.12 Restrictions on input/output statements
13 Input/output editing
13.1 Format specifications
13.2 Explicit format specification methods
13.2.1 FORMAT statement
13.2.2 Character format specification
13.3 Form of a format item list
13.3.1 Syntax
13.3.2 Edit descriptors
13.3.3 Fields
13.4 Interaction between input/output list and format
13.5 Positioning by format control
13.6 Decimal symbol
13.7 Data edit descriptors
13.7.1 Purpose of data edit descriptors
13.7.2 Numeric editing
13.7.2.1 General rules
13.7.2.2 Integer editing
13.7.2.3 Real and complex editing
13.7.2.3.1 General
13.7.2.3.2 F editing
13.7.2.3.3 E and D editing
13.7.2.3.4 EN editing
13.7.2.3.5 ES editing
13.7.2.3.6 EX editing
13.7.2.3.7 Complex editing
13.7.2.3.8 Input/output rounding mode
13.7.2.4 B, O, and Z editing
13.7.3 Logical editing
13.7.4 Character editing
13.7.5 Generalized editing
13.7.5.1 Overview
13.7.5.2 Generalized numeric editing
13.7.5.2.1 Overview
13.7.5.2.2 Generalized integer and enum editing
13.7.5.2.3 Generalized real and complex editing
13.7.5.3 Generalized logical editing
13.7.5.4 Generalized character editing
13.7.6 User-defined derived-type editing
13.8 Control edit descriptors
13.8.1 Position edit descriptors
13.8.1.1 Position editing
13.8.1.2 T, TL, and TR editing
13.8.1.3 X editing
13.8.2 Slash editing
13.8.3 Colon editing
13.8.4 SS, SP, and S editing
13.8.5 LZS, LZP and LZ editing
13.8.6 P editing
13.8.7 BN and BZ editing
13.8.8 RU, RD, RZ, RN, RC, and RP editing
13.8.9 DC and DP editing
13.9 Character string edit descriptors
13.10 List-directed formatting
13.10.1 Purpose of list-directed formatting
13.10.2 Values and value separators
13.10.3 List-directed input
13.10.3.1 List-directed input forms
13.10.3.2 Null values
13.10.4 List-directed output
13.11 Namelist formatting
13.11.1 Purpose of namelist formatting
13.11.2 Name-value subsequences
13.11.3 Namelist input
13.11.3.1 Overall syntax
13.11.3.2 Namelist input processing
13.11.3.3 Namelist input values
13.11.3.4 Null values
13.11.3.5 Blanks
13.11.3.6 Namelist comments
13.11.4 Namelist output
13.11.4.1 Form of namelist output
13.11.4.2 Namelist output editing
13.11.4.3 Namelist output records
14 Program units
14.1 Main program
14.2 Modules
14.2.1 Module syntax and semantics
14.2.2 The USE statement and use association
14.2.3 Submodules
14.3 Block data program units
15 Procedures
15.1 Concepts
15.2 Procedure classifications
15.2.1 Procedure classification by reference
15.2.2 Procedure classification by means of definition
15.2.2.1 Intrinsic procedures
15.2.2.2 External, internal, and module procedures
15.2.2.3 Dummy procedures
15.2.2.4 Procedure pointers
15.2.2.5 Statement functions
15.3 Characteristics
15.3.1 Characteristics of procedures
15.3.2 Characteristics of dummy arguments
15.3.2.1 General
15.3.2.2 Characteristics of dummy data objects
15.3.2.3 Characteristics of dummy procedures
15.3.2.4 Characteristics of asterisk dummy arguments
15.3.3 Characteristics of function results
15.4 Procedure interface
15.4.1 Interface and abstract interface
15.4.2 Implicit and explicit interfaces
15.4.2.1 Interfaces and scopes
15.4.2.2 Explicit interface
15.4.3 Specification of the procedure interface
15.4.3.1 General
15.4.3.2 Interface block
15.4.3.3 GENERIC statement
15.4.3.4 Generic interfaces
15.4.3.4.1 Generic identifiers
15.4.3.4.2 Defined operations
15.4.3.4.3 Defined assignments
15.4.3.4.4 Defined input/output procedure interfaces
15.4.3.4.5 Restrictions on generic declarations
15.4.3.5 EXTERNAL statement
15.4.3.6 Procedure declaration statement
15.4.3.7 INTRINSIC statement
15.4.3.8 Implicit interface specification
15.5 Procedure reference
15.5.1 Syntax of a procedure reference
15.5.2 Actual arguments, dummy arguments, and argument association
15.5.2.1 Argument correspondence
15.5.2.2 The passed-object dummy argument and argument correspondence
15.5.2.3 Conditional argument correspondence
15.5.2.4 Argument association
15.5.2.5 Ordinary dummy variables
15.5.2.6 Allocatable and pointer dummy variables
15.5.2.7 Allocatable dummy variables
15.5.2.8 Pointer dummy variables
15.5.2.9 Coarray dummy variables
15.5.2.10 Actual arguments associated with dummy procedure entities
15.5.2.11 Actual arguments and alternate return indicators
15.5.2.12 Sequence association
15.5.2.13 Argument presence and restrictions on arguments not present
15.5.2.14 Restrictions on entities associated with dummy arguments
15.5.3 Function reference
15.5.4 Subroutine reference
15.5.5 Resolving named procedure references
15.5.5.1 Establishment of procedure names
15.5.5.2 Resolving procedure references to names established to be generic
15.5.5.3 Resolving procedure references to names established to be only specific
15.5.5.4 Resolving procedure references to names not established
15.5.6 Resolving type-bound procedure references
15.6 Procedure definition
15.6.1 Intrinsic procedure definition
15.6.2 Procedures defined by subprograms
15.6.2.1 General
15.6.2.2 Function subprogram
15.6.2.3 Subroutine subprogram
15.6.2.4 Instances of a subprogram
15.6.2.5 Separate module procedures
15.6.2.6 ENTRY statement
15.6.2.7 RETURN statement
15.6.2.8 CONTAINS statement
15.6.3 Definition and invocation of procedures by means other than Fortran
15.6.4 Statement function
15.7 Pure procedures
15.8 Simple procedures
15.9 Elemental procedures
15.9.1 Elemental procedure declaration and interface
15.9.2 Elemental function actual arguments and results
15.9.3 Elemental subroutine actual arguments
16 Intrinsic procedures and modules
16.1 Classes of intrinsic procedures
16.2 Arguments to intrinsic procedures
16.2.1 General rules
16.2.2 The shape of array arguments
16.2.3 Mask arguments
16.2.4 DIM arguments and reduction functions
16.3 Bit model
16.3.1 General
16.3.2 Bit sequence comparisons
16.3.3 Bit sequences as arguments to INT and REAL
16.4 Numeric models
16.5 Atomic subroutines
16.6 Collective subroutines
16.7 Standard generic intrinsic procedures
16.8 Specific names for standard intrinsic functions
16.9 Specifications of the standard intrinsic procedures
16.9.1 General
16.9.2 ABS (A)
16.9.3 ACHAR (I [, KIND])
16.9.4 ACOS (X)
16.9.5 ACOSD (X)
16.9.6 ACOSH (X)
16.9.7 ACOSPI (X)
16.9.8 ADJUSTL (STRING)
16.9.9 ADJUSTR (STRING)
16.9.10 AIMAG (Z)
16.9.11 AINT (A [, KIND])
16.9.12 ALL (MASK) or ALL (MASK, DIM)
16.9.13 ALLOCATED (ARRAY) or ALLOCATED (SCALAR)
16.9.14 ANINT (A [, KIND])
16.9.15 ANY (MASK) or ANY (MASK, DIM)
16.9.16 ASIN (X)
16.9.17 ASIND (X)
16.9.18 ASINH (X)
16.9.19 ASINPI (X)
16.9.20 ASSOCIATED (POINTER [, TARGET])
16.9.21 ATAN (X) or ATAN (Y, X)
16.9.22 ATAN2 (Y, X)
16.9.23 ATAN2D (Y, X)
16.9.24 ATAN2PI (Y, X)
16.9.25 ATAND (X) or ATAND (Y, X)
16.9.26 ATANH (X)
16.9.27 ATANPI (X) or ATANPI (Y, X)
16.9.28 ATOMIC_ADD (ATOM, VALUE [, STAT])
16.9.29 ATOMIC_AND (ATOM, VALUE [, STAT])
16.9.30 ATOMIC_CAS (ATOM, OLD, COMPARE, NEW [, STAT])
16.9.31 ATOMIC_DEFINE (ATOM, VALUE [, STAT])
16.9.32 ATOMIC_FETCH_ADD (ATOM, VALUE, OLD [, STAT])
16.9.33 ATOMIC_FETCH_AND (ATOM, VALUE, OLD [, STAT])
16.9.34 ATOMIC_FETCH_OR (ATOM, VALUE, OLD [, STAT])
16.9.35 ATOMIC_FETCH_XOR (ATOM, VALUE, OLD [, STAT])
16.9.36 ATOMIC_OR (ATOM, VALUE [, STAT])
16.9.37 ATOMIC_REF (VALUE, ATOM [, STAT])
16.9.38 ATOMIC_XOR (ATOM, VALUE [, STAT])
16.9.39 BESSEL_J0 (X)
16.9.40 BESSEL_J1 (X)
16.9.41 BESSEL_JN (N, X) or BESSEL_JN (N1, N2, X)
16.9.42 BESSEL_Y0 (X)
16.9.43 BESSEL_Y1 (X)
16.9.44 BESSEL_YN (N, X) or BESSEL_YN (N1, N2, X)
16.9.45 BGE (I, J)
16.9.46 BGT (I, J)
16.9.47 BIT_SIZE (I)
16.9.48 BLE (I, J)
16.9.49 BLT (I, J)
16.9.50 BTEST (I, POS)
16.9.51 CEILING (A [, KIND])
16.9.52 CHAR (I [, KIND])
16.9.53 CMPLX (X [, KIND]) or CMPLX (X [, Y, KIND])