Value::GetValueAsData() takes an undocumented parameter called data_offset that is always 0. I couldn't figure out what it is supposed to be used for and it is never used, so here's a patch to remove it.
Details
Details
Diff Detail
Diff Detail
- Repository
- rL LLVM
Event Timeline
Comment Actions
From the looks of it, this appears to be the offset in the data extractor that you want to start extracting from (so, e.g. if you have a large data extractor, and you know that the value you're interested in is at byte 47, you would say GetValueAsData(large_extractor, 47).
That said, I think it would be good to remove this, as it does not seem to be a common use case, and one can always create a sub-data extractor, if he really wants to start extracting from a random offset.