Skip to content

Commit

Permalink
Rename is-same-file to is-same-object, and remove `is-same-mountp…
Browse files Browse the repository at this point in the history
…oint`.
  • Loading branch information
sunfishcode committed Jan 18, 2023
1 parent b19c6ad commit 3e69639
Showing 1 changed file with 3 additions and 18 deletions.
21 changes: 3 additions & 18 deletions wasi-filesystem.wit.md
Original file line number Diff line number Diff line change
Expand Up @@ -791,30 +791,15 @@ try-lock-exclusive: func() -> result<_, errno>
unlock: func() -> result<_, errno>
```

## `is-same-file`
## `is-same-object`
```wit
/// Test whether two descriptors refer to the same file or directory.
/// Test whether two descriptors refer to the same filesystem object.
///
/// In POSIX, this corresponds to testing whether the two descriptors have the
/// same device (`st_dev`) and inode (`st_ino` or `d_ino`) numbers.
/// wasi-filesystem does not expose device and inode numbers, so this function
/// may be used instead.
is-same-file: func(other: descriptor) -> bool
```

## `is-same-mountpoint`
```wit
/// Test whether two descriptors refer to files or directories on the same
/// mountpoint.
///
/// `rename-at` only works when source and destination are on the same mount
/// point. This function provides a way of testing whether two files or
/// directories are on the same mount point.
///
/// In POSIX, this corresponds to testing whether the two descriptors have the
/// same device (`st_dev`) number. wasi-filesystem does not expose device
/// numbers, so this function may be used instead.
is-same-mountpoint: func(other: descriptor) -> bool
is-same-object: func(other: descriptor) -> bool
```

```wit
Expand Down

0 comments on commit 3e69639

Please sign in to comment.