diff --git a/ase/macros.h b/ase/macros.h index 09fdd78c..860c0844 100644 --- a/ase/macros.h +++ b/ase/macros.h @@ -1,5 +1,5 @@ /* - * $Id: macros.h,v 1.10 2005-02-05 06:30:24 bacon Exp $ + * $Id: macros.h,v 1.11 2005-02-06 03:27:54 bacon Exp $ */ #ifndef _XP_MACROS_H_ @@ -27,33 +27,23 @@ #define XP_QUOTE(val) __XP_QUOTE(val) #define __XP_QUOTE(val) #val -//#define XP_MCHAR(ch) ((xp_mchar_t)ch) -//#define XP_MTEXT(txt) ((const xp_mchar_t*)txt) -#define XP_MCHAR(ch) ch -#define XP_MTEXT(txt) txt +#define XP_MCHAR(ch) ((xp_mchar_t)ch) +#define XP_MTEXT(txt) ((const xp_mchar_t*)txt) /* TODO: if the compiler doesn't have the built-in wchar_t support * XP_WCHAR & XP_WTEXT must be defined differently. #define XP_WCHAR(ch) ((xp_wchar_t)ch) #define XP_WTEXT(txt) don't know yet... may have to call a function? */ -#define XP_WCHAR(ch) L##ch -#define XP_WTEXT(txt) L##txt +#define XP_WCHAR(ch) ((xp_wchar_t)L##ch) +#define XP_WTEXT(txt) ((const xp_wchar_t*)L##txt) #if defined(XP_CHAR_IS_MCHAR) - /* #define XP_CHAR(ch) XP_MCHAR(ch) #define XP_TEXT(txt) XP_MTEXT(txt) - */ - #define XP_CHAR(ch) ch - #define XP_TEXT(txt) txt #else - /* #define XP_CHAR(ch) XP_WCHAR(ch) #define XP_TEXT(txt) XP_WTEXT(txt) - */ - #define XP_CHAR(ch) L##ch - #define XP_TEXT(txt) L##txt #endif #endif diff --git a/ase/test/lsp/lisp.c b/ase/test/lsp/lisp.c index cbd257a0..c382d319 100644 --- a/ase/test/lsp/lisp.c +++ b/ase/test/lsp/lisp.c @@ -10,9 +10,9 @@ static int get_char (xp_lisp_cint* ch, void* arg) { xp_lisp_cint c; - c = xp_fgetc(stdin); + c = xp_fgetc(xp_stdin); if (c == XP_EOF) { - if (xp_ferror(stdin)) return -1; + if (xp_ferror(xp_stdin)) return -1; c = XP_EOF; } @@ -42,7 +42,7 @@ int xp_main (int argc, xp_char_t* argv[]) mtrace (); #endif if (argc != 3) { - xp_fprintf (xp_stderr, XP_TEXT("usage: %ls mem_ubound mem_ubound_inc\n"), argv[0]); + xp_fprintf (xp_stderr, XP_TEXT("usage: %s mem_ubound mem_ubound_inc\n"), argv[0]); return -1; } diff --git a/ase/types.h b/ase/types.h index 83c06203..7913d712 100644 --- a/ase/types.h +++ b/ase/types.h @@ -1,5 +1,5 @@ /* - * $Id: types.h,v 1.11 2005-01-19 12:13:48 bacon Exp $ + * $Id: types.h,v 1.12 2005-02-06 03:27:54 bacon Exp $ */ #ifndef _XP_TYPES_H_ @@ -8,7 +8,7 @@ #ifndef _WIN32 #include #endif -#include +#include typedef xp_uint8_t xp_byte_t;