protox icon indicating copy to clipboard operation
protox copied to clipboard

[Feature request] Define spec for structs

Open fermuch opened this issue 9 months ago • 1 comments

As described in the docs there is already a mapping of field to type.

And the decode/1 function is using a generic struct. As an example of the generated code:

@spec decode(binary) :: {:ok, struct} | {:error, any}

Would it be possible to generate a @type t for the structs?

fermuch avatar Oct 23 '23 12:10 fermuch