protox
protox copied to clipboard
[Feature request] Define spec for structs
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?