mirror of
https://github.com/mruby/mruby
synced 2026-06-08 16:11:16 +00:00
define PATH_SEPARATOR
This commit is contained in:
@@ -47,6 +47,11 @@
|
||||
#endif
|
||||
|
||||
#define FILE_SEPARATOR "/"
|
||||
#if defined(_WIN32) || defined(_WIN64)
|
||||
#define PATH_SEPARATOR ";"
|
||||
#else
|
||||
#define PATH_SEPARATOR ":"
|
||||
#endif
|
||||
|
||||
#ifndef LOCK_SH
|
||||
#define LOCK_SH 1
|
||||
@@ -313,5 +318,7 @@ mrb_init_file(mrb_state *mrb)
|
||||
mrb_define_const(mrb, cnst, "LOCK_UN", mrb_fixnum_value(LOCK_UN));
|
||||
mrb_define_const(mrb, cnst, "LOCK_NB", mrb_fixnum_value(LOCK_NB));
|
||||
mrb_define_const(mrb, cnst, "SEPARATOR", mrb_str_new_cstr(mrb, FILE_SEPARATOR));
|
||||
mrb_define_const(mrb, cnst, "PATH_SEPARATOR", mrb_str_new_cstr(mrb, PATH_SEPARATOR));
|
||||
mrb_define_const(mrb, cnst, "NULL", mrb_str_new_cstr(mrb, NULL_FILE));
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user