*** empty log message ***
This commit is contained in:
		| @ -1,5 +1,5 @@ | |||||||
| /* | /* | ||||||
|  * $Id: macros.h,v 1.25 2005-05-28 13:34:26 bacon Exp $ |  * $Id: macros.h,v 1.26 2005-06-06 16:32:29 bacon Exp $ | ||||||
|  */ |  */ | ||||||
|  |  | ||||||
| #ifndef _XP_MACROS_H_ | #ifndef _XP_MACROS_H_ | ||||||
| @ -19,7 +19,6 @@ | |||||||
| #define xp_countof(n)  (sizeof(n) / sizeof(n[0])) | #define xp_countof(n)  (sizeof(n) / sizeof(n[0])) | ||||||
| #define xp_offsetof(type,member) ((xp_size_t)&((type*)0)->member) | #define xp_offsetof(type,member) ((xp_size_t)&((type*)0)->member) | ||||||
|  |  | ||||||
|  |  | ||||||
| #if defined(_WIN32) && defined(XP_CHAR_IS_WCHAR) && !defined(__LCC__) | #if defined(_WIN32) && defined(XP_CHAR_IS_WCHAR) && !defined(__LCC__) | ||||||
|     #define xp_main wmain |     #define xp_main wmain | ||||||
| #elif defined(XP_CHAR_IS_MCHAR) | #elif defined(XP_CHAR_IS_MCHAR) | ||||||
|  | |||||||
| @ -1,5 +1,6 @@ | |||||||
| SRCS = \ | SRCS = \ | ||||||
| 	stx.c memory.c object.c symbol.c hash.c misc.c context.c | 	stx.c memory.c object.c symbol.c class.c \ | ||||||
|  | 	hash.c misc.c context.c token.c parser.c bootstrp.c | ||||||
| OBJS = $(SRCS:.c=.obj) | OBJS = $(SRCS:.c=.obj) | ||||||
| OUT = xpstx.lib | OUT = xpstx.lib | ||||||
|  |  | ||||||
|  | |||||||
| @ -1,15 +1,16 @@ | |||||||
| SRCS = stx.c |  | ||||||
| OBJS = stx.obj |  | ||||||
| OUT = stx.exe |  | ||||||
|  |  | ||||||
| CC = bcc32 | CC = bcc32 | ||||||
| CFLAGS = -I..\..\.. | CFLAGS = -I..\..\.. | ||||||
| LDFLAGS = -L..\..\..\xp\bas -L..\..\..\xp\stx | LDFLAGS = -L..\..\..\xp\bas -L..\..\..\xp\stx | ||||||
| LIBS = import32.lib cw32mt.lib xpbas.lib xpstx.lib | LIBS = import32.lib cw32mt.lib xpbas.lib xpstx.lib | ||||||
| STARTUP = c0x32w.obj | STARTUP = c0x32w.obj | ||||||
|  |  | ||||||
| all: $(OBJS) | all: stx parser | ||||||
| 	ilink32 $(LDFLAGS) $(STARTUP) $(OBJS),$(OUT),,$(LIBS),, |  | ||||||
|  | stx: stx.obj | ||||||
|  | 	ilink32 $(LDFLAGS) $(STARTUP) stx.obj,stx.exe,,$(LIBS),, | ||||||
|  |  | ||||||
|  | parser: parser.obj | ||||||
|  | 	ilink32 $(LDFLAGS) $(STARTUP) parser.obj,parser.exe,,$(LIBS),, | ||||||
|  |  | ||||||
| clean: | clean: | ||||||
| 	del $(OBJS) *.obj $(OUT) | 	del $(OBJS) *.obj $(OUT) | ||||||
|  | |||||||
| @ -75,17 +75,12 @@ int stdio_func (int cmd, void* owner, void* arg) | |||||||
| 	else if (cmd == XP_STX_PARSER_INPUT_CONSUME) { | 	else if (cmd == XP_STX_PARSER_INPUT_CONSUME) { | ||||||
| 		stdio_t* p = (stdio_t*)owner; | 		stdio_t* p = (stdio_t*)owner; | ||||||
| 		xp_cint_t* c = (xp_cint_t*)arg; | 		xp_cint_t* c = (xp_cint_t*)arg; | ||||||
| 		if (xp_feof(p->stdio)) { | 		xp_cint_t t = xp_fgetc (p->stdio);	 | ||||||
|  | 		if (t == XP_CHAR_EOF) { | ||||||
|  | 			if (xp_ferror (p->stdio)) return -1; | ||||||
| 			*c = XP_STX_CHAR_EOF; | 			*c = XP_STX_CHAR_EOF; | ||||||
| 		} | 		} | ||||||
| 		else { | 		else *c = t; | ||||||
| 			xp_cint_t t = xp_fgetc (p->stdio);	 |  | ||||||
| 			if (t == XP_CHAR_EOF) { |  | ||||||
| 				if (xp_ferror (p->stdio)) return -1; |  | ||||||
| 				*c = XP_STX_CHAR_EOF; |  | ||||||
| 			} |  | ||||||
| 			else *c = t; |  | ||||||
| 		}	 |  | ||||||
| 		return 0; | 		return 0; | ||||||
| 	} | 	} | ||||||
| 	else if (cmd == XP_STX_PARSER_INPUT_REWIND) { | 	else if (cmd == XP_STX_PARSER_INPUT_REWIND) { | ||||||
|  | |||||||
| @ -1,5 +1,5 @@ | |||||||
| /* | /* | ||||||
|  * $Id: types.h,v 1.26 2005-05-20 04:01:12 bacon Exp $ |  * $Id: types.h,v 1.27 2005-06-06 16:32:29 bacon Exp $ | ||||||
|  */ |  */ | ||||||
|  |  | ||||||
| #ifndef _XP_TYPES_H_ | #ifndef _XP_TYPES_H_ | ||||||
| @ -133,7 +133,8 @@ typedef int  xp_mcint_t; | |||||||
| 	#define XP_CHAR_IS_MCHAR | 	#define XP_CHAR_IS_MCHAR | ||||||
| #elif defined(_WIN32) | #elif defined(_WIN32) | ||||||
| 	typedef unsigned short xp_wchar_t; | 	typedef unsigned short xp_wchar_t; | ||||||
| 	typedef int            xp_wcint_t; | 	/*typedef int            xp_wcint_t;*/ | ||||||
|  | 	typedef unsigned short xp_wcint_t; | ||||||
| #elif SIZEOF_LONG == 4 | #elif SIZEOF_LONG == 4 | ||||||
| 	/*typedef unsigned short xp_wchar_t;*/ | 	/*typedef unsigned short xp_wchar_t;*/ | ||||||
| 	typedef long           xp_wchar_t; | 	typedef long           xp_wchar_t; | ||||||
|  | |||||||
		Reference in New Issue
	
	Block a user