Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

how about a new base type? #27

Open
ronyrus opened this issue Mar 3, 2016 · 6 comments
Open

how about a new base type? #27

ronyrus opened this issue Mar 3, 2016 · 6 comments

Comments

@ronyrus
Copy link
Contributor

ronyrus commented Mar 3, 2016

So, we have the Line. Which can be (in IDA) a code or a data or unknown.
So, it would be natural to write:

l = sark.Line(ea)
if l.is_code:
     i = l.code 
     if i.is_call:
         aaa

or perhaps:

 l = sark.Line(ea)
 if l.is_data:
     d = l.data
     if d.is_string:
         xxxx
     elif d.is_qword:
         yyy
     elif d.is_struct:
         zzz

while we have the Instruction type, which we could return on line.code property, we don't have a Data type to wrap the line.data.

So, how about adding it?
What do you think about it?

@tmr232
Copy link
Owner

tmr232 commented Mar 3, 2016

This seems like an interesting idea. But I'll have to play with some code to see how it works.

@ronyrus
Copy link
Contributor Author

ronyrus commented Mar 3, 2016

In addition, in Xref it's xref.type.is_call which, imho, feels a bit less natural than x.is_call.

@tmr232
Copy link
Owner

tmr232 commented Oct 4, 2016

Sorry for the super-long delay with the response. I've been busy with other things, but this should not happen.

I created a new branch with a basic implementation of what I understood from your request. Is that what you meant?

@ronyrus
Copy link
Contributor Author

ronyrus commented Oct 6, 2016

yes! :)

@tmr232
Copy link
Owner

tmr232 commented Oct 6, 2016

Great :)

Next up will probably be data reading. Anything else?

@ronyrus
Copy link
Contributor Author

ronyrus commented Oct 6, 2016

Nothing at the moment.

Thanks a lot for your work!

On Thu, Oct 6, 2016 at 10:12 AM, Tamir Bahar [email protected]
wrote:

Great :)

Next up will probably be data reading. Anything else?


You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
#27 (comment), or mute
the thread
https://github.com/notifications/unsubscribe-auth/ABRKRqD0m3nAD-vy-kLEOOw7sA6XzkO9ks5qxJ9QgaJpZM4HoIoA
.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants