]> git.tdb.fi Git - libs/core.git/commitdiff
Move is_windows_drive into utils.h
authorMikko Rasa <tdb@tdb.fi>
Thu, 24 Aug 2006 14:15:26 +0000 (14:15 +0000)
committerMikko Rasa <tdb@tdb.fi>
Thu, 24 Aug 2006 14:15:26 +0000 (14:15 +0000)
source/path.cpp
source/utils.h

index ff6713f1f5c7625e66104c812eb4bc999c1e66bb..93a0a84630e29aeab758dd547931885f0d999b89 100644 (file)
@@ -12,11 +12,6 @@ using namespace std;
 namespace Msp {
 namespace Path {
 
 namespace Msp {
 namespace Path {
 
-bool is_windows_drive(const std::string &p)
-{
-       return (p.size()==2 && ((p[0]>='A' && p[0]<='Z') || (p[0]>='a' && p[0]<='z')) && p[1]==':');
-}
-
 /**
 Returns the number of components in the path.
 */
 /**
 Returns the number of components in the path.
 */
index e0c559d0450a47a2f79c873609f4ac76e32bfe0d..961ad499674666629ecc7b635d04032e2b5d63ac 100644 (file)
@@ -35,6 +35,9 @@ inline int stat(const Path &fn, struct stat &st)
 inline Path getcwd()
 { char buf[1024]; return ::getcwd(buf, sizeof(buf)); }
 
 inline Path getcwd()
 { char buf[1024]; return ::getcwd(buf, sizeof(buf)); }
 
+inline bool is_windows_drive(const std::string &p)
+{ return (p.size()==2 && ((p[0]>='A' && p[0]<='Z') || (p[0]>='a' && p[0]<='z')) && p[1]==':'); }
+
 } // namespace Path
 } // namespace Msp
 
 } // namespace Path
 } // namespace Msp