blob: b7c0ebd5ed9cf4fc4344d34476f6f1737855bbdf (
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
|
#ifndef ALGOS_IO_H_INCLUDED
#define ALGOS_IO_H_INCLUDED
#include <stddef.h>
#include <stdint.h>
struct stream {
size_t n;
size_t stride;
ssize_t last_idx;
int fd;
int out;
char *name;
};
/* for array implementation */
struct entry_a {
uint64_t val;
};
/* for linked list implementation */
struct entry_l {
uint32_t i; /* "pointer" to the next element. */
uint64_t val;
};
int stream_open(struct stream *in);
int stream_close(struct stream *in);
#endif /* ALGOS_IO_H_INCLUDED */
|