HPlogo HP/DDE Debugger User's Guide: HP 9000 Series 700/800 Computers > Appendix B Language Managers

FORTRAN Language Manager

» 

Technical documentation

Complete book in PDF

 » Table of Contents

 » Glossary

 » Index

Type Name

lang_ftn

Description

In general, this manager supports the FORTRAN expressions and declarations described in the FORTRAN language reference manual for your system, plus the debugging extensions listed under "Syntax."

Title

FORTRAN

Syntax

  • declaration

    A declaration of a variable, restricted to the following syntax:

    • [external] type_name {identifier[(integer)]},...

      type_name:   INTEGER
      INTEGER*2
      INTEGER*4
      INTEGER*8
      REAL
      REAL*4
      REAL*8
      REAL*16
      DOUBLE PRECISION
      COMPLEX
      COMPLEX*8
      DOUBLE COMPLEX
      COMPLEX*16
      LOGICAL
      LOGICAL*1
      LOGICAL*2
      LOGICAL*4
      BYTE
      CHARACTER
      CHARACTER*nnn

    A declaration of a record variable whose form was previously declared in a STRUCTURE statement:

    RECORD/struc_name/[variable_name | array_name | array_declarator]

    A declaration of a derived type whose form was previously declared in a TYPE definition:

    TYPE(dtype_name)[, attribute_list DOUBLECOLON] entity_list
  • expression

    A FORTRAN expression constructed from the operators, identifiers, constants, intrinsic functions, and extensions listed in this section.

    Operators

    Arithmetic

    +, -, *, /, **

    Relational

    .eq., .ne., .lt., .le., .gt., .ge.

    Logical

    .not., .or., .and., .eqv., .neqv.

    String

    //, (:)

    Assignment

    =

    Array indexing

    (,)

    Grouping

    ()

    Member reference

    ., %

    Declaration

    ::

    Identifiers

    Identifiers are not case sensitive and must start with a letter (ISO Latin-1 decimal values 65-90 and 97-122); any additional characters can be a letter, digit (0-9), dollar sign ($), or underscore (_).

    Constants

    Integer

    digits (decimal)

    [radix#]digits[_KS] (radix= 2, 8, 10, 16; KS =1, 2, 4, 8)

    For example, 16#1c6 specifies a hexadecimal integer.

    Real

    digits.digits[_KS][E[+|-]digits](KS = 4,8,16)

    digits.digits[{D|Q}[+|-]digits]

    digits.[_KS][E[+|-]digits](KS = 4,8,16)

    digits.[{D|Q}[+|-]digits]

    .digits[_KS][E[+|-]digits]

    .digits[{D|Q}[+|-]digits]

    For example, 3.5D0 specifies a double-precision number.

    Complex

    (number,number)

    Logical

    .TRUE. .FALSE.

    Character string

    'characters'

    Intrinsic Functions

    ABS
    AIMAG
    AINT
    AMOD
    ANINT
    CHAR
    CMPLX
    DABS
    DBLE
    DINT
    DMOD
    DNINT
    EXP
    FLOAT
    IABS
    ICHAR
    IDINT
    IDNINT
    IFIX
    INT
    LOC
    MOD
    NINT
    REAL
    SNGL

    Debugger Extensions

    iaddr() Address
    location\identifierName identifier visible from the
    scope location
    `va(address) Virtual address address
    (typename) expressionType conversion
    `long(expression) Cast the resulting value of expression to type INTEGER*4
    `short(expression) Cast the resulting value of expression to type INTEGER*2
    Array slices In place of an array subscript, you can give a range of elements:
     : Lower bound to upper bound
     expr1:expr2Given range
     :exprLower bound to given expr
     expr: Given expr to upper bound
     :: Lower bound to upper bound,
    stride of 1
     ::exprLower bound to upper bound,
    stride of expr
     expr1:expr2: Given range, stride of 1
     expr1:expr2:expr3Given range, stride of expr3
     :expr2:expr3Lower bound to expr2, stride of
    expr3
     expr1::expr3Given expr1 to upper bound,
    stride of expr3
     Example: print table(::, 30:60:5)

  • language_type

    {lang_ftn|fortran|ftn|f77|f90}

  • manager_option

    None.

Startup File

None.

Related Managers

None.