From 48ef7704c03e7e554c05de01bf8d1d70c16cb6f4 Mon Sep 17 00:00:00 2001 From: ProjectRevoTPP Date: Wed, 20 Dec 2017 16:34:35 -0500 Subject: add libc building to agbcc. --- libc/stdio/feof.c | 40 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 40 insertions(+) create mode 100644 libc/stdio/feof.c (limited to 'libc/stdio/feof.c') diff --git a/libc/stdio/feof.c b/libc/stdio/feof.c new file mode 100644 index 0000000..55f151b --- /dev/null +++ b/libc/stdio/feof.c @@ -0,0 +1,40 @@ +/* +FUNCTION +<>---test for end of file + +INDEX + feof + +ANSI_SYNOPSIS + #include + int feof(FILE *<[fp]>); + +TRAD_SYNOPSIS + #include + int feof(<[fp]>) + FILE *<[fp]>; + +DESCRIPTION +<> tests whether or not the end of the file identified by <[fp]> +has been reached. + +RETURNS +<> returns <<0>> if the end of file has not yet been reached; if +at end of file, the result is nonzero. + +PORTABILITY +<> is required by ANSI C. + +No supporting OS subroutines are required. +*/ + +#include + +#undef feof + +int +_DEFUN (feof, (fp), + FILE * fp) +{ + return __sfeof (fp); +} -- cgit v1.2.3