types
¶
Provide semantic-facing type nodes that extend the upstream ASTx type model without coupling them to template metadata helpers.
Classes:
GeneratorType
¶
GeneratorType(yield_type: DataType)
Bases: AnyType
Represent one stateful generator value that yields values of one statically known element type when iterated. attributes: yield_type: type: astx.DataType
Methods:
Source code in src/irx/astx/types.py
153 154 155 156 157 158 159 160 161 | |
get_struct
¶
get_struct(simplified: bool = False) -> ReprStruct
Source code in src/irx/astx/types.py
171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 | |
TemplateTypeVar
¶
TemplateTypeVar(name: str, *, bound: DataType)
Bases: AnyType
Represent one unresolved template type parameter inside function signatures or local declared types before specialization. attributes: name: type: str bound: type: astx.DataType
Methods:
Source code in src/irx/astx/types.py
98 99 100 101 102 103 104 105 106 107 108 109 | |
get_struct
¶
get_struct(simplified: bool = False) -> ReprStruct
Source code in src/irx/astx/types.py
119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 | |
UnionType
¶
Bases: AnyType
Represent one union of concrete type references that semantic analysis may enumerate as a finite type domain. attributes: members: type: tuple[astx.DataType, Ellipsis] alias_name: type: str | None
Methods:
Source code in src/irx/astx/types.py
36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 | |
get_struct
¶
get_struct(simplified: bool = False) -> ReprStruct
Source code in src/irx/astx/types.py
64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 | |