mirror of
https://github.com/0x221E/ibuild.git
synced 2026-01-18 02:42:20 +00:00
29 lines
458 B
C
29 lines
458 B
C
|
|
#ifndef IO_H
|
||
|
|
#define IO_H
|
||
|
|
|
||
|
|
#include "string.h"
|
||
|
|
|
||
|
|
typedef struct Arena Arena;
|
||
|
|
|
||
|
|
struct DirEntry
|
||
|
|
{
|
||
|
|
StringView path;
|
||
|
|
unsigned char type;
|
||
|
|
};
|
||
|
|
|
||
|
|
struct DirOpContext
|
||
|
|
{
|
||
|
|
Arena* a_f;
|
||
|
|
StringPool* sp;
|
||
|
|
};
|
||
|
|
|
||
|
|
typedef struct DirEntry DirEntry;
|
||
|
|
typedef struct DirOpContext DirOpContext;
|
||
|
|
|
||
|
|
// a should not contain a trailing slash
|
||
|
|
StringView path_concat_ss(StringPool* sp, StringView* a, StringView* b);
|
||
|
|
|
||
|
|
size_t dir_get_recursive(DirOpContext* doc, StringView* p);
|
||
|
|
|
||
|
|
#endif
|