comparison src/sysfile.h @ 3379:b544987e2eca

[xemacs-hg @ 2006-05-06 08:09:35 by aidan] Fix the win32 build following my lib-src/DOC format changes.
author aidan
date Sat, 06 May 2006 08:09:37 +0000
parents 959746c534f6
children a5210e70ffbe
comparison
equal deleted inserted replaced
3378:b90d5053b5ca 3379:b544987e2eca
465 #ifdef WIN32_NATIVE 465 #ifdef WIN32_NATIVE
466 466
467 #define SEPCHAR ';' 467 #define SEPCHAR ';'
468 #define DEFAULT_DIRECTORY_SEP '\\' 468 #define DEFAULT_DIRECTORY_SEP '\\'
469 469
470 #ifdef emacs
470 DECLARE_INLINE_HEADER (Ibyte sysfile_get_directory_sep (void)) 471 DECLARE_INLINE_HEADER (Ibyte sysfile_get_directory_sep (void))
471 { 472 {
472 if (!CHARP (Vdirectory_sep_char) 473 if (!CHARP (Vdirectory_sep_char)
473 || (XCHAR (Vdirectory_sep_char) != '/' 474 || (XCHAR (Vdirectory_sep_char) != '/'
474 && XCHAR (Vdirectory_sep_char) != '\\')) 475 && XCHAR (Vdirectory_sep_char) != '\\'))
482 483
483 return XCHAR (Vdirectory_sep_char); 484 return XCHAR (Vdirectory_sep_char);
484 } 485 }
485 #define DIRECTORY_SEP sysfile_get_directory_sep() 486 #define DIRECTORY_SEP sysfile_get_directory_sep()
486 487
488 #else /* emacs */
489
490 /* The above Lisp variables are not available to make-docfile, etc. */
491 #define DIRECTORY_SEP DEFAULT_DIRECTORY_SEP
492
493 #endif /* emacs */
494
487 #else /* not WIN32_NATIVE */ 495 #else /* not WIN32_NATIVE */
488 496
489 #define SEPCHAR ':' 497 #define SEPCHAR ':'
490 #define DEFAULT_DIRECTORY_SEP '/' 498 #define DEFAULT_DIRECTORY_SEP '/'
491 #define DIRECTORY_SEP '/' 499 #define DIRECTORY_SEP '/'
496 #ifdef WIN32_ANY 504 #ifdef WIN32_ANY
497 505
498 #define DEVICE_SEP ':' 506 #define DEVICE_SEP ':'
499 507
500 #define IS_DEVICE_SEP(c) ((c) == DEVICE_SEP) 508 #define IS_DEVICE_SEP(c) ((c) == DEVICE_SEP)
509
510 #ifdef emacs
501 511
502 DECLARE_INLINE_HEADER (int IS_DIRECTORY_SEP (Ichar c)) 512 DECLARE_INLINE_HEADER (int IS_DIRECTORY_SEP (Ichar c))
503 { 513 {
504 return (c == '/' || c == '\\'); 514 return (c == '/' || c == '\\');
505 } 515 }
506 516
507 DECLARE_INLINE_HEADER (int IS_ANY_SEP (Ichar c)) 517 DECLARE_INLINE_HEADER (int IS_ANY_SEP (Ichar c))
508 { 518 {
509 return (c == '/' || c == '\\' || c == ':'); 519 return (c == '/' || c == '\\' || c == ':');
510 } 520 }
521
522 #else /* emacs */
523
524 /* The Ichar typedef is not available to make-docfile, etc. */
525
526 DECLARE_INLINE_HEADER (int IS_DIRECTORY_SEP (int c))
527 {
528 return (c == '/' || c == '\\');
529 }
530
531 DECLARE_INLINE_HEADER (int IS_ANY_SEP (int c))
532 {
533 return (c == '/' || c == '\\' || c == ':');
534 }
535
536 #endif
511 537
512 #else /* not WIN32_ANY */ 538 #else /* not WIN32_ANY */
513 539
514 #define IS_DEVICE_SEP(c) 0 540 #define IS_DEVICE_SEP(c) 0
515 #define IS_DIRECTORY_SEP(c) ((c) == DIRECTORY_SEP) 541 #define IS_DIRECTORY_SEP(c) ((c) == DIRECTORY_SEP)