Skip to content

Conversation

@baloo
Copy link

@baloo baloo commented Oct 8, 2024

This is a small improvement for RustCrypto#1560

@turbocool3r turbocool3r merged commit cef6205 into turbocool3r:error-derive-attr Oct 8, 2024
@baloo baloo deleted the baloo/der_derive/error-type branch October 8, 2024 23:24
baloo added a commit to baloo/formats that referenced this pull request Oct 8, 2024
baloo added a commit to RustCrypto/formats that referenced this pull request Oct 9, 2024
* der: Custom error types in derive macros.

`Sequence`, `Enumerated` and `Choice` macros now support `#[asn1(error = Ty)]` attribute that provides a custom error type for `Decode`/`DecodeValue` implementations.

This addresses #1559.

* der_derive: use an ErrorType to store the error attribute

* der_derive: apply errortype to enumerated

followup on turbocool3r#1

* der: Add documentation for the `#[asn1(error)]` attribute.

---------

Co-authored-by: Arthur Gautier <[email protected]>
scv35 pushed a commit to scv35/format-encoders-decoders that referenced this pull request Jul 4, 2025
* der: Custom error types in derive macros.

`Sequence`, `Enumerated` and `Choice` macros now support `#[asn1(error = Ty)]` attribute that provides a custom error type for `Decode`/`DecodeValue` implementations.

This addresses #1559.

* der_derive: use an ErrorType to store the error attribute

* der_derive: apply errortype to enumerated

followup on turbocool3r/formats#1

* der: Add documentation for the `#[asn1(error)]` attribute.

---------

Co-authored-by: Arthur Gautier <[email protected]>
ghost-knightx56yui added a commit to ghost-knightx56yui/formats that referenced this pull request Nov 13, 2025
* der: Custom error types in derive macros.

`Sequence`, `Enumerated` and `Choice` macros now support `#[asn1(error = Ty)]` attribute that provides a custom error type for `Decode`/`DecodeValue` implementations.

This addresses #1559.

* der_derive: use an ErrorType to store the error attribute

* der_derive: apply errortype to enumerated

followup on turbocool3r/formats#1

* der: Add documentation for the `#[asn1(error)]` attribute.

---------

Co-authored-by: Arthur Gautier <[email protected]>
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