Skip to content

der/derive: support for skipped field #1008

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

Closed
wants to merge 1 commit into from

Conversation

baloo
Copy link
Member

@baloo baloo commented Apr 18, 2023

the parsing profiles (#987) rely on a PhantomData field to specify the underlying profile used when parsing.

This is specified like:

pub struct TbsCertificate<P: Profile = Rfc5280> {
    // ...
    #[asn1(skipped = "Default::default")]
    pub(crate) _profile: PhantomData<P>,
}

the parsing profiles (RustCrypto#987) rely on a PhantomData field to specify
the underlying profile used when parsing.

This is specified like:
``` rust
pub struct TbsCertificate<P: Profile = Rfc5280> {
    // ...
    #[asn1(skipped = "Default::default")]
    pub(crate) _profile: PhantomData<P>,
}
```
@tarcieri
Copy link
Member

@baloo can you confirm if #1009 eliminates the need for this?

@baloo
Copy link
Member Author

baloo commented Apr 18, 2023

Almost! see #1012

@baloo baloo closed this Apr 18, 2023
@baloo baloo deleted the baloo/der/skipped-fields branch April 18, 2023 19:49
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.

2 participants