const as const can
This commit is contained in:
parent
0ed9caf969
commit
2ad572490c
@ -48,7 +48,7 @@ inline bool durationIsValid(const std::string &s)
|
|||||||
|
|
||||||
std::vector<std::string> result;
|
std::vector<std::string> result;
|
||||||
boost::algorithm::split_regex(result, s, boost::regex(":"));
|
boost::algorithm::split_regex(result, s, boost::regex(":"));
|
||||||
bool matched = regex_match(s, e);
|
const bool matched = regex_match(s, e);
|
||||||
return matched;
|
return matched;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -63,7 +63,7 @@ inline unsigned parseDuration(const std::string &s)
|
|||||||
|
|
||||||
std::vector<std::string> result;
|
std::vector<std::string> result;
|
||||||
boost::algorithm::split_regex(result, s, boost::regex(":"));
|
boost::algorithm::split_regex(result, s, boost::regex(":"));
|
||||||
bool matched = regex_match(s, e);
|
const bool matched = regex_match(s, e);
|
||||||
if (matched)
|
if (matched)
|
||||||
{
|
{
|
||||||
if (1 == result.size())
|
if (1 == result.size())
|
||||||
|
Loading…
Reference in New Issue
Block a user