chc.app.CConst module

chc.app.CConst.CConst(cd, ixval)

Constant expression.

chc.app.CConst.CConstChr(cd, ixval)

Constant character.

chc.app.CConst.CConstEnum(cd, ixval)

Constant enumeration value.

chc.app.CConst.CConstInt(cd, ixval)

Constant integer.

chc.app.CConst.CConstReal(cd, ixval)

Constant real number.

chc.app.CConst.CConstStr(cd, ixval)

Constant string.

chc.app.CConst.CConstWStr(cd, ixval)

Constant wide string (represented as a sequence of int64 integers)

chc.app.CConst.CStringConstant(cd, ixval)

Constant string value

Object representation of CIL constant sum type.

class chc.app.CConst.CConst(cd: CDictionary, ixval: chc.util.IndexedTable.IndexedTableValue)[source]

Bases: chc.app.CDictionaryRecord.CDictionaryRecord

Constant expression.

get_exp(ix: int) CExp[source]
get_strings() List[str][source]
property is_chr: bool
property is_enum: bool
property is_int: bool
property is_real: bool
property is_str: bool
property is_wstr: bool
class chc.app.CConst.CConstChr(cd: CDictionary, ixval: chc.util.IndexedTable.IndexedTableValue)[source]

Bases: chc.app.CConst.CConst

Constant character.

  • args[0]: char code

property chrvalue: str
property is_chr: bool
class chc.app.CConst.CConstEnum(cd: CDictionary, ixval: chc.util.IndexedTable.IndexedTableValue)[source]

Bases: chc.app.CConst.CConst

Constant enumeration value.

  • tags[1]: enum name

  • tags[1]: enum item name

  • args[0]: exp

property enum_name: str
property exp: CExp
property is_enum: bool
property item_name: str
class chc.app.CConst.CConstInt(cd: CDictionary, ixval: chc.util.IndexedTable.IndexedTableValue)[source]

Bases: chc.app.CConst.CConst

Constant integer.

  • tags[1]: string representation of value

  • tags[2]: ikind

property ikind: str
property intvalue: int
property is_int: bool
class chc.app.CConst.CConstReal(cd: CDictionary, ixval: chc.util.IndexedTable.IndexedTableValue)[source]

Bases: chc.app.CConst.CConst

Constant real number.

  • tags[1]: string representation of real

  • tags[2]: fkind

property fkind: str
property is_real: bool
property realvalue: float
class chc.app.CConst.CConstStr(cd: CDictionary, ixval: chc.util.IndexedTable.IndexedTableValue)[source]

Bases: chc.app.CConst.CConst

Constant string.

  • args[0]: string index

get_strings() List[str][source]
property is_str: bool
property stringvalue: str
class chc.app.CConst.CConstWStr(cd: CDictionary, ixval: chc.util.IndexedTable.IndexedTableValue)[source]

Bases: chc.app.CConst.CConst

Constant wide string (represented as a sequence of int64 integers)

  • tags[1..]: string representation of int64 integers

property is_wstr: bool
property stringvalue: str
class chc.app.CConst.CStringConstant(cd: CDictionary, ixval: chc.util.IndexedTable.IndexedTableValue)[source]

Bases: chc.app.CDictionaryRecord.CDictionaryRecord

Constant string value

  • tags[0]: string value or hexadecimal representation of string value

  • tags[1]: ‘x’ (optional) if string value is represented in hexadecimal

  • args[0] length of original string

property is_hex: bool
property string_length: int
property stringvalue: str