set_member_type

Change structure member type.

This function can be used in two forms. First form: long set_member_type(long id, long member_offset, long flag, long typeid, long nitems);

Second form: long set_member_type(long id, long member_offset, long flag, long typeid, long nitems, long target, long tdelta, long reftype);

arguments: id - structure type ID member_offset - offset of the member flag - new type of the member. Should be one of FF_BYTE..FF_PACKREAL (see above) combined with FF_DATA typeid - if is_struct(flag) then typeid specifies the structure id for the member if is_off0(flag) then typeid specifies the offset base. if is_strlit(flag) then typeid specifies the string type (STRTYPE_...). if is_stroff(flag) then typeid specifies the structure id if is_enum(flag) then typeid specifies the enum id Otherwise typeid should be -1 nitems - number of items in the member the remaining arguments are allowed only if is_off0(flag) and you want to specify a complex offset expression: target - target address of the offset expr. You may specify it as -1, ida will calculate it itself tdelta - offset target delta. usually 0 reftype - see REF_... definitions returns: !=0 - ok.

long set_member_type(long id, long member_offset, long flag, long typeid, long nitems, long target, long tdelta, long reftype);

Index | Previous topic | Next topic