Fixed std::tolower overload ambiguity

This commit is contained in:
Craig Hutchinson 2015-12-03 15:52:43 +00:00
parent bcab4455c2
commit 998e801a5b

View File

@ -233,7 +233,7 @@ namespace Clara {
}
inline void convertInto( std::string const& _source, bool& _dest ) {
std::string sourceLC = _source;
std::transform( sourceLC.begin(), sourceLC.end(), sourceLC.begin(), std::tolower );
std::transform( sourceLC.begin(), sourceLC.end(), sourceLC.begin(), static_cast<int(*)(int)>(std::tolower) );
if( sourceLC == "y" || sourceLC == "1" || sourceLC == "true" || sourceLC == "yes" || sourceLC == "on" )
_dest = true;
else if( sourceLC == "n" || sourceLC == "0" || sourceLC == "false" || sourceLC == "no" || sourceLC == "off" )