Skip to content

Add support for non defined value in ConfigEntry #518

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

Conversation

Vitroxyn
Copy link
Contributor

@Vitroxyn Vitroxyn commented Feb 6, 2020

Addresses #515

To not introduce breaking api changes ConfigEntry has a new method has_value() which returns true when a value is defined. The methods value_bytes() and value() are panicing when a non defined value is present this could be prevented by checking has_value() first.

@alexcrichton alexcrichton merged commit 43b8e28 into rust-lang:master Feb 7, 2020
@alexcrichton
Copy link
Member

Thanks!

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.

2 participants