NCEPLIBS-w3emc 2.12.0
Loading...
Searching...
No Matches
mova2i.f File Reference

This Function copies a bit string from a Character*1 variable to an integer variable. More...

Go to the source code of this file.

Functions/Subroutines

integer function mova2i (a)
 This Function copies a bit string from a Character*1 variable to an integer variable.
 

Detailed Description

This Function copies a bit string from a Character*1 variable to an integer variable.

Author
Stephen Gilbert
Date
1998-12-15

Definition in file mova2i.f.

Function/Subroutine Documentation

◆ mova2i()

integer function mova2i ( character(len=1)  a)

This Function copies a bit string from a Character*1 variable to an integer variable.

It is intended to replace the Fortran Intrinsic Function ICHAR, which only supports 0 <= ICHAR(a) <= 127 on the IBM SP. If "a" is greater than 127 in the collating sequence, ICHAR(a) does not return the expected bit value when the -qhot ( and therefore -qsmp) option is used when compiling. This function can be used for all values 0 <= ICHAR(a) <= 255 and will work with or without the -qhot compiler option.

Program history log:

  • Stephen Gilbert 1998-12-15
  • Stephen Gilbert 2001-06-11 Added a step to fill an 8-byte character array with the same value so that the f90 transfer function is more predictable. All bytes will now contain the desired value.
Parameters
[in]aCharacter*1 variable that holds the bitstring to extract.
Returns
mova2i() Integer value of the bitstring in character a.

Definition at line 24 of file mova2i.f.