4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
..
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
|
* ~ lexi hale <lexi@hale.su>
* this header declares IO primitive functions and
* structures. it is the same for all platforms.
* platform-specific code is found in the *.platform.h
* files.
*/
#include <k/str.h>
#include <k/type.h>
#include <k/mem.h>
#ifdef __cplusplus
extern "C" {
#endif
................................................................................
kiocond_fail_no_space,
kiocond_fail_forbidden,
kiocond_fail_over_quota,
kiocond_fail_pfault,
kiocond_fail_too_big,
kiocond_fail_stream_mismatch,
} kiocond;
kiocond kiosend(kiochan, ksraw, sz*); // send data to a channel
kiocond kiosendall(kiochan, ksraw); // keep sending data to a channel until it's all sent
kiocond kiorecv(kiochan, ksraw*); // receive data from a channel
kmptr kiorecvall(kiochan, kmcell*, kmkind); // automatically allocate a bufer for a channel
// kmkind is only used if kmcell* is null
kiocond kiocon(kiochan, kiochan); // connect one channel to another
#ifdef __cplusplus
}
#endif
#endif
|
|
4
5
6
7
8
9
10
11
12
13
14
15
16
17
..
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
|
* ~ lexi hale <lexi@hale.su>
* this header declares IO primitive functions and
* structures. it is the same for all platforms.
* platform-specific code is found in the *.platform.h
* files.
*/
#include <k/type.h>
#include <k/mem.h>
#ifdef __cplusplus
extern "C" {
#endif
................................................................................
kiocond_fail_no_space,
kiocond_fail_forbidden,
kiocond_fail_over_quota,
kiocond_fail_pfault,
kiocond_fail_too_big,
kiocond_fail_stream_mismatch,
} kiocond;
#include <k/str.h>
kiocond kiosend(kiochan, ksraw, sz*); // send data to a channel
kiocond kiosendall(kiochan, ksraw); // keep sending data to a channel until it's all sent
kiocond kiorecv(kiochan, ksraw*); // receive data from a channel
kmptr kiorecvall(kiochan, kmcell*, kmkind); // automatically allocate a bufer for a channel
// kmkind is only used if kmcell* is null
kiocond kiocon(kiochan, kiochan); // connect one channel to another
#ifdef __cplusplus
}
#endif
#endif
|