Documentation: decl_module! macro (#2147)

* Add: initial draft of decl_module!, before fact-check

* Add: edits after content review by Guillaume

* style

* add link to event doc

* Changed `nocompile` to `rust,ignore` for docs

* Update srml/support/src/dispatch.rs

Co-Authored-By: nczhu <nicole@parity.io>

* Update dispatch.rs

* Changed examples layout of decl_module macro docs

* style and links

* decl_module doc tests passing

* All doc tests passing for decl_module

* Minor cleanup, comment out doc test imports

* some cleanup

* Update srml/support/src/dispatch.rs

Co-Authored-By: DemiMarie-parity <48690212+DemiMarie-parity@users.noreply.github.com>

* Bump `impl_version` for CI

* Fix indentation

* Update description of Multiple Module Instances

* function definition updates

* restructure example and spelling fixes

* update after review

* `ensure_root` is not a macro

* remove ! from ensure_root in text

* public vs private
This commit is contained in:
Nicole Zhu
2019-04-23 19:52:10 +02:00
committed by Gavin Wood
parent 116e99b6f3
commit 25c529095c
4 changed files with 137 additions and 33 deletions
+2 -2
View File
@@ -299,9 +299,9 @@ impl<N> OnInitialize<N> for () {}
/// Off-chain computation trait.
///
/// Implementing this trait on a module allows you to perform a long-running tasks
/// Implementing this trait on a module allows you to perform long-running tasks
/// that make validators generate extrinsics (either transactions or inherents)
/// with results of those long-running computations.
/// with the results of those long-running computations.
///
/// NOTE: This function runs off-chain, so it can access the block state,
/// but cannot preform any alterations.