hugr_core/
lib.rs

1//! Extensible, graph-based program representation with first-class support for linear types.
2//!
3//! This crate contains the core definitions for the HUGR representation.
4//! See the [top-level crate documentation](https://docs.rs/hugr/latest/hugr/) for more information.
5
6// proptest-derive generates many of these warnings.
7// https://github.com/rust-lang/rust/issues/120363
8// https://github.com/proptest-rs/proptest/issues/447
9#![cfg_attr(test, allow(non_local_definitions))]
10#![cfg_attr(coverage_nightly, feature(coverage_attribute))]
11
12pub mod builder;
13pub mod core;
14pub mod envelope;
15pub mod export;
16pub mod extension;
17pub mod hugr;
18pub mod import;
19pub mod macros;
20pub mod ops;
21pub mod package;
22pub mod std_extensions;
23pub mod types;
24pub mod utils;
25
26pub use crate::core::{
27    CircuitUnit, Direction, IncomingPort, Node, NodeIndex, OutgoingPort, Port, PortIndex,
28    Visibility, Wire,
29};
30pub use crate::extension::Extension;
31pub use crate::hugr::{Hugr, HugrView, SimpleReplacement};
32
33#[cfg(test)]
34pub mod proptest;