microsoft / microsoft/qdk

Support aggregating generators for classically dynamic callable selection

Open
#1,392 0 comments 0 reactions 1 assignee Claimed by @cesarzc View on GitHub
enhancement low-priority
Dominant language
Rust
Stars
1k
Forks
212
Avg merge
3d 8h
Merged PRs (30d)
65

Description

When an exact callable is a result of a classically dynamic selection, RCA doesn't know which callable generator to use and can't perform further analysis. For example:
```qsharp
let cond = true;
let f = if cond { op1 } else { op2 };
f()
```
Even though the condition is a compile time constant, this might be across longer calculation that makes it non-obvious which callable will be invoked on the last line. To handle this, RCA would need some fairly complex mechanism for aggregating across arbitrary code the resulting generators to use the sum of the dynamism. Note that a single if-statement might be easy, but they can be arbitrarily nested, call functions that return callables, or select callables from within an array, so while this aggregation should be possible it is not straightforward.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.