Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 11 additions & 5 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ html-escape = "0.2.13"
itertools = "0.14.0"
jsonschema = "0.29.1"
num-rational = "0.4.1"
paste = "1.0"
pastey = "0.1.1"
proptest = "1.7.0"
proptest-derive = "0.5.0"
regex = "1.11.2"
Expand All @@ -79,7 +79,7 @@ assert_cmd = "2.0.17"
assert_fs = "1.1.3"
predicates = "3.1.0"
indexmap = "2.11.3"
fxhash = "0.2.1"
rustc-hash = "2.1.1"
bumpalo = "3.19.0"
pathsearch = "0.2.0"
base64 = "0.22.1"
Expand Down
4 changes: 2 additions & 2 deletions hugr-core/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -40,14 +40,14 @@ derive_more = { workspace = true, features = [
] }
downcast-rs = { workspace = true }
enum_dispatch = { workspace = true }
fxhash.workspace = true
html-escape = { workspace = true }
indexmap.workspace = true
itertools = { workspace = true }
paste = { workspace = true }
pastey = { workspace = true }
petgraph = { workspace = true }
portgraph = { workspace = true, features = ["serde", "petgraph"] }
regex = { workspace = true }
rustc-hash.workspace = true
# Rc used here for Extension, but unfortunately we must turn the feature on globally
serde = { workspace = true, features = ["derive", "rc"] }
serde_json = { workspace = true }
Expand Down
2 changes: 1 addition & 1 deletion hugr-core/src/export.rs
Original file line number Diff line number Diff line change
Expand Up @@ -20,14 +20,14 @@ use crate::{
},
};

use fxhash::{FxBuildHasher, FxHashMap};
use hugr_model::v0::bumpalo;
use hugr_model::v0::{
self as model,
bumpalo::{Bump, collections::String as BumpString, collections::Vec as BumpVec},
table,
};
use petgraph::unionfind::UnionFind;
use rustc_hash::{FxBuildHasher, FxHashMap};
use smol_str::ToSmolStr;
use std::fmt::Write;

Expand Down
2 changes: 1 addition & 1 deletion hugr-core/src/hugr/views/sibling_subgraph.rs
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,13 @@ use std::cell::OnceCell;
use std::collections::HashSet;
use std::mem;

use fxhash::FxHashSet;
use itertools::Itertools;
use portgraph::LinkView;
use portgraph::PortView;
use portgraph::algorithms::CreateConvexChecker;
use portgraph::algorithms::convex::{LineIndex, LineIntervals, Position};
use portgraph::boundary::Boundary;
use rustc_hash::FxHashSet;
use thiserror::Error;

use crate::builder::{Container, FunctionBuilder};
Expand Down
2 changes: 1 addition & 1 deletion hugr-core/src/import.rs
Original file line number Diff line number Diff line change
Expand Up @@ -29,10 +29,10 @@ use crate::{
type_row::TypeRowBase,
},
};
use fxhash::FxHashMap;
use hugr_model::v0::table;
use hugr_model::v0::{self as model};
use itertools::{Either, Itertools};
use rustc_hash::FxHashMap;
use smol_str::{SmolStr, ToSmolStr};
use thiserror::Error;

Expand Down
2 changes: 1 addition & 1 deletion hugr-core/src/macros.rs
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ macro_rules! const_extension_ids {
$($(#[$attr])* $v const $field_name: $crate::extension::ExtensionId =
$crate::extension::ExtensionId::new_unchecked($ext_name);

paste::paste! {
pastey::paste! {
#[test]
fn [<check_ $field_name:lower _wellformed>]() {
$crate::extension::ExtensionId::new($ext_name).unwrap();
Expand Down
2 changes: 1 addition & 1 deletion hugr-core/src/ops.rs
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ use crate::{Direction, Node, OutgoingPort, Port};
use crate::{IncomingPort, PortIndex};
use derive_more::Display;
use handle::NodeHandle;
use paste::paste;
use pastey::paste;

use enum_dispatch::enum_dispatch;

Expand Down
4 changes: 2 additions & 2 deletions hugr-core/tests/snapshots/model__roundtrip_add.snap
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,12 @@ expression: ast

(import core.meta.description)

(import core.nat)

(import core.fn)

(import arithmetic.int.types.int)

(import core.nat)

(declare-operation
arithmetic.int.iadd
(param ?0 core.nat)
Expand Down
4 changes: 2 additions & 2 deletions hugr-core/tests/snapshots/model__roundtrip_alias.snap
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,12 @@ expression: ast

(mod)

(import core.type)

(import core.fn)

(import arithmetic.int.types.int)

(import core.type)

(declare-alias local.float core.type)

(define-alias local.int core.type arithmetic.int.types.int)
Expand Down
8 changes: 4 additions & 4 deletions hugr-core/tests/snapshots/model__roundtrip_call.snap
Original file line number Diff line number Diff line change
Expand Up @@ -6,16 +6,16 @@ expression: ast

(mod)

(import core.call)
(import compat.meta_json)

(import core.load_const)
(import core.call)

(import core.fn)

(import compat.meta_json)

(import arithmetic.int.types.int)

(import core.load_const)

(declare-func
public
example.callee
Expand Down
4 changes: 2 additions & 2 deletions hugr-core/tests/snapshots/model__roundtrip_cfg.snap
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,12 @@ expression: ast

(import core.ctrl)

(import core.adt)

(import core.type)

(import core.fn)

(import core.adt)

(define-func public example.cfg_loop (param ?0 core.type) (core.fn [?0] [?0])
(dfg [%0] [%1]
(signature (core.fn [?0] [?0]))
Expand Down
6 changes: 3 additions & 3 deletions hugr-core/tests/snapshots/model__roundtrip_cond.snap
Original file line number Diff line number Diff line change
Expand Up @@ -8,14 +8,14 @@ expression: ast

(import core.meta.description)

(import core.nat)
(import core.adt)

(import core.fn)

(import core.adt)

(import arithmetic.int.types.int)

(import core.nat)

(declare-operation
arithmetic.int.ineg
(param ?0 core.nat)
Expand Down
24 changes: 12 additions & 12 deletions hugr-core/tests/snapshots/model__roundtrip_const.snap
Original file line number Diff line number Diff line change
Expand Up @@ -6,29 +6,29 @@ expression: ast

(mod)

(import collections.array.array)

(import compat.const_json)
(import collections.array.const)

(import core.load_const)
(import core.const)

(import arithmetic.int.const)
(import core.adt)

(import arithmetic.float.const_f64)
(import core.fn)

(import core.const.adt)

(import arithmetic.int.types.int)

(import core.const)
(import arithmetic.int.const)

(import collections.array.const)
(import arithmetic.float.const_f64)

(import arithmetic.float.types.float64)

(import core.fn)
(import core.load_const)

(import core.adt)
(import compat.const_json)

(import arithmetic.int.types.int)

(import collections.array.array)

(define-func
public
Expand Down
10 changes: 5 additions & 5 deletions hugr-core/tests/snapshots/model__roundtrip_constraints.snap
Original file line number Diff line number Diff line change
Expand Up @@ -6,17 +6,17 @@ expression: ast

(mod)

(import collections.array.array)
(import core.fn)

(import core.nat)
(import core.title)

(import core.nonlinear)

(import core.type)
(import core.nat)

(import core.fn)
(import core.type)

(import core.title)
(import collections.array.array)

(declare-func
private
Expand Down
16 changes: 8 additions & 8 deletions hugr-core/tests/snapshots/model__roundtrip_entrypoint.snap
Original file line number Diff line number Diff line change
Expand Up @@ -6,36 +6,36 @@ expression: ast

(mod)

(import core.fn)

(import core.entrypoint)

(import core.fn)

(define-func public main (core.fn [] [])
(meta core.entrypoint)
(dfg (signature (core.fn [] []))))

(mod)

(import core.fn)

(import core.entrypoint)

(import core.fn)

(define-func public wrapper_dfg (core.fn [] [])
(meta core.entrypoint)
(dfg (signature (core.fn [] []))))

(mod)

(import core.entrypoint)

(import core.make_adt)

(import core.ctrl)

(import core.fn)

(import core.entrypoint)

(import core.adt)

(import core.fn)

(define-func public wrapper_cfg (core.fn [] [])
(dfg
(signature (core.fn [] []))
Expand Down
8 changes: 4 additions & 4 deletions hugr-core/tests/snapshots/model__roundtrip_loop.snap
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,13 @@ expression: ast

(import core.make_adt)

(import core.type)

(import core.fn)
(import core.title)

(import core.adt)

(import core.title)
(import core.type)

(import core.fn)

(define-func private _1 (param ?0 core.type) (core.fn [?0] [?0])
(meta (core.title "example.loop"))
Expand Down
Loading
Loading