Commits
Click on a commit to change the comparison rangeci: Run ci checks on PRs to any branch feat!: Allow generic Nodes in HugrMut insert operations (#2075)
`insert_hugr`, `insert_from_view`, and `insert_subgraph` were written
before we made `Node` a type generic, and incorrectly assumed the return
type maps were always `hugr::Node`s.
The methods were either unusable or incorrect when using generic
`HugrView`s source/targets with non-base node types.
This PR fixes that, and additionally allows us us to have
`SiblingSubgraph::extract_subgraph` work for generic `HugrViews`.
BREAKING CHANGE: Added Node type parameters to extraction operations in
`HugrMut`. fix!: Don't expose `HugrMutInternals` (#2071)
`HugrMutInternals` is part of the semi-private traits defined in
`hugr-core`.
While most things get re-exported in `hugr`, we `*Internal` traits
require you to explicitly declare a dependency on the `-core` package
(as we don't want most users to have to interact with them).
For some reason there was a public re-export of the trait in a
re-exported module, so it ended up appearing in `hugr` anyways.
BREAKING CHANGE: Removed public re-export of `HugrMutInternals` from
`hugr`. feat!: Mark all Error enums as non_exhaustive (#2056)
#2027 ended up being breaking due to adding a new variant to an error
enum missing the `non_exhaustive` marker.
This (breaking) PR makes sure all error enums have the flag.
BREAKING CHANGE: Marked all Error enums as `non_exhaustive` feat!: Handle CallIndirect in Dataflow Analysis (#2059)
* PartialValue now has a LoadedFunction variant, created by LoadFunction nodes (only, although other analyses are able to create PartialValues if they want)
* This requires adding a type parameter to PartialValue for the type of Node, which gets everywhere :-(.
* Use this to handle CallIndirects *with known targets* (it'll be a single known target or none at all) just like other Calls to the same function
* deprecate (and ignore) `value_from_function`
* Add a new trait `AsConcrete` for the result type of `PartialValue::try_into_concrete` and `PartialSum::try_into_sum`
Note almost no change to constant folding (only to drop impl of `value_from_function`)
BREAKING CHANGE: in dataflow framework, PartialValue now has additional variant; `try_into_concrete` requires the target type to implement AsConcrete. Merge branch 'main' into release-rs-v0.16.0 feat: Make NodeHandle generic (#2092)
Adds a generic node type to the `NodeHandle` type.
This is a required change for #2029.
drive-by: Implement the "Link the NodeHandles to the OpType" TODO feat!: remove ExtensionValue (#2093)
Closes #1595
BREAKING CHANGE: `values` field in `Extension` and `ExtensionValue`
struct/class removed in rust and python. Use 0-input ops that return
constant values.