<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def enum_device_interfaces(h_info, guid):

 """Function generator that returns a device_interface_data enumerator
 for the given device interface info and GUID parameters
 """

    dev_interface_data = SP_DEVICE_INTERFACE_DATA()
    dev_interface_data.cb_size = sizeof(dev_interface_data)

    device_index = 0
    while SetupDiEnumDeviceInterfaces(h_info,
            None,
            byref(guid),
            device_index,
            byref(dev_interface_data) ):
        yield dev_interface_data
        device_index += 1
    del dev_interface_data