Skip to content

Conversation

@acl-cqc
Copy link
Contributor

@acl-cqc acl-cqc commented Jan 9, 2026

Guess I hit merge on #2800 slightly too soon, although in practice it makes no difference: the old code would have computed containing_func as being the module root, and so recursively processed ("replace_with_opts") the entrypoint-subtree twice (once before and once after insertion); however, the second would have done nothing. So perhaps this is a small performance optimization ;), but mostly for correctness-of-variable-name and readability!

@codecov
Copy link

codecov bot commented Jan 9, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 83.71%. Comparing base (3a76b3e) to head (bb21344).
⚠️ Report is 1 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #2807   +/-   ##
=======================================
  Coverage   83.71%   83.71%           
=======================================
  Files         261      261           
  Lines       52635    52637    +2     
  Branches    47376    47378    +2     
=======================================
+ Hits        44061    44064    +3     
+ Misses       6184     6183    -1     
  Partials     2390     2390           
Flag Coverage Δ
python 88.85% <ø> (ø)
rust 83.14% <100.00%> (+<0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@acl-cqc acl-cqc marked this pull request as ready for review January 9, 2026 08:56
@acl-cqc acl-cqc requested a review from a team as a code owner January 9, 2026 08:56
@acl-cqc acl-cqc requested a review from mark-koch January 9, 2026 08:56
@acl-cqc acl-cqc changed the title fix(ReplaceTypes): computation of containing_func refactor(ReplaceTypes): [tiny] correct computation of containing_func Jan 9, 2026
@acl-cqc acl-cqc enabled auto-merge January 9, 2026 09:09
@acl-cqc acl-cqc added this pull request to the merge queue Jan 9, 2026
Merged via the queue into main with commit 960ccfa Jan 9, 2026
33 checks passed
@acl-cqc acl-cqc deleted the acl/fix_containing_func branch January 9, 2026 09:13
@hugrbot hugrbot mentioned this pull request Jan 9, 2026
github-merge-queue bot pushed a commit that referenced this pull request Jan 9, 2026
## 🤖 New release

* `hugr-model`: 0.25.2 -> 0.25.3 (✓ API compatible changes)
* `hugr-core`: 0.25.2 -> 0.25.3 (✓ API compatible changes)
* `hugr-llvm`: 0.25.2 -> 0.25.3 (✓ API compatible changes)
* `hugr-passes`: 0.25.2 -> 0.25.3 (✓ API compatible changes)
* `hugr-persistent`: 0.4.2 -> 0.4.3 (✓ API compatible changes)
* `hugr`: 0.25.2 -> 0.25.3 (✓ API compatible changes)
* `hugr-cli`: 0.25.2 -> 0.25.3 (✓ API compatible changes)

<details><summary><i><b>Changelog</b></i></summary><p>

## `hugr-model`

<blockquote>

##
[0.25.0](hugr-model-v0.24.3...hugr-model-v0.25.0)
- 2025-12-22

### Bug Fixes

- *(model)* avoid non abi-compatible pyo3 calls
([#2679](#2679))

### New Features

- [**breaking**] Upgrade pyo3 dependency to 0.27
([#2736](#2736))

### Refactor

- Direct import of model representation to Python
([#2683](#2683))
</blockquote>

## `hugr-core`

<blockquote>

##
[0.25.3](hugr-core-v0.25.2...hugr-core-v0.25.3)
- 2026-01-09

### Bug Fixes

- more nondeterminism in linking
([#2792](#2792))

### Documentation

- Add collection extension ops to the spec
([#2767](#2767))
</blockquote>

## `hugr-llvm`

<blockquote>

##
[0.25.0](hugr-llvm-v0.24.3...hugr-llvm-v0.25.0)
- 2025-12-22

### New Features

- *(llvm)* [**breaking**] upgrade to inkwell 0.7
([#2695](#2695))

### Refactor

- Deprecate Value::Function and inline_constant_functions
([#2770](#2770))
</blockquote>

## `hugr-passes`

<blockquote>

##
[0.25.3](hugr-passes-v0.25.2...hugr-passes-v0.25.3)
- 2026-01-09

### Bug Fixes

- *(hugr-passes)* Recursive replacement on NodeTemplate::LinkedHugr
([#2800](#2800))

### Refactor

- *(ReplaceTypes)* [tiny] correct computation of containing_func
([#2807](#2807))
</blockquote>

## `hugr-persistent`

<blockquote>

##
[0.4.0](hugr-persistent-v0.3.4...hugr-persistent-v0.4.0)
- 2025-12-22

### New Features

- [**breaking**] Remove `RootCheckable`
([#2704](#2704))
- [**breaking**] Bump MSRV to Rust 1.89
([#2747](#2747))
- [**breaking**] Type-safe access for node metadata
([#2755](#2755))

### Refactor

- [**breaking**] Remove multiple deprecated definitions
([#2751](#2751))
</blockquote>

## `hugr`

<blockquote>

##
[0.25.3](hugr-v0.25.2...hugr-v0.25.3)
- 2026-01-09

### Bug Fixes

- *(hugr-passes)* Recursive replacement on NodeTemplate::LinkedHugr
([#2800](#2800))
- more nondeterminism in linking
([#2792](#2792))

### Documentation

- Add collection extension ops to the spec
([#2767](#2767))

### Refactor

- *(ReplaceTypes)* [tiny] correct computation of containing_func
([#2807](#2807))
</blockquote>

## `hugr-cli`

<blockquote>

##
[0.25.0](hugr-cli-v0.24.3...hugr-cli-v0.25.0)
- 2025-12-22

### New Features

- *(cli, python)* programmatic interface to cli with python bindings
([#2677](#2677))
- return description output to python on error
([#2681](#2681))
- [**breaking**] Type-safe access for node metadata
([#2755](#2755))
- [**breaking**] GeneratorDesc metadata definition
([#2759](#2759))

### Refactor

- [**breaking**] move envelope reading to dedicated module with
dedicated errors ([#2689](#2689))
- *(cli)* [**breaking**] remove deprecated hugr_json handling
([#2690](#2690))
- [**breaking**] Remove multiple deprecated definitions
([#2751](#2751))
</blockquote>


</p></details>

---
This PR was generated with
[release-plz](https://github.com/release-plz/release-plz/).
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants