OpenQASM 3 language features

Below is a list of the OpenQASM 3 language features, separated into basic OpenQASM 3 language features.

For more details on these capabilities, see the OpenQASM 3.X Live Specification .

Key:

  • ❌ Not supported

  • 🟡 Partial support

  • ✅ Supported

Feature

Support

Comments

comments

QASM version string

include

unicode names

qubit

🟡

Only supports physical qubits, and no arrays.

bit

bool

int

Some support for comparisons against integers and casting.

uint

float

angle

complex

const

pi/π/tau/τ/euler/

Aliasing: let

register concatenation

casting

🟡

Casting between arrays of bits, int, and bool is supported

duration

durationof

ns/µs/us/ms/s/dt

stretch

delay

barrier

box

Built-in U

gate

No support for non-basis gates

gphase

ctrl @/ negctrl @

inv @

pow(k) @

reset

measure

bit operations

boolean operations

arithmetic expressions

comparisons

if

else

else if

for loops

🟡

Discrete sets and negative stepping is not supported.

while loops

continue

break

return

extern

🟡

Only for certain extern subroutines exposed by backend devices. It is currently not possible for clients to submit these.

def subroutines (classical)

def subroutines (quantum)

input

output