wake.ir.expressions.new_expression
module
#
NewExpression
class
#
Bases: ExpressionAbc
A new expression may create:
- a new contract, e.g.
new ERC20(), - a new array, e.g.
new uint[](10), - a new
bytesorstring, e.g.new bytes(10).
Source code in wake/ir/expressions/new_expression.py
children
property
#
Yields:
| Type | Description |
|---|---|
TypeNameAbc
|
Direct children of this node. |
type_name
property
#
Is:
- UserDefinedTypeName referencing ContractDefinition when creating a new contract,
- ArrayTypeName when creating a new array,
- ElementaryTypeName when creating new
bytesorstring.
Returns:
| Type | Description |
|---|---|
TypeNameAbc
|
Type name of the object to be created. |