[−][src]Crate ink_lang_ir
The ink! intermediate representation (IR) and abstractions.
This module defines everything the ink! procedural macro needs in order to parse, analyze and generate code for ink! smart contracts.
The entry point for every ink! smart contract is the Contract
with its Config
provided in the initial invokation at
#[ink::contract(... configuration ...)]
.
The ink! IR tries to stay close to the original Rust syntactic structure.
All ink! definitions of an ink! smart contract are always defined within
a so-called Rust inline modlue (mod my_module { ... items ... }
).
Therefore all ink! definition are found and accessed using the
ItemMod
data structure.
Macros
format_err | Creates a |
format_err_spanned | Creates a |
Structs
CallableWithSelector | Wrapper for a callable that adds its composed selector. |
Config | The ink! configuration. |
Constructor | An ink! constructor definition. |
Contract | An ink! contract definition consisting of the ink! configuration and module. |
Event | An ink! event struct definition. |
InkTest | The ink! test with all required information. |
InkTrait | A checked ink! trait definition. |
InkTraitConstructor | A checked ink! constructor of an ink! trait definition. |
InkTraitMessage | A checked ink! message of an ink! trait definition. |
InputsIter | Iterator over the input parameters of an ink! message or constructor. |
ItemImpl | An ink! implementation block. |
ItemMod | The ink! module. |
IterConstructors | Iterator yielding all ink! constructor within a source ink!
|
IterEvents | Iterator yielding all ink! event definitions within the ink!
|
IterInkTraitItems | Iterator over all the ink! trait items of an ink! trait definition. |
IterItemImpls | Iterator yielding all ink! implementation block definitions within the ink!
|
IterMessages | Iterator yielding all ink! messages within a source ink!
|
Message | An ink! message definition. |
Namespace | An ink! namespace applicable to a trait implementation block. |
Selector | A function selector. |
Storage | An ink! storage struct definition. |
Enums
CallableKind | The kind of externally callable smart contract entity. |
ImplItem | An item within an ink! implementation block. |
InkItem | An ink! specific item. |
InkTraitItem | An ink! item within an ink! trait definition. |
Item | An item in the root of the ink! module ( |
Receiver | The receiver of an ink! message. |
Visibility | The visibility of an ink! message or constructor. |
Traits
Callable | An ink! callable. |