2022-10-01 18:59:22 +00:00
|
|
|
#ifndef _STDIO_H
|
|
|
|
#define _STDIO_H
|
|
|
|
|
|
|
|
#include <stdarg.h>
|
|
|
|
#include <stddef.h>
|
|
|
|
|
|
|
|
#define SEEK_SET 0
|
|
|
|
|
|
|
|
typedef struct
|
|
|
|
{
|
2022-10-11 14:57:08 +00:00
|
|
|
int f_fd;
|
|
|
|
int f_eof;
|
|
|
|
int f_err;
|
2022-10-01 18:59:22 +00:00
|
|
|
} FILE;
|
|
|
|
|
2022-10-11 19:08:46 +00:00
|
|
|
extern FILE* __stderr;
|
|
|
|
extern FILE* __stdout;
|
|
|
|
#define stderr __stderr
|
|
|
|
#define stdout __stdout
|
|
|
|
|
2022-10-01 18:59:22 +00:00
|
|
|
#ifdef __cplusplus
|
|
|
|
extern "C"
|
|
|
|
{
|
|
|
|
#endif
|
|
|
|
int fclose(FILE*);
|
|
|
|
int fflush(FILE*);
|
|
|
|
FILE* fopen(const char*, const char*);
|
|
|
|
int fprintf(FILE*, const char*, ...);
|
|
|
|
size_t fread(void*, size_t, size_t, FILE*);
|
|
|
|
int fseek(FILE*, long, int);
|
|
|
|
long ftell(FILE*);
|
|
|
|
size_t fwrite(const void*, size_t, size_t, FILE*);
|
2022-10-11 14:57:08 +00:00
|
|
|
int ferror(FILE*);
|
|
|
|
int feof(FILE*);
|
|
|
|
void clearerr(FILE*);
|
2022-10-01 18:59:22 +00:00
|
|
|
void setbuf(FILE*, char*);
|
|
|
|
int vfprintf(FILE*, const char*, va_list);
|
2022-10-03 17:00:10 +00:00
|
|
|
int printf(const char*, ...);
|
2022-10-03 17:59:33 +00:00
|
|
|
int vprintf(const char*, va_list);
|
|
|
|
int sprintf(char*, const char*, ...);
|
|
|
|
int snprintf(char*, size_t, const char*, ...);
|
|
|
|
int vsprintf(char*, const char*, va_list);
|
|
|
|
int vsnprintf(char*, size_t, const char*, va_list);
|
2022-10-03 17:00:10 +00:00
|
|
|
int puts(const char*);
|
2022-10-08 10:42:25 +00:00
|
|
|
void perror(const char*);
|
2022-10-01 18:59:22 +00:00
|
|
|
|
|
|
|
#ifdef __cplusplus
|
|
|
|
}
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#endif
|