mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-04-22 17:18:01 +00:00
Prep to release v0.42.0 (#2003)
* Prep to release v0.42.0 * Remove test_context reference from example * standalone_crate for doc tests because codegen is expensive * fmt
This commit is contained in:
@@ -14,7 +14,7 @@ use super::CodegenError;
|
||||
/// Generate constants from the provided pallet's metadata.
|
||||
///
|
||||
/// The function creates a new module named `constants` under the pallet's module.
|
||||
/// ```ignore
|
||||
/// ```rust,ignore
|
||||
/// pub mod PalletName {
|
||||
/// pub mod constants {
|
||||
/// ...
|
||||
|
||||
@@ -13,7 +13,7 @@ use subxt_metadata::PalletMetadata;
|
||||
///
|
||||
/// The function creates a new module named `events` under the pallet's module.
|
||||
///
|
||||
/// ```ignore
|
||||
/// ```rust,ignore
|
||||
/// pub mod PalletName {
|
||||
/// pub mod events {
|
||||
/// ...
|
||||
@@ -24,7 +24,7 @@ use subxt_metadata::PalletMetadata;
|
||||
/// The function generates the events as rust structs that implement the `subxt::event::StaticEvent` trait
|
||||
/// to uniquely identify the event's identity when creating the extrinsic.
|
||||
///
|
||||
/// ```ignore
|
||||
/// ```rust,ignore
|
||||
/// pub struct EventName {
|
||||
/// pub event_param: type,
|
||||
/// }
|
||||
|
||||
@@ -410,19 +410,24 @@ pub struct StructFromVariant {
|
||||
/// Returns the TokenStream of the type alias module.
|
||||
///
|
||||
/// E.g a struct like this:
|
||||
/// ```ignore
|
||||
///
|
||||
/// ```rust,ignore
|
||||
/// pub struct SetMaxCodeSize {
|
||||
/// pub new: ::core::primitive::u32,
|
||||
/// }
|
||||
/// ```
|
||||
///
|
||||
/// will be made into this:
|
||||
/// ```ignore
|
||||
///
|
||||
/// ```rust,ignore
|
||||
/// pub struct SetMaxCodeSize {
|
||||
/// pub new: set_max_code_size::New,
|
||||
/// }
|
||||
/// ```
|
||||
///
|
||||
/// And the type alias module will look like this:
|
||||
/// ```ignore
|
||||
///
|
||||
/// ```rust,ignore
|
||||
/// pub mod set_max_code_size {
|
||||
/// use super::runtime_types;
|
||||
/// pub type New = ::core::primitive::u32;
|
||||
|
||||
+1
-1
@@ -40,7 +40,7 @@ pub use syn;
|
||||
///
|
||||
/// Generating an interface using all of the defaults:
|
||||
///
|
||||
/// ```rust
|
||||
/// ```rust,standalone_crate
|
||||
/// use codec::Decode;
|
||||
/// use subxt_codegen::{ Metadata, CodegenBuilder };
|
||||
///
|
||||
|
||||
Reference in New Issue
Block a user