Skip to content
Snippets Groups Projects
Commit b8514409 authored by Dan Shields's avatar Dan Shields Committed by GitHub
Browse files

Clarify wieght traits needed to impl in example (#9842)


* Clarify wieght traits needed to impl in example

* Update frame/example/src/lib.rs

* Update frame/example/src/lib.rs

Co-authored-by: default avatarGuillaume Thiolliere <gui.thiolliere@gmail.com>

* fmt

Co-authored-by: default avatarSquirrel <gilescope@gmail.com>
Co-authored-by: default avatarGuillaume Thiolliere <gui.thiolliere@gmail.com>
parent 403b348d
Branches
No related merge requests found
......@@ -486,11 +486,12 @@ pub mod pallet {
// the chain in a moderate rate.
//
// The parenthesized value of the `#[pallet::weight(..)]` attribute can be any type that
// implements a set of traits, namely [`WeighData`] and [`ClassifyDispatch`].
// The former conveys the weight (a numeric representation of pure execution time and
// difficulty) of the transaction and the latter demonstrates the [`DispatchClass`] of the
// call. A higher weight means a larger transaction (less of which can be placed in a
// single block).
// implements a set of traits, namely [`WeighData`], [`ClassifyDispatch`], and
// [`PaysFee`]. The first conveys the weight (a numeric representation of pure
// execution time and difficulty) of the transaction and the second demonstrates the
// [`DispatchClass`] of the call, the third gives whereas extrinsic must pay fees or not.
// A higher weight means a larger transaction (less of which can be placed in a single
// block).
//
// The weight for this extrinsic we rely on the auto-generated `WeightInfo` from the
// benchmark toolchain.
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment