fs/Traits.hxx: add GetLengthFS()

There is no GetLengthUTF8() because strlen or std::string::size()
could be used instead.
This commit is contained in:
Denis Krjuchkov 2013-12-03 12:26:05 +06:00
parent 6c5828822c
commit 3a183f869f

View File

@ -29,6 +29,7 @@
#include <string>
#include <string.h>
#include <assert.h>
/**
@ -79,6 +80,11 @@ struct PathTraits {
return IsSeparatorUTF8(*p);
}
gcc_pure
static size_t GetLengthFS(const_pointer p) {
return strlen(p);
}
/**
* Determine the "base" file name of the given UTF-8 path.
* The return value points inside the given string.