1
0
mirror of https://github.com/simh/simh.git synced 2026-02-27 01:00:07 +00:00

FIO: Add a global variable that indicates the normal host path separator

This avoids the potential need for platform specific #ifdef blocks in
simulator code which might be needed on some platforms.
This commit is contained in:
Mark Pizzolato
2023-06-20 17:45:28 -10:00
parent e7879b1bd0
commit 6fa6b5292c
2 changed files with 9 additions and 0 deletions

View File

@@ -81,6 +81,13 @@ t_bool sim_end; /* TRUE = little endian, FALSE = big endian
t_bool sim_taddr_64; /* t_addr is > 32b and Large File Support available */
t_bool sim_toffset_64; /* Large File (>2GB) file I/O Support available */
const char sim_file_path_separator /* Platform specific value \ or / as appropriate */
#if defined (_WIN32)
= '\\';
#else
= '/';
#endif
#if defined(fprintf) /* Make sure to only use the C rtl stream I/O routines */
#undef fprintf
#undef fputs

View File

@@ -117,6 +117,8 @@ extern t_bool sim_taddr_64; /* t_addr is > 32b and Large File Support av
extern t_bool sim_toffset_64; /* Large File (>2GB) file I/O support */
extern t_bool sim_end; /* TRUE = little endian, FALSE = big endian */
extern const char sim_file_path_separator; /* Platform specific value \ or / as appropriate */
char *sim_trim_endspc (char *cptr);
int sim_isspace (int c);
#ifdef isspace