Commit f263fea
committed
Remove
Besides being a slight simplification (the only current use of
`file_create` is creating directories), if we add ways to create
other kinds of filesystem objects in the future, it's desirable
to create separate functions for them.
WASI has two levels of capabilities -- static and dynamic. The
static capabilities are the imports. By using separate functions
for separate file types, we can distinguish between the
capabilities to create different types of filesystem objects
statically.
And, users won't often need to specify what type of thing to create
dynamicaly. For example, the POSIX interface just has `mkdir`.file_create and add file_mkdir.1 parent 73ec778 commit f263fea
3 files changed
Lines changed: 9 additions & 5 deletions
File tree
- expected/wasm32-wasi
- libc-bottom-half
- cloudlibc/src/libc/sys/stat
- headers/public
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
39 | 39 | | |
40 | 40 | | |
41 | 41 | | |
42 | | - | |
43 | 42 | | |
| 43 | + | |
44 | 44 | | |
45 | 45 | | |
46 | 46 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
15 | 15 | | |
16 | 16 | | |
17 | 17 | | |
| 18 | + | |
18 | 19 | | |
19 | 20 | | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
20 | 25 | | |
21 | 26 | | |
22 | 27 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
639 | 639 | | |
640 | 640 | | |
641 | 641 | | |
642 | | - | |
| 642 | + | |
643 | 643 | | |
644 | 644 | | |
645 | | - | |
646 | | - | |
647 | | - | |
| 645 | + | |
| 646 | + | |
648 | 647 | | |
649 | 648 | | |
650 | 649 | | |
| |||
0 commit comments