-
-
Notifications
You must be signed in to change notification settings - Fork 55
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
Fix unknown id Type for EnumExt::deku_id() #398
Conversation
Remove unwrap causing the following error when the EnumExt tried to infer what type is was to return. An attribute could be added in the future to aid this, but for now we will just not emit the deku_id() for this type of enum. I decided in other causes (which aren't tested), to also remove the error and just not emit the function also. help: message: called `Result::unwrap()` on an `Err` value: Error("expected `,`") See #397
Benchmark for 65065c4Click to view benchmark
|
Fair enough. From a code-gen perspective, I'm not sure if there's a way of getting the type? probably some hackery via walking the struct/enum, etc. We currently have |
Right now we don't allow |
Yeah I agree, I don't favor that approach. You're right, currently we can't use |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks! This is a good solution for now, I created #400 to revisit in the future
Benchmark for dc44332Click to view benchmark
|
Remove unwrap causing the following error when the EnumExt tried to infer what type is was to return. An attribute could be added in the future to aid this, but for now we will just not emit the deku_id() for this type of enum. I decided in other causes (which aren't tested), to also remove the error and just not emit the function also.
help: message: called
Result::unwrap()
on anErr
value: Error("expected,
")Closes #397