mescc: Tinycc support: eputc.

* mlibc/include/stdio.h (eputc): Declare.
* mlibc/libc-gcc.c (eputc):
* mlibc/libc-mes.c (eputc): New function.
This commit is contained in:
Jan Nieuwenhuizen 2017-08-06 13:53:56 +02:00
parent ba50d4bd25
commit e616d6120b
3 changed files with 14 additions and 0 deletions

View file

@ -53,6 +53,7 @@ int fdputs (char const* s, int fd);
#undef putc
#endif
int eputc (int c);
int eputs (char const* s);
int fdputc (int c, int fd);
int getchar ();
@ -94,6 +95,7 @@ typedef int FILE;
typedef unsigned long size_t;
#endif
int eputc (int c);
int eputs (char const* s);
int fclose (FILE *stream);
FILE *fdopen (int fd, char const *mode);

View file

@ -461,6 +461,12 @@ fdputs (char const* s, int fd)
return 0;
}
int
eputc (int c)
{
return fdputc (c, STDERR);
}
int
eputs (char const* s)
{

View file

@ -139,6 +139,12 @@ strlen (char const* s)
return i;
}
int
eputc (int c)
{
return fputc (c, 2);
}
int
eputs (char const* s)
{