<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def _iter_serial_enum_member(eid, value, bitmask):
 """Iterate serial and CID of enum members with given value and bitmask. Here only valid values are returned, as `idaapi.BADNODE` always indicates an invalid member. """

    cid, serial = idaapi.get_first_serial_enum_member(eid, value, bitmask)
    while cid != idaapi.BADNODE:
        yield cid, serial
        cid, serial = idaapi.get_next_serial_enum_member(cid, serial)