libqasm 0.6.7__cp39-cp39-macosx_11_0_arm64.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- cqasm/__init__.py +1 -0
- cqasm/v3x/__init__.py +114 -0
- cqasm/v3x/ast.py +11261 -0
- cqasm/v3x/instruction.py +42 -0
- cqasm/v3x/primitives.py +72 -0
- cqasm/v3x/semantic.py +2367 -0
- cqasm/v3x/types.py +1742 -0
- cqasm/v3x/values.py +1714 -0
- libqasm/__init__.py +25 -0
- libqasm/_libqasm.cpython-39-darwin.so +0 -0
- libqasm/libqasm.py +1082 -0
- libqasm-0.6.7.dist-info/LICENSE.md +13 -0
- libqasm-0.6.7.dist-info/METADATA +127 -0
- libqasm-0.6.7.dist-info/RECORD +16 -0
- libqasm-0.6.7.dist-info/WHEEL +5 -0
- libqasm-0.6.7.dist-info/top_level.txt +2 -0
libqasm/__init__.py
ADDED
@@ -0,0 +1,25 @@
|
|
1
|
+
# Author Imran Ashraf, Jeroen van Straten
|
2
|
+
|
3
|
+
import os
|
4
|
+
from sys import version_info
|
5
|
+
|
6
|
+
|
7
|
+
# Before we can import the dynamic modules, we have to set the linker search path appropriately.
|
8
|
+
ld_lib_path = os.environ.get('LD_LIBRARY_PATH', '')
|
9
|
+
if ld_lib_path:
|
10
|
+
ld_lib_path += ':'
|
11
|
+
os.environ['LD_LIBRARY_PATH'] = ld_lib_path + os.path.dirname(__file__)
|
12
|
+
del ld_lib_path, os
|
13
|
+
|
14
|
+
# We only support Python 3
|
15
|
+
if version_info[0] != 3:
|
16
|
+
raise EnvironmentError(
|
17
|
+
"sys.version_info refers does not refer to a version of Python 3. "
|
18
|
+
"This is not permitted. "
|
19
|
+
"sys.version_info = {}".format(version_info))
|
20
|
+
del version_info
|
21
|
+
|
22
|
+
# Import the SWIG-generated module.
|
23
|
+
from .libqasm import *
|
24
|
+
|
25
|
+
# __all__ = [ init, schedule, compile ]
|
Binary file
|