forked from qt-creator/qt-creator
Utils: Move std::hash<Utils::FilePath>::operator() out of line
This generates quite a bit of code, and the non-inlined call should not be noticible given the rest. Change-Id: If3a699737142c2953dd0977df850b07bc529a124 Reviewed-by: Eike Ziller <eike.ziller@qt.io>
This commit is contained in:
@@ -994,3 +994,11 @@ void withNtfsPermissions(const std::function<void()> &task)
|
||||
}
|
||||
#endif
|
||||
} // namespace Utils
|
||||
|
||||
std::hash<Utils::FilePath>::result_type
|
||||
std::hash<Utils::FilePath>::operator()(const std::hash<Utils::FilePath>::argument_type &fn) const
|
||||
{
|
||||
if (Utils::HostOsInfo::fileNameCaseSensitivity() == Qt::CaseInsensitive)
|
||||
return hash<string>()(fn.toString().toUpper().toStdString());
|
||||
return hash<string>()(fn.toString().toStdString());
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user