libqasm
library for handling cQASM files
|
This directory contains the sources for the original API compatibility layer, intended to be used by projects relying on the original libqasm/liblexgram interface, both in the C++ and Python worlds.
File list:
libQasm.hpp
: contains the entry points for the original API. This is the file you would include in your project to use the original API. The entry points here call into qasm_semantic.hpp
to read a given cQASM file.qasm_semantic.hpp
: contains the code that orchestrates reading a cQASM file into the in-memory representation defined in qasm_ast.hpp
, and to do some checks on the result. Originally, this would call into the flex/bison-generated code to construct the AST from a given file, but now it calls into qasm_new_to_old.hpp
to use the new API to do that instead.qasm_ast.hpp
: contains the classes used to represent a cQASM file in memory.qasm_new_to_old.hpp
: contains the translation logic to convert the semantic tree format generated by the new API into the format defined in qasm_ast.hpp
.qasm_data.hpp
: artifact remaining from the flex/bison grammar that was here originally. Maintained only because it is technically a public header file, but otherwise the code inside is unused.CMakeLists.txt
: the CMake build instructions for the compatibility layer.