Add some filename helpers to os.
This commit is contained in:
parent
05c9d885dd
commit
dd0d255737
@ -39,6 +39,14 @@ mod libc_constants {
|
||||
fn S_IWUSR() -> uint { ret 0x0080u; }
|
||||
}
|
||||
|
||||
fn path_sep() -> str {
|
||||
ret "/";
|
||||
}
|
||||
|
||||
fn exec_suffix() -> str {
|
||||
ret "";
|
||||
}
|
||||
|
||||
|
||||
// Local Variables:
|
||||
// mode: rust;
|
||||
|
@ -39,6 +39,14 @@ mod libc_constants {
|
||||
fn S_IWUSR() -> uint { ret 0x0200u; }
|
||||
}
|
||||
|
||||
fn path_sep() -> str {
|
||||
ret "/";
|
||||
}
|
||||
|
||||
fn exec_suffix() -> str {
|
||||
ret "";
|
||||
}
|
||||
|
||||
// Local Variables:
|
||||
// mode: rust;
|
||||
// fill-column: 78;
|
||||
|
@ -29,6 +29,15 @@ mod libc_constants {
|
||||
fn S_IWUSR() -> uint { ret 0x0080u; } // really _S_IWRITE in win32
|
||||
}
|
||||
|
||||
|
||||
fn path_sep() -> str {
|
||||
ret "\\";
|
||||
}
|
||||
|
||||
fn exec_suffix() -> str {
|
||||
ret ".exe";
|
||||
}
|
||||
|
||||
// Local Variables:
|
||||
// mode: rust;
|
||||
// fill-column: 78;
|
||||
|
Loading…
x
Reference in New Issue
Block a user