src: implemented move constructor/assignment for filepath
* improves indexing performance by roughly 5% * switched to use uniqu_ptr for boost path to get rid of including boost in header * added different methods to change the current FilePath or to make a copy and change that one * used these methods appropriately throughout the code base * removed exists() method from FileSystem because it is already contained in FilePath * added const in some places
This commit is contained in:
@@ -63,7 +63,7 @@ std::set<FilePath> FileManager::getAllSourceFilePathsRelative(const FilePath& ba
|
||||
{
|
||||
if (baseDirectory.exists())
|
||||
{
|
||||
absolutePaths.insert(path.relativeTo(baseDirectory));
|
||||
absolutePaths.insert(path.getRelativeTo(baseDirectory));
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -78,7 +78,7 @@ std::vector<FilePath> FileManager::makeCanonical(const std::vector<FilePath>& fi
|
||||
std::vector<FilePath> ret;
|
||||
for (const FilePath& filePath: filePaths)
|
||||
{
|
||||
ret.push_back(filePath.canonical());
|
||||
ret.push_back(filePath.getCanonical());
|
||||
}
|
||||
return ret;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user