(concrete_target)
return True
Check if the concrete target methods return the correct type of data
        :return: True if the concrete target is compliant
Check if the concrete target methods return the correct type of data
        :return: True if the concrete target is compliant
Check if the concrete target methods return the correct type of data : return : True if the concrete target is compliant
def check_concrete_target_methods(concrete_target):
        """
        Check if the concrete target methods return the correct type of data
        :return: True if the concrete target is compliant
        """
        entry_point = concrete_target.read_register("pc")
        if not type(entry_point) is int:
            l.error("read_register result type is %s, should be <type 'int'>", (type(entry_point)))
            return False

        mem_read = concrete_target.read_memory(entry_point, 0x4)

        if not type(mem_read) is bytes:
            l.error("read_memory result type is %s, should be <type 'bytes'>", (type(mem_read)))
            return False

        try:
            concrete_target.read_register("not_existent_reg")
            l.error("read_register should raise a SimConcreteRegisterError when accessing non existent registers")
            return False

        except SimConcreteRegisterError:
            l.debug("read_register raise a SimConcreteRegisterError, ok!")

        return True
def check_concrete_target_methods ( concrete_target ) : entry_point = concrete_target . read_register ( "pc" ) if not type ( entry_point ) is int : l . error ( "read_register result type is %s, should be <type 'int'>" , ( type ( entry_point ) ) ) return False mem_read = concrete_target . read_memory ( entry_point , 0x4 ) if not type ( mem_read ) is bytes : l . error ( "read_memory result type is %s, should be <type 'bytes'>" , ( type ( mem_read ) ) ) return False try : concrete_target . read_register ( "not_existent_reg" ) l . error ( "read_register should raise a SimConcreteRegisterError when accessing non existent registers" ) return False except SimConcreteRegisterError : l . debug ( "read_register raise a SimConcreteRegisterError, ok!" ) return True