FPT and WinFPT Reference Manual - Command-line Commands

| SimCon Home | Reference Manual Home |


STRING

Syntax:

!% STRING [:] [:] <symbol> [ , <symbol> ... ]

!% ADDRESS AND LENGTH [:] [:] <symbol> [ , <symbol> ... ]

Function:

Specifies that the named sub-program arguments are passed as strings in the conventional Unix Fortran manner. When the sub-program is called, each string argument is passed as two separate tokens, one which contains the address of the string, and another which contains the length. FPT uses this information in the argument consistency check (please see CHECK ARGUMENTS). The alternative protocol specifications for arguments are:

   !% VALUE
   !% REFERENCE
   !% DESCRIPTOR
   !% ADDRESS AND LENGTH

Names which contain exotic characters such as' %', : 'or' # (which are all legal on some systems) must be written as quoted strings.

The %STRING command must be written in code within the scope of declaration of the variable.

Where to use this command:

Operating system command line

No


Configuration file, config.fsp

No


Specification (FSP) files, *.fsp

No


Interactively, to FPT> prompt:

No


Interactive command files

No


Embedded in the Fortran code

Yes


Default:

By default, CHARACTER arguments are assumed to be passed by address and length and numeric arguments are assumed to be passed by reference.

Example:

SUBROUTINE repval(namea,vala) REAL*4 vala CHARACTER*16 namea !% ADDRESS AND LENGTH :: namea

See also:

CHECK ARGUMENTS

PASS STRING ARGUMENTS


Copyright ©1995 to 2014 Software Validation Ltd. All rights reserved.