1
0
forked from Alepha/Alepha

Fix compiling error.

This commit is contained in:
2023-12-28 22:56:55 -05:00
parent 9424fbd193
commit c1c217146c

View File

@ -4,6 +4,8 @@ static_assert( __cplusplus > 2020'99 );
#include <Alepha/Alepha.h>
#include <cmath>
#include <map>
#include <string>
#include <exception>
@ -55,7 +57,7 @@ namespace Alepha::Hydrogen::Utility ::detail:: StringMap_m
} );
if( closest == end( storage ) ) throw std::out_of_range{ IOStreams::String() << "The key `" << key << "` could not be found." };
else if( optimalStringDistance( closest->first, key ) < sqrt( key.size() ) )
else if( optimalStringDistance( closest->first, key ) < std::sqrt( key.size() ) )
{
throw std::out_of_range{ IOStreams::String() << "The key `" << key << "` could not be found. Did you mean `"
<< closest->first << "`?" };