OpenCores
URL https://opencores.org/ocsvn/eco32/eco32/trunk

Subversion Repositories eco32

[/] [eco32/] [trunk/] [lcc/] [include/] [alpha/] [osf/] [stdio.h] - Blame information for rev 84

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 4 hellwig
#ifndef __STDIO
2
#define __STDIO
3
 
4
#define _IOFBF 0
5
#define _IOLBF 0200
6
#define _IONBF 04
7
#define BUFSIZ 8192
8
#define EOF (-1)
9
 
10
typedef struct _iobuf {
11
        int     _cnt;
12
        unsigned char   *_ptr;
13
        unsigned char   *_base;
14
        int     _bufsiz;
15
        short   _flag;
16
        short   _file;
17
        char    *__newbase;
18
        void    *_lock;
19
        unsigned char   *_bufendp;
20
} FILE;
21
extern FILE _iob[];
22
#define FILENAME_MAX 255
23
#define FOPEN_MAX 64
24
 
25
#if !defined(_FPOS_T) && !defined(_FPOS_T_) && !defined(_FPOS_T_DEFINED)
26
#define _FPOS_T
27
#define _FPOS_T_
28
#define _FPOS_T_DEFINED
29
typedef long fpos_t;
30
#endif
31
 
32
#define L_tmpnam 21
33
#ifndef NULL
34
#define NULL ((void*)0)
35
#endif
36
#define SEEK_CUR 1
37
#define SEEK_END 2
38
#define SEEK_SET 0
39
 
40
#if !defined(_SIZE_T) && !defined(_SIZE_T_) && !defined(_SIZE_T_DEFINED)
41
#define _SIZE_T
42
#define _SIZE_T_
43
#define _SIZE_T_DEFINED
44
typedef unsigned long size_t;
45
#endif
46
 
47
#if !defined(_VA_LIST) && !defined(_VA_LIST_DEFINED)
48
#define _VA_LIST
49
#define _VA_LIST_DEFINED
50
typedef struct {
51
        char    *_a0;           /* pointer to first homed integer arg */
52
        int     _offset;        /* byte offset of next param */
53
        float   _tmp;
54
} __va_list;
55
#endif
56
 
57
#define stderr (&_iob[2])
58
#define stdin  (&_iob[0])
59
#define stdout (&_iob[1])
60
#define TMP_MAX 16384
61
 
62
extern int remove(const char *);
63
extern int rename(const char *, const char *);
64
extern FILE *tmpfile(void);
65
extern char *tmpnam(char *);
66
extern int fclose(FILE *);
67
extern int fflush(FILE *);
68
extern FILE *fopen(const char *, const char *);
69
extern FILE *freopen(const char *, const char *, FILE *);
70
extern void setbuf(FILE *, char *);
71
extern int setvbuf(FILE *, char *, int, size_t);
72
extern int fprintf(FILE *, const char *, ...);
73
extern int fscanf(FILE *, const char *, ...);
74
extern int printf(const char *, ...);
75
extern int scanf(const char *, ...);
76
extern int sprintf(char *, const char *, ...);
77
extern int sscanf(const char *, const char *, ...);
78
extern int vfprintf(FILE *, const char *, __va_list);
79
extern int vprintf(const char *, __va_list);
80
extern int vsprintf(char *, const char *, __va_list);
81
extern int fgetc(FILE *);
82
extern char *fgets(char *, int, FILE *);
83
extern int fputc(int, FILE *);
84
extern int fputs(const char *, FILE *);
85
extern int getc(FILE *);
86
extern int getchar(void);
87
extern char *gets(char *);
88
extern int putc(int, FILE *);
89
extern int putchar(int);
90
extern int puts(const char *);
91
extern int ungetc(int, FILE *);
92
extern size_t fread(void *, size_t, size_t, FILE *);
93
extern size_t fwrite(const void *, size_t, size_t, FILE *);
94
extern int fgetpos(FILE *, fpos_t *);
95
extern int fseek(FILE *, long int, int);
96
extern int fsetpos(FILE *, const fpos_t *);
97
extern long int ftell(FILE *);
98
extern void rewind(FILE *);
99
extern void clearerr(FILE *);
100
extern int feof(FILE *);
101
extern int ferror(FILE *);
102
extern void perror(const char *);
103
 
104
#define _IOEOF 020
105
#define _IOERR 040
106
 
107
#define getc(p) (--(p)->_cnt < 0 ? _filbuf(p) : (int) *(p)->_ptr++)
108
#define putc(x, p) (--(p)->_cnt < 0 ? \
109
        _flsbuf((unsigned char) (x), p) : \
110
        (int) (*(p)->_ptr++ = (unsigned char) (x)))
111
extern int _filbuf(FILE *), _flsbuf(unsigned, FILE *);
112
#endif /* __STDIO */

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.