Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for custom varule fields in #[make_varule] #3580

Merged
merged 2 commits into from
Jun 27, 2023

Conversation

Manishearth
Copy link
Member

cc @skius

sffc
sffc previously approved these changes Jun 26, 2023
@@ -600,6 +626,9 @@ impl<'a> UnsizedFieldKind<'a> {
match *ty {
Type::Reference(ref tyref) => OwnULETy::new(&tyref.elem, "reference").map(UnsizedFieldKind::Ref),
Type::Path(ref typath) => {
if let Some(custom_varule_ident) = custom_varule_ident {
return Ok(UnsizedFieldKind::Custom(typath, custom_varule_ident));
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Question: is it correct that previously, this only supported the exact matches ZeroVec, VarZeroVec, Cow, Vec, and Box, but now it supports things annotated with zerovec::varule as well?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

correct

@Manishearth Manishearth merged commit 8336bca into unicode-org:main Jun 27, 2023
@Manishearth Manishearth deleted the varule-attr branch June 27, 2023 08:14
@Manishearth Manishearth mentioned this pull request Sep 21, 2023
13 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants