(self, address)
Retrieve data from data memory: variable space
Retrieve data from data memory: variable space
Retrieve data from data memory : variable space
def get_memory(self, address):
        """Retrieve data from data memory: variable space """
        name_addr = -1
        var_addr = -1
        the_var = None
        for name in self._var_memory:
            name_try, var_try = self._var_memory[name]
            if name_try <= address and name_try > name_addr:
                name_addr, var_addr = name_try, var_try
                the_var = name
        if the_var is None:
            return -1
        if address >= var_addr:
            offset = address - var_addr
            if offset >= values.size_bytes(the_var):
                return -1
            var_rep = self._vars[the_var]
            return var_rep[offset]
        else:
            offset = address - name_addr
            return get_name_in_memory(the_var, offset)
def get_memory ( self , address ) : name_addr = - 1 var_addr = - 1 the_var = None for name in self . _var_memory : name_try , var_try = self . _var_memory [ name ] if name_try <= address and name_try > name_addr : name_addr , var_addr = name_try , var_try the_var = name if the_var is None : return - 1 if address >= var_addr : offset = address - var_addr if offset >= values . size_bytes ( the_var ) : return - 1 var_rep = self . _vars [ the_var ] return var_rep [ offset ] else : offset = address - name_addr return get_name_in_memory ( the_var , offset )