hugr_core/
std_extensions.rs1use crate::extension::ExtensionRegistry;
6
7pub mod arithmetic;
8pub mod collections;
9pub mod logic;
10pub mod ptr;
11
12pub fn std_reg() -> ExtensionRegistry {
14 let reg = ExtensionRegistry::new([
15 crate::extension::prelude::PRELUDE.clone(),
16 arithmetic::int_ops::EXTENSION.to_owned(),
17 arithmetic::int_types::EXTENSION.to_owned(),
18 arithmetic::conversions::EXTENSION.to_owned(),
19 arithmetic::float_ops::EXTENSION.to_owned(),
20 arithmetic::float_types::EXTENSION.to_owned(),
21 collections::array::EXTENSION.to_owned(),
22 collections::list::EXTENSION.to_owned(),
23 collections::static_array::EXTENSION.to_owned(),
24 logic::EXTENSION.to_owned(),
25 ptr::EXTENSION.to_owned(),
26 ]);
27 reg.validate()
28 .expect("Standard extension registry is valid");
29 reg
30}
31
32lazy_static::lazy_static! {
33 pub static ref STD_REG: ExtensionRegistry = std_reg();
35}