microprobe.code.var.VariableArray

class VariableArray(name: str, vartype: str, size: int, align: int | None = None, value=None, address: Address | None = None)[source]

Bases: Variable

__init__(name: str, vartype: str, size: int, align: int | None = None, value=None, address: Address | None = None)[source]
Parameters:
  • name

  • vartype

  • size

  • align – (Default value = 16)

  • value – (Default value = None)

Methods

__init__(name, vartype, size[, align, ...])

param name:

array()

Return if the variable is an array.

set_address(address)

Set variable address.

Attributes

address

Variable address (Address).

align

Variable alignment (int).

elems

Number of elements in the variable array (int).

name

Variable name (str).

size

Variable size in bytes (:int).

type

Variable type (str).

value

Variable value.




property type

Variable type (str).

property name

Variable name (str).

property value

Variable value.

array()[source]

Return if the variable is an array.

Return type:

bool

property size

Variable size in bytes (:int).

property align

Variable alignment (int).

property elems

Number of elements in the variable array (int).

property address

Variable address (Address).

set_address(address: Address)

Set variable address.

Parameters:

address – Address of the variable.