• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

Qiskit / qiskit / 7051979172 / 1
87%
main: 88%

Build:
Build:
LAST BUILD BRANCH: stable/2.3
DEFAULT BRANCH: main
Ran 30 Nov 2023 08:56PM UTC
Files 984
Run time 27s
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

30 Nov 2023 08:35PM UTC coverage: 87.431% (+0.02%) from 87.414%
7051979172.1

push

github

web-flow
Track runtime variables in control-flow builders (#10977)

* Track runtime variables in control-flow builders

This adds support for all the new classical runtime variables through
the control-flow builder interface.  In particular, most usefully it
automatically manages the scoping rules for new declarations and inner
variable accesses, and ensures that its built scopes automatically close
over any variables used within them (including making sure nested scopes
do the same thing).

The builder API is factored out a little into an explicit interface
object, with `QuantumCircuit` getting an explicit implementation of
that.  This is done because the number of separate API methods we would
have needed to pass around / infer was getting overly large, and this
allows us to just use standard virtual dispatch to automatically do the
right thing.

Python doesn't have a way to have an object implement an
interface other than by structural (duck) typing, so to avoid name
leakage and collisions, we instead make `QuantumCircuit`'s
implementation a friend class that handles the inner state on its
behalf.

Not everything control-flow-builder related is factored out into the API
because it didn't seem overly useful to do this, especially when the
overridden behaviour would just have been to throw exceptions.

* :us:

Co-authored-by: Matthew Treinish <mtreinish@kortar.org>

* More descriptive variable name

* Remove superfluous private statement

---------

Co-authored-by: Matthew Treinish <mtreinish@kortar.org>

59904 of 68516 relevant lines covered (87.43%)

275973.03 hits per line

Source Files on job 7051979172.1
  • Tree
  • List 0
  • Changed 28
  • Source Changed 0
  • Coverage Changed 5
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Build 7051979172
  • a79e8796 on github
  • Prev Job for on gh-readonly-queue/main/pr-10977-c0702bf66d2e51678feceebbc3c09b674560d674 (#7047993505.1)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc