Fgetc reads a single character from the current position of the specified stream and increments the file pointer to the next character; fgetchar reads from stdin.
#include <stdio.h> int fgetc(FILE *stream); int fgetchar(void);
#include <wchar.h>
wint_t fgetwc(FILE *stream);
stream
fgetchar is equivalent to:
fgetc(stdin)
fgetc and fgetchar are identical to getc and getchar, but they are functions, not macros.
fgetwc is the wide-characetr version of fgetc and returns the character as a wint_t.
fegtc and fgetchar return EOF on error or end-of-file. fgetwc returns WEOF on error or end-of-file.
tchar.h routine |
_UNICODE not defined |
_UNICODE defined |
|---|---|---|
| _fgettc | fgetc | fgetwc |
| Versions | Defined in | Include | Link to |
|---|---|---|---|
| INtime 3.0 INtime 6.0 |
intime/rt/include/stdio.h intime/rt/include/wchar.h intime/rt/include/tchar.h |
stdio.h wchar.h tchar.h |
clib.lib |