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

sections: add Section#type? and Section#attribute? #424

Merged
merged 6 commits into from
Jan 11, 2022

Conversation

woodruffw
Copy link
Member

These two predicates replace the Section#flag? predicate, which
has unintuitive behavior and is now deprecated.

Closes #423.

This two predicates replace the `Section#flag?` predicate, which
has unintuitive behavior and is now deprecated.

Closes #423.
Previously, the offset returned by this method could be incidentally
wrong, depending on unrelated flags in each section. This changeset fixes
the method so that only the section's type is checked, rather than
the entire composite flag field.
Introduced by Mach-O at some point.
Clarify that these are masks.
@woodruffw
Copy link
Member Author

cc @iOS-Developer-Sun let me know if these changes work for you.

@woodruffw woodruffw mentioned this pull request Jan 11, 2022
@woodruffw woodruffw merged commit 59020eb into master Jan 11, 2022
@woodruffw woodruffw deleted the fix-section-type-attribute-preds branch January 11, 2022 21:15
@woodruffw woodruffw mentioned this pull request Jan 11, 2022
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Feb 11, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

MachO::Sections function flag? implementation is wrong
1 participant