Commit 4b38008
authored
feat: Add HugrMut::insert(_view)_forest (#2518)
closes #2500, #2496
* New trait methods can insert several subtrees at once at different
locations in target Hugr
* trait-default-implement `insert_hugr`, `insert_view` and
`insert_subgraph` using these
Technically I think this is breaking, any external `impl HugrMut` now
has to provide these new methods, but we believe implementations of
HugrMut outside of hugr-core to be sufficiently rare not to justify a
major-version-number release, and rs-semver-checks does not seem to pick
up on this.1 parent 38378dc commit 4b38008
6 files changed
Lines changed: 465 additions & 101 deletions
File tree
- hugr-core/src
- builder
- hugr
- views
- hugr/benches/benchmarks
- hugr
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
99 | 99 | | |
100 | 100 | | |
101 | 101 | | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
102 | 105 | | |
103 | 106 | | |
104 | 107 | | |
| |||
256 | 259 | | |
257 | 260 | | |
258 | 261 | | |
259 | | - | |
| 262 | + | |
| 263 | + | |
| 264 | + | |
260 | 265 | | |
261 | 266 | | |
262 | 267 | | |
| |||
0 commit comments