Relax BoundedVec trait restrictions (#8749)

* requiring users to maintain an unchecked invariant is unsafe

* relax trait restrictions on BoundedVec<T, S>

A normal `Vec<T>` can do many things without any particular trait
bounds on `T`. This commit relaxes the bounds on `BoundedVec<T, S>`
to give it similar capabilities.
This commit is contained in:
Peter Goodspeed-Niklaus
2021-05-07 22:04:16 +02:00
committed by GitHub
parent 9e894ce135
commit b689790171
6 changed files with 156 additions and 115 deletions
+1 -1
View File
@@ -1238,7 +1238,7 @@ pub mod pallet_prelude {
dispatch::{DispatchResultWithPostInfo, Parameter, DispatchError, DispatchResult},
weights::{DispatchClass, Pays, Weight},
storage::types::{StorageValue, StorageMap, StorageDoubleMap, ValueQuery, OptionQuery},
storage::bounded_vec::{BoundedVec, BoundedVecValue},
storage::bounded_vec::BoundedVec,
};
pub use codec::{Encode, Decode};
pub use crate::inherent::{InherentData, InherentIdentifier, ProvideInherent};