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

Edits to next_dfs() docstring example. #307

Merged
merged 1 commit into from
Jun 22, 2018

Conversation

data-pup
Copy link
Contributor

Edited the code example in the next_dfs() docstring, following the same loop style as shown in dwarfdump example found here: https://github.com/gimli-rs/gimli/blob/master/examples/dwarfdump.rs#L799

Copy link
Member

@fitzgen fitzgen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @data-pup !

@data-pup
Copy link
Contributor Author

No problem! :D

@fitzgen
Copy link
Member

fitzgen commented Jun 22, 2018

Failing CI is due to rust-lang/rust#51699 -- going to just go ahead and merge this.

@fitzgen fitzgen merged commit af4d0e4 into gimli-rs:master Jun 22, 2018
@philipc
Copy link
Collaborator

philipc commented Jun 22, 2018

This is an improvement over the previous example, which was a non-typical use. But I think this is still a non-typical example because if you're traversing starting at the root then it's good enough to stop when next_dfs returns None. Keeping track of the depth is more useful when you start at a specific entry.

@data-pup data-pup deleted the depth-fixed-search-doc-ex branch March 12, 2019 16:04
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

Successfully merging this pull request may close these issues.

3 participants