4 /* Decls for routines in ghc/runtime/io/ only used there.
5 * This file is used when compiling the Haskell library
6 * that _ccalls_ those routines; and when compiling those
7 * routines (to check consistency).
11 StgInt closeFile PROTO((StgAddr));
13 /* createDirectory.lc */
14 StgInt createDirectory PROTO((StgByteArray));
17 char * strDup PROTO((const char *));
18 int setenviron PROTO((char **));
19 int copyenv (STG_NO_ARGS);
20 int setenv PROTO((char *));
21 int delenv PROTO((char *));
25 extern int ghc_errtype;
26 void cvtErrno(STG_NO_ARGS);
27 void stdErrno(STG_NO_ARGS);
30 int execvpe PROTO((char *, char **, char **));
33 StgInt fileEOF PROTO((StgAddr));
36 StgInt fileGetc PROTO((StgAddr));
38 /* fileLookAhead.lc */
39 StgInt fileLookAhead PROTO((StgAddr));
42 StgInt getFilePosn PROTO((StgAddr));
43 StgInt setFilePosn PROTO((StgAddr, StgInt));
46 StgInt filePutc PROTO((StgAddr, StgInt));
49 StgInt fileSize PROTO((StgAddr, StgByteArray));
52 StgInt flushFile PROTO((StgAddr));
54 /* getBufferMode.lc */
55 StgInt getBufferMode PROTO((StgAddr));
58 StgInt getClockTime PROTO((StgByteArray, StgByteArray));
61 StgByteArray getCPUTime PROTO((StgByteArray));
63 /* getCurrentDirectory.lc */
64 StgAddr getCurrentDirectory(STG_NO_ARGS);
66 /* getDirectoryContents.lc */
67 StgAddr getDirectoryContents PROTO((StgByteArray));
70 int lockFile PROTO((int, int));
71 void unlockFile PROTO((int));
72 StgInt getLock PROTO((StgAddr, StgInt));
75 StgInt inputReady PROTO((StgAddr));
78 StgAddr openFile PROTO((StgByteArray, StgByteArray));
81 StgInt readBlock PROTO((StgAddr, StgAddr, StgInt));
82 StgInt readLine PROTO((StgAddr, StgAddr, StgInt));
83 StgInt readChar PROTO((StgAddr));
85 /* removeDirectory.lc */
86 StgInt removeDirectory PROTO((StgByteArray));
89 StgInt removeFile PROTO((StgByteArray));
91 /* renameDirectory.lc */
92 StgInt renameDirectory PROTO((StgByteArray, StgByteArray));
95 StgInt renameFile PROTO((StgByteArray, StgByteArray));
98 StgInt seekFile PROTO((StgAddr, StgInt, StgInt, StgByteArray));
99 StgInt seekFileP PROTO((StgAddr));
101 /* setBuffering.lc */
102 StgInt setBuffering PROTO((StgAddr, StgInt));
104 /* setCurrentDirectory.lc */
105 StgInt setCurrentDirectory PROTO((StgByteArray));
108 StgAddr showTime PROTO((StgInt, StgByteArray, StgByteArray));
111 StgInt systemCmd PROTO((StgByteArray));
114 StgAddr toLocalTime PROTO((StgInt, StgByteArray, StgByteArray));
117 StgAddr toUTCTime PROTO((StgInt, StgByteArray, StgByteArray));
120 StgAddr toClockSec PROTO((StgInt, StgInt, StgInt, StgInt, StgInt, StgInt, StgInt, StgByteArray));
123 StgInt writeFile PROTO((StgAddr, StgAddr, StgInt));
125 #endif /* ! STGIO_H */