Skip to main content

miden_protocol/
lib.rs

1#![no_std]
2
3#[macro_use]
4extern crate alloc;
5
6#[cfg(feature = "std")]
7extern crate std;
8
9pub mod account;
10pub mod address;
11pub mod asset;
12pub mod batch;
13pub mod block;
14pub mod errors;
15pub mod note;
16pub mod package;
17mod protocol;
18pub mod transaction;
19
20#[cfg(any(feature = "testing", test))]
21pub mod testing;
22
23mod constants;
24
25// RE-EXPORTS
26// ================================================================================================
27
28pub use constants::*;
29pub use miden_core::mast::{MastForest, MastNodeId};
30pub use miden_core::prettier::PrettyPrint;
31pub use miden_core::{EMPTY_WORD, Felt, ONE, WORD_SIZE, ZERO, field};
32pub use miden_core_lib::CoreLibrary;
33pub use miden_crypto::hash::poseidon2::Poseidon2 as Hasher;
34pub use miden_crypto::word;
35pub use miden_crypto::word::{Word, WordError};
36pub use protocol::ProtocolLib;
37
38pub mod assembly {
39    pub use miden_assembly::ast::{Module, ModuleKind, ProcedureName, QualifiedProcedureName};
40    pub use miden_assembly::debuginfo::SourceManagerSync;
41    pub use miden_assembly::{
42        Assembler,
43        DefaultSourceManager,
44        Linkage,
45        ModuleParser,
46        Path,
47        SourceFile,
48        SourceId,
49        SourceManager,
50        SourceSpan,
51        debuginfo,
52        diagnostics,
53        mast,
54    };
55    pub use miden_assembly_syntax::Parse;
56    pub use miden_mast_package::{
57        Package as KernelLibrary,
58        Package as Library,
59        PackageExport as LibraryExport,
60        ProcedureExport,
61    };
62}
63
64pub mod crypto {
65    pub use miden_crypto::{SequentialCommit, dsa, hash, ies, merkle, rand, utils};
66}
67
68pub mod utils;
69
70pub mod vm {
71    pub use miden_assembly_syntax::ast::{AttributeSet, QualifiedProcedureName};
72    pub use miden_core::advice::{AdviceInputs, AdviceMap};
73    pub use miden_core::events::{EventId, EventName, SystemEvent};
74    pub use miden_core::program::{Program, ProgramInfo};
75    pub use miden_mast_package::debug_info::{DebugSourceNodeId, PackageDebugInfo};
76    pub use miden_mast_package::{
77        Package,
78        PackageDebugInfoError,
79        PackageExport,
80        PackageManifest,
81        ProcedureExport,
82        Section,
83        SectionId,
84        TargetType,
85    };
86    pub use miden_processor::trace::RowIndex;
87    pub use miden_processor::{FutureMaybeSend, MIN_STACK_DEPTH, StackInputs, StackOutputs};
88    pub use miden_verifier::ExecutionProof;
89}