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

[codegen] Add missing debug impls to generic groups #641

Merged
merged 1 commit into from
Oct 6, 2023
Merged

Conversation

cmyr
Copy link
Member

@cmyr cmyr commented Sep 29, 2023

Aka the lookup and extension enums in gpos/gsub.

fixes #605

This also renames an internal method to match the name used elsewhere in codegen.

Aka the lookup and extension enums in gpos/gsub.
@@ -190,15 +190,15 @@ pub(crate) fn generate_group(item: &GenericGroup) -> syn::Result<TokenStream> {

let mut variant_decls = Vec::new();
let mut read_match_arms = Vec::new();
let mut as_some_table_arms = Vec::new();
let mut dyn_inner_arms = Vec::new();
Copy link
Collaborator

Choose a reason for hiding this comment

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

Nit: Feels like Hungarian notation which isn't really necessary in Rust. Would anything be particularly horrible about dropping dyn_ from various names? - we know it's dyn, it's in the signature.

Copy link
Member Author

Choose a reason for hiding this comment

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

nothing terrible, but the change here is just making this small portion of the code match the naming convention used everywhere else. This method is a private implementation detail related to the traversal code, and I don't have particularly strong feelings either way (the other name I had used here was 'as_some_table')

in any case if we want to change this it would be a significantly bigger diff and should be a separate PR.

@cmyr cmyr merged commit 37bf82b into main Oct 6, 2023
9 checks passed
@cmyr cmyr deleted the group-debug-impl branch October 6, 2023 14:53
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.

we aren't generating debug impls for fancy layout enums
2 participants