1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54
#![cfg_attr(feature = "nightly", feature(never_type))]
#![warn(missing_docs)]
//! Hydroflow is a low-level dataflow-based runtime system for the [Hydro Project](https://hydro.run/).
//!
//! The primary item in this crate is the [`Hydroflow`](crate::scheduled::graph::Hydroflow) struct,
//! representing a Hydroflow dataflow graph. Although this graph can be manually constructed, the
//! easiest way to instantiate a `Hydroflow` instance is with the [`hydroflow_syntax!`] macro using
//! Hydroflow's custom "surface syntax."
//!
//! ```rust
//! let mut hf = hydroflow::hydroflow_syntax! {
//! source_iter(["hello", "world"]) -> for_each(|s| println!("{}", s));
//! };
//! hf.run_available();
//! ```
//!
//! For more examples, check out the [`examples` folder on Github](https://github.com/hydro-project/hydroflow/tree/main/hydroflow/examples).
pub mod compiled;
pub mod scheduled;
pub mod util;
#[cfg(feature = "python")]
pub use pyo3;
pub use variadics::{self, var_args, var_expr, var_type};
pub use {
bincode, bytes, futures, hydroflow_lang as lang, itertools, lattices, pusherator, rustc_hash,
serde, serde_json, tokio, tokio_stream, tokio_util, tracing, web_time,
};
/// `#[macro_use]` automagically brings the declarative macro export to the crate-level.
mod declarative_macro;
#[cfg(feature = "hydroflow_datalog")]
pub use hydroflow_datalog::*;
#[cfg(feature = "hydroflow_macro")]
pub use hydroflow_macro::{
hydroflow_main as main, hydroflow_parser, hydroflow_syntax, hydroflow_syntax_noemit,
hydroflow_test as test, monotonic_fn, morphism, DemuxEnum,
};
/// Stand-in for the [nightly "never" type `!`](https://doc.rust-lang.org/std/primitive.never.html)
#[cfg(not(feature = "nightly"))]
pub type Never = std::convert::Infallible;
/// The [nightly "never" type `!`](https://doc.rust-lang.org/std/primitive.never.html)
#[cfg(feature = "nightly")]
pub type Never = !;
#[cfg(doctest)]
mod booktest {
mod surface_ops {
hydroflow_macro::surface_booktest_operators!();
}
}