Replies: 1 comment 1 reply
-
One possible workaround is that you can allocate a |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
As the title says, it would be useful to allow both borrowed and allocated types for a file mask.
Without looking at the code, my assumption is this should be fairly easy to accomplish just by replacing the field
mask: &'static str
withmask: Cow<str>
and internally lower it to an&str
. Library users would have to make a breaking change to add aninto()
call to their static masksExample usecase
For lutgen, it would be nice to keep a static slice of file extensions directly, used for both creating a custom footer doc and the file mask. ATM, I have to define the mask itself (ie,
*.png|*.jpg
) and then for the doc remove*.
and split the string along|
chars to be able to usedoc.literal()
for each item. With this change, I can move my constant to just a slice, and construct the mask at runtimeBeta Was this translation helpful? Give feedback.
All reactions