blob: 9813b85c2690a4d071d50a4c178c93b1284b301d (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
|
#pragma once
typedef struct io·Reader
{
Iface impl;
int (*read)(void*, byte *buf, int n);
} io·Reader;
typedef struct io·ByteReader
{
Iface impl;
int (*read)(void*, byte *buf, int n);
byte (*get)(void*);
} io·ByteReader;
typedef struct io·Writer
{
Iface impl;
int (*write)(void*, byte *buf, int n);
} io·Writer;
typedef struct io·ReadWriter
{
Iface impl;
int (*read)(void*, byte *buf, int n);
int (*write)(void*, byte *buf, int n);
} io·ReadWriter;
typedef enum io·SeekPos
{
SEEK·set,
SEEK·cur,
SEEK·end,
} io·SeekPos;
|