#open-qasm #parser #path #2-0

openqasm-parser

A parser for openqasm2

3 releases (1 stable)

1.0.0 Mar 29, 2023
0.1.1 Mar 27, 2023
0.1.0 Mar 27, 2023

#394 in Simulation

Download history 1/week @ 2025-08-16 3/week @ 2025-08-23 3/week @ 2025-09-27 6/week @ 2025-10-04 4/week @ 2025-10-18 1/week @ 2025-10-25

75 downloads per month
Used in quaru

MIT license

92KB
2K SLoC

A parser for openqasm 2.0.

Example

use openqasm_parser::openqasm;
use std::path::Path;

let program = openqasm::parse_openqasm(Path::new("openqasmfile.qasm"));

openqasm

A parser for openqasm 2.0 written in Rust.

Developed primarily to be used with the quantum simulator quaru (https://github.com/DATX11-22/quaru).

crate: https://crates.io/crates/openqasm-parser

No runtime deps