You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The ReplyData and ReplyXAttr types use bytes::Bytes to pass data from the filesystem to fuse3. Because those methods are async fn, it makes sense that the buffer type must be 'static. However, using bytes::Bytes is unnecessarily restrictive. My file system does not use Bytes internally, so I must do a data copy from my own buffer type into a Bytes, only for fuse3 to immediately copy it again with Vec::extend_from_slice.
The extra data copy could be eliminated if Filesystem has a generic parameter type Buffer: AsRef<[u8]> + 'static, and the ReplyData and ReplyXAttr types use that instead of Bytes.
The text was updated successfully, but these errors were encountered:
The ReplyData and ReplyXAttr types use
bytes::Bytes
to pass data from the filesystem to fuse3. Because those methods areasync fn
, it makes sense that the buffer type must be'static
. However, usingbytes::Bytes
is unnecessarily restrictive. My file system does not useBytes
internally, so I must do a data copy from my own buffer type into aBytes
, only for fuse3 to immediately copy it again withVec::extend_from_slice
.The extra data copy could be eliminated if
Filesystem
has a generic parametertype Buffer: AsRef<[u8]> + 'static
, and theReplyData
andReplyXAttr
types use that instead ofBytes
.The text was updated successfully, but these errors were encountered: