Skip to content

Fix warnings (OCONF-87)#11

Merged
ktf merged 2 commits intomasterfrom
OCONF-87
Apr 5, 2018
Merged

Fix warnings (OCONF-87)#11
ktf merged 2 commits intomasterfrom
OCONF-87

Conversation

@awegrzyn
Copy link
Collaborator

@awegrzyn awegrzyn commented Apr 4, 2018

No description provided.

@awegrzyn awegrzyn requested a review from ktf April 4, 2018 08:56
// Getters return a boost::optional that will be empty if the value is not present
int getValue = conf->get<int>(myKey).value();
int getValueWithDefault = conf->get<int>("/this/key/does/not/exist").value_or(-1);
conf->get<int>(myKey).value();
Copy link
Member

Choose a reason for hiding this comment

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

Shouldn't the return value be checked via BOOST_CHECK or something similar?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Not really as this file contains examples (I don't know why examples are in the test/ dir). The full tests are in the TestConfiguration.cxx file.

@ktf ktf merged commit 7dd6fec into master Apr 5, 2018
@awegrzyn awegrzyn deleted the OCONF-87 branch April 18, 2018 13:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants