hyperstack-macros 0.6.6

Proc-macros for defining HyperStack streams
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
//! Vixen parser generation from IDL specifications.
//!
//! Generates account parsers and instruction parsers for yellowstone-vixen runtime.

use crate::parse::idl::IdlSpec;
use proc_macro2::TokenStream;

/// Generate Vixen parsers for accounts and instructions from an IDL spec.
///
/// This is the equivalent of `idl_parser_gen::generate_parsers`.
pub fn generate_parsers_from_idl(
    idl: &IdlSpec,
    program_id: &str,
    sdk_module_name: &str,
) -> TokenStream {
    crate::idl_parser_gen::generate_parsers(idl, program_id, sdk_module_name)
}