You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Polkadot has the type Xcm<Call> which has an Order<Call> and an Order<()> which in turn has an Xcm<Call>. We get a overflow evaluating the requirement Vec<order::Order<()>>: TypeInfo
Since Call is not directly encoded, see double_encoded, this type parameter does not need to implement Encode/Decode/TypeInfo
To get around this for other derives they are just removing the bounds:
On the surface we should be able to add #[scale_info(bounds()))] from #88 to erase the bounds. Though that is not enough on its own because there is still TypeInfo requirement for adding to type_params.
So what we need to be able to do is control which type params are included in the type_params list, in addition to (or even instead of) the custom bounds.
The text was updated successfully, but these errors were encountered:
Polkadot has the type Xcm which has an Order and an Order<()> which in turn has an Xcm. We get a overflow evaluating the requirement Vec<order::Order<()>>: TypeInfo
As suggested by the error message the issue is in fact caused by the auto added Vec<order::Order<()>>: TypeInfo bound.
The reason we have such an apparently unnecessary bound is because there is not currently a good solution to differentiate between a generic type constructor e.g. Vec<T> and an alias to an associated type e.g. BalanceOf<T>. And we need the bound for the latter, so we just add both.
I have added a test to #88 which fixes this with a custom bound override: 3a98799
So what we need to be able to do is control which type params are included in the type_params list, in addition to (or even instead of) the custom bounds.
We still probably need to be able to do this, but it does not on its own resolve the overflow.
Polkadot has the type
Xcm<Call>
which has anOrder<Call>
and anOrder<()>
which in turn has anXcm<Call>
. We get aoverflow evaluating the requirement Vec<order::Order<()>>: TypeInfo
Since
Call
is not directly encoded, seedouble_encoded
, this type parameter does not need to implementEncode/Decode/TypeInfo
To get around this for other derives they are just removing the bounds:
On the surface we should be able to add
#[scale_info(bounds()))]
from #88 to erase the bounds. Though that is not enough on its own because there is stillTypeInfo
requirement for adding totype_params
.So what we need to be able to do is control which type params are included in the
type_params
list, in addition to (or even instead of) the custom bounds.The text was updated successfully, but these errors were encountered: