Returns the position of a character in the collating sequence associated
with the kind type parameter of the character.
Class
Elemental function
Argument type and attributes
C
must be of type character and of length one. Its value must be that
of a representable character.
Result type and attributes
Default integer.
Result value
The result is the position of C in the collating sequence associated with
the kind type parameter of C and is in the range 0 <= ICHAR (C) <= 127.
For any representable characters C and D, C .LE. D is true if and only
if ICHAR (C) .LE. ICHAR (D) is true and C .EQ. D is true if and only if ICHAR
(C) .EQ. ICHAR (D) is true.
Examples
ICHAR ('X') has the value 88 in the ASCII collating sequence.
Specific Name
Argument Type
Result Type
Pass As Arg?
ICHAR
default character
default integer
yes 1
Notes:
The extension is the ability to pass the name as an argument.
XL Fortran supports only the ASCII collating sequence.