Allow to replace the color functions in conio.h by macros for platforms

where these functions are dummies anyway.


git-svn-id: svn://svn.cc65.org/cc65/trunk@3422 b7a2c559-68d2-44c3-8de9-860c34a00d81
This commit is contained in:
cuz
2005-03-26 17:20:27 +00:00
parent 071c58bda2
commit 5363f9bee3
4 changed files with 200 additions and 105 deletions

View File

@@ -6,7 +6,7 @@
/* */
/* */
/* */
/* (C) 1998-2004 Ullrich von Bassewitz */
/* (C) 1998-2005 Ullrich von Bassewitz */
/* R<>merstra<72>e 52 */
/* D-70794 Filderstadt */
/* EMail: uz@cc65.org */
@@ -191,6 +191,34 @@ void __fastcall__ cputhex16 (unsigned val);
/*****************************************************************************/
/* Macros */
/*****************************************************************************/
/* On some platforms, functions are not available or are dummys. To suppress
* the call to these functions completely, the platform header files may
* define macros for these functions that start with an underline. If such a
* macro exists, a new macro is defined here, that expands to the one with the
* underline. The reason for this two stepped approach is that it is sometimes
* necessary to take the address of the function, which is not possible when
* using a macro. Since the function prototype is still present, #undefining
* the macro will give access to the actual function.
*/
#if defined(_textcolor)
# define textcolor(x) _textcolor(x)
#endif
#if defined(_bgcolor)
# define bgcolor(x) _bgcolor(x)
#endif
#if defined(_bordercolor)
# define bordercolor(x) _bordercolor(x)
#endif
/* End of conio.h */
#endif