Fortran is currently the world's most powerful numeric language and F is a subset of this. F is a programming language which is nearly as powerful as its parent language, containing the modern language features of Fortran, yet smaller and easier to use, debug and teach than Fortran. As with his previous Fortran books, Wilhelm Gehrke has provided a clear and comprehensive guide to the F language in this book which will be welcomed by practitioners and students alike. The F Language Guide will serve as a language reference manual for the novice as well as for the experienced programmer, as teaching material for courses in F programming, and in programming methodology. The guide concentrates on the description of the language as a programmers' tool. A representation of the F Syntax using railroad diagrams will be available on the Springer server at http://www.springer.co.uk/
Inhalt
1 Source Form.- 1.1 Classification of F Statements.- 1.2 Statement Ordering.- 2 Type Concept.- 2.1 Intrinsic Types.- 2.1.1 Integer Type.- 2.1.2 Real Type.- 2.1.3 Complex Type.- 2.1.4 Logical Type.- 2.1.5 Character Type.- 2.2 Derived Types.- 2.2.1 Derived Type Definition.- 2.2.1.1 Type Component Definition.- 2.2.1.2 Private/Public Derived Types and Components.- 2.2.2 Structure Objects.- 3 Lexical Tokens.- 3.1 Scoping Units.- 3.2 Keywords.- 3.3 Names.- 3.4 Operators and Assignment Symbol.- 3.5 Literal Constants.- 3.5.1 Integer Literal Constants.- 3.5.2 Real Literal Constants.- 3.5.3 Complex Literal Constants.- 3.5.4 Logical Literal Constants.- 3.5.5 Character Literal Constants.- 4 Data Objects.- 4.1 Constants.- 4.2 Variables.- 4.3 Scalars.- 4.3.1 Character Substrings.- 4.4 Arrays.- 4.4.1 Inner Structure of Arrays.- 4.5 Structure Components.- 4.6 Automatic Variables.- 4.7 Association.- 4.7.1 Name Association.- 4.7.2 Pointer Association.- 4.8 Definition Status.- 5 Pointers.- 5.1 Pointer Concept.- 5.2 Pointer Processing.- 5.2.1 Creation of Pointer Targets.- 5.2.2 Association Status.- 5.2.3 Deallocation of Pointer Targets.- 5.2.4 Nullification of Pointer Associations.- 6 Array Processing.- 6.1 Array Declaration.- 6.1.1 Explicit-Shape Arrays.- 6.1.2 Assumed-Shape Arrays.- 6.2 Reference and Use.- 6.2.1 Whole Arrays.- 6.2.2 Array Elements.- 6.2.3 Array Sections.- 6.2.3.1 Subscript-Triplet.- 6.2.3.2 Vector-Subscript.- 6.2.3.3 Array Sections of Substrings.- 6.3 Memory Management and Dynamic Control.- 6.3.1 Automatic Arrays.- 6.3.2 Allocatable Arrays.- 6.3.3 Array Pointers.- 6.4 Array Constructor.- 6.5 Operations on Arrays.- 6.5.1 Array Expressions.- 6.5.2 Array Subprograms.- 6.5.3 Array Assignments.- 7 Expressions.- 7.1 Numeric Intrinsic Expressions.- 7.2 Relational Intrinsic Expressions.- 7.2.1 Numeric Relational Intrinsic Expressions.- 7.2.2 Character Relational Intrinsic Expressions.- 7.3 Logical Intrinsic Expressions.- 7.4 Character Intrinsic Expressions.- 7.5 Defined Expressions.- 7.5.1 Defined Operators and Extended Intrinsic Operators.- 7.5.1.1 Nonextended Defined Operator.- 7.5.1.2 Extended Defined Operator.- 7.5.1.3 Extended Intrinsic Operator.- 7.6 Common Rules for Expressions.- 7.6.1 Precedence of Operators.- 7.6.2 Interpretation of Expressions.- 7.6.3 Evaluation of Expressions.- 7.7 Special Expressions.- 7.7.1 Constant Expressions.- 7.7.2 Initialization Expressions.- 7.7.3 Specification Expressions.- 8 Assignments.- 8.1 Intrinsic Assignment Statements.- 8.1.1 Numeric Assignment Statement.- 8.1.2 Logical Assignment Statement.- 8.1.3 Character Assignment Statement.- 8.1.4 Assignment Statement for Derived Types.- 8.2 Defined Assignment Statements.- 8.2.1 Nonextended Defined Assignment.- 8.2.2 Extended Defined Assignment.- 8.3 Pointer Assignment Statement.- 8.4 Masked Array Assignments.- 8.4.1 WHERE Construct.- 8.4.2 Common Rules for Masked Array Assignments.- 9 Declarations and Specifications.- 9.1 Attributes.- 9.1.1 ALLOCATABLE Attribute.- 9.1.2 Initial Value.- 9.1.3 DIMENSION Attribute.- 9.1.4 INTENT Attribute.- 9.1.5 OPTIONAL Attribute.- 9.1.6 PARAMETER Attribute.- 9.1.7 POINTER Attribute.- 9.1.8 PRIVATE Attribute.- 9.1.9 PUBLIC Attribute.- 9.1.10 SAVE Attribute.- 9.1.11 TARGET Attribute.- 9.2 Type Declaration Statements.- 9.2.1 INTEGER Statement.- 9.2.2 REAL Statement.- 9.2.3 COMPLEX Statement.- 9.2.4 LOGICAL Statement.- 9.2.5 CHARACTER Statement.- 9.2.5.1 Length Specification.- 9.2.6 TYPE Declaration Statement.- 9.3 Additional Specification Statements.- 9.3.1 PRIVATE Statement.- 9.3.2 PUBLIC Statement.- 9.3.3 IMPLICIT Statement.- 9.3.4 INTRINSIC Statement.- 10 Execution Control.- 10.1 IF Construct.- 10.1.1 Simple IF Constructs.- 10.1.2 Nested IF Constructs.- 10.2 CASE Construct.- 10.2.1 Simple CASE Constructs.- 10.3 DO Construct.- 10.3.1 DO Statement.- 10.3.2 END DO Statement.- 10.3.3 Forms of DO Constructs.- 10.3.4 Execution of a DO Construct.- 10.3.4.1 Additional Details about Count Loops.- 10.3.4.2 Additional Details about Endless Loops.- 10.3.4.3 CYCLE Statement and EXIT Statement.- 10.4 Nested Constructs.- 10.5 STOP Statement.- 11 Input/Output.- 11.1 Records.- 11.2 Files.- 11.3 File Attributes of External Files.- 11.3.1 File Names.- 11.3.2 Access Methods.- 11.3.2.1 Sequential Access.- 11.3.2.2 Direct Access.- 11.3.3 Form of a File.- 11.3.4 File Position.- 11.4 Units.- 11.5 Preconnected Units and Predefined Files.- 11.6 Input/Output Statements.- 11.6.1 Input/Output Specifiers.- 11.6.1.1 UNIT= Specifier.- 11.6.1.2 FMT= Specifier.- 11.6.1.3 REC= Specifier.- 11.6.1.4 ADVANCE= Specifier.- 11.6.1.5 End-of-Record Condition.- 11.6.1.6 IOSTAT= Specifier.- 11.6.1.7 Error Conditions.- 11.6.1.8 End-of-File Condition.- 11.6.1.9 SIZE= Specifier.- 11.6.2 Input/Output Lists.- 11.6.3 Data Transfer Statements.- 11.6.3.1 Formatted Input/Output.- 11.6.3.2 Unformatted Input/Output.- 11.6.3.3 List-Directed Input/Output.- 11.6.3.4 Internal Input/Output.- 11.6.3.5 Nonadvancing Input/Output.- 11.6.3.6 Printing.- 11.6.4 File Status Statements.- 11.6.4.1 OPEN Statement.- 11.6.4.2 CLOSE Statement.- 11.6.4.3 INQUIRE Statement.- 11.6.5 File Positioning Statements.- 12 Formats.- 12.1 Format Specification.- 12.2 Interaction between Input/Output List and Format.- 12.2.1 Repeat Specification, Groups of Edit Descriptors.- 12.2.2 Reversion of Format Control.- 12.3 Edit Descriptors.- 12.3.1 A Edit Descriptors.- 12.3.2 Colon Edit Descriptors.- 12.3.3 ES DO Edit Descriptors.- 12.3.4 F Edit Descriptors.- 12.3.5 I Edit Descriptors.- 12.3.6 L Edit Descriptors.- 12.3.7 Sign Control Edit Descriptors.- 12.3.8 Slash Edit Descriptors.- 12.3.9 Tabulator Edit Descriptors.- 13 Program Units and Subprograms.- 13.1 Main Program.- 13.2 Modules.- 13.2.1 USE Statement.- 13.2.2 Typical applications.- 13.3 Subprograms.- 13.3.1 Module Functions.- 13.3.1.1 Function Definition.- 13.3.1.2 Explicit Function Reference, Invocation.- 13.3.1.3 Operator Functions.- 13.3.2 Module Subroutines.- 13.3.2.1 Subroutine Definition.- 13.3.2.2 Explicit Subroutine Reference, CALL Statement.- 13.3.2.3 Assignment Subroutines.- 13.3.3 External Subprograms.- 13.3.4 Dummy Subprograms.- 13.3.5 Interface Blocks.- 13.3.6 Overloaded Generic Subprogram Names.- 13.3.7 Return from an Invoked Module Subprogram.- 13.4 Internal Program Communication.- 13.4.1 Argument Lists.- 13.4.1.1 Dummy Argument List.- 13.4.1.2 Actual Argument List.- 13.4.2 Argument Association.- 13.4.2.1 Data Objects as Dummy Arguments.- 13.4.2.2 Implicit Association of Two Dummy Arguments.- 13.4.2.3 Length of Character Dummy Arguments.- 13.4.2.4 Scalar Arguments.- 13.4.2.5 Dummy (Argument) Arrays.- 13.4.2.6 Dummy (Argument) Pointers.- 13.4.2.7 Restrictions on the Association of Data Entities.- 13.4.2.8 Dummy Subprograms.- 13.4.3 Optional Dummy Arguments.- 13.4.4 Dummy Argument with INTENT Attribute.- 14 Intrinsic Subprograms.- 14.1 Intrinsic Functions.- 14.1.1 Table of Intrinsic Functions.- 14.2 Intrinsic Subroutines.- 14.3 Intrinsic Subprogram Reference.- 14.4 Intrinsic Subprogram Definitions.- Appendices.- A ASCII Character Set and Collating Sequence.-…