Skip to content

clang::Comment::get_tag_attr_{name,value} should bounds check their idx parameter #143

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

Closed
fitzgen opened this issue Oct 25, 2016 · 1 comment

Comments

@fitzgen
Copy link
Member

fitzgen commented Oct 25, 2016

They should check that idx <= self.get_num_tag_attrs() and return None if idx is out of bounds, otherwise proceed as they do now and return Some.

This is one less foot gun for callers using this method.

I can mentor whoever would like to work on this.

@highfive
Copy link

Please make a comment here if you intend to work on this issue. Thank you!

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

No branches or pull requests

2 participants