microsoft / qsharp

Azure Quantum Development Kit, including the Q# programming language, resource estimator, and Quantum Katas
https://microsoft.github.io/qsharp/
MIT License
367 stars 73 forks source link

Wrong linter warning for operation that calls operation #1661

Closed msoeken closed 2 days ago

msoeken commented 4 days ago

Describe the bug

An operation that does not manipulate any qubits directly inside the operation, but calls another operation that does, is suggested to be changed to a function, but it cannot.

To Reproduce

Q# playground sample

Expected behavior

No warning should be emitted.