diff options
author | Patrick Lehmann <Patrick.Lehmann@plc2.de> | 2021-06-17 13:49:20 +0200 |
---|---|---|
committer | Unai Martinez-Corral <38422348+umarcor@users.noreply.github.com> | 2021-06-17 22:53:27 +0100 |
commit | f65fff4d5e3a33e83c633eb20fd367e349f3dc92 (patch) | |
tree | 66e3fb6afc69738b28bcaaf908a09c13143615e7 /pyGHDL/libghdl/vhdl/std_package.py | |
parent | 56f8ca47465a7cc052e80c0ed4bab6fc55eeacba (diff) | |
download | ghdl-f65fff4d5e3a33e83c633eb20fd367e349f3dc92.tar.gz ghdl-f65fff4d5e3a33e83c633eb20fd367e349f3dc92.tar.bz2 ghdl-f65fff4d5e3a33e83c633eb20fd367e349f3dc92.zip |
Using a decorator to bind libghdl to Python.
Diffstat (limited to 'pyGHDL/libghdl/vhdl/std_package.py')
-rw-r--r-- | pyGHDL/libghdl/vhdl/std_package.py | 34 |
1 files changed, 20 insertions, 14 deletions
diff --git a/pyGHDL/libghdl/vhdl/std_package.py b/pyGHDL/libghdl/vhdl/std_package.py index 53cbb7076..690dc78a4 100644 --- a/pyGHDL/libghdl/vhdl/std_package.py +++ b/pyGHDL/libghdl/vhdl/std_package.py @@ -6,9 +6,9 @@ # | .__/ \__, |\____|_| |_|____/|_____(_)_|_|_.__/ \__, |_| |_|\__,_|_| # |_| |___/ |___/ # ============================================================================= -# Authors: -# Tristan Gingold -# Patrick Lehmann +# Authors: +# Tristan Gingold +# Patrick Lehmann # # Package module: Python binding and low-level API for shared library 'libghdl'. # @@ -35,15 +35,21 @@ from ctypes import c_int32 from pyGHDL.libghdl import libghdl +from pyGHDL.libghdl._types import Location_Type, Iir_Package_Declaration, Iir_Enumeration_Type_Definition -__all__ = ["Std_Location", "Standard_Package", "Character_Type_Definition"] - -Std_Location = c_int32.in_dll( - libghdl, "vhdl__std_package__std_location" -) #: Virtual location for the ``std.standard`` package. Type ``Location_Type``. Use ``.value`` to access this variable inside libghdl. -Standard_Package = c_int32.in_dll( - libghdl, "vhdl__std_package__standard_package" -) #: Virtual package ``std.package``. Type ``Iir_Package_Declaration``. Use ``.value`` to access this variable inside libghdl. -Character_Type_Definition = c_int32.in_dll( - libghdl, "vhdl__std_package__character_type_definition" -) #: Predefined character. Type ``Iir_Enumeration_Type_Definition``. Use ``.value`` to access this variable inside libghdl. + +__all__ = [ + "Std_Location", + "Standard_Package", + "Character_Type_Definition" +] + + +Std_Location: Location_Type = c_int32.in_dll(libghdl, "vhdl__std_package__std_location") +"""Virtual location for the ``std.standard`` package. Use ``.value`` to access this variable inside libghdl.""" + +Standard_Package: Iir_Package_Declaration = c_int32.in_dll(libghdl, "vhdl__std_package__standard_package") +"""Virtual package ``std.package``. Use ``.value`` to access this variable inside libghdl.""" + +Character_Type_Definition: Iir_Enumeration_Type_Definition = c_int32.in_dll(libghdl, "vhdl__std_package__character_type_definition") +"""Predefined character. Use ``.value`` to access this variable inside libghdl.""" |