annotate stdio.h @ 44:c9293a6e40d2

*** empty log message ***
author kono
date Thu, 13 Feb 2003 18:16:19 +0900
parents b35787d8a442
children 8ffb8ca3fe34
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
d35df41eac69 Initial revision
kono
parents:
diff changeset
1 typedef struct {
d35df41eac69 Initial revision
kono
parents:
diff changeset
2 /* this is all wrong, but so what? */
32
b35787d8a442 macro initialization
kono
parents: 21
diff changeset
3 /* char pad[96]; */
b35787d8a442 macro initialization
kono
parents: 21
diff changeset
4 char pad[148];
0
d35df41eac69 Initial revision
kono
parents:
diff changeset
5 } FILE;
d35df41eac69 Initial revision
kono
parents:
diff changeset
6
18
df7fa8cee67b pass -Wall
kono
parents: 0
diff changeset
7 #ifdef __APPLE__
0
d35df41eac69 Initial revision
kono
parents:
diff changeset
8
18
df7fa8cee67b pass -Wall
kono
parents: 0
diff changeset
9 extern FILE __sF[];
df7fa8cee67b pass -Wall
kono
parents: 0
diff changeset
10 #define stdin (&__sF[0])
df7fa8cee67b pass -Wall
kono
parents: 0
diff changeset
11 #define stdout (&__sF[1])
df7fa8cee67b pass -Wall
kono
parents: 0
diff changeset
12 #define stderr (&__sF[2])
df7fa8cee67b pass -Wall
kono
parents: 0
diff changeset
13
df7fa8cee67b pass -Wall
kono
parents: 0
diff changeset
14 #else
21
f9f789aa7587 Linux version (Redhat 7.2)
kono
parents: 20
diff changeset
15 #ifdef bsd
0
d35df41eac69 Initial revision
kono
parents:
diff changeset
16 extern FILE __sstdin;
d35df41eac69 Initial revision
kono
parents:
diff changeset
17 extern FILE __sstdout;
d35df41eac69 Initial revision
kono
parents:
diff changeset
18 extern FILE __sstderr;
d35df41eac69 Initial revision
kono
parents:
diff changeset
19
d35df41eac69 Initial revision
kono
parents:
diff changeset
20 #define stdin (&__sstdin)
d35df41eac69 Initial revision
kono
parents:
diff changeset
21 #define stdout (&__sstdout)
d35df41eac69 Initial revision
kono
parents:
diff changeset
22 #define stderr (&__sstderr)
21
f9f789aa7587 Linux version (Redhat 7.2)
kono
parents: 20
diff changeset
23 #else
f9f789aa7587 Linux version (Redhat 7.2)
kono
parents: 20
diff changeset
24 /* new Linux */
f9f789aa7587 Linux version (Redhat 7.2)
kono
parents: 20
diff changeset
25 extern FILE *stdin;
f9f789aa7587 Linux version (Redhat 7.2)
kono
parents: 20
diff changeset
26 extern FILE *stdout;
f9f789aa7587 Linux version (Redhat 7.2)
kono
parents: 20
diff changeset
27 extern FILE *stderr;
f9f789aa7587 Linux version (Redhat 7.2)
kono
parents: 20
diff changeset
28 /*
f9f789aa7587 Linux version (Redhat 7.2)
kono
parents: 20
diff changeset
29 #define stdin stdin
f9f789aa7587 Linux version (Redhat 7.2)
kono
parents: 20
diff changeset
30 #define stdout stdout
f9f789aa7587 Linux version (Redhat 7.2)
kono
parents: 20
diff changeset
31 #define stderr stderr
f9f789aa7587 Linux version (Redhat 7.2)
kono
parents: 20
diff changeset
32 */
f9f789aa7587 Linux version (Redhat 7.2)
kono
parents: 20
diff changeset
33 #endif
18
df7fa8cee67b pass -Wall
kono
parents: 0
diff changeset
34 #endif
19
b62230ea38f6 ifdef debug
kono
parents: 18
diff changeset
35
0
d35df41eac69 Initial revision
kono
parents:
diff changeset
36 #define BUFSIZ 1024 /* size of buffer used by setbuf */
d35df41eac69 Initial revision
kono
parents:
diff changeset
37 #define EOF (-1)
d35df41eac69 Initial revision
kono
parents:
diff changeset
38 #define NULL 0
d35df41eac69 Initial revision
kono
parents:
diff changeset
39
d35df41eac69 Initial revision
kono
parents:
diff changeset
40 typedef int size_t;
d35df41eac69 Initial revision
kono
parents:
diff changeset
41 typedef /*long*/ int fpos_t;
d35df41eac69 Initial revision
kono
parents:
diff changeset
42 typedef void *__gnuc_va_list;
d35df41eac69 Initial revision
kono
parents:
diff changeset
43
d35df41eac69 Initial revision
kono
parents:
diff changeset
44 void clearerr(FILE *);
d35df41eac69 Initial revision
kono
parents:
diff changeset
45 int fclose(FILE *);
d35df41eac69 Initial revision
kono
parents:
diff changeset
46 int feof(FILE *);
d35df41eac69 Initial revision
kono
parents:
diff changeset
47 int ferror(FILE *);
d35df41eac69 Initial revision
kono
parents:
diff changeset
48 int fflush(FILE *);
d35df41eac69 Initial revision
kono
parents:
diff changeset
49 int fgetc(FILE *);
d35df41eac69 Initial revision
kono
parents:
diff changeset
50 int fgetpos(FILE *, fpos_t *);
d35df41eac69 Initial revision
kono
parents:
diff changeset
51 int fileno(FILE *);
d35df41eac69 Initial revision
kono
parents:
diff changeset
52 void flockfile();
19
b62230ea38f6 ifdef debug
kono
parents: 18
diff changeset
53
0
d35df41eac69 Initial revision
kono
parents:
diff changeset
54 int fprintf(FILE *, const char *, ...);
d35df41eac69 Initial revision
kono
parents:
diff changeset
55 int fpurge();
d35df41eac69 Initial revision
kono
parents:
diff changeset
56 int fputc(int, FILE *);
d35df41eac69 Initial revision
kono
parents:
diff changeset
57 int fputs(const char *, FILE *);
d35df41eac69 Initial revision
kono
parents:
diff changeset
58 size_t fread(void *, size_t, size_t, FILE *);
d35df41eac69 Initial revision
kono
parents:
diff changeset
59 int fscanf(FILE *, const char *, ...);
19
b62230ea38f6 ifdef debug
kono
parents: 18
diff changeset
60
0
d35df41eac69 Initial revision
kono
parents:
diff changeset
61 /* int fseek(FILE *, long int, int); */
19
b62230ea38f6 ifdef debug
kono
parents: 18
diff changeset
62
0
d35df41eac69 Initial revision
kono
parents:
diff changeset
63 int fsetpos(FILE *, const fpos_t *);
d35df41eac69 Initial revision
kono
parents:
diff changeset
64 long ftell(FILE *);
d35df41eac69 Initial revision
kono
parents:
diff changeset
65 int ftrylockfile();
d35df41eac69 Initial revision
kono
parents:
diff changeset
66 void funlockfile();
d35df41eac69 Initial revision
kono
parents:
diff changeset
67 size_t fwrite(const void *, size_t, size_t, FILE *);
d35df41eac69 Initial revision
kono
parents:
diff changeset
68 int getc(FILE *);
d35df41eac69 Initial revision
kono
parents:
diff changeset
69 int getc_unlocked();
d35df41eac69 Initial revision
kono
parents:
diff changeset
70 int getchar(void);
d35df41eac69 Initial revision
kono
parents:
diff changeset
71 int getchar_unlocked();
d35df41eac69 Initial revision
kono
parents:
diff changeset
72 int getw(FILE *);
d35df41eac69 Initial revision
kono
parents:
diff changeset
73 int pclose(FILE *);
d35df41eac69 Initial revision
kono
parents:
diff changeset
74 void perror(const char *);
d35df41eac69 Initial revision
kono
parents:
diff changeset
75 int printf(const char *, ...);
d35df41eac69 Initial revision
kono
parents:
diff changeset
76 int putc(int, FILE *);
d35df41eac69 Initial revision
kono
parents:
diff changeset
77 int putc_unlocked();
d35df41eac69 Initial revision
kono
parents:
diff changeset
78 int putchar(int);
d35df41eac69 Initial revision
kono
parents:
diff changeset
79 int putchar_unlocked();
d35df41eac69 Initial revision
kono
parents:
diff changeset
80 int puts(const char *);
d35df41eac69 Initial revision
kono
parents:
diff changeset
81 int putw(int, FILE *);
d35df41eac69 Initial revision
kono
parents:
diff changeset
82 int remove(const char *);
d35df41eac69 Initial revision
kono
parents:
diff changeset
83 int rename (const char *, const char *);
d35df41eac69 Initial revision
kono
parents:
diff changeset
84 void rewind(FILE *);
d35df41eac69 Initial revision
kono
parents:
diff changeset
85 int scanf(const char *, ...);
d35df41eac69 Initial revision
kono
parents:
diff changeset
86 void setbuf(FILE *, char *);
d35df41eac69 Initial revision
kono
parents:
diff changeset
87 void setbuffer();
d35df41eac69 Initial revision
kono
parents:
diff changeset
88 int setlinebuf();
d35df41eac69 Initial revision
kono
parents:
diff changeset
89 int setvbuf(FILE *, char *, int, size_t);
d35df41eac69 Initial revision
kono
parents:
diff changeset
90 int snprintf();
d35df41eac69 Initial revision
kono
parents:
diff changeset
91 int sprintf(char *, const char *, ...);
d35df41eac69 Initial revision
kono
parents:
diff changeset
92 int sscanf(const char *, const char *, ...);
d35df41eac69 Initial revision
kono
parents:
diff changeset
93 int ungetc(int, FILE *);
d35df41eac69 Initial revision
kono
parents:
diff changeset
94 int vfprintf(FILE *, const char *, __gnuc_va_list);
d35df41eac69 Initial revision
kono
parents:
diff changeset
95 int vfscanf();
d35df41eac69 Initial revision
kono
parents:
diff changeset
96 int vprintf(const char *, __gnuc_va_list);
d35df41eac69 Initial revision
kono
parents:
diff changeset
97 int vscanf();
d35df41eac69 Initial revision
kono
parents:
diff changeset
98 int vsnprintf();
d35df41eac69 Initial revision
kono
parents:
diff changeset
99 int vsprintf(char *, const char *, __gnuc_va_list);
d35df41eac69 Initial revision
kono
parents:
diff changeset
100 int vsscanf();
d35df41eac69 Initial revision
kono
parents:
diff changeset
101 char *ctermid(char *);
d35df41eac69 Initial revision
kono
parents:
diff changeset
102 FILE *fdopen(int, const char *);
d35df41eac69 Initial revision
kono
parents:
diff changeset
103 char *fgetln();
d35df41eac69 Initial revision
kono
parents:
diff changeset
104 char *fgets(char *, int, FILE *);
d35df41eac69 Initial revision
kono
parents:
diff changeset
105 FILE *fopen(const char *, const char *);
d35df41eac69 Initial revision
kono
parents:
diff changeset
106 FILE *freopen(const char *, const char *, FILE *);
d35df41eac69 Initial revision
kono
parents:
diff changeset
107 FILE *funopen();
d35df41eac69 Initial revision
kono
parents:
diff changeset
108 char *gets(char *);
d35df41eac69 Initial revision
kono
parents:
diff changeset
109 FILE *popen(const char *, const char *);
d35df41eac69 Initial revision
kono
parents:
diff changeset
110 char *tempnam(const char *, const char *);
d35df41eac69 Initial revision
kono
parents:
diff changeset
111 FILE *tmpfile(void);
d35df41eac69 Initial revision
kono
parents:
diff changeset
112 char *tmpnam(char *);