02.07.2014 Views

Intel(R) Fortran Language Reference (online version)

Intel(R) Fortran Language Reference (online version)

Intel(R) Fortran Language Reference (online version)

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Execution Control 7<br />

INTEGER L(20)<br />

COMPLEX Z1<br />

CALL TEST_C(I, L, J, KYWD1 = K, KYWD2 = Z1)<br />

...<br />

The first three actual arguments are associated with their corresponding dummy arguments by<br />

position. The argument keywords are associated by keyword name, so they can appear in any<br />

order.<br />

Note that the interface to subroutine TEST has two optional arguments that have been omitted in<br />

the CALL statement.<br />

The following is another example of a subroutine call with argument keywords:<br />

CALL TEST(X, Y, N, EQUALITIES = Q, XSTART = X0)<br />

The first three arguments are associated by position.<br />

See Also<br />

• “Subroutines”<br />

• “Argument Association” for details on procedure arguments<br />

• “OPTIONAL Attribute and Statement” for details on optional arguments<br />

• “Dummy Procedure Arguments” for details on dummy arguments<br />

• Appendix A, “Deleted and Obsolescent <strong>Language</strong> Features”, for details on obsolescent<br />

features in <strong>Fortran</strong> 95 and <strong>Fortran</strong> 90<br />

CASE Constructs<br />

The CASE construct conditionally executes one block of constructs or statements depending on<br />

the value of a scalar expression in a SELECT CASE statement.<br />

The CASE construct takes the following form:<br />

[name:] SELECT CASE (expr)<br />

[CASE (case-value [, case-value]...) [name]<br />

block]...<br />

[CASE DEFAULT [name]<br />

block]<br />

END SELECT [name]<br />

name<br />

Is the name of the CASE construct.<br />

7-9

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!