* Updated ABI definitions & parsing * Run type generation * Definitions (should be ok-ish) * Cleanup names * Allow aliasses on structs (JSON parsing) * Cleanup json mapping passing * s/types/lookup/ * Parsing as per current output * InkSelector * MtRegistryIndex * String lookup tests * Remove serd ovverride comments (it works as-is) * inkRegistry tests * Extract primitive types * s/ty/id/ * Start of parsing into types (actually to be TypeDef) * Parsing * stringify struct fields * Small cleanups * Add type index to project lookup * Prefix with index * Fix interface generation * Latest contract metadata (#2118) * Add new (provisional) incrementer contract metadata * Update and regenerate type definitions * WIP: generate new format scale-info types * WIP: implementing variants * Implement variants * Fix up type resolution * Fix registry spec tests * Fix lints and some tests * Fix inkTypes tests * Fix some lints * Make imports same line like original * Comment out (temporarily) sanitize import to make CI pass * Sanitize * Remove indices * Remove index * api-contract rewrite * lint * cleanup * latest * latest * fix definition * fiz definitions * rv ink storage * Update packages/api-contract/src/base/Contract.ts Co-authored-by: Jaco Greeff <jacogr@gmail.com> * fixes * rv scripts * restore api-contract * reorder definitions, fix ink storage * fixes * def order * fixes * encodeTypeDef asRaw * update ink typ spec * latest built contracts * compare files * Apply suggestions from code review Co-authored-by: Jaco Greeff <jacogr@gmail.com> Co-authored-by: Andrew Jones <ascjones@gmail.com>
243 lines
4.8 KiB
JSON
243 lines
4.8 KiB
JSON
[
|
|
{
|
|
"info": 6,
|
|
"type": "u128"
|
|
},
|
|
{
|
|
"displayName": "Header",
|
|
"namespace": "ink_storage::collections::stash",
|
|
"info": 9,
|
|
"sub": [
|
|
{
|
|
"info": 6,
|
|
"type": "u32",
|
|
"name": "last_vacant"
|
|
},
|
|
{
|
|
"info": 6,
|
|
"type": "u32",
|
|
"name": "len"
|
|
},
|
|
{
|
|
"info": 6,
|
|
"type": "u32",
|
|
"name": "len_entries"
|
|
}
|
|
],
|
|
"type": "{\"last_vacant\":\"u32\",\"len\":\"u32\",\"len_entries\":\"u32\"}"
|
|
},
|
|
{
|
|
"info": 6,
|
|
"type": "u32"
|
|
},
|
|
{
|
|
"displayName": "Entry",
|
|
"namespace": "ink_storage::collections::stash",
|
|
"params": [
|
|
{
|
|
"displayName": "AccountId",
|
|
"namespace": "ink_env::types",
|
|
"info": 6,
|
|
"type": "AccountId"
|
|
}
|
|
],
|
|
"info": 3,
|
|
"sub": [
|
|
{
|
|
"displayName": "VacantEntry",
|
|
"namespace": "ink_storage::collections::stash",
|
|
"info": 9,
|
|
"sub": [
|
|
{
|
|
"info": 6,
|
|
"type": "u32",
|
|
"name": "next"
|
|
},
|
|
{
|
|
"info": 6,
|
|
"type": "u32",
|
|
"name": "prev"
|
|
}
|
|
],
|
|
"type": "{\"next\":\"u32\",\"prev\":\"u32\"}",
|
|
"name": "Vacant"
|
|
},
|
|
{
|
|
"displayName": "AccountId",
|
|
"namespace": "ink_env::types",
|
|
"info": 6,
|
|
"type": "AccountId",
|
|
"name": "Occupied"
|
|
}
|
|
],
|
|
"type": "{\"_enum\":{\"Vacant\":\"VacantEntry\",\"Occupied\":\"AccountId\"}}"
|
|
},
|
|
{
|
|
"displayName": "AccountId",
|
|
"namespace": "ink_env::types",
|
|
"info": 6,
|
|
"type": "AccountId"
|
|
},
|
|
{
|
|
"info": 12,
|
|
"length": 32,
|
|
"sub": {
|
|
"info": 6,
|
|
"type": "u8"
|
|
},
|
|
"type": "[u8;32]"
|
|
},
|
|
{
|
|
"info": 6,
|
|
"type": "u8"
|
|
},
|
|
{
|
|
"displayName": "VacantEntry",
|
|
"namespace": "ink_storage::collections::stash",
|
|
"info": 9,
|
|
"sub": [
|
|
{
|
|
"info": 6,
|
|
"type": "u32",
|
|
"name": "next"
|
|
},
|
|
{
|
|
"info": 6,
|
|
"type": "u32",
|
|
"name": "prev"
|
|
}
|
|
],
|
|
"type": "{\"next\":\"u32\",\"prev\":\"u32\"}"
|
|
},
|
|
{
|
|
"displayName": "ValueEntry",
|
|
"namespace": "ink_storage::collections::hashmap",
|
|
"params": [
|
|
{
|
|
"info": 6,
|
|
"type": "u128"
|
|
}
|
|
],
|
|
"info": 9,
|
|
"sub": [
|
|
{
|
|
"info": 6,
|
|
"type": "u128",
|
|
"name": "value"
|
|
},
|
|
{
|
|
"info": 6,
|
|
"type": "u32",
|
|
"name": "key_index"
|
|
}
|
|
],
|
|
"type": "{\"value\":\"u128\",\"key_index\":\"u32\"}"
|
|
},
|
|
{
|
|
"displayName": "Entry",
|
|
"namespace": "ink_storage::collections::stash",
|
|
"params": [
|
|
{
|
|
"info": 10,
|
|
"sub": [
|
|
{
|
|
"displayName": "AccountId",
|
|
"namespace": "ink_env::types",
|
|
"info": 6,
|
|
"type": "AccountId"
|
|
},
|
|
{
|
|
"displayName": "AccountId",
|
|
"namespace": "ink_env::types",
|
|
"info": 6,
|
|
"type": "AccountId"
|
|
}
|
|
],
|
|
"type": "(AccountId, AccountId)"
|
|
}
|
|
],
|
|
"info": 3,
|
|
"sub": [
|
|
{
|
|
"displayName": "VacantEntry",
|
|
"namespace": "ink_storage::collections::stash",
|
|
"info": 9,
|
|
"sub": [
|
|
{
|
|
"info": 6,
|
|
"type": "u32",
|
|
"name": "next"
|
|
},
|
|
{
|
|
"info": 6,
|
|
"type": "u32",
|
|
"name": "prev"
|
|
}
|
|
],
|
|
"type": "{\"next\":\"u32\",\"prev\":\"u32\"}",
|
|
"name": "Vacant"
|
|
},
|
|
{
|
|
"info": 10,
|
|
"sub": [
|
|
{
|
|
"displayName": "AccountId",
|
|
"namespace": "ink_env::types",
|
|
"info": 6,
|
|
"type": "AccountId"
|
|
},
|
|
{
|
|
"displayName": "AccountId",
|
|
"namespace": "ink_env::types",
|
|
"info": 6,
|
|
"type": "AccountId"
|
|
}
|
|
],
|
|
"type": "(AccountId, AccountId)",
|
|
"name": "Occupied"
|
|
}
|
|
],
|
|
"type": "{\"_enum\":{\"Vacant\":\"VacantEntry\",\"Occupied\":\"(AccountId, AccountId)\"}}"
|
|
},
|
|
{
|
|
"info": 10,
|
|
"sub": [
|
|
{
|
|
"displayName": "AccountId",
|
|
"namespace": "ink_env::types",
|
|
"info": 6,
|
|
"type": "AccountId"
|
|
},
|
|
{
|
|
"displayName": "AccountId",
|
|
"namespace": "ink_env::types",
|
|
"info": 6,
|
|
"type": "AccountId"
|
|
}
|
|
],
|
|
"type": "(AccountId, AccountId)"
|
|
},
|
|
{
|
|
"info": 6,
|
|
"type": "bool"
|
|
},
|
|
{
|
|
"displayName": "Option",
|
|
"params": [
|
|
{
|
|
"displayName": "AccountId",
|
|
"namespace": "ink_env::types",
|
|
"info": 6,
|
|
"type": "AccountId"
|
|
}
|
|
],
|
|
"info": 5,
|
|
"sub": {
|
|
"displayName": "AccountId",
|
|
"namespace": "ink_env::types",
|
|
"info": 6,
|
|
"type": "AccountId"
|
|
},
|
|
"type": "Option<AccountId>"
|
|
}
|
|
] |