MCPcopy Create free account
hub / github.com/REhints/HexRaysCodeXplorer / MakeArray

Function MakeArray

src/HexRaysCodeXplorer/Utility.cpp:320–345  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

318}
319
320bool MakeArray(ea_t ea, size_t nitems)
321{
322 asize_t itemsize = 0;
323 tid_t tid = BADADDR;
324 flags_t flags = get_flags(ea);
325 if (is_code(flags) || is_tail(flags) || is_align(flags))
326 return false;
327
328 if (is_unknown(flags))
329 flags = 0;
330
331 if (is_struct(flags))
332 {
333 opinfo_t ti;
334 if (!get_opinfo(&ti, ea, 0, flags))
335 return false;
336 itemsize = get_data_elsize(ea, flags, &ti);
337 tid = ti.tid;
338 }
339 else
340 {
341 itemsize = get_item_size(ea);
342 }
343
344 return create_data(ea, flags, static_cast<asize_t>(itemsize * nitems), tid);
345}

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected