Introduce default-setting prime for collective (#5137)

* Introduce default-setting prime for collective

* Docs.

* Elections phragmen supports prime

* Fix

* Membership supports prime

* Fix

* Update frame/collective/src/lib.rs

Co-Authored-By: Shawn Tabrizi <shawntabrizi@gmail.com>

Co-authored-by: Shawn Tabrizi <shawntabrizi@gmail.com>
This commit is contained in:
Gavin Wood
2020-03-05 15:57:03 +01:00
committed by GitHub
parent d3208aa7bc
commit 0573f1408d
7 changed files with 399 additions and 50 deletions
@@ -73,6 +73,10 @@ pub trait StorageValue<T: FullCodec> {
/// Store a value under this key into the provided storage instance.
fn put<Arg: EncodeLike<T>>(val: Arg);
/// Store a value under this key into the provided storage instance; this uses the query
/// type rather than the underlying value.
fn set(val: Self::Query);
/// Mutate the value
fn mutate<R, F: FnOnce(&mut Self::Query) -> R>(f: F) -> R;