mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-07-25 13:24:46 +00:00
Make constructors target-specific. This fixes problems where the path would
include backslashes on Windows. This should fix llvm-ld problems on win32. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@50960 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -46,6 +46,16 @@ namespace llvm {
|
||||
namespace sys {
|
||||
const char PathSeparator = ';';
|
||||
|
||||
Path::Path(const std::string& p)
|
||||
: path(p) {
|
||||
FlipBackSlashes(path);
|
||||
}
|
||||
|
||||
Path::Path(const char *StrStart, unsigned StrLen)
|
||||
: path(StrStart, StrLen) {
|
||||
FlipBackSlashes(path);
|
||||
}
|
||||
|
||||
bool
|
||||
Path::isValid() const {
|
||||
if (path.empty())
|
||||
@@ -230,7 +240,7 @@ Path::isRootDirectory() const {
|
||||
}
|
||||
|
||||
std::string Path::getDirname() const {
|
||||
return getDirnameCharSep(path, '\\');
|
||||
return getDirnameCharSep(path, '/');
|
||||
}
|
||||
|
||||
std::string
|
||||
|
Reference in New Issue
Block a user