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

Qiskit / qiskit-terra / 5616085257
87%

Build:
DEFAULT BRANCH: main
Ran 20 Jul 2023 10:14PM UTC
Jobs 1
Files 1259
Run time 22s
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

pending completion
5616085257

push

github

web-flow
Add `Expr` support to OpenQASM 3 exporter (#10408)

* Add `Expr` support to OpenQASM 3 exporter

This adds support for `Expr` nodes in `condition` fields and
`SwitchCaseOp.target`.  The general `c_if` condition checking is lifted
into an `Expr` node as part of the OQ3 export, so the form of them
automatically becomes like the new-style outputs, depending on how
`expr.lift_legacy_condition` chooses to raise them to `Expr` nodes.

As part of the refactor of the `Expression` subtree of the temporary
AST, I removed `SubroutineCall`.  Its definition was severely
out-of-date (a form from before even the initial arXiv draft), where it
was statement-like instead of expression-like.  There is currently no
support in Qiskit for representing these sorts of subroutines properly,
and the OQ3 exporter would produce invalid OQ3 if it encountered
something that it thought should be a a subroutine call.  This commit
fixes that bug, correctly raising an exception that non-unitary
instructions are not yet supported for export.

This commit also removes the special casing from the `CXGate` into the
exporter itself; it was more convenient in the new structure of some
internal components, and it's a data model we don't want to support
anyway.

* Use `IntegerLiteral` for `Uint` values

This is what the QSS stack expects (they don't like bitstring literals
in expressions yet), and is more in line with what we used to do anyway.

* Fix quotes

* Add test of no spurious casts

166 of 166 new or added lines in 3 files covered. (100.0%)

72845 of 84780 relevant lines covered (85.92%)

58883.11 hits per line

Jobs
ID Job ID Ran Files Coverage
1 5616085257.1 20 Jul 2023 10:14PM UTC 0
85.92
GitHub Action Run
Source Files on build 5616085257
Detailed source file information is not available for this build.
  • Back to Repo
  • d13f0bba on github
  • Prev Build on gh-readonly-queue/main/pr-10355-9a78e11528451273b260ff09f0707dc1a6756cfb (#5615305925)
  • Next Build on main (#5616442880)
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