Unverified Commit 59dcb1ba authored by Andrew Jones's avatar Andrew Jones Committed by GitHub

[metadata] rename abi crate to metadata (#465)

* git mv abi metadata

* mm

* Rename codegen abi to metadata

* Fmt
parent 65e094e1
Pipeline #98794 failed with stages
in 11 minutes and 46 seconds
......@@ -255,7 +255,7 @@ publish-docs:
- git fetch origin gh-pages
# Generating Docs
- time cargo doc --no-deps --all-features
-p scale-info -p ink_abi -p ink_abi_derive -p ink_core -p ink_core_derive
-p scale-info -p ink_metadata -p ink_metadata_derive -p ink_core -p ink_core_derive
-p ink_primitives -p ink_prelude -p ink_lang -p ink_lang_macro
# saving README and docs
- mv target/doc/ /tmp/
......
[workspace]
members = [
"abi",
"metadata",
"core",
"lang",
"prelude",
......
......@@ -14,8 +14,8 @@
[e2]: https://github.com/Aaronepower/tokei#badges
[f1]: https://img.shields.io/badge/docs-core-blue.svg
[f2]: https://paritytech.github.io/ink/ink_core
[h1]: https://img.shields.io/badge/docs-abi-blue.svg
[h2]: https://paritytech.github.io/ink/ink_abi
[h1]: https://img.shields.io/badge/docs-metadata-blue.svg
[h2]: https://paritytech.github.io/ink/ink_metadata
[i1]: https://img.shields.io/badge/docs-prelude-blue.svg
[i2]: https://paritytech.github.io/ink/ink_prelude
......@@ -27,7 +27,7 @@ For more information please visit [the ink! tutorial](https://substrate.dev/subs
## Developer Documentation
| `ink_abi` | `ink_core` | `ink_prelude` |
| `ink_metadata` | `ink_core` | `ink_prelude` |
| ------------- | ------------- | ------------- |
| [![][h1]][h2] | [![][f1]][f2] | [![][i1]][i2] |
......
......@@ -15,7 +15,7 @@ categories = ["no-std", "embedded"]
include = ["Cargo.toml", "src/**/*.rs", "README.md", "LICENSE"]
[dependencies]
ink_abi = { version = "2.1.0", path = "../abi/", default-features = false, features = ["derive"], optional = true }
ink_metadata = { version = "2.1.0", path = "../metadata/", default-features = false, features = ["derive"], optional = true }
ink_alloc = { version = "2.1.0", path = "../alloc/", default-features = false }
ink_primitives = { version = "2.1.0", path = "../primitives/", default-features = false }
ink_core_derive = { version = "2.1.0", path = "derive", default-features = false }
......@@ -54,8 +54,8 @@ itertools = "0.9"
default = ["std"]
std = [
"criterion",
"ink_abi",
"ink_abi/std",
"ink_metadata",
"ink_metadata/std",
"ink_alloc/std",
"ink_prelude/std",
"ink_primitives/std",
......
......@@ -18,5 +18,5 @@ synstructure = "0.12"
[dev-dependencies]
ink_primitives = { version = "2.1.0", path = "../../primitives" }
ink_abi = { version = "2.1.0", path = "../../abi" }
ink_metadata = { version = "2.1.0", path = "../../metadata" }
ink_core = { version = "2.1.0", path = ".." }
......@@ -28,7 +28,7 @@ fn field_layout<'a>(
};
let ty = &field.ty;
quote! {
::ink_abi::layout2::FieldLayout::new(
::ink_metadata::layout2::FieldLayout::new(
#ident,
<#ty as ::ink_core::storage2::traits::StorageLayout>::layout(__key_ptr),
)
......@@ -49,9 +49,9 @@ fn storage_layout_struct(s: &synstructure::Structure) -> TokenStream2 {
let field_layouts = field_layout(variant);
s.gen_impl(quote! {
gen impl ::ink_core::storage2::traits::StorageLayout for @Self {
fn layout(__key_ptr: &mut ::ink_core::storage2::traits::KeyPtr) -> ::ink_abi::layout2::Layout {
::ink_abi::layout2::Layout::Struct(
::ink_abi::layout2::StructLayout::new(vec![
fn layout(__key_ptr: &mut ::ink_core::storage2::traits::KeyPtr) -> ::ink_metadata::layout2::Layout {
::ink_metadata::layout2::Layout::Struct(
::ink_metadata::layout2::StructLayout::new(vec![
#(#field_layouts ,)*
])
)
......@@ -78,8 +78,8 @@ fn storage_layout_enum(s: &synstructure::Structure) -> TokenStream2 {
let mut __variant_key_ptr = __key_ptr.clone();
let mut __key_ptr = &mut __variant_key_ptr;
(
::ink_abi::layout2::Discriminant::from(#discriminant),
::ink_abi::layout2::StructLayout::new(vec![
::ink_metadata::layout2::Discriminant::from(#discriminant),
::ink_metadata::layout2::StructLayout::new(vec![
#(#field_layouts ,)*
]),
)
......@@ -88,11 +88,11 @@ fn storage_layout_enum(s: &synstructure::Structure) -> TokenStream2 {
});
s.gen_impl(quote! {
gen impl ::ink_core::storage2::traits::StorageLayout for @Self {
fn layout(__key_ptr: &mut ::ink_core::storage2::traits::KeyPtr) -> ::ink_abi::layout2::Layout {
fn layout(__key_ptr: &mut ::ink_core::storage2::traits::KeyPtr) -> ::ink_metadata::layout2::Layout {
let dispatch_key = __key_ptr.advance_by(1);
::ink_abi::layout2::Layout::Enum(
::ink_abi::layout2::EnumLayout::new(
::ink_abi::layout2::LayoutKey::from(dispatch_key),
::ink_metadata::layout2::Layout::Enum(
::ink_metadata::layout2::EnumLayout::new(
::ink_metadata::layout2::LayoutKey::from(dispatch_key),
vec![
#(#variant_layouts ,)*
]
......
This diff is collapsed.
......@@ -32,7 +32,7 @@ pub struct DynamicAllocator {
#[cfg(feature = "std")]
const _: () = {
use crate::storage2::traits::StorageLayout;
use ink_abi::layout2::{
use ink_metadata::layout2::{
FieldLayout,
Layout,
StructLayout,
......
......@@ -30,7 +30,7 @@ use ink_primitives::Key;
#[cfg(feature = "std")]
const _: () = {
use crate::storage2::traits::StorageLayout;
use ink_abi::layout2::{
use ink_metadata::layout2::{
CellLayout,
Layout,
LayoutKey,
......
......@@ -35,7 +35,7 @@ use ink_primitives::Key;
#[cfg(feature = "std")]
const _: () = {
use crate::storage2::traits::StorageLayout;
use ink_abi::layout2::{
use ink_metadata::layout2::{
FieldLayout,
Layout,
StructLayout,
......
......@@ -36,7 +36,7 @@ const _: () = {
lazy::Lazy,
traits::StorageLayout,
};
use ink_abi::layout2::{
use ink_metadata::layout2::{
FieldLayout,
Layout,
StructLayout,
......
......@@ -43,7 +43,7 @@ const _: () = {
StorageLayout,
},
};
use ink_abi::layout2::{
use ink_metadata::layout2::{
FieldLayout,
Layout,
StructLayout,
......
......@@ -29,7 +29,7 @@ const _: () = {
lazy::LazyArray,
traits::StorageLayout,
};
use ink_abi::layout2::{
use ink_metadata::layout2::{
FieldLayout,
Layout,
StructLayout,
......
......@@ -38,7 +38,7 @@ const _: () = {
collections::Vec as StorageVec,
traits::StorageLayout,
};
use ink_abi::layout2::{
use ink_metadata::layout2::{
CellLayout,
FieldLayout,
Layout,
......
......@@ -30,7 +30,7 @@ const _: () = {
lazy::Lazy,
traits::StorageLayout,
};
use ink_abi::layout2::{
use ink_metadata::layout2::{
FieldLayout,
Layout,
StructLayout,
......
......@@ -90,7 +90,7 @@ where
#[cfg(feature = "std")]
const _: () = {
use crate::storage2::traits::StorageLayout;
use ink_abi::layout2::{
use ink_metadata::layout2::{
ArrayLayout,
CellLayout,
Layout,
......
......@@ -119,7 +119,7 @@ where
#[cfg(feature = "std")]
const _: () = {
use crate::storage2::traits::StorageLayout;
use ink_abi::layout2::Layout;
use ink_metadata::layout2::Layout;
impl<T> StorageLayout for LazyCell<T>
where
......
......@@ -153,7 +153,7 @@ const _: () = {
LayoutCryptoHasher,
StorageLayout,
};
use ink_abi::layout2::{
use ink_metadata::layout2::{
CellLayout,
HashLayout,
HashingStrategy,
......
......@@ -209,7 +209,7 @@ impl<V> LazyIndexMap<V> {
#[cfg(feature = "std")]
const _: () = {
use crate::storage2::traits::StorageLayout;
use ink_abi::layout2::{
use ink_metadata::layout2::{
ArrayLayout,
CellLayout,
Layout,
......
......@@ -71,7 +71,7 @@ where
#[cfg(feature = "std")]
const _: () = {
use crate::storage2::traits::StorageLayout;
use ink_abi::layout2::Layout;
use ink_metadata::layout2::Layout;
impl<T> StorageLayout for Lazy<T>
where
......
......@@ -53,7 +53,7 @@ pub struct Memory<T> {
#[cfg(feature = "std")]
const _: () = {
use crate::storage2::traits::StorageLayout;
use ink_abi::layout2::{
use ink_metadata::layout2::{
CellLayout,
Layout,
LayoutKey,
......
......@@ -84,7 +84,7 @@ impl<T> Pack<T> {
#[cfg(feature = "std")]
const _: () = {
use crate::storage2::traits::StorageLayout;
use ink_abi::layout2::{
use ink_metadata::layout2::{
CellLayout,
Layout,
LayoutKey,
......
......@@ -24,7 +24,7 @@ use crate::{
SpreadLayout,
},
};
use ink_abi::layout2::{
use ink_metadata::layout2::{
ArrayLayout,
CellLayout,
Discriminant,
......
......@@ -25,7 +25,7 @@ use crate::{
},
storage2::traits::KeyPtr,
};
use ink_abi::layout2::{
use ink_metadata::layout2::{
CryptoHasher,
Layout,
};
......
......@@ -6,7 +6,7 @@ edition = "2018"
[dependencies]
ink_primitives = { version = "2.1.0", path = "../../primitives", default-features = false }
ink_abi = { version = "2.1.0", path = "../../abi", default-features = false, features = ["derive"], optional = true }
ink_metadata = { version = "2.1.0", path = "../../metadata", default-features = false, features = ["derive"], optional = true }
ink_core = { version = "2.1.0", path = "../../core", default-features = false }
ink_lang = { version = "2.1.0", path = "../../lang", default-features = false }
......@@ -26,8 +26,8 @@ crate-type = ["cdylib"]
default = ["std"]
std = [
"ink_primitives/std",
"ink_abi",
"ink_abi/std",
"ink_metadata",
"ink_metadata/std",
"ink_core/std",
"ink_lang/std",
"scale/std",
......
......@@ -6,7 +6,7 @@ edition = "2018"
[dependencies]
ink_primitives = { version = "2.1.0", path = "../../../primitives", default-features = false }
ink_abi = { version = "2.1.0", path = "../../../abi", default-features = false, features = ["derive"], optional = true }
ink_metadata = { version = "2.1.0", path = "../../../metadata", default-features = false, features = ["derive"], optional = true }
ink_core = { version = "2.1.0", path = "../../../core", default-features = false }
ink_lang = { version = "2.1.0", path = "../../../lang", default-features = false }
......@@ -27,8 +27,8 @@ crate-type = [
default = ["std"]
std = [
"ink_primitives/std",
"ink_abi",
"ink_abi/std",
"ink_metadata",
"ink_metadata/std",
"ink_core/std",
"ink_lang/std",
"scale/std",
......
......@@ -6,7 +6,7 @@ edition = "2018"
[dependencies]
ink_primitives = { version = "2.1.0", path = "../../../primitives", default-features = false }
ink_abi = { version = "2.1.0", path = "../../../abi", default-features = false, features = ["derive"], optional = true }
ink_metadata = { version = "2.1.0", path = "../../../metadata", default-features = false, features = ["derive"], optional = true }
ink_core = { version = "2.1.0", path = "../../../core", default-features = false }
ink_lang = { version = "2.1.0", path = "../../../lang", default-features = false }
......@@ -29,8 +29,8 @@ crate-type = [
default = ["std"]
std = [
"ink_primitives/std",
"ink_abi",
"ink_abi/std",
"ink_metadata",
"ink_metadata/std",
"ink_core/std",
"ink_lang/std",
"scale/std",
......
......@@ -6,7 +6,7 @@ edition = "2018"
[dependencies]
ink_primitives = { version = "2.1.0", path = "../../../primitives", default-features = false }
ink_abi = { version = "2.1.0", path = "../../../abi", default-features = false, features = ["derive"], optional = true }
ink_metadata = { version = "2.1.0", path = "../../../metadata", default-features = false, features = ["derive"], optional = true }
ink_core = { version = "2.1.0", path = "../../../core", default-features = false }
ink_lang = { version = "2.1.0", path = "../../../lang", default-features = false }
......@@ -29,8 +29,8 @@ crate-type = [
default = ["std"]
std = [
"ink_primitives/std",
"ink_abi",
"ink_abi/std",
"ink_metadata",
"ink_metadata/std",
"ink_core/std",
"ink_lang/std",
"scale/std",
......
......@@ -6,7 +6,7 @@ edition = "2018"
[dependencies]
ink_primitives = { version = "2.1.0", path = "../../primitives", default-features = false }
ink_abi = { version = "2.1.0", path = "../../abi", default-features = false, features = ["derive"], optional = true }
ink_metadata = { version = "2.1.0", path = "../../metadata", default-features = false, features = ["derive"], optional = true }
ink_core = { version = "2.1.0", path = "../../core", default-features = false }
ink_lang = { version = "2.1.0", path = "../../lang", default-features = false }
......@@ -22,8 +22,8 @@ crate-type = ["cdylib"]
default = ["std"]
std = [
"ink_primitives/std",
"ink_abi",
"ink_abi/std",
"ink_metadata",
"ink_metadata/std",
"ink_core/std",
"ink_lang/std",
"scale/std",
......
......@@ -6,7 +6,7 @@ edition = "2018"
[dependencies]
ink_primitives = { version = "2.1.0", path = "../../primitives", default-features = false }
ink_abi = { version = "2.1.0", path = "../../abi", default-features = false, features = ["derive"], optional = true }
ink_metadata = { version = "2.1.0", path = "../../metadata", default-features = false, features = ["derive"], optional = true }
ink_core = { version = "2.1.0", path = "../../core", default-features = false }
ink_lang = { version = "2.1.0", path = "../../lang", default-features = false }
......@@ -22,8 +22,8 @@ crate-type = ["cdylib"]
default = ["std"]
std = [
"ink_primitives/std",
"ink_abi",
"ink_abi/std",
"ink_metadata",
"ink_metadata/std",
"ink_core/std",
"ink_lang/std",
"scale/std",
......
......@@ -6,7 +6,7 @@ edition = "2018"
[dependencies]
ink_primitives = { version = "2.1.0", path = "../../primitives", default-features = false }
ink_abi = { version = "2.1.0", path = "../../abi", default-features = false, features = ["derive"], optional = true }
ink_metadata = { version = "2.1.0", path = "../../metadata", default-features = false, features = ["derive"], optional = true }
ink_core = { version = "2.1.0", path = "../../core", default-features = false }
ink_lang = { version = "2.1.0", path = "../../lang", default-features = false }
......@@ -22,8 +22,8 @@ crate-type = ["cdylib"]
default = ["std"]
std = [
"ink_primitives/std",
"ink_abi",
"ink_abi/std",
"ink_metadata",
"ink_metadata/std",
"ink_core/std",
"ink_lang/std",
"scale/std",
......
......@@ -6,7 +6,7 @@ edition = "2018"
[dependencies]
ink_primitives = { version = "2.1.0", path = "../../primitives", default-features = false }
ink_abi = { version = "2.1.0", path = "../../abi", default-features = false, features = ["derive"], optional = true }
ink_metadata = { version = "2.1.0", path = "../../metadata", default-features = false, features = ["derive"], optional = true }
ink_core = { version = "2.1.0", path = "../../core", default-features = false }
ink_lang = { version = "2.1.0", path = "../../lang", default-features = false }
......@@ -22,8 +22,8 @@ crate-type = ["cdylib"]
default = ["std"]
std = [
"ink_primitives/std",
"ink_abi",
"ink_abi/std",
"ink_metadata",
"ink_metadata/std",
"ink_core/std",
"ink_lang/std",
"scale/std",
......
......@@ -6,7 +6,7 @@ edition = "2018"
[dependencies]
ink_primitives = { version = "2.1.0", path = "../../primitives", default-features = false }
ink_abi = { version = "2.1.0", path = "../../abi", default-features = false, features = ["derive"], optional = true }
ink_metadata = { version = "2.1.0", path = "../../metadata", default-features = false, features = ["derive"], optional = true }
ink_core = { version = "2.1.0", path = "../../core", default-features = false }
ink_lang = { version = "2.1.0", path = "../../lang", default-features = false }
......@@ -22,8 +22,8 @@ crate-type = ["cdylib"]
default = ["std"]
std = [
"ink_primitives/std",
"ink_abi",
"ink_abi/std",
"ink_metadata",
"ink_metadata/std",
"ink_core/std",
"ink_lang/std",
"scale/std",
......
......@@ -6,7 +6,7 @@ edition = "2018"
[dependencies]
ink_primitives = { version = "2.1.0", path = "../../primitives", default-features = false }
ink_abi = { version = "2.1.0", path = "../../abi", default-features = false, features = ["derive"], optional = true }
ink_metadata = { version = "2.1.0", path = "../../metadata", default-features = false, features = ["derive"], optional = true }
ink_core = { version = "2.1.0", path = "../../core", default-features = false }
ink_lang = { version = "2.1.0", path = "../../lang", default-features = false }
ink_prelude = { version = "2.1.0", path = "../../prelude", default-features = false }
......@@ -22,8 +22,8 @@ crate-type = ["cdylib"]
[features]
default = ["std"]
std = [
"ink_abi",
"ink_abi/std",
"ink_metadata",
"ink_metadata/std",
"ink_core/std",
"ink_lang/std",
"ink_primitives/std",
......
......@@ -7,7 +7,7 @@ edition = "2018"
[dependencies]
ink_primitives = { version = "2.1.0", path = "../../primitives", default-features = false }
ink_prelude = { version = "2.1.0", path = "../../prelude", default-features = false }
ink_abi = { version = "2.1.0", path = "../../abi", default-features = false, features = ["derive"], optional = true }
ink_metadata = { version = "2.1.0", path = "../../metadata", default-features = false, features = ["derive"], optional = true }
ink_core = { version = "2.1.0", path = "../../core", default-features = false }
ink_lang = { version = "2.1.0", path = "../../lang", default-features = false }
......@@ -23,8 +23,8 @@ crate-type = ["cdylib"]
default = ["std"]
std = [
"ink_primitives/std",
"ink_abi",
"ink_abi/std",
"ink_metadata",
"ink_metadata/std",
"ink_core/std",
"ink_lang/std",
"scale/std",
......
......@@ -17,7 +17,7 @@ include = ["Cargo.toml", "src/**/*.rs", "README.md", "LICENSE"]
[dependencies]
ink_core = { version = "2.1.0", path = "../core", default-features = false }
ink_primitives = { version = "2.1.0", path = "../primitives", default-features = false }
ink_abi = { version = "2.1.0", path = "../abi", default-features = false, optional = true }
ink_metadata = { version = "2.1.0", path = "../metadata", default-features = false, optional = true }
ink_prelude = { version = "2.1.0", path = "../prelude/", default-features = false }
ink_lang_macro = { version = "2.1.0", path = "macro", default-features = false }
......@@ -27,8 +27,8 @@ derive_more = { version = "0.99", default-features = false, features = ["from"]
[features]
default = ["std"]
std = [
"ink_abi",
"ink_abi/std",
"ink_metadata",
"ink_metadata/std",
"ink_prelude/std",
"ink_primitives/std",
"ink_core/std",
......
......@@ -29,7 +29,7 @@ regex = "1.3"
sha3 = "0.8"
[dev-dependencies]
ink_abi = { version = "2.1.0", path = "../../abi/" }
ink_metadata = { version = "2.1.0", path = "../../metadata/" }
ink_core = { version = "2.1.0", path = "../../core/" }
ink_lang = { version = "2.1.0", path = ".." }
......
......@@ -18,7 +18,6 @@ use quote::quote;
pub use crate::{
codegen::{
abi::GenerateAbi,
cross_calling::CrossCalling,
dispatch::Dispatch,
env_types::EnvTypes,
......@@ -26,6 +25,7 @@ pub use crate::{
EventHelpers,
EventStructs,
},
metadata::GenerateMetadata,
storage::Storage,
GenerateCode,
GenerateCodeUsing,
......@@ -54,7 +54,7 @@ impl GenerateCode for ContractModule<'_> {
let env_types = self.generate_code_using::<EnvTypes>();
let storage = self.generate_code_using::<Storage>();
let dispatch = self.generate_code_using::<Dispatch>();
let generate_abi = self.generate_code_using::<GenerateAbi>();
let generate_metadata = self.generate_code_using::<GenerateMetadata>();
let event_helpers = self.generate_code_using::<EventHelpers>();
let event_structs = self.generate_code_using::<EventStructs>();
let cross_calling = self.generate_code_using::<CrossCalling>();
......@@ -66,7 +66,7 @@ impl GenerateCode for ContractModule<'_> {
#storage
#event_helpers
#dispatch
#generate_abi
#generate_metadata
#cross_calling
#event_structs
#( #non_ink_items )*
......
......@@ -27,12 +27,12 @@ use crate::{
/// Generates code to generate the metadata of the contract.
#[derive(From)]
pub struct GenerateAbi<'a> {
pub struct GenerateMetadata<'a> {
/// The contract to generate code for.
contract: &'a ir::Contract,
}
impl GenerateCode for GenerateAbi<'_> {
impl GenerateCode for GenerateMetadata<'_> {
fn generate_code(&self) -> TokenStream2 {
let contract = self.generate_contract();
let layout = self.generate_layout();
......@@ -42,21 +42,21 @@ impl GenerateCode for GenerateAbi<'_> {
#[cfg(not(feature = "ink-as-dependency"))]
const _: () = {
#[no_mangle]
pub fn __ink_generate_metadata() -> ::ink_abi::InkProject {
let contract: ::ink_abi::ContractSpec = {
pub fn __ink_generate_metadata() -> ::ink_metadata::InkProject {
let contract: ::ink_metadata::ContractSpec = {
#contract
};
let layout: ::ink_abi::layout2::Layout = {
let layout: ::ink_metadata::layout2::Layout = {
#layout
};
::ink_abi::InkProject::new(layout, contract)
::ink_metadata::InkProject::new(layout, contract)
}
};
}
}
}
impl GenerateAbi<'_> {
impl GenerateMetadata<'_> {
fn generate_constructors<'a>(&'a self) -> impl Iterator<Item = TokenStream2> + 'a {
self.contract
.functions
......@@ -76,7 +76,7 @@ impl GenerateAbi<'_> {
.map(|fn_arg| self.generate_message_param(fn_arg));
quote_spanned!(span =>
::ink_abi::ConstructorSpec::new(#ident_lit)
::ink_metadata::ConstructorSpec::new(#ident_lit)
.selector([#(#selector_bytes),*])
.args(vec![
#(#args ,)*
......@@ -91,7 +91,7 @@ impl GenerateAbi<'_> {
fn generate_type_spec(&self, ty: &syn::Type) -> TokenStream2 {
fn without_display_name(ty: &syn::Type) -> TokenStream2 {
quote! { ::ink_abi::TypeSpec::new::<#ty>() }
quote! { ::ink_metadata::TypeSpec::new::<#ty>() }
}
if let syn::Type::Path(type_path) = ty {
if type_path.qself.is_some() {
......@@ -107,7 +107,7 @@ impl GenerateAbi<'_> {
.map(|seg| seg.ident.to_string())
.collect::<Vec<_>>();
quote! {
::ink_abi::TypeSpec::with_name_segs::<#ty, _>(
::ink_metadata::TypeSpec::with_name_segs::<#ty, _>(
vec![#(#segs),*].into_iter().map(AsRef::as_ref)
)
}
......@@ -120,13 +120,13 @@ impl GenerateAbi<'_> {
match ret_ty {
syn::ReturnType::Default => {
quote! {
::ink_abi::ReturnTypeSpec::new(None)
::ink_metadata::ReturnTypeSpec::new(None)
}
}
syn::ReturnType::Type(_, ty) => {
let type_spec = self.generate_type_spec(ty);
quote! {
::ink_abi::ReturnTypeSpec::new(#type_spec)
::ink_metadata::ReturnTypeSpec::new(#type_spec)
}
}