Skip to content
Snippets Groups Projects
Commit 62e8e97c authored by Martin's avatar Martin
Browse files

i forgot to comment

parent 3ba1af59
No related branches found
No related tags found
1 merge request!23Added slots to non-gui modules
Pipeline #132062 failed
...@@ -8,6 +8,9 @@ class ASR(IntegerRegister, MiaBusConnector): ...@@ -8,6 +8,9 @@ class ASR(IntegerRegister, MiaBusConnector):
Register for controlling the memory andress in MIA. Register for controlling the memory andress in MIA.
""" """
# Python does not allow multiple inherintence if more than one of the
# parent classes uses __slots__. Thus we also includes the __slots__
# from MiaBusConnector.
__slots__ = ("bus_id", "bus_control_s") __slots__ = ("bus_id", "bus_control_s")
def __init__( def __init__(
......
...@@ -14,6 +14,9 @@ class GRX(Module, MiaBusConnector): ...@@ -14,6 +14,9 @@ class GRX(Module, MiaBusConnector):
registers should be indexed by the GRx bits or the M bits. registers should be indexed by the GRx bits or the M bits.
""" """
# Python does not allow multiple inherintence if more than one of the
# parent classes uses __slots__. Thus we also includes the __slots__
# from MiaBusConnector.
__slots__ = ( __slots__ = (
"grx_control", "grx_control",
"m_control", "m_control",
......
...@@ -11,6 +11,9 @@ class MiaMemory(MiaBusConnector, Memory): ...@@ -11,6 +11,9 @@ class MiaMemory(MiaBusConnector, Memory):
to/from the mia bus. to/from the mia bus.
""" """
# Python does not allow multiple inherintence if more than one of the
# parent classes uses __slots__. Thus we also includes the __slots__
# from MiaBusConnector.
__slots__ = ("label_adress_mapping", "bus_id", "bus_control_s") __slots__ = ("label_adress_mapping", "bus_id", "bus_control_s")
def __init__( def __init__(
......
...@@ -17,6 +17,9 @@ class PC(Module, MiaBusConnector): ...@@ -17,6 +17,9 @@ class PC(Module, MiaBusConnector):
value on the bus. If both are true it does nothing. value on the bus. If both are true it does nothing.
""" """
# Python does not allow multiple inherintence if more than one of the
# parent classes uses __slots__. Thus we also includes the __slots__
# from MiaBusConnector.
__slots__ = ("bus_id", "bus_control_s", "value", "increase_by_one") __slots__ = ("bus_id", "bus_control_s", "value", "increase_by_one")
def __init__( def __init__(
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment