Skip to content

Commit

Permalink
change doc test in derive_codec
Browse files Browse the repository at this point in the history
  • Loading branch information
Shourya742 committed Dec 9, 2024
1 parent 0c8ae33 commit 0ba42e4
Showing 1 changed file with 10 additions and 10 deletions.
20 changes: 10 additions & 10 deletions protocols/v2/binary-sv2/no-serde-sv2/derive_codec/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ use proc_macro::{Group, TokenStream, TokenTree};
//
// # Example
//
// ```rust
// ```ignore
// use proc_macro2::{Delimiter, Group, Ident, Span, TokenStream, TokenTree};
// use quote::quote;
//
Expand Down Expand Up @@ -115,7 +115,7 @@ fn is_already_sized(item: TokenStream) -> bool {
//
// # Example
//
// ```rust
// ```ignore
// use proc_macro2::{Delimiter, Group, TokenStream, TokenTree};
// use quote::quote;
//
Expand Down Expand Up @@ -192,7 +192,7 @@ enum ParserState {
//
// # Examples
//
// ```
// ```ignore
// struct MyStruct<T> {
// pub field1: i32,
// pub field2: String,
Expand Down Expand Up @@ -229,7 +229,7 @@ struct ParsedStruct {
//
// # Examples
//
// ```
// ```ignore
// // Given a struct field definition:
// // data: Option<T>,
//
Expand Down Expand Up @@ -282,7 +282,7 @@ impl ParsedField {
//
// # Examples
//
// ```
// ```ignore
// use quote::quote;
//
// struct MyStruct<T> {
Expand Down Expand Up @@ -366,7 +366,7 @@ fn get_struct_properties(item: TokenStream) -> ParsedStruct {
//
// # Examples
//
// ```
// ```ignore
// struct MyStruct<T> {
// field1: i32,
// }
Expand Down Expand Up @@ -464,7 +464,7 @@ fn parse_struct_fields(group: Vec<TokenTree>) -> Vec<ParsedField> {
///
/// Given a struct:
///
/// ```
/// ```ignore
/// struct Test {
/// a: u32,
/// b: u8,
Expand All @@ -474,7 +474,7 @@ fn parse_struct_fields(group: Vec<TokenTree>) -> Vec<ParsedField> {
///
/// Using `#[derive(Decodable)]` on `Test` generates the following implementations:
///
/// ```rust
/// ```ignore
/// mod impl_parse_decodable_test {
/// use super::{
/// binary_codec_sv2::{
Expand Down Expand Up @@ -705,7 +705,7 @@ fn get_static_generics(gen: &str) -> &str {
///
/// Given a struct:
///
/// ```
/// ```ignore
/// struct Test {
/// a: u32,
/// b: u8,
Expand All @@ -715,7 +715,7 @@ fn get_static_generics(gen: &str) -> &str {
///
/// Using `#[derive(Encodable)]` on `Test` generates the following implementations:
///
/// ```rust
/// ```ignore
/// mod impl_parse_encodable_test {
/// use super::binary_codec_sv2::{encodable::EncodableField, GetSize};
/// extern crate alloc;
Expand Down

0 comments on commit 0ba42e4

Please sign in to comment.