Ichar

Integer code for character.

Declaration

Syntax

Ichar(expr arg, ttype type, expr? value)

Arguments

Argument Name

Argument Description

arg

expression argument

type

table entry type

value

value of expression

Return values

The return value is the expression that the Ichar represents.

Описание

Ichar represents integer code for character.

Types

Only accepts characters.

Examples

integer :: i
i = ichar(' ')

ASR:

(TranslationUnit
    (SymbolTable
        1
        {
            i:
                (Variable
                    1
                    i
                    Local
                    ()
                    ()
                    Default
                    (Integer 4 [])
                    Source
                    Public
                    Required
                    .false.
                )

        })
    [(=
        (Var 1 i)
        (Ichar
            (StringConstant
                " "
                (Character 1 1 () [])
            )
            (Integer 4 [])
            (IntegerConstant 32 (Integer 4 []))
        )
        ()
    )]
)

See Also