Inline some type conversions for ()
The `()` type accidentally wasn't getting its trivial type conversions inlined because it doesn't actually have any type parameters. This commit adds `#[inline]` to the relevant functions to ensure that these get inlined across crates.
This commit is contained in:
@@ -368,6 +368,7 @@ macro_rules! impl_wasm_params {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#[inline]
|
||||||
fn into_abi(self, _store: &mut StoreOpaque) -> Option<Self::Abi> {
|
fn into_abi(self, _store: &mut StoreOpaque) -> Option<Self::Abi> {
|
||||||
let ($($t,)*) = self;
|
let ($($t,)*) = self;
|
||||||
$(
|
$(
|
||||||
@@ -446,6 +447,7 @@ macro_rules! impl_wasm_results {
|
|||||||
{
|
{
|
||||||
type ResultAbi = ($($t::Abi,)*);
|
type ResultAbi = ($($t::Abi,)*);
|
||||||
|
|
||||||
|
#[inline]
|
||||||
unsafe fn from_abi(store: &mut StoreOpaque, abi: Self::ResultAbi) -> Self {
|
unsafe fn from_abi(store: &mut StoreOpaque, abi: Self::ResultAbi) -> Self {
|
||||||
let ($($t,)*) = abi;
|
let ($($t,)*) = abi;
|
||||||
($($t::from_abi($t, store),)*)
|
($($t::from_abi($t, store),)*)
|
||||||
|
|||||||
Reference in New Issue
Block a user