Skip to content

PossibleValueSet merging api #7759

@mostobriv

Description

@mostobriv

What is the feature you'd like to have?
Sometimes when developing workflows or some scripts I need to traverse PVS and then get the accumulated PVS of some variable (mostly this happened in cases when BN automatically fails to build PVS by itself), in this cases ability to merge one PVS with another is helpful, however current python api is lacking of such feature.

So, I think, having __add__ and __iadd__ for PossibleValueSet class would be a handy QoL feature.

  • UndeterminedValue + Any == UndeterminedValue or exception
  • ConstantValue / ConstantPointerValue + ConstantValue / ConstantPointerValue == InSetOfValues or (in case of equality) ConstantPointerValue
  • InSetOfValues + InSetOfValues == InSetOfValues
  • NotInSetOfValues + NotInSetOfValues == NotInSetOfValues
  • etc.

Metadata

Metadata

Assignees

Labels

Component: APIIssue needs changes to the APIComponent: Python APIIssue needs changes to the python APIComponent: Rust APIIssue needs changes to the Rust APICore: DataflowRelated to the Possible Value Set and Register Value systemsEffort: LowIssues require < 1 week of workImpact: MediumIssue is impactful with a bad, or no, workaround

Type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions